debug-systematically

debug-systematically is a skill for Claude Code, Codex from pingfanfan/hello-dsh. It costs 51 tokens per session (1,016 once invoked), scanned A, original, MIT.

A structured method for finding the underlying cause of a software problem. It moves from reproducing the problem, to locating the responsible code, to testing a specific explanation, and then to fixing it with a regression test.

In plain words
What is it for?
Investigating bugs, collecting exact reproduction steps and errors, narrowing down code changes, testing root-cause explanations, and verifying fixes.
Why use it?
It reduces guesswork and helps ensure that a symptom is not merely hidden while the real defect remains.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Investigating bugs, collecting exact reproduction steps and errors, narrowing down code changes, testing root-cause explanations, and verifying fixes.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/pingfanfan/hello-dsh/debug-systematically
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 pingfanfan/hello-dsh --skill debug-systematically
Clone the repo
git clone --depth 1 https://github.com/pingfanfan/hello-dsh

Made for: Claude Code, Codex.

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 debug-systematically

README.md
[![agentmods](https://agentmods.dev/badge/skills/pingfanfan/hello-dsh/debug-systematically/github.svg)](https://agentmods.dev/skills/pingfanfan/hello-dsh/debug-systematically)
Your own site
<a href="https://agentmods.dev/skills/pingfanfan/hello-dsh/debug-systematically"><img src="https://agentmods.dev/badge/skills/pingfanfan/hello-dsh/debug-systematically/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 debug-systematically

Your own site · 80×15
<a href="https://agentmods.dev/skills/pingfanfan/hello-dsh/debug-systematically"><img src="https://agentmods.dev/badge/skills/pingfanfan/hello-dsh/debug-systematically.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 51 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,016 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00051 $0.01016
Opus 5.5 $0.00020 $0.00406
Sonnet 5.5 $0.00010 $0.00203
Haiku 4.5 $0.00005 $0.00102

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

Security

Grade A, and why

debug-systematically 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 3mo 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.

examples/skills/debug-systematically/SKILL.md · 82 lines

What it actually says

系统化排查

铁律:没有定位到根因之前,不允许修改代码。

绕过这条铁律的典型说法是"先试试这样改会不会好"。那不是排查,那是碰运气:它可能让症状消失而根因还在,然后在别处以更难查的形式复现。

四个阶段

阶段之间不可跳跃。当前阶段的产出不满足,就不能进入下一阶段。

一、复现

产出:一条能稳定触发问题的命令或步骤。

  • 拿到确切的报错全文,不是转述
  • 确认触发条件:什么输入、什么环境、什么时序
  • 确认边界:什么情况下不发生——这条经常比"什么时候发生"信息量更大
  • 如果无法稳定复现,先解决这个问题:找出是并发、缓存、时序还是环境差异

无法复现就无法验证修复。这个阶段偷懒,后面全是猜。

二、定位

产出:指出具体的文件和行,并能解释它为什么产生了观察到的现象。

  • 从报错栈的最深处往外读,不是最外层
  • 在怀疑点打印实际值,不要假设它是什么
  • 二分缩小范围:注释掉一半、回退一半提交、禁用一半配置
  • 对比正常与异常两条路径的差异

判断标准:你能不能预测"如果我改动 X,现象会变成 Y"? 能,说明定位到了;不能,说明还在猜。

三、假设与验证

产出:一个被证据支持的根因陈述。

写成这个形式:

因为 <具体代码> 在 <具体条件> 下会 <具体行为>,所以出现 <观察到的现象>。

然后主动证伪:如果这个假设成立,还应该能观察到什么?去验证那件事。只找支持证据是确认偏误。

常见的假根因:

  • "可能是缓存问题" —— 哪个缓存?哪一行读的?
  • "时序问题" —— 哪两个操作的顺序?怎么证明?
  • "环境不一致" —— 具体哪个变量不同?

这些说法不含信息量,不能作为根因。

四、修复

产出:改动 + 能捕获这个回归的测试。

  • 修根因,不修症状
  • 先写一个当前会失败的测试,再修,看它变绿——顺序反了就无法证明测试有效
  • 检查同类问题:同样的模式在别处是否也存在
  • 确认没有引入新问题:跑完整测试,不是只跑相关的那个

常见陷阱

陷阱 表现 纠正
改了就好了 不知道为什么好了 回退改动确认它确实会复现,再改回来
加日志加到忘了目的 日志越来越多,问题没近 每加一条日志都要说清想验证什么假设
相信注释和文档 按文档说的推理 以代码实际行为为准,文档可能过期
相信测试全绿 测试通过就认为没问题 测试可能根本没覆盖这条路径
一次改多处 好了但不知道哪个起作用 一次只改一个变量
跳过复现 直接开始读代码找可疑点 先复现,否则无法验证

什么时候该停下来求助

  • 同一个假设方向试了三次都不对 —— 换方向,或者说出来让别人看
  • 定位到了但改不动(涉及不熟悉的子系统)—— 带着定位结论去问,比带着现象去问有效十倍
  • 复现不了 —— 优先解决复现,而不是硬猜

求助时给出:复现步骤、已排除的可能、当前假设、卡住的具体点。

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. 3mo ago First seen · 82 lines · 51 tokens per session scan A 34934d4bfcaa

Subscribe to this mod's changes

debug-systematically is a skill published in the GitHub repository pingfanfan/hello-dsh (111 stars, last pushed 2mo ago), licensed MIT. It adds 51 tokens to every session and 1,016 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-08-30.

Related

debug-systematically compared with skills from other repositories

debug-systematically next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
debug-systematicallypingfanfan/hello-dshSkill1112mo agoMITA51Claude Code, Codex
dsh-plugin-guidePerryLink/dsh-plugin-guideSkill748d agoApache-2.0A62Claude Code, Codex
diagnosing-bugs-zhgongyijie85/mattpocock-skills-dsh-zhSkill813d agoMITA48Claude Code, Codex
systematic-debuggingamplifthq/oh-my-dshSkill201mo agoMITA15Claude Code, Codex
dsh-debug-sessionhackerFish/awesome-dsh-skillsSkill62mo agoMITA40Claude Code, Codex
dsh-speed-up-perfWZZNNE/DSH-CyberWorkStationSkill262mo agononeA45Claude Code, Codex
dsh-ci-test-reliabilityWZZNNE/DSH-CyberWorkStationSkill262mo agononeA83Claude Code, Codex