Gemini 2.5 Flash Lite Preview TTS
Speechgoogle/gemini-2.5-flash-lite-preview-ttsAvailable Providers
Vertex
Supported Protocols
openai
Providers
Vertex
Input Tokens
$0.5/M
Output Tokens
$10/M
Output Audio
$10/M
Protocols
openai
/v1/audio/speechCode Examples
from openai import OpenAIclient = OpenAI(base_url="https://api.ofox.ai/v1", api_key="YOUR_OFOX_API_KEY")response = client.audio.speech.create(model="google/gemini-2.5-flash-lite-preview-tts",voice="Kore",input="Hello from OFOX.",response_format="wav",speed=1.1,extra_body={"language_code": "en-US", "instructions": "Speak warmly and clearly."},)response.stream_to_file("speech.wav")
Generate multilingual speech with adjustable speed and speaking style. Output is WAV; streaming can deliver PCM audio chunks or a complete WAV file.
Related Models
Frequently Asked Questions
Simply set your base URL to https://api.ofox.ai/v1 and use your Ofox API key. The API is OpenAI-compatible โ just change the base URL and API key in your existing code.