Skip to content

Commit

Permalink
update response
Browse files Browse the repository at this point in the history
  • Loading branch information
almazgimaev committed Oct 24, 2024
1 parent b1c3b49 commit d5f4668
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ async def evaluate(request: Request):
req = await request.json()
try:
state = req["state"]
run_evaluation(state["session_id"], state["project_id"])
return {"data": run_evaluation(state["session_id"], state["project_id"])}
except Exception as e:
sly.logger.error(f"Error during model evaluation: {e}")
return {"error": str(e)}
Expand All @@ -52,7 +52,7 @@ async def compare(request: Request):
req = await request.json()
try:
state = req["state"]
return run_compare(state["eval_dirs"])
return {"data": run_compare(state["eval_dirs"])}
except Exception as e:
sly.logger.error(f"Error during model comparison: {e}")
return {"error": str(e)}

0 comments on commit d5f4668

Please sign in to comment.