@vshulcz/pi-deja
v0.20.2
Published
deja-vu memory for pi: the coding sessions already on this machine — pi, Claude Code, Codex, Cursor and 29 more — recalled at session start and on every prompt, searchable with /deja. A local index, no LLM.
Maintainers
Readme
@vshulcz/pi-deja
pi remembers its own sessions. This extension answers the other question: what was done in the thirty-two other coding agents on this machine — Claude Code, Codex, Cursor, Gemini, OpenClaw and Hermes among them — including the months before pi was installed.
It runs deja, a local Go binary that indexes the transcripts those agents already wrote to disk. No LLM, no embeddings, nothing leaves the machine.
Install
pi install npm:@vshulcz/pi-dejaThe deja binary comes with the package; a deja you installed yourself
(brew install deja-vu) always wins — see Which binary.
deja install pi-auto wires pi too, and is the shorter path if you have the
CLI: it adds deja's MCP server and writes an extension of its own. When that
extension is present this package stands down, so having both never injects
twice — and the same for omp, whose extension the installer writes elsewhere.
omp loads pi.extensions manifests and emits the same before_agent_start
event, so pi install's omp counterpart picks this package up as well.
What it does
- Session start: a digest of what earlier sessions in this project decided goes to the model before your first prompt; the receipt shows in the footer.
- Every prompt (
before_agent_start): the prompt is matched against the index and, when a past session answers it, that session goes to the model with the prompt. Silence is the common case. - After a failed command (
tool_result): the repair this machine used the last time that error came up goes in beside the error, in the same turn. - Before an edit (
tool_resulton a read): what earlier sessions decided about the file the agent just opened. - After a compaction (
session_compact): the list of what this session was already shown is cleared, so the recall it lost can come back. /deja <query>: search the history by hand.
Which binary
In order: DEJA_BIN, deja on PATH, the usual install locations, and last
the copy bundled through @vshulcz/deja-vu.
Privacy
deja reads session files where the agents wrote them and builds a local index
under ~/.cache/deja (or DEJA_INDEX_DIR). Keys and tokens are stripped as
the index is built. Nothing is uploaded.
Part of deja-vu. MIT.
