The Problem
Marketing teams waste hours reviewing low-quality AI-generated content because most generation tools have no concept of a workflow. They hand you a blank prompt box and let you produce infinite variants with no structure, no approval gates, and no delivery mechanism. The result: creative chaos, not a repeatable production system.
The client needed something different—a platform where every ad campaign followed a strict, auditable path from brief to approved winner to delivered asset.
What Was Built
AI Ad Studio is a monorepo SaaS built around a single opinionated workflow:
Brief → Concepts → Storyboard previews → Render batch → Review → Winner selection → Promotion → Delivery
Every step is gated. You cannot skip to rendering without a reviewed concept. You cannot promote a variant without a winner selection. You cannot deliver without owner approval. This constraint is the product.
Architecture
The system runs on a Next.js monorepo with Supabase as the persistence and auth layer, Cloudflare R2 for asset storage, and Runway ML as the video generation backend.
The most interesting engineering challenge was the render batch system. Renders are expensive and slow—Runway can take 30–90 seconds per clip. The solution was a worker-driven batch queue that:
- Accepts a batch of concept variants from the UI
- Fans out generation jobs with per-job status tracking
- Streams status updates back to the UI via Supabase Realtime
- Locks the batch once all renders complete, preventing mid-batch edits
This means the UI is always consistent with the backend state—no orphaned renders, no stale previews.
Delivery Workspaces
Once a winner is selected, the system generates a token-gated public delivery workspace—a URL the campaign owner shares with their client. The workspace shows only the canonical winning variant, no drafts or rejected concepts. Access tokens are single-use or time-limited depending on the campaign settings.
This replaced the common pattern of sending Dropbox links or attaching files to emails—both of which lose the approval context entirely.
Key Engineering Decisions
Constrained workflow over open generation. The product deliberately doesn't let users generate freely. Every generation is attached to a concept, every concept to a brief. This sounds like a limitation—it's actually the feature that makes the output trustworthy.
OpenAI for concept scripting, Runway for video. Concept scripts and storyboard copy are generated via GPT-4o with structured output. Runway handles the visual generation. Keeping these two concerns separate made each easier to tune independently.
Brand kits as first-class objects. Colors, fonts, tone guidelines, and example outputs are stored per-brand and injected into every generation prompt. This was the single biggest quality improvement over generic prompting.
Scope
- ✓Structured product brief capture, brand kits, and reusable templates for repeatable campaigns.
- ✓Concept generation and storyboard preview flow before committing to expensive renders.
- ✓Controlled multi-variant render batches with side-by-side review and winner selection.
- ✓Public campaign pages and delivery workspaces backed by token-based access for canonical exports.
- ✓Owner-controlled single-export share links plus durable workflow records for audit and iteration.
Waqas Raza
AI-Native Full-Stack Engineer. Top Rated on Upwork · $180K+ earned · 93% job success. I build production AI agents, LLM systems, Web3 platforms, and full-stack applications.
Hire me on Upwork