Nodes/PromptPrism πŸŒˆβƒ€/Character Prompt Merger πŸŒˆβƒ€
ComfyUI Node

Character Prompt Merger πŸŒˆβƒ€

Reassemble a character prompt from just the parts you want β€” no API keys, no network

By BewinxedΒ·Created 2 years agoΒ·Updated about a year agoΒ· 0
Character Prompt Merger πŸŒˆβƒ€
  • character
  • tags
β—„delimiter,β–Ί
β—„enable_qualitytrueβ–Ί
β—„weight_quality1.0β–Ί
β—„enable_clothestrueβ–Ί
β—„weight_clothes1.0β–Ί
β—„enable_hairtrueβ–Ί
β—„weight_hair1.0β–Ί
β—„enable_eyestrueβ–Ί
β—„weight_eyes1.0β–Ί
β—„enable_facetrueβ–Ί
β—„weight_face1.0β–Ί
β—„enable_expressiontrueβ–Ί
β—„weight_expression1.0β–Ί
β—„enable_bodytrueβ–Ί
β—„weight_body1.0β–Ί
β—„enable_posetrueβ–Ί
β—„weight_pose1.0β–Ί
β—„enable_accessoriestrueβ–Ί
β—„weight_accessories1.0β–Ί
β—„enable_backgroundtrueβ–Ί
β—„weight_background1.0β–Ί
β—„enable_compositiontrueβ–Ί
β—„weight_composition1.0β–Ί
β—„enable_gendertrueβ–Ί
β—„weight_gender1.0β–Ί
β—„enable_speciestrueβ–Ί
β—„weight_species1.0β–Ί
β—„enable_agetrueβ–Ί
β—„weight_age1.0β–Ί
β—„enable_nametrueβ–Ί
β—„weight_name1.0β–Ί
β—„override_quality πŸŒŸβ€”β–Ί
β—„override_clothes πŸ‘—β€”β–Ί
β—„override_hair πŸ’‡β€”β–Ί
β—„override_eyes πŸ‘€β€”β–Ί
β—„override_face β€”β–Ί
β—„override_expression πŸ˜Šβ€”β–Ί
β—„override_body πŸ‘€β€”β–Ί
β—„override_pose πŸ•Ίβ€”β–Ί
β—„override_accessories πŸ•ΆοΈβ€”β–Ί
β—„override_background πŸžοΈβ€”β–Ί
β—„override_composition πŸ–ΌοΈβ€”β–Ί
β—„override_gender πŸš»β€”β–Ί
β—„override_species πŸΎβ€”β–Ί
β—„override_age β€”β–Ί
β—„override_name β€”β–Ί
β—„prefixβ€”β–Ί

The Character Prompt Merger is the quiet half of the PromptPrism pack, and it's the half you'll actually live in. The Parser does the clever - and paid - work of splitting a prompt into categories. The Merger takes that structured character object and reassembles exactly the categories you want into one flat tag string. No API keys, no network, no per-run cost. Just string math over whatever the parser handed you.

What it's for

Think character-sprite or Visual Novel work. You build a "base character" once - hair, eyes, face, body, species - then per scene you toggle on pose, background, composition and whatever outfit that scene needs, and leave the rest off. Or parse two characters and merge pieces of each. The README's example is exactly that second move: parse a second prompt and pull only the elements you want from it to combine with the first. That's the pattern this node exists to make painless.

How it works

It walks the 15 categories from the character object. For each one: if its enable_ toggle is on, it takes the tags from the object - unless you've wired an override_ input, which replaces them outright. Empty tags get dropped. If the category's weight isn't 1.0, every tag in that category gets a tag:1.2-style weight appended. Then everything is joined with the delimiter plus a space, and your prefix is stuck on the front.

The inputs that matter

  • character - the CHARACTER socket from the Parser. This is the one beginners trip on: the Merger does not work standalone. Drag one in without a parser feeding it and there's nothing to merge.
  • delimiter - default ,. Tags come out tag1, tag2, tag3.
  • enable_<category> and weight_<category> - 15 of each. Toggles decide whether a category appears at all; weights (0–10, default 1) scale its tags. Use a weight below 1 to downplay a category instead of deleting it.
  • override_<category> (optional) - wire a string node in and it replaces the parsed tags for that category. Handy for "same character, but this scene she's wearing X."
  • prefix (optional) - a string prepended to the whole result, if you want something like solo, before the assembled tags.

