dorucioclea/OpenAI-based PR Reviewer & Summarizer
OpenAI-based PR Reviewer and Summarizer
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
- Runtime
- Deprecated runtime
Inputs
| name | description | required | default |
|---|---|---|---|
| debug | Enable debug mode | no | false |
| max_files | Max files to review | no | 30 |
| temperature | Temperature for GPT model | no | 0.0 |
| review_comment_lgtm | Leave comments even if the patch is LGTM | no | false |
| path_filters | The path filters, e.g., "src/**.py", "!dist/**", each line will be considered as one pattern. See also - https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onpushpull_requestpull_request_targetpathspaths-ignore - https://github.com/isaacs/minimatch | no | !dist/** !**/*.pb.go !**/*.lock !**/*.yaml !**/*.yml !**/*.cfg !**/*.ini !**/*.mod !**/*.sum !**/*.json !**/*.mmd !**/*.svg !**/*.png !**/*.dot !**/gen/** !**/vendor/** |
| system_message | System message to be sent to OpenAI | no | You are a very experienced software engineer. You are able to thoroughly review code changes and uncover issues (if there are any) such as logic errors, syntax errors, out of bound errors, potential data races, livelocks, starvation, suspension, order violation, atomicity violation, consistency, complexity, error handling etc. We will be doing code reviews today. |
| summarize_beginning | The prompt for the whole pull request | no | $system_message We will be summarizing a pull request in this session. You will provide with a table containing filename and a short summary (within 30 words) for each file's diff. I have a pull request with title "$title" and the description is as follows, ``` $description ``` Next, I will be providing you diffs for each file for you to summarize. In every response, you will update the high-level summary of the entire pull request, the table for each file's diff summary and any feedback you might want to give to the developer, including compliments or suggestions on how to do better next time. Reply "OK" to confirm that you are ready to receive the diffs for summarization. |
| summarize_file_diff | The prompt for each file diff | no | Summary generated by you for other files, is as follows and you can use this summary as a basis for your response. ``` $summary ``` I am providing diff for `$filename` below. I would like you to summarize the diff and add the summary for this file in the table. In response, please provide the updated high-level summary, the summary table of the files we have summarized so far and your overall feedback to the developer. ```diff $file_diff ``` |
| summarize | The prompt for final summarization response | no | This is the end of summarization session. Below is the summary you have generated so far in our previous conversations. Please use this as a basis for your final response. ``` $summary ``` Please provide the final response as follows in the `markdown` format with the following content: - Thank the user for letting you participate in the code review. - High-level summary (focus on the purpose and intent within 80 words) - Your feedback to the developer (within 50 words) - Table of files and their summaries Do not provide any additional commentary as this summary will be added as a comment on the pull request. |
| summarize_release_notes | The prompt for generating release notes | no | Next, release notes in `markdown` format for this pull request that focuses on the purpose of this PR. If needed, you can classify the changes as "New Feature", "Bug fix", "Documentation", "Refactor", "Style", "Test", "Chore", "Revert" and provide a bullet point list, e.g. "New Feature: An integrations page was added to the UI". Your response should be as concise as possible (50-100 words), without additional commentary as this response will be used as is in our release notes. |
| review_beginning | The beginning prompt of a code review dialog | no | $system_message I will be providing you some files and entire diff to help you build context, in case the content is not too large. Then I will be sending you each patch from the diff for review. I have a pull request with title "$title" and the description is as follows, ``` $description ``` OpenAI generated summary is as follows, ``` $summary ``` Reply "OK" to confirm that you are ready for further instructions. |
| review_file | The prompt for each file | no | Providing `$filename` content as context. Please use this context when reviewing patches. ``` $file_content ``` |
| review_file_diff | The prompt for each file diff | no | Providing entire diff for `$filename` as context. Please use this context when reviewing patches. ```diff $file_diff ``` |
| review_patch_begin | The prompt for each file diff | no | Next, I will send you a series of patches, each of them consists of a diff snippet, and you need to do a brief code review for every patch, and tell me any bug risk or improvement suggestion. If the patch looks good and acceptable, please reply "LGTM!" with a short comment within 30 words. Your responses will be recorded as review comments on the pull request. Markdown format is preferred for your responses. Reply "OK" to confirm. |
| review_patch | The prompt for each chunks/patches | no | $filename ```diff $patch ``` |
Outputs
no outputs