XB-llama - ✨ 提示词增强预设
Model-specific system prompts, one dropdown at a time
- system_prompt
Here's the thing nobody tells you about "just have an LLM write my prompt": every image model wants its prompt in a different dialect. Flux.2 Klein wants flowing natural language. Animagine XL wants a clean comma-tag list with no weighted-parenthesis syntax. Pony wants its tags done a certain way. LTX video wants a structured cinematic description. XB_llamaPromptEnhancer is a dropdown of 38 ready-made system prompts, one per model family, that tells your local LLM exactly how to phrase its output for the model you're about to feed. You pick the target, wire the resulting system_prompt into XB_llamaInstruct, and the local model does the enhancement in the right dialect.
It's the community's prompt-engineering pattern from the KB distilled into a widget: translate your rough idea into the structured form your target model was trained to read. The LLM writes it, the encoder reads it, everyone's speaking the same language.
What's in the menu
The presets cover the 2026 model landscape in EN and ZH variants: Animagine XL, Boogu T2I, ERNIE-Image T2I, Flux.2 (T2I and I2I), Flux.2 Klein (T2I and I2I), Ideogram 4.0, Krea2, LTX2.3 T2V, Lumina-Next, Pony V6 XL, Qwen-Image 2512, Qwen-Image-Edit 2511, Wan (T2V, I2V, I2V Full-Auto, FLF2V), and Z-Image Turbo. Each is a hand-tuned system prompt in the pack's support_llama/presets/ folder - the Wan I2V ones, for example, encode the structured prompt format those video models expect.
The single input and output
- preset - the dropdown. That's it, nothing else.
- Output: system_prompt - a
STRINGthat goes into thesystem_promptinput onXB_llamaInstruct.
That's the entire node. It builds text; it does no inference. The actual enhancement happens when you wire this into an instruct node along with your rough idea.
Installing it
Part of XB_ToolBox - ComfyUI Manager (XB_ToolBox) or git clone, then restart. The node itself needs no dependencies, but it's only useful with the llama stack running - that means llama-cpp-python installed (see XB_llamaModelLoader for the CUDA/ROCm install) and a model in models/LLM.
How to actually use it
The clean workflow: XB_llamaPromptEnhancer (pick e.g. "Flux.2 Klein T2I [EN]") → its system_prompt into XB_llamaInstruct's system_prompt → your rough text in custom_prompt → the enhanced prompt out to the CLIP text encoder. If your target model isn't in the list, the generic "Creative - Refine & Expand Prompt" preset on the instruct node is the fallback.
Two things to watch. First, the preset sets the format the LLM should emit, but it doesn't guarantee the LLM obeys - a small uncensored 8B will occasionally drift out of format, and that leak lands in your conditioning (the KB's LLM-in-ComfyUI essay calls this the dirty-output failure mode). Second, an enhancer is a convenience, not a writer: it removes the blank-page problem and adds detail, but left unconstrained it adds detail you never asked for. The preset scopes the job; if the output runs away from your intent, tighten your own custom_prompt rather than trusting the enhancement alone.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| preset | COMBO | 38 options: Animagine XL [EN], Animagine XL [ZH], Boogu T2I [EN], Boogu T2I [ZH], ERNIE-Image T2I [EN], ERNIE-Image T2I [ZH], +32 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| system_prompt | STRING | — |