Spaces:
Sleeping
Sleeping
implement await
Browse files- ai_service.py +1 -1
ai_service.py
CHANGED
|
@@ -180,7 +180,7 @@ async def get_ai_response(user_query: str, telegram_id: int):
|
|
| 180 |
conversation_history = []
|
| 181 |
if db_manager:
|
| 182 |
print("arriving to get history messages: \n")
|
| 183 |
-
raw_history = db_manager.get_conversation_history(telegram_id, limit=6)
|
| 184 |
raw_history.reverse()
|
| 185 |
for msg in raw_history:
|
| 186 |
if msg.get('message_text'):
|
|
|
|
| 180 |
conversation_history = []
|
| 181 |
if db_manager:
|
| 182 |
print("arriving to get history messages: \n")
|
| 183 |
+
raw_history = await db_manager.get_conversation_history(telegram_id, limit=6)
|
| 184 |
raw_history.reverse()
|
| 185 |
for msg in raw_history:
|
| 186 |
if msg.get('message_text'):
|