fix 4o generation bug (#106)

This commit is contained in:
thot experiment 2025-05-01 18:23:41 -07:00 committed by GitHub
parent 67e9395017
commit f4f2e031e3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -392,6 +392,7 @@ class OpenAIGPTImage1(ComfyNodeABC):
):
model = "gpt-image-1"
path = "/proxy/openai/images/generations"
content_type="application/json"
request_class = OpenAIImageGenerationRequest
img_binaries = []
mask_binary = None
@ -400,6 +401,7 @@ class OpenAIGPTImage1(ComfyNodeABC):
if image is not None:
path = "/proxy/openai/images/edits"
request_class = OpenAIImageEditRequest
content_type="multipart/form-data",
batch_size = image.shape[0]
@ -461,7 +463,7 @@ class OpenAIGPTImage1(ComfyNodeABC):
size=size,
),
files=files if files else None,
content_type="multipart/form-data",
content_type=content_type,
auth_token=auth_token,
)