A telecom support bot on a self-hosted vLLM server sends a 3,000-token system prompt plus the growing chat history on every turn. After you enable automatic prefix caching, which outcome should you expect?
Show the answer and explanation
Correct answer: C, Lower TTFT and less prefill compute on turns that share a cached prefix, the same decode work per output token, and fewer hits whenever memory pressure evicts the cached blocks.
Explanation Caching
Automatic prefix caching (vLLM; SGLang's RadixAttention is the same idea organized as a radix tree) keeps the KV blocks of earlier requests after they finish. A new request whose token sequence starts with the same blocks reuses them, so only the new suffix needs prefill.
For this bot every turn begins with the same 3,000-token system prompt and then the previous turns, so turn n can reuse almost everything except the newest user message:
| Metric | Effect |
|---|---|
| TTFT | lower: only uncached tokens are prefilled |
| Prefill GPU compute | lower, which frees capacity for other requests |
| Decode work per token | unchanged: each new token still attends over the full context |
| Output | same as without caching (up to floating-point noise) |
Measured TPOT can still dip slightly under heavy load, but only indirectly: less prefill work competes with decoding for GPU time.
Cached blocks are not pinned: they live in the same pool as active sequences, and when memory is needed, unused cached blocks are evicted (typically least recently used). Under heavy load, or when a chat pauses long enough for other traffic to evict its blocks, hit rates fall.
Why the distractors fail: decode still reads the whole KV cache, cached or not, so caching does not make a decode step cheaper. The full prompt is still sent, but sending tokens is cheap; prefilling them is what costs time, which is why TTFT drops. Prefix caching stores KV states, not responses, and the model still generates every answer (a response cache is a different, application-level component). Nothing is reserved or guaranteed.
Interview tip: describe it as "skip prefill for repeated prefixes" and add the two conditions for hits: an identical token prefix from the first token, and the request reaching the replica that still holds those blocks.