再学 AI
第 01 课 / ask-matt
当前 · 工程阅读 → 对照 → 问答 → 场景

先学会选择工作方法

这是整套技能的导览员。它帮助你判断下一步应采用哪一种方法,而不是自动替你把所有方法跑一遍。

还不清楚 Skill、Agent、安装和调用?先读 从零开始的6节入门课

在关系图中查看 ask-matt 与其他技能的关联 →

先把必要的概念讲清楚

这是一张按当前问题选择技能的使用地图。下面先保留完整译文,再通过具体场景说明为什么走到某一步、下一步需要什么。

下面是老师补充的入门说明;原作者的要求保留在中英对照正文中。所有例子均为帮助理解而构造的教学情境。

spec / specification|规格说明

把要解决的问题、预期行为、约束和验收依据写明确的文档。它比“做个好用的学习网站”具体:例如登录用户能收藏课程,刷新后仍保留,重复收藏不会多出记录。它不必规定每个内部函数怎么写,但应让实现者和验收者对同一结果达成一致。

issue / ticket|问题或任务工单

跟踪一项需求、缺陷、调查或实施任务的记录,通常有标题、正文、状态和引用。issue 和 ticket 在这些文档里经常都指工单,具体含义由上下文决定。工单写着“已完成”只是状态声明,还需要相应证据支持。

context|Agent 当前可用的上下文

模型这一轮实际能使用的请求、对话、指令和已读文件内容。它不是电脑上所有资料,也不是永久记忆。文件存在但没被读到,就不一定参与推理。交接文档应指明当前目标、进度、关键证据位置和下一步,让新会话能够恢复必要背景。

context pointer|上下文资料指引

告诉 Agent 在什么条件下去读哪份材料的短指引。例如“新增或修改数据写入时,先读权限规则文档”。它同时承担地址与触发条件两项作用。只有“见文档”太模糊,可能找不到或不知道何时需要;一股脑放入所有内容又会占用上下文。

frontier|当前可推进的事项集合

任务存在先后依赖时,前置条件已满足、现在能处理的那些事项。先决定是否登录,才能决定收藏记录如何归属用户;配色可能不受这个决定影响,可以先讨论。前沿不是所有未完成事项,更不是凭直觉挑一个开始做。

prototype|用来回答问题的原型

成本低、范围小、可观察的试验产物,目的在于消除某个未知,例如比较逐段中英对照是否易读。它可以是界面、算法或粗稿。能运行不等于具备生产所需的权限、容错和维护条件;应带走试验所得的决定与证据。

读原文,理解每一步为什么这样做

左右内容按小节对应;窄屏先中文、后英文。两种语言均完整展示,对应讲解紧接在小节之后。译文传达原文要求;老师讲解补充概念、原因、例子与适用边界。

译注

原文称有“两个切入入口”,但下文列出三项。本译文保留这种不一致;不把路由指南提到的技能数量当作当前仓库文件总数。

中文译文English · 英文原文
中文译文
name: ask-matt
description: "询问哪一个技能或工作流程适合你的情况。这是本仓库技能的路由指南。"
disable-model-invocation: true
English · 英文原文
name: ask-matt
description: Ask which skill or flow fits your situation. A router over the skills in this repo.
disable-model-invocation: true
中文译文

问问 Matt:当前应该使用哪个技能

如果记不清这套技能分别用于什么,就用本技能帮助选择。

这里的流程,是指为完成一项工作,依次经过哪些技能。多数工作沿着一条主流程推进,也可以从其他问题入口进入。剩下的技能,有些独立使用,有些提供共同的概念和词汇。

English · 英文原文

Ask Matt

You don't remember every skill, so ask.

A flow is a path through the skills. Most paths run along one main flow, and two on-ramps merge onto it. Everything else is standalone, or a vocabulary layer that runs underneath.

中文译文

主流程:从想法到交付

这是最常见的情形:你有一个想法,希望把它做成实际成果。

English · 英文原文

The main flow: idea → ship

The route most work travels. You have an idea and want it built.

