luciferai-devil commited on
Commit
94140d6
·
verified ·
1 Parent(s): 49893ba

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. server/app.py +6 -2
server/app.py CHANGED
@@ -124,10 +124,14 @@ def run_baseline() -> dict:
124
  Run the baseline agent on all tasks and return scores.
125
  This endpoint triggers the baseline inference script.
126
  """
127
- import subprocess, sys, json, re
128
  try:
 
 
 
 
129
  result = subprocess.run(
130
- [sys.executable, "baseline/run_baseline.py", "--output", "json"],
131
  capture_output=True, text=True, timeout=120,
132
  )
133
 
 
124
  Run the baseline agent on all tasks and return scores.
125
  This endpoint triggers the baseline inference script.
126
  """
127
+ import subprocess, sys, json, re, os
128
  try:
129
+ # Get absolute path to the baseline script
130
+ base_dir = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
131
+ baseline_script = os.path.join(base_dir, "baseline", "run_baseline.py")
132
+
133
  result = subprocess.run(
134
+ [sys.executable, baseline_script, "--output", "json"],
135
  capture_output=True, text=True, timeout=120,
136
  )
137