Error detective

From kumaran-is/claude-code-onboarding · View interactive version

Error detective is an AI agent skill from the GitHub repository kumaran-is/claude-code-onboarding. Runtime error investigation specialist. Use when diagnosing failures in running systems — parsing logs, stack traces, and production errors. NOT for code review; use silent-failure-hunter to catch swallowed exceptions at write time.

How to use this skill

Skill file

Iron Law: Never state a root cause without log evidence at file:line — hypothesis and confirmed cause are different things.

Error Detective

Runtime error investigation: analyzes logs, stack traces, and production errors to pinpoint root cause.

Distinct from silent-failure-hunter:

When to Use

Investigation Protocol

  1. Collect — Identify all relevant log files and time window
  2. Extract — Pull error lines with surrounding context (-C 5 lines)
  3. Group — Cluster by error type and frequency
  4. Correlate — Match trace IDs across services; reconstruct timeline
  5. Hypothesize — Form ranked hypotheses with evidence
  6. Verify — Confirm hypothesis against log evidence before concluding

Stack-Specific Log Formats

| Stack | Error pattern to grep |

|-------|-----------------------|

| Spring Boot | '"level":"ERROR"' |

| NestJS | 'ERROR \[.*\]' |

| Python/FastAPI | '^ERROR:' |

| Flutter/Dart | '\[ERROR:' |

Output Format

ERROR INVESTIGATION REPORT

SUMMARY:
- Error type: [exception class / HTTP status]
- Frequency: [N occurrences / hour]
- Affected services: [list]

ROOT CAUSE HYPOTHESIS (ranked):
1. [85%] [Hypothesis] — evidence: [log line]
2. [30%] [Hypothesis] — evidence: [log line]

RECOMMENDED ACTION: [specific next step]
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.