Sign inSign up

jonesckevin/whisper-webapp

By jonesckevin

Updated about 2 months ago

Image
0

769

jonesckevin/whisper-webapp repository overview

Whisper Transcription Tool

Whisper Logo

DockerHub - Jonesckevin

AI-powered audio/video transcription using OpenAI Whisper with GPU acceleration. And it's a WebApp in Docker for all your HALp needs!

Whisper WebApp Screenshot Whisper WebApp Screenshot Whisper WebApp Screenshot

Quick Start

Choose Your Version:

  • Local CLI: .\run_whisper.ps1 (Windows) or python src/audio_to_text4.py input.mp4
  • Docker Web: .\start-docker.ps1 → option 1 → http://localhost:8080
  • Docker CLI: .\start-docker.ps1 → option 2 (batch processing)
  • DockerHub:
# CPU Version
docker run -d \
  --name whisper-webapp \
  -p 8000:5000 \
  -v "$(pwd)/data/uploads:/data/uploads" \
  -v "$(pwd)/data:/data/db" \
  -v "$(pwd)/data/models:/root/.cache/whisper" \
  -e NVIDIA_VISIBLE_DEVICES=all \
  -e CUDA_VISIBLE_DEVICES=0 \
  -e FLASK_ENV=production \
  -e MAX_UPLOAD_SIZE_GB=5 \
  -e PRELOAD_WHISPER_MODELS=false \
  --gpus '"device=0"' \
  --restart unless-stopped \
  jonesckevin/whisper-webapp:gpu
# GPU Version
docker run -d \
  --name whisper-webapp \
  -p 8000:5000 \
  -v "$(pwd)/data/uploads:/data/uploads" \
  -v "$(pwd)/data:/data/db" \
  -v "$(pwd)/data/models:/root/.cache/whisper" \
  -e NVIDIA_VISIBLE_DEVICES=all \
  -e CUDA_VISIBLE_DEVICES=0 \
  -e FLASK_ENV=production \
  -e MAX_UPLOAD_SIZE_GB=5 \
  -e PRELOAD_WHISPER_MODELS=false \
  --gpus '"device=0"' \
  --restart unless-stopped \
  jonesckevin/whisper-webapp:gpu
TaskCommand
Transcribe one filepython src/audio_to_text4.py video.mp4 --srt
Transcribe with large modelpython src/audio_to_text4.py audio.mp3 -m large --srt
Batch transcribe allpython src/audio_to_text4.py --transcribe-all --batch-model base
Spanish transcriptionpython src/audio_to_text4.py audio.mp3 --language es
Extract audio onlypython src/audio_to_text4.py video.mp4 --convert-only --audio-format mp3
Web UI (multi-user).\start-docker.ps1 → select 1 → http://localhost:8080
Docker batch process.\start-docker.ps1 → select 2

Docker Web Features

Access: http://localhost:8080 after running .\start-docker.ps1 → option 1

  • 📤 Upload: Drag & drop files (max 5GB via web, unlimited via network share)
  • 📋 Queue: View pending jobs, reorder priority with ↑↓ arrows
  • 📊 Progress: Real-time transcription progress with percentage
  • 🔄 Refresh: Single unified refresh button updates all data
  • 📁 Results: View and download transcripts/SRT stored in database
  • 🗒️ Logs: View application logs (last 1000 entries)

Persistent Storage:

  • data/uploads/ - Input audio/video files
  • data/sqlite.db - SQLite database containing:
    • Job queue (current, queued, completed jobs)
    • Transcription results (transcript text and SRT)
    • Application logs (last 1000 entries)
  • data/models/ - Cached Whisper models

Command Reference

