End-to-End Neural Pipeline for Goal-oriented Dialogue System using GPT-2
1. 1
End-to-End Neural Pipeline
for Goal-oriented Dialogue System
using GPT-2
Donghoon Ham*, Jeong-Gwan Lee*, Youngsoo Jang, Kee-Eung Kim
Presented by Jeong-Gwan Lee
The 58th Annual Meeting of the
Association for Computational Linguistics
* : Equal Contribution
https://github.com/KAIST-AILab/NeuralPipeline_DSTC8
2. DSTC8: Multi-Domain Task-Completion
Task[1]
2
• Developing an end-to-end multi-domain dialogue
system
• MultiWOZ dataset[2] (Goal-Oriented Dialogue Corpus)
Domain : “restaurant”
[usr] Are there any restaurants that serve proper British food in town?
[sys] Oh yes quite a few. Which part of town will you be dining in?
[usr] West, if possible.
[sys] We have three: Graffiti, Saint John‘s Chop House, and Traveller.
[usr] Will you give me the phone number, address, and postcode for Graffiti?
[sys] The phone number is 01223277977. The address is Hotel Felix Whitehouse Lane Hunthindon Road
and post code is cb30lx. Want to book?
[usr] 6 people, please.
[sys] Booking is successful. Reference number is 00000081.
“ref” : “00000081”
“name” : “graffiti”
“phone” : “01223277977”
”postcode” : “cb30lx”
“address” : “Hotel Felix Whitehouse Lane Hunthindon Road”
“food” : “british”
“area” : “west”
“ref” : “00000084”
“name” : grafton hotel restaurant
“phone” : “01223241387”
“postcode” : “cb580a”
“address” : “Grafton Hotel 619 Newmarket Road Fen Ditton”
“food” : “british”
“area” : “east”
Dialogue id : “SNG0689”
Goal
Database (restaurant)
Dialogue turns
Blue : Informable slot Yello-Green : Requestable slot name Orange : Requestable slot value
Informable slots
“food” : “british”
“area” : “west”
Requestable slots
“phone”
“address”
“postcode”
Book slot “people” : 6
……
Domain : “restaurant”
[usr] Are there any restaurants that serve proper British food in town?
[sys] Oh yes quite a few. Which part of town will you be dining in?
[usr] West, if possible.
[sys] We have three: Graffiti, Saint John‘s Chop House, and Traveller.
[usr] Will you give me the phone number, address, and postcode for Graffiti?
[sys] The phone number is 01223277977. The address is Hotel Felix Whitehouse Lane Hunthindon Road
and post code is cb30lx. Want to book?
[usr] 6 people, please.
[sys] Booking is successful. Reference number is 00000081.
“ref” : “00000081”
“name” : “graffiti”
“phone” : “01223277977”
”postcode” : “cb30lx”
“address” : “Hotel Felix Whitehouse Lane Hunthindon Road”
“food” : “british”
“area” : “west”
“ref” : “00000084”
“name” : grafton hotel restaurant
“phone” : “01223241387”
“postcode” : “cb580a”
“address” : “Grafton Hotel 619 Newmarket Road Fen Ditton”
“food” : “british”
“area” : “east”
Dialogue id : “SNG0689”
Goal
Database (restaurant)
Dialogue turns
Blue : Informable slot Yello-Green : Requestable slot name Orange : Requestable slot value
Informable slots
“food” : “british”
“area” : “west”
Requestable slots
“phone”
“address”
“postcode”
Book slot “people” : 6
……
Domain : “restaurant”
[usr] Are there any restaurants that serve proper British food in town?
[sys] Oh yes quite a few. Which part of town will you be dining in?
[usr] West, if possible.
[sys] We have three: Graffiti, Saint John‘s Chop House, and Traveller.
[usr] Will you give me the phone number, address, and postcode for Graffiti?
[sys] The phone number is 01223277977. The address is Hotel Felix Whitehouse Lane Hunthindon Road
and post code is cb30lx. Want to book?
[usr] 6 people, please.
[sys] Booking is successful. Reference number is 00000081.
“ref” : “00000081”
“name” : “graffiti”
“phone” : “01223277977”
”postcode” : “cb30lx”
“address” : “Hotel Felix Whitehouse Lane Hunthindon Road”
“food” : “british”
“area” : “west”
“ref” : “00000084”
“name” : grafton hotel restaurant
“phone” : “01223241387”
“postcode” : “cb580a”
“address” : “Grafton Hotel 619 Newmarket Road Fen Ditton”
“food” : “british”
“area” : “east”
Dialogue id : “SNG0689”
Goal
Database (restaurant)
Dialogue turns
Blue : Informable slot Yello-Green : Requestable slot name Orange : Requestable slot value
Informable slots
“food” : “british”
“area” : “west”
Requestable slots
“phone”
“address”
“postcode”
Book slot “people” : 6
……
Domain : “restaurant”
[usr] Are there any restaurants that serve proper British food in town?
[sys] Oh yes quite a few. Which part of town will you be dining in?
[usr] West, if possible.
[sys] We have three: Graffiti, Saint John‘s Chop House, and Traveller.
[usr] Will you give me the phone number, address, and postcode for Graffiti?
[sys] The phone number is 01223277977. The address is Hotel Felix Whitehouse Lane Hunthindon Road
and post code is cb30lx. Want to book?
[usr] 6 people, please.
[sys] Booking is successful. Reference number is 00000081.
“ref” : “00000081”
“name” : “graffiti”
“phone” : “01223277977”
”postcode” : “cb30lx”
“address” : “Hotel Felix Whitehouse Lane Hunthindon Road”
“food” : “british”
“area” : “west”
“ref” : “00000084”
“name” : grafton hotel restaurant
“phone” : “01223241387”
“postcode” : “cb580a”
“address” : “Grafton Hotel 619 Newmarket Road Fen Ditton”
“food” : “british”
“area” : “east”
Dialogue id : “SNG0689”
Goal
Database (restaurant)
Dialogue turns
Blue : Informable slot Yello-Green : Requestable slot name Orange : Requestable slot value
Informable slots
“food” : “british”
“area” : “west”
Requestable slots
“phone”
“address”
“postcode”
Book slot “people” : 6
……
[1] DSTC8 Track1 Task1 competition webpage (https://competitions.codalab.org/competitions/20162)
[2] Budzianowski, Paweł, et al. "Multiwoz-a large-scale multi-domain wizard-of-oz dataset for task-oriented dialogue modelling." ar
Xiv preprint arXiv:1810.00278 (2018).
3. GPT-2 for Goal-Oriented Dialogue System
3
● Pipelined architecture
● Easy to interact with database or external module
● Hard to management (not guarantee an overall performance improvement)
● Monolithic architecture
● Efficient to train (enjoy end-to-end training to generate system responses)
● Hard to interact with database or external module
Our main idea : Integrate Pipelined Architecture into single GPT-2
<usr> I ’d like to find an
expensive place to dine that
specifically serves Italian food .
<sys> Okay . Would you like to
go to the centre or south part of
town ?
<usr> I would like the south
part of town please .
Dialogue history :
System action ResponseDialogue state
Word decoder layer
Transformer decoder blocks
Dialogue history Dialogue state System action Response
GPT-2
Response : frankie and bennys meets
your criteria. Would you like to book it ?
5. Input Representation : Delexicalization
5
Replace dialogue-dependent words such as phone, name, postcodes into
generic slot tokens as [DOMAIN_SLOTNAME]
6. Input Representation : Embedding
6
Dialogue Policy
● Follow the original work of GPT and TransferTransfo[3]
● Use last 15 turns as history (maximum sequence length=1024)
● Concatenate only user and system utterances with delimiter tokens <usr> and
<sys> for dialogue history
[3] Wolf, Thomas, Victor Sanh, Julien Chaumond, and Clement Delangue. "Transfertransfo: A transfer learning approach for neural network based
conversational agents." arXiv preprint arXiv:1901.08149 (2019).
7. End-to-End Neural Pipeline
Restaurant-
inform
name :
[restaurant-name]
System Action
<usr> I ’d like to find an expensive place to
dine that specifically serves Italian food .
<sys> Okay . Would you like to go to the
centre or south part of town ?
<usr> I would like the south part of town
please .
Dialogue history :
restaurant pricerange : expensive
food : italian
area : south
Dialogue state
Dialogue history
Dialogue state
Dialogue state
System action
System action
Response
Response
①
②
Response : frankie and bennys meets yo
ur criteria. Would you like to book it ?
Query results
Replacement
Response : [restaurant_name] meets your
criteria. Would you like to book it ?
④
⑤
Database
DB
Query
③ Candidates after Query
“name” : “frankie and bennys”
“pricerange” : “expensive”
“area” : “south”
“food” : “Italian”
…
Normal case
Word decoder layer
Transformer decoder blocks
GPT-2
8. End-to-End Neural Pipeline
Restaurant-
inform
name :
[restaurant-name]
System Action
Candidates after Query
“name” : “frankie and bennys”
“pricerange” : “expensive”
“area” : “south”
“food” : “Italian”
…
Database
<usr> I ’d like to find an expensive place to
dine that specifically serves Italian food .
<sys> Okay . Would you like to go to the
centre or south part of town ?
<usr> I would like the south part of town
please .
Dialogue history :
restaurant pricerange : expensive
food : italian
area : south
Dialogue state
System action ResponseDialogue state
Word decoder layer
Transformer decoder blocks
Dialogue history Dialogue state System action Response
GPT-2
If Empty Query
Results,
①
②
Response : frankie and bennys meets yo
ur criteria. Would you like to book it ?
Query results
Replacement
Response : [restaurant_name] meets your
criteria. Would you like to book it ?
④
⑤
Response : There’s no restaurant
meets your criteria
Candidates after Query
No Results
Restaurant
-nooffer
None-None
System Action
Empty Query Results case
Normal case
DB
Query
③
9. Successful Example
[usr] Hello I want to eat expensive european food in south of city .
Dialogue State : <restaurant> <food> european <pricerange> expensive <area> so
uth
DB Search : None
System Action : <restaurant-nooffer> <food> european <pricerange> expensive <a
rea> south
[sys] I'm sorry, but there are no expensive European restaurants in the south.
[usr] How about mexican food ?
Dialogue State : <restaurant> <food> mexican <pricerange> expensive <area> sou
th
DB search : {name : ’chiquito restaurant bar’, area : ‘south’, pricerange : ‘expensive’,
…’}
System Action : <restaurant-recommend> <name> [restaurant-name] <booking-inform> <no
ne> <none>
[sys] Chiquito Restaurant Bar is a good choice. Would you like me to book you a tabl
e?
[usr] Yes please, and give me their address .
Dialogue State : <restaurant> <food> mexican <pricerange> expensive <area> sou
th]
DB search : {name : ’chiquito restaurant bar’, area : ‘south’, pricerange : ‘expensive’,
…}
10. DSTC8 Challenge Evaluation Results[4]
10
• Automatic Evaluation
• Human Evaluation
Limitation of automatic evaluation
✔ Unnatural user simulator response
System utterance: I have several.What area of town would you like?
User utterance: I 'd like to be in the don't care please .
✔ Misunderstanding
User utterance: Does that have free parking ?
System utterance: Yes, they have free parking.
sys_act = self.nlu_model.parse(input, context)
print(sys_act)
<class 'dict'>: {'Hotel-Inform': [['Parking', 'none']]}
[4] ConvLab & Challenge Leaderboard (https://convlab.github.io)
11. MultiWOZ Benchmarks[3] Performance
11
Model Joint Acc. Slot Acc.
GLAD 35.57 95.44
GCE 36.27 98.42
SUMBT 46.64 96.44
TRADE 48.62 96.92
Ours + greedy 44.03 96.07
• Dialogue State Tracking • Dialogue-Context-to-Text Generation
Model Inform Success BLEU
MultiWOZ 71.29 60.96 18.80
TokenMoE 75.30 59.70 16.81
HDSA 82.90 68.90 23.60
Structured Fusion 82.70 72.10 16.34
LaRL 82.78 79.20 12.80
Ours + greedy 77.00 69.20 6.01
The modular performance is measured on two MultiWOZ benchmark tasks.
Our model is competitive to the state-of-the-art models although it is not designed for
those tasks.
[3] Budzianowski, Paweł, et al. "Multiwoz-a large-scale multi-domain wizard-of-oz dataset for task-oriented dialogue modelling." arXiv preprint arXiv:181
0.00278 (2018).
12. Conclusion
12
• We present an End-to-End Neural Pipeline that simulates
the core steps of the dialogue management pipeline and
enjoys end-to-end training using GPT-2.
• The generated response is interpretable and our model is easily
integrable with external systems.
• The experimental result with human evaluation
demonstrates that our model can provide very natural
human-level interaction for goal-oriented dialogues.
13. 13
End-to-End Neural Pipeline
for Goal-oriented Dialogue System
using GPT-2
Donghoon Ham*, Jeong-Gwan Lee*, Youngsoo Jang, Kee-Eung Kim
Presented by Jeong-Gwan Lee
* : Equal Contribution
The 58th Annual Meeting of the
Association for Computational Linguistics
https://github.com/KAIST-AILab/NeuralPipeline_DSTC8