modelscope·@dheedrichard/mcp-mediacrea
暂无描述。
MediaCrea exposes Gemini 2.5 Flash Image capabilities through the Model Context Protocol (MCP)an open-source standard that connects AI applications to external tools, data, or workflows in a consistent way. MCP acts like a USB-C port for AI assistants: hosts such as Claude Code or Cursor can attach this server to generate, edit, and blend images without bespoke integrations. Each instance runs the MediaCrea presets by default for image-focused workflows. For a deeper understanding of MCPs architecture and ecosystem benefits, see: Model Context Protocol Getting Started.
git clone https://github.com/YOU/mcp-mediacrea.git
cd mcp-mediacrea
python3 -m venv .venv
source .venv/bin/activate # Windows: .venv\Scripts\activate
pip install --upgrade pip
pip install -e .
MediaCrea uses a simple configuration hierarchy:
export GEMINI_API_KEY="YOUR_GEMINI_KEY"
export MEDIACREA_OUTPUT_DIR="/absolute/path/for/images" # optional
~/.mediacrea_config.json so the server works across shells:
cat > ~/.mediacrea_config.json <<'EOF'
{
"api_key": "YOUR_GEMINI_KEY",
"output_dir": "~/mcp_generated_images"
}
EOF
GENAI_IMAGE_MODEL env var to pick a different Gemini image model (defaults to models/gemini-2.5-flash-image-preview).MEDIACREA_OUTPUT_DIR env var to change output folder (overrides config file).mcp-mediacrea # should start and wait on stdio; Ctrl+C to exit
.mcp.json){
"mcpServers": {
"nano-banana": {
"type": "stdio",
"command": "/usr/bin/env",
"args": ["python3", "-m", "mcp_mediacrea"],
"cwd": "/ABS/PATH/TO/mcp-mediacrea",
"env": {
"MEDIACREA_OUTPUT_DIR": "/ABS/PATH/TO/mcp_generated_images"
}
}
}
}
You can swap command for mcp-mediacrea if the console script is on PATH (e.g. from the venv).
Point the MCP entry at whichever interpreter/shell you use. Example:
{
"type": "stdio",
"command": "/ABS/PATH/TO/.venv/bin/mcp-mediacrea",
"args": []
}
or equivalently the /usr/bin/env python3 -m mcp_mediacrea variant with cwd as above.
Example:
{
"name": "generate_image",
"arguments": {
"prompt": "A banana wearing a superhero costume, studio lighting, 1:1",
"style": "cartoon",
"aspect_ratio": "1:1",
"quality": "high"
}
}
Example:
{
"name": "edit_image",
"arguments": {
"image_path": "/path/to/input.png",
"instructions": "Increase contrast and add warm studio lighting",
"preserve_style": true
}
}
Example:
{
"name": "blend_images",
"arguments": {
"image_paths": ["/img1.png", "/img2.png"],
"instructions": "Merge seamlessly with natural lighting",
"blend_mode": "natural"
}
}
Example:
{
"name": "generate_text",
"arguments": {
"prompt": "Draft three taglines for a space-themed banana brand.",
"system_instruction": "Keep each tagline under 12 words.",
"temperature": 0.8
}
}
This server implements the Model Context Protocol (MCP) to expose tools, resources, and prompts over a standardized JSON-RPC transport (stdio). MCP allows hosts like IDEs or assistants to connect to external capabilities in a consistent way. See the official docs for details: Claude MCP docs, MCP Specification (20250618).
Key considerations adapted from the spec:
Transport: stdio (recommended for portability). The console script mcp-mediacrea launches the server using stdio by default.
Environment variables:
models/gemini-2.5-flash-image-preview; other Gemini IDs will work as long as they support image generation)models/gemini-2.5-flash; the server automatically falls back to other Gemini 2.x IDs if the first choice is unavailable)Optional file: ~/.mediacrea_config.json
{ "api_key": "...", "output_dir": "/absolute/path" }
{
"name": "generate_image",
"arguments": {
"prompt": "A banana wearing …
ModelContextProtocol服务器适用于Magic UI,它通过提供诸如跑马灯、动画、特效和互动背景等组件的代码,使AI助手能够轻松为Web应用程序实现UI组件。
一个提供网页开发工具的MCP服务器,例如屏幕捕捉功能,可以让AI代理获取并处理用户屏幕的截图。
一个由人工智能驱动的工具,可以从自然语言描述生成现代UI组件,并与流行的IDE集成,以简化UI开发工作流程。
通过模型上下文协议(MCP)将Blender连接到Claude AI,使Claude能够直接与Blender交互并对其进行控制,从而实现AI辅助的3D建模、场景操作和渲染。
集成了Dify AI API,为Ant Design组件提供代码生成服务,支持文本和图像输入,并具备流式处理能力。
一种模型上下文协议服务器,提供创建、管理和导出Excalidraw绘图的API功能,支持SVG、PNG和JSON等多种格式。