MCPTools instance per server and pass every instance to the agent.
Prerequisites
1
Set up your virtual environment
Connect multiple servers
multiple_mcp_servers.py
Avoiding tool name collisions
When using multiple MCP servers, you may encounter tool name collisions. This often happens when the same tool is available in multiple of the servers you are using. To avoid this, you can use thetool_name_prefix parameter. This will add the given prefix to all tool names coming from the MCPTools instance.