Interlinked.

Explainers · tokens, billing & waste · measured July 2026

What is a token? And why you pay for so many.

An AI model doesn't read words. It reads tokens: chunks of text about four characters long, roughly three-quarters of an English word. Type a sentence and the model's tokenizer slices it into these pieces, and you are billed for every one it reads and every one it writes. So the real question behind any AI bill isn't how smart the model is. It's how many tokens your work takes, and how many get spent on nothing.

TL;DR · The short version

A token is a chunk of text about four characters long (roughly three-quarters of a word), and you're billed for every one a model reads and every one it writes.

On a real 4.47-million-file machine, about 58% of a Claude Code session's tokens went to finding files (directory dumps and search output) before the answer even began.

A prebuilt index collapses that hunt into one tool call instead of 71 and 16 ms instead of 6m 57s: about a 7,200,000× speed-up, and the tokens spent hunting fall from ~58% to ~0%.

The engine stays quiet: a single-file lookup returns in 85 microseconds (139 median), a save is searchable in about 1 ms, and it idles near 44 MB, less than a browser tab.

Everything local is free forever, no card. Hosting starts at $5.99/mo: no keys, and the index never leaves the machine.

See one, tokenized

Text goes in. Tokens come out.

Here is a short instruction an agent might get, cut into tokens the way a model sees it. Short common words are usually one token each; a run-together identifier like getUserToken splits into several. As a rule of thumb, 1,000 tokens is about 750 words. The seven tokens at the top are the intent: what you meant. Everything below is what the agent dragged back to answer it.

STEP 1 · THE PROMPT YOU TYPED, IN TOKENSfindwheregetUserTokenisdefinedgetUserToken → 3 TOKENS1 TOKEN ≈ 4 CHARACTERS ≈ ¾ OF A WORD · THIS LINE = 7 TOKENSSTEP 2 · THE DIRECTORY DUMP IT PULLED BACK TO FIND ONE FILEsrc/app/page.tsxcomponents/uibutton.tsxnode_modules/.bindist/assetsindex.js.cache/webpack5.git/objects/packlib/utils.tshooks/useAuth.tspublic/fonts.woff2styles.csstest/__mocks__coverage/lcov.mapvendorchunk.jstypes.d.tstsconfig.json.envpackage.json.lockREADME.mdout/logsbin/tmp+ 3,900 MORE PATHS → THOUSANDS OF TOKENS, EVERY ONE BILLED

The prompt cost seven tokens. Finding the answer to it cost thousands: a directory dump the model never asked for, tokenized and highlighted in blue. You pay for that too, and it's the part that balloons.

How billing works

You pay by the token. Both directions.

Tokens are metered in two streams. Input is everything sent up to the model: the system prompt, the tool definitions, the whole conversation so far, and every tool result. Output is everything it writes back. When you buy Claude Max at $200 a month, or point Claude Code at a repo, that is what the money buys: tokens, in and out.

WHAT YOU’RE BILLED FOR ON EVERY TURNINPUT: EVERYTHING SENT UP TO THE MODELSYSTEM PROMPTTOOL DEFSHISTORYTOOL RESULTS · FILE LISTINGSOUTPUT: WHAT THE MODEL WRITES BACKTHE CODE← fewer tokens, billed at a higher rateINPUT IS THE BIGGER STREAM: TOOL RESULTS PILE IN, AND THE WHOLE THING IS RE-SENT NEXT TURN

Two things make input the bigger number. Tool results (directory listings, search dumps, files pulled in) land in the input stream. And a conversation is stateless, so the entire history is re-sent on every single turn. A file listing pulled in early isn't billed once; it's billed again on every step that follows.

Where the tokens actually go

So most of the bill isn't thinking.

On a real 4.47-million-file machine we measured where a Claude Code session's tokens went on a single file-hunt task. About 58% of them went to finding files (the directory dumps and search output from the diagram above, at full scale) before a line of the answer was written. Not reasoning. Not output. Navigation. You're renting a frontier model, and more than half of what it does is look for things.

58%
of a real session's tokens went to finding files, before the answer began
71
tool calls to locate a single file, the measured median
6m 57s
wall-clock time that one hunt cost, on the machine below

YOU'RE RENTING A FRONTIER MODEL TO RUN A DIRECTORY LISTING.

What changes with an index

One call. The junk never enters the bill.

Interlinked keeps a live, always-fresh index of every file on the machine: names and contents, every repo, including the git-ignored files a project-scoped search never sees. The agent asks once and gets the answer, so the hunt never lands in the context and never compounds. Same session, same answer: the tokens that were searching are now thinking.

Per lookupWalking the diskWith the index
Time to the file6m 57s16 ms
Tool calls711
Session tokens on hunting~58%~0%
Single-file lookupwalks the drive85 μs
Edit → searchablere-index / re-walk~1 ms

That is roughly a 7,200,000× speed-up on the measured task. A single-file lookup returns in 85 microseconds: 139 microseconds is the median across 20 queries on the 4.47-million-file drive, best case 2. A save is searchable in about a millisecond, under 30 milliseconds worst case, so the answer is never stale. The whole engine sits around 44 MB at rest (less than a browser tab) and its index takes under 1% of the drive.

Methodology: Ryzen 9 9950X3D · 64 GB DDR5 · NVMe · Windows 11 · 4,470,000 files. The agent run is the measured Claude Code session; lookup times are the indexed engine on the same corpus. The same session, drawn as a token budget, is in where your tokens go and priced out per developer in the cost of file-hunting.

Common questions

The questions people ask.

What exactly is a token?

A token is a chunk of text a model reads as one unit: about four characters, or roughly three-quarters of an English word. A tokenizer slices your text into these pieces, and you're billed for every one the model reads and every one it writes.

Why is my agent bill so high when my prompts are short?

Because most of the tokens aren't your prompt. On a real 4.47-million-file machine, about 58% of a Claude Code session's tokens went to finding files (directory dumps and search output) before the answer began. And because the conversation is stateless, that whole history is re-sent on every turn, so the junk is billed again on each step.

How does a local index actually lower the bill?

The agent asks once and gets the answer, so the file hunt never enters the context and never compounds. On the measured task that is one tool call instead of 71 and 16 ms instead of 6m 57s (about a 7,200,000× speed-up) and the share of tokens spent hunting falls from ~58% to ~0%.

Is it fast enough to stay out of the way while I work?

Yes. A single-file lookup returns in 85 microseconds (139 microseconds is the median across the 4.47-million-file drive) and a save is searchable in about a millisecond, so the answer is never stale. The whole engine idles around 44 MB, less than a browser tab.

What does it cost, and does anything leave my machine?

Everything local is free forever, no card, and hosting starts at $5.99/mo: no AI, no keys, no metered lookups, and nothing is uploaded unless you choose to publish a project.

Do this today

Spend your tokens on the work.

1

Install once. One signed installer auto-configures 19 AI clients: Claude Code, Cursor, Codex, Copilot, Windsurf, Zed, Cline and the rest. No JSON editing, no keys.

2

Let it index. Filename search works immediately; content search fills in behind it. At rest the whole engine sits around 44 MB and its index takes under 1% of the drive.

3

Ask in one call. Whole-machine when you don't know where something lives; scoped to a folder when you do. Either way the answer is one tool call, not seventy-one.

4

Watch the bill move. The tokens that were finding files are now reasoning. Same plan, same model: more of it spent on your actual problem.

Everything local is free forever, on all your devices, no card. Hosting starts at $5.99/mo. No AI, no keys, no metered lookups. The index never leaves the machine. Download for Windows.

Measured July 2026 · Ryzen 9 9950X3D · 4.47M files · Windows 11← All research