Source profileQuality 89/100Review permissions

Aperivue/medsci-skills/skills/explainability/SKILL.md

explainability

Produce or audit the interpretability/explainability analysis of a medical-imaging model — Grad-CAM / Grad-CAM++ / attention-rollout / saliency / integrated-gradients — so it clears the rigor bar a reviewer expects: mandatory Adebayo sanity checks (model- and data-randomisation), a quantitative localisation metric against ground truth (IoU / pointing game / Dice) instead of eyeballed examples, a cohort-level result rather than cherry-picked cases, and attribution framing rather than "proof the m

Source repository stars
237
Declared platforms
0
Static risk flags
1
Last source update
2026-08-05
Source checked
2026-08-06

Decision brief

What it does—and where it fits

Produce or audit the interpretability/explainability analysis of a medical-imaging model — Grad-CAM / Grad-CAM++ / attention-rollout / saliency / integrated-gradients — so it clears the rigor bar a reviewer expects: mandatory Adebayo sanity checks (model- and data-randomisation), a quantitative localisation metric against ground truth (IoU / pointing game /…

Best for

  • A saliency / Grad-CAM heat-map is the most over-interpreted artifact in medical-imaging AI: a colourful map over the lesion is routinely presented as proof the model "looks at the right thing." Adebayo et al. (NeurIPS 2…
  • It sits alongside evaluation in the lane: /architecture-zoo → /preprocess-imaging → /model-scaffold → /model-validation → /model-evaluation + explainability → /write-paper + /check-reporting. It integrates captum / pyto…

Not for

  • Discrimination / calibration metrics → /model-evaluation then /analyze-stats.
  • Split or preprocessing leakage → /model-validation / /preprocess-imaging.

Compatibility matrix

Platform support, with evidence labels

PlatformStatusEvidenceWhat to check
CodexNot declaredNo explicit evidencePortability before use
Claude CodeNot declaredNo explicit evidencePortability before use
CursorNot declaredNo explicit evidencePortability before use
Gemini CLINot declaredNo explicit evidencePortability before use
Open the compatibility checker

Installation

Inspect first. Install second.

The source command is displayed only when detected. A safe inspection prompt is always available so your agent can explain every action before execution.

Source-detected install commandSource
npx skills add https://github.com/Aperivue/medsci-skills --skill "skills/explainability"
Safe inspection promptEditorial

Inspect the Agent Skill "explainability" from https://github.com/Aperivue/medsci-skills/blob/8b39515657a0e0a575d91b1b00b6f3df4f7bb90f/skills/explainability/SKILL.md at commit 8b39515657a0e0a575d91b1b00b6f3df4f7bb90f. List every install step, command, network request, credential, file read/write, external action, and rollback step. Explain whether it fits my task. Do not install or execute anything until I approve.

Workflow

What the source asks the agent to do

  1. 01

    Workflow

    Choose the method for the architecture (references/explainabilityguide.md): Grad-CAM / Grad-CAM++ for CNNs, attention-rollout for ViTs, integrated-gradients / SHAP for attribution. Wire captum or pytorch-grad-cam; do not write a new CAM implementation.

    Run the model-parameter randomisation and data (label) randomisation tests (Adebayo 2018);Compute a quantitative localisation metric against ground-truth masks (IoU / pointing game /Choose the method for the architecture (references/explainabilityguide.md): Grad-CAM / Grad-CAM++ for CNNs, attention-rollout for ViTs, integrated-gradients / SHAP for attribution. Wire captum or pytorch-grad-cam; do no…
  2. 02

    Phase 1 — Produce the maps (integrate, don't reimplement)

    Choose the method for the architecture (references/explainabilityguide.md): Grad-CAM / Grad-CAM++ for CNNs, attention-rollout for ViTs, integrated-gradients / SHAP for attribution. Wire captum or pytorch-grad-cam; do not write a new CAM implementation.

    Choose the method for the architecture (references/explainabilityguide.md): Grad-CAM / Grad-CAM++ for CNNs, attention-rollout for ViTs, integrated-gradients / SHAP for attribution. Wire captum or pytorch-grad-cam; do no…
  3. 03

    Phase 2 — Sanity-check and quantify

    Run the model-parameter randomisation and data (label) randomisation tests (Adebayo 2018);

    Run the model-parameter randomisation and data (label) randomisation tests (Adebayo 2018);Compute a quantitative localisation metric against ground-truth masks (IoU / pointing game /- Run the model-parameter randomisation and data (label) randomisation tests (Adebayo 2018); a faithful map degrades when the model/labels are randomised. - Compute a quantitative localisation metric against ground-trut…
  4. 04

    Phase 3 — Emit the explainability-report manifest

    interpretation: attribution / localization / faithfulness (descriptive) — never validation / causal (overclaim).

    interpretation: attribution / localization / faithfulness (descriptive) — never validation / causal (overclaim).
  5. 05

    Phase 4 — Gate the report (deterministic)

    Verdicts: SALIENCYASVALIDATION, NOSANITYCHECK, NOLOCALIZATIONMETRIC (Major); INSUFFICIENTSANITY, CHERRYPICKEDEXAMPLES, MISSINGMETHOD (Minor). The verdict is reproduced by rule on the manifest, never asserted from prose.

    Verdicts: SALIENCYASVALIDATION, NOSANITYCHECK, NOLOCALIZATIONMETRIC (Major); INSUFFICIENTSANITY, CHERRYPICKEDEXAMPLES, MISSINGMETHOD (Minor). The verdict is reproduced by rule on the manifest, never asserted from prose.

Permission review

Static risk signals and limitations

Runs scripts

medium · line 68

The documentation asks the agent to run terminal commands or scripts.

python3 scripts/check_explainability_report.py --manifest explainability_report.json --strict

Evidence record

Why each signal appears

EvidenceSourceComputedTestedEditorial
SignalValueEvidence typeMeaning
Quality score89/100ComputedDocumentation, specificity, maintenance, and trust rules
Repository stars237SourceRepository attention, not individual Skill quality
Compatibility0 platformsSourceDeclared in the catalog source record
Usage guideautomated source guideEditorialGenerated or reviewed according to the visible evidence level

Pinned source

Provenance and original SKILL.md

Repository
Aperivue/medsci-skills
Skill path
skills/explainability/SKILL.md
Commit
8b39515657a0e0a575d91b1b00b6f3df4f7bb90f
License
MIT
Collected
2026-08-06
Default branch
main
View the original SKILL.md

Explainability Skill

Purpose

A saliency / Grad-CAM heat-map is the most over-interpreted artifact in medical-imaging AI: a colourful map over the lesion is routinely presented as proof the model "looks at the right thing." Adebayo et al. (NeurIPS 2018) showed many saliency methods produce visually convincing maps that are independent of the model's learned weights and of the labels — so they explain nothing. This skill produces an explainability analysis that clears the rigor bar, and audits an existing one, so the map is trustworthy before it reaches a manuscript (CLAIM 2024 / TRIPOD+AI interpretability items).

It sits alongside evaluation in the lane: /architecture-zoo/preprocess-imaging/model-scaffold/model-validation/model-evaluation + explainability/write-paper + /check-reporting. It integrates captum / pytorch-grad-cam (referenced in the plan); it does not reimplement them and never runs a model on real patient data.

When to use

  • You produced (or are about to produce) saliency / Grad-CAM / attention maps and want them reported to the standard a reviewer expects.
  • You want to audit an explainability analysis for the four failure modes below.

When NOT to use

  • Discrimination / calibration metrics → /model-evaluation then /analyze-stats.
  • Split or preprocessing leakage → /model-validation / /preprocess-imaging.
  • LLM/MLLM faithfulness & hallucination → /mllm-eval.
  • Reimplementing captum / pytorch-grad-cam → out of scope (this skill wires and audits them).

The four failure modes (what the gate enforces)

  1. Saliency as validation. A map is attribution, not proof the model is correct or that the relationship is causal. Frame it as "where signal is attributed", never as "the model is right".
  2. No sanity check. Run the Adebayo model-randomisation and data-randomisation tests. A map that survives neither is uninterpretable; both axes are the minimum bar.
  3. No quantitative localisation. If you claim the map localises the finding, measure it — IoU / pointing game / Dice against ground-truth masks — do not eyeball a few examples.
  4. Cherry-picked examples. Report a cohort-level result, not a handful of hand-picked cases.

Workflow

Phase 1 — Produce the maps (integrate, don't reimplement)

Choose the method for the architecture (references/explainability_guide.md): Grad-CAM / Grad-CAM++ for CNNs, attention-rollout for ViTs, integrated-gradients / SHAP for attribution. Wire captum or pytorch-grad-cam; do not write a new CAM implementation.

Phase 2 — Sanity-check and quantify

  • Run the model-parameter randomisation and data (label) randomisation tests (Adebayo 2018); a faithful map degrades when the model/labels are randomised.
  • Compute a quantitative localisation metric against ground-truth masks (IoU / pointing game / Dice) over the cohort — not a visual impression.

Phase 3 — Emit the explainability-report manifest

{
  "method": "grad-cam++",
  "n_examples": 200,
  "cohort_level": true,
  "localization_metric": "iou",
  "localization_value": 0.63,
  "sanity_checks": ["model_randomization", "data_randomization"],
  "interpretation": "localization"
}

interpretation: attribution / localization / faithfulness (descriptive) — never validation / causal (overclaim).

Phase 4 — Gate the report (deterministic)

python3 scripts/check_explainability_report.py --manifest explainability_report.json --strict

Verdicts: SALIENCY_AS_VALIDATION, NO_SANITY_CHECK, NO_LOCALIZATION_METRIC (Major); INSUFFICIENT_SANITY, CHERRY_PICKED_EXAMPLES, MISSING_METHOD (Minor). The verdict is reproduced by rule on the manifest, never asserted from prose.

Integration

  • /model-evaluation — explainability accompanies the held-out metrics as a secondary analysis.
  • /self-review ai_overclaiming / image_synthesis probes audit saliency overclaiming in a finished manuscript; this skill produces the rigorous analysis they look for.
  • /check-reporting — the manifest documents the CLAIM 2024 / TRIPOD+AI interpretability items.

Anti-Hallucination

  • Never fabricate saliency maps, localisation metrics, or sanity-check results. Every value in the manifest comes from the researcher's executed XAI code — never invented. This skill designs and audits the analysis; it does not run a model on real patient data.
  • Never present a saliency map as proof of model correctness or causation. A map is attribution; claiming it validates the model is the overclaim this skill exists to prevent (SALIENCY_AS_VALIDATION).
  • Never report an explainability-audit "pass" without running check_explainability_report.py. The rigor verdict is reproduced deterministically, never asserted from prose.
  • Integrate, don't reimplement. Reference captum / pytorch-grad-cam; do not write a new CAM / attribution implementation or claim results for one.

Reproducible challenge

scripts/check_explainability_report_challenge/ ships a synthetic weak/strong report pair with a network-free verify.sh wired into the skill's validation commands.

Alternatives

Compare before choosing

Computed 941,212

first-fluke/oh-my-agent

oma-docs

Verify documentation references against the current codebase, propose updates for diff-affected docs, detect i18n translation drift, and lint translated docs for CJK style issues. Use to check if docs still match reality (broken file paths, CLI commands, config keys, env vars, scripts), to surface docs that may need updating after code changes, or to find stale or style-broken translations.

Computed 936

mgiovani/cc-arsenal

ci-local

Run the checks a GitHub Actions workflow would run, locally, when Actions is unavailable or out of quota. Parses .github/workflows/*.yml, extracts the jobs/steps that gate merges (lint, typecheck, test, build), translates them to local commands respecting the workflow's pinned node/python versions and env, executes them sequentially, and reports a parity table of what passed locally vs. what can't be replicated (service containers, secrets, matrix dimensions) and why. Activates on "CI quota", "A

Computed 921,212

first-fluke/oh-my-agent

oma-translator

Context-aware translation that preserves tone, style, and natural word order. Use when translating UI strings, documentation, marketing copy, or any multilingual content. Infers register, domain, and style from the source text and surrounding codebase context.

Computed 8723,881

alirezarezvani/claude-skills

sql-database-assistant

Use when the user asks to write SQL queries, optimize database performance, generate migrations, explore database schemas, or work with ORMs like Prisma, Drizzle, TypeORM, or SQLAlchemy.