-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
432a130
commit dbcac2e
Showing
4 changed files
with
53 additions
and
53 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,34 @@ | ||
# name: Code Review | ||
name: Code Review | ||
|
||
# permissions: | ||
# contents: read | ||
# pull-requests: write | ||
permissions: | ||
contents: read | ||
pull-requests: write | ||
|
||
# on: | ||
# pull_request: | ||
# types: | ||
# - opened | ||
# - synchronize | ||
# - reopened | ||
on: | ||
pull_request: | ||
types: | ||
- opened | ||
- synchronize | ||
- reopened | ||
|
||
# jobs: | ||
# test: | ||
# # if: ${{ contains(github.event.*.labels.*.name, 'gpt review') }} # Optional; to run only when a label is attached | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
# - uses: jaci-nordic/ChatGPT-CodeReview@main | ||
# env: | ||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
# OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} | ||
# # Optional | ||
# LANGUAGE: English | ||
# OPENAI_API_ENDPOINT: https://api.openai.com/v1 | ||
# MODEL: gpt-4o-mini # https://platform.openai.com/docs/models | ||
# PROMPT: "Please check if there are any confusions or irregularities in the following code diff: " | ||
# top_p: 1 # https://platform.openai.com/docs/api-reference/chat/create#chat/create-top_p | ||
# temperature: 1 # https://platform.openai.com/docs/api-reference/chat/create#chat/create-temperature | ||
# max_tokens: 10000 | ||
# MAX_PATCH_LENGTH: 10000 # if the patch/diff length is large than MAX_PATCH_LENGTH, will be ignored and won't review. By default, with no MAX_PATCH_LENGTH set, there is also no limit for the patch/diff length. | ||
# IGNORE_PATTERNS: /node_modules/**/*,*.md # glob pattern or regex pattern to ignore files, separated by comma | ||
# INCLUDE_PATTERNS: "*.*" # glob pattern or regex pattern to include files, separated by comma | ||
jobs: | ||
test: | ||
# if: ${{ contains(github.event.*.labels.*.name, 'gpt review') }} # Optional; to run only when a label is attached | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: jaci-nordic/ChatGPT-CodeReview@main | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} | ||
# Optional | ||
LANGUAGE: English | ||
OPENAI_API_ENDPOINT: https://api.openai.com/v1 | ||
MODEL: gpt-4o-mini # https://platform.openai.com/docs/models | ||
PROMPT: "Please check if there are any confusions or irregularities in the following code diff. Be concise : " | ||
top_p: 1 # https://platform.openai.com/docs/api-reference/chat/create#chat/create-top_p | ||
temperature: 1 # https://platform.openai.com/docs/api-reference/chat/create#chat/create-temperature | ||
max_tokens: 10000 | ||
MAX_PATCH_LENGTH: 10000 # if the patch/diff length is large than MAX_PATCH_LENGTH, will be ignored and won't review. By default, with no MAX_PATCH_LENGTH set, there is also no limit for the patch/diff length. | ||
IGNORE_PATTERNS: /node_modules/**/*,*.md # glob pattern or regex pattern to ignore files, separated by comma | ||
INCLUDE_PATTERNS: "*.*" # glob pattern or regex pattern to include files, separated by comma | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,23 @@ | ||
name: GPT2 | ||
# name: GPT2 | ||
|
||
on: | ||
pull_request: | ||
types: | ||
- opened | ||
- synchronize | ||
# on: | ||
# pull_request: | ||
# types: | ||
# - opened | ||
# - synchronize | ||
|
||
permissions: write-all | ||
jobs: | ||
review: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: GPT2 | ||
uses: actions/checkout@v3 | ||
# permissions: write-all | ||
# jobs: | ||
# review: | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
# - name: GPT2 | ||
# uses: actions/checkout@v3 | ||
|
||
- name: AI Code Reviewer | ||
uses: aidar-freeed/ai-codereviewer@main | ||
with: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # The GITHUB_TOKEN is there by default so you just need to keep it like it is and not necessarily need to add it as secret as it will throw an error. [More Details](https://docs.github.com/en/actions/security-guides/automatic-token-authentication#about-the-github_token-secret) | ||
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} | ||
OPENAI_API_MODEL: "gpt-4o-mini" # Optional: defaults to "gpt-4" | ||
#exclude: "**/*.json, **/*.md" # Optional: exclude patterns separated by commas | ||
# - name: AI Code Reviewer | ||
# uses: aidar-freeed/ai-codereviewer@main | ||
# with: | ||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # The GITHUB_TOKEN is there by default so you just need to keep it like it is and not necessarily need to add it as secret as it will throw an error. [More Details](https://docs.github.com/en/actions/security-guides/automatic-token-authentication#about-the-github_token-secret) | ||
# OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} | ||
# OPENAI_API_MODEL: "gpt-4o-mini" # Optional: defaults to "gpt-4" | ||
# #exclude: "**/*.json, **/*.md" # Optional: exclude patterns separated by commas |
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
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