Spotify open-sourced a Claude Code plugin that sends bulk file reads to a cheaper model

Image: Spotify Engineering
Why it mattersReading files is the largest and least valuable part of an agent's token bill, and it can be delegated to a cheap model without changing where the reasoning happens.
Spotify published a post on 3 September describing how it cut Claude Code token use by routing file reading away from the main model. The plugin behind it, called shunt, is on GitHub under Apache-2.0 in the spotify/portal-ai-plugins repository. The post is written by Dimitri Mazmanov, a principal product manager at the company.
The measured claim is specific and narrow. Spotify says mean bulk-read savings were around 90%, comparing the tokens Claude would spend reading files directly against the tokens spent consuming a summary produced by a cheaper worker model. That figure covers reading only. The post says the code-writing case has no direct token measurement, because in the baseline Claude both reads the reference files and produces the output as expensive output tokens, while delegated code goes straight to disk and Claude never sees it.
How the routing decides
Two modes do the work. A bulk-reader mode reads several files and answers one question about them. A code-writer mode generates boilerplate that matches patterns already in the repository. Both run as what Spotify calls AiKA modes: declarative agents on ephemeral runtimes, where you set instructions, pick a model, and attach tools without running infrastructure yourself.
The plugin decides when to delegate using hooks that check file size, with a default threshold of 350 lines. Anything under that stays with the main model. This is the part worth copying even if you never install the plugin, because the rule is mechanical and does not depend on the agent choosing well.
What it refuses to hand off
The limits are stated plainly, which is unusual for a post about a saving. Editing cannot be delegated, because the summaries a worker model returns do not carry reliable line numbers. Reasoning and debugging stay with the main model. And delegation costs time: Spotify puts the overhead at 10 to 30 seconds per call, with Portal capping any single invocation at 30 seconds.
Spotify also quotes two industry figures as context rather than as its own measurement: that a quarter of engineering leaders already spend $200 to $500 per developer per month on tokens, and that AI coding costs are expected to pass the average developer salary by 2028. Those are the post's framing, not something it measured.
The repository is young and small. It was created on 23 July 2026 and had 39 stars when checked, so the traction sits with the write-up rather than the code: the post reached the Hacker News front page with 118 points. The plugin currently ships for Claude Code only.
The shape of the saving is more useful than the number. Bulk reading is high volume and low judgement, so it is the cheapest thing in an agent loop to move to a weaker model, and the quality risk is contained because a summary that is wrong shows up in the next reasoning step. A 90% cut on reads is not a 90% cut on a bill, since the reasoning and output tokens that cost the most are exactly the ones that stay put. The honest version of this is that one line item got cheaper and the rest did not, which is still worth having when reads dominate your usage.
Source
Portal by Spotify cut my Claude Code token usage by 90%, Spotify Engineering, 3 September 2026. Plugin source: spotify/portal-ai-plugins.
Source: Spotify Engineering
This item was written by an AI system from the linked source. Reveneau is responsible for what it publishes.
Get AI News in your inbox
New developer tools, model and agent releases, and how teams are actually shipping with them. Short, and only when there is something worth reading.
