agentleFS
535803710535803710/ai-rd-skills/skills/diagnose/SKILL.md

diagnose

Skill8 starsChanged 7 months agoMITView on GitHub

系统化诊断复杂 bug、测试失败和性能回退,按复现、最小化、假设、观测、修复、回归测试循环推进;当用户说 debug、diagnose、报错、失败、性能变慢时使用。

126 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use zoom-out, to-issues and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • Hollis36Skill

    zoom-out

    Tell the agent to zoom out and give broader context or a higher-level perspective. Use when you're unfamiliar with a section of code or need to understand how it fits into the bigger picture.

    Also in 38 projects that use this

  • ninehillsSkill

    to-issues

    Break a plan, spec, or PRD into independently-grabbable issues on the project issue tracker using tracer-bullet vertical slices.

    Also in 34 projects that use this

  • Hollis36Skill

    to-prd

    Turn the current conversation context into a PRD and publish it to the project issue tracker. Use when user wants to create a PRD from the current context.

    Also in 38 projects that use this

  • kayamanSkill

    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.

    Also in 11 projects that use this

  • kayamanSkill

    request-refactor-plan

    Guides creating a detailed refactor plan with tiny commits via user interview, then files it as a GitHub issue. Use when user wants to plan a refactor, create a refactoring RFC, or break a refactor into safe incremental steps.

    Also in 9 projects that use this

  • AnasX7Skill

    scaffold-exercises

    Create exercise directory structures with sections, problems, solutions, and explainers that pass linting. Use when user wants to scaffold exercises, create exercise stubs, or set up a new course section.

    Also in 13 projects that use this

  • +2 more from kayaman

The file

Files
SKILL.md

Diagnose

目标

不要直接猜修复。先复现问题,再缩小范围,再提出假设,最后用观测和回归测试证明修复有效。

诊断循环

  1. Reproduce:复现问题,记录命令、输入、现象和期望。
  2. Minimise:缩小到最小可复现路径。
  3. Hypothesise:列出 1-3 个最可能原因。
  4. Instrument:加日志、断点、测试或静态检查验证假设。
  5. Fix:做最小修复。
  6. Regression-test:补回归测试或明确人工验证步骤。

原则

  • 不要同时改多个无关点
  • 不确定就先观测,不要编造原因
  • 修复后要能解释为什么问题不会再发生
  • 如果需要人工参与,可参考 scripts/hitl-loop.template.sh

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.