Skip to content

Code review skill - #54924

Merged
mthalman merged 6 commits into
dotnet:mainfrom
mthalman:dev/mthalman/code-review-skill
Jun 30, 2026
Merged

mthalman merged 6 commits into
dotnet:mainfrom
mthalman:dev/mthalman/code-review-skill

Conversation

@mthalman

Copy link
Copy Markdown
Member

No description provided.

Copilot AI review requested due to automatic review settings June 22, 2026 20:17

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new .github/skills/code-review agent skill document intended to guide problem-focused pull request reviews in dotnet/sdk.

Changes:

  • Introduces a code-review skill with step-by-step workflow (local checkout, context gathering, review, and posting).
  • Adds guidance on change categorization, test/impact analysis, and what to flag vs. avoid flagging.

Comment thread .github/skills/code-review/SKILL.md Resolved
Comment thread .github/skills/code-review/SKILL.md Resolved
@marcpopMSFT
marcpopMSFT requested a review from lbussell June 22, 2026 20:44
Comment thread .github/skills/code-review/SKILL.md Resolved
Comment thread .github/skills/code-review/SKILL.md Resolved

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

Comment thread .github/skills/code-review/SKILL.md Resolved

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

@nagilson

Copy link
Copy Markdown
Member

Thanks for investing in this code review skill. Some fundamental questions:

  1. Does this get picked up by the Copilot review from GitHub? If not, is there a way to do that?

  2. Do you happen to have any demo PR reviews showing the results before and after this skill was introduced? I'm curious how it overall changes the behavior of the PR review. I think there's a lot of useful guidance here though I also tend to find the agents have gotten better over time at doing code review. There's a lot of language to parse here and I've noticed even subtle tweaks can significantly influence the outcome.

I wonder also what influenced the decisions here as many repos are adding their own code review skills such as https://github.com/microsoft/aspire-skills/blob/main/.github/skills/pr-review/SKILL.md.

@mthalman

Copy link
Copy Markdown
Member Author

Thanks for investing in this code review skill. Some fundamental questions:

  1. Does this get picked up by the Copilot review from GitHub? If not, is there a way to do that?

It does. This is done by convention. Copilot review looks for any skill containing code-review in the name and will use that.

  1. Do you happen to have any demo PR reviews showing the results before and after this skill was introduced? I'm curious how it overall changes the behavior of the PR review. I think there's a lot of useful guidance here though I also tend to find the agents have gotten better over time at doing code review. There's a lot of language to parse here and I've noticed even subtle tweaks can significantly influence the outcome.

I've generated a set of real examples:

Each of these is based on a real PR to the sdk repo. The difference is that the base branch I'm targeting contains this skill. I triggered a Copilot review on each of them and analyzed the difference against Copilot's review on the original PR. Those analyses are posted as the last comment of each PR.

I wonder also what influenced the decisions here as many repos are adding their own code review skills such as https://github.com/microsoft/aspire-skills/blob/main/.github/skills/pr-review/SKILL.md.

This is directly based on Aspire's code-review skill. I've templatized their skill and replaced it with content specific to the sdk repo.

@nagilson

nagilson commented Jun 25, 2026 •

Copy link
Copy Markdown
Member

Thanks for investing in this code review skill. Some fundamental questions:

  1. Does this get picked up by the Copilot review from GitHub? If not, is there a way to do that?

It does. This is done by convention. Copilot review looks for any skill containing code-review in the name and will use that.

  1. Do you happen to have any demo PR reviews showing the results before and after this skill was introduced? I'm curious how it overall changes the behavior of the PR review. I think there's a lot of useful guidance here though I also tend to find the agents have gotten better over time at doing code review. There's a lot of language to parse here and I've noticed even subtle tweaks can significantly influence the outcome.

I've generated a set of real examples:

Each of these is based on a real PR to the sdk repo. The difference is that the base branch I'm targeting contains this skill. I triggered a Copilot review on each of them and analyzed the difference against Copilot's review on the original PR. Those analyses are posted as the last comment of each PR.

I wonder also what influenced the decisions here as many repos are adding their own code review skills such as https://github.com/microsoft/aspire-skills/blob/main/.github/skills/pr-review/SKILL.md.

This is directly based on Aspire's code-review skill. I've templatized their skill and replaced it with content specific to the sdk repo.

Thank you so much for this. This was thoughtful and really helpful to compare the results of the skill vs before the skill. I also think this is a helpful pattern we will be able to leverage whenever someone tries to modify the skill going forward to see if it changes anything. (Admittedly llms themselves will also get better but we can still test before and after.)

I appreciate the edge scenario PRs and behavior demonstrations you have there and clearly see the demonstrated value of this skill and understand it better now.

Looking briefly again at the instructions themselves but then approving.

@nagilson nagilson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for taking the time to do this and demonstrate the clear advantages that these instructions provide over the standard review without a skill.

Comment thread .github/skills/code-review/SKILL.md Resolved
Comment thread .github/skills/code-review/SKILL.md Resolved
Comment thread .github/skills/code-review/SKILL.md Resolved
Reword the terse 'would-fail-without-the-fix' shorthand in the Tests area-map row to plain prose for readability.
@mthalman
mthalman requested a review from nagilson June 26, 2026 14:43

@nagilson nagilson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's merge!

@mthalman
mthalman merged commit aaf00e7 into dotnet:main Jun 30, 2026
17 checks passed
@mthalman
mthalman deleted the dev/mthalman/code-review-skill branch June 30, 2026 18:48
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 11.0-preview7 milestone Jul 1, 2026
@mthalman mthalman mentioned this pull request Jul 7, 2026
25 of 39 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants