Skip to main content
Glama
tasopen

mcp-alphabanana

generate_image

Destructive

Generate images using AI with optional transparency, reference style images, and exact sizing. Supports PNG, JPG, WebP output with customizable cropping.

Instructions

Generate image assets using Gemini AI with optional transparency and reference images.

[Claude Desktop Guidance]

  • Prefer outputType='file' for medium or large images. base64 and combine responses can exceed Claude Desktop's context limit.

  • On Claude Desktop for Windows, use the FileSystem extension to choose reference-image paths and a writable absolute outputPath before calling this tool.

  • Use base64 only for small previews or when the client explicitly needs inline image data.

[Model Guidance]

  • Flash3.1 (recommended): High quality, very fast, supports grounding and advanced features.

  • Lite3.1 (Nano Banana 2 Lite): Ultra-fast, cost-effective, 1K-only, no search grounding. Ideal for quick drafting and low-latency iteration.

  • Pro3: Higher fidelity, but more costly and slower.

  • Flash2.5: Legacy, maintained for compatibility. Does not support 0.5K, 2K, or 4K resolutions.

[Aspect Ratios] Gemini supports the following aspect ratios (model-dependent):

  • Common to all models: 1:1, 2:3, 3:2, 3:4, 4:3, 4:5, 5:4, 9:16, 16:9, 21:9

  • Flash3.1 only: 1:4, 4:1, 1:8, 8:1

Normal mode: provide outputWidth/outputHeight and the server will choose the closest Gemini aspect ratio and source resolution, then resize to the requested pixel size. No-resize mode: set noresize=true and provide aspectRatio plus output_resolution. The server will return Gemini's native pixel dimensions for that combination without post-generation resizing.

If you intentionally want to control resizing/cropping in normal mode, use the 'resizeMode' parameter: 'crop' (default, center crop), 'letterbox' (fit with padding), 'contain' (trim transparent margins then fit), or 'stretch' (distort to fit).

[IMPORTANT] Always preserve the user's prompt as-is, including language and nuance. Do not translate or summarize.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
debugNoDebug mode: output intermediate processing images and prompt
modelNoModel tier to use for generation (see tool description for details; "flash" and "pro" are aliases for Flash2.5 and Pro3; "Lite3.1" is the low-latency Nano Banana 2 Lite model, 1K-only, no grounding)Flash3.1
promptYesUser-provided image prompt. Preserve the original wording and detail; do not summarize or translate. Only append transparency-related hints if needed.
noresizeNoSkip post-generation resizing and return Gemini native dimensions directly. When true, provide aspectRatio and output_resolution instead of outputWidth/outputHeight.
fringeModeNoFringe reduction mode: auto (size-based), crisp (binary alpha), hd (force-clear 1px boundary for large images).auto
outputPathNoOutput directory path (MUST be an absolute path when outputType is file or combine). In Claude Desktop on Windows, use the FileSystem extension to choose or prepare a writable absolute path such as C:\temp.
outputTypeNoOutput format: file=file only, base64=base64 only, combine=both. In Claude Desktop, prefer file for medium or large images to avoid context-size limits; use base64 only for small previews.combine
resizeModeNoResize mode: crop=center crop, stretch=distort, letterbox=fit with padding, contain=trim transparent margins then fitcrop
aspectRatioNoGemini aspect ratio to use directly when noresize=true. Ignored in normal resize mode.
outputWidthNoOutput image width in pixels. Required unless noresize=true. In normal mode, the image will be generated using the closest supported Gemini aspect ratio and resolution, then resized to this width.
transparentNoRequest transparent background (PNG or WebP only). Background color is selected by histogram analysis.
outputHeightNoOutput image height in pixels. Required unless noresize=true. In normal mode, the image will be generated using the closest supported Gemini aspect ratio and resolution, then resized to this height.
output_formatNoOutput formatpng
thinking_modeNoThinking mode (3.1 only)minimal
colorToleranceNoTolerance for color matching (0-255). Higher values are more permissive for transparent color selection and keying.
grounding_typeNoGrounding tool usage (3.1 only)none
outputFileNameYesOutput filename (extension auto-added if missing)
referenceImagesNoReference images for style guidance (Flash2.5: max 3, others: max 14)
include_metadataNoInclude grounding and reasoning metadata in JSON output (optional, may increase payload size).
include_thoughtsNoOptional (default: false). Request thought fields from Gemini (3.1 only). Thought content is returned in MCP response only when include_metadata=true.
transparentColorNoColor to make transparent. Hex (e.g. #FF00FF). null defaults to #FF00FF when transparent=true.
output_resolutionNoGemini generation source resolution (optional in normal mode, required when noresize=true). In normal mode, the final image is resized to the requested pixel size after generation.
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description discloses key behaviors beyond annotations: it explains that the tool generates files on disk (outputPath), handles resizing and cropping, supports transparency, and has model-dependent features. Annotations already indicate destructiveHint=true and openWorldHint=true, so the description adds context about what gets created and modified. However, it does not explicitly warn about overwriting existing files, which would have earned a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is long but well-structured with sections (Claude Desktop Guidance, Model Guidance, Aspect Ratios, IMPORTANT) and uses bullet points for readability. It front-loads the main purpose and then provides detailed guidance. While every sentence contributes value, some redundancy with schema descriptions could be trimmed slightly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (22 parameters, multiple modes, platform specifics), the description is quite comprehensive. It covers purpose, usage guidelines, model comparisons, resize behavior, output types, and important notes. However, it lacks explicit details about error responses or rate limits, and there is no output schema, but the description compensates well for the tool's generative nature.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so parameters are already documented. The description adds value by grouping parameters logically (e.g., model selection, aspect ratios, resize modes) and providing context for platform-specific usage (e.g., referenceImages filePath on Windows). It explains the interaction between parameters like outputWidth/outputHeight and noresize, which goes beyond individual parameter descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with 'Generate image assets using Gemini AI with optional transparency and reference images,' clearly stating the action, resource, and technology. It differentiates between different usage contexts (Claude Desktop, Windows, etc.) and provides model recommendations, ensuring the agent understands what the tool does and when to use which option.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description includes explicit guidance on when to use different output types ('Prefer outputType='file' for medium or large images'), when to use noresize mode vs normal mode, and when to choose each model (Flash3.1 recommended, Lite3.1 for quick drafting, etc.). It also provides platform-specific usage instructions for Claude Desktop and Windows, giving clear context for tool selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

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/tasopen/mcp-alphabanana'

If you have feedback or need assistance with the MCP directory API, please join our Discord server