#1 [high] Change: PR #548 shape, size and files
PR #548 "Add request latency histograms and process metrics", author WynnD (GitHub association NONE; Discord oystersmiles). Open as a DRAFT, opened 2026-11-26, last updated same day, base main, head ebecef1, branched from f377dc8. Size 8 files +545/−20. Labels: none. Reviews: none. CI on head commit: no checks. Closes #536.
Files:
- docs/api.md (+25/−3) — documents request histograms, host-cache retirement histogram, process_* series, states histograms are Prometheus-only, not in format=json.
- helios/src/server.rs (+2) — in the
/metricshandler:state.first_response.render_histogram(&mut text)andmetrics::process::render(&mut text). - helios/src/server/http.rs (+6/−1) — observes
flare_request_e2e_secondsin both the streamingDelivery::Completebranch and the non-streaming one, gatedif !count(count == the count_tokens request path). - helios/src/server/latency.rs (+27/−8) —
FirstResponseSamplesbecomes{window: Mutex<Samples>, histogram: Histogram<21>};FirstResponse::outputalso observesflare_time_to_first_response_seconds; addsrender_histogram. Median gauge and 60 s window unchanged. - helios/src/server/metrics.rs (+228) — new generic
Buckets<const N>+Histogram<const N>(per-bucket AtomicU64 + sum), bucket sets REQUEST_SECONDS(21), TOKEN_SECONDS(19), PROMPT_TOKENS(21),RequestTimesstruct, 6 new histogram fields onMetrics,Metrics::request_completed, render block, one new test. - helios/src/server/metrics/process.rs (new, +184) — Linux-only procfs reader for process_cpu_seconds_total, process_resident_memory_bytes, process_virtual_memory_bytes, process_start_time_seconds, process_open_fds, process_max_fds; non-Linux renders nothing. 2 tests.
- helios/src/server/runtime.rs (+38/−8) —
Incominggainstimes: RequestTimes;Worker::completestamps first/last committed token ns; both formermetrics.completed.fetch_addsites replaced bymetrics.request_completed(...);Worker::reserve_and_packstampsfirst_scheduled_nsfor each lane afterscheduler.commit. - helios/src/server/runtime/phase_tests.rs (+35) — 3 existing tests extended plus the fixture constructor.
Immutable/non-atomic note: last_token_ns: u64 is a plain field, not Option<> — 0 means none; Metrics::new uses Default for times.
#2 [high] Why: issue #536 is the direct driver, filed same day
Issue #536 "Metrics: add request latency histograms and process metrics for monitoring parity with vLLM", by Napuh, opened 2026-11-26 09:03, updated same minute, open, 0 comments. Environment: hyperflare-inference v0.3.2 (c0c4f79).
Missing-vs-vLLM table it builds: e2e latency (vllm:e2e_request_latency_seconds), queue time, time_per_output_token / inter_token_latency, prefill duration, decode duration, TTFT (only flare_first_response_median_seconds 60 s median gauge today), prompt tokens per request (vllm:request_prompt_tokens), process metrics (process_cpu_seconds_total, process_resident_memory_bytes, process_open_fds, process_start_time_seconds).
Motivation stated: the median gauge cannot give P95/P99, cannot be computed over other windows, cannot be aggregated across instances; histograms let users run histogram_quantile() over any window and alert on tail latency.
It proposed exactly the names PR #548 implements: flare_request_e2e_seconds, flare_request_queue_seconds, flare_request_prefill_seconds, flare_request_decode_seconds, flare_time_per_output_token_seconds, flare_time_to_first_response_seconds, flare_request_prompt_tokens, plus process_*. It also proposed keeping flare_first_response_median_seconds for compatibility (PR #548 does).
Difference vs the proposal: #536 asked for flare_request_queue_seconds = "admission to first scheduled step"; PR #548 measures "model-scheduler arrival to first model step" (docs/api.md wording) — i.e. it starts at runtime arrival, not HTTP admission. Also #536 did not list process_virtual_memory_bytes (PR adds it) and PR #548 does not add vLLM's flare_... equivalent of inter-token latency beyond time_per_output_token.
Filed by Napuh, 0 comments, 0 interest shown beyond the filing; the same day two PRs (#548, #549) close it and #537, all by WynnD, and #541 (jere357) builds a Grafana dashboard that mentions #536.
#3 [high] Change: what the new histograms measure, verified in code
Verified in code (PR head ebecef1):
-
Queue start = runtime arrival, not HTTP admission.
Incoming.arrival_nsis set insideModelRuntime::schedule(helios/src/server/runtime.rs:901) when the request is sent to the worker's queue;scheduler.set_arrival(handle, incoming.arrival_ns)at runtime.rs:1471. Soflare_request_queue_seconds= worker-queue + model-scheduler wait, excluding HTTP ingress, tokenization and framework preparation. docs/api.md (PR) says "from model-scheduler arrival"; issue #536 asked "admission to first scheduled step". The PR description says neither point explicitly, so a reader comparing to vLLM's queue-time (which starts at engine add_request) can mis-map it. E2e and TTFR, by contrast, start at HTTP admission (AdmittedAtinserted inadmit_http, helios/src/server.rs:828; read in http.rs:127). -
first_scheduled_nsis stamped inWorker::reserve_and_pack(runtime.rs:2186-2201) afterself.scheduler.commit(step, fence)and for every lane of the step, first-write-wins viaget_or_insert. So a request that is planned but whose step never commits gets no queue observation; and the stamp is the moment of reservation/packing, before the GPU replays. -
Both completion counter increments are now inside
Metrics::request_completed(metrics.rs:452-480): the user/text stop inWorker::complete(runtime.rs:1841) and the natural finish inWorker::publish(runtime.rs:1993). Cancelled (runtime.rs:1317,1338,1360,1407) and failed (runtime.rs:330) paths do not observe histograms, as documented. -
Decode/time-per-output-token are skipped unless
generated_tokens > 1;time_per_output_tokenuses integer divisiondecode / (generated_tokens - 1)so it truncates to whole nanoseconds before bucketing (metrics.rs:473-478) — harmless at 19 buckets. -
Prompt tokens observed =
carried.prompt_tokens.unwrap_or(live.prompt_tokens), i.e. the original prompt length carried across preemption, matching theFinishedevent's value — so prompt-token histogram agrees with per-responseusage.prompt_tokens. -
Histogram<N>::observeis a linear scan of the bounds per observation (21 comparisons) and usesOrdering::Relaxedatomics;sumstores nanoseconds and is printed assum as f64 / 1e9(metrics.rs:272-291). The ns sum exceeds f64's 2^53 exact-integer range only after ~104 days of accumulated request time in one counter, so a very long-lived, very busy server could print a_sumwith rounding (low risk, worth knowing).
#4 [high] Change: e2e is server-side only; TTFR needs a client poll, e2e does not
- e2e is observed in the
Delivery::Completearms ofhttp::generate: streaming at http.rs:614-617 (insidefilter_map, on the runtime's completion event, before the SSE body is drained) and non-streaming at http.rs:631-632 (before the JSON body is polled by the client).Delivery::Failed(http.rs:610,643) observes nothing, so failed/cancelled generations are absent from e2e — matches the description. - Asymmetry not stated anywhere:
flare_time_to_first_response_secondsis recorded only when the client actually polls the body (first_response.output()at http.rs:607/638, gated bystream_text/ non-empty chunk), whileflare_request_e2e_secondsis recorded as soon as the handler produces the completed response even if the client drops it. The phase testfirst_response_http_stream_excludes_pretext_failures_and_unpolled_bodies(phase_tests.rs:4406-4434) asserts e2e count stays 0 on failure;first_response_http_nonstream_records_only_when_completed_body_is_offered(phase_tests.rs:4436-4473) asserts e2e count is 1 whether or not the body is polled, while the TTFR histogram count followspoll_body. So e2e measures server-side handling only, not delivery to the client — a reader porting vLLM dashboards (where e2e is measured around the engine request) should know. /v1/messages/count_tokensis excluded from e2e vialet count = request.uri().path() == "/v1/messages/count_tokens"(http.rs:131). TTFR is not excluded explicitly, but a count_tokens response has no answer text, andresponse_text/stream_textwould not offer any, so it cannot be observed. Description states the e2e exclusion only.- The e2e histogram lives on the same runtime
Metricsstruct (pub(super) request_e2e: Histogram<21>), reached throughstate.model.metrics_handle()in the stream arm (http.rs:603) andstate.model.metrics()in the non-stream arm.
#5 [high] Change: process metrics are hand-rolled procfs, Linux only, no new dependency
helios/src/server/metrics/process.rs is a hand-written clone of the Prometheus client collector, not an added dependency. libc = "0.2.189" is already an unconditional dependency of the flare-helios crate (helios/Cargo.toml:50), so no new crate and no feature gate; the module is pub(super) mod process; in metrics.rs and is only reached from the /metrics text handler (server.rs:709). No Cargo.toml change in the PR (file list confirms). This satisfies the charter's "pin everything / no new dependencies" preference — the alternative (adding the prometheus crate) would have been a dependency change.
Platform behavior: render() is a no-op outside Linux (#[cfg(not(target_os = "linux"))] let _ = text;). Windows is a supported serving target (docs/windows.md; flare-winui; the native-serving CI matrix builds and tests on windows-2022, .github/workflows/native-serving.yml:17-21,64-68), so a Windows operator scraping /metrics sees no process_* series and generic Prometheus process dashboards stay empty there. docs/api.md (PR) says "Other platforms omit them", so it is documented but the PR description's framing ("generic Prometheus process dashboards have no process_* series to read") is only resolved on Linux.
Robustness choices: each source read is .ok()-guarded and a parse failure omits only the dependent metric (no unwrap in the render path); sysconf(_SC_CLK_TCK)/_SC_PAGESIZE and getrlimit(RLIMIT_NOFILE) are wrapped in unsafe with SAFETY comments; parse_stat splits after the last ) to survive a command name containing ) and spaces, and there is a unit test for that (parse_stat_reads_fields_after_a_parenthesized_command_with_a_paren).
process_open_fdscounts the entries of/proc/self/fd, which includes the directory handle opened for the read; the help string says so explicitly ("including the directory read that counts them"), so the value is off by one against the "true" count. Prometheus's own client_collector has the same artefact; worth knowing but declared.process_start_time_seconds=btimefrom /proc/stat + starttime ticks / CLK_TCK, the standard derivation.- There is no
process_threads, and no/proc/self/statmuse.
#6 [high] Related work: #536/#537/#541/#549 cluster and prior histogram code
All three come from the same request wave and are dated 2026-11-26:
- #536 (issue, Napuh, 09:03) — the feature request, vLLM monitoring parity. Closed by #548.
- #537 (issue, Napuh, 09:07) — companion KV-usage gap. Closed by #549.
- #548 (PR, WynnD) — this PR, closes #536, opened later the same day as a draft.
- #549 (PR, WynnD, 20:24) — sibling PR by the same author, closes #537, touches helios/src/server/metrics.rs and docs/api.md too; both PRs explicitly say the metrics.rs and docs/api.md hunks are in disjoint regions and "merge in either order". Verified plausible: #549 adds gauges near
cached_pages/SchedulerStatsand its own docs paragraph; #548 adds histograms besidecompletedand its own docs paragraphs; #549 also touches cache.rs, scheduler.rs, tests. - #541 (PR, jere357, 16:47, updated 19:21) — "Add a Prometheus and Grafana monitoring example": a docker-compose Prometheus+Grafana dashboard under examples/monitoring/. Its auto-review explicitly says "The only in-repo signal of Grafana interest is issue #536 (latency histograms, which Flare does not yet export)". So #541 is the consumer-side motivation for #548 and would be the first dashboard to actually use the new series — but #541's dashboard queries none of them yet (it predates the PR and its reviews flag missing/differently-named panels). Retitled by #541's review: DEPTH panels "belong with #536/#537".
- No competing or superseding PR exists for request histograms:
search_items histogram/prometheus/metricsreturns only #536, #548, #549, #541. - Prior metrics work that this extends: #507 (merged, lukealonso) persistent worker counter schema / Prometheus metrics / /v1/worker telemetry, and the host-cache histograms already in metrics.rs (flare_host_cache_missing_tokens / estimated_transfer_ns / estimated_prefill_ns / retirement_seconds, metrics.rs:851-890).
Histogramhere is a new generic type; the existing host-cache histograms keep their own[AtomicU64; 8]arrays +flare_selene::RETIREMENT_LATENCY_MSbounds, so the codebase now has two histogram implementations. PRIOR_ART_NOT_REFACTORED - a reviewer could ask why the host ones were not moved ontoBuckets/Histogram. - #78 (open issue, DS4.1 Flash disk Engram) asks "Would per-gather latency/miss-count histograms and explicit metric scope/rank labels be useful additions?" — evidence that request-level distributions have been wanted elsewhere too, though about a different subsystem.
- docs/TODO.txt:110-124 lists "Measure cross-host rank handoff ... request p99 ..." and "Qualify retained graph costs ... request latency measurements" — i.e. the project already tracks a TODO for request p99 latency measurement that this PR partially serves.
#7 [high] Claims and evidence: what is backed, what is not, CI has not run
- The PR is a draft with no CI checks on head ebecef1, no reviews, no labels, opened 2026-11-26 and updated the same day. Zero comments/reviews/reactions on the PR itself —
pr_commentsreturns "No comments". So no community engagement yet; the only external signal is the two issues it closes. - The author's own evidence claims:
--lib -- server::runtime::phase_tests: 109 passed;--lib -- server::metrics::: 20 passed. Those are two module-scoped subsets. He states explicitly "Not run here: the Windows build; the full helios suite; andmessages_image_hints_end_after_expansion_for_text_and_segmented_templates, which needs FLARE_TEST_TEMPLATE_DIR ... CI covers the first two."- Note the CI coverage: the
native-servingworkflow does build+test helios with--features runtime-core,serveron both ubuntu-24.04 and windows-2022 and sets FLARE_TEST_TEMPLATE_DIR fromtests/frontend/prepare_templates.py(.github/workflows/native-serving.yml:28-31,56-68). So the unrun Windows build and template-dependent test are genuinely covered once CI runs — but with no checks on the head commit, none of that has happened yet.
- Note the CI coverage: the
- Merge-logistics claim to verify at merge: description says the branch was cherry-picked onto the AzallazA fork commit
5ffe4d54and that the only conflict was context around the persistent-worker metrics function. That is the live-scrape base, not the PR base: onmain,helios/src/server/metrics.rsalready contains the persistent-worker render function from #507 (merged f646bebc, 2026-11-24). Nothing in the PR diff removes or relocates it, so the base merge is a clean add — the conflict story only affects reproducing the live numbers, not the merge. - The live evidence is on one two-GPU DeepSeek-V4.1-Flash instance, built with the repo Dockerfile, swapped into a llama-swap entry. The author states the instance also served the agent session's own requests, so the deltas exceed the three named requests ("Counts gained 5 for each runtime histogram and 6 for the first-response histogram" against 3 requests). Prompt-token buckets are used to attribute the extra observations: "le="64" gained exactly one observation ... le="2048" gained four, which are the two long prompts plus two session requests". That is a self-declared confound, not a controlled measurement; it is honest but the numbers cannot be read as a clean 3-request run.
- No performance claim is made ("Observability only ... nothing about serving changes", "claims no performance or memory improvement"). The only implicit cost not measured or mentioned: per-observation atomics in the decode loop (6 histogram fields, 1-2 atomic adds + a 21-entry linear scan per completed request, and one extra
monotonic_ns()per completion plus one per step inreserve_and_pack), and 6 new histograms of memory inMetrics(~63 AtomicU64 = ~500 B) times the number ofMetricsinstances. Not a plausible throughput risk, but is unmeasured and unstated.
#8 [high] People: first-time contributor; the area is owned by yatesdr and Luke Alonso
- Author: WynnD (git name Wynn Drahorad), GitHub association with the repo: NONE. In the last 180 days: 0 merged, 0 closed, 1 open PR before today — and that open one is #549, also opened today (2026-11-26 20:24). So #548/#549 are the author's first contributions to the repository; there is no merged history to weigh. Both close issues filed the same morning by Napuh; both carry
Discord: oystersmiles. - The issue filer, Napuh, is also new in this window: #536 and #537, both 2026-11-26, both 0 comments, both
Environment: hyperflare-inference v0.3.2 (c0c4f79). So the demand signal (two issues) and the supply (two PRs) all appeared within ~12 hours, from two accounts with no prior merged work in the last 180 days. That matters for "how long and how widely it has been wanted": by the local record, the ask is <1 day old and has one requester. - Who usually works in this area:
helios/src/server/metrics.rscommits in the last 180 days are dominated by yatesdr (host-cache/selene counters: #400, #415, #429, #358, #168, #141, #92), Luke Alonso (persistent worker schema #507, dashboard scaling, startup selection), Martin Vit (#504, #479, #298), jasonc (orbit/agent metric sampling), Eugene Rakhmatulin (KV capacity gauges). docs/ commits: Luke Alonso (367), Martin Vit (52), yatesdr (47). None of these people has engaged with #548. - Related consumer: #541 by jere357 (Discord cropinky) builds the Grafana example and is being actively auto-reviewed; it depends on the same metric names being right. jere357 has not commented on #548.
- Priority contributors named in the charter:
@voipmonitor,@original-el8,@lukealonso. Neither author of #548 nor #541 is one. docs/api.mdownership: Luke Alonso's commit 698ee450/543 and PCCessna's #538 landed in docs the same day; the api.md §Health and metrics table is maintained by Luke Alonso (author of the surrounding text and of #507's metric schema).
#9 [high] Reach: docs inconsistencies introduced or fixed by the change
- docs/api.md §Health and metrics was rewritten by this PR (docs/api.md:296-318 at PR head) to (a) move histograms into their own paragraph, (b) add the missing
flare_host_cache_retirement_secondsto the histogram list — an undeclared doc fix: the old text said "The only histograms describe host prefix-store lookups: missing_tokens, estimated_transfer_ns, estimated_prefill_ns", which was already stale because retirement_seconds shipped earlier (metrics.rs:851-890; docs/operating.md:47-50). So the PR's docs hunk also corrects pre-existing drift, which the description does not mention. - docs/api.md's JSON-contract section is not updated to say the new histograms are text-only in a way a JSON consumer sees: the PR writes "Histograms appear in the Prometheus format only" and the JSON snapshot is unchanged (verified: no new fields in
Metrics::snapshot, metrics.rs:488-526, andHttpState//metricsJSON path at server.rs:645-659 only insertsfirst_response, input counts andpersistent_worker). Soflare_helios::server::Snapshotconsumers see nothing new. Consistent with the description. - The metrics table at docs/api.md:338+ is not extended with the new series; they are described in prose paragraphs above it instead. Operator-facing consequence: the table remains the "field ↔ Prometheus name" map, and the new request series have no rows. #541's reviewer separately complained the table "lacks the *_kv_tokens gauges and requests_cancelled_total", so this is a known sore point in that area.
- No config, flag, default, or CLI change: nothing to enable or disable; the histograms are always on and always rendered. That means the
/metricsresponse body grows by ~6×(21 bucket lines + help/type/sum/count) ≈ 160 lines plus ~30 lines on Linux of process metrics — a permanent scrape-size increase with no opt-out. Not quantified by the author; Prometheus text for a scrape goes from a few KB to a few KB more, so it is small, but strictly monotone growth is a design choice a reviewer may comment on. flare_*naming overlaps:process_*is deliberately unprefixed to match the standard Prometheus collector names, so the docs' earlier claim "Counter and gauge names start withflare_" is now false. The PR does not amend that sentence (docs/api.md:288-289 still reads "Counter and gauge names start withflare_") while addingprocess_cpu_seconds_totaletc. That is an internal inconsistency introduced by the change.
#10 [high] Project fit: charter clauses on evidence, scope and what gets merged
Charter (read_charter) facts, stated as facts:
- "How We Work → Bring real evidence": "Performance PRs need benchmarks showing an actual speedup over
mainon a served workload". This PR claims no performance change, so that clause does not bite; it is observability-only. - "Keep the runtime small and model-agnostic": the change adds no per-model branch (scheduler/runtime only). It does add ~200 lines of generic histogram infrastructure plus ~184 lines of Linux procfs code inside
helios/src/server. The procfs code is arguably not hyperflare-specific and the charter's "smallest footprint ... or a way to solve it without new code at all" asks whether a dependency (theprometheuscrate's process collector) would be smaller — the author chose hand-rolled to avoid a dependency, which is the opposite trade of thelibc-free preference but matches "pin everything". - "What gets merged": "PRs that address a maintainer request, a roadmap item, a reproducible bug, a measured performance/memory issue, or bad docs." #548 addresses an issue filed by a non-maintainer (Napuh, association NONE per the record — the packet only gives association for the PR author WynnD; Napuh's association is not stated in what I read). The charter's authorization clause says "An explicit maintainer request covering the work is sufficient authorization"; a community issue is weaker. No maintainer has commented on #536/#537/#548/#549.
- AGENTS.md:165-169 "Every contribution must address an explicit maintainer request, a demonstrated defect, a measured performance or memory problem, or inaccurate documentation. ... Hypothetical future consumers, agent-generated suggestions, and lint findings alone do not establish a need for a change." The need here is stated as operator need (Grafana migration, SLO alerts) and the only consumer in-repo is #541, which is itself unmerged and has no maintainer approval.
- AGENTS.md:72-112 four-part PR description (why / what / claimed result / evidence). #548 has all four with headers, states what was not run, and distinguishes claimed from measured. It is unusually compliant on this axis.
- AGENTS.md:52-60 "State support as present qualification ... Record unresolved defects, unrun checks ... in docs/TODO.txt". The PR documents the Linux-only omission in docs/api.md rather than TODO.txt; acceptable as it is designed behavior, not an unresolved defect.
- Charter Non-Goals include "Broad production coverage across arbitrary models, GPUs, or deployment setups" and "general cluster orchestration". vLLM-parity Grafana/SLO tooling is closer to production monitoring framing than to the project's self-description ("a focused research prototype ... not trying to make it a general-purpose production server"). That is a tension a maintainer may weigh: the motivating issue is explicitly "monitoring parity with vLLM" and "move existing vLLM Grafana dashboards and SLO alerts to Flare".
- Reverse tension in the PR's favour: the project already ships a rich
flare_*metric surface, a terminal dashboard, anddocs/api.md§Health and metrics, so metrics work is established practice, not new scope.
#13 [high] Research summary
Case file for PR #548 "Add request latency histograms and process metrics" (WynnD, draft, +545/−20, 8 files, head ebecef1, no CI checks, no reviews) is gathered in the scratchpad across 12 entries, one per angle.
Key findings a reader could not get from the description:
flare_request_queue_secondsstarts at runtime arrival, not HTTP admission:Incoming.arrival_nsis set inModelRuntime::schedule(runtime.rs:901) and handed to the scheduler at runtime.rs:1471. Issue #536 asked for "admission to first scheduled step"; e2e and TTFR, by contrast, start at HTTP admission (AdmittedAt, server.rs:828). The description names neither start point, so a reader porting vLLM queue-time semantics can mis-map it. Prompt-token observation uses the preemption-carried original prompt length, so it agrees with per-responseusage.prompt_tokens.- Undeclared asymmetry in the HTTP observations:
flare_time_to_first_response_secondsis recorded only when the client actually polls the body, whileflare_request_e2e_secondsis recorded as soon as the handler produces the completed response even if the body is dropped (http.rs:614-617 vs :607/638; phase_tests.rs:4406-4473 pins both behaviours). e2e therefore measures server-side handling, not delivery. helios/src/server/metrics/process.rsis hand-written procfs code, Linux only;libcis already an unconditional dependency offlare-helios(Cargo.toml:50), so no Cargo change. Windows is a supported serving target and CI builds it, but a Windows scrape gets noprocess_*series — documented, yet it means the description's generic-dashboard motivation is resolved only on Linux.process_open_fdscounts its own directory read (declared in the help string).- The docs hunk also silently repairs pre-existing drift: the old text claimed host-prefix lookups were "the only histograms" while
flare_host_cache_retirement_secondsalready shipped. Conversely the change leaves "Counter and gauge names start withflare_" (api.md:288-289) standing while adding unprefixedprocess_*. - Process/community: the PR is a draft with zero checks, zero comments and no maintainer engagement anywhere in the cluster. The author has no merged contribution and GitHub association NONE; their other PR (#549) was opened the same day; both close issues (#536, #537) filed the same morning by one new filer, Napuh. So the demand is under a day old and one-requester wide — relevant to the charter's "explicit maintainer request" merger test.
- Evidence: the claimed test runs are two module subsets (
server::runtime::phase_tests109 passed;server::metrics::20 passed); Windows build, full helios suite and one template-dependent test are explicitly not run, and CI does cover the first two on both ubuntu and windows-2022 (native-serving.yml:56-68) but has not run. The live scrape is a single two-GPU DeepSeek instance whose deltas include the agent session's own traffic — self-declared confound, not a controlled three-request measurement. No performance claim is made and none of the added per-completion cost is measured. - Related work: nothing on main conflicts (no default-branch commit since f377dc8 touches these files);
metrics.rshas three open PRs in flight (#548, #549, #542) plus #334 touching it; #507 is the function the new code sits beside; #541 is the Grafana consumer whose own auto-review says the only in-repo Grafana signal is #536. The change leaves the four existing host-cache histograms on their older[AtomicU64; 8]implementation, so the file now holds two histogram implementations. - Charter fit: observability-only, no per-model branch, complete four-part description — but the motivating framing ("monitoring parity with vLLM", migrating SLO alerts) sits against the charter's "not a general-purpose production server" self-description, and no maintainer has authorized the work.
Angles with nothing found: community (no comments, reviews or reactions anywhere in the cluster).
#17 [high] AMENDMENT (2026-11-27): head d64c3ea — blocker 1 fixed, but the process refactor breaks a documented feature build
PR #548 head moved ebecef1 -> d64c3ea ("Exclude cancelled responses and reuse host helpers", 2026-11-26). Size is now +550/-20 in 10 files (was +545/-20 in 8): adds helios/src/runtime_core/mod.rs (+1) and helios/src/runtime_core/protection.rs (+1/-1), and metrics/process.rs shrank +184 -> +172. Still draft; no review, no CI evidence on the new head.
WHAT THE COMMIT DOES
- e2e exclusion + single observation point. http.rs:598-606: one observation per successful response, guarded
if !count && !encoder.tool_limit_reached, placed just beforeyield Delivery::Complete(response)inside the delivery generator; the duplicate observations in the streaming filter_map (:614-617 before) and the non-streamingDelivery::Completebranch (:631-635 before) are deleted,Delivery::Complete(_) => Nonenow (http.rs:621), and the cachedmetrics_handle()clone is gone (usesstate.model.metrics()). - process.rs now reuses shared helpers instead of hand-rolling them:
page = crate::os::page_size()(process.rs:56; eos/src/unix.rs:73-75),open_fds = crate::runtime_core::open_descriptors()(:63; runtime_core/protection.rs:291-302, newlypub(crate)and re-exported at runtime_core/mod.rs:58),max_fds = crate::os::raise_open_file_limit(0)(:65; eos/src/unix.rs:138-165, desired=0 only reads the soft limit). Only /proc/self/stat and /proc/stat btime parsing stay local.process_resident_memory_bytesno longer has a separate page-size fallback (:85-93). - New assertion in
disabled_parallel_calls_complete_http_and_stop_decoding(phase_tests.rs:4604-4613): the tool-limit cancellation must leaveflare_request_e2e_seconds_count 0.
BLOCKER 1 OF THE 26 NOV REVIEW IS FIXED. The tool-limit path was the only place the HTTP layer cancels a generation while still delivering a complete response (http.rs:471-476 skip, :526 Cancelled substitution, :563-567 generation.cancel()), and it is now excluded; docs/api.md:315-316 ("Cancelled and failed requests enter only ..._cancelled_total and ..._failed_total") is consistent again. The other cancel paths set the flag only from Generation::cancel/Drop (runtime.rs:152-154, :175-179), which either ends in an Error event or a dropped response, so no Complete and no observation. Nothing in the new head addresses the earlier "cancellation races the natural finish" remark, but I found no path where it now produces an e2e observation.
NEW HIGH FINDING — the refactor makes a documented build configuration fail to compile on Linux.
helios/src/server/metrics/process.rs:63callscrate::runtime_core::open_descriptors()unconditionally under#[cfg(target_os = "linux")].runtime_coreis#[cfg(feature = "runtime-core")] pub mod runtime_core;(helios/src/lib.rs:25-26), whileserveris gated only on#[cfg(feature = "server")](:28-29) and theserverfeature does not enableruntime-core(helios/Cargo.toml:25; default = [] at :17).- So a Linux build/test of helios with
--features serverand withoutruntime-corenow references a module that does not exist (E0433). Two documented commands use exactly that feature set:cargo test --manifest-path helios/Cargo.toml --features server --lib frontend::and... --features server --test message_boundaries(docs/model-development.md:99-100), and... --features server --lib scheduler::/server::runtime::phase_tests::(docs/scheduling-runtime-design.md:735-737). - CI cannot see it: native-serving builds helios only with
--features runtime-core,server(.github/workflows/native-serving.yml:63,68), flare-cli/flare always enable both (flare-cli/Cargo.toml:27, flare/Cargo.toml:23), helios-lifecycle runscargo kani --libwith no features. Windows--features serverstill compiles because the call sits behindcfg(target_os = "linux")— the break is Linux-only. - Before this commit the server module had no
runtime_corereference outside#[cfg(feature = "runtime-core")]code (session.rs, prompt_tests.rs), so this is new. - Cheap fixes: gate the call on the feature, route the fd count through the
crate::ossurface (it is a /proc read, not a runtime-core concept), or gate the wholeprocessmodule.
Also unchanged by the commit: the two competing histogram implementations (host-cache arrays vs Histogram<N>), the ~190-line permanent growth of every /metrics body with no opt-out, no process_* on Windows, and the unmeasured per-step/per-scrape cost.
#18 [high] AMENDMENT (2026-11-27): docs findings resolved at head; description drift grows
The d64c3ea docs hunk in docs/api.md (PR head lines 287-321) resolves most of the documentation findings in my 26 Nov report:
- Naming contradiction fixed: "Counter and gauge names start with
flare_, ... except the standardprocess_*series described below" (docs/api.md:288-290). - "Histograms ... accumulate since server start" added (:297).
- The two groups are now named and split: "The HTTP histograms observe delivery" (:303-307) and "The runtime histograms observe completed generations" (:309-316).
- e2e stream semantics fixed: "for a stream it is observed when delivery completes, which requires the client to drain the body" (:304-306).
- Eligibility fixed: decode and
flare_time_per_output_token_seconds"are recorded only for requests with at least two generated tokens" (:312-314), matching metrics.rs:470-479. - Prompt-token definition kept and clarified (:314-315).
- The queue boundary is now named as "model-scheduler arrival to the first model step that includes the request, which can be a vision step" (:309-312).
- The old "The only histograms describe host prefix-store lookups" sentence is gone, so the earlier "undeclared doc repair" finding is moot, and
flare_host_cache_retirement_secondsis listed (:298-301).
STILL WRONG / STILL OPEN
- "The HTTP histograms observe delivery" (:303) overstates the non-streaming case: e2e is recorded inside the delivery generator before the response is returned (http.rs:598-606), and
first_response_http_nonstream_records_only_when_completed_body_is_offeredstill pinsflare_request_e2e_seconds_count 1for bothpoll_body = falseandtrue(phase_tests.rs:4461-4465). Only the streaming case needs the client to drain. One clause ("non-streaming responses are observed when the body is produced"). - The vision phrase covers the queue boundary but not that prefill absorbs vision compute:
first_scheduled_nsis stamped for every lane before theGraphKind::Visionsplit (runtime.rs:2191-2203 vs :2208), soflare_request_prefill_secondsincludes vision work too. Partially addressed, still not said explicitly. - The PR description remains silent on the queue histogram's start point (docs say model-scheduler arrival; #536 asked for admission) and now also silent on the third e2e exclusion: it still reads "observed when delivery completes a successful response, except for
/v1/messages/count_tokens", with no mention of the tool-limit/cancelled exclusion that this commit adds, and no mention of the newruntime_coredependency or the shared-helper refactor. - The description's Evidence section was not updated with the new assertion, and still claims "nothing about serving changes" (unchanged), the two module-subset runs (109 + 20), the run-not-run list, and "CI covers the first two" (no checks on the new head either; the author instead asked for an autobot re-review).
docs/api.md:318-321still says other platforms omitprocess_*; unchanged, still the Windows gap.
#19 [high] AMENDMENT (2026-11-27): #548 now has a stacked dependent (#552) and a sibling (#553); issue #551 names the proxy gap
Three new items appeared in the hours after my 26 Nov report, all by WynnD and all referring to #548:
- Issue #551 "Report per-request timings on final responses so llama-swap can show prompt and decode rates" (WynnD, 2026-11-27 03:26, open, 0 comments): llama-swap's activity table and
GET /api/metrics/activityshow -1 for prompt/decode rates because Flare emits onlyusage;buildMetricsin llama-swap v250 (internal/server/metrics.go, commit60226b6) reads a llama.cpptimingsobject or a vLLMmetricsobject from a non-streaming body or any SSE event and never scrapes/metrics. Explicitly says "Flare's Prometheus histograms cannot substitute: llama-swap parses proxied response bodies and does not scrape/metrics" — i.e. the author states #548's series cannot serve this consumer. - PR #552 "Report request timings on final responses" (WynnD, 2026-11-27 04:30, draft, +929/-26, 11 files, head aea4147, closes #551): stacked on #548 — "This branch is stacked on #548, which adds the request-latency histograms and the
RequestTimesstamps this PR reads... Merge #548 first." It makesRequestTimespub, addsDraftCounts, carries both onGenerationEvent::Finished, and renders a llama.cpp-compatibletimingsobject (cache_n/prompt_n/prompt_ms/prompt_per_second/predicted_n/draft_n/draft_n_accepted) on the final output of all four protocols. Its own file list still shows #548's files (docs/api.md +45, metrics.rs +228, process.rs +184, latency.rs +27/-8) because it is not rebased. - PR #553 "Add vLLM-compatible per-request metrics" (WynnD, 2026-11-27 04:52, open, +302/-9, 11 files, head fd5c67e): opt-in
--enable-per-request-metrics/[server] per_request_metrics, emitting vLLM'smetricsobject (time_to_first_token_ms, time_to_first_content_token_ms, generation_time_ms, queue_time_ms, mean_itl_ms, tokens_per_second) in OpenAI response bodies. Claims no runtime/#548 overlap and "merges in any order with them"; its http.rs hunk starts from the pre-#548 base (delivery.next()loop still present), so it will conflict textually with #548's e2e rearrangement (http.rs:598-606 vs :631-644). - WynnD's 2026-11-27 04:56 comment on #548: "@flare-autobot review the pushed changes. The per-request metrics PR is new; the other two carry review fixes." — i.e. #548 is the PR carrying review fixes, #552/#553 are new.
Consequences for #548's review:
- The response-side gap #548 leaves (no per-request timing for proxies) is now explicit in the same author's own issue #551, and #552 is stacked behind #548, so #548 becomes a merge-order dependency for at least one sibling. That makes the queue histogram's semantics and
RequestTimes' shape more consequential: #552 reads exactly the stamps #548 added (first_scheduled_ns,first_token_ns,last_token_ns) and turns them intoprompt_ms/predicted_ms, so a wrong start point propagates into the response body, not just a scrape. - Three PRs now touch helios/src/server/http.rs and metrics.rs in the same week; the earlier "three open PRs edit metrics.rs" queue is now four-way plus #552/#553.
- No maintainer comment, review or CI run on any of #551/#552/#553 either; all under a day old.
#21 [high] Research summary
The new event (commit d64c3ea on PR #548, plus three new items in the cluster) is reviewed and the amendments are in scratchpad notes #17–#20. Headline amendments:
-
Review blocker 1 is fixed. e2e is now observed once, inside the delivery generator, guarded by
!count && !encoder.tool_limit_reached(http.rs:598-606); the duplicate observations and themetrics_handle()clone are gone; and a new assertion pinsflare_request_e2e_seconds_count 0on the parallel-tool-limit path (phase_tests.rs:4604-4613). The docs naming, cumulative-window, group-split, ≥2-token and stream-drain findings from the 26 Nov review are also now fixed indocs/api.md:287-321. -
New high finding introduced by the same commit.
process.rs:63now callscrate::runtime_core::open_descriptors()undercfg(target_os = "linux"), butruntime_coreis gated on theruntime-corefeature (helios/src/lib.rs:25-26) while theserverfeature does not enable it (helios/Cargo.toml:25). A Linux build with--features serveralone — exactly the documented commands indocs/model-development.md:99-100anddocs/scheduling-runtime-design.md:735-737— no longer compiles. No CI job covers that combination (native-serving.yml:63,68always passes both features; Windows compiles because the call is Linux-gated). -
Cluster change. #548 is now a merge-order dependency: PR #552 (draft, +929) is explicitly stacked on #548 and turns
RequestTimesinto llama.cpp (not opened)-styletimingson response bodies, and PR #553 adds vLLM-style per-requestmetrics; both by the same author, whose issue #551 states plainly that Prometheus histograms cannot serve the llama-swap consumer. That raises the cost of the queue-histogram start point, since #552 propagates the same stamps into the wire format. Also: docs still call non-streaming e2e "delivery" when it is recorded before the body is returned, the description is unchanged (still no queue start point, no tool-limit exclusion, stale CI/evidence claims), no CI has run on d64c3ea, and there are still no reviews or maintainer engagement anywhere in the cluster.
#22 [high] AMENDMENT TEXT (2026-11-27): the amendments to append to the report, worded
Amendments to the 2026-11-26 report (run of 2026-11-27)
1. Head moved: ebecef1 → d64c3ea "Exclude cancelled responses and reuse host helpers". Size +550/−20 in 10 files (was +545/−20 in 8). Still draft, still no reviews, still no CI checks, no maintainer engagement.
The two new files in the diff are helios/src/runtime_core/mod.rs (+1) and helios/src/runtime_core/protection.rs (+1/−1); metrics/process.rs shrank +184 → +172.
2. Corrected: the cancelled-response blocker is fixed (it was the first blocker in the 22:00 review of my last report).
flare_request_e2e_seconds is now observed exactly once, inside the delivery generator, immediately before yield Delivery::Complete(response), guarded by if !count && !encoder.tool_limit_reached (helios/src/server/http.rs:598-606). Both former observation sites are gone (Delivery::Complete(_) => None at http.rs:621; the non-streaming arm at http.rs:635-644 now only maps the body), the cached metrics_handle() clone is gone in favour of state.model.metrics(), and disabled_parallel_calls_complete_http_and_stop_decoding now asserts flare_request_e2e_seconds_count 0 on the tool-limit path (phase_tests.rs:4604-4613). The tool-limit path was the only place HTTP cancelled a generation while still delivering a complete response (http.rs:471-476, :526, :563-567), so the documented promise that cancelled and failed requests appear only in the _cancelled_total/_failed_total counters (docs/api.md:315-316) holds again. The earlier "e2e is recorded as soon as the handler produces a response even if the body is dropped" asymmetry is now deliberate, documented, and pinned by a test.
3. Corrected: most of the documentation findings are resolved.
At the new head docs/api.md:287-321 fixes: the process_* exception to "Counter and gauge names start with flare_" (:288-290); "accumulate since server start" (:297); the split into "The HTTP histograms observe delivery" and "The runtime histograms observe completed generations" (:303, :309); the ≥2-generated-token eligibility of decode and time-per-output-token (:312-314); the stream-drain wording (:304-306); and the queue boundary named as model-scheduler arrival to the first model step, "which can be a vision step" (:309-312). The stale "The only histograms describe host prefix-store lookups" sentence is gone, so my earlier "undeclared doc repair" observation is moot and flare_host_cache_retirement_seconds is listed (:298-301).
Two doc inaccuracies remain, both smaller than before:
- "The HTTP histograms observe delivery" (:303) is still wrong for the non-streaming case — e2e is recorded before the response is returned, and
first_response_http_nonstream_records_only_when_completed_body_is_offeredpins count = 1 withpoll_body = false(phase_tests.rs:4461-4465). Only streams require a drain. - The vision note covers the queue boundary only;
first_scheduled_nsis stamped for every lane before theGraphKind::Visionsplit (runtime.rs:2191-2203vs:2208), so prefill also absorbs vision work, which the docs do not say.
4. New high-severity finding the new commit introduces: the helper reuse breaks a documented feature build on Linux.
helios/src/server/metrics/process.rs:63 calls crate::runtime_core::open_descriptors(), but runtime_core is declared #[cfg(feature = "runtime-core")] pub mod runtime_core; (helios/src/lib.rs:25-26) while server is independent (:28-29) and does not enable it (helios/Cargo.toml:25; default = [] at :17). A Linux build of helios with --features server and without runtime-core therefore references a module that is not compiled (E0433). That feature set is documented and used: docs/model-development.md:99-100 (--features server --lib frontend::, --features server --test message_boundaries) and docs/scheduling-runtime-design.md:735-737 (--features server --lib scheduler::, server::runtime::phase_tests::). No CI job covers it — native-serving always passes runtime-core,server (.github/workflows/native-serving.yml:63,68), flare/flare-cli always enable both (flare/Cargo.toml:23, flare-cli/Cargo.toml:27), helios-lifecycle runs cargo kani --lib with no features — and Windows is unaffected because the call is Linux-gated, so the break is Linux-only and invisible to the matrix. Before this commit the server module had no unconditional runtime_core reference (only #[cfg(feature = "runtime-core")] code in session.rs and runtime/prompt_tests.rs). Fixes are cheap: gate the call on the feature, gate the process module, or route the fd count through the crate::os surface, which already re-exports flare_eos (helios/src/os.rs:8).
The rest of the helper consolidation is an improvement and is what the review asked for: crate::os::page_size() (process.rs:56, eos/src/unix.rs:73-75), crate::os::raise_open_file_limit(0) (:65, eos/src/unix.rs:138-165), and the shared open_descriptors (runtime_core/protection.rs:291-302, newly pub(crate) and re-exported at runtime_core/mod.rs:58). ~12 hand-rolled lines in process.rs disappear.
5. New context: #548 is now a merge-order dependency and one of three same-author PRs.
- Issue #551 (WynnD, 2026-11-27 03:26, open, 0 comments) asks for llama.cpp-style
timingson final responses so llama-swap can show prompt/decode rates, and states explicitly that "Flare's Prometheus histograms cannot substitute: llama-swap parses proxied response bodies and does not scrape/metrics." The author has therefore written down that this PR's series do not serve that consumer. - PR #552 "Report request timings on final responses" (WynnD, draft, +929/−26, head
aea4147, closes #551) is stacked on #548: "This branch is stacked on #548, which adds the request-latency histograms and theRequestTimesstamps this PR reads… Merge #548 first." It makesRequestTimespub, addsDraftCounts, carries both onGenerationEvent::Finished, and rendersprompt_ms/predicted_ms/draft_nfrom exactly the stamps #548 added. A mis-anchored queue or prefill stamp therefore no longer stops at a scrape: it reaches the response body of a downstream PR. - PR #553 "Add vLLM-compatible per-request metrics" (WynnD, +302/−9, head
fd5c67e) adds an opt-in--enable-per-request-metricsvLLMmetricsobject; it claims no overlap with #548 but starts from the pre-#548http.rsshape, so it will conflict textually with the new e2e rearrangement. - WynnD's 04:56 comment on #548 says the three pushed PRs are "the per-request metrics PR is new; the other two carry review fixes", i.e. #548 is the one carrying review fixes.
Consequence for the recommendation: the value of #548 is now partly as a dependency (#552 cannot land without it), and the cost of its weakest part — the queue histogram anchored at runtime arrival rather than HTTP admission, which #536 asked for and which the description still does not disclose — is higher, because the same stamps will be rendered into client-visible timings.
6. Unchanged since the last report.
The description was not edited: it still omits the queue histogram's start point, still omits the tool-limit exclusion it now implements, still says "nothing about serving changes", still cites the two module subsets (109 + 20 passed) with no run on the new head, still says "CI covers the first two", and does not mention the runtime_core dependency or the helper refactor. The untouched review items remain: the unmeasured per-step clock read plus lane loop and the blocking procfs reads per scrape, converting the four host-cache histograms to Histogram<8> (two implementations still coexist), gating the module on target_os instead of the let _ = text shim, the maintainer-authorization question for #536, and the ~190-line permanent /metrics growth with no opt-out. Windows still gets no process_* series (docs/api.md:318-321). No CI check has run on d64c3ea and no reviewer or maintainer has engaged with any of #536, #537, #548, #549, #551, #552 or #553.
#24 [high] AMENDMENT (2026-11-27b): head a34c4d0 closes 2 review nits, introduces a parser fix, build break persists
PR #548 head moved d64c3ea -> a34c4d060f96553c490eceb44b2fcf09ed277098 ("Hoist completion values and tighten stat parsing", WynnD, 2026-11-26 20:24-ish, pushed before the 04:56 re-review request). Size: +548/-25 in 10 files (was +550/-20); pr_files now reports process.rs +177, runtime.rs +43/-13, metrics.rs +219, latency.rs +24/-8. Still draft, still zero human reviews, no CI checks recorded.
WHAT THE COMMIT DOES (four hunks, all verified):
-
latency.rs: an
impl FirstResponseSamplesblock that sat afterstruct FirstResponse(latency.rs:127-131 in the old head) is moved up beside the struct's own impl (newrender_histogramat latency.rs:101-109). Pure code motion, no behaviour change. This is item "the separate impl block" from the 22:00 review's nit list, so one nit is closed. -
metrics/process.rs:
parse_stattightened. It now consumes the state character as the first tail token and rejects the line unless that character is in "RSDZTtWXxKPI" (process.rs:24-29), and theutimeskip drops from 11 to 10 (process.rs:31-32). Verified correct against proc(5): after the last)the first token is field 3 (state), so token k = field k+2, and afields.nth(n)afternext()consumes n+2 more tokens, i.e. field n+4. nth(10) -> field 14 = utime(P) ✓; nth(0) -> field 4 = ppid... wait, careful: nth(0) consumes 1 token = field 4 (ppid)?? No: afternext()(field 3), nth(0) consumes 1 more token = field 4 = ppid, not stime. Let me redo: value(|) is called successively, and each closure call consumes. Sequence: next() consumes field 3. value(10): nth(10) consumes fields 4..14 = 11 tokens, lands on field 14 = utime ✓ (21st field = token 19, so 19-14 = 5 tokens left, consistent). value(0): nth(0) consumes field 15 = stime ✓. value(6): consumes fields 16..22... but stat has only 21 fields, so starttime would be missing -- yet the unit test passes [11,12,19,20,21]. The test input is a fabricated 21-token line, not real procfs, so the arithmetic after utime is unverified against the kernel. This deserves an amendment line: the test string "42 (a) b) S 1 2 ... 21" supplies numbers 1..21 which are exactly the token positions, so the assertion Some([11,12,19,20,21]) only proves the "token value == token index" coincidence, not correct field mapping. Also the state validation makes the42 (no tail)case still None, correct. -
metrics.rs test: the second half of
request_histograms_bucket_completed_request_timingsnow usesRequestTimes::default()andgenerated_tokens = 0instead of the impossible{first_scheduled_ns: None, first_token_ns: Some(...)}+ 1 token state, and re-pins queue/prefill/decode_count 1, prompt_tokens_count 2, completed_total 2. This is the "impossible {None, Some} test state" nit from the 22:00 review, closed. It also, incidentally, pins that a zero-token completion contributes only a prompt-size observation -- which is a real semantic (a request that stops before any token) that the docs still do not describe. -
runtime.rs: hoists the two completion expressions into locals at the natural-finish site (runtime.rs:1993-2001), matching what Worker::complete already did (:1837-1845). Equivalent to the previous inline copy in request_completed and the Finished event; no behaviour change. This closes the "two expressions not hoisted" nit. But NOTE: the hoist leaves
prompt_tokens/generated_tokensshadowing the earlier frame locals and reuses them in theGenerationEvent::Finishedemit at :2018-2025, i.e. correct but the diff is now a 4-line duplication of the identical pattern in two functions instead of one, so the "extract a helper" suggestion would shrink it.
NEW HEAD STILL CARRIES the high finding from my last amendment, unchanged: process.rs:68 crate::runtime_core::open_descriptors() under #[cfg(target_os = "linux")] only, while runtime_core is #[cfg(feature = "runtime-core")] (helios/src/lib.rs:25-26) and server does not enable it (helios/Cargo.toml:25). Documented --features server Linux commands still break: docs/model-development.md:99-100 and docs/scheduling-runtime-design.md:735-736. No CI job passes --features server alone: native-serving.yml:63,68 pass runtime-core,server on both Linux and Windows. So the new commit lowered the count of the two named blockers from 2 to ... actually it did not touch blocker 2 (evidence overstatement) at all.
AMBIGUITY I MUST FLAG: the 06:15 autobot review says "most of the previous round is fixed" and still lists 2 blockers / 3 should-fix / 5 subtractive / 6 nits, but it was posted 2026-11-27 06:15 against a head that includes a34c4d0 (the diff in the review's own 22:00 predecessor cites the pre-a34c4d0 line numbers, e.g. runtime.rs:2187-2203 for the stamp, while the new head has it at :2190-2204). The two newest nits it names -- hoisting and parse_stat accepting any line with ) -- are exactly what a34c4d0 addresses, so the review either was generated from the partial update or is now partly stale. Either way the review's blocker set (e2e cancellation, evidence overstatement) is NOT refuted by a34c4d0: e2e cancellation was already fixed at d64c3ea, and evidence overstatement is untouched.
#536 asked for flare_request_queue_seconds: "admission to first scheduled step" (issue #536, Proposal bullet 2). The PR anchors it at runtime arrival (runtime.rs:183 arrival_ns, :901 set at runtime admission) and docs/api.md:309-311 now say "model-scheduler arrival", i.e. the PR silently narrows the requested metric and the description never says so. Unchanged by a34c4d0.
#25 [high] AMENDMENT TEXT (2026-11-27b): amendments to append, worded — head a34c4d0
Amendments to the 2026-11-27 report (head d64c3ea -> a34c4d0)
1. Head moved again. d64c3ea -> a34c4d0 "Hoist completion values and tighten stat parsing". Size +548/−25 in the same 10 files (was +550/−20). Still draft, still no CI check on the head, still no human reviewer and no maintainer engagement anywhere in the cluster (#536, #537, #548, #549, #551, #552, #553). The only comments are three from flare-autobot and one from the author. My earlier note "zero comments" is superseded only in the sense that bot comments now exist; the human-review count is still zero.
2. Correction to my last amendment: the runtime_core build break is NOT new to this cluster's later commits, but it is not fixed either.
Unchanged at a34c4d0: helios/src/server/metrics/process.rs:68 calls crate::runtime_core::open_descriptors() while process is only #[cfg(target_os = "linux")]-gated inside the module, runtime_core is #[cfg(feature = "runtime-core")] pub mod runtime_core; (helios/src/lib.rs:25-26), and the server feature does not enable runtime-core (helios/Cargo.toml:25, default = [] at :17). The two documented Linux commands that pass --features server alone still fail to compile: docs/model-development.md:99-100 and docs/scheduling-runtime-design.md:735-736 (--lib scheduler::, --lib server::runtime::phase_tests::). CI still cannot see it: .github/workflows/native-serving.yml:63,68 pass runtime-core,server on both Linux and Windows. a34c4d0 did not touch process.rs's helper call, so the finding stands exactly as reported.
3. New: three review nits are now closed, and all three hunks are behaviour-preserving.
- latency.rs — the stray second
impl FirstResponseSamplesblock that sat afterstruct FirstResponseis folded into the struct's main impl (helios/src/server/latency.rs:101-108). Pure code motion;render_histogramkeeps its signature and call site (helios/src/server.rs:671). - runtime.rs — the two completion expressions are hoisted into locals at the natural-finish site (
helios/src/server/runtime.rs:1993-2001) and reused by theGenerationEvent::Finishedemit (:2018-2019), matching whatWorker::completealready did (:1838-1840,:1850-1851). Values are identical to the previous inline copies; no semantic change. It is now two copies of the same 3-line pattern rather than one, so the "extract a helper" suggestion would still shrink the diff. - metrics.rs — the test's second half replaces the impossible
RequestTimes { first_scheduled_ns: None, first_token_ns: Some(..) }+ 1-token state withRequestTimes::default()+ 0 generated tokens (helios/src/server/metrics.rs:1683). Sensible: that state is unreachable in production becausefirst_token_nsis only stamped on a committed token, which implies a scheduled step.
This lowers my count of outstanding review items but leaves the two things that actually gate merge: the description evidence and the process-module feature gate.
4. New medium finding the hoist exposes: the docs do not describe a zero-generated-token completion, and the new test now pins that case.
Metrics::request_completed observes flare_request_prompt_tokens unconditionally and only observes queue/prefill when first_scheduled_ns is set, decode and time-per-output-token only when first_token_ns is set and generated_tokens > 1 (helios/src/server/metrics.rs:459-479). The rewritten test now pins exactly that shape: after request_completed(1_000_000_000, RequestTimes::default(), 3000, 0) the queue, prefill and decode counts stay at 1 and only flare_request_prompt_tokens_count rises to 2 (metrics.rs:1683-1690). docs/api.md:309-316 says the runtime histograms "observe completed generations" and names the ≥2-token rule for decode, but never says that a completion which generates no token still counts in flare_requests_completed_total and flare_request_prompt_tokens while contributing to none of the other five. One clause, and it matters for anyone dividing _count by flare_requests_completed_total to get a completeness ratio — that ratio is legitimately below 1.
5. New: the parse_stat hardening is a real improvement, but the accompanying test cannot catch a field-mapping error.
The commit adds a state-character check: after the last ), the first tail token must start with one of RSDZTtWXxKPI, else the parser returns None (helios/src/server/metrics/process.rs:24-28), and the utime skip drops from 11 to 10 (:31). Verified correct against proc(5): the tail token list starts at field 3, so the fields.nth(n) chain after one next() resolves to utime = field 14 (P), stime = 15, starttime = 22 (starttime is computed as starttime_ticks + btime, :104-111). So the values emitted are right.
The test does not prove that, though. Its fixture is "42 (a) b) S 1 2 3 ... 21", i.e. the token values are the token positions, so the assertion Some([11, 12, 19, 20, 21]) is satisfied by any consistent off-by-N as long as the parser stays positionally ordered — a shift of the utime index from 10 to 9 or 11 would still yield the same coincidental shape only if the numbers were chosen independently. Distinct, non-sequential fixture values would pin the mapping. Worth noting because the commit message advertises tightened parsing and the reject path is the only part genuinely tightened; the prev-head parser accepted any line containing ), which the new check now correctly rejects (42 (no tail) still yields None).
Also unchanged and still unexercised as a failure path: the six if let (Some(..), Some(..)) fallbacks (process.rs:72-131) cannot fail on a live Linux kernel, and the only test asserting real kernel values is render_reports_process_memory_descriptors_and_start_time (process.rs:150-177).
6. New: the 06:15 autobot review is already partly stale against the head it was posted on.
Posted 2026-11-27 06:15, i.e. after the author's 04:56 "review the pushed changes" and after a34c4d0 was pushed. It repeats "Changes Requested — the design is right … most of the previous round is fixed", with 2 blockers / 3 should-fix / 5 subtractive / 6 nits, and its own predecessor (22:00) cites pre-a34c4d0 line numbers (runtime.rs:2187-2203 for the stamp, now :2189-2202). Two of the six nits it names — "two expressions in Worker::publish not hoisted as complete does" and "parse_stat accepting any line with )" — are precisely what a34c4d0 fixes. So the review text under-describes the head by two items.
What survives from that review is what I independently confirmed: the description-level evidence problem ("nothing about serving changes" is still in the description verbatim, and the per-request e2e block was addressed at d64c3ea), the vision-stamp ambiguity in the prefill histogram, the host-cache Histogram<8> simplification, the #[cfg]-the-module suggestion, and the maintainer-authorization question. Nothing in it is a new defect I had not already logged; its one genuinely new item relative to my notes is the observation that the scrape deltas are 6 TTFR vs 5 runtime observations, which the author explains in the description as the instance also serving the agent session's own traffic — a confound the description states but does not resolve.
7. Unchanged.
The description still does not disclose that flare_request_queue_seconds starts at runtime arrival (runtime.rs:183, :901) rather than HTTP admission as #536 asked ("admission to first scheduled step", issue #536 Proposal bullet 2), even though docs/api.md:309-311 now says "model-scheduler arrival". #552 remains stacked on this PR and renders those same stamps into a client-visible timings object, so the undisclosed anchor propagates. Windows still receives no process_* series (docs/api.md:318-321). The /metrics body still grows ~190 lines permanently with no opt-out, and the per-step clock read plus lane loop (runtime.rs:2189-2202) and per-token stores are still unmeasured.
8. Bottom line for the amendment.
a34c4d0 is housekeeping: three nits closed, no behaviour change, no test-count growth, no description update, no CI run. It does not move the two merge gates. The one substantive code regression in the PR — the --features server Linux build break from d64c3ea — is still there, and the one substantive evidence problem — a description claiming "nothing about serving changes" and "CI covers the first two" — is still there. My recommendation is unchanged (Changes Requested), with the amendment that the review now to hand (06:15) is itself stale on two of its own nits.
#26 [high] AMENDMENT TEXT (FINAL, 2026-11-27b): supersedes #25 — head a34c4d0
SUPERSEDES entry #25 (and the garbled derivation inside entry #24). Entries #24 and #25 each contain an arithmetic error in the parse_stat section; the corrected analysis is section 5 below. Everything else in #25 stands.
Amendments to the 2026-11-27 report (head d64c3ea -> a34c4d0)
1. Head moved again. d64c3ea -> a34c4d0 "Hoist completion values and tighten stat parsing". Size +548/−25 in the same 10 files (was +550/−20). Still draft; no CI check has run on it; no human reviewer has engaged anywhere in the cluster (#536, #537, #548, #549, #551, #552, #553). The only discussion is three flare-autobot posts and one author post.
2. Correction to my last amendment — I over-claimed on this point, and the correction matters for triage.
My 2026-11-27 amendment described the --features server Linux build break as something "the same commit introduces". The gate is real and still open, but it is not this commit's doing and should not be attributed to a34c4d0:
helios/src/server/metrics/process.rs:68callscrate::runtime_core::open_descriptors()insiderender_linux.runtime_coreis#[cfg(feature = "runtime-core")] pub mod runtime_core;(helios/src/lib.rs:25-26), whileserveris gated independently (:28-29) and does not pull inruntime-core(helios/Cargo.toml:25;default = []at :17).- The documented Linux commands that pass
--features serveralone therefore fail to compile:docs/model-development.md:99-100, anddocs/scheduling-runtime-design.md:735-736(--lib scheduler::,--lib server::runtime::phase_tests::). - CI cannot detect it:
.github/workflows/native-serving.yml:63,68passruntime-core,serveron both Linux and Windows; no job passesserveralone.
a34c4d0 did not touch that call, so the finding is unchanged in substance. What I am correcting is the attribution: it arrived with the helper-reuse commit d64c3ea, and it survives a34c4d0. Fix is still one line — gate the call, gate the process module on the feature, or route the fd count through the crate::os surface, which already re-exports flare_eos (helios/src/os.rs:8).
3. New: three review nits are closed, and all four hunks are behaviour-preserving.
- latency.rs — the stray second
impl FirstResponseSamplesblock that sat afterstruct FirstResponseis folded into the struct's main impl (helios/src/server/latency.rs:101-108). Pure code motion;render_histogramkeeps its signature and its single call site (helios/src/server.rs:671). - runtime.rs — the two completion expressions are hoisted into locals at the natural-finish site (
helios/src/server/runtime.rs:1993-2001) and reused by theGenerationEvent::Finishedemit (:2018-2019), matching whatWorker::completealready did (:1838-1840,:1850-1851). Values are identical to the previous inline copies; no semantic change. It is now two copies of the same 3-line pattern in two functions rather than one, so an extracted helper would still shrink the diff. - metrics.rs — the test's second half replaces the impossible
RequestTimes { first_scheduled_ns: None, first_token_ns: Some(..) }+ 1-token state withRequestTimes::default()+ 0 generated tokens (helios/src/server/metrics.rs:1683). Sensible: that state is unreachable in production, becausefirst_token_nsis only stamped on a committed token and a committed token implies a scheduled step.
Net effect: the count of outstanding review nits drops, but the two things that gate merge do not move.
4. New medium finding: the docs do not describe a zero-generated-token completion, and the rewritten test now pins that case.
Metrics::request_completed increments flare_requests_completed_total and observes flare_request_prompt_tokens unconditionally; queue and prefill are observed only when first_scheduled_ns is set; decode and time-per-output-token only when first_token_ns is set and generated_tokens > 1 (helios/src/server/metrics.rs:459-479). The rewritten test now pins exactly that shape — after request_completed(1_000_000_000, RequestTimes::default(), 3000, 0) the queue, prefill and decode counts stay at 1 and only flare_request_prompt_tokens_count rises to 2 (metrics.rs:1683-1690).
docs/api.md:309-316 says the runtime histograms "observe completed generations" and states the ≥2-token rule for decode, but never says that a completion generating no token still counts in flare_requests_completed_total and flare_request_prompt_tokens while contributing to none of the other five. That matters operationally: anyone computing flare_request_prefill_seconds_count / flare_requests_completed_total to get an instrumentation-completeness ratio will legitimately see it below 1, with no documented explanation. One clause fixes it.
5. CORRECTED: the parse_stat change is correct, and its test does pin the field mapping.
The commit adds a state-character check — after the last ), the first tail token must start with one of RSDZTtWXxKPI, else the parser returns None (helios/src/server/metrics/process.rs:24-28) — and drops the utime skip from 11 to 10 (:31).
Derivation, verified against proc(5) field numbering: after the last ), the first tail token is field 3 (state), so tail token i is field i+3. The fields.next() that performs the state check consumes tail token 0 (field 3). Then each value(n) is fields.nth(n), which skips n and returns one, i.e. consumes n+1 tokens:
value(10)→ tail token 11 → field 14 = utime ✓value(0)→ tail token 12 → field 15 = stime ✓value(6)→ tail token 19 → field 22 = starttime ✓ (rendered asbtime + starttime_ticksat:104-111)value(0)→ tail token 20 → field 23 = vsize ✓value(0)→ tail token 21 → field 24 = rss ✓
All five correct. The fixture "42 (a) b) S 1 2 3 ... 21" supplies distinct sequential values whose magnitude equals their tail-token index, so the assertion Some([11, 12, 19, 20, 21]) genuinely pins the mapping — an off-by-one in any index yields different numbers and fails. My earlier note claiming this test cannot catch a mapping error was wrong; the fixture is adequate. The reject path is also a real improvement: the previous head accepted any line containing ), while 42 (no tail) now correctly returns None.
The one residual concern is a new failure mode the check introduces, and it is small but worth a line: the module's stated principle is that "a source that cannot be read or parsed omits only the metrics that depend on it." Because every stat-derived series shares this one parse, a kernel state character outside the hard-coded set — RSDZTtWXxKPI covers the documented R/S/D/Z/T/t/X/x/I plus the legacy W/K/P — would silently drop process_cpu_seconds_total, process_resident_memory_bytes, process_virtual_memory_bytes and process_start_time_seconds together, leaving only process_open_fds and process_max_fds. Substring matching on one character is also cheerfully permissive (any token starting with X, e.g. a 64-bit-clean marker, passes). Low severity: the current set covers every state in modern proc(5).
Separately, still unexercised as a failure path: the six if let (Some(..), Some(..)) fallbacks (process.rs:72-125) cannot fire on a live Linux kernel, and the only test asserting live kernel values is render_reports_process_memory_descriptors_and_start_time (process.rs:150-177).
6. New: the 06:15 autobot review is already partly stale against the head it was posted on.
Posted 2026-11-27 06:15 — after the author's 04:56 "review the pushed changes" and after a34c4d0 was pushed — it repeats "Changes Requested … most of the previous round is fixed" with 2 blockers / 3 should-fix / 5 subtractive / 6 nits. Its own predecessor (22:00) cites pre-a34c4d0 line numbers (e.g. runtime.rs:2187-2203 for the stamp, now :2189-2202), and two of the six nits it names are exactly what a34c4d0 fixed: "two expressions in Worker::publish not hoisted as complete does" and "parse_stat accepting any line with )". So the review under-describes the head by two items.
What survives from it is what I independently confirm: the description-level evidence problem, the vision-stamp ambiguity in the prefill histogram, the host-cache Histogram<8> simplification, the #[cfg]-the-module suggestion, and the maintainer-authorization question. Nothing in it is a defect I had not already logged. Its one genuinely new observation is that the live-scrape deltas are 6 TTFR observations against 5 runtime observations; the description attributes the excess to the instance also serving the agent's own session traffic, which states the confound but does not resolve it.
Note also that the review reports "2 blockers" and its blocker list still leads with the e2e cancellation issue, which the author fixed at d64c3ea (helios/src/server/http.rs:598-606, pinned at phase_tests.rs:4604-4613). So the outstanding blocker tally in that posted review is one higher than my own.
7. Unchanged and still the two merge gates.
- The description still does not disclose that
flare_request_queue_secondsstarts at runtime arrival (runtime.rs:183,:901) rather than HTTP admission as #536 asked ("admission to first scheduled step", #536 Proposal bullet 2), even thoughdocs/api.md:309-311now says "model-scheduler arrival". #552 remains stacked on this PR and renders those same stamps into a client-visibletimingsobject, so the undisclosed anchor propagates beyond a scrape. - The description still says "nothing about serving changes", still asserts "CI covers the first two" with no CI run on any head, still omits the tool-limit exclusion it implements, and still omits the
runtime_coredependency and the helper refactor. - Windows still receives no
process_*series (docs/api.md:318-321). The/metricsbody still grows ~190 lines permanently with no opt-out. The per-step clock read plus lane loop (runtime.rs:2189-2202) and the per-token stores remain unmeasured;a34c4d0neither added nor removed cost on the hot path (the hoist is value-neutral, the parser runs only per text scrape).
8. Bottom line.
a34c4d0 is housekeeping: three nits closed, no behaviour change, no new tests, no description update, no CI run, size roughly flat (+548/−25 vs +550/−20). It does not move either merge gate. My recommendation stands at Changes Requested, narrowed to: (a) the --features server Linux build break at process.rs:68, inherited from d64c3ea; (b) the description's evidence claims, which no commit has touched. The two doc-level items I would still raise in review are the missing zero-token completion clause (§4) and the non-streaming "observe delivery" overstatement already logged. Everything else in the PR is sound, and the parser change is correct.
#27 [high] Research summary
Amended. The new event is one commit, a34c4d0 "Hoist completion values and tighten stat parsing", taking #548 from d64c3ea to +548/−25 in the same 10 files. It is housekeeping: three review nits closed (the stray impl block folded into the struct's impl in latency.rs:101-108, the completion expressions hoisted in runtime.rs:1993-2001, and the impossible {None, Some} test state replaced with RequestTimes::default() + 0 tokens in metrics.rs:1683), all behaviour-preserving. The PR is still draft, no CI has run on the head, and no human has reviewed it or engaged with any item in the cluster.
Two findings from the previous report are corrected or refined. I re-derived the parse_stat field arithmetic against proc(5) — utime is field 14, stime 15, starttime 22, vsize 23, rss 24 — and the parser is correct, with the test fixture adequate to pin the mapping; my earlier suspicion of a mapping bug was an arithmetic slip of my own, now corrected on the scratchpad. I also corrected the attribution of the outstanding --features server Linux build break (process.rs:68 calling a feature-gated runtime_core): it is real and still open, but it arrived with d64c3ea, not with this commit.
Genuinely new material: the rewritten test newly pins that a zero-generated-token completion still increments flare_requests_completed_total and flare_request_prompt_tokens while contributing to none of the other five histograms, a semantic the docs never state — relevant to anyone computing an instrumentation-completeness ratio. And the 06:15 Autobot review is already partly stale against the head it was posted on: two of the six nits it lists are exactly what a34c4d0 fixed, and its blocker tally retains the e2e cancellation item fixed at d64c3ea. Recommendation is unchanged at Changes Requested, narrowed to the build break and the untouched description evidence claims. The deliverable amendment prose is scratchpad entry #26, which supersedes #25 and corrects #24.
#28 [high] Verified-at-head fact sheet for a34c4d0 (citations the report should use)
PR #548 head a34c4d060f96553c490eceb44b2fcf09ed277098, +548/−25, 10 files, draft. Verified this turn by reading the head directly.
SIZE AND FILES (pr_files) docs/api.md +28/−3 · helios/src/runtime_core/mod.rs +1/−0 · helios/src/runtime_core/protection.rs +1/−1 · helios/src/server.rs +2/−0 · helios/src/server/http.rs +8/−0 · helios/src/server/latency.rs +24/−8 · helios/src/server/metrics.rs +219/−0 · helios/src/server/metrics/process.rs +177/−0 (new, 178 lines total) · helios/src/server/runtime.rs +43/−13 · helios/src/server/runtime/phase_tests.rs +45/−0
COMMITS (search_history) a34c4d06 "Hoist completion values and tighten stat parsing" · d64c3ea3 "Exclude cancelled responses and reuse host helpers" · ebecef13 "Add request latency histograms and process metrics"
THE NEW COMMIT, HUNK BY HUNK
- latency.rs:101-108 —
render_histogramnow lives in the mainimpl FirstResponseSamplesblock (block that previously sat afterstruct FirstResponse); body unchanged, renders "time_to_first_response_seconds" againstsuper::metrics::REQUEST_SECONDS. Call site server.rs:671. - runtime.rs:1993-2001 —
prompt_tokens = request.carried.prompt_tokens.unwrap_or(prompt_tokens),generated_tokens = request.carried.generated_tokens + generated, thenmetrics.request_completed(request.incoming.arrival_ns, request.incoming.times, prompt_tokens, generated_tokens); the same two locals feedGenerationEvent::Finishedat :2018-2019. Mirrors the pre-existing pattern at :1838-1845 / :1850-1851. Value-identical to the previous inline expressions. - metrics.rs:1683 — test line now
metrics.request_completed(1_000_000_000, RequestTimes::default(), 3000, 0);replacing the{first_scheduled_ns: None, first_token_ns: Some(2_000_000_000), last_token_ns: 2_500_000_000}+ 1-token construction; assertions at :1685-1696 pin queue/prefill/decode_count 1, prompt_tokens_count 2,flare_requests_completed_total 2. - process.rs:24-32 — state-char check
"RSDZTtWXxKPI".contains(state)on the first token after the last), returning None otherwise;utimeskip 11 → 10.
PARSER ARITHMETIC (correct; verified against proc(5))
Tail token i = field i+3. After fields.next() (field 3), each value(n) consumes n+1 tokens: value(10)→utime=f14, value(0)→stime=f15, value(6)→starttime=f22, value(0)→vsize=f23, value(0)→rss=f24. Renderer uses btime + starttime/ticks at process.rs:104-111. Test fixture "42 (a) b) S 1 2 … 21" → Some([11,12,19,20,21]) at process.rs:141-148 pins the mapping because values are distinct (earlier doubt retracted).
HISTOGRAM SEMANTICS (unchanged)
Metrics::request_completed, metrics.rs:452-480: completed++ and prompt-token observe unconditional; queue needs first_scheduled_ns; prefill additionally first_token_ns; decode and time-per-output-token need first_token_ns and generated_tokens > 1. Field types metrics.rs:308-331 (request_e2e Histogram<21> at :327). Render for decode/time-per-output-token at :1406-1415. RequestTimes definition metrics.rs:300-306.
GATING AND COST
process.rs:9-15 render shim (let _ = text off Linux), render_linux :56-126, open_descriptors call :68, raise_open_file_limit(0) :70, if let fallbacks :72-125, tests :128-177. metrics.rs:12 pub(super) mod process; (no cfg). server.rs:706-709 calls metrics::process::render. lib.rs:22-29: server and runtime_core gated independently; Cargo.toml:25 server does not enable runtime-core, :17 default = []. server.rs:26-29 is the only cfg-gated server module (session). helios/src/os.rs:8 pub(crate) use flare_eos::*;.
HTTP / e2e
http.rs:598-606 single guarded observation (!count && !encoder.tool_limit_reached) before yield Delivery::Complete(response); :621 Delivery::Complete(_) => None; :635-644 non-streaming arm only maps the body. Pinned at phase_tests.rs:4604-4613 (tool-limit → count 0), :4461-4465 (non-streaming records with poll_body=false), :5395-5399 (route test, process_resident_memory_bytes present).
DOCS AT HEAD
docs/api.md:287-290 naming exception for process_*; :297 "accumulate since server start"; :303-307 HTTP group incl. stream-drain clause; :309-316 runtime group, queue = "model-scheduler arrival … which can be a vision step", ≥2-token rule, cancelled/failed exclusion; :318-321 Linux-only process series. Documented --features server-only Linux commands: docs/model-development.md:99-100, docs/scheduling-runtime-design.md:735-736. CI passes only runtime-core,server: .github/workflows/native-serving.yml:63,68.
#11 [medium] Recent activity: nothing recent on main conflicts; metrics.rs has 3 open PRs
- Last commits on the default branch in the touched areas: helios/src — ba35da3f (#538 cold pure-prefill), c915b5f0 (#532 16-SM alignment), c36a6a02 (#527 Latent576 page-split codec), 225758fe (#525 kv-codec parallel), e685a975 (#529 GB300 PCI id), 3d8640c6 (#523 kv-codec verify), e30d55db (#522 GPU confidence calibration), 716df00f (#504 KV compression). docs — 698ee450 (#545 RecipeParameters), f377dc85 (#543 remove joint kernel tuning), ba35da3f (#538), 33ab6df5 (#508 row-sharded attention), 28bd5047 (#531 publisher keys). None of these touch metrics, latency or
/metrics; the orientation packet also says no default-branch commit since the branch point (f377dc8) touches any file this PR changes. So the change builds on nothing recent and conflicts with nothing recent on main. - The most recent metrics-area commit is f646bebc (2026-11-24, Luke Alonso, #507) — persistent worker counter schema, Prometheus metrics, /v1/worker telemetry, launch dashboard view, parallax CLI. That is the function next to which the new histograms are inserted; it is also the commit that created the live-scrape cherry-pick conflict the author describes. #507 is merged, so #548 layers on top of it cleanly on main.
- Sibling in-flight work in the same file: #549 (WynnD, same day), #542 (FujitsuPolycom, "single-phase TP dispatch, x86_64 wake wait, intermediate batch capacities, and PreparedAllToAll") also lists
helios/src/server/metrics.rsas touched; #334 (javieratomic, Engram rows ahead of prefill) also touches it. So metrics.rs has two other open PRs plus #548 in flight — a three-way textual-overlap risk that the PR description addresses only for #549. - Prior art in the same file that the change does not unify with: the host-cache histograms (
flare_host_cache_missing_tokens,estimated_transfer_ns,estimated_prefill_ns,retirement_seconds) use[AtomicU64; 8]+flare_selene::RETIREMENT_LATENCY_MSand emit bucket bounds divided by 1000 at render time (metrics.rs:851-876). A reviewer may ask whether the new genericBuckets/Histogramshould replace them; the PR deliberately leaves them alone (no diff in that region).
#14 [medium] Why (continued): #537 sibling gap, demand age, and the only pre-existing signals
- Issue #537 (Napuh, 2026-11-26 09:07, open, 0 comments, env v0.3.2
c0c4f79) is the sibling gap: vLLM'svllm:kv_cache_usage_perccannot be computed from Flare's gauges because pages pinned by active requests still count asflare_cached_kv_pages. It reports three attempted bounds on the same two-GPU load:1 - free/totalvery high % even idle;1 - (free+cached+snapshot_backing)/total~0 % (lower bound);1 - (free+snapshot_backing)/total~16 % (upper bound); vLLM ~9 %. It proposesflare_request_kv_pagesor splitting cached into pinned/idle. Closed by #549, not by #548. - Relevance to #548: the PR description cross-references it ("This PR and #537 add different regions of
helios/src/server/metrics.rs"), and #549's description repeats the same claim in reverse ("page gauges besidecached_pageshere, request histograms beside the completion counter there. They merge in either order"). Verified plausible from the two diffs: #549 changesMetricsnear cached/free page fields plusSchedulerStats/cache.rs/scheduler.rs, #548 changes it besidecompletedplus runtime.rs/http.rs/latency.rs; both edit docs/api.md in different paragraphs. Same author, same day, so they are effectively a two-PR series closing #536+#537 together. - Demand age and width: both issues and both PRs appeared within about twelve hours of each other on 2026-11-26, from two accounts with no prior merged work in the 180-day window. Nothing in the repo's older history records a prior request for request histograms (searches for
histogram,p95/p99,vLLM parity,time to first tokenreturn only #536/#548/#549/#541 and unrelated issues). The one adjacent older signal is issue #78 (open, DS4.1 Flash disk Engram), which asks in passing whether "per-gather latency/miss-count histograms and explicit metric scope/rank labels" would be useful — a different subsystem. docs/TODO.txt:110-124 separately carries a standing TODO to "Measure cross-host rank handoff ... request p99 ..." and "Qualify retained graph costs ... request latency measurements; measure GPU replay, queueing, and host planning separately", which is the closest thing to a pre-existing project want in this area.
#15 [medium] Process: draft with no CI on head; description meets the repo's four-part rule
- State at review time: draft, base
main, headebecef1, branched fromf377dc8, 8 files +545/−20, labels none, reviews none, inline comments none, no CI checks on the head commit, opened and last updated 2026-11-26 (same day, so under a day old when examined).pr_commentsreturns "No comments". - Because no workflow has run, the
native-servingmatrix (ubuntu-24.04 + windows-2022,cargo test --release --features runtime-core,serverfor helios, plusflare-cli,flare,eos,selene,selene-manager) has produced no result for this head. The author's "CI covers the first two" refers to what that matrix would do, not to a run. - The description follows the repo's mandatory four-part shape from AGENTS.md:72-112 (why / what changed / claimed result / evidence), states "Not run here: the Windows build; the full helios suite; and
messages_image_hints_end_after_expansion_for_text_and_segmented_templates", and carries the requiredDiscord: oystersmilesline (AGENTS.md:142-153). Both issues (#536, #537) also carry Discord lines. - Merge logistics: no rebase or stacking dependency is declared against main. The
5ffe4d54cherry-pick story in the evidence section concerns reproducing the live scrape on a fork base, not the merge target; on main the surrounding persistent-worker code from #507 (f646bebc) is present and untouched by the diff. - Reviewer queue notes: the same file is claimed by #542 (FujitsuPolycom) and #334 (javieratomic), so whichever lands first sets the context for the others; #548's description only reasons about #549's overlap.
#20 [medium] AMENDMENT (2026-11-27): review scorecard at head d64c3ea
State at the time of this amendment (2026-11-27):
- #548 head
d64c3ea(+550/-20, 10 files), still draft, still zero reviews and zero substantive comments. The only comments are the autobot intake note (2026-11-26 20:56), the autobot review (2026-11-26 22:00, "Changes Requested") and WynnD's re-review request (2026-11-27 04:56, "@flare-autobot review the pushed changes. The per-request metrics PR is new; the other two carry review fixes."). - No CI checks on
d64c3eain the local record (same asebecef1); the description's evidence section was not updated, and no new test counts are reported. - CI coverage of the touched area, verified:
native-servingbuilds/tests helios on ubuntu-24.04 and windows-2022 with--features runtime-core,serverandFLARE_TEST_TEMPLATE_DIRfromtests/frontend/prepare_templates.py(.github/workflows/native-serving.yml:43-68);helios-lifecycleruns a TLA+ conformance check andcargo kani --libwithout features. Neither would catch a--features server-only Linux build break (see note on the runtime_core dependency). - Review posture for the amendment: blocker 1 of the 22:00 review is addressed (with a test), the eos/ helper consolidation asked for under "Should fix" was done, and the docs "Should fix" items were mostly done. Not addressed: the evidence/description blocker, the
Metrics-side simplification (single observation point is now done, buttime_to_first_responsestill lives onFirstResponseSampleswith its ownrender_histogram), the host-cacheHistogram<8>conversion, the#[cfg(target_os = "linux")]module gating, the maintainer-authorization question, and the per-step cost measurement. Line count went up, not down (+550 vs +545).
#29 [medium] Leads examined and dismissed this turn (record so the report does not re-open them)
Each of these was checked this turn and found NOT to warrant a report finding; recorded so the report either omits them or says briefly that they were checked.
-
FORMATTING/LINT GATE — none.
cargo fmt/rustfmt/clippyappear nowhere in.github/workflows/(search returned no matches), and there is norustfmt.tomlormax_widthsetting in the repo. So the new over-long line in the state check (process.rs:26, ~100 chars) and any rustfmt drift cannot fail CI and is not worth a review comment. Note separately thatselene-manager/docs/qualification.md:39documentsclippy … -D warningsas a manual qualification step only. -
WINDOWS — unaffected by the build break, and this is a real asymmetry rather than a separate bug.
open_descriptors()is only called insiderender_linux(process.rs:56-126), which is#[cfg(target_os = "linux")]; on Windowsrenderis a no-op (let _ = text, ::11-15) and emits nothing. So the--features server-only break is Linux-only, which is also why the Windows half of the CI matrix at native-serving.yml:68 stays green. -
MERGE OVERLAP — no new conflict partner.
items_touching("helios/src/server/metrics")returns #548, #552 and #540 only. #540 (FujitsuPolycom) toucheshelios/src/server/metrics/scheduler.rs, a different file frommetrics.rsandmetrics/process.rs, so it is not a textual conflict and needs no mention.related_items(548)shows #552 sharing 8 files (all of them except the two runtime_core files) — the stacked-PR point already recorded — and #549 sharing only docs/api.md, metrics.rs and runtime.rs, consistent with the earlier "merges in either order" claim. -
NO NEW ITEMS IN THE CLUSTER.
search_items("metrics histograms process")returns only #548, #536 and #541. Issue #551, PRs #552/#553 and the author's 04:56 comment were already recorded; nothing has been opened or commented on since the 06:15 bot review. So there is no new human engagement to report — the "no maintainer has engaged" finding stands as written. -
AUTHOR'S 04:56 COMMENT was re-read and is not a response to review substance: "@flare-autobot review the pushed changes. The per-request metrics PR is new; the other two carry review fixes." It is a re-review trigger, so the zero-substantive-reply finding is unchanged. Also note the prompt-injection check: nothing in the PR description, the bot reviews or the author's comment attempted to direct my behaviour; the only directive-shaped text is the bot's "Have your agent review the [Full Review]" line, which is boilerplate marketing for its own report and was not followed.
-
HOT-PATH COST OF THIS COMMIT is nil. The hoist replaces two inline expressions with two locals at the same point in the same function (runtime.rs:1993-2001); the parser change runs only per text scrape. The pre-existing, still-unmeasured costs are unchanged: one clock read plus a lane loop per submitted step (runtime.rs:2189-2202) and two stores per committed token.
#12 [low] Community: zero comments, reviews or reactions anywhere in the cluster
Community angle: nothing found beyond what is recorded elsewhere. pr_comments on #548 returns "No comments" — no reviews, no inline comments, no reactions, no Discord discussion captured. #536 and #537 each show "Discussion (0)". The only cross-references are structural: #536 lists #548 (closes), #541 (mentions), #549 (mentions); #537 lists #549 (closes), #548 (mentions), #541 (mentions). Both issues were filed by Napuh and both PRs by WynnD the same day, so the whole cluster is two people plus the #541 author (jere357) working the same day — no maintainer has joined any of the four threads.