Skip to main content
Glama

render_image

Render pixel-accurate layouts from text, shapes, lines, and progress elements for small displays, then return a hosted image URL with hash and change status.

Instructions

Render a custom layout from drawing elements and store it as (profile, label).

Origin (0,0) is top-left; sizes are in pixels. Colours are names (black, white, red, yellow, gray, dark_gray, light_gray) or #rrggbb; they snap to what the profile can show. Elements: {"type":"text","text":..,"x":..,"y":..,"size":12,"color":"black","bold":false, "anchor":"la","max_width":px,"max_lines":1} (anchor: Pillow anchors, e.g. "la","mm","ra") {"type":"rect","x":..,"y":..,"w":..,"h":..,"fill":colour|null,"outline":colour|null,"width":1} {"type":"line","x1":..,"y1":..,"x2":..,"y2":..,"color":"black","width":1} {"type":"progress","x":..,"y":..,"w":..,"h":..,"value":0.0-1.0} Returns the image URL, sha256 and changed (see render_card).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
labelYes
profileYes
elementsYes
backgroundNowhite
descriptionNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/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 it delivers real behavioral context: the top-left origin convention, pixel units, colours that 'snap to what the profile can show', and a `changed` return value implying cached/no-op semantics. It omits what happens when (profile, label) already exists and whether the store is overwritten, which keeps it short of a 5.

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 purpose sentence is front-loaded, followed by terse coordinate/colour rules and a compact element-type spec block. The spec block is large but earns its space given the free-form schema; the only soft spot is the dangling '(see render_card)' reference for `changed`.

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?

Return values (URL, sha256, changed) are named despite there being no output schema, and the element format is fully specified. What is missing is anything about the profile concept (a sibling list_profiles exists), label uniqueness/overwrite behavior, and the purpose of the description and background parameters.

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 0%, so the description must compensate; it does so thoroughly for the critical `elements` parameter by enumerating element types and their fields. However, profile, label, background (only defaulted in the schema) and description are never explained, leaving 4 of 5 parameters semantically undocumented.

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?

Specific verb+resource: 'Render a custom layout from drawing elements and store it as (profile, label)' tells an agent exactly what is produced and where it lands. It does not, however, explicitly differentiate the tool from its close siblings render_card and render_layout, which an agent must distinguish by name inference only.

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?

There is no statement of when to use this tool versus render_card or render_layout, nor any prerequisites or exclusions. The phrase 'custom layout from drawing elements' implies a low-level primitive, but the agent is left to infer the choice entirely from sibling tool names.

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