agentleFS
lza6lza6/claw-code-tingfeng/skills/analyze/SKILL.md

analyze

Skill5 starsChanged 12 days agoMITView on GitHub

Run deep investigation of architecture, bugs, performance issues, or dependencies and return structured findings with file:line evidence. Use when a user says 'analyze', 'investigate', 'why does', 'what's causing', or needs root cause analysis before making changes. Routes to architect agent or Codex MCP for thorough cross-file reasoning.

70 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use constitution, revise and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • ArvorCoSkill

    constitution

    Create or update the project constitution - personalized governance and coding principles. Use when starting a project or updating project standards. Triggers on: create constitution, update principles, set project rules.

    Also in 4 projects that use this

  • stormlightlabsSkill

    revise

    Address review comments on an open pull request and push the fixes. Use for /edit, /revise, or when asked to respond to review feedback on a PR number.

    Also in 3 projects that use this

  • DockerSkill

    write

    Write or edit reader-facing technical prose for immediate comprehension. Use for documentation, PR titles and descriptions, release notes, design documents, user-facing explanations, and substantive comments. Also use when asked to make writing clearer, more natural, less AI-generated, or easier to read. For documentation fixes, handles edits, formatting, self-review, and commits after research identifies what to change. Do not use for code-only tasks with no prose deliverable.

    Also in 6 projects that use this

  • ArvorCoSkill

    specify

    Create feature specification from natural language description. Use when starting a new feature or creating a spec. Triggers on: create spec, specify feature, new feature spec.

    Also in 5 projects that use this

  • H-mmerSkill

    submit

    Draft and submit a vulnerability report to the bug bounty platform. Reads scope.yaml for platform/program, uses brain + findings for content. Always drafts first for review.

    Also in 3 projects that use this

  • GoogleSkill

    quality

    Evaluates whether a GitHub issue is spam, empty, needs more information, or is OK to proceed.

    Also in 3 projects that use this

  • +1 more from ArvorCo

The file

Show its rules and text

We split this skill into the rules it gives an agent

15 rules. 0 are common, 13 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 60 edited versions we read keep these.

  • 13

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill for ambiguous, causal, evidence-heavy questions where the goal is to explain why an observed result happened, not to jump …

    line 8
  2. Very specific:

    Use $analyze when the problem is:

    line 12
  3. Distinctive:

    Always preserve these distinctions:

    line 36
  4. Distinctive:

    Do not collapse into:

    line 46
  5. Distinctive:

    Treat evidence as ranked, not flat.

    line 54
  6. Distinctive:

    Every serious investigation must try to falsify its own favorite explanation.

    line 67
  7. Distinctive:

    Run a rebuttal round between the leading hypothesis and the strongest alternative

    line 91
  8. Distinctive:

    call out missing evidence and failed predictions

    line 108
  9. Distinctive:

    avoid collapsing into implementation

    line 111
  10. Distinctive:

    After the initial evidence pass, pressure-test with these lenses when relevant:

    line 115
  11. Distinctive:

    Default to concise, evidence-dense progress and completion reporting unless the user or risk level requires more detail

    line 123
  12. Distinctive:

    Treat newer user task updates as local overrides for the active workflow branch while preserving earlier non-conflicting constraints

    line 124
  13. Distinctive:

    If correctness depends on additional inspection, retrieval, execution, or verification, keep using the relevant tools until the analysis is …

    line 125
  14. Distinctive:

    Gather relevant context: Read or identify the key files involved

    line 135
  15. Very specific:

    Use ask_codex with agent_role: "architect" when available

    line 140

“Common” is measured: kept by at least 6 in 10 of the 60 edited versions of this file we could read. “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

Analyze — Evidence-Driven Investigation

Use this skill for ambiguous, causal, evidence-heavy questions where the goal is to explain why an observed result happened, not to jump directly into fixing or rewriting code.

Good entry cases

Use $analyze when the problem is:

  • ambiguous or causal
  • evidence-heavy
  • best answered by exploring competing explanations
  • requires reading multiple files and reasoning across them

Examples:

  • runtime bugs and regressions
  • performance / latency / resource behavior
  • architecture / premortem / postmortem analysis
  • config / routing / orchestration behavior explanation
  • dependency analysis or impact assessment
  • "given this output, trace back the likely causes"

Do not use when

  • User wants code changes made — use $ralph or executor instead
  • User wants a full plan with acceptance criteria — use $plan instead
  • User wants a quick file lookup — use explore agent instead
  • User asks a simple factual question answerable from one file — just read and answer

Core investigation contract

Always preserve these distinctions:

  1. Observation — what was actually observed
  2. Hypotheses — competing explanations
  3. Evidence For — what supports each explanation
  4. Evidence Against / Gaps — what contradicts it or is still missing
  5. Current Best Explanation — the leading explanation right now
  6. Critical Unknown — the missing fact keeping the top explanations apart
  7. Discriminating Probe — the highest-value next step to collapse uncertainty

