02 — Build Plan & Authorized Scope (Phase-1 Test-Mode Build, 2026-06-02)
02 — Build Plan & Authorized Scope
2.1 Order executed
SB-0 → SB-1(F-83-1 + vocab) → SB-12+SB-13 → SB-11 → SB-2 → SB-10.
Note on order vs the mission's recommended SB-0 → SB-12 → SB-13 → SB-10 → SB-11 → SB-2 → SB-1: SB-0 was built first (foundation). SB-1 was brought forward immediately after SB-0 because it is self-contained, carries the mission-critical F-83-1 fix, and its action-type rows are inert vocabulary (no dependency on SB-2/SB-11 tables). The remaining GCOS/ownership tables were then built as their exact rehearsed DDL was retrieved from the KB implementation-index package (docs 38/39/40/58/59/60/61, doc 17/19). SB-10 was built last because its keystone DDL required the most retrieval. No correctness dependency was violated: SB-10's FK targets (governance_ruleset from SB-12, evolution_snapshots) existed before SB-10.
2.2 Per-step authorized object list
- SB-0: CREATE TABLE
governance_build_authorization(+4 idx); CREATE FUNCTIONquorum_passed(text),valid_sovereign_esign(text),fn_build_commit_allowed(text,text); CREATE VIEWv_build_auth_valid. No row seed. - SB-1:
CREATE OR REPLACE TRIGGER trg_birth_apr_action_types … fn_birth_registry_auto('action_code'); INSERT 8apr_action_typesrows (handler_ref='unimplemented',risk='high',status='active'). - SB-12: CREATE TABLE
governance_ruleset. No seed. - SB-13: CREATE TABLE
gov_worker_cursor. No seed. - SB-11: INSERT 5
event_type_registryrows (event_domain='governance',active=false). 0 new tables. - SB-2: CREATE TABLE
governance_responsibility_scope(+6 scope seed); CREATE TABLEgovernance_object_ownership(+3 idx incl. partial-unique); CREATE VIEWv_object_effective_owner. - SB-10: CREATE TABLE
governance_candidate_state(+3 idx). No seed.
2.3 Source of each DDL (no improvisation)
| Step | DDL source (rehearsed-green) |
|---|---|
| SB-0 | hardening doc 03 §3.1-3.4 + bootstrap rehearsal doc 03 (F-AUTH-LIVE-1 president filter mirrored from live fn_apr_quorum_check) |
| SB-1 | hardening doc 03 §3.3/§3.6 + live trigger/function analysis |
| SB-12 | impl-index doc 38 + rehearsal doc 58 |
| SB-13 | impl-index doc 39 §39.4 + rehearsal doc 59 |
| SB-11 | impl-index doc 41 + rehearsal doc 61 |
| SB-2 | impl-index doc 17 (contract) + doc 19 (literal DDL); FK codes verified live |
| SB-10 | impl-index doc 40 §40.4 (exact schema) + rehearsal doc 60 |
2.4 Build discipline (every committed step)
preflight → exact object list → rollback SQL staged → BEGIN..ROLLBACK rehearsal → in-txn verify → staged COMMIT → independent post-COMMIT verify → out-of-scope mutation check → stop/no-stop decision.
2.5 Deliberately deferred (documented, not improvised)
- SB-10 auxiliaries
candidate_scan_run(run ledger) +governance_candidate_object(selective per-object materialization) — exact literal DDL not present in retrieved docs; not needed for inert test substrate (no scanner runs). The keystonegovernance_candidate_stateis self-contained (last_run_idis a soft text ref). - SB-2 resolution enhancements: recursive owner-link-inheritance walk in
v_object_effective_owner+v_object_owner_gap— exact recursive SQL is in impl-index doc 17 §4-5 / the later SB-2 owner-line rehearsal (not retrieved at literal fidelity). The committedv_object_effective_owneris the correct direct-ownership form (rehearsed in doc 19).