From 9bede2cbc5ea961f952eaca3574706b6f35e5f31 Mon Sep 17 00:00:00 2001 From: Ethanfel Date: Thu, 25 Jun 2026 05:07:35 +0200 Subject: [PATCH] Release 1.0.2 Editable system_prompt input + Krea2 System Prompt helper node, plus mask self-heal/padding, downscale-only vision cap, and logo/banner. Also moves the system_prompt socket directly above image1. Co-Authored-By: Claude Opus 4.8 --- nodes.py | 17 +++++++++-------- pyproject.toml | 2 +- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/nodes.py b/nodes.py index 5dc4c0d..9ede002 100644 --- a/nodes.py +++ b/nodes.py @@ -64,6 +64,15 @@ class TextEncodeKrea2: "prompt": ("STRING", {"multiline": True, "dynamicPrompts": True}), }, "optional": { + # system_prompt sits just above the image slots. + "system_prompt": ("STRING", { + "forceInput": True, + "tooltip": "Optional system-instruction input. Wire a text node to override how the " + "VLM frames the reference + your prompt; leave unconnected to use Krea2's " + "trained descriptor (in-distribution). Use an instruct/edit-style " + "instruction (see README) to fuse the prompt with the image. The node " + "adds the chat-template scaffolding; provide just the instruction text.", + }), # image1/mask1 are the seed pair; the web extension grows image2/mask2, ... on connect. "image1": ("IMAGE",), "mask1": ("MASK",), @@ -79,14 +88,6 @@ class TextEncodeKrea2: "image size added on EACH side. 0 = tight crop to the mask; 0.1 = ~10% " "margin of surroundings. Only applies when a mask is connected.", }), - "system_prompt": ("STRING", { - "forceInput": True, - "tooltip": "Optional system-instruction input. Wire a text node to override how the " - "VLM frames the reference + your prompt; leave unconnected to use Krea2's " - "trained descriptor (in-distribution). Use an instruct/edit-style " - "instruction (see README) to fuse the prompt with the image. The node " - "adds the chat-template scaffolding; provide just the instruction text.", - }), }, } diff --git a/pyproject.toml b/pyproject.toml index 73d8e47..bd9d013 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "comfyui-krea2-text-encoder" description = "Vision-aware text conditioning for the Krea2 / K2 model. Feeds reference images through the Qwen3-VL-4B vision path with the Krea2 descriptor template; optional per-image mask crops to the masked region. No VAE (Krea2 has no reference-latent pathway). Auto-growing image+mask slots." -version = "1.0.1" +version = "1.0.2" license = "MIT" requires-python = ">=3.10" dependencies = []