Skip to content

Time to First Token

Delay between sending a request and the appearance of the first token in the response. This is what the user perceives as the model 'thinking'.

Why It Is a Separate Metric

Response generation consists of two phases:

  1. Prefill — the model reads the entire input prompt and calculates KV-cache;
  2. Decode — step-by-step token generation.

TTFT is primarily the first phase. The longer the input and the larger the model, the longer the prefill phase.

Factors Affecting TTFT

  • length of the input context;
  • size of the model and its quantization;
  • server load and request queue.

Relation to Other Metrics

Together with token generation speed, TTFT forms the overall inference latency. For dialogue systems, TTFT is critical: users do not like waiting for the first response.

See Also

← All Terms