agentleFS
dmlguq456dmlguq456/hearting/skills/design-tokens/SKILL.md

design-tokens

Skill8 starsChanged 2 months agoMITView on GitHub

Use only when autopilot-design dispatches design-token definition or revision. Not for top-level user requests or primary capability routing.

21 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use brief-to-tasks, information-architecture and 5 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • julianoczkowskiSkill

    brief-to-tasks

    Break a design brief into an ordered checklist of independently buildable tasks using vertical slices. Saves as a markdown checklist. Use when user wants to break down work, create tasks from a brief, plan implementation order, or mentions "tasks" or "breakdown".

    Also in 4 projects that use this

  • fefogarciaSkill

    information-architecture

    Use when organizing content for digital products, designing navigation systems, restructuring information hierarchies, improving findability, creating taxonomies or metadata schemas, or when users mention information architecture, IA, sitemap, navigation design, content structure, card sorting, tree testing, taxonomy, findability, or need help making information discoverable and usable.

    Also in 5 projects that use this

  • julianoczkowskiSkill

    design-flow

    Run the full design-to-build workflow as a guided sequence. Orchestrates all designer skills in order, from grilling through review. Use when user wants to go through the complete design process, start a project from scratch, run the full flow, or mentions "design flow" or "full workflow".

    Also in 3 projects that use this

  • nandanosqlSkill

    design-brief

    Create a design brief that clearly communicates the product context, user needs, constraints, and success criteria to the design team — bridging PM requirements and design execution.

    Also in 4 projects that use this

  • AnthropicSkill

    design-system

    Audit, document, or extend your design system. Use when checking for naming inconsistencies or hardcoded values across components, writing documentation for a component's variants, states, and accessibility notes, or designing a new pattern that fits the existing system.

    Also in 3 projects that use this

  • AWSSkill

    grill-me

    A relentless interview to sharpen a plan or design.

    Also in 4 projects that use this

The file

We split this skill into the rules it gives an agent

8 rules. 0 are common, 2 are distinctive, and 6 are very specific to this project.

  • 0

    Common

    Most of the 19 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 6

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Follow an explicit artifact or audience language when provided.

    line 20
  2. Very specific:

    Read 00_init/asset_inventory.md and locate existing tokens.css, tailwind.config.ts, app/globals.css, or equivalent project-owned token …

    line 27
  3. Very specific:

    Keep only rationale and visual evidence under 02_tokens/: tokens.md and the specimen.

    line 33
  4. Very specific:

    Write 02_tokens/tokens.md with Color Palette (Brand, Neutral, Semantic), Typography (family and scale), Spacing, Radius, Shadow, and Motion.

    line 48
  5. Very specific:

    Before components consume the tokens, create the self-contained 02_tokens/specimen.html with inline <style> and no build dependency:

    line 52
  6. Very specific:

    Write or extend CSS variables in tokens.css, @theme in app/globals.css, or tailwind.config.ts according to the actual stack and selected …

    line 64
  7. Distinctive:

    Before a major overwrite or extension when a prior token system exists:

    line 68
  8. Distinctive:

    Ask the user only when a genuine token conflict requires a design choice.

    line 73

“Common” is measured: kept by at least 6 in 10 of the 19 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

design-tokens

Language Rule

Follow an explicit artifact or audience language when provided. Otherwise, write rationale, specimen labels, and user-facing reports in the conversation language according to <agent-home>/roles/response-policy.md. Preserve canonical token names, values, CSS identifiers, paths, and native tool IDs.

Resolve and Check State

Find design_state.yaml under $AGENT_ARTIFACT_OUTPUT_DIR/designs/<name>/ or $AGENT_ARTIFACT_OUTPUT_DIR/spec/design/.

  • Require phases.refs: done; do not invent tokens without a brief.
  • Read 00_init/asset_inventory.md and locate existing tokens.css, tailwind.config.ts, app/globals.css, or equivalent project-owned token files.

Single Token Contract

