Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ Each example includes a complete workflow file that you can copy to your `.githu
2. **Data Gathering**: Fetches PR metadata, changed files, and diff content from GitHub API
3. **Template Rendering**: Uses Nunjucks templates to create a structured instruction for the AI
4. **AI Processing**: Calls the Augment Agent to analyze the changes and generate a review
5. **PR Update**: The Augment Agent updates the PR description with the generated review content
5. **PR Review Submission**: The Augment Agent submits a single GitHub review containing a brief summary and multiple inline comments anchored to specific lines in the PR diff (including suggestion blocks where appropriate)

Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: to be explicit/consistent with the templates, call these GitHub suggestion blocks.

Suggested change
5. **PR Review Submission**: The Augment Agent submits a single GitHub review containing a brief summary and multiple inline comments anchored to specific lines in the PR diff (including GitHub suggestion blocks where appropriate)

## Custom Guidelines

Expand Down
5 changes: 3 additions & 2 deletions templates/formatting/base.njk
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@

### Code References:
- Use backticks for inline code references (function names, variables, etc.)
- Use code blocks for multi-line code examples
- Include file paths and line numbers when referencing specific code locations
- In inline review comments, prefer GitHub suggestion blocks (```suggestion) for concrete code changes; ensure patches are minimal and accurate
- Do not include code blocks or specific code suggestions in the top-level review summary
Copy link
Contributor

Choose a reason for hiding this comment

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

Minor wording/clarity: consider showing the full fence so readers see the expected form of a suggestion block (open and close). For example: ("```suggestion ... ```")

- Include file paths and line numbers only within inline comments (not in the summary)
- Use proper syntax highlighting when showing code examples

### Links and References:
Expand Down
6 changes: 3 additions & 3 deletions templates/guidelines/base.njk
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@

### Comment Guidelines:
- **HIGH CONFIDENCE ONLY**: Only suggest changes you are highly confident will improve the code
- Be specific and reference exact lines or sections of code
- Provide clear explanations of issues and suggest concrete improvements
- Post one inline comment per distinct issue and location, anchored to the exact file and line in the PR diff
- Provide clear explanations of issues and suggest concrete improvements; when proposing code, use GitHub suggestion blocks in inline comments
- Use a constructive, helpful tone - focus on the code, not the person
- Include examples of better approaches when suggesting changes
- Prioritize critical issues over minor style preferences
- Group related comments together when possible
- Do not group multiple issues into a single comment; if an issue spans multiple locations, post separate inline comments and mention they are related
- **Quality over quantity**: Better to miss some issues than create noise with low-value suggestions

### Review Focus Areas:
Expand Down
7 changes: 4 additions & 3 deletions templates/request/base.njk
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,10 @@ You are conducting a comprehensive code review for PR #{{ pr.number }}. You have

## Action Required:
- Use GitHub's review system to post your feedback directly on the relevant lines of code in the PR
- Suggested changes should be used to make it easier to adopt your suggestions
- **IMPORTANT:** All of your comments should be sent as a single review, not as separate reviews
- Do not post comments outside of the single review
- For any code-specific issue, you MUST post an inline review comment anchored to the exact file and line in the PR diff; when proposing code changes, use GitHub suggestion blocks (```suggestion ... ```)
- The review summary MUST be at most 3 sentences and MUST NOT include code-specific suggestions, code blocks, or file/line references. Do not repeat details from inline comments.
- Submit a single GitHub review containing your inline comments plus the brief summary. Do not create multiple reviews.
Copy link
Contributor

Choose a reason for hiding this comment

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

Tiny consistency tweak to match the phrasing used elsewhere ("top-level review summary").

Suggested change
- Submit a single GitHub review containing your inline comments plus the brief summary. Do not create multiple reviews.
- The top-level review summary MUST be at most 3 sentences and MUST NOT include code-specific suggestions, code blocks, or file/line references. Do not repeat details from inline comments.

- If you cannot find a valid diff anchor for a code-specific suggestion, comment on the closest changed line and clearly reference the exact location; only if no anchor is possible, write one short general comment for that item.
- Never use "REQUEST_CHANGES" or "APPROVE"
- If no line-specific suggestions, post a general comment like "Review completed. No suggestions at this time."
- Only a single review should be created, never multiple reviews
Expand Down