Audio Batch Edit
Merge audio inputs, then slice a range out by index
- audio0
- audio1
- audio2
- audio3
- select_audio_batch
- start_audio_batch
- end_audio_batch
Audio Batch Edit does for audio batches roughly what Select_Images_Batch does for image batches: merge multiple audio inputs together, then pick out a specific slice by index, and get back both the slice you picked and the two remainders on either side of it.
The inputs and outputs that matter
Up to four audio inputs go in - audio0 is required, audio1 through audio3 are optional and get merged onto the end of audio0 if you supply them, all treated as batches (multiple clips stacked together, not concatenated in time - this is index-based selection, not audio editing). Once everything's merged into one combined batch, start_batch (starting from 0) picks where your selection begins, and batch_len sets how many items from there you want - a negative value counts backward from the end instead, so -1 grabs everything from start_batch to the last item. If your requested range runs past the actual batch length, the excess just gets ignored; the node clips itself to what's actually there.
Three outputs, and this is the genuinely useful part: select_audio_batch is exactly what you asked for - the slice at your chosen indices. start_audio_batch is everything that came before your selection in the merged batch, and end_audio_batch is everything that came after it. One node gives you the piece you picked plus both halves of what's left, which is handy any time you're triaging a batch of generated audio clips - TTS takes, music generation runs, sound-effect variations - and want to route "the one I'm keeping" one direction while still having access to the discards.
If you actually need to cut by time rather than by batch position, that's the job of the pack's other audio node, Audio_Crop_Batch - this one only ever slices along the batch dimension.
Installing it
Comes with the rest of ComfyUI-WJNodes. ComfyUI Manager: search "ComfyUI-WJNodes," install, restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/807502278/ComfyUI-WJNodes.git
Find it under WJNode → Audio. No models or extra dependencies - this is index and batch manipulation, not audio synthesis.
Where people get burned
Remember start_batch counts from 0 here, unlike this pack's image equivalent (Select_Images_Batch), which counts from 1 - the two nodes don't share an indexing convention, so don't assume one behaves like the other if you've used both. And if your merged batch order looks unexpected, remember the merge order follows audio0 → audio1 → audio2 → audio3 - if you need a specific clip first in the sequence, wire it into audio0, not one of the optional slots, since those are appended after it rather than reordered by any priority setting.
Also worth noting: this node slices along the batch dimension only - it has no concept of seconds or timestamps, just clip positions in a merged stack. If your actual goal is "cut this one clip down to a 10-second window," you want Audio_Crop_Batch instead; this node is for picking which clips, not which portion of a clip, you keep.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| audio0 | AUDIO | — | |
| start_batch | INT | 0-1000000–1000000 | — |
| batch_len | INT | -1-1000000–1000000 | — |
| audio1opt | AUDIO | — | |
| audio2opt | AUDIO | — | |
| audio3opt | AUDIO | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| select_audio_batch | AUDIO | — |
| start_audio_batch | AUDIO | — |
| end_audio_batch | AUDIO | — |