Skip to main content
Glama

Media Generator — Images, Videos & Audios

upscale_image

Input: An image URL and an optional scale factor (between 2 and 4) for upscaling.

Output: We will return the upscaled image URL to the user.

Functionality: This tool is used to upscale an image to a higher resolution. User will provide an image URL and optionally a scale factor, and the tool will return an upscaled version of that image.

Steps:

  1. We will get the user_id from the request context.

  2. We will validate the user's generation tokens.

  3. We will call the Image Upscaler API with the provided image URL and scale factor.

  4. This Image Upscaler API will return a JSON response with the upscaled image URL.

  5. We will return the upscaled image URL to the user.

INSTRUCTION FOR CLIENT MODEL:

  • Extract the required input parameter 'image_url' (type: string, URL) and the optional parameter 'scale_factor' (type: integer, default 2, allowed values: 2-4) from the user's prompt.

  • If 'scale_factor' is not specified in the prompt, use the default value 2.

  • Ignore any extraneous information in the user's input.

  • Pass the extracted values to this tool as 'image_url' and 'scale_factor'.

  • Example: For user input "Upscale this image https://example.com/image.jpg by 4x", extract 'image_url' as 'https://example.com/image.jpg' and 'scale_factor' as 4.

Input Schema

NameRequiredDescriptionDefault
image_urlYes
scale_factorNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • removedOutput schema / description
      Removed value: -"Generic wrapper for non-object return types."
  2. First observed

TDQS

B3.1/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and it discloses that the user_id is pulled from request context and generation tokens are validated — a real auth/failure hint. However it lists internal API steps that don't inform invocation and omits failure behavior or whether the image URL must be publicly reachable.

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

Conciseness2/5

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

The same fact — an upscaled image URL is returned — is restated three times across Functionality, Output, and Steps, and the numbered 'Steps' narrate internal API plumbing that the agent cannot act on. Section labels help, but the redundancy and irrelevant internals dilute the signal.

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?

An output schema exists and both parameters are fully documented, so the basics are covered for a simple 2-param tool. The gap is routing: nothing tells the agent why to pick upscale_image over the many image/video siblings, which is the main ambiguity left unresolved.

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 0%, so the description must compensate, and it largely does: image_url as a string URL, scale_factor as an integer defaulting to 2 with allowed values 2-4, plus a worked example. It stops short of stating accepted URL formats or image type/size limits.

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 — 'upscale an image to a higher resolution' with input/output described. It is distinguishable from generation siblings like generate_image, but never names or contrasts any sibling (e.g. edit_image_with_text) that an agent might confuse it with.

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

Usage Guidelines2/5

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

The description explains parameter extraction (default 2, range 2-4) but never says when to choose this tool over the 17 siblings, nor any preconditions or exclusions. All the guidance is about how to fill arguments, not when to invoke.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.