H3 Character Swap 1.5: ComfyUI and SAM 3.1 tutorial

Learn two ComfyUI character replacement workflows using H3 Character Swap 1.5, including SAM 3.1 masks for selecting one person in a crowd.

Player not loading? Watch on YouTube

This tutorial explains two ComfyUI workflows for H3 Character Swap LoRA version 1.5: a basic reference-to-video setup and a masked approach for selecting one person among several. The presenter demonstrates both through RunningHub, an online platform for ComfyUI workflows.

The basic setup uses the official Ref 2 VA model in int8 ComfyUI format, the character replacement LoRA, and a Ref 2 V acceleration LoRA. The example generates five seconds at a 9:16 aspect ratio and roughly 0.7 million pixels, using Euler sampling, the simple scheduler, and eight steps. A reference image supplies the character's appearance, while the source video supplies the performance.

The presenter reports that the examples retain gaze, mouth movements, gestures, and changes in lighting. Reference clothing tends to persist even when the original performer changes outfits. Frequent cuts cause less reliable results: one vlog test barely changes, while another retains the source subject's hairstyle.

For crowded scenes, the second workflow uses SAM 3.1 FP16 to locate the target. It cleans the mask, crops in tracked mode, and prepares the masked latent separately from conditioning. After sampling, a subject uncrop node places the result back into the source video. In the examples, the presenter replaces a pedestrian and the right-hand dancer while leaving nearby people unchanged.