发现语言模型的输出有内在非随机性,且不同架构表现各异。
The Randomness Floor: Measuring Intrinsic Non-Randomness in Language Model Token Distributions
- 用熵偏差衡量模型输出与均匀分布的差异。
- 变压器模型在无意义提示下仍有约0.30的熵偏差,表明非随机性源于模型权重。
- Mamba2模型表现出更高熵偏差和温度敏感性,适合研究架构差异。
语言模型不可能完全随机。本文提出熵偏差(ED),即模型词元分布与均匀分布之间的归一化KL散度,系统测量了31,200次生成结果,涵盖7种模型、2种架构(Transformer与状态空间)、9类提示、3种温度和5种语言。在语义中立提示(空字符串、随机字符、无意义音节)下,Transformer模型仍保持约0.30的ED,意味着语义提示下观察到的88-93%非随机性源自模型权重本身。三个Transformer家族(Gemma、Llama、Qwen)虽训练数据与词表不同,却趋近相同的ED值。状态空间模型Mamba2展现出完全不同特征:ED为两倍,序列内方差低三倍,且对温度极度敏感(相关系数r = -0.78),而Transformer几乎不受影响(r < 0.05)。跨语言实验显示Qwen-32B在英语、日语、中文、波兰语、阿拉伯语间保持稳定梯度,与词元丰度无关,即使共享相同词器子集的语言间也持续存在。这些发现确立了预训练语言模型随机性的结构下限,刻画了其在不同架构间的差异,并证明语言本身会独立于分词方式调节该下限。
原文摘要 · Abstract (English)
Language models cannot be random. This paper introduces Entropic Deviation (ED), the normalised KL divergence between a model's token distribution and the uniform distribution, and measures it systematically across 31,200 generations spanning seven models, two architectures (transformer and state space), nine prompt categories, three temperatures, and five languages. Under semantically neutral prompts (empty strings, random characters, nonsense syllables) transformers still exhibit ED of approximately 0.30, meaning that 88-93% of the non-randomness observed under semantic prompts is intrinsic to the learned weights rather than induced by context. Three transformer families (Gemma, Llama, Qwen) converge on nearly identical ED values despite different training data and vocabularies. A state space model (Mamba2) reveals a qualitatively different regime: twice the ED, three times lower within-sequence variance, and massive sensitivity to temperature (r = -0.78) where transformers are nearly immune (r < 0.05). Cross-lingual experiments with Qwen-32B show a stable gradient across five languages (English, Japanese, Chinese, Polish, Arabic) that does not correlate with token fertility and persists when two languages sharing an identical tokeniser subset are compared. These findings establish a structural lower bound on randomness in pretrained language models, characterise how this bound differs across architectures, and demonstrate that language itself modulates the bound independently of tokenisation.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。