arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2601.04765cs.CLcs.AIcs.LGphysics.comp-ph
收藏

大型语言模型中句法与语义的差异编码

Differential syntactic and semantic encoding in LLMs

Catalan Institute of Research and Advanced Studies (ICREA) and Universitat Pompeu Fabra (UPF)(加泰罗尼亚研究与高级科学研究所(ICREA)和庞培法华大学(UPF))

Santiago Acevedo, Alessandro Laio, Marco Baroni

AI总结:

本研究通过平均共享句法结构或语义的句子隐藏表示向量,发现大型语言模型(以DeepSeek-V3为例)的内部层表示中句法和语义信息至少部分线性编码,且两者编码轮廓不同,可一定程度解耦。

摘要:

我们研究了句法和语义信息如何在大型语言模型(LLMs)的内部层表示中编码,重点关注非常大的DeepSeek-V3。我们发现,通过平均共享句法结构或语义的句子的隐藏表示向量,我们得到了能够捕获表示中相当大比例的句法和语义信息的向量。特别是,从句子向量中减去这些句法和语义“质心”会强烈影响它们与句法和语义匹配句子的相似性,这表明句法和语义至少部分地线性编码。我们还发现句法和语义的跨层编码轮廓不同,并且这两种信号可以在一定程度上解耦,这表明LLM表示中这两种语言信息的差异编码。

英文摘要:

We study how syntactic and semantic information is encoded in inner layer representations of Large Language Models (LLMs), focusing on the very large DeepSeek-V3. We find that, by averaging hidden-representation vectors of sentences sharing syntactic structure or meaning, we obtain vectors that capture a significant proportion of the syntactic and semantic information contained in the representations. In particular, subtracting these syntactic and semantic ``centroids'' from sentence vectors strongly affects their similarity with syntactically and semantically matched sentences, respectively, suggesting that syntax and semantics are, at least partially, linearly encoded. We also find that the cross-layer encoding profiles of syntax and semantics are different, and that the two signals can to some extent be decoupled, suggesting differential encoding of these two types of linguistic information in LLM representations.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