Nodes/ComfyUI-Just-Nodes/Labeled Index πŸ’Ž Just Nodes
ComfyUI Node

Labeled Index πŸ’Ž Just Nodes

An integer with a label β€” the tiny node that keeps big graphs sane

By Arroz-11Β·Created 7 months agoΒ·Updated 3 days agoΒ· 1
Labeled Index πŸ’Ž Just Nodes
    • INT
    β—„labelsOption A Option B Option Cβ–Ί
    β—„modeβ–Ύβ–Ί
    β—„value0β–Ί
    β—„seed0β–Ί
    β—„min0β–Ί
    β—„max19β–Ί

    Labeled Index exists to solve a problem you only notice once your workflow has a few dozen nodes: what the hell is 5 connected to? It's an integer passthrough with a decorative label field on the node, so you can write "front view", "side view", "close-up" next to the values instead of memorizing them. The README calls it decorative, and that part is true - the labels never leave the node. The integer is the whole output.

    You feed it an index and it hands the same integer back, untouched, out of the single INT output. Where it earns its place: as the index for an Image From Folder node, as the select for a Picker, or as the slot chooser in any rotation you've built. Put Labeled Index in front of the thing that consumes an index, label each option in the multiline labels field, and the graph reads like a menu instead of a guessing game. In the bigger picture, this is the same instinct that makes rgthree's graph-organization nodes so popular - the graph is the interface, and readability is a feature.

    One detail the README undersells: the shipped code has moved past "pure passthrough." There's a mode field now. In manual mode it returns value untouched. In random mode it returns seed % (max - min + 1) + min, so you can generate a random index inside a range - same seed, same pick, reproducible. Set min/max to bound it (defaults are 0–19), set seed, flip the mode, and Labeled Index becomes a mini random-int source with a label on it.

    Inputs that matter: labels (multiline, purely visual - write your option names here), mode (manual/random), value (the passthrough when manual), and seed/min/max (when random). The output is the single INT - wire it anywhere an integer is expected.

    Installing it

    Same as every Just Nodes node: ComfyUI Manager β†’ search "Just Nodes" β†’ install β†’ restart, or cd ComfyUI/custom_nodes && git clone https://github.com/Arroz-11/ComfyUI-Just-Nodes.git. No models, no extra dependencies, MIT licensed.

    Gotchas

    • The labels are decorative. Nothing downstream sees them; they exist so you remember what the number means. Don't wire anything to them.
    • value isn't clamped to min/max in manual mode - min/max only govern random mode.
    • Random mode wraps correctly when max < min is handled (it forces max = min), so you won't get an out-of-range index.
    CategoryπŸ’Ž Just Nodes

    Inputs (6)

    NameTypeDefaultDescription
    labelsSTRINGOption A Option B Option Cβ€”
    modeCOMBO2 options: manual, random
    valueINT0β€”
    seedINT00–18446744073709550000β€”
    minINT0β€”
    maxINT19β€”

    Outputs (1)

    NameTypeDescription
    INTINTβ€”