Claude 5-minute prompt cache vs GPT 30-minute cache: the cost of pauses(requesty.ai)
457 points by danvdb 4 days ago | 202 comments
tl;dr: Analysis of 30 days of coding-agent traffic found that Claude's 5-minute prompt cache TTL causes 23.1% of bills to be spent rebuilding expired caches, versus 9.3% for GPT's 30-minute TTL—despite identical per-token cache multipliers. The damage concentrates in 5-30 minute pauses (coffee breaks, diff reviews), where Claude loses 15.2% vs GPT's 0.8%, turning identically-priced models into a 34x cost gap per break. The most effective mitigation is adaptive `max_tokens: 0` keep-alive pings on idle turns, which recover ~8-9% of the Claude bill.
HN Discussion:
  • ↑Claude's 5-minute cache is puzzlingly short given typical workflow interruptions like builds and tests
  • ~The article's concerns mainly apply to API users since subscription plans default to 1-hour cache
  • ↑Keep-alive pings are a simple, effective mitigation worth implementing or automating
  • ~Keep-alive gaming parallels old OS scheduler tricks and vendors will likely counter them
  • •Questions and alternative solutions about cache transparency and client-side KV cache storage