Skip to main content
saes_pic

SAE Lens

PyPI License: MIT build Deploy Docs codecov

SAELens exists to help researchers:

  • Train sparse autoencoders.
  • Analyse sparse autoencoders / research mechanistic interpretability.
  • Generate insights which make it easier to create safe and aligned AI systems.

SAELens inference works with any PyTorch-based model, not just TransformerLens. While we provide deep integration with TransformerLens via HookedSAETransformer, SAEs can be used with Hugging Face Transformers, NNsight, or any other framework by extracting activations and passing them to the SAE's encode() and decode() methods.

Please refer to the documentation for information on how to:

  • Download and Analyse pre-trained sparse autoencoders.
  • Train your own sparse autoencoders.
  • Generate feature dashboards with the SAE-Vis Library.

SAE Lens is the result of many contributors working collectively to improve humanity's understanding of neural networks, many of whom are motivated by a desire to safeguard humanity from risks posed by artificial intelligence.

This library is maintained by Joseph Bloom, Curt Tigges, Anthony Duong and David Chanin.

Loading Pre-trained SAEs.

Pre-trained SAEs for various models can be imported via SAE Lens. See this page for a list of all SAEs.

Migrating to SAELens v6

The new v6 update is a major refactor to SAELens and changes the way training code is structured. Check out the migration guide for more details.

Tutorials

Join the Slack!

Feel free to join the Open Source Mechanistic Interpretability Slack for support!

Other SAE Projects

  • dictionary-learning: An SAE training library that focuses on having hackable code.
  • Sparsify: A lean SAE training library focused on TopK SAEs.
  • Overcomplete: SAE training library focused on vision models.
  • SAE-Vis: A library for visualizing SAE features, works with SAELens.
  • SAEBench: A suite of LLM SAE benchmarks, works with SAELens.

Citation

Please cite the package as follows:

@misc{bloom2024saetrainingcodebase,
   title = {SAELens},
   author = {Bloom, Joseph and Tigges, Curt and Duong, Anthony and Chanin, David},
   year = {2024},
   howpublished = {\url{https://github.com/decoderesearch/SAELens}},
}

Metadata

Release files for sae-lens 6.54.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for sae-lens 6.54.6
File Size Uploaded Provenance
sae_lens-6.54.6.tar.gz 291.3 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for sae-lens 6.54.6
File Interpreter ABI Platform
sae_lens-6.54.6-py3-none-any.whl Python 3 none any Details

Total release size: 612.6 kB

Release files / sae_lens-6.54.6.tar.gz

Download URL sae_lens-6.54.6.tar.gz
Size 291.3 kB
Tags Source
SHA-256 checksum
How to use checksums
9b5aa512518021c23d2a7b8eb6e884700c4548dc077b773c4c85f6b8966dd3ed
BLAKE2b-256 checksum
How to use checksums
5a47516d54cc2b64fd158a152d2c25bb5f243f92d8246ecc2a8e91510f278de5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 19, 2026.

Transparency log

Release files / sae_lens-6.54.6-py3-none-any.whl

Download URL sae_lens-6.54.6-py3-none-any.whl
Size 321.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d36afcbd7bdf34ed7cb4f96f97cc8ec6c8d3f07ec524025cc8e1f51f6b820f9a
BLAKE2b-256 checksum
How to use checksums
bd1b5a4f2a00e22031e89fc5aa9e908fae1f9112a29f4aafba44a26047ae07d2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 19, 2026.

Transparency log

Security for sae-lens 6.54.6

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for sae_lens-6.54.6.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 19, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

6.54.6 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page