diff --git a/.claude/board/EPIPHANIES.md b/.claude/board/EPIPHANIES.md index e15f0efa..8d19ff49 100644 --- a/.claude/board/EPIPHANIES.md +++ b/.claude/board/EPIPHANIES.md @@ -1,3 +1,11 @@ +## 2026-07-16 — E-PALETTE-RESIDUAL-LADDER-1 — bgz-tensor's Hadamard-residual ladder = the honourable fourth mode next to the three flavours of 256; Hambly–Lyons signature as the [S] formal anchor + +**Status:** HONOURABLE-MENTION RULING (operator-directed) + [S] research anchor. No layout added to the §3 catalogue; no canon changed; the le-contract gains an append-only subsection. +**What:** next to the three flavours of 256 (E-H268-REPLAYABLE-TILE-1), a fourth **operational mode**: **index + residual**, shipped in `bgz-tensor/src/adaptive_codec.rs` — `AdaptiveRow { centroid_idx: u16, scale_bf16, scale2_bf16, … }` keeps the palette/CLAM centroid as the coarse deterministic PLACE and stores a **Hadamard-rotated residual** in a three-tier LFD split (corrected per codex P2 on #700, `classify_rows_by_lfd`): ~top-10% LFD rows → `Passthrough` (exact original stored, NO centroid/residual), next ~20% → i8 residual, bottom ~70% → i4+i2 cascade. Index PLACES, residual CORRECTS — the perturbation-pyramid place/magnitude decomposition with the magnitude side stored as a graded ladder. It is the **continuous-field exit** flat L4 cannot provide (first consumer instance, geo arc: 256 levels over ~1500 m relief ≈ 6 m elevation terraces; categorical surfaces — `Signed360` normals, harmonized colour — stay flat L4). Placement: NOT a ninth 12-byte layout — the ladder is **out-of-row** (same status as `Signed360` in the 96-bit carving); in-row refinement stays the turbovec 6×4-bit nibble lane. Also corrected in the same commit: lance-graph CLAUDE.md's stale "bgz-tensor 0 deps" row (it path-deps `ndarray` + `holograph`). +**Formal anchor:** Hambly–Lyons 2010 (Annals of Mathematics 171) — a bounded-variation path is determined by its signature (the graded iterated-integral cascade) up to tree-like equivalence; the theorem-shaped version of "a graded residual cascade determines the continuous field up to negligible equivalence" and of the replayable-trajectory framing. **Already in-workspace on both sides** (operator pointer, same day): jc **Pillar 11** (`crates/jc/src/hambly_lyons.rs`, feature `hambly-lyons` → `sigker`; forward/converse probes via Chen-identity tree-collapse + triangle level-2 signed area, on `signature_truncated` not the known-buggy `signature_kernel_pde`) and ndarray `src/hpc/pillar/signature.rs` (B7 signature transform + sig-kernel, Gram PSD check, 1 000-Lévy-path certification probe). Only the **ladder-levels → signature-levels mapping** stays [S] (consult [FORMAL-SCAFFOLD] before promoting); its probe builds on the existing Pillar-11 harnesses. +**Provenance caveat (operator, same day):** bgz-tensor predates turbovec/PolarQuant and helix — the mention records what ships, not a certification of current best practice; engineering follow-up review queued as `TD-BGZ-TENSOR-PRE-LANE-REVIEW` (reconcile the i4+i2 cascade vs turbovec Lloyd-Max/NativeLut, Hadamard vs the PolarQuant rotation findings, residual coding vs helix; consume-the-lane / demarcate / retire). +**Cross-ref:** `.claude/v3/soa_layout/le-contract.md` §3 "Honourable mention" subsection (the canonical text), E-H268-REPLAYABLE-TILE-1, ndarray `pr-x12-h268-morton-wgpu-synergies.md` §8, `TD-BGZ-TENSOR-PRE-LANE-REVIEW`, I-SUBSTRATE-MARKOV (untouched). + ## 2026-07-16 — E-H268-REPLAYABLE-TILE-1 — replayable Morton 2bit×2bit 4×4 tile: one substrate object serving H.268 mode-decision AND cognitive-shader dispatch; D-QUANTGATE rationale restated **Status:** SYNTHESIS + RATIONALE RESTATEMENT (design-consequence; every consequence probe-gated — no ruling changed, no kill condition weakened). diff --git a/.claude/board/LATEST_STATE.md b/.claude/board/LATEST_STATE.md index 24fc8410..5262e287 100644 --- a/.claude/board/LATEST_STATE.md +++ b/.claude/board/LATEST_STATE.md @@ -1,5 +1,18 @@ # LATEST_STATE — What Just Shipped (read this FIRST) +## 2026-07-16 — branch `claude/x265-x266-plans-review-h9osnl` (v4, post-#699) — Hadamard-residual-ladder honourable mention on the V3 substrate + +Doc-only. #698 and #699 MERGED same day; this follow-up adds: the +le-contract §3 "Honourable mention" subsection (bgz-tensor's index + +Hadamard-residual ladder as the fourth operational mode next to the three +flavours of 256, out-of-row, with the Hambly–Lyons 2010 signature theorem +as the formal anchor — already in-workspace as jc Pillar 11 + +ndarray hpc/pillar/signature.rs B7; only the ladder→signature mapping +stays [S]), EPIPHANIES `E-PALETTE-RESIDUAL-LADDER-1`, and +the CLAUDE.md stale "bgz-tensor 0 deps" row correction (it path-deps +ndarray + holograph). No layout added to the §3 catalogue; no contract +types touched. + ## 2026-07-16 — branch `claude/x265-x266-plans-review-h9osnl` (v3, post-#697) — comma-closure/96-bit facet/replayable-tile addendum Doc-only. #697 (PROBE-GPU-LUT oracle spec pinned) MERGED same day; this diff --git a/.claude/board/TECH_DEBT.md b/.claude/board/TECH_DEBT.md index f934eca5..12120de3 100644 --- a/.claude/board/TECH_DEBT.md +++ b/.claude/board/TECH_DEBT.md @@ -1,5 +1,34 @@ # Technical Debt Log — Open + Paid (double-entry, append-only) +## TD-BGZ-TENSOR-PRE-LANE-REVIEW — bgz-tensor's adaptive codec predates turbovec/PolarQuant/helix; engineering follow-up review queued (2026-07-16) + +**Open.** Operator nudge: `bgz-tensor` (incl. `adaptive_codec.rs`'s +Passthrough/i8/i4+i2 residual ladder and the Hadamard rotation, honoured +on the V3 substrate per `E-PALETTE-RESIDUAL-LADDER-1`) was engineered +BEFORE turbovec/PolarQuant and helix existed — its design choices were +made without today's lane inventory. The honourable mention records what +ships; it does NOT certify that what ships is what we would build now. +**Review scope (pay by an engineering follow-up review, then reconcile or +demarcate):** +(a) the i4+i2 residual cascade vs turbovec's Lloyd-Max 2/3/4-bit +quantizers + `NativeLut` (the measured 11.4× kernel-shape receipt) — is +the cascade a pre-turbovec reinvention that should consume the turbovec +lane? +(b) the Hadamard rotation vs the PolarQuant rotation-vs-error-correction +findings (`docs/ROTATION_VS_ERROR_CORRECTION.md`, thinking-engine +`polarquant_hip_probe.rs` / `turboquant_correction_probe.rs`) — same +job, two mechanisms; which survives? +(c) residual/location coding vs helix `ResidueEdge`/`Signed360` + the +`CurveRuler` coprime walk — bgz-tensor stores what helix can partly +derive; +(d) whether the Passthrough top-10% tier's cases could route to an +existing full-precision/`Signed360`-style lane instead of a bespoke +escape. +Outcome shapes: consume-the-lane refactor / explicit demarcation +doc-comment ("predates X, kept because Y") / retirement of the redundant +half. Cross-ref: `E-PALETTE-RESIDUAL-LADDER-1`, le-contract §3 +honourable-mention subsection (carries a pointer to this entry). + ## TD-RUNG2-144-VOCAB-SPLIT — the two 144s of rung 2 are divergent vocabularies (2026-07-15) **Open.** `E-RUNG-CONTENT-LADDER-1`'s rung-2 row cites `sigma_rosetta.rs` diff --git a/.claude/v3/soa_layout/le-contract.md b/.claude/v3/soa_layout/le-contract.md index cc27b90e..daff6aa5 100644 --- a/.claude/v3/soa_layout/le-contract.md +++ b/.claude/v3/soa_layout/le-contract.md @@ -167,6 +167,72 @@ similarity function. Two styles coexist: - **"analog" old style (L8):** 48-bit helix place codes + 6-byte CAM-PQ codes; continuous-flavored place geometry, table-compared. +### Honourable mention — the bgz-tensor Hadamard-residual ladder (index + residual; out-of-row) (operator, 2026-07-16) + +Next to the three flavours of 256 (CAM-PQ = 6×256² compressed to per-query +6×256 ADC rows; bgz17/L4 = the explicit materialized 256²; the V3 facet's +`6×(8:8)` rails = codec-agnostic 6×256² ADDRESS, classview-switched), a +fourth **operational mode** deserves explicit mention — shipped in +`crates/bgz-tensor/src/adaptive_codec.rs`: **index + residual**. +`AdaptiveRow { centroid_idx: u16, scale_bf16, scale2_bf16, … }` keeps the +palette/CLAM centroid as the coarse deterministic PLACE and stores a +**Hadamard-rotated residual** in a three-tier LFD split (corrected +2026-07-16, codex P2 on #700 — `classify_rows_by_lfd`): the **hardest +~top-10% LFD rows escape to `RowPrecision::Passthrough`** (the exact +original vector is stored; NO centroid/residual representation — the +codec's own refuse-to-force-the-mold tier), the **next ~20%** get an i8 +residual, and the **bottom ~70%** the i4+i2 cascade. Index PLACES, +residual CORRECTS — the same place/magnitude decomposition as the +perturbation pyramid, with the magnitude side stored as a graded ladder; +consumers must NOT assume every row has an index+residual representation +(the Passthrough tier does not). + +Why it earns the mention here: it is the **continuous-field exit** that +flat L4 cannot provide. A bare 256-level index terraces a continuous field +(first consumer instance, geo arc 2026-07-16: 256 levels over ~1500 m of +relief ≈ 6 m elevation terraces), while categorical/narrow surfaces +(`Signed360` normals, harmonized colour) stay flat L4. Placement +discipline: this is **NOT a ninth 12-byte layout** — the residual ladder is +**out-of-row** (same status as `Signed360` in the 96-bit carving); the +sanctioned in-row refinement budget remains the turbovec 6×4-bit nibble +lane. L4 byte pairs stay the index; the ladder rides beside the row when a +class's classview focuses a continuous field. + +Formal anchor: **Hambly–Lyons 2010** (Annals of Mathematics 171, +"Uniqueness for the signature of a path of bounded variation and the +reduced path group"): a bounded-variation path is determined by its +**signature** — the graded cascade of its iterated integrals — up to +tree-like equivalence. That is the theorem-shaped version of the ladder's +promise (a graded residual cascade determines the continuous field up to +negligible equivalence) and of the replayable-trajectory framing (store +the graded cascade, recover the path). **The theorem side is already +in-workspace, not an external citation** (corrected 2026-07-16, operator +pointer): **jc Pillar 11** (`crates/jc/src/hambly_lyons.rs`, feature +`hambly-lyons` → the `sigker` sibling; forward probe = tree-equivalent +excursion collapses to the identity signature via Chen's identity, +converse probe = triangle's non-zero level-2 signed area; deliberately +uses `sigker::signature_truncated`, not the known-buggy +`signature_kernel_pde`) and **ndarray `src/hpc/pillar/signature.rs`** +(B7: signature transform + Hambly–Lyons sig-kernel, Gram-matrix +positive-semidefiniteness check, certification probe over 1 000 Lévy +paths). What stays **[S — analogy-grade; consult [FORMAL-SCAFFOLD] before +promotion]** is only the **ladder-levels → signature-levels mapping** for +the residual cascade; its probe can be built directly on the existing +Pillar-11 harnesses rather than from scratch. + +**Provenance caveat (operator, 2026-07-16):** bgz-tensor predates +turbovec/PolarQuant and helix — the ladder's mechanisms (Hadamard +rotation, the bespoke i4+i2 cascade, the Passthrough escape) were chosen +before today's lane inventory existed. This mention records what SHIPS, +not what we would build now; an **engineering follow-up review is +queued** as `TD-BGZ-TENSOR-PRE-LANE-REVIEW` (reconcile vs turbovec +Lloyd-Max+NativeLut, PolarQuant rotation findings, helix +residue/`CurveRuler`; outcome = consume-the-lane / demarcate / retire). + +Cross-ref: ndarray `pr-x12-h268-morton-wgpu-synergies.md` §8 (the three +flavours + this mention), `E-PALETTE-RESIDUAL-LADDER-1` (EPIPHANIES), +`E-H268-REPLAYABLE-TILE-1`, `TD-BGZ-TENSOR-PRE-LANE-REVIEW` (TECH_DEBT). + ### Open reconciliation items ([H] — flag, don't resolve locally) - **L7 helix(48) vs the CANON key tail `family(u24)++identity(u24)`:** diff --git a/CLAUDE.md b/CLAUDE.md index 73ab210c..a633b915 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -923,7 +923,7 @@ exclude = [ - 512-bit VSA encoder: XOR bind + majority bundle (word order sensitive) - 6-state PoS FSM → SPO triples (36-bit packed) -**bgz-tensor** (standalone, ~1,300 LOC, 0 deps) — `crates/bgz-tensor/` +**bgz-tensor** (workspace-excluded; deps: `ndarray` + `holograph`, both path — the old "0 deps" note was stale, corrected 2026-07-16) — `crates/bgz-tensor/` - Attention via table lookup: Q·K^T/√d → table[q_idx][k_idx] in O(1) - Weight matrix 64MB → Base17 136KB → 256 archetypes 8.5KB → distance table 128KB - AttentionSemiring: distance table (u16) + compose table (u8) = multi-hop in O(1)