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.
npx skills add MadGraphTeam/MadAgents --skill ma-doctorgit clone --depth 1 https://github.com/MadGraphTeam/MadAgentsWrote 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.
[](https://agentmods.dev/skills/madgraphteam/madagents/ma-doctor)<a href="https://agentmods.dev/skills/madgraphteam/madagents/ma-doctor"><img src="https://agentmods.dev/badge/skills/madgraphteam/madagents/ma-doctor/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.
<a href="https://agentmods.dev/skills/madgraphteam/madagents/ma-doctor"><img src="https://agentmods.dev/badge/skills/madgraphteam/madagents/ma-doctor.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00106 | $0.01201 |
| Opus 5.5 | $0.00042 | $0.00480 |
| Sonnet 5.5 | $0.00021 | $0.00240 |
| Haiku 4.5 | $0.00011 | $0.00120 |
Grade A, and why
ma-doctor 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 1mo 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.
How it starts
The opening of the file, as written. The whole thing — 64 lines — stays where its author put it; the contents beside it link to each section on GitHub.
ma-doctor — audit and improve this agent system's harness
Run this when the user asks to audit / doctor / tune / improve the setup itself — its agents, skills, rules, memory — never for a physics or MadGraph task.
This reshapes the harness. Hardening behavior from a specific past mistake into memory is /ma-reflect's job; this is the structural sibling — it changes the agents, skills, and rules themselves. It is human-gated: recommend first, change only on the user's explicit approval.
Everything the workflow needs is in this skill's folder:
analyst.md— the analysis brief.lessons/— agent-design principles (lessons/INDEX.mdis the list).cc-mechanics.md— what Claude Code can and cannot do, so a recommendation is buildable.use-case.md— the product goals every change must serve.reviewers/— the five panel briefs.
1. Snapshot
Before anything else, archive the current harness so the whole operation is revertable to the exact pre-doctor state:
root="${CLAUDE_PROJECT_DIR:-$PWD}"
ts=$(date -u +%Y-%m-%dT%H-%M-%SZ)
mkdir -p "$root/.madagents/harness-archive/$ts"
cp -r "$root/.claude" "$root/.madagents/harness-archive/$ts/"
2. Analyze
Dispatch a general-purpose agent with the full text of analyst.md as its instructions. It returns prioritized, evidence-cited recommendations. It is read-only — it analyzes and reports, it never edits.
3. Present and discuss
Relay the recommendations to the user. Each names the weakness and its evidence, the proposed change, the principle it follows, and the risk. Make no change yet. Discuss until the user decides.
4. Approve
Apply only the changes the user explicitly approves. If the user is unsure, stay in discussion.
5. Apply
Apply the approved change to .claude/. When editing an existing agent card, edit its body in place — do not overwrite its description, which may carry a learned routing refinement.
Edit by targeted substitution — never normalise. A change that spans many files (a discipline across the roster, a slate, the wiki) is surgical: write an exact-string or tightly-anchored replacement for the one thing you are changing. Never add a "cleanup" pass — collapsing whitespace, tidying punctuation, stripping empty parens. Each looks harmless alone; together they silently rewrite content that had nothing to do with the change, and the result still parses, so nothing errors.
What ships with it
50 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- analyst.md 5.1 KB
- cc-mechanics.md 4.5 KB
- lessons/01-confident-wrongness-is-the-default.md 1.8 KB
- lessons/02-ground-every-claim-in-the-source.md 2.6 KB
- lessons/03-calibration-and-honesty-about-limits.md 2.1 KB
- lessons/04-reserve-the-model-for-judgment.md 1.6 KB
- lessons/05-the-maker-cannot-check-itself.md 2.2 KB
- lessons/06-running-is-not-being-right.md 2.4 KB
- lessons/07-reviewer-posture-and-actionable-feedback.md 2.0 KB
- lessons/08-the-evaluator-is-the-floor.md 1.5 KB
- lessons/09-independence-makes-pooling-work.md 1.7 KB
- lessons/10-consensus-before-high-stakes-claims.md 1.6 KB
- lessons/11-match-orchestration-to-complexity.md 1.8 KB
- lessons/12-do-not-over-fan-out.md 2.0 KB
- lessons/13-subagents-are-independent-context.md 1.6 KB
- lessons/14-self-contained-dispatch.md 1.6 KB
- lessons/15-dispatch-the-what-not-the-how.md 1.7 KB
- lessons/16-agree-done-up-front.md 1.6 KB
- lessons/17-the-lead-owns-the-final-voice.md 1.6 KB
- lessons/18-map-not-manual.md 2.5 KB
- lessons/19-guardrails-by-exclusion.md 1.9 KB
- lessons/20-the-description-is-the-router.md 3.4 KB
- lessons/21-curate-the-dispatch-payload.md 1.8 KB
- lessons/22-plain-files-not-a-database.md 1.9 KB
- lessons/23-memory-is-an-index-of-pointers.md 2.3 KB
- lessons/24-compile-dont-re-derive.md 2.4 KB
- lessons/25-source-versus-derived-knowledge.md 3.0 KB
- lessons/26-a-written-schema-and-a-shallow-cross-linked-tree.md 2.7 KB
- lessons/27-capture-a-lesson-from-every-mistake.md 2.7 KB
- lessons/28-know-what-not-to-learn.md 1.9 KB
- lessons/29-curate-the-learned-store.md 2.0 KB
- lessons/30-keep-the-human-on-the-loop.md 2.1 KB
- lessons/31-ask-before-guessing.md 1.5 KB
- lessons/32-surface-a-choice-well.md 1.6 KB
- lessons/33-gate-consequential-actions.md 1.7 KB
- lessons/34-design-degradation-paths.md 1.4 KB
- lessons/35-constraints-not-model-size-are-the-edge.md 2.5 KB
- lessons/36-dont-add-machinery-that-costs-more-than-it-saves.md 1.6 KB
- lessons/37-save-as-you-go-and-phase-the-work.md 2.3 KB
- lessons/38-compose-primitives-dont-bolt-on.md 2.0 KB
- lessons/39-narrow-specialists-beat-generalists.md 1.9 KB
- lessons/40-weight-a-judge-by-its-track-record.md 2.7 KB
- lessons/41-record-the-thesis-not-just-the-verdict.md 1.5 KB
- lessons/INDEX.md 8.9 KB
- reviewers/best-practice.md 1.4 KB
- reviewers/cc-alignment.md 1.2 KB
- reviewers/edit-critic.md 2.2 KB
- reviewers/surface-discipline.md 4.3 KB
- reviewers/use-case.md 1.1 KB
- use-case.md 2.8 KB
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.
- 1mo ago First seen · 64 lines · 106 tokens per session scan A 7da70163208f
ma-doctor is a skill published in the GitHub repository MadGraphTeam/MadAgents (14 stars, last pushed 2mo ago), licensed MIT. It adds 106 tokens to every session and 1,201 once invoked, about $0.0004 per session on Opus 5.5. 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-09-03.
Other skills, from other repositories
local-ai-agents
Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…
systematic-debugging
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.
next-cache-components-adoption
Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…
chat-pet-sprite-creation
Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.
cpu-profile-analysis
Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…
insight-error-page
Write or audit an insight-kind error page for the Next.js dev overlay. Use when creating a new errors/ .mdx page, auditing an existing one, or checking that a page matches the framework fix cards. Covers page structure, title alignment, FixCard cards with Copy prompt button, code snippets, terminology verification…