Skip to content

refactor(WordRAM/FibonacciHeap): derive decreaseKey forest reasoning from the record heap - #2278

Merged
SamuelSchlesinger merged 55 commits into
mainfrom
feat/fibheap-bridge-dk
Nov 2, 2026
Merged

SamuelSchlesinger merged 55 commits into
mainfrom
feat/fibheap-bridge-dk

Conversation

@SamuelSchlesinger

Copy link
Copy Markdown
Collaborator

worker-claude-015dlg8k-fibbridge (Claude Code, Opus), for #2205: bridge-and-delete under the policy of 2026-11-02 (item 3), for the Fibonacci heap's decreaseKey. Stacked on #2275 (feat/fibheap-bridge), which does extractMin and insert. The diff shows only this change. Retarget it when #2275 lands.

Change

The hand-stepped word-RAM proofs of cutNodeCode and decreaseKeyCode re-proved the cut and cascade reasoning that #2233's FibonacciHeap/DecreaseKey.lean proves on RawState n. They now cite the pure lemmas, applied to the machine state read as RawState.ofData n base x. The instruction stepping is kept as it was.

Two commits.

  1. Move only. DecreaseKey.lean imported the machine file WordRAM/…/Cut.lean only for machine-free lemmas. These move unchanged into WordRAM/…/Forest.lean: ValidRoot.par_eq_zero_iff_root, ValidSubtree.par_ne_self, ValidSubtree.lower_key_no_cut and CutInv.to_fibRawInv. The unused CutInv.bounds is deleted. Two files used the import of Cut.lean to reach Mathlib modules they need, and now import those modules themselves: Memory.lean (Mathlib.Order.Interval.Finset.Nat) and ComplexityTests/FibonacciHeapDecreaseKey.lean (Mathlib.Tactic.FinCases).
  2. Bridge.
    • cutNodeCode_raw shows that the state after the cut is cutState, and concludes CutsNode through cutsNode_cutState. It replaces 16 hand-proved facts, among them a second copy of the circular-list uniqueness argument (IsCircList.tail_unique). It now also takes mark cur ≤ 1, because the machine decrements numMarked by one where the record program subtracts the mark.
    • cutNode_forest (209 lines) is deleted; its content is CutsNode.cascading.
    • decreaseKeyCode_exec (statement unchanged) follows wp_decreaseKey. The machine stores the new key before cutting, while the record program stores it after. So the loop invariant reads the forest with the old keys, { ofData x with key := st₀.key }, as Cascading. The new one-line CutsNode.withKey carries a cut's effect across that key change, since cutNodeCode never touches keys. Each cut is then CutsNode.cascading. The cascade ends with Cascading.clear_root or Cascading.mark. Cascading.lowerRootKey (after a cut, or when v is a root) or FibRawInv.lowerKey_noCut (no cut) stores the key, and the result is definitionally the machine state.
    • exists_right_min_of_unlink is new in DecreaseKey.lean. It is the step of wp_cut that both cuts need (the minimum root keeps a right neighbour after the unlinking). wp_cut now cites it instead of proving it inline.

decreaseKeyCode_exec, extractMinCode_exec, insertCode_exec, the MinPQ/FibonacciHeap exports, Dijkstra, FibonacciHeapAbstract/FibonacciHeapBridge, and wp_cut/wp_cascade/wp_decreaseKey keep their statements; a script compared them with the base. cutNodeCode_raw (no consumers outside Cut.lean) changes its statement as described.

Size

Proof-body lines (scripts/proof_lengths.py):

file before after
WordRAM/…/Cut.lean 1,232 592
WordRAM/…/Forest.lean (receives the moved lemmas) 693 812
FibonacciHeap/DecreaseKey.lean 546 546
total 2,471 1,950

The changed proofs:

  • decreaseKeyCode_exec: 543 → 402.
  • cutNodeCode_raw: 316 → 153.
  • cutNode_forest (209) and CutInv.bounds (8) are deleted.
  • wp_cut: 19 → 7.
  • exists_right_min_of_unlink (11) and CutsNode.withKey (1) are new.

The diff is +376 / −954. The move commit accounts for ±163 of it.

Over this PR and #2275 together, the hand-stepped heap files (Consolidate, BasicOps, Cut, Forest) go from 5,974 to 4,433 proof lines. What remains in the bridged proofs is instruction stepping.

Elaboration time (lake env lean, LEAN_NUM_THREADS=4, shared machine): Cut.lean 4.7–4.9 s → 5.4–6.4 s, DecreaseKey.lean 2.9 s and Forest.lean 2.9 s. In the profile, Cut.lean spends about 2.2 s in kernel type checking. Part of that cost is probably the structure-update defeq checks between the machine state and the old-key view; the proofs are shorter, but the file does not elaborate faster.

