What it is
Pointing an AI tool at your codebase and having it check the implementation against your design system. It uses both the documented rules (via the zeroheight MCP) and the published package (the actual source of truth for component APIs and tokens, already in your environment). It flags where the code has drifted: hardcoded values that should be tokens, deprecated or off-system components, incorrect props or variants, missing accessibility attributes, components reimplemented locally rather than imported from the package, and naming that doesn’t match conventions.
This is read-only friendly on all sides, so auditing is pure reading and reasoning. The AI reads your code, the docs, and the package, then produces a report. Nothing changes unless you ask it to.
Scope: a full-repo drift audit, a focused audit of one feature before a release, a pre-merge check on a branch or PR, or an ongoing conformance check baked into a developer’s routine. Output is a prioritized list of issues with file/line locations, severity, the rule each violates, and a suggested fix, and, with permission, the applied fixes.
Benefits
For design system leads, this finally answers “how much have we actually drifted?” without a manual, weeks-long spreadsheet exercise. It turns governance from a periodic, dreaded audit into something you can run on demand.
For engineers, it catches off-system code before it ships, when it’s cheap to fix, rather than in a quarterly cleanup. It doubles as a teaching tool: a new engineer learns the system’s conventions by seeing what the audit flags and why.
And for the system’s overall health, it surfaces the gap between documentation and reality. Sometimes the code is wrong, sometimes the docs are stale, but it’s fine. Either way, you learn something actionable.
Pitfalls
- Over-flagging. The AI may flag intentional one-off deviations or context it doesn’t understand. Treat the report as a prioritized starting point, not gospel. It’s still worth having a human triage.
- Docs-vs-package conflicts. If the docs say one thing and the package does another, the AI needs a rule for which is authoritative. Default: the package for technical APIs/tokens, the docs for usage and intent. Put this in the
skills.md. - Scale and cost. A whole-monorepo audit can be slow and token-expensive. Scope the first run to a directory, a feature, or a diff rather than “audit everything.”
- Read-only MCP. It can tell you the docs are out of date, but it can’t fix them. That’s a manual follow-up.
- Auto-fix risk. Letting the AI rewrite many files at once is dangerous without tests and review. Have it propose fixes, then apply incrementally on a branch with CI.
What you'll need
- A zeroheight styleguide with Remote MCP enabled, plus the MCP server URL
- Your design system published package installed in the repo (
@acme/design-system) — ground truth for APIs and tokens - The codebase you want to audit, checked out locally
- An MCP-compatible AI coding tool (see options below)
- The
skills.mdfile (below) at the repo root - Optional: a way to run the audit in CI for ongoing conformance (a script that invokes the agent on changed files)
How to set this up
- Enable Remote MCP in zeroheight and copy the URL.
- Connect the zeroheight MCP to your AI tool’s
mcp.json. Confirm it lists real pages. - Install the DS package (eg.
@acme/design-system) in the repo so the AI can inspect its real exports, prop types, and token definitions. - Open the repo (or the specific area) in the AI tool and drop the
skills.mdat the root. - Scope the first run. Start small: “Audit
src/features/billingfor design system conformance,” not the whole repo. - Prompt (see the sample below).
- Triage the report. For fixes you accept, ask the AI to apply them in small batches to a branch and run your tests/CI.
- Log doc gaps. Where the audit shows the docs are wrong (not the code), record it — updating zeroheight is a separate, manual step.
Try it
Sample prompt
Audit src/features/billing against our design system. Use the zeroheight MCP for usage and naming rules and the installed @acme/design-system package for component APIs and tokens. Report issues grouped by severity with file/line locations and suggested fixes. Don’t change any files yet.
What good looks like
A severity-grouped report (High/Medium/Low) where each issue names the file and line, the rule or source it violates, a concrete suggested fix, and a confidence level with plausible intentional deviations flagged for review rather than asserted as errors.




