本文へ移動
cccskills
無料GitHub で公開

root-cause-tracing

Trace bugs backward to their origin, not just symptoms

インストール方法を見る

含まれるファイル(1)

  • SKILL.md3.0 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Root Cause Tracing

Core Principle

TRACE BACKWARD TO THE BUG'S ORIGIN
Don't patch symptoms - fix the disease

The Backward Trace Method

SYMPTOM
   ↓ Where does this value come from?
IMMEDIATE CAUSE
   ↓ What set that to wrong value?
DEEPER CAUSE
   ↓ Why did that happen?
ROOT CAUSE ← Fix HERE

Practical Steps

1. Start at Symptom

Q: What exactly went wrong?
→ Document the exact symptom
→ Note file, line, error message

2. First Backward Step

Q: Where does this value/state come from?
→ Find the direct source
→ Check: is THIS the bug or just a carrier?

3. Keep Tracing

Q: What set THAT to the wrong value?
→ Follow the data flow backward
→ Each step: is this the origin or just passing it along?

4. Identify Root

SIGNS YOU'VE FOUND ROOT:
- Logic error in requirements interpretation
- Initial state incorrectly set
- Wrong assumption in algorithm
- Missing validation at entry point
- Broken invariant at creation

Stop Conditions

You've found root cause when:

  • There's no earlier source to trace
  • The error was introduced HERE (not inherited)
  • Fixing HERE prevents the bug entirely
  • The "why" answer is: "wrong logic/design"

You're still at symptoms if:

  • The wrong value came from somewhere else
  • Another function passed bad data
  • It's a consequence, not origin
  • Fixing here = adding a workaround

Common Patterns

Bug PatternRoot Usually At
Wrong value displayedData calculation, not display code
Null pointerWhere object should've been created
Off-by-oneLoop bounds definition, not body
Race conditionShared state design, not specific access
Invalid stateState transition logic, not current handler

Anti-Patterns (Don't Do This)

❌ Symptom Patching

// Bad: Fix where error happens
if (value === undefined) value = defaultValue
// Good: Find why value is undefined

❌ Guard Stacking

// Bad: Add guards everywhere
if (x) if (y) if (z) doThing()
// Good: Ensure x, y, z correct at source

❌ Quick Fix Pressure

"Just make it work" → Technical debt
Better: "5 more minutes tracing saves 5 hours debugging later"

Verification

After identifying root cause:

  1. Explain the chain - Symptom ← caused by ← caused by ← ROOT
  2. Confirm origin - "This is where wrong value first appears"
  3. Fix at root - Change the origin, not the symptoms
  4. Verify fix - Original symptom gone + no new bugs

Integration with Checkers

Use with:

  • assumption-checker → Was root cause an assumption?
  • dependency-validator → Was root cause a broken dependency?
  • pre-action-verifier → Verify root cause fix before applying

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Complete methodology for preventing AI hallucinations. Use when accuracy is critical and you need Claude to verify before claiming, cite before asserting, and admit uncertainty instead of guessing.

日本語の概要は準備中です。原文の説明を表示しています。

a-ariff/ariff-claude-plugins142026年3月29日 更新

Transform rough ideas into solid designs through structured questioning

日本語の概要は準備中です。原文の説明を表示しています。

a-ariff/ariff-claude-plugins142026年3月29日 更新

Canvas API Connection Skill

日本語の概要は準備中です。原文の説明を表示しています。

a-ariff/ariff-claude-plugins142026年3月29日 更新

Forces every code-related claim to include file:line citations. No citation means the claim must be verified or removed. Use when building documentation, writing code reviews, or any output that others will rely on.

日本語の概要は準備中です。原文の説明を表示しています。

a-ariff/ariff-claude-plugins142026年3月29日 更新

Assign confidence scores (0-100) to every claim in a response. Helps users understand which parts are verified facts and which are educated guesses. Use when the user needs to know how much to trust each part of the answer.

日本語の概要は準備中です。原文の説明を表示しています。

a-ariff/ariff-claude-plugins142026年3月29日 更新

Forces Claude to extract exact quotes from files before making claims about them. Prevents hallucinations by grounding every statement in actual text from the codebase. Use when working with large files or unfamiliar code.

日本語の概要は準備中です。原文の説明を表示しています。

a-ariff/ariff-claude-plugins142026年3月29日 更新

a-ariff のスキルをすべて見る

このスキルの問題を報告する