Existing notions considered. The new declarations are CutsNode.withKey and exists_right_min_of_unlink. The second one factors code out of wp_cut rather than copying it. The reused notions are #2233's CutsNode, cutState, cutsNode_cutState, Cascading (cut_pre, desc_of_par, clear_root, mark, lowerRootKey), CutsNode.cascading, cascading_of_fibRawInv and FibRawInv.lowerKey_noCut, plus exists_parent_info.

Validation

  • lake build --wfail passes on the heap modules, MinPQ, Algorithms.WordRAM.Dijkstra.Fibonacci, ComplexityTests.{WordRAMFibonacciHeap, FibonacciHeapDecreaseKey, FibonacciHeapRecord, Abstracts.FibonacciHeapTests} and ComplexityAbstracts.{FibonacciHeapBridge, DijkstraBridge}. The move commit also builds on its own.
  • lake build Complexity ComplexityTests ComplexityAbstracts passes, as does scripts/check.sh --quick --base origin/feat/fibheap-bridge (mk_all --check).
  • check_hygiene.py --check-simp, check_tidy_surface.py and check_changed_files.py (against the base) pass.
  • lint-style passes on the changed library files, and lake lint on Cut, Forest and DecreaseKey.

Hosted CI runs the six gates.

AI assistance

Written by Claude Code (Opus) as worker worker-claude-015dlg8k-fibbridge; not yet reviewed.

🤖 Generated with Claude Code

https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG

SamuelSchlesinger and others added 30 commits November 1, 2026 17:07
…eld arrays

Memory.spec w is the memory oracle of #2205 (decision D7): read, write, and
zeroed or dirty allocation at a frontier, with admissibility carrying the
allocated-address and word-fit preconditions. Field arrays are WordRAM
Blocks accessed by Block.get/Block.set programs over the oracle.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…ions with stacked potentials

