2 Commits
Author SHA1 Message Date
CthomasdesignandClaude Fable 5 5fcf343a4d refactor(tools): machine-portable test scripts, shared asset helpers
_shared gains default_model()/default_lora() (env overrides
KREA2_TEST_MODEL/KREA2_TEST_LORA, else <repo>/../Models discovery with
clear errors) and fox_source()/ref_uint8() for the reference source image
boilerplate repeated across scripts. test_img2img/test_edit/
test_edit_grounded no longer hardcode machine paths; all tools compile
and resolve on a fresh checkout.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-09 13:59:11 -04:00
CthomasdesignandClaude Opus 4.8 984aabc0d1 feat: Krea2Edit node — in-context image editing on Turbo/MLX (v0.6.0)
New additive node for identity-preserving edits: the clean VAE-encoded
source rides the sequence as a frame≠0 reference token block while a
fresh-noise target is denoised, and only the target is decoded — the
appearance path from lbouaraba/comfyui-krea2edit, mapped onto our engine
(sequence [text | src(frame=1) | target(frame=0)], mirroring the 3-axis
RoPE frame scheme that was already present but unused).

Engine additions are isolated: transformer gains prepare_edit +
denoise_step_edit, sampling gains sample_edit + build_edit_positions,
pipeline gains generate_edit; the txt2img/img2img sample() path is
untouched (verified txt2img stays pixel-identical to the parity ref).

Pairs with the krea2_edit identity LoRA (conradlocke/krea2-identity-edit),
which loads through the existing Krea2LoRA node unchanged (ai-toolkit
reference naming, 28 blocks, 0 unmatched keys). Validated: source fox +
"red scarf" keeps the fox's identity while applying the edit; the LoRA
sharpens edit coherence markedly (see tools/test_edit.py). Second
reference image supported for multi-ref edit LoRAs.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-08 18:52:53 -04:00