How to Cut Claude Code's Token Costs 32% by Fixing Its Navigation Problem
The Navigation Problem You're Paying For
When you run claude code on a complex task, the agent doesn't use your IDE's "find references" or "go to definition" features. It uses grep. It reads hundreds of lines it doesn't need, gets lost, re-greps, and eventually finds what it's looking for after burning tokens on orientation.
This isn't just inefficient—it's expensive. A developer's benchmark of 54 automated runs on Sonnet 4.6 revealed that baseline agents average 25 navigation actions per code edit. That's 25 times the agent has to search, read, and orient itself before making a single change to your code.
The Tool That Fixes It: Scope
Scope is an open-source CLI tool (Rust, tree-sitter, SQLite) that gives Claude Code agents structural navigation commands. Instead of "search for this string," agents can ask for:
- "Show me a 180-token summary of this 6,000-token class"
- "Find all methods that call this function"
- "Search by what code does, not what it's named"
It's essentially giving agents the equivalent of IDE navigation. Currently supports TypeScript and C#, with the benchmark run on a 181-file C# codebase.
The Results That Matter
With Scope available, agents:
- Read more files (6.8 to 9.7 average)
- Made 67% more code edits per session
- Finished in fewer turns
- Achieved 32% lower cost per task
- Doubled navigation efficiency (13:1 nav-to-edit ratio vs 25:1)
The savings come from shorter conversations, which means less cache accumulation. And that's where ~90% of the token cost lives.
Task-Specific Results
The benefits vary by what you're asking Claude Code to do:
- Bug fixes: -62% cost
- New features: -49% cost
- Cross-cutting changes: -46% cost
- Discovery/refactoring tasks: No advantage (baseline agents already navigate these fine)
How to Use Scope Right Now
- Install it:
git clone https://github.com/rynhardt-potgieter/scope
cd scope
cargo build --release
- Configure Claude Code to use it:
Add to yourCLAUDE.mdor project context:
Available navigation tools:
- scope summary <file>: Get token-limited summary of large files
- scope find-references <symbol>: Find all uses of a symbol
- scope search-by-behavior <description>: Search code by what it does
- Test with your workflow:
Run the same task with and without Scope instructions. Track your Claude Code session length and token usage in the dashboard.
Why This Works
Claude Code's token economics work like this:
- Fresh input: $3/M tokens (reading new files)
- Cache write: $3.75/M tokens (agent thinking/planning)
- Cache read: $0.30/M tokens (referring to previous context)
- Output: $15/M tokens (generating code)
When agents get lost navigating, they create more cache (expensive) and have longer conversations (more cache accumulation). Scope reduces the "thinking" phase by giving agents direct answers to navigation questions.
The Caveats
- Statistical significance: p-values don't reach 0.05 at n=6 paired observations
- Language support: Benchmarked on C# only (TypeScript support exists but untested)
- Setup overhead: You need to install and configure the tool
What This Means for Your Workflow
If you're using Claude Code for:
- Bug fixing: Install Scope today—62% savings are real
- Feature development: 49% savings justify the setup
- Simple refactors: Skip it—no benefit
Track your own nav-to-edit ratio. If you see agents making multiple searches before each edit, you're wasting tokens on navigation.
The Bigger Picture
This isn't just about one tool. It's about recognizing that Claude Code agents need better navigation primitives. The MCP ecosystem should include more code-aware tools that understand structure, not just text.
What other navigation inefficiencies are you seeing? The developer community needs more benchmarks like this to understand where our tokens are actually going.




