Nodes/FireRedAudio · T8star-Aix/FireRedAudio 角色脚本/SRT 预检 · T8star-Aix
ComfyUI Node

FireRedAudio 角色脚本/SRT 预检 · T8star-Aix

Turn a paste of dialogue into a validated, batch-ready script plan

By T8mars·Created 23 days ago·Updated 20 days ago· 22
FireRedAudio 角色脚本/SRT 预检 · T8star-Aix
  • voice_bank
  • 脚本计划
  • 标准化脚本 JSON
  • 预检报告
script
source_formatauto
strict_validationfalse
default_speaker

Before you batch-dub anything, the script has to become a ScriptPlan - the structured object of lines, speakers, scenes, languages, and optional timestamps that every downstream dubbing node consumes. ScriptParser is that front door. You paste in a script in one of four formats and it parses, validates, and normalizes it into the plan, checking role bindings against your voice bank, flagging empty lines, language mismatches, and out-of-range timestamps. It's the "make sure this won't blow up mid-batch" node, and it sits first in the whole production chain.

What it accepts

  • SRT - standard timecoded subtitles. The SRT body can mark roles with [角色] 台词.
  • 角色:台词 role scripts - plain 角色:台词 lines.
  • Timed role scripts - role scripts with timecodes (the README shows [00:00:03,000 --> 00:00:06,000] 小夏:大家好. as valid).
  • JSON - either an array of lines or an object with a lines array; each line supports speaker, scene, text, language, start_seconds, end_seconds.

Scene grouping works too - # 场景:名称, # Scene: name, or ## 名称 headers mark the current scene, which is how the production pack later builds scene stems.

The inputs that matter

  • voice_bank - required. The parser validates that every speaker in the script exists in the voice bank. This is the safety net that stops a batch from quietly generating with a missing voice.
  • script - the raw text.
  • source_format - auto (default) detects SRT vs role script vs JSON, or pin it if you know.
  • default_speaker - optional. Lines without a role get assigned this speaker.
  • strict_validation - default off. Off, issues are reported and the plan still comes out; on, any error raises and halts. Turn it on in production and off while iterating.

Outputs: 脚本计划 (the structured plan for downstream), 标准化脚本 JSON (what the parser made of your text), and 预检报告 (valid/warnings/errors with line-level details).

Where it fits

The README's production flow starts here: 音色库 → this node → 朗读文本规范化 → 可恢复批量配音. So: build your VoiceBank from Load Audio → VoiceProfile per role, wire the bank and the pasted script in, and let the preflight catch problems at zero GPU cost before you commit a batch run. It pairs naturally with TextNormalizer, which takes the 脚本计划 this produces and generates the actual spoken text.

Installing

Pack-wide install (ComfyUI Manager search comfyui-fireredaudio-T8, or clone + python scripts\setup_runtime.py). No model needed - parsing is local logic. The gotcha to remember is that validation is only as good as your voice bank: a role spelled slightly differently in the script than in the bank ("小夏:" vs "小夏 :") will either get caught or silently bind to default_speaker. When a batch comes out with a wrong voice, this is the first node to recheck.

CategoryT8star-Aix/Audio/FireRedAudio

Inputs (5)

NameTypeDefaultDescription
voice_bankT8_FIREREDAUDIO_VOICE_BANK
scriptSTRING
source_formatCOMBOauto4 options: auto, srt, role_script, json
strict_validationBOOLEANfalse
default_speakeroptSTRING

Outputs (3)

NameTypeDescription
脚本计划T8_FIREREDAUDIO_SCRIPT_PLAN
标准化脚本 JSONSTRING
预检报告STRING