Skip to content
LangChain

Hugging Face for LangChain

com.huggingface/mcp

Hugging Face's hosted MCP server. Search models, datasets, papers and Spaces on the Hub, and run selected Spaces as tools.

client:LangChain transport:streamable-http tools:4

Install Hugging Face in LangChain

pip install langchain-mcp-adapters

from langchain_mcp_adapters.client import MultiServerMCPClient

client = MultiServerMCPClient({
        "mcp": {
            "transport": "streamable_http",
            "url": "https://huggingface.co/mcp",
        }
})

tools = await client.get_tools()

get_tools() returns the server's tools as LangChain tools, ready for an agent. LangChain docs

What LangChain can do once it is connected

Hugging Face in other clients