Fix PaintPlus OpenAI edit quality: edits silently fell back to dall-e-2

inpaint()/img2img()/outpaint() called /v1/images/edits without a model
field, so OpenAI defaulted every cloud edit to dall-e-2 regardless of
configuration — while txt2img used dall-e-3. Add a separate
OPENAI_EDIT_MODEL (default gpt-image-1, the only current model that
supports masked edits at ChatGPT-comparable quality), thread it through
the provider and both compose files, and handle gpt-image-1's
b64_json-only response shape alongside the url shape dall-e-2/3 return.
This commit is contained in:
Claude
2026-06-26 13:57:04 +00:00
parent efc4100640
commit 36a126bee7
5 changed files with 28 additions and 13 deletions
+5
View File
@@ -82,6 +82,11 @@ REPLICATE_API_KEY=r8_PASTE_YOUR_KEY_HERE
# ───────────────────────────────────────────────────────────────────────────
#OPENAI_API_KEY=sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
#OPENAI_MODEL=dall-e-3
# Model for inpaint/img2img/outpaint (the /v1/images/edits endpoint).
# dall-e-3 does NOT support edits at all — keep this on gpt-image-1 for
# ChatGPT-comparable edit quality, or set dall-e-2 for the older/cheaper option.
# Note: gpt-image-1 may require completing org verification at platform.openai.com.
#OPENAI_EDIT_MODEL=gpt-image-1
# ───────────────────────────────────────────────────────────────────────────
# INVOKEAI (self-hosted, best for Flux/SDXL)