Skip to content

plan (lab only): relational geometry amortization (D-RST) and recursive perspective rebinding (D-RPR) - #1622

Merged
AdaWorldAPI merged 10 commits into
mainfrom
ccr-08f48cec-lbv9l4
Oct 20, 2026
Merged

AdaWorldAPI merged 10 commits into
mainfrom
ccr-08f48cec-lbv9l4

Conversation

@AdaWorldAPI

@AdaWorldAPI AdaWorldAPI commented Oct 20, 2026 •

Copy link
Copy Markdown
Owner

Lab exploration only, documentation only. Nothing here is admitted to production, and no production code may be rewired to it. Two plans, with their plan-index entries, status-board rows and board entries:

  • .claude/plans/relstore-quack-petgraph-traversal-v1.md (D-RST-0..9): compiled relational geometry and its amortization. Petgraph is optional.
  • .claude/plans/recursive-perspective-rebinding-v1.md (D-RPR-0..3): recursive perspective rebinding over composable relational registers.

The BF16 tile-GEMM probe moved to #1623.

D-RPR: recursive perspective rebinding

An architectural distillation in which every claim is graded IMPLEMENTED, MEASURED, PROBE, PROPOSED or OPEN against origin/main.

  • No new nouns.
    • WORLD = a sealed version, with thought 0 as its givens (D-TGA).
    • ANGLE = focus binding + prepared relation planes (Focus, CsrPred, tile in the rmap.rs probe), with map palettes proposed in D-RMAP-1A.
    • THOUGHT = sparse deltas over one shared frame. Measured: 32 B per thought, and per-eval cost flat across 1/8/64 thoughts.
  • The addressing operation is the measured H14c/H14d canon Thought(t)[T_a[i] : T_b[i]]. The global → local binding it needs is admission A1 (D-RMAP-1 §6), still open.
  • Rebind exists and is measured (D-RMAP-1A §8.4): it wins for small k only. The deciding quantity is the k distribution along real question chains, which is unmeasured.
  • Hypothesis H1: a frame's escapes (ScopedReach.escaped, the IncompleteFocus refusal) seed the next angle.
  • MeTTa operations in four classes, from the existing polyfill classification and Decision H.
  • Experiments. D-RPR-1 (a recursive question chain) is pre-registered with arms, measures, failure cases with named refusals, and a falsifier; it is not authorized. D-RPR-2 is blocked on D-TGA-3 and D-RPR-3 on D-ASM-4.

D-RST: compiled relational geometry

  • Ownership: RelationshipMapStore owns facts, layouts, domains, seals and invalidation; RelAlg/Datalog own bindings; Quack compiles; mask-risc executes.
  • Petgraph is an optional consumer. D-RST-3 is deferred, with chore(experiments): lab-only D-RST-3 borrowed pattern-CSR view (deferred, evidence only) petgraph#4 kept as evidence.
  • §5b: tile GEMM consumes prepared geometry; it does not obtain it.
  • F8: a four-path amortization falsifier.
  • Prior art: the planner's AdjacencyStore is the starting point for native views (D-RST-9).

Checks run locally

  • Append-only gate: passes.
  • Citation decay: no new findings.
  • Entries and supersession indexes: regenerated.

🤖 Generated with Claude Code

https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K

…youts

Documentation only (D-RST-0..8). Records operator decision B:
RelationshipMapStore owns relationship persistence, identities,
layouts, coordinate-domain seals and invalidation; Quack compiles; mask-
risc on ndarray::simd stays the only population executor. D-RMAP-1A §1
and the 2026-10-05 storage-portability ruling are unchanged.

The plan inventories what exists (Registrar has only a test implementor;
Gremlin multi-hop refuses as NonFunctionalChain; RelAlg has no recursion
or hop; mask-risc has no frontier continuation), defines the store's
seams over Quack's existing Registrar, a borrowed petgraph RelView that
runs unmodified Bfs/Dfs, a typed traversal vocabulary that compiles to
Quack, layout reuse and invalidation, falsifiers F1-F7, and nine
mergeable PRs.

Two findings set its limits. Multi-hop over a large domain is blocked
by scatter as well as gather, so the tile within a focus is the only
admitted multi-hop shape until admission A2. The petgraph fork's
existing lance-fold-hop experiment consumes the quarantined OutgoingHop
and is not a base for this work.

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

coderabbitai Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 9c59b382-988b-4f7f-aa71-ae224de7b6db
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Warning

