Prose report · NVIDIA/hyperflare-inference #533

Raw Markdown for agents: https://autobot.eidonix.com/p/c9923bc7-7a3c-407f-a23c-b12ca2c9fc86.md

Prose review — PR #533 "Cap the per-request context target", head 02023eba (base main, 9 files, +84/−18)

Rules applied: AGENTS.md:72-109 (required PR descriptions: why → what → result → evidence, name components and material compatibility changes, attach scope and limitations to a measured claim), docs/design-review.md:137-152 (principle 16: same scheme, in order, "Reject messages that leave these answers implicit, omit them, or present them out of order"), and the changed docs row and help text. Head commit has no CI checks, so the new test was never executed.

Key findings

Blocking

B1. The description describes code (and a test) that is not at the head — tests/cli/test_planning.py:238-240, ignition/planning.py (absent), ignition/planning.py:704-712

Description quotes:

Code at the head:

Why it matters: this is the description claiming a user-facing validation exists and that the PR validates it, when the shipped behaviour silently accepts an unaligned target and the test that checks it raises no error. AGENTS.md:88-94 requires the description to describe what was actually added; docs/design-review.md:137-152 rejects a message a reviewer must reconcile against the diff.

Fix, one of two (state which in the description):

  1. Restore the alignment check the earlier round required (context_target % page_tokens in Plan.__post_init__ or in fit) and keep the test as written; or
  2. Drop the "page-multiple validation" and "distinguishes the default chunk from an explicit one" clauses, rewrite the test's multiple of the case to something the code does support, and say in the description what an unaligned target does (Helios re-aligns at load: helios/src/model/catalog.rs:43-70).

Settled by pytest tests/cli/test_planning.py -k request_context — expected failure at :239. No CI ran it.

Should fix

S1. The headline VRAM claim is unconditional; the pool only tracks the prepared context under --kv-cache-limit context|concurrency — description, docs/cli-design.md:446

page_ceiling returns Ok(None) when mode == KvCacheLimit::Memory (helios/src/runtime_core/memory.rs:284-292), and memory is the documented default (docs/cli-design.md:738). Only Context/Concurrency derive the ceiling from the context (memory.rs:298-320). The evidence command line says "served at concurrency 1–4 (--kv-cache-limit concurrency)", but the description's opening ("capping … shrinks the KV pool and frees VRAM") and "At concurrency 4 the 131072 cap frees 16 GB vs the default" attach no condition, and the new docs row (docs/cli-design.md:446) says only "Cap the prepared per-request context and max_sequence_tokens at N tokens, below the recipe's maximum." A reader who exports with the cap and runs with defaults will see none of the 16 GB.

Fix: add the condition to the headline/Result and to the docs row: "with --kv-cache-limit context or concurrency; the default memory mode sizes the pool from free VRAM regardless of the prepared context". AGENTS.md:95-102 (scope and material limitations attached to the claim).

S2. "a cap above the pool is a no-op … matching stock behavior" is false — description "Result:", ignition/planning.py:377-381, ignition/preparation/bootstrap.py:58

if self.context_target is None:
    return self.recipe.context          # unclipped
return min(self.recipe.context, self.context_target, self.tokens)

At main, common_preparation_kwargs passed "context": plan.recipe.context (bootstrap.py:58 before this PR), i.e. the recipe maximum regardless of the pool. So a target above a small pool prepares max_sequence_tokens = tokens < recipe.context, strictly lower than stock — the opposite of "no-op … matching stock". The PR's own test asserts this (oversized.prepared_context == min(recipe.context, oversized.tokens), test_planning.py:229-232). AGENTS.md:92-94 requires identifying material compatibility changes rather than presenting them as equivalence.

Fix: "a cap at or above the KV capacity resolves to the pool-bound context, which can lower max_sequence_tokens below the recipe maximum — unlike a preparation without the flag."

S3. The four required answers are out of order and the "why" is a setup line — description

Order as written: measurement headline (Evidence) → "What Changed" → "Result" → "Evidence … Workload: a memory-constrained deployment where the default per-request context (256K recipe max) over-provisions the KV pool, leaving insufficient VRAM for the desired concurrency." The nearest thing to a why is that Workload sentence, and it states a configuration, not the defect.

AGENTS.md:74-80: "Every description must answer these four questions, in this order: why, what exactly changed, what benefit or result is claimed, and what evidence supports it", and :101-102 "The claimed benefit must be clear before presenting the supporting test and benchmark details". docs/design-review.md:140-146 restates the order and says to "Reject messages that … present them out of order".

Fix: lead with one sentence of why (a 256K recipe maximum sizes per-request KV far above the requests a deployment serves, so the pool holds pages no request can use and competes with concurrency), then What Changed, then Result (with the S1 condition), then the table.

S4. The docs row never says a request above the cap is rejected — docs/cli-design.md:446

The description's Result claims "a request that would exceed the cap is rejected"; the shipped row says only "Cap … below the recipe's maximum. Command line only; a core's catalog is fixed at export…". The neighbouring --prefill-chunk-size row states its operational consequence ("while it runs, other active requests wait"), so the omission is a regression in the row's own style. Fix: one clause — "a request whose prompt plus output exceeds N is rejected at admission."

S5. "What Changed" omits a changed file — description, docs/cli-design.md

The file list names ignition/cli/{init,bench,preparation,serve}.py, planning.py, rebuild_manifest.py and tests/cli/test_planning.py; docs/cli-design.md is in the PR (+3/−2) and is the only user-facing description of the flag. AGENTS.md:88-94 asks the description to name the affected components. Fix: add it, e.g. "docs/cli-design.md documents the flag and the two context-limit rows".

Nits

Checked and clean (do not re-raise)

Could not settle