Skip to main content
Glama

draw_pixels

Draws pixel art from a character grid by mapping each character to a palette color, leaving unmapped characters unchanged; each call is a single undo step in Pixelorama.

Instructions

Draw pixels from a character grid. Each string in rows is one row of pixels; each character is looked up in palette. Characters that are not in the palette (such as '.') leave the pixel unchanged, so map a character to "transparent" to erase. Example: palette {"o": "#e8a33d", "d": "#7a4a12"}, rows [".oo.", "oddo", ".oo."]. The whole call is one undo step in Pixelorama.

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": {
      "rows": "<rows>",
      "palette": "<palette>"
    },
    "name": "draw_pixels"
  }
}

Input Schema

NameRequiredDescriptionDefault
xNoLeft edge of the grid on the canvas
yNoTop edge of the grid on the canvas
rowsYes
frameNoFrame index, from 0. Defaults to the current frame
layerNoLayer index, 0 is the bottom layer. Defaults to the current layer
paletteYesSingle character -> color

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations present, the description carries the burden and does well: it discloses that unpalettized characters leave pixels unchanged, that "transparent" erases, and that the entire call collapses into one undo step — non-obvious behavior an agent could not infer. It stops short of covering out-of-bounds coordinates or error/validation behavior.

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?

Purpose is front-loaded, followed by the two rules that matter (palette lookup and unchanged pixels), then a compact worked example that earns its space by showing the transparent-hole pattern concretely.

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?

For a six-parameter mutation tool with no annotations and no output schema, the description is largely sufficient — semantics, erase mechanism, and undo scope are covered, and positional params are documented in the schema. Return value behavior is unstated but arguably minor for a draw operation.

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 83%, so the baseline is 3, but the description adds genuine meaning: it defines rows as one canvas row per string and palette as a per-character color lookup, semantics the schema's bare type declarations do not convey. The x/y/frame/layer params are left entirely to the schema.

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?

States a specific verb and resource ("Draw pixels") plus the distinctive mechanism ("from a character grid"), which immediately separates it from sibling tools like fill_rect or read_pixels without naming 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 conveyed only by implication through the example and the erase technique; there is no explicit guidance on when to prefer this over fill_rect or when a single-pixel/rect approach is better, and no stated prerequisites.

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