2017.11.28
NAIST ⾃自然⾔言語処理理学研究室
D1 Masayoshi Kondo
論論⽂文紹介-‐‑‒ About Neural Summarization@2017
A Deep Architecture for Semantic Matching
With Multiple Positional Sentence Representations
AAAIʼ’16
Shengxian Wan, Yanyan Lan, Jiafeng Guo, Jun Xu, Liang Pang, and Xueqi Cheng
CAS Key Lab of Network Data Science and Technology
Institute of Computing Technology, Chinese Academy of Sciences, China
-‐‑‒-‐‑‒: Preliminaries
w1 w2 w3 wi wn w1 w2 w3 wi wm…… ……
Sentence-‐‑‒A / Length:n Sentence-‐‑‒B / Length:m
f (SA,SB;θ)マッチング関数
SCORE : 0,1{ }∈ R
【Train】
【Test】
((SA,SB), label)ペアデータから、loss関数を最⼩小にするようにパラメータθを学習.
学習済みモデルを⽤用いて、未知の(SA,SB)ペアに対してlabelを予測.
SCORE と Label を引数
とするloss関数を設定して、
最⼩小化.
-‐‑‒-‐‑‒: Preliminaries
【Dataset】
【Evaluation Metrics】
• [RTE] : Stanford Natural Language Inference Corpus (SNLI)
• [QA] : Yahoo ! Answers
• [QA] : Qatar Living Forum (http://www.qatarliving.com/forum)
• [Response Selection] : Ubuntu Corpus
• [Sentence Completion] : Reuters
• Accuracy
• P@1
• MRR(Mean Reciprocal Rank)
01: Introduction
Semantic Matching は、⾃自然⾔言語処理理の多くの応⽤用に必要不不可⽋欠なタスク
• Information Retrieval
• Question Answering
• Paraphrase Identification
例例)Question Answering :
質問q と 回答a が与えられた下で、マッチング関数は、2つの⽂文章
(質問⽂文、回答⽂文)がどれだけ適合しているかを評価する.
深層学習モデル (Deep Neural Networks) の発展
-‐‑‒ ⽂文章全体を単純なrepresentationとして表現
-‐‑‒ 2つのrepresentation間の類似度度を計算
DSSM[Huang et al, 13] / CDSMM[Shen et al, 14] / ARC-‐‑‒I[Hu et al, 14]
CNTN[Qiu and Huang, 15] / LSTM-‐‑‒RNN[Palangi et al, 15]
課題
複雑な⽂文章を1つの単純なベクトルに変換する際、重要な局所的情報が喪失.
02: Introduction
例例えば・・・
Q : Which teams won top three in the World Cup ?
A1 : Germany is the champion of the World Cup.
The top three of the European Cup are Spain,
Netherlands and Germany.
A2 :
このとき:
「top three」に注⽬目 :「A2の回答の⽅方が良良さそう」
「World Cup」に注⽬目 :「A1の回答の⽅方が良良さそう」
従来法(single sentence representation):上記の局所的な情報を扱えない.
-‐‑‒ 複雑な⽂文章を直接的にひとつのrepresentationに埋め込むため.
【課題】
03: Introduction
その他の⼿手法:taking multiple granularity
(ex: word, phrase, sentence level representation)
ARC-‐‑‒II[Hu et al., 13] / RAE[Socher et al., 14] / Deep-‐‑‒Match[Lu and Li, 14]
Bi-‐‑‒CNN-‐‑‒MI, MultiGranCNN[Yin and Schutze, 15]
複数のrepresentationを考慮することで、⽂文章の情報を記憶 → 精度度向上
Q : Which teams won top three in the World Cup ?
A1 : Germany is the champion of the World Cup.
The top three of the European Cup are Spain,
Netherlands and Germany.
A2 :
A3 : The top three attendees of the European Cup are
from Germany, France and Spain.
• A2の回答の⽅方が、A3の回答より良良さそう.
• 【理理由】:A2は、出場チームの top three を⽰示しているから.
課題
複数のrepresentationを⽤用いることで局所的な情報を取り扱うことは可能になった
⼀一⽅方で、⽂文章全体から単語やフレーズの真の意味を反映させることには限界がある.
multiple granularityのモデル : 上記の区別が⾏行行うことができない.
04: Introduction
Q : Which teams won top three in the World Cup ?
A1 : Germany is the champion of the World Cup.
The top three of the European Cup are Spain,
Netherlands and Germany.
A2 :
A3 : The top three attendees of the European Cup are
from Germany, France and Spain.
A2 と A3 の「top three」は、異異なる意味を⽰示している.
【A2】: about top three teams (出場チーム)
【A3】: about top three attendees (選出国)
Step 1: Positional Sentenve Representation
→ ⼀一般的なBi-‐‑‒LSTMの説明と提案法への導⼊入理理由の説明のため、割愛.
Step 2: Interactions Between Two Sentence
08: Our Approach
【Cosine】: Scalar
【Bilinear】: Scalar
【Tensor Layer】: Vector
s(u,v) =
uT
v
u ⋅ v
s(u,v) = uT
Mv+ b
s(u,v) = f uT
M[1:c]
v+Wuv
u
v
!
"
#
$
%
&+ b
'
(
))
*
+
,,
-‐‑‒ Similarity Score : S(u,v)
• ⼀一般的なメトリクス.
• 2つのベクトルの⾓角度度によって
類似性を測定.
• 異異なるベクトルサイズでも相互作⽤用
を計算可能.
• Cosineよりも表現⼒力力⾼高い.
(※ ||・||:L2-‐‑‒norm)
• Mi(i=1,…,c):i番⽬目のテンソル
スライス.関数fは、⾮非線形関数.
• 本研究では、f(z)=max(0, z).
09: Our Approach
Step 3: Interaction Aggregation
-‐‑‒ k-‐‑‒Max Pooling
-‐‑‒ MultiLayer Perception
• 2つの⽂文章に対して、最も強い相互作⽤用量量をk個抽出したい気持ち.
• [ Cosine, Biliner ] : a interactive matrix → a vector q
• [ Tensor Layer ] : a interactive tensor → vectors (for each slice)–
– concat → a vector q
パラメータk について
k=1の時:最⼤大の相互作⽤用量量の部分のみを考慮.
k=nの時:トップnの相互作⽤用量量の部分を考慮.→ 複数の重要部を考慮
r = f (Wrq + br )
s = f (Wsr + bs )
• ベクトルqは、k-‐‑‒max poolingの出⼒力力.
• 出⼒力力sは、マッチング関数のスコア.
• Full Connected Layer.
L SX,SY
+
,SY
−
( )= max 0,1− s(SX,SY
+
)+ s(SX,SY
−
)( )
10: Our Approach
Model Training
注) 論論⽂文では、「For different tasks, we need to utilize different loss functions to train
our model. For example, if the task is formalized as a ranking problem, ~∼ 」と記述され
ていて、本研究の実験において、提案⼿手法のloss関数に上記式を⽤用いたかは少し疑わしい.
Given a triplet-‐‑‒ SX,SY
+
,SY
−
( ) ,
SY
+
,SY
−
: SY
+ is ranked higher than SY
-‐‑‒, when matching with SX.
s(SX,SY
+
)
s(SX,SY
−
)
与えられる2つの⽂文章に対して、 の場合は⾼高くなった⽅方が良良く、⼀一⽅方で、
の場合は、低くなった⽅方が良良い.すなわち、「より似ている⽂文章ペア」
については「似ている」と学習し、「似ている度度合いが低い⽂文章ペア」については
「似ていない」と学習してほしい気持ちが、Loss関数に反映されている.
(※:loss関数は、Hinge Loss.)
19: Experiments
(2) Performance Comparison
SX
インターネットで無料料でロシア語学べる良良いサイトある?
SY
+ 無料料で⾔言語を学べるとも思えないけど、基本的な語彙くらいなら学べるか
もね.そういうことでは(インターネットは)素晴らしいと思う.
SY
-‐‑‒ Yahoo!のホームページに、無料料で提供されているゲームのリストが⾒見見れ
るよ.もしくは、www.iwin.comで無料料のゲームをダウンロードできる.
20: Experiments
(2) Performance Comparison
単語 “free” の意味について
SY
+ About free language resources
SY
-‐‑‒ About free games
提案法は、Multiple positionによって、”free” の違いを考慮できる.
21: Experiments
(2) Performance Comparison
[Hu et al, 2014]の研究で
は、MRRの検証は無かった.
QAタスクの場合に⽐比べて、
Deep Model⼿手法は、⼤大幅に
数値の改善が⾒見見られる.
提案法は、ベースラインに⽐比
べて、P@1で11.4%改善.
-‐‑‒ Sentence Completion