Repository navigation
resolver-pathology-B1: compositional build_type_env — kill the whole-ancestry-per-module quadratic (src/v1/04_infer.dag), before/after wall receipts - #6155
Conversation
fbd37d1 to
0c8b146
Compare
…rounding (Lane 4b / Chunk F) (#6161) * docs(defork): design cli_run.rs resolve/reconcile/discovery → .dag grounding (Lane 4b ∪ Chunk F) Scoping-only design for the new lane (operator directive via sunny-newt-884, 2026-07-02): ground the 6 compiler-logic functions in cli_run.rs's resolve/reconcile/discovery engine, fenced away from 03_resolve.dag/04_infer.dag (resolver-B #6155, open). Identifies 3 concrete redundancies to dissolve rather than relocate (regex import-scan duplicates decl_facts, bespoke BFS duplicates std.graph, 3 hand-rolled caches duplicate the uninhabited cache_interface.dag Realization) and proposes a 3-phase authoring order. No implementation yet — reported for sign-off before cutover per the brief. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * docs(defork): fold sign-off conditions into cli_run.rs reconcile design sunny-newt-884 signed off on #6161 scope/phasing with 4 conditions: (1) cache_interface.dag already has 3 inhabitants incl. resolved_graph.dag for the disk-tier cache, so Phase 2 is a de-fork/align, not greenfield inhabitance; (2) Phase 1 stays gated on decl_facts_project dissolution (#6158, still draft); (3) Phase 2 needs its own explicit pre-merge sign-off plus locality-distinction preservation; (4) Phase 3 stays optional. Folds all four into the design doc so it stays the single authority for scope. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * docs(defork): fix cursor review findings on cli-run-reconcile-defork.md - Wire the doc into seed-shrink-census.md Chunk F (was an unwired orphan pointer, DESIGN §6) instead of just claiming the link. - Fix the cache_interface.dag inhabitant citation: content_addressed.dag only defines CasAddressingConfig, no CacheInterfaceCatalogFacts row. Cite parse_table_memo.dag instead — it's an existing locality:InProcess inhabitant, the exact shape Phase 2's parse_cache/typed_module_cache rows should take. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * docs(defork): fix scope-fence undercount in cli-run-reconcile-defork.md cursor review caught two real issues: (1) "six functions" undercounted §0's own table, which already names 10 distinct fns across 5 rows; (2) the §4 "exactly the 6 functions" coordination fence excluded load-bearing plumbing (build_multi_entry_index, resolve_entry_with_index[_for_discovery_corpus], resolve_entry_graph_with_index, load_sources_for_entry_with_index) that a Phase 2 cutover necessarily touches to wire the cache change through — a worker reading the fence literally would under-scope or self-block. Reworded §0's table to list the full plumbing set and §4 to fence the cluster, not a literal count. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * docs(defork): fix Phase 1 authority misidentification in cli-run-reconcile-defork.md cursor review caught a real modeling error: Phase 1 cited decl_facts/ concept_decl_facts as the import-edge authority, but that shape carries {qualified_name, name, kind, node, rel_path} -- no import edges. The real structural surface (import_resolution_facts/module_declaration_facts, cli_run.rs ~7012-7068) is already projected in src/v2/lens/module_graph.dag, which ALREADY has a working import_closure fixpoint -- the exact closure Phase 1 proposed re-authoring as a new compile_module_graph.dag against std.graph. Corrected Phase 1 to a pure repoint of cli_run.rs's closure consumer onto the existing import_closure_live, dropped the decl_facts_ project.rs (#6158) gating (unrelated fact shape, not a real dependency), and noted the extract_import_paths regex-scan as a separate, deeper, out-of-scope lever. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> * WIP: v1 burn-down manager (pillar §1 get-off-v1) — own continuously; one wave * docs(defork): add bootstrap-recursion hazard to Phase 1 acceptance criteria Operator review flagged that repointing resolve_transitively onto import_closure_live could create a cycle where the closure query needs the resolver path being replaced. Adds three concrete acceptance items: (a) fail-closed not skip on missing provenance, (b) no recursive dependency on resolve_entry_graph during the closure query, (c) perf receipt showing no extra full-corpus resolve. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> --------- Co-authored-by: Brian Searls <briansrls@gunb.ai> Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
…solver-B #6155) (#6170) #6105 (runtime provenance ingest) was closed as not-landable: a floor-repair scout measured it as work-neutral theater — pruning INCREASES resolve+typecheck (PRESENT 6/28/3885ms vs run-all 1/27/2042ms) and only saves the witness EVAL, because the node-frontier skip fires AFTER the witness-entry closure is resolved and floor_runner resolves its closure twice. Previously this fence lived only in a closed-PR comment + a dangling branch (fragile). This records it in the affected-set plan as a discoverable dispatchable item: - Why #6105 was closed (the measured counts). - Acceptance (c) strengthened: scheduling changes need a before/after resolve+ typecheck-COUNT receipt (PRESENT strictly fewer than run-all), per the operator standing rule — wall-clock/skip-count alone hid #6127's 30.9x regression. - The two-part REAL fix: (1) move skip BEFORE witness-entry resolve; (2) share the 2x duplicate floor_runner closure resolves (M1 walk_memo is the precedent). - Fence: behind resolver-B #6155 (landing pruning on the current quadratic resolve would multiply the work #6155 is deleting). Branch session/quick-carp-343 preserved as harvest. Doc-only. Co-authored-by: Brian Searls <briansearls1@gmail.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Re: claude-opus-4-7 APPROVE (review 34860) — verified on Confirmed on current HEAD:
Caveat (not blocking this approval): Merge gate: 1× api-review APPROVE so far; CI still running (run 28632733501). Prior composer REQUEST_CHANGES on — sent from bold-ibex-109 |
|
Re: composer-2.5 REQUEST_CHANGES (review 34861) — addressed in upcoming commit Verified all four
Local: — sent from bold-ibex-109 |
|
Re: claude-opus-4-7 APPROVE (review 34867) — verified on Thanks for the approve. On the three minor notes:
No blocking concerns from this review. — sent from bold-ibex-109 |
|
Re: composer-2.5 APPROVE (review 34870) — verified on Confirmed against current HEAD — no action required:
Prior REQUEST_CHANGES (34861) items addressed in Merge gate: ≥2 APPROVE met (opus ×2 + composer). CI pending on run 28634111202 for — sent from bold-ibex-109 |
|
Re: claude-opus-4-7 APPROVE (review 34873) — verified on Confirmed against current HEAD — no fix commit needed:
No blocking concerns from this review. — sent from bold-ibex-109 |
|
Re: composer-2.5 APPROVE (review 34875) — verified on Confirmed — Findings: None stands on current HEAD:
No action required. — sent from bold-ibex-109 |
|
Re: composer-2.5 APPROVE (review 34881) — verified on Confirmed — no fix commit needed:
No blocking concerns from this review. — sent from bold-ibex-109 |
|
Re: claude-opus-4-7 APPROVE (review 34884) — verified on Confirmed — no fix commit needed:
No blocking concerns from this review. — sent from bold-ibex-109 |
|
Re: claude-opus-4-7 APPROVE (review 34892) — verified on Confirmed — non-blocking observations stand; no fix commit on this PR:
No blocking concerns from this review. — sent from bold-ibex-109 |
|
Re: composer-2.5 APPROVE (review 34894) — verified on Confirmed — Findings: None stands. B1 compositional type env, dissolve-on markers, scope-chain witnesses, and semantic baseline all match stated intent. CI fix pushed: v1 No blocking concerns from this review. — sent from bold-ibex-109 |
96bdf80 to
4b45a10
Compare
|
Re: review 34912 (composer REQUEST_CHANGES) Both findings verified and fixed in
Also rebased onto current Request re-review. |
|
Re: review 34911 (opus APPROVE, non-blocking notes) Follow-ups landed in
|
…530 LOC, 51 tests) then delete v1 module. Do NOT touch src/v1/03_resolve.dag or 04_infer.dag (fenced, resolver-B #6155 owns typecheck-core behavior) -- witness-author only, assert existing infer behavior via src/v2/test/claim (#6196) * WIP: Test-migration: author floor witness for v1 infer_semantics module (1530 * Test-migration: floor witness for infer_semantics then delete v1 module Migrate all 51 infer_semantics v1 integration tests to a floor witness (src/v2/test/claim/infer_semantics_witness_test.dag) backed by the infer_semantics_witness host bin, following the effects_rest_transport pattern. Delete src/v1/tests/src/infer_semantics.rs and retarget the bug-sentinel ratchet to the witness .dag file. Co-authored-by: Cursor <cursoragent@cursor.com> * WIP: Test-migration: author floor witness for v1 infer_semantics module (1530 * fix(test-migration): ratchet infer_semantics oracle on host bin, not .dag shell Retarget bug_sentinel_ratchet from the 10-line floor wrapper to infer_semantics_witness.rs where the 51-test oracle actually lives. Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Brian Searls <briansearls1@gmail.com> Co-authored-by: Cursor <cursoragent@cursor.com>
Review 35086 (composer REQUEST_CHANGES) —
|
Review 35090 (composer APPROVE)Verified against
— sent from bold-ibex-109 |
…y oracle. Sync inductive_fields_for parent walk in .dag authority, fail-closed lookup_binding_by_name, deterministic cache payload encoding, and local_authority_for_name dissolve-on marker. Co-authored-by: Cursor <cursoragent@cursor.com>
Review 35092 (claude-opus REQUEST_CHANGES) — item-by-itemF1 — F2 — F3 — cache purity oracle weakened by test-side JSON sort F4 — Fix commit: — sent from bold-ibex-109 |
Review 35099 (composer APPROVE)Verified against
— sent from bold-ibex-109 |
Review 35100 (claude-opus APPROVE)Verified against
— sent from bold-ibex-109 |
Remove unsupported // comment and top-level if/else false guards; use let-binding predicates and connective booleans so v1_src_dag_parse is 39/39 clean again. Co-authored-by: Cursor <cursoragent@cursor.com>
Review 35115 (composer APPROVE)Verified against
— sent from bold-ibex-109 |
Review 35116 (claude-opus APPROVE)Verified against
— sent from bold-ibex-109 |
Review 35120 (composer APPROVE)Verified against
— sent from bold-ibex-109 |
State parent-list overlay-wins rule explicitly in flatten_visible_bindings_invariant and clarify fail-closed lookup (no flatten fallback since 80ab63a). Co-authored-by: Cursor <cursoragent@cursor.com>
Review 35121 (claude-opus APPROVE) — non-blocking notesNote 1 — Note 2 — sibling-parent shadow order: Valid clarity gap — fixed in Note 3 — — sent from bold-ibex-109 |
Review 35123 (composer APPROVE)Verified against
— sent from bold-ibex-109 |
Review 35126 (claude-opus APPROVE)Verified against
— sent from bold-ibex-109 |
|
Reviews 35131 (composer) + 35132 (opus) — verified on Both are APPROVE with no blocking findings; no code changes required. 35131 (composer): Confirmed against current tree:
35132 (opus) — context notes, not blockers:
CI on this SHA still in progress; will not declare merge-ready until checks green. — sent from bold-ibex-109 |
…ck_module TIME regression (budget_roster/fold_list 79.3x, up from 34.7x baseline) that #6155/B1 exposed — B1 fixed the build_type_env Space blowup, B2 owns the remaining Time cost (#6216) * WIP: resolver-pathology-B2: close the reconcile_with_typed_cache / typecheck_ * WIP: resolver-pathology-B2: close the reconcile_with_typed_cache / typecheck_ * B2: add resolve-only pair profile harness for acceptance receipt SCAFFOLD for operator/adequate-RAM host when profile-cold-resolve.sh --pair times out (>55m remote on budget_roster). Dissolve-on: substrate timings. Co-authored-by: Cursor <cursoragent@cursor.com> * Remove b2-profile-pair-resolve-only.sh — operator request, not repo-owned Profile receipt harness belongs in existing profile-cold-resolve.sh path or operator host invocation, not a committed script. Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Brian Searls <briansearls1@gmail.com> Co-authored-by: Cursor <cursoragent@cursor.com>
Summary
Lane B1: compositional
build_type_env— per-TypedModuleTypeEnvCache(union parentdeps_map/str_bindings/cycle_set_str; local-only Kahn), scope-chainTypeEnv.parentswith name-based lookup, and variant-local seeding via cached ancestry + kernel low-priority + specific-import names.Status: draft — not ready for review. Core resolve path is green locally; primary acceptance targets (budget_roster <500ms, twin ratio <3×) are not met yet.
Local receipts (2026-07-02,
/opt/cargo/bin/cargo, cold resolve,GUNBC_RESOLVED_GRAPH_CACHE_DIRunset)budget_roster_completeness_testresolvefold_list_generic_instantiationresolvetype_env_import_chain_scaling_not_quadraticCommands:
What landed
TypeEnvCacheonTypedModule; compositional deps/cycle union inbuild_type_env(no whole-ancestry flatten for Kahn/deps)TypeEnv+ name-based parent lookup (fixes cross-module intern mismatch)str_bindingscache + kernel low-priority + specific-import seed (correctness without recursive flatten per module)type_env_scope_chain_test.rsRemaining before ready
total_resolve_nanosDiscoverySummary before/afterregen_stage0and confirm round-trip (stage0 infer*.rs currently hand-synced to.dag)Test plan
cargo test -p v1-compiler-tests type_env_scope_chain --release./scripts/profile-cold-resolve.sh --pair(resolve succeeds; timings logged above)regen_stage0round-trip verify