CharacterPromptSelect
Put characters where you want them in NAI4
- CharacterPrompt
This node exists for one specific feature: NovelAI's nai-diffusion-4 "character position" control, where you tell the model who is in the image and roughly where on the canvas they are. Character_Prompt_Select (shown as CharacterPromptSelect) is a small form for building that list - up to five characters, each with a positive prompt, a negative, and an x/y position. You feed its output into the characterPrompts input of NovelAI_Request_Payload.
It's the closest thing this pack has to a gimmick node, and it's worth understanding before you get excited: it only does anything on the nai-diffusion-4 models, and it's really a convenience wrapper around NovelAI's own v4 caption structure rather than a new control that ComfyUI adds on top.
How it works
Under the hood each character becomes a small object with a prompt, a uc (the negative), and a center position. When the payload builder turns that into the v4 request, it produces the v4_prompt/v4_negative_prompt caption structure NovelAI expects: a base_caption (your main prompt) plus a list of char_captions, each with its own center coordinates. In other words, the node is generating the exact JSON shape NovelAI's v4 models were trained on - the same one their web UI produces when you drag characters onto the canvas.
The inputs that matter
The node is a form with five near-identical slots. Only character 1 is required; characters 2–5 each have an enable toggle (character2_enable, etc.) that decides whether the slot counts at all.
- character1 / character2 / … - the character's tag, in Danbooru-style naming. The defaults are dead giveaways:
firefly_(honkai:_star_rail)andkafka__(honkai:_star_rail). That double-underscore in Kafka's tag is real and looks like a typo - it's actually a pretty good test of how literal these models are. The tag has to match the model's vocabulary, so don't freeform it. - character1_uc / … - the negative for that character. The default is literally the string
negative_prompt, which is a placeholder, not a command; replace it with a real negative if you want one. - character1_x / character1_y - the position, as normalized 0–1 coordinates (0.5, 0.5 is dead center). The defaults put character 1 center and character 2 off to the left; the v4 feature is about rough placement, not pixel precision.
Its one output, CharacterPrompt, is a LIST that wires into NovelAI_Request_Payload's characterPrompts input.
Install
Same as the rest of the pack - one install, six nodes:
cd ComfyUI/custom_nodes
git clone https://github.com/DiaoDaiaChan/ComfyUI_API_Request
or find "ComfyUI_API_Request" in ComfyUI Manager. Restart, and you're done. No model files, because the model is running on NovelAI's side.
Common issues
Two ways to be confused here. First, the feature is silently inert on non-v4 models - nai-diffusion-3 and nai-diffusion-2 don't take character positions, so this whole node becomes decoration. Second, empty character slots don't get included in the payload, but an enabled slot with an empty prompt will ship a character caption with nothing in it, which can do weird things to composition. If you're not using a slot, leave it disabled. And remember the x/y numbers are relative to the full canvas, so a position that works at 832×1216 still lands in the same relative spot at other resolutions.
Inputs (24)
| Name | Type | Default | Description |
|---|---|---|---|
| character1 | STRING | firefly_(honkai:_star_rail) | — |
| character1_uc | STRING | negative_prompt | — |
| character1_x | FLOAT | 0.50 | — |
| character1_y | FLOAT | 0.50 | — |
| character2_enableopt | BOOLEAN | true | — |
| character2opt | STRING | kafka__(honkai:_star_rail) | — |
| character2_ucopt | STRING | negative_prompt | — |
| character2_xopt | FLOAT | 0.10 | — |
| character2_yopt | FLOAT | 0.50 | — |
| character3_enableopt | BOOLEAN | false | — |
| character3opt | STRING | — | |
| character3_ucopt | STRING | negative_prompt | — |
| character3_xopt | FLOAT | 0.10 | — |
| character3_yopt | FLOAT | 0.50 | — |
| character4_enableopt | BOOLEAN | false | — |
| character4opt | STRING | — | |
| character4_ucopt | STRING | negative_prompt | — |
| character4_xopt | FLOAT | 0.10 | — |
| character4_yopt | FLOAT | 0.50 | — |
| character5_enableopt | BOOLEAN | false | — |
| character5opt | STRING | — | |
| character5_ucopt | STRING | negative_prompt | — |
| character5_xopt | FLOAT | 0.10 | — |
| character5_yopt | FLOAT | 0.50 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| CharacterPrompt | LIST | — |