Skip to content

Commit fd5f89d

Browse files
authored
[no-ci] Update CONTRIBUTING.md to include instructions about coderabbit (#3189)
* Update CONTRIBUTING.md to include instructions about coderabbit closes #2137 Added the text from CCCL's coderabbit.rst to our CONTRIBUTING.md * Correct information about forks. * Update contributing and move configuring section to its own file * Coderabbit suggestions * Apply ralf's suggestions
1 parent a2fb804 commit fd5f89d

2 files changed

Lines changed: 77 additions & 0 deletions

File tree

‎.github/CODERABBIT.md‎

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<!-- SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved. -->
2+
<!-- SPDX-License-Identifier: Apache-2.0 -->
3+
4+
# CodeRabbit Configuration
5+
6+
This document explains how CodeRabbit is configured for CUDA Python. For review
7+
commands and guidance, see the
8+
[CodeRabbit section of the contributing guide](../CONTRIBUTING.md#coderabbit).
9+
For complete product documentation, see the
10+
[CodeRabbit documentation](https://docs.coderabbit.ai/).
11+
12+
CUDA Python configures CodeRabbit through [`.coderabbit.yaml`](../.coderabbit.yaml)
13+
in the repository root. For pull requests from a branch in the same repository,
14+
the configuration in that branch is used for the review. Pull requests from
15+
forks use the target branch's configuration instead, so changes to
16+
`.coderabbit.yaml` in a fork do not affect that review.
17+
18+
When setting up or updating CodeRabbit:
19+
20+
1. Keep repository-specific settings in `.coderabbit.yaml`.
21+
2. Use `@coderabbitai configuration` on a pull request to inspect the resolved
22+
configuration. This is useful when checking whether CodeRabbit is using the
23+
expected repository settings for that pull request.
24+
3. Use `@coderabbitai generate configuration` to export the resolved
25+
configuration if a new baseline is needed. This is useful when moving
26+
settings into a reviewable repository configuration file.
27+
4. Keep configuration changes small and reviewable.
28+
5. Use `reviews.path_instructions` for path-specific review guidance.
29+
6. Use `knowledge_base.code_guidelines.filePatterns` for CUDA Python guidance
30+
files that CodeRabbit should read as review context.
31+
32+
The CUDA Python configuration should keep comments focused on correctness, API
33+
stability, performance, security, and other high-impact issues. Avoid enabling
34+
features that add noisy generated comments or code by default.

‎CONTRIBUTING.md‎

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@ Thank you for your interest in contributing to CUDA Python! Based on the type of
2828
- [Enabling git symlinks](#enabling-git-symlinks)
2929
- [Type stubs for cuda.core](#type-stubs-for-cudacore)
3030
- [Pre-commit](#pre-commit)
31+
- [CodeRabbit](#coderabbit)
32+
- [Review Guidance](#review-guidance)
33+
- [Pull Request Reviews](#pull-request-reviews)
3134
- [Pixi lockfiles](#pixi-lockfiles)
3235
- [Signing Your Work](#signing-your-work)
3336
- [Code signing](#code-signing)
@@ -235,6 +238,46 @@ between commits, leaving stale headers or out-of-date stubs in the history.
235238
If the hook isn't installed, `pre-commit run` will print a visible warning
236239
reminding you to run `pre-commit install`.
237240

241+
## CodeRabbit
242+
243+
This section explains how to use CodeRabbit for CUDA Python pull request review.
244+
For complete product documentation, see the
245+
[CodeRabbit documentation](https://docs.coderabbit.ai/).
246+
247+
### Review Guidance
248+
249+
We treat CodeRabbit feedback as review assistance, not as a merge requirement by
250+
itself. Maintainers remain responsible for deciding whether comments are
251+
actionable and whether a pull request has adequate tests and CI coverage.
252+
253+
### Pull Request Reviews
254+
255+
Automatic reviews may be disabled or restricted by the repository
256+
configuration. PR authors and maintainers can request a review explicitly by
257+
posting a comment on the pull request:
258+
259+
```text
260+
@coderabbitai review
261+
```
262+
263+
Use a full review when the pull request should be reviewed again from scratch:
264+
265+
```text
266+
@coderabbitai full review
267+
```
268+
269+
Other useful commands:
270+
271+
- `@coderabbitai help` shows the current command reference.
272+
- `@coderabbitai configuration` shows the active configuration.
273+
- `@coderabbitai summary` can be placed in the pull request description as a
274+
placeholder for the generated summary.
275+
- `@coderabbitai pause` and `@coderabbitai resume` pause or resume automatic
276+
review behavior. This is useful when a pull request is still being updated
277+
frequently and should not be reviewed again until it is ready.
278+
- `@coderabbitai ignore` can be placed in the pull request description to
279+
disable automatic reviews.
280+
238281
## Pixi lockfiles
239282

240283
The repository checks in a `pixi.lock` next to each `pixi.toml`. Those lockfiles

0 commit comments

Comments
 (0)