AI-YouTube-Shorts-Generator is a Python-based tool that automates the creation of short-form vertical video clips (“shorts”) from longer source videos — ideal for adapting content for platforms like YouTube Shorts, Instagram Reels, or TikTok. It analyzes input video (whether a local file or a YouTube URL), transcribes audio (with optional GPU-accelerated speech-to-text), uses an AI model to identify the most compelling or engaging segments, and then crops/resizes the video and applies subtitle overlays, producing a polished short video without manual editing. The tool streamlines multiple steps of the tedious short-form video workflow: highlight detection, clipping, subtitle generation, cropping to vertical 9:16 format, and final rendering — reducing hours of editing to a mostly automated pipeline. Because it supports both local and online video sources, it's flexible whether you're working with your own recorded content or repurposing existing longer-form videos.
Features
- Supports both YouTube URLs and local video files as inputs for conversion to Shorts
- Automatic audio transcription (with GPU/Whisper support) and subtitle generation for accessibility and engagement
- AI-based highlight detection to identify the most engaging 2-minute (or shorter) segment for clipping
- Smart cropping and formatting to 9:16 vertical video, optimized for mobile/social media viewing
- Subtitle overlay rendering and video re-encoding/pipeline automation via FFmpeg + OpenCV stack
- CLI-based workflow (or automated/batch mode) to process multiple videos, enabling fast scaling of content repurposing