From b225503dc5c798da510141ef04caac34c922832d Mon Sep 17 00:00:00 2001 From: Steven Nguyen Date: Fri, 7 Nov 2025 12:26:13 -0800 Subject: [PATCH] feat: Enhance issue triage with updated criteria - Include issues updated in last 24 hours (with new comments), not just newly created - Add non-English content check: detect and request English translation respectfully - Add multi-topic detection: ask users to split issues with multiple unrelated topics - Improve spam detection with clear guidance - Enhanced with empathetic approach for language and topic guidance - Add parameter hints for list_label tool usage - Clarify good first issue label application criteria - Update summary message to reflect new triage scope --- .github/workflows/issue-triage.lock.yml | 42 +++++++++++++------------ .github/workflows/issue-triage.md | 37 ++++++++++++---------- 2 files changed, 42 insertions(+), 37 deletions(-) diff --git a/.github/workflows/issue-triage.lock.yml b/.github/workflows/issue-triage.lock.yml index a42e8ef4ec..5c9d7caca8 100644 --- a/.github/workflows/issue-triage.lock.yml +++ b/.github/workflows/issue-triage.lock.yml @@ -5,7 +5,7 @@ # # Source: githubnext/agentics/workflows/issue-triage.md@0837fb7b24c3b84ee77fb7c8cfa8735c48be347a # -# Effective stop-time: 2025-12-07 20:16:16 +# Effective stop-time: 2025-12-07 20:26:06 # # Job Dependency Graph: # ```mermaid @@ -2135,22 +2135,26 @@ jobs: - You're a triage assistant for GitHub issues. Your task is to analyze issues created in the last 24 hours and perform initial triage tasks for each of them. + You're a triage assistant for GitHub issues. Your task is to analyze issues that were either created in the last 24 hours or updated (with a new comment) in the last 24 hours, and perform initial triage tasks for each of them. - 1. First, use the `list_issues` tool to retrieve all issues created in the last 24 hours. Filter issues by using the `since` parameter with a timestamp from 24 hours ago (calculate: current time minus 24 hours in ISO 8601 format). + 1. First, use the `list_issues` tool to retrieve all issues created in the last 24 hours. Filter issues by using the `since` parameter with a timestamp from 24 hours ago (calculate: 2025-11-06T20:20:55.649Z for reference, subtract 24 hours). Additionally, retrieve issues that were updated in the last 24 hours using a separate query with the `since` parameter to capture recently commented issues. 2. For each issue found, perform the following triage tasks: - 3. Select appropriate labels for the issue from the provided list. Only apply the `good first issue` label on verified issues with straightforward fixes. + 3. Check for spam and quality issues first: + + - **Non-English Content**: If the issue is primarily written in a non-English language, add a respectful and appreciative comment explaining that while you appreciate their contribution, the majority of the community communicates in English and kindly ask them to repost in English so everyone can follow along and help. Provide a friendly translation of your message in their language if possible. + - **Multiple Topics**: If the issue discusses multiple unrelated topics or problems, add a comment explaining that each issue should focus on one clear topic so the team can effectively solve the right problem. Politely ask them to split it into separate issues. + - **Obvious Spam or Bot-Generated Content**: If the issue is obviously spam, generated by a bot, or something that is not an actual issue to be worked on, add an issue comment with a one-sentence analysis and move to the next issue. - 4. Retrieve the issue content using the `get_issue` tool. If the issue is obviously spam, or generated by bot, or something else that is not an actual issue to be worked on, then add an issue comment to the issue with a one sentence analysis and move to the next issue. + 4. Retrieve the issue content using the `get_issue` tool for any issues that pass the spam checks. 5. Next, use the GitHub tools to gather additional context about the issue: - - Fetch the list of labels available in this repository using the `list_label` tool. This will give you the labels you can use for triaging issues. - - Fetch any comments on the issue using the `get_issue_comments` tool + - Fetch the list of labels available in this repository using the `list_label` tool with `owner: "appwrite"` and `repo: "appwrite"` parameters. This will give you the labels you can use for triaging issues. + - Fetch any comments on the issue using the `get_issue_comments` tool to understand recent activity - **Search for duplicate and related issues (repo first, then org-wide)**: - - First search in this repository using the `search_issues` tool with a query like: `repo:${GH_AW_EXPR_D892F163} is:issue (is:open OR is:closed) `. + - First search in this repository using the `search_issues` tool with a query like: `repo:appwrite/appwrite is:issue (is:open OR is:closed) `. - Then perform an org-wide search across the entire Appwrite organization using: `org:appwrite is:issue (is:open OR is:closed) `. - Prefer linking to OPEN issues when identifying potential duplicates; include CLOSED ones as related history when useful. @@ -2165,15 +2169,16 @@ jobs: 7. Write notes, ideas, nudges, resource links, debugging strategies and/or reproduction steps for the team to consider relevant to the issue. - 8. Select appropriate labels from the available labels list provided above: + 8. Select appropriate labels from the available labels list: - Choose labels that accurately reflect the issue's nature - Be specific but comprehensive - Select priority labels if you can determine urgency (high-priority, med-priority, or low-priority) - Consider platform labels (android, ios) if applicable - - Search for similar issues. If you find a duplicate of another OPEN issue in THIS repository, you may use a "duplicate" label (if available) and reference the canonical issue. - - If the closest match is in another repository within the Appwrite org, do NOT mark as duplicate here; instead, link it in your comment under a "Cross‑repo related issues" section. - - Only select labels from the provided list above + - Search for similar issues. If you find a duplicate of another OPEN issue in THIS repository, you may use a "duplicate" label (if available) and reference the canonical issue. + - If the closest match is in another repository within the Appwrite org, do NOT mark as duplicate here; instead, link it in your comment under a "Cross‑repo related issues" section. + - Only select labels from the provided list + - Only apply the `good first issue` label on verified issues with straightforward fixes - It's okay to not add any labels if none are clearly applicable 9. Apply the selected labels: @@ -2186,18 +2191,16 @@ jobs: - Start with "🎯 Agentic Issue Triage" - Provide a brief summary of the issue - **If duplicate or related issues were found**, add sections listing them with links: - - "### 🔗 Potentially Related Issues (this repo)" – bullet list of same‑repo issues with titles and links - - If applicable: "### 🌐 Cross‑repo related issues (org: appwrite)" – bullet list including `owner/repo#number` with titles and links + - "### 🔗 Potentially Related Issues (this repo)" – bullet list of same-repo issues with titles and links + - If applicable: "### 🌐 Cross-repo related issues (org: appwrite)" – bullet list including `owner/repo#number` with titles and links - Mention any relevant details that might help the team understand the issue better - Include any debugging strategies or reproduction steps if applicable - Suggest resources or links that might be helpful for resolving the issue or learning skills related to the issue or the particular area of the codebase affected by it - Mention any nudges or ideas that could help the team in addressing the issue - - If you have possible reproduction steps, include them in the comment - - If you have any debugging strategies, include them in the comment - - If appropriate break the issue down to sub-tasks and write a checklist of things to do. + - If appropriate break the issue down to sub-tasks and write a checklist of things to do - Use collapsed-by-default sections in the GitHub markdown to keep the comment tidy. Collapse all sections except the short main summary at the top. - 11. After processing all issues, provide a summary of how many issues were triaged. If no issues were created in the last 24 hours, simply note that no new issues needed triage. + 11. After processing all issues, provide a summary of how many issues were triaged (created or updated in the last 24 hours). If no issues matched the criteria, simply note that no issues needed triage. PROMPT_EOF - name: Append XPIA security instructions to prompt @@ -2308,7 +2311,6 @@ jobs: uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd env: GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt - GH_AW_EXPR_D892F163: ${{ github.repository }} with: script: | const fs = require("fs"); @@ -5002,7 +5004,7 @@ jobs: id: check_stop_time uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd env: - GH_AW_STOP_TIME: 2025-12-07 20:16:16 + GH_AW_STOP_TIME: 2025-12-07 20:26:06 GH_AW_WORKFLOW_NAME: "Agentic Triage" with: script: | diff --git a/.github/workflows/issue-triage.md b/.github/workflows/issue-triage.md index 71feb1b6cc..31a33e0a5c 100644 --- a/.github/workflows/issue-triage.md +++ b/.github/workflows/issue-triage.md @@ -44,22 +44,26 @@ source: githubnext/agentics/workflows/issue-triage.md@0837fb7b24c3b84ee77fb7c8cf -You're a triage assistant for GitHub issues. Your task is to analyze issues created in the last 24 hours and perform initial triage tasks for each of them. +You're a triage assistant for GitHub issues. Your task is to analyze issues that were either created in the last 24 hours or updated (with a new comment) in the last 24 hours, and perform initial triage tasks for each of them. -1. First, use the `list_issues` tool to retrieve all issues created in the last 24 hours. Filter issues by using the `since` parameter with a timestamp from 24 hours ago (calculate: current time minus 24 hours in ISO 8601 format). +1. First, use the `list_issues` tool to retrieve all issues created in the last 24 hours. Filter issues by using the `since` parameter with a timestamp from 24 hours ago (calculate: 2025-11-06T20:20:55.649Z for reference, subtract 24 hours). Additionally, retrieve issues that were updated in the last 24 hours using a separate query with the `since` parameter to capture recently commented issues. 2. For each issue found, perform the following triage tasks: -3. Select appropriate labels for the issue from the provided list. Only apply the `good first issue` label on verified issues with straightforward fixes. +3. Check for spam and quality issues first: + + - **Non-English Content**: If the issue is primarily written in a non-English language, add a respectful and appreciative comment explaining that while you appreciate their contribution, the majority of the community communicates in English and kindly ask them to repost in English so everyone can follow along and help. Provide a friendly translation of your message in their language if possible. + - **Multiple Topics**: If the issue discusses multiple unrelated topics or problems, add a comment explaining that each issue should focus on one clear topic so the team can effectively solve the right problem. Politely ask them to split it into separate issues. + - **Obvious Spam or Bot-Generated Content**: If the issue is obviously spam, generated by a bot, or something that is not an actual issue to be worked on, add an issue comment with a one-sentence analysis and move to the next issue. -4. Retrieve the issue content using the `get_issue` tool. If the issue is obviously spam, or generated by bot, or something else that is not an actual issue to be worked on, then add an issue comment to the issue with a one sentence analysis and move to the next issue. +4. Retrieve the issue content using the `get_issue` tool for any issues that pass the spam checks. 5. Next, use the GitHub tools to gather additional context about the issue: - - Fetch the list of labels available in this repository using the `list_label` tool. This will give you the labels you can use for triaging issues. - - Fetch any comments on the issue using the `get_issue_comments` tool + - Fetch the list of labels available in this repository using the `list_label` tool with `owner: "appwrite"` and `repo: "appwrite"` parameters. This will give you the labels you can use for triaging issues. + - Fetch any comments on the issue using the `get_issue_comments` tool to understand recent activity - **Search for duplicate and related issues (repo first, then org-wide)**: - - First search in this repository using the `search_issues` tool with a query like: `repo:${{ github.repository }} is:issue (is:open OR is:closed) `. + - First search in this repository using the `search_issues` tool with a query like: `repo:appwrite/appwrite is:issue (is:open OR is:closed) `. - Then perform an org-wide search across the entire Appwrite organization using: `org:appwrite is:issue (is:open OR is:closed) `. - Prefer linking to OPEN issues when identifying potential duplicates; include CLOSED ones as related history when useful. @@ -74,15 +78,16 @@ You're a triage assistant for GitHub issues. Your task is to analyze issues crea 7. Write notes, ideas, nudges, resource links, debugging strategies and/or reproduction steps for the team to consider relevant to the issue. -8. Select appropriate labels from the available labels list provided above: +8. Select appropriate labels from the available labels list: - Choose labels that accurately reflect the issue's nature - Be specific but comprehensive - Select priority labels if you can determine urgency (high-priority, med-priority, or low-priority) - Consider platform labels (android, ios) if applicable - - Search for similar issues. If you find a duplicate of another OPEN issue in THIS repository, you may use a "duplicate" label (if available) and reference the canonical issue. - - If the closest match is in another repository within the Appwrite org, do NOT mark as duplicate here; instead, link it in your comment under a "Cross‑repo related issues" section. - - Only select labels from the provided list above + - Search for similar issues. If you find a duplicate of another OPEN issue in THIS repository, you may use a "duplicate" label (if available) and reference the canonical issue. + - If the closest match is in another repository within the Appwrite org, do NOT mark as duplicate here; instead, link it in your comment under a "Cross‑repo related issues" section. + - Only select labels from the provided list + - Only apply the `good first issue` label on verified issues with straightforward fixes - It's okay to not add any labels if none are clearly applicable 9. Apply the selected labels: @@ -95,15 +100,13 @@ You're a triage assistant for GitHub issues. Your task is to analyze issues crea - Start with "🎯 Agentic Issue Triage" - Provide a brief summary of the issue - **If duplicate or related issues were found**, add sections listing them with links: - - "### 🔗 Potentially Related Issues (this repo)" – bullet list of same‑repo issues with titles and links - - If applicable: "### 🌐 Cross‑repo related issues (org: appwrite)" – bullet list including `owner/repo#number` with titles and links + - "### 🔗 Potentially Related Issues (this repo)" – bullet list of same-repo issues with titles and links + - If applicable: "### 🌐 Cross-repo related issues (org: appwrite)" – bullet list including `owner/repo#number` with titles and links - Mention any relevant details that might help the team understand the issue better - Include any debugging strategies or reproduction steps if applicable - Suggest resources or links that might be helpful for resolving the issue or learning skills related to the issue or the particular area of the codebase affected by it - Mention any nudges or ideas that could help the team in addressing the issue - - If you have possible reproduction steps, include them in the comment - - If you have any debugging strategies, include them in the comment - - If appropriate break the issue down to sub-tasks and write a checklist of things to do. + - If appropriate break the issue down to sub-tasks and write a checklist of things to do - Use collapsed-by-default sections in the GitHub markdown to keep the comment tidy. Collapse all sections except the short main summary at the top. -11. After processing all issues, provide a summary of how many issues were triaged. If no issues were created in the last 24 hours, simply note that no new issues needed triage. +11. After processing all issues, provide a summary of how many issues were triaged (created or updated in the last 24 hours). If no issues matched the criteria, simply note that no issues needed triage.