Skip to content

Commit 84f113e

Browse files
Add review agent style guidelines to .gemini/styleguide.md (#9805)
Initial attempt at adding guidance for GCAfGH to try cut down on the behavior observed so far that it: - Almost always includes generic praise for the PR, which is unhelpful since the agent has no context for evaluating what PRs we actually want (see [this particularly problematic example](#9795 (review))) - Appears to trust PR descriptions. E.g., recently praising a PR that was missing tests of most of the PR, but had a PR description saying it included extensive testing, as being extremely well tested. This text is based on some iteration with Gemini, under the theory that the AI model has far more exposure to examples of good prompts than I do. 🤷🏻
1 parent eab16dd commit 84f113e

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.gemini/styleguide.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,13 @@ auto-formatter, for each language, as described in
2121
- PR descriptions should include the Pre-Review Checklist from
2222
[the PR template](https://github.com/flutter/packages/blob/main/.github/PULL_REQUEST_TEMPLATE.md),
2323
with all of the steps completed.
24+
25+
## Review Agent Guidelines
26+
27+
When providing a summary, the review agent must adhere to the following principles:
28+
- **Be Objective:** Focus on a neutral, descriptive summary of the changes. Avoid subjective value judgments
29+
like "good," "bad," "positive," or "negative." The goal is to report what the code does, not to evaluate it.
30+
- **Use Code as the Source of Truth:** Base all summaries on the code diff. Do not trust or rephrase the PR
31+
description, which may be outdated or inaccurate. A summary must reflect the actual changes in the code.
32+
- **Be Concise:** Generate summaries that are brief and to the point. Focus on the most significant changes,
33+
and avoid unnecessary details or verbose explanations. This ensures the feedback is easy to scan and understand.

0 commit comments

Comments
 (0)