Amendments to the report on PR #560 — "Emit vLLM-compatible per-request metrics from runtime instants"
Per the request, only amendments and the corrections they force. The baseline report is scratchpad entry #30 (prior run); entries #31–#38 are the new material. Everything below is verified against head e3829e62 (metrics/per-request-speeds → main, open, no longer draft, labels area:api, enhancement, triage:review).
Key findings (amendments)
- The sole blocker from the 05:42 review is fixed at head — retract the blocker. Ignition's
[server]allowlist now carries"per_request_metrics": bool(ignition/cli/config.py:24), a built-inFalsedefault (:41), and a commented sample line inside[server]inwrite_initial(:194, writer at:184-205);ignition debug-serveforwards it (ignition/cli/serve.py:488) and Helios parses it as a strict bool (helios/src/server/config.rs:353-357(not opened)). Tests:tests/cli/test_config.py:162-163(rejects1and"true"),:182-188(default/true/false with source tag). The previous "the documented sample breaks every Ignition command" finding is resolved, not outstanding. - The 06:19 flare-autobot comment is not a new review — it re-posts 05:42 verbatim. Same counts ("Blockers: 1 · Should fix: 6 · Subtractive suggestions: 6 · Nits: 5"), same verdict sentence; only the Full Review / Value Proposition URLs differ (
1cb8da22 · f6a70428vs05bfd7d9 · c7afd3c8). The fix commits landed before 06:19, so both auto-reviews describe the pre-fix tree, and no review of head e3829e62 exists. Replace "05:42 is the latest review" with: latest review text is 06:19, a duplicate of 05:42. - A maintainer is now active in this cluster, and his conditions do not appear in #560. Luke Alonso (project owner per
docs/design-review.md, which requires his explicit approval) reviewed #548 at 2026-11-28 18:37 and #549 at 18:32 with blocking items; he has not commented on #560. Critical for #560: he made two demands that #560's evidence and code fail — see amendment A4 below. This supersedes my standing line "no human maintainer has ever commented in this cluster." - Stack is now two layers, not three: #548 → #560. #562 was closed 2026-11-28 23:06 while draft ("Closing to keep the metrics work to three PRs (#549, #548, #560)… The streaming content-instant implementation stays on branch
WynnD:metrics/content-ttft").time_to_first_content_token_msis therefore permanentlyValue::Nullin this PR (helios/src/server/protocol/encode.rs:262) with no open PR owning it, and the gateway-facing gaps can no longer be deferred to a follow-up. - Issue #551's own text asks for things #560 contradicts. #551 (WynnD, 2026-11-27 03:26, 0 comments) specifies Responses placement "beside
responserather than inside it", Messages coverage onmessage_delta, anddraft_n/draft_n_accepted/cache_n/prompt_ncounts. #560 nests the object insideresponse(encode.rs:732-745), excludes Messages (:238), and carries no draft counts — soCloses #551is overstated on three counts, the same shape as theCloses #536 → Part of #536correction Luke Alonso demanded of #548.
A1 — Process / Autobot comments (replaces the blocker block of entry #30)
Latest review text: 2026-11-28 06:19, flare-autobot, Changes Requested, 1/6/6/5 — a duplicate of the 05:42 review (https://autobot.eidonix.com/p/05bfd7d9-595d-43d9-8bf7-6d5308421b5d.html and .../1cb8da22-85ab-44e1-bf29-1fa0f54a5c61.html; case file unchanged since 02:18, https://autobot.eidonix.com/api/v1/cases/0eee5683-497b-4172-bbaf-67ed18107a5b.html). The mechanism ("worker owns the instants, encoder owns placement, nothing emitted when off") is called right-sized and correct for a third consecutive round. No author reply to either review; no human maintainer comment on #560. Scale moved from +1757/−77 in 22 files to +2000/−161 in 25 files, adding ignition/cli/config.py, ignition/cli/serve.py, tests/cli/test_config.py. CI status is not observable with my tools, so I cannot confirm the Helios lifecycle workflow ran on this head; the author's Evidence lists only cargo check, --lib tests and live runs.
A2 — Residual gaps around the ignition fix (should-fix scale, not blockers)
- The generated template line is untested.
grep per_request_metrics tests/returns onlytests/cli/test_config.py:162-188; nothing pins that the sample atignition/cli/config.py:194sits inside[server], i.e. that uncommenting it yields a valid file — the exact artifact whose absence broke ignition before. - The two readers of the shared config file still disagree. Ignition hard-errors on an unknown
[server]key (ignition/cli/config.py:21-33allowlist), while flare has nodeny_unknown_fields(flare/src/configuration.rs:26-35; comparePrefixCacheat:50-57), so flare silently ignores a typo that ignition rejects. Unchanged by this event. - Correction to my earlier A3.2 (no ignition serving gap).
ignition exportdeliberately does not bake the key into the exported core (_server_options,ignition/cli/serve.py:60-72, popped at:215, passed toprepared.exportat:240-242,:374-375);debug_serveadds it (:488) and_serve_preparedhandsoptionstoprepared.start_server(:553-563). Docs and code agree (docs/cli-design.md:1385-1387). So the only Ignition command that serves with the key honours it; there is no "parsed-and-ignored" gap to report.
A3 — One subtractive item is half-addressed
Commit e3829e62 ("Share the step-generates test predicate…") extracted generates() (helios/src/server/runtime/phase_tests.rs:374, used at :461, :4547, :5030) and Fixture::text_inputs() (:62), removing three copies of the decode/resume/prefill predicate. Still duplicated: the timed_pass/served_through_worker harness (phase_tests.rs:4535, :4567) versus the existing spawn/recv_timeout/to_bytes loops at :5009-5010, :5248-5250, :5642-5644, plus an inline repeat inside the third new test. Correct wording for the report: "the reviewer's ~180-line duplication finding is half-addressed (predicate shared, harness still duplicated)."
A4 — What the maintainer's conditions mean for #560 (new, highest remaining risk)
Luke Alonso's #548 review (2026-11-28 18:37) opened "The core design looks good" and then made two items blocking in code that #560's published diff carries verbatim:
- Mandatory TLA+ lifecycle conformance.
python3 verification/helios-lifecycle/check.py(not opened) plus--releasecrate tests are required (perdocs/design-review.mdLayer 3) wheneverRequestScheduleradmission, theWorkeradmission/completion/publish/park/shutdown paths, orruntime/phase_tests.rschange. #560 changes all three (runtime.rs+104/−37,phase_tests.rs+548/−18,response_lifecycle_tests.rs(not opened) +4), and its Evidence lists neither the lifecycle check nor a--releaserun — the identical omission he called blocking on #548 and #549. - Pre-prefill requeue corrupts the timing fields — the same fields #560's headline numbers are computed from.
Worker::reserve_and_packstampsfirst_scheduled_nson the first step of any graph kind (includingGraphKind::Init/Restore), andretry_late_pool_answerscancels such a request and callsself.requeue(handle, true). I verified at this head thatWorker::requeue(helios/src/server/runtime.rs:2647-2675) does not clearincoming.record.times, so a requeued request keeps a stalefirst_scheduled_ns. That value feedsqueue_time_ms(encode.rs:264),time_to_first_token_ms(:261) andtokens_per_second(:268-272), so #560 inherits the defect in its headline fields. The maintainer's prescribed fix (Reset incoming.record.times.first_scheduled_ns = None in Worker::requeue) is absent from the carried code. - Consequently his
Closes #536 → Part of #536rule will apply toCloses #551, for the reasons in Key finding 5.
A5 — Code changes since 046aaef0 (supersedes parts of entries #1/#4/#5/#9)
- Placement gate simplified.
helios/src/server/protocol/encode.rs:234-244:let placed = !streaming || self.include_usage || self.protocol == Protocol::Responses;— the oldinclude_usagesub-gate on the decode path is gone; Messages ⇒None(:238), multi-prompt ⇒None(:239),choices_per_prompt > 1⇒Some(RequestMetrics::Suppressed)renderingmetrics: null(:240,:252). So a Responses stream now always carries the object (still nested,:732-745). - Serialization reworked.
helios/src/server/http.rs:411, :536foldfirst_scheduled_nsacross choices with.chain(times.first_scheduled_ns).min(), andencoder.record_times(arrival_ns, times, generated_tokens)(:534) replaces the earliergenerated: Vec<u32>plumbing;encode.rs:750-756exposeschoice_generated_tokens(),:658/:750handle cancelled choices. first_scheduled_nsis now base-PR surface, not #560's.RequestTimesispub(helios/src/server/metrics.rs:344(not opened)) and re-exported besideSnapshot(helios/src/server.rs:33), documented inhelios/model-contract.md:343-352("a preempted request keeps its original value. It is null when no model step included the request"). The description still listsperformance.first_scheduled_nsunder "Flare's own shape" as this PR's contribution — inaccurate; it ships with #548.- Arithmetic detail (low value, checkable):
mean_itl_msdivides the first→last token span bygenerated − 1(encode.rs:265-267) using the usage-style count (http.rs:534), so the forced reasoning-close token enlarges the denominator without an instant and understatesmean_itl_msby ~(n−1)/n on a forced-close response; the speculative-rounds case is documented (docs/api.md:1011), the forced-close case is not.generation_time_msis0.0(not null) for a single token (encode.rs:255-259),tokens_per_secondis null on a zero-length span (:268-272). - Docs moved with the code:
docs/api.md:994-1043is the current section —:1022-1029documents theinclude_usagegate and names llama-swap,:1031-1036saystime_to_first_content_token_msis always null andn > 1/multi-prompt null/omitted.
A6 — Charter re-check (supersedes the charter row of entry #30)
- Flag compliant. AGENTS.md:453-454 permits serving settings as configuration or advanced flags; both are documented (
docs/cli-design.md:736,:1318,:1349), and behaviour is test-pinned on both entry points (flare-cli/src/cli.rs:1379-1400(not opened);flare-cli/src/config.rs:223-258(not opened)). - Charter "Don't silently ignore API fields" (#417) is the sharpest remaining charge, and it is a rule not a preference: "If a standard request field is passed in, either implement it according to the spec or reject it. Never accept it and quietly drop it." #560 accepts
stream: truewithoutstream_options.include_usagewith the option on and emits nothing (encode.rs:236; admitted in prose atdocs/api.md:1022-1029). Documenting a silent omission is not compliance; vLLM's force-include-usage is the spec-faithful route and Flare lacks it. - The dropped "named requirement" blocker has a charter route after all. Charter "What gets merged" includes "a reproducible bug"; issue #551 is exactly that, so the requirement can be satisfied without a maintainer statement. Keep "dropped, not satisfied" (no maintainer has endorsed #560), but note the charter row. The evidence row ("bring real evidence… served workload") is met by the 40/40 live matrix and the CPU bound, subject to A4(1).
A7 — Open questions, net after this event
- Will anyone review head e3829e62, given that the last two auto-reviews describe an earlier revision?
- Will the template line at
ignition/cli/config.py:194get a test, since its absence is exactly what broke ignition? - Does
Closes #551stand given the responses nesting, the excluded Messages protocol, and the absent draft counts — or does the maintainer'sPart ofrule apply as it did toCloses #536on #548? - Will #560 run
verification/helios-lifecycle/check.py(not opened) and--releasetests before merge, and will the requeuefirst_scheduled_nsreset land in #548 so #560's queue/TTFT/throughput fields are correct? - Content TTFT now has no open PR; will it return as a follow-up from
WynnD:metrics/content-ttft(3e8fd28), leavingdocs/api.md:1009permanently "Always null"?
Unchanged by this event (do not drop)
The mechanism was called correct in three consecutive auto-reviews; the published diff still carries all of #548, so a reviewer sees several PRs' worth and GitHub expresses none of the dependency; the include_usage gate limits Chat/Completions streams (encode.rs:236); the Responses placement never reaches llama-swap, which reads metrics only at an event's top level (author's own 03:26 row: "Responses streams show none") — this is now a documented contradiction of #551 rather than only a gateway limitation; author is WynnD (association NONE, 0 merged PRs, Discord oystersmiles), scoping the work down each round.
Not found / could not verify
No maintainer endorsement of per-request metrics as a requirement; no docs/TODO.txt entry for either remaining limitation; no multi-GPU-core or Windows-build evidence (author states both not run); CI/check-run status not observable with my tools; the autobot HTML review bodies were not read beyond the verdicts and counts quoted in the PR comments.
Author: WynnD (outside contributor, GitHub association NONE, 0 merged PRs; Discord oystersmiles)
Motivation: Clients and gateways such as llama-swap can only show prompt and decode rates if each response carries per-request timings, and Flare's /metrics endpoint aggregates instead. This PR adds, opt-in, vLLM's metrics object built from the instants the model worker already records for its histograms.
Scale: +2000 / −161 lines in 25 files (head e3829e62; the published diff also contains all of stacked #548)
Proposal:
- Add vLLM's six-field
metricsobject to Chat, Completions and Responses output, taken from worker-recorded instants rather than clocks read in the HTTP layer. - Place it at the top level of JSON bodies, on the final Chat/Completions usage chunk, and inside
responseofresponse.completed/response.incomplete. - Enable it with
--enable-per-request-metricsor[server] per_request_metrics, coveringflare run, Orbit rank zero, the desktop controller, andignition debug-serve. - Keep
time_to_first_content_token_msalways null (its implementation was split out and then closed as #562); suppress the object forn > 1, multi-prompt, and Anthropic Messages. - Document that streams without
stream_options.include_usageand Responses streams reach llama-swap with no rates, since Flare has no force-include-usage option. Touches: helios/src/server/metrics.rs(not opened) andhelios/src/server/runtime.rs(request instants, carried request times, requeue semantics)helios/src/server/protocol/encode.rsandhelios/src/server/http.rs(placement, gating, arithmetic)flare-cli/,flare/andignition/cli/configuration plumbing plusdocs/api.mdanddocs/cli-design.mdRelated items:- #548 Add per-request histograms and vLLM-parity request metrics (open): required base; supplies
RequestTimes/first_scheduled_ns; Luke Alonso's blockers there touch this PR's fields - #551 Report per-request timings on final responses so llama-swap can show prompt and decode rates (open): the issue this PR says it closes, but its own text specifies Responses top-level placement, Messages, and draft counts that #560 does not deliver
- #562 Report the first content token of per-request metrics in streams (closed): closed while draft; content TTFT now has no open PR
- #549 Report KV pages held by active requests (open): sibling metrics PR, reviewed by Luke Alonso with 0 auto-review blockers
- #552 Report request timings on final responses / #553 Add vLLM-compatible per-request metrics (closed): superseded predecessors
Link: https://github.com/NVIDIA/hyperflare-inference/pull/560
Autobot comments: The only blocking defect from the 05:42 auto-review (Ignition rejecting the documented
[server] per_request_metricskey) is fixed at head, and the 06:19 review is a verbatim duplicate of 05:42, so no review of the current tree exists. The description still claimsperformance.first_scheduled_nsas this PR's work when it ships with #548, andCloses #551overstates delivery: the object is nested insideresponsewhereas #551 asks for it besideresponse, Messages is excluded, and the draft-token counts #551 lists are gone after the switch to vLLM's format. Unaddressed and newly material: project owner Luke Alonso made the TLA+ lifecycle check plus--releasetests blocking on #548/#549, and the pre-prefill requeuefirst_scheduled_nsreset he asked for is still missing from the code this PR carries (verified:helios/src/server/runtime.rs:2647-2675does not clearrecord.times), which feeds this PR's queue-time, TTFT and throughput fields. Evidence rests on the author's own live 40/40 matrix and CPU bound; no CI result is visible, and the config template line the fix added is untested.