Skip to main content
QUICK REVIEW

[论文解读] Probing BERT in Hyperbolic Spaces

Boli Chen, Yao Fu|arXiv (Cornell University)|Apr 8, 2021
Topic ModelingComputer Science参考文献 20被引用 19
一句话总结

本文提出一种庞加莱探针,用于在双曲空间中分析 BERT 的上下文嵌入,利用庞加莱球模型天然的树状几何结构,更好地捕捉语言的层次结构。与欧几里得探针相比,该方法在恢复句法依存树和情感层次结构方面表现更优,尤其在深层树和长句中优势更明显,表明 BERT 的句法表征可能本质上更倾向于非欧几里得几何。

ABSTRACT

Recently, a variety of probing tasks are proposed to discover linguistic properties learned in contextualized word embeddings. Many of these works implicitly assume these embeddings lay in certain metric spaces, typically the Euclidean space. This work considers a family of geometrically special spaces, the hyperbolic spaces, that exhibit better inductive biases for hierarchical structures and may better reveal linguistic hierarchies encoded in contextualized representations. We introduce a Poincare probe, a structural probe projecting these embeddings into a Poincare subspace with explicitly defined hierarchies. We focus on two probing objectives: (a) dependency trees where the hierarchy is defined as head-dependent structures; (b) lexical sentiments where the hierarchy is defined as the polarity of words (positivity and negativity). We argue that a key desideratum of a probe is its sensitivity to the existence of linguistic structures. We apply our probes on BERT, a typical contextualized embedding model. In a syntactic subspace, our probe better recovers tree structures than Euclidean probes, revealing the possibility that the geometry of BERT syntax may not necessarily be Euclidean. In a sentiment subspace, we reveal two possible meta-embeddings for positive and negative sentiments and show how lexically-controlled contextualization would change the geometric localization of embeddings. We demonstrate the findings with our Poincare probe via extensive experiments and visualization. Our results can be reproduced at https://github.com/FranxYao/PoincareProbe.

研究动机与目标

  • 探究 BERT 的句法和情感表征是否在双曲空间中比在欧几里得空间中更易建模。
  • 开发一种庞加莱探针,利用双曲空间的几何结构显式编码层次结构。
  • 评估该探针对语言层次结构的敏感性是否高于标准欧几里得探针。
  • 探索情感嵌入在几何空间中的定位方式,以及词法控制上下文化的影响。

提出的方法

  • 庞加莱探针将 BERT 的上下文词嵌入投影到庞加莱球中,该模型是具有恒定负曲率的双曲空间。
  • 探针使用为广义庞加莱球模型定义的双曲运算(加法、矩阵乘法、指数映射和对数映射),以保持几何一致性。
  • 在句法探针中,层次结构由依存树深度定义,越靠近原点的节点代表越高的句法层级。
  • 在情感探针中,将两个元嵌入([POS] 和 [NEG])置于原点,词的情感极性决定其与原点的径向距离。
  • 探针通过双曲空间中的几何关系来训练预测句法结构或情感极性。
  • 使用 UUAS(无标签 Ullmann 准确率得分)和 DSpr(依存结构精确率)在句法和情感任务上评估该方法。

实验结果

研究问题

  • RQ1双曲几何是否比欧几里得几何更能捕捉 BERT 句法表征的层次结构?
  • RQ2庞加莱探针是否能比欧几里得探针更准确地恢复依存树,尤其是在深层或更长的句法结构中?
  • RQ3BERT 中的情感嵌入在双曲空间中如何几何定位?词法控制的上下文化在其中起什么作用?
  • RQ4庞加莱探针是否对语言结构敏感,而自身并非强解析器?

主要发现

  • 庞加莱探针在 BERTbase10 句法探针任务中达到 84.5 的 UUAS,显著优于最佳欧几里得探针(84.0,带非线性),表明其对句法结构的敏感性更高。
  • 对于深层树和长句,庞加莱探针的解析得分显著高于欧几里得探针,表明 BERT 的句法几何可能并非欧几里得。
  • 在情感探针中,庞加莱探针揭示了正向和负向情感的两个独立元嵌入,情感极性更强的词更靠近其对应的元嵌入。
  • 探针在随机基线嵌入上的得分较低(UUAS ~19.9),确认其并非强大解析器,而仅对内在语言结构敏感。
  • 不同曲率的实验表明,曲率为 -0.5 和 -1.0 时,距离任务的 DSpr(0.70)和 UUAS(40.5)达到最高,表明该曲率对句法层次结构具有最佳几何匹配。
  • 可视化结果证实,由于双曲空间的体积随半径呈指数增长,而欧几里得空间为多项式增长,双曲空间更适宜容纳树状结构。

阅读本论文

在 Nubint 阅读器中打开原文,边读边就任意段落提问。

在 Nubint 中阅读本论文

本解读由 AI 根据论文原文生成,引用前请核对原文。