mcp-agent-tool-adapter

The mcp-agent-tool-adapter is an automation tool developed in Python that integrates with MCP agents to create efficient workflows. Users can easily configure agents and automate tasks, enhancing productivity in their operations.

GitHub Stars

8

User Rating

Not Rated

Favorites

0

Views

39

Forks

0

Issues

0

README

mcp-agent-tool-adapter

From Protocol to Intelligence: Powering Agents with MCP.

license last-commit repo-top-language repo-language-count


๐Ÿ“ Overview

MCP Agent Tool Adapter enables modular tool invocation via the MCP protocol, and provides agents that can dynamically reason with tools using either Google ADK or LangGraph.

This project transforms MCP tools into:

  • ๐Ÿค– Google ADK-based agents with streaming FastAPI or CLI interfaces
  • ๐Ÿง  LangGraph-based agents that use ReAct + streaming tool planning

๐Ÿงฑ Project Structure
mcp-agent-tool-adapter/
โ”œโ”€โ”€ mcp_client/                # Core client implementation (modular)
โ”‚   โ”œโ”€โ”€ client.py              # MCPClient & MCPServer
โ”‚   โ”œโ”€โ”€ tool_loader.py         # High-level async loader
โ”‚   โ””โ”€โ”€ types.py               # Shared type definitions
โ”œโ”€โ”€ app_client_adk.py         # Google ADK agent + CLI chat
โ”œโ”€โ”€ app_client_langgraph.py   # LangGraph agent + ReAct CLI chat
โ”œโ”€โ”€ mcp_config.json           # Example MCP tool config
โ”œโ”€โ”€ requirements.txt          # Dependencies
โ””โ”€โ”€ README.md

๐Ÿš€ Getting Started
โ˜‘๏ธ Prerequisites
  • Python 3.10+
โš™๏ธ Installation
# Clone this repository
โฏ git clone https://github.com/serkanyasr/mcp-agent-tool-adapter
โฏ cd mcp-agent-tool-adapter

# Install dependencies
โฏ pip install -r requirements.txt

๐Ÿค– Usage
Run Google ADK CLI agent:
โฏ python app_client_adk.py
Run LangGraph ReAct CLI agent:
โฏ python app_client_langgraph.py

Ensure your mcp_config.json defines tools like:

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": ["@modular-protocol/filesystem"]
    }
  }
}

๐Ÿง  Tool Architecture

MCP tools are connected to agents through MCPClient, which handles:

  • Tool server spawning (via subprocess)
  • Session management
  • Tool adaptation (langgraph or Google ADK)
  • Cleanup

You can dynamically swap agent type by changing tool_type to "google" or "langgraph" in your app.


๐Ÿงช Development / Contributing
  • Fork the repo and create feature branches.
  • Submit a PR with a description of your changes.
  • Tag @serkanyasr in issues or PRs.

We welcome contributions in:

  • ๐Ÿงฉ new MCP tool adapters
  • ๐Ÿง  multi-agent LangGraph use cases
  • ๐Ÿ› ๏ธ OpenAPI / streaming support

๐ŸŽ— License

This project is licensed under the MIT License.For more details, refer to the LICENSE file.