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 agentmods add skills/zjunlp/mechanist/imagenpx skills add zjunlp/Mechanist --skill imagegit clone --depth 1 https://github.com/zjunlp/MechanistWrote 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/zjunlp/mechanist/image)<a href="https://agentmods.dev/skills/zjunlp/mechanist/image"><img src="https://agentmods.dev/badge/skills/zjunlp/mechanist/image.svg" alt="Measured on agentmods" 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 | $0.00183 | $0.01553 |
| Opus 5 | $0.00092 | $0.00776 |
| Sonnet 5 | $0.00037 | $0.00311 |
| Haiku 4.5 | $0.00018 | $0.00155 |
Grade A, and why
image 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 4d 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 — 101 lines — stays where its author put it; the contents beside it link to each section on GitHub.
ImageNet Eval Preprocessing
Drop-in snippet
import torchvision.transforms as T
IMAGENET_MEAN = (0.485, 0.456, 0.406)
IMAGENET_STD = (0.229, 0.224, 0.225)
def imagenet_eval_transform(crop: int = 224) -> T.Compose:
"""Canonical ImageNet eval preprocessing.
Pipeline:
1. Square resize to 256 x 256 (NOT short-side resize)
2. Center crop to `crop` x `crop` (default 224)
3. ToTensor (RGB / 255 -> [0, 1])
4. Normalize with ImageNet mean/std
"""
return T.Compose([
T.Resize((256, 256), antialias=True), # tuple => square resize
T.CenterCrop(crop),
T.ToTensor(),
T.Normalize(mean=IMAGENET_MEAN, std=IMAGENET_STD),
])
antialias=True is set explicitly because PIL inputs default to it but tensor inputs do not, and the explicit flag removes a version-dependent warning across torchvision ≥0.15.
The trap: Resize(256) vs Resize((256, 256))
Calling T.Resize with an int vs a tuple does two different things:
| Call | Behaviour | A 500 × 800 input becomes |
|---|---|---|
T.Resize(256) (int) |
Short-side resize, aspect ratio preserved | 256 × 410 |
T.Resize((256, 256)) (tuple) |
Square resize, aspect ratio NOT preserved | 256 × 256 |
After the subsequent T.CenterCrop(224), the two pipelines extract different patches from any non-square image. Most natural images (and most ImageNet validation images) are non-square, so the divergence applies to virtually the whole dataset.
For mechanistic interpretability and any work that ranks images by activation magnitude, this is a silent reproducibility hazard: the top-k maximally activating images set shifts when the crop shifts, which propagates to every downstream artefact — semantic embeddings, neuron labels, clarity / polysemanticity scores, faithfulness ablations. Numbers will look reasonable; they just will not match a reference pipeline that uses the other convention.
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.
- 4d ago First seen · 101 lines · 183 tokens per session scan A 306b8328132e
image is a skill published in the GitHub repository zjunlp/Mechanist (51 stars, last pushed 8d ago), licensed MIT. It adds 183 tokens to every session and 1,553 once invoked, about $0.0009 per session on Opus 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-08-30.
Other skills, from other repositories
nanoresearch-writing
Draft a LaTeX research paper from all previous stage outputs.
nanoresearch-experiment
Generate a Python code skeleton from an experiment blueprint.
nanoresearch-ideation
Search academic literature and generate research hypotheses.
ddr-globem-analysis
Analyze a specific participant's longitudinal passive-sensing and psychological data in the GLOBEM digital depression research dataset. Use this skill whenever the task involves: analyzing a user's mental health or behavioral data from wearables/smartphones, generating QA pairs about behavioral/psychological changes…
mimic-iv-patient-analysis
Comprehensive strategy for analyzing individual patient records in MIMIC-IV EHR database and generating high-quality, diverse QA pairs. Use this skill whenever the task involves analyzing a specific patient's clinical data from MIMIC-IV (or similar EHR databases), querying across hospital and ICU tables, and…
globem-user-analysis
Comprehensive individual-user analysis on the GLOBEM dataset — a longitudinal passive-sensing + mental-health study of college students. Use this skill whenever a task involves analyzing a specific participant (e.g. "Analyze user INS-W002") from the GLOBEM dataset, exploring behavioral patterns from smartphone…