src/orchestrator/skills/validation-gates/SKILL.md
Defines 10 sequential validation gates: secret scanning, lint/test/build checks, blast radius analysis, dependency auditing, browser testing, cache management, regression checks, and smoke tests. Use when running pre-deploy validation or CI checks, CI/CD pipelines, deployment pipeline validation, pre-merge checks, continuous integration, or pull request validation.
npx skillsauth add etylsarin/opencastle validation-gatesInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
| Gate | Name | Runs When |
|------|------|-----------|
| 1 | Secret Scanning | Every delegation |
| 2 | Deterministic Checks | Every delegation |
| 3 | Blast Radius Check | Every delegation |
| 4 | Dependency Audit | When package.json or lockfiles change |
| 5 | Fast Review | Every delegation (with auto-PASS exceptions) |
| 6 | Cache Clearing | Before browser testing |
| 7 | Browser Testing | UI changes |
| 8 | Regression Testing | Every delegation |
| 9 | Panel Review | High-stakes changes only |
| 10 | Final Smoke Test | Feature completion (after all tasks Done) |
Inherits: never-expose-secrets
Scan every diff before any other gate.
Example tool: gitleaks detect --source . --verbosity warn (or CI equivalent) — fail on findings matching secrets rules.
Run for every affected project (resolve exact commands via the codebase-tool skill): lint (with auto-fix), test, build. All must pass with zero errors.
Example (project with npm scripts):
npm run lint && npm test --silent && npm run build
| Metric | Normal | Warning | Escalate | |--------|--------|---------|----------| | Lines changed | ≤200 | 201–500 | >500 | | Files changed | ≤5 | 6–10 | >10 | | Projects affected | ≤1 | 2 | >2 |
Sensitive files (always Warning): **/auth/**, DB migrations, next.config.*, .env*, .github/workflows/**, lockfiles — also triggers Gate 4.
Runs only when
package.json,yarn.lock,package-lock.json,pnpm-lock.yaml, or similar lockfiles are modified.
| Check | Tool / Example Command | Pass Criteria | On Failure |
|-------|-------------------------|---------------|------------|
| Vulnerability | npm audit --audit-level=moderate | No new high/critical | BLOCK — use patched version or alternative |
| Bundle size | npx source-map-explorer dist/*.js or npx bundlesize | Frontend pkgs ≤50KB gzipped (project policy) | SHOULD-FIX; blocking if >200KB |
See REFERENCE.md for the full dependency-audit checklist (license, duplicates, maintenance, and additional checks).
Spawn reviewer sub-agent (load fast-review skill). PASS → proceed; FAIL → re-delegate (max 2); 3× FAIL → Gate 9. Auto-PASS rules: see fast-review skill.
rm -rf node_modules/.cache .next/cache .astro/ dist/
UI changes require Chrome screenshots. Start dev server → verify ACs → responsive breakpoints → capture screenshots. Load browser-testing skill.
{ "tool": "browser-testing/capture_screenshot", "url": "http://localhost:3000", "viewports": ["mobile", "desktop"] }
Additional options: see REFERENCE.md.
npm test -- --runInBand for all affected projectsrg "href=\"/changed-path|import .*from '@/components/changed'").rg "from '@/components/PriceRange'|@my-org/ui-package") and run their tests or quick smoke builds.Load panel-majority-vote skill — spawns 3 isolated reviewers, majority (2/3) wins. Use for: security-sensitive changes, DB migrations, architecture decisions.
runSubagent({ agentName: 'Reviewer', prompt: `Panel review 1/3: ${criteria}` });
Runs once after ALL tasks are Done.
npm run build && npm test && npx playwright test
Full build + test from clean state → E2E browser walkthrough → cross-task integration check → responsive sweep (if UI). On failure: re-delegate the specific failing integration only.
development
Generates test plans, writes unit/integration/E2E test files, identifies coverage gaps, and flags common testing anti-patterns. Use when writing tests, creating test suites, planning test strategies, mocking dependencies, measuring code coverage, or test planning.
development
Provides model routing rules, validates delegation prerequisites, supplies cost tracking templates, and defines dead-letter queue formats for Team Lead orchestration. Load when assigning tasks to agents, choosing model tiers, starting a delegation session, running a multi-agent workflow, delegating work, choosing which model to use, or assigning tasks.
testing
Saves and restores session state including task progress, file changes, and delegation history. Use when saving progress, resuming interrupted work, picking up where you left off, or checkpointing current work.
data-ai
Implements technical SEO: meta tags, JSON-LD structured data, sitemaps, and crawlability fixes. Use when adding schema markup, JSON-LD, robots.txt updates, canonical URLs, Open Graph tags, or improving crawlability.