arXiv:2502.10201cs.CLcs.AI2025-02ACL被引 4

LLM预测中的热门词是上下文驱动的高频词,非干扰性枢纽。

Prediction hubs are context-informed frequent tokens in LLMs

  • 通过上下文与解嵌向量比较生成下一词预测,形成非负面枢纽
  • 高频词在候选词中频繁出现,导致显著的枢纽现象
  • 使用欧氏或余弦距离时需警惕干扰性枢纽,建议采用缓解策略

当对高维数据使用标准距离度量时,枢纽性(hubness)——即少数点成为大量其他点近邻的现象——常出现并负面影响基于距离的分析。由于自回归大语言模型(LLMs)运行于高维表示空间,我们探究其是否也受枢纽性影响。首先证明,LLMs执行的大规模表示比较操作(即上下文与解嵌向量之间的比较,用于确定续写概率),并不表现出通常引发干扰性枢纽的距离集中现象。然而,实证表明该比较仍导致高度枢纽性,但这些枢纽并非扰动,而是由上下文调节的高频词构成,它们常出现在下一词预测的候选池中。当使用其他距离度量比较LLM表示时,缺乏理论保障,且确实出现干扰性枢纽。主要结论为:枢纽性虽在高维空间普遍存在,但在用于下一词预测时并非负面特性,无需消除;而使用欧氏或余弦距离比较模型表示时,存在高风险产生干扰性枢纽,从业者应采取缓解措施。

原文摘要 · Abstract (English)

Hubness, the tendency for a few points to be among the nearest neighbours of a disproportionate number of other points, commonly arises when applying standard distance measures to high-dimensional data, often negatively impacting distance-based analysis. As autoregressive large language models (LLMs) operate on high-dimensional representations, we ask whether they are also affected by hubness. We first prove that the only large-scale representation comparison operation performed by LLMs, namely that between context and unembedding vectors to determine continuation probabilities, is not characterized by the concentration of distances phenomenon that typically causes the appearance of nuisance hubness. We then empirically show that this comparison still leads to a high degree of hubness, but the hubs in this case do not constitute a disturbance. They are rather the result of context-modulated frequent tokens often appearing in the pool of likely candidates for next token prediction. However, when other distances are used to compare LLM representations, we do not have the same theoretical guarantees, and, indeed, we see nuisance hubs appear. There are two main takeaways. First, hubness, while omnipresent in high-dimensional spaces, is not a negative property that needs to be mitigated when LLMs are being used for next token prediction. Second, when comparing representations from LLMs using Euclidean or cosine distance, there is a high risk of nuisance hubs and practitioners should use mitigation techniques if relevant.

大模型枢纽性语言模型表示学习

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。