ln-911-github-triager

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese
Paths: File paths (
shared/
,
references/
,
../ln-*
) are relative to skills repo root. If not found at CWD, locate this SKILL.md directory and go up one level for repo root.
路径说明: 文件路径(
shared/
references/
../ln-*
)是相对于技能仓库根目录的。如果在当前工作目录(CWD)中未找到,请定位到本SKILL.md所在目录,然后向上一级目录即为仓库根目录。

ln-911-github-triager

ln-911-github-triager

Type: L3 Worker (standalone) Category: 9XX Community Engagement Caller: ln-910-community-engagement (or standalone)
Scans all open issues, PRs, and discussions in the current repository. Categorizes by urgency. Produces an actionable triage report.

类型: L3 Worker(独立运行) 分类: 9XX 社区参与 调用方: ln-910-community-engagement(或独立运行)
扫描当前仓库中所有公开的Issue、PR和讨论,按紧急程度分类,生成可执行的分类报告。

Arguments

参数

$ARGUMENTS
controls scope and staleness threshold:
TokenEffectDefault
issues
Scan issues onlyAll three
prs
Scan PRs onlyAll three
discussions
Scan discussions onlyAll three
Number (e.g.,
14
)
Staleness threshold in days7
issues 30
Combine: scope + threshold--
summary
Compact output for coordinator: skip Phase 4 preview, return red flags + priority counts + metrics onlyFull interactive report
Parse
$ARGUMENTS
: extract scope tokens (
issues
,
prs
,
discussions
), numeric threshold, and
summary
flag. If no scope tokens, scan all three. If no number, default to 7 days.

