analyst_diagnostic

analyst_diagnostic is a cursor rule for Cursor from HomenShum/NodeBenchAI. It costs 0 tokens per session (748 once invoked), scanned A, original, MIT.

A set of debugging rules that instructs an agent to find the underlying cause of a problem before changing code. It recommends reproducing the issue, tracing its data and state, and checking nearby behaviour after the fix.

In plain words
What is it for?
Use it when investigating bugs, errors, failing tests, or behaviour that appears to work but seems incorrect.
Why use it?
It helps prevent temporary patches that hide errors or move them to another part of the system.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use it when investigating bugs, errors, failing tests, or behaviour that appears to work but seems incorrect.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/homenshum/nodebenchai/analyst_diagnostic
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/HomenShum/NodeBenchAI

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for analyst_diagnostic

README.md
[![agentmods](https://agentmods.dev/badge/rules/homenshum/nodebenchai/analyst_diagnostic/github.svg)](https://agentmods.dev/rules/homenshum/nodebenchai/analyst_diagnostic)
Your own site
<a href="https://agentmods.dev/rules/homenshum/nodebenchai/analyst_diagnostic"><img src="https://agentmods.dev/badge/rules/homenshum/nodebenchai/analyst_diagnostic/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for analyst_diagnostic

Your own site · 80×15
<a href="https://agentmods.dev/rules/homenshum/nodebenchai/analyst_diagnostic"><img src="https://agentmods.dev/badge/rules/homenshum/nodebenchai/analyst_diagnostic.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 748 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.00748
Opus 5.5 $0.00000 $0.00299
Sonnet 5.5 $0.00000 $0.00150
Haiku 4.5 $0.00000 $0.00075

Measured 3mo ago against content hash 0ee678c9d0ba, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

analyst_diagnostic scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/analyst_diagnostic.mdc · 54 lines

How it starts

The opening of the file, as written. The whole thing — 54 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Analyst Diagnostic

Guide yourself like an analyst diagnosing the root cause, not a junior dev slapping on a bandaid.

When to trigger

  • Before writing ANY fix — investigate why the bug exists, not just what it looks like
  • When an error appears — trace it upstream to the source, don't just suppress it
  • When a test fails — understand the system state that caused it, not just make the assertion pass
  • When something "works but feels wrong" — name the smell, don't ignore it

The diagnostic process

  1. Reproduce: Confirm the exact failure mode. What triggers it? What's the expected vs actual?
  2. Trace upstream: Walk from symptom → intermediate state → root cause. Follow the data, not assumptions.
  3. Ask "why" 5 times: Each answer should go one level deeper. Stop when you reach a design decision, missing constraint, or wrong assumption.
  4. Fix the cause, not the symptom: The right fix makes the symptom impossible, not just invisible.
  5. Verify the fix didn't shift the problem: Bandaids often move bugs sideways. Check adjacent behavior.

Red flags you're bandaiding

  • Adding try/catch that swallows errors without understanding them
  • Adding ?. optional chaining to mask undefined instead of finding why it's undefined
  • Adding as any to silence type errors instead of fixing the type mismatch
  • Adding timeouts/retries to paper over race conditions
  • Deleting a failing test instead of fixing the code it tests
  • "It works now" without understanding why it didn't before

What analysts do differently

  • They form a hypothesis BEFORE trying a fix
  • They check if the "fix" actually addresses their hypothesis
  • They look for other places the same root cause could cause problems
  • They document what they found so the next person doesn't re-discover it
  • They ask: "What system condition allowed this bug to exist?"

UI-specific diagnostic

When fixing a UI issue, the analyst approach demands:

  1. Which component actually renders? Trace sidebar label → view key → MainLayout switch → component import. Grep alone can find the wrong file.
  2. What layer owns the data? Convex backend, React frontend, or stored DB records? Each requires a different deployment path.
  3. Is this a cold-start problem? Empty states for new users often point to missing bootstrap/onboarding data, not just bad copy. Fixing text is a bandaid; showing fallback content (trending, sample, public data) is structural.
  4. Would hiding the problem make it invisible or actually solve it? Changing "0/7 healthy" to "7 scheduled" hides a monitoring signal. The structural question is: should this panel even render when the system isn't configured?

Read the full file on GitHub · 54 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3mo ago First seen · 54 lines · 0 tokens per session scan A 0ee678c9d0ba

Subscribe to this mod's changes

analyst_diagnostic is a cursor rule published in the GitHub repository HomenShum/NodeBenchAI (14 stars, last pushed 17d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 748 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

analyst_diagnostic compared with cursor rules from other repositories

analyst_diagnostic next to 6 cursor rules from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
analyst_diagnosticHomenShum/NodeBenchAICursor rule1417d agoMITA0Cursor
hatch3r-observability-logginghatch3r/hatch3rCursor rule262mo agoMITA0Cursor
linuxAcKeskin/contextureCursor rule28d agoMITA1,224Cursor
ponytailDietrichGebert/ponytailCursor rule201k8d agoMITA604Cursor
angular-20angular/angularCursor rule102k5d agoMITA0Cursor
dev-standardapache/supersetCursor rule76ktodayApache-2.0A1,147Cursor
prefer-assertions-over-defensive-checksprisma/ormCursor rule48ktodayApache-2.0A0Cursor