Skip to main content
Glama

audit_ui_fidelity

Audit UI markup and CSS for WCAG 2.1 AA/AAA contrast, 44x44px touch targets, reduced-motion guardrails, and layout stability, returning a fidelity score from 0 to 100.

Instructions

Audit WCAG 2.1 AA/AAA contrast ratios, >=44x44px touch targets, prefers-reduced-motion guardrails, CLS stability, and overall UI fidelity score (0-100).

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": {
      "markup": "<markup>"
    },
    "name": "audit_ui_fidelity"
  }
}

Input Schema

NameRequiredDescriptionDefault
cssNo
markupYes
componentNameNo
targetFrameworkNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.8/5.0
Behavior3/5

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

With no annotations supplied, the description carries the full burden. It usefully discloses the distinct check categories and that a numeric 0-100 score is produced, but says nothing about whether it requires rendered markup versus source text, whether it is read-only, or how failures are reported.

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 front-loaded sentence with no filler — every clause names a distinct check. The comma-separated list is dense but readable and wastes nothing.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness1/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool that performs a multi-category accessibility audit, the description omits input format, defaults, output structure, and behavioral expectations. With no annotations, no output schema, and zero parameter documentation, it leaves critical caller decisions unexplained.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

All four parameters (markup, css, componentName, targetFramework) sit at 0% schema description coverage and the description explains none of them. It gives no hint about the expected form of markup, whether css is optional for inline styles, or how targetFramework changes the analysis, so an agent must guess at input format.

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?

Names a specific verb (Audit) and enumerates the concrete checks it performs — WCAG contrast ratios, touch targets, reduced-motion, CLS — plus the 0-100 fidelity score. An agent knows exactly what this tool returns conceptually, though nothing distinguishes it from siblings like extract_design_tokens or capture_ui_reference.

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?

The description is a feature list with no guidance on when to run this audit, when not to, or how it relates to the sibling tools in a UI workflow. An agent must infer that this is a post-build validation step rather than, say, a design-token extractor.

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