From 9d1b4bdfac20c3fa28315fe34df21b3463c6e4d1 Mon Sep 17 00:00:00 2001 From: Paul Bakaus Date: Wed, 29 Jul 2026 21:35:27 -0700 Subject: [PATCH] Fix five stale rule counts and the validator blind spots that hid them single-font's retirement made the detector 59 rules; both READMEs still said 60 in five places, and the count validator reported clean because 'deterministic detector rules' puts a word the regex never expected between the qualifier and the noun, and README.npm.md was never in the checked file list. The regex now tolerates the detector infix, counts qualified 'issues' claims, and README.npm.md joins the list. Co-Authored-By: Claude Fable 5 --- README.md | 6 +++--- README.npm.md | 4 ++-- scripts/build.js | 7 ++++++- 3 files changed, 11 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index c3dec5a46..7478d452f 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Impeccable -Design guidance for AI coding agents. 1 skill, 23 commands, live browser iteration, and 60 deterministic detector rules for AI-generated frontend design. +Design guidance for AI coding agents. 1 skill, 23 commands, live browser iteration, and 59 deterministic detector rules for AI-generated frontend design. > **Quick start:** From your project root, run `npx impeccable install`, then run `/impeccable init` inside your AI coding tool. Full docs: [impeccable.style](https://impeccable.style). @@ -13,7 +13,7 @@ Every model trained on the same SaaS templates. Skip the guidance and you get th Impeccable adds: - **One setup flow.** `/impeccable init` writes `PRODUCT.md` and offers `DESIGN.md`, so later commands know the audience, brand/product lane, voice, anti-references, colors, type, and components. - **23 commands.** A shared design vocabulary with your AI: `polish`, `audit`, `critique`, `distill`, `animate`, `bolder`, `quieter`, and more. -- **60 deterministic detector rules** plus LLM-only critique checks. The CLI and browser extension run the deterministic rules with no LLM and no API key. +- **59 deterministic detector rules** plus LLM-only critique checks. The CLI and browser extension run the deterministic rules with no LLM and no API key. ## What's Included @@ -377,7 +377,7 @@ npx impeccable ignores add-file "src/legacy/**" npx impeccable ignores add-value overused-font Inter --reason "Brand font" ``` -The detector catches 60 deterministic issues across AI slop (side-tab borders, purple gradients, bounce easing, dark glows) and general design quality (line length, cramped padding, small touch targets, skipped headings, and more). +The detector catches 59 deterministic issues across AI slop (side-tab borders, purple gradients, bounce easing, dark glows) and general design quality (line length, cramped padding, small touch targets, skipped headings, and more). By default, `detect` respects the same `.impeccable/config.json` and `.impeccable/config.local.json` detector config as the design hook: `detector.ignoreRules`, `detector.ignoreFiles`, `detector.ignoreValues`, and `detector.designSystem.enabled`. Hook lifecycle settings such as `hook.enabled` only affect automatic hook execution. diff --git a/README.npm.md b/README.npm.md index 5aa7077e1..ec00a1d2a 100644 --- a/README.npm.md +++ b/README.npm.md @@ -1,6 +1,6 @@ # Impeccable CLI -Detect UI anti-patterns and design quality issues from the command line. Scans HTML, CSS, JSX, TSX, Vue, and Svelte files for 60 deterministic rules, including AI-generated UI tells, accessibility violations, and general design quality problems. +Detect UI anti-patterns and design quality issues from the command line. Scans HTML, CSS, JSX, TSX, Vue, and Svelte files for 59 deterministic rules, including AI-generated UI tells, accessibility violations, and general design quality problems. ## Quick Start @@ -56,7 +56,7 @@ npx impeccable detect --fast src/ **Quality**: tiny body text, cramped padding, long line lengths, small touch targets -60 deterministic detector rules in total. See the full catalog at [impeccable.style/slop](https://impeccable.style/slop). +59 deterministic detector rules in total. See the full catalog at [impeccable.style/slop](https://impeccable.style/slop). ## Exit Codes diff --git a/scripts/build.js b/scripts/build.js index e099eb280..8e66e2121 100644 --- a/scripts/build.js +++ b/scripts/build.js @@ -59,6 +59,7 @@ function generateCounts(rootDir, skills, buildDir) { const filesToCheck = [ 'site/pages/index.astro', 'README.md', + 'README.npm.md', 'AGENTS.md', '.claude-plugin/plugin.json', '.claude-plugin/marketplace.json', @@ -86,9 +87,13 @@ function generateCounts(rootDir, skills, buildDir) { // Check for stale detection counts. Use the changelog-stripped content // so historical counts in changelog entries (e.g. "28 rules" from an // older release) don't flag against the current detector total. - const detectPattern = /\b(\d+)\s+(deterministic\s+)?(checks|patterns|rules|detections)/gi; + // "detector" as an infix ("60 deterministic detector rules") and + // qualified "issues" both evaded the old pattern, which is how five + // stale counts shipped while the validator reported clean. + const detectPattern = /\b(\d+)\s+(deterministic\s+)?(detector\s+)?(checks|patterns|rules|detections|issues)\b/gi; for (const match of strippedContent.matchAll(detectPattern)) { const num = parseInt(match[1]); + if (match[4] === 'issues' && !match[2]) continue; // plain "issues" is prose, not a count claim if (num !== detectionCount && num > 10) { // ignore small numbers like "3 patterns" console.error(` ❌ ${relPath}: found "${match[0]}" but detection count is ${detectionCount}`); errors++;