Skip to content

Latest commit

 

History

History
46 lines (37 loc) · 2.68 KB

REVIEW.md

File metadata and controls

46 lines (37 loc) · 2.68 KB

Review Tool

The review tool scans the PR code changes, and automatically generates a PR review. It can be invoked manually by commenting on any PR:

/review

For example:

The review tool can also be triggered automatically every time a new PR is opened. See examples for automatic triggers for GitHub App and GitHub Action

Configuration options

Under the section 'pr_reviewer', the configuration file contains options to customize the 'review' tool:

  • require_focused_review: if set to true, the tool will add a section - 'is the PR a focused one'. Default is false.
  • require_score_review: if set to true, the tool will add a section that scores the PR. Default is false.
  • require_tests_review: if set to true, the tool will add a section that checks if the PR contains tests. Default is true.
  • require_security_review: if set to true, the tool will add a section that checks if the PR contains security issues. Default is true.
  • require_estimate_effort_to_review: if set to true, the tool will add a section that estimates thed effort needed to review the PR. Default is true.
  • num_code_suggestions: number of code suggestions provided by the 'review' tool. Default is 4.
  • inline_code_comments: if set to true, the tool will publish the code suggestions as comments on the code diff. Default is false.
  • automatic_review: if set to false, no automatic reviews will be done. Default is true.
  • extra_instructions: Optional extra instructions to the tool. For example: "focus on the changes in the file X. Ignore change in ...".

Incremental Mode

For an incremental review, which only considers changes since the last PR-Agent review, this can be useful when working on the PR in an iterative manner, and you want to focus on the changes since the last review instead of reviewing the entire PR again, the following command can be used:

/improve -i

Note that the incremental mode is only available for GitHub.

PR Reflection

By invoking:

/reflect_and_review

The tool will first ask the author questions about the PR, and will guide the review based on his answers.