
sontallive/mcp-server-python-template
Developer tools이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기
이 템플릿은 Python의 Model Context Protocol (MCP) 서버를 구축하기위한 간소화 된 기반을 제공합니다. 그것은 MCP 공구의 AI 보조 발달을 더 쉽고 능률적으로 만들기 위하여 디자인됩니다.
개요
이 템플릿은 Python의 Model Context Protocol (MCP) 서버를 구축하기위한 간소화 된 기반을 제공합니다. 그것은 MCP 공구의 AI 보조 발달을 더 쉽고 능률적으로 만들기 위하여 디자인됩니다. - Ready-to-use MCP 서버 구현 - 구성 가능한 전송 모드 (stdio, SSE) - 예 날씨 서비스 통합 (NWS API) - 깨끗하고 잘 문서화 된 코드 구조 - Minimal Dependencies - 향상된 AI 도구 이해 이 프로젝트는 향상된 AI 코딩 지원을위한 Cursor 규칙을 사용하여 멋진 Cursor 규칙의 패턴과 함께합니다. - : 내장 깨끗한 코드 규칙은 일관성과 품질을 유지할 수 있도록 도와줍니다 - : 규칙은 AI 조수가 더 나은 코드를 생성하는 데 도움이되는 컨텍스트를 제공합니다 - : MCP 서버 구현을위한 최상의 관행을 따르십시오. Cursor 규칙은 AI 코딩 조수와 인간 개발자가 높은 코드 품질 기준을 유지하고 모범 사례를 따르는 데 도움이됩니다. 이 템플릿은 프로젝트에서 포괄적인 MCP 문서를 직접 포함합니다: - (protocals/mcp.).
개요(AI 번역)
MCP 공식 튜토리얼에서 영감을 받았습니다.
개요
이 템플릿은 Python의 Model Context Protocol (MCP) 서버를 구축하기위한 간소화 된 기반을 제공합니다. 그것은 MCP 공구의 AI 보조 발달을 더 쉽고 능률적으로 만들기 위하여 디자인됩니다.
특징
- MCP 서버 구현
- 구성 가능한 수송 모드 (stdio, SSE)
- 예 기상 서비스 통합 (NWS API)
- 깨끗하고 잘 문서화 된 코드 구조
- 최소 의존성
- **Embedded MCP 사양 및 문서 ** 향상된 AI 도구 이해
커서 규칙 통합
이 프로젝트는 향상된 AI 코딩 지원을위한 Cursor 규칙을 사용하여 멋진 Cursor 규칙의 패턴과 함께합니다.
- ** Clean Code Guidelines **: 내장 깨끗한 코드 규칙은 일관성과 품질을 유지
- **Enhanced AI 이해 **: AI Assistants가 더 나은 코드를 생성하는 데 도움이되는 context를 제공합니다.
- Standardized Patterns: MCP 서버 구현에 대한 모범 사례를 따르십시오.
Cursor 규칙은 AI 코딩 조수와 인간 개발자가 높은 코드 품질 기준을 유지하고 모범 사례를 따르는 데 도움이됩니다.
통합 MCP 문서
이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요.
README
원문 README의 일부입니다. 원문 보기.
MCP Server template for better AI Coding
Inspired by MCP Official Tutorial
Overview
This template provides a streamlined foundation for building Model Context Protocol (MCP) servers in Python. It’s designed to make AI-assisted development of MCP tools easier and more efficient.
Features
- Ready-to-use MCP server implementation
- Configurable transport modes (stdio, SSE)
- Example weather service integration (NWS API)
- Clean, well-documented code structure
- Minimal dependencies
- Embedded MCP specifications and documentation for improved AI tool understanding
Cursor Rules Integration
This project uses Cursor Rules for improved AI coding assistance, with patterns from Awesome Cursor Rules.
- Clean Code Guidelines: Built-in clean code rules help maintain consistency and quality
- Enhanced AI Understanding: Rules provide context that helps AI assistants generate better code
- Standardized Patterns: Follow established best practices for MCP server implementation
Cursor Rules help both AI coding assistants and human developers maintain high code quality standards and follow best practices.
Integrated MCP Documentation
This template includes comprehensive MCP documentation directly in the project:
-
Complete MCP Specification (
protocals/mcp.md): The full Model Context Protocol specification that defines how AI models can interact with external tools and resources. This helps AI assistants understand MCP concepts and implementation details without requiring external references. -
Python SDK Guide (
protocals/sdk.md): Detailed documentation for the MCP Python SDK, making it easier for AI tools to provide accurate code suggestions and understand the library’s capabilities. -
Example Implementation (
protocals/example_weather.py): A practical weather service implementation demonstrating real-world MCP server patterns and best practices.
Having these resources embedded in the project enables AI coding assistants to better understand MCP concepts and provide more accurate, contextually relevant suggestions during development.
Requirements
- Python 3.12+
- Dependencies:
mcp>=1.4.1httpx>=0.28.1starlette>=0.46.1uvicorn>=0.34.0
Getting Started
Installation
-
Clone this repository:
git clone https://github.com/yourusername/mcp-server-python-template.git cd mcp-server-python-template -
Create a virtual environment and install dependencies:
python -m venv .venv source .venv/bin/activate # On Windows: .venv\Scripts\activate pip install -e .
Running the Example Server
The template includes a weather service example that demonstrates how to build MCP tools:
# Run with stdio transport (for CLI tools)
python server.py --transport stdio
설치
This server does not publish a one-line install command.
Open the repository installation guide MCP 초보자라면? mcpskill.org 가이드부터 시작하세요 →