◈ Site Factory OS — Actual Build Pipeline
Entry
User Input Form
Boss submits business info via site.coddexa.media
prompt subdomain location niche demo_link language
Immediate
Subdomain Registration
DNS via Porkbun API · nginx vhost · certbot SSL
Porkbun DNS nginx certbot
Phase 0
Reasoning Agent
Extracts structured intake from free-text prompt via AI
DeepSeek business_name niche tone SEO keywords
⟐ Parallel — Phase 0.5 + 0.6
Phase 0.5
Deep Researcher
Business intelligence via Gemini + Google Search grounding. 3 parallel queries.
Gemini 2.0 Google Search social links competitors
Phase 0.6
Demo Scraper
Extracts visual style keywords and color palette from demo URL.
Firecrawl style_keywords color palette
Phase 1
Social Image Scraper
Downloads real photos from business social profiles and website.
Instagram · Apify Facebook OG Website · Firecrawl real_images[]
⟐ Sequential — Phase 2 then 1.5
Phase 2
Theme Hunter
AI scores all 129 local themes by niche + style fit, picks top 3.
OpenAI catalog.json 3 themes → v1/v2/v3
Phase 1.5
Image Curator
Maps real images to Astro theme slots (hero, gallery, team, etc.)
OpenAI slot mapping stock_needed count
Conditional
Stock Image Sourcer
Only runs if real images don't cover all slots. Searches for fallback photos.
Pexels API Unsplash API if stock_needed > 0
⟐ Parallel — Phase 3: 6 Planning Agents
Planner 1
Aesthetic Director
Color palette, typography, visual identity, hero style
DeepSeek
Planner 2
UX/UI Planner
Page sections, nav structure, CTA placement, mobile breakpoints
DeepSeek
Planner 3
Copywriter
Hero headline, tagline, section copy, CTAs in target language
DeepSeek
Planner 4
Security Advisor
CSP headers, robots.txt, meta privacy, GDPR notes
DeepSeek
Planner 5
QA Strategist
Acceptance criteria, edge cases, cross-browser notes
DeepSeek
Planner 6
Analytics Planner
GA4 events, conversion goals, heatmap zones
DeepSeek
⟐ Parallel — Phase 4: Builder × 3 Variants
Variant v1 · Theme 1
Builder Agent
Fork theme repo → inject content.json → npm run build → generate preview URL
OpenAIAstro build
Variant v2 · Theme 2
Builder Agent
Fork theme repo → inject content.json → npm run build → generate preview URL
OpenAIAstro build
Variant v3 · Theme 3
Builder Agent
Fork theme repo → inject content.json → npm run build → generate preview URL
OpenAIAstro build
⟐ Parallel — Phase 5: QA × 3 Variants
QA — v1
QA Validator
Lighthouse audit · Playwright e2e · AI verdict · score
PlaywrightLighthouse
QA — v2
QA Validator
Lighthouse audit · Playwright e2e · AI verdict · score
PlaywrightLighthouse
QA — v3
QA Validator
Lighthouse audit · Playwright e2e · AI verdict · score
PlaywrightLighthouse
Awaiting Input
Boss Reviews & Chooses
3 live previews at /sf-preview/{job_id}/v1|v2|v3 — Boss picks one variant to deploy.
v1 preview v2 preview v3 preview POST /sf/jobs/{id}/choose
Phase 6
Deployer
Copies chosen variant dist/ → /opt/site-factory/sites/{slug}/ · updates nginx root · certbot SSL if needed · nginx reload
nginx certbot SSL rsync dist/ status → deployed
Live
Site Live ✓
Full Astro static site — HTTPS — custom subdomain — real photos — AI-generated content in target language
https://{slug}.site.coddexa.media
Sequential flow
Parallel (yellow zone)
Planning agents (purple zone)
Build + QA + Deploy (green zone)
User decision point
Conditional step