What Does a Chromatin Foundation Model Know About a Petri Dish? Sparse Autoencoders Reveal In Vitro vs. In Vivo Context in EPIBERT

Nicole Ching, Ayushi MehrotraGenBio @ ICML 2026

TL;DR

Researchers used Sparse Autoencoders (SAEs) to "peek inside" EPIBERT, a genomics foundation model, discovering that it internally distinguishes between lab-grown cell lines (in vitro) and primary human tissues (in vivo). By identifying and manipulating these internal "context features," the authors demonstrate that we can mechanistically audit biological AI and even "steer" models to produce more accurate, tissue-specific predictions.

What Problem Does This Paper Address?

In the world of genomics, data is a bottleneck. Most high-quality epigenomic data comes from immortalized cell lines—cells grown in petri dishes that are easy to manipulate but biologically "weird" due to mutations and long-term culture. However, the goal of AI in medicine is to predict what happens in primary tissues (real human organs).

There is a fundamental tension here: if a foundation model like EPIBERT is trained mostly on "petri dish" data, does it realize that a liver cell line (HepG2) is different from actual liver tissue? If the model conflates these two contexts, its predictions for drug discovery or disease variants might be systematically biased. This paper seeks to move beyond treating these models as black boxes by finding the specific internal neurons (or "features") that represent this in vitro vs. in vivo distinction.

Methods

The authors employ several cutting-edge techniques from the field of mechanistic interpretability:

  1. EPIBERT: A BERT-style transformer model trained to predict chromatin accessibility (ATAC-seq) from DNA sequences.
  2. Sparse Autoencoders (SAEs): Transformers represent information in "dense" hidden layers where many concepts are tangled together. SAEs act like a prism, decomposing these dense activations into thousands of sparse, "monosemantic" features that are easier for humans to understand. The authors used a BatchTopK activation function to keep the features sparse and stable.
  3. Context Divergence Score (CDS): The authors introduced this new metric—essentially a contrastive t-statistic—to identify which SAE features fire significantly more in tissues versus cell lines.
  4. Causal Interventions: To prove these features actually matter, the authors performed causal ablation (turning specific features off to see if the model’s performance dropped) and context steering (nudging the model’s internal state toward the "tissue" direction to see if its predictions improved).
  5. Biological Annotation: They validated the "meaning" of these features using standard genomic tools (ChromHMM, HOMER, and GO:BP) to see if the features aligned with known biology.

Datasets

The study utilized ATAC-seq data from the ENCODE project, focusing on three matched pairs of "cell line vs. primary tissue" across different lineages:

  • Blood: K562 (cell line) vs. Hematopoietic Stem Cells (tissue).
  • Liver: HepG2 (cell line) vs. Liver Tissue.
  • Lymph: GM12878 (cell line) vs. Naive B Cells.

They used a held-out evaluation set of 200 genomic windows from chromosomes 8 and 9 to test their findings.

Key Insights and Ideas

  • Context Emerges with Depth: The model doesn't "know" about the petri dish immediately. Context-specific features are rare in early layers but grow 3.8-fold by the later layers. This suggests the model builds up a high-level "concept" of tissue context as it processes the data.
  • Features Capture Real Biology: These aren't just mathematical artifacts. The features identified as "liver-tissue-specific" were highly enriched for HNF4A, a master regulator of liver identity. Conversely, cell-line features were enriched for cancer-related and proliferative pathways (like AP-1 and E2F).
  • Asymmetry of the Petri Dish: There are significantly more features dedicated to representing cell lines than primary tissues. This likely reflects the "aberrant" nature of cell lines—they have extra regulatory "noise" from being cancerous or immortalized that the model has to account for.
  • The "Steering" Potential: By simply adding the "tissue" features and subtracting the "cell line" features during the model's forward pass, the researchers could close 11.2% of the prediction gap between the two contexts without any retraining.

Key Results

  • Feature Growth: Context-specific features increased from 57 in the early layers to 215 in the late layers.
  • Causal Impact: Ablating the top 25 context features had a massive effect on predictions (Cohen’s d = 1.79), proving these features are "load-bearing" for the model's logic.
  • Steering Success: Context steering was 4.5x more effective than random interventions at making cell-line predictions look like tissue predictions.
  • Lineage Specificity: The study found that there is no single "in vitro" button. The features that distinguish a liver cell line from liver tissue are different from those that distinguish blood cell lines from blood tissue.

Limitations and Future Work

  • Scale: The evaluation was limited to a relatively small set of genomic windows (200). Larger-scale audits are needed to find rarer features.
  • The "Remaining Gap": Steering only closed ~11% of the gap. The authors suggest the remaining 89% is likely due to complex genomic co-localization that a simple linear "nudge" can't fix.
  • Model Generalization: This study focused solely on EPIBERT. It remains to be seen if other popular models like Enformer or HyenaDNA encode context in the same depth-stratified way.
  • Future Path: The authors suggest that instead of full retraining, researchers could use these insights to perform "tissue-aware" fine-tuning, freezing early layers and only updating the context-heavy late layers.

Summary updated

BibTeX
@inproceedings{ching2026what,
  author = {Nicole Ching and Ayushi Mehrotra},
  title = {{What Does a Chromatin Foundation Model Know About a Petri Dish? Sparse Autoencoders Reveal In Vitro vs. In Vivo Context in EPIBERT}},
  booktitle = {GenBio @ ICML},
  year = {2026},
  url = {https://openreview.net/forum?id=JI9duJaATU},
}
Figure