XB-llama - ✨ 分镜增强预设
Turn a story idea into a frame-by-frame storyboard prompt
- system_prompt
Storyboarding is where the "prompt engineer" title actually earns its keep. One scene needs a camera logic, a consistent art style, a locked character, and N separate frame prompts that all stay visually coherent - and doing that by hand, per frame, is exactly the kind of repetitive work an LLM is good at once you've told it how. XB_llamaStoryboardEnhancer builds that system prompt for you: pick the target model's dialect, the art style, the camera logic, and how many frames you want, and it assembles a complete storyboard-generation prompt your local LLM can execute. It's the "enhancer" preset, which means it only builds the system prompt - the actual storyboard generation happens when you wire it into XB_llamaInstruct.
The inputs
- model_target - the syntax rules to inject. The tooltip says it plainly: Flux2-Klein gets natural-language prose flow, Qwen-Edit gets structured DiT flow (Wan/LTX video-camera flow and Animagine/Pony tag flow are in the full rules, though this node's menu currently exposes the image-edit pair).
- story_style - 12 global art styles, from Fairy Tale Illustration to Cyberpunk to Popmart blind-box clay to "Wes Anderson symmetry" to Akira Toriyama retro anime. Each binds the global look, lighting and palette so the frames don't drift apart.
- camera_logic - 5 shot-assembly logics: Static (single space, tightening shots), Tracking (locked on the protagonist), Epic (large scene jumps), Dialogue (psychological distance), and Journey (multi-scene flow).
- character_anchor - describe the protagonist ("a white fluffy rabbit in blue overalls and a straw hat"). The tooltip marks this as strongly recommended - it's the consistency anchor across frames.
- frame_count - 2–16 frames. 4 for a comic page, 6–8 for a short video, 12–16 for a video pre-vis.
- language - English or Chinese output.
- user_story - your story/idea text. Required - the node raises an error if it's empty.
Output
One system_prompt wire → XB_llamaInstruct.system_prompt. Your story is already baked into the instructions, so custom_prompt on the instruct node can stay minimal or empty.
Installing it
Part of XB_ToolBox - ComfyUI Manager (XB_ToolBox) or:
cd ComfyUI/custom_nodes
git clone https://github.com/WJLUOXIAO/XB_ToolBox.git
restart. Node needs no dependencies; using the output needs the llama stack (llama-cpp-python + model in models/LLM).
How to use it, and the traps
The intended flow is: this node → instruct (with XB_llamaParameters for the format-tight defaults) → the frame prompts on output_list → XB_ListDispatcher to fan each frame to its own CLIP Text Encode. That's the whole "LLM storyboards, ComfyUI draws it" pipeline in one chain.
The traps: (1) model_target matters - a prose-style prompt generated for Flux2-Klein will fight an anime tag model, so match it to your actual generation model. (2) The "自定义 (No Style Constraint)" style option exists precisely because style locking can over-constrain - use it when your own story text carries the style. (3) Small local models love to drop a character's traits by frame 3; the character_anchor is the mitigation, and it only works if you actually fill it in. (4) Since this node only builds the prompt, the usual LLM caveats apply downstream - format drift, subject drift, and the fact that an enhancer removes the blank page rather than writing the story for you.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| model_target | COMBO | Flux2-Klein | 选择目标生成模型, 后台自动注入对应的语法规则。 Flux2-Klein: 自然语言散文流 Qwen-2511: 结构化 DiT 流 Wan/LTX: 视频运镜流 Animagine/Pony: 二次元标签流 |
| story_style | COMBO | 治愈绘本 (Fairy Tale Illustration) | 强制绑定全局美术风格、光影基调和色彩方案, 防止风格跑偏 |
| camera_logic | COMBO | 固定场景演绎 (Static) | 镜头组接逻辑: 控制空间变换方式和景别推进节奏 固定场景: 单一空间, 景别收缩 动态跟随: 锁定主角, 空间流动 史诗跳跃: 大尺度场景跳跃 情感对话: 心理距离驱动 |
| character_anchor | STRING | — | |
| frame_count | INT | 62–16 | 生成的分镜帧数 (2~16) 四格漫画用4帧, 短视频用6~8帧, 长视频预演用12~16帧 |
| language | COMBO | 英文[EN] | 输出提示词的语言 English: 英文输出 (兼容所有模型) 中文: 中文输出 (适合 Qwen-Image / ERNIE-Image 等中文原生模型) |
| user_story | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| system_prompt | STRING | — |