$ARGUMENTS
用于控制扫描范围和 stale 阈值:
令牌作用默认值
issues
仅扫描Issue同时扫描三类
prs
仅扫描PR同时扫描三类
discussions
仅扫描讨论同时扫描三类
数字(例如
14
Stale阈值(天数)7
issues 30
组合使用:范围 + 阈值--
summary
为协调者生成精简输出:跳过第4阶段预览,仅返回红色预警、优先级统计和指标完整交互式报告
解析
$ARGUMENTS
:提取范围令牌(
issues
prs
discussions
)、数字阈值和
summary
标志。如果没有指定范围令牌,则扫描全部三类内容;如果没有指定数字,则默认阈值为7天。

Phase 0: GitHub Discovery

阶段0:GitHub发现

MANDATORY READ: Load
../ln-910-community-engagement/references/github_discovery.md
Execute the discovery protocol. Extract:
  • {owner}/{repo}
    for
    --repo
    flag and URLs
  • maintainer
    login (authenticated user) for maintainer detection
  • Verify
    gh
    is authenticated
Load strategy: check
docs/community_engagement_strategy.md
in target project, fallback to
../ln-910-community-engagement/references/community_strategy_template.md
. Extract Section 5 (Engagement Metrics) for targets and red flags.

必读: 加载
../ln-910-community-engagement/references/github_discovery.md
执行发现协议,提取:
  • {owner}/{repo}
    用于
    --repo
    参数和URL
  • maintainer
    登录账号(已认证用户),用于识别维护者
  • 验证
    gh
    工具已完成认证
加载策略:检查目标项目中的
docs/community_engagement_strategy.md
,如果不存在则回退到
../ln-910-community-engagement/references/community_strategy_template.md
。提取第5部分(参与度指标)中的目标值和红色预警条件。

Phase 1: Fetch Data

阶段1:获取数据

Run these
gh
commands based on scope. Execute all applicable fetches in parallel.
根据扫描范围运行以下
gh
命令,所有适用的获取操作并行执行。

1a. Issues

1a. Issues

bash
gh issue list --repo {owner}/{repo} --state open --limit 100 --json number,title,labels,createdAt,updatedAt,author,comments,assignees
bash
gh issue list --repo {owner}/{repo} --state open --limit 100 --json number,title,labels,createdAt,updatedAt,author,comments,assignees

1b. Pull Requests

1b. Pull Requests

bash
gh pr list --repo {owner}/{repo} --state open --limit 100 --json number,title,labels,createdAt,updatedAt,author,reviewDecision,reviewRequests,isDraft,comments,assignees
bash
gh pr list --repo {owner}/{repo} --state open --limit 100 --json number,title,labels,createdAt,updatedAt,author,reviewDecision,reviewRequests,isDraft,comments,assignees

1c. Discussions (GraphQL)

1c. Discussions (GraphQL)

bash
gh api graphql -f query='
  query($owner: String!, $name: String!) {
    repository(owner: $owner, name: $name) {
      discussions(first: 100, states: OPEN) {
        nodes {
          number
          title
          category { name }
          createdAt
          updatedAt
          author { login }
          answerChosenAt
          labels(first: 5) { nodes { name } }
          comments(first: 20) {
            totalCount
            nodes {
              author { login }
              createdAt
            }
          }
        }
      }
    }
  }
' -f owner="{owner}" -f name="{repo}"
Gate: If all sources return zero items, report "No open items. Triage complete." and stop.

bash
gh api graphql -f query='
  query($owner: String!, $name: String!) {
    repository(owner: $owner, name: $name) {
      discussions(first: 100, states: OPEN) {
        nodes {
          number
          title
          category { name }
          createdAt
          updatedAt
          author { login }
          answerChosenAt
          labels(first: 5) { nodes { name } }
          comments(first: 20) {
            totalCount
            nodes {
              author { login }
              createdAt
            }
          }
        }
      }
    }
  }
' -f owner="{owner}" -f name="{repo}"
判断: 如果所有数据源都返回0条内容,则报告“无公开内容,分类完成”并终止流程。

Phase 2: Classify Each Item

阶段2:分类每个内容项

For every fetched item, evaluate these conditions. An item can match multiple -- use highest priority.
对每个获取到的内容项,评估以下条件。一个内容项可能匹配多个条件,使用最高优先级的分类。

Priority Matrix

优先级矩阵

PriorityConditionApplies to
P0 CriticalLabel contains
bug
AND no assignee
Issues
P0 CriticalLabel contains
breaking
Issues, PRs
P1 UrgentAuthor != maintainer AND zero comments from maintainerIssues, Discussions
P1 UrgentQ&A discussion with
answerChosenAt
is null AND author != maintainer
Discussions
P1 Urgent
reviewDecision
is null or
REVIEW_REQUIRED
PRs
P2 StaleNo activity for > threshold days (
updatedAt
older than threshold)
All
P3 MonitorPR marked as draft (
isDraft
is true)
PRs
P3 MonitorAuthor == maintainer AND 0 community repliesDiscussions
P4 InfoItems not matching any above conditionAll
优先级条件适用对象
P0 紧急标签包含
bug
且无负责人
Issues
P0 紧急标签包含
breaking
Issues、PRs
P1 高优先级作者不是维护者,且维护者未留下任何评论Issues、Discussions
P1 高优先级Q&A类讨论未标记已解答(
answerChosenAt
为null)且作者不是维护者
Discussions
P1 高优先级
reviewDecision
为null或
REVIEW_REQUIRED
PRs
P2 已停滞超过阈值天数无任何活动(
updatedAt
早于阈值日期)
所有
P3 监控中PR标记为草稿(
isDraft
为true)
PRs
P3 监控中作者是维护者,且无社区回复Discussions
P4 信息类不匹配上述任何条件的内容项所有

Maintainer Detection

维护者识别

The maintainer login comes from Phase 0 discovery (
viewer.login
). An item "has maintainer reply" if any comment's
author.login
equals the maintainer login.
For issues: check
comments
array authors. For discussions: check
comments.nodes[].author.login
.
维护者登录账号来自阶段0的发现流程(
viewer.login
)。如果任何评论的
author.login
等于维护者登录账号,则认为该内容项“有维护者回复”。
对于Issues:检查
comments
数组中的作者;对于Discussions:检查
comments.nodes[].author.login

Staleness Calculation

停滞状态计算

Days since last activity:
(today - updatedAt)
in days. Compare against threshold (default 7, or from
$ARGUMENTS
).
最后一次活动至今的天数:
(今天 - updatedAt)
的天数。与阈值(默认7天,或来自
$ARGUMENTS
)进行比较。

Label Urgency Signals

标签紧急信号

Labels that elevate priority:
bug
,
breaking
,
security
,
urgent
.
Labels that signal engagement opportunity (not urgency):
help wanted
,
good first issue
.

提升优先级的标签:
bug
breaking
security
urgent
表示参与机会的标签(非紧急):
help wanted
good first issue

Phase 3: Engagement Metrics

阶段3:参与度指标

Calculate aggregate metrics per strategy Section 5:
MetricCalculationTargetRed Flag
Time to First ResponseAvg(first maintainer comment - item created) for items WITH reply<24h>72h
Unanswered discussionsCount where author != maintainer AND no maintainer comment AND age > threshold0Any >7 days
Community-to-maintainer ratioNon-maintainer comments / maintainer comments across all items>0.30
New discussions this monthDiscussions created in last 30 days>20
Zero-engagement itemsItems with 0 comments total----

根据策略第5部分计算汇总指标:
指标计算方式目标值红色预警
首次响应时间所有有回复的内容项中,(首次维护者评论时间 - 内容项创建时间)的平均值<24小时>72小时
未回复的讨论作者不是维护者、维护者未评论且存在时间超过阈值的讨论数量0任何超过7天的内容
社区与维护者回复比所有内容项中,非维护者评论数 / 维护者评论数>0.30
本月新增讨论过去30天内创建的讨论数量>20
零互动内容项总评论数为0的内容项数量----

Phase 4: Preview Table

阶段4:预览表格

If
$ARGUMENTS
contains
summary
→ skip this phase entirely. Output compact summary (red flags, priority counts per category, health metrics table) and stop. Do NOT compose the full Phase 5 report.
Otherwise (standalone mode): present a compact summary table of ALL classified items for user review. Wait for user approval before proceeding to Phase 5.
undefined
如果
$ARGUMENTS
包含
summary
→ 完全跳过此阶段。输出精简摘要(红色预警、各优先级数量统计、健康指标表格)并终止流程,不生成完整的第5阶段报告。
否则(独立运行模式): 展示所有已分类内容项的精简摘要表格,供用户审核。获得用户确认后,方可进入第5阶段。
undefined

Triage Preview -- {total count} items found

分类预览 -- 共找到 {total count} 条内容

#TypeTitlePriorityAgeKey Signal
{number}{Issue/PR/Discussion}{title (truncated to 50 chars)}{P0/P1/P2/P3/P4}{days}d{short reason}

Sort by priority (P0 first), then by age (oldest first) within each priority group.

After presenting, ask the user:
- Confirm priorities look correct
- Whether to exclude any items from the full report
- Whether to adjust the staleness threshold

Proceed to Phase 5 only after user confirms.

---
编号类型标题优先级存在天数关键信号
{number}{Issue/PR/Discussion}{title(截断至50字符)}{P0/P1/P2/P3/P4}{days}d{简短原因}

按优先级排序(P0优先),同一优先级内按存在天数排序(最旧的在前)。

展示预览后,询问用户:
- 确认优先级分类是否正确
- 是否需要从完整报告中排除某些内容项
- 是否需要调整停滞阈值

仅在用户确认后,方可进入第5阶段。

---

Phase 5: Compose Report

阶段5:生成完整报告

Present the full triage report in this format:
undefined
按以下格式生成完整的分类报告:
undefined

GitHub Triage Report -- {YYYY-MM-DD}

GitHub分类报告 -- {YYYY-MM-DD}

Scope: {issues/PRs/discussions or "all"} | Threshold: {N} days | Open items: {total count}
undefined
扫描范围: {issues/PRs/discussions 或 "全部"} | 阈值: {N} 天 | 公开内容项总数: {total count}
undefined

Red Flag Alerts

红色预警提示

If any red flags from Phase 3 are triggered, add BEFORE Health Metrics:
> [!WARNING]
> **Red flags detected:**
> - {description, e.g., "2 unanswered discussions older than 7 days"}
如果阶段3中触发了任何红色预警,需在健康指标表格之前添加:
> [!WARNING]
> **检测到红色预警:**
> - {描述,例如:"2条超过7天未回复的讨论"}

Health Metrics Table

健康指标表格

| Metric | Value | Target | Status |
|--------|-------|--------|--------|
| Unanswered (>{N}d) | {count} | 0 | {OK / RED FLAG} |
| Avg first response | {hours}h | <24h | {OK / RED FLAG} |
| Community:maintainer ratio | {ratio} | >0.3 | {OK / RED FLAG} |
| New discussions (30d) | {count} | >2 | {OK / RED FLAG} |
| Zero-engagement items | {count} | -- | {count} |
| 指标 | 数值 | 目标值 | 状态 |
|--------|-------|--------|--------|
| 未回复内容(>{N}天) | {count} | 0 | {正常 / 红色预警} |
| 平均首次响应时间 | {hours}h | <24h | {正常 / 红色预警} |
| 社区:维护者回复比 | {ratio} | >0.3 | {正常 / 红色预警} |
| 新增讨论(30天内) | {count} | >2 | {正常 / 红色预警} |
| 零互动内容项 | {count} | -- | {count} |

Priority Tables

优先级表格

For each priority P0..P3, show header with count. If count is 0, show header
(0)
and skip table.
P0 Critical:
#TypeTitleLabelsAgeAction Needed
P1 Urgent:
#TypeTitleAuthorAgeWhy
P2 Stale:
#TypeTitleLast ActivityDays Stale
P3 Monitor:
#TypeTitleNote
P4 Info: Do NOT list individually -- only include in total count.
为每个优先级P0..P3展示标题和数量。如果数量为0,展示标题
(0)
并跳过表格。
P0 紧急:
编号类型标题标签存在天数需执行操作
P1 高优先级:
编号类型标题作者存在天数原因
P2 已停滞:
编号类型标题最后活动时间停滞天数
P3 监控中:
编号类型标题备注
P4 信息类: 不单独列出,仅计入总数。

Recommended Actions

建议操作

undefined
undefined

Recommended Actions

建议操作

  1. Respond: {items needing maintainer reply, with GitHub URLs}
  2. Review: {PRs needing review, with GitHub URLs}
  3. Close or bump: {stale items -- suggest close if resolved, bump if relevant}
  4. Engage: {items that could benefit from community call-to-action}
undefined
  1. 回复: {需要维护者回复的内容项,附GitHub链接}
  2. 审核: {需要审核的PR,附GitHub链接}
  3. 关闭或激活: {已停滞的内容项 -- 建议如果已解决则关闭,若仍相关则激活}
  4. 参与互动: {可发起社区号召的内容项}
undefined

Formatting Rules

格式规则

  • Sort items within each priority group by age (oldest first)
  • URL format:
    https://github.com/{owner}/{repo}/{issues|discussions|pull}/{number}
  • Dates in
    YYYY-MM-DD
    , ages in days
  • All items in Recommended Actions must have direct GitHub URLs

  • 同一优先级内的内容项按存在天数排序(最旧的在前)
  • URL格式:
    https://github.com/{owner}/{repo}/{issues|discussions|pull}/{number}
  • 日期格式为
    YYYY-MM-DD
    ,存在天数以天为单位
  • 建议操作中的所有内容项必须附带直接的GitHub链接

Rules

规则

  • Read-only: this skill fetches and reports -- never create, modify, or close any GitHub item
  • No publishing: do not create issues, comments, labels, or any other GitHub state change
  • Maintainer login: from Phase 0 discovery (authenticated user)
  • Default threshold: 7 days (per strategy Section 5)
  • Rate limits: if GraphQL rate limit hit, report partial results with a warning

  • 只读: 本技能仅获取数据并生成报告 -- 绝不创建、修改或关闭任何GitHub内容项
  • 禁止发布: 不得创建Issue、评论、标签或任何其他GitHub状态变更
  • 维护者登录账号: 来自阶段0的发现流程(已认证用户)
  • 默认阈值: 7天(根据策略第5部分)
  • 速率限制: 如果触发GraphQL速率限制,需报告部分结果并附带警告

Definition of Done

完成标准

  • GitHub data fetched for all scoped item types (issues/PRs/discussions)
  • Every item classified by priority (P0-P4)
  • Engagement metrics calculated per strategy targets
  • Report composed (full interactive report OR compact summary for coordinator)

Version: 1.0.0 Last Updated: 2026-03-13
  • 已获取所有指定范围内容类型的GitHub数据(Issue/PR/讨论)
  • 所有内容项已按优先级分类(P0-P4)
  • 已根据策略目标计算参与度指标
  • 已生成报告(完整交互式报告 或 供协调者使用的精简摘要)

版本: 1.0.0 最后更新: 2026-03-13