agentleFS
jscott3201jscott3201/yet-more-skills/skills/diagnosis-loop/SKILL.md

diagnosis-loop

Skill4 starsChanged 2 months agoApache-2.0View on GitHub

Diagnose a difficult bug or performance regression through a symptom-specific reproduction and falsifiable hypotheses. Fix only when requested; not an automatic architecture rewrite.

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Do not promote an untested theory to fact, erase a flaky result with retries, or turn a local defect into a modernization program.

    line 32

≈ “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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Diagnosis Loop

Explain the cause using evidence. A diagnosis-only task authorizes inspection and safe checks, not an unrequested tracked code change or remote mutation. A request to fix the problem can include implementation after diagnosis without requiring a separate agent.

Build a useful feedback loop

State the expected behavior, actual symptom, affected environment, and observable failure signal. Inspect the relevant source and callers. Use an available index or memory service when helpful, with a focused file-search fallback.

Choose the narrowest existing test, request replay, browser scenario, CLI invocation, benchmark, or trace that exercises the symptom. Run it when safe and available. Preserve the first failure signal and protect credentials, personal data, device captures, and logs. Do not reproduce an issue against production or physical equipment without the necessary authority.

A useful loop distinguishes this bug from an unrelated setup failure. Minimize the input or sequence while preserving the symptom. If reproduction is unavailable, continue with bounded static reasoning and label the missing runtime evidence.

Test competing explanations

Keep as many hypotheses as the uncertainty needs; do not manufacture alternatives for an obvious proven defect. For each plausible cause, identify an observation that would falsify it. Try the cheapest high-information probe, change one variable at a time, and retire explanations contradicted by the evidence.

Prefer existing telemetry, debuggers, profilers, and focused checks over broad logging. Add temporary tracked instrumentation only when edits are in scope, and remove task-owned instrumentation before closing. For a performance regression, compare equivalent workloads and environments and separate CPU, I/O, contention, allocation, and tail latency.

Stop at the right boundary

For diagnosis, return the cause or bounded uncertainty, reproduction, supporting evidence, and a proposed regression seam. For an authorized fix, correct the root cause and verify the relevant failure path rather than patching only one symptom.

Do not promote an untested theory to fact, erase a flaky result with retries, or turn a local defect into a modernization program. Clean up task-owned runtime state and report remaining gaps plainly.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.