Short-Form Pipeline takes a YouTube URL and produces vertical clips ready to upload. It downloads the video and captions with yt-dlp, transcribes with Whisper, asks Claude for two to five moments of 30 to 60 seconds with a hook score of at least 7 out of 10, and checks that each clip ends on a complete thought.
FFmpeg then cuts each clip, crops 16:9 to 9:16 using a layout hint, and burns in word-highlighted captions. A second script clips without Claude, using heuristic scoring.
What You Get
- Vertical 1080 by 1920 clips in H.264 and AAC with word-highlighted captions
- Claude-selected segments with start and end time, title, hook sentence, payoff and layout hint
- A second Claude pass that checks each clip ends on a complete thought
- Layout-aware cropping, with face detection for talking heads when mediapipe and opencv are installed
- Tuning points: voice patterns, hook strength minimum, target duration, zoom and face position
- A troubleshooting list for FFmpeg, resolution, caption sync and upload problems
Common Use Cases
- Turning a podcast episode into three short clips for TikTok, Reels and Shorts
- Producing captioned vertical clips from a webinar or screen share recording
- Running a no-API clipper with heuristic scoring for a quick pass
- Batch-processing a channel’s videos while skipping ones already processed
What Makes It Unique
It covers the full path from URL to captioned vertical file in one script, and its crop step adapts to the video layout, with a different treatment for talking heads, screen shares, split screens and gallery views. A verification pass checks clip endings, and clips over 90 seconds are trimmed automatically.
Under The Hood
The scripts run as Python commands and shell out to yt-dlp, ffprobe and FFmpeg. They download videos and captions from YouTube, send transcript text to the Anthropic API using your key from the environment, and write video, caption and a processed-URL list into a workspace folder. A preamble at the start runs the repository’s version check and telemetry setup scripts, which log usage locally and make remote reporting opt-in.