Text Append
String Glue for Prompts Built From Parts
- text
If you've ever wanted to build a prompt from parts - base subject, style block, artist, quality tags - and got tired of pasting them together by hand, this is the node you were missing. Text Append takes two or more strings, glues them together in order with an optional separator, and hands you one clean STRING to wire onward. It lives in the WtlNodes/logic family, right next to the pack's Int, Float, and Text constants.
Here's the part people get wrong on first contact: you don't type into it. text_1 and text_2 are input sockets, not text boxes - you have to wire string sources into them, typically a couple of the pack's own Text nodes. Set the separator, and the node concatenates everything in order. The Python side walks text_1, text_2, and so on, joins them with the separator, and silently skips any None value, so a dead upstream node won't crash the whole chain.
The genuinely neat bit is the dynamic slots. The pack's frontend extension watches connections and grows a new text_3, text_4, … input whenever you connect the last one - and trims trailing empty slots when you disconnect. So two inputs is just the starting point; chain four or five string sources if the prompt demands it. You get the behavior of a multi-input append without a settings panel full of toggles.
The inputs that matter:
text_1,text_2- STRING, required, wired in. Sources of the text you're joining.separator- STRING, optional, default"". This is the trap.
That empty default is where people get burned. Wire "cat" and "on a sofa" with the default separator and you get caton a sofa. Set it to ", " for a Danbooru-style tag list or " " for sentence parts - both are very much a thing depending on which text encoder your checkpoint uses. The output is text (STRING), and it feeds straight into a CLIP Text Encode prompt input, into another append for longer chains, or into anything that wants a string.
Why reach for it? Two reasons. First, block-structured prompting: people who run tag-based models (Illustrious, Pony, Anima) commonly keep the prompt in distinct blocks - tags, style, series - and this is the cleanest way to assemble those blocks from separate, reusable constants. Change one block without touching the rest. Second, it plays well with dynamic prompts and wildcards: when a source resolves at run time, the append just concatenates whatever arrives, so you can mix a fixed prefix with a randomized suffix and see the joined result by dropping a WtlText on the output.
Install is the same for the whole pack:
cd ComfyUI/custom_nodes/
git clone https://github.com/Scorpiosis0/ComfyUI-WtlNodes.git
then restart ComfyUI, or search ComfyUI Manager for "WtlNodes" and let it handle it. Dependencies are numpy, scipy, and pillow - almost certainly already present in a working ComfyUI install - and there are no model downloads. It's pure CPU string work.
Gotchas, in summary: remember it takes wired inputs, not typed text; remember the separator (it really is empty by default); and know that a None from an upstream source disappears silently, which occasionally leaves you with a mysteriously short string. None of it is a bug - just read your separator before you queue the batch.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| text_1 | STRING | — | |
| text_2 | STRING | — | |
| separatoropt | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| text | STRING | — |