Nodes/Sage Utils/Construct LLM Prompt Extra
ComfyUI Node

Construct LLM Prompt Extra

The detail toggles that make an LLM describe like a photographer

By arcum42·Created 2 years ago·Updated 28 days ago· 33
Construct LLM Prompt Extra
    • extra
    extra_instructions
    describe_actionsfalse
    describe_moodfalse
    describe_settingfalse
    include_anomaliesfalse
    include_camera_detailsfalse
    include_contextfalse
    include_cultural_referencesfalse
    include_emphasis_on_detailsfalse
    include_lightingfalse
    include_marksfalse
    include_materialsfalse
    include_motionfalse
    include_reflectionsfalse
    include_scalefalse
    include_symmetryfalse
    include_time_of_dayfalse
    include_weatherfalse

    If Construct LLM Prompt is the "what do you want the LLM to do" node, Construct LLM Prompt Extra is the "how detailed should the description get" node. It's the companion piece that assembles the detail instructions: mood, lighting, camera details, materials, weather, time of day - the layer of specificity that turns a generic caption into something a text-to-image model can actually render.

    The interface is a wall of booleans, and that's the feature. Toggle on describe_mood, describe_setting, describe_actions, include_lighting, include_camera_details, include_materials, include_motion, include_weather, include_time_of_day, include_reflections, include_symmetry, include_scale, include_context, include_anomalies, include_cultural_references, include_emphasis_on_details... each one appends a pre-written instruction line telling the LLM to cover that dimension. Plus extra_instructions, a multiline free-text field for anything the toggles don't cover. The output is a single extra string with the enabled instructions joined together.

    Mechanically it's the same text-assembly pattern as its sibling: read the config in llm_prompts.json, concatenate the canned instruction for each enabled toggle, append your free text. Where it differs is division of labor: Construct LLM Prompt pulls its toggles from the "style / quality / content focus" categories, while this node draws from the "detail" category (and any others those don't cover). Together they're meant to be joined - main instruction from one, detail layer from the other - and the pack's LLM workflow usually feeds the combined result into the chat tab or an LLM text-generation node.

    The same honest caveats apply as the parent node. The LLM features are the part of Sage Utils the README calls work in progress, and the pack logs connection warnings at startup when LM Studio or Ollama aren't running - harmless, silenced with SAGEUTILS_LOG_LEVEL=WARNING. But this node, like its sibling, is pure string construction: it works with zero LLM configured. You can build the instruction, copy it, and use it with any model anywhere.

    One real opinion, since you're here: the detail toggles shine with vision models. If your local LLM can look at an image, feeding it a reference image plus "include lighting, describe mood, include camera details" produces the kind of rich caption that's actually useful for img2img or training data - the difference between "a woman standing in a room" and something you could feed back into a prompt and get close to the source. The toggles are the difference between the two outputs.

    Install

    ComfyUI Manager → search Sage Utils → install → restart. Manual:

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

    Restart ComfyUI. No extra dependencies beyond the pack's dynamicprompts. Optionally run ollama pull llama3.2 or set up LM Studio if you want to actually feed the result to a local model.

    CategorySage Utils/LLM

    Inputs (18)

    NameTypeDefaultDescription
    extra_instructionsSTRINGExtra instruction text to include with the prompt.
    describe_actionsBOOLEANfalseDescribe Actions
    describe_moodBOOLEANfalseDescribe Mood
    describe_settingBOOLEANfalseDescribe Setting
    include_anomaliesBOOLEANfalseInclude Anomalies
    include_camera_detailsBOOLEANfalseInclude Camera Details
    include_contextBOOLEANfalseInclude Context
    include_cultural_referencesBOOLEANfalseInclude Cultural References
    include_emphasis_on_detailsBOOLEANfalseEmphasize Details
    include_lightingBOOLEANfalseInclude Lighting
    include_marksBOOLEANfalseInclude Marks
    include_materialsBOOLEANfalseInclude Materials
    include_motionBOOLEANfalseInclude Motion
    include_reflectionsBOOLEANfalseInclude Reflections
    include_scaleBOOLEANfalseInclude Scale
    include_symmetryBOOLEANfalseInclude Symmetry
    include_time_of_dayBOOLEANfalseInclude Time of Day
    include_weatherBOOLEANfalseInclude Weather

    Outputs (1)

    NameTypeDescription
    extraSTRINGThe generated extra instructions for the LLM.