IT-RAT the stack/engram GitHub ↗
knowledge plane · wave 1

Engram. The memory that remembers why.

Vector search finds text that looks similar. It cannot say when a fact was true, where a belief came from, or that two beliefs disagree. Engram can: an embeddable memory in one SQLite file that stores raw episodes, distills them into facts with confidence scores, and answers why() for every belief it holds. No server, no Docker, and writing the first memory needs zero API keys.

releasev2.2.1 · PyPI engdbram
corePython 3.11+ · 424 tests
storagesingle SQLite file + sqlite-vec
recallhybrid BM25 + vector
integrationsMCP · LangChain · LlamaIndex
sixty seconds, one reflection

Watch five episodes become ten facts.

This is a simulation, but not a fantasy: it replays the shape of the live validation run, the first time Engram's reflection pipeline processed real Claude output instead of fixtures. Five episodes go in, reflect() reasons over them, ten subject-predicate-object facts come out: each scored for confidence, each traceable to its source episodes, zero contradictions. Three independent runs gave the same result.

under the hood

One file on disk. One optional network call.

Your agent calls observe() and recall() against one .engram file: SQLite plus sqlite-vec, in-process, nothing between the agent and its memory. Inside: three kinds of memory, bitemporal facts, spreading activation and Ebbinghaus decay. The only part that ever touches a network is reflect(), through a pluggable LLM adapter, and even that can route through TokenFuse.

agent observe · recall engram.db · SQLite + sqlite-vec episodic · semantic · procedural bitemporal facts spreading activation Ebbinghaus decay working memory writes in ~4 ms · no LLM in the write path LLM adapter Anthropic/OpenAI/Ollama via TokenFuse base_url reflect facts MCP server · stdio Claude Desktop · Cursor remember/recall/why/forget no network listener agent-event NDJSON memory_written·reflection_run contradiction·memory_forgotten opt-in · off by default
what it holds

Not a log of text. Beliefs with receipts.

Single file, embeddable

One .engram file on SQLite plus sqlite-vec: no server, no Docker, no config file. pip install, two lines of Python, and the first memory is on disk. Writes land in about 4 ms because no LLM sits in the write path.

reflect() distills facts

A background reflection loop groups recent episodes and asks an LLM to extract subject-predicate-object facts, each with a confidence score. Every fact keeps a why() chain: which episodes produced it, which run extracted it, which model, at what confidence.

Facts that know their dates

Every fact carries two timelines: when it was true in reality and when the system learned it. Ask what the agent believed as of March and get that answer, not today's. When Ivan changes jobs, the old fact is closed with an end date, not deleted.

Three ways to recall

Cosine vectors for meaning, BM25 blended with vectors when exact terms matter, and spreading activation that walks the entity graph. A query about Ivan can surface Project X because the graph connects them, even when the texts share no words.

GDPR forget, scoped

forget() erases an episode, forget_fact() a single semantic fact, forget_entity() cascades across episodes, facts and graph edges. Erasure is agent-scoped as of 2.2.1: one agent cannot delete another agent's episodes.

MCP server, stdio only

engram-mcp speaks stdio: no network listener, no port to guard. Claude Desktop, Claude Code and Cursor get remember, recall, why and forget against the same store with zero integration code. reflect() is deliberately not exposed to clients.

an honest comparison

Similarity is a fraction of memory.

Pinecone, Weaviate and pgvector are good at the problem they chose: similarity search over large corpora. Engram ships a vector index too, in-process. The difference is everything similarity cannot answer: when a fact was true, where it came from, whether two beliefs disagree. The third column is what most agents actually run on today.

EngramVector DBsRaw chat history
What it storesMemories with provenanceEmbeddings of textTranscripts
Reasons over timeBitemporal: valid + recordedNoNo
Explains itselfwhy() chain to source episodesNoNo
Contradiction handlingDetected, flagged as eventsNot a conceptNone
Runs whereIn-process, one fileManaged serviceIn your prompt window
Forget a personTargeted GDPR eraseDelete by id, if you kept the idsImpossible
in the stack

The plane that remembers.

Engram is the knowledge plane of the stack. Its own reflect() calls can point base_url at TokenFuse, so even thinking has a budget. Every memory_written, reflection_run, contradiction_found and memory_forgotten goes out as an agent-event on the same NDJSON bus Idryx correlates into the identity graph. The envelope they travel in is the Agent Passport contract: one spec, every service, including this one.

try it now
pip install engdbram

The PyPI name is engdbram (the plain name was taken); the import stays from engram import Engram. Your first memory needs zero API keys: an LLM enters the picture only when you ask for reflect().