Architecture: How to make Vitto orchestrate platform generation instead of...
Documentation for Sessions
🏗️ Architecture: How to make Vitto orchestrate platform generation instead of...
Date: 2026-02-28
Time: 21:38:59 UTC
Session: gspace1-156.3
Agent: backend
Confidence: 92%
Status: ✅ Documented
📋 Decision Context
Question:
How to make Vitto orchestrate platform generation instead of bypassing it?
Task: Not specified
🎯 Decision Made
Chosen:
PlatformGenerationController + PlatformGenerationService in backend-vitto-api's module-generation module. POST /module-generation/platform/generate with SSE streaming. Orchestrates ANALYZE→PLAN→EXECUTE→VERIFY using existing BackendAiClientService and BackendApiClientService. Continue-on-failure per module.
Options Considered:
- No alternatives documented
💭 Reasoning
ROOT CAUSE: Platform generation went directly from vibe-universe UI → backend-ai-api's workflow.service, completely bypassing Vitto. This meant no SmartRouter (multi-provider failover), no CostGuard, no strategy optimization, no user memory injection, no episodic recall. The fix adds a platform-level endpoint to Vitto's existing module-generation module (not a new top-level module — same domain). Vitto calls backend-ai-api for LLM generation (which now includes the convergence loop) and backend-api for page persistence. Shell template selection mirrors the frontend ShellGeneratorService logic for consistency. Each module is generated independently with continue-on-failure semantics — a failed module doesn't kill the whole platform.
📁 Files Involved
APIs/backend-vitto-api/src/app/module-generation/platform-generation.controller.tsAPIs/backend-vitto-api/src/app/module-generation/platform-generation.service.tsAPIs/backend-vitto-api/src/app/module-generation/module-generation.module.ts
🔗 Related
- Decision ID:
dev_1772314739854_v17ts99 - Session: 156
- Workspace: gspace1
Auto-generated by MCP Smart Consolidation