rca-umb commited on
Commit
c6258d3
·
verified ·
1 Parent(s): 84afef6

Change prompt

Browse files
Files changed (1) hide show
  1. app.py +14 -1
app.py CHANGED
@@ -86,7 +86,20 @@ def run_and_submit_all( profile: gr.OAuthProfile | None):
86
  print(f"Skipping item with missing task_id or question: {item}")
87
  continue
88
  try:
89
- submitted_answer = agent(question_text)
 
 
 
 
 
 
 
 
 
 
 
 
 
90
  answers_payload.append({"task_id": task_id, "submitted_answer": submitted_answer})
91
  results_log.append({"Task ID": task_id, "Question": question_text, "Submitted Answer": submitted_answer})
92
  except Exception as e:
 
86
  print(f"Skipping item with missing task_id or question: {item}")
87
  continue
88
  try:
89
+ submitted_answer = agent(
90
+ "## INSTRUCTIONS\n"
91
+ "You are a general AI assistant. I will ask you a question. Report your thoughts, and "
92
+ "use the final_answer tool to provide JUST your final answer and nothing else. "
93
+ "YOUR FINAL ANSWER should be a number OR as few words as possible OR a comma separated "
94
+ "list of numbers and/or strings. "
95
+ "If you are asked for a number, don’t use comma to write your number neither use units such as $ or "
96
+ "percent sign unless specified otherwise. "
97
+ "If you are asked for a string, don’t use articles, neither abbreviations (e.g. for cities), and write the "
98
+ "digits in plain text unless specified otherwise. "
99
+ "If you are asked for a comma separated list, apply the above rules depending of whether the element "
100
+ "to be put in the list is a number or a string.\n"
101
+ f"## QUESTION\n{question_text}"
102
+ )
103
  answers_payload.append({"task_id": task_id, "submitted_answer": submitted_answer})
104
  results_log.append({"Task ID": task_id, "Question": question_text, "Submitted Answer": submitted_answer})
105
  except Exception as e: