WICK · Total-Recall · PLAN Review

Entity-Brain Foundation — v1

Assemble the existing total-recall faculties (perception · grounding · intuition · credit · recall-wrapper) into the closed learning loop via a hub/blackboard orchestrator plus the two missing pieces — the decision/action HEAD and fusion. Recall-agnostic; additive; fixture-tested. BUILD double-gated.

The core insight. The faculties already exist and are individually tested — but they can't be composed: there's no orchestration contract and no head to run the loop. That gap is recall-independent, so it can be designed, built, and fixture-tested today, in parallel with store-fill. The day the store fills, the faculty layer is ready to wire. freeze-base a36046b6 · sprint_type new_feature · ~450 loc · 0 deletions
4
new files
~450
loc (additive)
5
TDD tasks
L0–L4
scenario cover
0
faculties modified
BUILD gate

Architecture — hub / blackboard (not a linear pipe)

The orchestrator holds a mutable WorkingContext and routes a projection of it to each faculty — faculties take different inputs, they are not chained. The hub retains the original RecallContext because credit.computeOutcomeReward(RecallContext, outcome) needs it (disk-verified) — a linear pipe would lose it.

flowchart TD
    IN["input: RawMemory[] + root"]:::io
    subgraph HUB["orchestrator.ts — WorkingContext (blackboard)"]
      direction TB
      P["perception
perceiveToSessionGraph → SessionGraph"]:::f R["recall-wrapper
→ Candidate[]"]:::f G["grounding-gate
groundCheck(GroundingCandidate, {ledger,root})"]:::f I["intuition
IntuitionEngine → hints (MemoryId[])"]:::f H["decision-action.ts (HEAD)
grounded + hints → Action | Abstention"]:::new FU["fusion.ts
deterministic dedup/merge"]:::new C["credit
computeOutcomeReward(RecallContext, outcome)"]:::f end IN --> P --> R --> FU --> G --> I --> H H -->|Action → outcome| C -->|OutcomeReward| SEAL["seal → MEMORY"]:::io H -->|Abstention| ABS["reward = null · NO seal"]:::risk classDef f fill:#161b22,stroke:#4c8dd6,color:#e6edf3; classDef new fill:#12261a,stroke:#5bbf7b,color:#e6edf3,stroke-width:2px; classDef io fill:#1c232d,stroke:#9aa7b4,color:#e6edf3; classDef risk fill:#2a1820,stroke:#d1607a,color:#e6edf3;

Changes — 4 new files (all additive)

FileRoleKey contract
faculty-contract.tsauthoritative typed interface map + adapter typesimports the 5 real faculty types; defines the genuine-new Candidate→GroundingCandidate adapternew
orchestrator.tsthe hub: WorkingContext + projection routing + the loopholds groundingContext={ledger,root}, recallContext; seals only on Actionnew
decision-action.tsthe HEAD — grounded+hints → Action | Abstentionabstain on empty/low-confidence; Action carries a RecallOutcomeTrace outcomenew
fusion.tsdeterministic multi-source candidate fuse (dedup/merge)order-independent, idempotentnew

TDD tasks → scenario coverage

TaskBuildsTest (layer)
T1faculty-contract.ts + adaptersL1 — each of 5 entrypoints callable in isolation on fixtures; type-checks
T2fusion.tsL3 (A3-3) — dup/overlap sets → identical fused set, order-independent
T3decision-action.ts (HEAD)L3 (A3-1/A3-2) — fabricated→abstain; low-conf→abstain; terminal-state: Action→seal, Abstention→reward null, NO seal
T4orchestrator.ts (hub)L0 (A0-1) + L2 (A2-1) — full loop on fixtures; every seam type-checks or has a documented adapter
T5NC batteryL4 — NC1 faculty tests green · NC2 recall-agnostic · NC3 grounding fail-closed · NC4 fusion determinism + credit=utility · NC-abstain (no seal) · NC5 no live-recall/empty-store BUILD

Traceability: L0→T4 · L1→T1 · L2→T4 · L3→T2,T3 · L4→T5. All five layers covered.

Cross-model panel — converged

Genuine 2-round PLAN panel (signed seats: Grok mandatory + Codex + Gemini; recall endpoint = corroborating dogfood seat).

Grok · approve · steelman 9 Codex · approve (R2) · steelman 8 Gemini · approve (R2) · steelman 9

R1 → R2: Codex caught an abstention/credit contract gap (does Abstention seal credit?); Gemini caught a missing groundingContext in WorkingContext + a mislabeled adapter (sliceMemoriesToCandidates is memories→Candidate, not Candidate→GroundingCandidate). All verified on disk and closed in the revision → R2 unanimous approve.

Gates & risks

BUILD double-gate

Holds until (1) keystone-convergence (the serving-lane W1 harness) and (2) store-fill (WICK_CONTINUOUS_INGEST fills the real co-access store). PLAN/DESIGN proceed now; BUILD waits.

non-duplicative

This faculty layer consumes the filled store; it does not rebuild revive-build's serving-lane W1–W5 (per WICK_WIRING_ROADMAP).

residual risk

Fixture-to-real-store shape drift after store-fill — mitigated by NC2 (recall-agnostic) + thin adapter-typed seams + the L4 battery. New contract seams stay unexercised until the W1 harness lands (Grok's residual).

WICK_ENTITY_BRAIN_FOUNDATION_v1 · PLAN-scope · freeze-base a36046b6 · panel dispatch-ids grok 8774519a / codex e19e7891 / gemini c472c41d · awaiting operator approval → PLAN→DESIGN