I built a CLI tool that generates accurate subtitles for any video in under 2 minutes. Here's what I learned the hard way. The problem: existing subtitle tools either cost money, require uploads to third-party servers, or produce timestamps that drift out of sync with the video. I wanted a fully local, offline-capable pipeline. Achieved ~94% word accuracy on clear audio using Whisper medium model with no internet dependency after setup. The interesting decision: Whisper outputs word-level timestamps but they aren't always aligned with natural sentence boundaries — it'll split "I don't" across two subtitle cards, which looks jarring. I wrote a post-processing pass that merges short segments using a sliding window over character count and pause duration thresholds, then reformats to SRT. This alone made the output feel professional rather than machine-generated. Batching was the other challenge — processing a 90-minute video as one chunk causes memory spikes. I chunked audio into 30-second overlapping windows and merged transcripts with deduplication on the overlap region. What I'd do differently: add speaker diarization using pyannote.audio so multi-speaker videos get proper speaker labels in the subtitles. That's the one feature that would make this genuinely production-grade. Full case study on my portfolio → my-portfolio-one-zeta-50.vercel.app