Extending memory networks for dialog modeling

We consider a dialog as a turn-based conversation between two participants (say A and B), where each turn of dialog involves an utterance by A followed by a response by B. We can then treat the production of a response at each turn as an NLU task where we must choose or generate an appropriate response for an incoming query based on the entire conversation history before the query.

We have already discussed how we can build a memory network-based QA model, which takes a question and some associated facts as input, and produces a response to the question by reasoning over the facts. To effectively model dialog as part of such a framework, the utterance at each turn of the conversation would be a question, and the entire dialog history would be the facts, based on which a memory network will produce the response:

For dialog to continue at the next turn, the previous utterance and response pair will have to be appended to the conversation history. The model will then be used to process the next utterance and produce an appropriate response for it, till the end of the conversation.

Before we dive into the code behind a memory network chatbot, we will introduce a few dialog datasets, and talk about one in particular—the bAbI dialog dataset by Facebook AI research.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset