Skip to content
Petro Bykov edited this page Oct 6, 2026 · 2 revisions

Claude Code telemetry widget: wiki

How every number in the menu is calculated. One page per topic. Each page opens with the answer, then one formula, then one worked example.

Pick a question

You want to know... Read
What did this request cost? Cost
Why does it say "150k context"? Context and cost threshold
Is my cache warm right now? Cache TTL
What is a "cold-cache restart"? Cold-cache detection
Why is the menu orange or red, and what should I do? Menu advice
What does the HTML session report add? Session report

Three facts

  1. Everything is local. Numbers come from ~/.claude/projects/**/*.jsonl. Nothing is sent anywhere.
  2. Prices live in prices.json. These are USD per million tokens, copied from Anthropic's pricing page.
  3. Thresholds live in config.json. Edit them from the menu with Edit thresholds.

Legend

  • D = documented by Anthropic
  • H = heuristic chosen by this project (not an Anthropic rule)

Source of truth: pricing.py, claude-usage.2m.py, session-report.py, ingest.py.

Clone this wiki locally