Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
|
@@ -215,7 +215,7 @@ async def chat(
|
|
| 215 |
"""Perform a text search."""
|
| 216 |
try:
|
| 217 |
with WEBS(proxy=proxy) as webs:
|
| 218 |
-
results = webs.chat(
|
| 219 |
return JSONResponse(content=jsonable_encoder(results))
|
| 220 |
except Exception as e:
|
| 221 |
raise HTTPException(status_code=500, detail=f"Error getting chat results: {e}")
|
|
|
|
| 215 |
"""Perform a text search."""
|
| 216 |
try:
|
| 217 |
with WEBS(proxy=proxy) as webs:
|
| 218 |
+
results = webs.chat(chat_messages=[{"role": "user", "content": q}], model=model)
|
| 219 |
return JSONResponse(content=jsonable_encoder(results))
|
| 220 |
except Exception as e:
|
| 221 |
raise HTTPException(status_code=500, detail=f"Error getting chat results: {e}")
|