Hacker News new | ask | show | jobs
by HeavenFox 37 days ago
If they are literally sending the entire transcript and asking for a summary, wouldn't almost all of the tokens be cache hit, and therefore fairly cheap?
5 comments

I don't want to sound rude but even at cache hit you are burning almost input * 0.10 * context amount of tokens multiple times.

If it happens 10 times you have already accepted the same cost as the entire session fresh prefill.

People on HN are either too rich or wayyy too rich

But you also burn the exact same number of tokens (actually more) every time the model makes a tool call. It's an agent, it makes a lot of tool calls.
This is the right perspective. It costs as much as one additional tool call in the conversation. It’s a bit weird to do it on a timer, which inflates a bit over “just a tool call”, but not by much?
Tool calls don’t sent the full transcript? I think you mean one more turn?
Pretty much everything sends the full transcript. That’s how LLMs work, and why “compact before cache expiry” is now a default in Claude Code. Cache hits are incredibly cheap to service on the provider side.
Who pays for their own tokens at full price?
All Claude Enterprise customers.
Most claude code users, minority can still use subscriptions.
given that the subsidized plans from all companies are getting worse by the hour it's probably a smart thing to consider, at least.
I mean all big businesses (150+ peep) have to pay that much, it's the reality of the times. Getting some AI imho essential/good, one 200$ plan or spending 5000-7000$ per engineering team sure, 100$ plans or 3000$ for most semi technical staff definitely.

But if you are telling me I am wasting like a good 10-20% of my tokens on summaries I might as well stop using your service, worst part is claude doesn't let you use something else.

Isn’t it 0.2?
It's 0.1 I think brain fart I typed the rest correctly though after 10 summaries you still burn the same amount of tokens
Didn't they change the cache TTL to 5 minutes earlier this year? So depending on exact timing it could potentially be invalidated between the updates.
If you're using the API, I think. It's an hour when using Claude Code.
It's an hour. It'll tell you the expiry time on the status line now but that information is also available in /usage.
https://github.com/anthropics/claude-code/issues/46829

Looks like what I remembered was a bug.

Subagents have a default TTL of 5 minutes though, with an opt in to increase it to 1h, for a premium for writing to cache.
No, not necessarily - the prompt-cache is only hit if everything prior matches... including MCP & tool definitions. So to benefit from prompt-caching themselves they would need to include the tools you define to the summariser.

If they were doing that, then a cheaper (prompt-cache friendly) option is just to silently send the whole conversation with the summariser prompt appended

A cheap operation adds up to a large cost if it's done enough times. TFA even talks about caching.

Do you disagree with the numbers and conclusion in the -pretty obviously bot-generated- Fine Article?

Unless they prepend something like, "summarise this, "
But they definitely wouldn’t do that.
Yeah, this would have quadratic cost, but something silly has to be happening to waste a noticeable amount of tokens on summaries
Wouldn’t they?
I just had a look, and they don't. It's really just a temporary fork of the conversation, so it's fully cached. But it does run every 30 seconds, so that is very bad especially if it's a subagent that's at 800k tokens.

And I don't really get the point of this feature, I've always found it super annoying that the main agent creates a subagent with the clear description of "Fix tile cache" for example, and then after a while it turns into something generic like "Running browser tests"