Nodes/T2 text tools/T2 Seed Index
ComfyUI Node

T2 Seed Index

Queue up every seed and prompt combo, then walk away

By conKORD·Created 12 months ago·Updated 12 months ago· 0
T2 Seed Index
    • seed
    • index
    • seedIndexFormatted
    task_index0
    seed_start0
    seeds_total1
    seed_methodincrement
    index_start0
    indexes_total1
    orderseed_then_index
    batch_size1

    If you've ever sat there clicking Queue Prompt thirty times to try thirty seeds on the same prompt, this node is for you. T2 Seed Index (class SeedIndex, from the conKORD/comfyui-text-tools pack, "T2 text tools") is a little batch scheduler that turns your whole seeds × prompts grid into one linear queue. One click advances you through it, it remembers where you are between runs, and you never touch the seed box again. It touches no pixels - pure plumbing that emits numbers.

    What it's for

    Batch and sweep workflows. Instead of setting the sampler to randomize and hoping, you declare the grid up front and step through it deterministically. That's the discipline the community keeps preaching: lock the seed, change one variable, compare (see the "seed farming" advice in the KB - a fast sampler at low steps to hunt seeds, then the good one). SeedIndex makes that systematic across many prompts at once, and because your position is just a number, you can close ComfyUI and pick up exactly where you left off.

    How the index math works

    The mental model is a linear task counter unwrapped into two dimensions. Your grid has seeds_total × indexes_total total jobs. task_index (times batch_size) is where in that queue this run starts, and the node decodes each position into a (seed, prompt-index) pair.

    order decides how the counter walks. seed_then_index runs every seed for prompt 0, then every seed for prompt 1 - seeds change fastest. index_then_seed flips it: every prompt for seed 0 first. Each decoded seed is seed_start plus an offset (or minus it with decrement, or left alone with fixed), and each prompt index is index_start plus an offset.

    The inputs that actually matter

    • seeds_total and indexes_total - the two dimensions of your grid.
    • seed_start - the base seed everything else offsets from.
    • order - which axis changes fastest (seed_then_index or index_then_seed).
    • batch_size - how many jobs a single Queue click runs.
    • task_index - your current position in the queue. The tooltip says it straight: set control_after_generate to "increment" so each run steps you forward one task.
    • seed_method - fixed, increment, or decrement.

    Outputs and where they go

    All three outputs are lists: seed (INT), index (INT), and seedIndexFormatted (STRING, like seed 0 index 0). Because they're lists, the engine executes anything wired downstream once per entry - that's what actually fans a batch of seeds out into a batch of generations. Wire seed into a KSampler's converted seed input, and index into a prompt picker (the pack's sibling T2 Prompt Selector is the natural match) so each prompt gets its run. seedIndexFormatted is handy if you want a readable per-job label for filenames.

    Installing it

    The whole pack is dependency-free Python - no models, no downloads, nothing to pip install, which is a big part of its appeal. Through ComfyUI Manager, search "comfyui-text-tools" (or "T2 text tools"). Manually:

    cd ComfyUI/custom_nodes
    git clone https://github.com/conKORD/comfyui-text-tools
    

    Then restart ComfyUI. Keep the folder named comfyui-text-tools - the node's import path depends on it.

    Troubleshooting

    • If the node shows a validation error like "task_index (26) should not be greater than seeds_total*indexes_total", you've walked past the end of the grid. Bump a dimension or reset task_index to 0.
    • The classic control_after_generate trap applies here too: with increment, the number you see is the one that runs next. Lock a great result by setting it to fixed, and consider switching ComfyUI's "widget control mode" to Before so the box always shows what just ran.
    • Outputs are lists by design. Don't expect a scalar socket - go through the sampler's converted input.
    • The pack README is the stock cookiecutter boilerplate, barely edited (it still says "A list of features"). The real behavior lives in nodes.py at the repo root, and it's tiny - worth a read.
    Categorysd

    Inputs (8)

    NameTypeDefaultDescription
    task_indexINT00–1000Set control_after_generate to 'increment'
    seed_startINT0-18446744073709550000–18446744073709550000Seed to work with
    seeds_totalINT11–1000Total seeds for each prompt index
    seed_methodCOMBOincrement3 options: fixed, increment, decrement
    index_startINT00–1000
    indexes_totalINT11–1000When node should stop
    orderCOMBOseed_then_index2 options: seed_then_index, index_then_seed
    batch_sizeINT11–1000How many tasks should be processed in one run.

    Outputs (3)

    NameTypeDescription
    seedINT
    indexINT
    seedIndexFormattedSTRING