Sequicity: Simplifying Task-oriented Dialogue Systems with Single Sequence-to-Sequence Architectures

简介

Sequicity: Simplifying Task-oriented Dialogue Systems with Single Sequence-to-Sequence Architectures, acl2018, pdf, pytorch code

本文是针对任务型对话提出的一种end2end的模型,名为Sequicity。该模型是一种seq2seq+Two Stage CopyNet的结构。

优点

  • 1.相对于pipeline的结构,复杂度低,参数少,训练时间短。
  • 2.针对oov的数据,还能保持不错的实体匹配率。
  • 3.可以同时完成task completion和response generation。

结构细节

Belief Span (bspan)

在Belief Span的术语中:一个slot可以是informable 或者requestable。所谓informable是指这个slot是作为知识库搜索时的限制条件,比如食物类型food_type,如果设定成chinese food,则搜索时返回的餐馆必须是中餐馆;所谓requestable是指这个slot可以被用户指定返回,比如用户需要知道餐馆的类型,slotaddress就会被置为true,后面的回答就必须包含餐馆的地址。

Sequicity

image

模型的输入(图中上层)是上一轮的bspan,上一轮的系统回答,本轮的用户输入;输出(图中下层)是更新的bspan和本轮系统回答。

输入先是过了一个统一的encoder,然后再分别过一个bspan的decoder,再拿这个decoder的结果再过response的decoder,生成最终的response。

上面的两步也正对应着两步的copy net:1.计算生成的词分布和输入的词分布,将二者叠加获得新的词分布,生成bspan decoder的输出;2.将生成的次分布和bsapn decoder的词分布叠加,生成response decoder的词分布。

实验

数据集: CamRest676 (Wen et al., 2017a) and KVRET (Eric and Manning, 2017b)

样例:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
{
"dial": [
{
"turn": 0,
"usr": {
"transcript": "I need to find an expensive restauant that's in the south section of the city.",
"slu": [
{
"act": "inform",
"slots": [
[
"pricerange",
"expensive"
]
]
},
{
"act": "inform",
"slots": [
[
"area",
"south"
]
]
}
]
},
"sys": {
"sent": "There are several restaurants in the south part of town that serve expensive food. Do you have a cuisine preference?",
"DA": [
"food"
]
}
},
{
"turn": 1,
"usr": {
"transcript": "No I don't care about the type of cuisine.",
"slu": [
{
"act": "inform",
"slots": [
[
"pricerange",
"expensive"
]
]
},
{
"act": "inform",
"slots": [
[
"food",
"dontcare"
]
]
},
{
"act": "inform",
"slots": [
[
"area",
"south"
]
]
}
]
},
"sys": {
"sent": "Chiquito Restaurant Bar is a Mexican restaurant located in the south part of town.",
"DA": []
}
},
{
"turn": 2,
"usr": {
"transcript": "What is their address?",
"slu": [
{
"act": "request",
"slots": [
[
"slot",
"address"
]
]
},
{
"act": "inform",
"slots": [
[
"pricerange",
"expensive"
]
]
},
{
"act": "inform",
"slots": [
[
"area",
"south"
]
]
},
{
"act": "inform",
"slots": [
[
"food",
"dontcare"
]
]
}
]
},
"sys": {
"sent": "There address is 2G Cambridge Leisure Park Cherry Hinton Road Cherry Hinton, it there anything else I can help you with?",
"DA": [
]
}
},
{
"turn": 3,
"usr": {
"transcript": "What is the food type they serve ?",
"slu": [
{
"act": "request",
"slots": [
[
"slot",
"food"
]
]
},
{
"act": "inform",
"slots": [
[
"area",
"south"
]
]
},
{
"act": "inform",
"slots": [
[
"food",
"dontcare"
]
]
},
{
"act": "inform",
"slots": [
[
"pricerange",
"expensive"
]
]
}
]
},
"sys": {
"sent": "They serve Mexican food .",
"DA": []
}
},
{
"turn": 4,
"usr": {
"transcript": "Nope, that's what I was looking for. Thanks a lot!",
"slu": [
{
"act": "inform",
"slots": [
[
"food",
"dontcare"
]
]
},
{
"act": "inform",
"slots": [
[
"pricerange",
"expensive"
]
]
},
{
"act": "inform",
"slots": [
[
"area",
"south"
]
]
}
]
},
"sys": {
"sent": "Thank you very much for using the Cambridge Restaurant System.",
"DA": []
}
}
],
"dialogue_id": 0,
"finished": true,
"goal": {
"constraints": [
[
"pricerange",
"expensive"
],
[
"area",
"south"
]
],
"request-slots": [
"address"
],
"text": "Task 11193: You are looking for an expensive restaurant and it should be in the south part of town. Make sure you get the address of the venue."
}
},

指标:

  • BLEU
  • Entity match rate evaluates task completion.
  • Success F1

结果:

指标超过各个baseline模型。