McpHub for LangChain
io.github.john0king/mcphub
MCP bridge that folds multiple MCP servers' capabilities into a few fixed tools for AI tools.
client:LangChain
transport:stdio
runtime:nuget
Install McpHub in LangChain
pip install langchain-mcp-adapters
from langchain_mcp_adapters.client import MultiServerMCPClient
client = MultiServerMCPClient({
"mcphub": {
"transport": "stdio",
"command": "dnx",
"args": ["McpHub", "--yes"],
}
})
tools = await client.get_tools()
get_tools() returns the server's tools as LangChain tools, ready for an agent. LangChain docs