-
Stefy Lanza (nextime / spora ) authored
Krea2Pipeline.__call__ takes a prompt and no image, and the family's only other entry points in diffusers 0.42 are the Krea2Turbo modular blocks. So the card with the identity-edit LoRA had its weights ready and no way to be asked "change THIS picture" -- and because _task_of() finds no img2img mapping for the family, an edit request fell through to text-to-image and silently ignored the image it was given. The edit is done IN CONTEXT, not by denoising from the reference: the reference is VAE-encoded once, kept clean, and appended to hidden_states beside the canvas, so identity survives the whole trajectory instead of being worn away as the canvas resolves. That is what the family's edit LoRAs are trained against, and it is why `strength` has no meaning here -- there is no partial noising to control, which also makes _is_instruction_edit classify it correctly straight off its signature. Telling the token groups apart is the whole trick. position_ids is (seq, 3): the canvas keeps (0, h, w) and the reference repeats its grid at plane 1, so the rotary embedding separates "this pixel of the canvas" from "this pixel of the reference" while keeping them aligned. Identical coordinates would make the two indistinguishable. The builder is module-level and pure so it can be checked without the 12B weights, and on a build whose diffusers has no Krea 2 at all -- importing the module never breaks such a build. Built with from_pipe over the loaded components: a Krea 2 transformer is 12B and a second load would mean an eviction on every alternation between generating and editing. The reference is encoded with mode(), not sample(), so the same edit of the same picture does not differ run to run. Co-Authored-By:
Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014T3rZnLhydX9QqUcfBbqLu
96a84b69