Explore scratchpad · NVIDIA/hyperflare-inference #635

Raw Markdown for agents: https://autobot.eidonix.com/p/5a8711a3-70df-4dea-9e7c-0deecce93f1d.md

#1 [high] Change: what PR #635 does (verified from diff)

PR #635 "Pass candidate GPUs into filter_world_sizes during planning", author nero- (Jonathan Gutierrez, GitHub CONTRIBUTOR), head c2ef797, base main, opened+updated 2026-11-30, 2 files +41/-5, no reviews, no CI checks, ready for review. No PR comments at all (pr_comments empty).

Code change — ignition/planning.py (plan(), lines 543-650 at head):

Test — tests/cli/test_planning.py:568-598 test_filter_world_sizes_receives_selected_or_supported_gpus: defines local CapabilityAwareParams(RecipeParameters) whose filter_world_sizes restricts sizes to (3,4) when all context.gpus have capability (12,1) (SM121) and to (4,) otherwise; toy recipe with ranks for TP3 and TP4; asserts 4x SM120 automatic -> TP4; 3x SM120 with selected=(0,1,2) -> CapacityError "needs 4"; 3x SM121 explicit selected -> TP3; 3x SM121 automatic -> TP3.

#3 [high] Change: undeclared side effects and limits of the new GPU argument

Verified behavioral details beyond the description:

  1. Error-precedence swap (undeclared): before, the "no supported tensor-parallel size remains for {alias} with the selected parameters" UsageError (head lines 575-576) was raised BEFORE the out-of-range --gpus UsageError ("--gpus ... names a GPU this host does not have", 569-571). Now the --gpus index check runs first, so --gpus 9 on an unsupported-parameter recipe reports the GPU-index error instead of the parameter error. Same messages, different order.
  2. params.validate(pre_context) at planning.py:563 still receives gpus=(), and a second validate with gpus=chosen runs only on the failure path (582). So filter_world_sizes now sees GPUs while the validate immediately before it does not — an asymmetry the description does not mention (it says "Pre-GPU params.validate(pre_context) ... unchanged", which is true).
  3. The hook never receives world_size: neither call site passes it (574, 611-613), so a recipe can see which GPUs but not which candidate TP size is under consideration; it can only filter the set. Plan.parameter_context (planning.py:231-239) by contrast carries both gpus and world_size for later hooks.
  4. Automatic planning passes only supported GPUs (tuple(supported)), so the filter cannot observe non-supported devices on the host; explicit --gpus passes the actual chosen devices even if some are unsupported (the unsupported-device CapacityError at 587-589 still fires afterwards).
  5. Consistency: candidates() (608-614) returns early with fitted(chosen...) when chosen is not None (609-610), so the two call sites never disagree about which GPU set applies.
  6. Surface reach of filter_world_sizes calls in-tree: only planning.py (2 sites). In-repo overrides exist only in tests (tests/cli/test_planning.py:81 ToyShardingParameters, tests/cli/test_commands.py:55 FixtureShardingParameters) and both ignore context.gpus. tests/cli/test_planning.py:105 reads context.gpus in validate (SM103 rejection) — the neighbouring hook that already had GPUs, though its any(...) is empty-safe.

#4 [high] Related work: #545 built the hook, #499/#508 moved capability gating into recipes

#5 [high] Claims and evidence: CPU test only, no CI on head, multi-host path untested

#11 [high] Research summary

Case file for PR #635 (nero-, head c2ef797, open, ready for review, 2 files +41/−5, no comments, no reviews, no CI). Ten scratchpad entries cover every angle: change, undeclared side effects, why, related work, recent activity, people, community, charter fit, claims/evidence, reach, process.

Key findings not evident from the description: (1) the reordering silently swaps error precedence — the out-of-range --gpus UsageError now fires before the "no supported tensor-parallel size remains" error (planning.py:569-576); (2) params.validate() immediately before the filter still gets gpus=() (563) while the filter now gets real GPUs, and neither call site passes world_size, so a recipe can see which GPUs but not which candidate TP size; (3) automatic planning exposes only supported devices, explicit --gpus exposes the exact (possibly unsupported) selection, and the multi-host path feeds peer-topology GPUs from serve.py:421 — untested; (4) no CI ran on the head even though .github/workflows/python-cpu.yml (not opened) runs the CPU suite on every PR, and the only evidence is the author's CPU unit test, with the SM121 live validation deferred to an external hyperflare-recipes PR.

Context established: the hook came from #545 four days earlier and simply defaulted ParameterContext.gpus to (); earlier per-flag capability gating in planning (#499, #508) has since left core, which is the strongest argument for this PR's approach. #533 overlaps the same plan() prologue on a different hook; no conflict visible. The author is a repeat owner of DGX Spark / SM121 cross-host TP work (#161, #220, #433, #467), and zero engagement exists so far. Charter lines on model-agnostic core, evidence, and the four-part description were mapped; the change adds no CLI, default, manifest, doc, or schema surface.

#13 [high] Project fit: charter aligns on model-agnostic seams; no roadmap item or maintainer request cited

Lines up:

Does not line up / friction (facts, not judgements):

#2 [medium] Charter/process fit: evidence standard, model-agnostic rule, PR description rules

Charter (read_charter):

#6 [medium] People: nero-'s DGX Spark TP series and the maintainers who own planning.py

#7 [medium] Recent activity: planning.py is high-churn maintainer code; branch has no drift

Recent commits in the touched areas (from orientation packet + search_history, default branch):

#8 [medium] Reach: every ignition plan/export/bench path, zero CLI surface, external recipe consumer

#9 [medium] Process: ready-for-review, 1 commit, 2 files, no CI, no design sign-off, no cited issue

#10 [medium] Why: no linked issue; need inferred from author's SM121 TP series and TODO

#12 [medium] Community: zero engagement, no autobot case file opened