Billing warning: we have not been able to collect payment for this subscription for more than 72 hours. Please update the payment method or pay any pending invoices in Billing to avoid service interruption.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

…darray

Adds the amortization principle (a relation is written once as facts,
and its relationship-shaped layouts are built at seal time, so RelAlg
pays identity translation once per version) and §5a, a read-in-source
check of the shipped BlasGraph CSR as the store's layout.

BlasGraph's storage types (CSR, CSC, hypersparse CSR, COO->CSR, Boolean
semiring) are the vocabulary to reuse, but as shipped they carry a
2 KiB BitVec value per entry, usize indices, an mxv that clones the
matrix per call (the CSC transpose clones too), an indexed read of the
input vector per entry, and no ndarray on the CSR/mxv path. The plan
reuses the types with a pattern-only u32 borrowed variant, sends dense
row blocks to ndarray mask ops through mask-risc via the reserved
StorageFormat::Bitmap, and narrows admission A2 to sparse rows.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K
Boolean composition, walk counts and triangle counts on one 256 x 256
focus, through ndarray::simd::bf16_tile_gemm_16x16_packed (the facade,
not a new kernel) and through a bit matrix, both against a triple-loop
oracle. 4 tests; 5 guards disable-verified.

D-RMAP-2 §3's exactness claim holds: BF16 walk counts equal the oracle
exactly and count > 0 equals Boolean composition at 1 %, 10 %, 50 % and
with skewed hubs. On this host only the F32x16 polyfill tier runs (no
AMX, no avx512_bf16): A*A takes about 19 ms, while the bit arm composes
in 2.6-25 us and gives the same walk counts by popcount in 165-192 us.
The polyfill allocates per output element, recorded as
ISS-BF16-POLYFILL-PER-ELEMENT-ALLOC; tile-tier hosts are unmeasured.

Recorded in D-RMAP-2 §5a, the D-RST plan §5a, STATUS_BOARD, ISSUES and a
board entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K
@AdaWorldAPI AdaWorldAPI changed the title plan: stored relations, compiled traversal, petgraph over borrowed layouts (D-RST) plan: stored relations, compiled traversal, petgraph (D-RST); D-RMAP-2 first measured cell (BF16 tile GEMM) Oct 20, 2026
CPUID, XCR0 and arch_prctl(ARCH_REQ_XCOMP_PERM) on syscall 158 checked
directly, per ndarray AMX_GOTCHAS Gotcha 4: no AMX, no AVX512-BF16; the
permission request returns EOPNOTSUPP. The polyfill tier is the host's,
not a detection bug.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K
Review refinements, documentation only.

- A bitmap row is gather-free only in the predecessor (pull) direction:
  F'[t] = any(pred(t) AND F). Pushing through successor rows selects
  rows by the frontier's set bits, an indexed access. The table of
  representations and their indexed access is in §5a; CSR and CSC both
  stay, so the compiler can match direction to algebra.
- BlasGraph's Boolean semiring is bitwise AND/OR over 16 384-bit
  hyperdimensional values, not edge existence. Structural and valued
  relations are kept as distinct interpretations; the lean CSR starts
  as a borrowed, version-pinned pattern-CSR view beside the existing
  owned types, not a refactor of them.
- The seal fixes identity, version and declared base indexes;
  specialized layouts (bitmap blocks, tiles, join domains) are prepared
  on first demand and retained under their seal.
- Edge ids are stable fact identities; a row offset is one only under a
  stable-row-id contract (F1 now tests compaction).
- New F2b: the cross-front-end layout-reuse hypothesis, falsifiable by
  the prepare count. D-RST-3 is brought forward as an isolated probe.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K
Reverts b5672a5 and 3329eeb on this branch. Their content now lives in
#1623 as cherry-picks, so its measurements, disable-verified guards and
provenance are kept there. This PR returns to D-RST-0, the plan, and
gains one pointer to #1623 in §5a. No protected history is rewritten:
the append-only gate compares against the merge-base with main, and the
reverted ISSUES.md and board-entry additions were never on main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K
@AdaWorldAPI AdaWorldAPI changed the title plan: stored relations, compiled traversal, petgraph (D-RST); D-RMAP-2 first measured cell (BF16 tile GEMM) plan: stored relations, compiled traversal, petgraph over borrowed layouts (D-RST-0) Oct 20, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K
Operator correction (2026-10-20). The plan's center of gravity is reusable
relational geometry amortized across front ends and thought versions, not
a graph API:

