Skip to main content
Glama
mattferry

Stitch MCP Server

by mattferry

generate_component_variants

Analyzes a screen to identify a component, then generates multiple visual variants for A/B testing or component libraries.

Instructions

Analyses a screen to identify a target component (button, card, hero, form, navigation) and generates multiple visual variants of it as separate screens. Useful for A/B testing or building component libraries.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
screenIdYesThe source screen ID containing the component.
projectIdYesThe Stitch project ID.
deviceTypeNoTarget device type.DESKTOP
variantCountNoNumber of variants to generate (1-5).
componentTypeYesThe type of component to generate variants for.
variantStylesNoSpecific visual styles for the variants. If omitted, a diverse mix is used.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.7/5.0
Behavior3/5

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

With no annotations provided, the description is the only source of behavioral information. It transparently states that the tool analyzes an existing screen and generates new separate screens, but it does not disclose whether the original screen is modified, whether the variants are persisted or merely returned, or any side effects beyond generation.

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 two sentences with no filler. It front-loads the core action and output, then adds legitimate usage context. Every clause earns its place.

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 tool is moderately complex with six parameters, no output schema, and no annotations. The description covers purpose and use cases, but it omits important invocation context such as whether generated variants are saved to the project, whether the source screen is left untouched, and what the tool returns. The schema covers parameter details, but behavioral/return expectations are incomplete.

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 the schema already documents every parameter. The description adds only a general sense of visual variants and a partial list of component types, which provides minimal additional semantic value beyond the structured fields.

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?

The description uses specific verbs ('Analyses', 'generates'), identifies the resource (a screen and a target component), and states the output (multiple visual variants as separate screens). It is clear, though it does not explicitly differentiate itself from sibling tools like generate_variants or generate_responsive_variant.

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?

The description explicitly states use cases: 'Useful for A/B testing or building component libraries.' This gives clear context for when to invoke the tool, though it does not provide exclusions or mention alternative sibling tools.

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