•
9 min read
•AI/MLVideo Automation at Scale: Processing 1,000+ Videos/Day
How we built an AI-powered video automation engine that reduced production costs by 85%, processing 1,000+ videos daily from $500 to $75 per video.
The Problem
E-commerce clients needed product videos at scale:
- Manual editing: $500/video
- 500 videos/month target
- Quality must be consistent
- Fast turnaround required
The Solution: Vela
Vela automates video production using:
- FFmpeg for processing
- Browser-based rendering
- Template system
- Batch processing
Architecture
┌──────────────┐ ┌──────────────┐ ┌──────────────┐
│ Template │────▶│ Renderer │────▶│ Output │
│ Builder │ │ (FFmpeg) │ │ Storage │
└──────────────┘ └──────────────┘ └──────────────┘
│
▼
┌──────────────┐
│ Browser │
│ Preview │
└──────────────┘
Key Features
1. Template System
interface VideoTemplate {
id: string;
duration: number;
layers: Layer[];
transitions: Transition[];
}
interface Layer {
type: 'text' | 'image' | 'video' | 'audio';
content: string | Blob;
start: number;
end: number;
effects?: Effect[];
}
2. Browser Rendering
Using FFmpeg.wasm for in-browser rendering:
const ffmpeg = new FFmpeg();
await ffmpeg.load();
await ffmpeg.writeFile('input.mp4', videoFile);
await ffmpeg.exec([
'-i', 'input.mp4',
'-i', 'overlay.png',
'-filter_complex', 'overlay=10:10',
'-c:v', 'libx264',
'-preset', 'fast',
'output.mp4'
]);
3. Cloud Fallback
For complex renders, offload to AWS Fargate:
if (estimatedRenderTime > 30000) {
// Use cloud rendering
const job = await ecs.runTask({
cluster: 'video-render',
taskDefinition: 'ffmpeg-task',
});
} else {
// Use browser rendering
const output = await renderInBrowser(template);
}
Cost Breakdown
| Component | Before | After | Savings | |-----------|--------|-------|---------| | Manual editing | $500 | $0 | 100% | | Compute (cloud) | - | $45 | - | | Storage | - | $20 | - | | CDN | - | $10 | - | | Total | $500 | $75 | 85% |
Performance
- Throughput: 1,000+ videos/day
- Quality: 1080p output
- Formats: MP4, WebM, GIF
- Speed: Average 30s render time
Results
For e-commerce clients:
- 85% cost reduction per video
- 10x faster turnaround
- Consistent quality
- Scalable to any volume
Video automation demonstrates that with the right tools, content creation can be both fast and affordable.