ComfyUI Node

Gemini TTS

The most expressive voice controls in the pack

By Aryan185·Created about a year ago·Updated about a month ago· 14
Gemini TTS
    • audio
    text
    api_key
    model
    voice_id
    seed69
    temperature1.00
    styleNone
    paceNone
    accentNone
    audio_profile
    scene

    Every TTS API gives you a voice list. Gemini TTS gives you a voice list and the ability to say "Newscaster," "Whisper," or "Vocal Smile," set the pace to "Rapid Fire," and pick an accent - and it actually follows. This node wraps Gemini's text-to-speech, and it's the pack's most expressive voice option by a mile. If you're making characters, doing voice-overs with a specific read, or narrating with a personality, this is the one to fight with.

    The catch is it's a Gemini-preview TTS: quality is good, controls are rich, but it's a "preview" model family, so expect occasional API hiccups and model-name churn as Google shuffles the lineup.

    How it works

    The node uses the google-genai SDK and calls models.generate_content() configured as a TTS generation - your text, a voice_id from a catalog of prebuilt voices, and a VoiceConfig carrying the style, pace, and accent you chose. The returned audio bytes become a Comfy AUDIO dict (waveform + sample rate). The extra inputs like audio_profile and scene get woven into the generation config for context-aware delivery.

    The inputs that matter

    • text - what gets spoken.
    • voice_id - thirty prebuilt voices with moon- and star-inspired names: Zephyr, Puck, Charon, Kore, Fenrir, Leda, Aoede, Orus, Enceladus, and two dozen more. The names don't tell you the gender or timbre, so you will be auditioning. That's the fun part.
    • model - gemini-2.5-flash-preview-tts, gemini-2.5-pro-preview-tts, or the newer gemini-3.1-flash-tts-preview. Flash for speed, pro for polish.
    • style - the delivery knob: Vocal Smile, Newscaster, Whisper, Empathetic, Promo/Hype, Deadpan, or None. This is the feature nobody else in the pack has.
    • pace - Natural, Rapid Fire, The Drift, Staccato, or None. Pairs with style.
    • accent - Neutral, plus American (Gen/Valley/South), British (RP), Transatlantic, and Australian. Yes, you can make a British-RP newscaster.
    • temperature (default 1.0) - the expressiveness dial; lower for flat, higher for loose.
    • audio_profile and scene (optional) - free-text fields for describing the recording setup/context; leave empty unless you're chasing a specific delivery.
    • seed / api_key - key in the field or .env (GEMINI_API_KEY).

    The output

    audio - one AUDIO output, to preview or save.

    Installing it

    One of ~20 nodes in the Aryan185/ComfyUI-ExternalAPI-Helpers pack:

    cd ComfyUI/custom_nodes
    git clone https://github.com/Aryan185/ComfyUI-ExternalAPI-Helpers.git
    cd ComfyUI-ExternalAPI-Helpers
    pip install -r requirements.txt
    

    Restart ComfyUI; find "Gemini TTS" under audio/generation. Needs google-genai. Gemini key from aistudio.google.com - paste in the field or set GEMINI_API_KEY in .env.

    Where people get burned

    Preview-model churn is the main headache: Google renames these TTS models, and the enum in the node can point at a name that's been deprecated or quota-limited server-side. If you start getting model-not-found errors, check whether a newer TTS model name is available. Also, the voice catalog is big but opaque - no way to preview in-node, so audition by generating one line per candidate. And TTS via API is billed; the preview tier has limits, so a long narration run can stall on quota.

    For "I need a character voice with attitude," this beats the pack's other TTS options. For "I need a reliable studio narration," ElevenLabs or plain OpenAI TTS are the boring, dependable choices.

    Categoryaudio/generation

    Inputs (11)

    NameTypeDefaultDescription
    textSTRING
    api_keySTRINGDirectly put Gemini API key or .env variable name (GEMINI_API_KEY)
    modelCOMBO3 options: gemini-2.5-flash-preview-tts, gemini-2.5-pro-preview-tts, gemini-3.1-flash-tts-preview
    voice_idCOMBO30 options: Zephyr, Puck, Charon, Kore, Fenrir, Leda, +24
    seedINT69-1–2147483646
    temperatureFLOAT1.000–2
    styleoptCOMBONone7 options: None, Vocal Smile, Newscaster, Whisper, Empathetic, Promo/Hype, +1
    paceoptCOMBONone5 options: None, Natural, Rapid Fire, The Drift, Staccato
    accentoptCOMBONone8 options: None, Neutral, American (Gen), American (Valley), American (South), British (RP), +2
    audio_profileoptSTRING
    sceneoptSTRING

    Outputs (1)

    NameTypeDescription
    audioAUDIO