improve the prompt per reviews suggestion

This commit is contained in:
Ville Saukkonen 2023-04-23 23:08:51 +03:00
parent 6176ca5693
commit a2b67879fe
3 changed files with 3 additions and 3 deletions

2
dist/index.js vendored

@ -119,7 +119,7 @@ function getBaseAndHeadShas(owner, repo, pull_number) {
}); });
} }
function createPrompt(file, chunk, prDetails) { function createPrompt(file, chunk, prDetails) {
return `Your job is to review pull requests. Instructions: return `Your task is to review pull requests. Instructions:
- Provide the response in following JSON format: [{"lineNumber": <line_number>, "reviewComment": "<review comment>"}] - Provide the response in following JSON format: [{"lineNumber": <line_number>, "reviewComment": "<review comment>"}]
- Do not give positive comments or compliments. - Do not give positive comments or compliments.
- Provide comments and suggestions ONLY if there is something to improve, otherwise return an empty array. - Provide comments and suggestions ONLY if there is something to improve, otherwise return an empty array.

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

@ -96,7 +96,7 @@ async function getBaseAndHeadShas(
} }
function createPrompt(file: File, chunk: Chunk, prDetails: PRDetails): string { function createPrompt(file: File, chunk: Chunk, prDetails: PRDetails): string {
return `Your job is to review pull requests. Instructions: return `Your task is to review pull requests. Instructions:
- Provide the response in following JSON format: [{"lineNumber": <line_number>, "reviewComment": "<review comment>"}] - Provide the response in following JSON format: [{"lineNumber": <line_number>, "reviewComment": "<review comment>"}]
- Do not give positive comments or compliments. - Do not give positive comments or compliments.
- Provide comments and suggestions ONLY if there is something to improve, otherwise return an empty array. - Provide comments and suggestions ONLY if there is something to improve, otherwise return an empty array.