Skip to content
This repository was archived by the owner on Mar 6, 2024. It is now read-only.

Commit f9fb692

Browse files
authored
update instructions (#202)
<!-- This is an auto-generated comment: release notes by openai --> ### Summary by OpenAI ## Release Notes - Documentation: Updated instructions for reviewing code changes to improve the quality of code reviews. > "Code reviews made better, > With new format and style. > Reviewers can focus on substance, > And make our code worthwhile." <!-- end of auto-generated comment: release notes by openai -->
1 parent 889ea5e commit f9fb692

File tree

2 files changed

+20
-20
lines changed

2 files changed

+20
-20
lines changed

dist/index.js

Lines changed: 10 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/review.ts

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -388,14 +388,15 @@ Format for changes:
388388
---end_change_section---
389389
...
390390
391-
The above format for changes consists of multiple change sections.
392-
Each change section consists of a new hunk (annotated with line numbers)
393-
and an old hunk. Note that the code in old_hunk does not exist anymore
394-
as it was replaced by the new hunk. The old_hunk is only included for
395-
context. The new hunk is the code that you should review. Optionally,
396-
existing review comment chains are included for additional context.
397-
398391
Important instructions:
392+
- The above format for changes consists of multiple change sections. Each change
393+
section consists of a new hunk (annotated with line numbers), an old hunk and
394+
optionally, existing comment chains. The line number annotation on each line
395+
in the new hunk is of the format \`<line_number><colon><whitespace>\`.
396+
- Note that the code in the old hunk does not exist anymore as it was replaced
397+
by the new hunk. The new hunk is the code that you need to review. Consider
398+
the context provided by the old hunk and associated comment chain when reviewing
399+
the new hunk.
399400
- Your task is to do a line by line review of new hunks and point out
400401
substantive issues in those line number ranges. For each issue you
401402
identify, please provide the exact line number range (inclusive) where
@@ -411,9 +412,8 @@ Important instructions:
411412
<start_line_number> must belong to the same hunk as the
412413
<end_line_number>. The line number range is sufficient to map your
413414
comment to the code changes in GitHub pull request.
414-
- Consider the context provided by the old hunk and associated comment
415-
chain when reviewing the new hunk. Do not summarize the changes in the
416-
review comment and only focus on pointing out substantive issues.
415+
- Do not summarize the changes or repeat back provided code in the review
416+
comments and only focus on pointing out substantive issues.
417417
- Use Markdown format for review comment text.
418418
- Fenced code blocks must be used for new content and replacement
419419
code/text snippets and must not be annotated with line numbers.

0 commit comments

Comments
 (0)