An open-source, local-first voice cloning and speech synthesis agent. Run high-fidelity neural flow-matching (F5-TTS) and real-time offline text-to-speech (Kokoro-82M) directly on your machine without cloud subscriptions, API keys, or usage fees.
| Feature | Engine | Hardware | Typical Speed |
|---|---|---|---|
| Zero-Shot Voice Cloning | F5-TTS Flow Matching | Apple Silicon (MPS) / NVIDIA (CUDA) | ~3-5s for 15s audio |
| Instant Offline Synthesis | Kokoro-82M ONNX | Any Mac / Windows PC (CPU / GPU) | < 0.8s (Realtime 15x+) |
| Word-Level Subtitle Sync | Faster-Whisper | Local CPU (int8) | < 1.0s |
| Studio Audio Mastering | FFmpeg Chain | CPU | Real-time |
Run the automated installer:
chmod +x setup_mac.sh
./setup_mac.shOr install manually in terminal:
python3 -m venv .venv
source .venv/bin/activate
pip install --upgrade pip
pip install torch torchaudio
pip install -r requirements.txtRun the installer:
setup_windows.batOr install manually:
python -m venv .venv
call .venv\Scripts\activate.bat
pip install torch torchaudio --index-url https://download.pytorch.org/whl/cu121
pip install -r requirements.txtProvide a 5–15 second clean audio clip (.wav) along with its reference transcript:
python clone.py \
--ref samples/reference_sample_1.wav \
--ref-text "This is an open source demonstration of voice cloning and synthesis running entirely on a local personal computer." \
--text "Welcome to the open-source voice cloning setup guide. We are running neural flow matching locally." \
--out output.wavGenerate high-quality speech offline with zero GPU overhead:
python synth_kokoro.py \
--voice af_bella \
--text "Real-time speech synthesis running completely offline on your device." \
--out instant.wavGenerate precise word-level JSON timestamps for captions and editing:
python align.py --audio output.wav --out words.jsonAI agents (such as autonomous CLI agents or background workers) can invoke this repository programmatically:
{
"tool": "voice_clone",
"command": "python clone.py --ref <audio_path> --ref-text <transcript> --text <target_script> --out <output_path>"
}Agents can check hardware availability before launching synthesis:
import torch
device = "cuda" if torch.cuda.is_available() else ("mps" if torch.backends.mps.is_available() else "cpu")
print(f"Agent using device: {device}")voice-clone-agent/
├── clone.py # Main F5-TTS neural flow-matching cloner
├── synth_kokoro.py # Ultra-fast Kokoro-82M offline synthesizer
├── align.py # Word-level timestamp extractor (Faster-Whisper)
├── setup_mac.sh # One-click automated macOS installer
├── setup_windows.bat # One-click automated Windows installer
├── requirements.txt # Dependency specification
├── samples/ # Royalty-free reference and demo audio files
│ ├── reference_sample_1.wav
│ ├── reference_sample_2.wav
│ ├── demo_cloned_output_1.wav
│ └── demo_cloned_output_2.wav
└── README.md
Open-source under the MIT License. Models are subject to their respective upstream licenses (Apache-2.0).