MCP.so
登录

MCP Server

@drkhan107

基本信息

分类

AI 与智能体

许可证

MIT

传输方式

stdio

作者

drkhan107

关于 MCP Server

A working pattern for SSE-based MCP clients and servers using Gemini LLM

MCP Server 配置

使用下面的配置,将此服务器添加到你的 MCP 客户端。

{
  "mcpServers": {
    "mcp_gemini": {
      "command": "python",
      "args": [
        "sse_server.py"
      ]
    }
  }
}

MCP Server 工具

工具列表暂未提供

当前收录暂时没有可展示的工具列表,不代表服务没有工具。请查阅项目文档了解支持的能力。

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is Model Context Protocol (MCP)?

A working demo of the Model Context Protocol integrated with Google’s Gemini. It provides a server that uses SSE (Server-Sent Events) to expose MCP endpoints, alongside a FastAPI backend and a Streamlit GUI for interacting with the system.

How to use Model Context Protocol (MCP)?

Clone the repository, set a GOOGLE_API_KEY in a .env file, install dependencies with pip install -r requirements.txt, then start the MCP server with python sse_server.py (defaults to http://localhost:8080/sse). Optionally launch the SSE client with python ssc_client.py http://localhost:8080/sse, start the FastAPI server with python fastapp.py, and finally run the Streamlit app with streamlit run app.py (opens on localhost:8501). Click “Connect to MCP server” in the browser.

Key features of Model Context Protocol (MCP)

  • Integrates with Google’s Gemini.
  • Uses SSE (Server-Sent Events) transport.
  • Includes a FastAPI server for a GUI backend.
  • Provides a Streamlit web interface.
  • Simple setup with a .env file for API key.
  • Fully functional demo ready to run locally.

Use cases of Model Context Protocol (MCP)

  • Experimenting with MCP and Gemini in a local environment.
  • Building a chat-like GUI that connects to an MCP server.
  • Prototyping applications that combine context management with Google’s generative AI.
  • Learning how to set up an MCP server with SSE and a client.

常见问题

1

What transport does the MCP server use?

The server uses SSE (Server-Sent Events) and runs by default on `http://localhost:8080/sse`.

2

Do I need an API key to run this server?

Yes, you must add a valid Google API key to a `.env` file as `GOOGLE_API_KEY`.

3

How do I start the GUI?

First ensure the MCP server and FastAPI server are running, then launch the Streamlit app with `streamlit run app.py` and open `localhost:8501` in your browser.

4

What dependencies are required?

All dependencies are listed in `requirements.txt` and can be installed with `pip install -r requirements.txt`.

评论

AI 与智能体 分类下的更多 MCP 服务器