Nodes/Visual Prompt Library/Visual Prompt Picker
ComfyUI Node

Visual Prompt Picker

Remembering prompts is a losing game — pick them from thumbnails instead

By kazuya-bros·Created 3 months ago·Updated 3 months ago· 0
Visual Prompt Picker
    • prompt
    delimiter,
    preview_prompt

    You know the workflow. You spent an afternoon dialing in the exact expression, the camera angle, the lighting phrase that makes a character look right - and three days later you're staring at a plain text prompt box trying to remember whether it was "low angle view" or "dynamic perspective" that did it. Wildcards solve variety by randomizing. This node solves a different problem: remembering what a prompt fragment looks like, and picking it deliberately from a picture.

    Visual Prompt Picker is the centerpiece of the Visual Prompt Library pack, and the name is a bit of a lie in the best way - there's no model, no API, no key, nothing to download. It's a thumbnail browser that lives inside a ComfyUI node. You build a personal dictionary of prompt parts (expressions, poses, lighting, camera composition, backgrounds), give each one a picture, and click the cards you want. The node stitches the chosen fragments into a single string and hands it to the graph. For the tag-style models most people run now - Illustrious and Noobai lineage, where prompts are comma-separated booru tags - this is genuinely nice, because "the exact tag string that produces this face" is exactly the kind of thing you can't remember from text.

    How it works

    The Python side is almost embarrassingly simple. VisualPromptPicker.build_prompt reads the fragments you've selected, joins their prompt text with the delimiter string, and emits the result as a STRING. All the real machinery is the frontend: a card grid rendered inside the node, a search box, and a library loader that talks to a tiny REST API the pack adds at /visual_prompt_library. Click a card to toggle it on; click again to drop it. The selection is stored as hidden state inside the node, and an IS_CHANGED hash makes sure changing your picks actually re-runs it instead of sitting on ComfyUI's cache. Your dictionaries live as JSON files under the pack's data/libraries/ folder, and a separate Visual Prompt Library sidebar tab is where you edit them - add categories like "表情" (expression), "画角" (camera angle), or "lighting," then parts with a label, the prompt text, and an optional thumbnail you can upload, paste as a data URL, or pull from your recent ComfyUI output.

    The inputs that matter

    Honestly, there's one real setting. The rest is clicking.

    • delimiter - the string used to join selected fragments. Default ", " is exactly right for booru-tag models. Set it to a newline or a space if your model prefers sentences.
    • preview_prompt - a live preview of the joined text, auto-filled as you click cards. Here's the trap: typing in it does nothing. The backend rebuilds the output from your selections and ignores whatever you type, so treat it as a readout, not an input.
    • Output prompt - a single STRING. Wire it into the positive input of a CLIP Text Encode node and you're done.

    One thing to know up front: each dictionary entry has a negative field in the editor, but the picker does not emit it. The output is positive-prompt text only. If you want negatives tied to your picks, you'll be wiring a second node.

    Install

    No dependencies, no models, no key - it's stdlib Python plus one JS folder, and pyproject.toml lists zero deps. Either use ComfyUI Manager and search "Visual Prompt Library," or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/kazuya-bros/ComfyUI-VisualPromptLibrary.git
    

    Restart ComfyUI. If the UI doesn't show up but the node loads, hard-reload the browser - the README says JS-only changes usually just need that.

    Where people get burned

    • Your libraries are local-only. They live in data/libraries/, which is gitignored so updates won't wipe them - but reinstall the pack from scratch and they're gone. Back the folder up if you care.
    • This node is enormous. The frontend clamps it to at least ~820px tall. It's a UI, not a lightweight value node; plan your canvas space.
    • It's brand new. Version 0.1.0, zero community footprint at the time of writing. Don't expect a polished issue tracker history - you're an early adopter.

    It won't replace wildcards (that's the randomize-y thing) and it won't write prompts for you. It's a manual visual dictionary, and for the fragments you keep forgetting, it's the one I'd reach for.

    Categoryprompt/visual

    Inputs (2)

    NameTypeDefaultDescription
    delimiterSTRING,
    preview_promptSTRING

    Outputs (1)

    NameTypeDescription
    promptSTRING