agentleFS
NguyenHuy190303NguyenHuy190303/EEP/skills/investigate/SKILL.md

investigate

Skill2 starsChanged 21 days agoMITView on GitHub

Use to find why something behaves as it does, what a change would break, where data or a request flows, where time goes, or why a deployed service fails (errors, logs, metrics). Read-first; reports findings rather than fixing as a side effect.

128 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use pair-agent, plan-devex-review 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.
  • seek888Skill

    pair-agent

    Pair a remote AI agent with your browser. One command generates a setup key and prints instructions the other agent can follow to connect. Works with OpenClaw, Hermes, Codex, Cursor, or any agent that can make HTTP requests. The remote agent gets its own tab with scoped access (read+write by default, admin on request). Use when asked to "pair agent", "connect agent", "share browser", "remote browser", "let another agent use my browser", or "give browser access". (gstack) Voice triggers (speech-to-text aliases): "pair agent", "connect agent", "share my browser", "remote browser access".

    Also in 10 projects that use this

  • seek888Skill

    plan-devex-review

    Interactive developer experience plan review. Explores developer personas, benchmarks against competitors, designs magical moments, and traces friction points before scoring. Three modes: DX EXPANSION (competitive advantage), DX POLISH (bulletproof every touchpoint), DX TRIAGE (critical gaps only). Use when asked to "DX review", "developer experience audit", "devex review", or "API design review". Proactively suggest when the user has a plan for developer-facing products (APIs, CLIs, SDKs, libraries, platforms, docs). (gstack) Voice triggers (speech-to-text aliases): "dx review", "developer experience review", "devex review", "devex audit", "API design review", "onboarding review".

    Also in 13 projects that use this

  • ShreyRaviSkill

    landing-report

    Read-only queue dashboard for workspace-aware ship. Shows which VERSION slots are currently claimed by open PRs, which sibling Conductor workspaces have WIP work likely to ship soon, and what slot /ship would pick next. No mutations — just a snapshot. Use when asked to "landing report", "what's in the queue", "show me open PRs", or "which version do I claim next". (gstack)

    Also in 7 projects that use this

  • ayudaySkill

    setup-deploy

    Configure deployment settings for /land-and-deploy. Detects your deploy platform (Fly.io, Render, Vercel, Netlify, Heroku, GitHub Actions, custom), production URL, health check endpoints, and deploy status commands. Writes the configuration to CLAUDE.md so all future deploys are automatic. Use when: "setup deploy", "configure deployment", "set up land-and-deploy", "how do I deploy with gstack", "add deploy config".

    Also in 14 projects that use this

  • ayudaySkill

    cso

    Chief Security Officer mode. Performs OWASP Top 10 audit, STRIDE threat modeling, attack surface analysis, auth flow verification, secret detection, dependency CVE scanning, supply chain risk assessment, and data classification review. Use when: "security audit", "threat model", "pentest review", "OWASP", "CSO review".

    Also in 17 projects that use this

  • ramybarsoumSkill

    document-release

    Post-ship documentation update. Reads all project docs, cross-references the diff, updates README/ARCHITECTURE/CONTRIBUTING/CLAUDE.md to match what shipped, polishes CHANGELOG voice, cleans up TODOS, and optionally bumps VERSION. Use when asked to "update the docs", "sync documentation", or "post-ship docs". Proactively suggest after a PR is merged or code is shipped.

    Also in 18 projects that use this

  • +1 more from seek888

The file

We split this skill into the rules it gives an agent

5 rules. 0 are common, 4 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 115 edited versions we read keep these.

  • 4

    Distinctive

    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
  1. Distinctive:

    No red-capable command, no hypothesis.

    line 58
  2. Distinctive:

    When no loop is possible (production-only, unsafe, no access, no way to run commands), say so, list what you tried, and ask for access to …

    line 67
  3. Very specific:

    Follow the data, not the directory tree.

    line 96
  4. Distinctive:

    Logs and metrics around that timestamp: Read what happened *before* the error line.

    line 124
  5. Distinctive:

    When no loop can be built, say so and hand over as in step 4.

    line 130

“Common” is measured: kept by at least 6 in 10 of the 115 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

Investigate

Pick the mode from the question. They share the discipline below and differ in what counts as coverage.

ModeQuestion
root-causewhy is it broken
impactif I change this, what breaks
flowwhere does this data / request actually go
perfwhere does the time go
deployed servicewhy a running dev/prod service fails, seen only through telemetry

Shared discipline

Restate the symptom in observables. Log line, exit code, error text, a measured number, a screenshot. Not "the WebSocket is flaky" but the actual close code and the count. If the symptom is only reported second-hand, say so and find the observable before theorising.

Draw the boundary early. Two lists: what is ruled out and by what evidence, what is still in scope. An investigation without a shrinking boundary is a tour.

Every claim carries its evidence inline — path/to/file.py:214, or the command and its real output. Anything you concluded rather than observed is labelled as inference. Paste errors verbatim.

Separate root cause from contributing condition from symptom. Naming a contributing condition as the root cause is the most common way an investigation ends early and the bug comes back.

Close with what is open. What is now established, what is still UNCHECKED, and specifically what observation would close each open item. A green local test suite proves the code does not contradict itself; it does not prove a claim about the running system in production — that needs an observation from that system.

