Toward mastering the cell language by learning to generate

Yixin Chen, Haiyang Bian, Lei Wei, Jinmeng Jia, Xiaomin Dong, Yuzhuo Li, Yubo Zhao, Xinze Wu, Chen Li, Erpai Luo, Chuxi Xiao, Minsheng Hao, Xuegong ZhangbioRxiv 2024

Abstract

Cells can be viewed as complex stories written by coordinated expression of genes. The success of AI large language models (LLMs) in mastering human language inspired the development of scMulan, a generative foundation model with 368 million parameters designed to generate cell transcriptomics with designated attributes. By defining a unified "c-sentence" to incorporate transcriptomics and meta-attributes, scMulan was pre-trained on the equivalence of 100 million human cells. Experiments demonstrate that scMulan can generate designated pseudo-transcriptomics, predict missing cell attributes, reconstruct unobserved cells along functional gradients, and identify driving regulators of cell fates.

Introduction

The rapid growth of single-cell RNA sequencing (scRNA-seq) data has spurred the development of specialized deep-learning tools for tasks such as cell type annotation and batch effect correction. However, these task-specific models often fail to capture a holistic understanding of biological mechanisms. While existing foundation models like scGPT or Geneformer adapt Transformer architectures to biology, they primarily rely on masked language modeling (predicting missing genes) and focus on microscopic interactions. These models often underutilize macroscopic metadata (e.g., organ source, donor age) and require extensive fine-tuning for new datasets.

scMulan addresses these gaps by adopting a generative paradigm that integrates microscopic and macroscopic information into a unified framework. This approach enables "zero-shot" applications, allowing the model to perform complex tasks on new data immediately after pre-training without task-specific fine-tuning.

Methods

The core innovation of scMulan is the c-sentence (cell sentence). Rather than treating a cell as a simple matrix of expression values, scMulan represents it as a sequence of "words," where each word is a tuple: (entity, value).

  • Entities encompass genes, metadata terms (e.g., "Heart," "T cell"), and specific task prompts (e.g., <cell type annotation>).
  • Values represent gene expression levels or placeholders for metadata.
The workflow of scMulan, showing how data is transformed into c-sentences for multitask pre-training.

scMulan utilizes a Transformer decoder-only architecture with several key adaptations for biological data. It features dual embedding layers for entities and values, and dual prediction heads: an Entity Prediction (EP) head for classification and a Value Prediction (VP) head for regression. Because gene order in a cell is arbitrary, the authors removed positional encodings and employed random shuffling during training to ensure robustness. Natural-language-based prompts allow the model to switch between tasks like annotation or generation in a zero-shot manner.

The model was pre-trained on hECA-10M, a curated subset of the human Ensemble Cell Atlas containing over 10 million high-quality cells from vital organs, covering 42,117 genes and rich metadata.

Results and Insights

scMulan demonstrates state-of-the-art performance across several benchmarks without the need for fine-tuning.

  • Zero-Shot Annotation: The model achieved a weighted F1 score of approximately 0.9 across novel datasets, consistently outperforming fine-tuned versions of previous foundation models.
  • Efficient Batch Integration: In COVID-19 immune dataset challenges, scMulan matched the performance of fine-tuned models in removing batch effects while superiorly preserving biological conservation (AvgBIO), all while bypassing the typical 10+ hours of fine-tuning.
  • High-Fidelity Generation: The model successfully generates realistic pseudo-cells based on organ or cell-type prompts. Q-Q plots confirm that the distribution of gene expression and sparsity in generated data closely mirrors real biological data.
UMAP visualization showing that scMulan's embeddings naturally cluster by cell type and organ.

By integrating macroscopic metadata directly into the "language," scMulan learns the environmental context of gene regulation, bridging the gap between cell-level and system-level biology. Moving from "filling in the blanks" to a generative paradigm allows the model to handle diverse tasks through simple prompting.

Conclusion

scMulan represents a significant step toward mastering the "cell language." While the model shows some sensitivity to out-of-distribution cell types and minor issues with generation sparsity, its zero-shot capabilities are a major advancement. Future work will focus on scaling to larger datasets and applying the model to simulate drug responses or perform in silico gene perturbations.

Summary updated

BibTeX
@misc{chen2024toward,
  author = {Yixin Chen and Haiyang Bian and Lei Wei and Jinmeng Jia and Xiaomin Dong and Yuzhuo Li and Yubo Zhao and Xinze Wu and Chen Li and Erpai Luo and Chuxi Xiao and Minsheng Hao and Xuegong Zhang},
  title = {{Toward mastering the cell language by learning to generate}},
  year = {2024},
  doi = {10.1101/2024.01.25.577152},
  howpublished = {bioRxiv},
}
Figure