A neural attention model for sentence summarization

40

Transcript of A neural attention model for sentence summarization

Page 2: A neural attention model for sentence summarization
Page 3: A neural attention model for sentence summarization
Page 4: A neural attention model for sentence summarization
Page 5: A neural attention model for sentence summarization
Page 6: A neural attention model for sentence summarization
Page 7: A neural attention model for sentence summarization

x

M x1, ...,xM

y1, ...,yNy N

y (N < M)

argmax s(x,y)y 2

s

Page 8: A neural attention model for sentence summarization

argmax s(x,y)y 2

argmax s(x,x[m1,...,mN ])m 2 {1, ...,M}N

m 2 {1, ...,M}N , mi�1 < mi

argmax s(x,x[m1,...,mN ])

x[i,j,k]

Page 9: A neural attention model for sentence summarization

s(x,y) ⇡N�1X

i=0

g(yi+1,x,yc)

log p(y|x; ✓) ⇡N�1X

i=0

log p(yi+1|x,yc; ✓)

s(x,y) = log p(y|x; ✓)

Cyc

Page 10: A neural attention model for sentence summarization

Cs(x,y) ⇡N�1X

i=0

g(yi+1,x,yc)

log p(y|x; ✓) ⇡N�1X

i=0

log p(yi+1|x,yc; ✓)

s(x,y) = log p(y|x; ✓)

C

yc

Page 11: A neural attention model for sentence summarization

s(x,y) ⇡N�1X

i=0

g(yi+1,x,yc)

log p(y|x; ✓) ⇡N�1X

i=0

log p(yi+1|x,yc; ✓)

s(x,y) = log p(y|x; ✓)

Cyc

Page 12: A neural attention model for sentence summarization

x

y y

argmax s(x,y)y 2

argmax s(x,y)y 2

argmax s(x,x[m1,...,mN ])m 2 {1, ...,M}N

m 2 {1, ...,M}N , mi�1 < mi

argmax s(x,x[m1,...,mN ])

s(x,y) = log p(y|x; ✓) ⇡N�1X

i=0

log p(yi+1|x,yc; ✓)

Page 13: A neural attention model for sentence summarization
Page 14: A neural attention model for sentence summarization

log p(yi+1|x,yc; ✓)

Page 15: A neural attention model for sentence summarization
Page 16: A neural attention model for sentence summarization
Page 17: A neural attention model for sentence summarization
Page 18: A neural attention model for sentence summarization

p(yi+1|yc,x; ✓) / exp(Vh+Wenc(x,yc))

yc = [Eyi�C+1, ...,Eyi]h = tanh(Uyc)

✓ = (E,U,V,W)

Page 19: A neural attention model for sentence summarization

p(yi+1|yc,x; ✓) / exp(Vh+Wenc(x,yc))

yc = [Eyi�C+1, ...,Eyi]h = tanh(Uyc)

✓ = (E,U,V,W)

E =Eyi

Page 20: A neural attention model for sentence summarization

p(yi+1|yc,x; ✓) / exp(Vh+Wenc(x,yc))

yc = [Eyi�C+1, ...,Eyi]h = tanh(Uyc)

✓ = (E,U,V,W)

ycU h

tanhCV

H H

Page 21: A neural attention model for sentence summarization

p(yi+1|yc,x; ✓) / exp(Vh+Wenc(x,yc))

yc = [Eyi�C+1, ...,Eyi]h = tanh(Uyc)

✓ = (E,U,V,W)

H H

V

Vh +

+ V V

W enc(x,yc)

Page 22: A neural attention model for sentence summarization

p(yi+1|yc,x; ✓) / exp(Vh+Wenc(x,yc))

yc = [Eyi�C+1, ...,Eyi]h = tanh(Uyc)

✓ = (E,U,V,W)

Page 23: A neural attention model for sentence summarization

enc1(x,yc) = p

Tx

p = [1/M, ..., 1/M ] x = [Fx1, ...,FxM ]

Page 24: A neural attention model for sentence summarization

8i, l 2 {1, ..., L}, xlj = tanh(max{xl

2i�1, xl2i})

x

0 = [Fx1, ...,FxM ]

8j, enc2(x,yc)j = max x

Li,j

i

8i, l 2 {1, ..., L}, xli = Q

lx

l�1[1�Q,...,1+Q]

Page 25: A neural attention model for sentence summarization

enc3(x,yc) = p

Tx

p / exp(xPy

0

c)

y0

c = [Gyi�C+1, ...,Gyi]

x = [Fx1, ...,FxM ]

i+Q

q = i�Q

8i xi =X

xq/Q

Page 26: A neural attention model for sentence summarization
Page 27: A neural attention model for sentence summarization

(x(1),y(1)), ..., (x(J),y(J))

J

Page 28: A neural attention model for sentence summarization

y

⇤ = argmax

Xg(yi+1,x,yc)

y 2

N � 1

i = 0

y⇤

Page 29: A neural attention model for sentence summarization
Page 30: A neural attention model for sentence summarization
Page 31: A neural attention model for sentence summarization

s(y,x) =N�1X

i=0

↵T f(yi+1,x,yc)

Page 32: A neural attention model for sentence summarization

f(yi+1,x,yc)

↵ =< 1, 0, ..., 0 >

Page 33: A neural attention model for sentence summarization
Page 34: A neural attention model for sentence summarization
Page 35: A neural attention model for sentence summarization
Page 36: A neural attention model for sentence summarization
Page 37: A neural attention model for sentence summarization
Page 38: A neural attention model for sentence summarization
Page 39: A neural attention model for sentence summarization
Page 40: A neural attention model for sentence summarization