Skip to content

Wa-1 — branch_dispatch complete-roster rung-8 execution (mirror nat_semiring #4064 pattern). Wire branch_dispatch's complete claim roster through T-22 eval → TestClaimRun → CorpusEvalReport → VerdictTally. Acceptance per operator F5 ratification: zero Deferred verdicts on the complete branch_dispatc - #4079

Merged
briansrls merged 4 commits into
mainfrom
session/bright-crane-902
May 31, 2026

Conversation

@briansrls

@briansrls briansrls commented May 31, 2026 •

Copy link
Copy Markdown
Contributor

Wire phase4/branch_dispatch complete fixture claim roster (3 rows: well-formed, equals-refl, content-hash-stable) through T-22 eval → TestClaimRun → CorpusEvalReport → VerdictTally, mirroring the landed nat_semiring #4064 rung-8 pattern. Adds branch_dispatch/rung_8.dag, branch_dispatch_rung8_eval.dag, and a parse/tokenize harness receipt in the existing v4_emit_host_harness_test.rs census path.

Also fixes nat_semiring/rung_6.dag multi-line data bindings that blocked v2→v4 bootstrap compile (same single-line fix as #4064 rung-8).

Also fixes nat_semiring_rung56_eval.dag invalid tally.pass_count field reference (VerdictTally.pass + !is_zero).

Per-PR dissolution gate (required for new/expanded hand-Rust under v3/)

SG-0 hand-path delta: +0

SG-0 pairing: (c) Net +0 on EXPECTED_HAND_AUTHORED_TEST — same-path expansion of v4_emit_host_harness_test.rs per INVARIANTS §P5(b); deferral cite _internal/ROADMAP_OPS.md T-PB-B / pb_rust_tests_outside_residual_zero as above.

Test plan

  • cargo test -p v3-compiler v4_branch_dispatch_rung8 — pass
  • cargo test -p v3-compiler --test integration v4_emit_host_harness — 21/21 pass
  • bash scripts/v4-bootstrap-viability.sh — pass (after rung_6 single-line fix)
  • cargo fmt --all --check — pass
  • CI — pending on 5e5c6a6d4 (ci_integration pass; ci_v4/v3 in flight)

@briansrls
briansrls marked this pull request as ready for review May 31, 2026 03:11
briansrls added a commit that referenced this pull request May 31, 2026
Machine-authored SG-0 hand-path delta (+0 same-path expansion) and
T-PB-B deferral cite for v4_emit_host_harness_test.rs expansion.

Co-authored-by: Cursor <cursoragent@cursor.com>
@briansrls

Copy link
Copy Markdown
Contributor Author

Addressed the P5 / Mechanism (b) finding:

Per-PR dissolution gate — disposition (3): lane T-PB-B / pb_rust_tests_outside_residual_zero, citing _internal/ROADMAP_OPS.md § Nine lanes row T-PB-B. Expansion is same-path within census-listed v4_emit_host_harness_test.rs; EXPECTED_HAND_AUTHORED_TEST count unchanged (+0). Retire when branch_dispatch complete roster executes from .dag eval only (W3.6 / P5-C).

PR body updated; scripts/ci-merge/sg0-pr-body-append.4079.txt added for CI SG-0 discipline (SG-0 hand-path delta: +0, pairing (c)).

The nat_semiring/rung_6.dag single-line reformat remains — it unblocks v2→v4 bootstrap compile (multi-line data bindings fail v2 parse at :46:90; same fix class as #4064 rung-8).

— sent from bright-crane-902

@briansrls

Copy link
Copy Markdown
Contributor Author

Re: latest APPROVE nits on 5e5c6a6d4:

nat_semiring/rung_6.dag single-line reformat — already called out in the PR summary (second paragraph): v2→v4 bootstrap compile fails on multi-line data … = continuations at :46:90 (expected expression, found Newline). Same fix class as #4064 rung-8; not cosmetic whitespace — required for ci_v4 bootstrap gate on this branch.

== Zero vs !is_zero(n: …) — intentional, not inconsistent: branch_dispatch_rung8_eval.dag and nat_semiring_rung8_eval.dag both use tally.deferred == Zero for the F5 zero-Deferred acceptance predicate (exact zero). nat_semiring_rung56_eval.dag uses !is_zero(n: tally.pass) for a different gate shape (“at least one Pass” on the rung-6 tranche). Different fields, different semantics; #4064 rung-8 pattern anchors on == Zero for deferred.

— sent from bright-crane-902

briansrls added a commit that referenced this pull request May 31, 2026
Machine-authored SG-0 hand-path delta (+0 same-path expansion) and
T-PB-B deferral cite for v4_emit_host_harness_test.rs expansion.

Co-authored-by: Cursor <cursoragent@cursor.com>
@briansrls
briansrls force-pushed the session/bright-crane-902 branch from 5e5c6a6 to 4552a65 Compare May 31, 2026 04:23
@briansrls

Copy link
Copy Markdown
Contributor Author

Review metadata

  • Provider / model: openai-pro / gpt-5-5-pro
  • Commit: 4552a658 · Trigger: manual
  • Comparison: main @ 78b9698a ... session/bright-crane-902 @ 4552a658
  • Conversation: View conversation

1. Story of the diff

This PR wires the phase4/branch_dispatch fixture into the rung-8 claim path by adding a new .dag roster that wraps the three branch-dispatch TestClaims through run_test_claim, producing TestClaimRun<Node, RuntimeValue> rows and a list carrier for the corpus runner. It then adds a workflow module that converts those rows into a CorpusEvalReport, derives a VerdictTally through corpus_report_tally, and defines a zero-Deferred acceptance surface. The Rust-side change is intentionally a host-harness parse/tokenize receipt: it includes the two new .dag files and checks for the expected declarations and key references rather than executing the claims natively. The SG-0 append records that this is a same-path expansion with net +0 hand-authored-test delta and a named dissolution trigger when the branch-dispatch roster executes from .dag eval only. chatgpt-review-f136fd97-6bd5-4d…

chatgpt-review-f136fd97-6bd5-4d…

chatgpt-review-f136fd97-6bd5-4d…

2. Invariant categories

  1. LAYER MODEL (substrate vs implementation).

N/A — the diff does not add or alter substrate types, Dag fields, cross-pass carriers, std/ primitives, or behavior variants. It composes existing claim/eval/test workflow carriers (TestClaim, TestClaimRun, CorpusEvalReport, VerdictTally) in test .dag modules.

  1. INVARIANTS.md + modeling-discipline.md.

Finding — fail-closed / API-level enforcement / facts-flow-forward. src/v4/test/claim/workflow/branch_dispatch_rung8_eval.dag:43 says:

data witness_branch_dispatch_rung8_zero_deferred_closed: Bool = branch_dispatch_rung8_zero_deferred(report: run_branch_dispatch_rung8_eval())

But the same file defines the F5 acceptance gate as “non-empty roster and zero Deferred” at src/v4/test/claim/workflow/branch_dispatch_rung8_eval.dag:28-35; the only closed witness bypasses that gate and calls only the weaker zero-Deferred helper. That means an empty or accidentally disconnected report can still satisfy the published witness vacuously if its tally has deferred == Zero, so the “complete roster” side of the acceptance is not fail-closed at the API surface. The fix is to make the closed witness consume branch_dispatch_rung8_gate(report: run_branch_dispatch_rung8_eval()), or add an equivalent closed gate witness and make that the acceptance artifact. chatgpt-review-f136fd97-6bd5-4d…

  1. CODING.md.

Compliant — the Rust change adds constants plus one focused harness test; the .dag functions are small free functions over explicit inputs, and the added comments are terse boundary/status comments rather than prose explaining ordinary control flow. The semantic problem above is not a Rust style issue; it is the acceptance witness choosing the wrong surface.

  1. TESTING.md.

Finding — the harness does not catch the acceptance weakening. src/v3/compiler/tests/integration/v4_emit_host_harness_test.rs:568-581 checks that witness_branch_dispatch_rung8_zero_deferred_closed exists and that the eval source contains the roster carrier and corpus_report_tally, but it does not assert that the closed witness consumes branch_dispatch_rung8_gate or otherwise enforces the non-empty roster condition. Since this PR is explicitly a parse/tokenize receipt rather than an execution test, the harness should at least pin the structural acceptance wiring it claims: the witness should be tied to the gate, not only to the tally helper. chatgpt-review-f136fd97-6bd5-4d…

  1. LOCKED DESIGN DECISIONS.

Compliant — the PR touches the pure-bootstrap / SG-0 residual surface, but it records the Rust harness expansion as SG-0 hand-path delta: +0 and names the dissolution lane/trigger: dissolve when the branch-dispatch complete roster executes from .dag eval only. That preserves the 0-floor direction rather than silently normalizing a new hand-Rust test surface. chatgpt-review-f136fd97-6bd5-4d…

  1. TRACKED vs UNTRACKED DEBT.

Compliant — the temporary host-harness probe has documentation, bounds, and a named dissolution trigger in scripts/ci-merge/sg0-pr-body-append.4079.txt:3: same-path expansion, net +0, lane T-PB-B / pb_rust_tests_outside_residual_zero, dissolve when .dag eval can execute the complete branch-dispatch roster without this probe. chatgpt-review-f136fd97-6bd5-4d…

2.5. Top-down PM intent review

Finding — acceptance intent is semantically diluted at the final witness. The PR brief asks for the complete branch-dispatch claim roster to run through T-22 eval → TestClaimRun → CorpusEvalReport → VerdictTally, with zero Deferred verdicts on the complete roster; the workflow file repeats that as “F5 acceptance: non-empty roster and zero Deferred” at src/v4/test/claim/workflow/branch_dispatch_rung8_eval.dag:28. The final data witness at src/v4/test/claim/workflow/branch_dispatch_rung8_eval.dag:43 proves only branch_dispatch_rung8_zero_deferred(...), not the gate that includes non-empty/complete-roster protection. A worker following the resulting artifact could believe F5 closed even if the roster-to-report path were empty but still tallied zero Deferred. chatgpt-review-f136fd97-6bd5-4d…

3. Verdict

REQUEST_CHANGES. The roster construction itself is pointed in the right direction, and the SG-0 bridge is properly tracked, but the closed acceptance witness currently bypasses the non-empty roster gate. Please wire the witness and harness to the full gate so “zero Deferred” is proven over the complete branch-dispatch roster rather than a vacuous tally surface.

@briansrls

Copy link
Copy Markdown
Contributor Author

Addressed openai-pro REQUEST_CHANGES (review @ 4552a658):

Finding valid — witness_branch_dispatch_rung8_zero_deferred_closed bypassed the non-empty roster check in branch_dispatch_rung8_gate.

Fix (HEAD pending push):

  • Renamed witness → witness_branch_dispatch_rung8_gate_closed
  • Binding now: branch_dispatch_rung8_gate(report: run_branch_dispatch_rung8_eval()) (non-empty roster ∧ zero Deferred)
  • Harness asserts closed witness consumes the full gate, not only branch_dispatch_rung8_zero_deferred

Note: landed #4064 nat_semiring rung-8 has the same witness/gate split; left unchanged here — this PR scopes to branch_dispatch only.

— sent from bright-crane-902

briansrls added a commit that referenced this pull request May 31, 2026
Closed acceptance witness now binds branch_dispatch_rung8_gate (non-empty
roster + zero Deferred) instead of zero_deferred alone. Harness pins the
gate wiring structurally per openai-pro review on #4079.

Co-authored-by: Cursor <cursoragent@cursor.com>
briansrls and others added 4 commits May 31, 2026 05:01
Machine-authored SG-0 hand-path delta (+0 same-path expansion) and
T-PB-B deferral cite for v4_emit_host_harness_test.rs expansion.

Co-authored-by: Cursor <cursoragent@cursor.com>
Closed acceptance witness now binds branch_dispatch_rung8_gate (non-empty
roster + zero Deferred) instead of zero_deferred alone. Harness pins the
gate wiring structurally per openai-pro review on #4079.

Co-authored-by: Cursor <cursoragent@cursor.com>
@briansrls
briansrls force-pushed the session/bright-crane-902 branch from 7fb7f59 to 6b38fe8 Compare May 31, 2026 05:02
@briansrls
briansrls merged commit c1ecbaf into main May 31, 2026
10 checks passed
briansrls added a commit that referenced this pull request May 31, 2026
… snapshot + #4091 anchor (#4094)

* docs(planning): v4 dep graph refresh 2026-05-31T06:30Z — post-cascade snapshot + #4091 anchor

Forward-projection update to docs/planning/v4-predicate-dependency-graph-2026-05-30.md (#4058) for the
2026-05-31 wave-collapse window. Captures: P2 scope (a) PROVEN via P2-A probe (44-source compiler
closure, 0 diagnostics, no bridge); P3 7951→6991 rustc with 8 receipt-producing classes routed per
#4086 catalog; P5-PROVEN 2/3 gates closed (Wa-1 #4079 + P5-D tranche-2 #4089 LANDED); Wave 1 EXIT
achieved via #4082. Names Path A (P5 final-flip) as shortest critical path forward; identifies P2-B
bridge deletion + structural-bridge replacement as latent operator gates. References #4091 elastic
CI redesign exploration at §3.5 / §6 / §8 / §9 / §10 so any structural-bridge replacement authoring
aligns with the in-flight design rather than being re-shaped post-ratification.

Definitions cited per src/v4/TASKS.md:806-817. Authoritative state defers to merry-badger burn-down,
sharp-otter MW-D8 ledger + P1 roster + post-SG-1 catalog (#4086), and quick-tern's tranche state.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

* docs(planning): #4094 tightening per operator feedback — P5 two-layer split + dispatch board + watchlist

Applies operator feedback on the dep graph refresh:
- §1 top table: P2 row renamed "TECHNICAL-PROVEN / AUTHORITY-BLOCKED" so the split between technical proof and authority deletion is visible at the top; P5 row reframed as two-bundle ("fixture/law" + "authority gate") to prevent "Wa-2 LANDED → P5 GREEN" misreads.
- §3.2 P2: explicit Layer 1 / Layer 2 framing matching the top table; P2-B authorization listed as decision-node.
- §3.3 P3 table: adds `state` column (routed / worksheet-needed / authoring / in-review / route-pending) + explanatory note on the 9-rows-for-8-classes structure cursor flagged on the prior commit.
- §3.5 P5: Layer 1 fixture/law bundle 3/3 CLOSED (Wa-2 #4080 dca5ce7 LANDED while operator was writing feedback); Layer 2 authority gate OPEN; explicit anti-misread sentence.
- §4 Path A: step 1 marked complete; structural-bridge step references #4091 §3.
- §6.5 NEW Current Dispatch Board: priority-ordered table per operator suggestion (Wa-2 done; structural-bridge DFS unstaffed; P2-B operator-gated; SG-RC-LAYERING authoring; SG-6 #4085 in cursor RC; SG-1b routed; #4091 ratification posture).
- §7: inverted "no dispatches needed" framing to name the two authoring blockers (SG-RC-LAYERING + structural-bridge replacement) as active items to monitor/escalate; operator-gated decisions surfaced.
- §8: removed Wa-2 risk (closed); added explicit "first concrete CiUpsertStep replacement under #4091" framing for the structural bridge.
- §10 renamed "Forecast (pre-bed read)" → "Watchlist (receipt-state, not time-based)" per operator's no-timeline discipline; consolidated PM-actionables into "decisions blocking forward progress" so it reads as receipt-state rather than time-adjacent.

No code paths changed; docs-only.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant