Who it is forA developer returning to a long Claude Code session after the cache has gone cold, who wants to know the cost before paying it.
The problemA cold resend silently rewrites the whole cached context, and the user has no price in front of them before the send.
The outcomeThe user sees an estimated rewrite price, resends only if they accept it, or clears the session and starts from a note.
What you need first
- Claude Code 2.1.287 or later
- A one-hour cache (included subscription usage defaults to one hour; API-key, usage-credit and cloud-provider sessions default to five minutes and need promptCacheTtl set to "1h")
- Claude Code left running during the break
Steps
- Install the plugin as described in the keepwarm use case, then restart Claude Code or run
/reload-plugins. - Run
/cache-taxto see the current cache estimate, warming window and this session's cold-write tally. - Keep the default with
/cache-tax guard refuse, or switch to/cache-tax guard warnto see the price and send without a drop. - When a cold send is dropped, read the estimated rewrite price, then send the message again to pay it, or run
/clearand start from a note.
Prompt for your agent
In the karanb192/cache-tax repo, with the cache-tax plugin installed, run /cache-tax in a resumed Claude Code session. Report the cache estimate and cold-write tally, and state whether the guard is set to warn or refuse. Verify that the guard mode matches the value you set with /cache-tax guard.
Caveat. The refusal figure is an upper bound and the README says these are API-equivalent costs, not extra subscription charges.
Use this in your AI agent
Ask your agent
Using the Deduped MCP, get the setup steps for karanb192/cache-tax and "See the rewrite price before a cold send"
Add Deduped to Claude Code once
claude mcp add --transport http deduped https://dedupedai.com/mcp
Every Monday: the 5 hottest repos and exactly how to use them. Free, one email a week, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer