You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add comprehensive documentation about the GitHub action for automatic
PR reviewer assignment, including its behavior with CODEOWNERS,
module-based assignment, and existing reviewer respect.
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+21-7Lines changed: 21 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -93,13 +93,27 @@ Developer workflow for code contributions is as follows:
93
93
3. Once the code changes are staged on the fork and ready for review, a [Pull Request](https://help.github.com/en/articles/about-pull-requests) (PR) can be [requested](https://help.github.com/en/articles/creating-a-pull-request) to merge the changes from a branch of the fork into a selected branch of upstream. PRs should typically target the `main` branch.
94
94
* Creation of a PR creation kicks off the code review process.
95
95
* At least one TensorRT-LLM engineer will be assigned for the review. When the PR is under review, the label `Pending Review` will be added to the PR.
96
-
* Reviewers are automatically requested based on the modules affected in the PR. Module paths are defined in `.github/module-paths.json` and ownership in `.github/workflows/module-owners.json`.
97
-
* You can test the assignment script locally with the `--dry-run` flag:
Reviewers are automatically assigned to PRs through a GitHub Action that:
100
+
101
+
***Triggers**: Runs automatically when PRs are opened, synchronized, or reopened
102
+
***Module-based assignment**: Maps changed files to modules using `.github/module-paths.json` and assigns reviewers based on module ownership defined in `.github/workflows/module-owners.json`
103
+
***Respects existing assignments**: Won't assign additional reviewers if any reviewers are already assigned (unless forced)
104
+
***Excludes PR author**: Automatically excludes the PR author from reviewer assignments
105
+
***Limits reviewer count**: Randomly samples up to 3 reviewers if more are eligible (configurable via `REVIEWER_LIMIT`)
106
+
***Coexists with CODEOWNERS**: Works alongside GitHub's CODEOWNERS file (`.github/CODEOWNERS`) which enforces mandatory approvals for specific paths (e.g., API stability tests, release branches)
107
+
108
+
The auto-assignment system analyzes all files changed in your PR, maps them to the appropriate code modules, and assigns reviewers from the module owner lists. This ensures domain experts review relevant changes while avoiding over-assignment.
109
+
110
+
**Testing the assignment locally**: You can test reviewer assignment with the `--dry-run` flag:
**Manual assignment**: You can also manually trigger reviewer assignment via GitHub's workflow dispatch with options for dry-run mode and force-assignment.
103
117
* If changes are requested, then the reviewer will add the label `Changes Requested` to the PR.
104
118
* Once changes are approved, CI will be launched to validate the change. When CI passes, the reviewer will merge the PR.
105
119
* If CI reports any failures, it's up to the requester to fix any CI failures before requesting another review.
0 commit comments