feat: Update to 'gpt-4.0-turbo' version #16
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test Action | |
on: | |
pull_request: | |
branches: ["main"] | |
jobs: | |
chatgpt-pr-reviewer: | |
runs-on: ubuntu-latest | |
name: Use ChatGPT for PR review | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Review PR diff | |
id: chatgpt_pr_reviewer | |
uses: ./ # Uses an action in the root directory | |
# or use a released Github Action | |
# uses: osl-incubator/[email protected] | |
with: | |
openai_api_key: ${{ secrets.OPENAI_API_KEY }} | |
openai_model: 'gpt-4.0-turbo' | |
openai_temperature: 0.5 | |
openai_max_tokens: 2048 | |
openai_extra_criteria: | # optional, use `;` for separate the criteria items | |
- prefer readable variable name instead of short names like `k` and `v`, when apply; | |
- verify `SOLID` principles design pattern violations, when apply; | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
github_pr_id: ${{ github.event.number }} | |
- name: Print the result | |
run: | | |
echo "${{ steps.chatgpt_pr_reviewer.outputs.chatgpt_result }}" |