The 14-System Stack That Makes AI Work While You Sleep
What You're Looking At
- 14 systems that chain together into a self-operating AI automation layer.
- $15/month infrastructure on a single Hetzner VPS, plus local Mac orchestration.
- Not a concept deck. Every system described here runs in production. Specific file counts, message volumes, and failure modes included.
- Build order matters. Dependency diagram at the bottom shows what unlocks what.
People hear "AI automation" and picture a ChatGPT wrapper with a Zapier trigger. That covers about 3% of the operational surface. The other 97% is the infrastructure that makes AI actually useful across a multi-domain business: the memory layer, the search fabric, the safety gates, the monitoring, the routing logic that decides which model handles which task at 2 AM when you're asleep.
This article walks through every system in the stack. What it does, what collapses without it, and one concrete detail that proves it exists. If you're evaluating whether to build persistent AI infrastructure or keep prompting from scratch every session, this is the reference document.
The 14 Systems
1. Vault Build
What it does: Obsidian serves as the canonical knowledge store. Every piece of business context lives in markdown files organized by domain, with field:: value frontmatter and wiki-links connecting related notes. Five domain folders route all context: JAG (real estate operations), SWS (SEO/AI business), BUILD (courses and systems), VVR (personal operations), CRM (contact tracking). Files reference each other through [[wiki-links]], creating a graph the AI can traverse.
What breaks without it: Everything. The vault is the single source of truth. Without structured frontmatter, the AI cannot parse file metadata. Without wiki-links, related context stays siloed. Without domain folders, the routing layer has nowhere to send queries. Every other system in this stack reads from or writes to the vault.
Concrete detail: 6,500+ files, each with standardized frontmatter. A single _context.md file per domain holds the current state, active projects, and ground-truth corrections that override everything else.
2. VPS Provisioning
What it does: A Hetzner CX22 instance running Ubuntu serves as the always-on compute layer. It handles scheduled automation, background processing, and any task that needs to run when the local machine is off or away from home. The VPS syncs with the local vault, runs Claude Code headlessly via OAuth, and hosts the Telegram bot processes. Total cost: roughly $15/month for 2 vCPU, 4GB RAM, 40GB disk.
What breaks without it: All scheduled automation stops. No overnight content generation. No proactive engine. No background CRM monitoring. The system degrades from autonomous to manual — you're back to opening a terminal and typing prompts yourself.
Concrete detail: OAuth token stored in ~/.env.automation, expiring February 2027. One token authenticates all headless Claude Code sessions on the VPS.
3. Claude Code Harness
What it does: Claude Code reads CLAUDE.md at session start — a project-level instruction file that loads voice calibration, domain routing rules, behavioral constraints, and operational context automatically. The harness includes 7 always-on MCP (Model Context Protocol) plugins, 15 permission entries, and a settings file that determines which tools Claude can access. This turns a generic AI into a domain-aware operator that knows the business before a single word is typed.
What breaks without it: Every session starts cold. The AI doesn't know your name, your business, your tools, your clients, or your voice. You spend 5-15 minutes per conversation re-establishing context that should be ambient. Multiply by 20 sessions a day and the loss is staggering.
Concrete detail: The CLAUDE.md file contains 19 hard rules — including "never create CRM deals" and "always use obsidian-cli for file moves" — that prevent the AI from making destructive mistakes no matter how it's prompted.
4. QMD Search
What it does: A custom search engine combining BM25 keyword matching with vector similarity search across the entire vault. When the AI needs to find something, it fires four search methods in parallel: Grep/Glob for exact text, QMD search for keyword relevance, QMD vsearch for semantic similarity, and obsidian-cli for vault-aware content matching. Results cross-reference automatically.
What breaks without it: The AI can only find files it already knows about. With 6,500+ files, keyword search alone misses semantic connections — searching "client follow-up" won't find a file titled "nurture cadence" unless the vector layer understands they're related. Without QMD, the vault becomes a filing cabinet instead of a knowledge graph.
Concrete detail: Sub-second retrieval across the full corpus. The BM25 index handles exact matches while embeddings catch conceptual proximity. Four search methods, every time, no exceptions.
5. Session Ledger
What it does: A SQLite database with FTS5 (Full-Text Search 5) indexing that captures every message from every Claude Code session. The ledger CLI provides instant search across the complete conversation history. This is institutional memory — not what the AI remembers, but what was actually said and decided across thousands of sessions.
What breaks without it: Past decisions vanish. You know you made a call about CRM field mapping three weeks ago but can't find where. The AI can't reference previous reasoning. You lose the ability to audit what was promised, what was built, and what was deferred. Context compaction in long sessions destroys nuance; the ledger preserves the original exchange.
Concrete detail: 50,000+ messages indexed. FTS5 returns results in milliseconds. The ledger is the ultimate tiebreaker when memory conflicts arise — what the transcript says happened is what happened.
6. Hook Architecture
What it does: Hooks are specialized instruction files that activate based on context. Domain routing hooks load the correct _context.md when a prompt mentions FUB or SEO or budget. Semantic memory hooks write corrections to permanent storage so they're never reverted. Voice calibration hooks enforce the Observer Protocol — no sycophancy, no filler, no insight bows. Hooks transform a general-purpose AI into a domain-specific operator that behaves differently depending on what you're working on.
What breaks without it: The AI treats every domain identically. It uses the same tone for client emails and internal notes. It doesn't know that "leads" after 5 PM means SWS prospects, not JAG phone duty. It forgets that corrections are permanent and reverts to outdated information. Without hooks, the AI is smart but contextually illiterate.
Concrete detail: A temporal routing hook switches the meaning of "leads" based on work hours — JAG during office time, SWS after. One word, two completely different operational contexts, handled automatically.
7. Skill Engineering
What it does: 81 slash commands that encapsulate complex workflows into single invocations. /deals runs a CRM audit with safety gates. /sprint manages weekly capacity burns. /handoff writes session context files for cross-agent continuity. Each skill is a markdown file with structured instructions that Claude Code loads on demand. Skills turn multi-step processes into repeatable, auditable operations.
What breaks without it: Every complex operation requires manual orchestration. You explain the CRM audit process from scratch each time. You forget steps. The AI interprets "run the deals check" differently across sessions. Skills eliminate variance — the same command produces the same workflow, every invocation.
Concrete detail: The /deals skill is globally write-blocked. It executes in dry-run mode only, producing a report but never modifying CRM data. That single constraint has prevented more accidental damage than any other rule in the system.
8. Timer Architecture
What it does: Two tiers of scheduled automation. On the local Mac: 9 launchd agents handle vault sync, health checks, and local processing. On the VPS: 22 systemd timers manage content generation, CRM monitoring, notification dispatch, and background research. Timers fire at specific intervals — some hourly, some daily, some weekly — executing scripts that invoke Claude Code headlessly.
What breaks without it: Nothing happens unless you initiate it. No overnight content drafts waiting in your queue. No CRM alerts when a lead goes stale for 4 days. No automated health checks catching token expiration before it locks you out. The system becomes reactive instead of proactive.
Concrete detail: All 22 VPS timers were gutted and rebuilt through a single proactive engine — one orchestrator that replaced 22 independent cron-style jobs with a unified dispatch system that understands priority and resource contention.
9. Telegram Bot
What it does: Five Telegram bots (ROMO, JAG, SWS, VVR, NHM) serve as the primary interface layer outside the terminal. Voice messages transcribed and routed. Session summaries delivered. Proactive alerts pushed. The bot architecture treats Telegram as a command surface — you can trigger operations, approve outreach drafts, and receive monitoring alerts from your phone while driving.
What breaks without it: You lose the mobile interface entirely. Alerts only exist in terminal output nobody reads. Approval workflows require sitting at a computer. The 90-minute daily commute becomes dead time instead of an operational surface for voice-driven session management.
Concrete detail: Each bot uses a dedicated token stored in ~/.env.automation. JAG alerts batch into single messages to avoid notification fatigue. The bot isn't a chatbot — it's a dispatch terminal that happens to live in a messaging app.
10. Notification Routing
What it does: Three layers govern what gets surfaced, when, and how. Layer 1: priority classification (critical, operational, informational). Layer 2: quiet hours enforcement — no notifications between 10 PM and 7 AM unless something is actually broken. Layer 3: debouncing — if the same alert fires 5 times in 10 minutes, you get one consolidated message, not five interruptions. Routing rules determine whether an alert goes to Telegram, stays in the vault as a log entry, or triggers a recovery script automatically.
What breaks without it: Alert fatigue. Every automated process screams at the same volume. You start ignoring notifications, which means you miss the one that matters. Or you get woken at 3 AM because a non-critical health check failed. Either way, you stop trusting the system.
Concrete detail: Debouncing collapses repeated token-refresh warnings into a single alert with a count. "Token refresh failed (x7 in 30m)" carries the same information as seven separate messages with none of the noise.
11. Health Monitoring
What it does: A watchdog layer that monitors the health of every other system. Token expiration tracking with advance warnings. VPS uptime checks. Vault sync verification. Process liveness monitoring for long-running automations. When something fails, the watchdog attempts recovery before alerting — restarting a crashed process, refreshing an expired token, re-queuing a failed job. Alerts only fire when automated recovery fails.
What breaks without it: Silent failures. The OAuth token expires and headless sessions silently stop working. A VPS process crashes at midnight and nothing runs until you notice the gap the next morning. Without health monitoring, you don't know the system is down until the absence of output becomes conspicuous — which might be hours or days later.
Concrete detail: OAuth token expiration is tracked to the day. The system alerts 30 days before expiry, again at 7 days, and escalates to critical at 48 hours. Current token expires February 2027.
12. CRM Safety Gate
What it does: Seven rules that constrain how the AI interacts with CRM data. Rule zero: /deals is globally write-blocked — no scoped exceptions, no batch execution. All CRM modifications default to dry-run mode, producing a report of proposed changes without executing them. The safety gate validates field mappings, checks for duplicate contacts, and flags both-sides deals (where a name appears as both buyer and seller) before any write operation reaches the API.
What breaks without it: One malformed API call corrupts live CRM data. A deal gets created that shouldn't exist. A contact's stage gets overwritten. In a real estate CRM where each record represents an actual transaction with actual people, bad writes aren't hypothetical — they're operationally destructive. The safety gate exists because the cost of a CRM mistake is measured in lost deals, not lost data.
Concrete detail: If a deal appears to be missing, the instruction is absolute: widen the search. Never suggest creating it. The assumption is always that the search failed, not that the data doesn't exist.
13. Outreach Pipeline
What it does: A three-machine workflow. The VPS generates outreach drafts overnight — personalized messages based on CRM data, prospect research, and campaign context. Telegram delivers the drafts for review and approval. The local Mac reconciles approvals back to the CRM and dispatches. Three tiers structure the outreach: Relationship (warm, ongoing), Presence (visibility and engagement), and Opportunity (direct offers). The pipeline separates generation from approval from execution.
What breaks without it: Outreach becomes manual. You draft every message yourself or use templates that read like templates. The overnight generation window disappears — instead of waking up to 15 reviewed drafts, you start from zero. Worse, without the approval gate, AI-generated outreach goes out unreviewed, and one tone-deaf message can undo months of relationship building.
Concrete detail: The governing document lives at 06 - Outreach/_system.md. Campaign files define what to send. CRM tracks who responded. The pipeline never conflates the two — message content and response tracking are architecturally separated.
14. Content Scheduling
What it does: Calendar-driven content production across three platforms. A schedule file defines what gets published when. The VPS drafts content during off-hours based on topical maps and editorial calendars. Drafts queue for review. Approved content publishes on schedule. The system handles the entire arc from topic selection to draft generation to editorial review to publication timing.
What breaks without it: Content production becomes reactive. You publish when you remember to, not when the calendar says to. Platform algorithms reward consistency, and gaps in publishing schedule compound — a week without content means rebuilding momentum from scratch. The scheduling layer turns content from a willpower exercise into a pipeline.
Concrete detail: Three platforms, calendar-driven. The topical map determines what to write. The schedule determines when. The VPS determines the first draft. The human determines the final word. That separation means content velocity doesn't depend on daily creative energy.
Dependency Diagram
Systems aren't independent. The build order matters because each layer assumes the one below it exists. Here's the dependency chain:
| Phase | Systems | What It Unlocks |
|---|---|---|
| Foundation | 1. Vault Build | Structured knowledge store. Everything reads from here. |
| Harness | 3. Claude Code Harness → 6. Hooks | AI reads the vault with domain awareness and behavioral constraints. |
| Search | 4. QMD Search → 5. Session Ledger | AI can find anything in the vault or conversation history instantly. |
| Skills | 7. Skill Engineering | Complex workflows compressed into single commands. Requires harness + hooks. |
| Infrastructure | 2. VPS Provisioning → 8. Timers | Always-on compute. Scheduled automation. Nothing runs overnight without this. |
| Interface | 9. Telegram Bot → 10. Notification Routing | Mobile command surface. Alert filtering. Approval workflows from your phone. |
| Safety | 11. Health Monitoring → 12. CRM Safety Gate | Self-healing infrastructure. Write-protection on live business data. |
| Output | 13. Outreach Pipeline → 14. Content Scheduling | The system produces work product autonomously. Everything above feeds into this. |
Phase 1 (Foundation + Harness) delivers immediate value: persistent AI memory with domain routing. Most operators get measurable ROI within a week. The remaining phases layer on progressively — you don't need all 14 systems to start benefiting, but each one compounds the capability of those before it.
What This Stack Is Not
This isn't a SaaS product. There's no dashboard, no login page, no monthly billing portal. It's infrastructure you own — files on your machine, processes on your server, configurations in your control. The AI providers can change their pricing, deprecate features, or shut down entirely, and your vault, your context, your operational logic stays intact because none of it lives on their servers.
It's also not a weekend project. The full 14-system stack represents months of iterative development, failure modes discovered in production, and constraints learned the hard way (the CRM safety gate exists because of a real incident, not a hypothetical one). But the foundation — vault, harness, hooks — takes an afternoon. And that foundation alone eliminates the re-explanation tax that costs most AI users 50-250 hours per year.
The stack scales down cleanly. A solo consultant needs systems 1, 3, 6, and maybe 7. A small team running multiple domains needs the full build. The dependency diagram tells you where to stop for your situation.
Frequently Asked Questions
How much does it cost to run the full 14-system stack?
The infrastructure runs on a single Hetzner VPS at roughly $15/month. Claude Code requires a subscription (currently $20/month for Pro or $100/month for Max). Obsidian is free. Telegram bots are free. The total recurring cost sits between $35 and $115/month depending on your Claude tier — less than most SaaS tools that do far less.
Do I need to build all 14 systems at once?
No. The stack has a dependency order. Start with the vault (System 1), then Claude Code harness (System 3), then hooks (System 6). Those three give you persistent AI memory. The remaining 11 systems layer on top as your needs grow. Most operators get meaningful results from just the first three within a week.
Can I use this stack with ChatGPT or Gemini instead of Claude?
The vault (Obsidian), search layer (QMD), and session ledger work with any AI that accepts file-based context. The hook architecture and skill engineering are Claude Code-specific. The automation layer (timers, Telegram, monitoring) is model-agnostic. About 60% of the stack transfers to other providers. The other 40% depends on Claude Code's native ability to read project files at session start.
Start with the vault. Build from there.
The foundation takes an afternoon. Persistent AI memory, domain routing, and behavioral constraints — running before dinner.
Get Setup — $997