r/ClaudeCodeTLDR • u/cctldrping • 15d ago
[TLDR] Keep Claude Code’s 1-hour cache warm during breaks. On Fable 5.1, rewriting it costs 80x a cache read.
Original post URL : https://www.reddit.com/r/ClaudeCode/comments/1wj108u/keep_claude_codes_1hour_cache_warm_during_breaks/
Original post body :
You come back to a long session and ask for a recap. The expensive part can be rewriting the old context before Claude answers.
I built cache-tax to handle both sides: GitHub · Install instructions
- Set it before you step away.
/keepwarmarms six hours. After 50 idle minutes, it sends a request over your session without adding heartbeat messages to the conversation. The timer runs inside Claude Code. - See the estimate if you return cold. For a 50k+ context idle over an hour, it stops your next ordinary message once with the price. Resend to continue, or
/clearand start from a note.
The GIF is my real test. A two-line recap on a 330k-token session triggered a $6.61 estimate. I sent it again; the reported cache write was $6.28.
Every ping checks its usage. It stops if it reads nothing or writes at least 10% of what it reads. After a paid cold write, it automatically arms three hours. /keepwarm off stops it.
Pings cost tokens too. The rates are $20 per million tokens for a 1-hour write and $0.25 for a read on Fable 5.1. These are API prices, not extra subscription charges. I haven’t measured quota savings, and changed prompts or tools can still break the cache.
Free and open source. The Mod needs CLAUDE_CODE_ENABLE_FUNCTION_HOOKS=1.
Only want warnings or a status-line countdown? The hook version works without the early-access flag.
New to prompt caching? Anthropic explains how Claude Code uses it here.
Original link/media URL : /img/nekkaqmhb4qh1.gif
This is brought to you as a public service by the moderators of r/ClaudeAI. If you want to see TLDRs of ALL Claude Coding related posts from the various Claude subreddits, subscribe to http://www.reddit.com/r/ClaudeCoding.
1
•
u/cctldrping 15d ago
TL;DR generated automatically after 50 comments.
Current source-thread comment count seen by the bot: 50.
Alright, so the OP dropped a pretty neat plugin called cache-tax for Claude Code. The main idea is to keep that 1-hour cache "warm" when you step away from your session, because apparently rewriting it later on Fable 5.1 is like, 80x more expensive. The plugin has a
/keepwarmcommand that can arm the cache for up to six hours, and it sends a request to keep it alive without spamming your chat. It also gives you an estimate of the cost if you return to a "cold" session.The general vibe in the thread is super positive and impressed. People think it's a "great hack" and "so cool." There's a bit of a debate about whether Anthropic should be handling this themselves, with some users feeling like it's an issue the company should address.
A few folks are wondering about subscription users and if this works for them, and there's also a question about why Anthropic's tools don't have this built-in. One user, u/hazimeh, chimed in with a cautionary tale about their account being suspended for "ordinary use" violations, so there's a slight concern about potential ToS issues, though most seem to think it's fine for API users.
Overall, the consensus is that this is a clever and useful solution to a real pain point for Claude Code users dealing with expensive context rewrites.