Skip to content

Commit 20a338b

Browse files
authored
fix(ci): align code-review workflow inputs with reusable workflow (#4)
Align .github/workflows/code-review.yml kebab-case input and secret keys with gpustack/.github/.github/workflows/code-review.yml@main. Signed-off-by: thxCode <thxcode0824@gmail.com>
1 parent 8daf7f5 commit 20a338b

1 file changed

Lines changed: 27 additions & 10 deletions

File tree

‎.github/workflows/code-review.yml‎

Lines changed: 27 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,24 @@
1+
# This workflow runs AI code review on pull requests by calling the reusable workflow in
2+
# gpustack/.github. Trigger gating and the concurrency group are owned by that reusable
3+
# workflow now, so this file only owns the "on:" triggers (required because GitHub has no
4+
# way to invoke a workflow_call workflow without a concrete event trigger living here),
5+
# the "permissions:" grant (GITHUB_TOKEN cannot be granted more than this declares), and
6+
# this repository's review configuration: the secrets mapping and the LLM inputs below
7+
# (endpoint/model/thinking/reasoning-effort from org variables).
8+
#
9+
# Aligned with upstream:
10+
# https://github.com/alibaba/open-code-review/blob/main/examples/github_actions/ocr-review.yml
11+
112
name: Code Review
213

314
permissions:
415
contents: read
516
pull-requests: write
617

718
on:
19+
# Use pull_request_target instead of pull_request so that secrets are
20+
# available even for PRs from forks. This is safe because the reusable
21+
# workflow only reads the diff and does not execute any code from the PR.
822
pull_request_target:
923
types: [opened, synchronize, reopened]
1024
issue_comment:
@@ -14,14 +28,17 @@ jobs:
1428
review:
1529
uses: gpustack/.github/.github/workflows/code-review.yml@main
1630
with:
17-
llm_url: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_URL }}"
18-
llm_model: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_MODEL }}"
19-
llm_thinking: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_THINKING }}"
20-
llm_reasoning_effort: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_REASONING_EFFORT }}"
21-
llm_temperature: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_TEMPERATURE }}"
22-
llm_top_p: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_TOP_P }}"
23-
llm_thinking_clear: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_THINKING_CLEAR }}"
31+
# This repository's review backing: the org-level LLM endpoint/model
32+
# (OCR appends /chat/completions to the base URL), thinking mode, and
33+
# reasoning effort.
34+
llm-url: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_URL }}"
35+
llm-model: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_MODEL }}"
36+
llm-thinking: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_THINKING }}"
37+
llm-reasoning-effort: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_REASONING_EFFORT }}"
38+
llm-temperature: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_TEMPERATURE }}"
39+
llm-top-p: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_TOP_P }}"
40+
llm-thinking-clear: "${{ vars.CI_GPUSTACK_CODEREVIEW_LLM_THINKING_CLEAR }}"
2441
secrets:
25-
llm_auth_token: ${{ secrets.CI_GPUSTACK_CODEREVIEW_LLM_AUTH_TOKEN }}
26-
app_id: ${{ secrets.CI_GPUSTACK_CODEREVIEW_APP_ID }}
27-
app_private_key: ${{ secrets.CI_GPUSTACK_CODEREVIEW_APP_PRIVATE_KEY }}
42+
llm-auth-token: ${{ secrets.CI_GPUSTACK_CODEREVIEW_LLM_AUTH_TOKEN }}
43+
app-id: ${{ secrets.CI_GPUSTACK_CODEREVIEW_APP_ID }}
44+
app-private-key: ${{ secrets.CI_GPUSTACK_CODEREVIEW_APP_PRIVATE_KEY }}

0 commit comments

Comments
 (0)