ComfyUI H3 Motion Context Auto-Chain: Long Lip-Sync Videos in One Run
An addon for ComfyUI-H3-Motion-Context that auto-chains MiniMax H3 lip-sync clips: audio is split, motion and audio carry through latent context, and clips stitch into one MP4.
Example frame from the auto-chain lip-sync demo posted by the author.
The problem it solves
MiniMax H3 generation is limited to roughly 20-second clips, so a lip-sync video longer than that normally means manually chaining ComfyUI runs: starting a new generation every 20 seconds, resizing clips to fit VRAM, and joining the pieces afterwards. The Auto-Chain addon automates that loop. It cuts the complete audio into clip-sized chunks, keeps the original timeline for gap-free stitching, queues the next clip automatically, and carries video and audio continuity through H3's latent context so each clip continues from the previous one.
The author's demo (TBG ETUR on YouTube) shows a long lip-sync video built from chained clips, including camera movement driven by per-clip prompts:
Nodes included
| Node | What it does |
|---|---|
| H3 Auto Chain Audio | splits the audio into clip-sized chunks and outputs the current clip's audio, prompt, clip number and chain configuration |
| H3 Auto Chain Load Latent | loads the previous clip's H3 video/audio latent for the Motion Context node |
| H3 Auto Chain Save Latent | saves the current sampler output into a numbered slot for continuation |
| H3 Auto Chain Frame Reference | supplies the reference image: the initial image every clip, the previous clip's final frame (last_frame, recommended), or only for clip 1 |
| H3 Auto Chain Motion Context | delegates to the original Motion Context node for continuation clips, with a first-clip pass-through |
| H3 Auto Chain + Stitch | saves the current clip, extracts its final frame, queues the next clip, and stitches all completed clips into one MP4 when the chain finishes |
Per-clip prompting works with a shared style_prompt plus numbered clip_prompts ([1] The character walks through a rainy city street., [2] The character enters a warm cafe., ...), and each clip segment gets its own output file so a chain can be resumed or a single clip re-rendered with the same chain_id.
Example workflow
The repository ships a complete lip-sync workflow that connects the addon nodes to the original H3 Motion Context package:
Recommended starting settings: 20-second chunks, 24 fps, 22 context frames, last_frame reference mode.
Installation
The addon requires the original ComfyUI-H3-Motion-Context package and a working MiniMax H3 video workflow. Install both folders into ComfyUI/custom_nodes/ and restart ComfyUI:
ComfyUI/custom_nodes/ComfyUI-H3-Motion-Context-orig/
ComfyUI/custom_nodes/ComfyUI-H3-Motion-Context-Auto-Chain-addon/The experimental modified H3 fork should not be installed alongside the original package and this addon, because it registers duplicate node IDs.
Availability
- Code: Ltamann/ComfyUI-H3-Motion-Context-Auto-Chain-addon on GitHub
- Workflow:
MiniMax H3 Lipsync.jsoninexample_workflows/ - Demo: TBG ETUR on YouTube
Comments
Sign in with GitHub to join the discussion.