vllm:prompt_tokens
Counter for the number of prefill tokens processed.
Summary
In vLLM v0.23.0, under V1 metrics published by PrometheusStatLogger, vllm:prompt_tokens counts prefill tokens processed across iterations. In that same version and V1 PrometheusStatLogger context, the metric is registered as a Prometheus counter. It is registered with the label names model_name and engine. At runtime in v0.23.0, the counter increments from IterationStats.num_prompt_tokens during iteration logging. Interpretively, in v0.23.0 it represents aggregate prefill work and does not by itself distinguish cached prompt tokens from newly computed ones. Accordingly, in v0.23.0 use rate over this counter for prompt throughput, and pair it with cached/computed-token and queue/TTFT metrics before drawing efficiency conclusions.
Version history
- In the only version covered here,
v0.23.0,vllm:prompt_tokensis registered as a Prometheus counter carrying the label namesmodel_nameandengineundertheV1PrometheusStatLoggerpublisher. - In
v0.23.0it counts prefill tokens processed across iterations, incrementing fromIterationStats.num_prompt_tokensduring iteration logging. - In
v0.23.0it reflects aggregate prefill work without distinguishing cached from newly computed prompt tokens, so it should be read as a rate for prompt throughput and paired with cached/computed-token and queue/TTFT metrics before drawing efficiency conclusions.
Identity
- Prometheus type
- counter
- Labels
- model_nameengine
- Unit
- Not recorded — vLLM registration code has no structured unit field, and units are not inferred from name suffixes
Semantic coverage
Metric knowledge (6)
| Claim | Semantic layer | Verified |
|---|---|---|
In vLLM v0.23.0, vllm:prompt_tokens counts prefill tokens processed across iterations. | Measurement semantics | Sep 29 |
In vLLM v0.23.0, vllm:prompt_tokens increments from IterationStats.num_prompt_tokens during iteration logging. | Causal/runtime semantics | Sep 29 |
In vLLM v0.23.0, vllm:prompt_tokens is aggregate prefill work and does not by itself distinguish cached from newly computed prompt tokens. | Interpretation & composition | Sep 29 |
In vLLM v0.23.0, vllm:prompt_tokens use rate for prompt throughput and pair it with cached/computed-token and queue/TTFT metrics before drawing efficiency conclusions. | Guarded guidance | Sep 29 |
In vLLM v0.23.0, vllm:prompt_tokens is registered as a Prometheus counter. | Structural identity | Sep 29 |
In vLLM v0.23.0, vllm:prompt_tokens is registered with the label names model_name, engine. | Structural identity | Sep 29 |
Related Use Cases (1)
Availability
vllm:prompt_tokens is registered as a Prometheus counter in vLLM v0.23.0.