SuperAPI AI 工具集

resolve-slate-issue

编程与开发

查看项目

更新于 10-16 07:09

技能介绍

用途

Resolve Slate Issue 用于一次处理一个 Slate 或 Slate v2 的 GitHub issue,目标是证明、修复或分类该 issue,然后直接在 issue 上留言。它将任务式 issue-first 执行方式与 Slate Plan 的 live-source、issue-ledger 和 Slate v2 验证纪律结合起来。

硬性规则

  • 不得开启、创建、更新或提及 PR。
  • 不得在 GitHub issue 评论中包含 PR 元数据行。
  • 不得在评论中包含 Fixes ... issue 元数据行。
  • 在结果被验证或有意分类为 already fixed/currently accounted 之前,不得评论。
  • 使用 gh issue comment ... --body-file ... 提交最终 issue 评论。
  • 如果验证后置信度为 95%+,在发表评论后关闭 issue。
  • 如果无法诚实测试所需流程,不要关闭 issue;请人工复现确切流程并反馈。
  • 从 issue 源开始,而不是从旧计划或记忆开始。
  • 当前 .tmp/slate-v2 源代码优先于 issue 提出时的假设。
  • issue 可能指定 origin commit。将该 commit 视为报告基线,而非当前事实;后续 commit 可能已修复。
  • 如果当前 .tmp/slate-v2 对 issue 流程已经是绿的,不要仅为制造 diff 而修补代码。分类为 already-accounted,记录证据,并用当前验证结果评论。
  • 如果当前 .tmp/slate-v2 是红的,先添加最小的 proof row,修复真正的 owner,然后验证。
  • 不得仅凭合成浏览器行声称手动 IME/移动端/设备端关闭。
  • plate-2 命令只能证明计划/文档状态。Slate 行为证明必须在 .tmp/slate-v2 中运行。

受理(Intake)

解析 issue:

gh issue view <number-or-url> -R udecode/slate --comments --json number,title,body,comments,labels,state,url

如果仓库不是 udecode/slate,则从 URL 或当前 gh repo 解析仓库,然后获取相同字段。

阅读 issue 正文、评论、标签、附图与附视频。

如果存在视频或屏幕录制,在实现前使用 video-transcripts,除非已有缓存转录评论完整覆盖同一规范化媒体 URL。

提取:issue 编号与标题、确切用户流程、预期行为、实际行为、本地路由或包 owner、存在时的 live reference route、存在时的 origin commit 或分支、.tmp/slate-v2 中可能的 owner、浏览器/设备需求。

当前状态检查

编辑前:

  • 检查当前 .tmp/slate-v2 源码、示例、测试以及拥有该 issue 的路由。
  • 如果 issue 指定了 origin commit,可在有助于解释为何 issue 已修复时,将基线与当前 HEAD 对比。除非为证明所需,不要检出旧 commit。
  • 首先针对当前 .tmp/slate-v2 复现。

对当前状态分类:

状态 含义 行动
red-current 当前 .tmp/slate-v2 仍能复现该 issue。 添加 proof row、修复、验证,然后评论。
already-accounted 当前 .tmp/slate-v2 通过 issue 流程,可能已由后续 commit 或先前工作修复。 不改代码;验证、评论,若置信度 95%+ 则关闭。
needs-manual-proof 浏览器/设备/IME 证明无法诚实地自动化。 运行可用的支持性证明,请求人工复现确切流程,保持开启,不要过度声称。
blocked 在真实尝试后,所需 issue 证据、媒体或工具仍不可访问。 不要以修复身份评论。报告 blocker。

执行(Execution)

针对 red-current:

  • 添加最小的失败证明:模型/历史/剪贴板合约使用 package test;浏览器行为使用 Playwright row;仅在自动化无法诚实覆盖时使用手动/浏览器备注。
  • 修复 .tmp/slate-v2 中持久的 owner。
  • 除非 bug 确实是示例本地问题,避免示例本地补丁。
  • 从 .tmp/slate-v2 运行聚焦验证。
  • 当触及面足够广时,运行更广泛的 Slate v2 gate。
  • 仅在有助 issue 记账时更新任何本地计划或 fork dossier。
  • 如果验证给出 95%+ 置信度,在发表评论后关闭 issue:gh issue close <number-or-url> -R udecode/slate。

针对 already-accounted:

  • 保持代码不变。
  • 仅当 issue 流程重要且未被覆盖时,添加缺失的证明。
  • 用最小诚实命令或浏览器流程验证当前行为。
  • 以当前已验证行为评论,而非作为新修复。
  • 若置信度 95%+,在发表评论后关闭 issue。

针对 needs-manual-proof:

  • 运行任何对该流程诚实的支持性自动化证明。
  • 评论中包含确切的人工复现请求。
  • 保持 issue 开启。
  • 不要使用 95-100% 置信度行。

验证(Verification)

记录带 cwd 的确切命令。常见 Slate v2 gates:

cd .tmp/slate-v2
bun --filter slate-react typecheck
bun check
PLAYWRIGHT_BASE_URL=http://localhost:3100 bun playwright <test-file> --project=chromium --grep "<issue row>"

仅使用适合触及面的命令。如果 bun check 因无关的广泛集成或本地环境原因失败,隔离失败并记录为何它不阻塞 issue 评论。

评论正文

将最终评论写入临时文件,然后发布:

gh issue comment <number-or-url> -R udecode/slate --body-file <comment-file>

使用此格式。保持简洁。当没有真实 caveat 时省略 ⚠️ Caveat。

🟢 95-100% confidence

| Phase      | 🧪 Tests                                  | 🌐 Browser                     |
| ---------- | ----------------------------------------- | ------------------------------ |
| Reproduced | 🔴 <failing proof or issue-current repro> | ✅ <browser/local repro>       |
| Verified   | 🟢 <passing proof>                        | ✅ <browser verified behavior> |

**🌐 Browser Check**

- Open `<exact route>`.
- Follow `<exact user flow>`.
- Confirm `<expected fixed/current behavior>`.

**✅ Outcome**

- <What now happens for the user.>
- <What no longer happens.>

**⚠️ Caveat**

- <Only real caveats: manual IME/device gap, already fixed by later commits, or partial browser coverage.>

**🏗️ Design**

- Chosen owner: <runtime/package/example owner>.
- Why not quick patch: <why a local workaround was wrong, or `N/A; already fixed in current v2`.>
- Why not broader change: <why a larger API/runtime change was unnecessary, if applicable.>

**🧪 Verified**

- `<command or browser proof>`
- `<command or browser proof>`

状态词:

  • 仅当本次运行中观察到真实失败证明,或从刚执行的计划中保留该证明时,才使用 🔴。
  • 当证据存在但当前检出已经是绿的时,使用 ✅。
  • 对于 already-accounted,在 Outcome 或 Caveat 中直接说明;不要伪造 red-green。
  • 如果浏览器/设备证明是部分或仅手动的,将置信度保持在 95% 以下。
  • 仅当置信度行为 🟢 95-100% confidence 时关闭 issue。
  • 当所需浏览器/设备流程无法测试时,包含如下 caveat:Please reproduce the steps above on <browser/device/input method>; leave this open until that confirms the behavior.

最终交接

评论后,回答:issue 编号、分类(red-current -> fixed、already-accounted 或 blocker)、评论发布情况(若 gh 返回则给出 URL)、issue 是否关闭(yes/no 及原因)、验证命令、任何 caveat。保持简短。

限制

该技能的具体配置参数、支持的 Slate 版本范围、安装命令等信息暂未提供。