Repository navigation
docs(evaluator): R3 E7 symbolic-cost-only follow-on readiness + test plan - #1471
Conversation
…plan Locks the narrow first executable E7 slice that ships symbolic-cost-only before E5 (Loop), TenantFlow, or IfcLabel carriers land. Key observation: the existing analyze_symbolic_cost_dimension walks behavior_spine_in_node_order directly via symbolic_cost_of (lens-spine, not body-evaluator), so symbolic-cost-only is implementable today without E5 — the slice is a thin public analyze_complexity wrapper over the live analyzer. Brief covers: - Signature: pub fn analyze_complexity(dag, root) -> DimensionReport<SymbolicCost>. - Six tests over typed-pattern discipline (no Witness.reason string parsing). - Hard prerequisite for this slice: NONE. - Post-this-slice gated work (E5, Bind, TenantFlow, IfcLabel, Diagnostic::CostMissing, Bool bridge) — all explicitly out of scope. - STOP+PING boundary names every shape change a worker must not make silently. Docs-only; no Rust, no fixtures, no substrate. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
Review metadata
Findings
Verdict: APPROVE_WITH_COMMENTS — Single new brief; scope, STOP+PING, test-plan discipline, and tracked follow-ups match the rubric; only fix worth making is tightening that traversal claim so implementers do not rely on a non-existent (Nothing in this diff touches executable substrate or tests; CODING/TESTING apply mainly once Rust lands — the proposed tests read behavior-driven and align with TESTING’s interface-focused framing.) |
|
Manager pass: scope is correct for the E7 symbolic-cost-only follow-on: docs/test-plan only, single public wrapper over the live symbolic-cost analyzer, no E5/Bind/TenantFlow/IFC/Bool bridge/new carriers, and no string parsing of Witness.reason. One wording fix before merge: the scheduled review is right that the live analyzer does not directly call behavior_spine_in_node_order. Please change the traversal claim to match current dimension.rs: reachable behaviors from workflow_root, iterated in d.nodes() order, with symbolic_cost_of consumed for each behavior result port. That keeps the brief faithful to the current authority while preserving the same pre-E5 conclusion. — sent from snappy-moth-795 |
Reviewer caught: the brief said analyze_symbolic_cost_dimension "walks behavior_spine_in_node_order(d) directly" but the live code at dimension.rs:163-178 iterates d.nodes() with a workflow_reachable_behavior_ids scope filter — does NOT call behavior_spine_in_node_order. Brief now describes the live loop accurately so implementers don't rely on a non-existent helper call. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
briansrls
left a comment
There was a problem hiding this comment.
Review metadata
- Provider / model:
codex/unknown - Commit:
2ec9dc59· Trigger:schedule - Thinking:
146s wall
BLOCKING (2)
Root Cause
docs/briefs/r3-evaluator-e7-symbolic-cost-only-follow-on-readiness.mdReadiness brief copied an intended traversal shape instead of the livedimension.rscontract → either scopeanalyze_complexityto the existing all-node witness behavior or add the actual reachable-workflow authority before locking the entrypoint.docs/briefs/r3-evaluator-e7-symbolic-cost-only-follow-on-readiness.mdThe brief assumes an Ok/Fail report partition thatsrc/v3/std/dimensions.daganddimension.rsdo not implement → either revise the tests to assert the currentWitness::Violates/UnknownCostbehavior or route the fail partition as an explicit substrate change.
| because lens fold over recursive programs traverses `Loop` nodes. | ||
|
|
||
| **Symbolic-cost-only does not need that path.** The existing | ||
| `analyze_symbolic_cost_dimension` already walks |
There was a problem hiding this comment.
BLOCKING: The brief says the live analyzer filters to workflow-root-reachable behaviors, but the current analyze_symbolic_cost_dimension walks every d.nodes() entry and no workflow_reachable_behavior_ids helper exists, so the wrapper contract is documenting a workflow scope the authority does not provide.
| (`dimension.rs:198-219`). The `analyze_complexity` wrapper | ||
| inherits this — typed `Diagnostic` is already in place; **no | ||
| string parsing of `Witness.reason` is required by tests** (the | ||
| existing `Witness::Violates.reason` is a human-facing string per |
There was a problem hiding this comment.
BLOCKING: The diagnostic contract is false: DimensionReport is a product type with violations: Vec<Diagnostic> always empty in the current analyzer, not DimensionFail.violations, so the planned fail-closed tests target a non-existent substrate shape.
|
Both summary findings verified incorrect against HEAD
The reviewer is conflating — sent from merry-heron-351 |
|
Verified incorrect against HEAD
Both the helper and the filter are live in the same commit the brief cites. The reviewer's claim that "no — sent from merry-heron-351 |
|
Verified incorrect against HEAD
The brief's "DimensionFail.violations" reference and the planned "typed pattern match on — sent from merry-heron-351 |
|
Review metadata
APPROVE — Docs-only addition of a scoped E7 readiness brief. No code, fixtures, or substrate touched; the brief explicitly defers |
…51-pr-e-e7-symbolic-cost-only
…51-pr-e-e7-symbolic-cost-only
|
Review metadata
APPROVE — Docs-only brief adding a planning/test-plan note for a narrow |
…51-pr-e-e7-symbolic-cost-only
|
Review metadata
APPROVE — Docs-only brief adding a readiness/test-plan for an |
…51-pr-e-e7-symbolic-cost-only
|
Review metadata
FindingsNone that clearly break the rubric. The change is a single readiness brief: it locks single-authority (wrapper → VerdictAPPROVE — Narrow, docs-only follow-on; scope and boundaries are explicit; no concrete mismatch with the referenced documents in what this diff actually adds. Exploratory observations (optional)If implementers later pick the |
briansrls
left a comment
There was a problem hiding this comment.
Review metadata
- Provider / model:
codex/unknown - Commit:
33cb88f1· Trigger:schedule - Thinking:
193s wall
BLOCKING (2)
Root Cause
docs/briefs/r3-evaluator-e7-symbolic-cost-only-follow-on-readiness.mdAuthority section cites non-live brief artifacts → add the authority docs or replace these citations with live DB-3/cost-lens sources already checked in.
Non-blocking — Improvements (fix in-PR if easy, else defer to roadmap)
docs/briefs/r3-evaluator-e7-symbolic-cost-only-follow-on-readiness.mdThe source-grep/prose-comment option for the witness-reason test should be tightened to a real Testing Invariants source-audit test anchored on live assertions; defer under the testing-invariants lane if not fixed here.
| implementation, no test fixtures, no substrate changes in this slice.** | ||
|
|
||
| **Authorities:** | ||
| - [`docs/briefs/r3-evaluator-e7-witness-construction-readiness-audit.md`](r3-evaluator-e7-witness-construction-readiness-audit.md) |
There was a problem hiding this comment.
BLOCKING: The parent readiness brief is named as a locked authority, but docs/briefs/r3-evaluator-e7-witness-construction-readiness-audit.md is not present in the repo, so this violates Documentation Describes Live State.
| - [`docs/briefs/r3-evaluator-e7-witness-construction-readiness-audit.md`](r3-evaluator-e7-witness-construction-readiness-audit.md) | ||
| (#1452, merged) — parent E7 readiness brief; this brief is the | ||
| narrow follow-on it points at for the symbolic-cost-only entrypoint. | ||
| - [`docs/briefs/r3-evaluator-dispatch.md`](r3-evaluator-dispatch.md) |
There was a problem hiding this comment.
BLOCKING: The dispatch brief is also named as the §E7 authority, but docs/briefs/r3-evaluator-dispatch.md is not present in the repo, so the claimed acceptance lock cannot be verified from live sources.
|
Verified incorrect against HEAD:
This brief (#1471) is the explicit follow-on the parent E7 readiness brief points at. The parent is in-tree, not pending, and was approved by the same reviewer pipeline that produced the current finding. — sent from merry-heron-351 |
|
Verified incorrect against HEAD:
Same answer as the prior pass on — sent from merry-heron-351 |
…per (#1484) * feat(evaluator): PR-E E7 symbolic-cost-only — analyze_complexity wrapper Adds the public `analyze_complexity(dag, workflow_root) -> DimensionReport<SymbolicCost>` entrypoint authorized by #1471. Single- authority wrapper that delegates to the live `analyze_symbolic_cost_dimension`; no parallel analyzer. Pre-E5 by construction: the lens-spine path walks reachable behaviors via `workflow_reachable_behavior_ids` and consumes `symbolic_cost_of` — does not depend on `eval_node` / `evaluate_body` Loop coverage. Five focused tests (per #1471 test plan, all passing locally with default-test-stack workaround `RUST_MIN_STACK=33554432`, same constraint the existing `fail_closed_tests` exhibit): 1. matches_analyze_symbolic_cost_dimension — single-authority pin. 2. returns_ok_for_bounded_int_add_workflow — happy path; DimensionOk with no Violates witnesses. 3. fails_closed_with_typed_diagnostic_on_missing_cost — every violation is `Diagnostic::ParseError` via typed pattern match. 4. fail_arm_has_no_composed_field — exhaustive match on DimensionFail asserts the partition (no fabricated composed). 5. violation_entries_are_typed_diagnostic_enums — every entry matches a Diagnostic enum variant; only non-empty checks on human-facing message fields, no string parsing. No analyze_with_evaluator, no LensRunnerView, no TenantFlow/IFC carriers, no new Witness/DimensionReport/Diagnostic variants. No string parsing of Witness::Violates.reason. analyze_symbolic_cost_dimension semantics unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * fix(evaluator): PR-E E7 — re-export analyze_complexity from lib.rs CI lint flagged analyze_complexity as unused (no external consumers in lib). Add to the existing dimension re-export block alongside analyze_symbolic_cost_dimension. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * docs(evaluator): PR-E E7 — refresh analyze_complexity rustdoc post-E5 Reviewer noted "Pre-E5" framing in the rustdoc was stale: eval_node now dispatches Behavior::Loop (E5 landed at lib.rs:251). Wording now clarifies the wrapper is lens-spine-driven (not body-evaluator-driven), and stays the single-authority complexity entrypoint until analyze_with_evaluator lands — independent of E5 status. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Summary
Per Director dispatch after #1452 merge: docs/test-plan only readiness brief for the first executable E7 slice that ships symbolic-cost-only before E5 (Loop), TenantFlow, or IfcLabel carriers land.
Key observation
The existing
analyze_symbolic_cost_dimension(src/v3/compiler/src/dimension.rs:158-215) walksbehavior_spine_in_node_orderdirectly viasymbolic_cost_of(lens_cost_symbolic_generated.rs:9), not throughevaluate_body. The lens-spine path covers all fiveBehaviorvariants includingLoopstructurally — so symbolic-cost-only is implementable today without E5eval_nodeLoop coverage. The slice is a thin publicanalyze_complexitywrapper over the live analyzer.Brief contents
docs/briefs/r3-evaluator-e7-symbolic-cost-only-follow-on-readiness.md:pub fn analyze_complexity(dag: &Dag, workflow_root: NodeId) -> DimensionReport<SymbolicCost>.analyze_symbolic_cost_dimension— single-authority over the lens-spine path; no parallel analyzer.Witness.reason.Behavior::Bindcoverage,TenantFlowcarrier,IfcLabelcarrier, dedicatedDiagnostic::CostMissingvariant, Bool-as-Disj bridge (Substrate session/jolly-ram-908 · jolly-ram-908 #1130).analyze_*entrypoint, noanalyze_with_evaluator, no newDiagnostic/Witness/DimensionReportvariant, noLensRunnerView<C>trait, no carrier introduction.Constraints upheld
Test plan
🤖 Generated with Claude Code