Update app.py
Browse files
app.py
CHANGED
|
@@ -80,11 +80,7 @@ def chat_with_ai(message, history, role):
|
|
| 80 |
return history
|
| 81 |
|
| 82 |
except Exception as e:
|
| 83 |
-
|
| 84 |
-
error_msg = f"Error: {e.response.text}"
|
| 85 |
-
else:
|
| 86 |
-
error_msg = f"Error: {str(e)}"
|
| 87 |
-
history.append((message, error_msg))
|
| 88 |
return history
|
| 89 |
|
| 90 |
def create_chatbot():
|
|
|
|
| 80 |
return history
|
| 81 |
|
| 82 |
except Exception as e:
|
| 83 |
+
history.append((message, f"Error: {str(e)}"))
|
|
|
|
|
|
|
|
|
|
|
|
|
| 84 |
return history
|
| 85 |
|
| 86 |
def create_chatbot():
|