Skip to main content
Glama

playcal_visual

Compare a PNG screenshot against a saved baseline with per-pixel tolerance, ignore dynamic regions, and write a diff image when the check fails; save baselines for later visual regression checks.

Instructions

screenshot gate: compare a PNG to a saved baseline with a per-pixel tolerance, write a diff PNG on a fail

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": {
      "action": "<action>",
      "name": "<name>",
      "png": "<png>"
    },
    "name": "playcal_visual"
  }
}

Input Schema

NameRequiredDescriptionDefault
dirNowhere baselines live (default .playcal/visual).playcal/visual
pngYesthe screenshot (8- or 16-bit PNG)
nameYesbaseline name, e.g. level4-start
actionYessave: make this PNG the baseline; check: compare a PNG to it
ignoreNoskip a box that changes on its own, like a clock or FPS counter (repeatable)
toleranceNoper-channel difference a pixel may have, 0-255 (default 8)
max_changedNopercent of pixels allowed to change (default 0.1)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.1

TDQS

B3.2/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 does disclose one important side effect: a diff PNG is written on failure. It is silent on the more consequential behaviors, notably that `action=save` overwrites the stored baseline, where the diff file lands, and whether a failed check returns an error or a structured result, so the agent cannot predict the outcome of a write path.

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?

A single compact sentence with the core concept front-loaded and no filler. It is dense but readable; the only structural weakness is that the failure-side effect is appended rather than the save path being mentioned at all.

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 7-parameter tool with no annotations and no output schema, the description covers the happy-path comparison but leaves the save action, baseline overwrite semantics, and result shape unexplained. Adequate for the check path, incomplete for the tool as a whole.

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, and the description adds only that tolerance is per-pixel. It contributes nothing about `ignore` box syntax, `max_changed` semantics, or the `dir` baseline location beyond what the schema states, so the baseline of 3 is appropriate.

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 concrete verb and resource: compare a PNG against a saved baseline, a visual-regression gate. It is specific enough to distinguish the operation, but it describes only the comparison half of the tool even though `action` also supports "save", and it never distinguishes this from the sibling `playcal_baseline`, which an agent could reasonably mistake for the same job.

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 when-to-use guidance, no when-not-to-use, and no mention of alternatives such as `playcal_baseline` or `playcal_snap`. The implied workflow (save a baseline first, then check against it) has to be inferred from the schema enum rather than being stated in the description.

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