Deploying a self-hosted AI video clipper with Docker Compose takes roughly 10 to 15 minutes once your container runtime, FFmpeg volume mounts, and Whisper/LLM environment variables are aligned. Use the interactive .env and terminal generator above to build a tailored config for OpenShorts, SupoClip, AutoClip, or ClipsAI, then follow the hardware-specific setup steps below.
System Prerequisites Before You Run Docker Compose
Every self-hosted clipping stack executes four heavy tasks inside or alongside containers: audio extraction (FFmpeg), word-level speech recognition (faster-whisper or WhisperX), transcript moment ranking (Ollama or cloud LLM API), and 9:16 face-tracked video encoding. Verify these host requirements first:
- Disk space (20 GB+ free): Docker base images plus Python CUDA libraries,
MediaPipe/YOLOv8weights, andfaster-whispermodels (small~500 MB,medium~1.5 GB,large-v3~3.1 GB) consume 6–12 GB before storing source MP4s. - System RAM (8 GB minimum, 16 GB+ recommended): SupoClip runs four services (
Next.js,FastAPI,PostgreSQL,Redis) plus media workers; 16 GB RAM prevents Linux OOM-killer crashes during concurrent 1080p FFmpeg encodes. - GPU acceleration (optional but 5x–7x faster): On Ubuntu or Windows 11 WSL2 with an NVIDIA RTX card (8 GB+ VRAM), install the NVIDIA Container Toolkit (
nvidia-ctk) so containers see both CUDA cores (for Whisper) andh264_nvenc(for fast MP4 export).
# Verify Docker can access your NVIDIA GPU before launching a clipper stack:
docker run --rm --gpus all nvidia/cuda:12.4.1-base-ubuntu22.04 nvidia-smi
Connecting Dockerized Clippers to Local Ollama (100% Offline Mode)
The #1 setup mistake when building an air-gapped self-hosted AI video clipper is writing http://localhost:11434 inside a container's .env file. Inside a Docker container, localhost points to the container itself—not your host machine running Ollama.
- Expose Ollama to the local Docker bridge on your host: On Linux, set
OLLAMA_HOST=0.0.0.0:11434in Ollama's systemd environment so containers ondocker0can reach it; on macOS and Windows Docker Desktop, Ollama only needs to be running natively on the host. - Pull an instruction-tuned model with reliable JSON adherence: Moment-scoring prompts ask the LLM to return structured start/end timestamps and hook titles. Models with 8B–14B parameters (
ollama pull qwen2.5:14borollama pull llama3.1:8b) dramatically outperform tiny 1B–3B models at picking coherent clip boundaries without truncating mid-sentence. - Use the right bridge hostname in
.env:- macOS & Windows Docker Desktop: Use
http://host.docker.internal:11434/v1(OpenAI-compatible path for OpenShortsLLM_BASE_URLand AutoClip) orhttp://host.docker.internal:11434(native Ollama URL for SupoClip). - Linux Docker Engine: Add
extra_hosts: ["host.docker.internal:host-gateway"]todocker-compose.ymlor point directly tohttp://172.17.0.1:11434/v1.
- macOS & Windows Docker Desktop: Use
Project-by-Project Installation Walkthroughs
1. OpenShorts (mutonby/openshorts · Port 5175)
OpenShorts ships a unified Docker Compose setup under the MIT License. After cloning the repository and copying .env.example to .env, run docker compose up --build. Open http://localhost:5175 in your browser: you can paste a Gemini API key directly in the web dashboard settings (Google's free tier allows 1,500 requests/day) or set LLM_BASE_URL in .env to route moment selection through local Ollama or vLLM.
2. SupoClip (FujiwaraChoki/supoclip · Port 3107)
SupoClip orchestrates its Next.js studio, FastAPI backend, PostgreSQL database, and Redis queue via docker compose up -d --build. Before starting, edit .env to define at least one transcription backend (local Whisper or AssemblyAI Universal-2) and one LLM provider (Gemini, OpenAI, Anthropic, or Ollama). Once healthy, visit http://localhost:3107 to paste YouTube/Twitch/Kick URLs or upload local recordings. Remember to check our OpenShorts vs SupoClip Review regarding SupoClip's noncommercial/own-channel license rule.
3. AutoClip (zhouxiaoka/autoclip · Port 3000 & 8000)
AutoClip requires creating three host bind-mount folders (mkdir -p data logs uploads) after copying env.example to .env so container workers have write permissions for downloaded VODs and rendered vertical clips. Start with docker compose up -d --build, then open http://localhost:3000 for the web UI or http://localhost:8000/docs to inspect the FastAPI Swagger endpoints.
4. ClipsAI Python SDK (ClipsAI/clipsai · Virtualenv)
If you prefer a scriptable Python workflow without Docker containers, install system packages ffmpeg and libmagic (brew install ffmpeg libmagic on macOS or sudo apt install ffmpeg libmagic1 on Ubuntu), create a clean Python 3.10–3.11 venv, and install clipsai alongside whisperx. Create a free read token on Hugging Face and accept the pyannote/speaker-diarization-3.1 model conditions so clipsai.resize() can diarize speakers for 9:16 cropping.
Troubleshooting Common Self-Hosting Errors
- Apple Silicon (M1/M2/M3/M4) slow Docker transcription: Docker Desktop on macOS runs Linux containers inside a lightweight VM that cannot access Apple Metal GPUs. For 3x faster performance on Mac, run Ollama natively on macOS and either run the Python worker natively (
venv) or usesmall/mediumint8 Whisper inside Docker. yt-dlpHTTP 403 or Sign-In Required on YouTube links: Cloud/datacenter VPS IPs are frequently rate-limited by YouTube. Either self-host on your residential home connection, pass fresh browser cookies into the container'syt-dlpconfig, or download the MP4 locally first and use local file upload.- Subtitles rendering as rectangular tofu boxes (
□□□): Minimal Alpine/Debian container images sometimes lack CJK or emoji fonts when clipping Chinese, Japanese, Korean, or emoji-styled captions. Installfonts-noto-cjkandfonts-noto-color-emojiinside the worker Dockerfile or mount your host font directory.
Need to compare feature trade-offs before building images? Return to the Open Source AI Video Clipper Comparison or inspect the Open Source OpusClip Alternatives Matrix.
No hardware notes posted on this page yet—be the first to share what GPU/CPU and Whisper model you run.