diagnose

Diagnose bugs and performance regressions through a structured reproduce-hypothesise-fix workflow.

2|1|Updated Apr 12, 2026
One-click install
npx skills add https://github.com/brandtam/rubber-ducky-legacy --skill diagnose-brandtam
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: diagnose
Source: https://github.com/brandtam/rubber-ducky-legacy/tree/main/.agents/skills/diagnose
Command: npx skills add https://github.com/brandtam/rubber-ducky-legacy --skill diagnose-brandtam

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? Hard bugs and performance regressions stall when developers jump straight to guessing fixes without a reliable reproduction. This Skill enforces a disciplined six-phase loop — build a feedback loop, reproduce, hypothesise, instrument, fix with regression test, and clean up — so root causes are found systematically instead of by luck. ## Core Features & Use Cases - Feedback loop construction: Ten ranked strategies for building a deterministic pass/fail signal, from failing tests and curl scripts to headless browser replays, fuzz loops, and git bisect harnesses. - Ranked falsifiable hypotheses: Generates 3-5 hypotheses with explicit predictions before testing, and checkpoints them with the user to leverage domain knowledge. - Tagged instrumentation and cleanup: Every debug log gets a unique [DEBUG-...] prefix so removal is a single grep, and a post-mortem checklist captures the confirmed root cause. - Use Case: A user reports that an export endpoint intermittently returns corrupted data. The Skill guides building a 100-iteration loop to raise the reproduction rate, ranking hypotheses about concurrency vs serialization, instrumenting the boundary, and landing a regression test at the correct seam. ## Quick Start Ask the agent to diagnose the bug where the export button intermittently throws an error, and have it build a reproduction loop before proposing any fix.

Frequently Asked Questions about diagnose

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I debug an intermittent or flaky bug?▼

Raise the reproduction rate instead of chasing a clean repro: loop the trigger 100 times, parallelise, add stress, and narrow timing windows. A bug that fails 50% of the time is debuggable; at 1% it is not, so keep increasing the rate before hypothesising.

How to diagnose a performance regression in code?▼

Establish a baseline measurement first using a timing harness, performance.now(), a profiler, or a query plan, then bisect to find the regression point. Logs are usually the wrong tool for performance work; measure first and fix second.

What should I do when a bug cannot be reproduced locally?▼

Stop and say so explicitly rather than guessing. Ask the user for environment access, a captured artifact such as a HAR file, log dump, or screen recording, or permission to add temporary production instrumentation before proceeding.

When should I write a regression test for a bug fix?▼

Write the regression test before the fix, but only at a correct seam where the test exercises the real bug pattern as it occurs at the call site. If no correct seam exists, that absence is itself an architectural finding worth flagging.

Why generate multiple hypotheses before testing a bug theory?▼

Generating 3-5 ranked falsifiable hypotheses prevents anchoring on the first plausible idea. Each hypothesis must state a testable prediction, and showing the list to the user lets domain knowledge re-rank it cheaply before any testing begins.