Stores

Everything your agent keeps is kept at a place: the agent's folder on this machine, a SQLite file, or an encrypted bucket of the agent's own. A store driver keeps each place outside the agent's sandbox, and the agent and the agent's tools reach every place through the same storage bridge.

Places Where Collections Live

An agent's things are six collections: its Home, instructions, skills, memory, conversations and schedule (Agent Spec). Local Link keeps each collection at one of three places, by that place's driver, outside the agent's sandbox. File Store keeps ordinary files, SQLite Store keeps rows in a local database, and Bucket Store keeps encrypted remote objects.

file

lnk-file-store keeps every collection as ordinary files in the agent's folder on this machine, LNK_STORE_DIR, which you read and edit as they are. A conversation's events are appended to a log, with a readable copy beside it, and the driver follows no link within the agent's folder (File Store).

sqlite

lnk-sqlite-store keeps all but home as rows of one SQLite file in the agent's folder, which moves with the agent's files (SQLite Store).

bucket

lnk-bucket-store keeps every collection as objects in the agent's bucket, the first encrypted one lnk storage connected for it, safe on one machine at a time (Bucket Store).

Choose Where Collections Are Kept

An agent's spec says in its [storage] which place the agent prefers for each collection, and the agent's machine decides. The machine's ~/.lnk/safe/agents/policy.toml lists the places the machine supports, and the agent's preference holds where the machine lists it (Where an agent's things are kept). A place whose driver isn't installed is installed as a module.

Show Your Agent's Storage Preferences

The agent's spec shows the storage preferences your agent currently uses.

lnk agent spec show

Keep Conversations Through a Driver

Read how conversations stay in local logs, compressed history, or a store driver in Link Harness.

Write a Store Driver

A driver is a program, lnk-<name>, that answers contract, call and serve, which the storage bridge invokes outside the agent's sandbox. The store interface defines a driver's requests and the reusable checks a driver passes. Tools reach files held outside their sandbox through the files bridge.