Masked Marginal Scoring
Also known as: masked marginals, zero-shot scoring, log-likelihood scoring
ESM-2's zero-shot method for scoring variant effects. It masks each position and measures how surprising the mutant amino acid is relative to wild-type.
Source: Meier J et al. 'Language models enable zero-shot prediction of the effects of mutations on protein function.' NeurIPS 2021. https://doi.org/10.1101/2021.07.09.450648
Primary reference ↗Masked marginal scoring is the method used to extract variant effect predictions from protein language models like ESM-2. It requires no additional training or fine-tuning — only the pretrained model and the protein sequence.
How It Works
For each position in the sequence:
- The amino acid at that position is replaced with a
[MASK]token - The model predicts a probability distribution over all 20 amino acids at that position, given the surrounding sequence context
- The mutation score is the difference in log-probabilities:
score = log P(mutant | context) − log P(wild-type | context)
A negative score means the mutant amino acid is evolutionarily unexpected at that position. A strongly negative score predicts functional damage.
Why “Zero-Shot”
The model is never shown experimental fitness data for the protein being scored. It relies entirely on patterns learned during pretraining on 250 million sequences. This is what makes it useful for novel proteins with no prior DMS data.
Relationship to Evolutionary Conservation
A position with strong purifying selection across evolution will have a narrow, peaked probability distribution — most amino acids are predicted as highly unlikely. ESM-2 learned this pattern from 250M sequences, so masked marginal scores correlate with evolutionary conservation and functional importance.
Limitations
- Zero-shot scoring doesn’t distinguish between types of functional impairment (stability vs. catalysis)
- Heavily conserved positions score well; evolvable positions (like substrate recognition sites) score poorly even when mutations are functionally interesting
- Protein context matters: distant epistatic interactions aren’t fully captured