Add review workflow#13503
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds two GitHub Agentic Workflows to run the existing expert-reviewer agent: automatically on PR open and manually via a /review slash command, with shared configuration factored into a reusable import.
Changes:
- Added shared workflow configuration/prompt content for “expert review” runs.
- Added a
/reviewcommand-triggered workflow and its compiled lockfile. - Added a PR-open-triggered workflow and its compiled lockfile.
Show a summary per file
| File | Description |
|---|---|
.github/workflows/shared/review-shared.md |
Introduces shared imported config/prompt body and attempts to centralize PAT rotation logic. |
.github/workflows/review.agent.md |
Defines the slash-command entrypoint workflow importing the shared config. |
.github/workflows/review.agent.lock.yml |
Compiled workflow for the slash-command review run. |
.github/workflows/review-on-open.agent.md |
Defines the on-open entrypoint workflow importing the shared config. |
.github/workflows/review-on-open.agent.lock.yml |
Compiled workflow for the on-open review run. |
Copilot's findings
- Files reviewed: 5/5 changed files
- Comments generated: 3
Expert Code ReviewThis PR adds CI/CD infrastructure to automatically trigger the existing ✅ No BLOCKING IssuesNo MSBuild behavioral changes. No ChangeWave concerns. No backwards-compatibility risk. ✅ No MAJOR IssuesNo performance, API surface, test coverage, or error message concerns (pure CI infrastructure). MODERATE Observations1. Permission mismatch between source and compiled output Both permissions:
contents: read
pull-requests: readBut the compiled lock files grant 2.
MINOR Observations3. PAT rotation comment — acknowledged temporary workaround The 4. The trigger covers only 5. Lock files are auto-generated (DO NOT EDIT header present) Both SummaryThe change is well-scoped and follows security best practices: all actions are pinned to full commit SHAs, fork PRs are rejected at the compiled activation level, contributor membership is gated to write/maintainer/admin roles, and permissions are minimal. The observations above are informational and do not block merging. ✅ Approved with the minor suggestion to add a comment in
|
JanProvaznik
left a comment
There was a problem hiding this comment.
from description
triggered on PR open
this does not align with (at minimum my) workflow, I think the trigger should be "on PR moved from draft to Ready-for-review"
Adjusted to "on opened (draft PRs already filtered out) or on moved to ready_for_review" |
|
/review |
|
or does it work only if it's in main 😄 ? |
There was a problem hiding this comment.
fork PRs are rejected at the compiled activation level
this also does not align with typical team workflow, but if I get it correctly, that's a fundamental limitation so we may consider changing workflow
or am I missing the point of that comment and it's only about fork-targeting PRs, and upstream-targeting PRs from forks work?
Expert Code Review — PR #13503: Add review workflowSummary: This PR adds two Copilot Agentic Workflow (gh-aw) files that automatically invoke the BLOCKINGNone. MAJORNone. MODERATENone. NITNIT — Severity label mismatch in The shared body instructs the agent to organize findings by severity as Recommendation: Change -3. Post a single review comment summarizing findings, organized by severity (BLOCKING > MAJOR > MODERATE > MINOR).
+3. Post a single review comment summarizing findings, organized by severity (BLOCKING > MAJOR > MODERATE > NIT).Security & Infrastructure observations (informational)The key security properties are all correctly implemented:
The lock files are compiled/generated by the gh-aw framework and should not be edited manually — this is clearly documented in the file headers. Overall: LGTM with one NIT. The NIT is worth fixing for consistency but is not a blocker.
|
|
I suppose it's better than classic copilot code review but still a lot of space to improve. It uses sonnet model and from the logs there is no evidence of spawning subagents. When I run the review workflow locally with opus and use /fleet I'd actually do the subagent review as intended. |
|
Expert Code Review — PR #13503 "Add review workflow"Overall assessment: Well-structured PR that follows the established pattern from No BLOCKING or MAJOR issues found. MODERATE1.
2.
MINOR3.
4.
5.
NIT6.
7. Duplication between the two
Security Summary ✅
VerdictApprove — This PR correctly mounts the pre-existing
|
Expert Code Review — PR #13503: Add review workflow
This PR adds two agentic workflows ( ✅ Security — All checks pass
🟡 MODERATE1. No draft-PR guard in
if: github.event.pull_request.draft == false
if: github.event.issue.pull_request && github.event.issue.draft == false
```
(or document the intentional difference with a comment)
---
### 🟠 MINOR
**2. Model version hardcoded in `review-shared.md` (line 33)**
```
`model: "claude-opus-4.6"`This will need manual updates as the model evolves. Consider a brief comment noting the intention (use the highest-capability model available) so future maintainers know why it's hardcoded rather than using a symbolic alias. 3. Potential for noisy reviews on every non-draft PR open
💬 NITs
SummaryNo blocking or major issues. The PR correctly follows existing PAT rotation patterns, uses minimal permissions, pins action SHAs, and delegates access control to the compiled lock files. The two moderate/minor items above are worth a quick author decision before merging.
|
Motivation
Mount the expert-reviewer agent into PR process - triggered on PR open (for contributors only) and on
/reviewslash command (by contributors only)This PR intends to only mount the pre-existing reviewing logic (not to change it in any way)