Manuscript Offprint

arXiv:2609.04793

ProtLingo: Efficient Protein Language Modeling via Conditional Memory and Expert Routing

Mingrui Li, Sixian Shen, Minzhang Li, Ruiyi Zhang, Kexin Zhang, Jiakai Zhang, Jingyi Yu

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Proteins perform diverse cellular functions, and even single amino-acid substitutions can alter stability, activity, or molecular interactions. Protein language models (PLMs) provide a scalable approach for modeling such sequence-function relationships from unlabeled sequences, but increasing the size of dense Transformer backbones often brings substantial computational cost without consistently improving mutation-sensitive prediction. We introduce ProtLingo, an efficient PLM framework that augments a pretrained single-sequence backbone with conditional local memory and sparse expert routing. ProtLingo maps contextual residue representations into route-specific discrete codes, composes centered local windows into latent NN-gram addresses, and retrieves reusable residual signals associated with recurring local sequence contexts. In parallel, selected feed-forward blocks are upcycled into sparse Mixture-of-Experts layers with shared and routed experts, enabling residue-dependent computation while activating only a subset of parameters. Experiments on protein fitness prediction, FLIP benchmarks, and supervised contact prediction show that ProtLingo achieves competitive performance with a 150M-scale backbone, including strong parameter efficiency on mutation-effect prediction and preserved long-range structural representations.

1 Introduction

Proteins perform most cellular functions, and even a single amino-acid substitution can alter their stability, activity, or interactions. Predicting these sequence-function relationships is therefore crucial for protein engineering, variant interpretation, and therapeutic discovery, yet experiments cover only a tiny fraction of the vast sequence space. Protein language models (PLMs) offer a scalable alternative by learning transferable representations from large collections of unlabeled sequences, supporting tasks from structure prediction to fitness estimation (Rives et al. 2021; Jumper et al. 2021; Notin et al. 2023). However, scaling dense Transformer backbones brings rapidly increasing computational costs without consistently improving downstream performance (Akiyama et al. 2026). This limitation motivates architectures that use model capacity more effectively and incorporate inductive biases tailored to protein sequences (Cheng et al. 2024).

Following this direction, prior work has enriched PLMs with evolutionary information from multiple sequence alignments (Rao et al. 2021; Eddy 2011), geometric information

Figure

Figure 1: Performance-parameter comparison of PLMs. Bubble size indicates total model parameters, while the x-axis reports active parameters in millions on a log scale and the y-axis reports Spearman. ProtLingo achieves competitive DMS prediction performance with only 153M active parameters, matching or exceeding larger dense baselines such as ESM2-150M, ProtBert, CARP, and RITA XL while using fewer active parameters than ESM2-650M and ESM-1b.

from protein structures (Su et al. 2023), or related sequences retrieved from external databases (Notin et al. 2022). Although these approaches improve biological grounding, they depend on homologous sequences, structural inputs, or external resources whose availability and quality vary across proteins. They also leave open a complementary question: how can a single-sequence PLM better exploit the local context already present within its input? This question is especially important for mutation-sensitive prediction, because the effect of a substitution often depends on nearby conserved residues, functional sites, and local residue environments (Ng and Henikoff 2003; Bogan and Thorn 1998; Porter, Bartlett, and Thornton 2004). Standard dense PLMs can model such dependencies implicitly, but provide no explicit mechanism for reusing recurring local contexts or adapting computation across residues. An effective architecture should therefore preserve broad pretrained knowledge while introducing local-context memory and residue-dependent computation.

We present ProtLingo, an efficient protein language modeling framework that augments a pretrained dense backbone

∗^{*}Equal contribution.

with conditional memory and expert routing. Its conditional memory maps contextual residue representations into route-specific discrete codes and composes codes from centered local windows into latent N-gram addresses. These addresses retrieve reusable residual signals associated with recurring local sequence contexts. The retrieved memories are compressed and locally refined before being injected into selected backbone layers, allowing ProtLingo to adapt residue representations without overwriting the general knowledge encoded by pretraining. ProtLingo further upcycles selected dense feed-forward blocks into sparse Mixture-of-Experts layers containing a shared expert and multiple routed experts. A top-1 router assigns each residue to a context-dependent expert while activating only a subset of the available parameters. Both the memory pathway and the routed experts are initialized to preserve the pretrained model function, enabling stable continuation training and gradual specialization. Together, conditional memory and expert routing allow ProtLingo to reuse recurring local contexts and allocate computation adaptively across residue environments, improving mutation-sensitive sequence modeling without relying on substantially larger dense backbones.

We evaluate ProtLingo on protein fitness prediction, clinical variant classification, FLIP benchmarks and supervised contact prediction. Across these tasks, ProtLingo achieves competitive performance with a 150M-scale backbone, demonstrating that conditional memory and expert routing can improve sequence modeling without substantially enlarging the dense model. On supervised contact prediction, ProtLingo retains precision comparable to the ESM2-150M backbone, suggesting that continuation training preserves structure-relevant long-range residue representations. Ablation studies further examine centered latent N-gram memory and MoE upcycling. The results show that local-context memory and routed experts provide complementary gains. We will release the source code and model checkpoints upon publication.

References (34)