Skip to main content
Glama

normalize_frames

Converts separately generated frames into a consistent sprite set by matching body scale, anchoring feet, centering on one canvas, and snapping colors to a reference.

Instructions

Turn separately generated frames into one consistent sprite set (no Codex call, instant).

Frames need a transparent background (generate them with chroma_key). Each frame is scaled so the character's body area (ignoring thin parts like a pick handle) matches reference_path, which keeps the same size whether the pose stands, crouches or lunges. Frames are anchored on a shared feet baseline and centre on one canvas, given hard alpha, and snapped to up to palette_size of the reference's own colours (0 keeps the generated colours). Writes <output_dir>/.png and returns each frame's scale and body height, the shared canvas size and the anchor (feet point) for the engine's sprite offset.

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": {
      "frame_paths": "<frame_paths>",
      "reference_path": "<reference_path>",
      "output_dir": "<output_dir>"
    },
    "name": "normalize_frames"
  }
}

Input Schema

NameRequiredDescriptionDefault
paddingNo
overwriteNo
output_dirYes
frame_pathsYes
palette_sizeNo
reference_pathYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/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 mostly succeeds: it discloses what is scaled, how anchoring/centering/hard-alpha/palette snapping work, that files are written to disk, and what the return payload contains. It omits conflict behavior for existing files and any permission or failure-mode context.

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?

Front-loads the core purpose in the first line before detailing mechanics, and most sentences are dense with useful specifics. A few clauses (e.g. the pick-handle aside) are longer than needed but illustrative rather than wasteful.

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 unusually complete — it documents the return shape (per-frame scale, body height, canvas size, feet anchor) in place of an output schema. The remaining gap is the undocumented padding and overwrite 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 coverage is 0% across six parameters, so the description must compensate. It explains palette_size ('0 keeps the generated colours'), output_dir (write location and naming), and the role of reference_path, but leaves padding and overwrite — including what the default false does on collision — entirely undefined.

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 — turning separately generated frames into one consistent sprite set — and immediately distinguishes itself from the generation siblings with '(no Codex call, instant)', making clear this is post-processing rather than image generation.

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

Usage Guidelines4/5

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

Gives a clear prerequisite ('Frames need a transparent background (generate them with chroma_key)'), which situates the tool after frame generation in the pipeline, but offers no explicit when-not guidance and never addresses the overwrite=false default or what to do when outputs already exist.

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