Live data from Hacker News

Portal by Spotify cut my Claude Code token usage by 90%

engineering.atspotify.com

41–50 of 176 posts

Re: Portal by Spotify cut my Claude Code token usage by 90%

#44
post #18

So this is just delegating certain work to dumber models? I certainly wouldn't use Gemini 2.5 Flash (!!?) for code writing as suggested. I've never had an issue with Codex or Claude reading massive files, they're really good at precise greps.

> I've never had an issue with Codex or Claude reading massive files Reading files isn't a problem they want to solve. The idea seems to be using a cheaper model to "scout" for the intended code, instead of an expensive one that reads all the things (and spends more tokens / thinks about them). I think this might be useful because Opus 5 especially tends to over-read. So this looks like an "LLM Bloom filter", telling…

> "LLM Bloom filter"

very good way to put it.

Re: Portal by Spotify cut my Claude Code token usage by 90%

#45
post #18

So this is just delegating certain work to dumber models? I certainly wouldn't use Gemini 2.5 Flash (!!?) for code writing as suggested. I've never had an issue with Codex or Claude reading massive files, they're really good at precise greps.

> I've never had an issue with Codex or Claude reading massive files Reading files isn't a problem they want to solve. The idea seems to be using a cheaper model to "scout" for the intended code, instead of an expensive one that reads all the things (and spends more tokens / thinks about them). I think this might be useful because Opus 5 especially tends to over-read. So this looks like an "LLM Bloom filter", telling…

Pretty sure claude code already delegates reading a large codebase to haiku subagents.

Re: Portal by Spotify cut my Claude Code token usage by 90%

#46
post #18

Earlier quoted context omitted.

> I've never had an issue with Codex or Claude reading massive files Reading files isn't a problem they want to solve. The idea seems to be using a cheaper model to "scout" for the intended code, instead of an expensive one that reads all the things (and spends more tokens / thinks about them). I think this might be useful because Opus 5 especially tends to over-read. So this looks like an "LLM Bloom filter", telling…

Pretty sure claude code already delegates reading a large codebase to haiku subagents.

As of July, the explore agent inherits the parent model, capped at opus.

So fable and opus use opus to explore. Sonnet uses sonnet.

I replaced my built in explore agent with one hardcoded to sonnet low effort.

https://github.com/anthropics/claude-code/issues/72940

Re: Portal by Spotify cut my Claude Code token usage by 90%

#48
post #5

It cuts token usage because they are using a different service with a different token budget for the reader/code writer tasks. You can also just delegate this to subagents with Claude Code (though you have a more limited choice of models unless you swap the cheaper models via OpenRouter). I'm OK using a dumb model as a smart grep, but the whole point of using the frontier models is using their intelligence for the ha…

You can also use hooks to force the use of subagents for this. The stack here is entirely unnecessary

I’m currently on codex can it also this? I find it hard to make accurate benchmarks in token use for these kind of changes because I don’t keep repeating the same tasks.

Basically I run in luna high or extra high continuously with a terra subworker dedicated to planning and difficult research questions. Then I end with a final review in Terra or Sol depending how big the feature is.

Re: Portal by Spotify cut my Claude Code token usage by 90%

#49

Isn't this a somewhat standard multi-model setup? there's nothing ground breaking here, just delegate claude to plan -> smaller model for implementation.

Very standard in all coding harnesses/models I've worked with, with the bonus that everything listed in the "What doesn't work in Portal by Spotify" section still works. I've been watching Opus spin off work to Fable and Sonnet as appropriate all day.

Do you have specific instructions that cause this or did it come out of the box? Is it also when using normal prompting or only when you set a goal?

In codex I don’t see this behaviour despite having added the instructions to do so to my agents file. I also let that agents file be reviewed by Sol to come up with the right phrasing but no luck so far.

Post reply on HN