Nodes/ComfyUI-MDSNodes/Text (Multiline) Dual
ComfyUI Node

Text (Multiline) Dual

Two prompt boxes, one node, zero magic

By MarwanDSAI·Created 3 months ago·Updated about 15 hours ago· 3
Text (Multiline) Dual
    • text_a
    • text_b
    ◄text_a►
    ◄text_b►

    Let's not oversell this one. Text (Multiline) Dual is two big text boxes in a single node, and each one comes out the other side unchanged as its own STRING output. There is no processing, no expansion, no clever anything. If that sounds like a node that shouldn't need to exist, you haven't yet built a graph with eleven separate prompt primitives scattered across three screens.

    It exists for the same reason PrimitiveString exists: repetition and legibility. Two values you always edit together should sit together.

    What it does, mechanically

    text_a and text_b are both multiline STRING widgets - the same tall box you get on a CLIP Text Encode, with line breaks preserved. Both are passed straight through as str(), so what you type is exactly what comes out, newlines included, no trimming, no wildcard or {a|b|c} substitution, no LLM anywhere near it. The outputs are named text_a and text_b and wire into any text input: CLIP Text Encode, a prompt-stack node, a filename builder, a save-note node, or another node in this pack.

    Empty box means empty string. No error, no warning - you get "" downstream and the run proceeds.

    That's the entire contract. Which means the interesting part isn't the node, it's the workflow shapes it's good at.

    Where it actually helps

    Pairs that must not drift. Positive and negative prompts belong next to each other, especially on models where the negative still does real work - it's the unconditioned prediction CFG compares against, not a filter applied afterwards, and at CFG 1 it isn't computed at all. Keeping both in one node means you see them together, edit them together, and notice when one has gone stale. Split across two nodes ten centimetres apart, you won't.

    Two-block prompt structures. Some of the newer LLM-encoded model families want a style block and a content block as distinct pieces of text rather than one run-on sentence. Two labelled boxes on one node is the least-fussy way to hold that.

    Dual-encoder rigs. When a model takes two text inputs - different CLIPs, or a prompt plus a separate style/quality string - you were going to build this from two primitives and a reroute anyway. Fewer nodes, one place to look.

    The trick worth knowing

    Either widget can be converted to an input: right-click → Convert widget to input, and it becomes a socket. Do that on text_b only and you get a hybrid - text_a stays hand-typed, text_b receives a generated string from a captioner, an LLM prompt node, or a file loader. That's more useful than the symmetric version, because in practice half your prompt is authored and half is assembled.

    One caution on the outputs: they're named identically to the inputs (text_a out, text_a in), and they sit in that order on the node. It is genuinely easy to drag the second output into the negative encode when you meant the first, or vice versa. Check the slot you grabbed, not the label you read.

    And a note on what it isn't: it does not do wildcards or dynamic prompts. Impact Pack's __wildcard__ and {this|that} syntax - the thing a lot of workflows depend on without knowing which pack supplies it - has to happen downstream, in a node that actually parses text. This one just holds it.

    Installing it

    ComfyUI Manager: search ComfyUI-MDSNodes (publisher marwandsai), install, restart. Or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/MarwanDSAI/comfyui-mdsnodes
    

    Restart ComfyUI and hard-refresh the browser. The node appears under MDSNodes → text as "Text (Multiline) Dual".

    Dependencies: none. The pack's requirements.txt is a single blank line, the pyproject.toml lists nothing, and the README's claim that it works out of the box with stock ComfyUI holds up. No models, no downloads. MIT, version 1.8.0, by a single author who wrote the pack for his own model-testing workflow - and which, for what it's worth, has no visible discussion in the ComfyUI subreddits, so don't expect a tutorial if something looks off.

    Common issues

    Output is empty. The box you wired from is empty. Both inputs are required but neither has a fallback, so "" travels silently. If you want a default, park a String Trim Fallback after it.

    You can't type into one of the boxes. Someone converted it to an input - maybe you did, when hunting for how to feed a generated prompt in. Right-click → Convert input to widget to get the text box back.

    Your wildcards are coming out literally. They will. Nothing here parses them; chain it into a dynamic-prompt node.

    CategoryMDSNodes/text

    Inputs (2)

    NameTypeDefaultDescription
    text_aSTRINGFirst multiline text input.
    text_bSTRINGSecond multiline text input.

    Outputs (2)

    NameTypeDescription
    text_aSTRINGOutput of the first multiline text.
    text_bSTRINGOutput of the second multiline text.