Kackle commited on
Commit
ff90411
·
verified ·
1 Parent(s): d976005

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +28 -26
app.py CHANGED
@@ -417,38 +417,40 @@ class SlpMultiAgent:
417
  lambda: manager_agent.run(f"""
418
  Question: {short_question}
419
 
420
- CRITICAL INSTRUCTIONS:
421
- 1. Use tools DIRECTLY, not in code execution
422
- 2. For factual questions: Use google_search() tool immediately
423
- 3. For math: Use math_calculator() tool directly
424
- 4. DO NOT write complex code - use tools instead
425
- 5. DO NOT call ResearchAgent() or SolverAgent() in code
426
-
 
427
  Available tools:
428
  - google_search(query): Search the web
429
  - math_calculator(expression): Calculate math
430
  - file_processor(action, data): Handle files
431
  - knowledge_base(topic): Get knowledge
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
432
 
433
- SIMPLE APPROACH:
434
- - Call the appropriate tool
435
- - Get the result
436
- - Provide final_answer()
437
-
438
- Example for factual question:
439
- 1. Call google_search("your query")
440
- 2. Extract answer from results
441
- 3. Call final_answer("the answer")
442
-
443
- NO complex code execution. Use tools directly.
444
-
445
- Take your time and think every step out, be confident and precise.
446
-
447
- Google should be able to answer all these questions and you have access to it.
448
-
449
- They are simple yet tricky questions, so be careful and double check your answers. Make sure to use google_search for any factual question.
450
-
451
- always provide a final_answer in the format final_answer("your answer here") when you have the answer.
452
  """)
453
  )
454
  break # Success, exit retry loop
 
417
  lambda: manager_agent.run(f"""
418
  Question: {short_question}
419
 
420
+ INSTRUCTIONS:
421
+ - For every question, you MUST call the most appropriate tool to get the answer.
422
+ - You MUST NOT output any code blocks, markdown, or print statements.
423
+ - You MUST NOT use triple backticks or <code> tags.
424
+ - Only call the tool and then call final_answer('...').
425
+ - If you cannot answer, call final_answer('I don't know').
426
+ - STRICTLY FOLLOW THIS FORMAT. DO NOT OUTPUT ANYTHING ELSE.
427
+
428
  Available tools:
429
  - google_search(query): Search the web
430
  - math_calculator(expression): Calculate math
431
  - file_processor(action, data): Handle files
432
  - knowledge_base(topic): Get knowledge
433
+ - wikipedia_search(query): Search Wikipedia
434
+ - code_executor(code): Execute Python code
435
+ - web_scraper(url): Scrape web pages
436
+
437
+ EXAMPLES:
438
+ Q: What is the capital of France?
439
+ A: final_answer('Paris')
440
+ Q: 2 + 2 = ?
441
+ A: final_answer('4')
442
+ Q: Who won the 2020 Olympics 100m?
443
+ A: final_answer('Lamont Marcell Jacobs')
444
+ Q: What is the square root of 81?
445
+ A: final_answer('9')
446
+ Q: What is the population of Japan?
447
+ A: final_answer('125.7 million')
448
+ Q: What is the output of print(2**3)?
449
+ A: final_answer('8')
450
+ Q: What is the main ingredient in guacamole?
451
+ A: final_answer('avocado')
452
 
453
+ STRICTLY FOLLOW THIS FORMAT. DO NOT OUTPUT ANYTHING ELSE.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
454
  """)
455
  )
456
  break # Success, exit retry loop