agentleFS
yuvrajangadsinghyuvrajangadsingh/brandmd/SKILL.md

brandmd

Skill66 starsChanged 4 months agoMITView on GitHub

Extract a website's design system into a DESIGN.md file. Use when starting a new frontend project, rebuilding a site, or when the user wants AI-generated UI to match an existing brand.

  • Reads credentials
  • In this repositoryOne other file it gives its agents.

The file

We split this skill into the rules it gives an agent

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

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Read the generated DESIGN.md to confirm it looks right

    line 43
  2. Distinctive:

    Use these tokens in all subsequent UI code generation

    line 45

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “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

brandmd

You extract a website's design system into a DESIGN.md file that AI coding agents use for on-brand UI generation.

When to use

  • User says "match this website's design" or "use the same style as [url]"
  • Starting a new frontend project and the user has an existing site
  • User wants design consistency across AI-generated components
  • User asks to "extract design tokens" or "get the design system" from a URL

How to run

npx brandmd <url> -o DESIGN.md

Pass the most design-rich page (usually the homepage) for best results. The tool extracts from the visible viewport and lazy-loaded content on that single page.

What it extracts

The output follows Google Stitch's DESIGN.md format. Sections 1-5 are always present; 6-7 are conditional on flags.

  1. Visual Theme & Atmosphere - mood, shape language, depth
  2. Color Palette & Roles - colors with semantic roles (background, text, accent, border)
  3. Typography Rules - Primary font (role-aware: display > heading > body, skipping mono/fallback/icon fonts), per-role font breakdown (Headings, Display, Body, Buttons), all detected fonts with frequencies, size scale, weights, line heights, letter spacing
  4. Component Stylings - buttons, cards, inputs with radii, colors, shadows
  5. Layout Principles - spacing scale, base grid unit, border radii
  6. Dark Theme Overrides (with --dark) - palette + atmosphere for dark mode
  7. Visual Identity Beyond CSS (with --vision) - illustration style, photography mood, copywriting voice, microcopy patterns. Requires GEMINI_API_KEY (free tier: aistudio.google.com/apikey).

After extraction

  1. Read the generated DESIGN.md to confirm it looks right
  2. Summarize the key tokens for the user (primary colors, fonts, spacing scale)
  3. Use these tokens in all subsequent UI code generation
  4. Reference specific hex codes, font names, and spacing values from DESIGN.md when writing CSS/Tailwind/styled-components

Options

  • npx brandmd <url> - DESIGN.md to stdout
  • npx brandmd <url> -o DESIGN.md - DESIGN.md to file
  • npx brandmd <url> --dark - also extract dark-mode palette (Section 6)
  • npx brandmd <url> --vision - also extract illustration / photography / voice / microcopy via Gemini (Section 7). Needs GEMINI_API_KEY env var.
  • npx brandmd <url> --css - CSS custom properties output instead of DESIGN.md
  • npx brandmd <url> --tailwind - Tailwind v4 @theme block instead of DESIGN.md
  • npx brandmd <url> --html - HTML brand guide (visual, shareable)
  • npx brandmd <url> --json - raw tokens as JSON (programmatic use)
  • Multiple URLs merge tokens: npx brandmd <url1> <url2> <url3>

Limitations

  • Extracts from a single page, not the entire site (multi-URL merges token frequencies but the vision screenshot is the first page only)
  • Can't read Figma tokens or design tool files
  • Color role assignment is heuristic (based on usage frequency and luminance)
  • Requires a publicly accessible URL (no auth-gated pages)
  • Cloudflare-protected sites: brandmd waits up to 20s for the JS challenge to auto-resolve (--cf-wait-ms to tune). If the challenge persists, you get a clear error rather than garbage tokens. Hard-blocked sites (openai.com, perplexity.ai, discord.com, etc.) are correctly flagged as bot-protected and not bypassed.

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.