FD900 commited on
Commit
f0f3fcb
·
verified ·
1 Parent(s): 2cbde76

Update agent.py

Browse files
Files changed (1) hide show
  1. agent.py +3 -3
agent.py CHANGED
@@ -15,11 +15,11 @@ def load_tasks():
15
  with open("metadata.jsonl", "r", encoding="utf-8") as f:
16
  for line in f:
17
  item = json.loads(line)
18
- question_id = item.get("task_id") or item.get("question_id")
19
  question = item.get("Question") or item.get("question")
20
  if question_id and question:
21
  tasks.append({
22
- "question_id": question_id,
23
  "question": question
24
  })
25
  return tasks
@@ -34,7 +34,7 @@ def solve_task(task, tools=TOOLS):
34
  response = mistral.run(prompt)
35
 
36
  return {
37
- "question_id": task["question_id"],
38
  "question": task["question"],
39
  "submitted_answer": response.strip() if response else "ERROR: Empty model response"
40
  }
 
15
  with open("metadata.jsonl", "r", encoding="utf-8") as f:
16
  for line in f:
17
  item = json.loads(line)
18
+ task_id = item.get("task_id")
19
  question = item.get("Question") or item.get("question")
20
  if question_id and question:
21
  tasks.append({
22
+ "task_id": task_id,
23
  "question": question
24
  })
25
  return tasks
 
34
  response = mistral.run(prompt)
35
 
36
  return {
37
+ "task_id": task["task_id"],
38
  "question": task["question"],
39
  "submitted_answer": response.strip() if response else "ERROR: Empty model response"
40
  }