中文译文
  1. /grill-with-docs:先把想法问清楚。 只要正在某个工作目录中开展工作,就从这个技能开始。它通过深入访谈澄清想法,并将认识保存到 CONTEXT.md 和架构决策记录(ADR)。如果没有可用于保存资料的工作目录,改用后面独立技能中的 /grill-me。两者都采用 /grilling 的基础提问方法;grill-with-docs 还留下文字记录,所以作者在有仓库时优先选择它。
English · 英文原文
  1. /grill-with-docs sharpens the idea by interview. Start here whenever you are working in a working directory: it's stateful, retaining what it learns in CONTEXT.md and ADRs. (No working directory? Use /grill-me instead, covered under Standalone. Both run the same /grilling primitive; grill-with-docs is the one that leaves a paper trail, which makes it the better of the two whenever a repo is there to leave it in.)
老师讲解 · 对应上方原文 · 含教学举例

先把想法问清楚,具体会问什么?

这一段解决“你说的功能”和“AI 理解的功能”不是同一件事的问题。 例如你说想收藏课程,AI 需要先确认收藏对象是整门课程还是单个课时,是否必须登录,以及刷新后是否保留。

这些选择会改变实际实现,不能仅靠一句“我懂了”跳过。grilling 用有顺序的追问形成共同理解;domain-modeling 则在概念明确时把名称和定义记录下来。

“有工作目录”意味着 Agent 有地方读写项目资料。它不是指你必须亲手打开终端写代码。没有可写目录时,也可以做对话澄清,只是不能假装已经把决定保存到文件。

中文译文
  1. 分支判断:所有问题都能在对话中确定吗? 有些问题必须运行起来、或者亲眼看见才好判断,例如状态变化是否合理、业务逻辑能否成立、界面是什么样。遇到这类问题,先转去做原型,来回都使用 /handoff 交接背景。原型在自己的目录中开展,这正是可携带交接文档的用途。有关选择见“阶段边界”。
    • 先用 /handoff 写出交接材料,在新会话中读取它。
    • 使用 /prototype 制作一次性代码,回答那个具体问题。
    • 再用 /handoff 整理原型带来的发现,把结论带回最初讨论想法的会话。
English · 英文原文
  1. Branch: can you settle every question in conversation? If a question needs a runnable answer (state, business logic, a UI you have to see), detour through a prototype, bridged by /handoff in both directions (a prototype lives in its own directory, which is exactly what /handoff is for; see Phase boundaries):
    • /handoff out, then open a fresh session against that file,
    • /prototype to answer the question with throwaway code,
    • /handoff back what you learned, and reference it from the original idea thread.
老师讲解 · 对应上方原文 · 含教学举例

有些问题需要讨论,有些问题需要实际试一下

原型应回答一个还无法靠讨论确定的问题。 例如“收藏是否允许游客使用”是产品决定,可以与你讨论;“这三种布局哪种读起来舒服”则更适合给你实际页面比较。

制作前说清待验证问题,结束后说清答案。换会话制作时,交接文件负责把问题、约束和资料带过去;完成后,再把经过验证的结论带回需求讨论。原型只是获取认识的过程,不能因为能运行就自动视为正式产品。

中文译文
  1. 分支判断:这项开发是否需要跨多个会话完成?
    • 如果需要,先用 /to-spec 将当前讨论整理成规格说明,再用 /to-tickets 拆成“曳光弹式工单”:每张只打通一条很小、却可以从头到尾验证的功能。每张工单都要明确声明,哪些前置任务尚未完成时会阻止它开始。

      如果采用本地任务管理,每张工单对应 .scratch/<feature>/issues/ 下的一个独立文件。执行者自己检查依赖顺序,优先完成前置任务。

      如果采用专门的工单系统,依赖关系可以变成平台内置的阻塞链接。这样,只要一张工单的所有前置任务都已完成,就可以领取执行。

      针对每张工单启动 /implement。完成一张、准备进入下一张时,用 /clear 清空上一段会话上下文。每张工单都应包含或准确引用执行所需的信息,因此下一张不必依靠保留上一张的聊天来工作。

    • 如果不需要,就在当前上下文窗口中使用 /implement 完成工作。

