Nodes/ComfyUI-MiniMaxH3-Contex-Loop/MiniMax H3 Lazy Motion AV Loader
ComfyUI Node

MiniMax H3 Lazy Motion AV Loader

A motion-reference loader that doesn't decode the video (until it has to)

By ethanfel·Created 17 days ago·Updated about 20 hours ago· 315
MiniMax H3 Lazy Motion AV Loader
    • source_video
    • source_audio
    • skip_first_frames
    • status
    video_path
    skip_first_frames0

    Every frame of a motion-reference video you decode is VRAM and RAM you didn't need - H3 only ever consumes a small 24 fps scene window at a time, and the rest of the file just sits there. This loader is the lazy route: it opens the container, keeps the video file-backed (never reading the full frame tensor), and only decodes the embedded audio track so legacy AUDIO wiring has something to pull. It's a 0.4-era adapter, and the pack would rather you use Source Timeline for new work, but if you're running a saved 0.4 workflow it's exactly what you need.

    What it does

    Give it an absolute video_path to your motion-reference video. It produces:

    • source_video - a native file-backed VIDEO wrapper. The full picture stream stays on disk; consumers pull only the window they need.
    • source_audio - the complete post-skip embedded soundtrack, aligned to the same 24 fps timeline, for legacy AUDIO fan-out.
    • skip_first_frames - a validated native-frame origin to connect to the tagged motion node's matching input, so the Plan timeline starts where you want without the loader actually decoding those skipped frames.
    • status - resolved path, skipped origin, audio duration, and a lazy-load summary.

    The skip_first_frames input has a subtlety worth knowing: it moves the timeline origin, but the VIDEO wrapper stays untrimmed. You connect the output INT to the tagged motion reference's matching input rather than expecting the video to come out shorter.

    Why "legacy" and should you care

    This is explicitly a Legacy 0.4 adapter. New workflows should register their motion reference container with Source Timeline, which is the 0.5 source-media contract and does the same laziness properly - recording video, audio, timing, fingerprints, and recovery data behind one typed wire. The loader exists so old graphs keep running. If you're starting fresh, reach for Source Timeline; if you're resurrecting a 0.4 workflow or just want a single container wired into a legacy graph, this is the path.

    Install and gotchas

    cd ComfyUI/custom_nodes
    git clone https://github.com/ethanfel/ComfyUI-MiniMaxH3-Contex-Loop.git
    

    Restart ComfyUI, or install via Manager under "MiniMax H3 Contex Loop". No pip step - it relies on ComfyUI's own PyAV. You'll want ffmpeg on PATH as a general good practice, and a current ComfyUI with native Add Guide support (PR #15439).

    The main trap: video_path is an absolute path, so a workflow shared between machines breaks until you re-point it. And because it's file-backed, don't expect IMAGE output from this node - the video stays lazy by design; you'd decode it with a preview node when you actually want to look.

    Categoryconditioning/minimax/contex_loop/media

    Inputs (2)

    NameTypeDefaultDescription
    video_pathSTRINGAbsolute path to the motion-reference video. VIDEO remains file-backed; only its embedded audio track is decoded.
    skip_first_framesINT00–100000000Start the Plan timeline after this many native source frames. The VIDEO wrapper stays untrimmed; connect this INT to the tagged motion node's matching input.

    Outputs (4)

    NameTypeDescription
    source_videoVIDEONative file-backed VIDEO wrapper; the full picture stream remains on disk.
    source_audioAUDIOComplete post-skip embedded soundtrack for legacy AUDIO wiring.
    skip_first_framesINTValidated native-frame origin to connect to Tagged Motion Ref Path.
    statusSTRINGResolved path, skipped origin, audio duration, and lazy-load summary.