DeepResearch icon indicating copy to clipboard operation
DeepResearch copied to clipboard

React_agent: Custom tool descriptions not included in prompts, and function_list parameter is unused

Open zhudanhao opened this issue 5 months ago • 2 comments

Problem Description

  1. Tool descriptions are not passed to the prompt: When registering custom tools, their descriptions (defined in the tool class) are not being included in the prompt sent to the LLM. This means the model lacks context about what each tool does and how to use it properly.

  2. The function_list parameter is non-functional: The MultiTurnReactAgent class accepts a function_list parameter but never uses it because:

    • The __init__ method doesn't call super().__init__()
    • The agent relies entirely on a global TOOL_MAP instead of the passed function_list
    • This makes the parameter misleading and breaks expected inheritance behavior

Expected Behavior

  1. Tool descriptions should be dynamically included in the system prompt
  2. The function_list parameter should either work as expected or be removed
  3. The agent should follow proper OOP patterns with parent class initialization

Questions

  1. Are there plans to refactor this code for better maintainability and proper OOP design?
  2. Is this project open to community contributions? We'd be happy to submit PRs to address these issues.

Would love to contribute if the project is accepting PRs!

zhudanhao avatar Sep 21 '25 01:09 zhudanhao

Thanks my friends

Bangkah avatar Sep 21 '25 07:09 Bangkah

+1

siqim avatar Oct 22 '25 18:10 siqim