IndexTTS 2.5 上下文逐句情感建议 · T8star-Aix
An emotion editor that reads the room for you
- model
- dialogue_script
- 带建议的台词脚本
- 可编辑建议 JSON
- 分析摘要
Hand-tuning emotion per line is the most tedious part of scripted TTS. You know line 14 should be angry and line 15 relieved, but transcribing "which vibe goes here" into the pack's eight-dimension emotion vector, line after line, is exactly the kind of work that makes you abandon a multi-character project. This node - 上下文逐句情感建议 - does the boring first pass for you: it reads the script, looks at each line's neighbors, and suggests an eight-dimension emotion vector and strength for every line, using the same QwenEmotion model the rest of the pack runs locally.
The deliberate twist: it never generates audio. This is a two-stage safety design. Stage one produces suggestions you can inspect and edit; stage two (you, after approving) wires the edited script into the timeline editor and generation nodes. Nothing gets synthesized until you say so.
How it works
It takes your parsed dialogue_script and the loaded model, then for each line feeds the local QwenEmotion model the context around it: context_window lines before and after (default 2 and 2), with roles kept distinct so a reply from another character is read as dialogue, not as part of the same utterance. The model classifies emotion and returns the pack's fixed eight dimensions - 喜、怒、哀、惧、厌恶、低落、惊喜、平静 (joy, anger, sadness, fear, disgust, low, surprise, calm), each 0–1 - plus a strength.
The overwrite_existing toggle is the safety valve. Off by default, which means any text: or vector: emotion you already wrote by hand is preserved and the suggestion just fills the gaps. Flip it on and the suggestions replace everything. Low-VRAM machines get a nice touch: the QwenEmotion model is released right after analysis so it doesn't sit in VRAM waiting for a generation that may never come.
The inputs that matter
dialogue_script- output of the批量台词 / SRTnode. Required; empty script errors immediately.context_window- 0–5, default 2. More context = more accurate reading of where the scene is going; less = faster, and less room for the model to overthink.overwrite_existing- leave off unless you want machine opinion to override your manual work.
Outputs are the dialogue_script with suggestions baked in, an editable JSON you can dump to a text node and tweak, and a summary string telling you how many lines got classified and how many manual settings survived.
Installing and using
Same pack install as everything else - ComfyUI Manager → IndexTTS 2.5 · T8star-Aix, or git clone https://github.com/T8mars/comfyui-indextts25-t8.git into custom_nodes/, restart. The QwenEmotion model is bundled in the 7.7 GiB model download, so there's no extra model fetch.
The recommended flow: load model → parse script → this node → check the JSON → 时间轴编辑 if you need timing → multi-role generation. The pack ships example 32 wired this way on purpose, with the generation node deliberately disconnected so you can't accidentally skip the review step. Trust the two-stage design. A machine-suggested angry line that's actually sad reads worse than a hand-set neutral one, and this node exists to make the hand-set part cheap.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| model | T8_INDEXTTS25_MODEL | — | |
| dialogue_script | T8_INDEXTTS25_DIALOGUE_SCRIPT | — | |
| context_window | INT | 20–5 | 2 表示参考目标台词前 2 句和后 2 句;分析时会区分角色。 |
| overwrite_existing | BOOLEAN | false | 关闭时保留脚本里已有的 text:/vector: 人工设置。 |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| 带建议的台词脚本 | T8_INDEXTTS25_DIALOGUE_SCRIPT | — |
| 可编辑建议 JSON | STRING | — |
| 分析摘要 | STRING | — |