Conversational Knowledge Teaching Agent that uses a Knowledge Base

When implementing a conversational educational teaching agent, user-intent understanding and dialog management in a dialog system are not sufficient to give users educational information. In this paper, we propose a conversational educational teaching agent that gives users some educational information or triggers interests on educational contents. The proposed system not only converses with a user but also answer questions that the user asked or asks some educational questions by integrating a dialog system with a knowledge base. We used the Wikipedia corpus to learn the weights between two entities and embedding of properties to calculate similarities for the selection of system questions and answers.


Introduction
Dialog is the most natural interaction between a mentor and mentee in the real world. Therefore, dialog-based intelligent tutoring systems (ITSs) have been widely studied to teach science (Jordan et al., 2013;Litman and Silliman, 2004;Graesser et al., 2004;VanLehn et al., 2002;, foreign language (Kyusong et al., 2014;Lee et al., 2010;Lee et al., 2011;Johnson et al., 2007), and programming language (Fossati et al., 2008;Lane and VanLehn, 2015) usually without intervention from a human teacher. However, previous dialog-based language learning systems mostly only play the role of a conversational partner using chatting like spoken dialog technology, and providing feedback such as grammatical error correction and suggesting better expressions.
However, in real situations, students usually ask many questions to indulge their curiosity and a tutor also asks questions to continue the conversation and maintain students' interest during the learning process. In science and programming language learning, mostly pre-designed scenarios and contents are necessary; these are usually handcrafted by human education experts. However, this process is expensive and time-consuming.
Our group is currently involved in a project called POSTECH Immersive English Study (POMY). The program allows users to exercise their visual, aural and tactile senses to receive a full immersion experience to develop into independent EFL learners and to increase their memory and concentration abilities to the greatest extent (Kyusong Lee et al., 2014). During field tests, we found that many advanced students asked questions that cannot be answered using only a dialog system 1 . Recently, knowledge base (KB) data such as freebase and DBpedia have become publicly available. Using the KB, knowledge base question answering (KB-QA) has been studied (Berant and Liang, 2014); it has advantages of very high precision because it exploits huge databases. Hence, we proposed a dialogbased intelligent tutoring system that uses a KB, as an extension of POMY, POMY Intelligent Tutoring System (POMY-ITS). The main advantage is that the human cost to manually construct educational contents is eliminated. Moreover, the system chooses its response after considering information importance, current discourse, relative weights between two entities, and property similarity. The additional functions of the POMY-ITS are that it: 1) Answers user's question such as factoid questions, word meaning; 2) Generates questions to continue the conversation and to interest the user; 3) Uses entities and properties in freebase to generate useful information that might interest a user, and presents it in natural language. To implement 1) the QA function, we used Parasempre (Berant and Liang, 2014) based KB-QA system as our QA system. However, in this paper, we focus only on 2) and 3) which are generating questions or informing by selecting appropriate entity and property in the KB; we do not present the detailed explanation or assess the accuracy of the QA system.

Intuition of the system
A user who asks about Bill Gates, may also be interested in Microsoft and Paul Allen, which are topics strongly related to Bill Gates. In the KB graph, the 'Bill Gates' entity is connected to many other entities. However, these connections present too much information, such as URLs of related websites, gender of Bill Gates, published books, music, and architecture. However, KB does not contain the entity importance or weighted relationship between entities and properties ( Figure 1). This information can be useful to POMY-ITS to enable it to decide what to ask or talk about. When a system and a user are talking about Bill Gates' wife's name, the user may also want to know when they got married or who Bill Gates' other family members are. Manual construction of the entity relationship or order of scenarios would be very expensive. Our system considers entity and property to decide automatically what to ask or to inform. To deploy the system, we used the Wikipedia corpus to learn property similarity, and weight between two entity pairs.

Method
The main role of the POMY-ITS is to give information that a user wants to know. The KB-QA technology will give the answer if the utterance is a 'wh' question, but often, a user does not know what to ask. Thus, the conversation must include initiative dialog. When the dialog between a tutor and a user stalls, the tutor should ask a relevant question to or give useful information related to the current context.

