The open creative studio on ComfyUI: images, video, 3D and audio on open weights, on your own GPU or the cloud. Camera motions, effects, apps, Cinema, Layers, Image to 3D and an AI agent.
TypeScript ai-videocomfyuicreative-toolsgenerative-aiideogramimage-generationimage-to-3dimage-to-videoltx-videominimax-h3nextjsopen-sourceopen-weightsqwen-imagetext-to-imagevideo-generationwan
ComfyUI library: the painted eraser hands its mask on; mattes and depth maps get their options
Claudedf07a751a3ce
diff --git a/scripts/comfy/build-library.mjs b/scripts/comfy/build-library.mjsindex 2465c6f7..dfe987a4 100644--- a/scripts/comfy/build-library.mjs+++ b/scripts/comfy/build-library.mjs@@ -108,6 +108,8 @@ export const BINDING_KEYS = new Set(['maskPrompt', 'maskGrow', 'skipPass2', 'supersample', 'zoomStart', 'zoomEnd', 'panStartX', 'panStartY', 'panEndX', 'panEndY','easeInOut', 'chunkFrames', 'crossfade', 'headroomDb', 'fadeCurve', 'format', 'profile', 'peakNits', 'resolutionLevel', 'fovX','decimation', 'cutout', 'numGaussians', 'splatFormat', 'orbitFrames', 'frameWidth',+ // remove-object package (round 4)+ 'colormap', 'sideBySide',]);const readJson = (p, fallback) => (fs.existsSync(p) ? JSON.parse(fs.readFileSync(p, 'utf8')) : fallback);diff --git a/scripts/comfy/hand-built/video-bg-remove-sam3.json b/scripts/comfy/hand-built/video-bg-remove-sam3.jsonindex 2c86780f..9cba1edb 100644--- a/scripts/comfy/hand-built/video-bg-remove-sam3.json+++ b/scripts/comfy/hand-built/video-bg-remove-sam3.json@@ -114,5 +114,52 @@"_meta": {"title": "Save transparent WebM (VP9 alpha)"}+ },+ "10": {+ "class_type": "MaskToImage",+ "inputs": {+ "mask": [+ "6",+ 0+ ]+ },+ "_meta": {+ "title": "Matte (white = what was kept)"+ }+ },+ "11": {+ "class_type": "CreateVideo",+ "inputs": {+ "images": [+ "10",+ 0+ ],+ "fps": [+ "2",+ 2+ ],+ "bit_depth": "auto",+ "color_space": "sRGB",+ "codec": "none"+ },+ "_meta": {+ "title": "Matte video"+ }+ },+ "12": {+ "class_type": "SaveVideo",+ "inputs": {+ "video": [+ "11",+ 0+ ],+ "filename_prefix": "fuobe/video-bg-remove-sam3",+ "format": "auto",+ "format.codec": "auto",+ "codec": "auto"+ },+ "_meta": {+ "title": "Save matte MP4"+ }}}diff --git a/scripts/comfy/hand-built/video-depth-da3.json b/scripts/comfy/hand-built/video-depth-da3.jsonindex 7af1953b..0316ff16 100644--- a/scripts/comfy/hand-built/video-depth-da3.json+++ b/scripts/comfy/hand-built/video-depth-da3.json@@ -60,7 +60,7 @@"class_type": "CreateVideo","inputs": {"images": [- "5",+ "10",0],"fps": [@@ -92,5 +92,88 @@"_meta": {"title": "Save depth video"}+ },+ "8": {+ "class_type": "ImageStitch",+ "inputs": {+ "image1": [+ "2",+ 0+ ],+ "image2": [+ "12",+ 0+ ],+ "direction": "right",+ "match_image_size": false,+ "spacing_width": 0,+ "spacing_color": "black"+ },+ "_meta": {+ "title": "Original | depth"+ }+ },+ "9": {+ "class_type": "PrimitiveBoolean",+ "inputs": {+ "value": false+ },+ "_meta": {+ "title": "Side by side (sideBySide)"+ }+ },+ "10": {+ "class_type": "ComfySwitchNode",+ "inputs": {+ "switch": [+ "9",+ 0+ ],+ "on_true": [+ "8",+ 0+ ],+ "on_false": [+ "5",+ 0+ ]+ },+ "_meta": {+ "title": "Depth alone, or next to the original"+ }+ },+ "11": {+ "class_type": "GetImageSize",+ "inputs": {+ "image": [+ "2",+ 0+ ]+ },+ "_meta": {+ "title": "The clip's size"+ }+ },+ "12": {+ "class_type": "ImageScale",+ "inputs": {+ "image": [+ "5",+ 0+ ],+ "upscale_method": "lanczos",+ "width": [+ "11",+ 0+ ],+ "height": [+ "11",+ 1+ ],+ "crop": "disabled"+ },+ "_meta": {+ "title": "Depth at the clip's size (an even total width for the encoder)"+ }}}diff --git a/scripts/comfy/hand-built/video-depth-vda-small.json b/scripts/comfy/hand-built/video-depth-vda-small.jsonindex ed41e87f..7ff95862 100644--- a/scripts/comfy/hand-built/video-depth-vda-small.json+++ b/scripts/comfy/hand-built/video-depth-vda-small.json@@ -51,13 +51,15 @@],"colormap": "gray"},- "_meta": {}+ "_meta": {+ "title": "Colour map (colormap: gray | inferno)"+ }},"6": {"class_type": "CreateVideo","inputs": {"images": [- "5",+ "10",0],"fps": [@@ -85,5 +87,88 @@"_meta": {"title": "Save depth video"}+ },+ "8": {+ "class_type": "ImageStitch",+ "inputs": {+ "image1": [+ "2",+ 0+ ],+ "image2": [+ "12",+ 0+ ],+ "direction": "right",+ "match_image_size": false,+ "spacing_width": 0,+ "spacing_color": "black"+ },+ "_meta": {+ "title": "Original | depth"+ }+ },+ "9": {+ "class_type": "PrimitiveBoolean",+ "inputs": {+ "value": false+ },+ "_meta": {+ "title": "Side by side (sideBySide)"+ }+ },+ "10": {+ "class_type": "ComfySwitchNode",+ "inputs": {+ "switch": [+ "9",+ 0+ ],+ "on_true": [+ "8",+ 0+ ],+ "on_false": [+ "5",+ 0+ ]+ },+ "_meta": {+ "title": "Depth alone, or next to the original"+ }+ },+ "11": {+ "class_type": "GetImageSize",+ "inputs": {+ "image": [+ "2",+ 0+ ]+ },+ "_meta": {+ "title": "The clip's size"+ }+ },+ "12": {+ "class_type": "ImageScale",+ "inputs": {+ "image": [+ "5",+ 0+ ],+ "upscale_method": "lanczos",+ "width": [+ "11",+ 0+ ],+ "height": [+ "11",+ 1+ ],+ "crop": "disabled"+ },+ "_meta": {+ "title": "Depth at the clip's size (an even total width for the encoder)"+ }}}diff --git a/scripts/comfy/hand-built/video-inpaint-wan-vace-painted.json b/scripts/comfy/hand-built/video-inpaint-wan-vace-painted.jsonindex d4b08b83..ac90fe65 100644--- a/scripts/comfy/hand-built/video-inpaint-wan-vace-painted.json+++ b/scripts/comfy/hand-built/video-inpaint-wan-vace-painted.json@@ -192,7 +192,7 @@"17": {"class_type": "CLIPTextEncode","inputs": {- "text": "色调艳丽,过曝,静态,细节模糊不清,字幕,风格,作品,画作,画面,静止,整体发灰,最差质量,低质量,JPEG压缩残留,丑陋的,残缺的,多余的手指,画得不好的手部,画得不好的脸部,畸形的,毁容的,形态畸形的肢体,手指融合,静止不动的画面,杂乱的背景,三条腿,背景人很多,倒着走",+ "text": "\u8272\u8c03\u8273\u4e3d\uff0c\u8fc7\u66dd\uff0c\u9759\u6001\uff0c\u7ec6\u8282\u6a21\u7cca\u4e0d\u6e05\uff0c\u5b57\u5e55\uff0c\u98ce\u683c\uff0c\u4f5c\u54c1\uff0c\u753b\u4f5c\uff0c\u753b\u9762\uff0c\u9759\u6b62\uff0c\u6574\u4f53\u53d1\u7070\uff0c\u6700\u5dee\u8d28\u91cf\uff0c\u4f4e\u8d28\u91cf\uff0cJPEG\u538b\u7f29\u6b8b\u7559\uff0c\u4e11\u964b\u7684\uff0c\u6b8b\u7f3a\u7684\uff0c\u591a\u4f59\u7684\u624b\u6307\uff0c\u753b\u5f97\u4e0d\u597d\u7684\u624b\u90e8\uff0c\u753b\u5f97\u4e0d\u597d\u7684\u8138\u90e8\uff0c\u7578\u5f62\u7684\uff0c\u6bc1\u5bb9\u7684\uff0c\u5f62\u6001\u7578\u5f62\u7684\u80a2\u4f53\uff0c\u624b\u6307\u878d\u5408\uff0c\u9759\u6b62\u4e0d\u52a8\u7684\u753b\u9762\uff0c\u6742\u4e71\u7684\u80cc\u666f\uff0c\u4e09\u6761\u817f\uff0c\u80cc\u666f\u4eba\u5f88\u591a\uff0c\u5012\u7740\u8d70","clip": ["15",0@@ -774,5 +774,60 @@"_meta": {"title": "Work height (multiple of 16, <= 1280)"}+ },+ "74": {+ "class_type": "MaskToImage",+ "inputs": {+ "mask": [+ "10",+ 0+ ]+ },+ "_meta": {+ "title": "Tracked masks as images"+ }+ },+ "75": {+ "class_type": "ComfyMathExpression",+ "inputs": {+ "expression": "max(0, a - 1)",+ "values.a": [+ "86",+ 1+ ]+ },+ "_meta": {+ "title": "The window's last frame"+ }+ },+ "76": {+ "class_type": "ImageFromBatch",+ "inputs": {+ "image": [+ "74",+ 0+ ],+ "batch_index": [+ "75",+ 1+ ],+ "length": 1+ },+ "_meta": {+ "title": "Its tracked mask"+ }+ },+ "77": {+ "class_type": "SaveImage",+ "inputs": {+ "images": [+ "76",+ 0+ ],+ "filename_prefix": "fuobe/video-inpaint-wan-vace-painted"+ },+ "_meta": {+ "title": "Save the last frame's mask (starts the next window: white = the object)"+ }}}diff --git a/scripts/comfy/library.spec.mjs b/scripts/comfy/library.spec.mjsindex 49119d64..eeb8d0d7 100644--- a/scripts/comfy/library.spec.mjs+++ b/scripts/comfy/library.spec.mjs@@ -73,9 +73,13 @@// cutout, numGaussians, splatFormat (TripoSplat: BiRefNet cut-out on/off, number of Gaussians, ply | ksplat | spz)// orbitFrames (TripoSplat orbit preview length in frames)// frameWidth (reference brief: width the clip's frames are scaled to, px)+// Keys added by the remove-object package (round 4):+// colormap* (Video Depth Anything's colour map: gray | inferno; params.colormap grayscale → gray)+// sideBySide (depth maps: the original clip next to the depth map)// Output fields beyond {node, kind}: stem ("voice" | "background"), role ("cues" | "transcript" | "language" |// "sheet" | "tiles" | "layers" | "first-frame" | "turntable" | "lines" | "frame" | "frames" | "scene" | "depth" | "splat" |-// "brief"). Entry fields: worker "isolated" (needs its own ComfyUI, see README), expand "captions" (the provider writes one+// "brief" | "mask" (a painted eraser's last tracked frame, white = the object) | "cutout" | "matte" (a matte graph's transparent+// and black-and-white videos: params.extra.keepOutput keeps one)). Entry fields: worker "isolated" (needs its own ComfyUI, see README), expand "captions" (the provider writes one// segment per caption cue before submitting).import fs from 'node:fs';@@ -1690,8 +1694,8 @@ export const SPEC = [handBuilt: 'hand-built/video-bg-remove-birefnet.json',bindings: { video: [b('1', 'file')] },outputs: [- { node: '7', kind: 'video' },- { node: '10', kind: 'video' },+ { node: '7', kind: 'video', role: 'cutout' },+ { node: '10', kind: 'video', role: 'matte' },],limits: { maxWidth: 2048, maxHeight: 2048 },vramGb: 4,@@ -1699,7 +1703,8 @@ export const SPEC = [notes:'Core RemoveBackground on every frame -> InvertMask -> JoinImageWithAlpha (it stores 1-mask as alpha, like bg-remove-birefnet) -> SaveWEBM (vp9, crf 24, fps = source fps): an RGBA .webm with real transparency (yuva420p). ' +'Second output (node 10) = black/white matte .mp4 for compositing. SaveWEBM reports its file under history outputs "images" (animated: true), not "videos": classify by the .webm extension / the declared kind. ' +- 'Per-frame model, so hair edges may flicker (inferred). Source audio is dropped. For "keep only X" use video-bg-remove-sam3.',+ 'Per-frame model, so hair edges may flicker (inferred). Source audio is dropped. For "keep only X" use video-bg-remove-sam3. ' ++ 'Roles: node 7 "cutout", node 10 "matte"; params.extra.keepOutput ("cutout" | "matte") makes the provider drop the other save node (Video tools → Remove background: Cutout video / Alpha mask).',},{id: 'video-bg-remove-sam3',@@ -1710,20 +1715,26 @@ export const SPEC = [video: [b('1', 'file')],prompt: [b('4', 'text')],},- outputs: [{ node: '9', kind: 'video' }],+ outputs: [+ { node: '9', kind: 'video', role: 'cutout' },+ { node: '12', kind: 'video', role: 'matte' },+ ],limits: { maxWidth: 2048, maxHeight: 2048 },vramGb: 6,license: 'Meta SAM License (royalty-free, commercial use allowed; attribution + acceptable-use terms)',notes:'prompt = what to KEEP ("person", "red car"). SAM3_VideoTrack (detection_threshold 0.5, max_objects 4, detect_interval 1) -> SAM3_TrackToMask (object_indices "" = all tracked objects) -> InvertMask -> JoinImageWithAlpha -> SaveWEBM (vp9, fps = source). ' +- 'Masks are hard-edged; multiply with the BiRefNet matte for hair. Output under history "images" (animated .webm). Template utility_video_segment_sam3 runs SAM3_Detect per frame instead.',+ 'Masks are hard-edged; multiply with the BiRefNet matte for hair. Output under history "images" (animated .webm). Template utility_video_segment_sam3 runs SAM3_Detect per frame instead. ' ++ 'Second output (node 12, role "matte", added by the remove-object package) = the black-and-white matte .mp4 of what was kept (MaskToImage -> CreateVideo at the source fps); ' ++ 'params.extra.keepOutput ("cutout" | "matte") makes the provider drop the other save node, so only the chosen one is encoded.',},{id: 'video-depth-da3',title: 'Video Depth Map (Depth Anything 3 Mono)',capability: 'depth-video',handBuilt: 'hand-built/video-depth-da3.json',- bindings: { video: [b('1', 'file')] },+ bindings: { video: [b('1', 'file')], sideBySide: [b('9', 'value')] },+ defaults: { sideBySide: false },outputs: [{ node: '7', kind: 'video' }],limits: { maxWidth: 2048, maxHeight: 2048 },vramGb: 4,@@ -1737,7 +1748,8 @@ export const SPEC = [title: 'Video Depth Map (Video Depth Anything Small, temporally stable)',capability: 'depth-video',handBuilt: 'hand-built/video-depth-vda-small.json',- bindings: { video: [b('1', 'file')] },+ bindings: { video: [b('1', 'file')], colormap: [b('5', 'colormap')], sideBySide: [b('9', 'value')] },+ defaults: { colormap: 'gray', sideBySide: false },outputs: [{ node: '7', kind: 'video' }],limits: { maxWidth: 2048, maxHeight: 2048 },vramGb: 4,@@ -1745,7 +1757,9 @@ export const SPEC = [autoDownloads: ['LoadVideoDepthAnythingModel downloads depth-anything/Video-Depth-Anything-Small video_depth_anything_vits.pth (0.12 GB) into models/videodepthanything on first run'],notes:'yuvraj108c/ComfyUI-Video-Depth-Anything: LoadVideoDepthAnythingModel(model video_depth_anything_vits.pth - pass it explicitly, the declared default ".safetensors" is not in its own option list) -> ' +- 'VideoDepthAnythingProcess(input_size 518, max_res 1280, fp16) -> VideoDepthAnythingOutput(gray) -> CreateVideo (source fps). Designed for long videos with consistent depth across frames. Audio dropped.',+ 'VideoDepthAnythingProcess(input_size 518, max_res 1280, fp16) -> VideoDepthAnythingOutput(gray) -> CreateVideo (source fps). Designed for long videos with consistent depth across frames. Audio dropped. ' ++ 'colormap = gray | inferno (the only two VideoDepthAnythingOutput offers; turbo / magma / viridis would need a LUT step). sideBySide true = the original clip on the left, ' ++ 'the depth map scaled to the clip\'s size on the right (ImageStitch; an even width for the encoder), through a lazy ComfySwitchNode (remove-object package).',},// ---- palette / colour lock ----------------------------------------------@@ -2537,7 +2551,10 @@ export const SPEC = [maskGrow: [b('11', 'expand')], prompt: [b('16', 'text')], negativePrompt: [b('17', 'text')], checkpoint: [b('20', 'unet_name')],loraStrength: [b('21', 'strength_model')], shift: [b('22', 'shift')], seed: [b('23', 'seed')], steps: [b('23', 'steps')], cfg: [b('23', 'cfg')],},- outputs: [{ node: '38', kind: 'video' }],+ outputs: [+ { node: '38', kind: 'video' },+ { node: '77', kind: 'image', role: 'mask' },+ ],defaults: { checkpoint: 'wan2.1_vace_14B_fp16.safetensors' },limits: { maxWidth: 1280, maxHeight: 1280, maxFrames: 81, dimensionMultiple: 16 },vramGb: 24,@@ -2548,7 +2565,9 @@ export const SPEC = ['The mask is scaled to the work size like the frames (not cropped), so any PNG size lines up. ' +'Everything else as video-inpaint-wan-vace: windows in seconds (startTime, duration; at most 81 frames, the largest 4n+1 decoded), width x height = the work-size budget in the clip\'s shape, ' +'paste-back into the original frames, the window\'s sound kept. ' +- 'For a window after the first, the mask must be painted on (or tracked to) that window\'s first frame. Validated by /prompt only (no GPU here).',+ 'For a window after the first, the mask must be painted on (or tracked to) that window\'s first frame: the second output (node 77, role "mask", added by the remove-object package) ' ++ 'is the tracked mask of the window\'s LAST frame (SAM3_TrackToMask before GrowMask, at the work size, white = the object), which Fuobe feeds to the next window as its mask, so the object is followed across windows. ' ++ 'Validated by /prompt only (no GPU here).',},{id: 'video-erase-void',diff --git a/scripts/comfy/validation-state.json b/scripts/comfy/validation-state.jsonindex 042e2067..db52bbc8 100644--- a/scripts/comfy/validation-state.json+++ b/scripts/comfy/validation-state.json@@ -519,13 +519,13 @@"sha256": "08da8d310a04add6eb729fb67f3a82b63b0a806368ce49fc498dfe6aeb58c83e","validated": true,"error": null,- "at": "2026-10-16T23:33:21.314Z"+ "at": "2026-10-23T01:11:55.971Z"},"video-bg-remove-sam3": {- "sha256": "111df3bc07d19b0b7c05b31150a260799a991fdd82f5b0407fa476338489452a",+ "sha256": "0d8eb4714dee686b9c5b63a74ff2edd7feccf8eae825e3c6843e00efe1bac1b9","validated": true,"error": null,- "at": "2026-10-16T23:33:21.559Z"+ "at": "2026-10-23T01:11:55.986Z"},"video-concat-2": {"sha256": "3d08966f5a3c2da662dc112df537ad4245bcd5dbb90e0451a0beb5c54d8db581",@@ -582,16 +582,16 @@"at": "2026-10-21T16:25:18.439Z"},"video-depth-da3": {- "sha256": "4c2dd5a6ee8b99eb9eeaf3ea5c9e7b3439964dc87171afef8dbbe2db53676f81",+ "sha256": "732796f61d7404fe06f9e1132262778692c7e51ebca7316841ed14b91493e4f7","validated": true,"error": null,- "at": "2026-10-16T23:33:21.879Z"+ "at": "2026-10-23T01:11:55.998Z"},"video-depth-vda-small": {- "sha256": "aa686ba74bb94dad4ef71f54eed453589d6330e3b25ae79ed5721637fe8902bb",+ "sha256": "dc83a7795e72cde121a462cc9b3cc684e9619711521d3935fee015209f932dfe","validated": true,"error": null,- "at": "2026-10-16T23:33:22.128Z"+ "at": "2026-10-23T01:11:56.014Z"},"video-erase-void": {"sha256": "667f8b59d931311b5081e2407ef53aee0b39a36007cf838ba18b64d5d2681bdc",@@ -624,10 +624,10 @@"at": "2026-10-23T00:12:19.803Z"},"video-inpaint-wan-vace-painted": {- "sha256": "2563d3d6a4ecac8d21d7831324eb4c0e93797afce58eaed71015bca3aa7549ab",+ "sha256": "97d00c52d4c177c408528604cf20116bebf7128fba216021fefe5560f9a8d3fb","validated": true,"error": null,- "at": "2026-10-23T00:12:20.124Z"+ "at": "2026-10-23T01:11:56.041Z"},"video-insert-wan-vace": {"sha256": "5f57a143e6b2357badf59ebaa3d6d5c834c03330dee79f8af96d9b2307b5be24",diff --git a/src/lib/comfy.ts b/src/lib/comfy.tsindex 0c4f585b..28113a7f 100644--- a/src/lib/comfy.ts+++ b/src/lib/comfy.ts@@ -59,7 +59,8 @@ export interface ManifestOutput {/*** What a text, image or 3D output is: timed caption cues, a plain transcript, the detected language, layers, a grid's sheet or tiles…* Round 4: OCR "lines" (JSON, boxes 0–1000) and the "frame" the model saw, an EXR sequence's "frames", a whole-"scene" GLB and its- * "depth" map, a Gaussian "splat", a reference video's style "brief".+ * "depth" map, a Gaussian "splat", a reference video's style "brief"; a painted eraser's last tracked "mask" (handed to the next+ * window), and a matte graph's "cutout" (transparent video) and "matte" (black and white) videos.*/role?:| "cues"@@ -76,7 +77,10 @@ export interface ManifestOutput {| "scene"| "depth"| "splat"- | "brief";+ | "brief"+ | "mask"+ | "cutout"+ | "matte";}export interface ManifestWorkflow {diff --git a/tests/comfy-library-4.test.ts b/tests/comfy-library-4.test.tsindex 0c409dfb..105312ab 100644--- a/tests/comfy-library-4.test.ts+++ b/tests/comfy-library-4.test.ts@@ -18,7 +18,8 @@ const VACE = ["startTime", "duration", "width", "height", "maskGrow", "prompt",const ROUND4: Record<string, { capability: string; bindings: string[]; outputs: [string, string?][] }> = {"ocr-lines-qwen35": { capability: "ocr", bindings: ["image", "maxSize", "checkpoint", "instruction", "maxTokens", "filenamePrefix"], outputs: [["text", "lines"], ["text", "frame"]] },"video-inpaint-wan-vace": { capability: "remove-object", bindings: ["video", "maskPrompt", ...VACE], outputs: [["video"]] },- "video-inpaint-wan-vace-painted": { capability: "remove-object", bindings: ["video", "mask", ...VACE], outputs: [["video"]] },+ // The painted eraser also saves its last tracked frame's mask, which starts the next window (remove-object package).+ "video-inpaint-wan-vace-painted": { capability: "remove-object", bindings: ["video", "mask", ...VACE], outputs: [["video"], ["image", "mask"]] },"video-erase-void": {capability: "remove-object",bindings: ["video", "startTime", "duration", "width", "height", "maskPrompt", "maskGrow", "prompt", "negativePrompt", "cfg", "steps", "seed", "skipPass2", "filenamePrefix"],@@ -54,6 +55,8 @@ const ROUND4: Record<string, { capability: string; bindings: string[]; outputs:const MEDIA: Record<string, string> = { LoadImage: "image", LoadImageMask: "image", LoadVideo: "file", VHS_LoadVideo: "video", LoadAudio: "audio", VHS_LoadAudioUpload: "audio" };const ROLES: NonNullable<ManifestOutput["role"]>[] = ["cues", "transcript", "language", "layers", "sheet", "tiles", "first-frame", "turntable", "lines", "frame", "frames", "scene", "depth", "splat", "brief",+ // remove-object package: the painted eraser's hand-off mask, the matte graphs' two videos.+ "mask", "cutout", "matte",];describe("round-4 ComfyUI workflows", () => {@@ -189,7 +192,8 @@ for (const id of ["video-inpaint-wan-vace", "video-inpaint-wan-vace-painted", "vWINDOWS[id] = {cap: 81,counts: [[82, 81], [81, 81], [80, 77], [30, 29], [5, 5], [1, 1]],- lengthUsers: ["ComfyMathExpression", "ImageFromBatch", ...(id === "video-insert-wan-vace" ? ["RepeatImageBatch"] : []), "WanVaceToVideo"],+ // The painted eraser also counts back from the window's last frame for the mask it hands on.+ lengthUsers: ["ComfyMathExpression", "ImageFromBatch", ...(id === "video-insert-wan-vace" ? ["RepeatImageBatch"] : []), ...(id.endsWith("-painted") ? ["ComfyMathExpression"] : []), "WanVaceToVideo"],model: "WanVaceToVideo",workScales: id.endsWith("-painted") || id === "video-insert-wan-vace" ? 2 : 1,sizes: SAMPLE_SIZES.vace,diff --git a/workflows/comfyui/manifest.json b/workflows/comfyui/manifest.jsonindex 56b441d5..a2fd8957 100644--- a/workflows/comfyui/manifest.json+++ b/workflows/comfyui/manifest.json@@ -1,6 +1,6 @@{"version": 1,- "generatedAt": "2026-10-23T00:20:02.191Z",+ "generatedAt": "2026-10-23T01:11:51.812Z","comfyuiCommit": "fc04da91b2ab12f99e4716371a7e4f98ac982597","comfyuiVersion": "0.41.0","workflowTemplatesVersion": "0.11.86",@@ -7652,11 +7652,13 @@"outputs": [{"node": "7",- "kind": "video"+ "kind": "video",+ "role": "cutout"},{"node": "10",- "kind": "video"+ "kind": "video",+ "role": "matte"}],"defaults": {},@@ -7676,7 +7678,7 @@"vramGb": 4,"license": "MIT (BiRefNet)","validated": true,- "notes": "Core RemoveBackground on every frame -> InvertMask -> JoinImageWithAlpha (it stores 1-mask as alpha, like bg-remove-birefnet) -> SaveWEBM (vp9, crf 24, fps = source fps): an RGBA .webm with real transparency (yuva420p). Second output (node 10) = black/white matte .mp4 for compositing. SaveWEBM reports its file under history outputs \"images\" (animated: true), not \"videos\": classify by the .webm extension / the declared kind. Per-frame model, so hair edges may flicker (inferred). Source audio is dropped. For \"keep only X\" use video-bg-remove-sam3."+ "notes": "Core RemoveBackground on every frame -> InvertMask -> JoinImageWithAlpha (it stores 1-mask as alpha, like bg-remove-birefnet) -> SaveWEBM (vp9, crf 24, fps = source fps): an RGBA .webm with real transparency (yuva420p). Second output (node 10) = black/white matte .mp4 for compositing. SaveWEBM reports its file under history outputs \"images\" (animated: true), not \"videos\": classify by the .webm extension / the declared kind. Per-frame model, so hair edges may flicker (inferred). Source audio is dropped. For \"keep only X\" use video-bg-remove-sam3. Roles: node 7 \"cutout\", node 10 \"matte\"; params.extra.keepOutput (\"cutout\" | \"matte\") makes the provider drop the other save node (Video tools → Remove background: Cutout video / Alpha mask)."},{"id": "video-bg-remove-sam3",@@ -7701,13 +7703,23 @@{"node": "9","input": "filename_prefix"+ },+ {+ "node": "12",+ "input": "filename_prefix"}]},"outputs": [{"node": "9",- "kind": "video"+ "kind": "video",+ "role": "cutout"+ },+ {+ "node": "12",+ "kind": "video",+ "role": "matte"}],"defaults": {},@@ -7727,7 +7739,7 @@"vramGb": 6,"license": "Meta SAM License (royalty-free, commercial use allowed; attribution + acceptable-use terms)","validated": true,- "notes": "prompt = what to KEEP (\"person\", \"red car\"). SAM3_VideoTrack (detection_threshold 0.5, max_objects 4, detect_interval 1) -> SAM3_TrackToMask (object_indices \"\" = all tracked objects) -> InvertMask -> JoinImageWithAlpha -> SaveWEBM (vp9, fps = source). Masks are hard-edged; multiply with the BiRefNet matte for hair. Output under history \"images\" (animated .webm). Template utility_video_segment_sam3 runs SAM3_Detect per frame instead."+ "notes": "prompt = what to KEEP (\"person\", \"red car\"). SAM3_VideoTrack (detection_threshold 0.5, max_objects 4, detect_interval 1) -> SAM3_TrackToMask (object_indices \"\" = all tracked objects) -> InvertMask -> JoinImageWithAlpha -> SaveWEBM (vp9, fps = source). Masks are hard-edged; multiply with the BiRefNet matte for hair. Output under history \"images\" (animated .webm). Template utility_video_segment_sam3 runs SAM3_Detect per frame instead. Second output (node 12, role \"matte\", added by the remove-object package) = the black-and-white matte .mp4 of what was kept (MaskToImage -> CreateVideo at the source fps); params.extra.keepOutput (\"cutout\" | \"matte\") makes the provider drop the other save node, so only the chosen one is encoded."},{"id": "video-depth-da3",@@ -7742,6 +7754,12 @@"input": "file"}],+ "sideBySide": [+ {+ "node": "9",+ "input": "value"+ }+ ],"filenamePrefix": [{"node": "7",@@ -7755,7 +7773,9 @@"kind": "video"}],- "defaults": {},+ "defaults": {+ "sideBySide": false+ },"limits": {"maxWidth": 2048,"maxHeight": 2048@@ -7787,6 +7807,18 @@"input": "file"}],+ "colormap": [+ {+ "node": "5",+ "input": "colormap"+ }+ ],+ "sideBySide": [+ {+ "node": "9",+ "input": "value"+ }+ ],"filenamePrefix": [{"node": "7",@@ -7800,7 +7832,10 @@"kind": "video"}],- "defaults": {},+ "defaults": {+ "colormap": "gray",+ "sideBySide": false+ },"limits": {"maxWidth": 2048,"maxHeight": 2048@@ -7815,7 +7850,7 @@"vramGb": 4,"license": "Apache-2.0 (Video-Depth-Anything-Small); Base/Large and metric variants are CC-BY-NC-4.0 (non-commercial) - keep the vits model","validated": true,- "notes": "yuvraj108c/ComfyUI-Video-Depth-Anything: LoadVideoDepthAnythingModel(model video_depth_anything_vits.pth - pass it explicitly, the declared default \".safetensors\" is not in its own option list) -> VideoDepthAnythingProcess(input_size 518, max_res 1280, fp16) -> VideoDepthAnythingOutput(gray) -> CreateVideo (source fps). Designed for long videos with consistent depth across frames. Audio dropped.",+ "notes": "yuvraj108c/ComfyUI-Video-Depth-Anything: LoadVideoDepthAnythingModel(model video_depth_anything_vits.pth - pass it explicitly, the declared default \".safetensors\" is not in its own option list) -> VideoDepthAnythingProcess(input_size 518, max_res 1280, fp16) -> VideoDepthAnythingOutput(gray) -> CreateVideo (source fps). Designed for long videos with consistent depth across frames. Audio dropped. colormap = gray | inferno (the only two VideoDepthAnythingOutput offers; turbo / magma / viridis would need a LUT step). sideBySide true = the original clip on the left, the depth map scaled to the clip's size on the right (ImageStitch; an even width for the encoder), through a lazy ComfySwitchNode (remove-object package).","autoDownloads": ["LoadVideoDepthAnythingModel downloads depth-anything/Video-Depth-Anything-Small video_depth_anything_vits.pth (0.12 GB) into models/videodepthanything on first run"]@@ -11839,6 +11874,10 @@{"node": "38","input": "filename_prefix"+ },+ {+ "node": "77",+ "input": "filename_prefix"}]},@@ -11846,6 +11885,11 @@{"node": "38","kind": "video"+ },+ {+ "node": "77",+ "kind": "image",+ "role": "mask"}],"defaults": {@@ -11907,7 +11951,7 @@"vramGb": 24,"license": "Apache-2.0 (Wan 2.1 VACE 14B, lightx2v T2V LoRA, umT5, Wan VAE); SAM 3.1 under Meta's SAM License (commercial use allowed under its terms); GrowMaskWithBlur from ComfyUI-KJNodes (GPL-3.0 code)","validated": true,- "notes": "mask = a PNG of the window's FIRST frame, read from the red channel: white = the object to remove, black = keep (in the clip's shape). SAM3_VideoTrack takes it as initial_mask and tracks the object through the window. Changed from the research graph: the mask is read from the red channel (Fuobe's mask convention, as flux1-fill-inpaint) instead of alpha. The mask is scaled to the work size like the frames (not cropped), so any PNG size lines up. Everything else as video-inpaint-wan-vace: windows in seconds (startTime, duration; at most 81 frames, the largest 4n+1 decoded), width x height = the work-size budget in the clip's shape, paste-back into the original frames, the window's sound kept. For a window after the first, the mask must be painted on (or tracked to) that window's first frame. Validated by /prompt only (no GPU here)."+ "notes": "mask = a PNG of the window's FIRST frame, read from the red channel: white = the object to remove, black = keep (in the clip's shape). SAM3_VideoTrack takes it as initial_mask and tracks the object through the window. Changed from the research graph: the mask is read from the red channel (Fuobe's mask convention, as flux1-fill-inpaint) instead of alpha. The mask is scaled to the work size like the frames (not cropped), so any PNG size lines up. Everything else as video-inpaint-wan-vace: windows in seconds (startTime, duration; at most 81 frames, the largest 4n+1 decoded), width x height = the work-size budget in the clip's shape, paste-back into the original frames, the window's sound kept. For a window after the first, the mask must be painted on (or tracked to) that window's first frame: the second output (node 77, role \"mask\", added by the remove-object package) is the tracked mask of the window's LAST frame (SAM3_TrackToMask before GrowMask, at the work size, white = the object), which Fuobe feeds to the next window as its mask, so the object is followed across windows. Validated by /prompt only (no GPU here)."},{"id": "video-erase-void",diff --git a/workflows/comfyui/object_info.subset.json b/workflows/comfyui/object_info.subset.jsonindex 2821f9f8..0595a42e 100644--- a/workflows/comfyui/object_info.subset.json+++ b/workflows/comfyui/object_info.subset.json@@ -5290,7 +5290,9 @@{"tooltip": "Select a frame interpolation model to load. Models must be placed in the 'frame_interpolation' folder.","multiselect": false,- "options": []+ "options": [+ "vftest_rife_random.safetensors"+ ]}]}@@ -17564,7 +17566,9 @@"COMBO",{"multiselect": false,- "options": []+ "options": [+ "vftest_esrgan_x4_random.safetensors"+ ]}]}diff --git a/workflows/comfyui/video-bg-remove-sam3.json b/workflows/comfyui/video-bg-remove-sam3.jsonindex f44a1df4..d85e2606 100644--- a/workflows/comfyui/video-bg-remove-sam3.json+++ b/workflows/comfyui/video-bg-remove-sam3.json@@ -114,5 +114,52 @@"_meta": {"title": "Save transparent WebM (VP9 alpha)"}+ },+ "10": {+ "class_type": "MaskToImage",+ "inputs": {+ "mask": [+ "6",+ 0+ ]+ },+ "_meta": {+ "title": "Matte (white = what was kept)"+ }+ },+ "11": {+ "class_type": "CreateVideo",+ "inputs": {+ "images": [+ "10",+ 0+ ],+ "fps": [+ "2",+ 2+ ],+ "bit_depth": "auto",+ "color_space": "sRGB",+ "codec": "none"+ },+ "_meta": {+ "title": "Matte video"+ }+ },+ "12": {+ "class_type": "SaveVideo",+ "inputs": {+ "video": [+ "11",+ 0+ ],+ "filename_prefix": "fuobe/video-bg-remove-sam3",+ "format": "auto",+ "format.codec": "auto",+ "codec": "auto"+ },+ "_meta": {+ "title": "Save matte MP4"+ }}}diff --git a/workflows/comfyui/video-depth-da3.json b/workflows/comfyui/video-depth-da3.jsonindex 7af1953b..0316ff16 100644--- a/workflows/comfyui/video-depth-da3.json+++ b/workflows/comfyui/video-depth-da3.json@@ -60,7 +60,7 @@"class_type": "CreateVideo","inputs": {"images": [- "5",+ "10",0],"fps": [@@ -92,5 +92,88 @@"_meta": {"title": "Save depth video"}+ },+ "8": {+ "class_type": "ImageStitch",+ "inputs": {+ "image1": [+ "2",+ 0+ ],+ "image2": [+ "12",+ 0+ ],+ "direction": "right",+ "match_image_size": false,+ "spacing_width": 0,+ "spacing_color": "black"+ },+ "_meta": {+ "title": "Original | depth"+ }+ },+ "9": {+ "class_type": "PrimitiveBoolean",+ "inputs": {+ "value": false+ },+ "_meta": {+ "title": "Side by side (sideBySide)"+ }+ },+ "10": {+ "class_type": "ComfySwitchNode",+ "inputs": {+ "switch": [+ "9",+ 0+ ],+ "on_true": [+ "8",+ 0+ ],+ "on_false": [+ "5",+ 0+ ]+ },+ "_meta": {+ "title": "Depth alone, or next to the original"+ }+ },+ "11": {+ "class_type": "GetImageSize",+ "inputs": {+ "image": [+ "2",+ 0+ ]+ },+ "_meta": {+ "title": "The clip's size"+ }+ },+ "12": {+ "class_type": "ImageScale",+ "inputs": {+ "image": [+ "5",+ 0+ ],+ "upscale_method": "lanczos",+ "width": [+ "11",+ 0+ ],+ "height": [+ "11",+ 1+ ],+ "crop": "disabled"+ },+ "_meta": {+ "title": "Depth at the clip's size (an even total width for the encoder)"+ }}}diff --git a/workflows/comfyui/video-depth-vda-small.json b/workflows/comfyui/video-depth-vda-small.jsonindex fa978af5..34fe740b 100644--- a/workflows/comfyui/video-depth-vda-small.json+++ b/workflows/comfyui/video-depth-vda-small.json@@ -51,13 +51,15 @@],"colormap": "gray"},- "_meta": {}+ "_meta": {+ "title": "Colour map (colormap: gray | inferno)"+ }},"6": {"class_type": "CreateVideo","inputs": {"images": [- "5",+ "10",0],"fps": [@@ -85,5 +87,88 @@"_meta": {"title": "Save depth video"}+ },+ "8": {+ "class_type": "ImageStitch",+ "inputs": {+ "image1": [+ "2",+ 0+ ],+ "image2": [+ "12",+ 0+ ],+ "direction": "right",+ "match_image_size": false,+ "spacing_width": 0,+ "spacing_color": "black"+ },+ "_meta": {+ "title": "Original | depth"+ }+ },+ "9": {+ "class_type": "PrimitiveBoolean",+ "inputs": {+ "value": false+ },+ "_meta": {+ "title": "Side by side (sideBySide)"+ }+ },+ "10": {+ "class_type": "ComfySwitchNode",+ "inputs": {+ "switch": [+ "9",+ 0+ ],+ "on_true": [+ "8",+ 0+ ],+ "on_false": [+ "5",+ 0+ ]+ },+ "_meta": {+ "title": "Depth alone, or next to the original"+ }+ },+ "11": {+ "class_type": "GetImageSize",+ "inputs": {+ "image": [+ "2",+ 0+ ]+ },+ "_meta": {+ "title": "The clip's size"+ }+ },+ "12": {+ "class_type": "ImageScale",+ "inputs": {+ "image": [+ "5",+ 0+ ],+ "upscale_method": "lanczos",+ "width": [+ "11",+ 0+ ],+ "height": [+ "11",+ 1+ ],+ "crop": "disabled"+ },+ "_meta": {+ "title": "Depth at the clip's size (an even total width for the encoder)"+ }}}diff --git a/workflows/comfyui/video-inpaint-wan-vace-painted.json b/workflows/comfyui/video-inpaint-wan-vace-painted.jsonindex a7ebadf1..4c12a7ca 100644--- a/workflows/comfyui/video-inpaint-wan-vace-painted.json+++ b/workflows/comfyui/video-inpaint-wan-vace-painted.json@@ -606,6 +606,61 @@"title": "First-frame mask"}},+ "74": {+ "class_type": "MaskToImage",+ "inputs": {+ "mask": [+ "10",+ 0+ ]+ },+ "_meta": {+ "title": "Tracked masks as images"+ }+ },+ "75": {+ "class_type": "ComfyMathExpression",+ "inputs": {+ "expression": "max(0, a - 1)",+ "values.a": [+ "86",+ 1+ ]+ },+ "_meta": {+ "title": "The window's last frame"+ }+ },+ "76": {+ "class_type": "ImageFromBatch",+ "inputs": {+ "image": [+ "74",+ 0+ ],+ "batch_index": [+ "75",+ 1+ ],+ "length": 1+ },+ "_meta": {+ "title": "Its tracked mask"+ }+ },+ "77": {+ "class_type": "SaveImage",+ "inputs": {+ "images": [+ "76",+ 0+ ],+ "filename_prefix": "fuobe/video-inpaint-wan-vace-painted"+ },+ "_meta": {+ "title": "Save the last frame's mask (starts the next window: white = the object)"+ }+ },"80": {"class_type": "Video Slice","inputs": {