Nodes/cgem156-ComfyUI๐ŸŒ/Dart Config ๐ŸŒ
ComfyUI Node

Dart Config ๐ŸŒ

The generation knobs for the tag-completion LLM

By laksjdjfยทCreated 2 years agoยทUpdated about a month agoยท 93
Dart Config ๐ŸŒ
    • DART_CONFIG
    โ—„max_new_tokens128โ–บ
    โ—„min_new_tokens0โ–บ
    โ—„temperature1.00โ–บ
    โ—„top_p1.00โ–บ
    โ—„top_k20โ–บ
    โ—„num_beams1โ–บ
    โ—„cfg_scale1.00โ–บ

    This node doesn't generate anything by itself - it's a bundle of settings for Dart Generate, the node that actually runs the Dart language model to expand your seed tags into a full prompt. If you've ever tuned temperature, top_p, or num_beams on a text LLM, every field here will feel familiar, because Dart is a small language model, not a diffusion model, and it's sampled the same way GPT-style text generation is.

    Why it's a separate node

    Splitting config out from the generate call is a pattern cgem156 uses a few times in this pack (same idea as its custom samplers): it lets you save a specific "generation personality" - say, a conservative low-temperature config for reliable tag lists versus a wild high-temperature one for brainstorming - and swap it into DartGenerate without touching anything else in the graph. If you skip this node entirely, DartGenerate's config input is optional, so it'll fall back to its own defaults.

    The fields that matter

    Most of these map straight onto Hugging Face's generate() arguments, because that's what's running under the hood:

    • max_new_tokens / min_new_tokens - the length bounds on how many tag-tokens Dart is allowed to add. Default caps at 128; that's plenty for a full Danbooru-style tag list.
    • temperature - the usual randomness dial. Low values give you the model's most confident, "safe" tag continuations; push it up and you get more varied, sometimes stranger combinations. Default 1.0 is neutral.
    • top_p / top_k - nucleus and top-k sampling, the standard ways of trimming the tail of unlikely tokens before sampling. Default top_p of 1 means no nucleus trimming; top_k of 20 means it only considers the 20 most likely next tags at each step.
    • num_beams - beam search width. 1 (the default) is plain sampling; higher values trade randomness for a more deliberate, higher-likelihood tag sequence, at the cost of speed.
    • cfg_scale - classifier-free-guidance-style steering for the tag generation itself, separate from any image-generation CFG downstream. Default 1 is effectively off; raising it should push the model to lean harder on your seed tags rather than drifting into its own associations.

    Installing it

    Same install as every node in this pack - ComfyUI Manager, search "cgem156-ComfyUI", or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/laksjdjf/cgem156-ComfyUI
    

    Restart ComfyUI. This node has no model dependency of its own; it's pure configuration, so there's nothing to download for it specifically. It only becomes useful once you've got LoadDart and DartGenerate wired up alongside it.

    Where people get tripped up

    Since this is a niche corner of a niche pack with essentially no community discussion to draw on, the honest troubleshooting here is standard LLM-sampling common sense rather than anything cgem156-specific: crank temperature too high without lowering top_p/top_k to compensate and you'll get tag salad - plausible-sounding fragments that don't cohere into a sensible prompt. If output feels repetitive or stuck, that's usually num_beams set too high relative to how much variety you actually want, since beam search actively favors the single most likely continuation over diverse ones. And if cfg_scale above 1 does nothing to your output, double check you've actually got this DartConfig plugged into DartGenerate's config input - it's optional, so a dangling DartConfig node that isn't connected does exactly nothing.

    Categorycgem156 ๐ŸŒ/dart

    Inputs (7)

    NameTypeDefaultDescription
    max_new_tokensINT1281โ€“256โ€”
    min_new_tokensINT00โ€“255โ€”
    temperatureFLOAT1.000โ€“5โ€”
    top_pFLOAT1.000โ€“1โ€”
    top_kINT201โ€“500โ€”
    num_beamsINT11โ€“10โ€”
    cfg_scaleFLOAT1.000โ€“10โ€”

    Outputs (1)

    NameTypeDescription
    DART_CONFIGDART_CONFIGโ€”