Memory lifecycle

One map of the six memory stores and the exact script or hook that moves data between them, with the trigger and cadence on every edge.

One map of the six memory stores and the exact script or hook that moves data between them, with the trigger and cadence on every edge.

Last Updated: 2026-08-08

HEADING OS keeps memory in six mechanisms. Each is documented on its own; what this page adds is the lifecycle: where a fact is written, how it is indexed for recall, when it is retired, and how the per-launch store stays in sync with the durable one. The diagram is the mechanism only. It names stores and the scripts that move data, never any real memory content.

The map

flowchart TD
    SESS([Session: Write tool]) -->|on demand| AM[auto-memory<br/>data-root/auto-memory + MEMORY.md]
    DREAM([/dream: manual, human-gated]) -->|consolidate: merge, reword, resolve| AM
    DREAM -->|consolidate| ODIN[ODIN brain<br/>knowledge/odin-brain]

    AM <-->|memory-reconcile.py<br/>SessionStart hook, newest-wins, no delete-propagation| NAT[native harness store<br/>per-launch, ephemeral]

    AM -.->|memory-auto-retire.py<br/>RETIRED: timer disabled, installer refuses| RET(((retired<br/>all stores)))
    AM -->|retire-memory.py<br/>manual, on explicit instruction, the delete that sticks| RET

    AM -->|memory-index.py build<br/>daily 03:30 incremental| IDX[(semantic recall index<br/>.memory-index)]
    ODIN -->|memory-index.py build| IDX
    THR[threads<br/>threads/business, personal] -->|memory-index.py build| IDX

    KB[knowledge base<br/>knowledge/] -->|promote-knowledge.py<br/>manual| COR[corporate knowledge<br/>knowledge/shared]

    SESSJSONL([past session transcripts<br/>~/.claude/projects]) -->|chronicle.py build<br/>daily timer, local gemma3:4b| CHR[conversation chronicle<br/>chronicle/business, personal]
    CHR -->|memory-index.py build<br/>business only, ranked below brain| IDX

    HYG([memory-hygiene.py: weekly Mon 07:34]) -.->|detect only, never mutates| AM
    HYG -.->|detect only| ODIN

The stores

Store Location Side
auto-memory data-root/auto-memory/*.md + MEMORY.md DATA (private)
native harness store per-launch Claude Code native memory dir DATA (ephemeral)
semantic recall index data-root/.memory-index/, plus engine .memory-index-code/ DATA + engine
ODIN brain data-root/knowledge/odin-brain/ DATA (private)
knowledge base data-root/knowledge/ (+ knowledge/shared/) DATA (private)
threads data-root/threads/business, personal DATA (private)
conversation chronicle data-root/chronicle/business, personal DATA (private)

The conversation chronicle is a distinct historical CLASS, not one of the belief stores above. It records “on date X we discussed Y” from past session transcripts; it is never promoted into the brain and never treated as a current fact. It is listed here because it shares the recall index, ranked below the belief stores, with its personal subtree air-gapped.

The edges, one by one

Driving it from one place

The six operations have one console-first entry point, scripts/memory.py, a thin facade that shells out to the scripts above with no behavior change:

python scripts/memory.py status      # read-only overview (index stats + knowledge health + count)
python scripts/memory.py recall "<text>"   # semantic query over the index
python scripts/memory.py promote --note <path>   # promote a knowledge note to corporate
python scripts/memory.py retire <name> [<name> ...]   # all-store retire
python scripts/memory.py reconcile   # sync native store with canonical (CLI mode)
python scripts/memory.py hygiene     # run the defect detector

Each subcommand returns the underlying script’s exit code and degrades with a plain message when a backing script or store is absent.

What this map deliberately leaves out

See also the Memory and Odin page for how the auto-memory and ODIN brain are used in practice.