Lab notes

The files that run up the bill

2 min read

Token dashboards usually stop at the model name. That is the wrong grain. The invoice is a pile of reads: the same src/ tree pulled into context, the same generated fixture, the same 4,000-line types file the agent “just needed to check.” Graph Explorer is a tree of those files, sized by cache-aware cost — not by line count, not by how often a linter touched them.

Claude Code already writes which paths showed up in a turn. TokensLab rolls those touches up from file to folder to project so you can see concentration. A fat node is not a moral failure. It is a prompt you can cut in half tomorrow morning.

Why size-by-cost beats size-by-tokens

Raw token counts lie the same way a naive invoice lies. A cache read of two million tokens is not two million tokens at the input rate; it is 0.1×. A 1-hour cache write is 2×. If the graph used a single multiplier, the noisiest folder would always look like the most expensive one, and you would “optimize” the wrong place.

The graph uses the same five-class pricing as the dashboard. A file that is only ever cache-read looks smaller than a file that keeps forcing cache creation. That is the distinction that actually moves the bill.

What to do with a fat node

  • Stop dumping the whole package into the system prompt. Point at the module.
  • Keep generated or vendored trees out of the default context pack. Skills Explorer will show you if a skill is still dragging them in.
  • If one project dominates all-time spend, open it from the dashboard. The briefing is the same dollars, scoped.

This is the gain the landing page is selling: not another chart of “tokens this week,” but a map of which files you paid to keep in the model’s working set. Install TokensLab, open Graph, and look at the heaviest branch. That branch is the prompt.

WhatsApp All notes