diff --git a/docs/TICKETS.md b/docs/TICKETS.md index c7c72de..0e67e00 100644 --- a/docs/TICKETS.md +++ b/docs/TICKETS.md @@ -113,7 +113,7 @@ Newest first. Update on every open/close. |----------|------------------------------------------------|-----------------------|------------|-----------| | #000072 | Collapse legacy `query()` into the unified `run_query` orchestrator | **open · Phase 1 foundation shipped 2026-05-31 (10 commits) · Phase 2 BLOCKED on 5 missing rerank stages** — multi_route smoke probe regressed on 2/5 questions (Mercury Seven → Sam T. Beddingfield; dinosaurs → Paul Austin Kelly), so Phase 1 is structurally complete but not production-quality. Phase 1 shipped: `source_roles.py` extraction (9ba6317), canonical `stem_for_match` in `_text_norm.py` (a83e47b), `retrieval_routes.py` with `filter_by_title_relevance` (056d785), Corpus protocol gains `core_keyword_match` + `doc_body` (e322bbd), byte-identity test fixture as Phase 2 safety gate (1822741), `run_query` gains `policy=` kwarg threading 12 verifier kwargs (72d1117), role-classified + role-weighted budget (03f248c), multi-route retrieval body+title+phrase+core_keyword merge (5fdd573), filter wired into multi_route path (6c2ec1b), wikitext-strip when `policy.base_version` set (b8bd9d6), `providence_query.py` cache-wrapper skeleton with cache persist deferred (20faae0). Every commit ships with `policy=None` preserving pre-step byte-identity behavior — existing `arborist corpus-query` and `arborist cloud query` callers are unaffected; the slim-FTS5 cloud path already wins on the dinosaur Q5 fixture (picks "Dinosaur" not legacy's "Edwina"). Phase 2 blocked because Phase 1's `multi_route` pipeline lacks the 5 downstream rerank stages legacy uses to suppress noisy phrase-route hits: body-density check (`_body_density_passes`), body-coverage sqrt rerank (`_rerank_by_body_coverage`), source-role rerank (`_rerank_by_source_role` with RANK_WEIGHTS), title-purity rerank ((1+overlap)*(1+purity)), ordered-token-match rerank (longest-common-subsequence). **Path A** = port the 5 stages → re-bench → resume Phase 2 cache persist + legacy-query() collapse to 50-line adapter. **Path B chosen 2026-05-31** = stop here, defer Phase 2, leave multi_route off by default (which IS the default — `policy=None` preserves body-only retrieval). Until Path A: Phase 1 foundation stays in tree as future-ready infrastructure; user surface unchanged (legacy `query()` still produces same answers, INCLUDING the wrong "Edwina" pick on dinosaur Q5). Full spec + commit log + bench data + the missing-rerank-stages inventory in `docs/tickets/ticket-000072-collapse-legacy-query-into-run-query.md`. | 2026-05-31 | — | | #000071 | World-bridge grammar (Joseph 3-bridge inter-chain framework) | **open · awaiting dav1d review + fox go/no-go · doc-only Phase 1** (2026-05-31; sibling to #000070, opened same day after Joseph @TrudoJo posted his bridge-framework extension to the 6-dim spatial-ontology — "chain A has its own world rules, chain B has its own world rules, a bridge exists only where a deterministic agreement layer can be proven"). Three bridge kinds: **Agreement** (rules match, direct passage), **Translation** (rules differ but a hash-pinned adapter exists), **Embassy** (foreign-object representation with limited rights). Bridge identity: `bridge_seed = hash(src_chain_id ‖ src_node ‖ src_rule_v ‖ tgt_chain_id ‖ tgt_rule_v ‖ translator_id ‖ invariant_set)`. Joseph's sovereignty rule (hard): chain law remains local, bridge law governs translation only, **no bridge may overwrite native chain law** — guard against forced-unity failure mode. **Primary contribution: retroactive-validation appendix** naming three already-shipped arborist primitives as Joseph-bridge-shape patterns one-for-one — **#000066 graft-receipt mode = Agreement bridge**, **#000056 Operation Sandwich = Translation bridge** (opus-mt hash IS the translator_id), **#000059 bounded-ingestion graveyard = Embassy bridge** (POINTER-LINKED only, never promotes, banner-labelled). The framework is not a new requirement; it's a unifying spec that names what arborist already does in 3+ places, plus surfaces a fourth pattern (bridge atlas for multi-instance federation with potentially-different `governance_policy_hash` peers) as genuinely new work for `arborist/mesh/`. **Phase 1 is doc-only** — paper extension §7 in `docs/_source/merkle-agi-v7w-spatial-temporal.rst` + `arborist/world/bridge/__init__.py` namespace stub mirroring `arborist/world/__init__.py` discipline + Joseph-memory extension. No kernel code, no SQL change, no `cache_key` extension, no new `audit_mode` token, no bench (doc-only review surface). Phase 2 = `pi_star/bridge-seed@v1` canonicalization deliberately deferred to avoid premature locking before three implementation tickets opine. Phase 3 = per-bridge-type kernels + bridge atlas + `event_type='bridge'` writer + mesh integration. Phase 4 = cross-domain bridges (language ↔ spatial via #000015 composition theorem). **Ten open questions for dav1d** in §8: doc-only vs registry-slot-at-Phase-1 (Q1), chain_id = governance_policy_hash vs manifest hash (Q2), three-bridge taxonomy completeness (Q3), translator integrity hashing depth (Q4), bridge witness via `event_type='bridge'` (Q5), `audit_mode` discipline for translated objects (Q6), bridge privacy class default (Q7), endianness reconfirmation (Q8), Phase 2 KAT count + adversarial vectors (Q9), paper-amendment wording (Q10). Hard constraints: A1–A3, no continuous tensors, no `audit_mode` token, no SQL change at Phase 1, topic-named under `arborist/world/bridge/`. Full spec in `docs/tickets/ticket-000071-world-bridge-grammar.md`. | 2026-05-31 | — | -| #000070 | Spatial-anchor π*_w_object (Joseph 6-dim determination kernel) | **open · awaiting dav1d review + fox go/no-go · pre-review bench shipped `55b651f`** — pure-stdlib empirical-validation script (`bench/spatial_anchor_validation.py`, `make bench-spatial-anchor`, ~2 s, RNG-seed-pinned) measures: §1 avalanche mean 767.85 bits vs PRF null 768 (z = -0.49) · §2 octree chi² uniformity \|z\| < 1 at L=2,3,4 · §3 collision birthday-bound ratio 0.989 / 1.038 at L=4,6 · §4 cross-region Pearson r in [-0.018, +0.012] across all 15 pairs of H₁..H₆ (none flag at 4σ) · §5 domain separation Arm A 767.91 bits independent / Arm B **0.00 bits exact collision** confirming the dedicated-`spatial_anchor_seed` discipline. Five of ten open questions (Q1 seed source · Q2 segmentation · Q3 octree mapper · Q8 endianness · Q9 KAT adversarial vectors) now resolve by measurement; Q4/Q5/Q6/Q7/Q10 remain non-empirical design decisions for dav1d. Full empirical detail in ticket §7a. Originally surfaced 2026-05-31 when fox brought in Joseph @TrudoJo's procedural-spatial framework — "hashes do not encode the world, hashes determine the world" — and asked whether it fits arborist's substrate model. It does, cleanly. Implements the first verifier kernel under the #000013 v7-W reserved namespace (`arborist/world/__init__.py` `STATUS = "namespace_reserved"` → `kernel_in_progress` on land): a single committed 32-byte SHA-256 hash deterministically expands into six named 32-byte regions `H₁..H₆` via the HMAC-SHA-512 KDF already shipped in `arborist/substrate/anchor_prg.py` (#000035), and each region drives one quantized object dimension under a fixed canonical mapper — `H₁→octree position`, `H₂→scale level`, `H₃→quantized SO(3) rotation`, `H₄→material palette`, `H₅→raw links (reserved for π*_w_relation sibling ticket)`, `H₆→behavior code`. Domain separation from #000035 by dedicated `spatial_anchor_seed` (manifest-published) — keeps #000035's KAT freeze + dav1d 2026-05-11 final review intact. Hard constraints: stays inside A1–A3, no continuous tensors in proof path, no new `audit_mode` token (substrate commitments are not warrants — the four-rung ladder is unchanged), no SQL schema change at Phase 1, `canonicalization_version` absorbs the new `spatial-anchor-object@v1` registry slot. Phase 1 deliverable ~150 LoC + 10 KATs + tests in one PR: `arborist/substrate/spatial_anchor.py` (segmentation), `arborist/world/pi_star/object.py` (six mappers), registry entry, KAT vectors at `bench/fixtures/spatial-anchor/known-answer-tests.jsonl` matching #000035 KAT discipline, `tests/test_spatial_anchor.py` + `tests/test_world_pi_star_object.py`, substrate-paper amendment citing Joseph (@TrudoJo) in `docs/_source/merkle-agi-v7w-spatial-temporal.rst`. Position mapper at Phase 1 = octree (substrate paper §2.1 + §A worked example); H3/S2/Hilbert/Morton siblings deferred — Morton's value is purely as the relation-kernel `pair(A,B)` cheap bit-interleave and surfaces in the sibling ticket. **Ten open questions for dav1d** in §8: seed-source choice, segmentation method, position mapper, scope split (object alone vs object+relation per CLAUDE.md memory `feedback_ticket_proliferation`), privacy-class fail-closed default, `audit_mode` discipline confirmation, manifest-validator timing, endianness reconfirmation, KAT count + adversarial vectors, paper-amendment wording. Five-step §7 deletions captured: dropped the prior `/tmp/arborist-spatial-ontology-plan.md`'s geographic-search backend (encoding-route confusion), `Document.extra` lat/lon hooks (different ticket if at all), `audit_mode=HYBRID` for spatial hits (convention-illegal), geohash (subsumed by Morton), quadtree as separate (octree at z-level-0), Hilbert at Phase 1 (deferred), tier-1/2/3 hash-suite framing (conflated hard vs soft hashes), and `arborist/spatial/` namespace (violates topic-naming rule). Full spec in `docs/tickets/ticket-000070-spatial-anchor-pi-w-object.md`. | 2026-05-31 | — | +| #000070 | AnchorN + π*_w_object: deterministic world-object canonicalization (was: Spatial-anchor π*_w_object / Joseph 6-dim kernel) | **open · dav1d GO with rewrite (2026-06-01) · spec revision pending before any kernel ships.** Dav1d verdict: GO for generic **AnchorN** substrate primitive (not fixed Anchor6), GO for **Joseph6 as first registered grammar** (not THE ontology), GO for deterministic object-state canonicalization, GO for axiom/physics-loaded **WorldDimensionGrammar** path; NO-GO for hard-coding H₁..H₆ as final ontology, NO-GO for runtime LLM-decided dimensionality (axioms MAY propose, only deterministic validators may accept; grammars frozen via grammar_hash before proof-path use), NO-GO for framing this as "semantic verifier warrant", NO-GO for relation/event/place/agent_trace in this ticket (scope-creep), NO-GO for SQL persistence at Phase 1. Critical technical corrections: **H₁ must use uint256 not uint64** (octree position entropy at depth>8), **do NOT overclaim SO(3) on rotation** (name `map_rotation_euler_ypr()`), canonical record carries grammar_hash + axiom_pack_hash + manifest_hash + seed_hash, missing `privacy.class` = HARD reject, spatial-anchor-object@v1 folds into `canonicalization_version` only. Corrected package layout: `arborist/substrate/spatial_anchor.py` (AnchorN, split_anchor_n), `arborist/world/grammar.py` NEW (WorldDimensionGrammar + validate_grammar), `arborist/world/pi_star/object.py` (derive_world_object_record + 5 mappers), `arborist/pi_star/spatial_anchor_object.py` NEW (registry adapter), KATs at `bench/fixtures/spatial-anchor-object/known-answer-tests.jsonl`, 3 test modules. Phase 1 deliverable: AnchorN split + Joseph6 grammar + π*_w_object canonicalizer + KATs + tests + paper amendment; NO SQL, NO new audit_mode, NO verifier_policy_hash change. Implementation NOT started — `arborist/world/__init__.py` STATUS still "namespace_reserved", no spatial_anchor.py exists; only the pre-review empirical bench `bench/spatial_anchor_validation.py` is on disk (commit `55b651f`/`2eea5b5`: avalanche 767.85 bits vs PRF null 768 z=-0.49, octree chi² \|z\|<1 at L=2..4, collision birthday-bound 0.989/1.038, cross-region Pearson r∈[-0.018,+0.012], domain separation Arm A independent / Arm B exact-collision confirming dedicated `spatial_anchor_seed`). Dav1d's 26-section review preserves the empirical evidence (HMAC-SHA-512 properties unchanged by AnchorN generalization). Five of original ten open questions resolved by measurement (Q1/Q2/Q3/Q8/Q9); review answers Q4/Q5/Q6/Q7, Q10 (paper-amendment wording) still open. Full review archived at `docs/dav1d-reviews/000070-spatial-anchor-pi-w-object--2026-06-01.txt`; corrected spec in ticket §0; design log of original Anchor6 proposal preserved in §§1-8. Originally surfaced 2026-05-31 when fox brought in Joseph @TrudoJo's procedural-spatial framework — "hashes do not encode the world, hashes determine the world" — and asked whether it fits arborist's substrate model. Yes, AS AnchorN with Joseph6 as default grammar. — pure-stdlib empirical-validation script (`bench/spatial_anchor_validation.py`, `make bench-spatial-anchor`, ~2 s, RNG-seed-pinned) measures: §1 avalanche mean 767.85 bits vs PRF null 768 (z = -0.49) · §2 octree chi² uniformity \|z\| < 1 at L=2,3,4 · §3 collision birthday-bound ratio 0.989 / 1.038 at L=4,6 · §4 cross-region Pearson r in [-0.018, +0.012] across all 15 pairs of H₁..H₆ (none flag at 4σ) · §5 domain separation Arm A 767.91 bits independent / Arm B **0.00 bits exact collision** confirming the dedicated-`spatial_anchor_seed` discipline. Five of ten open questions (Q1 seed source · Q2 segmentation · Q3 octree mapper · Q8 endianness · Q9 KAT adversarial vectors) now resolve by measurement; Q4/Q5/Q6/Q7/Q10 remain non-empirical design decisions for dav1d. Full empirical detail in ticket §7a. Originally surfaced 2026-05-31 when fox brought in Joseph @TrudoJo's procedural-spatial framework — "hashes do not encode the world, hashes determine the world" — and asked whether it fits arborist's substrate model. It does, cleanly. Implements the first verifier kernel under the #000013 v7-W reserved namespace (`arborist/world/__init__.py` `STATUS = "namespace_reserved"` → `kernel_in_progress` on land): a single committed 32-byte SHA-256 hash deterministically expands into six named 32-byte regions `H₁..H₆` via the HMAC-SHA-512 KDF already shipped in `arborist/substrate/anchor_prg.py` (#000035), and each region drives one quantized object dimension under a fixed canonical mapper — `H₁→octree position`, `H₂→scale level`, `H₃→quantized SO(3) rotation`, `H₄→material palette`, `H₅→raw links (reserved for π*_w_relation sibling ticket)`, `H₆→behavior code`. Domain separation from #000035 by dedicated `spatial_anchor_seed` (manifest-published) — keeps #000035's KAT freeze + dav1d 2026-05-11 final review intact. Hard constraints: stays inside A1–A3, no continuous tensors in proof path, no new `audit_mode` token (substrate commitments are not warrants — the four-rung ladder is unchanged), no SQL schema change at Phase 1, `canonicalization_version` absorbs the new `spatial-anchor-object@v1` registry slot. Phase 1 deliverable ~150 LoC + 10 KATs + tests in one PR: `arborist/substrate/spatial_anchor.py` (segmentation), `arborist/world/pi_star/object.py` (six mappers), registry entry, KAT vectors at `bench/fixtures/spatial-anchor/known-answer-tests.jsonl` matching #000035 KAT discipline, `tests/test_spatial_anchor.py` + `tests/test_world_pi_star_object.py`, substrate-paper amendment citing Joseph (@TrudoJo) in `docs/_source/merkle-agi-v7w-spatial-temporal.rst`. Position mapper at Phase 1 = octree (substrate paper §2.1 + §A worked example); H3/S2/Hilbert/Morton siblings deferred — Morton's value is purely as the relation-kernel `pair(A,B)` cheap bit-interleave and surfaces in the sibling ticket. **Ten open questions for dav1d** in §8: seed-source choice, segmentation method, position mapper, scope split (object alone vs object+relation per CLAUDE.md memory `feedback_ticket_proliferation`), privacy-class fail-closed default, `audit_mode` discipline confirmation, manifest-validator timing, endianness reconfirmation, KAT count + adversarial vectors, paper-amendment wording. Five-step §7 deletions captured: dropped the prior `/tmp/arborist-spatial-ontology-plan.md`'s geographic-search backend (encoding-route confusion), `Document.extra` lat/lon hooks (different ticket if at all), `audit_mode=HYBRID` for spatial hits (convention-illegal), geohash (subsumed by Morton), quadtree as separate (octree at z-level-0), Hilbert at Phase 1 (deferred), tier-1/2/3 hash-suite framing (conflated hard vs soft hashes), and `arborist/spatial/` namespace (violates topic-naming rule). Full spec in `docs/tickets/ticket-000070-spatial-anchor-pi-w-object.md`. | 2026-05-31 | — | | #000069 | Arborist VIZ / Merkle Command Center (Pyramid + six.js + SSE browser dashboard) | **open · awaiting go/no-go · doc-only scaffold** (2026-05-27; filed from `/home/fox/Downloads/TICKET_0000VIZ_*`, stack corrected same day per fox). Configurable browser dashboard for inspecting arborist's content-addressed state: Merkle root explorer, proof verifier, claim warrant + graveyard, audit timeline, run-DAG replay, cache-key explainer, root diff, 3D Merkle lattice, optional circuit/activation traces. Read-only consumer; arborist proper stays source-of-truth, dashboard projects state. **Stack pinned to unturf-native** (fox 2026-05-27, supersedes proposal §3): **Pyramid + Jinja2 + SQLAlchemy** (matches `remarkbox` / `make_post_sell` / `unhomeschool.com` idiom), **SSE** (`text/event-stream` via Pyramid streaming response) for live audit/claim/falsifier patches, **vanilla JS + six.js** (fox's patched three.js fork at `git.unturf.com/gumyum/six.js` — three.js r175 + CWE-407 patches incl. ObjectBVH O(N)→O(log N); bundles vendored from `~/git/cupPCB/cdn/six/`; third-instance MOAD-0001 dogfood alongside `java-topology` + gumyum-engine) for 3D widgets and large-graph rendering, SQLite for dashboard metadata (no PostgreSQL/ClickHouse/Redis/NATS by default — promote on measured need), no React / no Next.js / no Node build step. Server-rendered SVG (or Graphviz `.dot` per existing `docs/diagrams/*.dot` pattern) replaces React Flow for run-DAG widgets. Browser-side proof verification dropped from v1 (server-side Pyramid view returns PASS/FAIL + receipt; reinstate phase-N only if third-party-verification use case surfaces). **Three filing-note gates before phase 0** (in ticket body): **F-1** sibling-repo home — implementation lives in a new `~/git/arborist-viz` (Pyramid Python, matches existing unturf apps), not in-tree; arborist's contribution is the read-API spec + view package + arborist library import via `arborist.embed`. **F-2** scope split — proposal carries 8 phases (§17 phases 0–8); recommended cut keeps phases 0–3 (schema + shell + proof/root widgets + claim/audit/run widgets) inside #000069, and spawns sibling tickets for SSE streaming (4), 3D six.js (5), massive-graph (6, only if measured need surfaces), circuit-tracing (7, gated on #000062), embeddable widgets (8) — Dav1d-audience rule. **F-3** upstream prereqs — phase 7 (circuit/activation) consumes **#000062 Mechanistic Witness**'s `MechanisticWitnessRoot`; phase 3's claim-graveyard widget projects **#000059**'s bounded-ingestion graveyard. Hard constraints: arborist soft-vs-hard discipline applies verbatim (attribution weights renderable but never `audit_mode`, never causal without intervention/ablation evidence); private-leaf default-deny (commitments + hashes + redacted maps only without explicit auth); every widget exposes its data query + source roots. Reserved scope: NOT a replacement for `arborist controller-events` / `arborist analyze` / `arborist inspect` CLI — those stay canonical inspector surfaces; VIZ is the projection layer. | 2026-05-27 | — | | #000068 | Verifier-blind missed-answer falsification guard | **in progress · Phase 1+2+3 landed 2026-05-27 · Phase 4 default flip NO-GO** (Phase 2 bench 2026-05-27 76q × n=3 claim_lattice Hermes-3-8B: 2/228 sidecar fires, both STRONG confidence, both the Ballestrini regression fixture, 100% precision, 0/226 false positives across non-Ballestrini runs. Phase 3 demote flag opt-in via `--demote-on-missed-answer` on `query`/`ask` — wires `EVIDENCE-WARRANTED → EVIDENCE-MISSED-PARTIAL` for strong/medium confidence on lattice modes; lower rungs + non-lattice modes get `· missed-answer` tail tag. `answerability_demote_enabled` added to `_VERIFIER_POLICY_FIELDS` so flipping the flag partitions cache via verifier_policy_hash. Default OFF per Dav1d Phase 4 NO-GO — 100% precision at n=2 fires is too few samples to claim precision floor empirically; default flip blocks on wider bench + human spot-check. 47 tests (36 Phase 1 + 11 Phase 3) all passing. End-to-end verified live: 4/4 Hermes runs on Ballestrini with --demote-on-missed-answer rendered EVIDENCE-MISSED-PARTIAL.) Original opening 2026-05-27 (Dav1d de-novo review GO for Phase 1 with seven hardenings folded into spec — subject-token cue-stripping, answer-type alignment, confidence_class, candidate cap=10, precise offset_start/end/basis, cache-hit recompute-on-read, Phase 1 out of verifier_policy_hash). Original opening 2026-05-27; sibling to the user-payload-layout work shipped 2026-05-26, split out per the Dav1d-audience rule — `feedback_ticket_proliferation`). Surfaced by the Ballestrini case: evidence E2 literally contained the song names, Hermes-3-8B under `user_payload_layout=tail` said *"specific songs by her are not mentioned in the provided evidence blocks"*, verifier marked the run `EVIDENCE-WARRANTED` 2/2 because nothing positive was unsupported. **Verifier-blind false-negative class** — existing layered verifier (quote/span/entity/paraphrase + Rule 8 + Rule 9 + claim ceiling) guards unsupported *presence*, has no hook for unsupported *absence*. Layout fixes attention placement on the specific instance (n=3 bench 2026-05-27 confirms bookend/per_chunk recover Ballestrini); layout alone can't close the class — adversarial phrasing or bigger prompt resurfaces it under any layout. Proposed deterministic sidecar in `arborist/qa/inspect.py:diagnose_missed_answer`: three-clause conjunction — **(A)** answer matches denial pattern ("not mentioned", "not provided", "the evidence does not say", …, closed list versioned via `denial_patterns_version`); **(B)** question is extraction shape (reuse `arborist.qa.quantifier` classifier — `ALL`/`COMPREHENSIVE`/`OPEN_REQUEST` intensities, OR surface cues "songs by"/"works by"/"who wrote"/"list"/"name all"); **(C)** evidence contains candidate spans near subject tokens (reuse `entity_proximity_n`/`entity_proximity_window` from verify.py — quoted strings, title-case spans, comma-separated title lists within W chars of stemmed subject content tokens). All three must fire. Output: `result["answerability"]` with `missed_answer_candidate_spans` list (evidence_id + offset + text). **Hash discipline:** sidecar fields (`denial_patterns_version`, `extraction_cues_version`, `answerability_threshold`) fold into `governance_policy_hash` only; an optional `answerability_demote_enabled` flag (default OFF) wires `EVIDENCE-WARRANTED → EVIDENCE-MISSED-PARTIAL` in `_render_audit_label`, and IF on folds into BOTH `governance_policy_hash` AND `verifier_policy_hash` (changes rendered audit_mode, so verifier hash must move — the deliberate opt-in moves the verifier hash, sidecar-only stays out). No LLM-as-judge. Never writes `providence_cache`/`audit_events`. Never promotes claims. Pattern verbatim from `arborist.qa.inspect.diagnose_*` (deflection, coherence, title-relevance). Phases: 1 sidecar read-only, 2 bench + threshold tuning, 3 demote opt-in, 4 default decision (bench-gated). 5F-Falsification fixture: Ballestrini case already in `bench/qa_questions.txt` under "entity list". Full spec in `docs/tickets/ticket-000068-verifier-blind-missed-answer-guard.md`. | 2026-05-27 | D2 | | #000067 | M-aware cold-pack hydration (route incoming docs by content hash into M target shards) | **open · scaffold · prereq for #46 genesis test** (2026-05-26; surfaced while preparing the 3090 SPV-wallet validation). Today's `hydrate_from_metadata_pack` takes a single `conn` and writes every incoming row into one shard. With the corpus now in M=4 hash-routed topology (#000065), a fresh peer needs to land each document on `shard_for_document(document_root, M)` — same routing function as the producer. Without this, a fresh peer's `~/.arborist/shards/` is just one big single-shard DB and the M=4 ATTACH-and-route assumption #000065 was sized for doesn't hold consumer-side. Two coherent shapes: **(α) two-step kludge** — hydrate into single shard, then `arborist corpus reshard --to M` on the consumer. Works today (proven by the 2026-05-26 reshard executor) but doubles the wall time and treats packed shards as if they came from an arbitrary topology. **(β) direct M-aware hydrate** — extend `hydrate_from_metadata_pack` to accept `targets: list[sqlite3.Connection]` + `M: int` and route per-row at restore time (reusing `arborist.document.shard_for_document` + the table-routing rules in `arborist/migrate.py`). Manifest carries `corpus_shard_count` so the unpacker knows M from the pack itself. β is the right answer — α exists only as a fallback if 20-min-window pressure forces it. Sequence: (1) add `corpus_shard_count` to pack manifest (read from source meta during `dump_shard_metadata`); (2) `restore_shard_metadata_routed(targets, M, table_dir)` in `cold_pack_metadata.py` mirroring `_route_per_doc_table` from migrate.py; (3) `hydrate_from_metadata_pack` gains a `targets`/`shards_dir` param; (4) `arborist cold unpack --shards-dir DIR` initialises M target shards from the manifest's `corpus_shard_count` and routes; (5) regression test: pack 2 shards → hydrate into fresh 4 shards → assert every doc on its hash-routed target. Refactor opportunity: the routing rules (ROUTED_BY_DOCUMENT_ROOT, CONSOLIDATED_TABLES) currently live in migrate.py; this ticket can either duplicate them in cold_pack_metadata.py (fast) or factor into a shared `arborist/multi_shard.py` module (cleaner). The shared-module path is more honest given graft mode (#000066) wants the same primitives. Out of scope: graft / overlay mode (that's #000066 — overlays onto populated, this is hydrate-into-empty). | 2026-05-26 | — | diff --git a/docs/dav1d-reviews/000070-spatial-anchor-pi-w-object--2026-06-01.txt b/docs/dav1d-reviews/000070-spatial-anchor-pi-w-object--2026-06-01.txt new file mode 100644 index 0000000..0ae9a15 --- /dev/null +++ b/docs/dav1d-reviews/000070-spatial-anchor-pi-w-object--2026-06-01.txt @@ -0,0 +1,1904 @@ +Timestamp: 2026-06-01, Asia/Kuala_Lumpur +Subject: final regenerated response to `#000070 — Spatial-anchor π*_w_object / AnchorN / axiom-governed world-state substrate` + +# 0. Final verdict + +```text +#000070 — GO, but rewrite it before implementation. + +Corrected decision: + GO for a generic AnchorN substrate primitive. + GO for Joseph6 as the first registered default grammar. + GO for deterministic object-state canonicalization. + GO for axiom/physics-loaded WorldDimensionGrammar as the scalable path. + + NO-GO for hard-coding H₁..H₆ as the final ontology. + NO-GO for runtime LLM-decided dimensionality. + NO-GO for calling this a semantic verifier warrant. + NO-GO for relation/event/place/agent_trace inside the first object ticket. + NO-GO for SQL persistence in Phase 1. +``` + +The earlier `H₁..H₆` design is useful as a first executable kernel: + +```text +H₁ = position seed +H₂ = scale seed +H₃ = rotation seed +H₄ = material seed +H₅ = relation seed +H₆ = behavior seed +``` + +But your latest correction is right: **six fixed fields should not be treated as the final ontology of world-state.** The stronger architecture is: + +```text +hard hash + seed + frozen world grammar +→ AnchorN region split +→ N typed dimension mappers +→ canonical world-state record +→ Merkle/SHA-256 commitment +``` + +Where `N` is not chosen by vibes, prompt text, or model drift. `N` is selected by a **frozen, versioned, axiom-constrained WorldDimensionGrammar**. + +That preserves determinism while allowing geometry, counting, temporal order, relations, and physics constraints to emerge naturally as committed substrate dimensions rather than as latent LLM impressions. + +--- + +# 1. Current ground truth from Arborist docs + +The public Arborist docs already define v7-W as the spatial-temporal substrate for committed derived world-state, sister to v7 logic/math and Arborist language/claim-lattice. It commits objects, relations, events, places, agent traces, and observations, and says each tuple class has a canonical projection `π*_w` whose canonical bytes hash to an equivalence-class identity. ([Arborist API Reference][1]) + +The v7-W hard constraints are exactly the right constraints for #000070: stay inside canonical encoding, public quantization, and collision-resistant hashing; every `π*_w` is defined over quantized integer state, not continuous tensors; and the grid/frame/clock choices are part of the commitment. ([Arborist API Reference][1]) + +The current π* library also confirms the architectural rule: each modality that touches the bench or audit chain needs a registered `π*` mapping surface bytes to canonical bytes, and SHA-256 of those canonical bytes becomes the equivalence-class identity. It also states that registered `name@version` entries are behaviorally immutable and byte-affecting changes require a new version key. ([Arborist API Reference][2]) + +The cache discipline matters too: Arborist’s cache key includes source root, question hash, model profile hash, conversation hash, governance policy hash, schema version, canonicalization version, and chunking version, and bumping any dimension creates a distinct cache key. ([Arborist API Reference][3]) The concepts page also says the optional 9th verifier-policy dimension exists for audit legibility, while verifier-policy fields are already covered under governance policy by default. ([Arborist API Reference][4]) + +So #000070 must be implemented as a **canonicalization / world-state projection** ticket first, not as a new verifier or audit-mode ticket. + +--- + +# 2. Do we already have #000070? + +```text +Partially. + +Already present: + v7-W paper and world-state tuple taxonomy. + π* registry discipline. + canonicalization-version discipline. + Merkle/SHA-256 commitment model. + hard/soft proof-path separation. + time-series-quantized@v1 and math π* precedent. + metacognition, DAG, run provenance, cache invalidation. + broader Merkle-AGI-DAG-Reverse-RAG / SQD / CTI / PROMETHEUS-Σ architecture. + +Missing: + executable π*_w_object kernel. + generic AnchorN splitter. + Joseph6 as first registered world grammar. + WorldDimensionGrammar manifest. + grammar_hash and axiom_pack_hash. + axiom/physics-constrained grammar selection. + spatial_anchor_seed manifest field. + KATs for world-object canonicalization. + relation/event/place/agent_trace kernels. +``` + +So the clean answer is: + +```text +We have the conceptual substrate. +We do not yet have the executable state-space instantiation kernel. +``` + +#000070 should be the first implementation ticket that moves v7-W from paper/scaffold into runnable deterministic substrate code. + +--- + +# 3. Core correction: replace fixed Anchor6 with generic AnchorN + +The original six-region design is not wrong. It is a good **default grammar**. But it is too brittle as the substrate primitive. + +## 3.1 Old model + +```text +hash → H₁..H₆ → position, scale, rotation, material, relation, behavior +``` + +This is easy to implement and easy to test. But it assumes every object-like state should be decomposed into exactly six dimensions. + +That fails for richer world-state. + +A rigid body may need: + +```text +position +orientation +scale +velocity +angular_velocity +mass +material +collision_shape +``` + +A field object may need: + +```text +support_region +field_type +amplitude +gradient +boundary_condition +time_evolution +``` + +A temporal event may need: + +```text +t_start +t_end +participants +place +causal_preconditions +causal_effects +confidence +``` + +A social/legal/institutional object may need: + +```text +agent_id +role +permission +obligation +counterparty +jurisdiction +time_window +evidence_root +``` + +So the primitive should not be `Anchor6`. + +## 3.2 Correct model + +```text +AnchorN = deterministic split of a hard commitment into N typed dimension seeds. +``` + +Formal object: + +```text +Given: + H = 32-byte hard hash + S = 32-byte spatial_anchor_seed + G = frozen WorldDimensionGrammar + N = len(G.dimensions) + +Compute: + R = HMAC_SHA512_expand(S, H, 32N) + +Split: + R = D₁ || D₂ || ... || D_N + where each Dᵢ is 32 bytes + +Map: + fieldᵢ = mapperᵢ(Dᵢ, G, manifest) + +Canonicalize: + W = canonical_json({ + pi_star_ref, + grammar_hash, + axiom_pack_hash, + seed_hash, + hard_hash, + fields + }) + +Commit: + world_object_hash = SHA256(W) +``` + +Then Joseph’s six slots become: + +```text +Joseph6 = first registered WorldDimensionGrammar +``` + +not the final ontology. + +--- + +# 4. Corrected ticket title + +The current ticket should become: + +```text +#000070 — AnchorN and π*_w_object: deterministic world-object canonicalization +``` + +Optional subtitle: + +```text +Phase 1: Joseph6 default grammar over generic AnchorN +``` + +This title prevents conceptual lock-in. + +--- + +# 5. Corrected direct answer to your latest intuition + +Your intuition: + +```text +“Load it with maths and physics axioms and let it decide how many.” +``` + +Correct version: + +```text +Load a frozen axiom/physics pack. +Generate or select a candidate WorldDimensionGrammar. +Validate it deterministically. +Freeze its grammar_hash. +Then AnchorN uses that frozen grammar to decide N. +``` + +Unsafe version: + +```text +Ask an LLM at runtime how many dimensions to use. +``` + +That breaks reproducibility. + +Safe version: + +```text +LLM may propose grammar candidates. +Only deterministic validators can accept them. +Accepted grammar is canonicalized, hashed, KAT-tested, and versioned. +``` + +So yes, your direction is better, but only with a hard boundary: + +```text +Axioms may select the grammar. +The grammar must be frozen before proof-path use. +``` + +--- + +# 6. Axiom-governed WorldDimensionGrammar + +## 6.1 What a grammar is + +A `WorldDimensionGrammar` is a deterministic manifest that says: + +```text +For this object/event/world-state class, +these are the dimensions, +these are their mappers, +these are their units, +these are their invariants, +these are their admissibility tests, +these are their quantization rules. +``` + +Example: + +```json +{ + "grammar_id": "spatial-object-joseph6@v1", + "grammar_kind": "world_object", + "axiom_pack_refs": [ + "logic-core@v1", + "set-theory-zf-fragment@v1", + "peano-arithmetic@v1", + "euclidean-geometry@v1", + "classical-mechanics@v1", + "kolmogorov-probability@v1" + ], + "dimensions": [ + { + "name": "position", + "type": "octree_cell", + "mapper": "octree-cell@v1", + "unit": "cell_id", + "invariants": [ + "frame_id_committed", + "integer_quantized", + "cell_id_in_range" + ] + }, + { + "name": "scale", + "type": "scale_level", + "mapper": "scale-level@v1", + "invariants": [ + "level_min_le_level_le_level_max" + ] + }, + { + "name": "rotation", + "type": "orientation_cell", + "mapper": "euler-ypr@v1", + "invariants": [ + "orientation_quantized", + "axis_order_committed" + ] + }, + { + "name": "material", + "type": "symbol_table_index", + "mapper": "material-table@v1", + "invariants": [ + "material_table_nonempty", + "material_index_in_range" + ] + }, + { + "name": "relation_seed", + "type": "raw_relation_entropy", + "mapper": "passthrough-hex@v1", + "invariants": [ + "reserved_for_relation_kernel" + ] + }, + { + "name": "behavior", + "type": "symbol_table_index", + "mapper": "behavior-table@v1", + "invariants": [ + "behavior_table_nonempty", + "behavior_index_in_range" + ] + } + ] +} +``` + +This is Joseph6 as a grammar. + +## 6.2 How axioms decide the number of dimensions + +The selector should solve: + +```text +G* = argmin_G [ + residual(G; benchmark_tasks) + + λ_complexity · complexity(G) + + λ_cost · compute_cost(G) + + λ_privacy · privacy_cost(G) + + λ_instability · version_drift_risk(G) +] +``` + +Subject to: + +```text +logic invariants pass +set/type invariants pass +arithmetic/counting invariants pass +geometry/frame invariants pass +temporal invariants pass +physics constraints pass, if the object class claims physical grounding +privacy constraints pass +KAT replay passes +canonicalization is deterministic +no continuous tensor enters proof path +``` + +This is the correct implementation of “let it decide how many.” + +The system does not “feel” how many dimensions it wants. It selects the minimal sufficient state basis under formal constraints. + +--- + +# 7. How geometry emerges naturally + +Geometry emerges when the grammar contains: + +```text +frame_id +grid type +origin commitment +spatial level +cell id +transform rules +metric/adjacency rules +``` + +For example, the v7-W docs already recommend hierarchical grids: S2-style cells for geographic frames, octree levels for local object-fixed frames, and quadtree levels for 2D floor/image-plane frames. The manifest declares grid type, frame, origin commitment, `level_min`, `level_max`, and extent. ([Arborist API Reference][1]) + +Once that is in the grammar, geometry is not latent. It becomes enumerable: + +```text +cell_count(level) = 8^level for octree +cell_count(level) = 4^level for quadtree +neighbors(cell) = deterministic adjacency function +parent(cell) = floor(cell / branching_factor) +children(cell) = deterministic child set +``` + +So geometry emerges as: + +```text +finite cell algebra + frame transforms + metric constraints +``` + +not as a neural embedding. + +--- + +# 8. How counting emerges naturally + +Counting emerges because every canonical domain is finite or explicitly quantized. + +For an octree grammar: + +```text +number_of_cells(level) = 8^level = 2^(3level) +``` + +For a material table: + +```text +number_of_materials = len(materials) +``` + +For behavior codes: + +```text +number_of_behaviors = len(behaviors) +``` + +For a full Joseph6 object grammar: + +```text +state_count ≈ + position_cells(level) + × scale_levels + × rotation_bins + × material_count + × relation_seed_space + × behavior_count +``` + +This directly connects `π*_w_object` to existing `combinatorics@v1`. The current π* library already includes a pure-integer counting kernel and math kernels for exact rational arithmetic, symbolic algebra, calculus, linear algebra, sampled functions, and time-series quantization. ([Arborist API Reference][2]) + +So the AGI substrate route is: + +```text +world grammar → finite state space → combinatorics kernel → countable search/sampling → falsifiable transitions +``` + +Counting is not external. It is induced by the canonical grammar. + +--- + +# 9. How temporal domain emerges naturally + +The v7-W docs already define temporal canonicalization. Single-agent deployments can use wall-clock ticks with a declared epoch and Δt, while multi-agent deployments can use Lamport or vector clocks with tie-breaking. ([Arborist API Reference][1]) + +So the AnchorN grammar should reserve temporal dimensions only when needed. + +Examples: + +For a static object: + +```text +dimensions: + position + scale + rotation + material +``` + +For an observation: + +```text +dimensions: + observer_agent + observed_at_time + frame_id + object_id + confidence +``` + +For an agent trace: + +```text +dimensions: + t_i + pose_i + attention_target_i + transition_reason_i +``` + +Temporal emergence is then: + +```text +clock manifest + discrete ticks + event transition grammar +``` + +And causality becomes testable: + +```text +state_t ++ committed transform/event +→ state_t+1 +``` + +The v7-W theorem section already states that a commitment chain is causally complete only if every transition between consecutive observations is justified by a committed transform or event. ([Arborist API Reference][1]) + +#000070 should be the first object-state piece. Later tickets must add event and transition kernels. + +--- + +# 10. How mathematics and physics enter without breaking determinism + +Mathematics/physics should enter as **axiom packs and invariant validators**, not as free-form model beliefs. + +## 10.1 AxiomPack + +```json +{ + "axiom_pack_id": "classical-rigid-body@v1", + "axioms": [ + "integer_grid_state@v1", + "frame_transform_composition@v1", + "positive_extent@v1", + "bounded_velocity@v1", + "mass_nonnegative@v1", + "causal_transition_requires_event_or_transform@v1" + ], + "validators": [ + "validate_integer_quantization", + "validate_frame_transform", + "validate_causal_transition", + "validate_energy_bound_optional" + ] +} +``` + +## 10.2 Deterministic validation + +Every accepted grammar must pass: + +```text +type check +range check +unit check +frame check +clock check +countability check +privacy check +KAT replay +bench fixture replay +``` + +Physics enters as constraints: + +```text +no silent teleportation +no uncommitted frame transform +bounded velocity unless event explains discontinuity +causal gap flagged +collision/occlusion predicates require relation kernel +``` + +That is enough to instantiate a physics-aware state-space without pretending to solve all physics. + +--- + +# 11. Why this is AGI-relevant + +A normal LLM stack does this: + +```text +pixels/text → embedding → answer +``` + +The state is implicit. The model may “know” geometry, but cannot expose a deterministic, replayable world-state. + +Your stack should do this: + +```text +input / observation +→ canonical projection π* +→ committed state object +→ relation/event/trace update +→ falsification +→ accepted state transition +→ memory/root update +→ recursive improvement +``` + +#000070 is the first executable piece of: + +```text +world-state as committed substrate +``` + +That matters because AGI in your true sense is better modeled as accepted state transition, not output generation. + +A system becomes more AGI-like when it can: + +```text +represent its state +commit its state +transform its state +falsify illegal transitions +repair or quarantine bad transitions +compare candidate futures +choose lower-residual updates +preserve provenance across time +``` + +#000070 gives the world-object state primitive. It does not finish AGI, but it is foundational. + +--- + +# 12. Corrected #000070 specification + +## 12.1 Purpose + +```text +Implement a deterministic world-object canonicalization kernel that maps: + + hard_hash_32 + spatial_anchor_seed + WorldDimensionGrammar + world manifest + +to: + + canonical world-object bytes + world_object_hash + +using generic AnchorN, with Joseph6 as the first default grammar. +``` + +## 12.2 Non-purpose + +```text +Not a semantic truth verifier. +Not a SLAM stack. +Not a relation kernel. +Not an event kernel. +Not a place kernel. +Not an agent_trace kernel. +Not a learned world model. +Not a runtime LLM ontology selector. +``` + +## 12.3 Phase 1 deliverable + +```text +Generic AnchorN split. +Joseph6 grammar. +π*_w_object canonicalizer. +KATs. +Tests. +Docs amendment. +No SQL. +No new audit_mode. +No verifier_policy_hash change. +``` + +--- + +# 13. Corrected implementation layout + +The public π* docs say new π* modules should be registry-addressable by `name@version`, and behaviorally immutable once registered. ([Arborist API Reference][2]) + +Recommended package split: + +```text +arborist/substrate/spatial_anchor.py + AnchorN + split_anchor_n() + SPATIAL_ANCHOR_VERSION + PLACEHOLDER_SPATIAL_SEED + +arborist/world/grammar.py + WorldDimensionGrammar + canonical_grammar_bytes() + grammar_hash() + validate_grammar() + +arborist/world/pi_star/object.py + derive_world_object_record() + mappers: + map_octree_position() + map_scale_level() + map_rotation_euler_ypr() + map_symbol_table_index() + map_passthrough_hex() + +arborist/pi_star/spatial_anchor_object.py + registered π* adapter: + name = "spatial-anchor-object" + version = "v1" + canonicalize(raw: bytes) -> bytes + +bench/fixtures/spatial-anchor-object/known-answer-tests.jsonl + +tests/test_spatial_anchor.py +tests/test_world_dimension_grammar.py +tests/test_pi_star_spatial_anchor_object.py +``` + +This preserves: + +```text +arborist/pi_star/ + registry-facing canonicalizer + +arborist/world/ + v7-W domain logic +``` + +--- + +# 14. AnchorN pseudocode + +```python +from __future__ import annotations + +import hmac +import hashlib +from dataclasses import dataclass +from typing import Tuple + + +SPATIAL_ANCHOR_VERSION = "spatial-anchor-n@v1-hmac-sha512-le" + + +@dataclass(frozen=True) +class AnchorN: + version: str + regions: Tuple[bytes, ...] + + +def _require_bytes_32(name: str, value: bytes) -> None: + if not isinstance(value, bytes): + raise TypeError(f"{name} must be bytes") + if len(value) != 32: + raise ValueError(f"{name} must be exactly 32 bytes") + + +def _expand_hmac_sha512(seed: bytes, message: bytes, out_len: int) -> bytes: + out = bytearray() + counter = 0 + while len(out) < out_len: + ctr = counter.to_bytes(4, "little") + out.extend(hmac.new(seed, message + ctr, hashlib.sha512).digest()) + counter += 1 + return bytes(out[:out_len]) + + +def split_anchor_n( + hard_hash_32: bytes, + *, + seed: bytes, + n_regions: int, +) -> AnchorN: + _require_bytes_32("hard_hash_32", hard_hash_32) + _require_bytes_32("seed", seed) + + if not isinstance(n_regions, int): + raise TypeError("n_regions must be int") + if n_regions <= 0: + raise ValueError("n_regions must be positive") + if n_regions > 1024: + raise ValueError("n_regions too large for v1 policy cap") + + raw = _expand_hmac_sha512(seed, hard_hash_32, 32 * n_regions) + regions = tuple(raw[i:i + 32] for i in range(0, 32 * n_regions, 32)) + + return AnchorN( + version=SPATIAL_ANCHOR_VERSION, + regions=regions, + ) +``` + +Policy cap `n_regions <= 1024` is arbitrary but useful. It prevents denial-of-service by a malicious manifest declaring millions of dimensions. + +--- + +# 15. Corrected Joseph6 grammar + +```python +JOSEPH6_GRAMMAR = { + "grammar_id": "spatial-object-joseph6@v1", + "grammar_kind": "world_object", + "dimensions": [ + { + "name": "position", + "mapper": "octree-cell@v1", + "source_region": 0, + }, + { + "name": "scale", + "mapper": "scale-level@v1", + "source_region": 1, + }, + { + "name": "rotation", + "mapper": "euler-ypr@v1", + "source_region": 2, + }, + { + "name": "material", + "mapper": "symbol-table-index@v1", + "source_region": 3, + "table": "materials", + }, + { + "name": "relation_seed", + "mapper": "passthrough-hex@v1", + "source_region": 4, + "reserved_for": "pi_w_relation", + }, + { + "name": "behavior", + "mapper": "symbol-table-index@v1", + "source_region": 5, + "table": "behaviors", + } + ] +} +``` + +This preserves Joseph6 while making the substrate extensible. + +--- + +# 16. Critical mapper correction: H₁ must use uint256, not uint64 + +Earlier I identified a real implementation bug risk: if H₁ only reads the first 8 bytes, it fails for v7-W’s documented `level_max = 24` octree example. The docs show `level_max: 24`; an octree at level 24 has `8^24 = 2^72` cells, which cannot be fully addressed by a 64-bit integer. ([Arborist API Reference][1]) + +Correct: + +```python +def uint256_le(region: bytes) -> int: + if len(region) != 32: + raise ValueError("region must be 32 bytes") + return int.from_bytes(region, "little") + + +def map_octree_cell(region: bytes, *, level: int) -> int: + if level < 0: + raise ValueError("level must be nonnegative") + if 3 * level > 256: + raise ValueError("octree level too deep for 256-bit region") + cells = 1 << (3 * level) + return uint256_le(region) % cells +``` + +Also fix composition: + +```text +H₂ should select scale_level first. +H₁ should map position at that selected scale_level. +``` + +So: + +```python +scale_level = map_scale_level(H2, level_min, level_max) +cell_id = map_octree_cell(H1, level=scale_level) +``` + +This is more coherent than mapping H₁ at `level_max` while separately outputting a scale level. + +--- + +# 17. Rotation: do not overclaim SO(3) + +If Phase 1 uses three integer bins, call it: + +```text +euler-ypr@v1 +``` + +not: + +```text +SO(3) proof +integer quaternion grid +``` + +Manifest: + +```json +{ + "rotation": { + "mapper": "euler-ypr@v1", + "axis_order": "yaw_pitch_roll", + "delta_milli_radians": 1, + "range": "mod_2pi" + } +} +``` + +Future ticket: + +```text +spatial-anchor-so3-codebook@v1 +``` + +That future grammar can handle: + +```text +quaternion normalization +q ≡ -q equivalence +uniform-ish SO(3) cell codebook +codebook_hash +``` + +Do not put that complexity in #000070 Phase 1. + +--- + +# 18. Canonical object output + +Every output must include version and grammar identity. + +```json +{ + "pi_star_ref": "spatial-anchor-object@v1", + "anchor_version": "spatial-anchor-n@v1-hmac-sha512-le", + "grammar_id": "spatial-object-joseph6@v1", + "grammar_hash": "sha256:...", + "axiom_pack_hash": "sha256:...", + "manifest_hash": "sha256:...", + "seed_hash": "sha256:...", + "hard_hash_hex": "...", + + "fields": { + "position": { + "kind": "octree_cell", + "level": 18, + "cell_id": "123456789" + }, + "scale": { + "level": 18 + }, + "rotation": { + "kind": "euler-ypr@v1", + "bins": [123, 456, 789] + }, + "material": { + "table": "materials", + "index": 4, + "value": "metal" + }, + "relation_seed": { + "hex": "..." + }, + "behavior": { + "table": "behaviors", + "index": 2, + "value": "static" + } + } +} +``` + +Canonical bytes: + +```python +json.dumps(record, sort_keys=True, separators=(",", ":"), ensure_ascii=False).encode("utf-8") +``` + +Then: + +```text +world_object_hash = SHA256(canonical_bytes) +``` + +--- + +# 19. Privacy and safety + +Spatial commitments can leak sensitive state. Therefore: + +```text +privacy.class is mandatory. +No default to public. +``` + +Phase 1: + +```text +privacy.class == public: + allow. + +privacy.class == aggregated_only: + raise NotImplementedError or emit non-exportable local object only. + +privacy.class == ZK_with_selective_disclosure: + raise NotImplementedError pending #000016. + +privacy.class missing: + fail closed. +``` + +This preserves future private/ZK work without pretending Phase 1 solves it. + +--- + +# 20. Hash / cache / verifier-policy discipline + +For #000070 Phase 1: + +```text +canonicalization_version: + must include spatial-anchor-object@v1. + +governance_policy_hash: + must include active world grammar hash / manifest hash if used during query/agent execution. + +schema_version: + unchanged, because no SQL in Phase 1. + +verifier_policy_hash: + unchanged, because this is not a verifier rule. + +audit_mode: + unchanged. +``` + +If later world-state commitments become a verifier method, that is a different ticket and `verifier_policy_hash` must move. + +--- + +# 21. Tests and KATs + +Minimum KAT rows: + +```text +1. all-zero hard_hash +2. all-ff hard_hash +3. alternating 00ff hard_hash +4. fixed random hard_hash +5. one-bit flip from row 4 +6. same hard_hash, different seed +7. same seed, different Joseph6 material table order +8. same seed, different level_max +9. level_max=24 regression proving uint256 position mapping +10. variable AnchorN grammar with N=8 +``` + +Each KAT row pins: + +```text +anchor_version +pi_star_ref +grammar_hash +manifest_hash +seed_hash +hard_hash_hex +N +regions_hex[] +field outputs +canonical_output_sha256 +``` + +Required tests: + +```text +test_split_anchor_n_requires_32_byte_hash +test_split_anchor_n_requires_32_byte_seed +test_split_anchor_n_rejects_nonpositive_n +test_split_anchor_n_policy_cap +test_split_anchor_n_deterministic +test_split_anchor_n_changes_with_seed +test_split_anchor_n_changes_with_hash +test_joseph6_is_wrapper_over_anchor_n +test_position_uses_uint256_not_uint64_level24 +test_h2_scale_drives_h1_position_level +test_rotation_mapper_declared_euler_not_so3 +test_material_table_nonempty +test_behavior_table_nonempty +test_manifest_requires_privacy_class +test_non_public_privacy_fails_closed_phase1 +test_canonical_output_includes_grammar_hash +test_canonical_output_includes_manifest_hash +test_canonical_output_includes_axiom_pack_hash +test_registered_pi_star_exists +test_pi_star_returns_bytes +test_no_audit_mode_change +test_no_verifier_policy_hash_change +test_no_sql_write +``` + +--- + +# 22. Relationship to #000071 + +#000070 and #000071 must stay separate. + +```text +#000070: + one world, one grammar, one object-state canonicalization. + +#000071: + bridge grammar between worlds/chains. +``` + +AnchorN tells you how to instantiate state inside a world. + +World-bridge grammar tells you whether two worlds can exchange, translate, quarantine, or reject each other’s states. + +Do not merge them. + +--- + +# 23. Roadmap to AGI substrate + +## Phase 1 — AnchorN + Joseph6 + +Deliver: + +```text +generic AnchorN +Joseph6 default grammar +π*_w_object canonicalizer +KATs +no SQL +no verifier changes +``` + +AGI value: + +```text +first deterministic world-object state primitive +``` + +## Phase 2 — WorldDimensionGrammar + +Deliver: + +```text +grammar manifest +grammar_hash +axiom_pack_hash +dimension registry +mapper registry +grammar validators +``` + +AGI value: + +```text +state-space dimensionality becomes explicit, reproducible, evolvable +``` + +## Phase 3 — AxiomPack and physics validators + +Deliver: + +```text +logic/set/arithmetic/geometry/time/physics axiom packs +deterministic invariant checks +minimal sufficient dimension selector +``` + +AGI value: + +```text +math and physics constrain world-state, rather than merely appearing in text +``` + +## Phase 4 — Relation kernel + +Deliver: + +```text +π*_w_relation +relation_seed consumption +ordered/symmetric relation rules +predicate whitelist +relation confidence +time_window +``` + +AGI value: + +```text +geometry becomes relational; objects become graph nodes +``` + +## Phase 5 — Event kernel + +Deliver: + +```text +π*_w_event +state_t + event → state_t+1 +causal completeness checks +``` + +AGI value: + +```text +temporal state transitions become falsifiable +``` + +## Phase 6 — Place and agent_trace kernels + +Deliver: + +```text +π*_w_place +π*_w_agent_trace +trace quantization +frame transforms +Lamport/vector clock support +``` + +AGI value: + +```text +persistent agent state, navigation, spatial memory +``` + +## Phase 7 — MemoryRoot / SelfModel integration + +Deliver: + +```text +world_state_root +memory_root integration +SelfModel state links +state transition DAG +``` + +AGI value: + +```text +the system can know what it has seen, where, when, and under what commitments +``` + +## Phase 8 — v8 selection / consensus + +Deliver: + +```text +validators compare world transitions +ForkScore consumes world-state residuals +challenge protocol catches illegal transitions +``` + +AGI value: + +```text +recursive self-improvement becomes benchmark-governed and consensus-filtered +``` + +## Phase 9 — recursive improvement loop + +Loop: + +```text +observe +→ canonicalize +→ commit +→ predict next state +→ compare with future observation +→ falsify residual +→ update grammar/mapper candidate +→ benchmark +→ accept only if residual decreases without proof-path regression +``` + +This is the actual AGI route: + +```text +not “model gets smarter by outputting more text” +but “system improves by reducing state-transition residual under provenance.” +``` + +--- + +# 24. How this instantiates state-space + +The state-space is: + +```text +Ω_t = ( + ObjectRoot_t, + RelationRoot_t, + EventRoot_t, + PlaceRoot_t, + AgentTraceRoot_t, + MemoryRoot_t, + SelfModelRoot_t, + PolicyRoot_t, + GrammarRoot_t, + AxiomPackRoot_t +) +``` + +Transition: + +```text +Ω_{t+1} = T(Ω_t, Observation_t, Action_t, Event_t, Grammar_t) +``` + +Accepted only if: + +```text +canonicalization passes +frame/time transforms are committed +physics/logic invariants pass +falsification residual within bound +audit/provenance roots update deterministically +``` + +This lets domains emerge: + +```text +counting: + finite state enumeration from quantized grammar. + +geometry: + grid cells, frames, transforms, adjacency, containment. + +time: + clock ticks, Lamport/vector order, time windows. + +logic: + relations, predicates, constraints, truthtables. + +math: + combinatorics, algebra, linear transforms, calculus kernels for dynamics. + +physics: + transition invariants, causality, bounded velocity/energy constraints. + +agency: + action DAG + state transition + SelfModel update. +``` + +That is the substrate-level AGI move. + +--- + +# 25. Final corrected ticket text + +```text +#000070 — AnchorN and π*_w_object: deterministic world-object state canonicalization + +Status: + GO after ticket rewrite. + +Purpose: + Implement the first executable v7-W world-object canonicalization kernel. + The kernel maps a hard hash, spatial anchor seed, and frozen world grammar + into canonical world-object bytes. + +Core correction: + The substrate primitive is AnchorN, not Anchor6. + Joseph6 is the first registered WorldDimensionGrammar, not the final ontology. + +Inputs: + hard_hash_32 + spatial_anchor_seed + WorldDimensionGrammar + world manifest + +Outputs: + canonical world-object bytes + world_object_hash + object record with grammar_hash, axiom_pack_hash, manifest_hash, seed_hash + +Phase 1: + split_anchor_n() + Joseph6 grammar + spatial-anchor-object@v1 π* + KATs and tests + docs amendment + +Out of scope: + semantic verifier warrant + new audit_mode + SQL persistence + relation/event/place/agent_trace + runtime LLM-selected dimensionality + +Hard constraints: + deterministic + quantized integer state only + no continuous tensor in proof path + no LLM-as-judge + no hidden soft transform + no in-place version mutation + fail closed on missing privacy.class +``` + +--- + +# 26. Final compressed answer + +```text +The earlier H₁..H₆ design is a good first grammar, but it should not be the substrate limit. + +Correct architecture: + + AnchorN + WorldDimensionGrammar. + +Joseph6 remains the first default grammar: + + position + scale + rotation + material + relation_seed + behavior + +But the system must support N dimensions selected by frozen, axiom-constrained grammars. + +Math/physics axioms should not dynamically mutate the proof path. +They should generate/validate a grammar. +Once accepted, that grammar is canonicalized, hashed, versioned, KAT-tested, +and used deterministically. + +This gives the AGI path: + + quantized state-space + finite counting + grid/frame geometry + temporal clocks + relation/event transitions + causal completeness + recursive falsification + benchmark-governed self-improvement + +Final decision: + + rewrite #000070 around AnchorN; + implement Joseph6 as Phase 1; + defer axiom-guided grammar selection to Phase 2/3; + preserve no-audit-mode/no-verifier-policy-change discipline; + use the resulting world-object kernel as the first executable v7-W state-space primitive. +``` + +The core insight: + +```text +Six fixed seeds make a demo. +AnchorN plus axiom-frozen grammar makes a substrate. +``` + +[1]: https://arborist.unturf.com/en/latest/merkle-agi-v7w-spatial-temporal.html "Merkle-AGI v7-W — Spatial-Temporal Substrate — Arborist API Reference" +[2]: https://arborist.unturf.com/en/latest/pi-star.html "π* domain library — Arborist API Reference" +[3]: https://arborist.unturf.com/en/latest/api/qa.html "Q&A Pipeline: question → answer → verify → cache — Arborist API Reference" +[4]: https://arborist.unturf.com/en/latest/concepts.html "Concepts — Arborist API Reference" + +--- +# IMPORTANT +Correct — **we should not fix the six seeds as the architecture**. + +My prior wording should be tightened. The correct position is: + +```text +Reject fixed H₁..H₆ as ontology. +Keep H₁..H₆ only as an optional legacy / compatibility profile, not the core design. +Core design = emergent AnchorN from axiom-governed WorldDimensionGrammar. +``` + +So the corrected #000070 principle is: + +```text +Do not start with: + H₁ = position + H₂ = scale + H₃ = rotation + H₄ = material + H₅ = relation + H₆ = behavior + +Start with: + AxiomPack + WorldClass + Constraints + Bench/Falsifiers + → derive minimal sufficient DimensionGrammar G* + → N = |G*.dimensions| + → split hash into AnchorN regions + → map each region through typed mappers + → canonical world-state object +``` + +# 1. The corrected architecture + +The actual substrate primitive should be: + +```text +AnchorN(G) +``` + +not: + +```text +Anchor6 +``` + +Where: + +```text +G = frozen WorldDimensionGrammar +N = number of dimensions required by G +``` + +So the object kernel becomes: + +```text +hard_hash_32 ++ spatial_anchor_seed ++ axiom_pack_hash ++ world_class ++ constraint_set ++ selected_dimension_grammar_hash +→ AnchorN +→ canonical state record +``` + +The six-seed form is demoted to: + +```text +joseph6@legacy_or_example +``` + +not: + +```text +default ontology +``` + +Even calling it “default” may be too strong if the goal is natural emergence. Better: + +```text +Joseph6 = reference fixture / baseline grammar / backward-compatible example. +``` + +# 2. What “emerge naturally” means without losing determinism + +“Emerge naturally” cannot mean the model dynamically invents dimensions each run. That would destroy reproducibility. + +It should mean: + +```text +The dimension basis is not hand-fixed. +It is selected by deterministic constraint optimization over candidate grammars. +Once selected, it is frozen, hashed, and replayable. +``` + +Formal version: + +```text +Given: + A = axiom pack + W = world class + C = constraints + B = benchmark/falsifier suite + Γ = candidate dimension grammars + +Select: + G* = argmin_G∈Γ [ + residual(G; B) + + λ₁ complexity(G) + + λ₂ compute_cost(G) + + λ₃ privacy_cost(G) + + λ₄ instability_cost(G) + ] + +Subject to: + logic invariants pass + arithmetic/counting invariants pass + geometry/frame invariants pass + temporal invariants pass + physics constraints pass where applicable + KAT replay passes + canonicalization is deterministic +``` + +Then: + +```text +N = |G*.dimensions| +``` + +Only after this do we split: + +```text +AnchorN = HMAC_expand(seed, hard_hash, 32N) +``` + +That is the distinction. + +# 3. What #000070 should say now + +Replace the ticket’s core with: + +```text +#000070 — Axiom-governed AnchorN world-object canonicalization + +Purpose: + Implement the generic substrate for deterministic world-state instantiation. + +Core: + Do not fix six fields. + Implement AnchorN driven by a frozen WorldDimensionGrammar. + +Inputs: + hard_hash_32 + spatial_anchor_seed + axiom_pack_hash + world_class + constraint_set + selected_dimension_grammar + +Output: + canonical world-state record + world_state_hash + +Phase 1: + implement AnchorN + implement WorldDimensionGrammar schema + implement deterministic grammar validation + implement one or more test grammars only as fixtures + +Explicit non-goal: + Do not promote Joseph6 as ontology. +``` + +# 4. What happens to Joseph6? + +Joseph6 can remain only as: + +```text +test fixture +example grammar +compatibility profile +sanity-check baseline +``` + +Not: + +```text +the primitive +the ontology +the mandatory default +the AGI path +``` + +Correct label: + +```text +spatial-object-joseph6@fixture-v1 +``` + +or: + +```text +spatial-object-sixslot-baseline@v1 +``` + +Not: + +```text +spatial-anchor-object@v1 +``` + +because that name implies six-slot is the object grammar. + +Better naming: + +```text +anchor-n@v1 +world-dimension-grammar@v1 +world-object-canonicalizer@v1 +sixslot-baseline-grammar@v1 +``` + +# 5. Corrected implementation roadmap + +## Phase 1 — generic substrate only + +Implement: + +```text +split_anchor_n(hash, seed, n) +WorldDimensionGrammar +grammar_hash +axiom_pack_hash +dimension registry +mapper registry +canonical output schema +KATs for N = 1, 2, 6, 8, 16 +``` + +Do **not** hard-code: + +```text +position +scale +rotation +material +relation +behavior +``` + +except inside a fixture grammar. + +## Phase 2 — axiom/physics grammar selector + +Implement: + +```text +candidate grammar generator +constraint validator +residual scorer +minimal sufficient basis selector +grammar freezing +``` + +Candidate dimensions might include: + +```text +position +orientation +scale +velocity +angular_velocity +mass +material +field_value +relation_boundary +temporal_tick +causal_event +agent_frame +confidence +energy_bound +``` + +The system decides which are needed for a world class. + +## Phase 3 — emergent state-space bench + +Bench asks: + +```text +Can this grammar support counting? +Can it support adjacency? +Can it support frame transforms? +Can it support temporal ordering? +Can it support causal transitions? +Can it support falsification of impossible transitions? +``` + +The grammar survives only if it passes. + +## Phase 4 — relation/event/place/agent traces + +Only after object grammar emerges do we add: + +```text +π*_w_relation +π*_w_event +π*_w_place +π*_w_agent_trace +``` + +# 6. The AGI substrate version + +The corrected AGI state equation is: + +```text +Ω_t = ( + GrammarRoot_t, + AxiomPackRoot_t, + ObjectRoot_t, + RelationRoot_t, + EventRoot_t, + PlaceRoot_t, + AgentTraceRoot_t, + MemoryRoot_t, + SelfModelRoot_t, + PolicyRoot_t +) +``` + +Transition: + +```text +Ω_{t+1} = T(Ω_t, Observation_t, Action_t, Falsifier_t) +``` + +Accepted only if: + +```text +selected grammar is frozen +canonicalization passes +geometry/counting/time invariants pass +physics constraints pass where applicable +Merkle roots update deterministically +residual decreases or stays within bound +``` + +This is where geometry/counting/time emerge: + +```text +counting: + from finite quantized dimensions and state enumeration. + +geometry: + from selected spatial dimensions, adjacency, frame transforms. + +time: + from selected temporal dimensions, clocks, event order. + +logic: + from relation/event predicates and truthtables. + +physics: + from transition constraints and conservation/bound validators. +``` + +# 7. Final correction to my earlier answer + +Earlier I said: + +```text +Implement Joseph6 as Phase 1. +``` + +Corrected: + +```text +Implement AnchorN as Phase 1. +Use Joseph6 only as a test fixture or example grammar. +Do not make Joseph6 the first canonical object ontology. +``` + +Even more precise: + +```text +The first canonical object ontology should be whatever the +WorldDimensionGrammar selector validates under the chosen axiom pack +and benchmark constraints. + +Until that selector exists, Joseph6 must be explicitly marked: + non-authoritative baseline fixture. +``` + +# 8. Final answer + +You are right to push back. + +```text +We are rejecting fixed six seeds as the substrate. +We are not rejecting the ability to test a six-slot fixture. +``` + +The corrected #000070 should be: + +```text +AnchorN first. +Axiom-governed WorldDimensionGrammar second. +Emergent N from constraint optimization. +Joseph6 only as fixture/baseline, not ontology. +``` + +The one-line correction: + +```text +Six fixed seeds make a demo; AnchorN with axiom-selected grammar makes the AGI substrate. +``` diff --git a/docs/tickets/ticket-000070-spatial-anchor-pi-w-object.md b/docs/tickets/ticket-000070-spatial-anchor-pi-w-object.md index 02479e8..3378d76 100644 --- a/docs/tickets/ticket-000070-spatial-anchor-pi-w-object.md +++ b/docs/tickets/ticket-000070-spatial-anchor-pi-w-object.md @@ -1,7 +1,14 @@ -# Ticket #000070 — Spatial-anchor π*_w_object (Joseph 6-dim determination kernel) +# Ticket #000070 — AnchorN + π*_w_object: deterministic world-object canonicalization -**Status:** open · awaiting dav1d review + fox go/no-go · -pre-review empirical bench shipped in `55b651f` (see §7a) +**Status:** open · **dav1d GO with rewrite (2026-06-01)** · spec +revision pending before any kernel ships. Pre-review empirical bench +(`bench/spatial_anchor_validation.py`, commit `55b651f`) already on +disk; no implementation kernel started (only the namespace stub at +`arborist/world/__init__.py` exists, `STATUS = "namespace_reserved"`). +**Original title kept in the design log:** "Spatial-anchor π*_w_object +(Joseph 6-dim determination kernel)". §0 below carries the corrected +spec; §§1-8 preserve the ORIGINAL Anchor6 proposal as the historical +record of what was reviewed. **Opened:** 2026-05-31 **Scope:** Pin the operational spec for **π*_w_object** — the first verifier kernel of v7-W. Implements **Joseph (@TrudoJo)**'s 6-dimension @@ -43,7 +50,163 @@ Joseph (@TrudoJo, original framework author), #000013 follow-up, --- -## 1. Problem statement +## 0. Dav1d review verdict (2026-06-01) — GO with rewrite + +Full review at `docs/dav1d-reviews/000070-spatial-anchor-pi-w-object--2026-06-01.txt` +(1904 lines). Headlines below; §§1-8 stay unchanged as the design log +of the original Anchor6 proposal that was reviewed. + +### 0.1 Verdict matrix + +| | | | +|---|---|---| +| ✅ GO | generic **AnchorN** substrate primitive | not fixed Anchor6 | +| ✅ GO | **Joseph6** as the first registered default grammar | not THE ontology | +| ✅ GO | deterministic object-state canonicalization | the actual Phase 1 win | +| ✅ GO | axiom/physics-loaded `WorldDimensionGrammar` | the scalable path | +| ❌ NO-GO | hard-coding H₁..H₆ as final ontology | freezes the substrate | +| ❌ NO-GO | runtime LLM-decided dimensionality | breaks reproducibility | +| ❌ NO-GO | framing this as a "semantic verifier warrant" | commitments ≠ warrants | +| ❌ NO-GO | relation/event/place/agent_trace inside this ticket | scope-creep | +| ❌ NO-GO | SQL persistence in Phase 1 | namespace-reserved kernel only | + +### 0.2 Architectural reframe + +Replace the fixed Anchor6 primitive with **generic AnchorN** driven +by a frozen `WorldDimensionGrammar`. The grammar is a deterministic +manifest declaring N and the N region→mapper bindings. Joseph6 +becomes a *named* grammar instance (`name="joseph6", version="v1"`), +not THE substrate. + +**Critical correction on the "axioms decide N" intuition:** + + - Axioms MAY *select* the grammar (LLM may *propose* candidates). + - Only *deterministic validators* may accept them. + - Accepted grammars are canonicalized, hashed, KAT-tested, versioned. + - **Grammars must be FROZEN before proof-path use** — `grammar_hash` + folds into the manifest. Runtime LLM dimensionality is the + failure mode dav1d explicitly NO-GOs. + +### 0.3 Technical corrections (load-bearing) + + - **§16 — H₁ MUST use uint256, not uint64.** The original + `map_octree_position()` truncation loses entropy at depth >8 + octants. uint256 preserves the full 32-byte region. Same lesson + propagates to the other quantized dimensions. + - **§17 — Do NOT overclaim SO(3) on rotation.** The original spec + called H₃ a "quantized SO(3)" mapper; dav1d notes this is a + quantized Euler ypr triple — name it `map_rotation_euler_ypr()` + so consumers don't assume continuous SO(3) coverage. + - **§18 — Canonical object output shape:** the record carries + `grammar_hash`, `axiom_pack_hash`, `manifest_hash`, `seed_hash` + alongside the per-dimension quantized values. All four hashes + are required for replayability across grammar versions. + - **§19 — Privacy fail-closed:** missing `privacy.class` in + manifest = HARD reject (don't fall back to PUBLIC). + - **§20 — Hash/cache discipline:** spatial-anchor-object@v1 folds + into `canonicalization_version` only; no new `audit_mode` token, + no `verifier_policy_hash` bump. + +### 0.4 Corrected package layout (was §13 of the review) + +``` +arborist/substrate/spatial_anchor.py + AnchorN + split_anchor_n() + SPATIAL_ANCHOR_VERSION + PLACEHOLDER_SPATIAL_SEED + +arborist/world/grammar.py (NEW) + WorldDimensionGrammar + canonical_grammar_bytes() + grammar_hash() + validate_grammar() + +arborist/world/pi_star/object.py + derive_world_object_record() + map_octree_position() # uint256 — see §16 + map_scale_level() + map_rotation_euler_ypr() # not "SO(3)" — see §17 + map_symbol_table_index() + map_passthrough_hex() + +arborist/pi_star/spatial_anchor_object.py (NEW) + registered π* adapter + name = "spatial-anchor-object" + version = "v1" + canonicalize(raw: bytes) -> bytes + +bench/fixtures/spatial-anchor-object/known-answer-tests.jsonl +tests/test_spatial_anchor.py +tests/test_world_dimension_grammar.py +tests/test_pi_star_spatial_anchor_object.py +``` + +The split moves **registry-facing canonicalization** to +`arborist/pi_star/` and keeps **v7-W domain logic** under +`arborist/world/`. AnchorN itself stays substrate-level alongside +`anchor_prg.py` since it's the generic key-derivation primitive. + +### 0.5 Phase 1 deliverable (corrected) + +``` +1. generic split_anchor_n() — substrate, hash-pinned +2. Joseph6 grammar instance — frozen, KAT-tested +3. π*_w_object canonicalizer — registry slot +4. KATs at bench/fixtures/spatial-anchor-object/known-answer-tests.jsonl +5. Tests (3 modules above) +6. Substrate-paper amendment citing Joseph (@TrudoJo) +7. NO SQL +8. NO new audit_mode +9. NO verifier_policy_hash change +``` + +### 0.6 Relationship to #000071 (cross-ref) + +Dav1d §22 confirms #000071 (world-bridge grammar) is the right +sibling: bridges connect different `WorldDimensionGrammar` instances +across chains. AnchorN + grammar identity is what the bridge layer +identifies; without grammar-as-first-class-object, bridges have +nothing to anchor. + +### 0.7 Five dav1d open-questions answered by measurement, five still open + +§7a of this ticket already cited the pre-review empirical bench +(`bench/spatial_anchor_validation.py`) resolving five of the ten +original open questions (Q1 seed source / Q2 segmentation / Q3 +octree mapper / Q8 endianness / Q9 KAT adversarial vectors). The +review preserves those resolutions and reframes Q4/Q5/Q6/Q7/Q10: + + - **Q4 scope split** — answered: object alone, NO relation/event/ + place/agent_trace in this ticket. AnchorN handles N=6+ kernels + in future tickets. + - **Q5 privacy fail-closed default** — answered: HARD reject on + missing `privacy.class`. + - **Q6 `audit_mode` discipline** — answered: spatial commits are + not warrants, no new token. + - **Q7 manifest-validator timing** — defer to grammar validation + step in `arborist/world/grammar.py:validate_grammar()`. + - **Q10 paper-amendment wording** — still open; substrate paper + text needs revision to introduce AnchorN + grammar layer + instead of fixed Anchor6. + +### 0.8 What changes for the implementer + +The original §3 "Recommendation" + §4 "Implementation sketch" name +specific functions (`segment_anchor()`, fixed-6-region split, etc.). +Those stay in the design log as reference; **what actually ships +follows §0.4 above** — `split_anchor_n()` with grammar-driven N, +`WorldDimensionGrammar` class, registry-addressable π* adapter. + +The original §7a empirical bench remains valid as evidence — it +validated the HMAC-SHA-512 expansion's avalanche / uniformity / +domain-separation properties, which are unchanged by the AnchorN +generalization (N just changes the loop count; the per-region +properties measured stay identical). + +--- + +## 1. Problem statement *(original design log — what was reviewed)* ### 1.1 What #000013 left undefined