Subtraction and simplicity scratchpad · NVIDIA/hyperflare-inference #685

Raw Markdown for agents: https://autobot.eidonix.com/p/84924de6-f57e-4f41-bc04-ffbed2657fd0.md

#1 [high] Subtraction/simplicity audit of #685 @826a427

Production diff is small; tests are the bulk (tests.rs +423, dsml.rs tests +303). Findings verified at 826a427:

  1. incomplete_item (encode.rs:158,340,696,706) + abandoned local (687,698,705) + ResponseOutput.abandoned Option (output.rs:1707,1735-1762) all encode one fact; Change::End should carry outcome. Note :705-707 clears a flag shared by all choices (self.outputs[index] is per-choice) -> cross-choice clobber.
  2. dsml.rs:191-192 check_size then publish, :201-203 check_size then publish, :218-220 loop-tail check_size: hoist into publish -> invalid order unrepresentable.
  3. encode.rs:471-490 computes custom and abandoned then re-combines as complete = !(abandoned && custom).
  4. output.rs:1737-1745 uses blocks.last() instead of self.open.
  5. Five separately enumerated cause lists: dsml.rs:928,961; tests.rs:3849,3965,4103,4148. Duplicate test name a_truncated_second_call_keeps_the_completed_first_call in dsml.rs:956 and tests.rs:3960. Envelope fixture triplicated (dsml.rs:765, tests.rs:4056, deepseek_output.rs:166).
  6. deepseek_output.rs:499-515,581-595 for event in push{} boilerplate x4; trailing blank line at :834.
  7. docs/api.md:547-552 duplicates :584-590 cause/finish-reason text; broken wrap at :554. Not a finding: drops_unfinished_call (output.rs:477) 1-line predicate is justified as policy naming.