English · 英文原文
  1. Branch: is this a multi-session build?
    • Yes/to-spec (turn the thread into a spec), then /to-tickets to split it into tracer-bullet tickets, each declaring its blocking edges. On a local tracker that's one file per ticket under .scratch/<feature>/issues/, worked blockers-first by hand; on a real tracker the edges become native blocking links, so any ticket whose blockers are done can be grabbed: kick off /implement per ticket, /clearing context between each one. Each ticket is self-contained, so the last one's context is disposable.
    • No/implement right here, in the same context window.
老师讲解 · 对应上方原文 · 含教学举例

大任务换几次对话,下一次凭什么能继续?

这段解决的问题是:项目较大,需要多个会话完成;若需求、决定和进度只留在聊天里,新会话就容易遗漏。 作者建议把继续工作所需的信息保存到规格说明和工单中。

下面用“为学习网站增加课程收藏”这个教学例子逐步解释。

1. /to-spec:先把要做成什么写明白。 聊天里可能只有“我想收藏课程,下次找到”。规格要形成可以验收的行为:可以收藏和取消;刷新后仍保留;同一课程重复收藏不产生重复记录。后续实现和审查都拿这些条件作依据。

2. 曳光弹式工单:一次打通一条小而完整的功能。 第一张可以只完成“点收藏 → 保存记录 → 刷新仍显示已收藏”。它同时涉及页面和数据保存,但范围很小,可以独立验证。以后再做取消、列表等其他行为。不要只把工作拆成“先建所有表、再写所有接口、最后做所有页面”,否则很晚才能检查各部分是否配合。

3. 阻塞关系:明确必须先完成谁。 假设收藏属于登录用户,可以这样安排:

工单 前置条件
A:识别当前用户
B:保存当前用户的收藏 A 完成
C:展示当前用户的收藏列表 B 完成

A 没完成时,B 缺少必要前提,称为被阻塞。原文 edges 来自图中的连线,表示这些依赖。只有所有前置条件已满足的工单,才能领取。

4. 自包含:新会话能从工单找到所需信息。 工单不能只写“按刚才说的做”。应说明或准确引用目标行为、约束和依赖、相关规格或决定,以及怎样验证完成。自包含不要求复制所有材料,而要求执行者能找到它们。

5. 为什么可以清空上下文? 上一张工单的成果已经进入代码,必要决定和验证结果已经记录;下一张又提供自己的执行背景,因此可以重新读取资料开始。清空的是上一段聊天,不是删除代码、规格或工单。

这里有必要前提:继续工作需要的信息已经保存完整且可以访问。 如果关键决定还只存在于聊天中,就不能直接清空。完整交接是否成立,应看新执行者能否依靠材料继续,而不是看摘要有多短。

中文译文

无论走哪条路径,/implement 都会在内部使用 /tdd 的节奏,一次完成一小片“先测试失败、再实现通过”的行为。提交之前,再用 /code-review 从项目规范和需求规格两个方向审查改动。

如果只是想用测试先行的方法实现某个具体行为,不需要整份规格流程,可以单独使用 /tdd。如果是检查分支或 PR 相对于某个固定参照点的变化,可以单独使用 /code-review

English · 英文原文

Either way, /implement builds each issue by driving /tdd internally (one red-green slice at a time), then closes out by running /code-review, a two-axis review (Standards + Spec) of the diff, before committing. Reach for /tdd on its own when you just want to build a concrete behaviour test-first without a full spec, and /code-review on its own whenever you want to review a branch or PR against a fixed point.

老师讲解 · 对应上方原文 · 含教学举例

实现快不等于完成,检查要对准具体行为

第一轮可以先证明“收藏后能查到课程”,下一轮再证明“重复收藏不重复保存”。这就是一次一小片的测试与实现。最终审查分别核对项目规范和原始需求,避免代码很整齐却漏掉刷新后保留等关键要求。

单独的小行为可以只用 tdd;已有一组提交需要审查,可以只用 code-review。使用技能是为了解决当前问题,不必每次把整套流程从头跑完。

中文译文
管理会话上下文

