Neuronpedia is a free, open source (Apache 2.0) website and API for exploring what is going on inside open weight language models: you can search the features that sparse autoencoders find, steer a model with them, build circuit tracing graphs, and read a model's "J-space" with the Jacobian Lens. It complements the two main Python libraries rather than replacing them. You write experiments in TransformerLens or nnsight, and you look up and share what you found on Neuronpedia.
TransformerLens vs nnsight is a choice between two ways of looking inside a language model. TransformerLens gives you a standard, interpretability friendly view of a model, with consistent hook names on every layer and a one line way to cache all activations; it is the library most mechanistic interpretability tutorials teach. nnsight wraps the model you already have, any PyTorch model, and lets you read and edit its internals inside a with model.trace() block, and it can run the same code remotely on very large open models through the free NDIF service. Choose TransformerLens to learn and to follow existing research recipes; choose nnsight for big models, unusual architectures, or when you cannot host the model yourself. New to the field? Start with what mechanistic interpretability research is.
The big 2026 change: TransformerLens 4.0
If you learned TransformerLens from older tutorials, note that version 4.0, released on PyPI in September 2026, removed the classic HookedTransformer class. According to the official migration guide, TransformerBridge, introduced in 3.0, is now the only path. The old 3.x branch still gets bug fixes, but no new features or models.
# TransformerLens 4.0
from transformer_lens.model_bridge import TransformerBridge
model = TransformerBridge.boot_transformers("gpt2")
model.enable_compatibility_mode() # HookedTransformer-style weight processing
logits, cache = model.run_with_cache("Hello World")
By default the bridge keeps the raw Hugging Face weights, so its outputs match Transformers. Calling enable_compatibility_mode() reproduces the old defaults, such as folding LayerNorm into the weights, so results from older notebooks line up. The project's README says the bridge supports more than 15,000 models across over 140 architecture families.
TransformerLens vs nnsight at a glance
| Item | TransformerLens | nnsight |
|---|---|---|
| Approach | Reexposes the model with standard hook points | Traces the original PyTorch model in place |
| Latest PyPI release (checked October 22, 2026) | 4.2.0 (October 10) | 0.8.1 (October 20) |
| Model support | Hugging Face models through TransformerBridge | Any PyTorch model, with wrappers for Hugging Face, diffusers and vLLM |
| Remote execution | No | Yes, through NDIF with an API key |
| Best known for | Teaching and classic circuit style research | Large models and flexible interventions |
| Licence | MIT | MIT |
How TransformerLens works
TransformerLens was created by Neel Nanda and is now maintained by a community team. Its goal, in the README's words, is to reverse engineer the algorithms a model learned from its weights. You load a model, run it with a cache, and every internal activation, from attention patterns to residual stream values, is available under a predictable name. You can also attach hook functions to edit, remove or replace activations as the model runs, which is how techniques like activation patching are done.
The strengths are consistency and community. Hook names follow the same scheme across supported models, which makes notebooks far easier to move from one model to another. Much of the published interpretability curriculum, including the ARENA course linked from the README, is built on it, and SAELens offers deep integration for working with sparse autoencoders.
The tradeoff is that TransformerLens needs an adapter for each architecture, and very new models may lag. It also runs everything locally, so you need enough memory to hold the model; our VRAM guide helps you estimate that.
How nnsight works
nnsight comes from the NDIF team, described in the paper NNsight and NDIF. Instead of reimplementing the model, it records what you want to do and runs it alongside the real forward pass. Version 0.8.0 (October 16, 2026) made TransformersModel the class in the quick start, and 0.8.1 followed on October 20. The current README example looks like this:
from nnsight import TransformersModel
model = TransformersModel("openai-community/gpt2", dispatch=True)
with model.trace("The Eiffel Tower is in the city of"):
model.transformer.h[0].output[:] = 0 # edit a layer's output
hidden = model.transformer.h[6].output.save() # read a later layer
logits = model.output.logits.save()
In 0.8 a GPT-2 block's .output is a plain tensor, so older snippets that index .output[0] on a block need updating; attention modules still return tuples. The older LanguageModel class is still importable, so existing notebooks keep loading. The 0.8.0 release notes also cut import nnsight time from 7.6 to 1.6 seconds and add an nnsight login command for storing your NDIF key.
You write the intervention in the order the model executes it, and mark what you want to keep with .save(). The nnsight README also shows generation, batching several prompts, gradients with respect to internal values, and applying modules out of order, as in the logit lens. Check the docs for the version you install, because the API moves between minor releases.
The headline feature is remote execution. Add remote=True and an NDIF API key, and the same trace runs on NDIF's servers. The NDIF website describes it as a National Science Foundation project offering free remote access to large open models for research. Available models change, so check NDIF's status page.
The tradeoff is that you work with each model's own module names, which differ between architectures, so code is less portable than TransformerLens notebooks.
Where Neuronpedia fits
Neuronpedia started as a hosted website and was open sourced on March 31, 2025 by its creator Johnny Lin, together with more than 4 TB of public interpretability datasets. The GitHub repository is Apache 2.0 and lists its features as an API, steering, activation testing, circuit graphs, autointerp explanations and scoring, search, SAE dashboards, probes and exports. The newest web release on GitHub is v2.8.0 (October 20, 2026), which improved neuron search.
Two recent features explain much of the current search interest:
- Jacobian Lens. Launched in July 2026 at neuronpedia.org/jlens, it shows the concepts a model "holds in mind" at each token, based on the global workspace (J-space) idea from Gurnee et al., and lets you swap or steer those concepts and compare answers. Per the Jacobian Lens docs, Neuronpedia has prefitted lenses for 36 or more models, the largest being Llama 70B, with tabs for Qwen 3.6 27B, Gemma 3 12B and DeepSeek V4 Flash. On October 15, 2026 it added the J++ Lens by Ayonrinde and Lindsey, a drop in replacement that reads early layers more faithfully. If you run those models yourself, see our guides to running Qwen 3.6 locally and running Gemma 4 locally (a J++ lens for Gemma 4 31B is on Neuronpedia's Hugging Face page).
- Circuit tracer. Built with Anthropic and the Anthropic Fellows on the open source
circuit-tracerlibrary, it generates attribution graphs from your own prompt in about a minute. The circuit tracing docs list Gemma 2 2B, Gemma 3 4B Instruct, Qwen3 4B and Qwen3 1.7B for new graphs. Anthropic's own write ups on features and circuits live on Transformer Circuits.
Neuronpedia also has natural language autoencoders (NLAs), which explain activations in plain English.
In practice the three tools form one workflow:
- Train or load sparse autoencoders with SAELens, which works with TransformerLens and, if you extract activations yourself, with nnsight.
- Look up what each feature means on Neuronpedia, where published SAEs come with top activating examples and written explanations.
- Go back to TransformerLens or nnsight to steer or ablate the features you found and measure the effect.
You can also self host the whole platform. The README says every service runs locally, starting from a Postgres 16 database with the pgvector extension, and that the local database starts empty until you import the sources you want. For code, the public API covers almost everything on the site: features, activation tests, search, steering, graphs, the Jacobian Lens and NLAs. Many GET endpoints work without a key, while writes need an x-api-key header. For Python there is a neuronpedia package on PyPI (version 1.2.1, unchanged as of October 22, 2026), and bulk data should come from the exports rather than one API call per feature. For the research context, see our mechanistic interpretability explainer.
If you only need attribution scores for a classic model rather than mechanistic internals, Captum (attribution methods such as integrated gradients for PyTorch) and SHAP (Shapley value explanations for any model) are the usual choices.
Side by side: common tasks
- Cache every activation: TransformerLens's
run_with_cachedoes it in one call. In nnsight, you save the specific values you need. - Activation patching: both handle it well. TransformerLens uses hook functions; nnsight lets you assign values from one trace into another.
- Steering vectors: both can add a vector to the residual stream; nnsight's in place edits read naturally.
- Sparse autoencoders: SAELens integrates most deeply with TransformerLens, but its README says SAEs work with Transformers, nnsight or any PyTorch model if you extract activations yourself. You can explore published SAE features on Neuronpedia.
- Toy models: TransformerLens 4.0 can build a model from a config with
TransformerBridge.boot_native, handy if you train a small LLM from scratch to study. - Models too big for your GPU: nnsight with NDIF.
Pros and cons
TransformerLens
- Pros: consistent hook names across models; one line activation caching; the most tutorials and research recipes; strong sparse autoencoder tooling.
- Cons: version 4.0 breaks older
HookedTransformercode; depends on architecture adapters; local only.
nnsight
- Pros: works with any PyTorch model; very flexible interventions; free remote access to large models through NDIF; supports vLLM for faster generation.
- Cons: code depends on each model's module layout; the deferred execution style takes some getting used to; remote use requires an account and API key.
Which should you choose?
- You are learning mechanistic interpretability: TransformerLens, following the ARENA curriculum.
- You are reproducing a paper from the last few years: probably TransformerLens, with compatibility mode on.
- You study a model with tens of billions of parameters and lack the hardware: nnsight with NDIF.
- You work on a brand new or nonstandard architecture: nnsight.
- You do sparse autoencoder work: start with SAELens and TransformerLens, and move to nnsight if your model is not supported.
Both libraries depend on open weights; our explainer on open weight vs open source models covers which models allow this kind of research.
Who this is for
Researchers, students and engineers getting started with mechanistic interpretability, and anyone whose old TransformerLens code broke after the 4.0 release.
FAQ
What is Neuronpedia used for?
Neuronpedia is used to explore what features inside a model mean. You can search features by description, view the text that activates them, steer a model with them, and build attribution graphs for supported open weight models. It is free on the web and Apache 2.0 if you want to self host.
What is the Neuronpedia Jacobian Lens?
It is a Neuronpedia tool, at neuronpedia.org/jlens, that reads the concepts a model holds at each token from what Gurnee et al. call the Jacobian space, or J-space. You chat with a supported model, select tokens, and see the top readouts per layer, then swap or steer a readout to see how the answer changes. The J++ Lens option is a newer drop in replacement that works better on early layers.
Does Neuronpedia have an API?
Yes. The API reference at neuronpedia.org/api-doc covers features, explanations, activation tests, search, steering, attribution graphs, the Jacobian Lens and NLAs. Reading most data needs no key; writing data needs an API key in the x-api-key header, and the neuronpedia Python package wraps common calls.
Is Neuronpedia made by Anthropic?
No. Neuronpedia was created by Johnny Lin and is run with Decode Research. Anthropic worked with it on the circuit tracer: when Anthropic open sourced its circuit tracing tools on May 29, 2025, the interactive graph frontend was hosted on Neuronpedia, and the Jacobian Lens files are fitted with Anthropic's Jacobian Lens library.
What is the difference between TransformerLens and nnsight?
TransformerLens exposes a model through standard, consistent hook points and makes it easy to cache all activations. nnsight traces the original PyTorch model in place, works with any architecture, and can run experiments remotely on large models through NDIF.
Was HookedTransformer removed from TransformerLens?
Yes. TransformerLens 4.0 removed the HookedTransformer stack. Use TransformerBridge.boot_transformers instead, and call enable_compatibility_mode() to reproduce the old weight processing.



