AI Infrastructure Architecture

VPS Design, Data Layers & System Integration Spec ยท March 2026

System Overview

The egelloC AI infrastructure operates across three layers that converge at a central DigitalOcean VPS. Each layer serves a distinct mode of human-AI interaction, and the VPS acts as the connective tissue โ€” the egelloC Brain โ€” that keeps all layers in sync.

The Three Layers

Claude Team Plan

Daily AI co-worker for all staff. Chat, Projects, Cowork, Connectors.

Users: Everyone: coaches, CX, marketing, sales, leadership

Tools: Claude.ai, Desktop app

OpenClaw (3 Mac Minis)

Always-on automations. Cron jobs, event-triggered agents, background processing.

Users: Runs autonomously. Tony owns 2 Minis (Cornelius + Emerson), Victor owns 1 (Jarvis).

Tools: Cornelius, Emerson, Jarvis, cron jobs, Zapier, Claude API

Dev Layer

Build and ship. Code the automations, agents, and product features.

Users: Tony, Victor, Ray + AI team

Tools: Cursor, GitHub, Claude Code, Vercel

DigitalOcean VPS โ€” The Brain

The VPS hosts shared knowledge, configuration, and data that every agent and every human-facing Project draws from. It serves four functions: SOP repository, API key vault, shared context store, and webhook receiver.

Directory Structure

PathPurpose
/opt/egelloc/brain/sops/SOP Markdown files, organized by department (coaching/, sales/, cx/, marketing/)
/opt/egelloc/brain/playbooks/Decision trees and response templates (parent-comms/, financial-aid/, essay-coaching/)
/opt/egelloc/brain/context/Shared context DB (SQLite), agent state files, student data snapshots
/opt/egelloc/config/API key vault (.env files), Tailscale config, agent routing rules
/opt/egelloc/webhooks/Webhook receiver scripts (Node.js/Express), event logs, routing logic
/opt/egelloc/logs/All agent action logs, API call logs, cost tracking CSVs
/opt/egelloc/exports/Processed outputs for Claude Team Projects (synced to Google Drive)

Networking โ€” Tailscale Mesh

All machines connect via Tailscale private networking. No public ports exposed except webhook endpoints (HMAC secured).

DigitalOcean VPSCentral hubSSH accessible from all nodes. Webhook port 443 public.
Mac Mini #1 (Cornelius)Agent host โ€” TonyChief of Staff + BI. Orchestrator and triage layer. Telegram (Tony only).
Mac Mini #2 (Emerson)Agent host โ€” TonyStudent intel + content. Coaching support. Slack (@emerson, team-wide).
Mac Mini #3 (Jarvis)Agent host โ€” VictorProduct + ops. QA, internal tooling, operational workflows. Slack (@jarvis, team-wide).
Dev machinesDev nodesPush code to VPS via Git. Cursor + GitHub + Claude Code.

Agent Routing Rules

Cornelius is the orchestrator. When a request or event enters the system, Cornelius triages and routes to the correct agent:

