MiniMax H3 Prompt Enhancer (Cloud / Local GGUF)
Turn one sentence into a MiniMax H3 prompt that actually follows the rules
- first_frame
- last_frame
- reference_images
- reference_videos
- provider_config
- enhanced_prompt
MiniMax H3 is the open-weight video model that launched to a chorus of "unbelievably good," and its one grumpy requirement is that you prompt it the way its docs insist. Not "a woman walks through a neon street." Proper H3 form - [Shot N], strict timestamps, a speaker contract, a soundscape field the model actually expects by name. Hand it sloppy prose and you'll get a fine-looking clip that quietly ignores half of what you meant.
This node is the translation layer. You type the rough idea, it pays an LLM to rewrite it into official H3 shape, and you get one enhanced_prompt STRING to feed into your H3 generation node. It's a prompt enhancer, not a generator - it operates on text, upstream of the sampler, which is the entire point.
How it works
The task_type dropdown picks the H3 format you're aiming at: T2VA (text to audio-video), I2VA (first-frame), FL2VA (first + last frame), L2VA (last frame only), or Ref2VA (reference images/videos). The official core h3-prompt-writing skill is always baked in, pinned to a fixed upstream commit, so details like (S1) speaker tags, <scenetrans> for cross-cut dialogue and <cutoff> for end-of-clip cutoffs come out right without you knowing the syntax. shot_count goes AUTO or a fixed 1–20; a fixed number becomes a hard "write exactly this many [Shot N]" instruction, though the model is allowed to miss. rewrite_mode (strict / balanced / creative) maps to temperatures 0.2 / 0.7 / 1.2 - creative is where the writing gets visibly punchier.
Beyond the core there's optional flavor: 8 official scene presets (product ad, 3D short, paper-collage explainer, the official music-video subtitle generator, and more) and a library of 190 "case templates" that transplant structure and pacing from real published clips without copying their characters or plot. The two dropdowns are easy to ignore; the core does the job alone.
The inputs that actually matter
On a first run you set four things: prompt (the only required field), task_type, shot_count or duration_seconds, and rewrite_mode. output_language defaults to 中文 - flip it to English if that's how you prompt. If you picked anything but T2VA, wire the matching first_frame, last_frame, reference_images (up to 9) or reference_videos (up to 3) sockets, and the LLM genuinely looks at them. reference_context and constraints are folded away for good reason: they exist for facts the pixels can't tell it (who's who, what must not change). Leave them alone until you hit a case they solve.
There are four channels behind api_mode:
- 贞贞平价小屋 (default):
https://api.seedance.nz, fixed vision modelbytedance/doubao-seed-evolving. - 贞贞的 AI 工坊:
https://ai.t8star.org/v1/chat/completions, defaultgemini-3.5-flash. - OpenAI compatible: your own base URL + model ID, for whichever provider you already pay.
- 本地 GGUF:
ComfyUI/models/LLM, no key at all, Qwen3.8-27B recommended.
A note on the author: T8mars runs the first two gateways, so the cloud half is partly a funnel to paid endpoints (there are affiliate links in the README). It's a real, well-tested product though, and the local GGUF path sidesteps the funnel entirely.
Install
ComfyUI Manager → search "MiniMax H3 / Seedance 2.0 / Music 3 Prompt Enhancer (T8)", or:
cd ComfyUI/custom_nodes
git clone https://github.com/T8mars/comfyui-minimax-h3-prompt-enhancer-T8.git
Restart ComfyUI, hard-refresh the browser with Ctrl+F5 if the menu doesn't update. Cloud mode needs no extra Python packages. The local path is the heavy one: run python install_local_qwen.py inside the pack directory to pull the ~15.9 GiB Qwen GGUF, the ~0.9 GiB vision projector, and llama.cpp. Plan for 24 GB VRAM; 16 GB works via --fit offloading but is slow.
Where people get burned
- The key is for the enhancer LLM, not for video generation. This key bills the prompt-rewrite requests. Your downstream H3 generation API key is a different thing entirely.
- Clicking "save to workflow" embeds the key in the workflow JSON. Clear it before you share anything.
- Cloud videos cap at 50 MB (MP4/AVI/MOV/MKV); Ref2VA wants 2–15s clips, 12 total pieces of media max.
- Local mode samples your video at ~2 fps and reads only the visuals - it will not, and does not claim to, hear the audio track.
- Gateway 5xx and Cloudflare hiccups retry automatically up to three times; a 401 or empty balance won't. That's by design, not a stuck node.
Inputs (35)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | Only this text is required. The LLM analyzes connected media and completes the H3 prompt. | |
| task_type | COMBO | T2VA(文生音视频) | 5 options: T2VA(文生音视频), I2VA(首帧图生音视频), FL2VA(首尾帧生音视频), L2VA(尾帧图生音视频), Ref2VA(参考图/视频生音视频) |
| duration_seconds | INT | 54–30 | — |
| shot_count | COMBO | AUTO(系统自动判断) | AUTO 由模型结合时长、内容与节奏判断;1-20 要求输出对应数量的 [Shot N]。 |
| rewrite_mode | COMBO | balanced | Controls enrichment only: strict is conservative, balanced fills details, creative expands style. This is separate from the official Skill language profile. |
| description_word_target | INT | 00–1000 | 0 = automatic. Compatibility mode uses Chinese characters or English words; official strict mode always uses English words. |
| output_language | COMBO | 中文 | 2 options: 中文, English |
| prompt_mode | COMBO | 官方增强 | 2 options: 官方增强, 参考模板融合 |
| official_skill_profile | COMBO | 现有兼容(保留中英文) | 兼容模式保留当前中英文正文;官方严格模式强制所有说明字段使用英文,仅原文对白、歌词和可见文字保留原语言。 |
| creative_preset | COMBO | 无(仅核心规则) | AUTO 或八个 MiniMax 官方场景写作预设。音乐 MV 动态字幕预设来自官方 music-video-subtitle-generator v0.6.6;仅使用用户给出的歌词/节拍事实,或在用户明确授权时创作短篇原创歌词,不分析音频。预设只影响写法,不执行生成、剪辑或外部工作流。 |
| case_template | COMBO | 无(不使用 T8 案例) | 选择后显示用途、输入格式、推荐示例、结构锚点和本地 GIF。迁移 Creative DNA 与因果节奏,不复制源人物、剧情、文案、镜头表或媒体。 |
| api_mode | COMBO | 贞贞平价小屋(推荐) | 4 options: 贞贞平价小屋(推荐), 贞贞的AI工坊(图片/视频), OpenAI兼容接口(备用), 本地 GGUF(llama.cpp / Qwen,离线) |
| ai_workshop_model | COMBO | gemini-3.5-flash | 仅用于贞贞的AI工坊。默认 gemini-3.5-flash;选择 Custom 后填写下方模型 ID。 |
| first_frameopt | IMAGE | Required by I2VA and FL2VA. | |
| last_frameopt | IMAGE | Required by FL2VA and L2VA. | |
| reference_imagesopt | COMFY_AUTOGROW_V3 | — | |
| reference_videosopt | COMFY_AUTOGROW_V3 | — | |
| reference_contextopt | STRING | Supplemental identity/relationship facts or narrow reference roles, for example character, scene, or typography-only references. | |
| constraintsopt | STRING | Content that must be preserved or must not be added/changed, including exact lyrics, text safety, or forbidden transitions. | |
| api_keyopt | STRING | Accepts a connected STRING or the masked field below. A connected value takes priority. Environment fallback depends on API mode. | |
| reference_templateopt | STRING | Provides shot structure, pacing, camera, style, and sound references. The user's prompt and media remain authoritative. | |
| custom_modelopt | STRING | OpenAI兼容模式必填;AI工坊选择 Custom 时使用。填写供应商模型列表中的完整 ID。 | |
| openai_base_urlopt | STRING | Provider root, /v1 URL, or full /chat/completions URL. Used only in OpenAI-compatible mode. | |
| openai_video_urlsopt | STRING | 每行一个,按已连接 VIDEO 顺序替代视频 Base64;未填写或未覆盖的视频仍以内联 Base64 发送。图片始终内联 Base64。 | |
| seedopt | INT | 00–18446744073709550000 | 控制 ComfyUI 重跑,并把当前值作为提示词变体标识。供应商未公开 Chat Completions 的确定性种子参数。 |
| local_modelopt | COMBO | Qwen3.8-27B-Q4_K_M.gguf | 仅本地模式使用。递归扫描 ComfyUI/models/LLM 及其任意子目录。 |
| local_mmprojopt | COMBO | AUTO(自动匹配) | 仅本地图片/视频采样帧分析使用;AUTO 会按 GGUF 元数据匹配主模型。 |
| local_context_sizeopt | INT | 327688192–65536 | — |
| local_max_tokensopt | INT | 4096256–8192 | — |
| local_think_modeopt | COMBO | 关闭(推荐,速度优先) | 2 options: 关闭(推荐,速度优先), 开启(质量优先) |
| local_reasoning_effortopt | COMBO | medium | 3 options: low, medium, xhigh |
| local_video_sample_fpsopt | FLOAT | 2.000.25–8 | 只分析按真实时间戳采样的画面,不读取视频音轨。 |
| local_unload_policyopt | COMBO | 执行后卸载(推荐) | 3 options: 执行后卸载(推荐), 保持驻留, 空闲10分钟后卸载 |
| local_comfy_memory_policyopt | COMBO | AUTO(显存不足时释放) | 2 options: AUTO(显存不足时释放), 不主动释放 ComfyUI 模型 |
| provider_configopt | T8_LLM_PROVIDER_CONFIG | 不连接时完全使用本节点原有字段;连接后使用共享配置,断开即恢复。 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| enhanced_prompt | STRING | — |