Nodes/AntiMatter Nodes/AntiMatter Style Preset Mixer
ComfyUI Node

AntiMatter Style Preset Mixer

The AntiMatter Style Preset Mixer

By AntiMatterComfy·Created 4 months ago·Updated 4 days ago· 0
AntiMatter Style Preset Mixer
    • text
    • selected_style_files
    enabledfalse
    style_file17_poses.txt
    read_moderandom
    enabled_1false
    style_file_101_emotions_expressions.txt
    read_mode_1random
    enabled_2false
    style_file_203_nsfw_body_focus_anatomy.txt
    read_mode_2random
    enabled_3false
    style_file_314_undressing.txt
    read_mode_3random
    enabled_4false
    style_file_409_sexy_outfits_clubwear_latex_leather.txt
    read_mode_4random
    enabled_5true
    style_file_5Flux/POSES/crawling.txt
    read_mode_5random
    enabled_6false
    style_file_6Flux/2GIRLS/2GIRL_FINGERING.txt
    read_mode_6random
    enabled_7false
    style_file_713_hairy_pussy_details.txt
    read_mode_7random
    input_text

    The short version

    Queue fifty images with one hand-typed prompt and you get fifty near-identical images. The fix everyone lands on: move the variable parts into a .txt file, one variation per line, and let the graph pick a line per run. Impact Pack quietly owns a lot of that job - the __wildcard__ syntax plenty of workflows depend on without knowing who provides it.

    The AntiMatter Style Preset Mixer is a narrower take: eight slots, each pointing at a file of one-line prompt fragments, and every enabled slot contributes one line to a single output string. Two slots on and your prompt picks up two fragments. It exists because it replaces the eight-slot style subgraph inside the author's own KREA2_BATCH_WILD workflow, so the immediate audience is anyone who loaded that workflow and got missing-node errors. You don't need the workflow, though. If you keep style lists in files, this is one node instead of eight.

    How it works

    Three widgets per slot: enabled, style_file, read_mode (random, random_no_repeat, sequential, reverse). Per queue, the node walks slots 0 to 7, skips the disabled ones, reads the chosen file from disk and appends one line. Blank lines and lines starting with # are skipped, so you can comment in your own files. A slot that yields no line is ignored rather than erroring the run, and the parts are joined with ", " after trailing commas are stripped.

    The mechanism underneath is worth knowing: the class implements IS_CHANGED returning float("nan") - the standard ComfyUI idiom for "always re-execute me," since NaN compares unequal to itself and the cache check can never call the node clean. Without it, random and sequential would pick once and never advance. The cost is the usual one: the node is dirty every run and drags everything behind it along. So yes, "I queued again and it re-sampled everything" is this node working.

    The inputs and outputs that matter

    enabled, style_file, read_mode, eight sets of them. The dropdown carries 17 entries: none plus the shipped presets. Subfolders appear as forward-slash paths (Flux/POSES/crawling.txt), so organize as deep as you like.

    input_text is the one optional input, and it's a socket rather than a text box - you have to wire a string in. Put a PrimitiveString in front to type something, or use the pack's own LinePrompt_MasterLoad, which has the same read modes plus a freeze. Whatever you wire in goes first; the fragments follow.

    Two outputs, both strings: text is the assembled prompt, into the positive CLIP Text Encode, and selected_style_files names the files that actually supplied text this run - the answer to "that slot looks armed, so why is nothing in my prompt?"

    There's no seed and no freeze. random uses Python's global random, so it isn't reproducible and isn't tied to your KSampler seed. Capture the text output when a pick turns out well; the node has already forgotten it.

    Install

    cd ComfyUI/custom_nodes
    git clone https://github.com/AntiMatterComfy/antimatter-nodes
    

    Restart ComfyUI. That's all of it: dependencies = [] in the pack's pyproject.toml, so no pip step, no CUDA target, no model download. Stdlib Python reading text files.

    Try ComfyUI Manager first, but read the README before concluding anything. It says Install Missing Custom Nodes only works if the repo is discoverable by Manager - through the ComfyUI Registry or a PR to Manager's custom-node-list.json. The repo ships that metadata, so if Manager can't find "AntiMatter Nodes", that's expected rather than broken.

    Making the presets your own

    Files live at custom_nodes/antimatter-nodes/styles/krea2_batch_wild/, one non-empty, non-comment line per preset, subfolders fine. Two restart rules apply:

    • New or renamed files need a ComfyUI restart - the dropdown is built when ComfyUI imports the module, so nothing new appears until it re-imports.
    • Edited contents don't. The file is re-read on every execution, so a typo fix lands on your next queue.

    Presets must sit inside that folder: the node validates each style_file against it and rejects anything elsewhere, so an existing wildcard library has to be copied in, not referenced. Reading is UTF-8 with a BOM tolerated, so save as UTF-8.

    One header note on the shipped content. It's adult-oriented, and the fifth slot arrives with enabled already on - turn it off if you're just poking at the node. Those bundled lines also carry the old (detail:1.4) weighting syntax, which is inherited noise: on LLM-encoded models like Krea 2 (Qwen3-VL text encoder) weighting is gone, and those parentheses pass through as literal punctuation.

    Where it gets fiddly

    Check selected_style_files first when a slot looks armed but contributes nothing: empty there means the file had no usable line, usually a comment-only file or one that's just whitespace.

    Nothing de-duplicates across slots - the no-repeat pool is tracked per slot and per file, so two slots pointed at the same file can hand you the same line twice.

    Watch the length, too. Eight fragments plus your own text is a lot of comma-separated material, and stacking every slot dilutes more than it reinforces. The honest use case is batch exploration: sequential on one file to walk a list, random_no_repeat on another for subject detail, batch size high enough to compare. Small node, small job, no dependencies.

    CategoryAntiMatter/Text

    Inputs (25)

    NameTypeDefaultDescription
    enabledBOOLEANfalse
    style_fileCOMBO17_poses.txt17 options: none, 01_emotions_expressions.txt, 03_nsfw_body_focus_anatomy.txt, 09_sexy_outfits_clubwear_latex_leather.txt, 13_hairy_pussy_details.txt, 14_undressing.txt, +11
    read_modeCOMBOrandom4 options: random, random_no_repeat, sequential, reverse
    enabled_1BOOLEANfalse
    style_file_1COMBO01_emotions_expressions.txt17 options: none, 01_emotions_expressions.txt, 03_nsfw_body_focus_anatomy.txt, 09_sexy_outfits_clubwear_latex_leather.txt, 13_hairy_pussy_details.txt, 14_undressing.txt, +11
    read_mode_1COMBOrandom4 options: random, random_no_repeat, sequential, reverse
    enabled_2BOOLEANfalse
    style_file_2COMBO03_nsfw_body_focus_anatomy.txt17 options: none, 01_emotions_expressions.txt, 03_nsfw_body_focus_anatomy.txt, 09_sexy_outfits_clubwear_latex_leather.txt, 13_hairy_pussy_details.txt, 14_undressing.txt, +11
    read_mode_2COMBOrandom4 options: random, random_no_repeat, sequential, reverse
    enabled_3BOOLEANfalse
    style_file_3COMBO14_undressing.txt17 options: none, 01_emotions_expressions.txt, 03_nsfw_body_focus_anatomy.txt, 09_sexy_outfits_clubwear_latex_leather.txt, 13_hairy_pussy_details.txt, 14_undressing.txt, +11
    read_mode_3COMBOrandom4 options: random, random_no_repeat, sequential, reverse
    enabled_4BOOLEANfalse
    style_file_4COMBO09_sexy_outfits_clubwear_latex_leather.txt17 options: none, 01_emotions_expressions.txt, 03_nsfw_body_focus_anatomy.txt, 09_sexy_outfits_clubwear_latex_leather.txt, 13_hairy_pussy_details.txt, 14_undressing.txt, +11
    read_mode_4COMBOrandom4 options: random, random_no_repeat, sequential, reverse
    enabled_5BOOLEANtrue
    style_file_5COMBOFlux/POSES/crawling.txt17 options: none, 01_emotions_expressions.txt, 03_nsfw_body_focus_anatomy.txt, 09_sexy_outfits_clubwear_latex_leather.txt, 13_hairy_pussy_details.txt, 14_undressing.txt, +11
    read_mode_5COMBOrandom4 options: random, random_no_repeat, sequential, reverse
    enabled_6BOOLEANfalse
    style_file_6COMBOFlux/2GIRLS/2GIRL_FINGERING.txt17 options: none, 01_emotions_expressions.txt, 03_nsfw_body_focus_anatomy.txt, 09_sexy_outfits_clubwear_latex_leather.txt, 13_hairy_pussy_details.txt, 14_undressing.txt, +11
    read_mode_6COMBOrandom4 options: random, random_no_repeat, sequential, reverse
    enabled_7BOOLEANfalse
    style_file_7COMBO13_hairy_pussy_details.txt17 options: none, 01_emotions_expressions.txt, 03_nsfw_body_focus_anatomy.txt, 09_sexy_outfits_clubwear_latex_leather.txt, 13_hairy_pussy_details.txt, 14_undressing.txt, +11
    read_mode_7COMBOrandom4 options: random, random_no_repeat, sequential, reverse
    input_textoptSTRING

    Outputs (2)

    NameTypeDescription
    textSTRING
    selected_style_filesSTRING