Skip to main content
Glama

flow_edit_image

Edit an existing image using a natural-language prompt without masks. Apply targeted changes, insert or remove objects, extend the canvas, or swap backgrounds.

Instructions

Edit an existing image with a natural-language instruction (no mask needed).

Args: image_path: Path to the source image. prompt: What to change. edit_mode: 'free' (default, just follow the prompt), 'inpaint_insertion' (add), 'inpaint_removal' (remove), 'outpaint' (extend canvas), 'bgswap' (new background). model: 'fast' (default), 'pro', 'lite', or a full model id. aspect_ratio: Output aspect ratio. Defaults to the input image's shape. image_size: '1K', '2K' or '4K'. output_dir: Override the output folder. mask_mode: Ignored. Kept for compatibility with 0.1.0 (Nano Banana edits need no mask).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "image_path": "<image_path>",
      "prompt": "<prompt>"
    },
    "name": "flow_edit_image"
  }
}

Input Schema

NameRequiredDescriptionDefault
modelNo
promptYes
edit_modeNofree
mask_modeNo
image_pathYes
image_sizeNo
output_dirNo
aspect_ratioNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.3

TDQS

A3.9/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does reasonably well: it discloses that no mask is required, that mask_mode is ignored for backward compatibility, and the default behavior of aspect_ratio (inherits input shape). It omits whether the source file is modified or a new file is written, where output lands by default, and any cost or latency implications.

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 one-line purpose is front-loaded and the Args block is scannable with no filler. The bulleted edit_mode explanation wraps across two lines but every phrase earns its place.

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

Completeness3/5

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

For an 8-parameter mutation tool with no annotations and no output schema, the parameter documentation is complete but the surrounding behavior is thin. An agent still cannot tell what the tool returns (file path, URL, asset id) or whether invoking it costs credits, which matters given the presence of flow_estimate_cost and flow_usage_today as siblings.

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

Parameters5/5

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

Schema coverage is 0%, so the description must supply all meaning, and it does: every one of the 8 parameters is explained, including the enumerated values for edit_mode, the model tiers, the image_size options, and the aspect_ratio default. This adds substantial value the bare schema lacks.

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

Purpose4/5

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

States a specific verb and resource: 'Edit an existing image with a natural-language instruction', plus a differentiating constraint ('no mask needed') that separates it from masked-edit workflows. It does not explicitly contrast with flow_edit_video or flow_generate_image, so the sibling boundary is left implicit.

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

Usage Guidelines3/5

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

The edit_mode list implies which situation each mode suits (add, remove, extend canvas, new background), which is real usage guidance at the mode level. However, there is no guidance on when to choose this tool over flow_generate_image or flow_edit_video, and no prerequisites such as whether the source image must exist locally or in a project.

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