madhavkishor/OpenAI-based PR Reviewer & Summarizer
OpenAI-based PR Reviewer and Summarizer
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Maintainedlast commit Nov 3, 2025
- License
- MIT
- Runtime
- Deprecated runtime
Pinned Snippet
uses: madhavkishor/openai-pr-reviewer@d7e874900bb555472ffddbfd41648bac4e5b68fa # no releases — HEAD as of 2026-07-11tags can be moved; commit SHAs can't. why a SHA?
Inputs
| name | description | required | default |
|---|---|---|---|
| debug | Enable debug mode | no | false |
| max_files | Max files to review. Less than or equal to 0 means no limit. | no | 60 |
| 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 !**/*.toml !**/*.ini !**/*.mod !**/*.sum !**/*.json !**/*.mmd !**/*.svg !**/*.png !**/*.dot !**/*.md5sum !**/gen/** !**/_gen/** !**/vendor/** |
| openai_model | Model to use | no | gpt-3.5-turbo |
| openai_model_temperature | Temperature for GPT model | no | 0.0 |
| openai_retries | How many times to retry openai API in case of timeouts or errors? | no | 5 |
| openai_timeout_ms | Timeout for openai API call in millis | no | 60000 |
| openai_concurrency_limit | How many concurrent API calls to make to openai servers? | no | 4 |
| system_message | System message to be sent to OpenAI | no | You are `@openai`, a highly experienced software engineer with a strong ability to review code changes thoroughly.You can uncover issues such as logic errors, syntax errors, out of bound errors, potential data races, livelocks, starvation, suspension, order violation, atomicity violation, consistency, complexity, error handling, typos, and more. You will be conducting code reviews today and write code if asked to do so. |
| summarize_beginning | The prompt for the whole pull request | no | $system_message In this session, we will summarize a pull request. The pull request has the title "$title" and the following description: ``` $description ``` Reply "OK" to confirm that you are ready. |
| summarize_file_diff | The prompt for each file diff | no | I am providing diff for `$filename` below. I would like you to summarize the diff within 30 words. ```diff $file_diff ``` |
| summarize | The prompt for final summarization response | no | This is the end of the summarization session. Below is the summary you have generated so far for each file. ``` $summary ``` Please provide your final response 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) - Table of files and their summaries. You can group files with similar changes together into one row to save space. Avoid 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 | Create concise release notes in `markdown` format for this pull request, focusing on its purpose and user story. In needed, you can classify the changes as "New Feature", "Bug fix", "Documentation", "Refactor", "Style", "Test", "Chore", "Revert", and provide a bullet point list. For example: "New Feature: An integrations page was added to the UI". Keep your response within 50-100 words. Avoid 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 provide you with some files and the entire diff to help you build context, unless the content is too large. Then, I will send you each patch from the diff for review. The pull request has the title "$title" and the following description: ``` $description ``` The OpenAI-generated summary is as follows: ``` $summary ``` Reply "OK" to confirm. |
| review_file | The prompt for each file | no | Here is the content of `$filename` for context. Please use this context when reviewing patches. ``` $file_content ``` Reply "LGTM!" if the existing code in this file looks correct. If there are serious issues in the existing code please let me know and I will add your comment on the pull request for this file. |
| review_file_diff | The prompt for each file diff | no | Here is the entire diff for `$filename` for context. Please use this context when reviewing patches. ```diff $file_diff ``` Reply "OK" to confirm. |
| review_patch_begin | The prompt for each file diff | no | Next, I will send you a series of patches. Each patch consists of a diff snippet, and your task is to review every patch. Identify any bug risks or provide improvement suggestions. If the patch looks good and acceptable, please reply "LGTM!" with a short comment. 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 Existing comments on the patch, though some of them may be outdated. Please use them as additional context. ``` $comment_chain ``` Diff for review: ```diff $patch ``` |
| comment_beginning | Prompt for comment | no | $system_message A comment was made on a review for a diff patch on file `$filename`. I would like you to follow the instructions in that comment. If possible, I will provide you the file and the entire diff to help provide overall context for your response. The pull request has the title "$title" and the following description: ``` $description ``` The OpenAI-generated summary is as follows: ``` $summary ``` Reply "OK" to confirm. |
| comment_file | Prompt for file | no | Here is the content of `$filename` for context. ``` $file_content ``` Reply "OK" to confirm. |
| comment_file_diff | Prompt for file diff | no | Here is the entire diff for `$filename` for context. ```diff $file_diff ``` Reply "OK" to confirm. |
| comment | Prompt for comment | no | I would like you to follow the instructions in the new comment made on a conversation chain on a code review diff. Diff being commented on: ```diff $diff ``` The format of the conversation chain is: `user: comment` Conversation chain (including the new comment): ``` $comment_chain ``` Please reply directly to the new comment (instead of suggesting a reply) and your reply will be posted as-is. If the comment contains instructions/request for you, please comply. For example, if the comment is asking you to generate documentation comments on the code, in your reply please generate the required code. In your reply, please make sure to begin the reply by tagging the user with "@user". The comment/request that you need to directly reply to: ``` $comment ``` |
Outputs
no outputs