Add Pocket TTS as a lightweight CPU-only TTS engine#7
Open
Ahmed-Ezzat20 wants to merge 2 commits into
Open
Conversation
Adds Pocket TTS (Kyutai, 100M params) as a new TTS backend alongside Qwen3-TTS, Chatterbox, and MLX. Runs entirely on CPU with no GPU required. Supports zero-shot voice cloning (requires gated model access) and 8 predefined voices. Auto-trims long voice references (>30s) to prevent hallucination. Falls back to predefined voice when cloning unavailable. Currently English only. Usage: --tts-engine pocket [--pocket-voice alba]
daceb7f to
ccfbce5
Compare
Code enhancements: - Guard empty/whitespace text in _PocketTTSWrapper.synthesize() to return silence instead of crashing on Pocket's tokenizer. - Hoist _POCKET_MAX_REF_SECONDS to module level for visibility. - Mention 'pocket' in the --tts-engine help string (choices were already updated but the help text listed only qwen/chatterbox/mlx). Documentation: - README.md: add Pocket TTS to the pipeline feature list, install extras, and a dedicated "Dub without a GPU" Quick Start section. - docs/installation.md: add tts-pocket to the voice-synthesis install list, compatibility matrix, and task-requirements table. - docs/cli-reference.md: update both --tts-engine tables (dub and speak subcommands), add --pocket-voice flag, and a Pocket TTS example in the speak examples section. - docs/quick-start.md: add a "Use Pocket TTS" section with predefined- voice and voice-cloning examples.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
alba,marius,javert,jean,fantine,cosette,eponine,azelmapip install "mazinger[tts-pocket]"Changes
tts.py_PocketTTSWrapper,_load_pocket_model,_create_pocket_voice_state,_synthesize_pocket; updatedTTSEngine,load_model,create_voice_promptcli/_groups.py"pocket"to--tts-enginechoices, new--pocket-voiceargcli/_dub.pypocket_voiceto pipelinepipeline.pypocket_voiceparam ondub(), override ref audio when setpyproject.tomltts-pocketoptional extra (pocket-tts>=1.0)Usage
Test plan
--tts-engine pocketand--pocket-voiceacross all subcommandspipeline.pypassespocket_voicethrough tocreate_voice_prompt()dubpipeline end-to-end with Pocket TTS