Forget and export
Forget an item you do not want, see what forgetting does on disk, and export everything Weavekeep stores.
Forget an item
Find the item's id with weavekeep search, then pass it to forget:
weavekeep search stripe
weavekeep forget 43d63996Forget 1 item:
fact Payments go through Stripe Checkout 2h ago 43d63996
Forget these? [Y/n]
✓ Forgot fact 43d63996
✓ Forgot its note ece8e5ba- You can pass several ids at once:
weavekeep forget 4c9e21aa 0b77f3d1. - The 8-character short id from
searchworks, and so does the full id. - Every id is checked first. If one is unknown or matches more than one item, nothing is forgotten and the command exits with code 1.
- On a terminal you are asked first.
--yesskips the question. Without a terminal, the command goes ahead.
Related items go with it:
- Forgetting a decision or fact also forgets the note
rememberstored with it, which holds the same text. - Forgetting a session event (a prompt, a reply, a tool result) also forgets the facts that were taken from it.
The project's memory files are rewritten, so a forgotten decision disappears from decisions.md. Deleting a line from decisions.md or facts.md forgets it the same way.
Your agent can forget too, with its forget tool: when you say a memory is wrong, or when a new decision replaces an old one. See When you change your mind.
What forgetting means
Forgetting hides an item. It does not erase it from the disk.
- A forgotten item no longer shows up in
search, the agent's tools, the context at session start, or the memory files. - The item stays in the database file,
~/.weavekeep/keep.db, marked with the time it was forgotten and the reason. - If the item was large, its full text also stays in its file under
~/.weavekeep/blobs/. - You can still see forgotten items with
weavekeep export --include-forgotten.
Weavekeep never erases memory on its own. Only weavekeep uninstall --purge removes it from disk.
Caution
If a real secret slipped past the secret filter, forgetting it is not enough to remove it from disk. To remove everything Weavekeep stored, run weavekeep uninstall --purge, which deletes the whole ~/.weavekeep folder. Rotate the secret either way. See Privacy and security.
Export
export writes everything Weavekeep stores as JSON lines, one record per line:
weavekeep export > memory.jsonlEach line is one of:
{"type":"session","data":{"id":"…","project":"/home/you/projects/shop","client":"claude-code","started_at":"…","ended_at":"…", …}}
{"type":"event","data":{"id":"…","session_id":"…","kind":"user","content":"…", …}}
{"type":"fact","data":{"id":"…","subject":"…","predicate":"decision","value":"…", …}}Sessions come first, then events in session order, then facts. Secrets were removed when the text was stored, and export does not bring them back.
| Option | What it does |
|---|---|
--project <path> | Only this project |
--include-forgotten | Also forgotten and replaced items |
--blobs | Include the full text of large items (as full_content); otherwise only their first 1,024 characters |
--out <file> | Write to a file instead of stdout. The file is readable only by you, and a failed export never leaves a half-written file |
weavekeep export --project . --out backup.jsonlIf there is no database yet, export exports nothing and says so on stderr. It never creates a database.
Backup
weavekeep export --blobs --out <file> gives you a readable copy of all live memory. There is no import command, so an export is for keeping and reading, not for restoring.
To keep a copy you can restore, copy the whole ~/.weavekeep folder while no agent session is running. It holds the database, the large-item files and the memory files. See Files and settings.