Nodes/MiniMax-H3-Prompt-Rewriter-ComfyUI/MiniMax-H3 Guide Prompt (any LLM)
ComfyUI Node

MiniMax-H3 Guide Prompt (any LLM)

Get the MiniMax-H3 writing guide as prompt text — no model runs at all

By pytraveler·Created about a month ago·Updated a day ago· 170
MiniMax-H3 Guide Prompt (any LLM)
  • duration
  • aspect_ratio
  • system_prompt
  • user_prompt
  • prompt
prompt
taskT2VA
resolution16:9
reference_material
auto_downloadtrue
formatplain

Every guide-based writer in this pack works by putting MiniMax's writing guide in the system prompt and your idea in the user prompt. This node is just that plumbing, exposed: it builds system_prompt and user_prompt from the guide and hands them back as plain strings. No model runs, no VRAM is touched, no time is spent. It's the "bring your own LLM" escape hatch for the whole MiniMax-H3 prompt pipeline.

Why does that exist? Because the writer nodes are locked to their own GGUF runner, and you might already have a perfectly good language model in the loop - an API, an Ollama server, a remote box, or ComfyUI's own text generation. This node covers all five tasks, Ref2VA included, and produces the exact prompts the writers would have built. Wire them into whatever LLM node you already use and you get the same H3-shaped output from a model you already pay for or run elsewhere.

What it outputs

  • system_prompt - the guide, as a system message.
  • user_prompt - your prompt plus (for the frame tasks) the reference material and the alignment line.
  • prompt - both of them in one string, because most LLM nodes take exactly one. Including ComfyUI's own Generate Text, which since 0.30 runs a language model in ComfyUI's own process off a model loaded by CLIPLoader. That's the shortest route to this pack's output with no GGUF downloaded at all - Load CLIP → Generate Text → done.

Inputs that matter

  • task - all five: T2VA, I2VA, FL2VA, L2VA, Ref2VA. Ref2VA pulls the longer full-reference guide and its six-section output contract.
  • reference_material - what the reference frames or assets show, one per line. Required for Ref2VA; for the other frame tasks it's what anchors the rewrite to your images.
  • resolution / duration - folded into the user prompt so the model writes to your aspect ratio and length.
  • format - plain (default) or chatml. On plain the two prompts are joined with a blank line and the LLM node applies the model's own chat template, landing the whole guide in the user turn. On chatml the turns are written out yourself, so a Qwen text encoder takes the guide as a real system message. It's Qwen-shaped by construction - on Gemma or anything else, stay on plain.
  • auto_download - fetch the guide from MiniMax on first use (it's not bundled with the pack, for licence-territory reasons; ~16 KB / ~24 KB once).

Making Generate Text actually work

Three settings decide whether it does:

  • max_length ≈ 2048. Its default of 512 is the output budget, and six Ref2VA sections don't fit in 512 tokens. The pack's own writers use 2048 (max_new_tokens), and a measured Ref2VA rewrite stops on its own at roughly 580 tokens - inside 2048 with room to spare, and cut mid-section at 512.
  • thinking off. The guide asks for fields and nothing else; reasoning just spends the budget on prose you'd have to strip.
  • use_default_template on, format on plain.

The number to keep in your head: a full guide-based system prompt is ~10,240 tokens of context before the model writes a word. That's what decides whether a given encoder can take this at all - a 4B Qwen3-VL handled a Ref2VA rewrite in about 38 seconds, but the context budget is the thing to check first.

Install

Same pack, same story - ComfyUI Manager (search "MiniMax-H3") or:

cd ComfyUI/custom_nodes
git clone https://github.com/pytraveler/MiniMax-H3-Prompt-Rewriter-ComfyUI

This node installs nothing extra and downloads nothing on its own; the only fetch is the guide, on first use, under the auto_download switch.

Where people get burned

  • Skipping max_length. Default 512 output tokens silently chops the answer mid-section. Set it to ~2048.
  • chatml on a non-Qwen model. It's built around Qwen's <|im_start|> template. On Gemma or anything else the turns won't parse - leave format on plain and let the model's own template do the wrapping.
  • No model = no output. This node returns strings; it's not a generator. If nothing's wired to its outputs, nothing happens - which is the point, but it surprises people who expect a rewrite.
CategoryMiniMax-H3

Inputs (8)

NameTypeDefaultDescription
promptSTRING
taskCOMBOT2VARef2VA uses the full-reference guide and its six output sections.
resolutionCOMBO16:9Target aspect ratio the rewrite is composed for. It has no socket on purpose: a ratio arriving from the graph belongs on 'aspect_ratio', which reads the spellings other nodes use and overrides this while it is connected.
durationFLOAT,INT100.1–600Target clip length in seconds; drives shot count and pacing. Right-click the node for 'duration': the default value back, or a new upper end for the widget. It offers 30 seconds until you change it and the server takes up to 600, because a widget's range is fixed when the node is declared and one number cannot suit every graph -- MiniMax's own guide is written around clips of a few seconds, while the stretched pipelines the community has built run well past that. What you set is remembered with the workflow.
aspect_ratiooptSTRING,COMBOOptional, and it overrides the picker while something is connected. Reads a ratio ('16:9'), a frame size ('3840x1080') or a bare number ('1.78'), and a label around the pair is fine -- '3:4 (Portrait Standard)' reads as 3:4. A size within 2% of a listed ratio is called by its name, so 1376x768 arrives as 16:9 rather than as 43:24.
reference_materialoptSTRINGWhat the reference frames or assets show. Required for Ref2VA. List every reference asset, one per line: Picture 1: young woman, long dark hair, blue cardigan, seated by a window Video 1: source clip being edited — handheld walk down a night street Audio 1: voice-timbre reference for the woman
auto_downloadoptBOOLEANtrueFetch the guide from MiniMaxAI/MiniMax-H3 if it is not already in the ComfyUI user directory.
formatoptCOMBOplainHow the third output joins the two. 'plain' puts a blank line between them and lets the LLM node apply the model's own chat template, which lands the guide in the user turn. 'chatml' writes the turns out instead, so a Qwen text encoder takes the guide as a real system message and skips its thinking block; on a model that is not ChatML, leave this on 'plain'.

Outputs (3)

NameTypeDescription
system_promptSTRING
user_promptSTRING
promptSTRING