Installation¶
AbstractVoice has a lightweight remote-first base install plus explicit local extras:
- Python:
>=3.9(seepyproject.toml) - Base install: OpenAI/OpenAI-compatible TTS/STT/profile/clone adapters and AbstractCore plugin discovery
- Platform/local extras: Piper TTS, Supertonic 3 ONNX TTS, faster-whisper STT, audio I/O, AEC where supported, and local cloning/TTS engines
One-line install¶
No admin rights and no Python needed: the installer gets uv when it is
missing, Python 3.12 through uv, and installs AbstractVoice alone (no gateway, no services) in its
own environment, with the abstractvoice and abstractvoice-prefetch commands in ~/.local/bin.
# macOS / Linux
curl -LsSf https://abstractframework.ai/voice/install.sh | sh
# Windows 10 / 11
powershell -ExecutionPolicy ByPass -c "irm https://abstractframework.ai/voice/install.ps1 | iex"
# With pip, in your own Python environment
pip install "abstractvoice[apple]" # Apple Silicon Mac
pip install "abstractvoice[gpu]" # NVIDIA or AMD GPU
It picks the profile from the machine (--profile chooses another one):
| Machine | Profile | What it installs |
|---|---|---|
| Apple Silicon Mac, macOS 14 or later | apple |
abstractvoice[apple]: the MLX engines on the Apple GPU (echo cancellation is left out: it has no macOS wheel, and the installer never starts a compiler) |
NVIDIA card (nvidia-smi -L works) or, on Linux, ROCm (rocminfo) |
gpu |
abstractvoice[gpu]; with NVIDIA, also ONNX Runtime's CUDA build (below); on Windows, PyTorch's CUDA build for the driver (--torch-backend cu130 or cu126) |
| Anything else (an Intel Mac, an older macOS, no GPU) | light |
processor only: the base package with Supertonic speech, faster-whisper transcription and speaker/microphone I/O (Windows on ARM: Supertonic only) |
--profile gpu on a machine without a card installs the same GPU stack, whose engines then run on
the processor. Every step prints its command, and so does the summary: the version, the profile,
where the commands are, the CUDA step's result and what to try first:
abstractvoice-prefetch --supertonic # the Supertonic voice, once (about 380 MB)
abstractvoice --tts-engine supertonic --prompt "Hello from AbstractVoice." --output hello.wav
| macOS / Linux | Windows | |
|---|---|---|
--print (or --dry-run, -n) |
-Print (or -DryRun) |
show the plan and every command; change nothing |
--profile auto\|light\|apple\|gpu |
-Profile auto\|light\|gpu |
the profile (default auto; AV_PROFILE) |
--pin VERSION\|latest |
-Pin VERSION\|latest |
the version: by default the release the script ships with, latest = the newest on PyPI (AV_PIN) |
--from PATH |
-From PATH |
install from a checkout, sdist or wheel, for testing (AV_FROM) |
--no-modify-path |
-NoModifyPath |
do not run uv tool update-shell |
-v, --verbose |
-Verbose |
show the full output of every command |
Options go after sh -s -- (curl -LsSf https://abstractframework.ai/voice/install.sh | sh -s -- --print)
or into a script block on Windows
(& ([scriptblock]::Create((irm https://abstractframework.ai/voice/install.ps1))) -Print).
Upgrade: run the same line again. It finds the install, says
AbstractVoice 0.20.1 found: upgrading to AbstractVoice 0.21.0 (or already up to date), keeps the profile
unless --profile says otherwise, ends with abstractvoice 0.20.1 -> 0.21.0, runs the CUDA step
again, and reinstalls in place when the command no longer starts. Remove it with
uv tool uninstall abstractvoice. AbstractFramework's installer already includes AbstractVoice and
its commands: on such a machine this script stops and says so, and nothing is changed. A standalone
AbstractVoice beside the framework's gateway tool is not supported (there is no --force: both
would own the same commands); upgrade AbstractFramework instead.
The CUDA step (NVIDIA): with an NVIDIA driver 580 or newer and compute capability 7.5 or newer
(ONNX Runtime's CUDA build is a CUDA 13 build), the installer runs Supertonic and Piper on the
card. ONNX Runtime's CPU build (onnxruntime, which piper-tts and faster-whisper require) and its
CUDA build (onnxruntime-gpu) write the same files, and installed together the CPU build's won
(measured on Ubuntu 24.04 with a Quadro RTX 5000), so the step is two commands:
uv tool install --python 3.12 "abstractvoice[gpu,onnx-cuda]==<version>"
uv pip install --python "$(uv tool dir)/abstractvoice/bin/python" --no-deps \
--reinstall-package onnxruntime-gpu "onnxruntime-gpu==<the version just installed>"
The second one rewrites the CUDA build's files alone, after everything else; then the installer
checks that import onnxruntime; onnxruntime.get_available_providers() lists
CUDAExecutionProvider, which shows the CUDA build is in place; whether its provider loads on the
card is what Supertonic and Piper report at first use (execution_device(), get_info()). With an
older driver, no NVIDIA card, or an nvidia-smi that does not answer (driver not loaded), it says
why and Supertonic and Piper run on the processor. If the CPU build ever comes back on top (Supertonic's
reason says so), running the installer again repairs it.
Install¶
pip install abstractvoice
This is the remote/plugin-friendly install. VoiceManager() defaults to OpenAI
hosted audio; set OPENAI_API_KEY or pass remote_api_key=.... The CLI/web
examples are install-aware: with the plain install they start on OpenAI, while
abstractvoice[all-apple] and abstractvoice[all-gpu] start on Supertonic by
default. For local desktop/REPL voice and local cloning engines, prefer the
profile for your machine:
pip install "abstractvoice[apple]" # Apple Silicon / native macOS
pip install "abstractvoice[gpu]" # NVIDIA/AMD GPU-oriented local stack
pip install "abstractvoice[all-apple]" # Apple stack + local web example
pip install "abstractvoice[all-gpu]" # GPU stack + local web example
For OpenAI-compatible HTTP audio endpoints, install AbstractVoice beside AbstractCore Server and configure a remote provider or install local voice runtimes explicitly:
pip install "abstractcore[server]" abstractvoice
OPENAI_API_KEY=... python -m abstractcore.server.app
AbstractCore provides /v1/audio/speech and /v1/audio/transcriptions;
AbstractVoice is discovered as the voice/audio capability backend.
Optional extras¶
pip install "abstractvoice[apple]" # Apple Silicon local stack: Piper, Supertonic, faster-whisper + mlx-whisper (Apple GPU), AEC, cloning/TTS engines
pip install "abstractvoice[gpu]" # GPU local stack: Piper, Supertonic, faster-whisper, cloning/TTS engines (AEC on macOS and Windows)
pip install "abstractvoice[all-apple]" # Apple stack + local FastAPI browser example
pip install "abstractvoice[all-gpu]" # GPU stack + local FastAPI browser example
pip install "abstractvoice[piper]" # Local Piper TTS only
pip install "abstractvoice[supertonic]" # Local Supertonic 3 ONNX TTS only
pip install "abstractvoice[stt]" # Local faster-whisper STT (keeps PyAV below 19, which faster-whisper 1.2.1 needs)
pip install "abstractvoice[stt-mlx]" # mlx-whisper: Whisper on the Apple GPU (Apple Silicon only)
pip install "abstractvoice[stt-hf]" # Local Transformers/Hugging Face ASR (e.g. openai/whisper-large-v3, Qwen/Qwen3-ASR-1.7B)
pip install "abstractvoice[audio-io]" # Microphone/playback/VAD dependencies
pip install "abstractvoice[cloning]" # explicit OpenF5-based cloning (heavy; Python 3.10+)
pip install "abstractvoice[chroma]" # Chroma-4B (very heavy; torch/transformers)
pip install "abstractvoice[audiodit]" # LongCat-AudioDiT (heavy; torch/transformers)
pip install "abstractvoice[omnivoice]" # recommended/default local cloning + OmniVoice TTS/design (very heavy; Python 3.10+)
pip install "abstractvoice[qwen3-tts]" # Qwen3-TTS: preset speakers, cloning, voice design (heavy; Python 3.10+; MLX on Apple silicon, PyTorch elsewhere)
pip install "abstractvoice[openai]" # Hosted OpenAI intent extra (no extra deps today)
pip install "abstractvoice[openai-compatible]" # Generic compatible provider intent extra
pip install "abstractvoice[aec]" # Optional echo cancellation (true barge-in)
pip install "abstractvoice[onnx-cuda]" # After a profile, on Linux/Windows with an NVIDIA card: Supertonic and Piper on the GPU
pip install "abstractvoice[audio-fx]" # Speed change without pitch change (librosa)
pip install "abstractvoice[web]" # Local FastAPI browser example
pip install "abstractvoice[web,supertonic]" # Web example + Supertonic dependency
pip install "abstractvoice[web,omnivoice]" # Web example + OmniVoice dependency
abstractvoice[web] intentionally stays lightweight: it installs the browser
server, but no local engines. Compose it with abstractvoice[all-apple],
abstractvoice[all-gpu], or granular engine extras such as
abstractvoice[supertonic] / abstractvoice[omnivoice] for smaller installs.
Remote OpenAI-compatible audio:
# OpenAI hosted audio
export OPENAI_API_KEY=...
python - <<'PY'
from abstractvoice import VoiceManager
vm = VoiceManager(tts_engine="openai", stt_engine="openai")
vm.set_profile("nova") # OpenAI voice id
wav = vm.speak_to_bytes("Hello from remote TTS.", format="wav")
PY
# Any OpenAI-compatible /v1 server, including AbstractCore Server
export OPENAI_BASE_URL=http://localhost:8000/v1
python - <<'PY'
from abstractvoice import VoiceManager
vm = VoiceManager(tts_engine="openai-compatible", stt_engine="openai-compatible")
print([p.profile_id for p in vm.get_profiles()])
wav = vm.speak_to_bytes("Hello through a compatible endpoint.", format="wav")
PY
Remote cloning is provider-specific. For compatible services, configure
OPENAI_BASE_URL and use cloning_engine="openai-compatible";
the default custom clone route is POST /voice/clone and should return
{"voice_id": "..."} or {"id": "..."}.
For cloning_engine="openai", OpenAI custom voice creation is org-gated and
requires explicit consent configuration such as
ABSTRACTVOICE_OPENAI_VOICE_CONSENT_ID.
Remote profile/voice listing is part of the AbstractVoice-compatible extension
contract. Compatible servers can expose GET /v1/audio/voices; the adapter
calls it as GET /audio/voices relative to remote_base_url, parses
profiles, voices, cloned_voices, or OpenAI-style data, and exposes the
ids through VoiceManager.get_profiles(). Static ids can be configured with
ABSTRACTVOICE_REMOTE_TTS_VOICES.
Python-version notes:
- Python 3.9 supports the lightweight base, local Piper/faster-whisper extras, local Supertonic 3 ONNX TTS, the web example, and AudioDiT TTS/prompt-audio cloning.
- Supertonic is the recommended local base TTS path. OmniVoice is the recommended/default local cloning backend.
- OpenF5/F5-TTS, Chroma, and OmniVoice require Python 3.10+ because their upstream runtimes do.
- The platform profiles (
apple,gpu,all-apple,all-gpu) include OpenF5/F5-TTS only on Python 3.11+, because on 3.10f5-ttspinsnumpy<=1.26.4and would block NumPy 2 stacks (AbstractVision, MLX). On 3.10, installabstractvoice[cloning]separately if you need F5-TTS. - AEC requires Python 3.11+ because
aec-audio-processingdeclares that floor. The platform profiles include it on macOS and Windows only: on Linux the package has no wheel and its source build does not succeed on x86_64, so a Linux server installs the profile without echo cancellation (a server has no microphone to cancel for).
Note (Qwen3-TTS on PyTorch): the platform profiles and abstractvoice[qwen3-tts] keep
transformers below 5.21. Transformers 5.21 split its Mimi codec into encoder and decoder
sub-models, and the Qwen3-TTS speech tokenizer that AbstractVoice ships (a subclass of that codec)
does not construct on it. The pin lifts when the tokenizer is ported.
Note (OmniVoice): OmniVoice uses the torch/torchaudio/torchvision stack. If you
already have an incompatible torchvision installed (common after changing
torch-backed extras), you may see import errors like:
RuntimeError: operator torchvision::nms does not exist
Fix by installing a torchvision build that matches your torch version. For the torch 2.8 family this is typically:
python -m pip install --upgrade --force-reinstall "torchvision==0.23.*"
Offline-first model downloads¶
The REPL (python -m abstractvoice cli) runs with allow_downloads=False and will not
download weights implicitly. Prefetch explicitly:
# Piper voice model (per language). Cache: ~/.piper/models
python -m abstractvoice download --piper en
# Supertonic 3 ONNX TTS (weights + 10 built-in voice styles).
# Cache: ~/.cache/abstractvoice/supertonic-3
python -m abstractvoice download --supertonic
# STT model (faster-whisper). Cache: ~/.cache/huggingface by default
python -m abstractvoice download --stt small
# Voice cloning artifacts (optional; require extras)
pip install "abstractvoice[cloning]" # for --openf5 (Python 3.10+)
python -m abstractvoice download --openf5
pip install "abstractvoice[chroma]" # for --chroma (GPU-heavy)
python -m abstractvoice download --chroma
pip install "abstractvoice[audiodit]" # for --audiodit (LongCat-AudioDiT-1B)
python -m abstractvoice download --audiodit
pip install "abstractvoice[omnivoice]" # for --omnivoice (OmniVoice)
python -m abstractvoice download --omnivoice
The same operations are available via the convenience entrypoint:
abstractvoice-prefetch --piper en
abstractvoice-prefetch --supertonic
abstractvoice-prefetch --stt small
abstractvoice-prefetch --openf5
abstractvoice-prefetch --chroma
abstractvoice-prefetch --audiodit
abstractvoice-prefetch --omnivoice
Audio device setup (common issues)¶
AbstractVoice uses PortAudio via sounddevice.
macOS¶
- Ensure your terminal/IDE has Microphone permission (System Settings → Privacy & Security → Microphone).
- If audio devices fail to open, PortAudio can be installed with:
brew install portaudio
Linux (Debian/Ubuntu)¶
sudo apt-get update
sudo apt-get install -y portaudio19-dev
Windows¶
Usually works out of the box. If device access fails, check OS microphone permissions and installed audio drivers.
AEC (aec-audio-processing) has Windows wheels for Python 3.11 to 3.13.
Linux¶
abstractvoice[gpu] and [all-gpu] install without echo cancellation on Linux (see the AEC note
above); everything else in the profile has Linux wheels, so a clean Ubuntu host needs no compiler.
NVIDIA GPUs (Linux and Windows)¶
The torch engines (Qwen3-TTS, OmniVoice, AudioDiT, F5, Transformers ASR) pick the card's native
dtype: bfloat16 on compute capability 8.0 (Ampere) and newer, float32 on older cards such as
Turing, where bfloat16 is emulated and slower; each engine's runtime_info() reports dtype and
dtype_reason. Qwen3-TTS on CUDA replays its codebook predictor as a CUDA graph and speaks faster
than real time on a mid-range card (Quadro RTX 5000: 0.8 of real time at float32, model warm).
Supertonic and Piper run on ONNX Runtime. Its CUDA build (onnxruntime-gpu) and its CPU build
(onnxruntime, which piper-tts and faster-whisper require) are two packages that write the same
files, so the profiles install the CPU build and the card is a second, explicit step:
pip install "abstractvoice[gpu]"
pip install "abstractvoice[onnx-cuda]" # onnxruntime-gpu + nvidia-curand; empty on macOS
The second command writes the CUDA build over the CPU one. Supertonic then requests the CUDA
provider first (then the CPU) and Piper enables CUDA when the provider exists; both preload the
pip-installed CUDA libraries before opening a session and report the providers the session runs
on (execution_device() / get_info()). If the CPU build is installed on top later, the CUDA
provider disappears and Supertonic's reason names the repair: pip install --force-reinstall
--no-deps onnxruntime-gpu. Measured on the Quadro RTX 5000, 8 s of speech: Supertonic 0.85 s then
0.09 s warm on CUDA against 1.6 s on the CPU; Piper's model is small enough that CUDA and the CPU
are within a few tenths of a second.
On Linux and Windows, abstractvoice[gpu] and [all-gpu] also install NVIDIA's CUDA 12 cuBLAS and
runtime wheels (nvidia-cublas-cu12, nvidia-cuda-runtime-cu12), and on Windows cuDNN 9
(nvidia-cudnn-cu12). faster-whisper's CTranslate2 loads CUDA 12 cuBLAS (libcublas.so.12 /
cublas64_12.dll) and runs the Whisper encoder's convolutions through cuDNN 9; a CUDA 13 PyTorch
build carries no CUDA 12 cuBLAS. On Linux, cuDNN 9 comes from torch's own CUDA wheel (its
nvidia-cudnn-cu12 or -cu13 dependency, in site-packages/nvidia/cudnn); AbstractVoice no longer
adds a second cuDNN wheel there, because two cuDNN versions in that one folder made every CUDA
convolution fail (CUDNN_STATUS_SUBLIBRARY_VERSION_MISMATCH, fixed in 0.21.1). Before
faster-whisper runs, AbstractVoice preloads those libraries on Linux and adds their folders to the
DLL search on Windows. It picks CUDA only when CTranslate2 sees a CUDA GPU and both
libraries load, with the best compute type the GPU supports (int8_float16 on most cards);
otherwise it runs on the CPU and records why. A CUDA failure while loading or at the first
transcription falls back to the CPU with the reason recorded. ABSTRACTVOICE_WHISPER_DEVICE=cpu|cuda
is a request: cuda without a usable GPU is refused with a sentence. See
Where Whisper runs.
Check Whisper on an NVIDIA machine (after pip install "abstractvoice[gpu]"):
python -c "from abstractvoice.compute import resolve_faster_whisper_device as r; print(r().to_dict())"
# {'device': 'cuda', 'compute_type': 'int8_float16', 'reason': None, 'requested': 'auto', 'refused': False}
python - <<'PY'
from abstractvoice.adapters.stt_faster_whisper import FasterWhisperAdapter
import numpy as np
a = FasterWhisperAdapter("large-v3", device="auto", compute_type="auto")
print(a.execution_device())
print(a.transcribe_from_array(np.zeros(16000, dtype=np.float32), 16000, language="en"))
print(a.execution_device()) # still {'device': 'cuda', ...}: the first GPU run did not fall back
PY
nvidia-smi # the Python process holds GPU memory while the model is loaded
Whisper on the Apple GPU¶
CTranslate2, faster-whisper's engine, has no Apple GPU backend, so on a Mac faster-whisper runs on
the CPU. The mlx-whisper engine runs the same Whisper models on the Apple GPU through MLX
(mlx-whisper, from abstractvoice[apple] or abstractvoice[stt-mlx]; Apple Silicon only). Select
it with VoiceManager(stt_engine="mlx-whisper", whisper_model="large-v3"), or as the
mlx-whisper provider of an AbstractCore speech-input route. Weights come from the
mlx-community repos in the Hugging Face cache (large-v3: mlx-community/whisper-large-v3-mlx,
3.1 GB; large-v3-turbo: mlx-community/whisper-large-v3-turbo, 1.6 GB).
Measured on an M5 Max, one 17-second English clip, warm model:
| Engine | Device | large-v3 | large-v3-turbo |
|---|---|---|---|
| faster-whisper (int8, beam 5) | CPU | about 20 s | about 6 s |
| mlx-whisper (float16, greedy) | Apple GPU | about 1.4 s | about 0.25 s |
Qwen3-TTS on the Apple GPU¶
On Apple silicon the qwen3-tts, apple, all-apple, gpu and all-gpu extras install mlx
and tokenizers, and Qwen3-TTS runs on the Apple GPU through MLX (ADR 0008): the same Qwen
checkpoints from the same Hugging Face cache, loaded strictly from the original bf16 safetensors
and quantized to 8-bit as they load (ABSTRACTVOICE_QWEN3_TTS_MLX_QUANTIZATION=bf16|8bit|4bit
chooses otherwise). Nothing changes in how you select the engine; runtime_info()["backend"]
reports mlx. Elsewhere, or with ABSTRACTVOICE_QWEN3_TTS_BACKEND=torch, the PyTorch path runs
as before. Asking for mlx on a machine where it cannot run fails with a plain error. Measured
figures are in docs/benchmark.md and
Qwen backends.
Troubleshooting¶
- Piper model not available locally: run
python -m abstractvoice download --piper <lang>. - Supertonic model not available locally: run
python -m abstractvoice download --supertonic. - Cloning runtime not ready: for the default OmniVoice cloning path, run
/cloning_statusthen/cloning_download omnivoicein the REPL (or usepython -m abstractvoice download --omnivoice). Use/cloning_download f5_tts|chroma|audioditonly when selecting those engines explicitly. - LLM API not reachable (REPL only): the default provider preset is Ollama at
http://localhost:11434(OpenAI-compatiblePOST /v1/chat/completions). Start it withollama serve, or point the REPL at a different--provider/--apibase URL. - Sanity-check your environment: run
python -m abstractvoice check-deps(orabstractvoice check-deps) to print a dependency report.
See also: docs/faq.md.