Spaces:
Runtime error
Runtime error
Update main.py
Browse files
main.py
CHANGED
|
@@ -95,6 +95,7 @@ def analyze_with_gemini(image_path, user_text):
|
|
| 95 |
raise FileNotFoundError(f"圖片路徑無效:{image_path}")
|
| 96 |
|
| 97 |
organ = PIL.Image.open(image_path)
|
|
|
|
| 98 |
response = chat.send_message([user_text, organ])
|
| 99 |
|
| 100 |
# 提取回應內容
|
|
|
|
| 95 |
raise FileNotFoundError(f"圖片路徑無效:{image_path}")
|
| 96 |
|
| 97 |
organ = PIL.Image.open(image_path)
|
| 98 |
+
chat = model.start_chat(history=history)
|
| 99 |
response = chat.send_message([user_text, organ])
|
| 100 |
|
| 101 |
# 提取回應內容
|