Request a review
AbstractPost /review on an open GitHub pull request or GitLab merge request. The poller checks who asked, reviews the change once, and posts one comment on the reviewed head. The command line does the same for a change address or a local branch.
Post the comment
Post a new comment containing just /review on an open GitHub pull request or GitLab merge request. The service polls the configured projects every two minutes by default, and accepts new requests from the human accounts you configure.
The result is posted on the reviewed head: one comment, naming the commit it describes. A poll uses zero model tokens. Requests run one at a time, with the existing prompt budget and cache.
What the poller skips
| A comment is skipped when | Because |
|---|---|
| Its author is not one of the project's requesters | Only the accounts you list may spend a model call. |
Its text is not exactly /review | Anything more is an ordinary message. |
| It has been edited | The forge's created and updated timestamps differ. |
| It is older than the project's first activation | Requests from before the project was watched were never queued. |
| Its author is a bot, or it is a forge quick action | A bot must not be able to start a review. |
| It is already queued or already done | The same comment is never reviewed twice. |
Setup takes GitHub or GitLab usernames and stores their numeric account IDs. The poller compares each comment author's ID against that list.
Assay's deskmonitor pr supplies the open change numbers. Batched deskread comments --change calls read their conversations on every cycle, including changes with no new commits.
One at a time, across every project
Requests from all configured projects share one queue. It is drained oldest first, one review at a time, so a long review on one repository delays the next request on another.
The queue lives in a SQLite database on the state volume, with the cache and the request history. Keep the state volume across restarts, and requests posted during downtime on still-open changes are picked up on the next cycle. Queued reviews survive a restart.
A review that was interrupted after it started is not reissued. It needs a fresh /review.
What reaches the pull request
The review runs the same steps as the command line with --change, plus --post. The posted comment has a fixed shape:
- A header naming the provider and the full commit.
- The review's state.
- The model's findings, at most three, each with its path and line.
- Each local check that could not run, and the findings of the checks that did.
- The static checks, with a count for each tool.
- The history advisories, where a history is available.
- Each path that lies outside the review's coverage.
Output and exit codes lists every line the comment can contain. The overview quotes a real one.
With the command line
The local form reviews a branch in a checkout. The forge form reviews a pull request or merge request by address:
cursor-review --repo /path/to/checkout --base main --estimate
cursor-review --repo /path/to/checkout --base main --max-input-tokens 4000
cursor-review --repo /path/to/checkout --change 'org/repo#42' --estimate
cursor-review --repo /path/to/checkout --change 'org/repo#42' --model MODEL
The local form compares the merge base to the committed HEAD, or to an explicit --head. Both commits and their common ancestor must be available locally.
The forge form uses the configured Assay backend for that repository. Both forges use the owner/repo#number address accepted by deskread. GitLab subgroup projects can also use CI mode, independent of deskread's slug syntax. Forge access requires the installed desk tools and their normal role and repository configuration, which the container provides.
Publish a summary
Add --post to the --change command to post the reviewed commit and its findings as a single ordinary comment. Assay handles GitHub and GitLab routing, reviewer custody, repeated identical comments and the current-head check through deskpost comment ... --kind mr --head SHA. A stale head is refused.
Publication requires the configured Assay reviewer role. No write happens by default.
The poller supports /review. The upstream PR-Agent chat commands such as /ask and /improve belong to its comment server, which is a separate entry point from this reviewer. See the upstream guides for GitHub and GitLab. GitLab pipeline jobs alone do not receive comment events.
If nothing happened
Work down this list before changing anything:
- Is the author one of the project's
requester_ids? - Was the comment posted after the project was first activated, and left unedited?
- Is the change still open, and is the comment a fresh one rather than a quick action?
- Is another review ahead of it in the queue? Each poll waits 120 seconds by default, and reviews run one at a time.
- Did the review start and get interrupted? Post
/reviewagain.