Nodes/Simple String Repository/Simple String Repository Small Compact (IO)
ComfyUI Node

Simple String Repository Small Compact (IO)

Three packed-string slots for small tag groups

By IgalOgonov·Created 2 years ago·Updated 2 years ago· 3
Simple String Repository Small Compact (IO)
    • parsed_string
    string
    delimiter
    target10,1,-1
    target20,1,-1
    target30,1,-1

    SimpleStringRepositorySmallCompact is the smallest footprint in the Simple String Repository family: three selection slots, and each one is a single packed string instead of three separate widgets. You get the core idea - a newline-separated tag collection in the string field, entries selected by index, one joined string out - in the least cluttered form the pack offers. If you want a prompt tag picker that barely takes up canvas space, this is the one.

    How the packed slot works

    Each targetN field holds index,strength,random in one comma-separated string. 1,1.2,-1 means "entry 1, weight 1.2, pick a random option." Optional parts can be dropped: 1 alone means target 1, strength 1, random -1. The regular (non-Compact) nodes split these into three separate widgets; the Compact format trades that clarity for a much shorter node. Given how few slots Small has, the saving is biggest here - three text fields versus nine widgets.

    The rest is family-identical: string (multiline) is your collection, delimiter ("," or " ") joins the selections, and the output is a single parsed_string that also displays on the node body because it's an output node.

    The one thing to set before it works

    Every targetN defaults to 0,1,-1, and target 0 almost never exists - unindexed lines get 1-based line numbers at runtime, so index 0 only shows up if you explicitly write a 0.something line. Out of the box, all three slots select nothing and the output is empty. Change the first field to 1,1,-1 (or your real entry's index) and you're live. The "Reset Target Parameters" button also resets to that same 0,1,-1, so clicking it blanks your output until you re-enter targets.

    When to use it (and when not to)

    Reach for this when you have a genuinely small group - one style, one mood, maybe one artist - and you're the one typing the selections. It's a near-perfect fit for a tidy prompt-building corner of a workflow. Reach for the regular Small node instead if other nodes need to drive the selections, because wiring a packed text string is clumsier than feeding INT and FLOAT widgets.

    Install

    ComfyUI Manager (search "Simple String Repository") or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/IgalOgonov/ComfyUI_Simple_String_Repository
    

    Restart ComfyUI. No requirements file, no models - plain Python plus a small JS extension.

    Family quirks to keep in mind

    Dots in entries are a trap - the parser splits on ., so an unindexed entry with a dot can throw a ValueError and an indexed one gets truncated at the second dot. Duplicate indexes silently shadow everything after the first, and the node never caches, so random at -1 re-rolls every queue run. Small, tidy, and predictable once you know those three things.

    Categoryutils

    Inputs (5)

    NameTypeDefaultDescription
    stringSTRING
    delimiterCOMBO2 options: ,,
    target1optSTRING0,1,-1
    target2optSTRING0,1,-1
    target3optSTRING0,1,-1

    Outputs (1)

    NameTypeDescription
    parsed_stringSTRING