sessions
Skill67 starsChanged 4 months agoMITView on GitHub
List recent Claude Code sessions as a table with auto-generated descriptions, session IDs, cwd, and turn counts. Use when the user asks "what sessions did I run", wants to find/recover a past or crashed session, or needs a session ID to resume.
24 other projects use a version of this.
Adopted by
Most recently taken up by
- EthanLLL/loomtheir own version, first seen Nov 8, 2026
- Mereithhh/very-happytheir own version, first seen Nov 6, 2026
- microsoft/vscodetheir own version, first seen Nov 2, 2026
- phnx-labs/agi-clitheir own version, first seen Oct 26, 2026
- phnx-labs/.agentstheir own version, first seen Oct 11, 2026
- NeuralInverse/neuralinversetheir own version, first seen Oct 8, 2026
Used with
Projects with it also use tool-rename-deprecation, add-policy and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
gitpod-ioSkilltool-rename-deprecation
Ensure renamed built-in tool references preserve backward compatibility. Use when renaming a toolReferenceName, tool set referenceName, or any tool identifier. Run on ANY change to tool registration code. Covers legacyToolReferenceFullNames for tools and legacyFullNames for tool sets.
Also in 5 projects that use this
OpenCortexIDESkilladd-policy
Use when adding, modifying, or reviewing VS Code configuration policies. Covers the full policy lifecycle from registration to export to platform-specific artifacts. Run on ANY change that adds a `policy:` field to a configuration property.
Also in 4 projects that use this
gitpod-ioSkillagent-sessions-layout
Agent Sessions workbench layout — covers the fixed layout structure, grid configuration, part visibility, editor modal, titlebar, sidebar footer, and implementation requirements. Use when implementing features or fixing issues in the Agent Sessions workbench layout.
Also in 3 projects that use this
slopusSkillmetrics-graphana
Query and manage Grafana dashboards and Prometheus metrics for Happy infrastructure. Covers grafanactl CLI usage, direct Prometheus queries through Grafana proxy, and dashboard-as-code workflows. Use when user asks about metrics, dashboards, monitoring, Grafana, Prometheus, or wants to add/modify panels.
Also in 3 projects that use this
slopusSkillcontrol-flow
Analyze and design control flows and data structures. Produces compact ASCII tree diagrams showing triggers, call chains, payload shapes, state mutations, and re-render effects. Use when user asks to diagram, trace, visualize, or design a flow or data structure.
Also in 3 projects that use this
TheKREATORSSkillrefactor-clean
No description
Also in 3 projects that use this
- +2 more from gitpod-io
Other versions24 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 24
- microsoft/vscode★ 195ksame name
- slopus/happy★ 25ksame name
- gitpod-io/openvscode-server★ 6.2ksame name
- posit-dev/positron★ 4.3ksame name
- NeuralInverse/neuralinverse★ 221same name
- OpenCortexIDE/cortexide★ 175same name
- Altman-conquer/agentrejoin★ 75same name
- elijahmuraoka/skills★ 58same name
- phnx-labs/agi-cli★ 26same name
- last9/mithai★ 20same name
14 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 repository24 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- autoresearchSkill
- brainstormSkill
- bug-huntSkill
- check-resolvableSkill
- compSkill
- debugSkill
- dialectic-reviewSkill
- distillSkill
- finalizeSkill
- implementSkill
- learnSkill
- plan-taskSkill
- premortemSkill
- red-teamSkill
- researchSkill
- retroSkill
- reviewSkill
- rsbSkill
- shipSkill
- socratesSkill
- tradeoffSkill
- verifySkill
- wrapupSkill
The file
Files
Session History Table
Lists Claude Code sessions from the local session store with a one-line description for each, so the user can find a session ID to resume or recover.
How it works
Claude Code writes one JSONL transcript per session under
~/.claude/projects/<encoded-cwd>/<session-uuid>.jsonl. Each transcript
contains an aiTitle record (Claude's own auto-generated session title) and
the user's prompts. The bundled list_sessions.py reads these, skips subagent
and workflow transcripts, and prints a table sorted by last-active time.
Run it
python3 ~/.claude/skills/sessions/list_sessions.py $ARGUMENTSFalls back to python if python3 isn't on PATH (e.g. some Windows setups) —
the script itself has no version-specific dependencies.
Arguments ($ARGUMENTS)
[days]— look-back window in days (default7).--project SUBSTR— only sessions whose cwd contains SUBSTR (e.g.--project myproject).--md— emit a GitHub-flavored markdown table (default: aligned monospace text). Use--mdwhen presenting the result inline to the user.--all— ignore the day window; list every session on disk.
Examples
/sessions→ last 7 days/sessions 14 --md→ last 14 days as a markdown table/sessions --project myproject --all→ every session ever, for a given project folder
Presenting results
Render the output as a markdown table for the user (pass --md, or reformat the
text output). Columns: last-active, turns, session ID, description. Point out
that a session is resumed with claude --resume <SESSION ID> — this works from
any directory, so the user does not need to cd anywhere first. If several
sessions share an identical timestamp, note that — it usually means a crash or
shutdown flushed them together.
Notes / gotchas
- Namespaces are already unioned — do not "fix" this. Transcripts are split
across one directory per launch folder (home,
~/Projects, one per project, …).list_sessions.pyglobsprojects/*/*.jsonl, so the*covers every namespace in one pass. Same forsession-search.py, which iterates the same root. - Resume is not namespace-scoped; the picker is.
claude --resume <ID>with an explicit ID resolves across namespaces and reattaches to the original transcript wherever it lives. Only--continueand the bare--resumepicker are limited to the current directory — those are the cases where launch folder matters. - Description fallback chain when a session has no
aiTitleyet: first typed prompt → first slash-command invocation (<command-name>+<command-args>, skipping config commands like /effort and /model) → thelast-promptrecord. - Turn count = non-meta user prompts, including slash-command turns.
0turns genuinely means an empty session. (Earlier versions undercounted slash-command-only sessions as 0 and labeled them "(no prompt)".) - Any secret-scanning hook that blocks shell
head/cat/heredoc pipes over these JSONL files should be respected — always read them inside a Python script (as this tool does), never via a bash pipe.
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.

