Nodes/SDVN_Comfy_node/πŸ”‘ Any Input Type
ComfyUI Node

πŸ”‘ Any Input Type

One text box, four typed outputs

By StableDiffusionVNΒ·Created 2 years agoΒ·Updated 29 days agoΒ· 118
πŸ”‘ Any Input Type
  • in1
  • in2
  • in3
  • in4
  • STRING
  • FLOAT
  • INT
  • BOOLEAN
β—„inputβ–Ί
β—„output_listNoneβ–Ί
β—„translateβ–Ύβ–Ί
β—„seed0β–Ί

This is the pack's swiss-army value node. You type something into one box, and it hands you that value back as a string, a float, an int, and a boolean, all at once - plus it can concatenate several inputs, split text into lists, translate, and run dynamic prompts. It replaces the fistful of primitive nodes you'd otherwise scatter around a graph to feed a number here, a string there. The pack pitches it as "a powerful and flexible node for working with text or numbers," and that's fair.

If you just want the simple version - text auto-cast to a type, commas as separators - that's the pack's Simple Any Input. This is the loaded one, with the extra knobs.

How it works

You put text in input. The node processes it - applying translation and dynamic-prompt expansion if you've set those - then makes it available cast to each of the four output types. On top of that, it can splice in up to four other inputs (in1-in4) wherever you reference them by keyword in the text; the README's example is concatenating segments using in1, in2, in3 as placeholders. The output_list setting decides whether and how it splits the result into a list - by keyword or by line, one match or all.

The inputs and outputs that matter

  • input (multiline STRING) - your text or number, and the template if you're using the in1-in4 placeholders.
  • in1-in4 (optional, any type) - values to weave into the text by keyword.
  • output_list - None, keywork, keywork_all, line, or line_all. This controls list-splitting; None keeps it as a single value. (Yes, "keywork" is their spelling.)
  • translate (language picker, default None) and seed - translate the text before output; the seed is what makes dynamic prompts reroll to a different pick.

Outputs are four lists: STRING, FLOAT, INT, BOOLEAN. Wire the one you actually need - string into a CLIP encode, int/float into a numeric slot on another node.

How to install it

Comes with the SDVN pack. ComfyUI Manager, search SDVN_Comfy_node; or:

cd ComfyUI/custom_nodes
git clone https://github.com/StableDiffusionVN/SDVN_Comfy_node
pip install -r custom_nodes/SDVN_Comfy_node/requirements.txt

from the ComfyUI root, then restart.

Common issues & troubleshooting

Dynamic prompts do nothing. The pack's dynamic-prompt support relies on the separate ComfyUI-DynamicPrompts node being installed. Without it, wildcard/{a|b|c} syntax won't expand. Install it and restart.

The number outputs are wrong or zero. If your text isn't actually a number, the FLOAT and INT casts have nothing sensible to produce. Feed numeric text if you're pulling from those outputs; feed prose only if you're using the STRING output.

Same dynamic result every time. The seed drives the reroll. A fixed seed gives the same expansion each run - change it (or randomize it) to get variety.

output_list confusion. If you're getting a list where you wanted a single value, or the splitting isn't matching your intent, that's this setting. Start with None for a plain single output and only switch to the line/keyword modes when you specifically want it chopped up.

CategoryπŸ“‚ SDVN/πŸ’‘ Creative

Inputs (8)

NameTypeDefaultDescription
inputSTRINGβ€”
output_listCOMBONone5 options: None, keywork, keywork_all, line, line_all
translateCOMBO108 options: None, afrikaans, albanian, amharic, arabic, armenian, +102
seedINT00–18446744073709550000The random seed
in1opt*β€”
in2opt*β€”
in3opt*β€”
in4opt*β€”

Outputs (4)

NameTypeDescription
STRING*β€”
FLOATFLOATβ€”
INTINTβ€”
BOOLEANBOOLEANβ€”