imurra commited on
Commit
6c121ca
·
verified ·
1 Parent(s): 3a8e6a8

Syntax error in the file! There's a typo on line 148

Browse files
Files changed (1) hide show
  1. app.py +10 -1
app.py CHANGED
@@ -145,4 +145,13 @@ async def search_medqa(request: SearchRequest):
145
  "distance": results['distances'][0][i] if 'distances' in results else None
146
  })
147
 
148
- return Sea
 
 
 
 
 
 
 
 
 
 
145
  "distance": results['distances'][0][i] if 'distances' in results else None
146
  })
147
 
148
+ return SearchResponse(results=formatted_results)
149
+ except Exception as e:
150
+ raise HTTPException(status_code=500, detail=str(e))
151
+
152
+ @app.get("/health")
153
+ async def health():
154
+ return {"status": "healthy", "items": collection.count()}
155
+
156
+ # Mount Gradio on FastAPI
157
+ app = gr.mount_gradio_app(app, demo, path="/")