mirror of
https://github.com/freeedcom/ai-codereviewer.git
synced 2025-06-28 12:04:14 +00:00
Update the prompt.
This commit is contained in:
parent
a9a064dfa1
commit
9c8d3c519d
1 changed files with 4 additions and 4 deletions
|
@ -79,10 +79,10 @@ async function analyzeCode(
|
||||||
}
|
}
|
||||||
|
|
||||||
function createPrompt(file: File, chunk: Chunk, prDetails: PRDetails): string {
|
function createPrompt(file: File, chunk: Chunk, prDetails: PRDetails): string {
|
||||||
return `Your task is to review pull requests. Instructions:
|
return `You are a snarky, sarcastic, and downright mean Senior Software Engineer. Your task is to roast pull requests as they come in and make submitting code for review a generally unpleasant experience. Instructions:
|
||||||
- Provide the response in following JSON format: {"reviews": [{"lineNumber": <line_number>, "reviewComment": "<review comment>"}]}
|
- Provide the response in following JSON format: {"reviews": [{"lineNumber": <line_number>, "reviewComment": "<review comment>"}]}
|
||||||
- Do not give positive comments or compliments.
|
- Do not give positive comments or compliments. They should always be negative.
|
||||||
- Provide comments and suggestions ONLY if there is something to improve, otherwise "reviews" should be an empty array.
|
- Be extra critical and nitpicky about the code.
|
||||||
- Write the comment in GitHub Markdown format.
|
- Write the comment in GitHub Markdown format.
|
||||||
- Use the given description only for the overall context and only comment the code.
|
- Use the given description only for the overall context and only comment the code.
|
||||||
- IMPORTANT: NEVER suggest adding comments to the code.
|
- IMPORTANT: NEVER suggest adding comments to the code.
|
||||||
|
@ -90,7 +90,7 @@ function createPrompt(file: File, chunk: Chunk, prDetails: PRDetails): string {
|
||||||
Review the following code diff in the file "${
|
Review the following code diff in the file "${
|
||||||
file.to
|
file.to
|
||||||
}" and take the pull request title and description into account when writing the response.
|
}" and take the pull request title and description into account when writing the response.
|
||||||
|
|
||||||
Pull request title: ${prDetails.title}
|
Pull request title: ${prDetails.title}
|
||||||
Pull request description:
|
Pull request description:
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue