Maya1 TTS (AIO)
Maya1 TTS (AIO)
- audio
ComfyUI has image, video, even music nodes now, but until recently it couldn't talk to you. This node fixes that. Maya1 TTS (AIO) is a single all-in-one node that loads the Maya1 model - a 3B-parameter open-weight speech model from Maya Research, Apache 2.0 - and turns text into expressive voice. No API, no key, no cloud. It runs entirely on your GPU, the same way your checkpoints do.
The headline feature is emotion. You drop tags straight into your script - <laugh>, <cry>, <whisper>, <angry>, <gasp> - and the narrator actually performs them at the right moment. That's the difference between a robot reading a screenplay and a character acting it. For video voiceover, character dialogue, narration for an animated workflow, or just making your ComfyUI setup feel alive, this is the audio half of everything the image side does visually.
How it works
Maya1 is a Llama-architecture transformer that doesn't write speech audio directly - it writes SNAC audio tokens, from the SNAC neural codec. The node wraps your voice description into a <description="..."> control token, appends your script with its emotion tags, then generates codec tokens autoregressively (7 tokens per audio frame). It filters and unpacks those tokens and hands them to the SNAC decoder, which turns them into a 24kHz mono waveform.
That two-stage design is also why it's fast: token generation runs at real-time-ish speed, around 45 it/s on a 5090 with bfloat16 + sdpa attention. The author's release thread on r/StableDiffusion has demos; the pack also pairs with the same author's dotWaveform node if you want the waveform visualized.
The inputs that matter
Most of these you'll leave alone once it's working:
- voice_description - natural language. Age, gender, accent, pitch, timbre, pacing. "Female voice in her 20s, British accent, warm tone, conversational pacing" is the whole recipe.
- text - your script, with
<tag>emotions typed inline. - dtype - defaults to
bfloat16(~8-9GB VRAM) which is also the fastest.4bit/8bitare there for sub-10GB GPUs but are slower - quantization dequantizes on every forward pass. If you have 10GB+, just keep bfloat16. - max_new_tokens - roughly 50 tokens per word; 4000 ≈ 30-40s of audio. Bump it if clips cut off early.
- seed - same seed, same performance. 0 is random.
- keep_model_in_vram - leave
truefor repeated generations; the node auto-clears the cache if you switch dtypes.
The custom UI
This is why you'd pick this node over its plain sibling. The canvas gives you 5 character presets (Male US, Female UK, Announcer, Robot, Demon), emotion-tag buttons that insert at the cursor position, a fullscreen modal editor (Ctrl+Enter saves, Esc cancels), a font-size slider, and click-to-edit inline text. It's genuinely pleasant to work with - until it isn't. If the node renders as a black box with no widgets, that's a JavaScript rendering issue, and the pack ships a second node (Maya1 TTS Barebones) that's the same engine with standard ComfyUI widgets.
Output
audio - a ComfyUI AUDIO type at 24kHz mono. Wire it into PreviewAudio, SaveAudio, or anything else that accepts audio.
Install
ComfyUI Manager (search "Maya1 TTS"), or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/Saganaki22/ComfyUI-Maya1_TTS.git
cd ComfyUI-Maya1_TTS && pip install -r requirements.txt
Then grab the model - this is the step people miss. It goes in ComfyUI/models/maya1-TTS/maya1/, not the standard model folders:
cd ComfyUI
hf download maya-research/maya1 --local-dir models/maya1-TTS/maya1
That's roughly 6GB across two shards. The snac pip package pulls its own codec checkpoint on first use, so the first generation is slower than the rest. Restart ComfyUI and you'll find both nodes under Add Node → audio. If the model picker says no models found, check the folder path and restart.
Troubleshooting
- OOM - drop to
4bit(~6GB) or close other VRAM hogs. For long scripts,chunk_longformsplits at sentence boundaries with crossfades, but it's flagged experimental for a reason. - Audio cuts off - raise
max_new_tokens. - Quantization errors -
pip install bitsandbytes, and remember 4/8-bit needs CUDA. - Cancel - the node respects ComfyUI's cancel button natively via a stopping criteria, so you're never stuck waiting out a 4000-token run.
Inputs (13)
| Name | Type | Default | Description |
|---|---|---|---|
| model_name | COMBO | (No models folder found - see console for instructions) | 1 options: (No models folder found - see console for instructions) |
| dtype | COMBO | bfloat16 | 5 options: 4bit (BNB), 8bit (BNB), float16, bfloat16, float32 |
| attention_mechanism | COMBO | sdpa | 4 options: sdpa, eager, flash_attention_2, sage_attention |
| device | COMBO | cuda | 2 options: cuda, cpu |
| voice_description | STRING | Realistic male voice in the 30s age with american accent. Normal pitch, warm timbre, conversational pacing. | — |
| text | STRING | Hello! This is Maya1 <laugh> the best open source voice AI model with emotions. | — |
| keep_model_in_vram | BOOLEAN | true | — |
| temperature | FLOAT | 0.400.1–2 | — |
| top_p | FLOAT | 0.900.1–1 | — |
| max_new_tokens | INT | 4000100–16000 | Maximum NEW SNAC tokens to generate per chunk (excludes input prompt tokens). Higher = longer audio per chunk (~50 tokens/word). 4000 tokens ≈ 30-40s audio |
| repetition_penalty | FLOAT | 1.101–2 | — |
| seed | INT | 00–18446744073709550000 | — |
| chunk_longform | BOOLEAN | false | Split long text into chunks at sentence boundaries with smooth crossfading. Enables unlimited audio length beyond the 18-20s limit |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| audio | AUDIO | — |