deniz.in

Markets

Weather

Loading weather

· via dev.to (home feed)

Open-source pipeline turns a topic into a finished 20-30 minute documentary

A developer has released AI Video Factory, an MIT-licensed Python pipeline that researches, scripts, narrates and assembles full documentaries on local hardware, no cloud required.

Open-source pipeline turns a topic into a finished 20-30 minute documentary

A developer has released AI Video Factory, an MIT-licensed Python pipeline that takes nothing more than a topic and produces a finished 20-30 minute documentary: a researched script, per-scene visuals, narration, music, captions, a thumbnail and YouTube-ready metadata. In a dev.to post dated 20 September 2026, the author, publishing under the handle summitsingh, walks through what the tool does and, more interestingly, what building it taught them about where generative AI still breaks down.

What the pipeline actually does

According to the post, the system handles the whole production chain end to end. It researches the topic, drafts a script with citations, fetches stock footage for each scene from Pexels, Pixabay and NASA, narrates with a local text-to-speech engine, adds a music bed, overlays karaoke-style captions and assembles the final cut with FFmpeg. A quality-control step runs before output, and the pipeline also produces a thumbnail plus the metadata a YouTube upload needs. Seven presets are included, covering formats such as business post-mortems, historical reconstructions, science documentaries and a horror anthology.

Hallucinated citations, runtime drift and the stock-footage surprise

The most candid part of the write-up is the list of problems the author hit along the way. The first: language-model scripts came back with references that sounded credible but resolved to nothing. The fix is now built into the pipeline itself — every cited URL receives a live HTTP request, and only a 200 response counts as valid. Citations that fail the check are cut or rewritten.

The second problem was what the author describes as runtime drift: a video targeted at 25 minutes kept finishing at around 14, because the generated script simply carried too little material. Scripts are now structured as timed beats, and underweight sections get extended at roughly 150 words per minute until the target length holds.

The third finding cuts against current expectations: for most scenes, real stock footage worked better than AI-generated visuals. The author writes that generated imagery looks impressive frame by frame but feels off across a 20-minute runtime. The pipeline now prefers real footage, falling back to locally generated stills and procedural visuals when nothing suitable turns up.

The unglamorous engineering

The post also credits the less flashy parts of the build. Each pipeline stage is cached by content hash, so revising a single scene no longer forces a full re-render. A QC gate fails the run before encoding if it detects dark frames, silent audio or the wrong resolution. Audio gets a single loudness-normalisation pass to -16 LUFS, and scenes are joined with FFmpeg crossfade transitions.

Local-first, with cloud video on the roadmap

Nothing in the pipeline requires a cloud service, according to the author. Script generation works against any OpenAI-compatible endpoint — LM Studio and llama-server are both named — and the text-to-speech stage runs locally. Planned additions include caption alignment using Whisper, more music profiles, optional Veo and Sora providers for visuals, and multilingual narration. The code is available on GitHub under the MIT licence, and the author closes by admitting uncertainty about whether anyone else wants the tool, inviting readers to suggest what to throw at it first.

Why it matters

AI Video Factory is a useful snapshot of how generative AI workflows have matured: the interesting engineering is no longer in prompting a model but in the scaffolding around it — verification, runtime budgeting, caching and quality gates. The HTTP citation check in particular treats LLM output as claims to be validated rather than facts to be trusted, a pattern that deserves to spread far beyond video production. The finding that licensed stock footage beats generated imagery over long runtimes is a quiet corrective to the assumption that generative video is ready to displace real footage everywhere. And the project shows how far one developer can get with local models and open tooling alone, no cloud GPU required.

  • #open-source
  • #ffmpeg
  • #generative-video
  • #llm
  • #python

Related posts