- petgraph becomes an optional consumer beside the Gremlin adapter; it
  leaves the execution path of the diagram, and its parity check becomes
  the optional falsifier F-PG. D-RST-3 is OPTIONAL / DEFERRED /
  MEASUREMENT-GATED; petgraph#4 is kept as evidence.
- New D-RST-9 (critical path, first): native borrowed relation views with
  no petgraph, starting from the planner's existing AdjacencyStore /
  AdjacencyBatch rather than a fourth owned CSR type.
- New §5b: tile GEMM consumes prepared geometry. Preparation, execution
  and maintenance are measured apart; break-even comes from measured
  values only; Boolean existence and BF16 multiplicity are kept apart,
  with the BF16 exactness bound.
- New F8: four execution paths on one relation, cold and warm, 1/8/64
  thought versions, sparse to hub distributions.
- New admission A6: an attested sort order, without which a Quack one-hop
  scans the whole lane (measured in D-RST-3).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K
@AdaWorldAPI AdaWorldAPI changed the title plan: stored relations, compiled traversal, petgraph over borrowed layouts (D-RST-0) plan: compiled relational geometry and its amortization; petgraph optional (D-RST-0) Oct 20, 2026
Operator ruling (2026-10-20): the relationship store is one option among
many for certain data shapes, unfit to promote until further testing;
nothing may be rewired to it. Plan status, board rows and the board entry
say so; the 'critical path' is renamed a lab sequence. The entry also
records that none of the measured paths touched DataFusion.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K
Architecture and experimental design only, graded against origin/main:

- WORLD x ANGLE x THOUGHT map onto existing components (sealed version
  with thought 0 as givens; focus binding plus prepared relation planes;
  sparse thought deltas over one shared frame).
- The addressing operation is the measured H14c/H14d canon; the global to
  local binding it needs is admission A1, still open.
- Rebind is measured (D-RMAP-1A 8.4) and pays only for small k, so the
  open quantity is the k distribution along real question chains.
  Hypothesis H1: a frame's escapes seed the next angle.
- MeTTa operations sorted into four classes from the existing polyfill
  classification; the pre-registered chain probe D-RPR-1 is not
  authorized, D-RPR-2/3 are blocked on D-TGA-3 and D-ASM-4.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VyWZYKycy6MoYDxHRVnV5K
@AdaWorldAPI AdaWorldAPI changed the title plan: compiled relational geometry and its amortization; petgraph optional (D-RST-0) plan (lab only): relational geometry amortization (D-RST) and recursive perspective rebinding (D-RPR) Oct 20, 2026
@AdaWorldAPI
AdaWorldAPI marked this pull request as ready for review October 20, 2026 08:19
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-20T08:24:59.037291Z d5c7925 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@AdaWorldAPI
AdaWorldAPI merged commit 4dbd085 into main Oct 20, 2026
5 checks passed

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d5c7925803

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

|---|---|---|
| WORLD, 0..255 local slots | `struct Focus { ids: Vec<u32>, by_id: Vec<(u32, u8)>, pub generation: u64 }`, `SLOTS = 256` (`rmap.rs:58–65, 201–208`) | binding 3 072 B |
| ANGLE, per predicate | `CsrPred { p, offsets: [u32; SLOTS+1], dst: Vec<u8>, row: Vec<u32>, escaped: Vec<(u8, u32, u32)>, has_escape: SlotSet }`; the 256 × 256 tile built from it | CSR 18–66 KB; tile 8 KiB per predicate |
| THOUGHT, 0..63 | `ThoughtDelta` sparse edits over the shared tile | 32 B per thought as edits, 16 KiB lowered to executor planes; per-eval 2.61 / 2.66 / 2.79 µs at 1 / 8 / 64 thoughts (sparse d2), "the shared tile is stored once" (§8.5) |

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Report ThoughtDelta's allocated footprint

The 32-byte figure is only a logical edit count, not the probe's resident per-thought memory. In crates/mork-pathmap-probe/src/rmap.rs, ThoughtDelta::new immediately allocates two full plane() buffers in add and del, while bytes_sparse() merely returns edits * 2; each live thought therefore retains roughly 16 KiB plus struct overhead. Treating 32 B as the measured footprint materially understates the 64-thought memory cost unless a genuinely sparse representation and explicit lowering lifecycle are implemented.

Useful? React with 👍 / 👎.


