shang-zhu/violin

Open-source Video Translation Skill

What it solves

Violin is an open-source tool for translating videos into different languages while maintaining a natural feel. It automates the complex process of transcribing original speech, translating the text, generating a native-sounding voice-over, and syncing the new audio back into the video file.

How it works

Violin uses a pluggable pipeline of AI models to process video:

  1. Audio Extraction: Uses ffmpeg to pull audio from the video.
  2. Transcription: Employs Whisper Large v3 to create word-level timestamps and sentence segments.
  3. Translation: An LLM (DeepSeek V4 Pro by default) translates the segments based on a selected style profile.
  4. Speech Synthesis: A TTS engine (Cartesia Sonic 3 by default) generates the dubbed audio.
  5. Remuxing: ffmpeg aligns the video speed to the dubbed audio and encodes the final output MP4 with optional SRT subtitles.

Who it’s for

Content creators and developers who need to localize video content for global audiences across 33 target languages without manual dubbing services.

Highlights

  • Pluggable Stack: Easily switch between providers like Together AI, OpenAI, and ElevenLabs via a single YAML configuration.
  • Style Profiles: Six experimental profiles (standard, kids, academic, casual, storyteller, news) that adjust both translation tone and TTS delivery.
  • In-video Q&A: Allows users to ask questions about specific moments in the dubbed video using sampled frames and subtitles.
  • Natural-language Voice Picker: Uses an LLM to select the best voice from the catalog based on a user's description.
  • Flexible Deployment: Available as a CLI tool, a FastAPI web app, or a Claude Code skill.

Related

  • Project
  • Project
  • Project
  • Project