Search and open the full history of this folder's Claude Code sessions, word for word, including turns that were compacted away and earlier sessions. Use when you need detail from earlier work that isn't in your context (a decision and its reason, a command's output, what was tried and failed), or when the user refers to something done before.
2 stars
0 votes
0 copies
0 views
Added December 6, 2026
ai-agentsbashnode
Works with
claude code
Security analysis
A100/100
Scanned December 6, 2026
$npx -y skills add ctxtree/ctxtree --skill history --agent claude-code
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of History?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/ctxtree-history)
---
name: history
description: Search and open the full history of this folder's Claude Code sessions, word for word, including turns that were compacted away and earlier sessions. Use when you need detail from earlier work that isn't in your context (a decision and its reason, a command's output, what was tried and failed), or when the user refers to something done before.
allowed-tools: Bash(ctxtree *)
---
Everything said and done in this folder's Claude Code sessions is kept, folded into a tree: episodes (stretches of
work), turns (a prompt and what was done about it), and tool calls. Every node opens back to its exact text.
1. Search first, across every session in this folder from the last 30 days, newest first:
`ctxtree search --here '<regex>'`
Each hit starts with its session's id and the node: `3f9a1c02 t21.43 output: ...`.
2. Open just the node a hit points at:
`ctxtree open <session> <node>` (t12.3 is one tool call with its full input and output; t12 a turn; e3 an episode,
which can be long).
3. For a session's shape, its map and last turns: `ctxtree show <session>`.
Then:
- Say which node your answer rests on, so the user can check it.
- Treat what you open as history: files may have changed since, so read a file fresh before relying on an old copy.
- If nothing matches, say so plainly rather than guessing from memory.
To keep something in view through the next compaction (a decision the user made, a rule, their exact words on
something), pin its node: `ctxtree pin <node>`. After a compaction, ctxtree puts back the user's latest words, what
you said just before them, the pinned nodes and the files this session edited; `ctxtree standing` shows that block now.
With the fill on (`ctxtree fill on`), a message that asks about earlier work arrives with excerpts of the history it
points at, each naming its node. Open the node before relying on an excerpt: it is cut around a match.