find-session
Skill8 starsChanged 3 months agoMITView on GitHub
Find a past or active Claude Code session by searching transcript text — accepts a grep string, a regex, or a natural language description of the session
11 other projects use a version of this.
Adopted by
Most recently taken up by
- WingedGuardian/x4-ai-toolkittheir own version, first seen Nov 8, 2026
- WingedGuardian/skyrimvr-claude-toolkittheir own version, first seen Nov 8, 2026
- theyoungastronauts/polaristheir own version, first seen Nov 1, 2026
- ooooooooooooooooooop/agent-toolstheir own version, first seen Oct 22, 2026
- ooooooooooooooooooop/personal-aitheir own version, first seen Oct 22, 2026
- Aman-Kothari7/claude-code-skillstheir own version, first seen Oct 20, 2026
Other versions11 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 11
- fleurytian/awesome-claude-skills★ 316same name
- WingedGuardian/skyrimvr-claude-toolkit★ 21same name
- ooooooooooooooooooop/agent-tools★ 4same name
- ooooooooooooooooooop/personal-ai★ 4same name
- theyoungastronauts/polaris★ 4same name
- FooJiaYin/dev-skills★ 2same name
- LiozShor/claude-code-skills★ 2same name
- WingedGuardian/x4-ai-toolkit★ 2same name
- wardawgmalvicious/agent-config★ 1same name
- Aman-Kothari7/claude-code-skills★ 0same name
1 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository15 other files it gives its agents.
- AGENTS.mdAGENTS.md
- instructions/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- exploreSkill
- featureSkill
- fix-ciSkill
- humanizerSkill
- kauffj-voiceSkill
- proposeSkill
- review-prSkill
- review-securitySkill
- review-simplicitySkill
- review-uiSkill
- workspaceSkill
- writingSkill
The file
We split this skill into the rules it gives an agent
7 rules. 0 are common, 4 are distinctive, and 3 are very specific to this project.
0
Common
Most of the 8 edited versions we read keep these.
4
Distinctive
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 18
Use the search script that ships with this config (no other transcript spelunking needed):
- Very specific: line 38
Optional local extra: If $HOME/projects/claude-beep/claude-grep exists on this machine, it can additionally point at the tab: claude-grep …
- Distinctive: line 50
If it reads as a literal phrase or regex (quoted text, regex metacharacters, an exact error message or identifier), run it as-is — one …
- Distinctive: line 53
If it reads as a natural language description ("the session where we debugged the disk filling up"), derive 3–6 search patterns and run a …
- Distinctive: line 57
Derive good patterns from descriptions: Prefer distinctive, rare tokens over common words: filenames, function names, error fragments, …
- Very specific: line 64
Widen if needed: Start with --all --since 2d for a recent-sounding query.
- Very specific: line 94
If nothing matched even with --all, say so and show which patterns you tried, so the user can correct your guesses.
“Common” is measured: kept by at least 6 in 10 of the 8 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Find a Claude Code Session
You are searching the user's Claude Code session transcripts to find the session(s) they're thinking of. They often have 15+ terminal windows with active sessions and remember only a fragment of what was said.
Query: $ARGUMENTS
Tool
Use the search script that ships with this config (no other transcript spelunking needed):
$HOME/.claude/bin/claude-search PATTERN [--all] [--since 6h|2d|1w] [-m N] [--paths]- Searches the user + assistant text of session transcripts — what the user could scroll through in a terminal, not tool payloads — across Claude, Codex and Grok.
- PATTERN is a Python regex, always case-insensitive.
- Scope defaults to LIVE sessions only. Pass
--allto sweep history; that is the right default for "find the session where we…" questions about anything older than the tabs open right now. --since 6h|2d|1wlimits by how recently the transcript was touched.- Each hit prints the session id, project directory, match count, last-active age, the opening prompt (this is what identifies the terminal window), matching lines, and the exact command that reopens it.
- Exit code is nonzero with a "no matches" message when nothing hits.
Optional local extra. If $HOME/projects/claude-beep/claude-grep exists on
this machine, it can additionally point at the tab:
claude-grep --mark <session-id-prefix> renames that session's terminal tab to
🎯 <project> — FOUND 🎯 and rings its bell; --unmark <prefix> restores the
title. It writes to the tab's tty and may need sandbox override / permission
approval. It is a separate personal tool, not part of this config — check it
exists (test -x) before reaching for it, and just skip the marking step if it
does not. If the user says they found the tab, unmark it.
Approach
- Classify the query.
- If it reads as a literal phrase or regex (quoted text, regex metacharacters, an exact error message or identifier), run it as-is — one search.
- If it reads as a natural language description ("the session where we debugged the disk filling up"), derive 3–6 search patterns and run a search per pattern.
- Derive good patterns from descriptions. Prefer distinctive, rare
tokens over common words: filenames, function names, error fragments,
domain terms, project-specific vocabulary. Include synonyms the
conversation might have used instead of the user's wording (e.g.
"disk full" →
disk space,df -h,100%.*use,filled up). Use alternation (foo|bar) to keep the number of runs small. - Widen if needed. Start with
--all --since 2dfor a recent-sounding query; widen to--since 1w, then to a bare--all, when that yields nothing or only weak hits. If the user's wording implies age ("a while back", "last month"), start wide. Drop--allonly when the user says the session is open right now. - Merge and rank. Combine hits across patterns by session (the resume id). Rank by: number of distinct patterns that hit > recency > match count. A session matched by several independent patterns is almost certainly the one.
- Point at the tab. A session that still appears in a default (live)
claude-searchrun is open right now. If the best match is clearly the session the user described (one strong match, or several patterns agree) and the optionalclaude-grepis installed, runclaude-grep --mark <id-prefix>so its tab lights up — that is usually what the user actually wants. If multiple candidates are equally plausible, don't mark; list them and let the user choose.
Output
Lead with the best match. For each candidate (best first, at most ~5):
- Project directory, how recently it was active
- Whether it's open right now (it appears in a live-scope search) and, if you
marked it, that its tab is now named
🎯 <project> — FOUND 🎯 - Its first prompt (this is what identifies the terminal window)
- The one or two most telling matching lines
- The exact resume command:
claude --resume <session-id>
If nothing matched even with --all, say so and show which patterns you
tried, so the user can correct your guesses.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

