多个音频合并
Concatenate a list of audio files into one MP3
- pathList
- 音频地址
MultiMergeAudio (多个音频合并, "merge multiple audio") takes a list of audio file paths and glues them together into one MP3, in order. You feed it a LIST of paths (say, from the pack's AutioPath node picking several clips, or from a file-list loader), it concatenates them sequentially, writes the result to ComfyUI/output/audio/, and returns the path to the merged file.
This is a "voiceover assembly" node more than a music tool. In the pack's world - Chinese-first, with TTS nodes and WeChat-app publishing - the workflow is obvious: generate several TTS clips, then stitch them into one narration track. It also fits video work: piece together the audio track for a multi-scene video, or append a lead-in to a clip. The mechanism is dead simple sequential concatenation - no crossfades, no volume normalization, no overlap handling. If you need any of that, this isn't your node; if you need "these N files in a row, saved as one file," it's perfect.
How it works
It uses pydub (AudioSegment), which is why the pack lists it in requirements.txt - and pydub is a thin wrapper around ffmpeg for MP3 work, so ffmpeg needs to be reachable on your system. Each path in pathList is loaded as an MP3 and appended (combined += audio), then exported as a single MP3 named after filename_prefix into the output audio folder. The folder_paths.get_save_image_path call is reused for filename/counter logic, so you get the usual _00001_-style naming. Output is the full path to the merged file as a STRING.
Inputs and output
pathList- aLISTof audio file paths, in the order you want them joined.filename_prefix- the output filename stem (defaultComfyUI).- Output:
音频地址(audio path) -STRINGpath to the merged MP3.
Install
In yanlang0123/ComfyUI_Lam - Manager search "ComfyUI_Lam", or:
cd ComfyUI/custom_nodes
git clone https://github.com/yanlang0123/ComfyUI_Lam
restart. This is one of the few nodes where the pack's install.bat step is genuinely relevant - pydub isn't part of a stock ComfyUI, so you need it installed. Make sure ffmpeg/ffprobe is on your PATH (or the portable ComfyUI's bundled ffmpeg) or pydub's MP3 handling will fail.
Gotchas
The load call is AudioSegment.from_mp3, which is strict about MP3 - feed it a WAV or FLAC and it errors, so normalize formats before merging. And because there's no processing between segments, you get hard cuts; if the result clicks or has abrupt silence between clips, that's expected behavior - trim silence in the source clips (the pack's AudioBeforeAfterSilence can even add deliberate gaps if you're pacing narration). One more: batch count - pathList is one list, so this produces one merged file per run. Need each pair merged separately? You'd loop the node. Simple tool, simple rules, and it does the one thing without drama.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| pathList | LIST | — | |
| filename_prefix | STRING | ComfyUI | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| 音频地址 | STRING | — |