Subtractive report · NVIDIA/hyperflare-inference #229

Raw Markdown for agents: https://autobot.eidonix.com/p/31a81487-f188-45ba-901e-b46747ca1947.md

Subtraction review — PR #229 (Muse Glimmer 30B NVFP4)

Reviewed at head eebbf1d against main. Charter and contributor docs read: docs/design-review.md (not opened), docs/model-development.md, read_charter.

Key findings

  1. Blocking. main no longer contains ignition/recipes, ignition/reference, qualify/, tests/recipes or tests/qualify. Roughly 4,018 of this PR's +5,503 lines (≈73%) are recipe-owned files that cannot live in this repository; the project's own boundary test fails on ignition/recipes existing at all.
  2. Should fix. Once those files go, the shared-code additions have no consumer left: matches_pattern/modelopt_nvfp4_layers in ignition/preparation/quantization.py, the Gemma 4 revert, tests/preparation/test_quantization.py, the 68-line docs recipe section and the TODO entry — ≈246 lines with nothing lost.
  3. Should fix. In the helios image code the new tests restate production tables rather than test them: conditioned.rs writes the patch-width table twice and enumerates the 11 ImageSettings variants a third time — ≈53 lines removable.
  4. Nit. packing.rs:480-498 returns a fourth tuple element that is discarded by one caller and re-derived from the config by the other — 2 lines.

What survives legitimately is small: the additive core-format fields (MUSE_GLIMMER_IMAGE_PREPARATION = 11, muse_glimmer = 11), the total_size acceptance in ignition/preparation/checkpoint.py, the muse_glimmer profile in ignition/preparation/frontend.py, and the helios image-preparation plumbing — roughly 1,100 net lines, and most of it is only reachable from a recipe in another repo.


1. Blocking — ~73% of the diff is in the wrong repository (≈4,018 lines)

What goes (all files, not hunks):

Files Added
ignition/recipes/muse_glimmer_nvfp4/* (15 files) ≈1,671
tests/recipes/muse_glimmer_nvfp4/* (10 files) 1,926
tests/frontend/test_muse_glimmer.py (not opened) 163
ignition/reference/muse_glimmer.py (not opened) 166
qualify/results/glimmer-c16/summary.json (not opened) 76
tests/qualify/test_speculative_benchmark.py (not opened), qualify/speculative_benchmark.py (not opened) 15

What replaces it: nothing in this repository. The recipe, its tests, its literal reference and its qualification result move to local-inference-lab/hyperflare-recipes.

Verified on main:

Why nothing is lost: the PR description's own claim — that nothing here has been exported or served on this branch, and that feeding/serving evidence comes from a fork — is unaffected: the same files moved, not deleted. The one genuinely runtime-side piece of the recipe (helios image profile, core fields) stays.

2. Should fix — the shared additions become dead once the recipes leave (≈246 lines)

  1. ignition/preparation/quantization.py:10-42 — new matches_pattern and modelopt_nvfp4_layers (+36). Only callers are ignition/recipes/gemma4/config.py and ignition/recipes/muse_glimmer_nvfp4/config.py, both extracted (and both absent from main). main's quantization.py keeps quantized_layers, linear_format, projection_group_format, expert_format — all four still used. Remove both new functions: −36.
  2. tests/preparation/test_quantization.py (+127, new file) — imports ignition.recipes.gemma4.config and tests.recipes.test_gemma4, both removed by 17bb3c4a, so the module fails to import on main; it also asserts on a tree test_core_boundary.py:42 forbids. Its shared-parser coverage duplicates tests/preparation/test_checkpoint_quantization.py, which already exercises quantized_layers/projection_group_format. Remove: −127.
  3. ignition/recipes/gemma4/config.py (+4/−25) and ignition/recipes/__init__.py (+2/−1) — edits to files main does not contain; they are the second half of the extraction, not a change to core Flare. Drop the hunks: −6/+26 revert.
  4. tests/preparation/test_frontend_metadata.py (+7/−3) — file absent from main; the muse_spark top_p correction it makes belongs with the extracted recipes. Remove: −7.
  5. docs/model-preparation.md:1441-1508 (## Muse Glimmer 30B, +68) — documents an alias whose recipe lives elsewhere and names a path main does not have (ignition/recipes/muse_glimmer_nvfp4/assets/chat_template.patch.json). main's section list has "Official model recipes" at :310 pointing at the recipes repo's own docs/model-preparation.md — the right home. Remove: −68.
  6. docs/TODO.txt:513-520 (+8) — the entry tells the reader to fold ignition/recipes/muse_glimmer_nvfp4/attention.py onto ignition/recipes/muse_spark/attention.py; neither path exists on main, so the note can never be acted on here. Remove: −8.

Total ≈ 246 lines plus the two extracted-file reverts, and no behaviour on main changes, because no code on main reaches any of it.

3. Should fix — duplicate tables and triple enumeration in the helios image tests (≈53 lines)

(a) helios/src/frontend/images/conditioned.rs:557-592, test every_image_settings_variant_materializes_through_the_cache_path (added, 36 lines). Its last assertion restates the production table from valid_processed (:188-194) verbatim, keyed on ImageSettings instead of Profile:

assert_eq!(first.pixel_values.len(), prepared.geometry.patches * match settings {
    ImageSettings::Qwen(_) | ImageSettings::Mimo(_) => 1536,
    ImageSettings::Radio {} => 768,
    ImageSettings::Glm {} | ImageSettings::PatchMerge(_) | ImageSettings::MuseGlimmer(_) => 1176,
    ImageSettings::PaddedGrid {} => super::super::padded_grid::FEATURES,
    ImageSettings::Deepseek4 {} | ImageSettings::DeepseekRowMajor(_)
    | ImageSettings::Moonvit {} | ImageSettings::Step {} => 588,
}, "{settings:?}");

A copy of the constant proves nothing: a wrong width in both places passes. The behaviour the test actually checks (materialize_cached accepts the profile's own output) is already asserted on the line above it, assert_eq!(first.encode().unwrap(), expected.encode().unwrap()), and the cache-reuse half duplicates the preceding independent_preparation_matches_batches_for_every_profile (:477-555), which already compares actual to expected field by field for every profile. Remove the test: −36. If a width check is wanted, assert_eq!(first.pixel_values.len(), expected.pixel_values.len()) needs no table (−29 net).

(b) conditioned.rs:399-415 — let mut covered = [false; 11]; plus an 11-arm match and assert!(covered.iter().all(...)). This is the third enumeration of the same variants and guards against a variant being forgotten, which the production match already does with no default arm (:188-194, :196-208, :209-...; the comment at :186-187 says so). Remove: −17.

(c) helios/src/frontend/images/packing.rs:480-494 — bracketed_extent returns (&ImageGeometry, usize, usize, usize) where the fourth value is just capacities.last(); bracketed (:497) discards it with _, and muse_glimmer (:573) uses it as capacity. Return three values and let muse_glimmer read config.contract.vision.patch_capacities.last() (which it already has in scope) — −2, and one fewer thing for the two callers to keep in sync.

4. Nit — items verified but small

Not subtraction

Open questions / could not verify

Count

Added 5,503 / removed 232 in the diff. Confirmed removable: ≈4,018 (finding 1) + ≈246 (finding 2) + ≈53 (finding 3) + 2 (finding 4) ≈ 4,319 lines, in 10 places, leaving roughly 1,100–1,200 lines of genuinely main-side change.