ThomasHeap/random_sae

0

stars

1

commits

Python

primary language

Feb 3, 2025

updated

Browse cluster: Sparse Autoencoders and Mechanistic Interpretability

README

Introduction

This codebase is for "Sparse Autoencoders Can Interpret Randomly Initialized Transformers" and is heavily based on the following repositories:

Installation

Required packages:

pip install torch
pip install transformers
pip install datasets
pip install nnsight
pip install numpy
pip install pandas
pip install matplotlib
pip install seaborn
pip install scikit-learn
pip install orjson

Optional dependencies:

pip install bitsandbytes  # For 8-bit model loading

Code Organization

The codebase is organized into several components:

  • sae/: Core sparse autoencoder implementation
  • sae-auto-interp/: Automated interpretation tools and utilities
  • SAEBench/: Evaluation and benchmarking tools
  • experiments/: Scripts for running the training, evaluation and analysis experiments

All experiment scripts are prefixed with "run_" in the experiments folder, with different configurations for various model sizes and settings.

Contributors

ThomasHeap

1 commits

ThomasHeap/random_sae

0

stars

1

commits

Python

primary language

Feb 3, 2025

updated

Browse cluster: Sparse Autoencoders and Mechanistic Interpretability

README

Introduction

This codebase is for "Sparse Autoencoders Can Interpret Randomly Initialized Transformers" and is heavily based on the following repositories:

Installation

Required packages:

pip install torch
pip install transformers
pip install datasets
pip install nnsight
pip install numpy
pip install pandas
pip install matplotlib
pip install seaborn
pip install scikit-learn
pip install orjson

Optional dependencies:

pip install bitsandbytes  # For 8-bit model loading

Code Organization

The codebase is organized into several components:

  • sae/: Core sparse autoencoder implementation
  • sae-auto-interp/: Automated interpretation tools and utilities
  • SAEBench/: Evaluation and benchmarking tools
  • experiments/: Scripts for running the training, evaluation and analysis experiments

All experiment scripts are prefixed with "run_" in the experiments folder, with different configurations for various model sizes and settings.

Contributors

ThomasHeap

1 commits

Languages

Python

91.3%

Jupyter Notebook

7.1%

Shell

1.6%