Community编程与开发github.com

mattpocock/ask-matt

根据你的需求,推荐最合适的技能或工作流程。作为本仓库所有技能的导航路由器。

ask-matt 是什么?

Ask Matt 是一个元技能(路由器),帮助开发者和 AI 智能体用户快速找到最适合当前场景的技能或工作流。它围绕一条“从想法到交付”的主干流程设计,结合了打磨思路、原型验证、PRD 生成、任务拆分、TDD 实现和代码审查等步骤,形成一个端到端的工程方法论。此外,它还提供了故障排查(triage)、bug 诊断、代码架构改进、领域建模等技能,覆盖了代码库健康维护和词汇层定义。它支持 Claude Code 等 AI 编码工具,强调上下文窗口管理(如 handoff 跨会话续接、compact 阶段内压缩),并假设项目已通过 /setup-matt-pocock-skills 完成初始配置。它的核心价值在于将松散的单点技能组织成一个可导航的系统,避免用户在众多工具中迷失方向。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/mattpocock/skills/tree/main/skills/engineering/ask-matt

Installed? Explore more 编程与开发 skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

Ask Matt

你不可能记住所有技能,所以直接问。

一个流程是贯穿多个技能的一条路径。大多数路径沿一条主干流程运行,并由两个入口汇入。其余技能都是独立存在的,或作为底层词汇层运行。

主干流程:从想法到交付

这是大多数工作遵循的路线。你有一个想法,希望把它构建出来。

  1. /grill-with-docs — 通过访谈来打磨想法。当你有代码库时从这开始:它是有状态的,会将学到的东西保留在 CONTEXT.md 和 ADR 中。(没有代码库?请使用 /grill-me — 参考独立技能部分。两者都运行相同的 /grilling 原语;grill-with-docs 是留下纸质记录的那个。)

  2. 分支 — 你能在对话中解决所有问题吗? 如果某个问题需要一个可运行的答案(状态、业务逻辑、必须看到的 UI),请通过原型绕道,并用 /handoff 双向桥接(参考跨会话部分):

    • 使用 /handoff 导出,然后打开一个新会话针对该文件,
    • 使用 /prototype 用一次性代码来回答问题,
    • 使用 /handoff 将学到的内容带回来,并在原始想法线程中引用它。
  3. 分支 — 这是一个需要多个会话的构建吗?

    • 是 → /to-prd(将线程转换为 PRD)→ /to-issues(将 PRD 拆分为可独立领取的任务)。因为任务是独立的,所以每个任务之间要清除上下文:每个任务启动一个新会话,并通过传递 PRD 和单个任务来启动 /implement。
    • 否 → 直接在这里、在同一个上下文窗口中执行 /implement。

    无论哪种方式,/implement 都会通过内部驱动 /tdd 来构建每个任务——一次一个红-绿循环——然后在提交之前通过运行 /code-review(一个双轴审查:标准 + 规格)来收尾。当你只想在没有完整规格的情况下以测试优先的方式构建一个具体行为时,可直接使用 /tdd;当你想对照某个固定点审查一个分支或 PR 时,也可直接使用 /code-review。

上下文卫生

将步骤 1-3 保持在一个连续的上下文窗口中——在完成 /to-issues 之前不要压缩或清除——这样打磨、PRD 和任务都建立在相同的思路之上。之后每个 /implement 都从头开始,基于任务进行工作。

这种做法的限制在于 智能区:模型仍能清晰推理的窗口(最先进模型大约 120k tokens)。如果在到达 /to-issues 之前会话接近这个限制,不要用退化的模型继续推进——使用 /handoff 并在一个新线程中继续。

入口

一个产生工作并汇入主干流程的起始场景。

  • Bug 和请求堆积 → /triage。它将任务通过分类角色流转,并生成智能体可用的任务,后续由 /implement 接取。

    分类只适用于不是你创建的任务——Bug 报告、传入的功能请求、任何原始输入。/to-issues 产生的任务已经对智能体就绪,所以不要对它们进行分类。

  • 某处出问题了 → /diagnosing-bugs。用于处理棘手的 Bug:那些扫一眼看不出来的 Bug、间歇性 flake、在两个已知良好状态之间悄悄出现的回归。它拒绝在没有紧密反馈循环(一个命令已经在这个 Bug 上变红)的情况下进行理论推测,然后通过回归测试修复它。当真正的问题在于没有好的接缝来锁定 Bug 时,它的复盘会交给 /improve-codebase-architecture。

代码库健康

不是特性工作——而是日常维护。

  • /improve-codebase-architecture — 只要你有空闲时间就运行它,以保持代码库对智能体操作友好。它揭示深化机会;选择一个机会会生成一个想法,你可以将其带入主干流程的 /grill-with-docs 阶段。它是发现候选方案的调查阶段;/codebase-design(见下文)是你在其中设计选定方案的工作台。

底层词汇

两个由模型调用的引用,运行在其他技能之下——每个都是其词汇的唯一真实来源。当问题出在词而不是过程时,直接使用它们;或让上述技能将它们拉入。

  • /domain-modeling — 打磨项目的领域语言:质疑模糊术语,解决过载的词语(例如“account”承担三种工作),将难以撤销的决定记录为 ADR。这是 /grill-with-docs 所驱动的主动训练,以保持 CONTEXT.md 成为一份清晰的词汇表。
  • /codebase-design — 深层模块的词汇表(模块、接口、深度、接缝、适配器、杠杆作用、局部性),用于设计模块的形状:在一个干净接缝处,用一个小接口承载大量行为。/tdd 和 /improve-codebase-architecture 都使用它。

