Files
DemonGatanjieu-Anomalous_Mo…/api/blocks/inpaint_basic.json
T
DemonGatanjieuandClaude Opus 5.5 8ecc261949 Let ready-made blocks say what they hand the next one, and build them as a chain
Every block in api/blocks names what it gives a block after it ("gives": its sampler and its
output node; {} for one that changes the step it is put on) and its own model loader
("own_model"). api/block_chain.py builds a list of steps on a new tab: the picture first, each
next block anchored to what the step before gave, by near_node_id and a new page-only
save_node_id (canvas_roles.js findRoles pins the output node), so a canvas with several
samplers and outputs is no guess. add_nodes' answer names the block it built.

Redraw with another model and face/hand detailing now take the step before's picture
("$save.images") instead of the sampler's decode, which after an enlargement is the older
picture. The two-model routes are built as two-step chains; routes.json no longer names the
loaders.

Checked through the real page on the test ComfyUI: the Tile route on two Anima models (base on
Harem 1.5, Tile redraw on Kirazuri v4, from the base's picture and prompts), then face and hand
detailing after it took the Tile step's colour-matched picture.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-09 00:42:56 +08:00

74 lines
1.8 KiB
JSON

{
"job": "repaint",
"rank": 3,
"short": "built-in nodes",
"title": {
"zh": "局部重绘·官方节点",
"en": "Repaint: built-in nodes"
},
"about": {
"zh": "只用 ComfyUI 自带的节点重画圈出的地方,没装别的包时用。",
"en": "ComfyUI's own nodes only: for when the packs above are missing."
},
"source": {
"zh": "ComfyUI 官方的局部重绘做法",
"en": "ComfyUI's own way to inpaint"
},
"packs": {},
"takes": "inpaint",
"nodes": {
"picture": {
"class_type": "LoadImage",
"inputs": {
"image": "$image"
}
},
"soft": {
"class_type": "DifferentialDiffusion",
"inputs": {
"model": [
"$sampler.model",
"*"
]
},
"wire_to": "$sampler"
},
"encode": {
"class_type": "VAEEncode",
"inputs": {
"pixels": [
"picture",
0
],
"vae": [
"$decode.vae",
"*"
]
}
},
"area": {
"class_type": "SetLatentNoiseMask",
"inputs": {
"samples": [
"encode",
0
],
"mask": [
"picture",
1
]
},
"wire_to": "$sampler"
}
},
"roles": {
"sampler": {
"denoise": 0.5
}
},
"after": "The sampler repaints only the area, at denoise 0.5 so it keeps the picture's look (higher changes more). The marked area's size becomes the size of what is painted there: mark tightly around it (a hand, not the arm beside it). Keep denoise 0.35-0.5 to fix something and keep its size and pose; 0.7 and up paints a new thing that fills the whole mark. Hands and faces vary a lot from seed to seed: run_workflow with batch 4 and let the user pick, rather than judging one. Then run_workflow.",
"gives": {},
"models": [],
"tested": {}
}