mcp-agent-tool-adapter
Transforms MCP tools into collaborative, reasoning agents using modern agent frameworks.
claude mcp add --transport stdio serkanyasr-mcp-agent-tool-adapter npx @modular-protocol/filesystem
How to use
The mcp-agent-tool-adapter exposes MCP-enabled tooling that lets agents dynamically invoke modular tools. This server acts as a bridge between MCP clients and tool servers (for example, filesystem tooling) by spawning tool processes and exposing them through the MCP protocol. It supports two agent backends: Google ADK-based agents with streaming interfaces and LangGraph-based agents using ReAct-style planning with streaming tool calls. You can switch between agent types by configuring the tool_type in your client adapter. To start using it locally, ensure your Python environment is set up and point your MCP client at this server via the MCP configuration (mcp_config.json). The sample configuration demonstrates how to reference a tool package (e.g., @modular-protocol/filesystem) via npx, which the agent tool adapter will spawn and manage for you.
How to install
Prerequisites:
- Python 3.10+ installed on your system
- Git to clone the repository
Step-by-step installation:
-
Clone the repository: git clone https://github.com/serkanyasr/mcp-agent-tool-adapter cd mcp-agent-tool-adapter
-
Create a Python virtual environment (optional but recommended): python -m venv venv source venv/bin/activate # Linux/macOS venv\Scripts\activate # Windows
-
Install dependencies: pip install -r requirements.txt
-
Run the example client/server locally:
- The repository provides Python scripts for Google ADK and LangGraph clients: python app_client_adk.py python app_client_langgraph.py
-
Prepare your mcp_config.json with the appropriate mcpServers entries (see examples in the README): { "mcpServers": { "filesystem": { "command": "npx", "args": ["@modular-protocol/filesystem"] } } }
-
(Optional) Install additional tooling or agents as needed and ensure the tool packages referenced in mcp_config.json are available in your environment.
Additional notes
Tips and notes:
- The server uses subprocess-based tool spawning, so ensure the referenced tool packages (e.g., @modular-protocol/filesystem) are available in your environment and can be invoked via the declared command.
- You can switch between Google ADK and LangGraph agents by adjusting the tool_type in your client configuration; both approaches are supported by the MCPClient within this adapter.
- If you encounter permission or PATH issues, ensure that node (for npx) is installed and available in your system PATH for the npx invocation to succeed.
- The example mcp_config.json demonstrates how to wire a filesystem tool; you can add more tools by duplicating the server entries under mcpServers with distinct keys.
- Review logs from the Python process for hints about tool spawning and tool adapter behavior during development.
Related MCP Servers
langchain -adapters
LangChain 🔌 MCP
langgraph-ai
LangGraph AI Repository
MCP-MultiServer-Interoperable-Agent2Agent-LangGraph-AI-System
This project demonstrates a decoupled real-time agent architecture that connects LangGraph agents to remote tools served by custom MCP (Modular Command Protocol) servers. The architecture enables a flexible and scalable multi-agent system where each tool can be hosted independently (via SSE or STDIO), offering modularity and cloud-deployable execut
ai-learning
AI Learning: A comprehensive repository for Artificial Intelligence and Machine Learning resources, primarily using Jupyter Notebooks and Python. Explore tutorials, projects, and guides covering foundational to advanced concepts in AI, ML, DL and Gen/Agentic Ai.
the -company
TheMCPCompany: Creating General-purpose Agents with Task-specific Tools
alris
Alris is an AI automation tool that transforms natural language commands into task execution.