Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/qwen-issue-followup-bot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -367,6 +367,9 @@ jobs:
- `<!-- qwen-issue-bot:invalid -->`
- `<!-- qwen-issue-bot:needs-info -->`
- `<!-- qwen-issue-bot:related -->`
- `<!-- qwen-issue-bot:welcome-pr -->`
- `<!-- qwen-maintain:welcome-pr -->`
- `<!-- qwen-maintain:pr-intake -->`
- Do not assign issues to people in this phase.
- Do not close issues in this workflow version.
- Add labels only. Do not remove any labels, including
Expand Down
94 changes: 94 additions & 0 deletions .github/workflows/qwen-triage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
name: 'Qwen Triage'

on:
issues:
types: ['opened']
pull_request_target:
types: ['opened']
issue_comment:
types: ['created']
workflow_dispatch:
inputs:
number:
description: 'Issue or PR number to triage'
required: true
type: 'number'

concurrency:
group: '${{ github.workflow }}-${{ github.event.issue.number || github.event.pull_request.number || github.event.inputs.number }}'
cancel-in-progress: true

permissions:
contents: 'read'
issues: 'write'
pull-requests: 'write'
actions: 'write'
Comment thread
yiliang114 marked this conversation as resolved.

jobs:
triage:
timeout-minutes: 10
runs-on: 'ubuntu-latest'
if: >-
github.repository == 'QwenLM/qwen-code' && (
github.event_name == 'issues' ||
github.event_name == 'pull_request_target' ||
github.event_name == 'workflow_dispatch' ||
Comment thread
yiliang114 marked this conversation as resolved.
(github.event_name == 'issue_comment' &&
contains(github.event.comment.body, '@qwen-code /triage') &&
github.event.comment.user.login != 'github-actions[bot]' &&
(github.event.comment.author_association == 'OWNER' ||
github.event.comment.author_association == 'MEMBER' ||
github.event.comment.author_association == 'COLLABORATOR'))
)
steps:
- name: 'Checkout repo'
uses: 'actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd' # v6.0.2
with:
token: '${{ secrets.GITHUB_TOKEN }}'

- name: 'Resolve target number'
id: 'resolve'
run: |
if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then
echo "number=${{ github.event.inputs.number }}" >> "$GITHUB_OUTPUT"
elif [ "${{ github.event_name }}" = "pull_request_target" ]; then
echo "number=${{ github.event.pull_request.number }}" >> "$GITHUB_OUTPUT"
else
echo "number=${{ github.event.issue.number }}" >> "$GITHUB_OUTPUT"
fi

- name: 'Run Qwen Triage'
uses: 'QwenLM/qwen-code-action@5fd6818d04d64e87d255ee4d5f77995e32fbf4c2'
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
TARGET_NUMBER: '${{ steps.resolve.outputs.number }}'
REPOSITORY: '${{ github.repository }}'
with:
OPENAI_API_KEY: '${{ secrets.OPENAI_API_KEY }}'
OPENAI_BASE_URL: '${{ secrets.OPENAI_BASE_URL }}'
OPENAI_MODEL: '${{ secrets.OPENAI_MODEL }}'
settings_json: |-
{
"maxSessionTurns": 25,
"coreTools": [
"run_shell_command",
"write_file"
],
"sandbox": false
}
prompt: |-
You are a triage assistant for the QwenLM/qwen-code repository.

Run `/triage ${TARGET_NUMBER}` to triage this issue or PR.

Use the available shell commands (`gh`) to gather information and
execute the triage workflow. The triage skill is available at
`.qwen/skills/triage/SKILL.md` — follow its rules exactly.

Key rules:
- Only target QwenLM/qwen-code with `--repo QwenLM/qwen-code`
- Labels: apply existing only, verify with `gh label list`
- Comments: use `--body-file` with heredoc for multi-line content
- Include both stage markers and bot-coordination markers
- Never close, merge, approve, assign, or remove labels
- Evaluate the tiered gate model before any `gh` write call
Loading