Do not collapse into:

  • a generic fix-it coding loop
  • a generic debugger summary
  • a raw dump of output
  • fake certainty when evidence is incomplete

Evidence strength hierarchy

Treat evidence as ranked, not flat. From strongest to weakest:

  1. Controlled reproductions / direct experiments / uniquely discriminating artifacts
  2. Primary source artifacts with tight provenance (trace events, logs, metrics, configs, git history, file:line behavior)
  3. Multiple independent sources converging on the same explanation
  4. Single-source code-path or behavioral inference
  5. Weak circumstantial clues (timing, naming, stack order, resemblance to prior bugs)
  6. Intuition / analogy / speculation

Explicitly down-rank hypotheses that depend mostly on lower tiers when stronger contradictory evidence exists.

Strong falsification rules

Every serious investigation must try to falsify its own favorite explanation.

For each top hypothesis:

  • collect evidence for it
  • collect evidence against it
  • state what distinctive prediction it makes
  • state what observation would be hard to reconcile with it
  • identify the cheapest probe that would discriminate it from the next-best alternative

Down-rank a hypothesis when:

  • direct evidence contradicts it
  • it survives only by adding new unverified assumptions
  • it makes no distinctive prediction compared with rivals
  • a stronger alternative explains the same facts with fewer assumptions

Team-mode orchestration (when using $team)

For complex investigations, use $team to run parallel tracer lanes:

  1. Restate the observed result or "why" question precisely
  2. Generate multiple deliberately different candidate hypotheses
  3. Spawn 3 tracer lanes via $team
  4. Assign one lane per hypothesis
  5. Each lane gathers evidence for and against its hypothesis
  6. Run a rebuttal round between the leading hypothesis and the strongest alternative
  7. Merge findings into a ranked synthesis

Default hypothesis lanes

Unless the problem strongly suggests a better partition:

  1. Code-path / implementation cause
  2. Config / environment / orchestration cause
  3. Measurement / artifact / assumption mismatch cause

Worker contract

Each worker must:

  • own exactly one hypothesis lane
  • gather evidence for and against the lane
  • rank evidence strength
  • call out missing evidence and failed predictions
  • name the critical unknown for the lane
  • recommend the best discriminating probe
  • avoid collapsing into implementation

Cross-check lenses

After the initial evidence pass, pressure-test with these lenses when relevant:

  • Systems lens — queues, retries, backpressure, feedback loops, upstream/downstream dependencies
  • Premortem lens — assume the current best explanation is wrong; what failure mode would embarrass the trace later?
  • Science lens — controls, confounders, measurement bias, falsifiable predictions

Execution policy

  • Default to concise, evidence-dense progress and completion reporting unless the user or risk level requires more detail
  • Treat newer user task updates as local overrides for the active workflow branch while preserving earlier non-conflicting constraints
  • If correctness depends on additional inspection, retrieval, execution, or verification, keep using the relevant tools until the analysis is grounded
  • Continue through clear, low-risk, reversible next steps automatically; ask only when the next step is materially branching, destructive, or preference-dependent

Good: The user says continue after the workflow already has a clear next step. Continue the current branch of work instead of restarting or re-asking the same question.

Good: The user changes only the output shape or downstream delivery step. Preserve earlier non-conflicting workflow constraints and apply the update locally.

Execution steps

  1. Identify the analysis type: Architecture, bug investigation, performance, or dependency analysis
  2. Gather relevant context: Read or identify the key files involved
  3. Generate hypotheses: At least 2-3 competing explanations
  4. Route to analyzer:
    • For simple cases: investigate directly with file reads and reasoning
    • For complex cases: use $team with tracer lanes
    • Use ask_codex with agent_role: "architect" when available
  5. Falsify: Try to break your own best hypothesis
  6. Return structured findings: Present with evidence, file references, and actionable recommendations

Output format

Observed Result

[What happened]

Ranked Hypotheses

RankHypothesisConfidenceEvidence StrengthWhy it leads
1...High / Medium / LowStrong / Moderate / Weak...

Evidence Summary by Hypothesis

  • Hypothesis 1: ...
  • Hypothesis 2: ...

Evidence Against / Missing Evidence

  • Hypothesis 1: ...
  • Hypothesis 2: ...

Most Likely Explanation

[Current best explanation with file:line references]

Critical Unknown

[Single missing fact keeping uncertainty open]

Recommended Next Step

[Single best action — either a discriminating probe or a fix recommendation]

Quality bar

Good analysis output is:

  • evidence-backed with file:line references
  • concise but rigorous
  • skeptical of premature certainty
  • explicit about missing evidence
  • practical about the next action
  • explicit about why weaker explanations were down-ranked

Task: {{ARGUMENTS}}

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.