AV Handles (Add)
Stop eating your first frames — give the video model a warm-up with AV Handles (Add)
- images
- audio
- images
- audio
- total_frames
- handles_added
- info
Ever notice your generated video starts with a few garbage frames before the "real" motion kicks in? That's not you doing something wrong. Video diffusion models like WAN S2V, WAN Fun Control, and LTX2 need a bit of runway to warm up - feed them 24 frames and the first 6 or so can be jittery artifacts. The classic fix is to pad the front with copies of your first frame (they call them "handles"), run the model, then chop the padding off after. AV Handles (Add) is the pad side of that trick, and the part that makes it non-trivial is that it keeps your audio in sync while it does it.
Here's the thing most people get burned on: if you're generating with audio - lip-sync with WAN S2V, any A/V workflow - you can't just pad video frames. Adding frames shifts everything relative to the audio, and now your mouth moves half a beat late. This node repeats the first frame and prepends exactly the right amount of silence so audio and video stay locked together. Feed it 60 frames + 2.0s of audio, ask for 12 handles, and you get 72 frames + 2.4s of audio. Same ratio, nothing drifts.
How it works: mechanically it's dead simple, which is why it's reliable. It grabs your first frame (images[0]), repeats it handle_frames times, and stacks the copies in front of the sequence - no VAE round-trip, no quality loss, just pure tensor ops. For audio it builds a block of zeros sized handle_frames / fps seconds and prepends that. The clever bit is FPS detection: it computes fps = frame_count / audio_duration from your inputs automatically, or you can force it with manual_fps (you'll want this for 23.976, 29.97, and audio-only work). The pack has zero dependencies - it's torch only, and ComfyUI already ships torch.
The inputs that actually matter:
handle_frames(required, default 8, 0–100) - how many warm-up frames to add. If you're just testing, 8 is a fine start.padding_mode-disabled,WAN (4n+1), orLTX2 (8n+1). WAN models want frame counts of 4n+1 (5, 9, 13…), LTX2 wants 8n+1 (9, 17, 25…). This rounds your total up to the nearest compatible value. Sethandle_framesto 0 with a mode enabled and it auto-calculates the minimum needed.manual_fps(default 0 = auto-detect) - override when auto-detection gives a weird number, or when you have audio and no images.
The one output you must not ignore: handles_added. When rounding kicks in, the actual number of frames added won't equal what you typed. Wire handles_added straight into the Trim node's handle_frames input and the pair self-syncs - that's the whole reason it exists. The other outputs are images, audio, total_frames, and info, a human-readable string telling you exactly what happened.
Install: ComfyUI Manager, search "AV Handles", install, restart. Or the manual way:
cd ComfyUI/custom_nodes
git clone https://github.com/pizurny/ComfyUI-AV-Handles.git
# restart ComfyUI
No model downloads, no dependencies. It shows up under video/handles. It's MIT-licensed and from a solo dev (pizurny) who's actively responsive on the release thread - a small, focused utility pack, and it stays that way by design.
Troubleshooting: audio out of sync means your Add and Trim nodes disagree - use the same handle_frames and manual_fps on both. Audio-only mode (no images) requires manual_fps; the node will warn and fall back to 30 FPS, which you probably don't want. And when in doubt, read the info output - it prints the frame counts, the FPS source, and the audio duration change so you can see the failure before it hits your eyeballs.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| handle_frames | INT | 80–100 | — |
| imagesopt | IMAGE | — | |
| audioopt | AUDIO | — | |
| padding_modeopt | COMBO | disabled | 3 options: disabled, WAN (4n+1), LTX2 (8n+1) |
| manual_fpsopt | FLOAT | 0.000–120 | Manual FPS override (0 = auto-detect from video/audio) |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| images | IMAGE | — |
| audio | AUDIO | — |
| total_frames | INT | — |
| handles_added | INT | — |
| info | STRING | — |