Vault
The vault is a persistent, shared file system accessible to agents across sessions. Think of it as the agent's long-term working directory — a place to save results, build up knowledge bases, and share files between agents and runs.
Vault files live in DATA_DIR/vault/ on the host.
Tools
| Tool | Description |
|---|---|
vault_read | Read the content of a file |
vault_write | Write (or overwrite) a file |
vault_patch | Apply a targeted edit — find-and-replace or JSON deep merge |
vault_list | List files in the vault (with optional path filter) |
vault_delete | Delete a file |
Vault in system prompts
Reference vault files directly in any agent's system prompt:
You are a knowledge assistant.
Company context:
@[context/company.md]
@[context/products.md]
@[context/policies.md]
Files are injected at session start. Update the vault files and they take effect on the next session.
Vault in the UI
The vault is accessible via Settings → Vault in the UI. You can:
- Browse the file tree
- Create, edit, and delete
.md,.json, and.txtfiles - Upload files from your computer
Examples
Saving research results
Save the research findings to vault/research/2024-q1-analysis.md
Building a knowledge base
The agent accumulates facts over time:
Read vault/kb/known-issues.md, add this new issue, and write it back.
Sharing between agents
Agent A writes vault/reports/draft.md. Agent B reads it, reviews it, and writes feedback to vault/reports/feedback.md. Agent A reads the feedback and revises.
vault_patch details
The patch tool supports two modes:
Text find-replace:
{
"tool": "vault_patch",
"path": "notes/todo.md",
"mode": "text",
"find": "- [ ] Task 1",
"replace": "- [x] Task 1"
}
JSON deep merge:
{
"tool": "vault_patch",
"path": "data/config.json",
"mode": "json",
"patch": { "api_version": "v2", "debug": false }
}
Configuration
| Setting | Default | Description |
|---|---|---|
vault_enabled | true | Enable or disable the vault tool |
vault_threshold | 100000 | Token count at which vault system prompt injections are included |
When the conversation is short, vault files injected via @[path] are always included. When the token count exceeds vault_threshold, Synapse summarises or truncates older context to make room.