Skip to content

Commit

Permalink
Update review prompt for concise feedback with code example
Browse files Browse the repository at this point in the history
  • Loading branch information
VassoD committed Jul 23, 2024
1 parent 453b683 commit 738ef20
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions review_script.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ def analyze_code(file_content, previous_comments):

prompt = f"""{HUMAN_PROMPT} As a senior developer, provide a brief, easy-to-read code review for the following changes. Focus on:
1. Key improvements or good practices implemented
2. The most important suggestion for further improvement
2. The most important suggestion for further improvement, with a short code example
Guidelines:
- Be concise. Limit your review to 2-3 short paragraphs.
- Be concise. Limit your review to 3-4 short paragraphs.
- Prioritize the most impactful feedback.
- Avoid repeating suggestions from previous reviews unless they're critical and unaddressed.
Expand All @@ -47,7 +47,8 @@ def analyze_code(file_content, previous_comments):
Provide your review in this format:
1. Positive point(s): [Very brief mention of good changes]
2. Top suggestion: [One key suggestion with a very short explanation]
3. Overall: [One-sentence summary of the code quality]
3. Example: [A brief code snippet illustrating the suggestion]
4. Overall: [One-sentence summary of the code quality]
{AI_PROMPT}"""

Expand Down

0 comments on commit 738ef20

Please sign in to comment.