Spotify cut Claude Code token usage 90% with a two-model routing setup called Portal
SumitGup · x · 2026-09-06
Spotify's engineering team shared "Portal," the internal setup that cut their Claude Code token usage by 90%. The insight: most coding-assistant work (opening five files to answer a question about one, cloning patterns from neighboring tests) requires no frontier-level reasoning yet is billed at top rates.
Key mechanics:
- Two cheap "assistant" models: one opens files and returns short summaries, another writes repetitive code from examples straight to disk. The expensive model never sees any of it.
- Files over 350 lines are hard-blocked from the expensive model—not steered away, blocked.
- Rules-as-instructions failed first; engineers and the model routed around soft rules. Hard blocks at the routing layer worked where prompt-level guidance didn't.
Implication: most frontier-model usage in coding workflows doesn't actually need frontier reasoning—architecture-level routing beats prompt engineering.
Related event: Spotify Cuts Claude Code Token Usage by 90% with Dual-Model Routing(2 posts)→
More from coding & agent
- Dev demos AI models handling 3D objects and animations surprisingly well — chongdashu · 2026-10-23
- Jason Kneen burns 104.56B tokens and $24.7K in 304 days of AI coding on Codex and Claude Code — jasonkneen · 2026-10-23
- Typosquatted Blender MCP Repo Hit 958 Stars in Days and Silently Ran Malware — Promptmethus · 2026-10-23
- Benchmarking 56 fresh dependency bugs: MCP routing lifts Claude Code accuracy 68% to 91% — Available_Side_7134 · 2026-10-23
- Swapping only the eval harness moves results 30%: designing agent evals like a scientist — AI Engineer · 2026-10-23
- Med student builds a whole-library RAG with Cognee; single-book ingestion still freezes his machine — shrike293103 · 2026-10-23