Skip to main content
Glama

viewport_compare_screenshot

Compare baseline and candidate viewport screenshots to check visual similarity. Returns a similarity score and metadata, using a pass threshold to validate if the candidate matches the baseline.

Instructions

Compare two workspace-local viewport screenshot artifacts.

Args: baseline_path: Workspace-local baseline PNG path candidate_path: Workspace-local candidate PNG path pass_threshold: Similarity threshold, 0-1

Returns: JSON string with similarity and artifact metadata.

KB: see knowledge_base/32_AGENT_PLAYABLE_SLICE_RECIPE.md#overview Example: viewport_compare_screenshot(baseline_path="/Game/MCP_Test/Example", candidate_path="/Game/MCP_Test/Example")

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
baseline_pathYes
candidate_pathYes
pass_thresholdNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.9/5.0
Behavior3/5

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

With no annotations provided, the description carries the behavioral disclosure burden. It states the return value is 'JSON string with similarity and artifact metadata' and notes workspace-local paths, but it does not explain what happens when similarity falls below pass_threshold, nor whether the operation has side effects. The behavior is broadly implied but not fully transparent.

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?

The description is well-structured: a one-sentence purpose, clearly labeled Args/Returns/KB/Example sections, and no filler. Every section contributes useful information and the main purpose is front-loaded.

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?

The description covers the main inputs and output, and references a KB document, but it leaves a meaningful gap around pass_threshold semantics: what constitutes passing, whether the tool returns a boolean or just similarity, and how the threshold affects the result. The example confusingly uses a non-PNG-looking path ('/Game/MCP_Test/Example') despite the parameter being described as a PNG path, adding some ambiguity.

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 description coverage is 0%, so the description must compensate, and it does: each parameter is explained, including path types and the 0-1 range for pass_threshold. The example adds practical usage context, though it oddly uses the same path for both baseline and candidate.

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?

The description opens with a specific verb and object: 'Compare two workspace-local viewport screenshot artifacts.' This clearly identifies the tool's function and the workspace-local scope, and it inherently distinguishes the tool from siblings like viewport_capture_screenshot.

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?

The description implies when to use the tool through the compare action and the baseline/candidate parameters, but it does not explicitly say when to prefer it over alternatives or when not to use it. The example and KB reference provide some context, but no exclusion criteria or alternative routing are given.

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

Deploy Server

Other Tools