<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/github---izeigerman-claude-thermos-keeps-your-claude-session-warm-for-you-43gblyspt" -->

---
title: GitHub - izeigerman/claude-thermos: Keeps your Claude...
description: claude-thermos is an open-source tool that prevents Claude Code's prompt cache from expiring during long multi-agent sessions. When a main agent is blocked...
canonical: https://daily.dev/posts/github---izeigerman-claude-thermos-keeps-your-claude-session-warm-for-you-43gblyspt
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: GitHub - izeigerman/claude-thermos: Keeps your Claude session warm for you | daily.dev
og:description: claude-thermos is an open-source tool that prevents Claude Code's prompt cache from expiring during long multi-agent sessions. When a main agent is blocked...
og:url: https://daily.dev/posts/github---izeigerman-claude-thermos-keeps-your-claude-session-warm-for-you-43gblyspt
og:image: https://api.daily.dev/og/posts/43GbLYSpt.png
og:image:alt: GitHub - izeigerman/claude-thermos: Keeps your Claude session warm for you
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# GitHub - izeigerman/claude-thermos: Keeps your Claude session warm for you

**[Hacker News](https://daily.dev/sources/hn)** · 5 min read · 0 upvotes · 0 comments

## Summary

claude-thermos is an open-source tool that prevents Claude Code's prompt cache from expiring during long multi-agent sessions. When a main agent is blocked waiting on a subagent for more than 5 minutes, its prompt cache silently expires, forcing an expensive full re-encode at 1.25x the write rate. The tool runs as a local reverse proxy, monitors API traffic, detects when the main agent is idle while a subagent is active, and periodically sends minimal warm requests (max_tokens: 1) to keep the cache alive. Based on ~185 real sessions, cache rebuilds accounted for ~22% of total API costs. The tool logs per-session events and calculates net savings in token units that can be converted to dollars using the model's input price.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://github.com/izeigerman/claude-thermos>

## Community take

How the wider developer community reacted, aggregated from 1 discussion and 104 comments across hackernews (as of 2026-07-24).

**TL;DR:** The community is divided on whether keeping Claude's prompt cache alive via minimal pings is a legitimate optimization or a tragedy-of-the-commons abuse; most agree the real fix is for Anthropic to offer more flexible, adaptive cache TTLs.

**Sentiment:** 25% positive · 45% mixed · 30% skeptical

**The case for**

- Keeping the cache warm is a paid operation and Anthropic explicitly prices and incentivizes cache use, so it's not abuse.
- For long-running agentic workflows with active subagents, losing the main-thread cache mid-task wastes money and disrupts continuity.
- Cached input saves compute and electricity, so maximizing cache hit rates benefits everyone including Anthropic.

**The pushback**

- If widely adopted, this could reduce Anthropic's ability to oversubscribe infrastructure, effectively making service worse for other users.
- The tool may be solving the wrong problem — Anthropic should offer adaptive TTLs rather than users hacking around a 5-minute default.
- Refreshing a large context (e.g. 120k tokens) still costs cache-read tokens each time, so it's not as cheap as it sounds.
- Using 1-token pings to extend a cache that cost a full cache-write to establish may be gaming the pricing model.

**By community**

- hackernews (mixed): Commenters are split between viewing cache-warming as a legitimate paid feature and worrying about tragedy-of-the-commons effects, with broad agreement that Anthropic should build better adaptive caching instead.

**Hottest debate:** Whether refreshing the prompt cache with minimal pings is a legitimate use of a paid API feature or an exploit that unfairly consumes shared infrastructure at other users' expense.

**Open questions**

- Why doesn't Anthropic offer adaptive or longer cache TTLs natively for agentic workflows?
- Could Anthropic detect and ignore keep-alive pings to prevent cache-gaming without penalizing legitimate users?
- Is there a way for Claude Code to signal 'subagents are active, please retain cache' without requiring dummy requests?
- At what context size does repeated cache-read refreshing become more expensive than just re-doing prefill?

**Highlights**

> But you pay for cache writes, it's not like you're abusing anything, you're simply  choosing to call a billed API for the explicitly intended purpose of writing/refreshing cache. If you keep this running for hours without doing anything, it will drain your limits and API. The use case of keeping the main thread cache warm while subagents work is very genuine and legitimate.
> — [dannyw on hackernews](https://news.ycombinator.com/item?id=49030425)

> The prefix cache is a resource shared by all users. This is basically a tragedy of the commons.
> — [kakugawa on hackernews · 2 comments](https://news.ycombinator.com/item?id=49029616)

> Make the cache TTL more adaptive. Have more tiers than just 5m and 1h. Long-running subagents become increasingly ubiquitous. There's no reason for Anthropic to not do a better job for this use case.
> — [s0ck\_r4w on hackernews](https://news.ycombinator.com/item?id=49026690)

> It's unfortunate that there isn't some better way to signal that there's a high chance that a turn is coming (ie, due to active sub-agents). If CC could send a ping saying "I don't need a turn, but please keep this cached at some tier because there will be a turn soon." that would probably help with cache efficiency. Instead, it seems like there's just the shotgun one-hour solution.
> — [supern0va on hackernews](https://news.ycombinator.com/item?id=49027639)

> Compute is also a resource shared by all users. When your prompt isn’t cached, your input needs to go through prefill; which is compute-bound. The cache is discounted for a reason. They WANT you to use it.
> — [dannyw on hackernews](https://news.ycombinator.com/item?id=49030542)

**Source threads**

- [hackernews](https://news.ycombinator.com/item?id=49024882) · 45 points · 104 comments

## Similar posts on daily.dev

- [Anthropic quietly nerfed Claude Code's 1-hour cache, and your token budget is paying the price](https://daily.dev/posts/anthropic-quietly-nerfed-claude-code-s-1-hour-cache-and-your-token-budget-is-paying-the-price-1jobhvzkb) · XDA Developers · 1 upvotes · 0 comments
- [Claude API Token Optimization](https://daily.dev/posts/claude-api-token-optimization-4sbqfmbsk) · SitePoint · 0 upvotes · 0 comments

---

Tags: [#ai-agents](https://daily.dev/tags/ai-agents), [#ai-inference](https://daily.dev/tags/ai-inference), [#claude-code](https://daily.dev/tags/claude-code), [#finops](https://daily.dev/tags/finops), [#python](https://daily.dev/tags/python)

[View this post on daily.dev](https://daily.dev/posts/github---izeigerman-claude-thermos-keeps-your-claude-session-warm-for-you-43gblyspt)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"GitHub - izeigerman/claude-thermos: Keeps your Claude session warm for you","url":"https://daily.dev/posts/github---izeigerman-claude-thermos-keeps-your-claude-session-warm-for-you-43gblyspt","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/github---izeigerman-claude-thermos-keeps-your-claude-session-warm-for-you-43gblyspt"},"datePublished":"2026-07-23T18:56:38.044Z","dateModified":"2026-10-14T02:35:50.508Z","description":"claude-thermos is an open-source tool that prevents Claude Code's prompt cache from expiring during long multi-agent sessions. When a main agent is blocked...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/d0e2ad9a5e8dbef04a472f5d73205053?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/d0e2ad9a5e8dbef04a472f5d73205053?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Hacker News","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Hacker News","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/hn","url":"https://daily.dev/sources/hn"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/github---izeigerman-claude-thermos-keeps-your-claude-session-warm-for-you-43gblyspt","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"ai-agents,ai-inference,claude-code,finops,python","timeRequired":"PT5M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Hacker News","item":"https://daily.dev/sources/hn"},{"@type":"ListItem","position":3,"name":"GitHub - izeigerman/claude-thermos: Keeps your Claude session warm for you"}]}
```

