🧠

CEO Terminal v2.0

Stephanie asks a question. The system calls live APIs. Real data comes back. No stale files. No guessing.

THE ARCHITECTURE

👩‍💼 STEPHANIE
🧠 OPENAI API (Reasoning + Tool Calling)
📊 Nexus API
📋 Monday.com
🔧 ServiceTitan
💰 Google Ads
💳 Ramp
✅ VERIFIED ANSWER (with data source + timestamp)

HOW IT WORKS (Runtime Flow)

1. Stephanie types: "What's going on today?"
2. OpenAI API receives the question + system prompt + tool definitions
3. OpenAI decides which tools to call: get_revenue_today, get_google_ads, get_overview
4. Our VM executes: GET /ceo-api/revenue/today, GET /ceo-api/google-ads/performance, GET /ceo-api/overview
5. Nexus API returns live data from ST, Google Ads, Ramp, GA4
6. OpenAI receives the tool results and composes an executive answer
7. Stephanie sees: revenue, alerts, decisions needed — all from live data, timestamped
🚨
THE RULE THAT FIXES EVERYTHING
If a live Nexus endpoint exists for the question,
the model MUST call it before answering.

No exceptions. No fallbacks. No guessing.

This is the missing enforcement layer. This is what broke before.

23 TOOLS THE TERMINAL CAN USE

get_health — API alive check
get_ceo_brief — Full morning briefing
get_overview — Combined system status
get_latest_briefing — Daily intel report
get_revenue_today — Today's revenue + jobs
get_revenue_week — Last 7 days
get_revenue_month — Month-to-date
get_technician_performance — Tech rankings
get_team_member_detail — Individual tech
get_google_ads_performance — Ads data
get_offensive_engine — Anomaly report
get_experiments_status — All experiments
get_recent_expenses — Ramp spend
get_website_speed — Page speed scores
get_ga4_today — GA4 traffic
get_robert_status — Robert's activity
list_monday_boards — List boards
get_monday_board_items — Board items
create_monday_board — Create board
create_monday_item — Create item
update_monday_item — Update item
delete_monday_item — Delete item
add_monday_update — Add comment

BUILD PLAN

PHASE 1: Deploy v4 Instructions to ChatGPT GPT (2 min) ✅

Robert copies v4 instructions into GPT builder. Immediate fix — GPT starts calling API first instead of answering from stale files. 80% of Stephanie's problem solved.

PHASE 2: Build VM Terminal with OpenAI Tool Calling (2 hrs)

Script: nexus_ceo_terminal.py on the VM
What it does:
1. Receives Stephanie's question (via Streamlit web UI or API endpoint)
2. Sends to OpenAI API with system prompt + 23 tool definitions
3. OpenAI decides which tools to call
4. VM executes the actual HTTP calls to Nexus API
5. Returns tool results to OpenAI
6. OpenAI composes executive answer
7. Stephanie sees the answer with data sources

Requires:
☐ OpenAI API key (in .env)
☐ openai Python package (pip install)
☐ System prompt (from v4 instructions)
☐ Tool schema JSON (23 tools defined)
☐ Tool executor (maps tool names to Nexus HTTP calls)
☐ Streamlit UI or new API endpoint for Stephanie to access

PHASE 3: Streamlit CEO Dashboard (1 hr)

URL: morpheus.callbrightside.com/ceo-terminal/
What Stephanie sees:
• Chat interface (type question, get answer)
• Sidebar with quick buttons: "Good morning" / "Revenue today" / "Tech performance" / "Google Ads"
• Every answer shows data source + timestamp
• Data quality warnings shown in orange
• Monday.com actions (create board, add item) built into chat

BEFORE vs AFTER

❌ BEFORE (ChatGPT GPT)
Stephanie asks question
GPT reads stale knowledge file
GPT answers with old numbers
Maybe calls API, maybe doesn't
No data freshness indicator
No quality warnings
Confidently wrong
✅ AFTER (VM Terminal)
Stephanie asks question
OpenAI selects tools to call
VM calls live Nexus API
Real data returns with timestamp
Data quality issues flagged
Executive-grade output
Correct or explicitly uncertain

WHAT STEPHANIE SEES (Example)

Stephanie: What's going on today?
CEO Terminal:
🚨 CRITICAL
• Google Ads: $401 spent, 0 leads attributed (ST tagging broken, not an ad problem)
• Site speed: Homepage 28/100 mobile, LCP 8.2s

💰 TODAY
• Revenue: $0 visible (⚠ 9 jobs pending invoice — revenue is real but not posted)
• Jobs: 9 completed
• Sewer campaign: 6 conversions, $3,000 value, 21.3x ROAS

📈 ADS (Last 7 Days)
• Spend: $3,285 | Conv: 24 | CPL: $137
• Top: Sewer $610 (21 conv) | Drain $809 (1 conv — bleeding)

WORKING
• Sewer campaign on fire (phones ringing per Kalen)
• 100 automated systems running
• Self-healing: 11 patches applied overnight

DECISION NEEDED:
• Approve 20 negative keywords ($892/mo waste)? Robert can execute.

Sources: /revenue/today (15:06 UTC) | /google-ads/performance (15:06 UTC) | /overview (15:06 UTC)