多文本联合
Gluing text together in the lam pack
- text0
- text1
- STRING
- LIST
If you've ever built a prompt out of parts - a base subject, a style, a lighting tag, a LoRA-trigger word - you know the standard ComfyUI answer is the built-in Text Concatenate node. MultiTextConcatenate is that node with a couple of small extras bolted on, and honestly the extras are the reason you'd pick it over stock.
The headline trick is that it returns two things at once: a combined STRING for dropping straight into a CLIP Text Encode, and a LIST of the individual parts. That second output is what makes it interesting in batch workflows - you can shove the list straight into this pack's MultiTextEncodeAdvanced and encode every prompt in the list in one pass instead of wiring up twenty text encodes.
How it works
Feed it text0 and text1 at minimum. The node sweeps every input whose name starts with text (so text2, text3, ... appear the moment you connect them), collects them in order, and joins them with an optional delimiter string. The linebreak_addition toggle (false/true) decides whether each part lands on its own line or just runs together - handy when you're stacking tag blocks you want visually separated in the widget.
The output is honest: STRING (the joined text) and LIST (the raw parts, in order). Wire STRING into your CLIP encoder; wire LIST somewhere that wants a list.
The two inputs that actually matter
text0/text1- the text parts. Keep addingtextNinputs by connecting more wires; no config needed.linebreak_addition- settruewhen you're combining semantically separate blocks and want a newline between them.
delimiter is optional and defaults to empty; it's a literal separator, so if you want commas between tags, type one.
Install
It ships in the yanlang0123/ComfyUI_Lam pack. Easiest path is ComfyUI Manager: search "ComfyUI_Lam" and install. Manual route:
cd ComfyUI/custom_nodes
git clone https://github.com/yanlang0123/ComfyUI_Lam
Restart ComfyUI and you'll find the node under the lam category. One honest warning about this pack: the README tells you to run install.bat/install.sh, which pip-installs a monster requirements.txt (tensorflow, insightface, librosa, ...) that this node doesn't need at all. For a plain text-joining utility, skip that step - ComfyUI will load the node fine without it.
Where people get tripped up
The biggest trap is expecting it to include inputs that aren't named text*. Anything else in kwargs gets silently skipped, so don't name your prompt inputs p0, p1 and hope they show up. Second trap: it's a joining node, not a formatting node - it doesn't dedupe tags or strip whitespace, so feed it clean text. Minor, but if your concatenated prompt looks wrong, check your delimiters before you blame the node.
It's not a flashy node and it won't generate anything on its own. It's the plumbing that keeps a many-part prompt workflow readable, and the LIST output earns it a slot in anyone running batch-prompt experiments.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| linebreak_addition | COMBO | 2 options: false, true | |
| text0 | TEXT,STRING | — | |
| text1 | TEXT,STRING | — | |
| delimiteropt | STRING | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| STRING | STRING | — |
| LIST | LIST | — |