Nodes/Trent Nodes/H3 Chain Audio + Save Barrier
ComfyUI Node

H3 Chain Audio + Save Barrier

Keep the sound when you chain H3 clips together

By TrentHunter82·Created 10 months ago·Updated a day ago· 42
H3 Chain Audio + Save Barrier
  • audio
  • meta_batch
  • audio
◄step—►
◄saved_tail—►

H3 generates its audio with the picture - dialogue, room tone and effects in the same pass, not a separate audio model bolted on afterwards. That's the reason to use it, and it's also why chaining H3 clips goes wrong in a way you don't notice until the render is done: each extension chunk has its own audio, but VHS's Video Combine only ever sees the batch arriving on the final pass. Your extended 30-second clip comes out with sound on the last four seconds and silence before it.

H3 Chain Audio + Save Barrier exists to fix exactly that. Every chunk's audio is collected as the chain runs, and on the final pass the whole track goes to the combine for muxing.

What it's doing under the hood

The node keeps a list of audio chunks in memory on the node instance. Because both H3 Chain nodes force re-execution every queue, that instance sees each requeue in turn, and the list survives between them for the life of the ComfyUI process.

On step == 0 it clears the list and records the sample rate. Every later pass has to arrive in order: if step isn't exactly the number of chunks collected so far, it errors rather than guessing. It rejects a chunk whose sample rate or channel count changed mid-run, because a track assembled from mixed formats is worse than a failed run.

Each waveform is copied to CPU as float32 with copy=True as it's stored - deliberate, since a slice of a decoded GPU audio tensor can keep the whole underlying buffer alive and hold VRAM you thought you'd freed. On the last chunk, the pass where the batch manager reports has_closed_inputs, the chunks are concatenated along the time axis and the state is released. Every earlier pass outputs only the newest chunk, because VHS doesn't look at audio until the final mux.

The save barrier, and why it's an input you can't skip

saved_tail is a STRING input and it's the odd one out. Connect the path your save step produces - the tooltip names it as Save Latent's path, and in a chunked H3 run that's whatever node writes the chunk's tail to disk. Wiring that string makes the save step a parent of this node, so it cannot execute until the tail latent is written. That's the barrier: the next extension's continuation is that tail. Leave it empty and you get a hard error, not a quiet degradation.

The other three inputs are plumbing. audio is the chunk's audio - and the node's own description says trimmed audio: send the part covering the chunk's new frames, not the overlap frames, or the assembled track drifts longer than the picture. meta_batch is the same VHS Meta Batch Manager H3 Chain Step reads, and step is that node's step output. There's one output, audio, straight into VHS Video Combine; this node does no muxing itself.

It's an output node, so it executes on every requeue whether or not anything consumes its output - but you still need the wire to the combine for the audio to reach the file.

Install

Manager path: search Trent Nodes (registry trentnodes) and install. Or:

cd ComfyUI/custom_nodes
git clone https://github.com/TrentHunter82/TrentNodes.git
cd TrentNodes
pip install -r requirements.txt

Restart, then find it under Trent/MiniMax. These two chain nodes aren't in the pack README's node list yet.

VideoHelperSuite is a real dependency here - VHS_BatchManager, VHS_VideoCombine and the combine's audio input all come from it. The pack's requirements.txt pulls in a lot you won't touch (vosk, psd-tools, transnetv2, the LLM SDKs); none of it is needed for this node.

Two neighbours worth knowing: MiniH3 Magic rounds a batch up to H3's 17n+5 frame grid, and H3 Repack AV Latent re-wraps a saved H3 AV latent so it can be split or decoded next run.

Where people get burned

"H3 chain requires the saved tail path before requeueing." saved_tail was empty - the save step didn't produce a path. Check that node actually ran.

"H3 chain audio lost a chunk. Queue a fresh run; do not resume a partial batch." The collected audio lives in the running ComfyUI process. Restart ComfyUI, edit the graph, or requeue by hand mid-chain and it's gone. No partial resume on purpose: a track with a hole in it muxes silently and you only hear it at the end.

"Sample rate changed between chunks" / "channels changed between chunks." Something upstream is inconsistent - usually two different audio paths, or a chunk that landed mono. Make the audio branch identical for every chunk.

Manager refusing to install the pack. Known thing with this repo: the author renamed it on day one, the registry flagged it as looking like two repos, and Manager has been flaky about it since. The git clone above sidesteps it.

CategoryTrent/MiniMax

Inputs (4)

NameTypeDefaultDescription
audioAUDIO—
meta_batchVHS_BatchManager—
stepINT—
saved_tailSTRINGConnect Save Latent's path so the tail is saved before the next requeue.

Outputs (1)

NameTypeDescription
audioAUDIO—