A SwarmUI extension with a small toolbox of Krea 2 tricks. Everything is gated on the selected
model being detected as Krea 2 (krea-2 / krea-2/lora) and does nothing otherwise.
Three features, each backed by a third-party ComfyUI node pack and each living in its own nested sub-group under the Krea Gone Wild parameter group. Each sub-group's toggle is the feature's on/off switch — there is no separate enable param. Install buttons appear inside the sub-group of whichever node pack is missing.
Applies ComfyUI-ConditioningKrea2Rebalance to both the positive and negative Krea 2 conditioning (and the refiner pass, if present).
Runs ComfyUI-Krea2-Ostris-Edit edit LoRAs
(ai-toolkit krea2 arch, model_kwargs.edit: true) — "Kontext-style" reference-image editing.
It wires the edit natively into SwarmUI rather than replacing SwarmUI's conditioning:
ReferenceLatent node.Krea2OstrisEditModelPatch so the Krea 2 DiT actually consumes those
reference latents (index_timestep_zero).Because SwarmUI's own SwarmClipTextEncodeAdvanced still builds the conditioning, all the advanced
prompt syntax (<break>, weighting, [from:to:when], regions, …) keeps working on edits. Only the
model patch comes from the ostris pack; the reference latents use core ComfyUI nodes — exactly the
"chain conditioning from … Set Reference Latent nodes" path the pack documents.
Note: the reference latents are attached to the main generation pass only; a separate refiner pass is not edit-patched.
Runs comfyui-krea2edit — instruction-based editing
with the krea2_edit identity LoRA. Different approach from the ostris pack: instead of reference
latents on the conditioning, the source is prepended to the sampling sequence as a block of clean
in-context tokens (RoPE frame=1), with the instruction encoded through Qwen3-VL alongside the image in
the exact layout the LoRA trained on.
Two halves to the recipe. Only the model patch comes from the pack:
SwarmClipTextEncodeAdvanced with the prompt
images wired and its stock "krea2" template, which appends the vision blocks after the
instruction with a Picture N: label. krea2_edit trained with them before the instruction and
unlabelled. That node passes any non-magic llama_template string straight through to
clip.tokenize and leaves the prompt text alone, so this extension just retemplates the existing
positive and negative encoders in place. Result: the pack's grounded encode, with <break>,
[from:to:when], [alter|nate], weighting and per-step scheduling all still working — none of
which the pack's own Krea2EditGroundedEncode node supports.Krea2EditModelPatch wraps the model. It gets the raw prompt image(s) plus
the VAE on the pixel path (immune to input/output resolution mismatches), the VAE-encoded source as
the required source_latent, and the sampler's own latent as target_latent so the source encode
happens before sampling instead of evicting the diffusion model mid-run.Up to two prompt images feed the model patch: the first is the scene (ref_boost_a), the second the
subject (ref_boost) — the training-matched order for the multi-reference LoRAs. Grounding sees every
prompt image SwarmUI batched, one vision block each.
krea2_edit LoRA and at least one
prompt image; with no prompt image it is a no-op.fit (training-matched, default) or crop (legacy) for
older weights."krea2"
template (still grounded, just with the training-mismatched vision-block placement).ImageScaleToMaxDimension node. 0 = leave SwarmUI's own prompt-image sizing alone.
The LoRA trained with 384–768px jitter, so 640–768 is in-distribution.Note: the pack's own guidance — Turbo at 8 steps / CFG 1 for most edits, Raw at CFG 3 / 20 steps for removals, generate at ≤2 MP.
The features are independent toggles. The two editing modes are alternative approaches to the same job — enable one, not both.
A SwarmUI extension with a small toolbox of Krea 2 tricks. Everything is gated on the selected
model being detected as Krea 2 (krea-2 / krea-2/lora) and does nothing otherwise.
Three features, each backed by a third-party ComfyUI node pack and each living in its own nested sub-group under the Krea Gone Wild parameter group. Each sub-group's toggle is the feature's on/off switch — there is no separate enable param. Install buttons appear inside the sub-group of whichever node pack is missing.
Applies ComfyUI-ConditioningKrea2Rebalance to both the positive and negative Krea 2 conditioning (and the refiner pass, if present).
Runs ComfyUI-Krea2-Ostris-Edit edit LoRAs
(ai-toolkit krea2 arch, model_kwargs.edit: true) — "Kontext-style" reference-image editing.
It wires the edit natively into SwarmUI rather than replacing SwarmUI's conditioning:
ReferenceLatent node.Krea2OstrisEditModelPatch so the Krea 2 DiT actually consumes those
reference latents (index_timestep_zero).Because SwarmUI's own SwarmClipTextEncodeAdvanced still builds the conditioning, all the advanced
prompt syntax (<break>, weighting, [from:to:when], regions, …) keeps working on edits. Only the
model patch comes from the ostris pack; the reference latents use core ComfyUI nodes — exactly the
"chain conditioning from … Set Reference Latent nodes" path the pack documents.
Note: the reference latents are attached to the main generation pass only; a separate refiner pass is not edit-patched.
Runs comfyui-krea2edit — instruction-based editing
with the krea2_edit identity LoRA. Different approach from the ostris pack: instead of reference
latents on the conditioning, the source is prepended to the sampling sequence as a block of clean
in-context tokens (RoPE frame=1), with the instruction encoded through Qwen3-VL alongside the image in
the exact layout the LoRA trained on.
Two halves to the recipe. Only the model patch comes from the pack:
SwarmClipTextEncodeAdvanced with the prompt
images wired and its stock "krea2" template, which appends the vision blocks after the
instruction with a Picture N: label. krea2_edit trained with them before the instruction and
unlabelled. That node passes any non-magic llama_template string straight through to
clip.tokenize and leaves the prompt text alone, so this extension just retemplates the existing
positive and negative encoders in place. Result: the pack's grounded encode, with <break>,
[from:to:when], [alter|nate], weighting and per-step scheduling all still working — none of
which the pack's own Krea2EditGroundedEncode node supports.Krea2EditModelPatch wraps the model. It gets the raw prompt image(s) plus
the VAE on the pixel path (immune to input/output resolution mismatches), the VAE-encoded source as
the required source_latent, and the sampler's own latent as target_latent so the source encode
happens before sampling instead of evicting the diffusion model mid-run.Up to two prompt images feed the model patch: the first is the scene (ref_boost_a), the second the
subject (ref_boost) — the training-matched order for the multi-reference LoRAs. Grounding sees every
prompt image SwarmUI batched, one vision block each.
krea2_edit LoRA and at least one
prompt image; with no prompt image it is a no-op.fit (training-matched, default) or crop (legacy) for
older weights."krea2"
template (still grounded, just with the training-mismatched vision-block placement).ImageScaleToMaxDimension node. 0 = leave SwarmUI's own prompt-image sizing alone.
The LoRA trained with 384–768px jitter, so 640–768 is in-distribution.Note: the pack's own guidance — Turbo at 8 steps / CFG 1 for most edits, Raw at CFG 3 / 20 steps for removals, generate at ≤2 MP.
The features are independent toggles. The two editing modes are alternative approaches to the same job — enable one, not both.