从步骤 1 到步骤 3,在完成 /to-tickets 之前,尽量保持在同一个连续的上下文窗口中,不压缩、不清空。这样,访谈、规格和工单都依据同一套讨论和认识。工单形成之后,各次 /implement 再从新上下文开始,读取各自工单。

这里受作者所称的 smart zone 限制,即模型仍能较好推理的上下文范围。原文给先进模型的估计约为 150k tokens。如果还没形成工单,就已经接近作者所说的范围,不要勉强在理解能力下降后继续。应在最近的阶段结束处执行 /compact,整理后再接着做,参见“阶段边界”。

English · 英文原文
Context hygiene

Keep steps 1–3 in one unbroken context window (don't compact or clear until after /to-tickets) so the grilling, spec, and tickets all build on the same thinking. Each /implement then starts fresh, working from the ticket.

The limit on this is the smart zone: the window (~150k tokens on state-of-the-art models) within which the model still reasons sharply. If a session approaches it before /to-tickets, don't push on degraded; /compact at the nearest phase boundary and carry on (see Phase boundaries).

老师讲解 · 对应上方原文 · 含教学举例

继续、清空和压缩,改变的到底是什么?

上下文是当前模型处理任务时可用的工作材料。 它包括聊天和已经读入的代码、文档、工具结果;不是整个磁盘,也不等于项目永久记忆。

继续会话保留这些材料。clear 清掉当前聊天背景,因此需要下一任务已经有独立材料。compact 保留摘要,减少长度,但会丢失部分细节。handoff 则把接班所需信息做成可以搬到其他环境的文件。

作者给出的 150k tokens 是原文的经验估计,不是所有模型的统一硬界限。实际是否需要整理,还要看模型、任务和材料质量。若早期决定已被后来要求取代,应明确标明当前版本,不能只把冲突内容一起压进摘要。

中文译文

从其他情况进入工作流程

有时工作并非从一个新想法开始,而是从其他情况产生,再进入主流程。

  • 积压了 bug 报告和功能请求:使用 /triage。它按分诊类别和状态整理工单,形成能够交给 Agent 的工作,再由 /implement 领取。

    这里的分诊针对不是你自己整理产生的原始输入,例如别人提交的错误报告和功能请求。/to-tickets 生成的工单本来就应达到可执行程度,不要再进行一遍分诊。

  • 系统的某项行为坏了:使用 /diagnosing-bugs。它适合不容易一眼定位的错误、时有时无的问题,以及两个已知正常状态之间出现的功能退化。先建立一条能反复运行、并能针对用户报告的这个具体问题判出失败的命令,再提出原因假设,然后通过回归测试验证修复。如果排查后发现真正的结构问题是“没有合适的测试接入点来防止再次发生”,就将具体发现交给 /improve-codebase-architecture

  • 一个很大、还很模糊的目标,一次会话装不下:例如从零创建项目或设计大型功能,使用 /wayfinder。当通往目标的路径还看不清时,它在工单系统中建立由决策工单组成的共同地图,逐项解决未知。此阶段产出的是已经明确的决定,不是直接交付产品。

    一次会话能够问清的想法,可以用 /grill-with-docs;无法容纳的大型探索,才考虑 /wayfinder。后者节奏更慢,信息更多,不应用于范围已经清楚的普通功能。

    地图清楚以后,应从 /to-spec 接入主流程,把地图及链接中的决定汇总为可实现的计划,再按常规拆工单和实现。不要直接把整张地图交给 /implement,否则可能跳过汇总、漏掉链接中的细节。只有探索后发现工作其实很小,才直接实现。

English · 英文原文

On-ramps

A starting situation that generates work, then merges onto the main flow.

  • Bugs and requests piling up/triage. It moves issues through triage roles and produces agent-ready issues, which /implement later picks up.

    Triage is only for issues you didn't create: bug reports, incoming feature requests, anything that arrives raw. Tickets that /to-tickets produced are already agent-ready, so don't triage them.

  • Something's broken/diagnosing-bugs. For the hard ones: the bug that resists a first glance, the intermittent flake, the regression that crept in between two known-good states. It refuses to theorise until it has a tight feedback loop (one command that already goes red on this bug), then fixes with a regression test. Its post-mortem hands off to /improve-codebase-architecture when the real finding is that there's no good seam to lock the bug down.

  • A huge, foggy effort: a greenfield project or a huge feature build, too big for one session/wayfinder, the most cognitively demanding flow here. When the way from here to the destination isn't visible yet, it charts a shared map of decision tickets on the issue tracker and resolves them one at a time, producing decisions, not deliverables, until the fog is pushed back and the way is clear. Where /grill-with-docs sharpens an idea you can hold in one session, wayfinder is for the idea you can't, and it's slower and denser, so save it for exactly that, never a well-scoped feature.

    When the map clears, it hands off, it doesn't build: merge onto the main flow at /to-spec, which collapses the map's linked decisions into a buildable plan, then /to-tickets and /implement as usual. Looping the map straight into /implement skips that collapse and throws the linked detail away, so go straight to /implement only when the effort turned out genuinely small.

老师讲解 · 对应上方原文 · 含教学举例

三类起点:有人提需求、系统出故障、目标尚不清楚

“有人提了二十条反馈”先需要判断哪些成立、哪些缺信息,适合 triage。“收藏偶尔丢失”需要复现并验证原因,适合 diagnosing-bugs。“想做一个完整 AI 导师平台,但关键方向未定”可能需要 wayfinder。

wayfinder 的决策地图还不是实现工单。把“采用个人进度而非班级排名”的决定做清楚后,仍需汇总成规格,再说明怎样实现和验收。不要因为已经有很多文档,就认定开发背景自然齐备。

中文译文

维护代码库的健康

这一部分是维护工作。

  • 有空时使用 /improve-codebase-architecture,寻找值得改善的结构,使代码更适合 Agent 查找、理解和修改。它寻找能把模块对外用法变简单、内部承担更多工作的机会。你选择某个候选后,就形成了一个待澄清的改进想法,可以从 /grill-with-docs 进入主流程。该技能负责发现候选;真正设计所选模块时,使用下面的 /codebase-design
English · 英文原文

Codebase health

Not feature work, just upkeep.

  • /improve-codebase-architecture runs whenever you have a spare moment to keep the codebase good for agents to operate in. It surfaces deepening opportunities; picking one generates an idea you can take into the main flow at /grill-with-docs. It's the survey that finds the candidates; /codebase-design (below) is the bench you design the chosen one on.
老师讲解 · 对应上方原文 · 含教学举例

架构检查先给你值得改的候选

假设每加一个练习题型,都要同步修改五处重复逻辑。架构检查可以提出把相关行为集中到一个模块,并解释如何减少未来修改成本。你选定后,再澄清范围和设计。

codebase-design 提供比较方案的概念;improve-codebase-architecture 负责寻找真实痛点。文件少一点不是充分理由,关键是具体工作会怎样变容易。

中文译文

支撑其他技能的共同词汇

下面两个参考技能可以由模型按需要加载,它们分别集中定义一组共同词汇。若问题在于“某个词到底指什么”,可以直接使用;也可以由上层技能引入。

  • /domain-modeling:澄清项目的业务语言,质疑模糊名称,区分一个词承载的不同含义,例如同一个“账户”实际上指三种对象。它还按条件记录难以撤销的架构决定。/grill-with-docs 通过它在讨论中持续维护 CONTEXT.md,使词汇表清楚一致。
  • /codebase-design:提供讨论代码结构的语言,包括模块、接口、深度、可替换的衔接位置、适配器、调用收益和修改集中性。它帮助设计模块的形状:通过简洁的使用接口,集中承担较多行为。/tdd/improve-codebase-architecture 都采用这组概念。
English · 英文原文

Vocabulary underneath

Two model-invoked references that run beneath the other skills, each the single source of truth for its vocabulary. Reach for them directly when the words, not the process, are the problem; or let the skills above pull them in.

  • /domain-modeling: sharpen the project's domain language: challenge a fuzzy term, resolve an overloaded word ("account" doing three jobs), record a hard-to-reverse decision as an ADR. It's the active discipline /grill-with-docs drives to keep CONTEXT.md a clean glossary.
  • /codebase-design is the deep-module vocabulary (module, interface, depth, seam, adapter, leverage, locality) for designing a module's shape: a lot of behaviour behind a small interface at a clean seam. /tdd and /improve-codebase-architecture both speak it.
老师讲解 · 对应上方原文 · 含教学举例

共同词汇使不同技能在谈同一件事

“课程”和“课时”属于业务概念;“模块”“接口”“测试接入点”属于工程概念。两套语言都需要清楚,但用途不同。

比如接口不只是代码里一行类型声明,还包括调用者必须知道的操作顺序、错误和配置。本文将这些定义放在参考技能中,上层技能使用时再读取,减少同一概念在不同文件中各说各话。

中文译文

一个阶段结束后,怎样接着工作

阶段是会话中的一段工作,例如澄清想法、实现代码或质量检查。一个阶段结束、下一个阶段开始时,有五种选择。这是整套方法中需要较多判断的地方:

  • 继续当前会话:保持原有材料,没有切换成本,也不丢失信息。
  • /clear:如果当前内容对下一步已经没有必要,清空上下文窗口。
  • /handoff:写成一份可携带的 Markdown 交接文件。作者主要将它用于换到另一种 Agent 运行环境、另一个目录、另一位同事,或者在阶段中途分出旁支任务。它的价值是让工作背景可以搬过去。
  • 子 Agent:把范围明确的任务交给独立上下文中的执行者,再取回报告。
  • /compact:把当前上下文概括成摘要,供后续会话继续。它是前面选择都不合适时的默认落点,不是每次首先使用的操作。

进一步阅读 PHASE-BOUNDARIES.md。其中给出五个按顺序判断的问题、各条分支的理由,以及为什么考虑原始信息损失时,应先判断能否继续当前会话。在阶段结束处作选择;阶段尚未完成时,继续当前工作,或者将剩余的明确任务交给子 Agent。

English · 英文原文

Phase boundaries

A phase is a chunk of work inside a session: the grilling, the implementation, the QA. At the boundary between two of them you have five options, and picking between them is the fuzziest decision in this whole map:

  • Continue: stay put. Costs nothing, loses nothing.
  • /clear: empty the window, when nothing here matters to what's next.
  • /handoff writes a portable markdown file. Narrow: only for a new harness, a new directory, a colleague, or forking a side task mid-phase. What it buys is portability.
  • Subagent: send a tightly-scoped task to its own window and get a report back.
  • /compact compresses this context and seeds a fresh session with it. The default, at the bottom of the tree rather than the first reach.

Read PHASE-BOUNDARIES.md for the ordered tree: the five questions, the reasoning behind each branch, and why the primary-source cost makes Continue the one to rule out first. Make the decision at a boundary; mid-phase, continue or split the rest into subagents.

老师讲解 · 对应上方原文 · 含教学举例

把切换放在一个阶段结束处,更容易带走完整结果

假设需求讨论已经完成,你手中有确认后的规格,这就是一个比较清楚的阶段结束点。若调查只进行了一半,证据尚未记录,立即清空会让后续工作不知道哪些是假设、哪些已经验证。

选择取决于下一步是否仍需要原材料,以及工作是否要搬到其他环境。原文的五个选项并不表示各客户端都有完全相同的命令。实际调用时,要确认当前工具提供哪种切换方式。

中文译文

可以独立使用的技能

以下技能不必经过整条主流程:

  • /grill-me:和 /grill-with-docs 使用同一种深入追问方式,但不负责把状态保存在本地,也不建立 CONTEXT.md。没有工作目录时,例如讨论计划、设计或文章,可以使用它;有目录可以留存材料时,作者优先选择带记录的版本。
  • /grilling:基础访谈方法本身,包括一轮一轮提问、判断当前有哪些问题可问,以及“事实由 Agent 查、决定由用户做”。/grill-me/grill-with-docs 是它的两个入口;分诊、路径探索和架构改善也会在内部使用它。需要直接使用基础访谈方法时,再单独调用。
  • /resolving-merge-conflicts:用于已经发生的 Git 合并或变基冲突。逐段追溯双方改动的原始意图,再组合出符合目标的结果,并完成操作,不只是选保留哪些行。作者要求在这个流程中继续解决,而不执行 --abort 中止。
  • /prototype:用小型一次性程序回答一个设计问题,例如状态变化是否合理、界面应该是什么样。一次性描述的是代码的用途和完善程度,并不等于不留下依据。验证结论进入正式代码;原型保存在主分支外的 prototype/<name> 分支,作为一手材料由实现工单引用。它既是主流程第 2 步的旁路,也可用于其他难以只靠文字判断的设计问题。
  • /research:把查阅资料的工作交给后台 Agent。它从一手来源调查,并在仓库保存逐项引用来源的 Markdown 笔记。在它阅读时,你可以继续其他工作。研究笔记可以带进 /grill-with-docs,为判断提供材料。
  • /to-questionnaire:如果缺少的信息掌握在别人那里,而不在你的脑中或代码库中,就生成问卷请对方回答。它先问清问卷发给谁、希望拿回什么,再围绕缺口写问题;不是要求你代替收件人回答。回收结果可以带入需求讨论或规格整理。
  • /wizard:处理确实只有人能完成的操作,例如开通服务、配置凭据和 CI 密钥、操作第三方后台,以及一次性迁移或切换。它生成交互式 Bash 向导,打开网址、收集值并写入 .env 或 GitHub secrets,避免每次从头解释。模型遇到必须由用户操作的环节时可以调用;Agent 自己能够做的事情,仍应自行完成。
  • /wait-what:当上一段解释没有讲明白时,要求 Agent 补足背景,使用项目统一术语和容易理解的英语重新讲述。任何技能运行期间都可用于澄清。它帮助修正已经发生的理解困难;早期建立共同语言则有助于减少这种困难。
  • /teach:把当前目录作为保存学习状态的工作区,跨多个会话学习某个概念。
  • /writing-for-agents:编写给 Agent 阅读的文档时使用,包括技能、AGENTS.md 和被其他文档引用的参考资料。
English · 英文原文

Standalone

Off the main flow entirely.

  • /grill-me: the same relentless interview as /grill-with-docs, but stateless: it saves nothing locally and builds no CONTEXT.md. Reach for it when you are not working in a working directory (sharpening a plan, a design, a piece of writing, anything with no repo under it). If you are in a working directory, use /grill-with-docs instead: it runs the same interview and leaves a paper trail, so it is strictly the better one.
  • /grilling is the interview primitive itself: rounds, the frontier, facts are the agent's job and decisions are yours. /grill-me and /grill-with-docs are the two named ways in, and /triage, /wayfinder and /improve-codebase-architecture all run it internally. Reach for it directly only when you want the interview with no wrapper around it.
  • /resolving-merge-conflicts works an in-progress merge or rebase conflict hunk by hunk, resolving by intent traced to each side's primary source rather than by picking lines, then finishes the operation. It never runs --abort. Standalone and off every flow: reach for it when you are already mid-conflict.
  • /prototype is a small, throwaway program that answers one design question: does this state model feel right, or what should this UI look like. Throwaway is a constraint on how the code is written, not a promise to destroy it: the answer folds into the real code, and the prototype itself is kept as a primary source on a prototype/<name> branch out of main, pointed at from the implementation issue. It's the detour in step 2 of the main flow, but reach for it any time a design question is hard to settle on paper.
  • /research: delegate reading legwork to a background agent: it investigates a question against primary sources, then leaves a cited Markdown file in the repo. Keep working while it reads. The file it produces is something to take into the main flow at /grill-with-docs, since research feeds the thinking rather than replacing it.
  • /to-questionnaire comes in when the thing blocking you isn't in your head or the codebase but in someone else's, and it writes them a questionnaire to fill in. It's the inverse of /grill-me: instead of interviewing you about the subject, it interviews you about the send (who it's going to, what you need back) and aims the questions at the gap. What comes back is material for /grill-with-docs or /to-spec.
  • /wizard is for the steps only a human can take: provisioning infrastructure, setting up credentials or CI secrets, clicking through an unfamiliar third-party dashboard, running a one-off migration or cutover. It generates an interactive bash script that opens each URL, captures each value, and writes it into .env and GitHub secrets, so the procedure stops being something you re-explain to an agent every time. Model-invoked, so the agent reaches for it the moment it hits a wall only you can pass. If the agent could just do it itself, it should; this is for where a human is genuinely in the loop.
  • /wait-what is the corrective for a message that didn't land. Use it mid-conversation, inside any other skill, and the agent re-pitches what it just said with the context you were missing, in plain English, using the CONTEXT.md vocabulary. It works after the fact; /grill-with-docs is the upfront cure, because a shared language agreed early is what stops the jargon arriving at all.
  • /teach: learn a concept over multiple sessions, using the current directory as a stateful workspace.
  • /writing-for-agents is the reference for writing documents agents consume: skills, AGENTS.md, pointed-at docs.
