Developer adds free in-browser auto captions to YouTube Shorts converter using Whisper AI
A developer has integrated automatic caption generation into Convert to Shorts, a free browser-based tool that reformats horizontal videos to the 9:16 YouTube Shorts aspect ratio without server uploads. The feature was the most-requested after the tool's launch, driven by the fact that most Shorts viewers watch without sound and manual captioning is time-consuming. To preserve the tool's privacy-first design, the developer ran OpenAI's Whisper Tiny speech recognition model entirely in the browser using Transformers.js and WebAssembly, avoiding any video upload to external servers. Audio is extracted and resampled to 16kHz mono using the Web Audio API before being passed to Whisper, which returns timestamped transcript segments. Captions are then burned into the video using ffmpeg.wasm with the ASS subtitle format, after simpler approaches like chained drawtext filters proved unreliable.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.


Discussion (0)
Log in to join the discussion and vote.
Log in