{"slug":"implementation/codebase-alignment","title":"25 · Codebase Alignment","section":"implementation","sectionLabel":"Implementation","status":"unclassified","type":"document","path":"implementation/codebase-alignment.mdx","bytes":3875,"description":"Founder Canon → repository reality. Baseline commit, surveyed services/packages/apps, nine planes, drift register G-01 → G-10, evidence, status, remediation sequence.","updated":null,"source":"integratewise/Integratewise-docs-wiki","content":"\n## What This Page Is\n\nThis page **never redefines the Founder Canon**. It answers:\n\n> **How closely does the implementation currently match it?**\n\n\nAuthority is ranked: Founder decisions (31 Aug 2026) + latest project conversations → late-August consolidation → 1 Aug 2026 freeze → earlier docs/code → external 2026 market research (validation only). See [Founder Canon](/canonical/00-SPINEWORKSPACE-INTEGRATEWISE-CANON).\n\n\n## Baseline & Survey\n\n* **Baseline commit** — `1 Aug 2026 GitHub canonical freeze` (implementation baseline where not superseded).\n* **Surveyed surface** — `apps/` (web, docs, auth, connector), `services/` (gateway, spine, pipeline, hermes, ai, twin), `packages/` (capability, work, spine, sdk, types, ui), plus `docs/canonical/` (00–18) as the only source allowed to redefine architecture.\n* **Nine planes** — the SpineWorkspace planes (Business Context Spine, Human + AI Workbenches, Work, Projection, Capability Fabric, Governance, Hermes, Sync/Verify/Reconcile, Identity/Tenancy) traced to code.\n\n## Drift Register (G-01 → G-10)\n\n| ID | Gap | Evidence | Status | Remediation |\n|---|---|---|---|---|\n| **G-01** | Monolithic AI Orchestrator vs separated cognition/routing/agent-runtime/capability/execution | `services/ai` + gateway routing + ADK vs single orchestrator assumption | Partial — separation underway | Finish ADK middleware extraction; see [Runtime Wiring](/implementation/runtime-wiring) |\n| **G-02** | Projection Engine as sole composition layer | `04-projection-engine` vs mixed UI composition paths | Open | Route gateway to delegate composition |\n| **G-03** | Loader as sole canonical writer | `services/pipeline` loader vs direct Spine writes | Open | Enforce governed writers only |\n| **G-04** | IQ Hub derived intelligence only | `services/iq-hub` vs canonical-entity confusion | Open | Constrain to derived |\n| **G-05** | Capability Fabric executes, not Hermes alone | Mixed Hermes direct calls | Open | Route through Fabric |\n| **G-06** | Governance on composition + execution | Partial policy-plane wiring | Open | Dual-plane governance |\n| **G-07** | ADK middleware orphan — actual MCP Pool routing | Orphaned ADK path, MCP Pool boundary unclear | Open | Wiring evidence in Runtime Wiring |\n| **G-08** | Personal Contextual Spine boundary | `03-HUMAN-WORKBENCH-AND-PERSONAL-MEMORY` vs `07_MEMORY_SYSTEM` | Defined | Enforce per-user, serve-BC |\n| **G-09** | Customer Zero → External go-live doctrine | `CUSTOMER_ZERO_CONSTITUTION` vs marketplace | Defined | Follow 16 + marketplace spec |\n| **G-10** | AI Continuity persistence substrate | Canonical: semantic scope defined; substrate remains architecture decision | **Tracked** — see [Memory & Continuity](/spine/memory-continuity) | Decide store/cache/substrate without changing semantic |\n\nRemediation sequence follows this table order — G-01 → G-10 — unless a gap blocks verified closure.\n\n## Evidence\n\nEvery row above links to code, docs, and ADRs. The full evidence bundle and surveyed file list live in `docs/canonical/17-IMPLEMENTATION-ALIGNMENT-AND-GAP-REGISTER.md`.\n\n## Where to Go Next\n\n<CardGroup cols={2}>\n  \n    What imports what, what invokes what, live vs orphaned paths.\n  \n  \n    The decisions that supersede earlier framings.\n  \n  \n    Canon planes → runnable mapping.\n  \n</CardGroup>\n"}