老师讲解 · 对应上方原文 · 含教学举例

独立技能按问题使用,不必经过代码开发主流程

如果你只是想让 AI 把上一段解释讲清楚,可以用 wait-what,不需要先写规格或建工单。如果需要业务同事提供信息,可以用 to-questionnaire;如果需要你登录某服务完成设置,可以用 wizard 编排必要的人工操作。

teach 组织学习,writing-for-agents 帮助写给 Agent 阅读的说明。每个都有自己的输入和产物。你应先问“我此刻缺什么”,再选方法,而不是为了练习命令硬塞进整条工程流程。

中文译文

开始前需要完成的配置

首次使用工程流程前,运行 /setup-matt-pocock-skills,确定其他技能依赖的工单系统、分诊标签和文档布局。它也支持用户自己的工单管理流程。

English · 英文原文

Precondition

/setup-matt-pocock-skills: run before your first engineering flow to configure the issue tracker, triage labels, and doc layout the other skills assume. Custom issue trackers also work.

老师讲解 · 对应上方原文 · 含教学举例

setup 记录项目约定,安装让客户端找到技能

安装技能后,客户端能够发现并读取它的说明,但还不一定知道这个项目把工单放在哪里。setup 把工单位置、标签和文档布局写清楚,供其他技能使用。

