systematic-debugging

systematic-debugging is a skill for Claude Code from XRenSiu/claude-code-forge. It costs 38 tokens per session (2,803 once invoked), scanned A, original, MIT.

A step-by-step method for finding the root cause of bugs, failed tests, and unexpected behaviour before changing code. It moves through investigation, pattern analysis, hypothesis testing, and implementation with TDD, meaning tests are written to guide the fix.

In plain words
What is it for?
Use it for intermittent bugs, unclear test failures, code that does not behave as expected, and bugs that return after an attempted fix.
Why use it?
It reduces guesswork and stops repeated patches from creating new problems. The required investigation helps separate symptoms from the actual cause.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the pdforge plugin — 10 skills, 13 commands, 5 agents, 2 hooks shipped together

Good fit Use it for intermittent bugs, unclear test failures, code that does not behave as expected, and bugs that return after an attempted fix.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/xrensiu/claude-code-forge/systematic-debugging
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add XRenSiu/claude-code-forge --skill systematic-debugging
Clone the repo
git clone --depth 1 https://github.com/XRenSiu/claude-code-forge

Made for: Claude Code.

Or install pdforge, the plugin that ships this one along with the rest of its 10 skills, 13 commands, 5 agents, 2 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for systematic-debugging

README.md
[![agentmods](https://agentmods.dev/badge/skills/xrensiu/claude-code-forge/systematic-debugging/github.svg)](https://agentmods.dev/skills/xrensiu/claude-code-forge/systematic-debugging)
Your own site
<a href="https://agentmods.dev/skills/xrensiu/claude-code-forge/systematic-debugging"><img src="https://agentmods.dev/badge/skills/xrensiu/claude-code-forge/systematic-debugging/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for systematic-debugging

Your own site · 80×15
<a href="https://agentmods.dev/skills/xrensiu/claude-code-forge/systematic-debugging"><img src="https://agentmods.dev/badge/skills/xrensiu/claude-code-forge/systematic-debugging.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,803 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00038 $0.02803
Opus 5.5 $0.00015 $0.01121
Sonnet 5.5 $0.00008 $0.00561
Haiku 4.5 $0.00004 $0.00280

Measured 1mo ago against content hash c3c11dc6dc78, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

systematic-debugging scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/pdforge/skills/systematic-debugging/SKILL.md · 395 lines

How it starts

The opening of the file, as written. The whole thing — 395 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Systematic Debugging

你遇到了一个问题。先别急着改代码——系统性调试是一种纪律,不是建议。

实测数据:系统性方法 15-30 分钟修复,随机修复方法 2-3 小时折腾。

Announce at start: "I'm using the systematic-debugging skill to investigate this issue methodically."

When to Use

  • 测试失败且原因不明显
  • 代码"应该工作"但就是不工作
  • 问题时有时无(间歇性问题)
  • 修了一个 bug 又冒出新 bug
  • "我不知道为什么会这样"

The Iron Law

┌─────────────────────────────────────────────────────────────┐
│                                                             │
│    未完成 Phase 1 之前,禁止提出任何修复方案                   │
│                                                             │
│    NO FIX PROPOSALS BEFORE PHASE 1 COMPLETION               │
│                                                             │
└─────────────────────────────────────────────────────────────┘

这不可协商。这不是建议。你不能为自己绕过这条规则找理由。

4+1 Phase Framework

digraph debugging {
    rankdir=TB;
    node [shape=box];
    
    "Phase 0: Problem Intake" -> "Phase 1: Root Cause Investigation";
    "Phase 1: Root Cause Investigation" -> "Phase 2: Pattern Analysis";
    "Phase 2: Pattern Analysis" -> "Phase 3: Hypothesis Testing";
    "Phase 3: Hypothesis Testing" -> "Phase 4: Implementation with TDD";
    "Phase 4: Implementation with TDD" -> "Verified Fix" [style=dashed];
    
    "Phase 1: Root Cause Investigation" -> "Phase 0: Problem Intake" [label="信息不足" style=dotted];
    "Phase 3: Hypothesis Testing" -> "Phase 1: Root Cause Investigation" [label="假设错误" style=dotted];
}

Phase 0: Problem Intake(问题收集)

目的:收集足够信息,而非急于诊断

必须收集的信息

  • 确切错误信息:完整的错误输出,不是"它报错了"
  • 复现步骤:如何可靠地重现问题?
  • 预期行为 vs 实际行为:应该发生什么?实际发生了什么?
  • 最近更改:问题出现前改了什么?
  • 环境信息:Node 版本、操作系统、依赖版本

Checklist

□ 我有完整的错误信息/堆栈跟踪
□ 我能可靠地重现问题
□ 我知道预期行为是什么
□ 我知道问题首次出现的时间/提交
□ 我了解相关的环境配置

Detection Commands

# 获取完整错误信息
npm test 2>&1 | tee error.log

# 查看最近更改
git log --oneline -10
git diff HEAD~3

# 环境信息
node -v && npm -v
cat package.json | jq '.dependencies'

⚠️ 如果无法收集完整信息,停在这里,先问问题获取更多信息。

Read the full file on GitHub · 395 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 395 lines · 38 tokens per session scan A c3c11dc6dc78

Subscribe to this mod's changes

systematic-debugging is a skill published in the GitHub repository XRenSiu/claude-code-forge (2 stars, last pushed 29d ago), licensed MIT. It adds 38 tokens to every session and 2,803 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-05.