```text
T_tile(N, M) = T_prepare + N · T_exec + M · T_maintain
T_sparse(N) = N · T_traverse (CSR/CSC or a native iterator, no tile)

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Charge sparse preparation in the cold crossover

For F8's cold and invalidation runs, paths A and B also have to construct or rebuild their CSR/CSC layouts, yet this equation charges preparation and maintenance only to the tile path. That conflicts with F8's requirement to report preparation and invalidation costs per path and makes the advertised end-to-end crossover incomparable; include the sparse layout's preparation/maintenance terms, or explicitly restrict this equation to a warm comparison where those base-index costs are shared and already sunk.

Useful? React with 👍 / 👎.

| an answer outside the focus | `IncompleteFocus` |
| a recursive dependency cycle | **no refusal exists yet: OPEN** |

**Acceptance.** Exact parity on every arm. Every case above refuses rather than answers. Arm (d)'s chain total is reported against (b) and (c) with its crossover.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Align acceptance with the listed reuse outcomes

D-RPR-1 cannot satisfy this acceptance condition as written: the no-shared-slots case deliberately succeeds by doing a full prepare rather than refusing, and the recursive-cycle row explicitly says that no refusal exists. Distinguish the expected full-prepare fallback from actual refusal cases and either define the cycle refusal before making it an acceptance gate or leave that case outside this experiment.

Useful? React with 👍 / 👎.

AdaWorldAPI pushed a commit that referenced this pull request Oct 20, 2026
#1622 is canonical for D-RST and D-RPR. #1624's duplicate plan file,
same-named entry and status rows D-RPR-0..6 are withdrawn (dropped in
the rebase); what #1622 lacked is now plan section 11 under the existing
ids:

- D-RPR-1 sub-cases 1a-1f (kill condition + disable run each)
- anti-vacuity rules, incl. the measured first-focus failure
- independent oracles; green -> red -> green protocol
- refusals by axis: version, focus, scope, ordering, thought identity,
  narrow frame, capacity
- measured preparation/reuse costs (break-even 76/11/1.8, CSR vs tile,
  escape reporting, bytes, zero-copy tension)
- two-variable and multiplicity limits

Corrections: WORLD/ANGLE/THOUGHT are metaphors (pointer notes in
sections 1 and 3); thought identity is #1605's ThoughtCommitId and
DurableRef; the "D-RST resolves to no plan" claim is withdrawn; D-MTP-1's
Semijoin path is gather-shaped; the two ThoughtMask meanings are OPEN.

The draft chain probe is banked as a patch in
.claude/harvest/d-rpr-1-chain-probe-draft/: it applies to main 4dbd085,
5 of 6 tests pass there, and it is not merged because D-RPR-1 is not
authorized. Board: the D-RPR-1 evidence column, entry
2026-10-20-d-rpr-consolidation-1624.md, regenerated index.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VncKoyG6JkpsoqhqTGTv3f
AdaWorldAPI pushed a commit that referenced this pull request Oct 20, 2026
same-named entry and status rows D-RPR-0..6 are withdrawn (dropped in
the rebase); what #1622 lacked is now plan section 11 under the existing
ids:

- D-RPR-1 sub-cases 1a-1f (kill condition + disable run each)
- anti-vacuity rules, incl. the measured first-focus failure
- independent oracles; green -> red -> green protocol
- refusals by axis: version, focus, scope, ordering, thought identity,
  narrow frame, capacity
- measured preparation/reuse costs (break-even 76/11/1.8, CSR vs tile,
  escape reporting, bytes, zero-copy tension)
- two-variable and multiplicity limits

Corrections: WORLD/ANGLE/THOUGHT are metaphors (pointer notes in
sections 1 and 3); thought identity is #1605's ThoughtCommitId and
DurableRef; the "D-RST resolves to no plan" claim is withdrawn; D-MTP-1's
Semijoin path is gather-shaped; the two ThoughtMask meanings are OPEN.

The draft chain probe is banked as a patch in
.claude/harvest/d-rpr-1-chain-probe-draft/: it applies to main 4dbd085,
5 of 6 tests pass there, and it is not merged because D-RPR-1 is not
authorized. Board: the D-RPR-1 evidence column, entry
2026-10-20-d-rpr-consolidation-1624.md, regenerated index.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VncKoyG6JkpsoqhqTGTv3f
AdaWorldAPI added a commit that referenced this pull request Oct 20, 2026
Consolidate into #1622: D-RPR-1 sub-cases, plan links for #1601–#1617, and the handoff lab probe
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