ARCHITECTURE MIND MAP • 2026-04-17

The Brain · The Site · The UI

Three repos, one flow. Where data lives, where skills execute, where operators click. The complete picture for team onboarding and future-Claude-session context.

The three repos at a glance
PYTHON · CLAUDE SKILLS
🧠
The Brain
campaign-forge
Source of truth. Every schema, every piece of research, every pipeline skill, every ADR. Nothing else has canonical data.
Owns
  • Pipeline skills (Stages 1-7, Retro)
  • Canonical JSON schemas (docs/schemas/)
  • Vertical research (EDU, auto, Medicare...)
  • Psychology trigger library (148 triggers)
  • Compliance configs per vertical
  • Winners vault per vertical
  • Swipe vault (UGC library + proven creative)
  • ADRs (architectural decisions)
Runs locally · Schema source for all subscribers
ASTRO · SVELTE ISLANDS
🌐
The Site
ContentForge
The execution surface. Articles, tools, quizzes, landers. Reads brain data at build time. Deploys to the public web.
Owns
  • Site templates & components
  • Tool UX (EFC Calculator, Quizzes, etc.)
  • Article + tool content (.mdx files)
  • SEO infrastructure (sitemaps, robots)
  • Build pipeline → Cloudflare Pages
  • Future: Content/SEO skills (.claude/skills/)
Deploys to degreesources.com + future vertical domains
SVELTEKIT · DRIZZLE
🎛️
The UI
campaignforge-app
Operator control surface. Wraps the pipeline today; will wrap content production tomorrow. Team's only touchpoint — no terminal required.
Owns
  • Pipeline UI (brief → campaign → export)
  • Pipeline orchestrator (SSE streaming)
  • Session management + cost tracking
  • Integrations (Everflow, Meta, Google, TikTok)
  • Scaffolded: Content UI routes (stubbed)
  • Pending: /api/content/build endpoint
Deploys to Coolify · Pending production deploy
The flow — visually
Operator / Team You + 2-3 media buyers CAMPAIGNFORGE-APP • THE UI SvelteKit Operator Console /api/pipeline/* execute · approve · status (BUILT) /api/content/* build · articles · tools (STUB) CAMPAIGN-FORGE • THE BRAIN Source of truth for all data + pipeline skills RESEARCH verticals/edu/ verticals/auto/ buyer intel, gov data state by state PSYCHOLOGY trigger-library 148 triggers Papers 1+2+3 synth + schema SCHEMAS docs/schemas/ 13 .json files canonical contracts ADR 0005 COMPLIANCE config/compliance/ per vertical restricted claims scan patterns SKILLS .claude/ skills/ Stages 1-7, R CONTENTFORGE • THE SITE Astro + Svelte Islands CONTENT articles + tools FUTURE SKILLS .claude/skills/ DEPLOY Cloudflare Pages CAMPAIGN OUTPUT verticals/<v>/campaigns/<name>/ brief → strategy → copy → creatives → structure → export (CSVs, XLSX) → Meta / Google / TikTok / Taboola click invoke pipeline skills future: invoke content skills reads research, schemas, compliance pipeline writes campaign artifacts
Built & live
Scaffolded, wiring pending
Planned next
Human action
Where skills live

campaign-forge/.claude/skills/

Pipeline · Built
  • /orchestrator flow ctl
  • /brief-validator Stage 1
  • /strategy-engine Stage 2
  • /copy-factory Stage 3
  • /copy-review Stage 3B
  • /creative-director Stage 4
  • /campaign-architect Stage 5
  • /landing-page Stage 7
  • /export-packager Stage 6
  • /campaign-retro Stage R
  • /content-writer legacy — move?
  • /content-site legacy — move?

ContentForge/.claude/skills/

Content + SEO · To build
  • /article-writer Tier 1
  • /tool-page-builder Tier 1
  • /quiz-builder Tier 1
  • /content-brief-builder Tier 1
  • /page-seo-audit Tier 1
  • /keyword-research Tier 2
  • /internal-link-planner Tier 2
  • /schema-markup-generator Tier 2
  • /content-gap-analyzer Tier 2
  • /cwv-audit Tier 3
  • /conversion-audit Tier 3
  • /content-refresh Tier 3
  • /edu-financial-aid-writer Tier 4
  • /auto-quote-funnel-builder Tier 4
  • /medicare-enrollment-content Tier 4

campaignforge-app/src/lib/server/

Orchestration · SvelteKit
  • pipeline/orchestrator.ts built
  • pipeline/state.ts built
  • pipeline/validator.ts built
  • agent/executor.ts built
  • agent/session-manager.ts built
  • agent/cost-tracker.ts built
  • agent/prompts.ts built
  • integrations/meta-api.ts built
  • integrations/google-ads.ts built
  • integrations/tiktok-api.ts built
  • integrations/everflow.ts built
  • integrations/capi.ts built
  • /api/content/build (wire up) STUB
  • /api/content/articles TODO
  • /api/content/tools TODO
Data flow paths
1

Campaign generation (today, built)

Operator launches a full campaign from brief → export. Pipeline skills live in brain, UI wraps them.

Operatorapp UI/api/pipeline/execute
agent/executor.tsbrain/.claude/skills/
reads vertical research + compliance + triggers
writes verticals/<v>/campaigns/<name>/
validates with scripts/validate-stage-output.py
SSE stream back to UI for display
2

Content production (target state)

Operator requests a new article or tool. Skill lives in ContentForge, reads brain data, writes content in-repo.

Operatorapp UI/api/content/build
invokes ContentForge/.claude/skills/article-writer
skill reads brain research + triggers + compliance
writes src/content/<v>/articles/<slug>.mdx
ContentForge build runs (Astro)
deploys to Cloudflare Pages
UI shows status + preview URL
3

Schema evolution (always)

A data contract needs to change. Brain owns the schema; subscribers adapt. ADR required first.

New requirement surfacesADR drafted in brain/docs/adr/
operator approves ADR
schema edited in brain/docs/schemas/
ContentForge pins new SHA + adapts types
campaignforge-app pins new SHA + adapts types
validators updated, CI passes
CROSS-REPO.md updated
4

Vertical expansion (repeatable pattern)

Adding auto insurance, Medicare, etc. The shell grows in brain first; execution surface follows.

Identify new verticalbrain/verticals/<v>/ created
research + compliance + brand config added
trigger library extended if needed
ContentForge/src/content/<v>/ scaffolded
Tier 4 skill added: /<v>-<function>
campaigns can generate; site can publish
Vertical expansion — EDU today, every vertical after
SHIPPED
STEP 1 · BRAIN SHELL

Vertical research in brain

Create verticals/<name>/. Drop in research docs, buyer intel, compliance config, brand.json, tracking.json. This is the data that every downstream skill will consume.

EDU complete. Auto insurance + Medicare research partially ported.

NEXT
STEP 2 · CONTENT SKILLS

Tier 4 skills in ContentForge

Add ContentForge/.claude/skills/<vertical>-*/. Each skill wraps Tier 1-3 primitives with vertical-specific context loaders (which research files, which compliance rules, which triggers apply).

