xinbenlv/OpenHands PR Review Action
Uses OpenHands AI to review a GitHub Pull Request by wrapping the generic OpenHands action.
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
Inputs
| name | description | required | default |
|---|---|---|---|
| review_bot_github_token | GitHub token with permissions to read repo content and write PR reviews/comments. Typically \$\{\{ secrets.GITHUB_TOKEN \}\} or a PAT. | yes | — |
| llm_api_key | API key for the LLM service (e.g., Anthropic API key). Typically \$\{\{ secrets.LLM_API_KEY \}\} | yes | — |
| llm_model | The LLM model to use for the review | no | anthropic/claude-3-haiku-20240307 |
| openhands_image | Docker image for the OpenHands AI agent (passed to underlying action) | no | docker.all-hands.dev/all-hands-ai/openhands:0.32 |
| runtime_image | Docker image for the sandbox runtime environment (passed to underlying action) | no | docker.all-hands.dev/all-hands-ai/runtime:0.32-nikolaik |
| log_all_events | Enable detailed logging of all events during task execution | no | true |
| review_prompt | The specific prompt instructing OpenHands how to review the PR. GitHub context like repository and PR number are passed via additional_env. | no | Run in shell `export GITHUB_TOKEN=${{ inputs.review_bot_github_token }}`` You are a coding expert focused on GitHub pull request reviews. Your task is to review the pull request number defined in the GITHUB_PR_NUMBER environment variable, within the repository defined in the GITHUB_REPOSITORY environment variable. The GITHUB_TOKEN environment variable is already set for you with the necessary permissions. Please perform the following: 1. Analyze the code changes in the PR. 2. Identify potential issues such as bugs, style inconsistencies, security vulnerabilities, or performance concerns. 3. Suggest improvements or fixes where necessary. 4. Post an overall summary comment on the PR. 5. If specific code lines require feedback, add line-level comments. 6. If the PR looks good and requires no changes, approve it. Use the available GITHUB_TOKEN and GitHub REST API calls to post comments and approvals directly to the pull request. |
| cli_args | Additional CLI arguments to pass to the OpenHands agent (passed to underlying action) | no | "" |
Outputs
no outputs