VoiceBridge Load SRT
The file picker your subtitle pipeline needed
- srt_string
Every pipeline that works on existing subtitles starts with the same chore: get the .srt file off disk and into the graph as a string. This node is the polite, upload-button-toting answer to that chore, and it's modeled directly on ComfyUI's own Load Audio node - dropdown of files, plus an upload button so you can drop a subtitle in without ever touching your file system.
How it works
The node scans ComfyUI/input/ and builds a dropdown (srt) of every .srt and .txt file it finds there. Pick one and it reads the file, decodes it, and hands you the raw content as srt_string.
Two details make it better than a generic "load text file" node:
- Encoding handling that actually cares about the real world. It tries UTF-8, then UTF-8 with BOM, then the Chinese encodings
gbkandgb18030, then falls back to latin-1. Subtitles from the wild are frequently GBK-encoded (or have a stray BOM), and a naiveopen()would throw aUnicodeDecodeErroron them. This node just quietly picks the encoding that works and logs which one it chose. - A real upload button. The pack ships a small frontend script (
web/js/uploadSRT.js) that injects a "choose srt file to upload" button into the node, mirroring the Load Audio/Image UX. Uploaded files are saved into the input directory and appear in the dropdown immediately - no refresh, no moving files around by hand.
The node also tracks changes properly: it hashes the file contents so the node re-executes when the file on disk changes, and it validates that the selected file actually exists.
The one input, the one output
There's a single input (srt, the dropdown) and a single output (srt_string, raw SRT text). The natural destination is VoiceBridge SRT Splitter's srt_string input - that's the documented chain: Load SRT → Splitter → any TTS → Audio List Merger. If you're instead running the legacy path, you can feed the string straight into SRT To Audio.
Installing it
This is part of the comfyui_voicebridge pack. ComfyUI Manager search "VoiceBridge", or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/YanTianlong-01/comfyui_voicebridge.git
cd comfyui_voicebridge
pip install -r requirements.txt
Restart ComfyUI after. No model downloads needed for this node - the ASR/TTS models only kick in downstream.
Where people get burned
The classic miss is dropping a file in the wrong folder. The dropdown only sees ComfyUI/input/, so a .srt sitting in your output folder or on the desktop is invisible until you either move it or use the upload button. The other gotcha is that this node does not validate SRT formatting - it reads whatever you point it at and passes it through. Malformed SRT won't fail here; it'll fail (with a clear error) at the Splitter. That's fine - Load SRT's job is just to get text in, and it does that without drama.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| srt | COMBO | 0 options: |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| srt_string | STRING | — |