Skip to main content

Validate in PR

A focused guide for enforcing preset AI checks in pull requests.

Objective

Catch design-system drift and policy violations before merge.

Baseline checks

Run at least one of:

  • drift detection: preset drift
  • copy and policy checks: preset audit-copy (where applicable)
  • scan and proposal reporting: preset scan (for discovery workflows)
  1. Run checks on every pull request
  2. Emit machine-readable output (json and/or sarif)
  3. Surface findings directly in the PR
  4. Block merge on configured severity thresholds

Example command set

preset drift src --strict --format sarif --output drift.sarif
preset drift src --format json --output drift.json

Optional:

preset audit-copy src --strict --format sarif --output copy.sarif

GitHub-oriented implementation

Use either:

  • the preset AI GitHub Action (see CI integration)
  • direct CLI commands in workflow steps

Minimum expectations:

  • PR comment or annotations with violations
  • upload SARIF when available
  • clear pass/fail signal for branch protection

Suggested policy thresholds

  • Enforce mode repos: fail on any high-severity violation
  • Assist / Guard repos: fail on critical, warn on medium/low
  • Legacy repos: warn-only initial rollout, then tighten

Rollout strategy

  1. Observe: report only
  2. Assist: warn + remediation guidance
  3. Enforce: block merge for policy-breaking drift

Outputs to keep

Store artifacts for traceability:

  • SARIF report
  • JSON report
  • summary metrics (drift score trend, violations by category)

For the full GitHub Action / CLI / SARIF reference, see CI integration.

Was this page helpful?

Last reviewed by @jschuyler
All systems operationalDocsDevelopersPlatformPricing
PrivacyTerms© 2026 fndd, LLC