criterio: Command for Claude Code

.claude/commands/design-check.md

design-check is a command for Claude Code from Carlos-Dominguez-faber/criterio. It costs 23 tokens per session (1,368 once invoked), scanned A, original, MIT.

A project-audit command that runs an anti-slop gate against a project contract and explains each failure in plain language. The contract is stored in brand.json, and the gate is a JavaScript script named gate.mjs.

In plain words
What is it for?
Use it to check a project against its brand contract and review failed checks. It can audit the whole project or a supplied path and tells you to initialize the contract first when brand.json is missing.
Why use it?
It turns technical gate failures into explanations of why they matter and concrete fixes in the project’s code. If no contract exists, it avoids judging the project against personal preferences.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

This is Carlos-Dominguez-faber/criterio's own configuration. It tells Claude Code how to work on criterio itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything criterio configures →

Reuse

Borrowing it

Nothing to install: this file belongs to Carlos-Dominguez-faber/criterio. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/Carlos-Dominguez-faber/criterio/main/.claude/commands/design-check.md
Clone the repo
git clone --depth 1 https://github.com/Carlos-Dominguez-faber/criterio

Made for: Claude Code.

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 design-check

README.md
[![agentmods](https://agentmods.dev/badge/commands/carlos-dominguez-faber/criterio/design-check/github.svg)](https://agentmods.dev/commands/carlos-dominguez-faber/criterio/design-check)
Your own site
<a href="https://agentmods.dev/commands/carlos-dominguez-faber/criterio/design-check"><img src="https://agentmods.dev/badge/commands/carlos-dominguez-faber/criterio/design-check/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for design-check

Your own site · 80×15
<a href="https://agentmods.dev/commands/carlos-dominguez-faber/criterio/design-check"><img src="https://agentmods.dev/badge/commands/carlos-dominguez-faber/criterio/design-check.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 23 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,368 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00023 $0.01368
Opus 5 $0.00012 $0.00684
Sonnet 5 $0.00005 $0.00274
Haiku 4.5 $0.00002 $0.00137

Measured 12d ago against content hash 860936b1500e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

design-check 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 12d 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.

.claude/commands/design-check.md · 123 lines

How it starts

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

/design-check — auditar contra el contrato

Argumento recibido (puede venir vacío): $ARGUMENTS

gate.mjs te dice qué falló. Tu trabajo es decir por qué importa y cómo se arregla, en el código real de este proyecto. Un exit code pegado sin traducir no le enseña nada a nadie.


Paso 1 — Ubica el script y el contrato

Busca scripts/gate.mjs, en este orden:

  • .criterio/scripts/gate.mjs
  • scripts/gate.mjs

Y busca brand.json en la raíz del proyecto.

Si no hay contrato, no audites nada contra nada. Di:

No hay brand.json en este proyecto, así que no hay contrato contra qué medir. Corre /design-init primero — son 8 preguntas.

Y ofrece correrlo. Un auditor sin contrato solo puede juzgar contra su propio gusto, y eso es justo lo que criterio no hace.

Paso 2 — Corre el gate

node <ruta>/scripts/gate.mjs

Si $ARGUMENTS trae una ruta, pásasela al script para acotar la revisión.

Interpretación del exit code:

  • exit 0 — el contrato está limpio
  • exit 1 — hay al menos un check en rojo

Paso 3 — Traduce cada fallo

Para cada check en rojo, escribe cuatro cosas. Nunca más, nunca menos:

  1. Qué falló, en una frase sin jerga.
  2. El valor concreto que lo provocó (el hex, el número, la línea, el archivo).
  3. Por qué la regla existe. Una frase. No moralices.
  4. El fix, aplicable, con el valor exacto que debería ir.

Formato:

✗ anti-slop / hue restringido
  tokens.colors.primary = #6366F1 → hue 239°
  El rango [235, 285] está bloqueado porque es el indigo por default del corpus
  de entrenamiento: sale gratis y no lo eligió nadie.
  Fix: elige un hue fuera del rango. Si tu archetype es Magician y el morado sí
  es una decisión, declara la excepción explícita en anti_slop.

Guía de traducción por familia de check:

Check Cómo explicarlo
hue restringido Es el indigo/morado por default. Excepción legítima solo si el archetype lo justifica y está declarada.
contraste 4.5:1 es el mínimo WCAG AA para texto de cuerpo. Verifica contra el fondo real que le queda encima, no contra el del body.
max_fonts El problema rara vez es el número. Revisa también si alguna se usó en un contexto que su avoid_for[] prohíbe.
max_radius_values Regla numérica: máximo 3. Cuando todo tiene el mismo radio, el radio deja de comunicar jerarquía.
props inseguras animadas width, height, padding, margin, top, left, right, bottom fuerzan reflow en cada frame. El fix casi siempre es transform.
coherencia archetype ↔ ejes El arquetipo restringe, no decora. Un Sage con hype: 4 es incoherente: o cambias el arquetipo o bajas el eje.
color fuera del contrato Suele aparecer en hover, bordes y sombras: donde el agente improvisa cuando el contrato no llega. Añádelo a brand.json o cámbialo por un token existente.

Read the full file on GitHub · 123 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. 12d ago First seen · 123 lines · 23 tokens per session scan A 860936b1500e

Subscribe to this mod's changes

design-check is a command published in the GitHub repository Carlos-Dominguez-faber/criterio (55 stars, last pushed 1mo ago), licensed MIT. It adds 23 tokens to every session and 1,368 once invoked, about $0.0001 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.