agentleFS
takayoshitoyoda05takayoshitoyoda05/claude-ml-template/.claude/skills/diagnosing-bugs/SKILL.md

diagnosing-bugs

Skill1 starsChanged 2 months agoMITView on GitHub

原因不明のバグ・性能劣化が出たとき、「原因を調べて」「バグを直したい」と言われたときに必ず使う。

193 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use setup-ts-deep-modules, loop-me 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.
  • liufeng1976Skill

    setup-ts-deep-modules

    Wire dependency-cruiser into a TypeScript repo so each package is a deep module — implementation hidden in subfolders, reachable only through its entry-point files. User-invoked.

    Also in 49 projects that use this

  • RoentekSkill

    loop-me

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

    Also in 62 projects that use this

  • LesaniSkill

    writing-beats

    Shape an article as a journey of beats, choose-your-own-adventure style. The user picks a starting beat from the raw material, you write only that beat, then offer options for where to pivot next, beat by beat, until the article reaches a natural end. Use when the user has raw material and wants to assemble it as a narrative rather than an argument.

    Also in 66 projects that use this

  • AWSSkill

    to-questionnaire

    Turn a decision you can't fully answer into a questionnaire for someone else to fill in.

    Also in 101 projects that use this

  • LesaniSkill

    writing-shape

    Take a markdown file of raw material and shape it into an article through a conversational session — drafting candidate openings, growing the piece paragraph by paragraph, arguing about format (lists, tables, callouts, quotes) at each step. Use when the user has a pile of notes, fragments, or a rough draft and wants help turning it into something publishable.

    Also in 63 projects that use this

  • AWSSkill

    wizard

    Generate an interactive bash wizard that walks a human through steps only they can perform. Use when provisioning infrastructure, setting up credentials or CI secrets, walking an unfamiliar third-party dashboard, or running a one-off migration or cutover. Don't invoke this for steps the agent can perform itself.

    Also in 138 projects that use this

  • +1 more from Lesani
  • +2 more from aws

The file

Files
SKILL.md

バグ診断ループ

推測でコードを直すのではなく、以下の手順を順番に踏んで原因を特定する。 ステップを飛ばさない。

手順

  1. 再現(Reproduce)
    • 問題が起きる最小限の入力・コマンドを確認する。
    • 再現できない場合は、ここで立ち止まりユーザーに再現条件を確認する。
  2. 最小化(Minimise)
    • 再現に必要な条件を削っていき、問題を引き起こす最小構成を特定する。
    • 例: 全データセットではなく1サンプルで再現するか確認する。
  3. 仮説(Hypothesise)
    • 原因の仮説を1つ立てる。複数の仮説がある場合は、最も検証しやすいものから 順に1つずつ検証する(同時に複数を疑わない)。
  4. 計測(Instrument)
    • 仮説を検証するため、ログ出力・print・アサーションなどで実際の値を 確認する。推測ではなく実測する。
    • この段階でのコード変更は最小限の計測コードに留める。
  5. 修正(Fix)
    • 仮説が実測で裏付けられたら、根本原因に対する最小限の修正を行う。
    • 症状を隠すだけの対症療法(例: try/exceptで握りつぶす)をしない。
  6. 回帰テスト(Regression-test)
    • 修正後、元の再現条件で問題が解消したことを確認する。
    • 可能であれば、この不具合を検出する自動テストを追加し、再発を防ぐ。

診断ログ

各ステップでの発見を .claude/plans/debug-YYYYMMDD-<topic>.md に記録する。 原因が特定でき修正方針が固まったら、その内容を Planner に渡して正式な 実装計画に落とし込んでもよい。

注意

  • 途中で「たぶんこれが原因」と決めつけて修正に飛びつかない。仮説は必ず 計測で裏付けてから修正する。
  • スコープ外のファイルを調査・編集しない。CLAUDE_WORK_SCOPE に従う。

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.