dola-contrastive-decoding-formula
IN premise — summaries/2026/08/24/xu-2024-knowledge-conflicts-survey-s4-intra-memory-conflict.md
Created 2026-08-25T02:59:03+00:00
DoLa (Chuang et al., 2023) computes next-token probability as p(next) ∝ exp(log_p_mature − log_p_premature), contrasting log-probabilities between mature (late) and premature (early) transformer layers.
Summary
DoLa picks the next word by comparing what the model's deep layers say versus what its shallow layers say, then boosting whatever the deep layers prefer over the shallow ones. In practice this means the system can suppress generic, surface-level guesses and lean into the more contextually specific prediction, which improves output quality without retraining the model.