沐阳 H3 · Media Agent
An LLM writes your H3 prompt — and checks every @video2 reference actually exists
- catalog
- asset_1
- asset_2
- asset_3
- asset_4
- asset_5
- asset_6
- asset_7
- asset_8
- asset_9
- asset_10
- asset_11
- asset_12
- asset_13
- asset_14
- asset_15
- agent_prompt
- summary_json
- media_manifest
- media
- myang_prompt
MiniMax H3's real superpower is multi-modal prompting: your prompt can reference pictures, videos and audio clips directly, and the model uses them. The problem is that H3 expects references in the official <Picture N>, <Video N>, <Audio N> form, and if your prompt references a <Video 3> that you never connected, the whole thing silently degrades. The Media Agent is the node that stops both problems - it lets an LLM rewrite your prompt into proper H3 form, then strictly validates that every media reference actually maps to connected media.
So you write editor-facing labels - @图片1, @视频1, @音频1 - in plain text, connect the actual assets to the node's asset_1…asset_15 slots, and the agent does three things. It describes the available media inventory, asks an LLM to rewrite your prompt (optionally expanding it, optionally fixing dialogue), and converts the labels into valid H3 tags. It can go further: turn on a vlm_service and a vision model describes what's actually in each image/video so the LLM knows which reference to cite; set 音频识别 to a Whisper model size and it transcribes audio clips to ground dialogue (this is the one place the pack wants a pip install - openai-whisper - and only if you use local transcription). Turn strict_media_check off and it relaxes the "every tag must connect" rule, which is occasionally useful for drafts and usually a mistake.
The LLM itself isn't built in. You configure a service once in ComfyUI Settings → Myang_node → LLM Service Settings - OpenAI-compatible APIs or Ollama, multiple URL/API-key routes per service, round-robin or primary-first with failover. Two safety details worth knowing: the config read endpoint never returns API keys to the browser, and to change a key you leave the field empty (it keeps the stored value). Config lives at user/default/Myang_node/config/llm_services.json in your ComfyUI user dir. If you have no LLM configured at all, the node degrades to a plain pass-through rather than dying.
Inputs beyond the prompt and media slots: 时长 (target duration), 扩写 (expand vs strictly refine), 对话修正 (dialogue correction), 音频主体 (which subject the audio belongs to), skill_preset/skill_text for writing style, and the vlm_service/音频识别 toggles. Outputs: agent_prompt (the rewritten, H3-valid prompt), summary_json (the storyboard summary), media_manifest, a media handle for downstream nodes, and myang_prompt - the pack's own canonical prompt form, which is what you wire into the script splitter.
Where people get burned: the LLM is very good at wrecking @视频1-style tags. That's exactly why H3SegmentPrompt keeps media_prefix out of LLM hands - if your agent output keeps producing dead references, move the media-reference sentence there. And remember this node calls out over the network with a credential; it's the classic phone-home shape, so configure it through the Settings panel and be deliberate about which service you point it at.
Install is the shared pack route - ComfyUI Manager, search ComfyUI-MiniMaxH3-Myang, restart; or git clone https://github.com/civilcoco/ComfyUI-MiniMaxH3-Myang.git into custom_nodes. No deps beyond standard ComfyUI unless you enable Whisper. The H3 model itself, as always, needs to be present and licensed for your region.
Inputs (31)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | — | |
| llm_service | COMBO | 1 options: 未配置 LLM 服务 | |
| skill_preset | COMBO | auto | 3 options: auto, none, README.md |
| skill_text | STRING | — | |
| agent_enabled | BOOLEAN | true | — |
| strict_media_check | BOOLEAN | true | — |
| ollama_auto_unload | BOOLEAN | true | — |
| seed | INT | 00–18446744073709550000 | — |
| vlm_service | COMBO | off | 1 options: off |
| 时长 | FLOAT | 5.01–30 | — |
| 扩写 | BOOLEAN | true | — |
| 对话修正 | BOOLEAN | true | — |
| 音频识别 | COMBO | off | 5 options: off, tiny, base, small, medium |
| 音频主体 | COMBO | 自动 | 8 options: 自动, 图片1, 图片2, 图片3, 图片4, 视频1, +2 |
| catalogopt | MINIMAX_H3_MEDIA | — | |
| asset_1opt | * | — | |
| asset_2opt | * | — | |
| asset_3opt | * | — | |
| asset_4opt | * | — | |
| asset_5opt | * | — | |
| asset_6opt | * | — | |
| asset_7opt | * | — | |
| asset_8opt | * | — | |
| asset_9opt | * | — | |
| asset_10opt | * | — | |
| asset_11opt | * | — | |
| asset_12opt | * | — | |
| asset_13opt | * | — | |
| asset_14opt | * | — | |
| asset_15opt | * | — | |
| asset_manifest_jsonopt | STRING | [] | — |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| agent_prompt | STRING | — |
| summary_json | STRING | — |
| media_manifest | STRING | — |
| media | MINIMAX_H3_MEDIA | — |
| myang_prompt | STRING | — |