agentleFS
thoitiettxl-cyberthoitiettxl-cyber/Claw-II/skills/systematic-debugging/SKILL.md

systematic-debugging

Skill2 starsChanged 7 months agoMITView on GitHub

Standardize a systematic debugging process for runtime errors, test failures, app/service not running, command failures, error logs, abnormal behavior, regression, or integration mismatch in OpenClaw-Module Android; prioritize minimal repro, first-failure analysis, cause-layer classification, evidence before hypothesis, minimal patch, fallback discipline, and explicit verification/rollback. Use when user says bug, fail, broken, not running, what error, why broken, unexpected behavior, runtime mismatch, integration issue, or needs root-cause analysis before fixing.

190 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use chinese-code-review, chinese-commit-conventions 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.
  • Leodorareluctant259Skill

    chinese-code-review

    中文代码审查规范——在保持专业严谨的同时,用符合国内团队文化的方式给出有效反馈

    Also in 8 projects that use this

  • Leodorareluctant259Skill

    chinese-commit-conventions

    中文 Git 提交规范 — 适配国内团队的 commit message 规范和 changelog 自动化

    Also in 8 projects that use this

  • obraSkill

    diagnosing-superpowers

    Use when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.

    Also in 20 projects that use this

  • mjunaidcaSkill

    building-chatgpt-apps

    Guides creation of ChatGPT Apps with interactive widgets using OpenAI Apps SDK and MCP servers. Use when building ChatGPT custom apps with visual UI components, embedded widgets, or rich interactive experiences. Covers widget architecture, MCP server setup with FastMCP, response metadata, and Developer Mode configuration. NOT when building standard MCP servers without widgets (use building-mcp-servers skill instead).

    Also in 4 projects that use this

  • mjunaidcaSkill

    building-chat-interfaces

    Build AI chat interfaces with custom backends, authentication, and context injection. Use when integrating chat UI with AI agents, adding auth to chat, injecting user/page context, or implementing httpOnly cookie proxies. Covers ChatKitServer, useChatKit, and MCP auth patterns. NOT when building simple chatbots without persistence or custom agent integration.

    Also in 4 projects that use this

  • +2 more from Leodorareluctant259
  • +5 more from mjunaidca

The file

Show its rules and text

We split this skill into the rules it gives an agent

17 rules. 0 are common, 12 are distinctive, and 5 are very specific to this project.

  • 0

    Common

    Most of the 177 edited versions we read keep these.

  • 12

    Distinctive

    This author's own choices. Worth a look.

  • 5

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Verify/report/rollback -> retest-and-rollback.md

    line 47
  2. Distinctive:

    If the strongest signature matches a specialist internal skill, hand off early after minimal evidence capture.

    line 64
  3. Distinctive:

    If the next step requires actions outside workspace/network write/sensitive mutation, stop and request approval checkpoint.

    line 65
  4. Very specific:

    Use the minimum command/request/path that reproduces the issue.

    line 72
  5. Very specific:

    Prefer a repro matrix when schema/validation/input shape may be involved.

    line 73
  6. Distinctive:

    Do not assume the last error message is the root cause.

    line 76
  7. Very specific:

    Use references/classification-matrix.md to place the issue into likely layers.

    line 78
  8. Distinctive:

    Prefer raw command output, logs, file state, version info, and recent diffs over intuition.

    line 82
  9. Distinctive:

    Avoid parallel patching that destroys causality.

    line 88
  10. Distinctive:

    If the failing tool itself becomes unreliable for the repair path, switch to a safer fallback path.

    line 91
  11. Distinctive:

    Run adjacent smoke checks.

    line 94
  12. Distinctive:

    Keep rollback path for every mutation cluster.

    line 95
  13. Distinctive:

    Use PARTIAL when mutation happened but verification is incomplete.

    line 97
  14. Distinctive:

    Use PASS only when repro rerun and adjacent smoke checks support the claim.

    line 98
  15. Very specific:

    Use references/escalation-map.md for specialist skill mapping.

    line 100
  16. Distinctive:

    stop retrying the same broken lane

    line 110
  17. Distinctive:

    Stop and request approval with exact command/scope.

    line 115

“Common” is measured: kept by at least 6 in 10 of the 177 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Systematic Debugging