Emerson (Mini #2)

Coaching, student intel, meeting prep, content

Channel: Slack @emerson

Jarvis (Mini #3)

Product QA, internal tooling, ops workflows

Channel: Slack @jarvis

Cornelius (Mini #1)

Leadership BI, cross-agent coordination, Tony-specific tasks

Channel: Telegram (Tony)

Data Flows

Flow 1: Automation โ†’ Claude Team Projects

1OpenClaw cron job runs on Mac Mini (e.g., Coach Capacity Dashboard, Monday 7am)
2Output written to VPS at /opt/egelloc/exports/ as structured file
3VPS sync script pushes to Google Drive (rclone cron)
4Claude Team Project references latest reports via Drive connector

Flow 2: Webhook Event โ†’ Agent Action

1Close CRM fires webhook when deal is Sales Won
2VPS webhook receiver catches event, forwards to Cornelius via Tailscale
3Cornelius pulls Fathom transcripts, processes via Claude API (Haiku), generates handoff
4Summary posted to Slack #cx-handoffs + written to VPS context store

Flow 3: Dev Builds & Deploys

1Code written in Cursor with AI-assisted coding (or Claude Code from terminal)
2Pushed to GitHub. CI/CD runs tests if configured
3Deploy to VPS or Mac Mini via SSH (git pull / rsync). Web features โ†’ Vercel
4New API keys added to VPS vault. Cron jobs registered and cost-tracked

Shared Context Store โ€” Brain DB

SQLite for V1, PostgreSQL when volume demands it. agent_logs and cost_tracking are append-only.

TableWriters
agent_logsAll agents (auto-logged)
student_contextEmerson, CX workflows
meeting_summariesMeeting Intelligence cron
sales_eventsWebhook receiver
sop_versionsAI team only (SOP Lock)
cost_trackingAll API calls (auto-logged)
webhook_eventsWebhook receiver

Claude Team Projects โ€” Knowledge Map

Each Project is organized by workflow, not by department or task.

Coaching Hub

VPS Synced

Coaching philosophy, no-spike language guide, tier breakdowns, PPI program docs, essay feedback tone guide

Users: Coach Art, all coaches

Financial Aid Playbook

VPS Synced

Hormozi Calculator Close script, FAS training materials, scholarship guides, financial aid strategy docs

Users: Coach David, coaches

Parent Comms

VPS Synced

Refund response templates, cancellation handling, coach reassignment scripts, progress update formats

Users: Kristen, CX, coaches

Marketing & Sales Engine

Manual

Webinar scripts, Jeremy Miner framework, Facebook ad guidelines, email sequences, brand voice guide

Users: Vik, Tony, sales team

CX Onboarding

VPS Synced

Onboarding SOP, handoff summary templates, Magoosh access, student check-in schedule, churn prevention

Users: CX team

Berkeley Masterclass

Manual

Event logistics, GHL campaign assets, session breakdowns, speaker notes, venue details

Users: Tony, Vik, ops

Leadership Ops

VPS Synced

Mission Control data, cost tracking reports, agent performance logs, team capacity reports

Users: Tony, Ray

Use Case Routing Map

Use CaseLayer
Meeting IntelligenceOpenClaw
Coach Capacity DashboardOpenClaw
Auto QA BotOpenClaw
Sales Won HandoffOpenClaw
Student Progress AlertsOpenClaw
SOP GeneratorOpenClaw
Coach Q&A AutoresponseClaude Team
Parent Progress ReportsClaude Team
Async Coaching FeedbackClaude Team
Content AgentHybrid
Marketing AttributionDev
Leadership DashboardDev

Cost Optimization Strategy

Critical Compliance Rule

Anthropic enforces a ban on using Claude Pro/Max subscription OAuth tokens in third-party tools like OpenClaw. All OpenClaw agents MUST use Anthropic API keys (pay-per-token). Violating this risks account suspension with no refund.

Model Routing (per MTok)

ModelCostApproval
Haiku 4.5$1 in / $5 outNone โ€” default
Sonnet 4.6$3 in / $15 outTeam lead
Opus 4.6$5 in / $25 outLeadership only

Rule of thumb: Haiku handles 80%+ of automated tasks. Only escalate to Sonnet when the task genuinely requires deeper reasoning.

Batch API

50% discount for non-real-time workflows. Haiku drops to $0.50/$2.50 per MTok. Ideal for daily digests, weekly reports, monthly parent reports.

Prompt Caching

Up to 90% off repeated context. Cache system prompts and SOP context. Cached reads drop from $1/MTok to $0.10/MTok for Haiku.

Smart Context Management

Pull only relevant SOP sections per call. Cap Haiku at 8K input, Sonnet at 20K. Summarize conversation history before passing to next call.

Cost Example: Meeting Prep

Before: Sonnet, full transcripts, no caching โ†’ ~$66/mo. After: Haiku, cached, batch, targeted extraction โ†’ ~$5/mo. 92% reduction.

Monthly Cost Projection

Line ItemMonthly Cost
Claude Team โ€” Standard seats (~20)~$500/mo
Claude Team โ€” Premium seats (~4)~$500/mo
OpenClaw API โ€” all agent workflows~$50โ€“150/mo
Cursor subscriptions (~4)~$80โ€“160/mo
DigitalOcean VPS~$20โ€“80/mo
TOTAL ESTIMATED~$1,150โ€“$1,390/mo

Month 1 Priorities

Week 1: Infrastructure Foundation

  • โ—Verify all machines connected to VPS via Tailscale + SSH
  • โ—Set up VPS directory structure (/opt/egelloc/brain/, /config/, /exports/, /logs/)
  • โ—Publish centralized API key directory on VPS
  • โ—Provision Claude Team plan with initial 5โ€“10 seats
  • โ—Invite Tony, Coach Art, Coach David, Kristen, Vik, Victor, Ray as initial users

Week 2: Knowledge Layer

  • โ—Create first 3 Claude Team Projects: Coaching Hub, Parent Comms, Financial Aid Playbook
  • โ—Upload foundational docs to each Project knowledge base
  • โ—Set custom instructions per Project (tone, role, boundaries)
  • โ—Set up Google Drive shared folder + rclone sync from VPS
  • โ—Connect Google Drive + Slack connectors to Team org

Week 3: First Automation

  • โ—Deliver Meeting Prep V1 via OpenClaw (Fathom โ†’ coach briefings)
  • โ—Audit all running cron jobs, assign cost-tracking keys, migrate to Haiku
  • โ—Set up Brain DB (SQLite) with agent_logs and cost_tracking tables
  • โ—Deploy webhook receiver on VPS for Close CRM events

Week 4: Convergence

  • โ—Sync Meeting Prep outputs to Google Drive โ†’ visible in Leadership Ops Project
  • โ—Train core team on Claude Team usage (Projects, Cowork, connectors)
  • โ—Generate first weekly cost report and post to Slack
  • โ—Retrospective: what's working, what's not, what's next

This document is a living spec. As the system evolves, update the VPS directory structure, the Projects map, and the use case routing table. The architecture is designed to grow organically โ€” when an agent reaches its limits, it splits; when a new function is underserved, a new Project is born.