The output

One tags string, nothing more. It feeds a CLIPTextEncode (or any string-combining node) and from there into your sampler. Because the merger is pure text assembly, you can batch variations without touching the parser or spending another API call.

Two quirks worth knowing (both real, both in the source)

  • Leave prefix empty and your output starts with a stray ", ". The code unconditionally emits prefix + delimiter + tags, so with no prefix you get a leading comma. Feed a prefix or strip it downstream - cosmetic, but it'll confuse you the first time.
  • The weight syntax is CLIP-style attention weighting: blue_hair:1.2. Exactly right for Pony/Illustrious/NoobAI, and meaningless on LLM-encoded models, where the colon passes through as literal punctuation. Know which lineage your checkpoint is on before you bother with weights.

And if you toggle every category off, the output is a bare ", " - an empty prompt in disguise. Keep at least one category on.

Install

Same pack as the Parser - ComfyUI Manager (search "PromptPrism"), or:

cd ComfyUI/custom_nodes
git clone https://github.com/Bewinxed/PromptPrism.git
cd PromptPrism
pip install -r requirements.txt

Then restart ComfyUI. The Merger itself adds no extra dependencies and downloads no models; the install cost is the pack's shared LiteLLM/Instructor stack, which the Parser needs anyway.

Worth the setup? If you're doing character-consistent batch work on a tag-based model, yes - it turns "same girl, different scene" from a copy-paste chore into a toggle. If you only generate one-off images, skip it: the Merger is useless without a parser upstream, and the parser is the part that costs you money per run.

Categorymergers

Inputs (48)

NameTypeDefaultDescription
characterCHARACTERβ€”
delimiterSTRING,β€”
enable_qualityBOOLEANtrueβ€”
weight_qualityFLOAT1.00–10β€”
enable_clothesBOOLEANtrueβ€”
weight_clothesFLOAT1.00–10β€”
enable_hairBOOLEANtrueβ€”
weight_hairFLOAT1.00–10β€”
enable_eyesBOOLEANtrueβ€”
weight_eyesFLOAT1.00–10β€”
enable_faceBOOLEANtrueβ€”
weight_faceFLOAT1.00–10β€”
enable_expressionBOOLEANtrueβ€”
weight_expressionFLOAT1.00–10β€”
enable_bodyBOOLEANtrueβ€”
weight_bodyFLOAT1.00–10β€”
enable_poseBOOLEANtrueβ€”
weight_poseFLOAT1.00–10β€”
enable_accessoriesBOOLEANtrueβ€”
weight_accessoriesFLOAT1.00–10β€”
enable_backgroundBOOLEANtrueβ€”
weight_backgroundFLOAT1.00–10β€”
enable_compositionBOOLEANtrueβ€”
weight_compositionFLOAT1.00–10β€”
enable_genderBOOLEANtrueβ€”
weight_genderFLOAT1.00–10β€”
enable_speciesBOOLEANtrueβ€”
weight_speciesFLOAT1.00–10β€”
enable_ageBOOLEANtrueβ€”
weight_ageFLOAT1.00–10β€”
enable_nameBOOLEANtrueβ€”
weight_nameFLOAT1.00–10β€”
override_quality 🌟optSTRINGβ€”
override_clothes πŸ‘—optSTRINGβ€”
override_hair πŸ’‡optSTRINGβ€”
override_eyes πŸ‘€optSTRINGβ€”
override_face optSTRINGβ€”
override_expression 😊optSTRINGβ€”
override_body πŸ‘€optSTRINGβ€”
override_pose πŸ•ΊoptSTRINGβ€”
override_accessories πŸ•ΆοΈoptSTRINGβ€”
override_background 🏞️optSTRINGβ€”
override_composition πŸ–ΌοΈoptSTRINGβ€”
override_gender 🚻optSTRINGβ€”
override_species 🐾optSTRINGβ€”
override_age optSTRINGβ€”
override_name optSTRINGβ€”
prefixoptSTRINGβ€”

Outputs (1)

NameTypeDescription
tagsSTRINGβ€”