diagnose

Guide structured 6-phase debugging for elusive bugs and performance regressions.

Updated Jul 22, 2025
One-click install
npx skills add https://github.com/MichaelSolati/mkai --skill diagnose-michaelsolati
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: diagnose
Source: https://github.com/MichaelSolati/mkai/tree/main/profiles/engineering/skills/diagnose
Command: npx skills add https://github.com/MichaelSolati/mkai --skill diagnose-michaelsolati

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Unstructured, ad-hoc debugging of hard bugs and performance regressions wastes developer time, leads to unreliable fixes, and often fails to address the root cause of elusive, intermittent issues.

Core Features & Use Cases

  • Structured 6-Phase Diagnosis Loop: Guides users through building a deterministic feedback loop, reproducing the bug, generating falsifiable hypotheses, targeted instrumentation, implementing fixes with regression tests, and post-mortem cleanup.
  • Non-Deterministic Bug Handling: Provides specific tactics to increase reproduction rates for flaky bugs that only appear intermittently under narrow conditions.
  • Use Case: When a developer encounters a performance regression that only appears under high load, this skill guides them to build a timing harness, generate hypotheses about database query bottlenecks, instrument the code to measure query times, and implement a fix with a regression test to prevent the issue from recurring.

Quick Start

Use the diagnose skill to debug the reported performance regression in the checkout flow by following the structured 6-phase diagnosis loop.

Frequently Asked Questions about diagnose

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

FAQPage Schema
How do I debug flaky tests and intermittent non-deterministic bugs?▼

To debug flaky tests and non-deterministic bugs, you need specific tactics to increase reproduction rates under narrow conditions. A structured workflow helps build deterministic reproduction loops to reliably trigger the elusive behavior.

What is the best way to find the root cause of a performance regression?▼

Finding the root cause of a performance regression requires targeted instrumentation to measure bottlenecks, such as database query times. Generating falsifiable hypotheses and building a timing harness ensures you identify the actual source.

How do I stop fixing the same bug repeatedly and prevent future regressions?▼

To stop repeatedly fixing the same bug and prevent future regressions, implement fixes alongside dedicated regression tests. Conducting post-mortem analysis after the fix eliminates unreliable patches and addresses the root cause.

Does unstructured debugging fail to resolve hard production issues?▼

Unstructured debugging fails to resolve hard production issues because it wastes developer time and produces unreliable fixes. Applying a 6-phase diagnosis loop replaces ad-hoc guessing with falsifiable hypotheses and targeted instrumentation.

Can I use a structured diagnosis workflow for high load performance issues?▼

You can use a structured diagnosis workflow for high load performance issues by building a timing harness. It guides you to generate hypotheses about database query bottlenecks, instrument the code, and implement a verified fix.