failure-diagnosis
Skill1 starsChanged 54 days agoMITView on GitHub
Observe, reproduce, classify, and determine the root cause and correct repair layer for a build, test, regression, integration, or environment failure. Use before patching when the cause is unknown or crosses layers.
In this repository21 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- adaptive-testingSkill
- architecture-decisionSkill
- artifact-validationSkill
- change-impactSkill
- clarification-gateSkill
- code-reviewSkill
- component-planningSkill
- failure-escalationSkill
- framework-checkpointSkill
- framework-resumeSkill
- gap-analysisSkill
- implement-componentSkill
- integration-gateSkill
- minimum-pathSkill
- project-intakeSkill
- quality-gateSkill
- reverse-engineeringSkill
- stage-gateSkill
- traceabilitySkill
- workflow-assessmentSkill
The file
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 4 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 14
Run after a meaningful failure when the responsible layer is uncertain, on regression or integration failure, or before a second broad …
- Distinctive: line 44
Do not edit production code or weaken tests merely to prove a hypothesis.
- Very specific: line 46
Use UNKNOWN when evidence is insufficient.
- Distinctive: line 63
Use Clarification Gate for expected behavior/authority ambiguity.
- Distinctive: line 67
Stop when root cause and repair layer are supported, when missing evidence blocks progress, or with ranked hypotheses at the investigation …
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Failure Diagnosis
Purpose
Replace speculative patching with an evidence-backed Root Cause Analysis and repair direction.
Trigger
Run after a meaningful failure when the responsible layer is uncertain, on regression or integration failure, or before a second broad correction attempt.
Inputs
- Expected/observed behavior, symptom, failing revision, reproduction, environment, logs, and reports.
- Recent changes and last-known-good revision.
- Relevant Requirements, architecture, detailed design, Contracts, interfaces, data, implementation, tests, and prior attempts.
Prerequisites
- Preserve original failure evidence before changing code/tests/environment.
- Define the failure precisely enough to distinguish success from failure.
Procedure
- Observe and record the exact failure, scope, timing, revision, and environment.
- Reproduce with the least invasive reliable method; record deterministic/intermittent status.
- Build a timeline and compare failing behavior with last known good evidence.
- Trace affected control, data, interface, and Contract paths.
- Form multiple plausible hypotheses and identify discriminating checks.
- Execute bounded diagnostics; falsify alternatives rather than confirming only the first theory.
- Classify the responsible layer: Requirement, Architecture, Detailed Design, Contract, Interface, Data, Implementation, Test, Environment, or
UNKNOWN. - Identify root cause, contributing factors, affected Artifacts/Components, and invalid evidence.
- Select the smallest correct repair layer and required revalidation scope.
- Record confidence, untested hypotheses, repair owner capability, and escalation threshold.
Decision Rules
- Reproduction failure lowers confidence; it does not prove the issue absent.
- Root cause must explain all material observations better than alternatives.
- Do not edit production code or weaken tests merely to prove a hypothesis.
- Repair at the responsible layer, not the nearest editable line.
- Use
UNKNOWNwhen evidence is insufficient.
Outputs
- RCA report with observation, reproduction, evidence chain, hypotheses, and classification.
- Root cause/confidence or ranked unresolved hypotheses.
- Correct repair layer/owner, affected states, and revalidation plan.
Failure Cases
- Failure cannot be reproduced and environments cannot be compared.
- Evidence/logs are unavailable or sensitive access is unauthorized.
- Expected behavior itself is ambiguous.
- Investigation budget expires without a supported root cause.
Escalation
Use Clarification Gate for expected behavior/authority ambiguity. Invoke Failure Escalation for repeated failure, exhausted local diagnosis, broad cross-layer impact, or required stage rollback.
Stop Conditions
Stop when root cause and repair layer are supported, when missing evidence blocks progress, or with ranked hypotheses at the investigation budget. Do not implement the fix in this Skill.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
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.

