GUIDED AV LOOP · Window Conditioning
Stop H3 from leaking the end of the shot into the start
- model
- clip
- video_vae
- audio_vae
- cine_linx
- bridge_frame
- first_frame_override
- last_frame_override
- ref_image_1
- ref_image_2
- ref_image_3
- ref_image_4
- ref_video
- ref_video_audio
- ref_audio
- motion_context
- model
- positive
- latent
- first_frame
- planned_last_frame
- reference_manifest_json
- prompt
- current_segment
- total_segments
- trim_head_frames
- report
- motion_state
Here's a failure mode you've probably seen without naming it: you render a long take in one latent, with several keyframes pinned across it, and the opening three seconds are already anticipating the ending. The camera drifts toward the final framing early. A character turns their head before they're supposed to. That's prompt leakage - the whole take shares one conditioning pass, so every window knows what every other window was told.
IAMCCS_MiniMaxH3MaskedLoopConditioning is the fix for the Guided AV Loop mode: it compiles one set of conditioning per technical window, so each window only sees its own framing directions. It is the mandatory partner of IAMCCS_MiniMaxH3MaskedLoopGuidedSampler - the sampler raises a hard error if it finds multiple windows and only one shared prompt.
Inputs
Required: model, clip, video_vae, audio_vae, cine_linx, segment_index.
Optional: bridge_frame, render_id, first_frame_override, last_frame_override, ref_image_1 through ref_image_4, ref_video, ref_video_audio, ref_audio, prompt_override, and motion_context.
That reference stack is the interesting part of this node. You get four still references, a reference video with its own audio, a separate audio reference, and overrides that let you replace the plan's planned opening and closing frames for this segment without re-authoring the Shotboard. That is a lot of conditioning surface for one take, which is what a masked-window sampler needs in order to hold a long loop together.
Outputs
Twelve, and they're mostly plumbing rather than results: model, positive, latent, first_frame, planned_last_frame, reference_manifest_json, prompt, current_segment, total_segments, trim_head_frames, report, and motion_state.
positive and latent go into the sampler. reference_manifest_json is the audit trail of which references were actually used - when a take looks like it ignored your reference image, that string is how you find out whether it made the cut. motion_state is the pass-through token that lets the pack's motion-context routing keep working through the loop. planned_last_frame is the destination the plan expects, which is genuinely useful on a loop: compare it against your last_frame_override before you render.
What it requires
- Task mode
guided_av_loop_experimental. The legacylongvid_masked_loop_guidedis accepted for load compatibility with the original isolated graph, but the current mode is the former. - Exactly one validated master chunk. This is a one-master-latent execution; if the plan holds several chunks you're using the wrong engine (that's Continuous AV's job).
- At least two matched Shotboard keyframes with frame indices.
Guided AV Loop needs at least two matched Shotboard images and frame indicesis the error when the plan is under-authored.
It also normalises your guides onto the master canvas, because a ComfyUI IMAGE batch can't hold mixed spatial sizes: the opener at frame 0 is stretched to fit, later anchors are centre-cropped. The log records each guide's transform, which is worth a look the first time you use a guide that was authored at a different aspect than the master.
Install
cd ComfyUI/custom_nodes
git clone https://github.com/IAMCCS/IAMCCS-nodes.git
Or Manager → search IAMCCS, restart. No models of its own beyond the H3 stack. The requirement that isn't obvious is the one the sampler enforces on ComfyUI itself: continuous per-row MiniMax H3 mask support (ComfyUI issue #15375). On a build without it, the loop backend refuses to run - and it refuses clearly, naming the missing feature, rather than degrading into a take with a hard seam in it.
Straight talk
This is an experimental-continuity node in a pack that labels its experimental parts as experimental. The payoff is real - per-window prompting is the difference between a long take that reads as one shot and one that reads as six shots stapled together - but you should expect to spend a run or two learning how it wants to be fed, and you should test with two or three windows before you author a long programme. The conditioning node itself is cheap and instant; all the cost is downstream in the sampler.
Inputs (19)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| clip | CLIP | — | |
| video_vae | VAE | — | |
| audio_vae | VAE | — | |
| cine_linx | IAMCCS_SUPERNODE_LINX | — | |
| segment_index | INT | 00–1000000 | — |
| bridge_frameopt | IMAGE | — | |
| render_idopt | STRING | — | |
| first_frame_overrideopt | IMAGE | — | |
| last_frame_overrideopt | IMAGE | — | |
| ref_image_1opt | IMAGE | — | |
| ref_image_2opt | IMAGE | — | |
| ref_image_3opt | IMAGE | — | |
| ref_image_4opt | IMAGE | — | |
| ref_videoopt | IMAGE | — | |
| ref_video_audioopt | AUDIO | — | |
| ref_audioopt | AUDIO | — | |
| prompt_overrideopt | STRING | — | |
| motion_contextopt | IAMCCS_H3_MOTION_CONTEXT | — |
Outputs (12)
| Name | Type | Description |
|---|---|---|
| model | MODEL | — |
| positive | CONDITIONING | — |
| latent | LATENT | — |
| first_frame | IMAGE | — |
| planned_last_frame | IMAGE | — |
| reference_manifest_json | STRING | — |
| prompt | STRING | — |
| current_segment | INT | — |
| total_segments | INT | — |
| trim_head_frames | INT | — |
| report | STRING | — |
| motion_state | IAMCCS_H3_MOTION_CONTEXT | — |