ComfyUI Node

Randoms Prompt

Eight random draws in one node

By clouddreamfly·Created about a year ago·Updated 8 months ago· 4
Randoms Prompt
    • text
    languageChinese
    classify1--
    classify2--
    classify3--
    classify4--
    classify5--
    classify6--
    classify7--
    classify8--
    seed0
    enabletrue
    input_prompt

    Generate Prompt draws one random phrase from one category. Randoms Prompt says: why stop at one? It gives you eight category slots - classify1 through classify8 - each independently drawing a random phrase from its dataset, all combined into a single comma-joined prompt from one seed. Set action, background, pose, light type, scenery and you get a full random scene description in a single node, which is the fastest route to "generate me fifty surprising prompts" that this pack offers.

    How it works

    Each slot maps to a category's JSONL file in assets/ (Chinese or English per language) and draws entry seed % dataset_length. Important detail: every slot uses the same seed - the source calls build.generate_prompt(seed) identically for each - so one seed drives all eight draws. That means it's fully reproducible: same seed, same eight phrases, every time. The enable toggle is a master switch: flip it off and the node outputs only the optional input_prompt text, useful for A/B testing whether the random block helps at all.

    Inputs that matter

    • classify1 through classify8 - the category dropdowns. Fill the ones you care about, leave the rest at --. Categories include the full 112-option list: action, age, animal, background, scenery, pose, and more.
    • seed - one seed for all draws. Bump to re-roll everything.
    • language, enable, input_prompt (optional) - standard pack controls; input_prompt is prepended to the combined result.

    One text output: input_prompt, phrase1, phrase2, …, phrase8, wired into your CLIP Text Encode.

    Install

    ComfyUI Manager → Custom Nodes Manager → search ComfyUI-PromptWrapper → Install → restart, or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/clouddreamfly/ComfyUI-PromptWrapper
    

    No downloads - all category datasets ship with the pack.

    Where people get burned

    Two things catch people. First, the output is still a bag of phrases, not a sentence - eight randomly drawn clauses joined by commas will often contradict each other (a "candlelit" light draw next to a "daylight" scenery draw). That's fine for exploration, but expect to curate. Second, because all slots share one seed, the draws aren't independent rolls - they're correlated by construction, so "random" here means "eight draws from the same dice", not eight dice. If you want each slot on its own seed, chain individual Generate Prompt nodes instead. And the standard pack note: default language is Chinese; switch to English for Western models.

    CategoryPromptWrapper

    Inputs (12)

    NameTypeDefaultDescription
    languageCOMBOChinese2 options: Chinese, English
    classify1COMBO--113 options: --, action, age, animal, animal ears, animal horn, +107
    classify2COMBO--113 options: --, action, age, animal, animal ears, animal horn, +107
    classify3COMBO--113 options: --, action, age, animal, animal ears, animal horn, +107
    classify4COMBO--113 options: --, action, age, animal, animal ears, animal horn, +107
    classify5COMBO--113 options: --, action, age, animal, animal ears, animal horn, +107
    classify6COMBO--113 options: --, action, age, animal, animal ears, animal horn, +107
    classify7COMBO--113 options: --, action, age, animal, animal ears, animal horn, +107
    classify8COMBO--113 options: --, action, age, animal, animal ears, animal horn, +107
    seedINT00–18446744073709550000
    enableBOOLEANtrue
    input_promptoptSTRING

    Outputs (1)

    NameTypeDescription
    textSTRING