Skip to main content
Glama

Lint token names

lint_naming
Read-onlyIdempotent

Checks proposed design token names against the category.role.variant[.state] grammar, returning violations and a corrected name when derivable. Use before proposing a token.

Instructions

Check proposed token names against the naming grammar category.role.variant[.state]: lowercase kebab segments, known category, intent words instead of CSS properties (inset, not padding), state last, no brand or mode in the name. Returns violations and a corrected name when one can be derived. Call it before proposing a token.

Input Schema

NameRequiredDescriptionDefault
namesYesProposed token names as dot paths, for example ['color.fg.subtle', 'spacing.padding.md']

Output Schema

NameRequiredDescriptionDefault
validYes
resultsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already cover safety (readOnlyHint, idempotentHint, destructiveHint=false), so the bar is lower. The description adds real behavioral value beyond that: it discloses the rule set being enforced and that the result is a violation list plus a derived corrected name 'when one can be derived', which is a meaningful caveat about non-determinism of the output.

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?

Front-loaded with the tool's purpose, then packs the grammar rules densely without filler. The rule enumeration is long but each clause (kebab case, intent words, state last, no brand/mode) carries distinct enforcement information, so nothing is wasted.

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

Completeness5/5

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

An output schema exists, so return values need not be re-explained, and annotations cover the safety profile. Combined with 100% parameter schema coverage, the description supplies everything an agent needs about intent, rules, timing, and result shape.

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?

Only one parameter, and schema description coverage is 100% — the schema already documents 'names' as dot-path strings with examples. The description's grammar text implies what valid input looks like but adds no parameter-specific syntax or formatting detail. Baseline 3 applies when the schema does the heavy lifting.

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 specific verb and resource ('Check proposed token names') and enumerates the exact grammar being enforced (category.role.variant[.state], lowercase kebab, state last, no brand/mode). It does not explicitly name or contrast the other siblings such as audit_css or find_token_for_value, though 'Call it before proposing a token' does implicitly position it against propose_token.

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?

Gives clear timing guidance: 'Call it before proposing a token.' That tells the agent when in the workflow to invoke it. It omits when-not-to-use and doesn't address the other siblings (e.g., when to lint vs. audit_css), so it falls short of a full 5.

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