Nodes/Bjornulf_custom_nodes/๐Ÿ”ง๐Ÿ‘จโ€๐Ÿ”ง๐Ÿ“ Text Generator (Object for Character)
ComfyUI Node

๐Ÿ”ง๐Ÿ‘จโ€๐Ÿ”ง๐Ÿ“ Text Generator (Object for Character)

Give your character something to hold

By justUmenยทCreated 2 years agoยทUpdated about a year agoยท 545
๐Ÿ”ง๐Ÿ‘จโ€๐Ÿ”ง๐Ÿ“ Text Generator (Object for Character)
  • add_GEN_OBJECT
  • GEN_OBJECT
โ—„object_selectionโ–พโ–บ
โ—„custom_objectโ–บ
โ—„CUSTOM_PROMPT_PREFIXโ–บ
โ—„CUSTOM_PROMPT_SUFFIXโ–บ

Part of the pack's Text Generator family - a set of feeder nodes (character, outfit, scene, style, pose, object) that each build one fragment of a prompt and merge into a main node. This one's job is narrow and specific: give your character something to hold or interact with. The author's own tutorial example is a good illustration of why this exists as a separate node rather than being baked into the character generator - it's meant to connect through a pose node, so the object and the action are tied together instead of just floating independently in the prompt ("holds a book" reads very differently from "book" and "holding" as two disconnected phrases).

How it works

object_selection gives you a big list of preset objects - swords, staffs, wands, books, scrolls, potions, daggers, bows, and dozens more - or you can set it to CUSTOM and type your own into custom_object. Beyond picking the object itself, CUSTOM_PROMPT_PREFIX and CUSTOM_PROMPT_SUFFIX let you wrap extra description around it - text before and after the object phrase - without having to rebuild the whole sentence yourself. The optional add_GEN_OBJECT input lets you chain a second object node in, the same chaining pattern the rest of the Text Generator family uses, in case a character needs to be holding more than one thing.

The inputs and outputs that matter

  • object_selection (enum, 77 choices including CUSTOM) - the object itself. Pick from the preset list, or choose CUSTOM to type your own.
  • custom_object (STRING) - only matters when object_selection is set to CUSTOM.
  • CUSTOM_PROMPT_PREFIX / CUSTOM_PROMPT_SUFFIX (STRING, multiline) - extra text wrapped before and after the object description.
  • add_GEN_OBJECT (optional) - chain in a second object node.
  • Output: GEN_OBJECT - feeds into a pose node or the main Text Generator node to actually show up in your final prompt.

How to install it

Via ComfyUI Manager: search Bjornulf_custom_nodes, install, restart. Manually:

cd ComfyUI/custom_nodes
git clone https://github.com/justUmen/Bjornulf_custom_nodes
cd Bjornulf_custom_nodes && pip install -r requirements.txt

then restart ComfyUI. No special dependency for this specific node - it's a dropdown/text builder - but it's part of the same repo as the rest of the pack, so the shared requirements.txt gets installed regardless.

Common issues & troubleshooting

The object shows up in the prompt but the character isn't actually holding it. That's a prompt-adherence problem with your checkpoint, not this node - the object description on its own is just text describing an item, and getting a model to render a character actively interacting with it (rather than the object floating nearby or ignored) generally needs it chained through a pose node so the action and the object read together. If your checkpoint struggles with that even after chaining, it's a known limit of prompt-only object placement, worth accepting rather than fighting with more prompt text.

Set object_selection to CUSTOM but nothing appears. Double check custom_object actually has text in it - the preset dropdown value is ignored once you pick CUSTOM, so an empty custom_object field means the node effectively contributes nothing.

This node's output never shows up in your image. Same as with the rest of the Text Generator family - nothing happens unless GEN_OBJECT eventually reaches the pack's main Image Text Generator node. Check that the chain is actually connected end to end.

CategoryBjornulf

Inputs (5)

NameTypeDefaultDescription
object_selectionCOMBO77 options: CUSTOM, sign, paper, sword, shield, staff, +71
custom_objectSTRINGโ€”
CUSTOM_PROMPT_PREFIXSTRINGโ€”
CUSTOM_PROMPT_SUFFIXSTRINGโ€”
add_GEN_OBJECToptGEN_OBJECT,STRINGโ€”

Outputs (1)

NameTypeDescription
GEN_OBJECTGEN_OBJECT,STRINGโ€”