Skip to main content
Glama

Generate Image

generate_image

Generates a JPEG image from a text prompt using Google Gemini and saves it to disk. Provide an optional save path to control the output location.

Instructions

Generate an image from a text prompt using Google Gemini and save the JPEG to disk.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
promptYesDescriptive text prompt for generating the image
save_pathNoOptional path to save the JPEG image. Supports absolute or relative paths. If omitted, the server saves to IMAGE_OUTPUT_DIR or a default local output directory.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
textNoOptional text response from the model
modelYesGemini model used for generation
file_pathYesAbsolute path where the generated image was saved
mime_typeYesMIME type for generated image bytes
Behavior4/5

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

Annotations already indicate the tool is not read-only and has side effects. The description adds context by naming the external service (Google Gemini) and the side effect of saving a JPEG to disk. It also clarifies the output format, going beyond what annotations provide.

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

Conciseness5/5

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

The description is a single sentence that is directly relevant and front-loaded with the main action. It avoids unnecessary detail and clearly communicates the purpose and key behavior.

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 simplicity (2 parameters, output schema present, annotations provided), the description is sufficiently complete. It mentions the key side effect (saving to disk) and the technology (Gemini). A minor gap is the lack of any error handling or rate-limit information, but this is not critical for a straightforward generation tool.

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

Parameters3/5

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

The input schema provides full descriptions for both 'prompt' and 'save_path', covering 100% of parameters. The description itself does not add extra semantics about parameters beyond what is in the schema, so it aligns with the baseline for high coverage.

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 clearly states the action ('Generate an image from a text prompt using Google Gemini') and the output ('save the JPEG to disk'). It is specific and leaves no ambiguity about what the tool does. Even without siblings, it distinguishes itself by naming the model and output format.

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

Usage Guidelines4/5

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

The description implicitly tells when to use this tool: whenever an image needs to be generated from a text prompt and saved to disk. It does not explicitly mention exclusions or alternatives because there are no sibling tools, so this is acceptable. It provides clear functional context.

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/priorwave/nano_banana_mcp_server'

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