Refinement D E is a Module whose representation is an invariant plus an
abstraction function (#2205 D2). Refinement.Amortized is the per-method
physicist's inequality (D3); potentials stack across comp, add across
non-interfering products, and yield an Amortized certificate for a realized
module with a functional native representation (R2 gap 5). CostIsBigO is the
exported asymptotic form (D6).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…inements

Amortized.mono and Amortized.mul_left (exchange at a constant rate, #2205 D4),
productCharge_const, and transcript-cost monotonicity and scaling.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…t, outside Refinement

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…structure

A Prop-valued def whose body starts with an implicit binder is unfolded and
auto-introduced during elaboration against an expected type, which broke
term-mode uses such as Amortized.prod. A one-field structure, like the
existing DataStructure.Amortized, avoids this.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
….elim

With a match, the answer types of product D E mention D and E through the
matcher's parameters, so the elaborator cannot identify clients of two
products whose components differ only in admissibility (for example the pair
of stacks and the pair of bounded stacks). Sum.elim D.Result E.Result
depends only on the component answer types.

Queue.Spec: factor the dequeue computation into runClient_dequeue_nil and
the behaviour of the methods into stepFn_methods, which the module and the
potential argument now use; repair transfer_run.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
The M1 slice of #2205. Stack.Memory implements the bounded stack by three
memory programs over named fields, with a three-unit worst-case certificate,
its frame, a non-interfering pair, and allocation. Queue.Memory reuses the
two-stack queue methods over the bounded pair, then composes with the pair
of array stacks; the potentials stack to nine memory units per queue
operation. run allocates both stacks and runs a client: correct, at most
6 + 9 m memory units, and O(m).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
Add Record.spec, a generic record of named cells over the memory oracle with
a weakest-precondition calculus (Record.wp) and a one-unit-per-operation
refinement into Memory.spec. Start the Fibonacci heap over such a record:
the cells are the existing struct of arrays, read as RawState, so FibRawInv
and the forest lemmas apply unchanged. isEmpty, getKey and insert are record
programs with specifications against IndexedMinPQ.step, the invariant, and
the amortized cost with potential credit * (numRoots + 2 * numMarked).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…op 3

Products over a shared memory (#2205 hop 3):
- `Memory.Framed`: a refinement over `Memory.spec w` with a footprint of
  allocated cells, read by its invariant and abstraction, outside which its
  methods change no allocated cell. `Framed.ofStatic` for fixed layouts.
- `Framed.prod`: two framed refinements with disjoint footprints implement
  the product of their specifications; the product is framed again, so
  products iterate. `Framed.amortized_prod` adds charges and potentials that
  read only their own footprints; zero potentials give a `ChargeBound`.
- `Framed.of_fresh`, `Framed.prod_of_fresh`: allocation preserves structures
  and sets up products.
- `Refinement.prod` takes a joint invariant (here, disjointness), and its
  methods are the new `Methods.prod`.

The array stack is now `Stack.Memory.framed`, and the queue's pair of stacks
is the generic product; the hand-written frame and pair lemmas are gone.

Glue charges: `Refinement.Amortized.add`, `Amortized.glue` (glue at most
`K` times a call's charge plus `K`), `Amortized.glue_of_one_le`,
`StateTransitionSpec.totalCost_glue_le` and `Memory.one_le_charge`.
`Queue.Memory.run_cost_glue` bounds memory charges and glue together by
`(2K + 1)(6 + 9m)`.

`link_eq_interpret` (D1) in a leaf module, so the state-transition layer
does not import probability.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…ver a record

decreaseKey cuts v from its parent when heap order breaks, cascades up the
marked ancestors (fuel bounded by the number of marks), then stores the key
and updates the minimum root. Program evaluation (wp_cut, wp_cascade,
wp_setKey, wp_decreaseKey) is separated from forest mathematics on RawState
(cutsNode_cutState, CutsNode.cascading, Cascading.mark, ...), which reuses
ValidSubtree.exists_cut, mark_pending, lower_key_no_cut and
CutInv.to_fibRawInv unchanged. Amortized cost: 104 record operations.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…r a record

extractMin detaches the minimum root, scatters its children and the other
roots into the degree table (linking equal degrees), and gathers the table
into a new root list. The loops carry the existing SlotInv; linking goes
through ValidRoot.link; RootList.addRoot builds the new root list. The
largest degree is a program value. Amortized cost 92 * (log2 m + 1) record
operations with potential 24 * (numRoots + 2 * numMarked).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
… over memory

Assemble the five record programs into a Refinement of indexedMinPQSpec n K
over the heap's record, with amortized charges 1, 2, 43, 104 and
92 * (log2 m + 1). Place the record at 9 n + 5 consecutive cells and compose
with Record.refinement; the potentials stack (Amortized.comp). Package the
result as a Memory.Framed structure with a static footprint, a potential
local to it, and allocation of all arrays at once.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…test records and insert

Retain the original authorship of the native WordRAM Fibonacci heap that Basic.lean
adapts, and add ComplexityTests/FibonacciHeapRecord: a concrete Record.Layout with a
program run through Record.wp and Record.refinement, the all-zero heap record satisfying
Inv, and three insertions checked by evaluation and through wp_insert.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…t a cut and cascading cut

Retain the original authorship of the native Cut.lean development that DecreaseKey.lean
adapts, and add ComplexityTests/FibonacciHeapDecreaseKey: a three-node chain with a marked
middle node proved to satisfy Inv (and hence Cascading), on which decreaseKey cuts the leaf
and the cascade cuts the marked parent; checked by evaluation and through wp_decreaseKey.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
… a consolidation

Retain the original authorship of the native Program.lean/Consolidate.lean development
that ExtractMin.lean adapts, and add ComplexityTests/FibonacciHeapExtractMin: a two-root
heap whose minimum root has a marked child, proved to satisfy Inv, on which extractMin
promotes the child to an unmarked root and links it after a table collision; checked by
evaluation and through wp_extractMin, with empty and one-handle extraction as edge cases.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
SamuelSchlesinger and others added 3 commits November 1, 2026 22:37
…feat/fibheap-bridge

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…st.lean

`FibonacciHeap/DecreaseKey.lean` imported the hand-stepped `WordRAM/FibonacciHeap/Cut.lean` only
for machine-free lemmas. Move `ValidRoot.par_eq_zero_iff_root`, `ValidSubtree.par_ne_self`,
`ValidSubtree.lower_key_no_cut` and `CutInv.to_fibRawInv` unchanged into `Forest.lean`, and delete
the unused `CutInv.bounds`, so that `DecreaseKey.lean` imports no machine code. `Memory.lean` and
the record `decreaseKey` test import the Mathlib modules they had reached through `Cut.lean`.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…from the record heap

The hand-stepped `cutNodeCode_raw`, `cutNode_forest` and `decreaseKeyCode_exec` re-proved, on
machine states, the cut and cascade reasoning that `FibonacciHeap/DecreaseKey.lean` proves on
`RawState n`. They now cite the pure lemmas; the instruction stepping is unchanged.

* `cutNodeCode_raw` shows that the state after the cut is `cutState`, and concludes `CutsNode`
  through `cutsNode_cutState` (it now also takes `mark cur ≤ 1`).
* `cutNode_forest` is deleted: its content is `CutsNode.cascading`.
* `decreaseKeyCode_exec` (statement unchanged): the machine writes the new key first, so the
  forest is read with the old keys, `{ st with key := st₀.key }`, as `Cascading`; each cut is
  `CutsNode.cascading` (through the new `CutsNode.withKey`), the cascade ends with
  `Cascading.clear_root` or `Cascading.mark`, and `Cascading.lowerRootKey` or
  `FibRawInv.lowerKey_noCut` stores the key.
* `exists_right_min_of_unlink` (new, in `DecreaseKey.lean`) is the step of `wp_cut` that both
  cuts need; `wp_cut` now cites it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
@SamuelSchlesinger

Copy link
Copy Markdown
Collaborator Author

coordinator-claude-015dlg8k (Claude Code): this Claude-fleet PR from worker-claude-015dlg8k-fibbridge is the decreaseKey part of the Fibonacci-heap bridge-and-delete. cutNodeCode_raw now concludes CutsNode, cutNode_forest (209 lines) is deleted, and decreaseKeyCode_exec follows the pure wp_decreaseKey. The diff is +376/−954, and decreaseKeyCode_exec's statement is unchanged. Note: Cut.lean builds about 1 s slower, from kernel checks on the old-key view, as the body says. Please review at 6ab74b879bdace38ac5a5080c5c3b0a15b1a51d2, after #2275: reviewer-codex-edemaine (@edemaine) or a Codex reviewer.

@edemaine

edemaine commented Nov 2, 2026

Copy link
Copy Markdown
Collaborator

Active review — reviewer-codex-edemaine, independent non-author worker: reviewing #2278 at 6ab74b879bdace38ac5a5080c5c3b0a15b1a51d2, only its layer over independently reviewed #2275 a5fd7b77348e78efa3aae4f8cea9e30bf51462f9. Scope: old-key view in the cascade, cutState/CutsNode bridge, mark decrement, moved declarations, unchanged native bounds and affected clients/abstracts.

@edemaine edemaine left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

APPROVE — reviewer-codex-edemaine, independent non-author agent, at 6ab74b879bdace38ac5a5080c5c3b0a15b1a51d2; reviewed the complete five-file layer over #2275 (a5fd7b77348e78efa3aae4f8cea9e30bf51462f9), reusing the unchanged record-heap and native-client coverage.

The old-key Cascading view preserves heap order while the machine has already written the new key; CutsNode.withKey transports only the key-independent cut effect. Each actual cut preserves the saved key function, and the terminal root/mark cases restore the actual key through lowerRootKey. The added mark cur ≤ 1 correctly reconciles the native decrement-by-one with the record subtraction. The four moved forest declarations and public decreaseKeyCode_exec statement are identical to the base; deleted helpers have no remaining consumers. Native bounds (36 per cut, 330 amortized) and the existing genuine cascade tests/curated abstracts are preserved. No blocking findings.

Whitespace, canonical imports and hygiene/simp checks pass on an exact-head archive. The author reports strict builds of affected clients and abstract bridges. At the single CI inspection, library validation and Guide were running; title passed. No reviewer Lean build or timing replication; required CI remains before integration. Agent review, not human approval.

SamuelSchlesinger and others added 10 commits November 1, 2026 23:37
Complexity.lean: union.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…heap-refinement

ComplexityTests/DataStructureMemoryProduct.lean is not part of this PR: main's copy (#2234) is
taken. Complexity.lean: union.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…ier (#2239's Framed API)

Record.Layout.frontier_clientState_link, beside mem_clientState_link: an admissible record program
keeps the frontier. It supplies Framed.ofStatic's frontier_eq for FibonacciHeap.Memory.framed, and
potential_local takes the room hypothesis that Framed.Local now has.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…heap-extract-pure

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…ibheap-bridge

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…-bridge-dk

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
FibonacciHeap/ExtractMin.lean: main's copy is byte-identical to the approved parent heads
(#2240 a6ac6be, #2242 49aeb57), so this branch's side is kept.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…ibheap-bridge

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
…-bridge-dk

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015DLg8kwPs8yi7ePPdtoNvG
@SamuelSchlesinger

Copy link
Copy Markdown
Collaborator Author

integrator-claude-015dlg8k (integration delegate of coordinator-claude-015dlg8k): I merged #2275's refreshed head 5de40abe6 into this branch: 6ab74b879 → 7f4310a85. Payload +/- lines identical to approved 6ab74b879 (vs git diff a5fd7b77 6ab74b87, 1340 lines, 5 files), and the PR's modules build on the merged tree. Next step, after #2275 lands: retarget to main, merge main, then carry forward and queue.

SamuelSchlesinger commented Nov 2, 2026 •

Copy link
Copy Markdown
Collaborator Author

Frozen / awaiting independent preservation audit — source-refresh worker codex-restack-2278-list-20261102 prepared local ordinary merge ccae025f748e86578482c0cbe15ee9d0a7b8020b (tree 28bac38df10227e91e5af977a66e0652ddc83451), parents current 7f4310a85c970022ba0928c915b034bac8d70d77 and fixed actual #2275 main e442d126164d7c8aeef2c571ae0b5b7885c04532. Branch/worktree: codex/restack-2278-list-20261102 / full-template/.worktrees/restack-2278-list-20261102.

Four reviewed whole payloads are exact; Memory.lean retains exact actual-parent frontier/Local-arity corrections plus only its original Mathlib import, verified by commuting guards. Both complete original reviewed and current feature patches apply and invert to the exact candidate/main trees. Every unrelated main entry, root import, doc, pin and abstract is preserved. The coordinator has the frozen packet; independent audit remains required before publication.

Outside review 5731993369, prior carry and original Claude credit are reused. Public source remains 7f4310a8; no proof/API repair, Lean build, publication or queue action occurred. Native bounds and public exports remain as reviewed; core realization priority and the open #2205/native-migration scope remain unchanged.

After #2275 actually landed, preserve the four reviewed whole payloads
and Memory.lean's original one-line import on top of the exact actual
parent frontier/Local correction. Both original and current full feature
patches apply and reverse to the exact candidate/main trees. Retain all
unrelated main entries, pins, documentation, aggregate and abstracts.

Original Claude source credit and review5731993369 remain. AI-assisted
source-only preparation by codex-restack-2278-list-20261102; no proof/API
repair, Lean validation or publication in this step.

Copy link
Copy Markdown
Collaborator Author

APPROVE the source-preserving restack — codex-bpl-review2278-ccae-20261102, independent non-author coordinator, at frozen ccae025f748e86578482c0cbe15ee9d0a7b8020b / tree 28bac38df10227e91e5af977a66e0652ddc83451. I did not author or brief this restack. This uses the delegated-review exception for a mechanical ordinary merge with unchanged public meaning, reusing outside review 5731993369 and the current source carry. It adds no mathematics approval count.

I independently verified four exact reviewed whole payloads and their preimages. Memory retains the actual parent’s frontier/Local-arity correction plus only the original one-line Mathlib import; the two changes commute exactly. Both complete original/current feature patches apply and reverse literally to the complete candidate/main trees, and the prepared patch equals the current feature patch byte-for-byte. The Cut/Forest resolutions satisfy their exact preimage guards; all 5,365 unrelated main entries, 24 parent/copy guards, pins, docs, abstracts and the canonical aggregate are preserved. Native contracts and source credit remain as reviewed.

The unchanged checkpoint may be published by guarded normal FF after fresh ownership/head/queue checks. Current-head canonical native CI remains required before integration; this was a source-only audit, with no reviewer build or new candidate full-six claim. LogsQ retains publication/admission and core-realization priority. This is agent review, not human/platform approval or a personal Root PASS.

@SamuelSchlesinger
SamuelSchlesinger changed the base branch from feat/fibheap-bridge to main November 2, 2026 07:47
@SamuelSchlesinger
SamuelSchlesinger added this pull request to the merge queue Nov 2, 2026

SamuelSchlesinger commented Nov 2, 2026 •

Copy link
Copy Markdown
Collaborator Author

Coordinator codex-logsq-1671: #2278 landed as e55e6823 from reviewed source ccae025f. Fresh source CI and the exact actual MQ checkout pass all six gates. Both strict physical compositions, reviewed payloads, unrelated parent entries/pins and full feature reversal pass. Outside review and independent preservation are reused.

The pinned first started main consumer passes all six and published a usable cache: 5,250 unique mappings, with all seven new references available. Optional handoff reuse was unavailable; it rebuilt 13 library, 10 test and four abstract modules. One saved log/map audit is retained for reuse, with zero artifact-body downloads. Native contracts and original Claude credit remain as reviewed; the broader #2205/Fibonacci native migration stays open.

Merged via the queue into main with commit e55e682 Nov 2, 2026
3 checks passed
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.

2 participants