Skip to main content
Glama

extract_design_tokens

Extract perceptual OKLCH color, dark-mode, 8pt spacing, typography, radius, and glass elevation tokens from UI markup and CSS for consistent design systems.

Instructions

Extract perceptual OKLCH color tokens, synthesized dark-mode counterparts, 8pt grid spacing tokens, typography scales, border radii, and glassmorphism elevations.

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": "extract_design_tokens"
  }
}

Input Schema

NameRequiredDescriptionDefault
cssNo
markupYes
componentNameNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.4/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden, yet it only describes output categories. It says nothing about whether the operation is read-only, what happens with malformed markup, whether optional CSS augments or overrides markup, how long extraction takes, or whether results are deterministic.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single dense sentence with zero padding and the highest-value information (the token categories) front-loaded. However, it spends all its budget enumerating deliverables instead of the invocation-critical facts, so its brevity comes at the cost of usefulness rather than from efficiency.

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

Completeness2/5

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

With no annotations, no output schema, and zero parameter documentation, the description is the agent's only information source and it omits inputs and behavior entirely. For a 3-parameter tool with a required argument, this leaves an agent unable to reliably construct a call.

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

Parameters1/5

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

Three parameters at 0% schema description coverage, and the description never mentions "markup", "css", or "componentName". The critical fact that markup is required while css and componentName are optional, and what componentName is used for, is documented nowhere.

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 ("Extract") and enumerates the exact resource types it produces — OKLCH color tokens, dark-mode counterparts, 8pt spacing, typography scales, radii, glassmorphism elevations. That enumeration implicitly separates it from extract_motion_physics and decompose_layout_skeleton, so an agent can tell what it does without opening the schema.

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 guidance on when to use this versus the sibling extractors, no statement of prerequisites (e.g., that HTML markup is required), and no exclusions. The list of outputs implies a static-analysis use case but the agent must infer it entirely.

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