vshulcz/deja-vu802

dsh-deja

Repository-root manifest for the DeepSeek Harness plugin that lives in extensions/dsh — the same package published to npm as dsh-deja. It re-exports the subdirectory so the plugin installs from a bare git URL or from github:vshulcz/deja-vu#path:extensions/dsh; the npm package is the shorter path. The repository itself is the Go project behind the deja binary.

包名
dsh-deja
版本
0.20.5
许可证
MIT
最近更新
2026年9月12日

安装

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:vshulcz/deja-vu

deja-vu

The one memory your coding agents share, built from the history already on your disk.

Your agent is about to re-debug something you fixed in March — in a different agent. deja indexes the sessions Claude Code, Codex, Cursor and every other agent on this machine already wrote to disk, and hands the right one back in whichever agent asks.

The same question put to the same agent twice: without memory it has no record of it, with deja it answers with the decision from eight months earlier

Nobody searched anything — the agent called deja itself. Every line is quoted from two real sessions.

Every memory tool starts empty and records forward. deja starts full.

And nobody has to ask for it: recall arrives at session start, on every prompt, before a file is edited or a command runs, and after one fails. Keys and tokens are stripped as the index is built, so what reaches the model is safe to send.

85.3% hit@1 on LongMemEval-S · 69.7% on LoCoMo · millisecond lookups over gigabytes of history

Both harnesses ship in this repo and run on the public datasets in minutes · check the numbers yourself

CI Release MCP Toplist MIT License

English | 中文

Docs · Benchmarks · How it compares

Install

curl -fsSL https://raw.githubusercontent.com/vshulcz/deja-vu/main/install.sh | sh
deja install --auto

What deja prints after the first index: the mark, the agents it found, and a query taken from your own history

Ten seconds to install, about ten to index, and it is useful. The second command wires MCP recall into every agent it finds, turns on session-start recall where the agent supports it, and builds the first index so the next session does not pay for it.

Start a new agent session and ask it something you worked on months ago:

have we dealt with jwt refresh rotation before? check your memory

It does not have to be asked, either — with auto-recall the agent already knows what you solved in that project when the session opens.

Other ways to install, and what to do if you want less than all of it

brew install deja-vu, go install github.com/vshulcz/deja-vu/cmd/deja@latest, or npx @vshulcz/deja-vu "query" to try it without installing anything. Desktop apps that take MCP servers as bundles can open the .mcpb from the latest release; it carries the binary.

Claude Code, Codex, Cursor, Qwen, OpenClaw and Copilot can take the same plugin bundle from their own marketplaces instead:

claude plugin marketplace add vshulcz/deja-vu && claude plugin install deja-vu@deja-vu

On Windows the install script exits with unsupported OS — it is a shell script. Use Scoop instead, from the main bucket every Scoop install already has:

scoop install deja-vu

Or take deja-vu__windows_amd64.zip from the latest release and put deja.exe on your PATH, e.g. in %USERPROFILE%\.local\bin.

The binary alone is a complete install for searching: index, search, show, ctx, blame, --json and redaction need nothing else. deja install is what wires MCP into your agents and turns on session-start recall — worth having, and optional. On a binary-only setup deja doctor reports every MCP target as not-wired, which is that setup working as intended. deja warmup also leaves a skill at ~/.agents/skills/deja-search/SKILL.md that teaches an agent the CLI contract — deja search --json, ctx, blame, how to read tier and total — so it knows history is searchable without MCP. The copy in the repo is skills/deja-search/SKILL.md.

deja install --all is --auto without the session-start recall: agents answer from memory when they decide to call it, rather than starting each session with it. The agent setup guide covers what each harness supports, aider's read-only context file, and the Windows cmd /c deja mcp wrapper.

What gets written into each agent's own guidance file

Install also writes user-level guidance for the harnesses it detects: Claude Code, Codex, opencode, Gemini CLI, Antigravity, Qwen, Kimi Code, pi, Copilot, VS Code Copilot Chat, Cursor, Goose, OpenClaw, Hermes, Roo Code, omp, Amp, prime-agent, DeepSeek Harness, Continue, Crush and Zed each get it in their own guidance file (or under the configured XDG_CONFIG_HOME). Re-run rewrites deja's skill or marked block without changing surrounding user content. Use deja install --all --no-guidance to opt out; Grok Build gets the shared skill in ~/.agents/skills, which is what it reads; the ~/.grok/GROK.md written beside it is for the unrelated community CLI that shares that directory. Cursor has no user-level instructions file, so it gets the shared skill in ~/.agents/skills — one of the four places Cursor reads skills from — read only when something looks relevant rather than every session.

What you get

Solve it in Codex. Claude remembers. Twenty-five coding agents write every conversation to local files, and deja turns those files into one memory layer all of them read.

Retroactive searchdeja "connection pool exhausted" over gigabytes, including everything from before you installed deja. Natural-language questions fall back to a relevance tier. Time is a hint, not a filter.
Cross-agent recallThe MCP recall tool answers "we fixed this three weeks ago" in whichever agent asks, whoever solved it originally.
It survives compactionMeasured over 43 compactions: the summary keeps 77% of the decisions and 0.2% of the commands you ran. deja hands back the other 99.8% — and on Claude Code and Codex it captures the task, the files and the commands as the compaction starts, then returns them once in the next session.
Recall at the point of actionBefore an agent edits a file or runs a command, deja names that file's prior decision, that command's working invocation, or the program this machine does not have. When a command fails, a PostToolUse hook answers with what followed that same error here before — the pair an agent never thinks to ask for.
It indexes the work, not just the talkThe files each turn opened, the commands that ran with their exit status, and the exact spans an edit replaced. That is the part every summary throws away.

Four more: rejected decisions, staleness, sync and handoff, redaction

It knows what helddeja promote --state rejected --note "why" marks a decision you reverted. Every later hit for that session shows it was tried and rejected, with the reason. Nothing is deleted, and --state accepted takes the mark back.
It says when the ground movedA hit reports 4 files this session touched have changed since, and says nothing when it cannot tell. It never claims anything is unchanged.
Sync and handoffdeja sync ssh laptop moves memory between machines, append-only, no cloud in the middle. deja handoff --to codex packages the live context so you can continue in another agent.
RedactionKeys, tokens, JWTs and private key blocks are stripped at index time, so the cache is safe to keep.

Your own work, wrapped

deja stats --card draws it in the terminal; give it a filename and it writes an SVG for a profile README. To post it anywhere else, turn it into a PNG — that page converts it in your own browser.

deja stats card: a year of agent sessions as a heatmap, the agents they came from, and the longest one

The full feature reference lives in the docs.

Privacy

Indexing and search are local. The network is used only by deja update, deja sync ssh, and the version check in deja doctor.

Credentials are redacted at index time: AWS keys, api_key= and token= assignments, bearer tokens and raw JWTs, PEM private key blocks, provider tokens, scheme://user:pass@host URLs, and high-entropy values for shapes no pattern knows. The value becomes [redacted:] and the surrounding text stays searchable. deja share and deja sync export re-apply redaction on the way out.

deja forget removes sessions from a rebuilt index and writes tombstones, so a later deja index cannot restore them from the source history. --unforget lifts a tombstone. Project exclusions are one pattern per line in ~/.config/deja/exclude.

The security model documents data flows, redaction limits, trust assumptions and release verification.

CLI

$ deja "jwt refresh token"
[claude] api        · Jul 8 · 8f31c0a9 — 2 matches
  login started failing after refresh token rotation; jwt kid mismatch in tests
  fixed by reloading jwks cache after rotateKey and adding a clock-skew test
[codex]  web        · Jul 1 · b77d91e2 — 1 match
  refresh token cookie needed SameSite=Lax in local callback flow

Ask your history

CommandWhat it does
deja Search every history. Multi-word is AND and quoted phrases require contiguous text; a query with no exact match then tries word forms and close spellings, which is where a substring reaches its word (code finds opencode).
dejaWith an index and a terminal: today's sessions, recalls served, a question you asked in more than one session, and a wall your agents keep hitting.
deja wipWhat the last session in this directory was doing: the task, what it settled, the files in flight, the last command and whether it failed — derived from the transcript, not from a note someone remembered to write.
`deja blame
`Which sessions discussed a file, what was decided, and why.
deja files The other direction: which files the work on a subject actually touched.
deja how How this machine actually runs a thing, with the real flags, from what agents ran before.
deja fix What this machine ran after that same error before, when the error did not come back.
deja frictionErrors that hit three or more separate sessions, with the harnesses named.

Using what it finds, and moving it between machines

Use what it finds

CommandWhat it does
deja ctx Markdown digest of the best match, ready to pipe into a prompt.
deja resume Reopen a found session in its native harness.
`deja restore
`Hand back a span an agent replaced, from the old_string its edit recorded. Never writes over the original.
deja promote Distill a session into a curated note with provenance, tags and a lifecycle state. Notes outrank raw transcripts.
deja share A sanitized session digest for a colleague, with secrets already scrubbed.

Move it and check it

CommandWhat it does
deja sync export/import/sshMove memory between machines. Watermarked, append-only, idempotent.
deja viewYour whole memory as one local HTML file. No server, nothing leaves the machine.
deja statsYour agent work, wrapped. --card draws it in the terminal, --card .svg writes one for a profile, --html a browsable timeline.
deja doctor [--deep]Self-diagnosis, and with --deep, proof of the index against the sources.
deja mcpThe stdio MCP server, which is what deja install wires in.

Full reference: commands and JSON output.

MCP tools

The server exposes one tool, deja, with a mode. deja install wires it in, so this is only needed to configure an agent by hand. The six older tool names (recall, recall_context, blame, fix, how, remember) still answer for anything already wired to them.

Arguments and return shapes

ToolArgumentsReturns
dejamode, plus query, path, error, what, text, tags?, harness?, project?, since?, limit?, offset?, all?Depends on the mode, below.
ModeArguments it readsReturns
recallquery, harness?, limit?, offset?Dense matching snippets, capped at 4KB.
contextquery, harness?Markdown digest of the best-matching session.
blamepath, harness?, project?, since?, limit?, all?Sessions that discussed a file.
fixerror, project?, limit?What this machine ran, or changed, after that same error before.
howwhat, project?, limit?The real invocation, from what agents ran here.
remembertext, project?, tags?Stores a durable decision for later recall.

Supported harnesses

With auto-recall installed, Claude Code and Codex hand deja the transcript as a compaction starts, and it keeps what the summary is about to drop: the task, the conclusions, the files, the commands with what each one did, and what was left open. The next hook for the same session and workspace gives it back once, inside a 4 KB budget, with a line saying whether the repository moved since. deja stats counts the tool calls before the first edit after a compaction, which is the number this is measured against. See automatic compaction recovery for what is read, what is stored and where the limits are.

aider · Amp · Antigravity · Claude Code · Cline · Codex CLI · Copilot CLI · VS Code Copilot Chat · Cursor · DeepSeek Harness · Gemini CLI · Goose · Grok Build · Hermes · Kimi Code · omp (Oh My Pi) · OpenClaw · opencode · Continue · Crush · pi · prime-agent (PrimeIntellect) · Qwen Code · Roo Code · Zed.

What each one supports

HarnessMCP recallAuto-recallSkillCommandResumeHandoffNeeds
aiderdeja aider
Amp
Antigravity