The Role of Dialog Management
First, the system should know whether a user utterance is a question, an answer, or has some other function (Algorithm 1). If the user utterance is a question, KB-QA will answer. If the utterance is an answer, the system will check whether or not the user utterance is correct. Otherwise, we used the example based dialog system which uses a similarity measure to find an example sentence in the example DB (Nio et al., 2014), and utters the sentence (Table 1). The following are the system actions such as Answer, Question (entity, property), Inform (entity, property, obj, Check-UserAnswer. To generate the next system utterance, we should select arguments such as entity, property, and object. For example, • Question (entity="Bill Gates", property="organization.founded") will generate "Do you    want to know the company Bill Gates founded?" • Inform(entity="Bill Gates", property=" organization.founded",obj="Microsoft") will generate "Bill Gates founded Microsoft" In this paper, we mainly explore how to select the most appropriate entity and property for generating system utterances.

Weight between two entities
Freebase is stored in a graph structure. The entity 'Bill Gates' is linked to many properties and entities in 'triple' format. However, the edges are not weighted. When the system provides useful information to a user about Bill Gates, then his profession, or books that he wrote will be more interesting to a user than Gates' gender or URL information. Moreover, the relationship between two entities can be represented as a directional graph. When we explain about Bill Gates, Basic programing language is important because he used it when he was programming. However, when we explain about Basic programing language, Bill Gates is not very important. Entities in Wikipedia are linked (Mendes et al., 2011) to obtain the weight information. Weight w( , ) is obtained as the follows when is 'Bill Gates' and is 'Microsoft'; First, we need the number of occurrence of "Microsoft" entity in the "Bill Gates" Wikipedia page to get ( ) . Second, we search the shortest path from "Bill Gates" to "Microsoft" in Freebase KB graph, then count the number of properties to get n( , ).

Property Embedding
The intuition of property-embedding similarity is as follows: when a user is talking about Bill Gates' professional achievement, POMY-ITS's best option would be to explain something related to professional achievement. However, designing all possible replies manually would be too expensive. When a user asks about Bill Gates' parents, POMY-ITS's best option would be to explain or ask the user about Gates' other family members. To determine that the "people.person.parents" property is more similar to "people.person.children" than "people.person.employment_history" (Figure 5), property-embedding vectors are generated to compute the similarity between two properties. We first obtain the sequence of the property from the Wikipedia corpus (Figure 2), then we use Skip-gram to train the vectors ( Figure  3). The training objective of the Skip-gram model is to find word representations that are useful to predict the surrounding (Mikolov et al., 2013). We used skip-gram to predict the next property given the current property as the following equation: ℎ denotes current property. The basic Skip-gram formulation uses the soft-max function to define ( + | ): where and ′ are, respectively, the input and output vector representations of r, and R is the number of properties in Freebase.

System Utterance Generation
After choosing entity and property, we can generate either question or inform sentences. Templatebased natural language generation uses rules (Table 2) to generate question utterances. Questions begin with a question word, are followed by the Freebase description of the expected answer type d(t), the further followed by Freebase descriptions of entities d(e) and d(p). To fill in auxiliary verbs, determiners, and prepositions, we parse the description d(p) into one of NP, VP, PP, or NP VP. For inform system actions, we generate the sentences from triple <Bill Gates, organization.founded, Microsoft> to "Bill Gates founded Microsoft" as follows: extract the triple from the text, and disambiguate to KB entities. Then, align to existing triples in KB, fourth. Finally, collect matched phrase-property pairs from aligned triples.

Experiment and Result
To compare the weight of two entities, 10 human experts ranked among the 60 entities that were most closely related to the target entity. We asked them to rank the entities as if they were teaching students about the target entities such as "Bill Gates", "Steve Jobs", "Seoul", etc. We considered the human labeled rankings to be the correct answers, and compared them to answers provided by the proposed method and word2vec 2 (Figure 4); as a similarity statistic we used the average score of Mean reciprocal rank (MRR). We obtained MRR scores 10 times, then got mean and standard deviation by repeating one human labels as the answer and another human labels as the test; this allows quantification of the correlation between human labels. The results show that human-to-human has the highest correlation. Next, the correlation between human and the proposed method is significantly better than between human and word2vec ( Figure 4). We found that word2vec has high similarity when entities are of the same type; e.g., Melinda Gates, Steve Ballmer, and Jeff are all "person" in Table 3. However, humans and the proposed system selected entities of different types such as 'Microsoft' and "Windows". Thus, semantic similarity does not necessarily represent the most related entities for explanation about the target entity in the educational perspective. To show property similarity, we plot in the 2D space using t-SNE (Van der Maaten and Hinton, 2008).
The graph shows that similar properties are closely plotted in 2D space, especially people.person.children and people.person.parents ( Figure 5). This is exactly consistent with our purpose of property-embedding, and our property-embedding model is available 3 which includes 779 total properties and 100 dimension.

Conclusion
We developed a conversational knowledge-teaching agent using knowledge base for educational purposes. To generate proper system utterance, we obtained the weight between two entities and property similarity. The proposed method significantly improved upon baseline methods. In the future, we will improve our conversational agent for knowledge education more tightly integrated into QA systems and dialog systems.