Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -74,7 +74,7 @@ def chat_bot(history):
|
|
| 74 |
time.sleep(0.02)
|
| 75 |
yield history
|
| 76 |
elif isinstance(block, dict) and block.get("image_url"):
|
| 77 |
-
url =
|
| 78 |
image = base64_to_image(url, f"{uuid.uuid4()}.png")
|
| 79 |
history.append({"role": "assistant", "content": {"path": image}})
|
| 80 |
yield history
|
|
|
|
| 74 |
time.sleep(0.02)
|
| 75 |
yield history
|
| 76 |
elif isinstance(block, dict) and block.get("image_url"):
|
| 77 |
+
url = block["image_url"].get("url").split(",")[-1]
|
| 78 |
image = base64_to_image(url, f"{uuid.uuid4()}.png")
|
| 79 |
history.append({"role": "assistant", "content": {"path": image}})
|
| 80 |
yield history
|