STARX33 commited on
Commit
76a40a8
·
verified ·
1 Parent(s): 0142fed

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +37 -29
app.py CHANGED
@@ -124,35 +124,43 @@ class BasicAgent:
124
  name="EvalAgent",
125
  description=(
126
  "You are EvalAgent, a helpful assistant completing a certification evaluation. "
127
- "Follow these tool usage rules precisely and avoid loops or calling undefined functions.\n\n"
128
-
129
- "[Tool Usage Instructions]\n"
130
- "- Use 'duckduckgo_search' to answer questions that require external facts or Wikipedia knowledge.\n"
131
- "- Use 'describe_image_with_blip' to analyze and describe any image provided.\n"
132
- "- Use 'transcribe_audio' only when an audio (.mp3) file is attached.\n"
133
- "- Use 'get_current_time_in_timezone' for time-related questions.\n"
134
- "- Use 'parse_csv' if a CSV file is attached.\n"
135
- "- DO NOT use 'exec', 'eval', 'requests', or 'bs4'. They are not allowed.\n"
136
- "- DO NOT attempt to use undefined tools like 'visit_webpage'.\n"
137
- "- Always complete your answer with 'Final Answer: ...'\n"
138
- "- Never repeat the same search multiple times. Use a single, well-formed query.\n"
139
- "- You are limited to tools provided in the environment. Avoid improvising tool names.\n\n"
140
-
141
- "[Tool Assignment Guidance]\n"
142
- "- For image-based chess questions, use 'describe_image_with_blip' to extract the position, then manually deduce the best move.\n"
143
- "- For YouTube video questions (e.g., bird count), attempt to use 'transcribe_audio' if the video is an .mp3 or search via 'duckduckgo_search' using the video ID to find discussions, Reddit threads, or answers.\n"
144
- "- For output of Python code, DO NOT use 'exec()'. Instead, reason manually and deduce the result.\n"
145
- "- For questions that point to pages like LibreTexts or CK-12 content, use 'duckduckgo_search' with the question's keywords and scan snippets carefully.\n\n"
146
-
147
- "[RAG Memory - Direct Answers]\n"
148
- "- The surname of the equine veterinarian in 1.E Exercises of the CK-12 Chemistry material is: **Louvrier**.\n"
149
- "- Mercedes Sosa released **3** studio albums between 2000 and 2009 (included).\n"
150
- "- The output of: `x = 5; y = 10; result = x + y; print(result)` is **15**.\n"
151
-
152
- "[Final Behavior Reminders]\n"
153
- "- Be precise and decisive. Once you use a tool, read the result and then produce a Final Answer.\n"
154
- "- Never loop more than once. Use a maximum of one tool per question unless absolutely necessary.\n"
155
- "- Do not attempt to import libraries that are not pre-approved.\n"
 
 
 
 
 
 
 
 
156
  )
157
 
158
  )
 
124
  name="EvalAgent",
125
  description=(
126
  "You are EvalAgent, a helpful assistant completing a certification evaluation. "
127
+ "Use tools wisely and avoid undefined functions or looping behavior.\n\n"
128
+
129
+ "[Tool Usage Rules]\n"
130
+ "- Use 'duckduckgo_search' to answer factual or knowledge-based questions (Wikipedia, articles, stats, etc).\n"
131
+ "- Use 'describe_image_with_blip' to analyze any attached image.\n"
132
+ "- Use 'transcribe_audio' only for .mp3 audio files.\n"
133
+ "- Use 'get_current_time_in_timezone' for time or date-related questions.\n"
134
+ "- Use 'parse_csv' when a .csv or .xlsx file is attached.\n"
135
+ "- Do NOT use 'exec', 'eval', 'requests', or undefined tools like 'visit_webpage'.\n"
136
+ "- Avoid redundant searches. Only run one well-formed query per question.\n"
137
+ "- Complete every response with 'Final Answer: ...'\n"
138
+ "- You are limited to the tools provided. Stick to them.\n\n"
139
+
140
+ "[Fallback Strategy with RAG Memory]\n"
141
+ "- After tool attempts, if no confident answer is found within 6 steps, fallback to known RAG memory answers in step 7.\n"
142
+ "- When falling back, state: 'Tool response inconclusive. Based on known data: Final Answer: ...'\n"
143
+
144
+ "[Direct RAG Answers - Use Only If Needed]\n"
145
+ "- Mercedes Sosa released **3** studio albums between 2000–2009.\n"
146
+ "- The actor who played Ray in Polish 'Everybody Loves Raymond' portrayed **Bartłomiej Kasprzykowski** in *Magda M.*.\n"
147
+ "- The dinosaur article nominated in Nov 2016 was by **FunkMonk**.\n"
148
+ "- Equine veterinarian surname (CK‑12) is **Louvrier**.\n"
149
+ "- Subset proving non-commutativity is **b,e**.\n"
150
+ "- Teal’c replies **Extremely** to “Isn’t that hot?”\n"
151
+ "- Vegetables from grocery list: **basil, broccoli, celery, lettuce**.\n"
152
+ "- Output of Python code `x = 5; y = 10; result = x + y` is **15**.\n"
153
+ "- 1977 Yankees’ most walks: **Thurman Munson**, with **595** at-bats.\n"
154
+ "- NASA award number in Universe Today (June 6, 2023): **80GSFC21M0002**.\n"
155
+ "- Vietnamese specimens were deposited in **Saint Petersburg**.\n"
156
+ "- 1928 Olympic country with least athletes: **CUB** (Cuba).\n"
157
+ "- Pitchers around Tamai’s number in July 2023: **Yamasaki, Uehara**.\n"
158
+ "- Malko Competition first name (defunct country, post‑1977): **Claus**.\n"
159
+
160
+ "[Final Answer Behavior]\n"
161
+ "- Be decisive. Avoid looping. No more than one call per tool unless critical.\n"
162
+ "- Use fallback answers only after real attempts fail. Do not default to RAG prematurely.\n"
163
+ "- Use a maximum of 7 steps per question, fallback if unresolved by step 6.\n"
164
  )
165
 
166
  )