deja-vu

Searchable local memory built from the session transcripts your coding agents already saved

By Vlad Shulcz (individual) Go Local · stdio Knowledge and memoryDeveloper tools

76 popularity score ★ 1.4k ↓ 3.1k/wk

Connect your client

Local (npm)

Add in one click

Opens the app, which asks before it adds the server.

Or add it by command or config

Claude CodeTerminal
claude mcp add deja-vu -- npx -y @vshulcz/deja-vu mcp
Claude Desktopclaude_desktop_config.json
{
  "mcpServers": {
    "deja-vu": {
      "command": "npx",
      "args": [
        "-y",
        "@vshulcz/deja-vu",
        "mcp"
      ]
    }
  }
}
Cursor~/.cursor/mcp.json
{
  "mcpServers": {
    "deja-vu": {
      "command": "npx",
      "args": [
        "-y",
        "@vshulcz/deja-vu",
        "mcp"
      ]
    }
  }
}
VS Code.vscode/mcp.json
{
  "servers": {
    "deja-vu": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@vshulcz/deja-vu",
        "mcp"
      ]
    }
  }
}
Codex~/.codex/config.toml
[mcp_servers.deja-vu]
command = "npx"
args = ["-y", "@vshulcz/deja-vu", "mcp"]
Gemini CLITerminal
gemini mcp add --scope user deja-vu npx -- -y @vshulcz/deja-vu mcp

Settings 9

DEJA_OFFLINE Optional: Set to 1 to turn off the daily release check.
DEJA_NO_UPDATE_NOTICE Optional: Any value stops the once-a-day latest-release check and notice.
Set together: semantic recall
DEJA_EMBED_URL Optional: Embeddings endpoint (Ollama, LM Studio or OpenAI-compatible). Unset, deja probes localhost:11434 and localhost:1234. `off` stops the probe. For semantic recall.
DEJA_EMBED_MODEL Optional: Embedding model name sent to the endpoint. Default nomic-embed-text. For semantic recall.
DEJA_EMBED_KEY secret Optional: Key for an authenticated embeddings endpoint. It takes precedence over OPENAI_API_KEY. For semantic recall.
OPENAI_API_KEY secret Optional: Used only when DEJA_EMBED_URL is an HTTPS api.openai.com address. For semantic recall.
DEJA_EMBED_OFF Optional: Set to 1 to stop the localhost probe. An explicit DEJA_EMBED_URL still wins. For semantic recall.
DEJA_EMBED_QUERY_PREFIX Optional: Text put before every search query, for models trained with prefixes such as E5 (`query: `). For semantic recall.
DEJA_EMBED_PASSAGE_PREFIX Optional: Text put before every indexed passage (`passage: ` for E5). Changing it means embedding again. For semantic recall.

What it does

deja-vu (the binary is called `deja`) reads the conversation logs that coding agents such as Claude Code, Codex, Cursor, opencode, Gemini CLI and dozens of others already keep on disk, and builds one local index from them. Any of those agents can then look up what was tried, decided or fixed in an earlier session. That works across agents, and for sessions from before deja was installed. The index also keeps which files each turn opened, which commands ran with their exit status, and what an edit replaced.

The MCP side is `deja mcp`, a stdio server. At v0.23.1 it declares one tool, `deja`, whose `mode` argument picks recall, context, blame, fix, how, orient, remember or handoff. The six older tool names (`recall`, `recall_context`, `blame`, `fix`, `how`, `remember`) still answer for clients that call them, though they are no longer listed. Recall answers are trimmed to a 4096-byte budget and blame returns 10 sessions unless `limit` is given (cmd/deja/mcp.go). A second server, `deja mcp --context-search`, offers a single `context_search` tool for Qwen Code.

The same binary is a terminal search screen and a CLI. `deja install --auto` writes the MCP entry, hooks and guidance files into each agent config it finds, but the server works without that step. From the CLI or the search screen, `deja delete <id>` erases a session from its agent and from deja. Search is lexical by default. Embeddings are optional: if you point `DEJA_EMBED_URL` at an endpoint and run `deja embed`, rephrased queries match too. The model defaults to `nomic-embed-text` when DEJA_EMBED_MODEL is unset, a default the README does not mention (internal/embed/client.go).

What it needs

RuntimeNode.js
Runs onmacOS, Windows, Linux
Also
  • At least one supported coding agent with session history on this machine
  • sqlite3 on PATH for agents that store sessions in SQLite (Cursor, opencode, Hermes, Crush, Kiro and others)
  • zstd on PATH for Zed, newer OpenClaw and some other stores

Node.js with npx for the npm way, which runs the packaged Go binary. Ways without Node: Homebrew, Scoop, winget, `go install` or the release archive. Semantic recall is optional and needs a reachable Ollama, LM Studio or OpenAI-compatible embeddings endpoint. With nothing reachable, lexical search and MCP recall carry on as before.

Limits

  • Not covered Only knows what agents wrote to local transcript files, so an agent that keeps no local history cannot be read
  • Not covered Search is lexical (word forms and close spellings) unless an embeddings endpoint is set up and `deja embed` has run
  • Size cap Each recall answer is capped at 4096 bytes, and blame returns 10 sessions unless `limit` is given (cmd/deja/mcp.go)
  • Limit Changing DEJA_EMBED_PASSAGE_PREFIX or the model means embedding everything again, since search skips vectors made with another model or prefix
  • Limit Redaction strips keys and tokens from the index only. The original transcripts stay as they were
  • Platform On Windows the curl install script exits with `unsupported OS`, and its docs use a `cmd /c deja mcp` wrapper there

It only knows what agents wrote to local transcript files, so it cannot read an agent that keeps no local history. TRAE IDE's chats sit in an encrypted database and are not read. Default search is lexical (word forms and close spellings), not semantic, unless you set up `deja embed`. Each recall answer is capped at about 4 KB, and blame returns 10 sessions by default (cmd/deja/mcp.go). Redaction strips keys and tokens from the index but leaves the original transcripts unchanged. The project's security model lists what redaction cannot catch. On Windows the curl install script exits with `unsupported OS`, and its docs use a `cmd /c deja mcp` wrapper there.

Who it suits

It suits developers who use several coding agents, or one agent over a long time, on their own machine and want earlier sessions to be searchable by the agent at work now. Nothing has to be captured by hand. All processing is local and needs no account. Look elsewhere if your agent keeps no local transcripts, if you want a shared team memory on a server, or if you need memory of general facts rather than coding-session history.

Tools 1

1 changes things. A ? marks an optional parameter.

deja changes
Single tool over past agent sessions. `mode` picks recall, context, blame, fix, how, orient, remember or handoff, and `q` carries the querymode: enumq?: stringharness?: stringproject?: stringlimit?: number

Similar servers