sp-debugging

A workflow for diagnosing a bug and writing a fix plan without implementing the change. It confirms the symptom, traces the failure to its root cause, tests the explanation, and records the proposed fix.

In plain words
What is it for?
Use it when you need evidence-based root-cause analysis and an agreed written plan before any implementation begins.
Why use it?
Jumping straight from an error to a code change can hide the real cause and lead to guesses or fixes in the wrong place.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/tta-lab/ttal-cli/sp-debugging
Any agent
npx skills add tta-lab/ttal-cli --skill sp-debugging
Clone the repo
git clone --depth 1 https://github.com/tta-lab/ttal-cli

Made for: Claude Code, Codex.

Per session 21 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 440 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00021 $0.00440
Opus 5 $0.00010 $0.00220
Sonnet 5 $0.00004 $0.00088
Haiku 4.5 $0.00002 $0.00044

Measured 2d ago against content hash 4edede9945de, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

sp-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 2d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (condition-based-waiting-example.ts, find-polluter.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

skills/sp-debugging/SKILL.md · 74 lines

What it actually says

Bug Diagnosis and Fix Planning

Diagnose from evidence, then persist the diagnosis and fix plan in FlickNote. Do not implement the fix.

1. Confirm the Symptom

Restate the observed behavior, expected behavior, affected surface, and known reproduction. Ask one focused question if the report is ambiguous.

2. Find the Root Cause

  1. Reproduce the failure.
  2. Read the complete errors and logs.
  3. Check recent changes and working examples.
  4. Trace bad state backward across component boundaries.
  5. Form one hypothesis and test it with the smallest useful probe.

If three hypotheses fail, stop and question the model or architecture instead of stacking guesses.

Useful references in this directory:

  • root-cause-tracing.md
  • defense-in-depth.md
  • condition-based-waiting.md

3. Confirm the Diagnosis

Tell the user:

  • Root cause and supporting evidence
  • Proposed fix boundary
  • Main risk or trade-off

Get alignment before writing a detailed plan when the fix direction is not already approved.

4. Write the FlickNote

Save one note in orientation:

flicknote add --project orientation

Structure:

Fix:

Symptom

Root cause

Evidence and reproduction

Fix strategy

Anti-goals

Implementation stages

Test strategy

Exit criteria

Risks

For behavior fixes, include TDD explicitly:

  1. Add a focused regression test.
  2. Run it and confirm it fails for the diagnosed reason.
  3. Implement the minimum fix.
  4. Run focused and broader tests.
  5. Refactor while green.

Each stage must name exact files, commands, expected results, and dependencies.

5. Worker-Eye Check

Re-read the note as the implementer. Fix missing paths, hidden assumptions, unclear ordering, and unresolved decisions with FlickNote edits.

Return the FlickNote ID and a short diagnosis summary. Stop; do not start implementation or invoke another skill.

Files

What ships with it

10 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. 2d ago First seen · 74 lines · 21 tokens per session scan A 4edede9945de

Subscribe to this mod's changes

sp-debugging is a skill published in the GitHub repository tta-lab/ttal-cli (23 stars, last pushed 1mo ago), licensed MIT. It adds 21 tokens to every session and 440 once invoked, about $0.0001 per session on Opus 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

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

brainstorming

You MUST use this before any creative work - creating features, building components, adding functionality, or modifying behavior. Explores user intent, requirements and design before implementation.

obra/superpowers · 37 tokens

auto-perf-optimize

Run agent-driven VS Code performance or memory investigations. Use when asked to launch Code OSS, automate a VS Code scenario, run the Chat memory smoke runner, capture renderer heap snapshots, take workflow screenshots, compare run summaries, or drive a repeatable scenario before heap-snapshot analysis.

microsoft/vscode · 62 tokens

chat-perf

Run chat perf benchmarks and memory leak checks against the local dev build or any published VS Code version. Use when investigating chat rendering regressions, validating perf-sensitive changes to chat UI, or checking for memory leaks in the chat response pipeline.

microsoft/vscode · 51 tokens

chat-pet-sprite-creation

Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.

microsoft/vscode · 53 tokens

cpu-profile-analysis

Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…

microsoft/vscode · 71 tokens