MCP Catalogs
Homelangchain-mcp-tools-py screenshot

langchain-mcp-tools-py

by hideya·28·Score 44

Python utility converting MCP server tools into LangChain-compatible tools with support for local and remote servers.

ai-llmdeveloper-toolsproductivity
10
Forks
2
Open issues
2 mo ago
Last commit
2d ago
Indexed

Overview

A lightweight Python library that simplifies integrating MCP server tools into LangChain applications. It provides a utility function to initialize multiple MCP servers in parallel and convert their tools into LangChain-compatible tools. The library supports various MCP server configurations including local command-based servers and remote HTTP/SSE/WebSocket servers. However, it only supports text results from tool calls and doesn't implement other MCP features like Resources or Prompts.

Try asking AI

After installing, here are 5 things you can ask your AI assistant:

you:Integrating MCP tools into LangChain agents
you:Working with local MCP servers using Python
you:Connecting to remote MCP servers via HTTP/WebSocket
you:Does this support all MCP features?
you:Can I use this with non-text tool results?

When to choose this

Choose this when you need a simple way to integrate MCP servers with LangChain and only require basic tool functionality.

When NOT to choose this

Don't choose this if you need full MCP protocol support with Resources, Prompts, or multi-content type results (images, etc.).

Tools this server exposes

1 tool extracted from the README
  • convert_mcp_to_langchain_toolsconvert_mcp_to_langchain_tools(mcp_servers)

    Converts MCP server configurations to LangChain tools by initializing servers and wrapping their tools.

Note: The README focuses on a utility function that converts MCP servers to LangChain tools, but doesn't explicitly list the specific MCP tools that would be exposed. The actual tools would depend on the MCP servers configured.

Comparable tools

langchain-mcp-adaptersmcp-chat

Installation

pip install langchain-mcp-tools

Claude Desktop Configuration

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-filesystem", "."]
    },
    "fetch": {
      "command": "uvx",
      "args": ["mcp-server-fetch"]
    }
  }
}

FAQ

Does this support all MCP features?
No, this library only supports MCP Tools. Resources, Prompts, and other MCP features are not implemented.
Can I use this with non-text tool results?
Currently, only text results from tool calls are supported. The library filters and uses only text content.

Compare langchain-mcp-tools-py with

GitHub →

Last updated · Auto-generated from public README + GitHub signals.