Spaces:
Sleeping
Sleeping
Update api_server.py
Browse files- api_server.py +3 -3
api_server.py
CHANGED
|
@@ -152,9 +152,9 @@ def predict_completion(request: PredictionRequest, db: Session = Depends(get_db)
|
|
| 152 |
except:
|
| 153 |
raise HTTPException(status_code=400, detail="patient_id 必須是整數")
|
| 154 |
|
| 155 |
-
# ⭐
|
| 156 |
-
result =
|
| 157 |
-
|
| 158 |
patient_id=patient_id,
|
| 159 |
db=db
|
| 160 |
)
|
|
|
|
| 152 |
except:
|
| 153 |
raise HTTPException(status_code=400, detail="patient_id 必須是整數")
|
| 154 |
|
| 155 |
+
# ⭐ 只呼叫 agent,並把 db、patient_id 傳進去
|
| 156 |
+
result = run_agent(
|
| 157 |
+
prompt=request.prompt,
|
| 158 |
patient_id=patient_id,
|
| 159 |
db=db
|
| 160 |
)
|