pixel-surgeon-mcp
Integration with Google's Gemini 3.1 Flash Image for image generation at multiple resolutions and aspect ratios, and Veo 3 for text-to-video generation with audio, including region repair features.
Integration with OpenAI's GPT Image 2 for high-quality image generation with excellent text rendering, infographics, and diagrams, supporting flexible resolutions and quality levels.
An MCP server that gives Claude (or any MCP client) the ability to generate images, edit them, fix garbled text, and create videos — all through natural language.
How it works
pixel-surgeon-mcp is a multi-provider image generation server. You can use any combination of providers and switch between them per-request:
Gemini (Google) — balanced
Google's image generation pipeline uses a two-stage approach: Gemini 3.1 Pro reasons about your prompt, then Gemini 3.1 Flash Image renders the pixels. Supports 9 aspect ratios at 512/1K/2K/4K resolution. Best price/performance ratio, with a free tier available.
OpenAI GPT Image 2 — highest quality
OpenAI's latest image model with dramatically improved text rendering and visual fidelity. Supports flexible resolutions — pixel-surgeon maps your chosen size and aspect ratio to the optimal pixel dimensions automatically. Quality levels: medium (fast) and high (print-ready). Excellent for infographics, diagrams, and text-heavy images where other models struggle. Slower and more expensive.
Grok Imagine (xAI) — fastest
xAI's Aurora-powered image model. Fastest generation speed and lowest cost. Supports 7 aspect ratios at fixed resolutions (~1K). Good for rapid prototyping and iteration.
Veo 3 (Video)
For video, the server calls Veo 3 with async polling — generating both video and ambient audio. Supports 16:9 and 9:16 at 5s or 8s duration.
Region repair
AI image models struggle with text-heavy images. The fix tools solve this by sending smaller regions to the provider, then stitching the results back with histogram-matched compositing for seamless blending.
Related MCP server: Nano Banana MCP Server
Tools
Tool | Description |
| Text-to-image generation (single image) |
| Parallel batch generation (1-8 images) |
| Text-to-video via Veo 3 with audio (5s or 8s) |
| Edit an existing image with natural language instructions |
| Grid-based tile repair for garbled text (2x2, 3x3, etc.) |
| Targeted region repair with automatic aspect ratio snapping |
| Browser-based crop UI with multi-shot selection |
| List generated images and videos |
| Import an external image into the workspace |
| Remove image background (alpha channel transparency) |
Models
Model | Provider | Resolution | Best for |
| 512 / 1K / 2K / 4K | General image generation, photo-realistic scenes | |
| 1K max (free tier) | Quick drafts, prototyping | |
| OpenAI | Flexible (up to 4K) | Text-heavy images, infographics, diagrams, typography |
| OpenAI | 3 fixed sizes | Legacy support |
| xAI | Fixed (~1K per ratio) | Fast iteration, lowest cost |
Force a specific model per-call via the model tool parameter, or set DEFAULT_IMAGE_MODEL env var.
Gemini automatic fallback
If a Gemini generation call fails with a billing / prepay error, the server automatically retries on the free-tier gemini-2.5-flash-image model. The viewer shows a yellow banner when this happens. Free-tier limits: 1K max resolution, 10 RPM, 500 RPD.
Style presets
All generation and edit tools support an optional style parameter:
neo-brutalist
Magazine editorial, bold typography, halftone textures. Cream, black, and terracotta palette.
duval-software-infographic
Duval Software's signature retro-futurist infographic style. 1960s Space Age meets 1980s arcade. Cathode blue, amber, and salmon palette. Great for diagrams and system overviews.
fractal-arcade
Dithered fractals, Sierpinski patterns, low-poly. CRT retro, Amiga/EGA palette.
clean-tech-infographic
Technical diagrams, system flows, data pipelines. Dark navy, cyan, and electric blue.
Setup
Get your API key(s)
You need at least one provider API key. You can use any combination for maximum flexibility.
Google (Gemini + Veo 3)
Go to Google AI Studio
Sign in with your Google account
Click Create API Key and copy it
Prepayment required. Gemini 3.1 Flash Image and Veo 3 require billing and prepaid credits. The free-tier fallback (2.5 Flash) has limited resolution and rate limits. See Google AI pricing.
OpenAI (GPT Image 2)
Go to OpenAI API
Sign in or create an account
Click Create new secret key and copy it
Ensure you have API credits — image generation is billed per request
GPT Image 2 excels at text rendering, infographics, and diagrams. If you primarily need text-heavy images, this is the provider to use.
xAI (Grok Imagine)
Go to xAI Console
Sign in or create an account
Create an API key and copy it
Grok Imagine is the fastest and cheapest provider. Great for rapid iteration and prototyping. Fixed output resolutions (~1K) with no size control.
Quick start (npx)
No install needed — run directly with npx. Pass whichever API keys you have:
npx pixel-surgeon-mcpClaude Code CLI
claude mcp add pixel-surgeon \
-e GOOGLE_API_KEY=your-google-key \
-e OPENAI_API_KEY=your-openai-key \
-e XAI_API_KEY=your-xai-key \
-- npx pixel-surgeon-mcpClaude Desktop / MCP client config
{
"mcpServers": {
"pixel-surgeon": {
"command": "npx",
"args": ["pixel-surgeon-mcp"],
"env": {
"GOOGLE_API_KEY": "your-google-api-key",
"OPENAI_API_KEY": "your-openai-api-key",
"XAI_API_KEY": "your-xai-api-key"
}
}
}
}Install from source
If you prefer a local clone:
git clone https://github.com/j-east/pixel-surgeon-mcp.git
cd pixel-surgeon-mcp
npm install
npm run buildImage output
Generated images are saved to ~/Pictures/pixel-surgeon/. A local browser viewer auto-launches on first use for full-resolution previews with model selection, respin controls, and search.
Development
npm run dev # tsx watch mode
npm run build # compile TypeScript
npm run start # run compiled serverKey implementation details
Aspect ratio snapping — crops are adjusted to the nearest Gemini-supported ratio while preserving center point
Histogram matching — per-channel RGB normalization ensures composited regions blend seamlessly
Human-in-the-loop —
interactive_fixopens a browser crop UI, blocks via Promise until the user submits, fires parallel Gemini calls, and lets the user pick the best resultMCP size limits — full-resolution images are saved to disk; downsampled versions (< 950KB) are returned in MCP responses
Contributing
PRs are welcome! We're especially looking for:
New style presets
Add entries to the STYLE_PRESETS object in src/index.ts. Your PR should include:
The preset definition (name, prompt prefix, default aspect ratio)
2-3 example images generated with the preset (drop them in your PR description)
A short description of the visual style for the README table
Model adapters
The server currently supports Gemini, OpenAI, Grok Imagine, and Veo 3. We'd love adapters for other image/video generation APIs — Stable Diffusion, Flux, etc. If you're interested in adding one, open an issue first so we can align on the interface.
Built by Duval Software
pixel-surgeon-mcp is maintained by John Evans, part of the engineering team at Duval Software — a software engineering firm in Jacksonville Beach, FL building AI-powered tools and custom integrations. If you need MCP servers, AI pipelines, or production tooling built, get in touch.
License
MIT
Available Tools
11 toolsedit_imageA
Edit an existing image. Supports Gemini and OpenAI models — pass the model param to choose. Provide the filename of an image in /root/Pictures/pixel-surgeon (use list_images to see available files, or save_image to import one first). The MCP reads the file directly — do NOT pass base64 image data.
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | Text prompt describing the edits to make to the image | |
| filename | Yes | Filename of the source image in /root/Pictures/pixel-surgeon (e.g. "2026-03-17T17-47-31-152Z_59f735df.png") | |
| aspect_ratio | No | Aspect ratio for the output image | 1:1 |
| image_size | No | Output image resolution | 1K |
| style | No | Optional style preset to apply. When set, the style's prompt prefix is prepended and its default aspect ratio is used (unless you explicitly set one). Available styles: • neo-brutalist — Neo-brutalist minimalist magazine editorial. Bold oversized typography, cream/black/terracotta palette, halftone textures, visible grid lines, asymmetric layout. Think Emigre meets Swiss brutalism. • retro-futuristic-arcade — Retro-futurist infographic style. 1960s Space Age optimism meets 1980s arcade aesthetics. Cathode blue, warm amber, salmon red, warm green palette. CRT scanlines, atomic-age geometry, pixel-grid accents. Great for diagrams, system overviews, and technical illustrations. • fractal-arcade — Geometric dithered fractal style. All shading via dithering patterns and geometric cross-hatch grids — no smooth gradients. Fractal backgrounds (Sierpinski, hexagonal tessellations, recursive diamonds), low-poly faceted subjects, retro CRT palette. • duval-software-infographic — Duval Software's clean technical infographic for architecture diagrams, system flows, and data pipelines. Dark navy background, cyan/electric blue glowing connection lines, geometric nodes, professional and precise. | |
| model | No | Model to use. Available: 'gemini-3.1-flash-image' (Gemini 3.1 Flash Image), 'gemini-2.5-flash-image' (Gemini 2.5 Flash Image), 'gpt-image-1' (GPT Image 1 (OpenAI)), 'gpt-image-2' (GPT Image 2 (OpenAI)), 'grok-imagine' (Grok Imagine (xAI)). Default: 'gpt-image-2'. Set DEFAULT_IMAGE_MODEL env var to change the default. Provider tradeoffs: grok-imagine is fastest and cheapest; gemini is mid-quality with the best price/performance ratio (free tier available); gpt-image-2 is highest quality but slower and more expensive. Gemini models fall back to free tier on billing errors. OpenAI requires OPENAI_API_KEY. Grok requires XAI_API_KEY. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations, but description compensates fully: discloses file reading mechanism, model choices with tradeoffs, default model, env var override, fallback behavior, and required API keys.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Front-loaded with main action. Each sentence adds value. Slightly long due to model and style details, but all are informative. No redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given 6 parameters (4 with enums), no output schema, and complex model/style options, description covers all necessary context: prerequisites, model behavior, key usage notes. Complete for agent invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage 100%. Description adds value: explains model param with detailed tradeoffs, style param with presets described, and clarifies default behavior for aspect_ratio when style is set.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly states 'Edit an existing image', verb+resource. Distinguishes from siblings like generate_image (create new) and fix_image. Provides model options and prerequisites.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly mentions prerequisites (use list_images or save_image first) and model tradeoffs. Implicitly separates from generation tools. No explicit when-not-to-use, but context is clear.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
fix_imageA
Fix an image that has glitched or garbled text by splitting it into tiles, re-rendering each tile, and stitching them back together. This works because smaller sections have less text for the model to handle at once. Use this when a generated image has text artifacts or overloaded text regions.
| Name | Required | Description | Default |
|---|---|---|---|
| filename | Yes | Filename of the source image in /root/Pictures/pixel-surgeon | |
| prompt | No | Instructions for fixing each tile | Clean up and fix any garbled, glitched, or distorted text in this image tile. Preserve the style, colors, and layout exactly but make all text crisp and legible. |
| grid | No | How to split the image: cols x rows | 2x2 |
| image_size | No | Resolution for each tile | 1K |
| model | No | Model to use. Available: 'gemini-3.1-flash-image' (Gemini 3.1 Flash Image), 'gemini-2.5-flash-image' (Gemini 2.5 Flash Image), 'gpt-image-1' (GPT Image 1 (OpenAI)), 'gpt-image-2' (GPT Image 2 (OpenAI)), 'grok-imagine' (Grok Imagine (xAI)). Default: 'gpt-image-2'. Set DEFAULT_IMAGE_MODEL env var to change the default. Provider tradeoffs: grok-imagine is fastest and cheapest; gemini is mid-quality with the best price/performance ratio (free tier available); gpt-image-2 is highest quality but slower and more expensive. Gemini models fall back to free tier on billing errors. OpenAI requires OPENAI_API_KEY. Grok requires XAI_API_KEY. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries full burden. It explains the tiling process and why smaller sections help, but does not disclose failure modes, authentication requirements, or what happens to the original file.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences front-loading the action, rationale, and use case. Every sentence earns its place with zero redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema, but the description covers the process and use case adequately for the tool's complexity. Could mention that the tool produces a fixed image, but not essential.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% and schema descriptions are very detailed (e.g., model parameter includes provider tradeoffs). The main description adds little beyond repeating the tiling concept, meeting baseline.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb-reource pair ('Fix an image') and explicitly states the method (splitting into tiles, re-rendering). It distinguishes from siblings like edit_image or fix_region by focusing on garbled text and tiling approach.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Directly says 'Use this when a generated image has text artifacts or overloaded text regions.' Clear context but lacks explicit when-not-to-use or alternative tool mentions beyond the implied tiling approach.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
fix_regionA
Fix a specific region of an image by cropping it out, sending it for repair, and reinserting it. The crop is automatically snapped to the nearest supported aspect ratio. Use this when only part of an image has glitched text or artifacts — more precise than fix_image's grid approach.
| Name | Required | Description | Default |
|---|---|---|---|
| filename | Yes | Filename of the source image in /root/Pictures/pixel-surgeon | |
| prompt | No | Instructions for fixing the selected region | Clean up and fix any garbled, glitched, or distorted text in this image region. Preserve the style, colors, and layout exactly but make all text crisp and legible. |
| x | Yes | Left edge of region as percentage of image width (0-100) | |
| y | Yes | Top edge of region as percentage of image height (0-100) | |
| width | Yes | Width of region as percentage of image width (1-100) | |
| height | Yes | Height of region as percentage of image height (1-100) | |
| image_size | No | Resolution for the cropped region | 1K |
| model | No | Model to use. Available: 'gemini-3.1-flash-image' (Gemini 3.1 Flash Image), 'gemini-2.5-flash-image' (Gemini 2.5 Flash Image), 'gpt-image-1' (GPT Image 1 (OpenAI)), 'gpt-image-2' (GPT Image 2 (OpenAI)), 'grok-imagine' (Grok Imagine (xAI)). Default: 'gpt-image-2'. Set DEFAULT_IMAGE_MODEL env var to change the default. Provider tradeoffs: grok-imagine is fastest and cheapest; gemini is mid-quality with the best price/performance ratio (free tier available); gpt-image-2 is highest quality but slower and more expensive. Gemini models fall back to free tier on billing errors. OpenAI requires OPENAI_API_KEY. Grok requires XAI_API_KEY. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Discloses cropping and snapping to nearest aspect ratio, and model tradeoffs in parameter description. However, no annotations exist, and it omits details like destructive nature, rate limits, or authentication requirements.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences plus parameter table; front-loaded with purpose and usage. Every part is informative, no fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Covers purpose, when to use, and key behavioral aspects. Lacks output description and error handling, but sufficient given tool complexity and parameter clarity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema covers all parameters with descriptions (100% coverage). The description adds minimal extra beyond schema; model parameter has detailed tradeoffs within schema, so baseline 3.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly states it fixes a region of an image by cropping, repairing, and reinserting. Distinguishes from fix_image's grid approach, saying it's more precise for partial glitches.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly advises using it when only part of an image has glitched text or artifacts, and contrasts with fix_image. Provides clear when-to-use and alternative.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
generate_imageB
Generate a single image. Supports Gemini and OpenAI models — pass the model param to choose. Full-resolution image is viewable in the browser viewer.
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | Text prompt describing the image to generate | |
| aspect_ratio | No | Aspect ratio for the image | 1:1 |
| image_size | No | Image resolution | 1K |
| style | No | Optional style preset to apply. When set, the style's prompt prefix is prepended and its default aspect ratio is used (unless you explicitly set one). Available styles: • neo-brutalist — Neo-brutalist minimalist magazine editorial. Bold oversized typography, cream/black/terracotta palette, halftone textures, visible grid lines, asymmetric layout. Think Emigre meets Swiss brutalism. • retro-futuristic-arcade — Retro-futurist infographic style. 1960s Space Age optimism meets 1980s arcade aesthetics. Cathode blue, warm amber, salmon red, warm green palette. CRT scanlines, atomic-age geometry, pixel-grid accents. Great for diagrams, system overviews, and technical illustrations. • fractal-arcade — Geometric dithered fractal style. All shading via dithering patterns and geometric cross-hatch grids — no smooth gradients. Fractal backgrounds (Sierpinski, hexagonal tessellations, recursive diamonds), low-poly faceted subjects, retro CRT palette. • duval-software-infographic — Duval Software's clean technical infographic for architecture diagrams, system flows, and data pipelines. Dark navy background, cyan/electric blue glowing connection lines, geometric nodes, professional and precise. | |
| model | No | Model to use. Available: 'gemini-3.1-flash-image' (Gemini 3.1 Flash Image), 'gemini-2.5-flash-image' (Gemini 2.5 Flash Image), 'gpt-image-1' (GPT Image 1 (OpenAI)), 'gpt-image-2' (GPT Image 2 (OpenAI)), 'grok-imagine' (Grok Imagine (xAI)). Default: 'gpt-image-2'. Set DEFAULT_IMAGE_MODEL env var to change the default. Provider tradeoffs: grok-imagine is fastest and cheapest; gemini is mid-quality with the best price/performance ratio (free tier available); gpt-image-2 is highest quality but slower and more expensive. Gemini models fall back to free tier on billing errors. OpenAI requires OPENAI_API_KEY. Grok requires XAI_API_KEY. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It mentions the tool generates a single image and results are viewable in the browser viewer, but does not disclose any side effects, permissions, or failure modes. It is adequate but not thorough.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The main description is three short sentences that efficiently convey purpose, model support, and output availability. The style details are appropriately placed in the parameter schema, keeping the main description clean. No wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the lack of annotations and output schema, the description explains what the tool does and model options, but misses behavioral details like return format, error handling, or when to choose this over siblings. Adequate for basic use but not fully complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so baseline is 3. The description adds significant value by detailing model tradeoffs (speed, quality, cost) and providing extensive style descriptions with examples. This goes beyond the schema's enum labels.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states 'Generate a single image' and specifies supported models, but does not explicitly distinguish from the sibling 'generate_images' tool, which likely generates multiple images. The mention of 'single' provides some differentiation, but it could be more explicit.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance on when to use this tool versus alternatives like 'generate_images' or other image tools. Model tradeoffs are described, but that's for choosing a parameter, not for tool selection. The description lacks usage context.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
generate_imagesA
Generate multiple images in parallel. Supports Gemini and OpenAI models — pass the model param to choose. Returns the generated images and any accompanying text. Full-resolution images are viewable in the browser viewer.
| Name | Required | Description | Default |
|---|---|---|---|
| prompts | Yes | Array of text prompts, one per image to generate (1-8 images) | |
| aspect_ratio | No | Aspect ratio for all generated images | 1:1 |
| image_size | No | Image resolution | 1K |
| style | No | Optional style preset to apply. When set, the style's prompt prefix is prepended and its default aspect ratio is used (unless you explicitly set one). Available styles: • neo-brutalist — Neo-brutalist minimalist magazine editorial. Bold oversized typography, cream/black/terracotta palette, halftone textures, visible grid lines, asymmetric layout. Think Emigre meets Swiss brutalism. • retro-futuristic-arcade — Retro-futurist infographic style. 1960s Space Age optimism meets 1980s arcade aesthetics. Cathode blue, warm amber, salmon red, warm green palette. CRT scanlines, atomic-age geometry, pixel-grid accents. Great for diagrams, system overviews, and technical illustrations. • fractal-arcade — Geometric dithered fractal style. All shading via dithering patterns and geometric cross-hatch grids — no smooth gradients. Fractal backgrounds (Sierpinski, hexagonal tessellations, recursive diamonds), low-poly faceted subjects, retro CRT palette. • duval-software-infographic — Duval Software's clean technical infographic for architecture diagrams, system flows, and data pipelines. Dark navy background, cyan/electric blue glowing connection lines, geometric nodes, professional and precise. | |
| model | No | Model to use. Available: 'gemini-3.1-flash-image' (Gemini 3.1 Flash Image), 'gemini-2.5-flash-image' (Gemini 2.5 Flash Image), 'gpt-image-1' (GPT Image 1 (OpenAI)), 'gpt-image-2' (GPT Image 2 (OpenAI)), 'grok-imagine' (Grok Imagine (xAI)). Default: 'gpt-image-2'. Set DEFAULT_IMAGE_MODEL env var to change the default. Provider tradeoffs: grok-imagine is fastest and cheapest; gemini is mid-quality with the best price/performance ratio (free tier available); gpt-image-2 is highest quality but slower and more expensive. Gemini models fall back to free tier on billing errors. OpenAI requires OPENAI_API_KEY. Grok requires XAI_API_KEY. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description reveals parallel execution and that full-resolution images are viewable, but with no annotations provided, it fails to disclose authentication requirements, rate limits, error behavior, or side effects.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three concise sentences, front-loaded with the core function. Every sentence adds relevant information without redundancy or filler.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Despite no output schema, the description only vaguely says 'Returns the generated images and any accompanying text', omitting details like output format (URLs, base64), number of images, or any concurrency limits. This incompleteness hampers agent understanding.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
With 100% schema description coverage, the schema already documents all parameters. The tool description adds minimal value beyond 'pass the model param to choose', which is a high-level remark. Baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool generates multiple images in parallel, distinguishes it from the sibling 'generate_image' tool, and specifies supported models. The verb 'Generate' and resource 'multiple images' are explicit.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies use when multiple images are needed via 'Generate multiple images in parallel', but does not explicitly state when to use this tool versus alternatives like 'generate_image', nor provides when-not-to-use guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
generate_videoA
Generate a video using Google's Veo 3. Returns an MP4 video file. Video generation takes 1-3 minutes — the tool will poll until complete. Veo 3 generates both video and ambient audio. Videos are saved to the shared directory and viewable in the browser viewer.
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | Text prompt describing the video to generate. Be descriptive about motion, camera angles, lighting, and scene details for best results. | |
| aspect_ratio | No | Aspect ratio — 16:9 for landscape, 9:16 for portrait/vertical | 16:9 |
| duration | No | Video duration in seconds | 8 |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Without annotations, the description reveals key behaviors: polling (1-3 minute generation), output format (MP4), ambient audio generation, and storage/viewing (shared directory, browser viewer). This is transparent, though it omits potential error scenarios or limitations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is four sentences, each adding value: purpose, time/polling, audio, storage. No unnecessary words, and the most critical info is front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description covers output format, timing, and storage, which is fairly complete for a generation tool with no output schema. However, it lacks mention of file size limits, quality options, or error handling.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, and the description adds minimal value beyond the schema's parameter descriptions. The prompt advice is already in the schema, and aspect ratio/duration enums are clear. The baseline score of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool generates a video using Google's Veo 3, returns an MP4 file, and distinguishes itself from sibling image tools (e.g., generate_images) by mentioning video-specific features like ambient audio and polling.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies the tool is for video generation, but it does not explicitly state when not to use it or provide alternatives among sibling tools. The context of sibling tools suggests image generation tools are separate, but the description lacks direct guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
interactive_fixA
Opens an image in a browser-based crop tool where the user can draw a rectangle around the region to fix, add notes/instructions, and submit. The tool waits for the user's selection, then sends the cropped region for repair and composites it back into the original image. Best for precise, user-guided fixes.
| Name | Required | Description | Default |
|---|---|---|---|
| filename | Yes | Filename of the source image in /root/Pictures/pixel-surgeon | |
| image_size | No | Resolution for the cropped region | 1K |
| model | No | Model to use. Available: 'gemini-3.1-flash-image' (Gemini 3.1 Flash Image), 'gemini-2.5-flash-image' (Gemini 2.5 Flash Image), 'gpt-image-1' (GPT Image 1 (OpenAI)), 'gpt-image-2' (GPT Image 2 (OpenAI)), 'grok-imagine' (Grok Imagine (xAI)). Default: 'gpt-image-2'. Set DEFAULT_IMAGE_MODEL env var to change the default. Provider tradeoffs: grok-imagine is fastest and cheapest; gemini is mid-quality with the best price/performance ratio (free tier available); gpt-image-2 is highest quality but slower and more expensive. Gemini models fall back to free tier on billing errors. OpenAI requires OPENAI_API_KEY. Grok requires XAI_API_KEY. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden. It explains the interactive workflow (opens browser tool, awaits user input, crops, repairs, composites), but lacks details on blocking behavior, timeout, or what happens if no selection is made. The core behavior is described, but some edge cases are missing.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences: first states the primary action, second explains the process, third provides usage guidance. No redundant information. Well-structured and front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description covers the interactive process and the compositing outcome. However, it does not explicitly state what the tool returns (e.g., the final image path or object). Given the complexity and absence of output schema, a brief mention of return value would improve completeness.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the description does not need to add much. It does not elaborate on parameters beyond what the schema already provides. The model parameter has extensive enum descriptions in the schema itself. Description adds little new meaning, so baseline score of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly specifies the action: opens a browser-based crop tool, waits for user to draw a rectangle, then repairs and composites. It distinguishes itself from sibling tools like 'fix_image' by emphasizing interactive, user-guided precision.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description states 'Best for precise, user-guided fixes' which implies when to use, but it does not explicitly mention when not to use or provide direct comparisons to sibling tools like 'fix_region' or 'fix_image'. The usage guidance is implied rather than explicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_imagesA
List image and video files in the shared pixel-surgeon directory (/root/Pictures/pixel-surgeon). Use this to find images available for editing.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries full burden. It discloses the directory and purpose, but does not mention any behavioral traits like sorting, filtering, or read-only nature. Slightly lacking for a zero-annotation tool.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences with no wasted words. The information is front-loaded and every sentence adds value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (no parameters, no output schema), the description is complete enough. It explains what the tool does and its intended use, fitting the context of sibling tools.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, so schema covers everything. The description adds the directory path and purpose, adding value beyond the empty schema. Baseline for 0 params is 4.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool lists image and video files in a specific directory, using the verb 'list' and specifying the resource. It differentiates from sibling tools which are editing/generation operations.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description says 'Use this to find images available for editing,' implying usage before editing tools. While it doesn't explicitly state when not to use, the sibling context provides sufficient differentiation.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
remove_backgroundA
Remove a background color from an image and make it transparent. Outputs a PNG with alpha channel. The image must already exist in /root/Pictures/pixel-surgeon (use save_image to import first).
| Name | Required | Description | Default |
|---|---|---|---|
| filename | Yes | Filename of the source image in /root/Pictures/pixel-surgeon | |
| color | No | Target background color as hex (e.g. "#FFFFFF" for white, "#000000" for black, "#FF0000" for red). Default: white. | #FFFFFF |
| threshold | No | How far from the target color a pixel can be and still count as background (0 = exact match only, 30 = default, higher = more aggressive) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description must carry the full burden. It discloses the output format (PNG with alpha) and the prerequisite file location, but lacks detail on behavior when the target color is not present or the effect of the threshold parameter beyond the schema.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely concise with two sentences, front-loading the purpose and output format in the first sentence and the usage prerequisite in the second. No unnecessary words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with 3 parameters, no output schema, and no annotations, the description covers the core functionality, output, and a key prerequisite. Minor gaps exist (e.g., handling of missing color, edge cases), but it is largely complete for the task.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the baseline is 3. The description adds no parameter-specific details beyond what the schema provides; all parameters are already described in the schema with defaults and ranges.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: remove a background color and make it transparent, outputting a PNG with alpha channel. It distinctly differentiates from sibling tools like edit_image or fix_image, which do not specialize in background removal.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly states that the image must already exist in a specific directory and recommends using save_image first, providing clear contextual guidance. However, it does not mention when not to use this tool or alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
save_imageA
Copy an image file into the shared pixel-surgeon directory (/root/Pictures/pixel-surgeon) so it can be used with edit_image. Use this when the user wants to edit an image that exists elsewhere on their filesystem.
| Name | Required | Description | Default |
|---|---|---|---|
| source_path | Yes | Absolute path to the image file to import |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided; description discloses the copy operation but lacks details on permissions, side effects, or limitations. Adequate for a simple non-destructive action.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences with no wasted words. Front-loaded with the action and purpose, then usage condition.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple tool with one parameter and no output schema, the description covers purpose, usage, and parameter sufficiently.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema covers the parameter with a description ('Absolute path to the image file to import'); the tool description does not add further meaning. Baseline 3 due to high schema coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Copy an image file') and the specific resource (shared pixel-surgeon directory), and distinguishes from sibling tools by indicating this is a prerequisite for editing.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly says when to use this tool: 'when the user wants to edit an image that exists elsewhere on their filesystem.' While it doesn't say when not to use it or list alternatives, the context is clear.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
trace_to_svgA
Convert a raster image to SVG using potrace vectorization. Best for line art, diagrams, logos, and high-contrast images. The image must already exist in /root/Pictures/pixel-surgeon (use save_image to import first).
| Name | Required | Description | Default |
|---|---|---|---|
| filename | Yes | Filename of the source image in /root/Pictures/pixel-surgeon | |
| threshold | No | Brightness threshold for black/white conversion (0-255). Lower = more black. -1 = auto-detect. Default: auto. | |
| invert | No | Invert the image before tracing (useful for light-on-dark images) | |
| turdsize | No | Suppress speckles up to this size (in pixels). Default: 2. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries full burden. It explains the underlying technique (potrace) and mentions key parameters, but does not disclose output details (e.g., file path, name convention) or limitations (e.g., unsupported image types).
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences: one describing the action and ideal usage, one providing a critical prerequisite. No wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema is provided, and the description does not specify what the output is (e.g., saved SVG file path). For a conversion tool, this is a notable gap, but the description is otherwise sufficient for basic use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% and schema descriptions fully document each parameter. The description adds no additional semantics beyond what the schema provides, so a baseline score of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly states the tool converts a raster image to SVG using potrace, and specifies best use cases (line art, diagrams, logos, high-contrast images). However, it does not explicitly differentiate from sibling tools like save_image or edit_image.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides context on when the tool is best used (line art, etc.) and includes a essential prerequisite: the image must exist in /root/Pictures/pixel-surgeon via save_image. Lacks explicit 'when not to use' instructions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
11 tool updates
v1.1.1- First observed
edit_image - First observed
fix_image - First observed
fix_region - First observed
generate_image - First observed
generate_images - First observed
generate_video - First observed
interactive_fix - First observed
list_images - First observed
remove_background - First observed
save_image - First observed
trace_to_svg
TDQS
Each tool has a clearly distinct purpose: generate vs edit vs fix vs background removal vs vectorization. The three fix tools are differentiated by scope (whole image, automatic region, interactive region). No ambiguity.
All tool names follow a consistent verb_noun pattern in snake_case (e.g., generate_image, remove_background, trace_to_svg). No mixed conventions or vague verbs.
11 tools cover the core image manipulation workflow: import, list, generate, edit, fix, background removal, vectorization, video generation. Well-scoped without being overwhelming.
Covers major AI-driven image operations. Lacks a dedicated manual crop tool (fix_region's automatic snapping may not suffice) and non-AI utilities like resize or filter, but the set is strong for its domain.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
LLM chat, text tools, image generation, editing and batch image jobs
AI image, video & music generation. Flux, Veo 3.1, Suno V5. Free tier included.
Generate, edit, and explore AI images. Flux, Imagen, LoRA identity swap, upscale, and more.
Create images and videos from prompts, with options for image mixing, reference images, and start/…
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables conversational image generation and editing with Google's Gemini 2.5 Flash Image Preview. Supports text-to-image generation, natural language image editing, multi-image composition, and style transfer with optional file saving.4123MIT
- AlicenseNot gradedqualityDmaintenanceEnables generating, editing, and manipulating images using Google Gemini Flash 2.5 through natural language prompts. Supports text-to-image generation, image editing, multi-image composition, and batch processing with direct file management.724MIT
- AlicenseNot gradedqualityBmaintenanceGenerate and refine AI images/audio/video through natural conversation.403Apache 2.0
- AlicenseAqualityFmaintenanceEnables AI image generation via Antigravity (Google Gemini) and OpenAI DALL-E 3, supporting text-to-image, image editing, multiple outputs, and character consistency.5139MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/j-east/pixel-surgeon-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server