Combined Command Table
Switch/ArgumentPowerShell (run_whisper.ps1)Linux/Mac (start-docker.sh)Python (audio_to_text4.py)Description
(no args)✅ Interactive menu✅ Interactive menu❌ Required: input fileLaunch interactive mode
input.mp4N/AN/Ainput.mp4Input audio/video file path
-o output.txtN/AN/A-o output.txtSpecify output file path
--srt✅ Prompted in menuN/A--srtGenerate SRT subtitle file
-m MODEL✅ Prompted in menuN/A-m largeSelect model (tiny/base/small/medium/large)
--language LANGN/AN/A--language esForce specific language (auto-detect by default)
--transcribe-allN/AN/A--transcribe-allBatch process all files in holding/audio/
--batch-model MODELN/AN/A--batch-model baseModel for batch transcription
--convert-onlyN/AN/A--convert-onlyExtract audio without transcribing
--audio-format mp3N/AN/A--audio-format mp3Audio format for conversion
--organizeN/AN/A--organizeSort files into audio/video folders
-Mode webN/AN/AN/A(Docker only) Launch web UI
-Mode cliN/AN/AN/A(Docker only) Batch CLI mode
-Mode buildN/AN/AN/A(Docker only) Build image without running
-Model mediumN/AN/AN/A(Docker only) Skip model selection prompt
Environment Variables (Docker)
VariableExampleDescription
NVIDIA_VISIBLE_DEVICESall or 0Specify which GPUs to use (all or specific IDs)
CUDA_VISIBLE_DEVICES0Specify which CUDA devices to use
FLASK_ENVproductionSet Flask environment (production/development)
MAX_UPLOAD_SIZE_GB5Max upload size in GB for web UI
PRELOAD_WHISPER_MODELStruePreload all Whisper models on startup (true/false)
PowerShell Launcher (run_whisper.ps1)
UsageDescription
.\run_whisper.ps1Interactive menu for model selection, SRT generation, and transcription
Auto-setupCreates virtual environment, installs dependencies, checks GPU/CUDA
GPU detectionOffers to install PyTorch with CUDA support if GPU detected
Docker Launcher (start-docker.ps1 / start-docker.sh)
OptionCommandDescription
Web ModeSelect 1 from menuMulti-user web UI at http://localhost:8080
CLI ModeSelect 2 from menuBatch process files from data/uploads/
Build OnlySelect 3 from menuBuild Docker image without running
StopSelect 4 from menuStop and remove containers
Direct Web.\start-docker.ps1 -Mode webLaunch web mode without menu
Direct CLI.\start-docker.ps1 -Mode cli -Model mediumLaunch CLI with specific model
Python Script (audio_to_text4.py)
SwitchExampleDescription
(required)python src/audio_to_text4.py input.mp4Input audio/video file
-o, --output-o transcript.txtSpecify output file path
-m, --model-m largeWhisper model (tiny/base/small/medium/large)
--srt--srtGenerate SRT subtitle file alongside transcript
--language--language esForce language (en, es, fr, de, etc.)
--transcribe-all--transcribe-all --batch-model baseBatch process all files in holding/audio/
--batch-model--batch-model mediumModel to use for batch processing
--convert-only--convert-only --audio-format mp3Extract audio without transcribing
--audio-format--audio-format wavAudio format for extraction (mp3/wav/flac)
--organize--organizeSort files in holding/ into audio/video folders

Model Selection

ModelVRAMSpeedQualityUse Case
tiny~1GB⚡⚡⚡⚡⚡Quick drafts, testing
base~1.5GB⚡⚡⚡⚡⭐⭐Recommended
small~2.5GB⚡⚡⚡⭐⭐⭐Better accuracy
medium~4GB⚡⚡⭐⭐⭐⭐High quality
large~5.5GB⭐⭐⭐⭐⭐Best quality

GPU Acceleration: 15-30x faster with NVIDIA GPU (auto-detected)

References: OpenAI Whisper Models | Model Card


File Support

Audio: MP3, WAV, FLAC, AAC, M4A, OGG, AMR
Video: MP4, AVI, MOV, MKV, FLV, WMV
Output: .txt transcripts with timestamps, .srt subtitles (optional)


Support

  • GPU Status: Check web UI footer or run nvidia-smi
  • Docker Logs: docker logs whisper-webapp
  • Issues: Report with error messages and GPU model info

Tag summary

Content type

Image

Digest

sha256:26fa1ef84

Size

8.9 GB

Last updated

about 2 months ago

docker pull jonesckevin/whisper-webapp