Spaces:
Sleeping
Sleeping
Update utils.py
Browse files
utils.py
CHANGED
|
@@ -131,8 +131,11 @@ def extract_question_list(llm, query):
|
|
| 131 |
|
| 132 |
output = llm.invoke(message_log)
|
| 133 |
pred = output.content
|
| 134 |
-
|
| 135 |
-
|
|
|
|
|
|
|
|
|
|
| 136 |
|
| 137 |
|
| 138 |
warnings.filterwarnings('ignore', message="pandas only supports SQLAlchemy connectable.*", category=UserWarning, module='chain')
|
|
|
|
| 131 |
|
| 132 |
output = llm.invoke(message_log)
|
| 133 |
pred = output.content
|
| 134 |
+
|
| 135 |
+
try:
|
| 136 |
+
return literal_eval(pred)
|
| 137 |
+
except:
|
| 138 |
+
return query
|
| 139 |
|
| 140 |
|
| 141 |
warnings.filterwarnings('ignore', message="pandas only supports SQLAlchemy connectable.*", category=UserWarning, module='chain')
|