MCP.so
ログイン

MCP Server Examples with AutoGen

@SaM-92

基本情報

カテゴリ

推論

トランスポート

stdio

作者

SaM-92

MCP Server Examples with AutoGen について

This repository demonstrates how to use AutoGen to integrate local and remote MCP (Model Context Protocol) servers. It showcases a local math tool (math_server.py) using Stdio and a remote Apify tool (RAG Web Browser Actor) via SSE for tasks like arithmetic and web browsing.

MCP Server Examples with AutoGen の設定

以下の設定を使って、このサーバーを MCP 対応クライアントに追加してください。

{
  "mcpServers": {
    "mcp_autogen_sse_stdio": {
      "command": "uv",
      "args": [
        "venv",
        "--python",
        "3.12"
      ]
    }
  }
}

MCP Server Examples with AutoGen のツール

ツール一覧はまだありません

この掲載には表示できるツール一覧がまだありません。サーバーにツールがないという意味ではありません。対応機能はプロジェクトのドキュメントをご確認ください。

ツールは README から自動的に抽出されます。メンテナーは ## Tools という見出しの下に記載することで、このタブに反映できます。

概要

What is 🤖 MCP Server Examples with AutoGen?

This repository demonstrates how to connect AI agents to tools using the Model Context Protocol (MCP) within the AutoGen framework. It shows integration with both a local tool server (Stdio transport) and a remote tool server (SSE transport) to solve real queries.

How to use 🤖 MCP Server Examples with AutoGen?

Set up a Python 3.12 virtual environment with uv, install dependencies via uv pip install -e ., and create a .env file with your OPENAI_API_KEY and APIFY_API_KEY. Run the demo from the parent directory using uv run mcp_autogen_sse_stdio/main.py.

Key features of 🤖 MCP Server Examples with AutoGen

  • Dual MCP integration: local (Stdio) and remote (SSE) transports
  • Local calculator tool (add, multiply)
  • Remote web browsing via Apify’s RAG Web Browser Actor
  • AutoGen AssistantAgent configured with both tool sets
  • Standardized communication between AI models and tools

Use cases of 🤖 MCP Server Examples with AutoGen

  • Solving arithmetic problems using local Python scripts
  • Summarizing live web news through remote browsing tools
  • Prototyping multi‑tool AI agents that combine local and cloud resources
  • Learning how to integrate MCP servers with AutoGen agents

よくある質問

1

What MCP transports are demonstrated?

Local tools use StdioServerParams (standard input/output), and remote tools use SseServerParams (Server‑Sent Events).

2

What runtime requirements are needed?

Python 3.12, the `uv` package manager, and API keys for OpenAI and Apify.

3

How do I obtain and configure API keys?

Create a `.env` file in the `mcp_autogen_sse_stdio` directory and add `OPENAI_API_KEY` and `APIFY_API_KEY`. The Apify key can be obtained from the Apify MCP Server page.

4

Does this project work with other MCP servers?

The framework generalizes to other MCP servers that support Stdio or SSE transports, though only the Apify remote server is shown.

5

Is there a visual walkthrough available?

Yes, the repository includes an animated GIF (`images/mcp_exmpl.gif`) illustrating the workflow.

コメント

「推論」の他のコンテンツ