
claude-devtools
Shows every step Claude Code took in a session, with the files, edits and tokens behind it
by matt
by Nadim TuhinCLI toolWrite code
Shrinks the notes Claude Code rereads at every session start, so each uses fewer tokens
You open Claude Code and thousands of tokens of old session notes load before you type a word, every session.
For Claude Code usersPeople with long project notesPeople who watch their Claude Code usage
Claude Token Optimizer is a command-line tool for people who use Claude Code in a project folder. It counts how many tokens your CLAUDE.md and related files load at the start of each session, then moves old session notes and finished task lists into side files that Claude opens only when needed. It keeps a backup of the file it changes and shows the count before and after. It suits Claude Code users whose project notes have grown long.
It shows the token count first, so you can see what each session costs before changing anything.
Start with the first one: it is a small task you can check easily.
Example prompts written by Agent Flows Hub.
From the creator's documentation.
| Feature | What it does | Runs |
|---|---|---|
| Measure | Shows how many tokens load at session start, file by file | Your computer |
| Prune | Moves finished tasks and old session notes into side files, with a backup | Your computer |
| Compress | Shrinks a markdown file with fixed rules; it cuts long lists and comments | Your computer |
| Audit | Runs 19 structure checks on your project notes | Your computer |
| Before and after | Shows the token difference between a file and its backup | Your computer |
| Hooks | Optional Claude Code hook templates, for example one that warns when startup files grow too large | Your computer |
Your Claude Code project has a long CLAUDE.md full of old session notes and finished tasks. The tool measures what loads at session start and moves the old material into files Claude reads only on demand.
Notes by Agent Flows Hub (original project name: claude-token-optimizer (cto)), written from the creator's documentation, not from running it ourselves. Claude Token Optimizer: README and commands
Tell us what happened. We take a look first; if it needs paid work, you get an estimate before anything starts.