Dialogue Manager

Last updated: Mar 26th, 2018

Introduction

The dialogue manager contains the core of the system. The developer designs the conversation flow for each intent. This design follows a graph data structure, which is represented by the Cuneiform programming language. The Cuneiform script is interpreted by the interpreter. The script contains code with custom syntax for a programming language specifically designed for dialogue management.

Dialogue Manager architecture

Shown above is the architecture for the Dialogue Manager component of Cuneiform. This component contains the following subcomponents.

Dialogue Manager Architecture

Development Environment

The development environment contains the visual elements which enable the developer to program conversations. The visually developed conversations get converted into a script, which is then executed by the interpreter.

While the application is being developed, this process is continuously repeated as the developer keeps designing and testing the application.

Script

This component of the dialogue manager contains the application written in the Cuneiform programming language. Each intent of the application is represented by a single script.

When developers design the application using the development environment, the visual components is continuously translated into the scripting language.

The script is also the point of communication between the dialogue manager and the classifier. Once the intent has been identified by the classifier, it communicates with the script respective to the identified intent, while providing the script with relevant information. This information is passed on to the interpreter, which executes the script, taking into account the information provided, and then passes the output back to the classifier.

Interpreter

The task of the interpreter is to scan the script, and execute the set of instructions provided by it. Once completed, the result (output) is passed back to the user.

When scanning the script, the interpreter breaks down the components of it into tokens. This is handled by the lexer. These token are then organised into nodes, and a Tree data structure is created using the nodes. This part is handled by the parser. The created tree is finally traversed, executing the set of instructions provided in the script by the interpreter.

What's next?

The next section discusses the structure of the Cuneiform Script.