跨会话

  • /handoff — 当一个线程已满或你需要分支(例如进入一个 /prototype 会话)时,它将对话压缩成一个 markdown 文件。你不会在原地继续——你会打开一个新会话并引用那个文件来跨会话传递上下文。它是上下文窗口之间的桥梁,可双向使用。当你想要一个新会话但需要保留当前对话时使用它。
  • /compact(内置)— 保持在同一对话中,让较早的轮次被总结。在阶段之间的刻意断点使用它,当你不介意丢失逐字历史时。不要在阶段中途压缩——智能体可能会迷失方向。/handoff 创建分支;/compact 继续。

独立技能

完全脱离主干流程。

  • /grill-me — 与 /grill-with-docs 一样不留情面的访谈,但适用于你没有代码库的情况。无状态:它不保存任何东西到本地,不构建 CONTEXT.md。用它来打磨任何不在仓库中的计划或设计。
  • /prototype — 一个小的、一次性程序,回答一个设计问题:这个状态模型感觉对吗,或者这个 UI 应该长什么样。从第一天起就是一次性的——保留答案,删除代码。它是主干流程步骤 2 中的绕道,但任何时候当设计问题难以在纸上决定时都可以使用它。
  • /research — 将阅读的体力活委托给一个后台智能体:它针对一手资料调查一个问题,然后在仓库中留下一个带引用的 Markdown 文件。你在它阅读的同时继续工作。它生成的文件可以带进主干流程的 /grill-with-docs 阶段——研究为思考提供输入,但不取代它。
  • /teach — 在多次会话中学习一个概念,使用当前目录作为有状态的工作区。
  • /writing-great-skills — 关于如何写好和编辑技能的参考。

前置条件

/setup-matt-pocock-skills — 在第一个工程流程之前运行,以配置任务追踪器、分类标签和文档布局,这些是其他技能所假设的。自定义任务追踪器也可以工作。

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

mattpocock/caveman

Ultra-compressed communication mode. Cuts token usage ~75% by dropping filler, articles, and pleasantries while keeping full technical accuracy. Use when user says "caveman mode", "talk like caveman", "use caveman", "less tokens", "be brief", or invokes /caveman.

mattpocock/claude-handoff

Hand the current conversation off to a fresh background agent that picks up the work immediately.

mattpocock/codebase-design

Shared vocabulary for designing deep modules. Use when the user wants to design or improve a module's interface, find deepening opportunities, decide where a seam goes, make code more testable or AI-navigable, or when another skill needs the deep-module vocabulary.

mattpocock/design-an-interface

Generate multiple radically different interface designs for a module using parallel sub-agents. Use when user wants to design an API, explore interface options, compare module shapes, or mentions "design it twice".

mattpocock/diagnose

Disciplined diagnosis loop for hard bugs and performance regressions. Reproduce → minimise → hypothesise → instrument → fix → regression-test. Use when user says "diagnose this" / "debug this", reports a bug, says something is broken/throwing/failing, or describes a performance regression.

mattpocock/diagnosing-bugs

Diagnosis loop for hard bugs and performance regressions. Use when the user says "diagnose"/"debug this", or reports something broken/throwing/failing/slow.

mattpocock/domain-modeling

Build and sharpen a project's domain model. Use when the user wants to pin down domain terminology or a ubiquitous language, record an architectural decision, or when another skill needs to maintain the domain model.

mattpocock/edit-article

Edit and improve articles by restructuring sections, improving clarity, and tightening prose. Use when user wants to edit, revise, or improve an article draft.

mattpocock/git-guardrails-claude-code

Set up Claude Code hooks to block dangerous git commands (push, reset --hard, clean, branch -D, etc.) before they execute. Use when user wants to prevent destructive git operations, add git safety hooks, or block git push/reset in Claude Code.

mattpocock/grilling

Grill the user relentlessly about a plan or design. Use when the user wants to stress-test a plan before building, or uses any 'grill' trigger phrases.

mattpocock/grill-me

Interview the user relentlessly about a plan or design until reaching shared understanding, resolving each branch of the decision tree. Use when user wants to stress-test a plan, get grilled on their design, or mentions "grill me".

mattpocock/grill-with-docs

Grilling session that challenges your plan against the existing domain model, sharpens terminology, and updates documentation (CONTEXT.md, ADRs) inline as decisions crystallise. Use when user wants to stress-test a plan against their project's language and documented decisions.

mattpocock/handoff

Compact the current conversation into a handoff document for another agent to pick up.

mattpocock/implement

Implement a piece of work based on a PRD or set of issues.

mattpocock/implement-spec

Implement a specification in code.

mattpocock/improve-codebase-architecture

Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.

mattpocock/loop-me

Grill me about specs for the workflows I want to build, within this workspace.

mattpocock/migrate-to-shoehorn

Migrate test files from `as` type assertions to @total-typescript/shoehorn. Use when user mentions shoehorn, wants to replace `as` in tests, or needs partial test data.

mattpocock/obsidian-vault

Search, create, and manage notes in the Obsidian vault with wikilinks and index notes. Use when user wants to find, create, or organize notes in Obsidian.

mattpocock/prototype

Build a throwaway prototype to flesh out a design — a runnable terminal app for state/business-logic questions, or several radically different UI variations toggleable from one route.

相关技能