Model and Inference EngineeringEnd-to-end serving and modalitiesStaff
What does aggregate token throughput reveal about an inference service’s user-visible performance?
By Amit Kumar3 min readWorked answer includedReviewed 26 Sept 2026
The question
Interview question
An inference benchmark reports high aggregate output tokens per second, but only 60 percent of production requests meet both first-token and streaming latency targets. Explain how these results can coexist and design a workload-representative benchmark. Then assess what happens when average output length doubles while the request arrival rate stays constant.
Draft your approach first
Take a few minutes before you read the answer. Name the constraint that matters most, the failure you are designing for and how you would know it worked.
Reveal the worked answerWorked answer
Throughput measures completed work per unit time. Latency measures how long a particular request waits. An engine can produce many tokens in a large batch while an individual user waits too long to join that batch or sees long pauses between updates. Time to first token, often abbreviated TTFT, measures waiting until output starts. A service-level objective, or SLO, states the latency or success target the product is expected to meet.
Ask which tokens the benchmark counts. Input prompt tokens and generated tokens involve different work. A saturated aggregate output rate does not describe the distribution of per-request waiting or streaming gaps. Uniform prompt lengths, warm prefixes and omission of failed or cancelled requests can make a benchmark easier than production.
Prefill processes the prompt into attention states before output starts. Decode repeatedly produces the next token using a key-value, or KV, cache of those states. Preempting a live sequence can pause it and require rebuilding its evicted state, so a high average token rate can coexist with long waits.
For a request, separate arrival to admission, queue, prefill, first token, each subsequent token, and completion. Time to first token includes waiting and prefill, not just GPU execution. A reported time per output token is often averaged over a request, while a user sees individual inter-token gaps. vLLM's metrics design distinguishes a gap between streamed events from a per request average over the whole output. They are not interchangeable, especially when one event bundles multiple tokens or a request pauses and catches up later.
The product success metric should count requests that meet both latency conditions and produce an acceptable result. Call that SLO goodput if the denominator and quality check are explicit. The DistServe paper uses TTFT and per output token targets to discuss goodput, but our success definition also needs errors, cancellations, and task quality. A raw token rate can be high when a small set of long batch jobs dominates the output, while short interactive requests miss their first token deadline. Break the data out by prompt size, output length, tenant, model, cache hit, and traffic class.
I would rerun the benchmark with the production arrival pattern, realistic length distributions and stopping rules, multiple concurrency levels, and a warmup that does not hide cold capacity if cold starts occur in production. Report completed good requests per second and per GPU hour under the stated p95 or p99 requirements, along with aggregate input and output tokens, queue age, KV occupancy, preemptions, and cost. Identify whether the 40 percent failures were late to first token, slow between tokens, errors, or low quality. Those have different fixes.
Now outputs double at the same arrival rate. Even if prompt work stays constant, live sequences last longer, generate more tokens, and hold KV longer. As a simplified illustration, 100 requests per second averaging 1,000 output tokens require 100,000 output tokens per second. At 2,000 tokens they require 200,000. If the pool could deliver 120,000 tokens per second at the required latency for the old mix, the new demand is above that simplified capacity and queue debt grows. Real token capacity is not a fixed scalar because sequence length and batch shape change execution, so measure the new mix. The arithmetic is enough to reject “QPS stayed flat” as an argument that supply is adequate.
The immediate response might be tighter output budgets, a different model route for tasks where quality permits it, extra warm replicas, or admission that tells callers to retry later. A queue with no bounded age makes the apparent throughput look good while new requests wait beyond usefulness. If a team proposes larger batches to recover token rate, check whether that moves the first token tail or per token stalls in the wrong direction. The answer is not one optimized number. It is a workload and a latency contract that the fleet can actually meet.
Related questions
Keep practising model and inference engineering
Follow another question in this area, or search the complete library.
Get my essays on AI engineering and distributed systems by email. Subscribe to ArchCrux