feat(tts): xAI Custom Voices — voice cloning support#18776
Conversation
🚨 CRITICAL Supply Chain Risk DetectedThis PR contains a pattern that has been used in real supply chain attacks. A maintainer must review the flagged code carefully before merging. 🚨 CRITICAL: Install-hook file added or modifiedThese files can execute code during package installation or interpreter startup. Files: Scanner only fires on high-signal indicators: .pth files, base64+exec/eval combos, subprocess with encoded commands, or install-hook files. Low-signal warnings were removed intentionally — if you're seeing this comment, the finding is worth inspecting. |
717f101 to
2345726
Compare
🚨 CRITICAL Supply Chain Risk DetectedThis PR contains a pattern that has been used in real supply chain attacks. A maintainer must review the flagged code carefully before merging. 🚨 CRITICAL: Install-hook file added or modifiedThese files can execute code during package installation or interpreter startup. Files: Scanner only fires on high-signal indicators: .pth files, base64+exec/eval combos, subprocess with encoded commands, or install-hook files. Low-signal warnings were removed intentionally — if you're seeing this comment, the finding is worth inspecting. |
Point users to xAI's custom voices feature — clone your voice in the console, paste the voice_id into tts.xai.voice_id. No code changes needed; the existing TTS pipeline already handles arbitrary voice IDs. - config.py: link to xAI custom voices docs in voice_id comment - setup.py: prompt accepts custom voice IDs during xAI TTS setup - tts.md: short section linking to xAI console and docs
2345726 to
bae5964
Compare
🚨 CRITICAL Supply Chain Risk DetectedThis PR contains a pattern that has been used in real supply chain attacks. A maintainer must review the flagged code carefully before merging. 🚨 CRITICAL: Install-hook file added or modifiedThese files can execute code during package installation or interpreter startup. Files: Scanner only fires on high-signal indicators: .pth files, base64+exec/eval combos, subprocess with encoded commands, or install-hook files. Low-signal warnings were removed intentionally — if you're seeing this comment, the finding is worth inspecting. |
Point users to xAI's custom voices feature — clone your voice in the console, paste the voice_id into tts.xai.voice_id. No code changes needed; the existing TTS pipeline already handles arbitrary voice IDs. - config.py: link to xAI custom voices docs in voice_id comment - setup.py: prompt accepts custom voice IDs during xAI TTS setup - tts.md: short section linking to xAI console and docs
Point users to xAI's custom voices feature — clone your voice in the console, paste the voice_id into tts.xai.voice_id. No code changes needed; the existing TTS pipeline already handles arbitrary voice IDs. - config.py: link to xAI custom voices docs in voice_id comment - setup.py: prompt accepts custom voice IDs during xAI TTS setup - tts.md: short section linking to xAI console and docs
Point users to xAI's custom voices feature — clone your voice in the console, paste the voice_id into tts.xai.voice_id. No code changes needed; the existing TTS pipeline already handles arbitrary voice IDs. - config.py: link to xAI custom voices docs in voice_id comment - setup.py: prompt accepts custom voice IDs during xAI TTS setup - tts.md: short section linking to xAI console and docs
Point users to xAI's custom voices feature — clone your voice in the console, paste the voice_id into tts.xai.voice_id. No code changes needed; the existing TTS pipeline already handles arbitrary voice IDs. - config.py: link to xAI custom voices docs in voice_id comment - setup.py: prompt accepts custom voice IDs during xAI TTS setup - tts.md: short section linking to xAI console and docs
Point users to xAI's custom voices feature — clone your voice in the console, paste the voice_id into tts.xai.voice_id. No code changes needed; the existing TTS pipeline already handles arbitrary voice IDs. - config.py: link to xAI custom voices docs in voice_id comment - setup.py: prompt accepts custom voice IDs during xAI TTS setup - tts.md: short section linking to xAI console and docs
Summary
Add support for xAI Custom Voices — clone your voice from a 30-120s recording and use it with Hermes TTS.
Custom voice IDs slot directly into the existing
tts.xai.voice_idconfig field. No changes to the TTS generation pipeline were needed — it already accepts arbitrary voice IDs.What's New
API Client (
tools/xai_custom_voices.py)Full Python client for the xAI Custom Voices REST API:
list_custom_voices()— paginated listing of team voicesget_custom_voice(voice_id)— single voice metadatacreate_custom_voice(file_path, **metadata)— create from reference audio (Enterprise-only via API)update_custom_voice(voice_id, **metadata)— patch metadata fieldsdelete_custom_voice(voice_id)— remove a voicedownload_custom_voice_audio(voice_id, output_path)— download reference cliplist_builtin_voices()— list all 89+ built-in xAI TTS voicesFollows existing patterns: reuses
tools.xai_http.hermes_xai_user_agent(), readsXAI_API_KEYviahermes_cli.config.get_env_value(), respectstts.xai.base_urlandXAI_BASE_URLenv var.Config and Setup
hermes_cli/config.py— comment ontts.xai.voice_idindicating custom voice IDs workhermes_cli/setup.py—hermes toolswizard now prompts for voice_id when xAI TTS is selected, with guidance on built-in vs custom voices and a link to the consoleDocumentation
website/docs/user-guide/features/tts.mdUsage
voice_idTests
28 new tests covering all API functions, validation, error paths. All existing TTS/STT tests unaffected (131 pass).
Relevant Docs