Token Cache Analysis — Development skill for Claude Code
Claude Code prompt cache efficiency analysis scripts.
How to install Token Cache Analysis
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open slmingol/token-cache-analysis and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Token Cache Analysis does
Claude Code prompt cache efficiency analysis scripts.
Alternatives in Development
- Benjamin Plus Skill — Benjamin-Plus: a measured token-efficiency skill for coding agents (−17.9% cost median, quality unchanged) 272 ★
- Caveman Micro — 6-line caveman micro prompt (85 tokens) that outperformed the original 552-token skill 162 ★
- Compact 서비스 (대화 요약) — 관찰 위치: Claude Code 내부 아키텍처 변수: NO_TOOLS_PREAMBLE, BASE_COMPACT_PROMPT, PARTIAL_COMPACT_PROMPT, PARTIAL_COMPACT 149 ★
README
[](https://python.org) [](https://github.com/slmingol/token-cache-analysis/blob/main/claude_cache.py) [](https://github.com/slmingol/token-cache-analysis/commits/main) [](https://github.com/slmingol/token-cache-analysis/stargazers) [](https://claude.ai/code)
Scripts for analyzing Claude Code prompt cache usage across all local sessions.
Background
Claude Code writes tokens to two cache tiers:
| Tier | TTL | Cost | Reuse |
|---|---|---|---|
| 5m ephemeral | 5 minutes | cheap | low — expires before next turn in slow sessions |
| 1h ephemeral | 1 hour | higher | high — survives across most session turns |
High 5m% = paying for cache that expires before it's reused. High 1h% = efficient.
Scripts
`claude_cache.py` — Daily totals
Scans all sessions, shows **daily** cache write breakdown.
python3 claude_cache.py
Example output:
Scanning all Claude Code session files...
Date 5m cache 1h cache Total writes 5m %
------------------------------------------------------------------------------
2026-09-01 0 14,231,482 14,231,482 0.0%
2026-09-08
Related Skills
Codex Token Meter
Native macOS menu bar apps for tracking Codex and Claude Code token usage, quota, cache efficiency, cost, and
Flowmeter Public
Local, privacy-first token, cost, cache, and trace analysis for Cursor, Claude Code, and Codex. Optional Flow-
Claude Mod Pack
Six Claude Code mods in one plugin (Token Weather, Cache Keeper, Wait What, Prompt Queue, Snake, Blast Radius)
Cato Plugin
Cut Claude Code token costs by 35-80% with prompt-cache TTL tracking, pre-read structural indexing, noisy CLI
Claude Architect
A plug-and-play framework for generating projects with Claude Code CLI — optimized for speed, token efficiency
Cc Statistics
270+ Three-in-one Claude Code stats: CLI + Web + native macOS SwiftUI panel. Token costs, code changes by lang
Related Agents
Usage Reporter
Reads real Claude Code usage from ~/.claude/stats-cache.json. Reports daily/weekly token usage by model, cache
Prompt Token Efficiency Verifier
AI Provider Expert
Primary reviewer for AI provider integrations, model routing, embeddings, prompt systems, streaming, token eff