Spaces:
Sleeping
Sleeping
Update gaia_benchmark/run.py
Browse files- gaia_benchmark/run.py +10 -1
gaia_benchmark/run.py
CHANGED
|
@@ -1 +1,10 @@
|
|
| 1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from gaia_benchmark.questions import get_all_questions
|
| 2 |
+
from gaia_benchmark.gaia_interface import submit_to_leaderboard
|
| 3 |
+
|
| 4 |
+
def run_and_submit_all(agent):
|
| 5 |
+
questions = get_all_questions()
|
| 6 |
+
answers = []
|
| 7 |
+
for q in questions:
|
| 8 |
+
answer = agent(q["question"])
|
| 9 |
+
answers.append({"question_id": q["id"], "answer": answer})
|
| 10 |
+
return submit_to_leaderboard(answers)
|