[Frontend][Core][Spec Decode] Per-request acceptance stats in OpenAI API responses (#48915)
Signed-off-by: Matthew Kotila <7692737+matthewkotila@users.noreply.github.com> Co-authored-by: Reed Meyerson <31574681+reed-meyerson@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Reed Meyerson
Claude Opus 4.8
parent
2f41c894e3
commit
7cfb97e337
@@ -45,6 +45,18 @@ class ObservabilityConfig:
|
||||
Note that collecting detailed timing information for each request can be
|
||||
expensive."""
|
||||
|
||||
per_request_spec_decode_metrics: Literal["none", "summary", "detailed"] = "none"
|
||||
"""Include per-request speculative-decoding acceptance metrics in the
|
||||
response under `metrics.speculative_decoding`. `none` disables; `summary` adds mean
|
||||
acceptance length, draft acceptance rate, and the step-by-draft-length
|
||||
histogram; `detailed` additionally records the ordered per-step
|
||||
accepted/proposed arrays (one entry per verify step). Only reported for
|
||||
single-sequence requests (`n == 1`), mirroring the timing metrics. No effect
|
||||
unless speculative decoding is enabled. Independent of `--disable-log-stats`.
|
||||
This is the per-request response-body counterpart of the aggregate
|
||||
`vllm:spec_decode_*` Prometheus metrics. The response field is experimental
|
||||
and its shape may change in a future release."""
|
||||
|
||||
kv_cache_metrics: bool = False
|
||||
"""Enable KV cache residency metrics (lifetime, idle time, reuse gaps).
|
||||
Uses sampling to minimize overhead.
|
||||
|
||||
Reference in New Issue
Block a user