Agent skill

Deja History Search

by vshulcz in vshulcz/deja-vu

Searches this machine's own history of past AI coding sessions across every tool used on it, before work is redone or something is denied.

MITAuto-check passedAgent Workflows

Install Deja History Search

skills CLI
$ npx skills add vshulcz/deja-vu --skill deja-history -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install vshulcz/deja-vu deja-history --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/vshulcz/deja-vu.git skills-src && mkdir -p .claude/skills && cp -r skills-src/codex-plugin/skills/deja-history .claude/skills/deja-history && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
deja-history
GitHub stars
1.2k
Used in
1 other repo
Token cost
~1.4k tokens
SKILL.md length
865 words
Files
1
Skills in repo
2
Repo updated
First seen
Licence
MIT

At a glance

Searches this machine's own history of past AI coding sessions across every tool used on it, before work is redone or something is denied.

  • Works in 3 steps: Run deja rules candidates (--since 90d… → Find the standing rules in that list:… → Show the list and stop. Write nothing…
  • Checking whether an error was already debugged in a past session
  • SKILL.md covers Finding something, Reading a result, Saying what you used and Limits worth respecting, plus 1 more section
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

This skill calls a local deja tool in one of several modes before certain risky moments: before debugging an error that might already be solved, before changing code, a config, a dependency or a schedule, and before telling the user that something on the machine doesn't exist. It specifically calls out two easy-to-miss triggers that aren't phrased as questions - the user stating something already exists, and the agent being about to deny something exists itself.

Its modes cover different needs: a recall mode for a targeted keyword search using the most specific token available, a context mode for the full digest of the best-matching session once a hit looks right, a blame mode for the sessions that discussed a file before it's edited or deleted, a fix mode for finding past sessions that resolved the exact error text at hand, a how mode for the real command and flags this machine actually used for a build or deploy, and an orient mode for a project's past commands and files at the start of new work. If the tool isn't available as a native call, the same index is reachable through shell commands.

The index is built from session history already on disk across every AI coding tool used on the machine, going back further than the tool's own installation.

When your agent uses it

  • Checking whether an error was already debugged in a past session
  • Confirming something exists before telling the user it doesn't
  • Finding the exact command a past session used for a build or deploy

Example prompts

  • “Didn't we already fix this exact error before? Check past sessions.”
  • “What did we decide about the retry schedule last time?”
  • “Before I say this config doesn't exist, check deja for it.”

Requirements

  • The deja CLI or MCP tool indexed against this machine's session history

Workflow steps

3 steps, taken from the first numbered list in SKILL.md.

  1. Run deja rules candidates (--since 90d for recent ones). It lists turns where the user corrected an agent, across every tool on this…
  2. Find the standing rules in that list: preferences the user would want applied in every future session, stated in at least two different…
  3. Show the list and stop. Write nothing until the user picks. Then show the exact lines you will append to the rules file deja rules names…

What it can do on your machine

Read from SKILL.md and the folder at commit 2cba7ef. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Deja History Search loads about 1.4k tokens when it runs. Until then it costs about 148 tokens; SKILL.md has 865 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~148
When it runs · the whole SKILL.md, loaded when a task matches
~1.4k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from vshulcz/deja-vu at commit 2cba7ef, republished under its MIT licence (© vshulcz). 865 words, ~1,413 tokens.

Download SKILL.mdSave it as .claude/skills/deja-history/SKILL.md (or your agent's skills folder).
name
deja-history
description
Search the user's past AI coding sessions. Holds what they already settled and never wrote into the repo (naming rules, banned or already-tried tools, required checks before merge, preferred values, who owns what). Use before your first edit in a task, before you call a change done or ready to merge, before you recommend a tool, library, design or reviewer, before re-debugging an error that may already be solved, when they say 'didn't we fix this before', 'what did we decide about X' or 'I already have that', and before telling them something on this machine does not exist.

Search deja before re-deriving past work: when the user refers to earlier sessions or decisions, before debugging an error, and before implementing something that may already exist. It searches this machine's own history across every AI coding tool used on it, going back further than deja itself was installed.

Before your first edit in a task, and again before you call a change done, ready or safe to merge, call deja with mode recall and the task's key nouns (file, package, feature, setting). A rule, a rejected option or a check it returns outranks your defaults: follow it and say so in one line.

Two triggers are easy to miss because they are not questions:

  • The user states that something of theirs already exists and you have no record of it — "I already have X", "we use Y for this", "that's what Z is for". They are not asking; they are telling you the history exists, which is a stronger reason to search than a question is.
  • You are about to tell the user that something on this machine does not exist — a command, a file, a setting, a past decision. Recall first. Absence from the code in front of you is not absence from the machine, and a wrong denial sends them to rebuild what they have.

If the deja tool is not available in this session, the same index is reachable through the shell: deja search --json "<query>", deja ctx <query>, deja blame <path> --json.

Finding something

These are the modes of the one deja tool, passed as mode.

  • recall: search with the most specific token available — an exact error string, function name, file path, or flag. Several words are ANDed. Not for library docs or general knowledge; only this user's own sessions.
  • context: a full digest of the single best-matching session, once a recall hit looks right and the reasoning behind it matters.
  • blame: before editing, refactoring or deleting a file, the prior sessions that discussed it, so you know why it is shaped the way it is. Session history, not git authorship.
  • fix: paste a failing output verbatim to see the commands that followed that same error before, in sessions where it did not come back.
  • how: the real command with the real flags this machine runs for a build, test, deploy or script, ordered by how many sessions ran it. A guessed invocation is plausible and fails on this setup.
  • orient: at the start of work in a project, the commands past sessions ran there and the files they worked in, before you go reading.
  • remember: store one durable decision after it is settled, as a single self-contained fact. Not transcripts, not anything already obvious from the code.

Reading a result

A result may carry a bracketed marker with a date — that is the user's own later judgement on that session, and it is not advisory. Do not repeat a rejected approach. Prefer a replacement over what it replaced. Treat a stale result as needing confirmation before acting on it. A result with no marker carries no judgement in either direction.

Show full SKILL.md (349 more words)Show less

Saying what you used

When recalled history genuinely helps — a reused fix, a skipped re-debug, even a partial hint that changed your approach — tell the user in one short line at the start of your reply, naming the session: "déjà vu: we hit this JWT skew in March — reusing that fix (deja:a1b2c3d4-e5f)". Say nothing about recalls that did not help. This is provenance, not advertising; a note on every call would be noise.

Limits worth respecting

  • Result windows are bounded. Do not report corpus-wide counts, or claim a complete audit, from the number of hits you got back.
  • If deja is unavailable or the index is empty, say that history search is unavailable. Do not invent what it might have found.
  • Vary the wording and try a second query before concluding nothing is there. Exact tokens match best, so an error string beats a paraphrase of it.

Rules the user keeps repeating

When the user asks you to find or suggest their standing rules — the things they keep having to tell their agents:

  1. Run deja rules candidates (--since 90d for recent ones). It lists turns where the user corrected an agent, across every tool on this machine, each numbered #n with the session it came from. It writes nothing.
  2. Find the standing rules in that list: preferences the user would want applied in every future session, stated in at least two different sessions. Ignore one-off corrections about a specific task. For each rule give one imperative sentence, the #n that state it, and how many distinct sessions. At most 15, most recurring first.
  3. Show the list and stop. Write nothing until the user picks. Then show the exact lines you will append to the rules file deja rules names, append only those, and run deja rules sync, which copies the file into every installed agent's global rules file.

This takes a strong model: on one machine's 236 candidates a frontier model found the user's recurring rules with real citations, and a 9B local model invented candidate numbers. On a small model, say so rather than guess.

© vshulcz, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in codex-plugin/skills/deja-history of vshulcz/deja-vu.

Open the folder on GitHubat commit 2cba7ef

Used in 1 other repository

We found 6 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 1 other GitHub owner. This page covers the copy in vshulcz/deja-vu, which our catalogue first saw on October 7, 2026.

Compare with similar skills

Deja History Search next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Deja History Search compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Deja History Search this skillvshulcz/deja-vu1.2k1 repos~1.4kAutomated safety check: PassMIT
Beads Task Memorygastownhall/beads28k—~1.2kAutomated safety check: PassMIT
Session History Searchslopus/happy24k—~3.1kAutomated safety check: PassMIT
Memori Long-Term MemoryMemoriLabs/Memori17k—~2kAutomated safety check: NotesCustom licence
Coding Agent Session Findercode-yeongyu/oh-my-openagent70k—~2.8kAutomated safety check: PassCustom licence
Memori MCP Memory UsageMemoriLabs/Memori17k—~3.8kAutomated safety check: PassMIT

Similar skills

  • Beads Task Memory

    gastownhall/beads

    Tracks multi-session work with dependencies in the bd issue tracker so the agent can find ready tasks and recover its context after conversation compaction.

    28k GitHub stars~1.2k tokensUpdated today
    Agent WorkflowsAuto-check passed
  • Searches past Claude Code, Codex and Cursor sessions and summarizes what was worked on, tried or decided, using extraction scripts instead of reading raw logs.

    24k GitHub stars~3.1k tokensUpdated today
    Agent WorkflowsAuto-check passed
  • Memori Long-Term Memory

    MemoriLabs/Memori

    Connects Claude Code to Memori Cloud for long-term memory, recalling stored context before substantive replies and saving new context afterward.

    17k GitHub stars~2k tokensUpdated 8 days ago
    Agent WorkflowsAuto-check: notes
  • Coding Agent Session Finder

    code-yeongyu/oh-my-openagent

    Finds, reads and reconstructs past coding-agent sessions across Codex, Claude, OpenCode, Senpi and many other local agent logs.

    70k GitHub stars~2.8k tokensUpdated today
    Agent WorkflowsAuto-check passed
  • Memori MCP Memory Usage

    MemoriLabs/Memori

    Teaches an MCP-connected agent when and how to call Memori's recall, summary, compaction, augmentation, feedback and quota tools to keep context across sessions.

    17k GitHub stars~3.8k tokensUpdated 8 days ago
    Agent WorkflowsAuto-check passed
  • Ourmem

    ourmem/omem

    Shared memory that never forgets. An agent skill from ourmem/omem.

    174 GitHub starsUsed in 1 repo~3.4k tokens
    Agent WorkflowsAuto-check passed

More from vshulcz/deja-vu

  • Searches your own past AI coding sessions across every tool on this machine with the deja CLI, before you re-debug something already solved or deny that it exists.

    1.2k GitHub stars~2k tokensUpdated today
    Auto-check passed

Categories

Questions about Deja History Search

What does Deja History Search do?

Searches this machine's own history of past AI coding sessions across every tool used on it, before work is redone or something is denied. This skill calls a local deja tool in one of several modes before certain risky moments: before debugging an error that might already be solved, before changing code, a config, a dependency or a schedule, and before telling the user that something on the machine doesn't exist. It specifically calls out two easy-to-miss triggers that aren't phrased as questions - the user stating something already exists, and the agent being about to deny something exists itself.

When should I use Deja History Search?

Deja History Search fits situations like: checking whether an error was already debugged in a past session; confirming something exists before telling the user it doesn't; finding the exact command a past session used for a build or deploy.

How do I install Deja History Search in Claude Code?

Run `npx skills add vshulcz/deja-vu --skill deja-history -a claude-code`. Or copy the skill folder (codex-plugin/skills/deja-history in vshulcz/deja-vu) into .claude/skills/deja-history in your project. Claude Code loads it when a task matches its description.

How do I install Deja History Search in Codex?

Run `npx skills add vshulcz/deja-vu --skill deja-history -a codex`. Or copy the skill folder (codex-plugin/skills/deja-history in vshulcz/deja-vu) into .agents/skills/deja-history in your project. Codex loads it when a task matches its description.

Can I use Deja History Search in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add vshulcz/deja-vu --skill deja-history -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/deja-history, .gemini/skills/deja-history, .github/skills/deja-history and .opencode/skills/deja-history in your project.

What does Deja History Search need to run?

SKILL.md names no scripts, command-line tools or credentials: Deja History Search is instructions for the agent only. Our summary lists: The deja CLI or MCP tool indexed against this machine's session history.

Does Deja History Search access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Deja History Search safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Deja History Search use?

Deja History Search is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Deja History Search use?

About 1.4k tokens (SKILL.md is roughly 5.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Deja History Search?

Skills that share tags, products or a category with Deja History Search: Beads Task Memory (gastownhall/beads, 28k stars), Session History Search (slopus/happy, 24k stars), Memori Long-Term Memory (MemoriLabs/Memori, 17k stars) and Coding Agent Session Finder (code-yeongyu/oh-my-openagent, 70k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Deja History Search?

vshulcz (a GitHub user) maintains it in vshulcz/deja-vu, which has 1,169 GitHub stars. The repository holds 2 skills in this directory. The repository was last updated on October 10, 2026.

Source: vshulcz/deja-vu on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.