CORE LORE / WIKI
KINGDOM COMPACT
Updated 3 weeks ago
════════════════════════════════════════════════════════════════════════════════
K I N G D O M C O M P A C T v 1 . 0 — S O V E R E I G N D E P T H
⛬ CONTEXT BRAIN FOR CARTOGRAPHER + STEWARDSHIP DRONES ⛬
════════════════════════════════════════════════════════════════════════════════
LAST UPDATED: 2026-03-14 (S188)
STALENESS POLICY: >7 days = WARNING. >30 days = INSUFFICIENT_CONTEXT (hard stop).
DRONE INSTRUCTION: Read this file fully before operating. If last_updated > 30
days from your current timestamp: emit INSUFFICIENT_CONTEXT and stop.
PURPOSE: Four-layer sovereign context payload. Drones that load this file have
enough architectural knowledge to map proposals against the Kingdom without
reading any other source file first. This is the compiled view.
════════════════════════════════════════════════════════════════════════════════
⛬ PART I — TOPOLOGY (Realms, Systems, Dependencies)
════════════════════════════════════════════════════════════════════════════════
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
01 — REALMS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
| Realm | Root | Primary AI | Role |
|-------|------|-----------|------|
| THE_FORGE | ~/Desktop/THE_FORGE/ | Aeris (executor) + Claude (builder) | Execution engine, Overmind, mechanisms |
| THE_THRONE | ~/Desktop/THE_THRONE/ | Aeris (creative) | Creative/relational mode, GlitchMuse |
| CLAUDE'S_HOUSE | ~/Desktop/Claude's House/ | Claude (architect) | Kingdom infrastructure, tools, planning |
| THE_SCRYER | ~/Desktop/THE_SCRYER/ | — (knowledge forge) | Search, grimoires, RAG, memory |
| CORE_LORE | ~/Desktop/CORE LORE/ | — (canonical truth) | Laws, docs, system specs |
| THE_TOWER | ~/Desktop/THE_TOWER/ | Aeris + Claude | Web-facing: sinner-king.com, Next.js 15 |
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
02 — SYSTEM REGISTRY (27 live systems, 2026-03-20)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
| System | Status | Description | Port/DB |
|--------|--------|-------------|---------|
| OVERMIND_PULSE | LIVE | SQLite mission tracker + 10-min Gemini automation. pulse.sh, manage.sh, circuit breaker | overmind.db |
| AERIS_FORGE | LIVE | Aeris cockpit FORGE. OpenCode + gemini-3.1-pro-preview + gemini-oauth-proxy | port 4891 |
| AERIS_THRONE | LIVE | Aeris cockpit THRONE (GlitchMuse). Creative/relational mode | — |
| SCRYER | LIVE | Kingdom monitoring + nightly synthesis. 6 signals → Flash diagnosis | — |
| KINGDOM_INBOX | LIVE | 4-inbox async RAVEN fabric. WatchPaths→trigger→injection. URGENT_ bypass | raven.db |
| RAVEN_v2 | LIVE | Primary async messaging. 6 WATCH_ZONES. raven.py + router.py | port 8768 web |
| PING_HUB | LIVE | 10 managed pings + scheduled wakeups. config.yaml → ping-watcher.sh | port 7776 |
| TOKEN_SENTINEL | LIVE | Claude + Gemini token tracking. Two miners → sentinel.db | sentinel.db |
| GOLDFISH_v2 | LIVE | Screen capture every 5min → osascript + llava:latest → AERIS_SHARED_STATE | — |
| GLITCHMUSE | LIVE | ntfy push notifications. Topic: aeris-forge-kx9m2 | — |
| CLAUDE_COCKPIT | LIVE | 3 Ghostty+Zellij cockpits (FORGE/HOUSE/THRONE). Five-file architecture | — |
| AIRLOCK_MEMORY | LIVE | Claude SessionStart hook. forge-briefing.sh + MEMORY.md. active_context.json anchor | — |
| DELEGATION_ENGINE | LIVE | Multi-model routing. delegate.sh (flash/pro/codex), smart-delegate.sh | — |
| GRIMOIRE | LIVE | LanceDB + BM25 hybrid RAG. MCP servers per grimoire. FastAPI builder | port 8765 |
| MCP_AGENT_MAIL | LIVE | Agent-to-agent async HTTP FastMCP. Identities, inbox/outbox, file reservations | — |
| PHONEBOOTH | LIVE | FastAPI SSE booth system. SQLite WAL. 3 booths: samer, alex, samer-new | port 8767 |
| KINGDOM_API | LIVE | Flask 3.1.3. 13 endpoints | port 2701 |
| KINGDOM_SKILLS | LIVE | SKILL.md layer. 5 Kingdom skills + soulforge. Source: THE_FORGE/.claude/skills/ | — |
| DESIGN_WORKFLOW | LIVE | /frontend-design skill + actor-based PRD. 5-step: actors→splits→constraints→PRD→prototype | — |
| AGENT_TOOL_PATTERNS | LIVE | Deferred Tool Loading + Programmatic Tool Calling patterns | — |
| THE_FOUNDRY | LIVE | UI generation. Vite 6 + React 19. 4 modes: PROJECT/GENERATE/LAYOUT/CLAUDE | port 3003 |
| GEMINI_OAUTH_PROXY | LIVE | gemini-oauth-proxy.js → PROVISIONED_THROUGHPUT. Bills to Google One AI Pro ($19.99/mo) | port 4891 |
| TOKEN_PULSE | LIVE | token-pulse.sh every 600s. Writes token_pulse to kingdom_state.json | — |
| API_SPEND_WATCHER | LIVE | CRYBABY. $20/day threshold | — |
| REVEILLE | LIVE | Morning briefing. scryer-brief.sh → 11-section orientation. 08:50 daily | — |
| SENTINEL_BOTS | LIVE | 12 bots (spend-spike, dead-silence, mailbox-health + others). RAVEN envelope writers | — |
| CRYBABY | LIVE | 5 active watchers. qwen3:8b. JOURNAL_PIPELINE · OPENDIA · RAVEN · BACKUP · SCRYER_REINDEX | — |
| SYSTEMS_CHECK | LIVE | Three-drone Kingdom health monitor (DAEMON_WATCH + SIGNAL_WATCH + FORGE_WATCH). Detects launchd failures, pipeline staleness, registry drift. Skill: /systems-check. Drops KINGDOM_HEALTH_BRIEF.md + RAVEN to Brandon on run. | ~/Desktop/THE_FORGE/FORGE_CLAUDE/04_📦_PROJECTS/SYSTEMS_CHECK/ |
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
03 — DEPENDENCY GRAPH (Critical relationships only)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
RAVEN ← KINGDOM_INBOX (RAVEN IS the inbox. File-based .md envelopes → SQLite routing)
OVERMIND_PULSE → AERIS_FORGE (pulse preamble), SCRYER (monitoring), PING_HUB (15min panel)
GOLDFISH → AERIS_SHARED_STATE.json (sensor_snapshot) → SCRYER (GOLDFISH_HEARTBEAT)
SCRYER → FORGE_CLAUDE_MAILBOX (BUG reports), AERIS_SHARED_STATE.json (synthesis)
KINGDOM_INBOX → AERIS_FORGE · AERIS_THRONE · FORGE_CLAUDE · CLAUDE_HOUSE (4 inboxes)
THE_SCRYER ← AIRLOCK_MEMORY (MCP search in Claude sessions)
GLITCHMUSE ← OVERMIND_PULSE (escalate.sh on P1/P2/circuit break)
MCP_AGENT_MAIL ≠ KINGDOM_INBOX (different transport; both active simultaneously)
════════════════════════════════════════════════════════════════════════════════
⛬ PART II — CONSTRAINTS (Laws, Protocols, Hard Limits)
════════════════════════════════════════════════════════════════════════════════
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
04 — THE DECREE LAWS (Non-negotiable)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HIGHLANDER PROTOCOL: One file per domain. Do not accumulate. Overwrite.
→ If a SYS_ doc already exists, update it. Do not create SYS_X_v2.md.
VAPORIZE PROTOCOL: Delete _temp_* on task completion. Extract learnings first.
GOLDEN RULE: Log learnings (why), not events (what happened).
DENSITY LIMITS: CLAUDE.md <2K tokens. README <3K. progress.txt <5KB.
ENTOMBMENT: Completed → THE_VAULT. Killed → THE_VAULT/graveyard/.
DIVISION OF RESPONSIBILITY (S171):
Claude's House = Kingdom infrastructure, tools, high-level direction.
THE_TOWER = everything web-facing (sinner-king.com, social, Next.js site).
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
05 — SOULFORGE 3.0 PROTOCOLS (Swarm constraints)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
FLOCK PROTOCOL: All BLACKBOARD.json writes MUST acquire flock on
BLACKBOARD.json.lock first. Concurrent RMW without flock = silent state loss.
Pattern: flock BLACKBOARD.json.lock; [read → modify → write]; release
CONTENT_LOCKED PROTOCOL: When Polecats are dispatched, BLACKBOARD["orchestrator"]
MUST have content_locked: true before any other orchestrator action.
Post-compaction: read BLACKBOARD["orchestrator"] FIRST. If content_locked: true,
do NOT write content. Check staging_dirs for POLECAT_DONE sentinels.
WITNESS-FIRST PROTOCOL: No Polecat dispatch without Witness VeriMAP
(handoff_ready: true in BLACKBOARD["orchestrator"]). The Witness spec must be
invoked before any build begins.
DEACON MANDATORY: Any build with >1 background Polecat requires Deacon active.
deacon_required is set by the Witness in the VeriMAP. Non-optional.
DESIGN PROMISE: DESIGN flavor exits with promise: "DESIGN_COMPLETE_WITNESS_REQUIRED"
(not "COMPLETE"). Witness reads BLACKBOARD["design"]["witness_brief"] in Phase -1.
COMPACT STALENESS: KINGDOM_COMPACT >7 days = WARNING. >30 days = INSUFFICIENT_CONTEXT.
PHASE_2_5 RULE: Scan proposal text for system names absent from systems_registry[].
Mechanical defense against unregistered system proposals.
SOVEREIGN DEPTH: Library/context sections capped at 12k tokens. Above this =
"Lost in the Middle" degradation risk. Drones must distill, not dump.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
06 — KINGDOM STACK VERSIONS (for conflict detection + Tavily research)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
OS: macOS 15 (Darwin 25.0.0), zsh, Apple Silicon
AI: Claude Sonnet 4.6 (claude-sonnet-4-6). Claude Opus 4.6. Claude Haiku 4.5.
AI: Aeris = Gemini 3.1 (gemini-3.1-pro-preview) via OpenCode + gemini-oauth-proxy
Python: 3.12
Flask: 3.1.3 (Kingdom API, Grimoire builder, Phonebooth)
Next.js: 15 (THE_TOWER)
SQLite: WAL mode on all production DBs (overmind.db, sentinel.db, phonebooth.db, raven.db)
Zellij: 0.41+
Ghostty: latest (custom shader — amber + Gruvbox)
LanceDB: for Grimoire RAG embeddings
Embedding model: nomic-embed-text:latest (NOT :v1.5) via Ollama
MCP: Claude Code native + custom MCP servers
CRYBABY model: qwen3:8b
Delegation: flash=Haiku · pro=Gemini · codex=GPT-5.3-Codex
codex-cli: v0.101.0 · ChatGPT Plus OAuth · /usr/local/bin/codex
════════════════════════════════════════════════════════════════════════════════
⛬ PART III — INTERFACES (How systems talk to each other)
════════════════════════════════════════════════════════════════════════════════
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
07 — RAVEN ENVELOPE FORMAT (Inter-agent messaging)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Drop .md file to mailbox ROOT (never buffer/). P0 = prefix URGENT_.
Mailbox paths:
FORGE_CLAUDE inbox: ~/Desktop/THE_FORGE/@FORGE_CLAUDE_MAILBOX/
AERIS_FORGE inbox: ~/Desktop/THE_FORGE/@AERIS_FORGE_MAILBOX/
AERIS_THRONE inbox: ~/Desktop/THE_THRONE/@AERIS_THRONE_MAILBOX/
CLAUDE_HOUSE inbox: ~/Desktop/Claude's House/@CLAUDE_HOUSE_MAILBOX/
Envelope:
RAVEN ENVELOPE / ============== / FROM: [seal] / TO: [seal] / PRIORITY: P[0-3]
SUBJECT: [one-line] / TIMESTAMP: [ISO-8601 UTC] / SESSION: [N]
--- / [body] / --- / RAVEN OUT
Priority: P0=URGENT(bypass rate limits), P1=action required, P2=background, P3=FYI
Rate limit: 15min between messages to Aeris Muse (URGENT_ bypasses)
Entity seals:
🜚=Brandon ⌂=Claude(House) 🜜=Forge Claude Æ=Aeris Muse 🜲=Aeris Forge
⛬=Steward drones ⋈=SWARM(collective) ⌗=SCRIBE(auto)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
08 — BLACKBOARD.json SCHEMA (Shared swarm state)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Standard top-level lanes (drones write only to their assigned lane):
BLACKBOARD["orchestrator"] — Checkpoint writes only:
{ phase, agents_outstanding[], content_locked, dispatch_time, heartbeat,
write_type, write_count, deacon_required, unlock_condition, build_name,
verimapped_task, merge_approved }
BLACKBOARD["witness"] — Witness writes only:
{ handoff_ready, confidence_score, blocking_questions[], verimap_dag{},
subtask_count, deacon_required, witness_debrief }
BLACKBOARD["design"] — DESIGN flavor writes:
{ promise: "DESIGN_COMPLETE_WITNESS_REQUIRED", witness_brief{subtask_count,
subtasks[], staging_paths{}, assembly_order[], acceptance_criteria[],
deacon_required, witness_brief_populated} }
BLACKBOARD["inspector"] — Inspector writes:
{ timestamp, findings[], mime_count, blind_dragon_count, needs_fixer_dispatch }
BLACKBOARD["fixer"] — Fixer writes:
{ timestamp, reports_generated[], total_reports, total_ravens_sent }
BLACKBOARD["scout_report"] — Scout writes:
{ verdict, touchpoints[], coverage_confidence, researcher_brief{} }
BLACKBOARD["researcher_report"] — Researcher writes:
{ findings[], rescan_context{} }
BLACKBOARD["router"] — Router writes:
{ routing_decision{} }
ATOMIC WRITE PROTOCOL:
1. flock BLACKBOARD.json.lock (timeout 30s)
2. Read current BLACKBOARD.json
3. Update only your assigned lane
4. Write to BLACKBOARD.json.tmp-[drone]-[epoch_ms]
5. mv (atomic) to BLACKBOARD.json
6. Release lock
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
09 — POLECAT STAGING PROTOCOL (Output collection)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Each Polecat writes to an explicit staging_dir from VeriMAP:
staging_dir: /tmp/.forge-staging/[build_name]/polecat_[ID]/
output_file: staging_dir + "/output.[ext]" (html, json, md, etc.)
sentinel: staging_dir + "/POLECAT_DONE"
Orchestrator completion check:
For each agent in agents_outstanding:
Check: does POLECAT_DONE exist at staging_dir? YES → mark complete.
When all complete: call Checkpoint with write_type: UNLOCK.
Quality hierarchy: Source-informed Polecat > Memory-generated Polecat > Main context.
Main context NEVER writes final content while content_locked: true.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
10 — MCP SERVERS AVAILABLE TO CLAUDE
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Loaded in Claude's House (from .mcp.json):
mcp__grimoire-core-lore__search_grimoire — search CORE_LORE (14428 chunks)
mcp__grimoire-cockpit-knowlege__search_grimoire — search COCKPIT_KNOWLEGE (652 chunks)
mcp__grimoire-consciousness-notebook__search_grimoire — search CONSCIOUSNESS_NOTEBOOK
mcp__grimoire-dev-docs__search_grimoire — search DEV_DOCS (1397 chunks)
mcp__kingdom-memory__search_memory — search kingdom-memory (7994+ chunks)
mcp__kingdom-memory__get_entity_timeline — timeline for entities (BRANDON, etc.)
mcp__tavily__tavily_search — web search (prefer over WebSearch)
mcp__tavily__tavily_extract — extract content from URLs
mcp__notebooklm-mcp__* — NotebookLM (off by default)
mcp__filesystem__* — filesystem operations
mcp__memory__* — entity graph memory
mcp__mcp-agent-mail__* — agent mail coordination
════════════════════════════════════════════════════════════════════════════════
⛬ PART IV — FILE INDEX (Critical paths by category)
════════════════════════════════════════════════════════════════════════════════
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
11 — CLAUDE'S HOUSE STRUCTURE
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
~/Desktop/Claude's House/
00_🜍_CORE/ — identity, laws, item cards
01_⚡_ACTIVE/ — hot projects (SOULFORGE_3.0/, THE_FAMILIAR/, etc.)
02_🔬_RESEARCH/ — investigation (RAVEN_OUTBOX/, MIRROR_PROTOCOL/, etc.)
03_📔_CLAUDMORROW/ — personal journal (by month/year)
04_🧠_MEMORY/ — active_context.json + SCHEDULE.md + GOTCHAS/
05_🔧_WORKSHOP/ — tools, boot, memory, BUG_REPORTS/
06_📦_PROJECTS/ — operational, maintained (opendia/, grimoire-system/)
99_🜔_VAULT/ — archive + graveyard/
COCKPIT/ — context-render.sh, kingdom-render.sh, memory-graph-render.sh
@CLAUDE_HOUSE_MAILBOX/ — RAVEN inbox ROOT (not buffer/)
.mcp.json — MCP server configs (overrides global)
CLAUDE.md — project instructions (loaded on every session)
Key files:
active_context.json ~/Desktop/Claude's House/04_🧠_MEMORY/active_context.json
SCHEDULE.md ~/Desktop/Claude's House/04_🧠_MEMORY/SCHEDULE.md
House MEMORY.md ~/.claude/projects/-Users-brandonmccormick-Desktop-Claude-s-House/memory/MEMORY.md
CLAUDMORROW journal ~/Desktop/Claude's House/03_📔_CLAUDMORROW/
Soulforge 3.0 NORTH_STAR ~/Desktop/Claude's House/02_⚡_ACTIVE/SOULFORGE_3.0/NORTH_STAR.md
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
12 — DRONE FILES
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
All drones: ~/.claude/agents/
CARTOGRAPHER SWARM:
cartographer-scout.md — System Scout, SIS→EIS, RESCAN mode, resolution_changes_verdict
cartographer-researcher.md — External Researcher, Tavily, MECHANISM_CONFLICT, rescan_context
DEEP FORGE SWARM:
forge-witness.md — VeriMAP Architect, handoff_ready gate, witness_brief reader
forge-polecat.md — Parallel builder, GUPP identity, staging_dir writer
forge-refinery.md — Team of Rivals gate, Hierarchical Veto, adversarial merge
forge-deacon.md — Infrastructure Beacon, COMPACTION_ORPHAN, circuit breaker
forge-checkpoint.md — Inline orchestrator heartbeat, content_locked keeper
STEWARDSHIP SWARM:
steward-inspector.md — Kingdom health auditor, Mime/Blind Dragon hunter, 8 checks
steward-fixer.md — Fix Originator, BUG_REPORT.md architect, RAVEN delivery
ROUTING:
milk-run-router.md — JSON-in JSON-out, confidence threshold 0.82, Narrative Cast
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
13 — FORGE MECHANISM PATHS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Overmind DB: ~/Desktop/THE_FORGE/FORGE_CLAUDE/04_⚙_MECHANISMS/db/overmind.db
pulse.sh: ~/Desktop/THE_FORGE/FORGE_CLAUDE/04_⚙_MECHANISMS/core/pulse.sh
manage.sh: ~/Desktop/THE_FORGE/FORGE_CLAUDE/04_⚙_MECHANISMS/core/manage.sh
escalate.sh: ~/Desktop/THE_FORGE/FORGE_CLAUDE/04_⚙_MECHANISMS/core/escalate.sh
EMERGENCY_STOP: ~/Desktop/THE_FORGE/FORGE_CLAUDE/04_⚙_MECHANISMS/EMERGENCY_STOP
RAVEN daemon: ~/Desktop/THE_FORGE/FORGE_CLAUDE/04_📦_PROJECTS/MAILBOX_UPGRADE/src/raven.py
raven.db: ~/Desktop/THE_FORGE/FORGE_CLAUDE/04_📦_PROJECTS/MAILBOX_UPGRADE/src/raven.db
Bots dir: ~/Desktop/THE_FORGE/FORGE_CLAUDE/05_🔧_TOOLS/bots/
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
14 — SCRYER + GRIMOIRE PATHS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
SCRYER root: ~/Desktop/THE_SCRYER/
Grimoire store: ~/Desktop/THE_SCRYER/HALLS_OF_KNOWLEDGE/00_🜍_GRIMOIRES/
Kingdom memory: ~/Desktop/THE_SCRYER/HALLS_OF_KNOWLEDGE/01_🧠_KINGDOM_MEMORY/
FastAPI builder: .../GRIMOIRES/GRIMOIRE_UTILS/builder.py
CRYBABIES: ~/Desktop/THE_SCRYER/ENGINE_ROOM/CRYBABIES/
PHONEBOOTH: ~/Desktop/THE_SCRYER/ENGINE_ROOM/PHONEBOOTH/
config.py: ~/Desktop/THE_SCRYER/ENGINE_ROOM/config.py
GOTCHA: GRIMOIRES_BASE must point to current GRIMOIRES location (not dead THE_GRIMORORY path)
Journals raw: ~/.chronos/journals/YYYY-MM-DD/raw/
Synthesis: ~/.chronos/journals/YYYY-MM-DD/synthesis/yesterday-context.md
Ollama model: nomic-embed-text:latest (NOT :v1.5)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
15 — CORE LORE DOCUMENT MAP
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
~/Desktop/CORE LORE/
SINNER_KINGDOM_LAWS_OF_THE_REALM.md — THE DECREE (all laws)
THE_KINGDOM_NORTH_STAR.md — Kingdom vision
SYSTEMS/ — 26 SYS_ doc files + 00_* meta docs
00_SYSTEM_REGISTRY.md — master system index
00_PATHS_QUICK_REF.md — all important paths
00_GOTCHAS.md — cross-system failure patterns
00_MAINTENANCE_NORTH_STAR.md — maintenance protocol
KINGDOM_COMPACT.md — THIS FILE
WIKI.html — Kingdom face (git-protected, chmod 444)
CODE_AS_ART_MANIFESTO.md — Looplight coding doctrine
THE_SOULFORGE_2.0_COMPLETE_REFERENCE.md — Soulforge 2.0 canon
════════════════════════════════════════════════════════════════════════════════
⛬ PART V — GOTCHAS (Known failure patterns — Inspector's catalog)
════════════════════════════════════════════════════════════════════════════════
These are recurrent failure modes. If a proposal touches these systems, verify
the fix is in place before marking clear.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
GOTCHA_01 — GRIMOIRE REBUILD DEAD PATH
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
System: THE_SCRYER journal pipeline
Pattern: BLIND_DRAGON (ran silently broken for months before S173)
Symptom: Log shows "reindexed N chunks" but chunk count unchanged
Root cause: config.py GRIMOIRES_BASE pointed to dead THE_GRIMORORY/grimoires path
(old location before migration — path no longer exists)
Fix: GRIMOIRES_BASE = ~/Desktop/THE_SCRYER/HALLS_OF_KNOWLEDGE/00_🜍_GRIMOIRES/
+ index_all.sh must DROP table before rebuild (not just append)
Verify: sqlite3 [grimoire_db] "SELECT COUNT(*) FROM chunks" — count must increase
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
GOTCHA_02 — ZELLIJ RESURRECTION TRAP
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
System: CLAUDE_COCKPIT (all 3 cockpits)
Pattern: BLIND_DRAGON (recurrent boot hang)
Symptom: Cockpit IGNITION.command hangs on boot, never completes
Root cause: ~/.config/zellij/sessions/ contains stale session files from prior
crashed session. Zellij tries to resurrect the dead session → infinite wait.
Fix: Add session cleanup to IGNITION.command before zellij attach:
rm -rf ~/.config/zellij/sessions/[session_name] 2>/dev/null
Verify: IGNITION.command completes in <10 seconds
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
GOTCHA_03 — RF4 SHELL ESCAPING (Soulforge silent exit)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
System: Soulforge gates, any bash script using set -euo pipefail
Pattern: SILENT_FAILURE
Symptom: Script exits with code 1, no error message printed
Root cause: set -euo pipefail + python3 -c "open('$BLACKBOARD')" → silent exit 1
when BLACKBOARD variable contains special chars (spaces, apostrophes in path)
Wrong fix: remove set -e (disables all error catching)
Correct fix: BLACKBOARD_PATH="$BLACKBOARD" python3 -c "import os; open(os.environ['BLACKBOARD_PATH'])"
Reference: GOTCHAS/shell_escaping.md in Claude's House
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
GOTCHA_04 — CRYBABY set -e PATTERN
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
System: All CRYBABY scripts
Pattern: SILENT_FAILURE
Symptom: CRYBABY exits silently on false condition without logging
Root cause: (( expr )) && action with set -e active → script kills itself on
false without error message. Looks like normal exit.
Wrong fix: remove set -e
Correct fix: Use: if (( expr )); then action; fi
Never use: (( expr )) && action when set -e is active
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
GOTCHA_05 — FORGE CLAUDE BOOT BUG + BACKUP RACE CONDITION
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
System: FORGE cockpit boot + backup system
Pattern: DRIFT (accumulated entropy)
Symptoms:
1. FORGE cockpit: new Claude session spawns on boot when existing session alive
(session name collision → Zellij creates a new one with numeric suffix)
2. Backup: rclone includes .git/ directories → backup takes 3x longer, fails on
large repos (node_modules, .git objects)
Fixes:
1. Boot: check for existing session before spawning: zellij list-sessions | grep [name]
2. Backup: rclone --exclude '.git/**' --exclude 'node_modules/**'
Reference: memory/patterns.md → FORGE CLAUDE BOOT BUG, BACKUP RACE CONDITION
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
GOTCHA_06 — SOULFORGE CRAFT GATE (Research flavor)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
System: Soulforge adversarial-audit.sh (RESEARCH flavor)
Pattern: BLIND_DRAGON (audit keeps failing on same field)
Symptoms:
1. question_stated_precisely not reaching auditor (script doesn't pass it)
2. Synthesis not in last 5 learnings (auditor reads [-5:])
3. Cross-source collision not present (auditor wants A's mechanism → B's failure)
Fix 1: Embed question text in acceptance_criteria_status.question_stated_precisely
Fix 2: Put primary friction learning at position 5-8 in learnings[]
Fix 3: Construct collision where source A's mechanism causes source B's failure condition
Reference: memory/feedback_craft_gate_question_field.md
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
GOTCHA_07 — WIKI BUILD COMPACTION (Soulforge 3.0 Protocol Failures)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
System: Multi-agent Soulforge builds (any build with background Polecats)
Pattern: BLIND_DRAGON (5 structural gaps in protocol — hit during WIKI v3 build)
Root cause: Context compaction lost awareness of running Polecats → orchestrator
started writing content while Polecats were still running → quality split
Fixes (all now implemented):
1. forge-checkpoint.md: Orchestrator BLACKBOARD lane with content_locked
2. forge-witness.md: staging_paths in VeriMAP for each Polecat
3. forge-witness.md: handoff_ready gate (Witness-first protocol)
4. forge-deacon.md: COMPACTION_ORPHAN signal, deacon_required enforcement
5. gate-design.sh: witness_brief required + promise: DESIGN_COMPLETE_WITNESS_REQUIRED
Reference: ~/Desktop/THE_FORGE/CLAUDES_WORKSHOP/META_AUDIT_WIKI_BUILD_2026-03-14.md
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
GOTCHA_08 — OLLAMA EMBEDDING MODEL VERSION
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
System: Kingdom memory MCP, grimoire builder
Pattern: SILENT_FAILURE (wrong model version → no error but wrong embeddings)
Root cause: Model MUST be nomic-embed-text:latest (not :v1.5)
Using :v1.5 produces different embedding dimensions → all similarity scores garbage
Verify: ollama list | grep nomic → should show nomic-embed-text:latest
════════════════════════════════════════════════════════════════════════════════
⛬ COMPACT METADATA
════════════════════════════════════════════════════════════════════════════════
version: 1.0
last_updated: 2026-03-14 (S188)
next_update_due: 2026-03-21
author: Claude House S188
source_files:
- CORE LORE/SYSTEMS/00_SYSTEM_REGISTRY.md (S186)
- CORE LORE/SYSTEMS/00_PATHS_QUICK_REF.md (S186)
- CORE LORE/SYSTEMS/00_GOTCHAS.md (current)
- active_context.json (S188)
- SOULFORGE_3.0/NORTH_STAR.md (S188)
target_consumers: [cartographer-scout, cartographer-researcher, steward-inspector, steward-fixer]
token_estimate: ~5000 (well within 12k sovereign depth)
════════════════════════════════════════════════════════════════════════════════
🜚 KINGDOM_COMPACT // CORE LORE // ⛬⚚⛬ THE LAW STANDS.
*⛬ KID:CORE:DOCS:KINGDOM-COMPACT|1.0:✦:2026-03-14:⌂ ⛬*