Skip to main content
Glama

Recolour to a palette

remap_palette

Recolour an existing pixel art image so every pixel uses a colour from a specified palette, such as PICO-8 or Game Boy, while preserving the original size.

Instructions

Recolour an existing pixel art image so every pixel uses a colour from the given palette (e.g. PICO-8 or Game Boy). Size is kept.

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": {
      "input": "<input>",
      "palette": "<palette>"
    },
    "name": "remap_palette"
  }
}

Input Schema

NameRequiredDescriptionDefault
inputYesPath or URL of a PNG or JPEG image
outputNoWhere to save the PNG
paletteYesPalette name (pico-8, sweetie-16, endesga-32, game-boy, 1-bit) or hex colours like "#1a1c2c,#5d275d"

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.2

TDQS

A3.5/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 behavioral burden and does add genuinely useful facts: the operation is a transformation of an existing image and 'Size is kept' (dimensions preserved). It omits other relevant behavior such as whether the input file is modified or a new file is written when 'output' is omitted, the quantization/dithering approach, and any failure mode for non-pixel-art input.

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?

Two sentences, no waste, and the core action plus the key constraint ('Size is kept') are front-loaded. Nothing could be removed without losing information.

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 a three-parameter transformation tool with no annotations and no output schema, the description covers the essentials (input must be an image, palette drives the result, size preserved) but leaves the agent guessing about output-file behavior when 'output' is absent and about handling of non-pixel-art sources.

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?

Schema description coverage is 100%, so every parameter is already documented, including the palette name/hex-colour syntax and supported formats. The description adds no meaning beyond the schema (its 'PICO-8 or Game Boy' examples duplicate what the palette field already lists), so the baseline of 3 applies.

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?

The description pairs a specific verb ('Recolour') with a specific resource ('an existing pixel art image') and names the mechanism ('every pixel uses a colour from the given palette'). It is clearly distinguishable from siblings like extract_palette or upscale_pixel_art, though it never explicitly contrasts itself with them.

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?

Usage is only implied: 'an existing pixel art image' suggests the input should already be pixel art, but there is no explicit when-to-use / when-not-to-use guidance and no routing to alternatives such as list_palettes for discovering palette names or extract_palette for deriving one from an image.

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