From 48f65296d5c96d95b11f1550b0a9db98160a00cd Mon Sep 17 00:00:00 2001 From: TiyaAnlite Date: Tue, 21 Oct 2025 20:04:48 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Ddoubao=E7=9A=84guidance=5Fsca?= =?UTF-8?q?le=E5=8F=82=E6=95=B0=E9=BB=98=E8=AE=A4=E5=80=BC=E6=A3=80?= =?UTF-8?q?=E9=AA=8C=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- base.py | 2 +- nodes.py | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/base.py b/base.py index ab25c14..c27603a 100644 --- a/base.py +++ b/base.py @@ -86,7 +86,7 @@ class BaseImageNode: # Parse response result = response.json() - if "data" not in result: + if "data" not in result or result["data"] is None: raise ValueError(f"Unexpected API response: {result}") # Process images diff --git a/nodes.py b/nodes.py index 87b96b3..d53c068 100644 --- a/nodes.py +++ b/nodes.py @@ -59,7 +59,7 @@ class SeedreamImage(VolcengineNode): }, "optional": { "reference_image": ("IMAGE", {"enabled": ["doubao-seedream-4-0-250828", "doubao-seededit-3-0-i2i-250628"]}), - "guidance_scale": ("FLOAT", {"min": 1, "max": 10, "enabled": ["doubao-seedream-3-0-t2i-250415", "doubao-seededit-3-0-i2i-250628"]}) + "guidance_scale": ("FLOAT", {"default":0, "min": 0, "max": 10, "enabled": ["doubao-seedream-3-0-t2i-250415", "doubao-seededit-3-0-i2i-250628"]}) } } @@ -68,4 +68,8 @@ class SeedreamImage(VolcengineNode): payload["size"] = "adaptive" if reference_image is None: raise ValueError("doubao-seededit-3-0-i2i-250628需要参数:reference_image") + print("kwargs:", kwargs) + if "guidance_scale" in kwargs and kwargs["guidance_scale"] < 1.0: + del kwargs["guidance_scale"] + print("kwargs(updated):", kwargs) return payload, timeout, extra_params, reference_image, kwargs \ No newline at end of file