Repository navigation
Re-pin door-ledger histogram receipt to current attributed frontier (#6551 moved determinism's refusal to the packaged-parse fork) - #6580
Merged
Conversation
…idate-once) grammar_validate_for_parse (5 whole-grammar checks + FIRST/nullable analysis, ~9.2s, all pure fns of the invariant grammar) ran inside parse_module — so a door call over a K-module import closure re-validated the SAME grammar K times, and compute_grammar_first_analysis ran twice per module (ambiguity check + parse_table_for_production). The cache-interface fields on ParseTableRealization (grammar_digest/materialization) were inert; the backend lookup is Miss-stubbed, so this was a recompute-per-module bug, not a missing cache. Fix (correctness by construction): PreparedGrammar carrier + prepare_grammar (well-formed + validate + analyze, once) hoisted ABOVE fold_list in program_assembly_fold_ingest; parse_module_prepared reuses it per module. parse_module / parse_production / parse_table_for_production / read_to_normalized_root keep backward-compatible wrappers (prepare then parse). Empty-ingest guarded so zero modules never pay the one-time prepare. Only fold_step's signature changed (internal, no external callers). Behavioral equivalence proven by execution: ledger histogram witness green with IDENTICAL causes (determinism->fact_density, error_primitives->resolve_unbound, bit->resolve_ambiguous_export); parse-table amortization green (2-file fold = one preparation, ~9.2s not ~18.4s); new empty-ingest guard witness green (4ms, no prepare). Cross-call content-addressed memo (across door calls) is the follow-up, gated on wiring the currently Miss-stubbed cache backend. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Re-pin the door-ledger cause-histogram receipt (
ledger_cause_histogram_over_mixed_affected_set, from #6540) to the current attributed frontier. The witness went RED on cleanmainafter #6551 (Determinism Phase A); this repins it to the causes the door actually produces today — no broadening.Why it went red (external, not a regression)
#6551 added a coproduct to
dag/std/determinism.dag:The ledger's admission pre-parse uses the packaged
parse(), which rejects coproduct-syntax modules atparse_grammar_choice_overlap_residue(the known packaged-parse fork —parse()rejects,parse_productiontolerates; MigrationOwned, dissolves with the packaged/parse_productionreconciliation). Sostd.determinism's refusal moved earlier — from thefact_densitylens (fact_density_hollow_alias_locus) to the parse fork — and no longer reaches the lens at all.Diagnosed by execution (per-module cause probe on clean
main, then deleted):std.determinism→parse_grammar_choice_overlap_residuestd.error_primitives→resolve_reason_unbound_symbolstd.bit→resolve_reason_unbound_symbolThe change (one test file, still discriminating)
This is not a masked-green broadening: it swaps one specific expected cause for another specific cause, and adds a discriminating
fact_density_hollow_alias_locus == 0check that would go RED if determinism regressed back to the lens. The receipt still tracks two distinct, correctly-attributed frontier causes over one real affected set (1 parse-cause + 2 resolve-causes).compile_door_ledger_witness_noteis updated to record the frontier move.The
fact_densitylens frontier is now covered by crisp-newt-633's dedicatedfact_densitywitnesses (#6579), not here.Verified green-by-execution
ledger_cause_histogram_over_mixed_affected_setPASS (~127s, wet, freshly-builtclaim_batch) onmain+this-edit. Re-verified on the post-merge tree.Test-only witness update; no substrate/pipeline change.
🤖 Generated with Claude Code