[Frontend] add per-request timing metrics field to response body of Chat/Completions APIs (#46768)

Signed-off-by: Nicholas Edelman <nedelman@nvidia.com>
Signed-off-by: Simon Mo <simon@inferact.ai>
Co-authored-by: Simon Mo <simon@inferact.ai>
Co-authored-by: GPT-5.5 <noreply@cursor.com>
This commit is contained in:
nv-nedelman-1
2026-07-06 17:48:29 -07:00
committed by GitHub
co-authored by Simon Mo GPT-5.5
parent 5769a7382c
commit 86db6c3070
12 changed files with 565 additions and 4 deletions
@@ -206,6 +206,14 @@ def test_chat_template_validation_for_sad_paths(serve_parser):
validate_parsed_serve_args(args)
def test_per_request_metrics_requires_log_stats(serve_parser):
args = serve_parser.parse_args(
args=["--enable-per-request-metrics", "--disable-log-stats"]
)
with pytest.raises(ValueError):
validate_parsed_serve_args(args)
@pytest.mark.parametrize(
"cli_args, expected_middleware",
[