Nodes/ComfyUI_Lam/Lam MiniMax H3 Reference to Video
ComfyUI Node

Lam MiniMax H3 Reference to Video

The node that wires MiniMax H3 reference-to-video together

By yanlang0123·Created 2 years ago·Updated about a month ago· 76
Lam MiniMax H3 Reference to Video
  • clip
  • vae
  • audio_vae
  • ref_images
  • ref_video_audios
  • ref_audios
  • positive
  • latent
prompt
width1344
height768
length124
ref_image_sizematch

LamMiniMaxH3RefVideo is the conditioning stage of the MiniMax H3 reference-to-video (Ref2V) pipeline, wrapped for the Lam pack. It takes your prompt, reference images, and optional reference audio, and produces the two things a sampler needs: the positive conditioning and the empty latent. On its own it does nothing - wire it between the H3 model loaders and a KSampler and it becomes the heart of a local, reference-driven video generation workflow.

Why this matters

MiniMax H3 is Hailuo's multimodal video model - text, images, video, and audio in one model, with native stereo sound, up to 15 seconds at 2K. It went open-weights in mid-2026 and ComfyUI shipped native support basically on day one. The thing the community actually celebrated about H3 was the reference-to-video mode: "finally a proper reference2video model we can run locally," as one r/StableDiffusion thread put it. Instead of the old grind - generate a start image, train a LoRA to lock the character, stitch scenes together - you dump your reference images and audio straight into the model and it keeps them consistent. That's exactly what this node is built around.

How it works

This node is the Ref2V encode step. It consumes the three model pieces the native H3 support loads - a clip (the text/image encoder that tokenizes your prompt and references), a vae (the H3 video VAE that encodes reference images), and an audio_vae (the audio VAE for reference audio) - and produces:

  • positive - CONDITIONING that carries your prompt plus any encoded references, wired into the sampler's positive input.
  • latent - LATENT, the empty audio/video latent you sample from.

The inputs that matter for a beginner:

  • prompt - your multiline prompt. Reference images are addressed inline with <Picture i> style tags (the standard H3 convention), and the model is good at instruction following, so write it like you're directing a shoot.
  • width / height - default 1344×768; standard video canvas sizes in multiples of 32.
  • length - default 124, which is about 5 seconds at 24 fps. The step is 17, so the frame count snaps to the 17k+5 grid H3 expects.
  • ref_image_size - match scales references to the canvas area; max aligns them to the 2048 short edge, which preserves identity better but is slower. Start with match.
  • ref_images (IMAGE, optional) - your character/scene/prop reference shots.
  • ref_audio slots - ref_video_audios and ref_audios (both AUDIO, optional), the soundtracks and standalone audio references H3 can condition on.

Then you take positive and latent into a sampler, VAE-decode the result, and save - LamSaveVideoNoOutput is a natural tail for exactly this pipeline.

Models and hardware

The Lam README won't help you here: it documents the pack's lama and face-swap models but says nothing about H3. You still need the actual H3 weights (the diffusion model, the H3 video VAE, the audio VAE, and the text encoder) via ComfyUI's native MiniMax H3 support - Model Manager or manual downloads into ComfyUI/models. That's the heavy part, tens of GB of downloads. Good news from the community: it's confirmed to run on a 3060, just slowly. Expect to feel the VRAM pressure on anything smaller.

Installing and troubleshooting

Install the pack once and the node appears:

cd ComfyUI/custom_nodes
git clone https://github.com/yanlang0123/ComfyUI_Lam.git

restart, or use ComfyUI Manager (search ComfyUI_Lam). Common snags:

  • Empty clip/vae/audio_vae sockets means you haven't loaded the H3 models yet - this node doesn't download anything itself. Load them first, then connect.
  • Out of memory during conditioning or sampling is the H3 tax on small cards. Drop resolution (768p instead of 1344 wide), shorten length, and use match on ref_image_size before you reach for max.
  • References ignored usually means your prompt doesn't reference them - H3 keys on the <Picture i> tags, so name your images in the prompt.

And the usual pack-level honesty: the UI and docs are Chinese, so you'll be matching sockets to the info_schema above more than reading labels. If all you need is plain text-to-video, the native H3 nodes are simpler; this one earns its keep when references are the whole point.

Categorylam

Inputs (11)

NameTypeDefaultDescription
clipCLIP
vaeVAE
audio_vaeVAE
promptSTRING
widthINT134432–8192
heightINT76832–8192
lengthINT1245–3600
ref_image_sizeCOMBOmatch2 options: match, max
ref_imagesoptIMAGE
ref_video_audiosoptAUDIO
ref_audiosoptAUDIO

Outputs (2)

NameTypeDescription
positiveCONDITIONING
latentLATENT