Our new X account is live! Follow @wizwand_team for updates
WorkDL logo mark

Distance-based Self-Attention Network for Natural Language Inference

About

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.

Jinbae Im, Sungzoon Cho• 2017

Related benchmarks

TaskDatasetResultRank
Natural Language InferenceSNLI (test)
Accuracy86.3
681
Natural Language InferenceSNLI (train)--
154
Natural Language InferenceMultiNLI matched (test)
Accuracy74.1
65
Natural Language InferenceMultiNLI Mismatched
Accuracy72.9
60
Natural Language InferenceMultiNLI mismatched (test)
Accuracy72.9
56
Natural Language InferenceMultiNLI Matched
Accuracy74.1
49
Natural Language InferenceSNLI 1.0 (test)
Accuracy86.3
19
Natural Language InferenceSNLI 1.0 (train)
Accuracy89.6
9
Showing 8 of 8 rows

Other info

Code

Follow for update