GPN#

GPN, also known as GPN-SS, is a single-sequence genomic language model trained on unaligned genomes. The maintained package supports both inference and training on prepared datasets.

Quick start#

from gpn import register_auto_classes
from transformers import AutoModelForMaskedLM

register_auto_classes("ss")

model = AutoModelForMaskedLM.from_pretrained("songlab/gpn-brassicales")

The GPN tutorial demonstrates tokenization, embeddings, masked nucleotide probabilities, and plots. File-backed inference is available through gpn ss {vep,logits,embedding}; see the command-line guide. The canonical prepared-data training recipe lives in recipes/gpn_training.

Published assets#

Brassicales model#

The GPN collection accompanies the PNAS paper.

Animal promoter model and TraitGym#

The TraitGym collection accompanies the causal regulatory variant benchmark.

Sorghum gene-expression fine-tune#

The sorghum model is a fine-tuned application of GPN, not a separate model family. It supports inference through the same register_auto_classes("ss") path. The sorghum collection accompanies the Nature Biotechnology paper.

Historical analyses#