Nodes/ComfyUI LC123 Nodes/🌱LC Seed
ComfyUI Node

🌱LC Seed

A seed node that randomizes when you tell it to, not behind your back

By lonecatone23Β·Created 2 months agoΒ·Updated 3 days agoΒ· 18
🌱LC Seed
    • seed
    β—„base_seed0β–Ί
    β—„seed_moderandomizeβ–Ί

    Here's the seed story everyone who has used ComfyUI for more than an afternoon knows: you generate a great image, go to lock the seed, and it's already been replaced - because control_after_generate fires after the run. LC Seed exists to take that footgun out of the equation entirely.

    The trick is in how it's built. The widget is named base_seed, not seed, which means ComfyUI doesn't attach its invisible control_after_generate dropdown to it at all. Instead the node has its own explicit seed_mode dropdown: fixed, randomize, increment, or decrement. The seed changes exactly when you say so, in exactly the direction you picked. If you want "same seed every run," you pick fixed and it stays put - no surprise overwrite at the end of the run.

    How it works

    Under the hood it's a small utility node: base_seed in, seed (INT) out. In randomize mode it picks a fresh 64-bit value each run; increment/decrement step by one; fixed returns the base as-is. It also forces itself to re-run in randomize mode by declaring itself changed every time, so the value actually updates when you hit queue. The README's note is worth taking literally: the seed modes work reliably when you queue this node alone, which makes it handy for A/B testing or generating a batch of base values to scan.

    Why you'd reach for it

    The KB's plumbing doc calls control_after_generate "the widget everyone gets bitten by once," and suggests the global fix (set widget control mode to Before). LC Seed is the pack-level version of that fix: the behavior is explicit and on the face of the node. If you've ever lost a seed to the after-run overwrite, this is a clean habit to adopt - one source for the seed, fanned out to every consumer, with the mode you actually mean written on it.

    Install

    Part of LC123 - ComfyUI Manager (search "LC123") or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/lonecatone23/ComfyUI_LC123_nodes
    

    Restart. No extra pip packages; MIT licensed. Cloud-hosted ComfyUI won't have LC123 until requested - request it or run local, or the node won't resolve.

    The honest caveat: if you've already set "widget control mode" to Before globally, a plain seed widget does most of this job. LC Seed's edge is that the mode lives right on the node, survives workflow sharing, and randomizes only when you opt in. For seed-heavy iteration it's genuinely nicer than a raw INT box.

    CategoryLC123/utils

    Inputs (2)

    NameTypeDefaultDescription
    base_seedINT00–18446744073709550000Base seed value. seed_mode decides how it changes each run.
    seed_modeCOMBOrandomizefixed: reuse base_seed. randomize / increment / decrement: every run (full queue or this node only).

    Outputs (1)

    NameTypeDescription
    seedINTβ€”