Skip to main content
Charter is a single-binary, offline-first Go CLI for scoring a repository’s AI-agent readiness.
Every command runs offline. Charter makes no network calls and never sends your code anywhere.

Commands

doctor

Scan a repo, evaluate all rules, and compute an AI-agent-readiness score.

init

Scaffold missing agent context files into a repo with create-missing-only safety.

fix

Preview and apply diff-first auto-repair for supported findings.

report

Generate a shareable, self-contained offline HTML report artifact.

explain

Look up a rule by ID and print its catalog metadata.

suppress

Record a governed suppression entry in .charter-suppress.yml.

version

Print build metadata for the currently installed binary.

Exit Codes

Global Flags

These flags are shared across most commands.
string
Explicit repository root to scan. Defaults to the current working directory.
int
Minimum passing score. Overrides the value set in charter.yaml when provided. Used by doctor for gating; reflected in report output but does not gate the report write.
text | json | markdown | sarif
Output format. Available values depend on the command: doctor supports all four; report supports html, markdown, and json; explain and version support text and json.
string
Write rendered output to a file instead of stdout. Supported by doctor and report.
boolean
Silent on pass; emits one summary line on fail. Applies to doctor text output only — JSON, Markdown, and SARIF still emit the full payload.

Typical Workflows