Adding memory to omp (Oh My Pi)
it keeps a session log per agent directory and reads none of it back
omp — Oh My Pi — writes a JSONL log per session under ~/.omp/agent/sessions/, with profiles keeping their own under ~/.omp/profiles/*/agent/sessions/, and can resume one. A new session reads none of the others, and nothing in it knows about the Claude Code or Codex session in the same repo last week. This page is about adding that.
What omp already has
The session logs, resumption, and an extension surface: one directory per module under the active agent directory's extensions/, with handlers registered on omp's event bus. It is a pi descendant, so much of the shape is pi's — but the store and the extension directory are its own, and the two are wired separately.
Adding recall
deja install omp-auto
Four things, all reversible with deja uninstall omp-auto:
- The extension at
~/.omp/agent/extensions/deja/index.js, which answers thecontextevent: a handler returning{ messages }replaces what goes to the provider, and that is the only seam here that reaches the model before it answers. - The MCP server in
~/.omp/agent/mcp.json, so what arrived can be followed up on — read a session in full, see a file's history, ask what fixed an error, store a decision. - The slash command at
~/.omp/agent/commands/deja.md, for asking directly. - The shared skill at
~/.agents/skills/deja-history/SKILL.md.
Which event, and that a returned list is honoured at all, came from running a probe extension against omp 17.4.1 and watching what fired: input never does in print mode, before_agent_start carries the prompt but not the context, and a marker prepended in context came back out of the model. The hook command names deja's launcher rather than the build it was installed from, so the extension keeps working when the binary moves.
What arrives
At the front of the context: a short digest of what this machine has done on the project — decisions, the commands that worked, the errors that recurred — and, when your prompt is already answered by your own history, that answer. Silence is the common case, and an injection is capped at 1,536 bytes per prompt and about 4 KB per tool call. What memory costs has the measured comparison.
The part that is not about omp
The index covers every agent's transcripts on the machine — thirty-four of them, each in its own format — so a fix found in Claude Code answers a question asked in omp, including sessions from before any of this was installed. A transcript a client later deletes stays searchable; only deja forget drops one on purpose. Nothing here writes memories, so there is nothing to hallucinate into your history; indexing and search are local, and credentials are stripped as the index is built (privacy).
Getting started · Switching between agents · The omp session format
Found this useful? Star deja-vu on GitHub.