Report before fixing. Fix during an investigation only when the fix is one line and obviously correct, or you were asked to; a mid-investigation fix destroys the evidence for whether it was the cause.

Mode specifics

root-cause

Build a red loop before forming any theory. The loop is one command (a failing test, a curl against a dev server, a CLI call diffed against a fixture, a replayed captured payload, a git bisect run script) that goes red on this bug. The step is done when you have run it, shown the invocation and its real output, and it is:

  • red-capable: it drives the real code path and asserts the user's exact symptom, so it turns green only when this bug is gone;
  • deterministic: the same verdict every run;
  • tight: seconds per run, with only the setup the bug needs;
  • agent-runnable: it runs unattended. Where a person must act, script their part with scripts/hitl-loop.template.sh so the loop stays structured.

No red-capable command, no hypothesis. Then tighten it: cache setup and narrow the scope for speed, assert the specific symptom rather than "did not crash", pin time, seed randomness and isolate filesystem and network. For a flaky bug, raise the reproduction rate instead of chasing a clean repro: loop the trigger 100×, parallelise, add load, narrow the timing window. A 50% bug is debuggable; a 1% bug is not yet.

Once red, minimise: cut inputs, config, data and steps one at a time, re-running after each cut. Done when removing any remaining element turns the loop green.

When no loop is possible (production-only, unsafe, no access, no way to run commands), say so, list what you tried, and ask for access to an environment that reproduces it, a redacted captured artifact (HAR, log dump, core dump), or permission for temporary instrumentation. Name the strongest proxy you used instead (logs, a stack trace read against the code) and state that the cause was not reproduced.

Work backwards from the observable to the first point where the invariant was already violated. That point, not the crash site, is where the root cause lives.

Tag every temporary probe with one prefix per investigation, e.g. [DEBUG-a4f2], and remove them before reporting; rg '\[DEBUG-a4f2\]' returning nothing is the proof. Loop scripts and harnesses live in a scratch location outside the repo's tracked files; the report lists any that remain, and a failing test worth keeping is offered as the regression test rather than left behind. Show commands and output with secrets replaced by <REDACTED>, and build the loop on environment variables so credentials stay out of it.

impact

Text search finds strings; it does not find call sites. Use ast-grep for structural matches, and the LSP tool where a code-intelligence plugin is active. Grep is the fallback, and its misses are your responsibility to state.

Coverage is not just callers. Sweep: callers · tests · fixtures · migrations · config and env vars · serialised data already on disk or in a queue · anything outside the repo that consumes the shape (HTTP clients, events, DB schema, dashboards, alerts).

Say plainly what you could not enumerate — consumers outside the repo usually cannot be, and a confident "nothing else uses this" is the failure mode here.

flow

Follow the data, not the directory tree. One line per hop: where → where (protocol, shape of the payload). Note where the shape changes, where it is validated, and where it is persisted. Mark hops you inferred from code but did not observe.

A diagram only when there are three or more hops and at least one branch.

perf

State the budget and the current baseline before proposing anything. Optimising without a budget produces work nobody asked for.

Measure before attributing. hyperfine for commands, in-process timing for hot paths. Report where the time went as a breakdown that sums to the total, and say what environment it was measured on — a laptop number is not a pod number.

Comparing two configs/variants is a paired test, not two point estimates. "77% vs 75.9%" from two independent runs is noise dressed as a finding. Run both on the same inputs, use a paired test (McNemar for pass/fail pairs, a paired t-test or Wilcoxon for continuous metrics), and report the interval and sample size next to the delta. A result that does not clear the test is a null, and a null with its cost (tokens, dollars, wall time) reported is still useful — it rules something out. Include at least one negative control: a case that should show no effect, so a wiring bug that makes everything look like an improvement gets caught before the real comparison is trusted.

deployed service

A root-cause on a running dev/prod service, where you see it only through telemetry. Work down; each step is cheaper than the next and most stop at step 2.

  1. Error tracker first (eep:sentry-cli when Sentry is configured): the stack trace, first-seen time, the release it started in, event and user counts. Read the error before forming a theory.
  2. Logs and metrics around that timestamp. Read what happened before the error line. Before trusting "no logs", check ingestion is alive (event count per few hours over the last day); a cliff to zero is a pipeline outage to escalate, not a quiet service. Metrics answer whether it is one request or the whole system: error rate, latency, restarts, saturation. If a metric moved at a specific minute, find what else changed then.
  3. Build the loop by replaying the event's input in local/dev, held to the root-cause gate above. When no loop can be built, say so and hand over as in step 4.
  4. Know the wall. Telemetry cannot show which version is running, why a pod restarts or is OOMKilled, or what config the cluster actually holds. When the evidence points there, stop and hand over the error issue, log window, moved metric and the exact question to someone with cluster access.

Team specifics (datasource IDs, hosts, query recipes): read private/team-debug.md when present.

Reach for the right tool

Reach for a CLI before writing a script: gron makes JSON greppable, websocat tests a WebSocket (ast-grep and hyperfine are under impact and perf). Whatever observability stack the project already runs (metrics, error tracking, issue tracker) answers faster than re-deriving the same facts from raw logs; check what is configured first.

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.