Inference, Serving & Production·Question 54 of 76Advanced

After a routine deploy, P99 TTFT went from ~600 ms to ~4 s. Throughput, error rate, GPU utilization and the model version are all unchanged. Debug it.

Type it the way you would explain it to an interviewer. A few sentences is enough; you can't break anything.

Model answer: the part to lead with

Roll back first, debug second: a 4 s P99 TTFT is a user-visible incident, and the deploy is the obvious suspect.

Full worked answer with diagram

Roll back first, debug second: a 4 s P99 TTFT is a user-visible incident, and the deploy is the obvious suspect.

Then the decomposition. TTFT = queue wait + prefill. Unchanged throughput with worse TTFT means we are not simply overloaded: either each request is prefilling more tokens, or the scheduler is admitting them later. So the first thing I want is those two components instrumented separately, because that single number bisects the whole search space.

If queue time grew, it is scheduling and admission. Candidates: max_num_seqs or the batched-token budget changed; chunked prefill got disabled or its threshold moved, so one long prefill now stalls the queue; preemption rate is up because of KV pressure, so requests are evicted and re-queued; replica count dropped via an autoscaler config change or a rollout still draining; a new priority or routing rule.

If prefill time grew, we are prefilling more tokens, and the prime suspect is the prefix cache hit rate collapsing. Check hit rate measured in tokens. If it went from ~80% to near zero, someone put something volatile at the front of the prompt: a timestamp, a request id, a user name, a reshuffled tool list, a reordered RAG block. Everything after the change point is a miss. Same symptom from a routing change that lost cache affinity, an adapter or quantization bump (cache keys include them), or simply a rolling restart that reset every cache, and that one recovers, so check whether the graph is flat or climbing back.

Other prefill growers: a longer prompt template, RAG returning more chunks, a chat-template or tokenizer change, or a new tenant sending 100K-token prompts into the shared queue.

Why "GPU utilization unchanged" proves nothing: utilization counts busy SMs, and both a bandwidth-starved decode and a compute-bound prefill read as busy.

Method: diff the deploy including config and prompt templates, not just model code; break P99 down by tenant, route and prompt-length bucket, since an aggregate regression is usually one segment; replay yesterday's traffic against both configs.

The tempting wrong move is adding replicas. That hides a cache regression at several times the cost.

Worth sketching. Drawing the bisect first shows you debug by splitting the metric, not by guessing causes in a list.

flowchart TD
    T["P99 TTFT: 600 ms to 4 s"] --> RB["Roll back, then debug"]
    RB --> S["Split TTFT into queue wait<br/>versus prefill time"]
    S -->|"queue grew"| Q["Scheduling: token budget, chunked prefill off,<br/>preemptions, replica count, routing rule"]
    S -->|"prefill grew"| P["Check prefix cache hit rate, measured in tokens"]
    P -->|"collapsed"| V["Volatile bytes at the front, lost cache affinity,<br/>adapter or quantization bump"]
    P -->|"steady"| L["More tokens: template change, more RAG chunks,<br/>a new long-prompt tenant"]

What a good answer covers

  • Roll back first, debug second
  • Unchanged throughput with worse TTFT means we are not simply overloaded
  • So the first thing I want is those two components instrumented separately, because that single number…
  • If queue time grew, it is scheduling and admission
  • If prefill time grew, we are prefilling more tokens, and the prime suspect is the prefix cache hit rate…

Key terms: If queue time grew · If prefill time grew · Method

Interviewer follow-ups to expect

  1. How would you alert on prefix cache hit rate without paging on every deploy?

  2. What deploy-time check would catch a prompt-prefix change before it ships?

Worked answer from AI-Engineer-Interview-Questions by Om (MIT), reformatted for LLM Prep · answer text last updated 6 November 2026 · scoring and review schedule by LLM Prep