MCP.so

Hello-MCP ๐Ÿš€

@Cookie-HOO

Hello-MCP ๐Ÿš€ ใซใคใ„ใฆ

A Simple MCP Demo With Client & Server

ๅŸบๆœฌๆƒ…ๅ ฑ

ใ‚ซใƒ†ใ‚ดใƒช

ใใฎไป–

ใƒฉใ‚คใ‚ปใƒณใ‚น

MIT

ใƒฉใƒณใ‚ฟใ‚คใƒ 

python

ใƒˆใƒฉใƒณใ‚นใƒใƒผใƒˆ

stdio

ๅ…ฌ้–‹่€…

Cookie-HOO

่จญๅฎš

ไปฅไธ‹ใฎ่จญๅฎšใ‚’ไฝฟใฃใฆใ€ใ“ใฎใ‚ตใƒผใƒใƒผใ‚’ MCP ๅฏพๅฟœใ‚ฏใƒฉใ‚คใ‚ขใƒณใƒˆใซ่ฟฝๅŠ ใ—ใฆใใ ใ•ใ„ใ€‚

{
  "mcpServers": {
    "hello-mcp": {
      "command": "uv",
      "args": [
        "venv",
        "#",
        "Create",
        "virtual",
        "environment"
      ]
    }
  }
}

ใƒ„ใƒผใƒซ

ใƒ„ใƒผใƒซใฏๆคœๅ‡บใ•ใ‚Œใพใ›ใ‚“ใงใ—ใŸ

ใƒ„ใƒผใƒซใฏ README ใ‹ใ‚‰่‡ชๅ‹•็š„ใซๆŠฝๅ‡บใ•ใ‚Œใพใ™ใ€‚ใƒกใƒณใƒ†ใƒŠใƒผใฏ ## Tools ใจใ„ใ†่ฆ‹ๅ‡บใ—ใฎไธ‹ใซ่จ˜่ผ‰ใ™ใ‚‹ใ“ใจใงใ€ใ“ใฎใ‚ฟใƒ–ใซๅๆ˜ ใงใใพใ™ใ€‚

ๆฆ‚่ฆ

What is Hello-MCP ๐Ÿš€?

Hello-MCP ๐Ÿš€ is a simple implementation of an MCP (Model Control Protocol) client and server. It helps developers understand what the MCP protocol is and how it works by providing hands-on experience in building and using both client and server components.

How to use Hello-MCP ๐Ÿš€?

Clone the repository, install uv (e.g., via curl -LsSf https://astral.sh/uv/install.sh | sh on macOS), create a virtual environment (uv venv), install dependencies (uv sync), and activate it. Configure your DeepSeek API key in config.yaml (copy from config.example.yaml). Run the client in stdio mode with python -m hello_mcp.client2stdio --server-path ./hello_mcp/server.py or in SSE mode by first starting the server (python -m hello_mcp.server --transport sse) then the client (python -m hello_mcp.client2sse --server-url http://127.0.0.1:8000). Debug the server using uv run mcp dev hello_mcp/server.py.

Key features of Hello-MCP ๐Ÿš€

  • Supports registering MCP servers via SSE and stdio transports
  • Interactive command-line chat interface
  • Integrates with DeepSeek API (configurable API key)
  • Streamed response output
  • Simple server built on FastMCP with a path utility tool
  • Health check endpoint on the server

Use cases of Hello-MCP ๐Ÿš€

  • Learning the MCP protocol by building your own client and server
  • Gaining hands-on experience with MCP tool registration and invocation
  • Debugging MCP servers using the built-in MCP Inspector
  • Experimenting with MCP in daily AI workflows (e.g., with Claude Desktop or Cursor)
  • Extending the server with custom tools (by adding functions with the @tool decorator)

FAQ from Hello-MCP ๐Ÿš€

What problems does MCP solve?

MCP standardizes AI model interaction protocols, provides unified tool calling specifications, simplifies complex AI system integration, and enables modular, reusable model capabilities.

How do I set up the DeepSeek API key?

Copy config.example.yaml to config.yaml and fill in your DeepSeek API key (obtained from https://platform.deepseek.com/api_keys). Ensure no extra spaces or quotes around the key.

What if the port is already in use when starting the server?

Use lsof -i :8000 to find the process using the port, terminate it, or change the server port and update the client registration URL accordingly.

How can I extend Hello-MCP with new tools?

Add a new function in server.py, decorate it with @tool, define the input parameter schema, and test it by calling the client.

What are the runtime requirements?

Python 3, uv for project management, and a DeepSeek API key (currently the only supported AI provider). No additional MCP hosts are required; the server runs as a standalone Python process.

ใ‚ณใƒกใƒณใƒˆ

ใ€Œใใฎไป–ใ€ใฎไป–ใฎใ‚ณใƒณใƒ†ใƒณใƒ„