Generate subtitles automatically from your videos or audio files using the Whisper-Large-V3-Turbo-CT2 model.
Reason to make this:
When you try to generate captions for free, most editing software either charges money or imposes strict limitations, such as daily/monthly usage limits or short-duration restrictions.
Even if they allow free use, they often add watermarks or downgrade videos to 720p doing every trick to force you to buy their software.
This tool isn’t 100% perfect, but it completes about 80% of the work reliably, providing a free and simple solution for subtitle generation.
- 🎤 Automatic Speech-to-Text: Generate
.srtsubtitles from video or audio using Whisper AI. - 🌍 Subtitle Translation: Translate subtitles into multiple languages while keeping them dubbing-friendly.
- ✍️ Grammar Fixing: Clean up bad English subtitles (e.g., spoken English) into polished, natural English.
- ⚡ Colab Ready: Run instantly on Google Colab without setup.
- 📂 JSON → SRT Converter: Convert AI-generated JSON back into
.srtfiles.
git clone https://github.com/NeuralFalconYT/Auto-Subtitle-Generator-Free.git
cd Auto-Subtitle-Generator-Free
pip install -r requirements.txt
python app.pyUpload an audio or video file → generate word-level subtitles using Whisper-Large-V3-Turbo-CT2,
then process the word-level timestamps to create different subtitle formats.
By default, you get the Whisper subtitles, and after processing you get multiple variations:
from subtitle import subtitle_maker
media_file = "video.mp4"
source_lang = "English"
target_lang = "English"
default_srt, translated_srt, custom_srt, word_srt, shorts_srt, txt_path, transcript = subtitle_maker(
media_file, source_lang, target_lang
)
# If source_lang and target_lang are the same, translation will be skipped.
# ⚠️ Note: Translation uses Google Translator, which may not always give accurate results.
# If you don’t need translation, set `source_lang` and `target_lang` to the same value.
# This will skip translation and keep the original subtitles.- default_srt → Original subtitles generated directly by Whisper-Large-V3-Turbo-CT2
- translated_srt → Translated subtitles (only if
source_lang ≠ target_lang, e.g., English → Hindi) - custom_srt → Modified version of default subtitles with shorter segments (max 38 characters per line, better readability for horizontal videos)
- word_srt → Word-level timestamps (useful for Shorts/Reels karaoke-style captions)
- shorts_srt → Optimized for vertical videos (3–4 words at a time, max 17 characters per segment)
- txt_path → Full transcript as plain text (useful for summarization or LLM-based Q&A)
- transcript → Transcript text returned directly by the function
✅ All functionality is contained in a single file, making it portable and reusable across projects.
-
Upload the
.srtfile generated by Whisper. -
Choose the Translation task in the app.
-
Generate Prompt Copy the generated prompt and paste it into Google AI Studio or your preferred LLM tool. Do not change the JSON output structure:
{ "subtitle sequence number": { "timestamp": "original timestamp", "actual subtitle text": "original subtitle line", "dubbing": <result> } } -
Copy the JSON Prompt Output Paste the JSON prompt into AI Studio and copy the LLM result.
-
Generate the Translated SRT File Paste the JSON output back into the app → download the translated
.srtfile.
Convert subtitles from any non-Latin script into Roman letters.
- Example:
"नमस्ते, आप कैसे हैं ?"→"Namaste, aap kaise hain ?" - Useful for creating dubbing-friendly subtitles for audiences who don’t read the original language but can read English..
The main goal is English-to-English dubbing: change the voice and fix grammar. After obtaining the corrected subtitles, you can use the SRT-to-audio conversion to generate audio, allowing you to dub the video or audio in English. This is especially useful for those who are weak in English or don’t have a strong voice.
Optional: Generate Audio from SRT
If you want to generate audio from the .srt file while preserving timestamps, you can try:
This allows basic video dubbing.
- 🎥 YouTubers → Auto-generate and translate subtitles.
- 🧑🏫 Teachers → Create multilingual educational content.
- 📱 Social Media Influencers → Dub videos for different audiences.
- 🌏 Movie/Anime Fans → Watch content in different languages with subtitles or dubbing.
This project is released under the MIT License free to use and modify.

