Zenaique

Match each LLM latency metric to what it actually measures

Match pairs·Medium·4.0 · 0·~2 min·Asked atHclSynthesiaTypeface
Attempt it

Drag each answer to line up with its matching prompt

TTFT (time to first token)

Delay from request to the first streamed token; driven by queue wait + prefill

TPOT (time per output token)

The tail: 99% of requests finish at or under this time

End to end latency

Total time to the complete response; ≈ TTFT + TPOT × output tokens

p99 latency

Aggregate token generation rate across all concurrent requests

Throughput (tokens/sec)

Average gap between successive streamed tokens; sets streaming speed

TL;DR

TTFT is the wait for the first token (queue + prefill), TPOT is the per-token streaming gap, and end to end ≈ TTFT + TPOT × output length.

Memory aid
Sign in to see the mnemonic that makes this stick.
Easy to grasp

Imagine ordering food at a counter. There's the wait until your first plate arrives, and then how quickly each following plate comes out. Those are two separate experiences. LLM latency works the same way. TTFT is how long until the first word shows up. TPOT is how fast the rest of the words keep coming after that. The total time you wait is the first-word wait plus the per-word pace times how many words there are — and the kitchen's overall output across all customers is throughput.

Concept explanation~2 min read

Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.

Latency for an LLM is not one number, and the candidates who treat it as one get caught the moment an interviewer asks "fast by which measure?" A streamed completion is a process that unfolds over hundreds of tokens, so a single round-trip figure throws away exactly the information you need to debug or to write an SLA.

The useful framing is two axes. First, per-request versus fleet-aggregate: some metrics describe what one user feels, others describe what the system can sustain. Second, central tendency versus tail: an average and a p99 can tell wildly different stories about the same service.

This walkthrough places each of the five metrics on those axes, derives how end to end latency composes from its parts, explains why the tail deserves its own number, and then closes on the trade that makes all of this matter — throughput and latency pulling against each other, so that no single scalar can be the target.

Per-request startup: TTFT

TTFT, time to first token, is the delay from when a request arrives to when the first token streams back. It is the metric a user experiences as raw responsiveness — the gap between hitting enter and seeing anything happen.

What drives it is queue wait plus prefill. The request first sits in the scheduler's queue until the serving loop can admit it, then the model runs a prefill pass over the entire prompt before it can emit token one. So TTFT grows with how loaded the system is and with how long the prompt is, but it is independent of how long the eventual answer will be.

This independence is the point of streaming. Without streaming, the user waits the full end to end time before seeing a single character. With streaming, they wait only TTFT — often a few hundred milliseconds — and then text flows. A serving team obsesses over TTFT because it is the first impression, and because prompt caching, smarter queueing, and prefill optimization all move it directly without touching the rest of the pipeline.

Per-request streaming pace: TPOT and end to end
The tail: why p99 earns its own number
The aggregate axis and the trade that links them
Sign in to unlock the full deep dive.

Situations where this technique stops working.

Sign in to see when this approach fails.

2–4 min · Everything important, quickly.

Sign in to see the quick scan of the deep dive.
MetricScopeDriven by
TTFTPer request, startupQueue wait + prefill
TPOTPer request, streamingDecode rate per token
End to endPer request, totalTTFT + TPOT × output tokens
p99 latencyPer request, tailDistribution of end to end times
ThroughputFleet aggregateConcurrent tokens/sec across all requests

Real products, models, and research that use this idea.

  • OpenAI and Anthropic publish or target TTFT and inter-token latency for their streaming chat APIs.
  • vLLM and TGI benchmark suites report TTFT, TPOT, and aggregate throughput side by side.
Sign in to see more production examples.

What an interviewer would ask next. Try answering before peeking at the approach.

QWhy can raising throughput via batching worsen TTFT and p99?
A

Tie larger batches to added scheduling and queue delay that lengthen startup and the tail even as tokens/sec rises.

2 more follow-ups an interviewer would ask next. Sign in to reveal them.

Red flags & common mistakes

The phrases that signal junior thinking. Click to expand.

Most common mistake

Conflating per-request latency with throughput, or assuming a high tokens/sec number means low latency — the two can move in opposite directions.

Sign in to see all red flags and common mistakes.

60 second bullets to scan on the way to the call.

  • Definition of TTFT and what dominates it

  • Definition of TPOT and which phase sets it

Sign in to unlock the revision sheet.

Primary sources. Browse if you want the original framing.

Similar questions

Same topic, related formats. Practice these next.

4 curated
Next question
In LLM serving, what is the primary driver of end to end latency for a generation request?
MCQ·Medium