Skip to main content
QUICK REVIEW

[论文解读] Encoding word order in complex embeddings

Benyou Wang, Donghao Zhao|arXiv (Cornell University)|Dec 27, 2019
Topic Modeling参考文献 39被引用 56
一句话总结

本论文引入连续的复值词嵌入,建模全局词位置信息及其顺序关系,将 CNN/RNN/Transformer 扩展为复值形式,并展示在文本分类、机器翻译和语言建模方面的改进。

ABSTRACT

Sequential word order is important when processing text. Currently, neural networks (NNs) address this by modeling word position using position embeddings. The problem is that position embeddings capture the position of individual words, but not the ordered relationship (e.g., adjacency or precedence) between individual word positions. We present a novel and principled solution for modeling both the global absolute positions of words and their order relationships. Our solution generalizes word embeddings, previously defined as independent vectors, to continuous word functions over a variable (position). The benefit of continuous functions over variable positions is that word representations shift smoothly with increasing positions. Hence, word representations in different positions can correlate with each other in a continuous function. The general solution of these functions is extended to complex-valued domain due to richer representations. We extend CNN, RNN and Transformer NNs to complex-valued versions to incorporate our complex embedding (we make all code available). Experiments on text classification, machine translation and language modeling show gains over both classical word embeddings and position-enriched word embeddings. To our knowledge, this is the first work in NLP to link imaginary numbers in complex-valued representations to concrete meanings (i.e., word order).

研究动机与目标

  • 动机:在文本中同时建模全局绝对位置和内部序列关系的必要性。
  • 提出一种新颖的嵌入,使词表示作为随位置连续变化的函数。
  • 将嵌入扩展到复数域,以捕捉更丰富的依赖于位置的结构。
  • 将复杂序(order)嵌入整合到 CNN、RNN 和 Transformer 中,并在多个任务上进行评估。

提出的方法

  • 将每个词嵌入从向量扩展为关于位置索引的函数,实现在位置相关的表示。
  • 定义复值嵌入 f(j,pos) = g_we(j) ⊙ g_pe(j,pos),其中 g_pe 使用复指数来编码位置。
  • 强加诸如与位置无关的偏移变换和有界性等性质;证明唯一的有界、可线性观测的解 g(pos) = z2 z1^pos,且 |z1| ≤ 1。
  • 将每个词的复嵌入参数化为 f(j,pos) = r_j,d e^{i(ω_j,d pos + θ_j,d)},在 D 个维度上(幅度、频率、相位)。
  • 证明 Vaswani 等人的位置编码是该方法的降级特例。

实验结果

研究问题

  • RQ1一个在位置上的连续复值嵌入是否能够同时捕捉词的绝对位置和相对顺序?
  • RQ2与原生及传统位置增强嵌入相比,复杂顺序嵌入是否在不同的神经网络架构(CNN、RNN、Transformer)上提升性能?
  • RQ3所提出的嵌入在文本分类、机器翻译和语言建模任务中是否有效?

主要发现

  • 复杂顺序嵌入在文本分类、机器翻译和语言模型任务中,优于原生及其他带位置信息的嵌入。
  • Transformer 变体显著受益于带顺序感的复嵌入,性能具有竞争力或更优,同时保持类似的效率。
  • 该方法为虚部作为词序信息提供了具体的解释,将复值表示与语言结构联系起来。
  • 消融研究表明,某些设计选择(如初始相位、共享方案)会影响性能和参数效率。

更好的研究,从现在开始

从论文设计到论文写作,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。