AutoGen Extension for MCP Tools
This package provides integration between Microsoft AutoGen and the Model Context Protocol (MCP), enabling AutoGen agents to seamlessly connect with various data sources and tools.
MCP is an open standard that enables secure, two-way connections between AI systems and data sources, replacing fragmented integrations with a single universal protocol. This allows AI assistants to maintain context as they move between different tools and datasets.
Installation
pip install autogen-ext-mcp
Features
- Seamless integration of MCP tools with AutoGen agents
- Connect to any MCP-compatible data source or tool
- Automatic conversion of MCP tool schemas to AutoGen-compatible formats
Quick Start
from autogen_ext_mcp.tools import get_tools_from_mcp_server
from mcp import StdioServerParameters
from pathlib import Path
# Get desktop path cross-platform
desktop_path = str(Path.home() / "Desktop")
# Connect to FileSystem MCP server
server_params = StdioServerParameters(
command="npx",
args=[
"-y",
"@modelcontextprotocol/server-filesystem",
desktop_path, # Allow access to Desktop directory
]
)
# Get tools
tools = await get_tools_from_mcp_server(server_params)
# Use tools with AutoGen agents
# The tools can be passed to any AutoGen agent that supports tool use
Samples
Check out the samples directory for example code and detailed instructions on getting started with the AutoGen MCP Extension. The samples demonstrate common use cases and best practices for integrating MCP tools with AutoGen agents.
Resources
- AutoGen Documentation
- Model Context Protocol Documentation
- MCP Quickstart Guide
- Pre-built MCP Servers
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Metadata
Release files for autogen-ext-mcp 0.2.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| autogen_ext_mcp-0.2.2.tar.gz | 66.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| autogen_ext_mcp-0.2.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 71.6 kB
Release files / autogen_ext_mcp-0.2.2.tar.gz
| Download URL | autogen_ext_mcp-0.2.2.tar.gz |
|---|---|
| Size | 66.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1e8a62b3f47bea83e0af24f441712ffc8a229d68f269bd661ffdb4c5e040e846
|
|
BLAKE2b-256 checksum How to use checksums |
439854b88c34c3b64031d797ba4586b12f6e918aab242d6ea66631910ca4ccc0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.8
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jan 25, 2025.
Transparency logRelease files / autogen_ext_mcp-0.2.2-py3-none-any.whl
| Download URL | autogen_ext_mcp-0.2.2-py3-none-any.whl |
|---|---|
| Size | 5.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
bca66889b6f1da775480b31d24fd12f380f6f7f46385ac1820036539d8ebf733
|
|
BLAKE2b-256 checksum How to use checksums |
7ed5ac0c031ec515e7608eb4741598ac1c57bc5c3460601e9a837316507a1bb5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.8
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jan 25, 2025.
Transparency log