Diff Modes
Every review needs to answer one question: what changed? The CLI supports four diff modes, each with a different source of truth.| Mode | Source of diff | Inlines files? | When to use |
|---|---|---|---|
| Working tree (default) | Uncommitted changes in your working directory | Yes | Mid-development, before staging anything. |
Staged (--staged) | git diff --cached | Yes | About to commit — same scope as git commit. |
Branch (--branch <base>) | base..HEAD committed diff | No | Pre-merge review of the whole branch. |
Commit (--commit <sha>) | The diff introduced by a single commit | No | Audit one commit, cherry-pick review. |
Review Modes
Three output styles, same underlying review.- Interactive (default) — a TUI that lists files, expands issues, and applies fixes one at a time with a preview. The natural way to work in a terminal.
- Auto-fix (
--fix) — applies every fixable issue at once, with a single confirmation. Use when you trust the rules and want to batch-apply. - Prompt-only (
--prompt-only) — minimal, structured text designed for AI agents to parse and act on. Pair with--fail-onin an agent loop so the loop exits cleanly when the review is clean.
--format json or --format markdown with any command for non-interactive consumers (CI, scripts, webhooks).
Authentication Modes
Pick one per machine. The CLI auto-detects what’s available.- Trial — no auth. 5 reviews per day. Good for “try it once”.
- Personal login (
kodus auth login) — an individual account. Tokens refresh automatically. - Team key (
kodus auth team-key --key kodus_xxxxx) — one shared key for a team, generated in the dashboard. Recommended for AI agents and anywhere you don’t want interactive logins. - CI/CD token (
kodus auth token) — a long-lived token for pipelines. Generated from a logged-in machine, used viaKODUS_TOKEN.
Kody Rules
A Kody Rule is a structured rule the Kodus reviewer applies during every review, scoped to a repository or global to your team.kodus rules create|update|view. The CLI is useful when you want rules in version control (generate them from a script, check into a repo, re-apply on provisioning).
Repository Settings
Every repository in Kodus has settings that govern how reviews behave: ignored files, base branch patterns, title filters, feature toggles. These live in the Kodus backend and are mirrored anywhere the repo is reviewed (web PRs, CLI reviews, agent loops). From the CLI:kodus config repo and kodus config remote are aliases for the same command group.
Centralized Config
Normally, each repository’s settings live in Kodus. Centralized Config lets a team store those settings in a single source-of-truth git repository — every change becomes a pull request against that repo, giving you review and version history on your review configuration itself. Enable, sync, or inspect state:Decision Memory
Decision Memory is Kodus’s way of persisting the reasoning behind AI agent work — not just the diff, but the “why”. When enabled, Kodus installs hooks in Claude Code, Cursor, or Codex that fire on every turn-complete event and capture structured decisions to:kodus decisions promote) so future work on that module starts with the accumulated context.
Full walk-through: Decision Memory.
Business Validation
Wherekodus review asks “is this code good?”, kodus pr business-validation asks “does this diff actually do what the task said to do?”. You point it at a Linear/Jira/URL-based task and a diff source (working tree, staged, branch, commit) and it checks the implementation against the task’s acceptance criteria.
AI Agent Output (--prompt-only and --agent)
Two related flags, different jobs.
--prompt-only— output is optimized for an AI agent to parse and act on. Only works on commands that produce review-style output (review,pr suggestions).--agent— global flag that enforces deterministic, machine-readable output on any command. Use when a script or agent parses CLI output; combine with--format jsonfor strictness.
--prompt-only. Reach for --agent when you’re orchestrating the CLI from a harness or a tool-calling loop that has strict format expectations.
Next steps
Command Reference
Full command + flag listing.
AI Agents
Build review-fix loops with coding agents.
Decision Memory
Capture and promote agent decisions across branches.
Troubleshooting
Common errors and exit codes.