TheDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/KittenML/KittenTTS/llms.txt
Use this file to discover all available pages before exploring further.
KittenTTS class is the primary interface for loading a model and synthesizing speech. It wraps an ONNX model downloaded from Hugging Face and exposes a simple API for generating audio.
Constructor
Hugging Face repository ID for the model to load. Can be a full repo ID like
KittenML/kitten-tts-mini-0.8 or just the model name.Available models:| Model | Parameters | Size |
|---|---|---|
KittenML/kitten-tts-mini-0.8 | 80M | 80 MB |
KittenML/kitten-tts-micro-0.8 | 40M | 41 MB |
KittenML/kitten-tts-nano-0.8 | 15M | 56 MB |
KittenML/kitten-tts-nano-0.8-int8 | 15M | 25 MB |
Local directory path for caching downloaded model files. If
None, uses the default Hugging Face cache directory (~/.cache/huggingface/hub).Properties
available_voices
Returns the list of voice names supported by the loaded model.List of available voice names for the loaded model. Pass any of these strings as the
voice argument to generate() or generate_to_file().Methods
| Method | Description |
|---|---|
generate() | Synthesize speech and return a numpy array. |
generate_to_file() | Synthesize speech and save it directly to a file. |
Legacy function
get_model() is a legacy wrapper kept for backward compatibility. Use KittenTTS() directly in new code.