Triage bot (#1417)
<!-- CURSOR_SUMMARY --> > [!NOTE] > Adds an issue triage workflow and upgrades the duplicate-detection workflow to a newer Anthropic model. > > - **CI Workflows**: > - **New `triage-issues.yml`**: > - Runs on new issues; installs `opencode` and labels non-English (`issue/lang`) and incomplete (`issue/incomplete`) reports, posting guidance comments. > - **`duplicate-issues.yml`**: > - Updates `opencode` model to `anthropic/claude-sonnet-4-5-20250929` for duplicate detection. > > <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit 11a89c6cfec1691c68837d599b8e3fc6888df09e. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup> <!-- /CURSOR_SUMMARY -->
This commit is contained in:
2
.github/workflows/duplicate-issues.yml
vendored
2
.github/workflows/duplicate-issues.yml
vendored
@@ -37,7 +37,7 @@ jobs:
|
||||
"webfetch": "deny"
|
||||
}
|
||||
run: |
|
||||
opencode run -m anthropic/claude-sonnet-4-20250514 "A new issue has been created:'
|
||||
opencode run -m anthropic/claude-sonnet-4-5-20250929 "A new issue has been created:'
|
||||
|
||||
Issue number:
|
||||
${{ github.event.issue.number }}
|
||||
|
||||
68
.github/workflows/triage-issues.yml
vendored
Normal file
68
.github/workflows/triage-issues.yml
vendored
Normal file
@@ -0,0 +1,68 @@
|
||||
# This was copied from https://github.com/sst/opencode/blob/d7a9f343c53d481802c134ce25691a8c150d59d2/.github/workflows/duplicate-issues.yml
|
||||
# MIT License
|
||||
# Copyright (c) 2025 opencode
|
||||
|
||||
name: Triage Issue
|
||||
|
||||
on:
|
||||
issues:
|
||||
types: [opened]
|
||||
|
||||
jobs:
|
||||
triage-issues:
|
||||
environment: ai-bots
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
contents: read
|
||||
issues: write
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 1
|
||||
|
||||
- name: Install opencode
|
||||
run: curl -fsSL https://opencode.ai/install | bash
|
||||
|
||||
- name: Triage issue
|
||||
env:
|
||||
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
OPENCODE_PERMISSION: |
|
||||
{
|
||||
"bash": {
|
||||
"gh issue*": "allow",
|
||||
"*": "deny"
|
||||
},
|
||||
"webfetch": "deny"
|
||||
}
|
||||
run: |
|
||||
opencode run -m anthropic/claude-sonnet-4-5-20250929 "A new issue has been created:'
|
||||
|
||||
Issue number:
|
||||
${{ github.event.issue.number }}
|
||||
|
||||
If most of the issue description is written in a language other than English, label the issue with 'issue/lang' and leave a friendly comment: 'Hi! We're only able to respond to issues in English. Please translate your issue with ChatGPT so we can help you. Thanks!'
|
||||
|
||||
If the issue has several blank sections, then label the issue with 'issue/incomplete' and leave a friendly comment: 'Hi! Please fill in all the fields in the issue so we can help you. A screenshot is very helpful!'
|
||||
|
||||
Here's an example of an empty issue:
|
||||
|
||||
<!--
|
||||
⚠️ IMPORTANT: All sections marked as required must be completed in English.
|
||||
Issues that do not meet these requirements will be closed and may need to be resubmitted.
|
||||
-->
|
||||
|
||||
## Bug Description (required)
|
||||
<!-- Please describe the issue you're experiencing -->
|
||||
|
||||
## Steps to Reproduce (required)
|
||||
<!-- Please list the steps to reproduce the issue -->
|
||||
|
||||
## Expected Behavior (required)
|
||||
<!-- What did you expect to happen? -->
|
||||
|
||||
## Actual Behavior (required)
|
||||
<!-- What actually happened? -->
|
||||
|
||||
"
|
||||
Reference in New Issue
Block a user