KoboldAI Lite normally keeps your story in your browser. Three server features change that:
- Multiplayer: several people work on one shared story.
- Server saves: save slots on the KoboldCpp computer, shared by everyone who can connect.
- Preloaded story: a story that KoboldCpp offers to everyone who connects.
Multiplayer
Section titled “Multiplayer”- In the launcher, open the Network tab and tick Shared Multiplayer (
--multiplayer). - Make KoboldCpp reachable for the others: same network, or Remote Tunnel. See Remote access.
- Set a Password: on the Network tab before you share the address.
- Click Launch.
- Give everyone the address and the password. They open KoboldAI Lite at your address, enter the password in the API Key Required box, and click Join Multiplayer in the top menu. Exit Multiplayer leaves the session.
The multiplayer endpoints need the password when one is set.
Server saves
Section titled “Server saves”- In the launcher, open the Loaded Files tab, tick Enable Server Side SaveData File and choose a file in SaveData File: (
--savedatafile). - Click Launch.
- In KoboldAI Lite, open Save / Load and choose KoboldCpp Server Storage as the location. The slots appear as Server Slot 1, Server Slot 2 and so on.
- There are 12 slots. Each story can be up to 10 MB.
- KoboldCpp adds
.jsondbto the file name:--savedatafile savescreatessaves.jsondb. A missing file is created, including its folders. - The slots are not private. Anyone who can connect can load, overwrite or delete them. The save endpoints need the password when one is set.
- Back up the
.jsondbfile to keep your saves. KoboldCpp rewrites the whole file on every save.
Preloaded story
Section titled “Preloaded story”Preload Story: on the Loaded Files tab (--preloadstory) takes a story saved from Lite as JSON. KoboldCpp serves it to frontends such as Lite.
When you export a template (.kcppt) from the launcher, the preloaded story is embedded in the template.
| Endpoint | Needs |
|---|---|
POST /api/extra/multiplayer/status, /api/extra/multiplayer/getstory, /api/extra/multiplayer/setstory | --multiplayer |
POST /api/extra/data/list, /api/extra/data/load, /api/extra/data/save | --savedatafile |
GET /api/extra/preloadstory | --preloadstory. Returns {} when none is set. |
Without --savedatafile, /api/extra/data/list and /api/extra/data/load close the connection without an answer. /api/extra/data/save returns HTTP 400.