arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1712.02047cs.CLcs.AI
收藏

基于距离的自注意网络在自然语言推理中的应用

Distance-based Self-Attention Network for Natural Language Inference

Seoul National University(首尔大学)

Jinbae Im, Sungzoon Cho

摘要:

注意力机制已经被用作辅助手段来帮助RNN或CNN。然而,Transformer(Vaswani等人,2017年)最近记录了机器翻译的最新性能,仅使用注意力就大大减少了训练时间。受Transformer的启发,定向自注意网络(Shen et al.,2017年),一个完全基于注意力的句子编码器,被提出。通过使用句子中的前向和后向信息,它在各种数据下都表现出良好的性能。但在他们的研究中,根本没有考虑单词之间的距离,这是学习局部依赖以帮助理解输入文本上下文的重要特征。我们提出了基于距离的自注意力网络,它通过使用一个简单的距离掩码来考虑词的距离,以便在不失去注意力固有的全局依赖建模能力的情况下对局部依赖进行建模。我们的模型在NLI数据上表现出了良好的性能,并记录了SNLI数据的最新结果。此外,我们还证明了我们的模型在长句或文档中具有优势。

英文摘要:

Attention mechanism has been used as an ancillary means to help RNN or CNN. However, the Transformer (Vaswani et al., 2017) recently recorded the state-of-the-art performance in machine translation with a dramatic reduction in training time by solely using attention. Motivated by the Transformer, Directional Self Attention Network (Shen et al., 2017), a fully attention-based sentence encoder, was proposed. It showed good performance with various data by using forward and backward directional information in a sentence. But in their study, not considered at all was the distance between words, an important feature when learning the local dependency to help understand the context of input text. We propose Distance-based Self-Attention Network, which considers the word distance by using a simple distance mask in order to model the local dependency without losing the ability of modeling global dependency which attention has inherent. Our model shows good performance with NLI data, and it records the new state-of-the-art result with SNLI data. Additionally, we show that our model has a strength in long sentences or documents.

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

↑