I've been working on AI Video Factory, an MIT-licensed Python pipeline that turns a topic into a complete 20-30 minute documentary: researched script, per-scene visuals, local TTS narration, music bed, karaoke captions, FFmpeg assembly, QC, thumbnail, and YouTube metadata.
Demo
Two videos so far:
Demo #1: an AI-generated teaser clip showing the idea: https://youtu.be/CASvWRXd3jg
Demo #2: 47 seconds of real output from the pipeline, topic "Europa's Hidden Ocean" (stock footage, local TTS narration, karaoke captions): https://youtu.be/XrlqRv2bInQ
Both are rough. If you watch, I'd rather hear what's off than what's good.
What it does
You give it a topic. It researches the topic, writes a script with citations, pulls per-scene visuals from Pexels/Pixabay/NASA, narrates it with local TTS, lays down a music bed, burns in karaoke captions, assembles everything in FFmpeg, runs a QC gate, and outputs a thumbnail plus YouTube metadata. Seven presets: business autopsy, history reconstruction, science doc, horror anthology, and more.
Three things I learned the hard way
1. LLM-written scripts invent citations that look completely legit. The first scripts came back with references that sounded real but pointed nowhere. Now every cited URL gets a real HTTP check against a 200 response. Anything that fails the check gets cut or rewritten.
2. A "25 minute" video kept coming out at 14 minutes. Runtime drift is a real problem with generated scripts. Scripts are now written in timed beats, and underweight beats get extended at roughly 150 wpm until the target runtime holds.
3. Real stock footage beats AI visuals for most scenes. This one honestly surprised me. AI-generated visuals look impressive frame by frame but feel off across a 20-minute runtime. The pipeline prefers real footage, with local still generation and procedural fallbacks when nothing fits.
The unglamorous wins
- Content-addressed caching of pipeline stages, so iterating on one scene does not mean a full re-render.
- A QC gate that fails the run on dark frames, digital silence, or wrong resolution before encoding.
- Single loudnorm pass to -16 LUFS, per-scene xfade transitions.
Local-first
Scripting runs against any OpenAI-compatible endpoint (LM Studio, llama-server), TTS is local, and nothing cloud is required. Roadmap includes Whisper-based caption alignment, more music profiles, optional Veo/Sora providers, and multilingual narration.
The repo is here: https://github.com/summitsingh/ai-video-factory
I genuinely don't know if anyone besides me wants this. Tell me what you'd throw at it first.
Top comments (0)