investigate

Guide systematic root-cause debugging through symptom collection, code tracing, and hypothesis verification.

8|2|Updated Mar 24, 2026
One-click install
npx skills add https://github.com/MFS-code/gstack --skill investigate-mfs-code
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: investigate
Source: https://github.com/MFS-code/gstack/tree/main/investigate
Command: npx skills add https://github.com/MFS-code/gstack --skill investigate-mfs-code

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Debugging often turns into guessing and repeated trial-and-error; this skill instead guides you through systematic root-cause investigation so the eventual fix addresses the underlying reason the bug happened.

Core Features & Use Cases

  • Root-cause-first workflow: Collect symptoms, inspect the relevant code path, check what changed recently, and verify the behavior you’re seeing before proposing any fix.
  • Pattern-based narrowing: Matches symptoms to common failure patterns (like race conditions, null propagation, integration failures, config drift, or stale cache) to focus where to look next.
  • Freeze-safe scope locking: When available, restricts edits to the narrowest affected module to prevent scope creep during debugging.
  • Evidence and verification discipline: Requires confirming the hypothesis before implementing and finishing with a verification/report step.
  • Manual-trigger debugging: Intended to be invoked only when the user explicitly asks (e.g., “/investigate”), minimizing accidental interference.

Use Case Example: When you see an unexpected runtime error or behavior change after a deployment, use this skill to trace the error back to the exact failing path, identify what changed, and then implement a fix tied to the root cause rather than the symptom.

Quick Start

Use the /investigate command when you need to debug why something broke so you can trace the issue to its root cause and apply a verified fix.

Frequently Asked Questions about investigate

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

FAQPage Schema
What is the best way to debug unexpected runtime errors after a deployment?

Root cause analysis identifies the underlying reason for code failures by collecting symptoms and inspecting relevant paths. This process ensures you fix the actual source of the bug rather than just treating the visible symptom, preventing regressions and unexpected outputs.

How do I troubleshoot software regressions without causing scope creep?

Troubleshoot software regressions while preventing scope creep by locking the debug scope to the narrowest affected module. This freeze-safe boundary restricts edits to the specific failing component, ensuring your investigation remains focused and controlled throughout the hypothesis testing process.

How do I systematically trace a failing workflow to its root cause?

Systematically trace a failing workflow to its root cause by following a multi-phase process: collect symptoms, inspect the code path, analyze recent changes, test hypotheses, and verify the behavior. This evidence-backed debugging method confirms the exact failure point before you implement fixes.

Does hypothesis testing work for narrowing down common failure patterns like race conditions?

Hypothesis testing works effectively for narrowing down common failure patterns like race conditions, null propagation, and config drift. By matching observed symptoms to these known patterns, you can focus your code inspection on the most probable causes and verify your hypothesis before changing code.

When should I manually trigger a root cause investigation for troubleshooting?

You should manually trigger a root cause investigation for troubleshooting only when you explicitly need to debug broken behavior, such as encountering unexpected outputs or errors. Invoking the investigation process manually ensures it activates solely for targeted, evidence-backed debugging without accidental interference.