LTXV Edit Anything Looping Sampler
The full Edit Anything conditioning stack, chunked for long clips
- model
- vae
- noise
- sampler
- sigmas
- guider
- positive
- negative
- latents
- editanything_module
- ref_image
- guide_frames
- denoised_output
- ref_image_preview
- diff_vs_previous_run
This is the flagship node in the pack, and it's genuinely dense - over twenty optional parameters - because it's doing three jobs at once. It's a custom sampler for LTXV Edit Anything LoRAs (the video_to_video_ref_adaln training strategy the whole pack is built around), it handles temporal tiling so you can sample clips longer than one chunk fits in memory, and it exposes every conditioning path the author's Edit Anything LoRAs can carry: IC-LoRA reference/guide tokens, a role-embedding bias, and AdaLN-style global appearance conditioning. If you've seen the author's LTX-2.3 Edit Anything LoRA doing background swaps and clothing replacement on Reddit, this sampler is the node underneath it.
Why "looping"
Instead of sampling your whole clip in one pass, it slices the video into temporal tiles (temporal_tile_size, default 80 pixel frames) with overlap between them (temporal_overlap, default 24), then blends the seams (blend_overlap, on by default) so a long generation doesn't need to fit entirely in memory at once. reapply_per_chunk decides whether the reference/guide tokens get re-appended on every chunk or only the first - leave it on unless you have a specific reason not to, since inheriting "no IC-LoRA append" on later chunks is a good way to lose identity partway through a clip.
The three conditioning paths, and what actually needs tuning
You load the LoRA either via lora_name directly or, as an alternative, via editanything_module - a sidecar object from this pack's LTXVEditAnythingModuleLoader node. Only use one at a time.
- IC-LoRA sequence conditioning (
enable_ic_lora, on by default): appendsref_imageand optionalguide_framesas clean conditioning tokens.ref_strengthandguide_strength(0-1) control how much each contributes. - Role embedding (
enable_role_embedding, off by default): injects a learned reference-role bias beforepatchify_proj. This one is genuinely LoRA-specific - the tooltip flags that the author's ownstage2_ref_visual_adaln_crossattncheckpoint was trained with this disabled, so flipping it on for the wrong LoRA is a real footgun, not a safe default to just try. - AdaLN reference conditioning (
enable_adaln, on by default,adaln_scaledefault 2): pools the reference image into a global style/appearance signal injected into LTXV's timestep path. - Visual cross-attention (
enable_visual_crossattn, on by default): auto-detectsref_visual_proj/ref_attnLoRA keys and, if present, runs a separate cross-attention path with its own scale knobs (ref_context_scale,ref_token_scale), block range (ref_start_block/ref_end_block), and initialization mode (ref_init_from) - all of which the tooltips say must match the LoRA's training config exactly, particularlyref_init_from.
Outputs: denoised_output (latent, for your VAE decode), ref_image_preview, and diff_vs_previous_run - a debug string comparing this run against the last, handy while you're iterating on strength values.
Installing it, and getting the LoRA right
Search "ComfyUI-BFSNodes" in ComfyUI Manager, or install by hand:
cd ComfyUI/custom_nodes
git clone https://github.com/alisson-anjos/ComfyUI-BFSNodes.git
cd ComfyUI-BFSNodes
pip install -r requirements.txt
Restart ComfyUI. The pack's own README points at the first public Edit Anything LoRA, edit_anything_reference_v0.1_r128_12000.safetensors - but the author (active on r/StableDiffusion, posting Edit Anything updates and workflows) had already shipped edit_anything_v1.1_r256.safetensors on their HuggingFace EditAnything repo by mid-2026, with real improvements to consistency and prompt adherence over the version the README names. Check for the newest file rather than trusting the README's version number literally. Put it under ComfyUI/models/loras/.
Where this actually breaks, from people who've used it
One recurring, confirmed issue: users running this sampler with the Edit Anything LoRA report a ghosting or "after-image" artifact - guide frames leaving a visible trail in the output. The author's own fix, straight from that thread: use the workflow bundled with the LoRA version you're on rather than an older one, keep LoRA strength at 1.0 (higher causes visual degradation, not better results), and delete any color-adjustment node sitting after VAE decode - that combination is what triggers it. Background and clothing replacement work well through this pipeline for video-to-video, but image-to-video support was reported as weaker in the same discussion, so don't be surprised if I2V results underperform V2V ones. And because this node auto-detects LoRA keys for the visual cross-attention path, a LoRA that's missing ref_visual_proj/ref_attn weights will just silently skip that path - if a setting doesn't seem to do anything, check debug_ea before assuming the node is broken.
Inputs (34)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| vae | VAE | — | |
| noise | NOISE | — | |
| sampler | SAMPLER | — | |
| sigmas | SIGMAS | — | |
| guider | GUIDER | Provides CFG/STG sampling settings. Its conds are overridden per chunk. | |
| positive | CONDITIONING | — | |
| negative | CONDITIONING | — | |
| latents | LATENT | — | |
| temporal_tile_size | INT | 808–1000 | Temporal tile size in pixel frames. |
| temporal_overlap | INT | 240–256 | Temporal overlap in pixel frames. |
| blend_overlap | BOOLEAN | true | — |
| lora_nameopt | COMBO | (none) | Edit Anything LoRA. Used to load role_embedding + ref_adaln_proj weights. Leave on (none) if passing editanything_module instead. |
| editanything_moduleopt | LTXV_EA_MODULE | Alternative to lora_name: sidecar module from LTXV Edit Anything Module Loader. | |
| ref_imageopt | IMAGE | Reference image (appearance anchor). Required for IC-LoRA ref tokens / AdaLN. | |
| guide_framesopt | IMAGE | Guide video frames (structure/motion). VAE-encoded internally, then sliced per chunk. | |
| ref_resize_modeopt | COMBO | pad_to_fit | 3 options: pad_to_fit, center_crop, stretch |
| ref_strengthopt | FLOAT | 1.000–1 | — |
| guide_strengthopt | FLOAT | 1.000–1 | — |
| role_strengthopt | FLOAT | 1.00–20 | — |
| adaln_scaleopt | FLOAT | 2.000–10 | — |
| enable_ic_loraopt | BOOLEAN | true | Append ref + guide_slice as IC-LoRA clean tokens per chunk. |
| enable_role_embeddingopt | BOOLEAN | false | Sum role_embedding bias onto IC-LoRA ref tokens. Must match training config `use_visual_ref_role_embedding`. stage2_ref_visual_adaln_crossattn was trained with this DISABLED. |
| enable_adalnopt | BOOLEAN | true | — |
| reapply_per_chunkopt | BOOLEAN | true | If True: append ref + (sliced) guide tokens on every chunk. If False: only on chunk 0; later chunks inherit no IC-LoRA append. |
| enable_visual_crossattnopt | BOOLEAN | true | Auto-detect ref_visual_proj + ref_attn LoRA keys in the checkpoint and enable the visual cross-attention path (stage2_ref_visual_adaln_crossattn). |
| ref_context_scaleopt | FLOAT | 0.010–2 | Scale for ref_attn output added to each block. Training default for video_to_video_ref_visual_adaln is 0.01 (very conservative). |
| ref_token_scaleopt | FLOAT | 0.250–2 | Scale applied to projected visual memory tokens before cross-attn. stage2_ref_visual_adaln_crossattn was trained with 0.25. |
| ref_start_blockopt | INT | 120–47 | First transformer block that consumes visual ref tokens (training default 12). |
| ref_end_blockopt | INT | 350–47 | Last transformer block that consumes visual ref tokens (training default 35). |
| ref_init_fromopt | COMBO | attn2 | How to initialize ref_attn before applying its LoRA. CRITICAL: must match the training config `init_ref_attn_from`. stage2_ref_visual_adaln_crossattn was trained with 'attn2'. |
| ref_init_seedopt | INT | 42-1–2147483647 | Seed for random ref_attn init when ref_init_from='none'. Ignored otherwise. |
| ref_attn_lora_strengthopt | FLOAT | 1.00-2–2 | Strength multiplier for the ref_attn LoRA deltas. |
| debug_eaopt | BOOLEAN | false | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| denoised_output | LATENT | — |
| ref_image_preview | IMAGE | — |
| diff_vs_previous_run | STRING | — |