This commit is contained in:
Timothy Jaeryang Baek 2026-01-06 02:00:30 +04:00
parent 619f260466
commit 2543252bb0

View file

@ -245,6 +245,15 @@ async def generate_image(
},
}
)
# Return a message indicating the image is already displayed
return json.dumps(
{
"status": "success",
"message": "The image has been successfully generated and is already visible to the user in the chat. You do not need to display or embed the image again - just acknowledge that it has been created.",
"images": images,
},
ensure_ascii=False,
)
return json.dumps({"status": "success", "images": images}, ensure_ascii=False)
except Exception as e:
@ -290,6 +299,15 @@ async def edit_image(
},
}
)
# Return a message indicating the image is already displayed
return json.dumps(
{
"status": "success",
"message": "The edited image has been successfully generated and is already visible to the user in the chat. You do not need to display or embed the image again - just acknowledge that it has been created.",
"images": images,
},
ensure_ascii=False,
)
return json.dumps({"status": "success", "images": images}, ensure_ascii=False)
except Exception as e: