Automatically routes frontend quality tasks to specialized workflows for creating, editing, debugging, validating, testing, comparing, migrating, or repairing UI, HTML/CSS, accessibility, and visual regression testing via Playwright/VRT.
Ships in vlmkit. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
This is the single automatic entry for vlmkit's focused agent workflows and the reference for its Visual Regression Testing (VRT) and accessibility verification CLI. The user installs this skill once and describes the outcome they want in ordinary language.
Automatically verifies that changes are visually and semantically (a11y) as intended, running a loop to detect and repair regressions.
SKILL.md, not relative to the user's project. Read the selected
workflow's SKILL.md completely before editing or running its gates.markup-assist for ordinary frontend work when there is no
stronger screenshot, behavior, test-generation, comparison, migration, or
benchmark signal.mock-markup, then prove an explicit motion brief with
dynamic-markup.Recorded here, once. The workflows do not repeat it, and
tests/skill-package.test.mjs pins this line to the package's own version so the
two cannot drift. Every workflow is reached through this file, so this is the one
place an agent has already read before it runs a gate.
Read what is installed before the first gate of a task:
npx vlmkit --version # vlmkit/0.28.0 <platform>-<arch> node-v<version>: only the first word is compared
@mizchi/[email protected] and use that.
A workflow that names a verb or a flag the installed CLI does not have fails
with "unknown option", which reads as the user's mistake rather than as a
version skew. Recent releases add gates and probe families that older CLIs
refuse: check story and --probe <families> did not exist two releases ago.Then:
@mizchi/vlmkit dependency when its version is not older
than the one above. Otherwise, detect the existing package manager from its
lockfile and add @mizchi/vlmkit as a development dependency with that
package manager. Do not install a second package manager or add a global CLI.pnpm exec vlmkit, npx vlmkit, or the
equivalent for the detected package manager).vlmkit binary. Use paths inside this bundled skill only for fixtures,
references, or an explicitly requested vlmkit benchmark.Treat this root skill as the selector, not as a requirement to run every workflow. Classify the task, load one primary specialized skill, and add a second only when the task genuinely crosses boundaries.
| Task shape | Primary skill | Capability |
|---|---|---|
| Edited HTML/CSS; no reference design | ./workflows/markup-assist/SKILL.md | Route to the smallest deterministic correctness gate and rerun to green |
| Accessibility of an app whose UI is not the DOM (Flutter web, Android, a native macOS app, a game or WebGPU renderer) | ./workflows/markup-assist/SKILL.md ("The UI is not the DOM") | scan a11y → check a11y tree, contrast read from the frame's pixels; --elements for a renderer that lists what it drew |
| Raw mock, retina export, or screenshot with no reference HTML | ./workflows/mock-markup/SKILL.md | Normalize the image and recreate verified markup |
| Target screenshot or UI Contract IR | ./workflows/auto-markup/SKILL.md | Scaffold and converge page/component composition and decoration |
| Responsive, scroll, interaction, or animation behavior | ./workflows/dynamic-markup/SKILL.md | Extend static convergence with deterministic dynamic gates |
| Natural-language story to browser test | ./workflows/spec-to-playwright/SKILL.md | Generate reproducible Playwright/VRT and heal drift |
| Need markup authoring signals | ./workflows/vrt-markup-synth/SKILL.md | Measure components, tokens, theme parity, and i18n stress |
| Whole screen or feature; needs splitting into components first | ./workflows/markup-decompose/SKILL.md | Decide the component split, route each phase, freeze converged parts as story baselines |
| Repair or restyle ONE component; page diff too noisy | ./workflows/component-vrt/SKILL.md | Mount one story and diff only that component, at component size |
| Compare two current renders | ./workflows/vrt-visual-diff/SKILL.md | Explain pixel, section, viewport, and computed-style deltas |
| Detect regressions across repeated CI runs | ./workflows/vrt-regression-watch/SKILL.md | Persist summaries and fail when most viewports worsen |
| Evaluate a framework/CSS/build migration | ./workflows/vrt-migration-eval/SKILL.md | Judge visual equivalence despite large intentional rewrites |
| Benchmark known CSS repair challenges | ./workflows/vrt-css-fix-loop/SKILL.md | Measure VLM+LLM recovery, not production healing |
| Harden an agent-facing CLI, SDK, or harness | ./workflows/agent-validation-loop/SKILL.md | Turn fresh-agent friction into fixes and tracked evidence |
Explaining or drawing how something works (module maps, D2 diagrams, slide decks) is not this router's: those skills live in mizchi/explainer.
The human-facing catalog, direct install commands, and category rationale are in the vlmkit skill catalog.
Every gate below is deterministic: Playwright + DOM / pixel math, no VLM and no
API key. vlmkit <group> --help lists the rest, vlmkit rules the rules each
gate can tune.
vlmkit check integrity page.html # Broken-page defects at 3 viewports: JS errors, collisions, clipping, overflow, invisible text
vlmkit check copy page.html --manifest copy.txt # Required copy present, exactly (--forbid: copy that must not appear, hidden text included)
vlmkit check layout page.html --contract l.json # A brief's structure per viewport: widths, per-row counts, order
vlmkit check design page.html # Consistency with itself: component styles reused, spacing on its own scale
vlmkit check composition page.html # Proximity, alignment rails, declared heading hierarchy
vlmkit check color page.html # Palette by role; field boundaries and links told apart by colour alone
vlmkit scan style page.html --out snap.json # One page load for design / composition / color (each takes --from snap.json)
vlmkit check tokens|theme|motion page.html # Design-token scale, dark-mode parity, CSS motion
vlmkit check grounding page.html # Can an agent acting on a screenshot hit the right target?
vlmkit check a11y contrast|touch|focus page.html # WCAG AA contrast, target size, focus order / traps
vlmkit check interactions page.html # Keyboard probes → ARIA state transitions
vlmkit stress i18n|media page.html # Long text; forced colours / reduced motion / print / RTL / 200% zoom
vlmkit scan a11y <url|ui.xml> --out a11y.json # Flutter web or Android: the platform's tree + its frame
vlmkit check a11y tree a11y.json # Names, reach, pixel contrast, target size, judged from that tree
vlmkit check responsive page.html # Property-based widths per media-query regime, shrunk to the range, breakpoint and declaration
vlmkit check breakpoints page.html --sweep # B-1 / B / B+1 per breakpoint, widths in between
vlmkit check scroll page.html # Sticky / fixed / snap actually behave
vlmkit check animation page.html # Animations run, settle, respect reduced motion
vlmkit inspect motion page.html --selector .toast # Does the motion look broken? Lost, clipped, covered, snap-back, jump, easing — from the page
vlmkit scan handlers page.html # Clickable divs, pointer-only controls, unfireable drag and drop
vlmkit verify flow page.html --flow flow.json # A scripted flow reaches its post-conditions
vlmkit verify markup attempt.html --target target.png # One verdict + full kickback
vlmkit build page|component target.png attempt.html # Missing / extra / misordered components; converge one crop
vlmkit scan mock [email protected] # Normalize a raw mock to a @1x target
vlmkit check story <story-id>... --gallery <url> # One component, at component size, against its baseline
vlmkit diff html a.html b.html # Two files or URLs across viewports
vlmkit diff png a.png b.png --elements-html page.html # Two screenshots; selector candidates + shift estimates
vlmkit snapshot <url>... # URL → baseline + diff
vlmkit contract introspect|scaffold|validate ... # UI Contract IR
vlmkit heal selector page.html ".broken" # Selector replacement candidates
TYPESAFEAI_API_KEY)A model's typed answers (where, whether shown, which kind), never a gate. Where a
command works without it, nothing asks Jev unless --jev is given; the commands
with no other engine need only the key.
vlmkit diff png a.png b.png --jev # Each changed region named: text / color / position / presence
vlmkit inspect motion page.html --jev --target "the green Saved toast" --selector .toast # + Jev per frame, and the --forbid statements
vlmkit inspect claims page.html --forbid "an error banner" # Yes/no statements about what a screenshot shows
vlmkit inspect locate shot.png "the Save button" # A described element's box and click point, on a screenshot
The rest of this page is for work inside the mizchi/vlmkit repository:
pkf run … tasks and source paths do not exist in a consumer project.
pnpm test # Unit tests (all workspace packages)
pkf run fix-loop -- --fixture page --seed 42 # Single CSS deletion challenge (VLM/LLM recovery)
pkf run css-bench -- --trials 30 # Benchmark (detection rate measurement)
pkf run css-bench-crater -- --fixture page # Crater prescanner backend
pkf run css-bench-all # All fixtures at once
pkf run css-report # Analysis report of accumulated data
pkf run migration-compare -- before.html after.html # 2-file comparison
pkf run migration-reset # Reset CSS comparison (normalize vs others)
pkf run migration-tailwind # Tailwind → vanilla CSS
Breakpoints are auto-discovered from CSS, generating boundary ±1px + random sample viewports.
pkf run vlmkit-demo # Basic VRT demo (kitty graphics)
pkf run vlmkit-demo-fix # Fix loop demo
pkf run vlmkit-demo-multi # Multi-scenario
pkf run vlmkit-demo-multistep # Multi-step
┌─────────────────────────────────────────────┐
│ 1. Create baseline │
│ pkf run vrt-update │
└─────────┬───────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────┐
│ 2. Make code changes │
│ - State intent clearly in commit message │
│ (feat: / fix: / style: / refactor: / │
│ a11y: / deps:) │
└─────────┬───────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────┐
│ 3. pkf run vlmkit │
└─────────┬───────────────────────────────────┘
│
┌────┴────────────────┐
│ │
PASS FAIL/ESCALATE
│ │
▼ ▼
┌──────────┐ ┌─────────────────────┐
│ 4a. │ │ 4b. Identify issue │
│ Done │ │ → Fix code │
│ │ │ → Return to 3 │
└──────────┘ └─────────────────────┘
Change ─→ 3 tracks run in parallel:
Track 1: Diff Intent — git diff + commit message → infer change intent
Track 2: Visual Diff — pixel comparison → heatmap → region classification
Track 3: A11y Diff — a11y tree diff → semantic change detection
→ Cross-Validation (cross-reference all 3):
| Visual | A11y | Intent | → Verdict |
|--------|-------|---------|----------------------|
| None | None | any | APPROVE (no change) |
| Yes | Yes | match | APPROVE (as expected) |
| Yes | Yes | none | ESCALATE (unclear intent) |
| Yes | None | style | APPROVE (visual only) |
| Yes | None | refac | ESCALATE (unintended) |
| None | Yes | a11y | APPROVE (a11y improvement) |
| None | Yes | other | REJECT (semantics broken) |
| any | regr | any | REJECT (a11y regression) |
→ Quality Gate:
- Whiteout detection (blank white screen)
- Error state detection (red warning display)
- Empty content detection
- A11y regression (lost label, removed landmark)
| code | Meaning |
|---|---|
| 0 | PASS — no change, or all approved |
| 1 | FAIL — rejected changes, or quality error |
escalate returns exit 0 but emits warnings.
check animation exits 1 when reduced-motion-ignored is its only suspect, and its status line says so. If
the brief sets no reduced-motion policy, judge the rest with --rule reduced-motion-ignored=off.
Every gate run appends one line to .vlmkit/run-ledger.jsonl in the working directory. The run that creates
it says so; --ledger <path> moves it, and --no-ledger writes nothing. Frames and reports go where
--frames / --out point (default test-results/).
The verification pipeline infers change intent from the commit message. When intent is correctly inferred, expected visual changes are auto-approved.
feat: add dark mode toggle → visual + a11y additions expected
fix: fix mobile layout breakage → only fix target should change
refactor: extract utility functions → no visual/a11y changes expected
style: change button color blue→green → visual change, no a11y change expected
a11y: add labels to form → a11y change, minimal visual change expected
deps: update to React 19 → no visual/a11y changes expected
VRT verify also inspects the A11y tree simultaneously. The following are detected:
label-missing)img-alt-missing)landmark-changed)node-removed)role-changed)If any of these are detected during refactoring, semantics are likely broken.
This repository is a pnpm workspace. See .claude/CLAUDE.md § Package Layout for the authoritative table.
├── skills/vlmkit/SKILL.md ← Public automatic skill entry
├── Taskfile.pkl # Task runner (pkfire: `pkf run <task>`)
├── Spec.pkl / Test.pkl # Specs + smoke gate (pkspec)
├── playwright.config.ts # Playwright config for VRT
├── e2e/ # Screenshot + a11y collection specs
├── fixtures/ # Test fixtures (a11y, migration, wireframe, ...)
├── packages/
│ ├── vlmkit-judge/ # Pure judges (snapshot in, findings out); scene and a11y-tree contracts
│ ├── vlmkit-core/ # Pixel/CSS/DOM/a11y diff engine + shared types, gate plugin runtime
│ ├── vlmkit-capture/ # Playwright / Crater capture, viewport discovery
│ ├── vlmkit-ai/ # VLM/LLM clients, 2-stage reasoning pipeline
│ ├── vlmkit-markup/ # Markup tooling: build/scan component, contract
│ │ # introspect/validate/scaffold, checks, stress,
│ │ # selector-heal (all deterministic, no VLM)
│ ├── vlmkit-plan/ # Spec + UI observations → structured test plan
│ ├── vlmkit-generate/ # Plan → Playwright spec (diagnostics-driven retries)
│ ├── vlmkit-heal/ # Failing-test heal loop (model escalation + budget)
│ ├── vlmkit-mcp/ # MCP server exposing the gates
│ └── vlmkit-animation-eval/ # Frame-sampled animation evaluator shared with `check animation`
├── src/
│ ├── cli/ # `vlmkit` CLI entry + router + commands
│ ├── api/ # Hono HTTP API server
│ ├── vrt/ # snapshot / compare workflows
│ ├── util/ # markup-loop, skill, agent helpers
│ └── experiments/ # migration, css-challenge, detection, benchmarks
└── docs/ # knowledge.md, markup-implementation-flow.md, reports/
| Issue | Solution |
|---|---|
| Font rendering diffs | Adjust pixelmatch threshold (packages/vlmkit-core/src/heatmap.ts) |
| A11y tree is null | Wait for page render completion (adjust waitFor) |
| Everything becomes ESCALATE | Add prefix to commit message (feat:/fix:/style: etc.) |
agents/openai.yaml (opens in a new tab)workflows/component-vrt/assets/_gallery-contract.md (opens in a new tab)workflows/component-vrt/assets/button.story.template.tsx (opens in a new tab)workflows/component-vrt/assets/gallery.host.html (opens in a new tab)workflows/component-vrt/assets/gallery.react.template.tsx (opens in a new tab)workflows/component-vrt/assets/gallery.vanilla.html (opens in a new tab)workflows/component-vrt/assets/gallery.vue.template.ts (opens in a new tab)workflows/component-vrt/assets/playwright.ct.config.template.ts (opens in a new tab)workflows/spec-to-playwright/assets/_generation-rules.md (opens in a new tab)workflows/spec-to-playwright/assets/_helpers.ts (opens in a new tab)workflows/spec-to-playwright/assets/ci.yml (opens in a new tab)workflows/spec-to-playwright/assets/playwright.config.preset.ts (opens in a new tab)workflows/spec-to-playwright/assets/seed.spec.template.ts (opens in a new tab)workflows/spec-to-playwright/assets/update-baselines.yml (opens in a new tab)workflows/spec-to-playwright/assets/vrt-review-ci.yml (opens in a new tab)workflows/spec-to-playwright/assets/vrt-review.mjs (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
/vlmkit:vlmkitfrom vlmkit
npx claudepluginhub mizchi/vlmkit --plugin vlmkitOther plugins' skills for the same job