For Claude Code · Free and open source

Keep your prompt cache warm while you take a break.

Arm a window before lunch. If you return to a cold session, see the estimated rewrite cost before sending.

Warming needs early-access function hooks, a one-hour cache, and Claude Code left running. Pings cost tokens.

Keep it warm

/keepwarm arms six hours. After 50 idle minutes, an in-process timer sends a tool-less fork over the session. Each ping checks its usage; zero reads or writes reaching 10% of reads stop the loop. One verified run on Fable 5.1: a ping at minute 50 kept the cache alive, and the message sent at minute 62 read 156,886 tokens from cache. One run, one configuration.

/keepwarm off stops it. An already-cold session waits for your next turn before pinging.

Catch the cold send

For a context of at least 50,000 tokens, the guard drops your ordinary message once when its one-hour clock says the cache is cold. It shows the estimated rewrite cost. Resend to continue.

After a detected cold write, it automatically arms a three-hour warming window. The session card keeps score.

Recorded in real sessions

Recorded status slot: last ping read 75k tokens, costing $0.02
Sonnet 5, 16 September 2026: the status slot reported a 75k-token cache read at $0.02. This run used the one-minute testing interval on the 2.0.0 build; its card priced the rewrite at $0.45 with an older Sonnet row, and the current build prints $0.30 for the same context. It is a receipt for this session, not a universal ping price.
See the cold-send refusal
Recorded cold-send guard showing a $6.61 rewrite estimate
Recorded on 2.1.1, before the 2.1.2 wording change. The estimate was $6.61; the subsequent reported cache write was $6.28. Current wording says “up to” the estimated token count.

Install through the marketplace

claude plugin marketplace add karanb192/claude-code-mods
claude plugin install cache-tax@claude-code-mods

Start Claude Code with the early-access flag:

CLAUDE_CODE_ENABLE_FUNCTION_HOOKS=1 claude

In a warm session, run /keepwarm. Use /keepwarm 90m for a shorter window. Start with a window you expect to return within.

No function hooks yet? The hook version warns by default, refuses once with CACHE_TAX_BLOCK=1, and adds a status-line countdown that can also run on its own.

Know what you are paying for