它不会自动让每个客户端拥有相同工具,也不等于已经获得外部账号权限。知道一份 Markdown 讲什么、让客户端加载它、让环境有能力执行其中动作,是三个需要分别理解的环节。

原作者:Matt Pocock · 中文翻译为非官方译本

来源:skills/engineering/ask-matt/SKILL.md ↗

固定版本:3cca18b368ae95cdbdebbff572ccafa662551015

配套参考资料(英文)

先作答,再看参考思路

Q1 · 理解

用自己的话说明:它解决什么问题,完成后会留下什么?

请各用一句话回答。若它只做规划或解释,不要把“已开发”“已部署”写成产物。

Q2 · 判断

同样是“继续项目”,为什么不能固定使用 implement?

我已思考,查看参考思路

因为继续可能是在继续决策、诊断或实现。应先读实际状态;implement 接受可执行工作,不能替代尚未完成的需求决定。

Q3 · 追问

原文中哪条要求在你的环境下可能不成立?

说出具体一句及其前提,例如工具不可用、资料缺失、已有项目约定冲突,或它只是作者偏好。把你的答案带回课堂,我们据此继续讨论。

课堂回传格式:第 01 课 / 我的理解 / Q2 回答 / 仍不理解的原句。这里是阅读教材;实时问答在我们的对话中进行。

把方法放进一个具体情境

教学案例:你说“AI 工程做不下去了”。如果已有稳定报错,应先诊断;如果连最终做什么都不清楚,应先澄清;如果各任务明确却无人执行,单靠路由技能不能修复调度。

边界与容易误读的地方

最容易误读的是把推荐路径当成每次必走的流水线。很小的修改可能直接实现,巨大而模糊的项目才值得用 wayfinder。

讨论后再实践:先判断上述情境是否适用,再选择真实任务。现在无需安装、运行命令或修改现有项目。

关联阅读