Why Mean Pooling Works: Quantifying Second-Order Collapse in Text Embeddings
For researchers and practitioners using text embeddings, this work explains the empirical success of mean pooling and provides a metric to assess its robustness.
The paper investigates why mean pooling works well for text embeddings despite its potential to collapse second-order statistics. It proposes a metric to quantify this collapse and finds that modern text encoders, especially contrastive fine-tuned ones, are robust to it due to concentrated token embeddings, with robustness correlating with downstream performance.
For constructing text embeddings, mean pooling, which averages token embeddings, is the standard approach. This paper examines whether mean pooling actually works well in real models. First, we note that mean pooling can collapse information beyond the first-order statistics of the token embeddings, such as second-order statistics that capture their spatial structure, potentially mapping distinct token embedding distributions to similar text embeddings. Motivated by this concern, we propose a simple metric to quantify such a collapse induced by mean pooling. Then, using this metric, we empirically measure how often this collapse occurs in actual models and texts, and find that modern text encoders are robust to this collapse. In particular, contrastive fine-tuned text encoders tend to be less prone to the collapse than their pretrained backbone models. We also find that the robustness of these text encoders lies in the concentration of token embeddings within each text. In addition, we find that robustness to the collapse, as quantified by our proposed metric, correlates with downstream task performance. Overall, our findings offer a new perspective on why modern text encoders remain effective despite relying on seemingly coarse mean pooling.