fix: use underscore naming for Tavily tool functions in DeepResearch agent#1400
Open
octo-patch wants to merge 2 commits intoagentscope-ai:mainfrom
Open
fix: use underscore naming for Tavily tool functions in DeepResearch agent#1400octo-patch wants to merge 2 commits intoagentscope-ai:mainfrom
octo-patch wants to merge 2 commits intoagentscope-ai:mainfrom
Conversation
fixes agentscope-ai#1392) The mcp python-sdk renamed `streamablehttp_client` to `streamable_http_client` in the streamable_http transport module. Update both the stateful and stateless HTTP MCP clients to use the new function name.
…agent (fixes agentscope-ai#1391) MCP registers tools with underscore names (tavily_search, tavily_extract) but the DeepResearch agent used hyphenated names (tavily-search, tavily-extract). This mismatch caused the follow-up extraction to never trigger and led to repeated redundant searches.
|
|
Member
qbc2016
reviewed
Apr 3, 2026
Member
qbc2016
left a comment
There was a problem hiding this comment.
Thank you for your contribution! I noticed this PR contains changes for two different features. To make the review and merge process smoother, could you please split them into separate PRs? This helps us track and review each feature independently.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1391
Problem
The DeepResearch agent used hyphenated tool names (
tavily-search,tavily-extract) but the MCP server registers tools with underscore names (tavily_search,tavily_extract). This mismatch caused:tavily_searchfor already-covered informationSolution
Update
self.search_functionandself.extract_functionto use underscore naming (tavily_search,tavily_extract) to match the names registered by the MCP server.Testing
Run
examples/agent/deep_research_agent/main.pywith a query that requires search + extract. The agent should now correctly recognize tool names, trigger follow-up extraction when needed, and avoid redundant repeated searches.