Starting with EDU — then repeatable per vertical.

REPEAT
STEP 3 · CAMPAIGNS + SITE

Execute across both surfaces

Campaigns generate from brain (already works — no changes needed per vertical). ContentForge deploys a new domain (autoinsurancesources.com, etc.). Everflow offer + tracking wired once. Loop closes.

Same brain, new surface. No duplication.

Team operator journey

Today — Terminal + Claude Code

OPERATOR ONLY
  • YouOpen Claude Code in campaign-forge repo
  • YouRun /orchestrator verticals/edu/campaigns/<name>
  • YouReview Stage 2 angles, approve/edit
  • YouReview Stage 3 copy after auto /copy-review
  • YouLaunch exports to Meta / Google manually
  • YouFor content: open Claude Code in ContentForge repo

Target — UI for everything

YOU + 2-3 TEAM MEMBERS
  • TeamLogs into campaignforge-app in browser
  • TeamClicks "New campaign" → fills brief form
  • TeamWatches stages stream in real time (SSE)
  • TeamReviews + approves at pause points (UI buttons)
  • TeamClicks "New article" → picks vertical + topic
  • TeamArticle auto-builds + deploys; preview URL back
  • YouOnly touch terminal for skill work + ADRs
Current state vs. target state
Surface Today Target Gap
Pipeline (brain) ✓ Stages 1-7 + Retro shipped Same None — stable
Pipeline UI (app) ◐ Built, not deployed Deployed to Coolify + team access Coolify deploy + auth + team onboarding
ContentForge site ✓ 31 pages, 10 tools, live on Cloudflare Same + multi-vertical subdomains Auto insurance / Medicare sites (future)
Content skills ○ None in ContentForge Tier 1-4 skills in ContentForge/.claude/skills/ THIS PROJECT — ADR 0010 + skill build
Content UI (app) ○ Routes stubbed, 501 endpoint Wired to ContentForge skills via API Wire /api/content/* to skill invoker
Schema subscription ◐ Docs exist, pinning manual Versioned npm/pip package Post-Phase 5 per CROSS-REPO.md
Vertical coverage ✓ EDU live EDU + auto + Medicare + more Tier 4 skills per vertical (repeatable)
Team access ○ Operator only 2-3 team members in UI App deployed + auth + training

The governing rule

Logic lives in repos. UI is orchestration only. Skills always live next to the code they operate on (pipeline skills in brain, content skills in ContentForge). The app is a dumb (but beautiful) operator surface that invokes skills via HTTP. If the app breaks, power users still ship via Claude Code. If Claude Code changes, the UI still works. Neither dependency direction inverts — no component owns another's code.

References: docs/adr/0010-content-skills-in-contentforge.md (drafted, not yet written), docs/psychology-engine/CROSS-REPO.md, docs/adr/0005-shared-schemas-in-campaign-forge.md.

CampaignForge Architecture Mind Map · v1 · 2026-04-17 · specs.fourthright.io/architecture.html