Nodes/ComfyUI-Just-Nodes/Preset Manager πŸ’Ž Just Nodes
ComfyUI Node

Preset Manager πŸ’Ž Just Nodes

The preset engine β€” templates that fill in the blanks, per character, per seed

By Arroz-11Β·Created 7 months agoΒ·Updated 3 days agoΒ· 0
Preset Manager πŸ’Ž Just Nodes
    • prompt
    • extra_text
    • output_path
    • output_prefix
    • negative
    • system_prompt
    β—„presetβ–Ύβ–Ί
    β—„seed0β–Ί
    β—„prompt_templateA beautiful {COLOR} {TYPE} flower, {SIZE} size, in a garden.β–Ί
    β—„preset_index-1β–Ί
    β—„negative_templateβ–Ί
    β—„extra_text_overrideβ–Ί
    β—„system_prompt_overrideβ–Ί

    Preset Manager is the only node in Just Nodes that's genuinely fiddly, and the only one that pays you back for the effort. It's a template engine with a preset system bolted on: a prompt template like A beautiful {COLOR} {TYPE} flower, {SIZE} size, in a garden. gets its {VARIABLES} filled in from preset files, and the whole thing is driven by a seed, so the same preset can produce different text on different runs. If you've ever wanted "one node per character, every prompt assembled for me," this is it.

    The preset dropdown is loaded from JSON files in the pack's presets/ directory - the loader merges every presets_*.json (one file per character is the author's stated design) plus presets_general.json, which is applied last so it can't clobber character-specific presets. lists.json holds the pools of values a variable can randomly pick from. The shipped example is honest about the format:

    // presets.json
    { "EXAMPLE - FLOWER": {
        "COLOR": {"mode": "random"},
        "TYPE":  {"mode": "manual", "value": "rose"},
        "SIZE":  {"mode": "manual", "value": "large"} } }
    // lists.json
    { "COLOR": ["red","blue","yellow","white","pink","purple","orange"] }
    

    Each variable is manual (uses its fixed value) or random (picks from lists.json[VAR] with a seed-seeded random choice). Beyond that there are underscore-prefixed special keys: _template (the prompt fallback), _negative, _extra_text, _system_prompt, _output_path and _output_prefix (which feed straight into the pack's Save Image With Text), and the interesting one, _pool - a list of dicts where seed % len(pool) picks a synchronized positive/negative/extra_text/system_prompt set, so all four stay coherent for a given seed.

    The six outputs, and the order things resolve (inputs beat pools beat presets):

    • prompt - your prompt_template input, else the pool's positive, else the preset's _template. If none exist, it returns an error string.
    • negative - negative_template input, else pool, else preset _negative.
    • extra_text - override input, else pool, else preset.
    • system_prompt - same chain; designed to feed an LLM node like QwenVL.
    • output_path and output_prefix - straight from the preset, for the Save node.

    After resolution, every {VARIABLE} placeholder is replaced across all four text outputs. And because the node's IS_CHANGED returns NaN, it re-runs on every queue - which is what lets random mode actually randomize per run rather than caching.

    Installing it

    Same as the whole pack: 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

    • It's JSON files, edited by hand. There's no in-UI editor - you edit presets/presets_*.json, then hit the node's reload presets button (it calls the pack's /just_nodes/reload_presets endpoint) to refresh the dropdown without restarting ComfyUI. Malformed JSON just logs an error and the file is skipped.
    • The resolution order is input > pool > preset, and it's strict: if you type anything into prompt_template, the pool and _template are ignored.
    • preset_index is an escape hatch for when you want the index from a batch stepper to drive preset choice - but out-of-range indexes return an error string as the prompt, not a clamped value.
    • Errors come back as string outputs, not pop-ups - if you see ERROR: Preset not found on a text output, that's the node talking.
    • It re-runs every queue by design. If you expected it to stay frozen, that's not a bug - it's the random mode working.
    CategoryπŸ’Ž Just Nodes

    Inputs (7)

    NameTypeDefaultDescription
    presetCOMBO1 options: EXAMPLE - FLOWER
    seedINT00–18446744073709550000β€”
    prompt_templateSTRINGA beautiful {COLOR} {TYPE} flower, {SIZE} size, in a garden.β€”
    preset_indexoptINT-1-1–999β€”
    negative_templateoptSTRINGβ€”
    extra_text_overrideoptSTRINGβ€”
    system_prompt_overrideoptSTRINGβ€”

    Outputs (6)

    NameTypeDescription
    promptSTRINGβ€”
    extra_textSTRINGβ€”
    output_pathSTRINGβ€”
    output_prefixSTRINGβ€”
    negativeSTRINGβ€”
    system_promptSTRINGβ€”