Agent turn 30 should not recompute turn 1's system prompt. Yet that is what happens when every vLLM replica keeps its own KV cache and your router sends the next tool result to a cold pod.
LMCache is the open-source layer Alpha Signal flagged for 10x-class inference wins. It is not a new foundation model. It is infrastructure that treats KV cache like reusable data, not disposable GPU state.
LMCache paper (arXiv:2510.09665)The problem in one agent trace
I wrote about a similar pain in vLLM + Mooncake for distributed KV: coding agents drag huge prefixes turn after turn. vLLM's own Mooncake blog cited median ~33 turns and context near 80K tokens by turn 30 on SWE-style traces, with input:output ratios around 131:1.
Most of each request is prefix you already paid to prefill.
| Symptom | Root cause |
|---|---|
| TTFT spikes on later agent turns | Prefix recomputed on a new replica |
| GPU memory full | KV evicted locally, no shared pool |
| Linear cost scaling | Every pod repeats the same prefill work |
Single-instance prefix caching helps one process. Production agents hit many replicas. That gap is where LMCache lives.

What LMCache actually does
LMCache sits beside inference engines (vLLM, SGLang, and others) as a KV cache connector:
- Extract KV blocks from GPU memory after prefill.
- Store them in tiered backends: CPU DRAM, local SSD, Redis, S3, RDMA paths.
- Lookup hashed prefixes on later requests, even on different engine instances.
- Orchestrate with control APIs: pin, cleanup, move, compress.
The project describes the shift as turning cache from temporary state into AI-native knowledge you can monitor and reuse. Marketing words aside, the engineering is offload + share.
LMCache is vendor-neutral Apache 2.0. That matters if you want to swap serving engines without throwing away cached prefixes.
LMCache on GitHubReported numbers (and how to read them)
The research paper and ecosystem blogs cite wide ranges because hit rate is everything:
| Metric | Reported range | Workload notes |
|---|---|---|
| Throughput | Up to 15x vs baseline vLLM | Multi-round QA, document analysis |
| TTFT | 3–10x reduction | Long shared prefixes, cross-instance hits |
| Cache capacity | 100x more KV vs single GPU | Tiered CPU / disk / remote backends |
Those are not guaranteed SaaS SLAs. They are what teams see when prefixes repeat and backends are wired correctly.
If your prompts change every turn, LMCache will not save you. If your agent constitution is stable and tool output appends at the end, LMCache can feel like free money.

LMCache vs Mooncake (both are in my stack notes)
This repo already has a Mooncake Store + vLLM post. They overlap in goal, differ in origin:
| Layer | Focus |
|---|---|
| Mooncake Store | Deep vLLM integration, RDMA-heavy clusters, agent traces with vLLM's connector story |
| LMCache | Vendor-neutral connector, broad engine support, enterprise tiered storage story |
You might run one or both depending on cloud, RDMA, and engine choice. The shared lesson: agent serving is a distributed systems problem.
When I recommend LMCache to clients
LMCache rises to the top of the checklist when:
- Multi-turn agents (coding, support, ops) with stable system prompts.
- Multiple vLLM replicas behind a naive load balancer.
- RAG with repeated document prefixes across users.
- Cost pressure on prefill-heavy models (long context + tools).
Skip it (for now) when:
- Traffic is mostly single-turn chat.
- Prompts are unique every request.
- You have not fixed prompt stability yet (cache-unfriendly edits).
Prompt habits that make cache hit rates jump
Same table I give after Mooncake reviews:
| Habit | Effect |
|---|---|
| Byte-stable system prompt and tool schemas | Higher prefix hash match rate |
| Append volatile tool output at end | Avoid invalidating entire prefix |
| Pin hot documents with LMCache control APIs | Repeat RAG corpora stay warm |
| Namespace caches per tenant | Prevent cross-customer leakage |
Security note: shared KV pools need tenant isolation in multi-tenant products. LMCache exposes orchestration hooks; your app still owns auth boundaries.
Where to start reading
- LMCache documentation
- LMCache project site
- Paper: arXiv:2510.09665
- Related: vLLM prefix caching docs
# Pseudocode: your engine-specific flags differ; read LMCache docs for vLLM/SGLang export LMCACHE_CONFIG_PATH=lmcache_config.yaml vllm serve your-model \ --kv-transfer-config '{"kv_connector":"LMCacheConnector", ...}'
Treat the snippet as orientation, not copy-paste config. Connectors evolve quickly.
Bottom line for applied AI teams
LMCache will not fix a bad agent design. It will punish teams that already run long-horizon agents on multiple vLLM pods without shared KV.
Alpha Signal's digest framed it as a 10x inference story. The honest version: 10x when your prefixes repeat and your backends match your traffic. That condition is true for more production agents every month.
If you want help profiling prefix hit rates on your agent traces before you add LMCache or Mooncake, book a free discovery call.

