Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By alexandernicholsonv0.4.9MITIn 1 marketplace
A prompt cache bar for every conversation, subagent and teammate, a dashboard with /keepalive, per-conversation cache TTLs, and upkeep that keeps an idle cache warm or compacts it before it expires. Requires Claude Code Mod function hooks enabled.
Trending plugins
7-day copy clicks
Code that runs inside Claude Code on every session, as you, unsandboxed.
Claude Code asks for these when you enable the plugin. Sensitive values are stored in your system keychain.
Prompt cache TTLcache_ttl
Prompt cache lifetime the main conversation starts in. Default keeps Claude Code's own choice; the cache bar's TTL button changes it for the session.
One of default, 5m
1 critical to review before installing
JavaScript or TypeScript that runs inside Claude Code as you, unsandboxed. Read from its source, it runs programs; makes network requests; reads environment variables (ANTHROPIC_API_KEY, ANTHROPIC_AUTH_TOKEN, ANTHROPIC_BASE_URL, CLAUDE_CODE_PROMPT_CACHE_TTL, CLAUDE_CODE_SUBAGENT_PROMPT_CACHE_TTL, CLAUDE_CODE_USE_BEDROCK, COLORFGBG, DISABLE_PROMPT_CACHING, DISABLE_PROMPT_CACHING_HAIKU, DISABLE_PROMPT_CACHING_OPUS, DISABLE_PROMPT_CACHING_SONNET, ENABLE_PROMPT_CACHING_1H, ENABLE_PROMPT_CACHING_1H_BEDROCK, FORCE_PROMPT_CACHING_5M); sets environment variables; reads your settings; changes your /config settings; calls a model on your account.
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
1hstringOptionaldefault default
Cache upkeepcache_upkeep
Prompt cache upkeep the main conversation starts in. The mode button on the cache bar changes it for the session.
One of off, warm, compact, warmcomp
stringOptionaldefault off
Reduced motionreduced_motion
on changes the cache bar's and dashboard's countdowns once a minute, in whole minutes, and shows soon in the last minute. off counts down every second.
One of off, on
stringOptionaldefault off
TTL for models that don't report oneunreported_ttl
Cache lifetime Keepalive assumes for models whose provider reports none and whose gateway publishes none, so warm, compact and warmcomp can work on them. off keeps them monitor-only. Never applies to Claude.
One of off, 5m, 15m, 30m, 45m, 1h
stringOptionaldefault off
Keepalive limitkeepalive_limit
Keepalives warm and warmcomp send after each request before warming stops; warmcomp then compacts. default sends them while each costs less than rewriting the cache, infinite never stops, and a number sends exactly that many. Split-pane teammates use it unless their own limit is set.
stringOptionaldefault default
Compaction thresholdcompact_threshold
The smallest conversation compact and warmcomp compact, in tokens, such as 100k or 80000. A smaller conversation is left to expire.
stringOptionaldefault 100k
Subagent prompt cache TTLsubagent_cache_ttl
Prompt cache lifetime each subagent starts in. Default keeps Claude Code's own choice; each subagent's TTL button changes it for that subagent.
One of default, 5m, 1h
stringOptionaldefault default
Teammate prompt cache TTLteammate_cache_ttl
Prompt cache lifetime each teammate starts in. Default keeps Claude Code's own choice; each teammate's TTL button changes it for that teammate.
One of default, 5m, 1h
stringOptionaldefault default
Price feed URLkeepalive_price_url
A JSON price list for models Anthropic and models.dev don't price: {"version":1,"models":{"alias":{"input":1,"read":0.1,"write":1.25,"output":5}}}. Relative units are fine. Empty uses your gateway's /v1/cache/prices when it has one; off disables the feed.
stringOptionaldefault
Teammate cache upkeepteammate_cache_upkeep
Prompt cache upkeep that split-pane teammates start in. Each teammate's own mode button can change it. In-process teammates and subagents cannot be kept warm.
One of off, warm, compact, warmcomp
stringOptionaldefault off
TTL for specific modelsunreported_ttl_models
Per-model overrides of that TTL, such as kimi*=15m, glm-5.3=off. The first match wins; * matches any text.
stringOptionaldefault
Teammate keepalive limitteammate_keepalive_limit
Keepalive limit for split-pane teammates. same uses the keepalive limit; default, infinite or a number work as they do there.
stringOptionaldefault same
Public GitHub repos that commit this plugin as enabled in their Claude Code settings
Keepalive is a Claude Code Mod that shows how well every conversation reuses its prompt cache, and can keep an idle cache from expiring. It works on its own, and with Agent Router when both are installed.
/keepalive: the session's hit rate now and overall, one dot per request, every agent as a tree, and the request history with the time between requests.CLAUDE_CODE_ENABLE_FUNCTION_HOOKS=1).PATH.Any endpoint works: a Claude subscription, an API key or an Anthropic-compatible gateway.
Step-by-step guide with settings and troubleshooting: INSTALL.md.
/plugin marketplace add alexandernicholson/agent-router
/plugin install keepalive@agent-router-tools
Run /keepalive-settings to choose the TTL each kind of conversation starts in, the upkeep the main conversation and split-pane teammates start in, the keepalive limits, the compaction threshold, and reduced motion. Each setting has its own row; a setting that also takes a typed value, such as an exact keepalive limit, has a boxed field at the end of its row, and Enter saves what you type.
Keepalive reads the routes Agent Router publishes for each session, so with both installed:
Each plugin works without the other. Keepalive finds split-pane teammates by itself, from their launch flags, so a lead links its teammates even without Agent Router.
The cache bar, /agent-cache and the cache settings were part of Agent Router up to 0.16.2. On its first run Keepalive copies the cache history Agent Router recorded, and it keeps using the cache settings you saved in Agent Router until you change them in /keepalive-settings.
The cache bar above the prompt follows the conversation in view: the main conversation, or the subagent or teammate whose transcript you are viewing.
[ ◕ ] ⬦ off TTL 5m ██████████ 96% ✕ 2 prefix · ETA ~3:44 · read 148.1k · write 5.7k · new 2
It shows the conversation's cache TTL, its cache hit rate over its last 10 requests, any recent cache misses, the time left before the entry expires, and the last request's tokens read, written, and sent uncached. When a response reports a different TTL than the conversation asked for, the bar adds it, as · 5m reported. A ⬆ after the dial means a newer Keepalive is available; press it for the update commands (see Updates).
The hit rate adds up the read, written and uncached tokens of the conversation's last 10 real requests, so one miss shows without one request hiding the rest. Keepalives and compactions are left out. Right after a compaction the bar shows the compaction's own hit rate.
A cache miss leaves a short chip after the hit rate: ✕, the number of misses in the last 15 minutes, and their most common causes in a word each (prefix, expired, model, TTL, or unknown). On the main conversation it counts misses across every agent in the session; on a subagent's or teammate's bar, only theirs. It is yellow for five minutes after the latest miss, then dims, and goes away once the last miss is 15 minutes old. It sends no notification and takes no keyboard focus. Click it to open the dashboard filtered to misses, where a line spells them out:
✕ 2 cache misses in the last 15 min: 1 expired, 1 prefix changed · latest 6:25 ago
The dial button shows the time left in quarters of the TTL: ● for a cache just read or written, then ◕, ◑, ◔, and ○ once it has expired. It refills when a request is dispatched, and shows ◌ while there is no reported TTL to count down. Click the dial, or run /keepalive (/agent-cache still works), to open the dashboard. The first time the bar appears, Keepalive adds a short guide to it in the transcript, once per user; the guide is shown to you only and is never sent to the model.
The dashboard opens with the whole session at a glance:
7-day copy clicks
npx claudepluginhub alexandernicholson/agent-router --plugin keepaliveBuilt from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.
Plugins from other owners that cover similar ground