Indexed Reference Map

  • @[SKILL.md#L1-L109] Frontmatter, trigger rules, SOP, output contract.
  • @[references/INDEX.md#L1-L29] Reading order and reference inventory.
  • @[references/QUICK_REFERENCE.md#L1-L50] Fast triage loop, stop conditions, and anti-patterns.
  • @[references/classification-matrix.md#L1-L30] Failure classification matrix by symptom/layer.
  • @[references/evidence-checklist.md#L1-L40] Evidence collection order and minimum proof set.
  • @[references/practical-lane.md#L1-L53] Practical debugging lane: minimal repro, first failure, fallback, mutation discipline.
  • @[references/retest-and-rollback.md#L1-L24] Verification, smoke checks, PARTIAL/PASS gate, and rollback discipline.
  • @[references/escalation-map.md#L1-L37] Handoff map to specialist internal skills.

Scope

  • In-scope:
    • Runtime errors, test failures, unexpected behavior, regressions, integration mismatches.
    • OpenClaw-Module Android issues involving shell/service/plugin/config/python/runtime layers.
    • Local reproduction, evidence collection, hypothesis testing, minimal patch planning.
    • Practical failure handling where the visible error may be downstream from the true first failing layer.
  • Out-of-scope:
    • Blind trial-and-error patching without reproduction or evidence.
    • Large architectural rewrites disguised as debugging.
    • Destructive/system-level actions outside approved workspace/runtime safety boundary.

KB Mode Notes

  • Reading order:
    1. references/INDEX.md
    2. references/QUICK_REFERENCE.md
    3. references/classification-matrix.md
    4. references/evidence-checklist.md
    5. references/practical-lane.md
    6. references/retest-and-rollback.md
    7. references/escalation-map.md
  • Coverage Matrix:
    • Symptom triage -> QUICK_REFERENCE.md, classification-matrix.md
    • Evidence discipline -> evidence-checklist.md
    • Practical incident handling -> practical-lane.md
    • Verify/report/rollback -> retest-and-rollback.md
    • Specialist handoff -> escalation-map.md
  • Portability note:
    • Workflow is local-first and does not depend on external docs. Absolute runtime paths, when mentioned, are verify targets/examples rather than mandatory hard dependencies.

Trigger Rules

  • Positive:
    • User reports bug, failure, regression, broken behavior, flaky result, mismatch, command fail, service/app not running, or asks why something is broken.
    • Logs/output show an error and the next step is root-cause isolation rather than immediate patching.
    • Prompt contains intent like: debug, diagnose, triage, investigate, root cause, inspect failure, find why, why broken, what error.
    • A task needs disciplined reproduce -> inspect -> isolate -> verify flow.
  • Negative:
    • User already requested a very specific, low-risk edit with clear root cause and no debugging needed.
    • Pure feature implementation, planning, refactor, scaffolding, or skill authoring with no failure diagnosis aspect.
    • User asks directly for a known mechanical action without symptom analysis.
    • Cases already clearly inside a specialist skill with a dominant signature.
  • Escalation:
    • If the strongest signature matches a specialist internal skill, hand off early after minimal evidence capture.
    • If the next step requires actions outside workspace/network write/sensitive mutation, stop and request approval checkpoint.

SOP

  1. Stabilize the symptom statement
    • Rewrite the problem as: expected behavior, actual behavior, scope, first known bad point.
    • Reject vague labels like "broken" without observable evidence.
  2. Build the smallest safe repro
    • Use the minimum command/request/path that reproduces the issue.
    • Prefer a repro matrix when schema/validation/input shape may be involved.
  3. Separate first failure from downstream symptom
    • Identify the earliest layer that violates contract.
    • Do not assume the last error message is the root cause.
  4. Classify the failure layer
    • Use references/classification-matrix.md to place the issue into likely layers.
    • For wrapper/core/executor style incidents, explicitly separate caller payload, bridge/wrapper normalization, core validation, and execution/runtime effects.
  5. Collect evidence in order
    • Follow references/evidence-checklist.md.
    • Prefer raw command output, logs, file state, version info, and recent diffs over intuition.
  6. Form bounded hypotheses
    • Generate 1-3 hypotheses maximum.
    • Each hypothesis must predict what evidence should appear if true.
  7. Test one variable at a time
    • Change only the minimum variable needed to confirm or reject a hypothesis.
    • Avoid parallel patching that destroys causality.
  8. Patch minimally and at the correct layer
    • Fix the first failing layer, not the loudest downstream symptom.
    • If the failing tool itself becomes unreliable for the repair path, switch to a safer fallback path.
  9. Verify explicitly
    • Re-run the original repro.
    • Run adjacent smoke checks.
    • Keep rollback path for every mutation cluster.
  10. Report with confidence and state gate
  • Use PARTIAL when mutation happened but verification is incomplete.
  • Use PASS only when repro rerun and adjacent smoke checks support the claim.
  1. Escalate or hand off when appropriate
  • Use references/escalation-map.md for specialist skill mapping.

Error Handling

  • Reproduction unavailable:
    • Return UNREPRODUCED status, list missing evidence, and avoid claiming root cause.
  • Multiple plausible layers:
    • Narrow by cheapest discriminator test first; do not branch into many speculative fixes.
  • Logs too noisy/large:
    • Extract only the minimal failing segment plus surrounding context needed for causality.
  • Tool-under-repair is itself failing:
    • stop retrying the same broken lane
    • choose fallback (read+write, script patcher, alternate probe) that preserves causality and rollback
  • Potential specialist-skill case:
    • Capture initial evidence, then hand off instead of duplicating a more specialized SOP.
  • Sensitive/destructive step required:
    • Stop and request approval with exact command/scope.

Output Contract

  • Deliverable:
    • Symptom: concise expected vs actual.
    • Repro: minimal path or repro matrix.
    • Classification: likely layer + reason.
    • First Failure: earliest violating layer + why.
    • Evidence: commands/logs/files used.
    • Hypotheses Tested: accepted/rejected.
    • Action: fix applied, proposed patch, fallback, or handoff.
    • Verification: repro re-check + adjacent smoke checks.
    • Rollback: backup path or recovery path.
    • Confidence: LOW|MEDIUM|HIGH.
  • Validation:
    • PASS = reproduced or strongly evidenced, first failing layer isolated, fix/handoff verified.
    • PARTIAL = some evidence or mutation exists, but root cause or verification incomplete.
    • UNREPRODUCED = symptom not reproduced and evidence insufficient.
    • FAIL = debugging attempt blocked, contradicted, or made unsafe by constraints.
  • Compliance Verdict:
    • PASS|PARTIAL|UNREPRODUCED|FAIL + short reason, never vague success claims.

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.

Reviews can't be read right now.

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.