docs/Gemini-TTS.md
Fabric supports Google Gemini's text-to-speech (TTS) capabilities, allowing you to convert text into high-quality audio using various AI-generated voices.
The Gemini TTS feature in Fabric allows you to:
To generate audio from text using TTS:
# Basic TTS with default voice (Kore)
echo "Hello, this is a test of Gemini TTS" | fabric -m gemini-2.5-flash-preview-tts -o output.wav
# Using a specific voice
echo "Hello, this is a test with the Charon voice" | fabric -m gemini-2.5-flash-preview-tts --voice Charon -o output.wav
# Using TTS with a pattern
fabric -p summarize --voice Puck -m gemini-2.5-flash-preview-tts -o summary.wav < document.txt
Use the --voice flag to specify which voice to use for TTS generation:
fabric -m gemini-2.5-flash-preview-tts --voice Zephyr -o output.wav "Your text here"
If no voice is specified, the default voice "Kore" will be used.
Gemini TTS supports 30+ different voices, each with unique characteristics:
To see all available voices with descriptions:
# List all voices with characteristics
fabric --list-gemini-voices
# List voice names only (for shell completion)
fabric --list-gemini-voices --shell-complete-list
Google Gemini TTS has usage quotas that vary by plan:
gemini-2.5-flash-preview-tts)If you exceed your quota, you'll see an error like:
Error 429: You exceeded your current quota, please check your plan and billing details
Solutions:
For current rate limits and pricing, visit: https://ai.google.dev/gemini-api/docs/rate-limits
--voice <voice_name> - Specify the TTS voice to use-o <filename.wav> - Output audio file (required for TTS models)-m <tts_model> - Specify a TTS-capable model (e.g., gemini-2.5-flash-preview-tts)You can also set a default voice in your Fabric configuration file (~/.config/fabric/config.yaml):
voice: "Charon" # Set your preferred default voice
-o filename.wav-o filename.wav when using TTS modelsFor additional help with TTS features:
fabric --help
For more information about Fabric, visit the main documentation.