mirror of
https://github.com/agent0ai/agent-zero.git
synced 2026-10-14 03:38:53 +00:00
Offer Paradee Heart alongside Kokoro voices in the existing bundled TTS plugin. Default unconfigured settings to Paradee while preserving saved Kokoro voices, blends, speed and activation choices. Switching engines replaces the voice selection without a separate plugin or startup dialog. Add lazy CPU ONNX synthesis with cached, pinned model assets and split long input without dropping phonemes. Make status and preload follow the selected engine, and present both engines through the Local TTS UI. Prepare Paradee dependencies in hooks.py on plugin install/update, enabled-plugin startup and re-enable. Reuse installed packages, preserve browser fallback on setup failure and keep requirements.txt unchanged. Update plugin documentation and regression coverage. Validation: 44 focused tests passed in both host and Docker framework runtimes. Live synthesis and voice-picker switching passed on localhost:32081. git diff --check passed. Fresh-image builds and actual missing-package installation were not tested.
1.5 KiB
1.5 KiB
Local TTS (Kokoro & Paradee)
Built-in local speech synthesis, retaining the _kokoro_tts plugin identity.
Behavior
- Defaults to Paradee-8M v1.0, a small CPU model with one American English Heart voice.
- Select Paradee · Heart in the voice picker or choose a Kokoro voice. Paradee cannot be blended; selecting it replaces the current Kokoro selection.
- Kokoro supports single voices, comma-separated equal blends, and optional in-memory weighted blends.
- Existing saved voices, blends, speed, and enable/disable preferences are preserved. No startup choice dialog is shown.
- Keeps browser-native
speechSynthesisas the fallback path when disabled or synthesis fails. - Prepares Paradee's ONNX Runtime and English phonemizer dependencies through
hooks.pyon installation, updates, startup, and re-enable. Already-installed dependencies are reused; speech synthesis never installs packages. - Uses Kokoro's existing voice-pack cache and does not create persistent blend files. Paradee downloads its pinned ONNX model and vocabulary on first use into
usr/plugins/_kokoro_tts/paradee/; later use works offline.
Config
voice:paradee(default), a Kokoro voice identifier, or a comma-separated Kokoro blendvoice_weights: optional mapping of voice identifiers to positive weights; when present, it defines the active blendspeed: playback speed multiplier for either model (default1.1)
Routes
POST /api/plugins/_kokoro_tts/synthesizePOST /api/plugins/_kokoro_tts/status