whatisgithub

What is ica-lens-paper?

liusida/ica-lens-paper — explained in plain English

Analysis updated 2026-05-18

26PythonAudience · researcherComplexity · 4/5Setup · hard

In one sentence

Research code for ICA Lens, a technique that uses Independent Component Analysis to find interpretable patterns inside AI language models.

Mindmap

mindmap
  root((ICA Lens))
    What it does
      Interpretability research
      Analyzes model activations
      Finds interpretable concepts
    Tech stack
      Python
      PyTorch
      uv package manager
    Use cases
      Reproduce paper results
      Explore ICA components
      Compare against SAEs
    Audience
      AI researchers
      ML interpretability students

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Explore which text patterns activate each ICA component in a browser-based explorer

USE CASE 2

Reproduce the ICA Lens paper's results using the provided numbered workflow scripts

USE CASE 3

Compare ICA against sparse autoencoders on interpretability benchmarks

USE CASE 4

Run a small-scale mini reproduction of the pipeline on a single GPU

What is it built with?

PythonPyTorchuv

How does it compare?

liusida/ica-lens-paperaevella/sky-pc-mcp-companionalicankiraz1/gemma-4-31b-mtp-vllm-server
Stars262626
LanguagePythonPythonPython
Setup difficultyhardmoderatehard
Complexity4/53/54/5
Audienceresearchervibe coderops devops

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · hard Time to first run · 1h+

Full-scale reproduction requires substantial GPU time and storage, precomputed databases up to 7GB download from Hugging Face.

The README does not specify license terms for reuse of the code.

So what is it?

This repository contains the code released alongside an academic paper called ICA Lens. The paper is about understanding what is happening inside large AI language models, a field called interpretability research. When an AI model processes text, it produces large tables of numbers at each internal layer, called activations. This work applies a mathematical technique called Independent Component Analysis (ICA) to find patterns in those numbers that correspond to interpretable concepts, such as topics, grammatical structures, or factual associations. ICA is a method that tries to separate a mixed signal into independent sources. In this context, it is applied to the activations of three publicly available AI models: GPT-2 (a smaller, older model), Gemma 2 2B, and Qwen 3.5 2B Base. The paper compares ICA against other approaches used in interpretability research, including sparse autoencoders (SAEs), which are currently the more popular tool for the same goal. The core claim is that ICA is fast, compact, and produces results comparable to or better than those alternatives on several benchmarks. The repository includes a browser-based visual explorer that lets researchers look at the ICA components: what text patterns activate each component most strongly, how components compare across layers, and how well they correlate with known features. There are two versions of the database: a small one (around 250 MB) for quick browsing, and a full one (around 7 GB) with richer information. Precomputed model files and databases are hosted on Hugging Face and downloaded on first use. For researchers who want to reproduce the paper's results, the repository provides numbered workflow scripts that walk through capturing activations, fitting ICA models, computing analysis metrics, building the explorer database, and running the benchmark comparisons. A mini reproduction mode runs the full pipeline on a small token sample and completes in a reasonable time on a single GPU. Full-scale reproduction requires substantially more GPU time and storage. Python 3.10 or later is required, along with PyTorch. The package manager used is called uv. A live demo of the explorer is available on Hugging Face Spaces.

Copy-paste prompts

Prompt 1
Walk me through running the mini reproduction mode of the ICA Lens pipeline
Prompt 2
Explain how Independent Component Analysis is applied to language model activations in this repo
Prompt 3
Help me set up the browser-based ICA component explorer from this repository
Prompt 4
What does this repo's comparison between ICA and sparse autoencoders show?

Frequently asked questions

What is ica-lens-paper?

Research code for ICA Lens, a technique that uses Independent Component Analysis to find interpretable patterns inside AI language models.

What language is ica-lens-paper written in?

Mainly Python. The stack also includes Python, PyTorch, uv.

What license does ica-lens-paper use?

The README does not specify license terms for reuse of the code.

How hard is ica-lens-paper to set up?

Setup difficulty is rated hard, with roughly 1h+ to a first successful run.

Who is ica-lens-paper for?

Mainly researcher.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.