The Lucid Memory Layer
The durable substrate the Decision System and the Deliberations pipeline both read from and write to.
It serves the theory of context activation defined at thelucidmind.ai: memory is stored; context is activated. This page is the implementation.
Source of truth
All epistemic content lives in epistemic_objects with a type discriminator and a content JSONB field. This is the authoritative store.
Rebuildable index
The vector store is derived, never authoritative: L2 must be fully rebuildable from L1. Lose it and nothing is lost.
Embedding writes are fire-and-forget. A Redis outage must never fail a Postgres write.
Embeddings are produced asynchronously through Celery using Ollama (nomic-embed-text, 768-dim). The L1 write commits first and independently; the embed task is dispatched after, wrapped so a broker outage degrades search quality temporarily but never blocks or fails the authoritative write.
Retrieval ranks candidates with a live composite of four terms — not similarity alone:
A temporal graph layer (Graphiti is the candidate) is being evaluated for relational and domain memory — the “Lucid Atlas”. It is scheduled, not built: this page marks it as evaluation, not a live component.