Analysis updated 2026-07-25
Reproduce the materials science model study using the included experiment scripts and frozen prompt manifests.
Fit a Jacobian Lens on a language model to inspect how it internally represents materials concepts.
Run causal swap experiments to test whether changing internal model signals alters its outputs.
Run the bundled smoke-test demo to quickly verify the package installs and works on your machine.
| lamm-mit/substrates | aarav90-cpu/fetchit | adammartinez271828/x4-analysis | |
|---|---|---|---|
| Stars | 10 | 10 | 10 |
| Language | Python | Python | Python |
| Setup difficulty | hard | easy | easy |
| Complexity | 5/5 | 2/5 | 2/5 |
| Audience | researcher | developer | general |
Figures from each repo's GitHub metadata at analysis time.
Full experiments are compute-intensive and may require accepting a license to download the Gemma model, companion data must be fetched separately from Hugging Face.
This repository contains the research code and data for a project that studies how an open-weight language model, Gemma, represents materials science concepts internally. The researchers apply a technique called the Jacobian Lens to examine and influence what happens inside the model when it processes prompts about materials and their properties. The project covers three areas: readable concepts that the model encodes, relational state changes that show how representations shift, and causal interventions that test whether changing internal signals alters the model's output. The code is organized into a Python package with tools for fitting the lens, reading out model states, analyzing results, generating reports, and running causal swap experiments. It includes frozen prompt manifests that specify exactly which questions the model is asked, experiment scripts with fixed protocols for reproducing the study, and offline tests. The package also bundles the Jacobian Lens runtime so the installation is self-contained. The authors note that the package does not expose a model's private chain of thought, it measures model activations and behavior. Companion resources on Hugging Face hold the fitted lens checkpoints, extracted state vectors, and the full prompt corpus organized into 21 named configurations. These are kept separate from this GitHub release, which is source only. The prompt corpus is divided into development, evaluation, falsification, and exploratory groups, and the models used may require accepting a license before downloading. Installation requires Python 3.10 or newer and supports both virtual environments and Conda. A small demonstration command downloads GPT-2, fits a tiny lens on eight records, and runs basic mechanics examples as a smoke test. The full paper protocol is much more demanding: it fixes 1,000 fitting records, targets specific model layers, requires at least 50 evaluation items per distribution, and expects both model and dataset revisions to be pinned. The authors describe this as a compute-intensive workflow, and each fitted lens file requires a provenance sidecar recording its metadata to be valid for any paper-level claim. The README is detailed and includes installation instructions, workflow descriptions, and references to additional documentation files for prompt schemas and CLI conventions. The full README is longer than what was shown.
Research code for studying how a language model represents materials science concepts internally, using a technique called the Jacobian Lens to read and alter what happens inside the model when it processes materials prompts.
Mainly Python. The stack also includes Python, Gemma, GPT-2.
The license is not specified in the available README content, so check the repository for licensing details before use.
Setup difficulty is rated hard, with roughly 1h+ to a first successful run.
Mainly researcher.
This repo across BitVibe Labs
Verify against the repo before relying on details.