Inference and Serving, lesson 21
Designing a fair benchmark
Warm-up, fixed inputs, enough runs, and one change at a time.
You know TTFT, percentiles and goodput from "First token and every token after", "Percentiles and the slow tail" and "Goodput under errors and timeouts".
Part 1. The first requests lie
You start a fresh server and send 10 requests one after another. TTFT in milliseconds: 2,400, 610, 190, 185, 192, 188, 183, 191, 187, 186.
Your turn
What's the mean TTFT of those 10 requests, and is it a fair number for this server?
The first requests to a fresh server pay for things that happen once: loading weights into GPU memory, compiling and tuning kernels for the shapes it sees, capturing CUDA graphs, filling the prefix cache. Real users mostly meet a server that's been running for a while.
Warm-up
Requests you send and then throw away before measuring, so one-off start-up costs don't land in your numbers. Send enough to cover the prompt lengths and batch sizes you'll test. Measure cold start separately, if it matters to you, and label it.
Part 2. One run proves little
Keep going with Pro
You've done the first part. Pro opens the rest of this lesson, and every other one.
- One run proves little
- Change one thing
- Send traffic the way users do
Inference and Serving overviewSpotted a mistake? Tell us.