Use case
A senior reviewer on every pull request.
Run Anatoly inside GitHub Actions or GitLab CI. Structured exit codes gate the merge, the full Markdown report uploads as an artifact, and a summary lands as a PR comment — same audit pipeline as local, headless.
Designed to run headless
Anatoly's CLI is non-interactive by default. The --plain flag drops colors and spinners for clean log output, the run is reproducible from a checkout, and the process exits with a code your pipeline can branch on.
0— audit completed, no significant findings. Pass the build.1— audit completed, findings detected. Fail the build, or set the job tocontinue-on-errorand post a comment instead.2— runtime error (config, API failure, rate-limit). Investigate and retry.
Drop-in GitHub Actions workflow
name: Anatoly audit on: pull_request: branches: [main] paths: - 'src/**/*.ts' - 'src/**/*.tsx' jobs: audit: runs-on: ubuntu-latest timeout-minutes: 30 steps: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: node-version: '22' cache: 'npm' - run: npm ci - name: Run Anatoly run: npx anatoly run --plain env: ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} - name: Upload report if: always() uses: actions/upload-artifact@v4 with: name: anatoly-report path: .anatoly/runs/*/report.md
Set ANTHROPIC_API_KEY as a repository secret and you're live. The report is uploaded as a build artifact if: always(), so you can inspect findings even when the job exits non-zero.
What the build log looks like
[anatoly] scanning · 312 files · TS · TSX [anatoly] axes · 7/7 · estimated $14.20 [anatoly] deliberation · 47 raw → 28 confirmed [anatoly] verdict: NEEDS_REFACTOR · 28 findings [anatoly] report: .anatoly/runs/2026-05-05_134210/report.md Error: Process completed with exit code 1.
Post the report as a PR comment
Add a second job step that reads the Markdown report and pushes it as a comment on the pull request — reviewers see findings without leaving the GitHub UI.
- name: Post findings if: failure() uses: actions/github-script@v7 with: script: | const fs = require('fs'); const report = fs.readFileSync( '.anatoly/report.md', 'utf-8'); constbody = report.length > 60000 ? report.slice(0, 60000) + '\\n... (truncated)' : report; await github.rest.issues.createComment({ owner: context.repo.owner, repo: context.repo.repo, issue_number: context.issue.number, body: `## Anatoly audit\\n\\n$${body}`, });
Cost control on every run
The CI budget question matters: a naive setup re-audits the whole repo on every PR. Anatoly avoids that two ways.
- SHA-256 incremental cache — unchanged files cost $0. Cache the
.anatoly/directory between runs (withactions/cache) and only the diff is re-audited. --no-rag— skips the RAG index rebuild. Faster CI runs at the cost of weaker duplication detection. Use it for fast-feedback PR audits, keep the full run on main.--file <path>— review a single file. Useful when you wire CI to only audit files in the PR diff viagit diff --name-only.
Other CI providers
Any pipeline that can run npx works the same way — the contract is just exit codes and a Markdown report on disk. GitLab CI, CircleCI, Jenkins, Buildkite: same recipe, different YAML.
Who this fits
- Engineering teams shipping daily — who want a senior-engineer-grade review on every PR without booking a human reviewer per change.
- Open-source maintainers — fielding AI-generated PRs from contributors and needing a second opinion before merging.
- Platform teams — owning a monorepo where quality gates need to be uniform, scriptable, and auditable in CI logs.
Other use cases
Lovable · Cursor · v0 · Bolt
Vibe-coded site audit
Audit codebases shipped by Lovable, Cursor, v0, Bolt or Windsurf. Surface the duplicates, dead code and silent bugs they leave behind.
Subscription · daily
Claude Code audit
Pay nothing per token. Anatoly runs through your Claude.ai subscription, with an Opus deliberation pass on every audit.
Air-gapped · regulated
Local LLM code audit
Run the full audit on a model you host. With local RAG, no source byte ever leaves your network — works with Ollama, LM Studio, vLLM.
NDA · M&A · litigation
Tech due diligence
Reports that survive counter-expertise. Every finding pinned to file, line, and evidence — for M&A, expert witness, compliance.