-
Notifications
You must be signed in to change notification settings - Fork 161
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow change McpClientTool's name property in host with mcp clients #154
Comments
Can you elaborate on the scenario? You're walking up to an MCP server, calling its ListTools to get back a list of the tools it supports, it gives you back a tool named "Something", and then you want to change that name to "PrefixSomething" when you call back to that MCP server? And the server will happily accept "PrefixSomething" even though it told you the name of the tool was "Something"? |
In my scenario, the application integrates multiple MCP servers (e.g., Playwright MCP server, Github MCP server). I retrieve all tools from each MCP server using the Maybe I don't have to worry about tool name conflicts? |
Thanks. So it's not that you want to change the name of the tool as it's known to the MCP server, but you want to advertize its name differently to the LLM, and then when the LLM asks for the tool by the modified name, you refer to it by its original name when calling to the MCP server, yes? |
Yes, this is what i mean. I would split the modified tool name to get server name and actual tool name, then use server name to get the corresponding mcp client, make a request with actual tool name |
It's a very relevant problem, but I think a forced pattern of "server.tool" isn't flexible enough for all cases. LLM tool accuracy is often highly dependent on naming, and I've had cases where I renamed MCP tools (in raw handlers) to get better accuracy. I don't think many (if any) server authors use evaluations to optimize the accuracy impact of their tool names. |
Addressed by #165 |
In my application, I need intergrate multiple mcp servers for one LLM, So i need add server name prefix to tool name in order to let application know which server the tool comes from.
But the name property in
McpClientTool
cannot be changed, And it also can't reconstructMcpClientTool
with new name.The text was updated successfully, but these errors were encountered: