Disciple is an approach for developing interactive learning agents where the user teaches the agent in much the same way in which he would teach a human ...
Building Disciple Agents: Selected Validation and Verification Issues Tomasz Dybala Gheorghe Tecuci * Harry Keeling {tdybala, tecuci, hkeeling}@gmu.edu Learning Agents Lab, Computer Science Department, George Mason University, Fairfax, VA 22030, USA Abstract Disciple is an approach for developing interactive learning agents where the user teaches the agent in much the same way in which he would teach a human apprentice, by giving the agent specific examples of problems and solutions, explanations of these solutions, supervising the agent as it solves new problems and validating its solutions. In this paper we review the Disciple approach emphasizing those features that facilitate the development of verified and validated intelligent agents. We use for illustration the case of developing an Assessment Agent for the Multimedia and Thinking Skills educational software.
1 Introduction For several years we have been developing the Disciple approach for building interactive learning agents that can be trained by a user to assists him or other users in various ways (Tecuci, 1988; Tecuci and Kodratoff, 1990; Tecuci, 1992; Dybala, 1996; Hieb 1996). The Disciple approach, as it is currently implemented in the Disciple toolkit, reflects three developments in machine learning that have enhanced its applicability to complex domains: apprenticeship learning (Mitchell et al., 1990; Porter et al. 1990; Tecuci and Kodratoff, 1990), multistrategy learning (Michalski and Tecuci, 1994), and integrated knowledge acquisition and learning (Tecuci and Kodratoff, 1995). In this paper we briefly review the Disciple agent building methodology, emphasizing those features that facilitate the development of verified and validated intelligent agents. We illustrate our approach with a case of building an Assessment Agent for the Multimedia and Thinking Skills (MMTS) educational software being developed by a team led by Lynn Fontana of GMU. We first present the application domain and the interaction between the MMTS system and the Assessment Agent. We then describe the methodology of building a Disciplebased agent with the Disciple toolkit. We discuss some of the features of the Disciple editors and browsers that facilitate and enforce the definition of correct knowledge *
pieces. We present in more details the process of teaching the agent which is based on a validation process. We conclude the paper with a discussion of the validation and verification related features of the Disciple approach.
2 An assessment agent for a multimedia educational system We are currently using the Disciple toolkit to build a knowledge-based Assessment Agent that supports the MMTS Slavery Unit, a multimedia educational system for teaching higher order thinking in the context of history (see Figure 1). MMTS is a non-KB system developed with Oracle Media Objects. Students learn as they explore a set of multimedia documents (text, audio, video, graphic, photographic) about the African American experience during the Civil War. Examples of higher order thinking skills to be acquired are: evaluation of documents for relevance, credibility, consistency, ambiguity, bias, and fact vs. opinion; analyzing them for content, meaning and point of view; and synthesizing arguments in the form of conclusions, claims, assertions, etc.
Sl a v e ry Un i t Multimedia Data Base
MMTS
Te ac he r
A sse ssm e nt A g e n t Student Model Knowledge Base
Asses sme nt Engi ne
Stude nts
Figure 1: The Slavery Unit and the Assessment Agent. The role of the Assessment Agent is to generate questions that will test students’ higher order thinking skills. The agent could assist the teacher to test the students, or it could assist the students to test themselves while learning. For instance, to test a student’s ability to judge the
Also with the Center for Machine Learning, Natural Language Processing and Conceptual Modeling, Romanian Academy, Bucharest, Romania.
relevance of historical documents, the student could be shown a document and be asked if it is relevant to a certain task (see Figure 2 for an example of such a test). Or, the student could be shown a document relevant to a task, as well as several potential reasons of why the document is relevant, and would be asked to select the right reasons. Or, the student could be shown three documents, one relevant to the task and two irrelevant ones, and would be asked to indicate which document is relevant. The Assessment Agent will also provide the correct answers and explanations of the answers. In the case of self-testing, the students could also receive hints from the Assessment Agent. The tests are dynamically generated based on a student model and do not involve documents that have been investigated by the student or used in previous tests for the student. Also, the students running the system in the same time, during a class, will receive different tests even if they have investigated the same documents. The MMTS Slavery Unit invokes the Assessment Agent whenever a test needs to be generated. It provides
the agent with information necessary to update the student model, and with requirements for the test. The agent generates and returns the test that is displayed by the MMTS Slavery Unit.
3 The methodology of using the Disciple toolkit to build intelligent agents The methodology for building and using the Disciplebased agents is illustrated in Figure 3. First, the agent developer customizes the Disciple Toolkit (presented in section 4) and develops domain dependent software modules. For instance, in the case of the Assessment Agent, one has to develop the Assessment Engine, as well as an interface between the agent and the MMTS Slavery Unit. The result of this phase is an Agent Shell that can interact with the expert (a historian and curriculum developer, in the case of the Assessment Agent) during the training process.
Figure 2: A test generated by the Assessment Agent.
DEVELOPER
EXPERT-USER
Mutual Support
Agent Training/Use
Agent Development Customized Agent Shell DISCIPLE T OOLK IT & DOMAIN DEPENDENT SOFTWARE MODULES
Need for Retraining
to facilitate KB consistency in face of a combination of automatic and manual modification of knowledge. DOMAIN DEPENDENT SOFTWARE MODULES
PERFORMANCE
DOMAIN INDEPENDENT GRAPHICAL USER INTERFACE
SUPERVISED LEARNING AGENT
Need for Redevolpment
BROWSING TOOLS
D IS CI P L E T O O L KI T
UNSUPERVISED AGENT
I NT E R FA CE
Trained Agent
EDITING TOOLS
LEARNING TOOLS
PERFORMANCE TOOLS
KNOWLEDGE QUERY LANGUAGE
KNOWLEDGE BASE
Agent Use USER
Figure 3: Using DISCIPLE Toolkit to build interactive learning agents. During agent training the expert first develops the agent’s initial knowledge base and then teaches the agent how to perform domain specific tasks. An illustration of this process is given in section 7. As a result, a trained agent is developed that can interact with a non-expert user (e.g. an elementary school student learning about slavery and higher order thinking). During agent training and/or agent use a need for periodic retraining or redevelopment may arise, in which case the previous phases are repeated.
4 The architecture of the Disciple Toolkit The Disciple Toolkit is being developed to be used with the agent building methodology described in the previous section. The toolkit has a modular architecture (see Figure 4) that facilitates the development of agent shells for various domains. Some of the design objectives of the Disciple Toolkit were: • to allow uniform interaction with the user over a diversity of knowledge management operations, in order to facilitate the communication between the agent and the user; • to facilitate the maintenance of rich associations between the related knowledge pieces, in order to facilitate the process of building a consistent KB; • to be specialized to the representation of knowledge required by the learning methods of Disciple, in order
Figure 4: Architecture of the DISCIPLE Toolkit The Disciple Toolkit consists of tools for: • examining the agent’s knowledge (such as Dictionary Browser, Concept Browser, Rule Browser, and Association Browser); • defining and modifying agent’s knowledge (such as Concept Editor, Rule Editor and Dictionary Editor); • interactively learning rules (Rule Formulation Tool, Rule Refinement Tool, Example Editor, Example Generator, Explanation Generator, Explanation Editor, and Exception Handler); • solving domain problems or performing domainspecific tasks (the performance tools). The Toolkit is being implemented using the Harlequin LISP software engineering environment on SUN platforms. It currently consists of approximately 25 thousand lines of LISP source code. Most of the tools are already functioning and they are tested and used to build various agents.
5 The organization knowledge base
of
agent’s
The agent’s knowledge base consists of a collection of knowledge elements that include instances, concepts, and rules. The concepts and instances are described in terms of properties and relationships with other concepts or instances, and are organized in a hierarchical semantic network. The rules are general “if-then” expressions that could represent a great variety of reasoning mechanisms such as inferring a statement from other statements, decomposing a problem into subproblems, or indicating an appropriate action to take in a certain situation. Each knowledge element has a unique name maintained in a global dictionary. This dictionary is the main data structure for four classes of operators on knowledge elements, operators that define the Knowledge Query
Language: constructors, destructors, modifiers, and queries. Part of the description of each knowledge element is the list of the other knowledge elements with which the element is associated. For example, part of a concept’s description is the list of the rules that use this concept. Such associations among knowledge elements play an important role in building a consistent knowledge base. For instance, one would not be allowed to delete a concept from the knowledge base before all the rules that refer to that concept are updated. The associations also facilitate the inspection and manipulation of the related knowledge elements because the system can easily access one from the other. The process of developing the agent’s knowledge base consists of two main phases: • developing an initial, incomplete knowledge base, discussed in the next section. • teaching the agent to perform various tasks, discussed in section 7.
6 Using the editing and browsing tools to develop an initial knowledge base
(assisted by the knowledge engineer) has first to represent the historical documents in terms of their content, author, reason of creation, procedures used to create them, and other features relevant to studying the documents. Instance and concept descriptions are created with the Concept Editor. For example, the bottom right window of Figure 5 is the Concept Editor window corresponding to the description of the document “Hauling the Week’s Picking” by William H. Brown. This document, the name of which is Document-6, is described in terms of features like: producer, content, content-type, media-type, primacy, and date. The content of the document is represented by a list of keywords that include slave-hiring, slave-work, and master-slave-relationship. The process of describing an instance, or a concept, consists of selecting its relevant features from a set of defined features (the middle pane in the bottom part of the Concept Editor window). Once a feature is selected from the middle pane, the rightmost pane indicates all the allowable values from which the user should select the correct value. When a feature is not defined, the expert has to use the Dictionary Browser/Editor to define it, as described later.
In order to build the knowledge base of the Assessment Agent for the MMTS Slavery Unit, the history expert
Figure 5: Concept Browser, Association Browser, Concept Editor Windows.
The left hand side of Figure 5 contains a Concept Browser window that allows easy inspection of the concepts and instances included in the KB. The top part of the window shows the generalization/specialization relationships between concepts and instances. The bottom part of the window gives a complete description of the concept or instance selected by the user in the generalization hierarchy. Since a new concept or instance is always described in terms of a more general concept (e.g. DOCUMENT-6 is an instance of DOCUMENT), the Concept Browser is a very useful tool in the definition of new knowledge elements. The Concept Browser can also be used to delete concepts and instances. The Concept Browser will allow the user to delete a concept only if it is not used by other elements of the agent’s knowledge. Otherwise, the Concept Browser will request the user to first modify the description of these knowledge elements, to no longer refer to the concept to be deleted.
learned rules do not have a single applicability condition but two conditions, a plausible lower bound condition and a plausible upper bound condition. These bounds define a Plausible Version Space (Tecuci, 1992) for the exact condition of the general inference rule to be learned. An example of such a rule is shown in the top pane of Fig. 9.
To determine the other elements that refer to the element to be deleted, the user can use the Association Browser (see the top right window in Figure 5). The user will select the name (e.g. PUBLISHED-DURING) in the left pane of the Association Browser and the right pane will list all the knowledge base elements that refer to it (e.g. HARPERSWEEKLY, CHRISTIAN-RECORDER). As mentioned above, in order to use a new feature to describe a concept or an instance, that feature needs first to be defined, by using the Dictionary Browser-Editor (see Figure 6). The Dictionary Browser-Editor has two main functions. As a browser, it allows the user to display (in alphabetical order) all the element names of a selected type, together with a brief description. As an editor, it allows the user to define the basic components of a knowledge element, such as a feature (property or relation), a problem or a function. For example, to define a feature, one has to indicate its name, a natural language description of the feature, and the set of allowable values. The rules in the agent’s KB are “if-then” rules. In the case of the Assessment Agent for the MMTS Slavery Unit, one type of rules are inference rules that infer new features of objects from other features. The condition of an inference rule is a conjunctive expression formed with the concepts and relationships from the hierarchical semantic network of concepts and instances. The conclusion of the rule is a new feature of some concept or instance. The expert and the knowledge engineer can manually define, inspect or modify the rules by using the Rule Editor and the Rule Browser. Most often, however, the agent will learn such rules from examples and explanations provided by the expert, as presented in the next section. Partially
Figure 6: Dictionary Browser-Editor. When the user is editing a rule, the constraints bellow are verified and the user is warned of any attempt to override them: • the upper bound condition must be more general than the lower bound condition; • the lower bound condition should cover all the positive examples from which the rule was learned. • the upper bound condition should not cover any of the negative examples from which the rule was learned.
7 Teaching the agent After defining an initial knowledge base, the expert teaches the agent to solve problems in much the same way in which the expert would teach a human apprentice, by
giving the agent specific examples of problems and solutions, explanations of these solutions, and supervising the agent as it solves new problems. During such interactions, the agent learns general rules and concepts, continuously extending and improving its knowledge base. The agent learns by integrating three basic learning strategies, explanation based learning, learning by analogy, and empirical inductive learning from examples, as illustrated in Figure 7.
A n a l o g y - Ba s e d M o d e Explanation-Based Mode
Plausib le Versio n Space
expert initiates the teaching process by giving the agent an example of a document that is relevant to a specific task (this is a kind of task that a student may receive in the history class): Suppose that you are a writer for Harper’s Weekly during the pre Civil War period and you have been assigned to write an article on slave life. Then Document 6, “Hauling the Week’s Picking”, is relevant to this task. This initial example is represented as shown in the upperleft pane of the window in Figure 8:
Explanation
Example s of Proble ms/Solu ti ons Propo sed by the Age nt P rob le m/S o lut i on Gi ven by E xper t
Wrong C orrec t P robl em/ S olut i on P robl em/ S olut i on
If the task is to write an article on slave life for Harper’s Weekly then Document-6 is relevant. Starting from this example the agent will learn a general rule of the form:
Induction-Based Mode
Figure 7: The learning method of Disciple.
7 . 1 Illustration of agent’s teaching
IF a task and a document have certain features THEN the document is relevant to the task
In the following we will briefly present a hypothetical session in which a history expert teaches the Assessment Agent how to evaluate a document for relevance. The
Figure 8: The Create Rule window.
7 . 1 . 1 Explanation-Based Mode First, in the Explanation-Based Mode, the agent looks for an explanation of why the example is correct. It will use several heuristics to propose partial plausible explanations from which the expert is asked to choose the correct ones. The explanations generated are shown in the bottom pane of the window in Figure 8, and the explanation chosen by the expert is preceded by an *. In this case the chosen explanation is: The content of Document-6 is about slave pickings hauling which was a component of slave life. The expert may guide the explanation generation process and can also define additional explanations using the Explanation Editor. In general, however, this initial explanation will be incomplete. This is partially a consequence of using heuristics, and partially a consequence of the incompleteness of the knowledge base. Nevertheless, the explanation shows some important features that justify the example provided by the expert, and can be used by the agent to generate analogous examples, as presented bellow.
7 . 1 . 2 Analogy-Based Mode After an explanation is found, the agent enters the Analogy-Based Mode in which it formulates the plausible version space rule shown in the upper-right pane of the window in Figure 8. In contrast to a standard “if-then” rule, this rule has two conditions. The plausible lower bound condition corresponds to the initial example and its explanation and applies only to this example. The standard “if-then” rule corresponding to this condition is: If the task is to write an article on slave life for Harper’s Weekly and the content of Document 6 is about slave pickings hauling which was a component of slave life then this document is relevant. The plausible upper bound condition is an overgeneralization of the plausible lower bound condition obtained by turning individual instances and concepts into variables and preserving the relationships between them.
The standard “if-then” rule corresponding to this condition is: If the task is to write an article on ?S27 for ?H41 and the content of ?D42 is about ?S43 which was a component of ?S27 then ?D42 is relevant. Obviously, the first rule is too specific (it covers only one example), while the second rule is too general (it covers also negative examples). These rules define a plausible version space for the rule to be learned that is more general than the first rule and more specific than the second one. Once this initial plausible version space has been defined, the agent starts an experimentation process. It generates instances of the plausible upper bound rule which are not covered by the plausible lower bound rule and asks the expert if they are correct or not. The examples are presented to the expert in the Refine Rule window illustrated in Figure 9. The top pane of this window contains the current rule, the bottom-right pane contains the initial example provided by the expert (but could also display other investigated examples), and the bottom-left pane contains the current example generated by the agent.
7 . 1 . 3 Induction-Based Mode The instances generated in the analogy mode are accepted or rejected by the expert, being thus characterized as positive examples or as negative examples of the rule to be learned. These instances are used to search the rule in the version space shown in the upper-right pane of the window in Figure 8. The use of the positive examples The first example generated by the agent is: If the task is to write an article on slave life for Christian Recorder then Document-3 is relevant. The content of Document-3 is about slave family which was a component of slave life.
Figure 9: The Refine Rule window. Notice that this example description incorporates also an expression that is similar to the explanation of the initial example. The expert accepts this example which is therefore a new positive example of the general rule to be learned. As a consequence, the plausible lower bound condition is generalized as follows (to cover this new positive example and to remain less general than the plausible upper bound condition): HARPERS-WEEKLY is generalized to PUBLICATION to cover CHRISTIAN-RECORDER DOCUMENT-6 is generalized to DOCUMENT to cover DOCUMENT-3 SLAVE-PICKINGS-HAULING is generalized to HISTORICAL-CONCEPT to cover SLAVE-FAMILY Other positive examples generated by the agent will further generalize the plausible lower bound condition. The use of the negative examples
Let us now consider the following example generated by the agent which is rejected by the expert: If the task is to write an article on slave life for Harper’s Weekly then Document-5 is relevant. The content of Document-5 is about slave cotton planting which was a component of slave life. This example is shown in the bottom-left pane of Figure 9. The expert rejects this example because Document-5 was created after the Civil War period and the task is to write an article during the pre Civil War period. Therefore it could not be used to write an article for that issue. This failure of the agent gives the expert an opportunity to provide an additional explanation of the initial example. The initial example is shown in the bottom-right pane of Figure 9, and the additional explanation is shown bellow it: Document-6 was created during precivil-war and Harper’s weekly was published during pre-civil-war.
As a result of this additional explanation, both the upper and lower bound descriptions of ?H41 and ?D42 are specialized to indicate that ?H41 was published during the period when ?D42 was created. The new rule is shown in the top pane of Figure 9. During this process, the plausible lower bound and the plausible upper bound are both generalized and specialized to better approximate the exact condition of the rule to be learned. This process continues until the two bounds become identical, or until all the instances of the upper bound with respect to the current knowledge base are also instances of the lower bound, or until the user decides to stop the teaching.
7 . 2 Other process
features
of
the
teaching
As mentioned above, the agent will only generate instances of the plausible upper bound that are not instances of the plausible lower bound. This guarantees that each such instance will lead to an improvement of the rule, whether it is a positive or a negative example. The direct consequence is that the rule learning process is very efficient. However, in the process of generating these instances, the system also collects the instances that are covered by the plausible lower bound, and the user could inspect them if he decides that the learned rule needs to be further validated. The above scenario gives only a very general outline of the teaching process. There are other kinds of interactions between the expert and the agent that have not been illustrated above. For instance, the expert may give the agent additional positive and negative examples that are used by the agent in the same way as the examples generated by the agent. During learning the agent may also accumulate negative or positive exceptions of the rule. A negative exception is a negative example that is covered by the plausible lower bound and specializing the lower bound to uncover it would result in the uncovering of some of the positive examples from which the rule was learned. That is, by trying to eliminate commission errors one would introduce omission errors. Similarly, a positive exception is a positive example that is not covered by the plausible upper bound and generalizing the upper bound to cover it would result in the covering of some of the negative examples from which the rule was learned. In such cases, the agent will attempt to elicit new knowledge from the domain expert (e.g., new features of the tasks, documents and publications that are not defined in the KB). These knowledge elements will allow the agent to modify the plausible version space of the rule such that the negative and the positive exceptions become negative examples and positive examples, respectively. Some of these knowledge
elicitation techniques are described in (Tecuci and Hieb, 1994). With respect to verification and validation, this process of teaching the agent is significant for two different reasons. First of all, it is much more natural for an expert to give examples, choose relevant explanations, and analyze the examples generated by the agent, rather than directly defining the rules. Consequently, this information is much more likely to be correct, than a general rule elicited from the expert. Second, this approach is based on an expert interacting with the agent, checking and correcting the way the agent solves problems, thus it produces validated rules.
8 Conclusions Shortliffe, Buchanan, and Feigenbaum (1979) rightly stress that the validation process should begin with the system specifications and continue throughout the whole development process. Consistent with this view, the Disciple agent building methodology addresses many validation and verification issues. A basic idea is that it attempts to significantly simplify the process of building an agent for a specific application domain and subsequently it increases the chances to build the right agent and to build the agent right (O’Keefe and O’Leary, 1989). By training the agent, rather than manually encoding its knowledge base, one greatly facilitates the knowledge acquisition process. The main idea was to create a synergism between the expert and the agent in which the agent helps the expert to express his knowledge using the agent’s representation language, and the expert guides the learning actions of the agent. Crucial to this synergism is the communication between the expert and the agent which, from the expert’s perspective, can be described in terms of five types of interactions: specifying knowledge to the agent; giving the agent a concrete example that the agent is to learn a general rule for; validating analogical examples proposed by the agent; explaining to the agent reasons for the validation; and being guided by the agent to provide new knowledge during interaction. Testing the agent is an integral part of teaching it and therefore, an integral part of building the agent. Therefore, one could say that the Disciple methodology is a validation-based methodology for building agents. Maintainability of agent’s knowledge base is also facilitated by the Disciple approach. Indeed, the agent’s learning method is an incremental adaptation of the rules to new positive and negative examples. If new examples are
discovered that are not correctly classified by a rule, one simply needs to reapply the learning method to refine the rule.
Acknowledgements Mark Pullen and Lynn Fontana provided useful suggestions for this research. Ward Cates and M.J. Bishop provided numerous examples of tests that shaped the approach to the Assessment Agent. This research was supported by the Advanced Research Projects Agency Contract No. N6600195-D-8653.
References Dybala, T., Shared Expertise Model for Building Interactive Learning Agents, PhD Thesis, Learning Agents Lab, Department of Computer Science, School of Information Technology and Engineering, George Mason University, 1996. Hieb, R.M., Training Instructable Agents Through Plausible Version Space Learning, PhD Thesis, Learning Agents Lab, Department of Computer Science, School of Information Technology and Engineering, George Mason University, 1996. Michalski, R.S. and Tecuci, G. (Eds.), Machine Learning: A Multistrategy Approach Volume 4, Morgan Kaufmann Publishers, San Mateo, CA, 1994. Mitchell, T.M., Mahadevan, S., and Steinberg, L.I., in Kodratoff Y. and Michalski R.S. (Eds.), Machine Learning, Vol. III, Morgan Kaufmann, San Mateo, 1990. O’Keefe, R. and O’Leary D., Verifying and Validating Expert Systems, Tutorial, IJCAI-89, 1989. Porter B. W, Bareiss R. and Holte R. C., Concept Learning and Heuristic Classification in Weak-Theory Domains. In J. W. Shavlik and T. G. Dietterich, Eds. Readings in Machine Learning, pp. 710-746. San Mateo, CA: Morgan Kaufmann, 1990. Shortliffe, E.H., Buchanan, B.G. and Feigenbaum E.A., Knowledge Engineering for Medical Decision Making: A Review of Computer-Based Clinical Decision Aides, Proceedings of IEEE, vol.67, no.9, pp.1207-1224, 1979. Tecuci G., DISCIPLE: A Theory, Methodology, and System for Learning Expert Knowledge, Ph.D. Thesis, University of Paris South, 1988.
Tecuci G. and Kodratoff Y., Apprenticeship Learning in Imperfect Theory Domains, in Y. Kodratoff and R. S. Michalski (Eds.), Machine Learning: An Artificial Intelligence Approach, vol. 3, Morgan Kaufmann, pp. 514551, 1990. Tecuci G., Automating Knowledge Acquisition as Extending, Updating, and Improving a Knowledge Base, IEEE Trans. on Systems, Man and Cybernetics, Vol. 22, No. 6, 1992. Tecuci, G. and Hieb, M.R. 1994. Consistency-driven Knowledge Elicitation: Using a Machine Learning-oriented Knowledge Representation to Integrate Learning and Knowledge Elicitation in NeoDISCIPLE. Knowledge Acquisition Journal, 6(1):23-46. Tecuci G. and Kodratoff Y. (Eds.), Machine Learning and Knowledge Acquisition: Integrated Approaches, Academic Press, 1995.