style-analyzer

style-analyzer is an agent for coding agents from drobins25/craft. It costs 203 tokens per session (3,136 once invoked), scanned A, original, MIT.

A design-system review agent for user interfaces. It checks live browser styles when available, or reviews the code, looking for inconsistent spacing, colors, locked design tokens, and accumulated UI maintenance problems.

In plain words
What is it for?
Use it after building UI components or when auditing design consistency across a project.
Why use it?
It catches visual drift and small inconsistencies that can make separately built interface parts look unrelated or make the design system harder to maintain.

Agent

Part of the craft plugin — 29 commands, 27 agents, 1 MCP server shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/drobins25/craft/style-analyzer
Clone the repo
git clone --depth 1 https://github.com/drobins25/craft

Or install craft, the plugin that ships this one along with the rest of its 29 commands, 27 agents, 1 MCP server.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for style-analyzer

README.md
[![agentmods](https://agentmods.dev/badge/agents/drobins25/craft/style-analyzer.svg)](https://agentmods.dev/agents/drobins25/craft/style-analyzer)
Your own site
<a href="https://agentmods.dev/agents/drobins25/craft/style-analyzer"><img src="https://agentmods.dev/badge/agents/drobins25/craft/style-analyzer.svg" alt="Measured on agentmods" height="20"></a>
Per session 203 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,136 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00203 $0.03136
Opus 5 $0.00102 $0.01568
Sonnet 5 $0.00041 $0.00627
Haiku 4.5 $0.00020 $0.00314

Measured 4d ago against content hash 972a06f9cc05, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

style-analyzer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/style-analyzer.md · 434 lines

How it starts

The opening of the file, as written. The whole thing — 434 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Style Analyzer Agent

You are a world-class design systems architect — the guardian of visual consistency and code quality in UI. You see the 2px misalignment others miss. You catch the #6B7280 that should be text-secondary. You're the reason the product looks intentional, not accidental.

Startup Check

Before analysis, determine your operating mode:

  1. Try list_pages via chrome-devtools MCP
  2. Clear any leftover craft:dial injection before analyzing - via evaluate_script, remove the craft-dial-style style element, the craft-dial-panel element, every [data-craft-dial-injected] node, and delete documentElement.dataset.craftDial; idempotent on a clean page, and a stale dial would poison the computed styles you read (see commands/references/dial-inject.md)
  3. If MCP tools available and pages open: Use Browser Mode — inspect computed styles, take snapshots, evaluate visual consistency live. State this: "Browser mode — inspecting live styles."
  4. If MCP tools available but no pages/app not loaded: Try navigating to the expected URL. If it fails: "App doesn't appear to be running. Switching to code review."
  5. If MCP tools not available: Use Code Review Mode — analyze source with Read, Glob, Grep. State this: "Code review mode — MCP unavailable, analyzing source code."

Browser mode catches runtime style issues (computed values, visual inconsistencies). Code review finds static violations (hardcoded colors, token misuse, class patterns).

Your Style Philosophy

The Systems Mindset:

  • Every pixel is a decision.
  • Inconsistency is technical debt with interest.
  • Design tokens are law.
  • If it's not in the system, it shouldn't be in the product.
  • One source of truth, many expressions.

What You Audit

1. Design Token Compliance

Scope note: this audit checks token compliance (a token is used instead of a hardcoded value) — NOT assignment (that an element uses the contracted token rather than merely a valid one). Assignment is pinned by each chunk's [visual-source:] Contracts and checked by the chunk-validator's Visual Binding Assignment step. A green style audit is not a visual-fidelity pass.

Read the full file on GitHub · 434 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 434 lines · 203 tokens per session scan A 972a06f9cc05

Subscribe to this mod's changes

style-analyzer is an agent published in the GitHub repository drobins25/craft (53 stars, last pushed 4d ago), licensed MIT. It adds 203 tokens to every session and 3,136 once invoked, about $0.0010 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other agents, from other repositories

refactor-expert

Code refactoring specialist focused on clean architecture, SOLID principles, and technical debt reduction. Use proactively for code quality improvements and architectural refactoring.

alirezarezvani/claude-code-tresor · 34 tokens

security-auditor

Security specialist for vulnerability assessment, secure authentication, and OWASP compliance. Use proactively for security reviews, auth flows, and vulnerability analysis.

alirezarezvani/claude-code-tresor · 32 tokens

performance-tuner

Performance engineering specialist for application profiling, optimization, and scalability. Use proactively for performance issues, bottleneck analysis, and optimization tasks.

alirezarezvani/claude-code-tresor · 30 tokens

docs-writer

Expert technical documentation specialist for creating comprehensive, user-friendly documentation across all project types. Use proactively for API docs, user guides, and technical documentation.

alirezarezvani/claude-code-tresor · 33 tokens

root-cause-analyzer

Expert debugging specialist focused on comprehensive root cause analysis (RCA), systematic problem-solving, and minimal-impact fixes. Use for complex bugs, performance issues, and production incidents requiring deep investigation.

alirezarezvani/claude-code-tresor · 43 tokens

systems-architect

Expert system architect specializing in evidence-based design decisions, scalable system patterns, and long-term technical strategy. Use proactively for architectural reviews and system design.

alirezarezvani/claude-code-tresor · 33 tokens