Nodes/ComfyUI-MoonNodes/πŸŒ— Moon Multi-Area KSampler (experiment)
ComfyUI Node

πŸŒ— Moon Multi-Area KSampler (experiment)

Regional prompting, all inside one sampler node β€” if you're brave

By m0rtus59Β·Created 3 months agoΒ·Updated 9 days agoΒ· 8
πŸŒ— Moon Multi-Area KSampler (experiment)
  • model
  • clip
  • mask_list
  • positive_list
  • negative_list
  • latent_image
  • LATENT
β—„modeMergeβ–Ί
β—„seed0β–Ί
β—„steps20β–Ί
β—„cfg8.0β–Ί
β—„sampler_nameβ–Ύβ–Ί
β—„schedulerβ–Ύβ–Ί
β—„denoise1.00β–Ί
β—„local_pass_percent0.20β–Ί

The pack's README labels this one "(experiment)", and you should take that label seriously. MoonMultiPassSampler is the all-in-one idea: instead of building the regional graph - patched model, combined conditioning, then a separate KSampler - this node is the sampler. It takes the model, masks, conditionings, and a latent, runs an elaborate multi-phase denoising routine internally, and hands you a finished latent. No downstream KSampler required.

It's ambitious, and it shows. Let me tell you what it does before I tell you whether you should use it.

The mechanism, in one breath

Normal KSamplers denoise the whole canvas together. This one weaves two different modes during the early part of sampling:

  • Isolated steps denoise each masked region and the background separately - each under its own prompt, exactly one step - then stitch them back onto the latent canvas.
  • Global steps denoise the whole canvas together through the attention-patched model, keeping composition and lighting cohesive so the regions don't end up looking like stickers.

local_pass_percent (default 0.2) controls how much of the run spends time in that alternating weave. At 0.2, the first ~20% of steps alternate between isolated and global passes; the remaining 80% finish as one unified pass through the patched model. That early-isolation / late-blend structure is exactly the "stop masking once composition has formed" advice from the regional-prompting playbook - automated, instead of left to your head_start_percent judgment.

There's also a detail that matters if you use ancestral or stochastic samplers: the node offsets the seed by the current step number (seed + step) for every isolated call. That prevents what the README calls the "Re-Seeding Trap" - constructive noise accumulation that happens when you re-run the same seed on the same noise. It's why euler_a and dpm++ actually converge here instead of getting noisier.

The inputs that matter

Beyond the standard KSampler surface (seed, steps, cfg, sampler_name, scheduler, denoise) and the shared regional inputs (model, clip, mask_list, positive_list, negative_list, mode), the one unique knob is local_pass_percent. Set it to 0 and the node basically degrades into a normal sampler run through the patched model - a handy diagnostic. Raise it and the weave gets longer, isolation gets stronger, and per-region identity gets sharper, at the cost of time and seams.

Output is a single LATENT, straight from Empty Latent to your VAE Decode.

Install

Same as every MoonNodes node:

cd ComfyUI/custom_nodes
git clone https://github.com/m0rtus59/ComfyUI-MoonNodes.git
cd ComfyUI-MoonNodes && pip install -r requirements.txt

Restart. It's pure Python on top of ComfyUI's own sampler classes - no extra dependencies.

Should you use it?

Here's the honest take. For a normal regional workflow, the two-node approach - Moon Regional Patcher feeding a regular KSampler - is easier to reason about, faster, and easier to debug when output looks wrong. MoonMultiPassSampler is for when per-region isolation is genuinely failing and you want the stronger, weave-style isolation in a single package.

The costs are real: it runs multiple sub-samples per step, so it's noticeably slower than a plain sampler; seams can still appear if local_pass_percent is too high; and because it's labeled an experiment, you should expect to read its console prints ([Weave] ISOLATED Step..., [Weave] GLOBAL Step...) when something misbehaves - they're diagnostic output, not noise. Try it on a low step count first, keep local_pass_percent modest, and treat the result as a candidate, not gospel.

CategoryMoonNodes

Inputs (14)

NameTypeDefaultDescription
modelMODELβ€”
clipCLIPβ€”
mask_listMASKβ€”
positive_listCONDITIONINGβ€”
negative_listCONDITIONINGβ€”
modeCOMBOMerge2 options: Merge, Concat
latent_imageLATENTβ€”
seedINT00–18446744073709550000β€”
stepsINT201–10000β€”
cfgFLOAT8.00–100β€”
sampler_nameCOMBO44 options: euler, euler_cfg_pp, euler_ancestral, euler_ancestral_cfg_pp, heun, heunpp2, +38
schedulerCOMBO9 options: simple, sgm_uniform, karras, exponential, ddim_uniform, beta, +3
denoiseFLOAT1.000–1β€”
local_pass_percentFLOAT0.200–1β€”

Outputs (1)

NameTypeDescription
LATENTLATENTβ€”