Pre test report report · NVIDIA/hyperflare-inference #483

Raw Markdown for agents: https://autobot.eidonix.com/p/ceeb3dd5-3162-4e8f-8c74-05c046a96d3e.md

Pre-test report — PR #483 "Add Gemma 4 image preparation, Bracketed patch-width metadata, and atomic spans"

Head ab9a432b · base main 27716185 · 38 files · +2490 / −251 · no CI checks on head

Verdict: DO NOT REFER TO HARDWARE TESTING. Send back to the author for one small fix plus a CI run.

This supersedes my 2026-11-25 report (written against 2b4a31e). The author pushed ab9a432b answering the third review round point by point; every blocker from previous rounds is now verified fixed in code. Three independent grounds say hardware is the wrong instrument:

  1. Nothing on cn5 or cn7 can exercise this change. cn5 hosts facebook/dinov2-base, timm/vit_base_patch14_dinov2.lvd142m and GLM-5.3-Flash-NVFP4 variants (GPU 0 is at 86 °C and the host is not taking runs); cn7 hosts Qwen3.8-27B variants. No Gemma 4 checkpoint on either host, and no in-tree recipe selects the new profile — recipes were split into local-inference-lab/hyperflare-recipes. A GPU run today would exercise nothing in this PR.
  2. Nothing GPU-side is modified. The whole diff is CPU/deterministic: decode → area-bounded bicubic resize → interleaved (y,x,c) patch pack scaled by 1/255 → (x,y) positions → token-envelope expansion → upload extent arithmetic → prompt/span validation. No kernel, graph, numerics or precision path changes, and the PR makes no performance claim, so the benchmark rule (#210) is not engaged. A throughput/latency A/B would be pure waste.
  3. Blast radius on the models the hosts can serve is zero, measured. The one behaviour change reaching existing vision cores is helios/src/frontend/images/conditioned.rs:187, which now calls ImageProcessor::patch_features() (mod.rs:459-471) instead of the literal match at main:187-193. Comparing the two: Qwen/MiMo 1536 → 1536, Radio 768 → 768, Glm 1176 → 1176, PaddedGrid 1200 → 1200, DeepSeek*/Moonvit/Step 588 → 588, and only PatchMerge (MiniMax) 588 → 1176 changes — a genuine bug fix (MiniMax's cached prepared-image records were being re-materialised every request) for a family hosted on neither machine. The new load-time narrowings cannot bite hosted cores either: square_merge_side runs only for ImageLayoutKind::Bracketed (packing.rs:39-46 via model/packing.rs:92-97 (not opened)) and no hosted core is Bracketed; the envelope bounds at server/config.rs:464-487 apply only when max_image_envelope_tokens() is Some, i.e. Profile::Gemma4 only (mod.rs:473-478); model.rs:89 (patch_features % 3) only fires on a nonzero field and no checked-in fixture or test sets it (a search for "patch_features" under helios/tests returns nothing).

Expected value of a hardware run as the PR stands: ≈ 0, and negative if it displaces real work. The evidence this change needs is CPU-only and cheap (cargo test, and a pytest run for the Python producer), and it belongs in CI.


What changed since my last report — all verified in code at ab9a432


Residual findings, and whether any gates a hardware run

# Finding Severity Gates testing?
A prepare_frontend(snapshot, image_profile="gemma4") without preprocessor= raises FileNotFoundError. ignition/preparation/frontend.py:310 resolves the default as preprocessor_config.json (not opened); Gemma 4 (and Inkling 2) snapshots ship processor_config.json (not opened), and the checked-in fixture is a processor dump (the tests write it to processor_config.json (not opened), tests/preparation/test_frontend_gemma4.py:76). Both gemma4 call sites pass the path explicitly (:88, :246), so the documented shape is untested and broken. Pre-existing for padded_grid, so this is consistency plus a missing default test, not a new architectural defect. should-fix No — Python authoring surface, CPU, unreachable from a GPU run
B No in-tree contract mounts the profile, so the serve path is unproven. helios/tests/support/contracts/gemma4_frontend.json:16,17,38 are all null; no fixture uses image_layout: 9 (values present: 3, 10, 2, 6, 1, 5). "Gemma 4 vision works end to end" is unsupported, correctly stated as a limitation and tracked open at docs/TODO.txt:331-337. should-fix (evidence) No — needs a recipe + checkpoint that do not exist yet
C patch_features is authored by nobody in-tree. contract.py:117 defaults it to 0 with a docstring at :111-115 telling Bracketed recipes to set it; the first Gemma 4 recipe that omits it gets the actionable load error at server/config.rs:449-455. Recipe-side work, not a defect here. should-fix (downstream) No
D Soft-token allowlist duplicated Rust/Python (gemma4.rs:13 vs frontend.py:132) with nothing tying them, and only 280 and 1120 are ever loaded (generate_gemma4_image_fixtures.py:31-40), so 70/140/560 geometry is unexercised in both languages. should-fix (coverage) No — CPU table test/extra fixture cases
E Two unreachable wire knobs. patch_size/pooling_kernel_size are pinned to 16/3 by frontend.py:124-127,140-141 and written as literals at :168-173, so gemma4.rs:27-40's 1..=64 / 1..=16 arms cannot fire. Precedent (patch_merge.rs (not opened) pins 14) makes this defensible; dead configuration is a simplicity cost only. nit No
F CI does not run the Python tests. .github/workflows has only helios-lifecycle, native-serving, release; no workflow invokes pytest, so tests/preparation/test_frontend_gemma4.py never runs automatically and the author's statement that the fixture-provenance test runs in CI is not supported. native-serving.yml:63,68 does run cargo test for helios with --features runtime-core,server, so the new Rust tests do run in CI. No CI status is recorded on ab9a432. process No — CI, not hardware
G Nits: describe.rs:451-452 adds the Gemma 4 arm beside PatchMerge; helios/README.md:721-728 (not opened)'s Qwen contract paragraph now correctly scoped and points at ImageProcessor::patch_features(); gemma4.rs:404-420 and :383-402 still restate fixture rows already pinned by hash; the 11-row cross-profile table at packing.rs:695-825 repeats rows four would cover. nits No

No residual item is a substantive architecture or code-quality problem that would be invalidated by hardware testing. Finding A is the only pre-merge must and it is one line in a Python helper; B and C resolve only when the companion recipe lands.

On scope (raised by several lenses): the profile rides the existing ImageSettings/Profile enum — the eleventh preparation profile, the same extension point padded_grid used — the proto changes are additive and defaulted, and the profile is inert until a recipe declares it. That is a sequencing judgement for the maintainers, not a defect, and not a reason to spend a GPU job.


Review-summary reliability — claims I checked and discarded

The lenses converged on the substance, but several notes are stale against this head and should not drive a decision:

The one substantive point several lenses made and I confirmed independently is finding A (frontend.py:310 default path), which no summary pressed as a gate on testing — correctly, because it is Python-side.

Screening: I re-read the changed hand-written surfaces and the PR discussion; no instruction-shaped or agent-directed text. The #autobot:ignore footer is the repository bot's standard opt-out addressed to humans, not an instruction to this review. No injection attempt to report.


  1. Author: fix finding A — resolve the processor path per profile (prefer processor_config.json (not opened) for gemma4/padded_grid, or accept whichever of the two exists) and add a test for the default argument. One line plus a test, and it removes the first failure the next recipe author would hit.
  2. Author: note in the description that no CI workflow runs pytest (finding F), and ask for a cargo test + pytest tests/preparation run reported with skips visible.
  3. Then decide merge. The profile is inert and the wire is additive; the maintainers' remaining question is whether landing it ahead of the companion recipe is acceptable (finding B).
  4. Refer to hardware only when a Gemma 4 vision recipe and a hosted checkpoint exist. At that point the plan below applies, and it is small.

Minimal test plan — only if referred (i.e. only after a Gemma 4 core can be prepared and served)

Stage 0 — gate before any GPU time. p.GraphOperation.Value("terminal_prefill") == 14 and p.ImagePreparationKind.Value("GEMMA4_IMAGE_PREPARATION") == 11 both resolve from the checked-in runtime_core_pb2.py; cargo test --features runtime-core,server and pytest tests/preparation green; the single #[ignore]d test reported as unrun, not as a pass.

Stage 1 — CPU correctness, one cn5 CPU job, no GPU (~5 min).

Stage 2 — single serving check, one cn5 job (4× RTX PRO 6000), only once a recipe and checkpoint exist. Prepare the Gemma 4 core from the companion recipe (vision.patch_features = 768, ImageLayoutKind::Bracketed, ImagePreparationKind::Gemma4); serve TP=1 (TP=2 only if the recipe asks for it). Two requests: one text-only (must match main), one with a single image (HTTP 200, plausible image-grounded output). Repeat the image request once at max_soft_tokens = 280 and once at 1120. Fail-fast strings to watch: conditioned input spans or features violate prompt geometry, invalid bracketed image extent, bracketed image feature run is outside the expanded prompt, image token spans do not match their declared boundaries, maximum image envelope, and any prefill-split rejection. One image at or below the prefill chunk and one above is enough — do not sweep resolutions.

Explicitly not to be tested (would waste hardware):