tts slot.
Setup
Set your Google credentials in the worker environment. Create a service account in the Google Cloud console and point the SDK at its JSON key. The Python SDK resolves credentials in priority order:credentials_json →
service_account_path → api_key → the GOOGLE_APPLICATION_CREDENTIALS env var → a
credentials.json file in the working directory.
The
api_key argument also falls back to the GOOGLE_API_KEY env var.Usage
Import the plugin and pass it to the pipeline’stts slot.
Voice families
Cloud TTS routes by voice name, so the voice family is normally inferred fromvoice. You can
optionally pin the family with model, which accepts one of the known GoogleTTSModel values:
"chirp3-hd", "chirp-hd", "studio", "neural2", "wavenet", "standard", "news",
"polyglot", "chirp". If the explicit model contradicts the family implied by voice, a
ValueError is raised.
Python
Parameters
Constructor parameters for the Python SDK (GoogleTTS). The JavaScript and Go SDKs expose voice, languageCode, model, speakingRate/SpeakingRate, and pitch in their idiomatic form.
Import paths
The synthesized audio is streamed back to the caller as the final stage of the
pipeline.