一个全面的项目编排工具,用于管理模型上下文协议(MCP)项目、模板、提示和Mermaid图表。
模板管理
提示管理
Mermaid图表生成
AWS MCP集成
pip install mcp-project-orchestrator
对于AWS集成支持:
pip install mcp-project-orchestrator[aws]
或者使用Poetry:
poetry add mcp-project-orchestrator
# 或者带有AWS支持
poetry add mcp-project-orchestrator -E aws
此仓库提供了一个Conan v2包,暴露了Python环境和CLI。在ai-servis的conanfile.py中添加:
def requirements(self):
self.requires("mcp-project-orchestrator/0.1.0@sparesparrow/stable")
然后激活运行环境,使mcp-orchestrator位于PATH上,并且包位于PYTHONPATH上:
conan profile detect --force
conan create . --user=sparesparrow --channel=stable
conan install mcp-project-orchestrator/0.1.0@sparesparrow/stable -g VirtualRunEnv
./conanrun.sh mcp-orchestrator --help
from mcp_project_orchestrator.templates import TemplateManager
# 初始化模板管理器
manager = TemplateManager("path/to/templates")
# 列出可用模板
templates = manager.list_templates()
print(templates)
# 应用项目模板
manager.apply_template("fastapi-project", {
"project_name": "my-api",
"project_description": "My FastAPI project",
"author_name": "John Doe",
"author_email": "john@example.com"
})
设置脚本读取config/project_orchestration.json以启用/禁用功能并设置端口和工具选项。
运行设置:
chmod +x scripts/setup_orchestrator.sh
scripts/setup_orchestrator.sh
编辑config/project_orchestration.json以控制搭建:
{
"enable": {
"cursorConfigs": true,
"pythonMcp": true,
"tsMcp": true,
"cppMcp": true,
"mcpClient": true,
"backgroundAgent": true,
"githubActions": true,
"devcontainer": true,
"awsTerraform": true,
"webAndMcp": true,
"cppConan": true,
"esp32": true,
"android": true
}
}
false以跳过生成这些组件。.cursor/webhooks、.cursor/agents、Dockerfile EXPOSE 和 compose.yaml中被尊重。from mcp_project_orchestrator.prompts import PromptManager
# 初始化提示管理器
manager = PromptManager("path/to/prompts")
# 列出可用提示
prompts = manager.list_prompts()
print(prompts)
# 渲染带有变量的提示
rendered = manager.render_prompt("system-prompt", {
"name": "User",
"project": "MCP"
})
print(rendered)
from mcp_project_orchestrator.mermaid import MermaidGenerator, MermaidRenderer
# 初始化生成器
generator = MermaidGenerator()
renderer = MermaidRenderer()
# 生成流程图
flowchart = generator.generate_flowchart(
nodes=[
("A", "Start"),
("B", "Process"),
("C", "End")
],
edges=[
("A", "B", ""),
("B", "C", "")
]
)
# 渲染为SVG
renderer.render(flowchart, "flowchart.svg")
mcp-project-orchestrator/
├── src/
│ └── mcp_project_orchestrator/
│ ├── templates/
│ │ ├── __init__.py
│ │ ├── base.py
│ │ ├── project.py
│ │ ├── component.py
│ │ └── manager.py
│ ├── prompts/
│ │ ├── __init__.py
│ │ ├── template.py
│ │ └── manager.py
│ └── mermaid/
│ ├── __init__.py
│ ├── generator.py
│ └── renderer.py
├── tests/
│ ├── __init__.py
│ ├── conftest.py
│ ├── test_templates.py
│ ├── test_prompts.py
│ └── test_mermaid.py
├── docs/
├── examples/
├── .github/
│ └── workflows/
│ └── ci.yml
├── pyproject.toml
├── Containerfile
└── README.md
git clone https://github.com/yourusername/mcp-project-orchestrator.git
cd mcp-project-orchestrator
poetry install
poetry run pytest
poetry run ruff check .
poetry run mypy src/mcp_project_orchestrator
该项目采用MIT许可证 - 查看LICENSE文件获取详细信息。
增强的OpenSSL项目模板和Cursor AI配置。
mcp-orchestrator create-openssl-project \
--project-name my-secure-app \
--deployment-target fips-government
mcp-orchestrator deploy-cursor --project-type openssl
openssl-consumer: 标准OpenSSL应用程序openssl-fips: FIPS 140-3政府部署