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 zjunlp/Mechanist --skill attribution-based-edge-scoringgit 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/attribution-based-edge-scoring)<a href="https://agentmods.dev/skills/zjunlp/mechanist/attribution-based-edge-scoring"><img src="https://agentmods.dev/badge/skills/zjunlp/mechanist/attribution-based-edge-scoring.svg" alt="Measured on agentmods" height="20"></a>- NVIDIA SkillSpector pass
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.00048 | $0.00684 |
| Opus 5 | $0.00024 | $0.00342 |
| Sonnet 5 | $0.00010 | $0.00137 |
| Haiku 4.5 | $0.00005 | $0.00068 |
Grade A, and why
eap-ig 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 8d 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 — 98 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Demo Scripts
scripts/usage_example.py
#!/usr/bin/env python3
"""
Demonstration script for EAP-IG library usage.
This script constructs a computational graph for a TransformerLens GPT-2 model,
runs Edge Attribution Patching with Integrated Gradients (EAP-IG-inputs) to score
nodes or edges, selects a top-n circuit, and evaluates its impact on a simple task.
You must install this library and TransformerLens prior to running:
pip install . transformer_lens
Replace the model loading step with your preferred TransformerLens autoregressive model.
"""
import torch
from torch.utils.data import DataLoader
from transformer_lens import HookedTransformer
from eap.graph import Graph
from eap.attribute import attribute
from eap.evaluate import evaluate_graph
from eap.utils import EAPDataset
def accuracy_metric(preds: torch.Tensor, labels: torch.Tensor) -> torch.Tensor:
"""
Simple accuracy metric.
Args:
preds: Model logits tensor of shape (batch, seq_len, vocab_size)
labels: Ground truth labels tensor of shape (batch, seq_len)
Returns:
Tensor with scalar accuracy (fraction correct)
"""
pred_tokens = preds.argmax(dim=-1)
correct = (pred_tokens == labels).float()
return correct.mean()
def main():
# Load a pretrained GPT-2 small model from TransformerLens
# This requires the transformer_lens package: pip install transformer_lens
model_name = "gpt2-small"
print(f"Loading TransformerLens model '{model_name}' ...")
model = HookedTransformer.from_pretrained(model_name)
# Prepare an example dataset for the "greater-than" synthetic task provided by EAPDataset
dataset = EAPDataset("greater-than")
dataloader = dataset.to_dataloader(batch_size=16, shuffle=True)
# Build computational graph from the model
print("Building computational graph from model ...")
graph = Graph.from_model(model)
# Compute attribution scores with EAP-IG on inputs mode (5 integrated gradient steps)
print("Computing attribution scores with EAP-IG (inputs) ...")
attribute(
model=model,
graph=graph,
dataloader=dataloader,
metric=accuracy_metric,
method="EAP-IG-inputs",
ig_steps=5,
intervention="none",
)
# Select top 10 nodes/edges to define the circuit
top_n = 10
print(f"Selecting top {top_n} scoring components as circuit ...")
graph.apply_topn(top_n)
# Evaluate circuit by ablating outside nodes/edges and measuring accuracy
print("Evaluating circuit faithfulness on dataset ...")
results = evaluate_graph(
model=model,
graph=graph,
dataloader=dataloader,
metric=accuracy_metric,
intervention="none",
)
print("Circuit evaluation results:", results)
if __name__ == "__main__":
main()
What ships with it
3 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.
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.
- 8d ago First seen · 98 lines · 48 tokens per session scan A 9d4e3c5f0ffe
eap-ig is a skill published in the GitHub repository zjunlp/Mechanist (72 stars, last pushed 12d ago), licensed MIT. It adds 48 tokens to every session and 684 once invoked, about $0.0002 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.
nnsight-remote-interpretability
Provides guidance for interpreting and manipulating neural network internals using nnsight with optional NDIF remote execution. Use when needing to run interpretability experiments on massive models (70B+) without local GPU resources, or when working with any PyTorch architecture.
sparse-autoencoder-training
Provides guidance for training and analyzing Sparse Autoencoders (SAEs) using SAELens to decompose neural network activations into interpretable features. Use when discovering interpretable features, analyzing superposition, or studying monosemantic representations in language models.
transformer-lens-interpretability
Provides guidance for mechanistic interpretability research using TransformerLens to inspect and manipulate transformer internals via HookPoints and activation caching. Use when reverse-engineering model algorithms, studying attention patterns, or performing activation patching experiments.