The canonical token source is the file the application actually imports: one of <project_root>/app/globals.css with @theme, styles/tokens.css, tailwind.config.ts, or the stack-equivalent source. The design workflow owns edits to that file; code workflows consume it.

Keep only rationale and visual evidence under 02_tokens/: tokens.md and the specimen. Do not create a second competing token-value source. Set design_state.tokens_path to the actual application file.

Seed from the codebase before designing. Extract colors, fonts, spacing, radii, and repeated inline hex or pixel values from the real token file and components. Promote the current implementation into an explicit contract, then refine it; do not start from a blank palette when a working system exists.

  • Existing canonical tokens: extend by default, preserving keys and adding values directly to the application file.
  • Explicit redesign: snapshot the current system under _internal/versions/v{N}/ before replacement.

Procedure

Step 1: Read the Brief

Extract color direction, typography direction, tone, mood, audience, accessibility, and compatibility requirements from 01_refs/brief.md.

Step 2: Record Design Decisions

Write 02_tokens/tokens.md with Color Palette (Brand, Neutral, Semantic), Typography (family and scale), Spacing, Radius, Shadow, and Motion. Record each value and one concise rationale. See references/tokens-exemplar.md for the complete exemplar.

Step 3: Render the Token Specimen

Before components consume the tokens, create the self-contained 02_tokens/specimen.html with inline <style> and no build dependency:

  • color swatches with hex values and foreground/background WCAG contrast ratios; label body text at least 4.5:1 and large text at least 3:1
  • the complete xs through 2xl type scale with line heights
  • visual rulers or boxes for spacing, radius, and shadow steps

Render the specimen, inspect the resulting image, critique contrast, harmony, collisions, and uneven scale jumps, adjust tokens, and rerender until clean. Use the active adapter's equivalent of preview → screenshot → view_image under the visual self-verification loop. When the native design MCP owns the run, preserve mcp__design__eval_js for getComputedStyle evidence.

This specimen-consume gate is mandatory: components may consume the tokens only after rendered verification succeeds.

Step 4: Write the Canonical Token File

Write or extend CSS variables in tokens.css, @theme in app/globals.css, or tailwind.config.ts according to the actual stack and selected single source. Use references/templates.md. Apply project-file changes only after the applicable confirmation.

Step 5: Snapshot and Version Changes

Before a major overwrite or extension when a prior token system exists:

  1. Copy the previous 02_tokens/tokens.md and canonical token file into _internal/versions/v{N}/, where N is one more than the current maximum.
  2. Extend while preserving keys, or replace only for an explicitly selected redesign.
  3. Append a narrative to design_summary.md with changed tokens, old → new values, rationale, and date. This is the only design-cycle change-history source; do not add a separate CHANGELOG.
  4. Ask the user only when a genuine token conflict requires a design choice.

Classify one or two small token adjustments as minor: skip the snapshot and append to the design_summary.md minor log. Treat a palette or scale redesign or a new axis as major. After at least five accumulated minor changes, recommend /audit without running it automatically.

Step 6: Update State

Preserve these fields in design_state.yaml:

phases:
  tokens: done
tokens_path: <actual application token file>
tokens_version: v{N}
tokens_updated: <date>
specimen: 02_tokens/specimen.html
tokens_verified_visually: true

tokens_version and tokens_updated are the reverse-drift anchors consumed by autopilot-code.

Output

  • 02_tokens/tokens.md
  • 02_tokens/specimen.html
  • the canonical project token file, such as tokens.css, app/globals.css, or tailwind.config.ts
  • _internal/versions/v{N}/ for a major change
  • design_summary.md

Return Format

<design_path>/02_tokens/ -- ✅ tokens decided (N colors, K type scale, M spacing)

For an extension:

<design_path>/02_tokens/ -- ✅ tokens extended (+K new tokens, existing preserved)

The acting agent may retain durable token preferences when they are genuinely useful. Do not make memory writes a completion requirement; the canonical application file and explicit project requirements remain authoritative.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.