~ pr-review

FAQ

Frequently asked questions about pr-review.

Do I need an API key?

No. pr-review delegates to your locally installed AI CLI tools (claude, copilot, codex, gemini, agent). Authentication is handled by each provider's own login flow.

What if my AI provider CLI is not installed?

pr-review will show only providers whose CLI binary it can find in your PATH. If none are found, it will display installation instructions and exit.

How does PR number detection work?

pr-review runs `gh pr view --json number --jq .number` against the current branch. If a pull request is open for that branch, the number is used in the output filename. Requires the gh CLI to be installed and authenticated.

What does maxDiffLength do?

If the git diff exceeds the maxDiffLength character limit (default 100,000), the diff is truncated before being sent. This prevents hitting token limits on the AI provider side.

Can I review any two branches, not just my current branch vs main?

Yes. Use --base=<branch> to override the destination branch. The source branch defaults to your current git branch (auto-detected). You can also change it at the interactive prompt.

Where is the report saved?

In the current directory. The filename is pr-<number>-review.md when a PR is detected, otherwise the outputFile value from your config (default: pr-review-review.md).

Can I use pr-review in CI/CD?

Yes. Use flags like --provider, --model, and --base to run non-interactively in your pipeline. Make sure the AI provider CLI is available and authenticated in your CI environment.

Can I change the review prompt?

Currently the prompt is internal to pr-review. The --focus flag adjusts the emphasis. Customizable prompts are planned for a future release.