|
|
--- |
|
|
title: Ai Image Video Mcp Server |
|
|
emoji: π |
|
|
colorFrom: green |
|
|
colorTo: red |
|
|
sdk: gradio |
|
|
sdk_version: 5.33.1 |
|
|
app_file: app.py |
|
|
pinned: false |
|
|
license: mit |
|
|
short_description: 'Edit images, create videos via MCP Client Claude ' |
|
|
tags: |
|
|
- mcp-server-track |
|
|
--- |
|
|
|
|
|
I made this for myself to do bulk image editing (Background removal, upscale, edit) and products marketing/demo video generation agent. Only works locally because we can't |
|
|
pass images from Claude MCP Client to MCP server without passing a local path. If you are a jury please contact me @shdkhasan on X.com so i can give you the API keys |
|
|
to test locally. API keys below are required: |
|
|
|
|
|
MODAL_LABS_KEY=xxxx |
|
|
MODAL_LABS_ENDPOINT="https://xxxx.modal.run" |
|
|
GEMINI_API=XXXX |
|
|
|
|
|
### πΊ Demo Video |
|
|
|
|
|
π [Watch how it works (Loom)](https://www.loom.com/share/90b7c72f4eda47e1a94ba6859b14d13e?sid=f268bb09-6a8d-4c83-8435-cf8f85085a93) |
|
|
|
|
|
--- |
|
|
|
|
|
### π§ Tools Available |
|
|
|
|
|
#### 1. **Remove Background** |
|
|
- **Model**: BiRefNet v2 (hosted on Modal Labs) |
|
|
- **Input**: Image with background |
|
|
- **Output**: Transparent PNG |
|
|
|
|
|
#### 2. **Upscale** |
|
|
- **Tile Upscaler**: Highly accurate enhancer using tiled upscaling (hosted on Modal Labs) |
|
|
- **Clarity Upscaler**: General quality enhancer (calls external Gradio Space API) |
|
|
|
|
|
#### 3. **Image-to-Video** |
|
|
- **Model**: Google Veo 2 |
|
|
- **Input**: Image + Prompt |
|
|
- **Output**: Cinematic video clip (5β8 sec) |
|
|
- β οΈ **Note**: Image must be visually coherent; typically used after background editing |
|
|
|
|
|
#### 4. **Edit Image with Gemini** |
|
|
- **Model**: Gemini 2.0 Flash Preview Image Generation |
|
|
- **Purpose**: Add backgrounds/scenes to background-removed subjects |
|
|
- β
**Important**: Prompt must specify to **not alter the subject**, only modify the environment. |
|
|
|
|
|
--- |
|
|
|
|
|
### π§βπ» How to Use With Claude Desktop (MCP) |
|
|
|
|
|
To use this space as an MCP server: |
|
|
|
|
|
1. **Download [Claude Desktop](https://claude.ai)** |
|
|
2. In Claude's MCP config, add this server and filesystem: |
|
|
|
|
|
```json |
|
|
{ |
|
|
"mcpServers": { |
|
|
"gradio": { |
|
|
"command": "npx", |
|
|
"args": [ |
|
|
"mcp-remote", |
|
|
"http://127.0.0.1:7860/gradio_api/mcp/sse" |
|
|
] |
|
|
}, |
|
|
"filesystem": { |
|
|
"command": "npx", |
|
|
"args": [ |
|
|
"-y", |
|
|
"@modelcontextprotocol/server-filesystem", |
|
|
"C:\\Users\\YOUR_USERNAME\\Desktop\\claude-accessible-folder" |
|
|
] |
|
|
} |
|
|
} |
|
|
} |
|
|
``` |
|
|
|
|
|
> ποΈ Replace `YOUR_USERNAME` with your actual Windows username. Make sure the folder `claude-accessible-folder` exists on your Desktop. Claude will use it to share image/video files with the tools. |
|
|
|
|
|
--- |
|
|
|
|
|
### π§΅ Built by: [@shdkhasan](https://x.com/shdkhasan) |
|
|
|