Skip to main content

Validate and score CLAUDE.md files — MCP-first AI context governance

Project description

Reporails CLI

Score your CLAUDE.md files. See what's missing. Improve your AI coding setup. Why this exists

Pre-1.0 — moving fast, API still evolving, feedback welcome.

Quick Start

One-line setup

# pip / uvx
ails setup

# or via npm (no Python install needed)
npx @reporails/cli setup

This detects agents in your project and writes the MCP config. Restart your editor, then run ails check.

CLI path (only deterministic rules)

# No install needed — run directly
uvx reporails-cli check
# or
npx @reporails/cli check

That's it. You'll get a score, capability level, and actionable violations.

╔══════════════════════════════════════════════════════════════╗
║   SCORE: 8.1 / 10 (partial)  |  CAPABILITY: Maintained (L5)    ║
║   ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░░░░░░░░░░░         ║
╚══════════════════════════════════════════════════════════════╝

Violations:
  CLAUDE.md (7 issues)
    ○ :1    No NEVER or AVOID statements found       RRAILS:C:0003
    · :1    No version or date marker found           CORE:C:0012
    ...

Fix the issues, run again, watch your score and your experience improve.

Install

pip install reporails-cli
# or
npm install -g @reporails/cli

This adds ails to your PATH. All commands below assume a global install.

Try without installing:

uvx reporails-cli check
# or
npx @reporails/cli check

What It Checks

  • Structure — File organization, size limits
  • Content — Clarity, completeness, anti-patterns
  • Efficiency — Token usage, context management
  • Maintenance — Versioning, review processes
  • Governance — Ownership, security policies

Capability Levels

Capability levels describe what your AI instruction setup enables — not how "mature" it is. Different projects need different capabilities.

Level Name What It Enables
L0 Absent No instruction file — nothing to evaluate
L1 Basic Reviewed, tracked instruction file
L2 Scoped Project-specific constraints, size control
L3 Structured External references, multiple files
L4 Abstracted Path-scoped rules, context-aware loading
L5 Maintained Structural integrity, governance, navigation
L6 Adaptive Dynamic context, extensibility, persistence

GitHub Actions

Add ails check as a CI gate with inline PR annotations:

# .github/workflows/reporails.yml
name: Reporails
on:
  pull_request:
    paths: ['CLAUDE.md', '.claude/**']
jobs:
  check:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: reporails/cli/action@v1
        with:
          min-score: '6.0'

Violations appear as inline annotations on the PR diff. The step summary shows score, level, and a violations table.

Action inputs:

Input Default Description
path . Path to validate
strict false Fail on any violation
min-score Minimum score threshold (0-10)
agent claude Agent type
experimental false Include experimental rules
version CLI version to install (default: latest)

Action outputs: score, level, violations, result (full JSON).

You can also use --format github directly in custom workflows:

ails check . --format github --strict

This emits ::error/::warning workflow commands for each violation, plus a JSON summary line.

Commands

ails setup                      # Set up MCP server for detected agents
ails check                      # Score your setup
ails check -f json              # JSON output (for CI)
ails check -f github            # GitHub Actions annotations
ails check --strict             # Exit 1 if violations (for CI)
ails check --no-update-check    # Skip pre-run update prompt
ails check --exclude-dir vendor # Exclude directory from scanning
ails check -v                   # Verbose: per-file PASS/FAIL with rule titles
ails heal                       # Interactive auto-fix + semantic evaluation
ails heal --non-interactive     # JSON output for agents and scripts
ails explain CORE:S:0001        # Explain a rule
ails map                        # Show project structure
ails map --save                 # Generate backbone.yml
ails update                     # Update rules framework + recommended
ails update --check             # Check for updates without installing
ails update --recommended       # Update recommended rules only
ails update --force             # Force reinstall even if current
ails update --cli               # Upgrade the CLI package itself
ails dismiss CORE:C:0001        # Dismiss a semantic finding
ails judge . "RULE:FILE:pass:reason"  # Cache semantic verdicts
ails version                    # Show version info

Updating

ails update              # Update rules framework + recommended to latest
ails update --check      # Check for updates without installing
ails update --recommended  # Update recommended rules only
ails update --force      # Force reinstall even if current
ails update --cli        # Upgrade the CLI package itself

Before each scan, the CLI checks for available updates and prompts to install. Use --no-update-check to skip.

Ephemeral runners (uvx, npx) always use the latest CLI version automatically.

Recommended Rules

Recommended rules (AILS_ namespace) are included by default and auto-downloaded on first run. To opt out, add to your .reporails/config.yml:

recommended: false

To update recommended rules independently:

ails update --recommended

Prerequisites

Depends on your install path:

  • uvx/pip path: uv — no separate Python install needed
  • npx/npm path: Node.js >= 18 — uv is auto-installed if missing
  • MCP setup: No dependencies — ails setup writes config files directly

Rules

Core rules are maintained at reporails/rules. Recommended rules at reporails/recommended.

Want to add or improve rules? Please follow Contribute guide in the Core repo.

License

BUSL 1.1

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

reporails_cli-0.3.0.tar.gz (231.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

reporails_cli-0.3.0-py3-none-any.whl (124.9 kB view details)

Uploaded Python 3

File details

Details for the file reporails_cli-0.3.0.tar.gz.

File metadata

  • Download URL: reporails_cli-0.3.0.tar.gz
  • Upload date:
  • Size: 231.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for reporails_cli-0.3.0.tar.gz
Algorithm Hash digest
SHA256 d04faf61f069e5f5c9ebec203d39baf3b0cff46cf5e8016283eecce15acd0432
MD5 5419705ba77aa3a7c611b1e54291456e
BLAKE2b-256 e083c20288c41347bc72cbdbac8046342d12ad71626bded92db799f53bc2580a

See more details on using hashes here.

Provenance

The following attestation bundles were made for reporails_cli-0.3.0.tar.gz:

Publisher: release.yml on reporails/cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file reporails_cli-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: reporails_cli-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 124.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for reporails_cli-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9daf66484545f04f9a5135e25140ed7133f02d2376bd5bdb8ed1ba2ab7b5f361
MD5 61aaea829ebecae504d6285fe1b25569
BLAKE2b-256 5f73473038251ed10779953f35cd6d95fb7b189d3702c47617870d46aa577342

See more details on using hashes here.

Provenance

The following attestation bundles were made for reporails_cli-0.3.0-py3-none-any.whl:

Publisher: release.yml on reporails/cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page