🦞🧠 The ClawCap — Avatar Accessory Skill
When the user wants to add a hat, headwear, or accessory to an avatar image, use this skill.
What It Does
ClawCap uses a 3-stage AI pipeline to add accessories to any avatar:
- VLM Fingerprint — Gemini Vision analyzes the avatar's art style, lighting, color palette, and head position
- Mask Generation — Automatically creates a pixel-precise placement mask using Pillow/NumPy
- AI Inpainting — Gemini generates the accessory that perfectly matches the original style
Supported Styles
- 📷 Real photos
- 🎨 Anime / 2D illustrations
- 🧊 3D renders
- 👾 Pixel art / NFT avatars
How to Use
As MCP Skill (Claude Desktop)
Add to claude_desktop_config.json:
{
"mcpServers": {
"clawcap": {
"command": "python",
"args": ["mcp_server.py"],
"cwd": "/path/to/The-ClawCap"
}
}
}
Then tell Claude: "给这个头像戴上一顶龙虾帽" with an image attached.
As Web API
POST http://localhost:8000/api/skill/alpha-equip
Content-Type: application/json
{
"image_base64": "<base64 encoded image>",
"accessory_prompt": "a red lobster claw beanie hat"
}
Live Demo
🌐 Try it online (Rate limited: 3 requests/minute per IP)
Requirements
- Python 3.10+
GEMINI_API_KEYenvironment variable (get one at https://aistudio.google.com/apikey)- Install deps:
pip install -r requirements.txt