Skip to content

Claude Code: the plugin that saves 90% of reading tokens (and how to set it up)

Since the 50% bonus on Claude Code weekly limits ended on September 13, quotas have been tighter. A plugin developed by Dimitri Mazmanov, principal product manager at Spotify, claims to cut reading token consumption by 90%, according to his own benchmarks. Here's what the plugin does, how it works, and what to know before adopting it.

Why file reads weigh so much

According to the source, coding agents spend more time reading and editing files than reasoning. Every time Claude Code opens a large file, the entire content enters the context window and consumes input tokens. On a real project, these repeated reads can account for a significant share of the bill and quotas.

The plugin's idea is simple: don't let Claude read large files itself, but delegate that reading to a cheaper model, then return only the useful result to Claude.

Two agents, two roles

The plugin relies on two agents: bulk-reader for reading and code-writer for writing. The reader is handled by gemini-2.5-flash with a deterministic temperature of 0.2. According to the source, a million input tokens costs $0.30 on gemini-2.5-flash versus $5 on Claude Opus 5, a considerable price gap that explains most of the savings.

How the hooks block reads

The mechanism relies on two hooks:

  • check-file-size blocks reads beyond a configurable threshold, set to 350 lines by default.
  • check-bash-read applies the same blocking to bash commands like cat, head, or tail.

Targeted reads remain allowed: Claude can still read only part of a file. This matters because it avoids breaking workflows that need a specific excerpt.

The reported results, and their limits

The 90% reduction on reads was measured on a Java repo across four different scenarios. This is a benchmark run by the plugin's author, not an independent test. Spotify does not report any reduction figure for writing.

Several limits are documented:

  • The reader cannot retrieve precise line numbers during its analysis.
  • The delegated model remains less capable than Claude, and critical tasks are not delegated.
  • Each delegation can add 10 to 30 seconds of latency according to Spotify, with no detailed measurement protocol.
  • The plugin depends on Spotify Portal for agent access, a heavy dependency.

The Siphon fork: removing the Portal dependency

A fork by JDN, named Siphon, replaces Portal calls with a direct call to the Gemini API. This simplifies setup, but adds a dependency: delegated files are sent to Google's API. The Siphon fork's tests are reported by the article's author, not by a third party.

Another caveat: on Codex, no hook fires. Delegation then relies on the agent's willingness, making behavior less predictable.

Should you adopt it?

The plugin is most relevant if you work with large files and your Claude Code quotas are a bottleneck. It does not replace Claude for critical tasks and introduces latency. Conversely, if your reads are already targeted or your files stay small, the gain will be marginal.

Key takeaways

  • Reported savings: 90% of reading tokens, according to the author's benchmark.
  • Default threshold: 350 lines.
  • Input cost: $0.30/M tokens on gemini-2.5-flash versus $5/M on Claude Opus 5, according to the source.
  • Added latency: 10 to 30 seconds per delegation, according to Spotify.
  • Dependency: Spotify Portal, or the Gemini API via the Siphon fork.

In short, it's a credible path to reducing reading costs, provided you accept the trade-offs on precision, latency, and reliance on an external service. The figures cited need validation on your own codebase before drawing definitive conclusions.

Source

Claude Code : ce plugin permet d'économiser 90% des tokens en lecture

Related reading