<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/i-built-a-langgraph-pipeline-that-turns-long-videos-into-short-clips-automatically-vyj8m8unt" -->

---
title: I built a LangGraph pipeline that turns long videos into...
description: A developer built an automated video clipping pipeline that takes long-form YouTube videos or uploads and produces three 9:16 portrait clips ready for TikTok,...
canonical: https://daily.dev/posts/i-built-a-langgraph-pipeline-that-turns-long-videos-into-short-clips-automatically-vyj8m8unt
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: I built a LangGraph pipeline that turns long videos into short clips automatically | daily.dev
og:description: A developer built an automated video clipping pipeline that takes long-form YouTube videos or uploads and produces three 9:16 portrait clips ready for TikTok,...
og:url: https://daily.dev/posts/i-built-a-langgraph-pipeline-that-turns-long-videos-into-short-clips-automatically-vyj8m8unt
og:image: https://api.daily.dev/og/posts/VyJ8m8uNt.png
og:image:alt: I built a LangGraph pipeline that turns long videos into short clips automatically
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# I built a LangGraph pipeline that turns long videos into short clips automatically

**[Abhisek Mishra](https://daily.dev/sources/d24bwfvkltystg5uzcb7l)** · [@abhisekmishra](https://daily.dev/abhisekmishra) · 2 min read · 0 upvotes · 0 comments

## Summary

A developer built an automated video clipping pipeline that takes long-form YouTube videos or uploads and produces three 9:16 portrait clips ready for TikTok, Reels, or Shorts. The pipeline uses Whisper for transcription, an LLM to identify high-engagement moments, face/focus detection for cropping, and FFmpeg for rendering with baked-in captions. The key architectural decision was using LangGraph to break the pipeline into discrete, independently retryable nodes (transcription → clip_selection → focus_detection → rendering), enabling real-time UI progress updates and easier debugging. The stack includes FastAPI, Next.js 14, and Supabase. Clip selection works best for talk-heavy content; multi-person framing and B-roll-heavy videos are known limitations.

## Content

I've been sitting on a side project for a few months and finally got it to a point where I'm comfortable sharing it.

The problem: I had hours of recorded content — long videos, lectures, interviews — and manually finding the good 60-second moments to clip was eating time I didn't have.

So I built a pipeline that does it automatically.

## What it does

You paste a YouTube URL or upload a video. The tool:

1. Pulls the audio and transcribes it with **Whisper**
2. Sends the transcript to an LLM to identify the 3 highest-engagement moments
3. Runs face/focus detection to find the right crop position
4. Renders each clip in **9:16 portrait format** with captions baked in via FFmpeg
5. Hands you 3 download-ready clips for TikTok / Reels / Shorts

## The interesting part — LangGraph orchestration

Instead of wiring this as one big sequential script, I broke it into discrete nodes using **LangGraph**:

```
transcription → clip_selection → focus_detection → rendering
```

Each node handles its own state, errors, and retries independently. The UI gets real-time progress updates as state moves through the graph — so you're not staring at a blank loading screen for 3 minutes.

It also made the pipeline much easier to debug. When clip selection was returning bad moments, I could isolate that node and test it without re-running transcription every time.

## Stack

- **FastAPI** — backend API
- **Next.js 14** — frontend
- **Whisper** — transcription
- **FFmpeg** — video rendering
- **LangGraph** — pipeline orchestration
- **Supabase** — storage and auth

## What works well / what doesn't

Clip selection is solid for talk-heavy content — podcasts, interviews, lectures, conference talks. It struggles more with B-roll-heavy videos where the transcript alone doesn't capture what makes a moment visually interesting. That's the next thing I want to solve.

Face detection works well for single-speaker videos. Multi-person framing still needs work.

## Try it

It's free right now, no signup needed: https://video-generator-six-coral.vercel.app/

Would genuinely love feedback from developers — especially on the LangGraph architecture and whether the clip selection actually picks good moments for your content type.

## Similar posts on daily.dev

- [I Built an “Anime Factory”: a System That Turns Episodes Into Shorts by Itself](https://daily.dev/posts/i-built-an-anime-factory-a-system-that-turns-episodes-into-shorts-by-itself-rkyg3s7yn) · Medium · 0 upvotes · 0 comments
- [How Glance turns hours of video into mobile-ready clips with AI](https://daily.dev/posts/how-glance-turns-hours-of-video-into-mobile-ready-clips-with-ai-vikjn8jaa) · Google Cloud · 1 upvotes · 0 comments
- [Stop Trying to Make ChatGPT Edit Your Videos](https://daily.dev/posts/stop-trying-to-make-chatgpt-edit-your-videos-1vvlf4b1y) · Towards Dev · 3 upvotes · 0 comments

---

Tags: [#backend](https://daily.dev/tags/backend), [#langgraph](https://daily.dev/tags/langgraph), [#whisper](https://daily.dev/tags/whisper)

[View this post on daily.dev](https://daily.dev/posts/i-built-a-langgraph-pipeline-that-turns-long-videos-into-short-clips-automatically-vyj8m8unt)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"DiscussionForumPosting","mainEntityOfPage":"https://daily.dev/posts/i-built-a-langgraph-pipeline-that-turns-long-videos-into-short-clips-automatically-vyj8m8unt","headline":"I built a LangGraph pipeline that turns long videos into short clips automatically","text":"A developer built an automated video clipping pipeline that takes long-form YouTube videos or uploads and produces three 9:16 portrait clips ready for TikTok, Reels, or Shorts. The pipeline uses Whisper for transcription, an LLM to identify high-engagement moments, face/focus detection for cropping, and FFmpeg for rendering with baked-in captions. The key architectural decision was using LangGraph to break the pipeline into discrete, independently retryable nodes (transcription → clip_selection → focus_detection → rendering), enabling real-time UI progress updates and easier debugging. The stack includes FastAPI, Next.js 14, and Supabase. Clip selection works best for talk-heavy content; multi-person framing and B-roll-heavy videos are known limitations.","url":"https://daily.dev/posts/i-built-a-langgraph-pipeline-that-turns-long-videos-into-short-clips-automatically-vyj8m8unt","datePublished":"2026-05-24T05:57:15.106Z","dateModified":"2026-05-24T05:58:16.080Z","author":{"@type":"Person","name":"Abhisek Mishra","url":"https://daily.dev/abhisekmishra","image":"https://lh3.googleusercontent.com/a/ACg8ocLok9HScfiLKlSOi3lpdJmlLK_LcOqlZbmmkT96CSjGdGoVVw=s96-c","interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"EndorseAction"},"userInteractionCount":30}},"interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"isPartOf":{"@type":"WebPage","url":"https://daily.dev/sources/d24bwfvkltystg5uzcb7l","name":"Abhisek Mishra"}}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Abhisek Mishra","item":"https://daily.dev/sources/d24bwfvkltystg5uzcb7l"},{"@type":"ListItem","position":3,"name":"I built a LangGraph pipeline that turns long videos into short clips automatically"}]}
```

