dean9703111/audio to srt converter
This skill should be used when the user asks to "convert audio to srt", "generate subtitles from audio", "create srt from mp3/wav/m4a/flac", "transcribe audio to subtitles", or needs to generate SRT subtitle files from audio files (MP3, WAV, M4A, FLAC, etc.) with customizable character limits and timeline adjustments.
npx skills add https://github.com/dean9703111/ai-agent-skill-for-video-workflow --skill Audio to SRT Converter
This skill provides a Python-based workflow for converting audio files (MP3, WAV, M4A, FLAC, etc.) into SRT subtitle files with automatic speech recognition, customizable text formatting, and timeline optimization.
Convert audio files (MP3, WAV, M4A, FLAC, etc.) into properly formatted SRT subtitle files with:
origin.srtUse this skill when:
Before processing, validate:
Process the audio file using speech recognition:
Format transcribed text according to parameters:
Adjust subtitle timing:
Create final SRT file:
origin.srtThe main conversion script is located at scripts/audio_to_srt.py.
python scripts/audio_to_srt.py <audio_file> [--max-chars MAX_CHARS]
audio_file (required): Path to the input audio file (MP3, WAV, M4A, FLAC, etc.)--max-chars (optional): Maximum characters per subtitle line (default: 22, minimum: 4)See examples/usage_example.sh for complete usage examples.
The script requires the following Python packages:
openai-whisper - For speech recognitionpydub - For audio processingffmpeg - System dependency for audio handlingInstall with:
pip install openai-whisper pydub
brew install ffmpeg # macOS
The generated SRT file follows this format:
1
00:00:00,000 --> 00:00:03,500
這是第一行字幕
2
00:00:03,500 --> 00:00:07,200
這是第二行字幕
scripts/audio_to_srt.py - Main conversion script with environment validationscripts/check_environment.py - Standalone environment checkerexamples/usage_example.sh - Complete usage examples with different parametersTake dean9703111/audio to srt converter from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.
The instructions reference pip, brew.
Without those the skill loads but fails at the first command.