index
int64 0
18.8k
| text
stringlengths 0
826k
| year
stringdate 1980-01-01 00:00:00
2024-01-01 00:00:00
| No
stringlengths 1
4
|
|---|---|---|---|
900
|
Learning to Coordinate Behaviors Pattie Maes & Rodney A. Brooks AI-Laboratory Massachusetts Institute of Technology 545 Technology Square Cambridge, MA 02139 pattieQai.mit .edu brooksQai.mit .edu Abstract We describe an algorithm which allows a behavior- based robot to learn on the basis of positive and - negative feedback when to activate its behaviors. In accordance with the philosophy of behavior- based robots, the algorithm is completely distribu- ted: each of the behaviors independently tries to sensors find out (i) whether it is relevant (i.e. whether it is at all correlated to positive feedback) and (ii) what the conditions are under which it be- comes reliable (i.e. the conditions under which it maximises the probability of receiving positive feedback and minimises the probability of receiv- ing negative feedback). The algorithm has been tested successfully on an autonomous 6-legged ro- bot which had to learn how to coordinate its lens E Figure 1: Cl assical decomposition of an autonomous robot. . . . so as to walk forward. build maps Situation of the Problem sensors - explore - actuators Since 1985, the MIT Mobile Robot group has advocated a radically different architecture for autonomous intel- ligent agents (Brooks, 1986). Instead of decomposing the architecture into functional modules, such as per- wander avoid objects ception, modeling, and planning (figure l), the archi- Figure 2: Behavior-based decomposition of an autono- tecture is decomposed into task-achieving modules, also mOuS robot. called behaviors (figure 2). This novel approach has al- ready demonstrated to be very successful and similar ap- proaches have become more widely adopted (cfr. for ex- fully grasp the peculiarities of the task and environment, ample (Brooks, 1990) (Rosenschein & Kaelbling, 1986) so as to be able to specify what will make the robot suc- (Arkin, 198’7) (Payton, 1986) (Anderson & Donath, 1988) (Yamaushi, 1990) (Zhang, 1989)). cessfully achieve the task (Maes, 1990). We therefore started developing an algorithm for learn- One of the main difficulties of this new approach lies ing the control of behaviors through experience. In ac- in the control of behaviors. Somehow it has to be decided cordance with the philosophy of behavior-based robots, which of the behaviors should be active and get control the learning algorithm is completely distributed. There over the actuators at a particular point in time. Until is no central learning component, but instead each behav- now, this problem was solved by precompiling the con- ior tries to learn when it should become active. It does trol flow and priorities among behaviors either by hand so by (i) trying to find out what the conditions are under (Brooks, 1986), or automatically, using a description of which it maximizes positive feedback and minimizes neg- the desired behavior selection (Rosenschein & Kaelbling, 1986). In both cases the result is some “switching cir- ative feedback, and (ii) measuring how relevant it is to the global task (whether it is correlated to positive feedback). cuitry” among the behaviors which is completely fixed at We hope that ultimately, this learning algorithm will compile time by the designer. allow us to program the behavior of a robot by selecting However, for more complicated robots prewiring such a number of behaviors from a library of behaviors, con- a solution becomes either too difficult or impractical. As netting these to the actual sensors and actuators on the the number of behaviors goes up, the problem of control robot, defining positive and negative feedback functions, and coordination becomes increasingly complex. Addi- and making each of the behaviors learn from experience tionally, it is often too difficult for the programmer to when it is appropriate for it to become active. 796 MACHINE LEARNING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. The Learning Task The learning task we are concerned with is defined as follows. Given a robot which has: a vector of binary perceptual conditions which are either being perceived (or “on”) or not being per- ceived (or “off”) at every instant of time, a set of behaviors; where a behavior is a set of pro- cesses involving sensing and action; a behavior has a precondition list, which is a conjunction of predi- cates testing a specific value (on or off) for a certain perceptual condition; a behavior may become active when all of its preconditions are fulfilled; an active behavior executes its processes, a positive feedback generator, which is binary and global, i.e. at every time t, the robot (and therefore all of the behaviors) either receive positive feedback or not, a negative feedback generator, which is again binary and global. The learning task is to incrementally change the pre- condition list of behaviors so that gradually only those behaviors become active that fulfill the following two con- straints: 1. they are relevant, where a relevant behavior is a behavior that is pos- itively correlated to positive feedback (i.e. positive feedback is more often received when the behavior is active then when it is is not active) and not pos- itively correlated to negative feedback (i.e. either not correlated at all or inversely correlated), 2. they are reliable, where a reliable behavior is defined as a behavior that receives consistent feedback (i.e. the probabil- ity of receiving positive (respectively negative) feed- back when the behavior is active is close enough to either 1 or 0). An additional requirement, imposed by our philoso- phy, is that we want the algorithm to be distributed. It should allow individual behaviors to change their precon- dition list in response to certain feedback patterns so that the global behavior of the set of behaviors converges to- wards a situation where maximal positive feedback and minimal negative feedback is received. Finally, three ad- ditional constraints are related to the fact that this al- gorithm has to be useful for real robots in unconstrained environments: (i) the algorithm should be able to deal with noise, (ii) the algorithm should be computationdly inexpensive, so that it can be used in real-time, and (iii) the algorithm should support readaptation, i.e. if the robot changes (e.g. some component breaks down), or its environment changes (e.g. the feedback generators change) the algorithm will make the robot adapt to this new situation (which possibly involves forgetting or revis- ing learned knowledge). We adopted some simplifying, but realistic, assump- tions. One is that, for every behavior, there exists at least one conjunction of preconditions for which the probability of positive feedback as well as the probability of negative feedback are within some boundary (which is a param- eter of the algorithm) from either 0 or 1. Another im- portant assumption is that feedback is immediate (there is no delayed feedback) and does not involve action se- quences. And finally only conjunctions of conditions (in- cluding negations) can be learned. The last section of the paper sketches how the algorithm could be extended to deal with the more general probleml. Nevertheless, even after adopting these simplifying assumptions, the learn- ing task is still far from trivial. More specifically, the global search space for a robot with n behaviors, and m binary perceptual conditions is n * 3m, since every behav- ior possibly has to learn an “on”, “off” or “don’t-care” value for every perceptual condition. The Algorithm The learning algorithm employed by each behavior is the following. Each behavior starts from a “minimal” pre- condition list. More specifically, only conditions that are necessary in order to be able to execute the processes of the behavior are present. Behaviors maintain data about their performance. A first set of data is related to whether the behavior is relevant or not. A behavior measures i, j, k and 1: active not active positive feedback j k no uositive feedback 1 m Where, j is the number of times positive feedback hap- pened when the behavior was active, k is the number of times positive feedback happened when the behavior was not active, 1 is the number of times positive feedback did not happen when the behavior was active, and m is the number of times negative feedback did not happen when the behavior was not active. The same statistics are main- tained for negative feedback. The statistics are initialized at some value N (for example N = 10) and “decayed” by multiplying them with fi every time they are up- dated. This ensures that impact of past experiences on the statistics is less than that of more recent experiences. The correlation (the Pearson product-moment correlation coefficient) between positive feedback and the status of the behavior is defined as cow(P, A) = j*m-l*k &m+l)*(m+k)*(j+k)*(j+l) MAES AND BROOKS 797 This gives a statistical measure of the degree to which the status of the behavior (active or not active) is corre- lated with positive feedback happening or not. cow(P, A) ranges from -1 to 1, where a value close to -1 represents a negative correlation (feedback is less likely when the be- havior is active), 0 represents no correlation and 1 repre- sents a positive correlation (feedback is more likely when the behavior is active). In an similar way, cow(N, A), i.e. the correlation between the status of the behavior and negative feedback is defined. The relevance of a particu- lar behavior is defined as coTr (P, A) - COTF( N, A) It is used by the algorithm to determine the probability that the behavior will become active (which is related to the effort which will be put into doing experiments in order to improve the behavior, i.e. making it more reli- able). The relevance of a behavior ranges from -2 to +2. The more relevant a behavior is, the more chance it has of becoming active. A behavior that is not very relevant has little chance of becoming active. So, these statistics makes it possible to determine which behaviors are the in- teresting ones (relevant ones). The relevant behaviors are not necessarily very reliable yet: they might only receive positive feedback in a minority of the times they are ac- tive. They also might still cause a lot of negative feedback to be received. All that is “known” is that positive feed- back will be more likely received when these behaviors are active, than when they are not active (respectively negative feedback being less likely). The reliabdity of a behavior is defined as (where index P stands for positive feedback and index N stands for negative feedback) . min(maz(A lP -), maz( - jp+b’jp+b The reliability of a behavior ranges from 0 to 1. When the value is close to 1, the behavior is considered very reliable (i.e. the feedback is very consistent: the proba- bility of receiving feedback is either close to 0 or to 1). The reliability of a behavior is used by the algorithm to decide whether the behavior should try to improve itself ( i.e. learn more conditions or modify the existing pre- conditions). If the behavior is not reliable enough, i.e. if either the negative feedback is inconsistent OE the posi- tive feedback is inconsistent or both, then one or more additional preconditions are relevant. In this case, the behavior will pick a new perceptual condition to moni- tor in order to determine whether this condition might be related to the inconsistent feedback 2. An additional set of statistics is related to the specific condition being monitored (if there is one): becomes close to 1 (respectively -l), then the condition will be adopted in the precondition list, with a desired value of “on” (respectively “off”). And similarly, if the correlation for negative feedback becomes close to 1 (re- spectively -l), then the condition will be adopted in the precondition list, with a desired value of “OR” (respec- tively “on”). If the values for positive and negative feed- back are incompatible, the one suggested by the negative feedback dominates. From the moment a new condition has been learned, a behavior only becomes active when this condition has the desired value. If after monitoring a condition for a while, the behavior doesn’t notice any cor- relation between the value of the condition and positive or negative feedback, and the behavior is still not reliable enough, it will start monitoring another condition. After learning a new condition, the behavior will not necessarily be completely reliable. There might still be other conditions related to the feedback. Until the be- havior is reliable enough, it will try to find extra precon- ditions s. Notice that the list of conditions being mon- itored/evaluated is circular. When all of the conditions have been evaluated and feedback is still inconsistent, the behavior will start monitoring conditions from the start of the list again, reevaluating also those conditions which have already been taken up in the precondition list. A be- havior might “forget” something it learned and reevaluate the relevance of that condition. This guarantees that if the environment (e.g. the feedback) or the robot changes, the behaviors are able to adapt to the new situation. The control strategy of the algorithm is as follows. Behaviors are grouped into groups which control the same actuators. At every timestep the selectable behaviors in every group are determined (those behaviors which are 2Currently there is a complete connectivity between behaviors and perceptual conditions. The connectivity will be decreased in a cond. on cond. off positive feedback n 0 no positive feedback D a Where n is the number of times positive feedback hap- pened when the behavior was active and the condition was on, o is the number of times positive feedback hap- pened when the behavior was active and the condition was off (not on), p the number of times positive feedback did not happen when the behavior was active and the condition was on, and q is the number of times negative feedback did not happen when the behavior was active and the condition was off. Again the same statistics are maintained for negative feedback. If the behavior notices a strong correlation between the condition being moni- tored and positive and/or negative feedback, it will adopt this condition as a new precondition. More specifically, if the correlation cow ( P, on) = n*q-p*o J(q+p)*(q+o)*(n+o)*(n+p) subsequent implementation through the use of a switchboard. In 3We make the assump tion here that for every condition that applications involving a large vector of perceptual conditions, one has to be learned the correlation to feedback is independently de- could restrict the subset of conditions that a particular behavior tectable. This is likely to be true, because we are not dealing with considers for learning. the problem of learning disjunctions. 798 MACHINE LEARNING not yet active and whose preconditions are fulfilled). For each of these groups, one or zero behaviors are selected probabilistically according to (in order of importance) o the relative relevance of behaviors, o the reliability of behaviors, and e the “interestingness” of the current situation for behav- iors, where a situation is more interesting for a behavior if the condition being monitored by the behavior appears in the situation with a value (on or off) that has been experienced a lesser number of times. The selected behaviors are then activated. The prob- abilistic nature of the selection process ensures that there is a balance between behaviors being selected (i) because they are successful (are relevant and reliable) and (ii) be- cause of experimentation purposes (to learn). Notice that the learning algorithm is biased: if behaviors are not very relevant (in comparison with other behaviors) they have very little chance of becoming active, which means that little effort is put into making them more reliable (learn new preconditions). Finally, there are a number of global parameters which can be varied to change the algorithm o how strong a condition has to be correlated to adopt it as a new precondition, o how long a condition is monitored before it is dropped, e how reliable a behavior should try to become, e how adaptive the behavior is (the relative importance of new data versus data of past experiences). These parameters have to be tuned to the particular circumstances of task and robot at hand. A Robot that Learns to The Task The described- algorithm is being tested on a six-legged robot, called Genghis (see figures 4 and 5). The goal of the experiment is to make Genghis learn to walk forward. This task was chosen because of its complexity. The cur- rent version consists of 12 behaviors learning about 6 per- ceptual conditions, which corresponds to a search space of 12*3” = 8748 nodes. Another reason for choosing this task was the availability of a 6-legged robot with a lot of degrees of freedom (12 to be precise) (Angle, 1989). The final reason is that a lot is known both about insect walk- ing (Wilson, 1966) (B eer, 1989) and about 6-legged robot walking (Donner, 1987) (B rooks, 1989). The results re- ported in this literature demonstrated that the task was feasible (that the completely distributed walking which traiu whest r? (posit eteedback) touch sensors (negative feedback) Figure 3: Schematic representation of Genghis, its pos- itive and negative feedback sensors and its distributed collection of learning behaviors. Genghis is an autonomous six-legged robot with twelve servo motors controlling the two degree of freedom legs (Angle, 1989). It has 4 on board 8-bit microprocessors linked by a 62.5Kbaud token ring. The total memory us- age of the robot is about 32Kbytes. Genghis has been programmed before to walk over rough terrain and fol- low a person passively sensed in the infrared spectrum (Brooks, 1989). 0 ur experiments were programmed us- ing the Behavior Language and Subsumption Compiler (Brooks, 1989b). Th e entire learning program runs on board. The sensors used in this experiment are two touch sensors on the bottom of the robot (one in the front and one in the back) and a trailing wheel which measures for- ward movement. Negative feedback is received by all of the behaviors every time at least one of the touch sensors fires. Positive feedback is received every time the wheel measures forward movement. We equipped Genghis with a dozen behaviors: 6 swing-leg-forward behaviors (which move a leg that is backward, up, forward and then down again), 6 swing-leg-backward behaviors (which move a leg that is forward, up, backward and then down again) (fig- ure 3). Further there is one horizontal balance behavior, which sums the horizontal angles of the legs and sends a correction to all of the legs so as to reduce that sum to 0 (i.e. if one leg is moved forward, all of the legs are moved backwards a little). The 12 swing behaviors try to learn what the conditions are under which they should become active. The vector of binary perceptual conditions has 6 elements, each of which records whether a specific leg is up (not touching the ground). would result from our learning was indeed robust and suc- cessful). This literature also made it possible to compare Results and interpret our results. The Robot In a first experiment only six swing forward behaviors plus the balance behavior were involved. Genghis was able to learn to activate behaviors safely (avoiding negative feed- back or “falling on its belly”) and successfully (producing positive feedback or moving forward). More specifically, MAES AND BROOKS 799 it learned to adopt a tripod gait, keeping three legs on This experiment has been successfully demonstrated the ground at any moment: the middle leg on one side on the robot. Using a non-intelligent search through the and the front and back leg on the other side. Notice that condition vector (i.e. every behavior monitors the condi- this task is not trivial: negative feedback is not related Cons in the same order, starting with the status of the to particular behaviors (none of the behaviors by itself first leg, then the status of the second leg, etc) this takes causes negative feedback), but rather to the way they are in the order of 10 minutes. Using an intelligent search coordinated (or uncoordinated). It is therefore a neces- (i.e. every behavior starts by monitoring the status of sity in this application that actions are explored by the legs that are nearby, then the ones that are further away, robot in parallel. This extra difficulty is successfully han- and so on), this experiment t&es approximately 1 minute dled by the algorithm: the distributed learning behaviors and 45 seconds. are able to learn a task which requires their coordination. Figure 4: Genghis learning to walk. Initially, the behaviors do not know yet how they are supposed to coordinate (under what conditions they should become active). Since the two front leg “swing forward” behaviors are being activated at the same time, Genghis falls down and receives negative feedback from the touch sensor mounted on the front of its belly. Figure 5: Gradually, a more coherent “walk” emerges. In this case the global behavior converges towards a tripod gait: two groups of three legs are being swung forward alternately. 800 MACHINE LEARNING The reason why this is so much faster is that in this case, behaviors learn and converge more or less simul- taneously (in the non-intelligent search case all of the behaviors have to “wait” for leg 4 and 5 to go through the whole condition vector before finding correlated con- ditions). The preconditions that are learned are that a swing-forward behavior is only allowed to become active when the neighboring legs (e.g. leg3 and leg0 in the case of legl) are down. Actually, we noticed that not all of the behaviors learn that both of the neighboring legs have to be down. If for example leg0 and leg4 learned not to be active at the same time as leg2, then leg2 doesn’t have to learn how to avoid negative feedback, because its two neighbors are taking care of the coordination problem. In a second experiment, which has been demonstrated in simulation (it is therefore difficult to compare the re- sulting convergence times), six swing-backward behaviors were added. The robot now also had to learn that only certain behaviors are relevant for receiving positive feed- back (in the first experiment, positive feedback didn’t play much of a role, because every behavior was corre- lated to positive feedback under all conditions). More specifically, the robot had to learn that even though the swing-leg-backward behaviors do not cause negative feed- back to be received (when coordinated), they should never become active because they are not correlated to positive feedback. In our simulation, the “non-relevant” swing- backward behaviors slowly die out, because they are not correlated to positive feedback. Their probability of be- coming active gradually goes down, so that they have less opportunities to find out what the conditions are under which they can minimize negative feedback. Most of them “die out” before they are able to find the optimal list of preconditions so as to avoid negative feedback. The gait that emerges in the experiments is the ttipod gait, in which alternatively 2 sets of 3 legs are simultr+ neously swung forward. As reported by Wilson (Wilson, 1966) and confirmed in simulations by Beer (Beer, 1989), the gait that emerges in a distributed g-legged walking creature is an emergent property of the time it takes to push a leg backwards during the “stance phase”. One of the experiments we are working on right now is to try to obtain different gaits as a result of varying the speed of the stance phase and by disconnecting one of the legs at run time. The circular monitoring scheme should take care that the behaviors can adapt to this new situation and modify their precondition lists accordingly. Another ex- periment we are currently working on is to make Genghis learn to walk backward, by adding a switch which inverts the movement feedback. for one or zero conditions at the time. As a consequence our algorithm is less computationally complex. Drescher’s algorithm would not be usable in real time. A second im- portant difference is that the algorithms are concerned with different learning tasks. In Drescher’s case the task is to discover the regularities of the world when taking actions (a condition-action-effect kind of representation of the world is built up), while in the work presented here the only things learned are the conditions which optimize positive feedback and minimize negative feedback. Our system evolves towards a task-dependent (goal-oriented) solution, while in Drescher’s case, generally useful knowl- edge is built up. There is further also some relation to Classifier Sys- tems and Genetic Algorithms (Holland et al., 1986) (for an application to control problems cfr. (Greffenstette, 1989)). The main difference is that our learning technique is basically constructivist, while theirs is selectionist. In our algorithm the right representations are built up (in an incremental way) instead of being selected. An advan- tage is that our algorithm is faster because it does not perform a “blind”, unstructured search. It further also uses memory more efficiently because there is no duplica- tion of information (all the information about one action is grouped in one behavior) and because we only moni- tor/explore a certain condition when there is a need for it (the behavior is not reliable yet). Finally, the problem studied here is related to a class of algorithms called Reinforcement Learning Algorithms (Sutton, 1984)(Sutton, 1988)(Sutton, 1990)(Kaelbling, - 199O)(also related are (Narendra & Thathachar, 1989) and (Berry & Fristedt, 1985)). The main differences are that (i) the algorithm discussed here is distributed and parallel: several actions an be taken at once, and asyn- chronously (this is even crucial to learn the tripod gait, for example), (ii) this algorithm is action- oriented, whereas’ reinforcement learning algorithms are state-oriented (util- ity functions are associated with states, while here rel- evance and reliability are associated with actions) and (iii) here feedback is binary and dual (positive and nega- tive), whereas in reinforcement learning the utility func- tion is real valued (both have advantages and disadvan- tages: the former’s advantage is that positive and nega- tive goals/feedback are treated separately, while the lat- ter’s advantages is that there is a more gradual evalua- tion). Conclusion and Future Work We have developed a learning algorithm which allows a Related Learning Work behavior-based robot to learn when its behaviors should become active using positive and negative feedback. We tested the algorithm by successfully teaching a g-legged This work is related to Drescher’s PhD thesis on “trans- robot to walk forward. In future work we plan to test the lating Piaget into LISP” (Drescher, 1989). The main dif- generality of the algorithm by doing more experiments ferences are: that our behaviors (corresponding to his with the same and different robots for different tasks and “schemas”) do not maintain statistics for all of the per- by studying the properties and limitations of the algo- ceptual conditions in the environment, but instead only rithm with a mathematical model. MAES AND BROOKS 801 We further plan some extensions to the algorithm, the first one being the addition of a mechanism to deal with delayed feedback (or learning action sequences). Three possible solutions to this problem will be investigated: (i) the usage of some Bucket Brigade Algorithm or Temporal Difference method (Sutton, 1988) (Holland et al., 1986), (ii) the extension of the perceptual condition vector with conditions representing the past actions taken and (iii) composing actions into macro-actions (so that feedback is still immediate for such an action sequence). Brooks R.A. (1990) Elephants don’t play chess. In: P. Maes (ed.) Designing Autonomous Agents, Bradford- MIT Press, in press. Also: special issue of Journal of Robotics and Autonomous Systems, Spring ‘90, North- Holland. Donner M.D. (1987) Real-time control of walking. Pro- gress in Computer Science series, Vol. 7, Birkhauser, Boston. Drescher G.L. (1989) Made-Up Minds: A Constructivist Approach to Artificial Intelligence, PhD Thesis, Depart- ment of EECS, MIT. Acknowledgements Greffenstette J.J. (1989) I ncremental learning of control strategies with genetic algorithms. Proceedings of the - Sixth International Workshop on Machine Learning, Mor- gan Kauftnann. Grinell Moore did most of the mechanical design and fabrica- tion of Genghis. Cohn Angle did much of the processor design Holland J.H., Holyoak K.J. Nisbett R.E. and Thagard and most of the electrical fabrication. Olaf Bleck built the P.R. (1936) Induction: Processes of inference, learning sensors providing positive and negative feedback and replaced and discovery. MIT-Press, Cambridge, MA. the broken servos every time our buggy programs “tortured” Kaelbling L. (1990 Learning in embedded systems, PhD the robot. Leslie Kaelbling, Maja Mataric and Paul Viola thesis, Stanford c, omputer Science Department, forth- provided useful comments on an earlier draft of this paper. coming. Richard Lathrop and David Clemens helped with the statis- Maes P. (1990) Situated agents can have goals. In: P. tics. Maes (ed.) Designing Autonomous Agents, Bradford- Supported by Siemens with additional support from the MIT Press, in press. Also: special issue of Journal of University Research Initiative under Office of Naval Research Robotics and Autonomous Systems, Spring ‘90, North- contract N00014-86-K-0685, and the Defense Advanced Re- Holland. search Projects Agency under Office of Naval Research con- tract N00014-85-K-0124. The first author is a research as- Narendra K, and Thathachar M.A.L. (1989) Learning Au- tomata, an Introduction. Prentice Hall, New Jersey. sociate of the Belgian National Science Foundation. She cur- rently holds a position as visiting professor at the M.I.T. Ar- Payton D.W. (1986) A n architecture for reflexive autono- tificial Intelligence Laboratory. mous vehicle control. IEEE Robotics and Automation Conference ‘86, San Francisco. Rosenschein S.J. and Kaelbling L. (1986) The synthesis Bibliography of digital machines with provable epistemic properties, in Joseph Halpern, ed, Proceedings of the Conference on Theoretical Aspects of Reasoning About Knowledge, Anderson T.L. and Donath M. (1988) A computation- Montereyv CA’ al structure for enforcing reactive behavior in a mobile Schlimmer J.C. (1986) Tracking Concept Drift, Proceed- robot. In: Mobile Robots III, Proc. of the SPIE confer- ings of the Sixth National Conference on Artificial Intel- ence, Vol. 1007, Cambridge, MA. ligence ‘86. Angle C.M. (1989) Genghis, a six-legged autonomous walk- Sutton R. (1984) Temporal credit assignment in rein- ing robot. Bachelors thesis, Department of EECS, MIT. forcement learning. Doctoral dissertation, Department of Computer and Information Science, University of Mas- Arkin R. (1987) Motor schema based navigation for a sachusetts mobile robot: An approach to programming by behavior. Amherst . IEEE Conference on Robotics and Automation ‘87. Sutton R.‘(I988) L earning to predict by the methods of Beer R.D. (1989) Intelligence as Adaptive Behavior: An Temporal Differences. Machine Learning Journal, Vol. 3, g 44 Experiment in Computational Neuroethology. Techni- - * cal Report 89-118, Center for Automation and Intelligent Sutton R. (1990) Integrated architectures for learning, Systems Research, Case Western Reserve University. planning and reacting based on approximating dynamic . Berry D.A. and Fristedt B. (1985) Bandit problems: Se- programming’ Proceedings of the Seventh International quential allocation of experiments. Chapman and Hall, Conference on Machine Learning. London. Wilson D.M. (1966) Insect walking. Annual Review of Brooks R.A. (1986) A robust layered control system for a Entomology, 11: 103-121. mobile robot. IEEE Journal of Robotics and Automation. Yamaushi B. (1990) Independent Agents: A Behavior- Volume 2, Number 1. Based Architecture for Autonomous Robots. Proceedings Brooks R.A. (1989) A robot that walks: Emergent be- of the Fifth Annual SUNY Buffalo Graduate Conference havior from a carefully evolved network. Neural Compu- on Computer Science ‘90, Buffalo, NY. tation, l(2). Zhang, Y. (1989) Transputer-based Behavioral Module Brooks R.A. (1989b) The behavior Language; User’s - for Multi-Sensory Robot Control. 1st International Con- Guide. Implementatron Note. AI-laboratory, MIT. ference in Artificial Intelligence and Communication Pro- cess Architecture ‘89, London, UK. 802 MACHINE LEARNING
|
1990
|
147
|
901
|
Empirical Studies on the Speed of Convergence of Neural Network Training using Genetic Algorithms Hiroaki Kitano Center for Machine Translation Carnegie Mellon University Pittsburgh, PA 15213, U.S.A. hiroaki@cs.cmu.edu Abstract This paper reports several experimental results on the speed of convergence of neural network train- ing using genetic algorithms and back propaga- tion. Recent excitement regarding genetic search lead some researchers to apply it to training neu- ral networks. There are reports on both success- ful and faulty results, and, unfortunately, no sys- tematic evaluation has been made. This paper re- ports results of systematic experiments designed to judge whether use of genetic algorithms provides any gain in neural network training over existing methods. Experimental results indicate that ge- netic search is, at best, equally efficient to faster variants of back propagation in very small scale networks, but far less efficient in larger networks. 1 Introduction Genetic algorithms are an efficient searching method inspired by the principle of natural selection. There are a few studies on the efficiency of search by genetic algorithms, including a few reports applied to neural network training [Montana and Davis, 19891 [Whitley and Hanson, 19891, and some reports claim that genetic algorithms are more efficient than back propagation [Montana and Davis, 19891. However, it is con- troversial whether application of genetic algorithms to train neural networks can be an efficient alternative to gradient- descent methods such as back propagation. One cause for this confusion is that we have not seen any systematic in- vestigation of the efficiency of neural network training using genetic algorithms. In [Whitley and Hanson, 19891 there are reports that show convergence characteristics change if population size changed or an adaptive mutation method was used, but no comparison has been made as to whether their method pro- vides any faster convergence than back propagation or its variants. [Montana and Davis, 19891 reported that training using genetic algorithms was substantially faster than back propagation. However, lack of description on the specific back propagation method and its parameters, and inaccess- ability to their task domain made their experiments unrepli- cable by other researchers. This paper is, perhaps, the first attempt to systematically evaluate the efficiency of genetic algorithms for neural net- work training. The goal of our experiments is to draw an overall picture as to relative strengths of back propagation and genetic algorithms for neural network training, and to evaluate the speed of convergence of both methods. We de- signed our experiments to be replicated by other researchers so that our report could serve as a common forum for dis- cussion to resolve this issue. For this purpose, we decided to use the XOR problem, various scales of encoder/decoder problems, and the two-spirals problem as tasks by which we evaluate the speed of convergence. Of course, we recognized the need to assess this with large and real-world domains, and thus we also conducted experiments in phoneme recognition tasks. However, reports from such a domain are not repli- cable by other researchers because the training data and the network for the task are not easily accessible. Thus, we re- port our experiments from the XOR, various encoder/decoder problems and the two-spirals problem which, at least, serve as a starting point for further systematic evaluations. Although there are applications of genetic algorithms for neural network designing as seen in [Miller et. al., 19891 [Harp et. al., 19891 and [Stork et. al., 19901, we focus on weight training in this paper. This is because neural network designing tasks can be subsumed by weight training where weight values in a specific value range or connectivity bits represent unconnected links. This view is biologicallyplausi- ble since real connection strengths between neural groups can be determined by the distribution of cell and substrate adhe- sion molecules (CAMS and SAMs)[Edelman, 19871. Com- putationally, convergence characteristics of weight training and configuration design have similar property since the only differences between them is the size of search spaces. This paper has three parts. First, we examine character- istics of genetic algorithm-based weight training using the XOR problem. As we will describe later, we found that simple use of genetic algorithms for neural network would generally be outperformed by back propagation. Second, we propose and examine the GA-BP method as a remedy for the problem of local search. The GA-BP method combines genetic algorithms and back propagation to offset problems of local search. We found that the GA-BP method consis- tently converges faster than genetic algorithms alone. Here, we found that as network size gets bigger, convergence of genetic algorithms degrades to the extent that even the GA- BP method underperforms back propagation and its faster variants. The third part of the paper is central. We ex- KITANO 789 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. amine convergence characteristics using various scales of encoder/decoder problems and the two-spirals problem to examine whether genetic algorithms converge faster than back propagation in its early stages of training. While the weakness of genetic algorithms in local fine-tuning is obvi- ous, although this problem was circumvented in the GA-BP method, the speed of convergence in the early stages of train- ing is the critical factor in evaluating their utility as a method of training neural networks. 2 Genetic Algorithms: Overview Genetic algorithm is a kind of stochastic search process that starts from a set (or a population) of finite string represen- tations, called chromosomes, each of which maps a possi- ble solution to the problem. Given an evaluation function, a reproduction probability for each chromosome is assigned based on the fitness of that chromosome. Chromosomes with higher fitness values will have higher reproduction probabili- ties. This simulates the survival of the fittest. Two operations are performed stochastically: crossover and mutation. The crossover operation chooses two chromosomes from a cur- rent population as parents, and reproduces descendants by mixing chromosomes. Since this is a probabilistic process, and not all chromosomes are crossovered, a parameter called a crossover parameter defines probability. Mutation is the random change of an element of a chromosome. As a result, a new population is formed as a descendant of the current population. The next generation will be formed by going through evaluation, crossover, and mutation processes. For detail, refer to [Goldberg, 19891. In our experiments, each chromosome represents a distri- bution of weights of each network. Thus, a population of chromosomes is a population of neural networks with differ- ent weight distributions. Since we employ a real value encod- ing, a chromosome is a list of real values each of which maps onto a connection weight. We expect chromosomes which represent highly optimized weight distribution to dominate the population through genetic search processes. 3 Problems of Genetic Algorithms for Neural Network Training There are two major problems in applying genetic algorithms to training neural networks: weakness in fine-tuned local search, and a trade-off between population size and speed of convergence. The weakness of genetic algorithms in performing fine- tuned local search is widely recognized. Although genetic algorithms exhibit very fast convergence to a point of approx- imate solution in a search space, a genetic algorithm itself does not entail a mechanism for local fine-tuning as seen in back propagation. when a population reaches a state where it is dominated by the best chromosome, finding a better so- lution must depend upon mutations. This would result in very inefficient search. We have confirmed this problem by training a neural net- work with a genetic algorithm. In figure 1, movements of sum square error are shown for back propagation, a serial genetic Total Sum Square Error 4 . 1.0 - * - . . 0.8 - serial Genetic Algorithm 0.6 . Figure 1: Convergence of GA- and BP-based training algorithm, and a parallel genetic algorithm. Although genetic algorithms successfully reduce the error measure at the begin- ning of the training, the speed of convergence was drastically decreased in searching for a near-optimal solution. Eventu- ally, back propagation outperformed genetic algorithm-based training. This characteristic of genetic algorithms would not be a problem when the required converge criteria of the error measure is relatively high, but this assumption is often not the case. One way to solve this problem is to have a larger popu- lation. [Whitley and Hanson, 19891 reported that an error measure was reduced to 0.0025 in the XOR problem using populations of 100 and 200, but not with a population of 50. We have also confirmed these results. However, the problem of using a larger population is that it requires exten- sive computation for each generation, and, even though the outcome converges into an optimal solution in a few gener- ations, genetic algorithms using large populations would be outperformed by back propagation. 4 Combining Genetic Algorithms and Back Propagation: The GA-BP Method We propose the GA-BP method as a remedy for this prob- lem. In the GA-BP method, neural networks are trained in two stages. First, genetic algorithms train weights and biases of nodes to locate a point in a weight-bias space which is close to the optimal solution. Then, back propagation starts from that point, and conducts an efficient local search. This combination would be an efficient method of training neu- ral networks because it takes advantage of the strengths of genetic algorithms and back propagation (the fast initial con- vergence of genetic algorithms and the powerful local search of back propagation), and circumvents the weaknesses of the two methods’ (the weak fine-tuning capability of ge- netic algorithms and a flat spot in back propagation). Since the problem of weak fine-tuning capability has been circum- vented by employing back propagation for local search, the ‘Ideas of combining local search methods with genetic algo- rithms are not new. It has been discussed in literatures such as [Grefenstette, 19871 and [Ackley, 19871. 790 MACHINE LEARNING central issue is whether the speed of convergence of genetic algorithms outperforms the speed of convergence of back propagation in locating a point near the solution. 4.1 Experimental Settings We have tested the GA-BP method using the XOR prob- lem and the 4-2-4 encoder/decoder problem. For the XOR problem, we used the 2-2- 1 feedforward network. In genetic algorithms, we represent the network with an array of floating point numbers, each of which corresponds to weights and biases. At the initialization, these floating point numbers are randomly generated in the range of f5.0, and follow a simple distribution. For the XOR problem and the 4-2-4 encoder/decoder problem, we assigned higher proba- bility in the range from +2.5 to +5.0, and from -2.5 to -5.0. A range from +2.5 to -2.5 has a lesser chance of being gen- erated. This distribution of initial values was decided based upon heuristic observation of weights and biases in the final state of the networks, and adjusted for each network. It is important to ensure that the optimal value of weights and biases is covered by the range of initial distribution. The size of the population is 50 unless otherwise stated. To evaluate the fitness of each chromosome, feedforward computation is performed by presenting patterns which consist of one epoch. Total sum square (TSS) error is used as an error measure. The fitness of a chromosome is: fitness = 1/TSS2. Reproduction strategy is a proportional reproduction which normalizes fit- ness, and assigns higher reproduction probability for higher fitness chromosomes. In addition, we introduced an elitist re- production which always chooses the two best chromosomes and simply copies them, without crossover or mutation, to the population of the next generation. Crossover is either a single crossover or multiple crossover (two point or more) with a probability of 50.0%. Mutation probability is 5.0% for a static mutation unless otherwise stated. For an adap- tive mutation, the value changes depending upon a similar- ity of paired chromosomes. For this experiment, we used two-point crossover, adaptive mutation, proportional repro- duction based on a fitness measure, and elitist copy strategy. After training by the genetic algorithm is completed, the best chromosome is sent to a back propagation module. The genetic algorithm stage was terminated when total sum square error was reduced to less than 0.6. This is because for chromosomes whose error measure is higher than this figure, significant numbers of trials did not converge. We used a standard back propagation as defined in [Rumelhart, Hinton and Williams, 19861. Learning parameters were default val- ues of [McClelland and Rumelhart, 19881. The learning was judged to have converged when the TSS measure went below 0.04 unless otherwise specified. The continuous weights up- date mode was used which conducts error back propagation after each presentation of the pattern. For back propagation, the initial values of weights and biases were randomly gener- ated within a range f 1 .O, instead of f5.0. This is because if we generate initial weights and biases with a range of f5.0, more than 30% of the trials do not converge. We have also used a quickprop, a faster variant of back propagation, proposed in [Fahlman, 19881. Quickprop is Total Sum Square Error 1.0 0.8 0.6 0.4 02 50 100 150 200 250 computaticm cc&3 (Cycle) Figure 2: Convergence of GA-BP and BP only methods known to be the fastest variation of back propagation at present. For quickprop, we used default parameters de- scribed in [Fahlman, 19881. In measuring computational costs, we counted one evalu- ation in a genetic algorithm as l/2 an epoch of back propaga- tion because the evaluation of TSS does not involve the er- ror back propagation process; only feedforward is involved. Thus, evaluating one generation consisting of 50 chromo- somes is considered to be equal to 25 epochs in back propa- gation. 4.2 Experimental Results We ran the standard back propagation (BP), quickprop with hyper error (QP-Hyper), quickprop with sum square error (QP-Sum), serial GA-BP with varying population size (GA- BP-50 and GA-BP-20), and parallel GA-BP with varying threshold value (PGA-BP-O.6 and PGA-BP-0.3). For each learning method, we ran 20 trials, and the average value and standard deviation was computed to compare the speed of convergence and the stability of the method. The result is shown in table 1, and typical convergence curves for parallel GA-BP, serial GA-BP, and standard back propagation are shown in figure 2. ECC is an expected convergence cycle, and STD is a standard deviation. In table 1, an experimental set of GA-BP-50 was con- ducted with a population size of 50, and an experimental set of GA-BP-20 with a population size of 20 was conducted, but with a very high mutation probability (50.0%). We used a relatively small population because the GA-BP method does not require a genetic algorithm-based process to converge into a very low sum square error measure. We only require it to converge down to 0.6. To this level of error measure, in the XOR problem, smaller populations converge faster than larger populations. It should be noted that for trials by quickprop 45% of the trials using sum square error, and 29% of trials using hyper error function did not converge within pre-decided limitations. These trials had to be restarted and numbers of iteration for unconverged trials were added to the total computation cost. PGA-BP-O.6 and PGA-BP-O.3 are parallel GA-BP methods with thresholds of stopping ge- netic algorithms of 0.6 and 0.3 in total sum square error, respectively. We also found that the threshold value of 0.6 KITANO 791 QP (Sum) GA-BP-50 GA-BP-20 PGA-BP-O.6 PGA-BP-03 ECC STD 285.8 90.9 91.9 60.9 226.6 123.6 130.9 72.4 100.5 37.5 33.1 4.6 46.7 28.2 Table 1: Results from the XOR problem Table 2: Results from the 4-2-4 encoder/decoder problem converges faster than the 0.3 setting. This is due to the fact that the genetic algorithm slows down its convergence speed if it needs to fine-tune weights and biases, and the speed of convergence of the back propagation process is not signifi- cantly reduced even if it starts from 0.3 of the TSS measure. Next, we carried out experiments with the 4-2-4 en- coder/decoder problem. In the genetic algorithm stage, it took an average of 58 generations to converge to 0.6 sum square error with a population size of 200. Trials with a population size of 50 did not converge to 0.6 within 200 gen- erations. In table 2, we show the results of 10 trials. Data for back propagation is the average of the trials which converged: almost 20% of trials did not converge within 1500 cycles and these trials were simply ignored. The convergence criteria was 0.16 in TSS allowing 0.01 TSS error for each output unit per pattern. In the 4-2-4 encoder/decoder problem, the GA-BP method was outperformed by quickprop. There are two possible explanations for this. First, the threshold to stop genetic algorithms is too low for this task so that efficiency was lost at the plateau. The second possibility is that quickprop is faster even in the initial search of near-optimal points. If the latter is the case, use of genetic algorithms for neural network training could generally be concluded to be inefficient compared to faster variants of back propagation. In the following section, we describe our experiments to critically test whether genetic algorithms can converge faster in the initial stage of training. 5 Scaled Up Experiments In order to examine the possibility that quickprop could be faster than genetic algorithms even in initial stage of train- ing, we have conducted a series of experiments on the en- coder/decoder problems ranging from 2-2-2 to 16-4-16 and the two-spirals problem. Chromosome length for these ex- periments ranges from 11 to 165 for encoder/decoder prob- lems, and 138 for the two-spirals problem. Experimental settings are the same as stated in the previous section. Since TotalSumSquareFirmx 10.0 R: ,/ 6416 7.5 /lo-s-10 - J 2.5 Figure 3: Total sum square error with GA-based training 10,ooo 3o.m Figure 4: Percentage of total sum square error against maxi- mum potential error we are going to compare genetic algorithms with a quick- prop which is an optimized version of back propagation, we have also optimized genetic algorithms using multi-point crossover, and an adaptive mutation rate method. Although these methods improved performance of genetic algorithms, its effects were not significant enough to alter the essential results of our experiments. 5.1 The Encoder/Decoder Problems The encoder/decoder problems are one of the standard bench- marks for neural network learning algorithms. An “N-M-N encoder/decoder” means a network of three-layers with N units for input and output layer and M units for a hidden layer. The network is given with N distinct input patterns, each of which only one bit is turned on, and all other bits are turned off. The network should duplicate the input pattern in the output units. Figure 3 shows total sum square error for each task plotted along with numbers of reproductions required 2. These are expected values averaged over 10 trials each. Clearly, TSS measure degrades as the size of the network increases. Figure 4 shows the percentage ratio of TSS compared to maximum potential TSS error. It should be noticed that the size of the network did not alter the speed of convergence 2For a population consists of 50 individuals, evolving one gen- eration requires 50 reproductions, for most cases, involving re- combination and mutation. Thus, 10,000 reproduction means 200 generations with a population of 50 individuals. 792 MACHINE LEARNING Tasks 2-2-2 3-2-3 I 4-2-4 8-3-8 10-5-10 16-4-16 Chromo. Length Max. Error GA QP 14 4.0 133 8.8 20 9.0 2950 9.2 26 16.0 3800 9.6 67 64.0 2800 9.7 125 100.0 1150 2.4 164 256.0 1950 7.2 Table 3: Convergence speed to 10% of MPE Remaining points to learn Genetic Algorithm I I I ) 1000 2000 3000 Cycle Figure 5: Results from the two-spirals problem measured by percentage bases, except with very small size networks such as the 3-2-3 problem and the 2-2-2 problem which converged into very low error measure. Table 3 shows expected numbers of reproductions for ge- netic algorithms to converge at 10% of the maximum poten- tial error (MPE). Length of the chromosome does not seem to have a strong correlation with the speed of convergence, but, again smaller networks such as the 2-2-2 problem converge much faster than in other tasks. Expected convergence cy- cles for quickprop to converge at 10% of the maximum error are shown. Quick prop was run with sum square error, not with hyper error which is faster than with sum square error, and still converged much faster than genetic algorithms. In addition, substantial numbers of trials from points specified by genetic algorithms were trapped in the local minima when the error measure of the point which stops genetic algorithm stage was more than 10% of the maximum potential error. 5.2 The lko-Spirals Problem The two-spirals problems is a task that, for each 194 training points belonging to one of two interwined spirals, a network must tell in which spiral a given point belongs to. This is a hard task for a back propagation due to its complicated error landscape. We use a training point generation program and a network described in [Lang and Witbrock, 19881. The network is a five-layered fully connected configuration with short cut connections. The network consists of 19 nodes and, counting threshold of each node, there are 138 trainable weights. In figure 5, plots of average numbers of points remain to be learned from 10 trials are shown. Although the task is extremely non-linear, quickprop outperforms GA-based training. For this experiment, network parameters used are the same as [Lang and Witbrock, 19881. A population size for GA-based training is 50. Adaptive mutation and mul- tiple crossover are used. Change in population size, muta- tion rate, number of crossover points and its probability, and initial weight distribution did not alter basic results of the experiments. 6 Discussions In essence, our experiments demonstrated the following three points: o Although genetic algorithms converge efficiently at the initial stage, the speed of convergence is severely under- mined later due to its weak local fine-tuning capability. f~+ Use of gradient-descent procedure, such as back propa- gation, from the point specified by a chromosome gen- erally provides faster convergence than starting from points determined at random. * Speed of convergence of genetic algorithms for larger networks is very slow, and the point of convergence is shifted upward. Thus, substantial numbers of trials for back propagation from these points ran the risk of being trapped by local minima. One clear message from our experiment is the need for faster convergence methods of genetic algorithms. Although weakness of local fine-tuning can be overcome by combining a gradient-descent scheme, such as back propagation, and a genetic algorithm as seen in the GA-BP method, if genetic al- gorithms’ initial convergence is slower than gradient-descent schemes, the utility of the genetic algorithm can hardly be seen. Unfortunately, for a range of problems we have tested here, this was the case. Convergence of genetic algorithm based neural network training was so slow that it was consis- tently outperformed by quickprop. Varying parameters such as mutation rate, crossover rate, and population size, or the introduction of faster convergence *methods, such as adap- tive mutation and multipoint crossover, made only limited contributions in reversing the results. However, it should be noted that our experiments were conducted only on relatively small tasks with rather simple error landscapes. It is conceivable that for this class of prob- lem, a gradient-descent method works very efficiently. This is especially true for encoder/decoder problems. But, this may not be the case where the error landscape has many local minima and pathetic curvature so that the speed of conver- gence of the gradient-descent method degrades substantially, and even runs a high risk of being trapped in the local minima. For this class of tasks, genetic algorithms may have a rea- sonable chance of outperforming even faster variants of back propagation. In fact, [Ackley, 19871 reports genetic algo- rithms have a better chance of outperforming hillclimbing on tasks with many local mimina. However, it should be noticed that our experiments include the two-spiral problems which is expected to be hard for gradient-descent methods. The fact that GA-based training was outperformed by quickprop even KITANO 793 Figure 6: Distribution of parent chromosomes in the two-spirals problem indicates that existence of strong non-linearity itself is not a sufficient condition to judge that the task is suitable for the GA-based training. We are cur- rently investigating whether the GA-BP method outperforms faster variants of back propagation in the real-world domain - phoneme recognition with time-delay neural networks. It is conceivable, however, that such a task as weight training of neural network is not a good task for genetic algorithms due to its interdependencies between regions of chromosomes. In neural network, modification of weights in a part of the network affects outcomes of other parts through activation or inhibitory links. This property of neural net- works counters to a basic idea of genetic search that a partial solution in a lower-dimensional subspace is likely to be a part of a good overall solution. Thus, combining good chromo- somes does not necessarily results in a better chromosome. It is an interesting question to ask to what extend a composi- tionality of solution is kept or disturbed in the neural network training task. In order to quantitatively analyze contribution by good partial solutions, we took statistics of ranking distri- bution of parents which created the best chromosome in each generation. In the figure 6, rank-based distribution of par- ents which created the best chromosome in each generation is mapped. This distribution is taken from one of the runs for the XOR problem. If a partial solution is likely to be a part of an overall good solution, there should be strong bias of distribution toward high ranking (lower half of the graph) chromosomes. 59.3% of the parents are within the top 25 range in rank3. Dis- tribution between the range from 26th to 100th was almost uniformal. Obviously, we have statistically significant bias toward higher ranking parents, although almost 40% of con- tribution comes from not-so-high ranked parents. However, since we are using the proportional reproduction rule, which is 1/TSS2, the above figure does not answer the question whether higher ranking chromosomes has a better chance of contributing to optimization. We would further analyze this by measuring an efj’ective reproduction rate. The efective reproduction rate is a ratio of reproduction which created the best chromosome out of an entire reproduction. 3This exclude the dead copy of the best chromosome of the pre- vious generation, because it merely shows any new recombination did not gain better fitness than existing one’s - only the parents of chromosomes which updated the best fitness should be counted. Range 2- 25 26 -50 51-75 76- 100 XOR 0.15 0.11 0.05 0.09 Linear Bits 0.47 0.11 0.11 0.07 Table 4: Effective reproduction rate Table 4 show the effective reproduction rate for each range of chromosomes in the XOR problem and a linear bits prob- lem. The linear bits problem is a task that for N-length bit string, obtain a string with maximum numbers of bits on. Thus, in this problem partial solution is always a part of a better overall solution. In the XOR problem, although there is a statistically significant bias toward high ranking chro- mosomes (0.15%), there is substantial contribution from low ranking chromosomes. The linear bits problem is more de- pendent upon high ranking chromosomes (0.47%). It seems that a strong interdependency of the neural network task suppresses an effective reproduction rate of high rank chro- mosomes, thus overall speed of convergence is slower than that of weak- or non-interdependent tasks. It should be noticed that successful reports on applications of genetic algorithms come mostly from the tasks having the compositional property assumed in the genetic algorithms. From this aspects, using genetic algorithms for neural net- works design would be more promising than weight training because well-formed local circuits are expected to be a part of more functional structure. The fact that genetic algorithms are not capable of conduct- ing local fine-tuning has interesting biological implications. Supposing our somatic system exhibits similar characteris- tics, it is computationally plausible that genetically encoded information on neural circuitry and connectivity is not suffi- cient to create an optimally tuned neural system. First, the fact that genetic algorithms alone are not capable of precisely determining weights of networks indicates that some gradient-descent type or equivalent learning scheme is needed. By the same token, genetic algorithms may not be able to fully optimize a network even in neural network design tasks. A need for a supplementary scheme for fine- tuning is clear. Second, however, simply combining genetic algorithms and local fine-tuning may not provide sufficient optimization. We might have to insert a more flexible scheme for adapta- tion in between genetic search and local gradient-descent search scheme. This can be concluded from two facts: (1) degradation of convergence of genetic algorithms on larger scale problems, and (2) many trials from points specified by genetic algorithms, in these degraded cases, are trapped in the local minima. Fortunately, our neural system has such mechanisms. One is a scheme such as that modeled on the theory of neural group selection or neural darwinism [Edelman, 19871, and the other is synaptic weight modification and plasticity. As- suming that our experimental results could be considered as being a simpler, but analogical simulation of evolution and development of the brain, a cascaded scheme of natural se- lection, adaptation, and learning is a necessary consequence for survival. 794 MACHINE LEARNING 7 Conclusion In this paper, we have reported results of systematic exper- iments designed to compare the speed of convergence for training neural networks using genetic algorithms and gradi- ent descent methods. At the outset of this paper, we pointed out that simple application of genetic algorithms would be outperformed by back propagation due to its weak local fine- tuning capability and computational cost for evaluating num- bers of chromosomes in one generation. Thus, instead of directly comparing genetic algorithms and back propagation, we have compared the GA-BP method and quickprop, both of which are faster methods of training neural networks. As a rationale for using the GA-BP method, we have shown briefly that the GA-BP method converges consistently faster than genetic algorithms alone. However, experimental re- sults using the XOR and the 4-2-4 encoding/decoding prob- lems revealed a possibility that the scaling property of genetic algorithms is not desirable for training larger networks even in the initial stage of convergence. Thus, the critical test should examine whether genetic algorithms converge faster than back propagation and its faster variants in the initial stage of training. Experiments with various scales of the encoder/decoder problems range from 2-2-2 to 16-4-16 and the two-spiral problem. As a result of these experiments, we discovered that the scaling property of genetic algorithms is undesir- able for neural network training. Although the performance largely depends upon the error landscape and evaluation func- tions used, degradation of performance was so significant that even the parallel GA-BP method underperformed quick- prop. Also, asymptotic convergence curves indicate genetic algorithms require far greater numbers of recombination to converge to desired error criteria compared to the quick- prop. On the other hand, we have a report by [Montana and Davis, 19891 indicating that neural network training by ge- netic algorithms converge much faster than training by back propagation. This conflict needs to be resolved by carrying out fair and well controlled experiments. As discussed in the previous section, from the scope of our experiments, we reached the conclusion that: Dramatically faster methods of convergence need to be discovered for genetic algorithms to be used as an effi- cient alternative to faster variants of back propagation. The neural network training task was cornfirmed to have a less compositional feature - combinations of good partial solutions do not necessarily create a better overall solution. Thus, the speed of convergence of genetic algorithm-based training was significantly undermined. The relation between the convergence speed of genetic algorithms and back propagation against various classes of error landscape needs to be systematically investi- gated to identify cases where genetic algorithms perform better than back propagation. By identifying classes of tasks and error landscapes which genetic algorithm based neural network training could perform better than back propagation or its faster variants, we can resolve e conflicts of results between successful and faulty re- ports, and this would lead to appropriate use of genetic algorithms for neural network training. The fact that genetic algorithms fail to converge into op- timal points in larger networks has interesting biological implications. Assuming our model simulates, even in a very simplified manner, real evolutional process, the convergence property discovered computationally sup- ports neural plasticity, such as neural group selection and weight modification, as a necessary mechanism to sustain the survival of our spices. References [Ackley, 19871 Ackley, D., A Connectionist Machine for Genetic Hillclimbing, Kluwer Academic Publishers, 1987. [Edelman, 19871 Edelman, G., Neural Darwinism: Theory ofNeu- ronal Group Selection, Basic Books, New York, 1987. [Fahlman, 19881 Fahhnan, S., An Empirical Study of Learn- ing Speed in Back-Propagation Networks, CMU-CS-88-162, Carnegie Mellon University, 1988. [Goldberg, 19891 Goldberg, D., Genetic Algorithms inSearch, Op- timization and Machine Learning, Addison Wesley, 1989. [Grefenstette, 19871 Grefenstette, J., “Incorporating Problem Spe- cific Knowledge into Genetic Algorithms,” In Davis, L. (Ed.), Genetic Algorithms and Simulated Annealing, Morgan Kauf- mann, 1987. [Harp et. al., 19891 H arp, S., Samad, T. and Guha, A., “Towards the Genetic Synthesis of Neural Networks,” In Proceedings of the Third InternationalConference on Genetic Algorithms, 1989. [Lang and Witb rock, 19881 Lang, K. and Wrtbrock, M., “Learning to Tell ‘l%o Spirals Apart,” In Proceedings of the 1988 Connec- tionist Models Summer School, 1988. [McClelland and Rumelhart, 19881 McClelland, J. L. and Rumel- hart, D. E., Explorations in Parallel Distributed Processing: A Handbookof Models, Programs, and Exercises, The MIT Press, 1988. [Miller et. al., 19891 Miller, G., Todd, P andHegde, S., “Designing Neural Networks using Genetic Algorithms,” In Proceedings of the Third International Conference on GeneticAlgorithms, 1989. [Montana and Davis, 19891 Montana, D. and Davis, L., “Training Feedforward Neural Networks Using Genetic Algorithms,” In Proceedings of International Joint Conference on Artificial In- telligence (IJCAI-89), 1989. [Rumelhart, Hinton and Williams, 19861 Rumelhart, D. E., Hin- ton, G. E. and Williams, R.J., “Learning Internal Representation by Error Propagation,” In Parallel Distributed Processing: Ex- plorations in the Microstructure of Cognition, (Eds.) Rumelhart, D. E. and McClelland, J. L., The MlT Press, 1986. [Stork et. al., 19901 Stork, D., Walker, S., Bums, M. and Jackson, B., “Preadaptation in Neural Circuits,” In Proceedings of the International Joint Conference on Neural Networks, 1990. [Whitley and Hanson, 19891 Whitley, D. and Hanson, T., “Opti- mizing Neural Network Using Faster, More Accurate Genetic Search,” In Proceedings of the International Conference on Ge- netic Algorithms, 1989. KITANO 795
|
1990
|
148
|
902
|
Theory Reduction, eory Allen Ginsberg AT&T Bell Laboratories Holmdel, NJ 07733 abgQvaxl35.att.com Abstract This paper presents an approach to retranslation, the third and final step of the theory reduction approach to solving theory revision problems [3,4]. Retranslation involves putting a modified “operationalized,” or “re- duced,” version of the desired revised theory back into the entire language of the original theory. This step is desirable for a number of reasons, not least of which is the need to “compress” what are generally very large reduced theories into much smaller, and thus, more ef- ficiently evaluated, unreduced theories. Empirical re- sults for the retranslation method are presented. Introduction and Overview A theory revision problem exists for a theory 7 when 7 is known to yield incorrect results for given cases in its intended domain of application. The goal of the- ory revision is to find a revision 7’ of ‘T which handles the set of all known cases correctly, makes use of the theoretical terms used in 7, and may, with a reason- able degree of confidence, be expected to handle future cases correctly. This paper is about retranslation: the third, and fi- nal, step of the theory reduction approach to solving theory revision problems. The first step of the ap- proach, discussed in detail in [3], is to ‘%ranslate” the theory in question into a form that is more amenable to inductive learning techniques. This may be viewed as a complete prior “operationalization” of the theory, in the sense of the term employed in explanation-based learning [7]. Th e resulting translation is called the re- duced theory because the number of distinct primitive terms employed by this theory is fewer than that of the original. In terms of the number of statements (distinct clauses or rules) it contains, however, the reduced the- ory will generally be much larger than its unreduced counterpart. The second step of the approach, pre- sented in [4], involves modifying the reduced theory in order to improve its ability to “give the correct answer” relative to the given set of cases, C, but in such a way that it is reasonable to expect improved performance over cases not included in C as well. RTLS (Reduced Theory Learning System) is the system that performs this step. Once the reduced theory has been modified to cover all the cases in C, the final step involves a “re- translation” of the modified reduced version back into the entire language of the original theory. This step is necessary/desirable for a number of reasons, one of them being the desire to “compress” what are gener- ally very large reduced theories into much smaller, and thus, more efficiently evaluated, unreduced theories. In the previously cited papers I asserted that 1) reduction of non-trivial medium-sized expert systems theories could be achieved in acceptable times, 2) good improvements in performance could be achieved by training the reduced theory using the methods dis- cussed in [4], and 3) that a method for automatic retranslation of expert system theories was known. While the first two assertions were, and still are, justi- fiable’ assertion (3), as I stated in [2], was premature: it turned out that the simple retranslation algorithm I had in mind would actually produce an egregiously overgeneralized result. My initial suspicion that re- translation would be a difficult problem, even for ex- pert system theories, was in fact correct. Thus the r&on d’etre of this paper: to present re- cent research results on the retranslation problem, and in so doing to present a sound approach for doing re- translation. First, however, after describing the prob- lem in detail in the next section, it will be shown that the notion of retranslation, properly understood, is a problem for theory revision in general, as well as other AI endeavors. Problem Statement Theory Reduction Theories posit inferential connections leading from “observable features” characteristic of some class of phenomena, to collections of theoretical terms that have explanatory and/or predictive power with respect to systems that exhibit these features. Theory reduc- tion is essentially a matter of compilation of the evi- dential relations holding between observables and the- oretical terms in a theory, and is not intended to carry the ontological or semantical connotations associated GINSBERG 777 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Table 1: Some Symbols and Terminology Defined Answer(c): the given (correct) theoretical description for case c;(may contain several t-terms). T-case: a c whose Answer(c) includes r. Non-T-case: a c whose Answer(c) does not include r. Rules-for(T): the set of rules in theory 7 that directly conclude T. Level( 7): max of the levels of Rules-for( 7) &label(T): a set of minimal environments being considered as a potential revised label for r. Endpoint: a t-term that does not occur in the antecedent of any rule. RTLS-label(T) the label generated for endpoint r by the RTLS system Label(e): the set of minimal environments generated by calculating the label of expression e (a conjunction of t-terms and observables), where every t-term in e has its original label or is assigned some S-label Rule-correlated-t-terms(T): the set of all t-terms occurring in some member of Rules-for(r) Rule-correlated-observables(7): the set of all observables occurring in some member of Rules-for(r) Theory-correlated-t-terms(T): the set of all t-terms that occur in any rule that is a “link” in a “rule-chain” having some rule in Rules-for(r) as the last link Theory-correlated-observables(7): the set of all observables that occur in any rule that is a “link” in a “rule- chain” having some rule in Rules-for(T) as the last link with reductionism in natural science or certain philo- sophical movements [5]. Let 7 be the theory and let the vocabulary (pred- icate symbols, propositional constants, etc.) of 7 be divided into two disjoint subsets 7, and z. We refer to these as the observational (operational) and theoreti- cud (non-operational) vocabulary of 7, respectively [8]. Let r be a member of It, and let 01 . . . ok be a conjunc- tion of distinct items where oi E 7, for i = 1, . . . , L. Suppose that the statement 01 . . . ok ---) r follows from 7. Moreover, suppose that if any conjunct is removed from or . . . ok this would not be the case. Then 01 . . . ok is a minimal sufficient purely observational condition for r relative to 7. Now let 0, represent the set of all conjunctions 01 . . . ok such that or . . . ok is a minimal sufficient purely observational condition for r relative to 7. Then 0, is the called the reduction of r with re- spect to lo. Following the terminology of de Kleer [l] 7 we sometimes call 0, the label for r, and each member of 0, is said to be an environment for r. The set of all 0, for T E x7 denoted by R(I), is called the reduction of the theory 7. Reduction of Expert System Theories We consider an expert system theory & to be a restricted propositional logic theory. That is, & consists of a set of conditionals in propositional logic, i.e., the rules or knowledge base. A sentence a + 0 is considered to follow from E iff, to put it loosely, p can be derived from a and & via a sequence of applications of a generalized version of modus ponens. E is said to be acyclic if, roughly speaking, a sentence of the form o + cy does not follow from E. In [3] I presented a two-step algorithm for the com- plete prior reduction of acyclic expert system theories, and discussed a system, KB-Reducer, that implements the algorithm. In the first step the rules in E are par- titioned into disjoint sets called rude levels. A rule r is 778 MACHINE LEARNING in level 0 iff the truth-value of the left-hand side of r is a function of the truth-values of observables only. A rule r is in level n, iff the truth-value of the left-hand side of r is a function of the truth-values of observables and theoretical terms that are concluded only by rules at levelsO,...,n- 1. This partition defines a partial- ordering for computing the reduction of all theoretical terms: each rule in level 0 is processed (exactly once), then each rule in level 1. etc. For further details see PI- Retranslation as a General Problem The subject of this paper is called ‘retranslation’ in re- lation to the aforementioned reduction process which may be termed a ‘translation’ of a theory into a form which avoids the use of theoretical terms (on the left- hand-sides of rules). In retranslation we are interested in re-expressing knowledge currently expressed solely in “low-level” observational terms, in more compact “high-level” theoretical terms. The problem of rein- terpreting/reassimilating low-level data or results in terms of high-level constructs is a key aspect of many AI problems, e.g. vision. As a concrete example in the domain of theory re- vision consider the case of Kepler’s laws of planetary motion in relation to Newton’s laws of motion (includ- ing the law of gravitation). Kepler’s laws are an ex- ample of what philosophers of science call empirical generalizations [El], i.e., statements couched solely in terms of observables, e.g., planet, elliptical orbit, sun. Newton showed that these laws are consequences of his laws of motion, which involve the theoretical notions of force and gravitational force. That is, from New- ton’s laws, together with certain necessary “auxiliary” statements, e.g., a planei is a mussive body, Kepler’s laws can be derived. Thus, if one were to reduce the Newtonian theory, one would find Kepler’s laws (or a set of more primitive statements equivalent to them) in the reduced theory. Note that this reduced theory would not contain theoretical terms such as force and gravity. The process of restating this reduced theory - which would contain Kepler’s laws and other purely observational statements - in terms of a theory that posits unobservables, is retranslation. Relaxed Retranslation While we may consider Kepler’s laws to be part of the reduction of Newton’s theory, it is not correct to sug- gest that Newton had, in any sense, the entire reduc- tion of his theory (or a variant thereof) available to him prior to its formulation in theoretical terms. New- ton’s laws entailed empirical generalizations that were not predicted and verified until well after the formu- lation of the theory. This illustrates the idea that the notion of retranslation - re-expressing something at a theoretically richer conceptual level - and the notion of generalization - formulating a more powerful version of something already known - cannot, in practice, be en- tirely divorced from one another. Thus one answer to the question, Why retranslate?’ is that this is simply another way of trying to broaden our knowledge. To help clarify the meaning and pertinence of this point of view consider the following points. In general, it is likely that a retranslation problem will start with a reduction R(7’) for a theory 7’ that is not the same as the reduction of the “ultimate desired version” of the theory. For most intents and purposes, it is reasonable to assume that this will be the case for all but very small “toy” theories. For this reason it seems foolish to insist that the retranslation process should necessarily yield a theory whose own reduction is exactly identical to the given reduction R(7’). In- stead of viewing R(7’) as an absolute constraint on the result - to be preserved at all costs - we should view it as providing guidelines on the retranslation process. We call this version of the problem relaxed retrunslu- tion. It is this version of retranslation that is most similar to the Newton-Kepler example. All that is re- quired of the generated retranslation is that its perfor- mance over the cases C be at least as good as that of R(7’). In the sequel it is this version of the retransla- tion problem that we will address. Finally, we should note a way in which the Newton- Kepler example differs from the retranslation problems addressed here. While Newton undoubtedly had some notion of force as part of the received knowledge of the time, the fact is that he really can be said to have invented this theoretical concept, and others, because he formulated precise laws that governed their use. In contrast, the retranslation problems addressed by this work always take place within the context of a set of given theoretical terms, and an initial, albeit flawed, version of the theory. As we will soon see, the struc- tural relationships among the various components of the theory - as embodied in its rules - provides cru- cial information in helping to guide the search for suit- able retranslations. Recognizing the need {utility) for {of} new theoretical terms, while a relevant avenue for future investigation, is a task that is not directly ad- dressed by the methods presented here. Retranslation As with any technical topic, one needs to introduce a certain amount of terminology in order to keep the presentation brief and precise. To make. for easier ref- erence, most of the special vocabulary used in this pa- per is defined in Table 1. A number of these ideas, in particular, the crucial notions of rule-correlated and theory-correlated observables and theoretical-terms, are illustrated in the example in Figure 1. Top-Down Retranslation Let 72 be the reduction we wish to retranslate, and let 7 be the version of the theory we were given prior to the learning session. For every endpoint r E 3 - where r is an endpoint iff it does not occur in the left-hand-side of any rule in 7 - a corresponding RTLS label, RTLS-label( 7)) will exist in R (this is the output of RTLS). Since the original theory was acyclic some endpoints must exist. In top-down retranslation we start with endpoints: for a given endpoint, r, we first try to find changes in the Rules-for(T) and in the la- beb of the theoretical terms, t-terms for short, in these rules so that the label for r generated by these changed rules and labels is either identical to, or fairly close to, RTLS-label(T). What is important is that this label generated for r - we call it a S-label - yields the same performance results over the cases as RTLS-label(T). Intuitively this process corresponds to asking the question: What would the labels of the t-terms used to conclude r - given by Rule-correlated-t-terms(r) - as well as the new Rules-for(r) have to “look like,” in order for RTLS-label(r) ( or something “close enough” to it) to be the label that the retranslated theory will generate for r ? Suppose that we have answered this question to our satisfaction: then we have succeeded in pushing, or, to borrow a phrase, “back-propagating,” the retranslation problem for T, down one level of the theory. Let X be any member of Rule-correlated-t- terms(T). Now the question is: What would the labels of the t-terms in Rule-correlated-t-terms(X) and the new Rules-for(X) have to look like in order for the S- label of X to be generated?, and clearly we have to ask this question for every X E Rule-correlated-t-terms(T), We continue to ask this question all the way down the rule levels until we reach the zeroth level. Since rules at the zeroth level make use solely of observables on their left-hand-sides’ we will know exactly what the rules at this level should look like: if r is a t-term at this level the new Rules-for(r) will come directly from the S-label(T) generated by the top-down retranslation procedure. While the general idea sounds simple enough, there are, in fact, many ways in which things can fail to GINSBERG 779 Original Theory 7 abvacvbc+q, advaeved-t fv1 - 5, h72 - 747 172 - 737 dVh--+rG, kT6 + 747 ce - 77, T-term 71 72 73 74 Label in 7 Level 72 nT3 XT7 - 5 v YT? Rule Correlated observables Figure 1 - 7s 0 abvacvbc a, b, c 0 advaevde a7d7e 1 abfg V acfgV f’d bcfg V ad1 V ael V edl 1 adh V aeh V deh V dhk h, k Endpoints of 7: RTLS-label( 74): RTLS-label( 75) : RTLS-label(Ts): 747 757 7s adeh V dhk abeln V abdln cx V cey Rule Theory Correlated Correlated t-terms observables a, b, c w&e 71, TX a, b, c, d, e7 f, g, 1 T1,72 71 72,76 2 abfgn V acfgnV n 73 bcfgn V adln V aeln V deln 0 dvh d7 h 0 ce c7 e _ 1 cex V cey Z'Y 77 go smoothly. In order to focus ideas we will look at a small, but, representative, example in some detail; Figures 1 and 2 are used to illustrate this example. We proceed on an endpoint by endpoint basis, i.e., we solve the retranslation problem for one endpoint and then move on to another. Every endpoint re- quiring retranslation, i.e., every endpoint that has an RTLS-label different from its original label in 7, will be processed once and only once. This immediately raises the question of “interactions” among endpoints that share theory-correlated t-terms. For example, in Figure 1, we see that 72 is correlated to both endpoint 74 (a rule-correlation) and 5 (a theory-correlation). If the retranslation of 74 leads to a change in label for 72 this means we have to redo the retranslation of 5, as- suming we did ~5 first. One way to avoid this problem is simply to avoid changing the labels of any t-terms that effect more than one endpoint. T-terms that are theoretically-correlated to a single endpoint are called eigen-terms of that endpoint. In Figure 1, for example, we see that 76 is an eigen-term of 74, and that ~1 and 73 are eigen-terms of 5 7 and that 77 is an eigen-term of ~6. (Analogously, ~1 is an eigen-term of 73 .) By chang- ing the labels of eigen-terms only (and by making sure that they remain eigen-terms in the final retranslation) we guarantee that no malicious interactions can occur by dividing up the retranslation problem as we have described. While this strategy can never fail, it may sometimes succeed too well, i.e., we may end up with a retranslated theory that makes less use of such non- eigen-terms than seems warranted. Ideally, one would like to modify only eigen-terms whenever possible, but when this fails to achieve good results the modification of non-eigen-terms should be considered. Bow to do so is a problem for future investigation. a7 d7 e7 h7 k 72 7 76 76 V bdeln V abfn V bcgn Theory Correlated t-terms Eigen-Terms a, h ~7 4 e7 f > g, h 1 Tl,Q, 73 T1,73 d7 h c7 e c7 e7 27 Y 77 77 Forming Interpretations Suppose that we are trying to retranslate some end- point’ or other t-term, T. This means that we have a &label(r) at this point (either RTLS-label(r) if T is an endpoint, or else the current S-label for T as deter- mined by the retranslation of the endpoint(s) to which T is theoretically-correlated). We begin by identify- ing Rule-correlated-observubles(T) and Rule-correluted- t-terms(T), where these are the observables and t-terms that occur in some rule that directly concludes T. We now try to “interpret” or “reconstruct” &label(r) by finding a set of rules for T using these items as compo- nents. That is, for each environment e = or . . . on E S- label(r), we attempt to partition the observables in e into sets corresponding to the various “contributions” that would be made by some rule containing these com- ponents. These rules are said to be interpretations of the environments that generate them. For example, in Figure 2, we see that each environment of the RTLS- label for 5 can be viewed as arising from the rule nq + 75 provided that the appropriate modifications to the label of 73 are made. In this Figure parentheses and bold-face are used to indicate the portion of the interpreted environment that is being “accounted for” by the indicated t-term. For example, in the interpre- tation n 73 (abel), abel is the portion of abeln coming from 73. There are three ac- tivities included in the interpretation-forming phase. In the first place we are generating candidates for the new Rules-for(r). The “external structure” of these rules can be identical to rules in the original theory, or they may generalize and/or specialize these rules in certain ways. In the second place we are determin- ing the content of the S-labels of the t-terms that are 780 MACHINE LEARNING used to conclude r. Consider, for example, the re- translation of 5 in Figure 2. In this case each desired environment happens to generate the same interpre- tation nr3 (which is, in fact, identical to a rule in the original theory), but each environment “impacts” a dif- ferent environment from the original label of 7-s. For example, the desired environment abeln forces a spe- cialization of the environment ael in the original label to the environment abel in the new label, while the environment bcgn forces a generalization of the envi- ronment bcfg in the original label to beg in the new label. Therefore, in the third place, we have to make sure that the new label that is generated for t-terms, 7-s in the example, accurately reflects all the changes arising from the interpretations that are, at least ten- tatively, being considered. In the current system this is achieved by obeying the following regimen. We first perform all the specialization modifications to the orig- inal label. Whenever we add a specialized environment e we must be sure to remove all the environments that are more general than e from the label. We then per- form all the generalization modifications. Finally, we re-minimize the resulting label. There are two main complications that can occur in the interpretation-forming phase. It simply may be im- possible to interpret all the environments of S-label(T) in terms of the items in Rule-correlated-observables(r) and Rule-correlated-t-terms(r). This will certainly be the case if some e E S-label(T) contains one or more observables that are not in theory-correlated- observabdes(T). In fact it is easy to know in advance whether or not theory-correlated-observables(T) will have to be aug- mented with new observables in the new theory. A simple criterion is the following: if there are two cases cl, ~2, one a t-case, and the other not, such that cl, c2 share exactly the same theoretically-correlated observ- ablesforr, then we know that we will have to make use of the other observables in these cases if we are to con- struct rules that distinguish them in the new theory. Thus the current strategy is to first find out whether or not there are such cases with respect to r in C. This is a straightforward and quick operation. The other problem in forming interpretations is the possibility of multiple interpretations. For example, consider the interpretation of the environment dhk for 74 given in Figure 2, viz., Icre (dh). If this interpre- tation is adopted the original label for 76, which was dv h, will be changed to dh. (Whenever we specialize a label by adding more specific environments to it, we must remove any more general environments from the label.) This is, in fact, the route that would be taken by the current strategy. But another interpretation of dhk is possible, viz., dhk + 7-4 could be adopted as a rule for 74, and no changes would be made to the label for 76. Note, however, that while h is rule-correlated to 74, d is only theory-correlated to 74. Adopting this interpretation, therefore, has the effect of “promoting” d to a rule-correlated-observable (rc-observable) of 74. In general, whenever possible, the current strategy fa- vors interpretations that do not require such changes in the status of observables or t-terms relative to the t-term being retranslated. Figure 2 Retranslation of 7-i Environment Interpretation Modification cx x 77 (c) generalize ce in label(rr) CeY y 77 (ce) - S-label for 77: c Resulting label(Ts): cx V cy, but cy leads to false positives for rs Patch: Add e to problematic interpretation, i.e., rule ~77 + 7-s becomes eyq + rs Retranslation of 5 Environment Interpretation Modification abeln abdln n 73 (abel) n 73 (abdl) specialize ael in label(r3) bdeln n 73 (bdel) specialize adl in Iabel abfn bcgn n 73 (abf) specialize del in label(Ts) n 7-a (beg) generalize abfg in label(Ts) generalize bcfg in label( 7s) S-label for 73: abdl V abel V bdel V abf V acfg V beg Retranslation of 72 Environment Interpretation Modification abdl blr2 ad abel make b rc-observable of 73 b 1 72 (ae) same bdel b 1 72 (de) same abf f ~1 (ab) acf9 bc9 f9 71 (ac> delete g in rule fgq -+ 7-3 - g 71 (bc) delete f in rule fgq S-labels for 71 & 72: identical to their original lazl? Resulting label(rs): abdl V abet V bdel V abf V acf V bcf V abg V acg V beg Resulting label(r5): abeln V abdln V bdeln V abf nv acfn V bcfn V abgn V acgn V bcgn Retranslation of 7-4 Environment Interpretation Modification adeh adeh dhk k 76 (dh) Add rule: adeh ----f 7-4 specialize dh New Theorv ” abVacVbc-+q, adVaeVed+rz, c-+r7 blT2 + r3, fr1 - 73, 971 - 75 nr3 - 75, dh + re, kre + r4 ad& - 74, 377 -+ ~8, eyr7 + rs Testing & Patching Interpretations Interpretations that involve the generalization or spe- cialization of some label need to be tested against the set of cases C. To see why, consider the example in Figure 2, beginning with the retranslation of endpoint rs. In this case the interpretations of the environments in RTLS-label(Ts) lead to a S-label of c for 77. We see, GINSBERG 78 1 however, that if this interpretation of 77 were adopted - other things being equal - a new false positive would be generated, i.e., the new label generated for 7-s would contain the environment cy, where there are known cases containing cy that are non-T7-cases. There are a number of options that can be pursued here. One that has proven to be useful, involves patch- ing the interpretation ~77, i.e., adding more observ- ables to it - so that the false positive will be avoided.. Any observable that is not present in a problematic case but is present in every Ts-case that cy is satisfied in, is a good candidate for a patch. Of course we pre- fer candidates that are either rule or theory correlated to 7-s in that order. In the example e fulfills this role, and leads to the adoption of the rule eyrr + rs. This and other patching techniques are similar to those dis- cussed in [4]. Empirical Evaluation As was mentioned above, top-down retranslation is a method for relaxed retranslation. This means that the new theory generated by this method may, and gener- ally will, correspond to a reduction that is not identical to the input from RTLS. Therefore, it is conceivable that the error rate of the new theory - defined in terms of performance over alb cases in the domain, and not just C - may be worse than that of the RTLS reduction. While one would like to be able to say that a se- vere performance degradation cannot take place using this method, this remains unproven. However, experi- ments show that, if anything, one can expect top-down retranslation to lead to a new theory that gives better performance than the RTLS reduction. The evidence for this follows. The top-down retranslation method described here has been tested on the same rheumatology knowledge base using the same 121 cases that were used to test RTLS [4]. As in the original testing of RTLS, the so- called leave-one-out method [6] for establishing an es- timated error rate was employed. Using this method on n cases entails performing n trials over n - 1 of the cases, “leaving out” a different case each time to be used in testing the result of that trial. The estimated error is calculated by summing the errors over the n trials. Thus 121 trials were run, on each trial one case was set aside. RTLS was then run on the remaining 120 cases, and then top-down retranslation was applied to the RTLS reduction. The new theory was then tested on the case that was left out. An estimated error rate of (I was obtained (RTLS achieved a .067 estimated error). There is another dimension of performance along which a retranslation method must be tested. This is what we may call the “compression ratio.” This re- lates to the one of the avowed goals of retranslation, viz., to convert a rather large and cumbersome reduc- tion into a smaller, more elegant, and more intelligible logical structure. In this case it is clear that the theory 782 MACHINE LEARNING generated by top-down retranslation can be no worse than the RTLS reduction, the question is how much better is it likely to be? Again, empirical results seem very reasonable. The rheumatology knowledge base initially consisted of roughly 360 rules which yielded a reduction of about 35,000 environments. The average size of the reduc- tion produced by RTLS in the above experiments was roughly 30,000 environments, and the average num- ber of rules generated by top-down retranslation was roughly 600. Technically, one ought to re-reduce the new theories in order to verify that they do indeed en- code reductions on the order of 30,000 environments. In the interests of time, this was not done (it would probably take 10 or more hours to calculate each re- duction), but cursory examination of the theories gen- erated make it highly probable that this was in fact the case. Conclusion The results reported here show that the three-fold the- ory reduction approach to theory revision is feasible and robust. One would like to see the method tai- lored to work with partial reductions of theories, i.e., we want to reduce as little of the theory as possible to solve the revision problems at hand. This work estab- lishes a framework and foundation within which such variations of top-down retranslation can be pursued. PI PI PI Fl PI PI PI PI References J. de Kleer. An assumption-based tms. Artificial Intelligence, 28:127-162, 1986. A. Ginsberg. Knowledge base refinement and the- ory revision. In Proceedings of The Sixth Interna- tional Workshop on Machine Learning, pages 260- 265, 1989. A. Ginsberg. Knowledge-base reduction: a new ap- proach to checking knowledge bases for inconsis- tency and redundancy. In Proceedings of the Sev- enth Annual National Conference on Artificial In- telligence, pages 585-589, 1988. A. Ginsberg. Theory revision via prior opera- tionalization. In Proceedings of the Seventh An- nual National Conference on Artificial Intelligence, pages 590-595, 1988. C. Hempel. Philosophy of Natural Science. Prentice-Hall, Englewood Cliffs, N.J., 1966. P. Lachenbruch. An almost unbiased method of obtaining confidence intervals for the probability of misclassification in discriminant analysis. Bio- metrics, 24:639-645, December 1967. T. Mitchell, R. Keller, and S. Kedar-Cabelli. Explanation-based generalization: a unifying view. Machine Learning, 1:47-80, 1986. E. Nagel. The Structure of Science. Harcourt, Brace, and World, New York, 1961.
|
1990
|
149
|
903
|
An Organizational Approach to Adaptive Production Systems Toru Ishida Makoto Yokoo NTT Communications and Information Processing Laboratories l-2356, Take, Yokosuka-shi, 238-03, Japan ishida/yokoo%nttkb.ntt.jp@relay.cs.net Abstract Recently-developed techniques have improved the per- formance of production systems several times over. However, these techniques are not yet adequate for continuous problem solving in a dynamically chang- ing environment. To achieve adaptive real-time per- formance in such environments, we use an organization of distributed production system agents, rather than a single monolithic production system, to solve prob- lems. Organization seZf-design is performed to sat- isfy real-time constraints and to adapt to changing resource requirements. When overloaded, individual agents decompose themselves to increase parallelism, and when the load lightens the agents compose with each other to free hardware resources. In addition to increased performance, generalizations of our compo- sition/decomposition approach provide several new di- rections for organization self-design, a pressing concern in Distributed AI. Introduction To improve the efficiency of production systems, high- speed matching algorithms, such as RETE [Forgy, 19821, TREAT [M iranker, 19871, and optimization al- gorithms [Ishida, 19881 have been investigated. Two kinds of parallel processing techniques have also been proposed: parallel matching [Stolfo, 1984; Gupta et ad., 1985; Acharya et al., 19891 to speed-up matching pro- cesses and parudlel firing [Ishida et al., 1985; Ishida, 1990; Tenorio et al., 1985; Moldvan, 19861 to reduce the total number of sequential production cycles. The motive for all of these studies is to speed up production systems several times over. However, these techniques are not yet adequate for continuous problem solving systems. Typical examples can be found in real-time expert systems, where new techniques are required to ada.pt the systems to dynamically changing environments [Laffey et aZ., 19881. T 0 satisfy real-time constraints, various agent-centered approaches are currently being studied. Lesser et al. [1988] discussed approximate processing techniques. Hayes-Roth et aZ. [1989] intro- duced adaptive inteZZigent systems that reason about 52 AUTOMATEDREASONING Les Gasser Computer Science Department University of Southern California Los Angeles, CA 90089-0782 gasser@pollux.usc.edu and interact with other dynamic entities in real-time. These approaches attempt to meet deadlines by im- proving the decision-making of individual agents. In this paper we take an organization-centered approach, where problems are solved by a society of distributed problem-solving agents. This-approach-aims to a.chieve adaptive real-time performance through reorganization of the society. In a.ddition to improving adaptabil- ity, our technique provides several insights and general mechanisms for organizational adaptation, a pressing concern in DA1 [Gasser et al., 1989a]. Moreover, it has the advantage of being grounded in a well-understood body of theory and practice: parallel production sys- tems. To explore the effectiveness of the organization- centered approach, we are studying the adaptive 1oa.d balancing problem in which a pa.r ticu1a.r problem solver shares a collection of processor resources with other problem solvers (and so has a.n opportunity for adapt- ing its levels of resource use). Problem solving re- quests arrive at the organization continuously, at vari- a.ble ra.tes. Meaningful results are required wit,hin a (possibly changing) time limit. When the problem- solver is embedded in an open community of other problem solvers, it does not -suffice to simply decom- pose to maximal parallelism - the collective must adapt itself to take advantage of resources as needed, but-it must also adaptively free up resources for others white continuing to operate. To achieve this goal, we first extended pnralled pro- duction systems, where global control exists, into dis- tribuied production systems, with distributed control. We then introduced organization self-design (OSD) [Corkill, 1982; Durfee et al., 1987; Gasser e2 nZ., 1989a.,b] into these distributed production systems. In previous research, reorganiza.tion mechanisms typically changed agent roles or inter-a.gent task ordering. In this paper, we a.dded new reorganization primitives: composition and decomposition of agents. \Vhen prob- lem solving requests arrive frequently, and make it difficult for the organization to meet its deadlines, agents autonomously decompose themselves so that parallelism increases. In contrast, when the organi- From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. zational load decreases, two agents compose (combine with each other) to save hardware resources. As a re- sult, both real-time constraints and efficient resource utilization are satisfied through composition and de- composition of the agents. Production Systems To establish our terminology, we give a brief overview of production systems. A production system is defined by a set of rules or productions called production mem- ory (PM), together with an assertion database called working memory (WM) that contains a set of working memo y elements (WMEs). Each rule comprises a con- junction of condition elements called the Zeft-hand side (LHS) of the rule, and a set of actions called the right- hand side (RHS). Positive condition eZem.ents are sak- isfied when a matching WME exists, and negative con- dition elements are satisfied when no matching WME is found. An instantiation of the rule is a set of WMEs that satisfy the positive condition elements. The RHS specifies assertions to be added to or deleted from the WM? A data dependency graph of production systems [Ishida et al., 1985; Ishida, 19901 is constructed from the following four primitives: A production node, which represents a set of insta.n- tiations. Production nodes are shown as circles in Figure 1 and 2. A working memory node, which represents a set of WMEs. Working memory nodes are shown as squares in Figure 1 and 2. A directed edge from a production node to a work- ing memory node, which represents the fact that a production node modifies a working memory node. More precisely, the edge labeled ‘+’ ( ‘- 3 indicates that a WME in a working memory node is a.dded (deleted) by firing an instantiation in a production node. A directed edge from a working memory node to a production node, which represents the fact that a production node refers to a working memory node. More precisely, the edge labeled ‘+’ ( ‘- ‘) indicates that a WME in a working memory node is referenced by positive (negative) condition elements when cre- ating an instantiation in a production node. Interference exists among rule instantiations when the result of parallel execution of the rules is different from the results of sequential executions applied in any order; it must be avoided by synchronization. Figure 1 shows an example of OPS5 rules and their data dependency graph. In this example, if either ruleA or ruleB is fired first it destroys the other rule’s ‘In this paper, we assume that each WME contains unique information. Operations adding duplicated WMEs are ignored. (p ruleA (class1 . ..) G*e class2 . ..)) (p ruleI (class1 . ..) - (class2 . ..) --> (remove 1)) Figure 1: Data Dependency Graph preconditions; therefore, interference may occur when firing both rules in parallel. If the two rules are dis- tributed to different agents, the agents have to syn- chronize to prevent firing those rules in parallel. Distributed Production Systems Overview A distributed production system is defined as a set of production system agents, each of which contains and fires some of the problem solving rules of the overall system. Each agent comprises the following three com- ponents: A problem solver, which continuously repea.ts the problem solving cycle described later in this section. In parallel production systems, multiple rules are si- multaneously fired but globally synchronized at the conflict resolution phase [Ishida el al., 1985; Ishida, 19901. In distributed production systems, on the other hand, rules are asynchronously fired by dis- tributed agents. Since no global control exists, in- terference among the rules is prevented by local syn- chronization between individual agents. Problem solving knowledge, contained in the PMs and WMs. For simplifying the following discussion, we assume no overlap between PMs in different agents, and assume the union of all PhIs in the organiza- tion is sufficient to solve the given problem. Each agent’s WM contains only WhIEs that ma.tch the LHS of that agent’s rules. Since the same condition elements ca.n appear in different rules, the WMs in different agents may over1a.p. The union of WhIs in an organization logically represents all the facts necessary to solve the given problem. In pra.ctice, since agents asynchronously fire rules, WMs can be temporarily inconsistent. Organ.izntionaZ knowledge, representing relationships among a.gents. Each agent knows only a.bout the others with whom it has data dependency or interfer- ence relationships (called its neighbors-see below). Since agents asynchronously perform reorga.niza.tion, I~~HDA E-~-AL. 53 organizational knowledge can be temporarily incon- sistent across agents. Organizational Knowledge Organizational knowledge consists of the following three elements: Dependencies: Each agent knows which rules in the organization have data dependency relationships with its own rules. We say that ruleA depends on ruleB if ruleA refers to a working memory node that is changed by ruleB. We describe this as depends (ruleA, ruleB). The data dependency knowledge of agentP is represented as: DEPENDENCY,S,,tp = ((ruleA, ruleB) I (ruleAEPA&,,tp V ruleBEPM,,,,tp) A depends(ruleA, ruleB)) Interference: Each a.gent knows which rules in the organiza.tion may interfere with its own rules. Various inter- ference analysis techniques are reported in [Ishida, 19901. We describe the interference of ruleA and ruleB as interfere(ruleA, ruleB). The interfer- ence knowledge of agentP is represented as: INTERFERENCEagentp = <(ruleA, ruleB) I (ruleAEPi&,,tp V ruleBEPMagentp> A interfere(ruleA, ruleB)) Though an individual agent’s execution cycle is se- quential, potential interference among its own rules is analyzed for future distribution of those rules. Locations: Each agent, say agentP, knows the location of rules, say ruleA, appearing in its own data dependency and interference knowledge. We describe this as appears(ruleA, agentp). The neighbor knowledge of agentP is represented as: LOCATION,,,,tp = <(ruleA, agentQ) 1 appears(ruleA, agentP) A ruleAEPA4a,,,tQ) Figure 2 illustrates the organizational knowledge of agentP. For example, since ruleA and ruleB in- terfere with each other, agentP has to synchronize with agentQ when executing ruleA. Also, ruleA’s WM modification has to be transferred to agents. We call agentQ a neighbor of agentP when agentQ has data dependency or interference relationships with agentP. From this definition, as illustrated in Figure 2, agentP’s organizational knowledge refers only to its neighbors. (m) indicatesthesameworkingmemorynode duplicatively stored indifferent agents. DEPENDENCYugenrP = ((ruleA, ruleC) (ruleD, ruleA) INTERFERENCE agentp (ruleA, ruleE)} = ((ruleA, ruleB)) LOCATION agentp = ((ruleA, aged) (ruleB, agenta (ruleC, agentR) (ruleD, agentS) (ruleE, agentT)} Figure 2: Organizationa. Knowledge Problem Solving Cycle We define a problem solving cycle of distributed pro- duction system agents by extending the conventional Match-Select-Act cycle to accommodate inter-agent data transfers and synchronization. Temporary inter- agent inconsistency caused by distribution is handled locally using temporary synchronization via rule de- activation. (We assume the preservation of message ordering.) The cycle is: 1. Process messages: When receiving a synchronization request message (e.g., deactivate(ruleA)), return an acknowledg- ment message and deactivate the corresponding rule (ruleA) until receiving a synchronization release message (activate (ruleA)). When receiving a WM m.odification message, update the local WM to reflect the change ma.de in the other agent’s WM. 54 AUTOMATED REASONING 2. 3. 4. 5. 6. Match: For each rule, determine whether the LHS matches the current WM. Select: Choose one instantiation of a rule (e.g., ruleB) that is not deactivated. Request synchronization: Using interference knowledge, send synchroniza- tion request messages (deactivate (ruleB) ) to the agents requiring synchronization. Await acknowl- edgment from all synchronized agents2. After com- plete acknowledgment, handle all WM modification messages that have arrived during synchronization. If the selected instantiation is thereby canceled, send synchronization release messages and restart the problem solving cycle. Act: Fire the selected rule instantiation (ruleB). Using the data dependency knowledge of agentP, inform dependent agents with WM modification messages. Release synchronization: Send synchronization release messages (act ivat e (ruleB)) to all synchronized agents. Organization Self-Design (OSD) Reorganization Requests To start reorganization, two kinds of reorganization re- quests are sent to all agents of the organization. De- composition requests are issued when the organization cannot, meet deadlines. Composition requests are is- sued to release resources when the organization-wide load is light. For these purposes, the behavior of the organization must, be continuously observed. Decomposition requests initiate division in heavily- loaded agents. Decomposition continues until paral- lelism increases, response times are shortened, and de- composition requests disappear. Conversely, composi- tion requests initiate combining each two lightly-loaded agents into one. Composition continues until the or- ganization’s load increases and composition requests disappear. Both kinds of requests can be issued simul- t aneousl y. Reorganization Process To control the reorganization processes, we added to each agent an organization self-designer, which per- forms reorganization at the end of each problem solv- ing cycle. We describe below how one agent, (e.g., agentP) decomposes itself into two agents(e.g., agentP and agentQ). During reorganization, rules, WMEs, de- pendency and interference knowledge are transferred from agentP to agentQ, but not modified. Loca.tion 2Deadlock is a possibility. When acknowledge messages are not received, synchronization release messages are sent and the problem solving cycle is restarted. knowledge is other agents. 1. 2. 3 4 5 6. 7. modified and changes are propagated to Create a new agent: agentP creates a new agent, agentQ, which immedi- ately starts problem solving cycles. Select rules to be transferred: agentP selects active rules to be transferred (e.g., ruleA) to agentQ. agentP sends synchronization request messages (deactivate(ruleA)) to agentQ. Currently, half of the active rules are arbitrarily se- lected and transferred, but we are refining a theory of rule selection based on maximizing intra-agent rule dependencies and minimizing inter-agent communi- cation. Request synchronization: agentP sends synchronization request messages to neighbors for all rules that have data depen- dency or interference relationships with rules to be transferred (e.g., deactivate(ruleB) is sent, if depends(ruleA, ruleB), depends(ruleB, ruleA) or interf ere(ruleA, ruleB))3. agentP waits for complete acknowledgment (resolving deadlock as be- fore). Transfer rules: agentP transfers rules (ruleA) to agentQ, upda.tes its own location knowledge, and propagates any changes to its neighbors. Transfer WMEs: agentP copies WMEs that ma.tch the LHS of the transferred rules (ruleA) to agentQ4. A bookkeep- ing process follows in both agents to eliminate du- plicated or unneeded WMEs. Transfer dependency an,d interference knowledge: agentP copies its dependency and interference knowledge to agentQ. Both agents do bookkeeping to eliminate duplica.ted or unneeded organizationa. knowledge5. Release synchronization.: agentP sends synchronization release messages (act ivat e (ruleA) to agentQ and activate(ruleB) to all synchronized neighbors). This ends reorganization. ‘This is to assure that WM modification and synchro- nization request messages related to rules to be transferred are not sent to agentP during the reorganization process. ‘More precisely, to avoid reproducing once-fired instan- tiations, not only WMEs but also conflict sets are trans- ferred to agentQ. Before transferring the conflict sets, how- ever, agentP has to maintain its WM by handling the WM modification mestiages that have arrived during the syn- chronization process. ‘Unneeded data dependency and interference knowledge are the tuples that include none of the agents’ rules. Un- needed location knowledge is the tuples that include none of the rules that appear in the agents’ data dependency and interference knowledge. ISHIDA ETAL. 55 An agent (e.g., agentp) can compose with another agent by a similar process. First, agentP sends com.po- sition request messages to its neighbors. If some agent, say agentQ, acknowledges, agentP transfers all rules and organizational knowledge to agent9 and destroys itself. The transfer method is the same as that for decomposition. During the reorganization process, neighboring agents deactivate rules that have data dependency or interference relationships with transferred rules. However, neighboring agents can concurrently perform other activities including firing and transferring rules that are not deactivated. This localization helps agents to modify the organization incrementally. Experimental Evaluation To evaluate the effectiveness of our approach, we imple- mented a simulation environment and solved the Waltz labeling problem: 36 rules solve the problem that ap- pears in Figure 3-17 in [Winston, 19771 with 80 rule firings. At initiation, only one agent, with all problem- solving and organizational knowledge, exists in the or- ganization. We assume the organization knowledge for the initial a.gent is prepared by analyzing its problem solving knowledge before execution. Problem-solving requests continuously arrive at the agent; older pend- ing requests are processed with higher priority. The load of each agent is represented by a firing ratio: the ratio of the number of rule firings to the number of problem solving cycles. Reorganization is performed as follows. (Global parameters are adjusta.ble.) When the organization cannot solve a problem within a predefined time limit, say 20 problem solving cycles, decomposition requests are sent to the organi- zation. We use experimentally-generated firing ra.tio thresholds to trigger reorganization. Agents whose fir- ing ratio is greater than 80% start decomposing. Upon decomposition, rules are arbitrary divided and dis- tributed between two agents. When the organization- wide ratio is less than SO%, composition requests are sent to the organization. Agents whose firing ratio is less than 30% compose with each other. These thresh- olds were experimentally found to provide a good bal- ance between adaptiveness and sensitivity, but further study is warranted. Figure 3 shows the simulation results. The line cha.rt indicates response times normalized by problem solv- ing cycles, and the step chart represents the number of agents in the organization. In Figure 3(a), problem solving requests arrive at constant intervals. In Figure 3(b), the frequency of requests is changed periodically. From these figures, we can conclude the following: Adaptiveness of the organization: In Figure 3(a), the organization reaches a stable state. Since several composition and decomposition cycles are performed, the firing ratios of the result- ing agents are equalized. In Figure 3(b), we can see (a) - time @I- time - number of agents t job arrival response time 0 (organizational approach) response time *-a-- (conventional parallel approach) Figure 3: Simulation Results 56 AUTOMATEDREASONING the number of agents at the busiest peak slightly decreases over time. Both charts show that the soci- ety of agents has gradually adapted to the situation through repeated reorganization. Real-time problem solving: The average number of agents in Figure 3(b) is 8.95. We compared the organization response times to the performance of 9 permanent agents with no self- design (which is the conventional parallel production system approach, shown as the dashed line in Fig- ure 3(b)). D ff i erences between the dashed and solid lines demonstrate how the organizational approach is effective for adaptive real-time problem solving. However, the effect of reorganization lags the change in problem load. To improve the capability to meet deadlines, time limits must be set shorter than ac- tual deadlines, and load increases must be detected as early as possible. Eficient resource utilization: In Figure 3(b), the number of required a.gents varies from 4 to 17. It is obvious tha.t the organiza- tional approach is more economical than the conven- tional parallel approach that permanently reserves 17 agents. The resource saving effect of the organi- zational approach is also supported by the fact tha.t 9 permanent agents (which require almost the same processing resources as the organizational approa.ch) cannot meet deadlines. Conclusion Techniques for building problem-solving systems that can adapt to changing problem solving requests and deadlines are of great interest. This pa.per has pre- sented an approach that relies on reorganization of a collection of problem-solvers to track cha.nges in deadlines and problem solving requests. It exploits an adaptive trade-off of parallelism for time by mak- ing new agents and continually reallocating problem- solving knowledge. The importance of this a.pproa.ch goes beyond the adaptive performance we have illus- trated. With additional decision-making meta-knowledge, this approach can become a more general organiza- tion self-design technique. It also has the a.dvantage of being grounded in a well-understood body of the- ory and practice: parallel production systems. In the current version, composition/decomposition decisions are made solely on the basis of firing ratios, and the choice of rules to transfer is made arbitrarily. Alloca- tion decisions could instead be based on the semantics of rules (i.e., distribution based on the kinds of ta.sks that need more resources). Partial knowledge trans- fer among existing agents can be combined with com- position and decomposition to provide a flexible and distributed task-sharing system. Within our existing formulation, avenues for future research include the implementation and the eva.lua- tion of this approach on actual message passing multi- processor systems, evaluating the impact of reorgani- zation overheads, finer threshold sensitivity analyses, techniques for incrementally acquiring reorganization strategy in more dynamic contexts, and applying this approach to adaptively overcoming local faults and in- consistency among agents. Acknowledgments The basic ideas in this paper were elaborated during Les Gasser’s visit at NTT Communications and Infor- mation Processing Laboratories. The authors wish to thank Kunio Murakami and Ryohei Nakano for their support to our joint research project, and Nick Rou- quette for helpful comments. References [Acharya et al., 19891 A. Acharya and M. Ta.mbe, “Production Systems on Message Passing Comput- ers: Simulation Results and Analysis,” Interna- tional Conferen*ce on Parallel Processing, pp. 246- 254, 1989. [Corkill, 19821 D.D. Corkill, A Framework for Orga- nizational Self-Design in Distributed Problem Solv- ing Networks, PhD Dissertation, COINS-TR-82-33, University of Massachusetts, 1982. [Durfee et al., 19871 E. H. Durfee and V. R. Lesser, “Using Partial Global Plans to Coordinated Dis- tributed Problem Solvers,” IJCAI-87, pp. 875-883, 1987. [Forgy, 19821 C. L. Forgy, “A Fast Algorithm for the Many Pattern / Many Object Pattern hIat& Prob- lem,” Artificial Intelligen.ce, Vol. 19, pp. 17-37, 1982. [Gasser et al., 1989a] L. Gasser and M. N. Huhns, “Themes in Distributed AI Research,” in L. Gasser and M. N. Huhns, Editors, Distributed Artificial In- telligence, Volume II, London:Pitman, 1989. [Gasser et al., 1989b] L. Gasser, N. Rouquette, R. Hill and J. Lieb, “Representing and Using Organiza- tional Knowledge in DA1 Systems,” in L. Gasser and M. N. Huhns, Editors, Distributed Artificial Intelligen.ce, Volume II, London:Pitma.n, pp. 55-78, 1989. [Gupta et al., 19881 A. Gupta., C. L. Forgy, D. Kalp, A. Newell and M. Tambe, “Parallel OPS5 on the Encore Multimax,” International Conference on Parallel Processing, pp. 271-280, 1988. [Ha.yes-Roth et al., 19891 B. Hayes-Roth, R. Washing- ton, R. Hewett, M. Hewett and A. Seiver, “Intelli- gent Monitoring and Control,” IJCAI-89, pp. 243- 249, 1989. [Ishida et al., 19851 T. Ishida and S. J. Stolfo, “To- wards Parallel Execution of Rules in Production ISI~DA ETAL. 57 System Programs,” International Conference on Parallel Processing, pp. 568-575, 1985. [Ishida, 19881 T. Ishida, “Optimizing Rules in Pro- duction System Programs,” AAAI-88, pp. 699-704, 1988. [Ishida, 19901 T. Ishida, “Methods and Effectiveness of Parallel Rule Firing,” IEEE Conference on Arti- ficial Intelligence Applications, pp. 116-122, 1990. [Laffey e-t al., 19881 T. J. Laffey, P. A. Cox, J. L. Schmidt, S. M. Kao, and J. Y. Read, “Real-Time Knowledge-Based Systems,” AI Magazine, Vol. 9, No. 1, pp. 27-45, 1988. [Lesser et al., 19881 V. R. Lesser, J. Pavlin and E. H. Durfee, “Approximate Processing in Real Time Problem Solving,” AI Magazine, Vol. 9, No. 1, pp. 49-61, 1988. [Miranker, 19871 D. P. Miranker, “TREAT: A Bet- ter Match Algorithm for AI Production Systems,” AAAI-87, pp. 42-47, 1987. [Moldovan, 19861 D. I. Moldovan, “A Model for Par- allel Processing of Production Systems,” IEEE In- ternational Conference on Systems, Man, and Cy- bernetics, pp. 568-573, 1986. [Stolfo, 19841 S. J. Stolfo, “Five Parallel Algorithms for Production System Execution on the DAD0 Machine,” AAAI-84, pp. 300-307, 1984. [Tenorio et al., 19851 F. M. Tenorio and D. I. Moldovan, “Mapping Production Systems into Multiprocessors,” International Conference on Parallel Processing, pp. 56-62, 1985. [Winston, 19771 P. H. Winston, Artificial Intelligence, Addison-Wesley, 1977. 58 AUTOMATEDREASONING
|
1990
|
15
|
904
|
sal Trees fro n-nation * Dan Geiger Azaria Paz Judea Pearl dgeiger@nrtc.northrop.com paz@techsel.bitnet judea@cs.ucla.edu Northrop Research and Computer Science Department Cognitive Systems Lab. Technology Center Israel Institute of Technology University of California One Research Park Haifa, Israel 32000 Los Angeles, CA 90024 Palos Verdes, CA 90274 Abstract In constructing probabilistic networks from hu- man judgments, we use causal relationships to convey useful patterns of dependencies. The con- verse task, that of inferring causal relationships from patterns of dependencies, is far less under- stood. Th’ 1s paper establishes conditions under which the directionality of some interactions can be determined from non-temporal probabilistic in- formation - an essential prerequisite for attribut- ing a causal interpretation to these interactions. An efficient algorithm is developed that, given data generated by an undisclosed causal polytree, recovers the structure of the underlying polytree, as well as the directionality of all its identifiable links. 1 Introduction The study of causation, because of its pervasive usage in human communication and problem solving, is cen- tral to the understanding of human reasoning. All rea- soning tasks dealing with changing environments rely heavily on the distinction between cause and effect. For example, a central task in applications such as di- agnosis, qualitative physics, plan recognition and lan- guage understanding, is that of abduction, i.e., finding a satisfactory explanation to a given set of observa- tions, and the meaning of explanation is intimately re- lated to the notion of causation. Most AI works have given the term “cause” a proce- dural semantics, attempting to match the way people use it in inference tasks, but were not concerned with what makes people believe that Ku causes b”, as op- posed to, say, “b causes a” or Kc causes both a and b.” [de Kleer & Brown 78,Simon 541. An empirical se- mantics for causation is important for several reasons. First, by formulating the empirical components of cau- sation we gain a better understanding of the mean- ing conveyed by causal utterances, such as Ku explains *This work was supported in part by the National Sci- ence Foundation Grant # IRI-8821444 770 MACHINE LEARNING b”, “a suggests b”, ‘a tends to cause b”, and “u actu- ally caused b”. These utterances are the basic build- ing blocks from which knowledge bases are assembled. Second, any autonomous learning system attempting to build a causal model of its environment cannot rely exclusively on procedural semantics but must be able to translate direct observations to cause and effect re- lationships. Temporal precedence is normally assumed essential for defining causation. Suppes [Suppes 701, for ex- ample, introduces a probabilistic definition of causa- tion with an explicit requirement that a cause pre- cedes its effect in time. Shoham makes an identical assumption [Shoham 871. In this paper we propose a non-temporal semantics, one that determines the di- rectionality of causal influence without resorting to temporal information, in the spirit of [Simon 541 and [Glymour at al. 871. Such semantics should be applica- ble, therefore, to the organization of concurrent events or events whose chronological precedence cannot be de- termined empirically. Such situations are common in the behavioral and medical sciences where we say, for example, that old age explains a certain disability, not the other way around, even though the two occur to- gether (in many cases it is the disability that precedes old age). Another feature of our formulation is the appeal to probabilistic dependence, as opposed to functional or deterministic dependence. This is motivated by the observation that most causal connections found in nat- ural discourse, for example “reckless driving causes ac- cidents” are probabilistic in nature [Spohn 901. Given that statistical analysis cannot distinguish causation from covariation, we must still identify the asymme- tries that prompt people to perceive causal structures in empirical data, and we must find a computational model for such perception. Our attack on the problem is as follows; first, we pretend that Nature possesses Ktrue” cause and effect relationships and that these relationships can be repre- sented by a causal network, namely, a directed acyclic graph where each node represents a variable in the do- main and the parents of that node correspond to its From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. direct causes, as designated by Nature. Next, we as- sume that Nature selects a joint distribution over the variables in such a way that direct causes of a variable render this variable conditionally independent of all other variables except its consequences. Nature per- mits scientists to observe the distribution, ask ques- tions about its properties, but hides the underlying causal network. We investigate the feasibility of recov- ering the network’s topology efficiently and uniquely from the joint distribution. This formulation contains several simplifications of the actual task of scientific discovery. It assumes, for example, that scientists obtain the distribution, rather than events sampled from the distribution. This as- sumption is justified when a large sample is available, sufficient to reveal all the dependencies embedded in the distribution. Additionally, it assumes that all relevant variables are measurable, and this prevents us from distinguishing between spurious correlations [Simon 541 and genuine causes, a distinction that is im- possible within the confines of a closed world assump- tion. Computationally, however, solving this simplified problem is an essential component in any attempt to deduce causal relationships from measurements, and that is the main concern of this paper. It is not hard to see that if Nature were to assign totally arbitrary probabilities to the links, then some distributions would not enable us to uncover the struc- ture of the network. However, by employing additional restrictions on the available distributions, expressing properties we normally attribute to causal relation- ships, some structure could be recovered. The basic requirement is that two independent causes should be- come dependent once their effect is known [Pearl 881. For example, two independent inputs for an AND gate become dependent once the output is measured. This observation is phrased axiomatically by a property called Marginal Weak Transitivity (Eq. 9 below). This property tells us that if two variables z and y are mu- tually independent, and each is dependent on their ef- fect c, then II: and y are conditionally dependent for at least one instance of c. Two additional properties of independence, intersection and composition (Eqs. 7, and 8 below ), are found useful. Intersection is guar- anteed if the distributions are strictly positive and is justified by the assumption that, to some extent, all observations are corrupted by noise. Composition is a property enforced, for example, by multivariate nor- mal distributions, stating that two sets of variables X and Y are independent iff every it; E X and y E Y are independent. In common discourse, this property is often associated with the notion of “independence”, yet it is not enforced by all distributions. The theory to be developed in the rest of the paper addresses the following problem. We are given a dis- tribution P and we know that P is represented as a singly-connected d,ag D whose structure is unknown (such a dag is also called a Polytree [Pearl 881). What properties of P allow the recovery of D ? It is shown that intersection composition and marginal weak tran- sitivity are sufficient properties to ensure that the dag is uniquely recoverable (up to isomorphism) in polyno mial time. The recovery algorithm developed consid- erably generalizes the method of Rebane and Pearl for the same task, as it does not assume the distribution to be dag-isomorph [Pearl 88, Chapter 81. The algorithm implies, for example, that the assumption of a multi- variate normal distribution is sufficient for a complete recovery of singly-connected dags. 2 Probabilistic Dependence: Background and Definitions Our model of an environment consists of a finite set of variables U and a distribution P over these vari- ables. Variables in a medical domain, for example, represent entities such as “cold”, Kheadache”, ‘fever”. Each variable has a domain which is a set of permis- sible values. The sample space of the distribution is the Cartesian product of all domains of the variables in U. An environment can be represented graphically by an acyclic directed graph (dag) as follows: We se- lect a linear order on all variables in U. Each variable is represented by a node. The parents of a node v correspond to a minimal set of variables that make v conditionally independent of all lesser variables in the selected order. Each ordering may produce a differ- ent graph, for example, one representation of the three variables above is the chain headache +- cold -+ fever which is produced by the order cold, headache and fever (assuming fever and headache are independent symptoms of a cold). Another ordering of these vari- ables: fever, cold, and heuduche would yield the dag headache + cold c- fever with an additional arc be- tween fever and headache. Notice that the directional- ity of links may differ between alternative representa- tions. In the first graph directionality matches our per- ception of cause-effect relationships while in the second it does not, being merely a spurious by-product of the ordering chosen for the construction. We shall see that, despite the arbitrariness in choosing the construction ordering, some directions will be preferred to others, and these can be determined mechanically. The basis for differentiating alternative representa- tions are the dependence relationships encoded in the distribution describing the environment. We regard a distribution as a dependency model, capable of answer- ing queries of the form UAre X and Y independent given 2 ?” and use these answers to select among possible representations. The following definitions and theorems provide the ground for a precise formulation of the problem. Definition [Pearl & Paz 891 A dependency model M over a finite set of elements U is any subset of triplets (X, 2, Y) where X, Y and Z are disjoint subsets of U. The interpretation of (X, 2, Y) E M is the sentence GEIGER ET AL. 771 “X is independent of Y, given 2” , denoted also by 1(X, 2, Y). When speaking about dependency mod- els, we use both set notations and logic notations. If (X, 2, Y) E M, we say that the independence stute- ment 1(X, 2, Y) holds for M. Similarly, we either say that M contains a triplet (X, 2, Y) or that M satisfies a statement 1(X, 2, Y). An independence statement 1(X, 2, Y) is called an independency and its negation is called a dependency. Every probability distribution defines a dependency model: Definition [Pearl & Paz 891: Let U be a finite set of variables. A Probabilistic Dependency Model Mp is defined in terms of a probability distribution P with a sumpbe space nUiEU d(q), the Cartesian product of d(ui), where d(u;) is the domain of w. If X, Y and Z are three disjoint subskts of U, and X, Y and Z are any instances from the domains of the variables in these subsets, then by definition (X, Z, Y) E Mp i# P(X, Y IZ) = P(XIZ) . P(Y IZ) (1) The definition above is suitable also for normal distri- butions, in which case the distribution function P in Eq. (1) is replaced by the normal density functions. The conditional density functions are well defined for normal distributions if all variances are finite. Dependency models can also be encoded in graph- ical forms. The following graphical definition of de- pendency models is motivated by regarding directed acyclic graphs as a representation of causal relation- ships. Designating a node for every variable and as- signing a link between every cause to each of its di- rect consequences defines a graphical representation of a causal hierarchy. For example, the propositions “It is raining” (r), “the pavement is wet” (w) and ‘John slipped on the pavement” (s) are well represented by a three node chain, from r through t.u to s ; it indicates that rain and wet pavement could cause slipping, yet wet pavement is designated as the direct cause; rain could cause someone to slip if it wets the pavement, but not if the pavement is covered. Moreover, knowing the condition of the pavement renders “slipping” and ‘raining” independent, and this is represented graph- ically by showing node r and s separated from each other by node w. Furthermore, if we assume that Ubro- ken pipe” (b) is another direct cause for wet pavement, as in Figure 1, then an induced dependency exists be- tween the two events that may cause the pavement to get wet: KrainB and Gbroken pipe”. Although they appear connected in Figure 1, these propositions are marginally independent and become dependent once we learn that the pavement is wet or that someone broke his leg. An increase in our belief in either cause would decrease our belief in the other as it would Kex- plain away” the observation. The following definition of &separation permits us to graphically identify such induced dependencies from the network. A preliminary definition is needed. Definition A trail in a dug is a sequence of links that form a path in the underlying undirected graph. A trail is said to contain the nodes adjacent to its Kinks. A node b is called a head-to-head node with respect to a trail t if there are two consecutive links a -+ b and b + c on t. A node that starts or ends a trail t is not a head-to-head node with respect to t’ . Definition [Pearl 881 Ij X, Y, and Z are three dis- joint subsets of nodes in a dug D, then Z is said to d-separate X from Y, denoted I(X, Z, Y),, a# there exists no trail t between a node in X and a node in Y along which (1) every head-to-head node (wrt t) ei- ther is or has a descendent in Z and -(2) every node that delivers an arrow along t is outside Z. A trail satisfying the two conditions above is said to be active. Otherwise, it is said to be blocked (by Z). 0 s slipping Figure 1 Definition A Dag Dependency Model MD is defined in terms of a directed acyclic graph D. If X, Y and Z are three disjoint sets of nodes in D, then, by defini- tion, (X, Z,Y) E MD ifl there is no active trail by Z between nodes in X and Y. For example, in Figure 1, (r, 0, b) E MD, (r, s, b) $ MD, (r, {w,s),b) 4 MD, and (vv) E MD- These two distinct types of dependency mod- els: graphical and probabilistic provide different for- malisms for the notion of “independent”. The similar- ity between these models is summarized axiomatically by the following definition of graphoids. Definition [Pearl & Paz 891 A graphoid is any depen- dency model M which is closed under the following in- ference rules, considered us axioms’: Trivial Independence Symmetry WC z, 0) (2) qx, z, Y) * v-9 z, X) (3) ‘The definitions of undirected graphs, acyclic graphs, trees, paths, adjacent links and nodes can be found in any text on graph algorithms (e.g., [Even 791). 2This definition differs slightly from that given in [Pearl & Paz 891 where axioms (3) through (6) define semi- graphoid and dependency models obeying also (7) are called graphoids. Axiom (2) is added for future clarity. 772 MACHINE LEARNING Decomposition 1(X, 2, Y u W) * 1(X, 2, Y) (4) Weak union I(X,Z,Y UW) =s I(X,ZlJW,Y) Contraction (5) 1(X, 2, Y) & 1(X, Z U Y, w) ==F 1(X, 2, Y U W) (6) Intuitively, the essence of these axioms lies in Eqs. (5) and (6). If we associate dependency with infor- mational relevance, these equations assert that when we learn an irrelevant fact, all relevance relation- ships among other variables in the system should re- main unaltered; any information that was relevant remains, relevant and that which was irrelevant re- mains irrelevant. These axioms are very similar to those assembled by Dawid [Dawid 791 for probabilis- tic conditional independence, those proposed by Smith [Smith 891 for G eneralized Conditional Independence and those used by Spohn [Spohn 801 in his exploration of causal independence. We shall henceforth call ax- ioms (2) through (6) graphoid axioms. It can readily be shown that the two dependency models presented thus far, the probabilistic and the graphical, are both graphoids. Several additional graphoids are discussed in [Pearl & Paz 89,Pearl & Verma 871. Definition A dag is an independence-map (I-map) of a graphoid M if whenever X and Y are d-separated by Z in D, then I(X, 2, Y) holds for M. In other words, MD C M, where MD is the dependency model defined by D. A dag D as a minimal-edge I-map of M if deleting any edge of D would make D cease to be an I-map of M. Definition [Pearl 881 A dag D is called a Causal net- work of a dependency model M, if D is a minimal-edge l-map of M. The task of finding a dag which is a minimal- edge I-map of a given distribution P was solved in [Pearl & Verma 87,Verma & Pearl 881. The algorithm consists of the following steps: assign a total ordering d to the variables of P. For each variable ai of P, identify a minimal set of predecessors I that ren- ders ai independent of all its other predecessors in the ordering of the first step. Assign a direct link from every variable in I to ui. The resulting dag is an I-map of P, and is minimal in the sense that no edge can be deleted without destroying its Emapness. The input L for this construction consists of n condi- tional independence statements, one for each variable, all of the form I(ai, ?r(ai), V(ui) - r(q)) where U(ui) is the set of predecessors of oi and r(ai) is a subset of U(ai) that renders ai conditionally independent of all its other predecessors. This set of conditional inde- pendence statements is said to generate a dag and is called a recursive basis drawn from P. The theorem below summarizes the discussion above. Theorem 1 [Verma & Pearl 881 If M is a graphoid, and L is any recursive basis drawn from M, then the dag generated by L is an I-map of M. Note that a probability model may possess many causal networks each corresponding to a different or- dering of its variables in the recursive basis. If tempo- ral information is available, one could order the vari- ables chronologically and this would dictate an almost- unique dag representation (except for the choice of n(ai)). However, in the lack of temporal information the directionality of links must be extracted from ad- ditional requirements about the graphical representa- tion. Such requirements are ‘identified below. 3 Reconstructing Singly Connected Causal Networks We shall restrict our discussion to singly connected causal networks, namely networks where every pair of nodes is connected via no more then one trail and to distributions that are close to normal (Gausian) in the sense that they adhere to axioms (7) through (9) be- low, as do all multivariate normal distributions with finite variances and non-zero means. Lemma 2 The following axioms are satisfied by nor- mal distributions. Intersection 1(X, mu, W) &1(X, zuw, Y) * 1(X, 2, Y UW) (7) Composition 1(X, 2, Y) & 1(X, 2, W) * 1(X, 2, Y u W) (8) Marginal Weak Transitivity I(X,0,Y) &I(X,c,W) 3 1(X,0+) orI(c,0,Y) (9) Definition A graphoid (e.g., a distribution) is called intersectional if it satisfies 0, semi-normal if it satis- fies (7) and (8), and pseudo-normal if it satisfies (7) through (9). Definition A singly-connected dag (or a polytree) is a directed acyclic graph with at most one trail connect- ing any two nodes. A dag is non-triangular if any two parents of a common node are never parents of each other. Polytrees are examples of non-triangular dags. The skeleton of a dag D, denoted skeleton(D), is the undirected graph obtained from D if the directionality of the links is ignored. The skeleton of a polytree is a tree. Definition A Markov network GO of an intersectional graphoid M is the network formed by connecting two nodes, a and b, if and only if (a, U \ (a, b), b) 4 M. A reduced graph GR of M is the graph obtained from Go by removing any edge a - b for which (a, 0, b) E M. Definition Two dags D1 and 02 are isomorphic if the corresponding dependency models are equal. GEIGERETAL. 773 Isomorphism draws the theoretical limitation of the ability to identify directionality of links using informa- tion about independence. For example, the two dags: a -+ b --) c and a + b t c, are indistinguishable in the sense that they portray the same set of independence assertions; these are isomorphic dags. On the other hand, the dag a -+ b + c is distinguishable from the previous two because it portrays a new independence assertion, I(a, 0, c), which is not represented in either of the former dags. An immediate corollary of the def- initions of &separation and isomorphism is that any two polytrees sharing the same skeleton and the same head-to-head connections must be isomorphic. Lemma 3 Two polytrees 2’1 and T2 are isomorphic if they share the same skeleton, and the same head-to- head connections. SufBciency: If Tl and T2 share the same skeleton and the same head-to-head connections then every ac- tive trail in Tl is an active trail in T2 and vice versa. Thus, MT, and MT~, the dependency models corre- sponding to Tl and T2 respectively, are equal. Necessity: Tl and T2 must have the same set of nodes U, for otherwise their dependency models are not equal. If a --) b is a link in Tl and not in T2, then the triplet (a, U \ (a, b), b) is in MT~ but not in iMT,. Thus, if MT~ and M T2 are equal, then Tl and T2 must have the same skeleton. Assume Tl and T2 have the same skeleton and that a + c + b is a head-to-head connection in Tl but not in T2. The trail a-c-b is the only trail connecting a and b in T2 because T2 is singly- connected and it has the same skeleton as Tl. Since c is not a head-to-head node wrt this trail, (a, c, b) E MT~. However, (a, c, b) @ MT~ because the trail a ---) c + b is activated by c. Thus, if MT, and MT~ are equal, then Tl and T2 must have the same head-to-head connections. II More generally, it can be shown that two dags are isomorphic iff they share the same skeleton and the same head-to-head nodes emanating from non adjacent sources [Pear, Geiger & Verma 891. The algorithm below uses queries of the form l-(X, 2, Y) to decide whether a pseudo-normal graphoid M (e.g., a normal distribution) has a poly- tree I-map representation and if it does, it’s topology is identified. Axioms (7) through (9) are then used to prove that if D exists, then it is unique up to iso- morphism. Th e a gorithm 1 is remarkably efficient; it requires only polynomial time (in the number of in- dependence assertions), while a brute force approach would require checking n! possible dags, one for each ordering of M’s variables. One should note, however, that validating each such assertion from empirical data may require extensive computation. 774 MACHINE LEARNING Input: Independence assertions of the form 1(X, 2, Y) drawn from a pseudo-normal graphoid M. Output: A polytree I-map of M if such exists, or acknowledgment that no such I-map exists. 1. 2. 3. 4. Start with a complete graph. Construct the Markov network Ge by removing ev- ery edge a - b for which (a, U \ {a, b}, b) is in M. Construct GR by removing from Go any link a - b for which (a, 0, b) is in M. If the resulting graph GR has a cycle then answer “NO”. Exit. Orient every link a - b in GR towards b if b has a neighboring node c, such that (a, 0, c) E M and a-c is in Go. 5. Orient the remaining links without introducing new head-to-head connections. If the resulting orienta- tion is not feasible answer “NO”. Exit. 6. If the resulting polytree is not an I-map, answer “NO”. Otherwise, this polytree is a minimal-edge I-map of M. The Recovery Algorithm The following sequence of claims establishes the cor- rectness of the algorithm and the uniqueness of the recovered network; full proofs are given in [Geiger 901. Theorem 4 Let D be a non-triangular dag that a’s a minimal-edge I-map of an intersectional graphoid M. Then, for every link a - b in D, (a, U \ (a, b), b) # M. Theorem 4 ensures that every link in a minimal-edge polytree I-map (or more precisely, a link in a minimal- edge non-triangular dag J-map) must be a link in the Markov network Go. Thus, we are guaranteed that Step 2 of the algorithm does not remove links that are needed for the construction of a minimal-edge polytree &map. Theorem 5 Let M be a semi-normal graphoid that has a minimal-edge polytree I-map T. Then, the re- duced graph GR of M equals skeleton(T). Corollary 6 All minimal-edge polytree I-maps of a semi-normal graphoid have the same skeleton (Since GR is unique). Theorem 5 shows that by computing GR, the algo- rithm identifies the skeleton of any minimal-edge poly- tree I-map T, if such exists. Thus, if GR has a cycle, then M has no polytree I-map and if M does have a polytree &map, then it must be one of the orientations of GR. Hence by checking all possible orientations of the links of the reduced graph one can decide whether a semi-normal graphoid has a minimal-edge polytree &map. The next two theorems justify a more efficient way of establishing the orientations of GR. Note that composition and intersection, which are properties of semi-normal graphoids, are sufficient to ensure that the skeleton of a polytree J-map of M is uniquely recover- able. Marginal weak transitivity, which is a property of pseudo-normal graphoids, is used to ensure that the algorithm orients the skeleton in a valid way. It is not clear, however, whether axioms (7) through (9) are in- deed necessary for a unique recovery of polytrees. Definition Let M be a pseudo-normal graphoid for which the reduced graph GR has no cycles. A partially oriented polytree P of M is a graph obtained form GR by orienting a subset of the links of GR using the fol- lowing rule: A link a + b is in P if a - b is a link in GR, b has a neighboring node c, such that (a, 8, c) E M and the link a - c a’s in Go. All other links in P are undirected. Theorem 7 If M is a semi-normal graphoid that has a polytree I-map, then M defines a unique partially oriented polytree P. Theorem 8 Let P be a partially oriented polytree of a semi-normal graphoid M. Then, every oriented link a + c of P is part of every minimal-edge polytree I-map ofM. Theorem 7 guarantees that the rule by which a par- tially oriented polytree is constructed cannot yield a conflicting orientation when M is pseudo-normal. The- orem 8 guarantees that the links that are oriented in P are oriented correctly, thus justifying Step 4. We have thus shown that the algorithm identifies the right skeleton and that every link that is oriented must be oriented that way if a polytree &map exists. It remains to orient the rest of the links. Theorem 9 below shows that no polytree &map of M introduces new head-to-head connections, hence, justi- fying Step 5. Lemma 3, further shows that all orienta- tions that do not introduce a head-to-head connection yield isomorphic dags because these polytrees share the same skeleton and the same head-to-head connections. Thus, in order to decide whether or not M has a poly- tree I-map, it is sufficient to examine merely a single polytree for I-mapness, as performed by Step 6. Theorem 9 Let P be a partially oriented Polytree of a pseudo-normal graphoid M. Every orientation of the undirected links of P which introduces a new head-to- head connection to P yields a polytree that is not a minimal-edge I-map of M. 4 Summary and Discussion In the absence of temporal information, discovering directionality in interactions is essential for inferring causal relationships. This paper provides conditions under which the directionality of some links in a prob- abilistic network is uniquely determined by the depen- dencies that surround the link. It is shown that if a distribution is generated from a singly connected causal network (i.e., a polytree), then the topology of the network can be recovered uniquely, provided that the distribution satisfies three properties: com- position, intersection and marginal weak transitivity. Although the assumption of singly-connectedness is somewhat restrictive, it may not be essential for the recovery algorithm, because Theorem 1, the basic step of the recovery, assumes only non-triangularity. Thus, an efficient recovery algorithm for non-triangular dags may exist as well. Additionally, the recovery of singly connected networks demonstrates the feasibility of ex- tracting causal asymmetries from information about dependencies, which is inherently symmetric. It also highlights the nature of the asymmetries that need be detected for the task. Another useful feature of our algorithm is that its input can be obtained either from empirical data or from expert judgments or a combination thereof. Tra- ditional methods of data analysis rely exclusively on gathered statistics which domain experts find hard to provide. Independence assertions, on the other hand, are readily available from domain experts. We are far from claiming that the method presented in this paper discovers genuine physical influences be- tween causes and effects. First, a sensitivity analysis is needed to determine how vulnerable the algorithm is to errors associated with inferring conditional indepen- dencies from sampled data. Second, such a discovery requires breaking away from the confines of the closed world assumption, while we have assumed that the set of variables U adequately summarizes the domain, and remains fixed throughout the structuring process. This assumption does not enable us to distinguish between genuine causes and spurious correlations [Simon 541; a link a - b that has been determined by our procedure may be represented by a chain a + c ---) b where c is a variable not accounted for when the network is first constructed. Thus, the dependency between a and b which is marked as causal when c @ U is in fact spu- rious, and this can only be revealed when c becomes observable. Such transformations are commonplace in the development of scientific thought: What is cur- rently perceived as a cause may turn into a spurious effect when more refined knowledge becomes available. The initial perception, nevertheless serves an impor- tant cognitive function in providing a tentative and ex- pedient encoding of dependence patterns in that level of abstraction. Future research should explore structuring tech- niques that incorporate variables outside U. The addi- tion of these so called “hidden” variables often renders graphical representations more compact and more ac- curate. For example, a network representing a collec- tion of interrelated medical symptoms would be highly connected and of little use, but when a disease variable is added, the interactions can often be represented by a singly connected network. Facilitating such decompo- sition is the main role of “hidden variables” in neural networks [Hinton 891 and is also incorporated in the program TETRAD citebk:glymour. Pearl and Tarsi provide an algorithm that generates tree representa- tions with hidden variables, whenever such a represen- tation exists iPear- & Tarsi 861. An extension of this GEIGERETAL. 775 algorithm to polytrees would further enhance our un- derstanding of causal structuring. Another valuable extension would be an algorithm that recovers general dags. Such algorithms have been suggested for distributions that are graph-isomorph [Spirtes, Glymour & Scheines 89, Verma 901. The ba- sic idea is to identify with each pair of variables 2 and y a minimal subset Sxy of other variables3 that shields x from y, to link by an edge any two variables for which no such subset exists, and to direct an edge from x to y if there is a variable z linked to y but not to x, such that 1(x, Sxz Uy, Z) does not hold (see Pearl 1988, page 397, for motivation). The algorithm of Spirtes et al. (1989) requires an exhaustive search over all subsets of variables, while that of Verma (1990) prunes the search starting from the Markov net. It is not clear, however, whether the assumption of dag isomorphism is realistic in processing real-life data such as medical records or natural language texts. References [Dawid 791 Dawid, A. P. 1979. Conditional indepen- dence in statistical theory. Journal Royal Statisti- cal Society, Series B, 41(1):1-31. [de Kleer & Brown 781 de Kleer, J.; and Brown, J. S. 1978. Theories of causal ordering. AI, 29( 1):33-62. [Even 791 Even, S. 1979. Graph Algorithm. Computer Science Press, Potomac MD. [Geiger 901 Geiger, D. 1990. Gruphoids: A Qualitative Framework for Probubidistic Inference. PhD the- sis, UCLA Computer Science Department. Also appears as a Technical Report (R-142) Cognitive Systems Laboratory, CS, UCLA. [Glymour at al. 871 Glymour, c.; Scheines, R.; Spirtes, P.; and Kelly, K. 1987. Discovering Causal Structre. Academic Press, New York. [Hinton 891 Hinton, G. E. 1989. Connectionist learning procedures. AI, 40( l-3):185-234. [Pear, Geiger & Verma 891 Pearl, J.; Geiger, D.; and Verma, T. S. 1989. The logic of influence dia- grams. In J. Q. Smith R. M. Oliver (ed. ), Influ- ence Diagrams, Bediefnets and Decision analysis, chapter 3. John Wiley & Sons Ltd. New York. [Pearl & Paz 891 Pearl, J.; and Paz, A. 1989. Graphoids: A graph-based logic for reasoning about relevance relations. In B. Du Boulay et al. (ed. ), Advances in ArtiJiciuZ Intelligence-II, pages 357-363. North Holland, Amsterdam. [Pearl & Verma 871 Pearl, J.; and Verma, S. T. 1987. The logic of representing dependencies by directed acyclic graphs. In AAAI, pages 347-379, Seattle Washington. 3the set Sxy contains ancestors of z or y [Pearl 881 Pearl, J. 1988. Probubidistic reasoning in in- telbigent systems. Morgan-Kaufman, San Mateo. [Pearl & Tarsi 861 Pearl, J.; and Tarsi, M. 1986. Struc- turing causal trees. Journal of Complexity, 2:60- 77. [Shoham 871 Shoham, Y. 1987. Reasoning About Change. MIT Press, Boston MA. [Simon 541 Simon, H. 1954. Spurious correlations: A causal interpretation. Journal Amercun Statisticad Association, 49:469-492. [Smith 891 Smith, J. Q. 1989. Influence diagrams for statistical modeling. Annuls of Statistics, 17(2):654-672. [Spirtes, Glymour & Scheines 891 Spirtes, P.; Gly- mour, C.; and Scheines, R. 1989. Causality from probability. Technical Report CMU-LCL- 89-4, Department of Philosophy Carnegie-Mellon University. [Spohn 801 Spohn, W. 1980. Stochastic independence, causal independence, and shieldability. Journal of Philosophical Logic, 9:73-99. [Spohn 901 Spohn, W. 1990. Direct and indirect causes. Topoi, 9. [Suppes 701 Suppes, P. 1970. A probabilistic theory of causation. North Holland, Amsterdam. [Verma 901 Verma, S. T. 1990. Learning causal struc- ture from independence information. in prepara- tion. [Verma & Pearl 881 Verma, T. S.; and Pearl J. 1988. Causal networks: Semantics and expressiveness. In Forth Workshop on Uncertainty in AI, pages 352-359, St. Paul Minnesota. 776 MACHINE LEARNING
|
1990
|
150
|
905
|
Constructor: A System for the Induction of Probabilistic Models Robert M. Fung and Stuart L. Crawford Advanced Decision Systems 1500 Plymouth Street Mountain View, CA 94043-1230 Abstract The probabilistic network technology is a knowledge- based technique which focuses on reasoning under uncertainty. Because of its well defined semantics and solid theoretical foundations, the technology is finding increasing application in fields such as med- ical diagnosis, machine vision, military situation as- sessment , petroleum exploration, and information re- trieval. However, like other knowledge-based tech- niques, acquiring the qualitative and quantitative in- formation needed to build these networks can be highly labor-intensive. CONSTRUCTQR integrates techniques and concepts from probabilistic networks, artificial intelligence, and statistics in order to induce Markov networks (i.e., undirected probabilistic networks). The resulting net- works are useful both qualitatively for concept orga- nization and quantitatively for the assessment of new data. The primary goal of CONSTRUCTOR is to find quali- tative structure from data. CONSTRUCTOR finds struc- ture by first, modeling each feature in a data set as a node in a Markov network and secondly, by finding the neighbors of each node in the network. In Markov networks, the neighbors of a node have the property of being the smallest set of nodes which “shield” the node from being affected by other nodes in the graph. This property is used in a heuristic search to identify each node’s neighbors. The traditional x2 test for indepen- dence is used to test if a set of nodes “shield” another node. Cross-validation is used to estimate the quality of alternative structures. Introduction The probabilistic networks technology is a new knowledge-based approach for reasoning under uncer- tainty. Because of its well-defined semantics and solid theoretical foundations, it is finding increasing appli- cation in fields such as medical diagnosis, machine vi- sion, military situation assessment, petroleum explo- ration, and information retrieval. However, like other knowledge-intensive approaches, acquiring the qualita- tive and quantitative information needed to build these networks is a highly labor-intensive task which requires trained personnel (i.e., knowledge engineers). In an effort to address this problem, techniques for network- induction [4, 141 have been explored. However these techniques are limited to the recovery of tree structures and these structures are often not expressive enough to represent real-world situations. In this paper, we describe CONSTRUCTOR-a sys- tem designed to more fully address this “knowledge acquisition bottleneck”. CONSTRUCTOR induces dis- crete, Markov networks of arbitrary topology, from data. These networks contain a quantitative (i.e., probabilistic) characterization of the data but, perhaps more importantly, also contain a qualitative structural description of the data. By qualitative structure we mean, loosely, the positive and negative causal rela- tionships between factors as well as the positive and negative correlative relationships between factors in the processes under analysis. CONSTRUCTOR has as a primary focus the recovery of qualitative structures since these structures not only determine which quan- titative relationships are recovered, but also because such structures are readily interpretable and thus are valuable in explaining the real world processes under analysis. The CONSTRUCTOR algorithm is based on the con- cept of “constructing” a network from a data set by instantiating a node for each attribute in the data set and identifying the neighbors of each node in the net- work. Identifying the neighbors of a particular node is operationalized by heuristically searching for the small- est set of nodes which makes the node independent of all other nodes in the network. Independence is tested through the use of the x2 test of independence. The resulting network is a Markov network. Throughout this paper we illustrate concepts with variations on a single problem, which was originally described in [l]. This problem involves an LED dis- play connected to a numeric keypad. The display is fuulty, however, since the output of the display may not always match the key that was depressed. Figure 1 shows the numerical digit display unit, and illustrates the components of the display that must be illuminated 762 MACHINE LEARNING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Rebane & Pearl, 1987 This research [14] extended the MWST algorithm of Chow and Liu to include the partial recovery of singly- connected graphs. ’ The basic idea is to first run the Chow and Liu algorithm to determine node neighbors. A test is then made for each node to determine which of the node’s neighbors are pairwise independent. If a set of mutually pairwise independent nodes exists, then they are labeled as predecessors of the node in question and the remainder are labeled as successors. However, if no pairwise independent nodes are found, no labeling can take place. Although this algorithm keeps all the positive fea- tures of the MWST algorithm, it does little to address its major drawback-the accurate representation of sit- uations which do not have a singly-connected network representation. Xl x2 3 x3 x4 x5 X6 x7 Xl X2 X3 X4 X5 X6 X7 - - ON ON OFF ON OFF ON ON Figure 1: The LED Display to generate the number 5. Since each component of the display has a 0.9 probability of illuminating in error, a training set can be generated in which each example consists of the key that was depressed and the actual state of the LED. The example task is to use CON- STRUCTOR to recover a probabilistic model which can be used both qualitatively to understand the workings of the LED display and quantitatively to assess the in- tended digit given new LED displays. Related Work This section describes a number of alternative ap- proaches to the model construction task addressed by CONSTRUCTOR. Chow & Liu, 1968 This research [4] was concerned with reducing the significant amounts of memory needed to represent large discrete probability distributions. The research resulted in the Maximum Weight Spanning Tree (MWST) alg or1 ‘th m. The algorithm takes as input a training set and produces as output a probabilistic net- work with a tree topology. The algorithm has several desirable properties. First, if the underlying distribution from which the training set is sampled has a tree structure, then the MWST algorithm will find the “optimal” tree. Sec- ondly, the algorithm is computationally tractable-it runs in O(n2) where it is the number of attributes in the training set. Thirdly, since the algorithm only uses pairwise statistics, the size of the training set can be modest and still achieve good results. The major drawback of this algorithm is that sit- uations with more complex structures (i.e., non-tree topologies) cannot be accurately represented. This is a serious drawback since most real problems do not have “tree” structures. Concept Formation Research The CONSTRUCTOR approach to structure learning shares some similarities with the more widely known machine learning work on concept formation [5,11,12]. The clearest similarity relates to the goals of the algo- rithms: the CONSTRUCTOR and concept formation al- gorithms are both designed “to help one better under- stand the world and to make predictions about its fu- ture behavior.“[7]. In addition, both approaches learn in an unsupervised manner-no advice or intervention is required from a “teacher” and like the AutoClass sys- tem [3], Constructor is inherently Bayesian in spirit, making use of probability distributions over the at- tributes of the observations in the training set. Fur- thermore, the networks generated by Constructor are not strictly hierarchical, as are the knowledge repre- sentations produced by many of the concept formation techniques. Component Techniques CONSTRUCTOR makes use of traditional techniques of artificial intelligence as well as recent advances in both probabilistic representation and inference and statis- tical analysis. The probabilistic network technologies provide an intuitive representation for a joint prob- ability distribution as well as efficient techniques of probabilistic inference. From AI, we use techniques of heuristic search in order to efficiently find the structure which best represents the data. From statistics, we use the x2 test to decide when attributes are probabilisti- tally independent and cross-validation for selecting the “best connected” network. Probabilistic Networks: Probabilistic networks [S, 131 are used for representing and reasoning with un- certain beliefs, and are based on the well-established 'A singly connected (undirected) cycles. graph is one in Which there are no FUNG AND CRAWFORD 763 Figure 2: Probabilistic Network for the LED Problem theory of Bayesian probability. The primary inno- vation of probabilistic networks is the explicit repre- sentation of conditional independence relations. The representation of conditional independence relations in a probabilistic network is encoded in the topology of the network and can be illustrated with an example. In the network topology shown in Figure 2, the De- pressed Key node separates all of the LED segments from each other. This topology implies that the state of any of the LED segments is independent of the state of every other segment in the display given that it is known what key has been depressed. This inde- pendence is conditional however, since the LED states are dependent if it is not known which key has been depressed. The three-place relation symbol I will be used to denote conditional independence. For example, I(n;, nk, ni) denotes that ni is conditionally indepen- dent of nj given ?&k. There are two types of probabilistic networks: Bayesian and Markov. A Bayesian network contains directed arcs whereas a Markov network contains undi- rected arcs. Networks of both types represent a joint state space and a probability distribution on that space. Each node of a probabilistic network represents one component of the joint state space (i.e., a mutually exclusive and exhaustive set of states). For example, the Depressed Key node in Figure 2 represents the set of states (0 1 2 3 4 5 6 7 8 9). Each arc of a proba- bilistic network represents a relationship between the nodes it connects. For example, the arc between the Depressed Key node and the LED1 node indicates that the top element of the LED is probabilistically related to the key that is depressed (i.e., if there is no failure, it will turn on if the depressed key is 0, 2, 3, 5,7, 8, or 9). The form of the probability distribution for a net- work depends on its type. In a Bayesian network, a conditional probability is stored at each node where the conditioning variables are the node’s predecessors. In a Markov network, the nodes are grouped into cliques.2, and probabilistic quantities are associated with the cliques of a network instead of with the nodes them- selves. Useful inferences can be made given a probabilistic network that represents a situation and evidence about the situation. For example, given the evidence that LED2 LED4 LED6 and LEDrare illuminated, and the network shown in Figure 2, one could infer updated be- liefs about the “depressed key”. As one would expect for this example, the result would be relatively strong beliefs for “5” and “6” and relatively weak beliefs for the other possible values for “depressed key”. Several algorithms for inference have been reported, [2,10,13]. While each of these algorithms has significantly differ- ent methods for inference, they are equivalent in that given a probabilistic network and a particular query, they will infer exactly the same result. Every node in a probabilistic network has a Markov boundary that “shields” it from being affected by ev- ery other node outside the boundary. In other words, given the Markov boundary of a node, that node is conditionally independent of every other node in the network. Formally, the Markov boundary of a node ni in a network U is a subset of nodes S such that: I(ni,S, u\s\W) (1) and no proper subsets of S satisfy Equation 1. (The op- erator “\n denotes set difference.) The Markov bound- ary of a Bayesian network node is simply the union of the node’s predecessors, the node’s successors, and the predecessors of the node’s successors. The Markov boundary for a Markov network node is simply its neighbors. Figure 3 shows the Markov boundary for a Bayesian network node. The Markov boundary con- cept is crucial to the development of the CONSTRUC- TOR algorithm. Statistical Methods: When attributes take on cat- egorical values, the degree to which two attributes are statistically independent can be ascertained via the well known x 2 test of independence. For this test, the data are arranged in a two-way contingency table such that the possible values of one attribute make up the rows of the table, the possible values of the other attribute make up the columns, and the data propor- tions of the various attribute/value combinations fill the cells of the table. The conditional independence of attributes ai and aj given attribute c&k can be tested by preparing a three-way contingency table so that the values of oi and aj make up the rows and columns of the table, and the values of ok make up the layers. 2A clique is a s et of nodes in which every node set is a neighbor of every other node iu the set. in the 764 MACHINELEARNING Figure 3: A Markov Boundary Conditional independence is tested by computing sep arate x2 statistics for each layer and summing. The conditional independence of attributes ai and aj given a set of attributes (ok, ul, . . .} can be tested by simply forming a “macro” attribute, h, whose values consist of all combinations of values of the attributes in the conditioning set. In most instances of model fitting algorithms (e.g., CONSTRUCTOR), the eventual goal is to uncover a model that will be useful for prediction. It is an un- fortunate fact that the predictive performance of such data-derived models often falls short of expectations. The model will often be highly predictive when test cases are drawn from the data used to formulate the model, but less predictive when new data are pre- sented. This phenomenon is called “statistical over- fitting” and indicates that, on average, the fit of the model to the data used to build the model is much closer than the fit to new data. A simple mecha- nism for addressing the problem of overfitting is cross- validation [15], often characterized as a “leave some out” technique in which a model formed from a por- tion of the data is subsequently tested against the data left out of the model formation process. The use of cross-validation is not restricted to model assessment, however, since the approach can also be used to assist with model selection. Breiman et al. [l] describe a powerful use of cross-validation for model selection in the context of finding the “right sized” classification tree. Cross-validation is used in a similar manner in CONSTRUCTOR for finding the “best-connected” net- work. The input to the CONSTRUCTOR algorithmis ing set X consisting of N examples, {Zr , &, . Constructor Algorithm a train- Each example, z’i, consists of P discrete values {Xil,ee*,Xij,.e., Zip}, one for each of the P attributes uj in a set of attributes A. The value set vj is the pos- sible set of values for attribute oj. The value set can either be input by the user or derived from the training set, Ui Xij* In the faulty LED example, the first attribute, al, is an integer-valued attribute indicating the numeric key that was depressed. The rest of the attributes ca2 . . .a83 are boolean-valued attributes to indicate whether or not a particular LED component is illumi- nated. Therefore, vr is (0, 1, . . . ,9), and vr...s is (on dT3* The output of the CONSTRUCTOR algorithm is a Markov network U. For each attribute a!j in X, the network contains a node ni whose state space is the value set vi of %. Qualitatively, the network repre- sents the relevance relationships between attributes in the training set. Quantitatively, the network repre- sents an estimate of the joint probability distribution from which the samples are derived. The CONSTRUCTOR algorithm takes as its starting point the simple theoretical notion that the structure of the probabilistic network 24 can be identified if the neighbors (i.e., Markov boundary) of each node of the network are found. The Markov boundary Bi of a node ni in the network U is found by searching for the set of nodes which correspond to the smallest set of at- tributes S such that: (2) and no proper subsets of S satisfy Equation 2. In CON- STRUCTOR the determination of conditional indpen- dence is made with the x2 test. However, finding such relations in large data sets is computationally complex since every such test will include the consideration of every feature of the data set. CONSTRUCTOR therefore limits its attentions to dis- tributions which are “composable”. Such distributions have the property that I(& C, D) a (Vb E B)(Vd E D) I(b, C, d). (3) where b, d represent individual discrete random vari- ables and B, C, D represent sets of such variables. This property states that finding whether two sets of el- ements are conditionally independent of a third set can be determined by the much simpler computational task of checking whether every pairwise combination of elements in the two sets is conditionally independent of the third set and therefore simplifies the finding of Markov boundaries to finding the smallest set of at- tributes S such that: (VUj E U\S\ai) I(aitSs uj) “Composable” models are a much broader class of models topologically and contain the previously ex- plored Utreen models of [4, 141. FUNG AND CRAWFORD 765 begiu Constructor: (Training Set) compute list of o-levels; initialize; for each o-level do: select cross-validation sample; initialize frequency tables; find network; estimate network error; compute network complexity; end for report networks, errors, complexities; end Constructor. begin Find-Network: (o-level) find mutually independent attribute subsets; for each subset do: for each attribute do: find neighbors; end for end for instantiate Bayesian network; find cliques; estimate clique potentials; return network; end Find-network. Figure 4: Overall CONSTRUCTOR Algorithm. Figure 5: The Network Identification Algorithm. Besides its use to find Markov boundaries, CON- STRUCTOR makes use of “composability” in a pre- processing step to separate attributes into mutually- independent sets. I(S,t@,S2)~(V% E Si)(Vaj E S2)I(ai,Q,aj) (5) Figure 4 shows the overall CONSTRUCTOR algo- rithm. In this and subsequent listings, a step is un- derlined and shown in more detail in a later figure. Network identification is the heart of the CON- STRUCTOR algorithm and is designed to find the prob- abilistic network that best represents the training set given an input parameter, cy. This parameter is the standard statistical measure of type I error and controls how much confirmation is needed before in- dependence relations can be concluded in the pro- cess. Network identification works by searching for the Markov boundary of each attribute in the training set. Wrapped around network identification is cross- validation-used to select a level of cy: that will deliver the “best connected” network. The function of cross- validation in CONSTRUCTOR is to assess the perfor- mance of a set of induced networks, each of which has a different degree of “connectivity”. Each network in the set is obtained via the use of a different setting of the a! parameter. The network with the best cross-validated performance is then selected as the “best connected” network. Network Identification: Network identification in- volves successively finding the neighbors of each at- tribute in the training set. Unfortunately, the problem of finding the neighbors of an attribute involves search- ing through the power set of a set of possible neigh- bors and the computational complexity for exhaustive search thus grows exponentially with problem size. Managing the exponential process of finding neigh- bors is the primary challenge for the network identi- fication task. This is accomplished by a number of diverse mechanisms which include heuristic search. In addition, the CONSTRUCTOR algorithm uses other mechanisms to minimize the size of the set of possi- ble neighbors of an attribute. For’ example, the net- work identification process uses findings of previous search results in order to reduce the possible neighbors set. This is possible because neighbor relationships are symmetric: Neighbor-op(ni, nj) e Neighbor-of(nj, ni). In this way, finding the neighbors and non-neighbors for one attribute adds to the knowledge about the neighborhood relationships of every other attribute in the training set. In spite of these mechanisms, there will be cases in which the search process will be lengthy. There are, however, two immediate observations which can be made about such cases. First, we do not expect to face such situations very often. It has been claimed that training sets derived from real world situations will usually yield sparse graphs (i.e., only a few neighbors per attribute) since real world situations are inherently structured. In these cases, attribute neighbors can be found quickly. In cases which do not have this prop- erty, the resulting network will be densely connected and will probably be of little use since little qualitative information will be extractable from the network. Secondly, a feasible solution (i.e., set of neighbors) always exists- the whole set of possible neighbors. Therefore, in hard subproblems the process can always be terminated successfully by returning as a solution the full set of possible neighbors. The network identification algorithm is outlined in Figure 5 and described in more detail below. Subset Selection: The first step in network identi- fication requires using the x2 test to assess the pair- wise independence of all attributes in the training set. With these results, the attributes can be partitioned into independent sets of attributes. That is, for any pair of independent sets, each attribute in one set will be independent of every attribute in the other set. Lo- cating these subsets helps to reduce the complexity of the neighbor search process. 766 MACHINELEARNING begin Find-Neighbors: (attribute oj) root + p; known-neighbors + Nk; shortest-path t nl”; shortest-path t aj; spawn first level; repeat: select node to expand; current-path t current-path + node; when shortest-path > current-path: spawn and coalesce children; for each child do: if independent (uj ,intervening nodes,child) then prune child; if all children pruned then shortest-path +- current-path; end for end when until: no nodes can be expanded; return shortest-path; end Find-neighbors. Figure 6: The Neighbor Identification Algorithm. Neighbor Identification: Finding the neighbors for every attribute in a training set is an iterative search process based on finding the Markov boundary for each attribute. As discussed earlier, the Markov boundary is the smallest set of attributes that makes the target attribute conditionally independent of every other attribute in the training set. Finding the neighbors of a particular attribute aj, outlined in Figure 6, begins with the instantiation of an attribute tree, consisting of attribute nodes, each of which represents an attribute in the training set. The root node of an attribute tree always represents the target attribute aj (i.e., the attribute for which neigh- bors are being sought). Each branch of a partial at- tribute tree (Le., the path from the root node to a leaf attribute node) represents a hypothesis that the attributes associated with the attribute nodes in that branch make up the Markov boundary for the target attribute. The search for the Markov boundary of attribute oj begins by instantiating the root node of the attribute tree as oj. An attribute node for each member of the set of known neighbors, nf’, is then sequentially added to the attribute tree in a single branch rooted at oj. The set of candidate new neighbors, n/“, is initialized to J\C?j3\Mk\=@, where Sal” is the set of nodes kn not to be neighbor ‘For the very first attribute to be explored, n/& = a/” = and so the initial set of candidate neighbors consists of AP = A\(cLj). The first step of the search process is to choose a leaf node for expansion. Initially there will only be one leaf node-the end of the A/k branch. Expansion of a node simply means that a child node is instantiated for every member of nl” and takes place only if expansion will not create a branch whose length exceeds that of the current shortest path. Note that to avoid duplication, each new branch is merged with any existing branch that contains exactly the same attributes. After ex- pansion, a x2 test is then carried out to determine if aj is conditionally independent of each of the new at- tribute leaf nodes given the intervening branch. If so, a new shortest path has been found. If not, the newly instantiated nodes are pruned away and another leaf node is chosen for expansion. The search continues until there are no leaf attributes to expand and the shortest path is then returned as the set of neighbors for the attribute. This search is performed for each attribute in the training set. Once completed, a probabilistic network is instantiated in which each attribute is represented by a node whose state space is the value set of its associated attribute. The structure (i.e., connectivity) of the network is determined by placing an undirected arc between each pair of neighbors. Given the network structure, arcs are added which ‘KU-in” [16] the network and then the nodes in the net- work are grouped into cliques. A joint probability dis- tribution for each node in the clique is then estimated using the empirical distribution found in the training set. Search Heuristics: The computational efficiency and therefore the viability of CONSTRUCTOR depends on the overall strength of the search heuristics that can eventually be identified. We discuss two of the more powerful heuristics which have been identified. First, since computational cost grows exponentially with the number of attributes that must be examined in the neighbor search, it makes sense to first explore those attributes which are likely to have only a few neighbors. Because it is unlikely that attributes that are pairwise independent of the target node are neigh- bors of the target node, this heuristic simply states that neighbors should first be located for those at- tributes with the largest number of pairwise indepen- dencies. Note that, because of the neighbor symmetry relationship described earlier in this section, locating any neighbor relationships will reduce the search space for subsequent neighbor relationships and so it is eI%i- cient to do the shorter searches first. network is a fu expansion, first select that node with the largest de- FUNG AND CRAWFORD 767 Table 1: LED1 Dependency On LED2 and LED3 11 pendency on the target node given the current state of the tree. Examples To illustate the algorithm’s operation, we describe the results obtained when CONSTRUCTOR is applied to the digit recognition training set. In particular, we focus on the search to discover the neighbors of attribute LEDI. The pairwise independence relationship be- tween LED1 and all other attributes is first exam- ined and it is discovered that LED1 is independent (at ar = 0.001) of all attributes save for LED7, LED5, and Depressed Key. All other attributes are therefore pruned from the search tree. The remaining attributes (children of the LED2 node) are examined and an ex- pansion order is computed. The “dependence” heuris- tic forms an order based upon the degree of depen- dence between children and parent. Since LED7shows the highest degree of dependence with LEDl, it is ex- panded first. It is found that LED1 and LED2 through LED6 are conditionally independent given LED7, but since LED1 and LED7 are found to be conditionally independent given Depressed Key, LED7 cannot be a neighbor of LED1 and so it, and its children are pruned. The Depressed Key node is expanded next and it is found that all other attributes are condition- ally independent given Depressed Key and are there- fore pruned from consideration. The Depressed Key attribute makes up a feasible set of Markov neighbors for the LED1 attribute and since no other path can possibly be shorter than this one (a path of length l), the search is terminated. The neighbors for all attributes are located in the same manner and the final result of this process is a network with exactly the same topology as that illus- trated in Figure 2. Digit Recognition with Loop: For this training set, we introduce an additional source of error into the model for our already faulty display. In this model, the state of LED1 is determined entirely by the states of LED2 and LED.??, both of which depend upon the state of Depressed Key. The dependencies are summarized in Table 1. The introduction of this additional source of error in the digit recognition model amounts to the introduc- tion of a loop in the Bayesian network representation of the model, as shown in Figure 7. Y LED7 I Figure 7: Digit Recognition Network with Loop CONSTRUCTOR can uncover this structure when pro- vided with a set of training examples generated from the probability model. The final result is a Markov network with the same topology as the network in Fig- ure 7 with the exception of an additional arc between LED2 and LEDJ. This demonstrates, in the simplest possible way, the feasibility of CONSTRUCTOR recover- ing models with loops. iscussion In this paper, we have described the CONSTRUCTOR system for inducing probabilistic models from data. The motivation for CONSTRUCTOR is that previous structure-finding algorithms have been limited to trees and that such structures are often too restrictive for ad- dressing real problems. The basic idea of CONSTRUC- TOR is theoretically sound-it is to construct a net- work by finding the neighbors of each node through a heuristic search process. CONSTRUCTOR operational- izes this theoretical idea through the application of modern statistical techniques and addresses the com- putational complexities of the task to make significant progress towards a practical machine-learning system. CONSTRUCTOR has been tested not only on train- ing sets generated from probability models like those in Section 4, but has been tested recently on real data in an information retrieval application [6]. For those training sets generated from probability models, CON- STRUCTOR was able to reconstruct the models and for the information retrieval spplication, CONSTRUCTOR yielded a network which was intuitive to an expert and performed well in practice. Although CONSTRUCTOR can be run without user intervention, we strongly believe that users often have important insights that may be easy to acquire and may significantly improve the process of structure learning. In order to benefit from these insights, CON- STRUCTOR allows the user to interact with the sys- tem in every phase of the algorithm. For example, the 768 MACHINE LEARNING user can choose to have the structure for the entire set of attributes be discovered using the search heuris- tics, or may wish to choose to find the neighbors for a single attribute himself. In the search for the neigh- bors of a particular attribute, the user can observe the growth of the search tree and can control the order in which attribute nodes will be expanded. The user can also control pruning and cross-validation and can view intermediate results such as pairwise-independencies, neighbor relationships and the networks which have been found. Future Research: The primary focus of subsequent research will focus on addressing problems created by the exponential search space in neighbor identification and problems imposed by the “curse” of dimension- ality - the observation that high-dimensional space is inherently sparsely populated. For CONSTRUCTOR, the curse of dimensionality is manifested in low cell counts in the contingency tables used to assess inde- pendence via the x2 test. One approach to this prob- lem is to reduce the dimensionality of the training set and, to this end, some relatively new dimension re- ducing techniques such as projection pursuit [9] will be investigated. Two other important areas for research are: enlarg- ing the class of distributions which CONSTRUCTOR can recover and exploring parallel implementations. While CONSTRUCTOR recovers gene& graphical structures, there are some classes of distributions that are cur- rently not adequately recovered with CONSTRUCTOR. To address this issue, it is possible to use the condi- tional independence test of Equation 2 as a heuristic and do an exact test when this heuristic is successful. Much of the CONSTRUCTOR algorithm is inherently parallel. It therefore appears likely that substantial performance gains could result from implementation of CONSTRUCTOR on a parallel architecture. References [l] L. Breiman, J. H. Friedman, R. A. Olshen, and C. J. Stone. Classification and Regression l%ees. Wadsworth, Belmont, 1984. [2] K. C. Chang and R. M. Fung. Node aggregation for distributed inference in bayesian networks. In Proceedings of the Iith IJCAI, Detroit, Michigan, August 1989. [3] Peter Cheeseman, James Kelly, Matthew Self, John Stutz, Will Taylor, and Don Freeman. Auto- class: a bayesian classification system. In Proceed- ings of the Fifth International Conference on Ma- chine Learning, Ann Arbor, Michigan, June 1988. [4] C. K. Chow and C. N. Liu. Approximating dis- crete probability distributions with dependence trees. IEEE lkans. on Info Theory, 1968. [5] D. H. Fisher. Knowledge acquisition via incre- mental conceptual clustering. Machine Learning, 2(2):139-172, September 1987. [6] R. M. Fung, S. L. Crawford, L. Appelbaum, and R. Tong. An architecture for probabilistic concept-based information retrieval. In Proceed- ings of the 13th International Conference on Re- search and Development in Information Retrieval, September 1990. [7] John Gennari, Pat Langley, and Doug Fisher. Models of incremental concept formation. Arti- ficial Intelligence, 40(1-3):11-61, 1990. [8] R.A. Howard and J.E. Matheson. Influence dia- grams. In R.A. Howard and J.E. Matheson, edi- tors, The Principles and Applications of Decision Analysis, vol. 11, Menlo Park: Strategic Decisions Group, 1981. [9] P.J. Huber. Projection pursuit. The Annals of Statistics, 13(2):435-475,1985. [lo] S. L. Lauritzen and D. J. Spiegelhalter. Lo- cal computations with probabilities on graphical structures and their application in expert systems. Journal Royal Statistical Society B, 50, 1988. [ll] M. Lebowitz. Experiments with incremental con- cept formation: UNIMEM. Machine Learning, 2(2):103-138, September 1987. [12] R.S. Michalski and R.E. Stepp. Learning from ob- servation: conceptual clustering. In R.S. Michal- ski, J.G. Carbonell, and T.M. Mitchell, editors, Machine Learning: An Artificial Intelligence Ap- proach, Morgan Kaufman, 1983. [13] J. Pearl. Probabilistic Reasoning in Intelligent Systems: Networks of Plausible Inference. Mor- gan Kaufmann, San Mateo, 1988. [14] G. Rebane and J. Pearl. The recovery of causal poly-trees from statistical data. Proc., 3rd Work- shop on Uncertainty, 1987. [15] M. Stone. Cross-validatory choice and assessment of statistical predictions. Journal of the Royal Sta- tistical Society, 36:111-147,1974. Series B. [16] R. E. Tarjan and M. Yannakakis. Simple linear- time algorithms to test chordality of graphs, test acyclicity of hypergraphs, and selectively reduce hypergraphs. SIAM J. Comput., 13:566-579, 1984. FUNG ANDCRAWFORD 769
|
1990
|
151
|
906
|
Generalization with Taxonomic Information Alan M. fiisch and C. David Page Jr. Dept. of Computer Science and Beckman Institute University of Illinois 405 North Mathews Ave. Urbana, IL 61801 Abstract This paper studies sorted generalization-the gener- alization, with respect to an arbitrary taxonomic the- ory, of atomic formulas containing sorted variables. It develops an algorithm for the task, discusses the al- gorithm and task complexity, and presents semantic properties of sorted generalization. Based on its se- mantic properties, we show how sorted generalization is applicable to such problems as abduction, induction, knowledge base vivification, and analogical reasoning. Significant distinctions between this work and related work with taxonomic information arise from the gen- erality of the taxonomic theories we allow, which may be any first-order taxonomic theories, and the seman- tic completeness properties of sorted generalization. Introduction Unification plays an important role in many auto- mated deduction systems. It comes in many forms including term unification, string unification, unifica- tion with built-in equality, sorted unification, and fea- ture structure unification, as well as variations of these. The common feature of all these forms of unification is that they compute maximal lower bounds in some partially-ordered set of syntactic objects. Turning uni- fication on its head yields an operation called “general- ization,” or “anti-unification,” that computes minimal upper bounds. As with unification, one can imagine many forms of generalization. We conjecture that gen- eralization will play a role in non-deductive reasoning (e.g., abduction, induction and analogy) as important as that played by unification in deductive reasoning. (Unification has some non-deductive applications, and, as we shall see, generalization can have deductive ap- plications.) This paper studies sorted generalization, the dual of sorted unification. Whereas ordinary gen- eralization, which has been studied by Plotkin [1970; 19711, Reynolds [1970], Lassez, Maher and Marriott ‘This research was partially funded by a grant from Mc- Donnell Douglas Corporation. The writing of the paper was completed while the first author was on leave at IBM T. J. Watson Research Center. [1988], and Lassez and Marriott [1987], is a syntac- tic operation that operates solely on the basis of ex- pression structure, sorted generalization takes into ac- count a body of taxonomic information. Giving special treatment to taxonomic information has been a fruit- ful approach to the construction of AI reasoning sys- tems. For example, sorted logics distinguish taxonomic information from other information, and their deduc- tive systems can exploit this distinction by handling the taxonomic information with special-purpose meth- ods such as sorted unification. This paper formalizes the sorted generalization problem, formulates an algo- rithm for its solution, discusses the complexity of the problem and the algorithm, and shows how sorted gen- eralization can be applied to problems in abduction, induction, knowledge base vivification and analogical reasoning. Before formalizing the task, let’s intuitively examine an example of sorted generalization and compare it with unsorted generalization. The examples in this paper use the following taxonomic information: & = {Vz UNIV(2), GOOD-COOK(mother(c~yde)), GOOD-COOK( moi!he7+nbo)), ELEPHANT( ChJdC), CIRCUS-ANIMAL( C&h?), ELEPHANT&nbo), CIRCUS-ANIMAL(jumbo), \da: ELEPHANT(s) -+ ELEPHANT(mother(Z))). Example 1 Let E = { eats( clyde,peanuts), eats( jumbo,peanuts)}. E has two maximally-specific sorted generalizations with respect to Cl: eats( 2:ELEPHANT ,peanuts) and eats(y:CIRCUS-ANIMAL,peanuts). E has a most specific unsorted generalization: eats( z,peanuts). As Example 1 illustrates, there are cases in which there is no most specific sorted gener- alization. Neither eats(z:ELEPHANT,peanuts) nor eats(y:CIRCUS-ANIMAL,peanuts) is more specific than the other. Notice also that the sorted generalizations are more specific than the unsorted generalization.’ ‘Section 2 precisely defines “specific” and “general.” FRISCH AND PAGE 755 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Sorted generalizations sorted generalizations. are never less specific than un- Formalizing the Problem We formalize the sorted generalization problem us- ing Sorted First Order Predicate Calculus (SFOPC), a language that extends First Order Predicate Calcu- lus (FOPC) with special notation for encoding taxo- nomic information [Frisch, 19891. SFOPC is no more expressive than FOPC; each sentence of SFOPC is log- ically equivalent to one of FOPC. SFOPC is written with a lexicon that contains the usual function and predicate symbols and, in addition, contains a count- able set of sort symbols. Typographically, sort sym- bols are written entirely in upper-case. Semantically, a sort symbol denotes a nonempty subset of the do- main, called a sort. SFOPC contains two kinds of expressions, “A-expressions” and “S-expressions.” We refer to A-expressions that are terms as “A-terms” and A-expressions that are formulas as “A-formulas,” and we use “S-term” and “S-formula” analogously for S- expressions. We say that an expression is atomic if it is a term or an atomic formula. Roughly, the goal of sorted generalization is to find the maximally-specific generalizations of a set of atomic A-expressions with respect to a theory consisting of S-expressions. A-expressions are similar to ordinary FOPC expres- sions except that they may contain sorted variables, variables that are restricted to range over specified sub- sets of the domain. A sorted variable is a pair, Z:T, where z is a variable name and r is a sort symbol. For clarity, variables are sometimes writ ten in angle brackets, such as (z:T). r and w are used as meta- linguistic symbols that always stand for sort symbols. The meanings of A-expressions are similar to those of FOPC expressions, except for the following rules for quantification over sorted variables. In these semantic rules [+I M’ e is the semantic value assigned to an ex- pression or symbol 4 by a model M and an assignment to variables e, and e[d/z] is the assignment to variables that is identical z is assigned d. to e with the possible exception that [Vx:r $?gM1’ = True if, and only if, for every pxzT dn”+ = True if, and only if, for some d E 1[7j”+, pn”+[+l = True The role of S-expressions is to express relationships among the sorts and the sortal behavior of the func- tions. - S-expressions are constructed like ordinary ex- pressions of FOPC, except they contain no ordinary predicate symbols; in their place are sort symbols act- ing as monadic predicate symbols. Hence, every atomic S-formula is of the form 7(t), where T is a sort sym- bol and t is an ordinary term. S-formulas are assigned truth values in the usual Tarskian manner. A finite satisfiable set of S-sentences is called a sort theory and is frequently denoted by X. Cr is a simple example of a sort theory. Sort theories may also contain sentences of other forms, such as DOG(fied) V ELEPHANT(fied) and v’z DOG(z) A YOUTH(z) ---) PUPPY(x). We are often interested in whether one sort is a sub- set of another sort according to a given sort theory C. T’ is a subsort of T according to X if, and only if, C k Vz T'(X) + T(Z); we write 7l-4~7. To en- sure that any two terms have some generalization, as in the unsorted case, we augment every sort theory with a sort symbol, UNIV, representing the sort con- sisting of the entire domain (the universal sort). We therefore assume that each sort theory contains the S- sentence Vx UNIV(2). It follows from this assumption that T 5~ UNIV for every sort symbol T and every sort theory C. Note that a variable of the universal sort behaves as an unsorted variable. Unification and generalization for FOPC formulas are defined in terms of an instantiation ordering, that of substitutions. Sorted generalization, as well as sorted unification, is defined in terms of an analogous instantiation ordering for SFOPC, that of well-sorted substitutions. Intuitively, a well-sorted substitution is a substitution that respects the sorts of the variables. More precisely, a substitution 0 is well-sorted relative to a sort theory C if, and only if, for every variable Z:T, (x:7)6 is a term t such that c b vT(t)i2 Thus, for ex- ample, 61 = {clyde/z:ELEPHANT} is a well-sorted sub- stitution relative to Cl, but 192 = {~~~O/Z:ELEPHANT} is not. An A-expression e is said to be C-more gen- eral than e’ if e’ = e0, for some substitution 8 that is well sorted relative to C. We also say that e C- subsumes e’, and we write e>xe’. An A-expression that C-subsumes each member of a set of A-expressions is a C-generalization of the set. The most general common instance, e, of a set, E, of atomic expressions may be found with unification and characterizes the common instances of E: an ex- pression is a common instance of E if, and only if, it is an instance of e. Likewise, the most specific gen- eralization, g, of E characterizes the expressions that are more general than every expression in E: an ex- pression is more general than every member of E if, and only if, it is more general than g. We would like to use a C-generalization to similarly characterize the A-expressions that are C-more general than any given set of atomic A-expressions. But Example 1 shows that there may be no most specific C-generalization. An analogous characterization therefore requires a set of maximally specific C-generalizations, none C-more general than another. Specifically, the goal of sorted generalization is to find a complete set of incomparable C-generalizations (or CIGx) for a given set of atomic 2For any expression $, ‘J$ denotes the universal closure of +, the result of universally quantifying all free variables of 4. Similarly, 34 d enotes the existential closure of $. 756 MACHINE LEARNING A-expressions. A set G is a CIGI: of a set E of atomic A-expressions if, and only if, o each member of G is C-more member of E [Correctness], general than every o any atomic A-expression that is C-more general than every member of E is X-more general than some member of G [Completeness], and o no member of G is C-more general than any other [incomparability]. Some sets of atomic A-expressions have no C- generalization; the CIGx of any such set is the empty set. For example, there is no A-expression that is C- more general than two atomic A-formulas with dif- ferent predicate symbols. More completely, a set of atomic A-expressions has an empty CIGx if, and only if, it contains both A-terms and atomic A-formulas or contains atomic A-formulas with different predicate symbols. Might other sets have more than one CIGD? Can a CIGI: be infinite? Lemma 1 AZZCIGxs of a set of atomic A-expressions are variants. That is, any CIGx can be obtained from another by uniformly renaming variables. Lemma 2 There are only a finite number of A- expressions C-more general than a given A-expression, up to renaming. Corollary 3 Every CIGx is finite. The following two examples of sorted generalization illustrate additional distinctions between sorted and unsorted generalization, which a sorted generalization algorithm must accommodate. In Example 2 “mother” is a function symbol, so E is a set of terms. Example 2 Let E = { mother( Clyde), mother(jumbo)}. Then a CAGE, of E is {y:C00D-COOK, mother(a::ELEPHANT), mother(z:CIRCUS-ANIMAL)}, and a most specific unsorted generalization of E is mother(x). In Example 2, ~:GOOD-COOK Xi-subsumes neither mother( z:ELEPHANT) nor mother(z:CIRCUS-ANIMAL). This contrasts with the unsorted case, where a variable always subsumes any other term. We refer to a vari- able that C-subsumes all members of a set of A-terms as a “variable generalization” of that set. We refer to a non-variable A-expression that C-subsumes all mem- bers of a set of A-expressions as a “structured gener- alization.” A sorted generalization algorithm cannot assume that a variable generalization of a set of A- terms C-subsumes every structured generalization of that set. It must therefore compare the variable gen- eralizations with the structured generalizations. Because variable generalizations need not C- subsume structured generalizations, members of a CIGz may have different structures. In the CIGE1 of Example 2, one generalization is a variable while the other two are built from the function symbol “mother.” Such structural differences can become more remark- able as the expressions being generalized grow more complex. That variable generalizations need not C- subsume structured generalizations is a result of func- tion polymorphism. A function is .polymorphic if terms built from that function’s symbol may denote mem- bers of different sorts based on the arguments in the terms. mother is a polymorphic function, because whether a term built from “mother” denotes a member of the sort GOOD-COOK depends on the argument to mother. If the argument is Clyde or jumbo, the term denotes a good cook; otherwise it does not. If mother were instead a monomorphic function, that is, if all mothers were known to be good cooks, the variable ~:GOOD-COOK would &-subsume any structured gen- eralization. Example 3 Let E = {Zoves( cZyde,mother( Clyde)), Eoves(jumbo,mother(jumbo))}. Then a CIGz, of E is { Zoves( 2:ELEPHANT) mother( z:ELEPHANT)), Zoves(a::ELEPHANT, mother(r:CIRCUS-ANIMAL)), Zoves(z:ELEPHANT, y:GOOD-COOK), ZOVeS(XCIRCUS-ANIMAL, mother(z:ELEPHANT)), Zoves(z:CIRCUS-ANIMAL, mother(z:CIRCUS-ANIMAL)), Zoves(z:CIRCUS-ANIMAL, y:GOOD-COOK)}, and a most specific unsorted Zoves(x,mother(x)). generalization of E is The interesting point of Example 3 is that the CIGx:, of E is built from the cross-product of CIGx:,s of the parts-the arguments-of the formulas in E. Care is required in building the CIGEc, to ensure that variables repeat in exactly the right places, that is, that variable co-references are correct. There might also be variable generalizations of E; in this instance there are not, because E contains A-formulas rather than A-terms. A Sorted Generalization Algorithm The 2-SG algorithm, shown in Figure 1, computes the CAGE of any pair of atomic A-expressions. The 2-SG algorithm uses a bijection 4 from any triple of the form (t, s, T) to a variable of sort T.~ To avoid accidental variable collisions, we further stipulate that the range of $ is disjoint from the alphabet from which the A- expressions input to the algorithm are built. 3This function is similar to the bijection between vari- able names and pairs of terms that is usep in the anti- unification (unsorted generalization) algorithm of [Lassez et al., 19881. FRISCH AND PAGE 757 I Input: Two atomic A-expressions, (~1 and (~2, and a sort theory X. Output: A CIGI: of al and ar2. IfcQ= ar2 then return {err}. If ~1 and (~2 are A-formulas with different predicate symbols or one is an A-term and the other an A-formula, then return ( }. If cy1 and CQ are p(sr, 52, . . . . So) and p(tl, $2, . . . . t,), respectively, where p is a predicate/function symbol, and 81, s2 , . . . . s,, tl, t2, . . . . t, are A-terms, then Let Structured-Set = {~(TI, ~2, . . . . TV) 1 Q E 2-SG(si, t;, C), for all 1 5 i 5 n}. Otherwise, Let Structured-Set = { }. If al and ~2 are A-terms, then a. Let Variable-Set = {4(ar, (~2, T) 1 T is any sort symbol occurring in X for which C b V~(al), C /= VT(Q~), and for every e E Structured-Set C k VT(e)}. b. For each variable x:r E Variable-Set: If there is another variable y:w remaining in Variable-Set such that w & T, then Remove X:T from Variable-Set. Otherwise, Variable-Set = { }. Return Structured-Set U Variable-Set. Figure 1: The 2-SG Algorithm Theorem 4 (Z-SG Algorithm Correctness) Given oracles for determining whether or not any given universally-closed atomic S-formula follows from C and whether or not T -(x w for any two given sorts T and w, the Z-SG algorithm halts and returns a CIGx of aI and a2. The algorithm interacts with the sort theory through two kinds of taxonomic queries. It asks whether the sort theory entails a given universally-closed atomic S- formula, and it asks whether 3~ is true of a given pair of sorts. Therefore oracles, or decision procedures, for these taxonomic queries are sufficient for computation of sorted generalization; if the taxonomic queries are decidable for a given sort theory, then sorted general- ization relative to that sort theory is computable. The converse is also true; if sorted generalization is com- putable relative to a given sort theory, then the tax- onomic queries are decidable relative to that theory because any algorithm for sorted generalization can be used to answer the queries. Therefore, oracles for the taxonomic queries are necessary, as well as sufficient, for sorted generalization. In general such oracles can- not be computed, but restrictions can be placed on the sort theory so that they can be. The reader is encouraged to walk through the 2 SG algorithm’s computation of the generalizations in the examples. Let’s take the examples in order, con- sidering how the algorithm addresses the major is- sue raised by each. Example 1 shows that a set of atomic A-expressions may have more than one maximally-specific sorted generalization. The algo- rithm therefore returns a set rather than a single gen- eralization. Example 2 shows that variable general- 758 MACHINE LEARNING izations are not guaranteed to C-subsume structured generalizations. Therefore, step 4 of the 2-SG algo- rithm compares variable generalizations with struc- tured generalizations as it builds the Variable-Set. No- tice that the algorithm never removes a structured generalization. Structured generalizations cannot C- subsume variable generalizations, and, because of the way they are built, no structured generalization built by 2-SG C-subsumes another. Example 3 illustrates the cross-product operation inherent in generalizing atomic A-expressions involving functions or predicates with more than one argument. It also shows that variables must be named properly to ensure correct variable co-references when cross-products are taken. Step 3 of the 2-SG algorithm builds structured gen- eralizations of atomic A-expressions using the cross- product of the sorted generalizations of their compo- nents. Correct variable co-references are ensured by the bijection 4 used for variable naming in step 4, the only step at which new variables are introduced. For example, if 4 maps (clyde,jUmbo,ELEPHANT) to Z:ELEPHANT during generalization of the first argu- ments in the A-expressions loves( clyde,mother( Clyde)) and loves(jumbo,mother(jumbo)), then during gener- alization of the second arguments, it maps an in- put to Z:ELEPHANT if, and only if, that input is also (clyde,jumbo,ELEPHANT). Thus a variable repeats in a C-generalization only if a pair of A-terms, one from each input A-expression, repeats in the same way in the input A-expressions. Note that repetition of a pair of A-terms in the input A-expressions does not guarantee a corresponding variable repetition in every C-generalization, because the pair of A-terms may be generalized in more than one way. The CIGx Decomposition Theorem, which follows, shows that the 2-SG algorithm can be used repeatedly to generalize three or more atomic A-expressions. Theorem 5 (CIGx Decomposition Theorem) Let A and B be sets of atomic A-expressions and let C be a sort theory. Then {x 1 x E CIGx(a, b) for some a E CIGr:(A), and b E CIGx(B)} is a complete set of C-generalizations of A u B. The CIGZ: Decomposition Theorem says nothing about whether the complete set of C-generalizations contains comparable A-expressions, that is, whether it is a CIGx. In general it may not be. But given the oracles used in the 2-SG algorithm, the complete set can be filtered into a CIGx by the following proce- dure. Let E be the set of A-expressions we wish to filter. From E choose distinct A-expressions er and e2 such that er >x e2 and remove el from E, until no such A-expressions remain in E. It follows from Lemma 2 that E is initially finite. Given the oracles, >x is decidable, so this procedure halts and returns a CIGI: that characterizes the same set as the original complete set of C-generalizations. Algorithm and Problem Complexity We have seen that sorted generalization is computable given oracles for the taxonomic queries. But given polynomial-time response to the taxonomic queries, the 2-SG algorithm requires exponential time in the worst case. Exponential time is a requirement of the problem itself because, in the worst case, the size of the CIGx of two atomic A-expressions is exponential in the size of the smaller A-expression. The size is O(tn), where t is the number of sort symbols in C and n is the size of the smaller A-expression. The exponential size is a result of the cross-product operation. We can represent CIGxs more compactly by using an explicit cross-product operator rather than computing cross-products. A CIGx can always be rep- resented in size polynomial in the size of the atomic A- expressions generalized and the number of sort sym- bols available. We can modify the 2-SG algorithm to compute such a compact representation. Unfortu- nately, the problem requires an exponential time algo- rithm (assuming P # NP) even when we allow a com- pact representation of the CIGxs and are guaranteed polynomial-time (in t and n) response to taxonomic queries. We call such a version of the problem “sim- plified sorted generalization.” Theorem 6 Simplified sorted generalization is NP- hard. The proof of this theorem shows that 3-Satisfiability is polynomially reducible to simplified sorted general- ization. This result does not depend on any partic- ular compact representation of CIGxs. It holds for any representation of CIGxs with which we can test in polynomial time whether a given A-expression is a member of a given CIGx. This complexity result indicates that efficient re- sponse to taxonomic queries is not enough to allow effi- cient sorted generalization. It is possible, nonetheless, to restrict the taxonomic information in other ways to guarantee polynomial-time computation of CIGcs in a compact representation. It is possible as well to restrict the taxonomic information so that the size of all CIGxs is polynomial in the size of the input. The study of such restrictions is an interesting area for fur- ther work. It is also possible to compute the compact representation of a complete set of C-generalizations in polynomial time, given polynomial-time response to taxonomic queries, if the set is allowed to contain com- parable A-expressions. Thus the complexity of simpli- fied sorted generalization is in ensuring incomparabil- ity. Applications So far we have ordered atomic A-expressions by well- sorted substitutions, but we have said nothing about the semantic relationships between A-expressions. We could not have done so, as we have not even specified whether the variables in the A-expressions are univer- sally or existentially quantified. It turns out that there are correspondences between the ordering 2x, based on well-sorted substitutions, and orderings based on entailment. It is because of these correspondences that we can use the algorithm for various reasoning tasks. The first application we consider might arguably be classified as abduction or induction. Let 0, a set of observations, be any finite set of sentences, and let B, a body of background information, be any finite satisfi- able set of sentences. Informally, the problem is to find an hypothesis, h, that taken with the background in- formation, B, explains each of the observations. More formally, by “explains” we mean that h is consistent with B, and h together with B entails ~0 (~0 is the conjunction of the observations). We say that h is B- stronger than ~0 and ~0 is B-weaker than h. But there may be many such hypotheses, some better than others, so we would like to find the best one, or charac- terize the set of all hypotheses. The weakest hypothe- sis with respect to the background theory characterizes the set of all hypotheses, but again there may be no single weakest hypothesis. We therefore want a com- plete set of incomparable hypotheses, that is, a set H of sentences from an hypothesis language such that e every member of H is B-stronger than AO, o any sentence in the hypothesis language that is B- stronger than A0 is B-stronger than some member of H, and e no member of H is B-weaker than any other one. It is unclear whether to classify this problem as ab- duction or induction. In abduction there may be only a FRISCH AND PAGE 759 single obser vation, and the background information is normally a causal theory. Abduction typically finds hypotheses that explain the observation(s) through chaining, possibly extensive, using modus ponens. In- duction, on the other hand, frequently works with many observations and produces a general, universally- quantified sentence that requires less inference to entail the observations. So whereas background information is crucial to abduction, it is less prominent, sometimes even absent, in induction . The current problem seems to include many instances of both abduction and in- duction. Let’s consider a special case of the problem, in which 0 may be any finite set of universally-closed atomic A- formulas and B may be any sort theory. We wish to ex- plain the observations with a universally-closed atomic A-formula. As the reader may have guessed, the prob- lem can be solved by sorted generalization. The CIGx of the atomic A-formulas is a complete set of incom- parable hypotheses, once its formulas are universally closed. Why? Because the instantiation ordering >E over atomic A-formulas is equivalent to the entailment ordering of those A-formulas, universally closed. Theorem 7 Let I= be a sort theory and let cx1 and cv2 be atomic A-formulas. CY~ 21: cy2 if, and only ij, {k&l} u c t= vcq3. Therefore the universal closure of any member of the CIGz of a set of observations is a maximally-weak hy- pothesis relative to C. If we allow disjunction in the hypothesis language, there are yet C-weaker hypothe- ses. In fact, there is a B-weakest one, which is the disjunction of the universal closures of the A-formulas in the CIGx. We have seen how atomic A-formulas are ordered by entailment when variables are universally quanti- fied. The next problem we consider involves exist en- tially quantified variables. The problem is vivification, a promising approach to efficient deduction [Borgida and Etherington, 1989; Levesque, 1988]. The premise of vivification is that much of the complexity of au- tomated deduction arises from incomplete knowledge in knowledge bases (KBs), in particular from disjunc- tions leading to reasoning by cases. Vivification weak- ens the knowledge base in order to remove such dis- junctions. To use an example from Levesque [1988], suppose our KB includes age(fred,?l) V age(fred,72). Many of the interesting results of this fact follow from Fred being in his early seventies or, even more gener- ally, being a senior citizen. If we know that 71 and 72 belong to the category low-seventies, we may use sorted generalization to replace age(fied,71) V age(fred,72) with %:LOW-SEVENTIES age(fred,z:LOW-SEVENTIES). As another example, if our KB includes the disjunction age(fred,‘lO) V age(joe,70), and the background infor- mation specifies that Fred and Joe are both golfers and dentists, a sorted generalization algorithm will find two vivifications of the disjunction: %:DENTIST age(s:DENTIST,79) and &GOLFER age(y:GOLFER,70). It is then necessary to decide which vivification will re- place the disjunction. It may be best to replace it with the conjunction of the vivifications, because replacing one formula with another of equal or greater size can increase efficiency if the replacement eliminates some reasoning by cases. But does sorted generalization nec- essarily give the desirable vivid form of all disjunc- tions? Does it give the strongest consequents of a dis- junction together with specified knowledge from the KB? We now see that it does, where the disjuncts and consequents are equivalent to ground or existentially quantified atomic A-formulas and the background in- formation is taxonomic. Vivification is a special case of the following truth- preserving inference problem. Let L3 and B be finite sets of sentences, where B is satisfiable. Find a set C of sentences from a specified “consequent” language such that a every member of C is B-weaker than VD (VD is the disjunction of the sentences in D), e any sentence in the consequent language that is B- weaker than VD is B-weaker than some member of C, and e no member of C is B-stronger than any other one. Sorted generalization solves all instances of this prob- lem in which D is a set of atomic A-formulas, exis- tentially closed, B is a sort theory, and C is allowed to be any set of existentially-closed atomic A-formulas. It solves these instances because, according to the follow- ing theorem, the instantiation ordering 2~ on atomic A-formulas is also equivalent to an entailment ordering on those A-formulas, existentially closed. Theorem 8 Let C be a sort theory and let crl and cu2 be atomic A-formulas. arl 2~ cv2 if, and only if, (3cy2) u c i= 3q. Finally, various methods for falsity-preserving and truth-preserving generalization are used in algorithms for analogical reasoning. Reasoning with taxonomic information is a large part of many such methods. Therefore, based on Theorems 7 and 8, we suggest that sorted generalization is a useful tool for analogical rea- soning, whether truth-preserving or falsity-preserving generalizations are needed. For example, Leishman’s [1989] analogical tool uses truth-preserving general- ization of terms with respect to taxonomic informa- tion in finding constrained partial correspondences be- tween conceptual graphs. These correspondences pro- duce a more general conceptual graph. It follows from the truth-preserving character of this generalization method that the taxonomic “concepts” used in the more general graph may be understood as existentially quantified sorted variables. Relationship to Other Work The present work differs in two major ways from other studies of generalization with taxonomic background 760 MACHINE LEARNING information. First, the generality of the taxonomic theories distinguishes this work. A simple consequence of this generality is that a set of atomic A-expressions may have more than one minimal C-generalization. Therefore, the set of atomic A-expressions, ordered by C-subsumption, is not a lattice. This contrasts with other methods such as those described in [Michalski, 1983; Mitchell et al., 19831. A less obvious conse- quence, further distinguishing this work, is the poly- morphism of function symbols. The need for poly- morphism is evident; if fido is a dog and jumbo is an elephant, we should be able to let mother(fido) and mother(jumbo) denote individuals that do not belong to exactly the same sorts. But providing this needed flexibility adds the subtlety involving structured gen- eralizations and variable generalizations, as illustrated in Example 2. The second major distinction of this work is the pair of semantic properties asserted by Theorems 7 and 8. They assert falsity-preserving and truth-preserving correctness and completeness properties of sorted gen- eralization. Plotkin’s work on unsorted generalization begins with the semantic property that Vcul b V’a;! if, and only if, cy1 &a. We know of no such entailment- based result for methods of generalization with taxo- nomic background information, other than these pre- sented here. Finally, we relate sorted generalization to the gener- alized subsumption of Buntine [1988]. Generalized sub- sumption is defined over Horn clauses with respect to a logic program that acts as the background information. Because atomic A-formulas are equivalent to Horn clauses whose antecedents contain only taxonomic con- straints on variables, we can compare C-subsumption, on which sorted generalization is based, with general- ized subsumption, in cases where C consists entirely of Horn clauses. In these cases, C-subsumption and generalized subsumption are equivalent. Because C-subsumption is based on purely taxo- nomic information, the 2-SG algorithm generalizes atomic A-expressions by decomposing them, general- izing their parts, and composing these generalizations. This compositional approach reduces the search for maximally-specific C-generalizations. It is reasonable to ask whether this approach can also reduce the search for generalization based on generalized subsumption with respect to arbitrary logic programs. It cannot be applied directly to generalization problems with such non-taxonomic theories, because in some cases it com- putes an incomplete set of generalizations. It may be possible, nevertheless, to use the 2-SG algorithm as part of a broader generalization procedure, much as algorithms for sorted unification are useful in improv- ing the efficiency of deductive methods. Acknowledgements We thank the members of the Knowledge Representa- tion and Reasoning Group and the Inductive Learning Group at the University of Illinois, and Tony Cohn, David Etherington, Mike Frazier, and Chris Matheus for helpful discussions and comments. eferences [Borgida and Etherington, 19891 A. Borgida and D. W. Etherington. Hierarchical knowledge bases and effi- cient disjunctive reasoning. In First Int. Conf, on Principles of Knowledge Representation and Reason- ing, Toronto, Ontario, Canada, May 1989. [Buntine, 19881 Wray Buntine. Generalized subsumption and its applications to induction and redundancy. Ar- tificial Intelligence, 36(2):149-176, 1988. [Frisch, 19891 A. M. F risch. A general framework for sorted deduction: Fundamental results on hybrid reasoning. In First Int. Conf. on Principles of Knowledge Rep- resentation and Reasoning, pages 126-136, Toronto, Ontario, Canada, May 1989. [Lassee and Marriott, 19871 J-L. Lassez and K. Marriott. Explicit representation of terms defined by counter ex- amples. Journal of Automated Reasoning, 3:301-317, 1987. [Lassez et al., 19881 J-L. Lassez, M. J. Maher, and K. Mar- riott. Unification revisited. In Jack Minker, editor, Foundations of Deductive Databases and Logic Pro- gramming, chapter 15, pages 587-625, Morgan Kauf- mann Publishers, 1988. Leishman, 19891 D. Leishman. Analogy as a constrained partial correspondence over conceptual graphs. In First Int. Conf. on Principles of Knowledge Repre- sentation and Reasoning, pages 223-234, Toronto, On- tario, Canada, May 1989. Levesque, 19881 H. J. Levesque. Logic and the complexity of reasoning. Journal of Philosophical Logic, 17:355- 389, 1988. [Michalski, 19831 R. S. Michalski. A theory and method- ology of inductive learning. In T.M. Mitchell R.S. Michalski, J.G. Carbonell, editor, Machine Learning: An Artificial Intelligence Approach, pages 82-132, Morgan Kaufmann Publishers, 1983. [Mitchell et al., 19831 T. G. Mitchell, P. E. Utgoff, and R. Banerji. Learning by experimentation: Acquir- ing and redefining problem solving heuristics. In T.M. Mitchell R.S. Michalski, J.G. Carbonell, edi- tor, Machine Learning: An Artificial Intelligence Ap- proach, chapter 5, pages 137-162, Morgan Kaufmann Publishers, 1983. [Plotkin, 19701 G. D. Plotkin. A Note on Inductive Gener- alization, chapter 8, pages 153-163. Volume 5 of Ma- chine Intelligence, Edinburgh University Press, Edin- burgh, 1970. [Plotkin, 19711 G. D. Plotkin. A Further Note on Inductive Generalization, chapter 8, pages 101-124. Volume 6 of Machine Intelligence, Edinburgh University Press, 1971. [Reynolds, 19701 J. C. Reynolds. Transformational Sys- tems and Algebraic Structure of Atomic Formulas, chapter 7, pages 135-52. Volume 5 of Machine Intelli- gence, Edinburgh University Press, Edinburgh, 1970. FRISCHAND PAGE 761
|
1990
|
152
|
907
|
What Should Be Minimized in a Decision Tree? Usama M. Fayyad and Keki B. Irani Artificial Intelligence Laboratory Electrical Engineering & Computer Science Department The University of Michigan Ann Arbor, MI 48109-2122 umf@zip.eecs.umich.edu Abstract In this paper, we address the issue of evaluating decision trees generated from training examples by a learning algorithm. We give a set of performance measures and show how some of them relate to oth- ers. We derive results suggesting that the number of leaves in a decision tree is the important mea- sure to minimize. Minimizing this measure will, in a probabilistic sense, improve performance along the other measures. Notably it is expected to produce trees whose error rates are less likely to exceed some acceptable limit. The motivation for deriving such results is two-fold: 1. To better understand what constitutes a good mea- sure of performance, and 2. To provide guidance when deciding which aspects of a decision tree generation algorithm should be changed in order to improve the quality of the decision trees it generates. The results presented in this paper can be used as a basis for a methodology for formally proving that one decision tree generation algorithm is better than another. This would provide a more satisfactory al- ternative to the current empirical evaluation method for comparing algorithms. I. Introduction Knowledge Acquisition is one of the important areas of application for machine learning techniques [Quin86]. With the advent of rule-based and expert systems, and their widespread use, came the reality of the knowledge acquisition bottleneck Feig811. It still remains to be seen whether machine learning will alleviate the knowl- edge acquisition bottleneck by endowing machines with the autonomous ability to construct their own knowledge bases. However, some steady advances in this direction have taken place. For example, Michalski conducted experiments in Soybean disease diagnosis that showed that his concept learning program attained a higher level of classification accuracy than a human knowl- edge acquisition approach conducted as part of the same experiment[Mich78]. Mozetic was able to reduce the size Irani@caen.engin.umich.edu of a ECG database by 97% without loss of information us- ing the same concept learning techniqueCMoze861. Quin- lan’s success with a large database of thyroid problem data is another of the many examples of machine knowl- edge acquisitionrQuin86, Mich791. For applications in the domain of semiconductor manufacturing see [Iran90]. An important problem associated with applying induc- tion programs is the measurement of performance and the establishment of improvement. So far, different methods for rule induction have been compared against each other empirically. A domain is chosen, and examples are col- lected. Programs are then used to induce classification rules from a training subset of examples. Performance is measured by using the induced classification rules on a separate set of test examples. The problem with this method of evaluation is that it is time consuming and of- ten inconclusive. Some programs may do better on one data set or domain, and worse on another. In this paper, we attempt to provide a more theoretical basis for es- tablishing improvement for decision tree generation. By examining the different performance measures, we show that some of them that are data dependent (require a test set of examples) can be probabilistically related to a mea- sure that does not require test sets, namely the number of leaves in the induced tree. This may then serve as a ba- sis for provably establishing that one method for inducing decision trees is better than another by proving that one algorithm always produces a tree with a smaller number of leaves than another algorithm, given the same training data. In addition to giving a possible tool for proving that one program is better than another, the results pro- vide some guidance to ways of improving decision tree learning algorithms. 2. Inducing Decision Trees From Examples Programs that learn from examples are presented with examples of different concepts (classes). The program is provided with the class to which each example be- longs. The goal of the program is to construct an ef- fective method (classifier, or set of rules) for classify- ing examples in their proper classes. The important per- formance criteria regarding the produced classifier are: size/complexity and error rate. Since programs that learn FAYYADANDIRANI 749 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. from examples perform induction, it is not reasonable to require that they produce classifiers that are completely correct. The error rate of a classifier (see definition 1) is strongly dependent on the choice of training set pre- sented to the learning algorithm. On the other hand, finding a classifier with minimal size/complexity for a given data set can easily be shown to be an NP-hard probleml. Most systems in the literature, therefore, resort to heuristic approaches that attempt to produce compact classifiers. A particularly efficient and popular approach to inducing classifiers is via the generation of decision trees[Brei84, Quin86, Quin87, Chen88]. In this paper, we show that a compact classilier is in- deed a good target to strive for. We demonstrate that, in a certain probabilistic sense, the compactness of a classifier is related to its expected error rate. Results to this effect for general learning algorithms have appeared before in [Blum87]. In this paper we show how those results ap- ply to decision trees in particular, and how they can be used in deciding which performance measure is most crit- ical. Consequently the results point out what to focus on when attempting to modify and “improve” a particular algorithm for inducing decision trees. First we briefly describe what a decision tree is. For a more detailed discussion, see [Quin86]. A training set consists of examples expressed as attribute-value pairs. Each example belongs to a single class. A decision tree is a tree in which nodes represent subsets of examples and the outgoing branches from a single node constitute conditions which involve a single attribute. The condi- tions are mutually exclusive and collectively exhaustive, thus they induce a partition on the set of examples at the node. The subset of examples represented by any node in the decision tree consists of all examples in the training set that satisfy the conjunction of the conditions appearing on the branches on the path from the root to that node. Typically, the leaf nodes have examples that belong to exactly one class. That class is referred to as the outcome predicted by the leaf. In some cases it may not be possible or desirable to produce a tree that classi- fies the training set perfectly (i.e. one outcome per leaf, c.f. [Span89]). However, we restrict our attention to the case where perfect classitication is possible. Assumptions In this paper, it is assumed that the learning algorithm generates a decision tree that classifies all examples in the training set correctly. Another assumption we make is that the sets of training and test examples are noise free and are not ambiguous 2. Furthermore, we assume that the examples in the training and test sets are drawn indepen- dently and at random according to some fixed (unknown) probability distribution. Finally, the training examples are ‘It is essentially the multiple-valued logic minimization problem, also see [Hyaf76]. 2A data set is ambiguous when there are at least two exam- ples that agree on the values of all the attributes but belong to different classes. expressed in terms of attribute-value pairs (see section 4) and the conditions on the outgoing branches of a node are mutually exclusive and collectively exhaustive tests on the values of a single attribute. These assumptions ad- mit most decision tree algorithms in the literature such as CART[Brei84], ID3 [Quin86], GID3 [Chen88], and others. 3. Performance Evaluation Criteria There are several dimensions along which the complex- ity and correctness of a decision tree can be measured or estimated. Quinlan [Quin87] used the number of nodes in the tree as a measure of its optimality. He also used the percentage error rate when the tree is used to classify examples not in the training set. A decision tree may also be translated into a set of rules that perform an equivalent classification. Some performance measures may be de- fined on this set of classification rules as well. Below, we list measures of performance that we used in a previous paper[Chen88]. The (I) and (1) symbols indicate that it is desirable (intuitively) for the corresponding measure to be maximized or minimized respectively. MI: Percentage errors on classifying unseen examples (l)* M2: Number of rules in the rule-base (leaves in tree) (1). M3: Number of nodes in the tree (1). M4: Total number of preconditions in the rule-base (I). This measures the generality of the entire set of rules. It is a more accurate measure of generality than the average number of preconditions per rule (M6), since the latter is not very indicative if the number of rules is relatively large when compared against the number of training examples. M5: Average example support per rule (per leaf) (I). This is the average number of examples in the test set on which a rule is applicable and correctly predicts the class. It is a measure of the applicability (generality or utility) of the produced rules. 3 M6: Average number of tests per example in the test set (1). This is a data-dependent measure of the efficiency of the generated classification tree (the weighted aver- age depth of the tree). Note that measures Ml, M4, MS, and M6 are essentially estimated by using the set of rules to classify several test sets of examples whose classification is known. Perfor- mance measure M4 can be directly related to measure M2. The relation between M3 and M2 is typically direct but can only be quantified when the algorithm is fixed (i.e. it depends on the form of trees generated by the algorithm). The percentage of errors (measure Ml) serves as an estimate of the true error rate of the set of rules (see definition I). It is considered by most researchers in the 3This measure should be normalized by the total number of examples in the test set for which a prediction, correct or erroneous, was made. 750 MACHINE LEARNING field to be the key measure. Afterall, a minimal set of rules which has a high error rate is not beneficial. On the other hand, a lower error rate is desirable even at the expense of a slightly less efficient or a larger set of rules. However, obtaining a good estimate of the error rate of a decision tree is not easy and it necessitates the use of separate large test sets of examples. A major theme of this paper is to show that by minimizing the number of leaves (measure M2), one may, in a probabilistic sense, expect a reduction in error rate to result. Measure M5 will also be shown to be directly related to measures Ml and M2. Measure M6 is not as easy to analyze. We shall delay discussing it until section 5. The above discussion indicates that it is important to try to minimize the number of leaves in the tree. By re- ducing the number of leaves we should in general expect an improvement in performance along the other measures listed above. We justify this claim in the next section. This claim is not intuitively obvious. Generally speak- ing, it is not clear which performance measure is most critical. Although it is highly desirable to have a low er- ror rate, the error rate of a generated tree is not something that can be controlled directly by the learning algorithm. On the other hand, the number of leaves or the depth of the generated tree may be more easily changed by mod- ifying the algorithm. In this sense, it is useful to derive relations between the error rate of a tree and more ac- cessible measures such as the number of leaves in the tree. 4. The Fewer the Leaves, the Better the First we establish the easy result that shows that measure M5 is directly related to measures M2 and Ml. Let n be the number of leaves in a decision tree. Given a test set of t, examples, measure M5 is defined as4 Average example support per rule = number of test examples correctly classified number of leaves In general, given an error rate E (measure Ml), we expect (1 - Q) . t, test examples to be classified correctly by the tree. Thus Average example support per rule = (l-+t, n Thus reducing the number of leaves n improves perfor- mance along measure M5. Furthermore, reducing the er- ror rate c will also improve the average example support per rule. An objection that may arise here is that de- creasing the number of leaves may result in a tree which has a higher error rate. However, our result below shows that, probabilistically, reducing the number of leaves is expected to result in lowering the error rate. This cor- relation serves to strengthen our statement regarding the relation between the average support per rule (M5) and the number of leaves (M2). 4As mentioned before, we are ignoring factor since it &es not affect the analysis. the normalization We now proceed to establish the result regarding the error rate and its relation to the number of leaves in a tree. We first need to establish a few definitions and facts. Let E be a training set of examples expressed in terms of Ic attributes from the set A = {Al,. . . , Ah}, and j classes from the set C = (Cl, . . . , Cj}. Thus each ex- ample e E E is a X: + 1-tuple e = (VI,. . . , Vk; Cj), where Vi E Range(Ad ) is a value in the range of the attribute Ag E A and Cj E C. Let KU be the total number of attribute-value pairs in the training set5, that is K, = cf=, IRange(A From this point on, the reader should assume that there is a fixed (unknown) probability distribution according to which training and test examples are draw. Any reference to error rates is implicitly to be interpreted as error rate with respect to the fixed probability distribution. Definition 1: A decision tree T has error rate E, 0 2 E < 1, if the probability that T will misclassify a randomly drawn test example (according to our fixed distribution) is E. Equivalently, if T classifies m randomly drawn exam- ples then for very large m, (m -6) examples are expected to be misclassified by T. Lemma 1 For every decision tree T with n leaves, there exists a binary decision tree T’ with n leaves that is logi- cally equivalent to it. The proof is given by an algorithm that transforms an r-ary decision tree to an equivalent binary one with the same number of leaves. We do not include the proof in this paper. The only requirement is that the conditions on the outgoing branches of a node be mutually exclusive and collectively exhaustive. Clearly two decision trees that are logically equivalent have exactly the same error rate when used to classify a set of examples. This lemma allows us to concentrate our analysis on binary trees only. This simplifies the analysis but does not change the final results. efinition 2: Let DT(n) denote the set of logically non- equivalent binary decision trees having n leaves. ‘Iwo binary decision trees are logically equivalent if the two DNF expressions obtained by taking the disjunction of the conditions on the leaves of each tree are equivalent. Proposition 1 There are at most DTu (n) and at least DTl(n) binary decision trees in DT(n) (logically non- equivalent binary decision trees with n leaves), where 5This holds for discrete attributes. For a continuous attribute Ai, IRange( is at most II31 - 1. FAYYAD AND IRANI 751 The proof consists of counting binary tree topologies and then counting the possible labellings of the internal nodes with the interpretation that the left branch out of an inter- nal node is labelled TRUE and the right branch is labelled FALSE. Note that the upper and lower bounds are fairly tight. For K, >, n > 2 they differ by at most (%)!. Definition 3: Let B(n, c) C DT( n) denote the set of binary trees with n leaves that have an error rate greater than~,O<~<l. We are now ready to derive our main result. The re- sult follows almost directly from a theorem that relates the number of examples needed to probabilistically guarantee a certain error rate. The theorem is by Blumer, Ehren- feucht, Haussler, and Warmuth and appears in [Blum87]. For completeness, we include the modified proof for trees. Theorem 1 Let T be a binary tree having n leaves that classifies a set of m randomly chosen training examples correctly. Then 1 B(n, E) 1. (1 - c)~ is an upper bound on the probability that T has an error rate greater than E, O<E<l. Proof: By proposition 1 there are IDT(n) 1 possible bi- rxxzees with exactly n leaves. Let B(n, E) C DT(n), B(n, E) = {T E DT(n) 1 T has error rate > E} is the set defined in definition 3. We want to bound the probability that our tree T is a member of B (n, E). For any T E B( n, c), and any randomly chosen example e E E, Prob( { T misclassifies e)) > E. Hence, Prob( { T correctly classifies e)) < (1 - E). Assuming the m training examples were chosen inde- pendently at random according to some fixed probability distribution, Prob({T is consistent with the training set}) < (1 - c)” We want to bound the probability of any tree in B( n, E) being consistent with m examples, namely Prob ( u {T is consistent with m examples} j TEB(%f) By the subadditivity property, this probability is < IB(n,E)l -Prob({T,is consistent with m examples}) = IB(n,E)I . (1 - c)” 0 Note that IB( , )I n E is not easy to quantify. To get a looser quantitative bound, one may use the fact that B( n, E) < I DT(n) I by definition, and proposition 1 to show that the probability that the obtained tree has error greater that E is mnna2Forany~dc,O<c<I,andanyn~> nl > 2 the following property holds: IB(n2,4 I%1 Y 4 I > 2h-“1) The proof is by induction on the fact that for any n 2 2 1% + WI > 2 IBh 4 I The proof of this fact is omitted. 0 Corollary 1 Let Tl and T2 be two decision trees consis- tent with a fixed training set of m examples. Let n1 and n2 be the number of leaves in TI and T2 respectively. For a fixed e, 0 < E =C 1, let bl and b2 be the bounds derived in Theorem I for Tl and T2 respectively. If n2 > nl 2 2 then bI -C b2. Furthermore b2 - > 2(““--7q h Proof: 121 < 122, 0 < (l- E) < 1, and Theorem 1 give bl < b2. b2 being larger than bl exponentially in the dif- ference (n2 - nl) follows from Theorem 1 and Lemma 2 regarding growth of I B( n, 6) I with n. Cl Thus for a fixed training set, given two decision trees TI and T2 with nl and n2 leaves respectively, let PI = Prob( { T&s error rate > E}) and P2 = Prob((T2has error rate > E)). Notethatif n1 < n2 it fol- lows from Theorem 1: PI < bI and P2 < b2. Corollary 1 states that bl is smaller than b2 by a factor of 2(n2-“1). However, Corollary 1 does not imply that PI < P2. Prov- ing this would be desirable but is not possible because the trees TI and T2 were derived by an induction process that examined the same finite subset of the set of all possible examples. The corollary does state that the upper bound on the probability that TI has an error rate that exceeds c is always lower than the corresponding upper bound for T2. Note that the upper bounds grow exponentially tighter with the number of training examples available to the learning program. Finally, even with very tight upper bounds (i.e. very large training sets) bl is always smaller than b2 by a factor that grows exponentially in the differ- ence (722 - nl). Thus improvement in the upper bound on the probability of error is very sensitive to a decrease in the number of leaves of the generated tree for a fixed training set. We shall denote the probability that a tree T has error greater than c by P(T, E), i.e. P(T, 6) = Prob ({T has error rate > E}) . Definition 4: We say that a tree Tl is likely to have a lower error rate than a tree T2 if, for a fixed E, 0 < E < 1, < IDT(n)I . (1 - E)~ 1 @-12(2(,7_;‘)) . (1 - E)” px-ob ({P(Tl, 6) < P(T2, E))) > - 2 < However, we do not want to loosen our bound tmneces- sarily for reasons that should shortly become apparent. i.e. when it is more likely that P(Tl, E) < P(T2,c) than otherwise. 752 MACHINE LEARNING Given two decision trees, we should prefer the one that is likely to have a lower error rate than the other. Assume that, for a fixed training set of m examples, we are given two decision trees Tl and T2 having n1 and n2 leaves respectively, with n2 > nl. If we have no special knowledge of the data or the trees, we only have one more piece of information, namely that for any fixed E, corollary 1 states that the bound bI on P(Tl, C) is exponentially smaller than the corresponding bound b2 for P(Tl , E). How may we use this piece of information? Is there a formally justifiable strategy for preferring Tl over T2? Having no further knowledge, it seems reasonable to assume that P(TI , E) could be any value less than bl. i.e. that P(Tl, E) is uniformly distributed over the range [0, bl ). Assuming the same for T2, the following corol- lary will justify our strategy for preferring Tl over T2. Corollary 2 Given two decision trees Tl and T2 having n1 and n2 leaves respectively, if nl < n2 then assuming that P(TI, E) and P(T2,c) are uniformly distributed be- low there respective bounds bl and b2, then Tl is likely to have a lower error rate than T2. Proof: From Theorem 1 and corollary 1 we get that P(TI, E) < bl, P(T2, E) < b2, and that bl < b2 by a factor of 2(“2-4. Now if P(TI , E) and P(T, , E) are uniformly distributed over the ranges [0, bl) and [0, b2) respectively, we can show that Rob ({P(Tl, E) < P(Tz, 4)) > 1 1 yjj * 2(“2-“1) I which is always greater than 0.75. 0 Corollary 2 justifies the strategy that prescribes prefer- ring the tree with the smaller number of leaves. Note that Corollary 2 does not state that a tree with the mini- mal number .of leaves is the best tree. The key condition is that the tree must be consistent with the training ex- amples. For example, the tree consisting of a single-&de is not consistent with the training set (unless all train- ing examples are of one class, in which case it would be the best tree.) Furthermore, the corollary does not state that P(Tl, E) < P(Tl, E), it just states that, un- der the uniform distribution assumption, the event that {P(TL 4 < WI, c)) is a more likely event than its complement: { P(T2, E) < P(TI, 6)). The above strategy is motivated by the assumption that we (i.e. the users/designers of the learning algorithm) have no special knowledge of the domain. Since the true error rate is not easy to get, we would like to at least have a certain confidence that a given tree’s error rate is “acceptable”, namely it is less than c’. We thus “prefer” a tree for which a tighter upper bound on the probability of error being “unacceptable” can be established. 5. Discussion We have shown that by concentrating on improving a sin- gle performance measure, namely the number of leaves in the decision tree, we can achieve, probabilistically, im- provement along the other performance measures listed in section 3. The usefulness of this result is in point- ing out an aspect of decision trees where further research should be emphasized. We know that the problem of finding optimal decision trees (with respect to almost any performance measure) is NP-hard. Thus it is very likely that there exists no efficient algorithm for producing opti- mal trees. We therefore have to be satisfied with heuristic algorithms that generate suboptimal trees. With the grow- ing usage of these algorithms, we become more familiar with their problems and limitations, and the need arises for improving them. The result given in this paper sug- gests that if the goal is to improve a certain heuristic algorithm for generating decision trees, then a good ap- proach to take is to try to modify it in a way that causes it to generate trees that have fewer leaves. It does not matter how the tree with fewer leaves is generated since the results of this paper predict that the tree is expected to perform better based solely on the fact that it has fewer leaves? There remains two issues that need to be addressed. The first is that the results are probabilistic, and they cannot be absolute. This is due to the fact that the qual- ity of the decision tree relies heavily on the choice of training set. Thus by choosing pathological training sets, one could force a given algorithm to generate trees that are arbitrarily “bad”. An absolute statement regarding improvement in performance would therefore necessarily be false. The second is that the bounds used are worst case bounds and may be too restrictive. However, this does not mean they are not useful. Corollary 2 shows that it is indeed a “safer” strategy to prefer the tree with the smaller number of leaves. At this time, we cannot state whether an average-case analysis would necessarily lead to a result consistent with the results presented. Finally, our analysis did not take into account per- formance measure M6. The relation between the num- ber of leaves and the average depth of the decision tree (weighted by relative frequencies of examples in test set) is not clear. The latter would favour a tree with a very large branching factor. One extreme of this is if each example had a unique id number, and if the id number were used as an attribute to create a branch for each id number. This creates a tree with depth 1 and a leaf node for each example in the training set. However, this tree will fail to classify any example that did not appear in the training set. On the other hand, measure M6 is a good measure of the speed of the decision tree in classifying an example-the average number of tests required before an example can be classified. If the tests (attributes) are not very costly, then measure M6 can be ignored. In this case a deeper tree means that the rules have more pre- conditions, which means more information is encoded in each rule, and thus, at least intuitively, one would expect such rules to be better predictors. Thus it is not at all 6As long as the tree is consistent with the mining set. FAYYAD AND IRANI 753 clear, at least intuitively, whether this measure should be minimized. 6. Conclusions The main motivation for this work is to derive results that give us a handle on two problems relating to decision tree generation: 1. If a particular algorithm for inducing decision trees is to be “improved”, then what should be changed in it? Out of the various performance measures available, which is most critical? 2. Suppose one gives a new algorithm for generating de- cision trees, then how can one go about establishing that it is indeed an improvement? To date, the answer to the second problem has been: Compare the performance of the new algorithm with that of the old algorithm by running both on many data sets. This is a slow process that does not necessarily produce conclusive results. On the other hand, suppose one were able to prove that given a data set, Algorithm A will al- ways (or “most of the time”) generate a tree that has fewer leaves than the tree generated by Algorithm B. Then the results of this paper can be used to claim that Algorithm A is “better” than algorithm B. In this case “better” means: without special knowledge of the data, given a training set, it is more likely that the tree generated by Algorithm A will outperform the one generated by Algorithm B on the performance measures considered. We have presented some results that seem to indicate that the number of leaves in a decision tree is the impor- tant measure to consider when attempting to show that one tree is better than another if both trees were gener- ated from the same training se& The results hold when no special knowledge of the data is available. All that is required is that the generated tree classify the training set correctly. We have also identified some of the limitations of the derived results. The primary motivation behind this work is to produce the tools needed to make it possible to formally prove improvement in decision tree genera- tion algorithms and thus avoid the less than satisfactory and tedious approach of empirical comparison over large varieties of training and test example sets. Acknowledgments The authors wish to thank Kevin Compton for help on counting trees, and to thank Sami Bayyuk, Jie Cheng, and Moncef Maiza for insightful and helpful discussions. This work was supported in part by a DeVlieg Industrial Fellowship and in part by a Hughes Unrestricted Grant. References [Blum87] Blumer, A., Ehrenfeucht, A., Haussler, D., and Warmuth, M. “Occam’s Razor.” Infor- mation Processing Letters 24. pp. 377-380. North-Holland (1987). 754 MACHINE LEARNING [Brei84] [Chen88] [FeigO l] [HYaf761 [Mich78] [Mich79] [Moze86] [Quin86] [Q&r87 [Span89 Breiman, L., Friedman, J.H., Olshen, R.A., and Stone, C.J. Classification and Regression Trees. Monterey, CA: Wadsworth & Brooks (1984). Cheng, J., Fayyad, U.M., Irani, K.B., and Qian, Z. “Improved decision trees: A gen- eralized version of ID3.” Proceedings of the Fifth International Conference on Ma- chine Learning. pp. 100-108. Ann Arbor, MI (1988). Feigenbaum, E.A. “Expert systems in the 1980s.” In Bond, A. (Ed.), State of The Art Report on Machine Intelligence. Maid- enhead: Pergamon-Info&h, (198 1). Hyafil, L. and Rivest, R. “Constructing op- timal binary decision trees is NP-complete.” Information Processing Letters. vol 5, no. 4. (May 1986). Irani, K.B., Cheng, J., Fayyad, U.M., and Qian, Z. “Applications of Machine Learn- ing Techniques in Semiconductor Manufac- turing.” Proceedings of The S.P.IE. Confer- ence on Applications of Artijcial Intelligence VIII. Orlando, Fl (1990). Michalski, R.S. and Larson, J.B. “Selection of most representative training examples and incremental generation of VLl hypotheses: The underlying and the description of pro- grams ESEL and AQI 1.” Report No. 867. Computer Science Dept., University of Illi- nois, Urbana, (1978). Michie, D. (Ed.) Expert Systems in the Micro Electronic Age. Edinburgh: Edinburgh Uni- versity Press (1979). Mozetic, I. “Knowledge extraction through learning by examples.” In Mitchell, T.M., Carbonell, J.G., and Michalski, R.S. Ma- chine Learning: A Guide to Current Re- search. pp. 227-23 I. Boston: Kluwer Aca- demic Publishers, (1986). Quinlan, J.R. “Induction of decision trees.” Machine Learning 1, No. 1. pp. 81-106. Boston: Kluwer Academic Publishers, (1986). Quinlan, J.R. “Generating production rules from decision trees”. IJCAI-87. pp. 304-307. Milan, Italy (1987). Spangler, S ., Fayyad, U.M., and Uthu- rusamy, R. “Induction of decision trees from inconclusive data.” Proceedings of the Sixth International Workshop on Machine Learn- ing. pp. 146-150. Ithaca, NY (1989).
|
1990
|
153
|
908
|
Learning from Textbook nowledge: A Case Study William W. Cohen Computer Science Department Rutgers University New Brunswick, NJ 08903 wcohen@cs.rutgers.edu Abstract One of the “grand challenges for machine learning” is the problem of learning from textbooks. This paper addresses the problem of learning from texts includ- ing omissions and inconsistencies that are clarified by illustrative examples. To avoid problems in natural language understanding, we consider a simplification of this problem in which the text has been manually translated into a logical theory. This learning prob- lem is solvable by a technique that we call analogical abductive explanation based learning (ANA-EBL). For- mal evidence and experimental results in the domain of contract bridge show that the learning technique is both efficient and effective. Introduction One of the “grand challenges for machine learning” that Dietterich suggested in his address at the 1989 Machine Learning Conference is the problem of learn- ing from textbooks. A great deal of knowledge from a huge variety of domains has been codified in textbook form; however, this knowledge is not directly usable by computer programs. Some of the problems involved in learning from text- books are natural language understanding problems. However, these are not the only problems, and perhaps not even the major problems. The information in even a well-written textbook contains inconsistencies and omissions that would make it useless if transcribed di- rectly into logic. Learning from textbook knowledge is thus an important and challenging machine learning problem. The text on contract bridge used in this experiment [Sheinwold, 19641 illustrates some of the specific techni- cal problems involved in learning from textbook knowl- edge. The first three chapters of the book were man- ually translated into Horn clause logic, and found to contain several undefined terms, and many pieces of advice that are contradictory. However, the popular- ity of this text (which has sold millions of copies, and is still in print after 23 years) shows that these logical shortcomings are not problematic to human readers. Many of the inconsistencies and ambiguities in the text are clarified by illustrative examples. For instance, in discussing rules for bidding two-suited hands [Shein- wold, 1964, page 161, Sheinwold says “The general rule is, if your suits are unequal in length, bid the longer one; if your suits are equal in length, bid the higher one.” 1 but immediately adds that “You have to disregard this general rule on some hands”. After a short digression into what defines a “biddable suit”, he presents fifteen examples that clarify this general rule. Such passages make it clear that the bidding rules presented are over-general, and that understand- ing the examples is necessary to fully understand the concept being taught. This should not be surprising - common sense tells us that understanding examples and working exercises is a crucial part of learning from textbooks. To summarize, the problem addressed in this paper is learning by understanding examples from a textbook. Unlike previous work (e.g., [Van Lehn, 1987]), we as- sume that the textbook knowledge is imperfect, and that examples are used to clarify flaws in the knowl- edge; the problem of learning from textbook knowledge will thus be treated as a a special instance of the more general problem of learning from understanding exam- ples using an approximate theory. Description of the problem In this case study, the first three chapters of a text on the game of contract bridge [Sheinwold, 19641 were manually translated into Horn clause logic. These three chapters taught opening bids, a small but reason- ably interesting part of the game of bridge; Sheinwold devotes 34 pages to this subject. Most of the rules required to understand the ex- amples of the first three chapters are clearly and ex- plicitly presented, which made transcription into logic straightforward. However, the direct transcription into ‘Terminology from the bridge domain will be used in this paper only in presentation of examples. Hence famil- iarity with contract bridge, while helpful to the reader, is not strictly necessary. COHEN 743 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. logic resulted in a theory that had several flaws. e Certain key properties (for example, whether a hand had “good length in the major suitsn) were not de- fined. e Several of the rules in the theory were over-general, and clearly not intended to be used in all the situa- tions in which they were applicable. Augmenting the theory with commonsense knowledge partially solved the first problem. For each undefined property, it was possible to restrict the number of pos- sible definitions to a small number of reasonable can- didates. For example, the definition of “good length in the majors suits” could be inferred to be “having length in the major suits greater than L” for some un- known minimal length L. Completing the theory could thus be reduced to the problem of choosing the correct definition of each undefined term. Apart from the incompleteness of the theory, the over-general rules also caused the theory to be inac- curate, as measured by a sample test also taken from [Sheinwold, 19641. Because of the over-general rules, no completion could achieve a score of better than 12 out of a possible 16 problems: on the remaining 4 prob- lems, the theory suggested multiple bids, some of which were incorrect .2 We concluded that: in order to complete and correct the theory, additional information was needed. The ob- vious source of additional information is the examples that accompany the text. How can the information in these examples be extracted? One possibility is to incorporate into the theory all possible completions of the undefined predicates. The result is a theory that is complete but over-general. The problem of incorporating the examples now be- comes a theory specialization problem [Flann and Di- etterich, 19891: Given: 1) an over-general theory Ti, 2) a set of examples of correct uses of Ti, Find: a theory Td that specializes Ti, and that only leads to correct predictions. The specialization Td of the initial theory Ti will be called the target theory. In learning from textbooks, Td is the concept being taught (in this case, opening bids) expressed as a set of Horn clauses, and Ti includes all of the definitions of terms (such as “major suit”), all possible definitions of undefined terms (such as “length in majors”) and whatever rules are given in the text- book (such as the bidding rules given in [Sheinwold, 19641). In the context of learning from textbooks, the theory specialization problem ideally should be solved without using any knowledge from o&side the textbook (e.g., 21t is possible for a hand to have more than one correct bid in Sheinwold’s bidding system. generalization hierarchies, etc) other than common- sense knowledge. Showing that this constraint is satis- fied in a learning system that is not purely automatic can be difficult. In our experiments, for example, one insidious source of additional knowledge is the repre- sentational choices made in transcribing the text into logic. Efforts were made to make these choices in a consistent and natural manner, and also to avoid intro- ducing additional knowledge not explicitly present in the textbook; the latter policy was followed even at the cost of omitting some information that could (perhaps) be inferred by an intelligent reader. Nevertheless, some representational choices that affect learning needed to be made; thus the skeptical reader may wish to view this work as learning from a synthetic theory that is believed (by the authors) to be prototypical of the sort of theories that could be automatically derived from a textbook. See [Cohen, 19891 for a detailed description of the transcription process. The following problems make theory specialization difficult in this domain. 1. The initial theory Ti can produce multiple inconsis- tent explanations of an example; i.e., it suffers from the multiple explanation problem [Rajamoney and DeJong, 19881. 2. The target theory Td is disjunctive; i.e., no single rule is sufficient to describe all correct opening bids. 3. The initial theory Ti and target theory T, are rela- tional, not propositional. Problems 1 and 2 rule out use of the mEBG and IOE techniques discussed in [Flann and Dietterich, 19891; the fact that negative examples are also present also argues against the appropriateness of these tech- niques (with each hand, Sheinwold presents a list of correct bids; possible bids not on the list are thus by inference negative examples). Problem 2, and the lack of a generalization language, rules out use of the technique of incremental version-space merging [Hirsh, 19891. Problem 3 rules out use of the MIRO algorithm [Drastal et al., 19891, which could also be considered a theory specialization technique. Finally, the presence of an almost-correct initial theory suggests that tradi- tional inductive learning techniques, which cannot use this information directly, are not appropriate. The techniques that seem most appropriate to this problem are the techniques described in [Pazzani, 19881 and [Fawcett, 19891 for using explanation-based learn- ing (EBL) on a theory that generates multiple incon- sistent explanations. These researchers have identified heuristics for choosing between multiple inconsistent explanations. If heuristics could be found that make the correct choices, then a refinement theory T, could be formed by simply disjoining the results of perform- ing explanation based generalization (EBG) on the chosen explanations. In investigating such approaches, however, a final obstacle was uncovered: 744 MACHINE LEARNING 4. No single fixed to learning. level of operationality iS appropriate Introduction of an operationality predicate is some- what problematic in any case: since no operationality predicate is explicitly given in the textbook, using any operationality predicate at all violates the principle of using no knowledge from outside the textbook. How- ever, in this context, an operationality predicate rep- resents knowledge about what features are relevant to the bidding problem; this knowledge could reasonably be inferred by a reader. For instance, the bidding rules given by Sheinwold are presented at a fairly high level; rules are typically given in terms of high level features of hands such as the number of high card points, the length of biddable suits, etc. It seems reasonable for a reader to assume that lower-level features are not relevant to bidding rules. This and similar arguments can be used to justify a choice of an operationality predicate.3 However, the sample test from [Sheinwold, 19641 in- dicates that this level of operationality is too low for a standard explanation based learner to achieve good performance. In two of the sixteen test problems, the correct bid is supported by an explanation that was different (at the chosen level of operationality) from every explanation of every training example. A conse- quence of this is that no rule generated by performing EBG on some explanation of a training example would apply to these test cases. For both of these anomalous test case, although the correct explanation is not identical to the ex- planation of any of the training examples, the cor- rect explanation is very similar to the explanation of some training example; for example, the expla nation of the correct bid of 1 club for the test case 4 KJ642 0 A5 0 3 AQ732 differs in only one subproof from the e lanation used to jus- tify the bid of 1 c on the training example K&J75 0 5 0 62 AJ963. This particular prob- lem could be handled by marking the predicate open- ing-strength as operational. Unfortunately, if this were done, then in some other cases, every rule learnable from a training example would be over-general. Considerations such as these suggest that some sort of simple analogical reasoning strategy is needed, where bids can be accepted or rejected based on consideration of training examples with similar, but non-identical explanations. This in turn suggests that explanation-based analogical reasoning tech- niques such as those described in [Huhns and Acosta, 1987; Kedar-Cabelli, 19871 could be combined with explanation-selection heuristics to solve the learning problem. These analogical reasoning techniques use EBG with a artificially high level of operationality to produce rules that match any potential analogies. ., 19891 for 3Again, the interested reader is referred to [Cohen a more detailed description of our choice. These rules are over-general, in the sense that not all instances that match these rules should be treated the same as the training example from which the rule was formed. One can view such a rule as an explicit repre- sentation of the generalizations that would be implic- itly made by an analogical reasoner. In this research, a slightly different approach was taken to analogy. For each training example, instead of generating a single very general rule, a large number of somewhat general rules were produced, each corre- sponding to a class of analogical instances. What one would like to do is to pick general rules that only match instances that should be treated the same as the train- ing example. A key insight is that choosing the right generalization can be done with the same techniques used to solve the multiple explanation problem. The learning algorithm The learning algorithm used is shown in Figure 1. It takes as input a set of positive examples S+, a set of negative examples S” , a theory T, an opera- tionality predicate 0, and an additional parameter Ic, which will be discussed shortly. The algorithm is called analogical abductive explanation based learning (ANA- EBL), since the theory can generate multiple incon- sistent explanations and hence is similar in character to the abductive theories described in [O’Rorke, 1988; Pazzani, 19881. The reader is referred to [Mitchell et al., 19861 for definitions of terms such as “explanation structure”, and for an algorithm for explanation based generalization. The basic idea of the algorithm is simple. First, all possible generalizations of the positive training ex- amples are enumerated, where “all possible generaliza- tions” includes generalizations formed by first marking up to Ic internal nodes of some explanation structure for the example as “operational”. These extended gen- eralizations can be matched by a new problem with an explanation that differs from the training example in up to E subproofs. The parameter Ic is thus a constraint on how similar an new example must be to a training example in order to be treated analogously. Inconsis- tent generalizations (those that match some negative example) are then filtered out, and finally, a greedy set cover algorithm is used to find a minimal-sized dis- junction of the remaining candidates which covers all the positive examples. Unfortunately, space limitations make presentation of a detailed example of the algorithm impossible; the interested reader is referred to [Cohen, 19891. An ap- pendix to this paper containing an example and a short summary of some relevant formal results is also avail- able from the author on request. Note that with L = 0, no analogical reasoning takes place; in this case ANA-EBL simply uses the set cov- ering and size heuristics to choose between multiple explanations and find the set of EBG rules that best describes the data. COHEN 745 Algorithm ANA-EBL(S+, S-, Z’, 0, B): 1. Compute the explanation structure of every proof of every example in S+. 2. For each explanation structure found in step 1, find the set of candidate rules that can be formed by (a) marking up to k internal nodes of the explanation structure as uoperational” (b) applying the final stage of EBG to the resulting explanation structure. by removing 3. Filter the set of candidate rules that covers an element of S- . 4. any rule Use that a greedy set cover accounts for all of to find a small set of rules the training examples: (a) Initially, let COV be the empty set. (b) Add to COV that candidate rule R that maximizes the ratio of the number of as-yet-uncovered examples explained by R to the sizea of R. (c) Repeat step 4b until all examples have been covered. 5. Return the disjunction of the rules in COV. aThe size of R is defined to be the number of explanation structure from which R was formed. nodes in the Figure 1: The ANA-EBL Learning Algorithm It can be easily shown that this algorithm runs in time polynomial in the total size of the set of proofs for elements of S +, but exponential in L. Of course, the number of proofs can be very large or even infinite; ANA-EBL is only efficient when this is not the case. It can also be shown that ANA-EBL satisfies Valiant’s criterion of efficient learnability [Valiant, 19841. Theorem 1 (From [Cohen, 19891) Let n be the min- imal size (over all samples) of any set of rules gen- erated by the procedure above that correctly define the target theory T,, and let ITi 1 be the number of Born clauses in the initial theory Ti. Then with probability at least I- 6, ANA-EBL will return a specialized the- ory that will have error (with respect to the probability distribution function D) less than E if it is given only m($, $,n) examples chosen stochastically according to D, where 1 1 m(- -94 &'6 = O(max(i log 2, 1 nlQyY(log "'OfTil)Z)) Furthermore, there exists initiaZ theories Ti such that every algorithm that with probability at least 1 - 6 re- turns a specialized theory that has an error of less than e will require at least rni$, #, n) examples, where 11 m(- -,n) = Q(iln E’S ;+s, Assuming that n is large and log ITi I is small, the upper and lower bounds on m can be simplified to O($(log E)2) and sZ($) respectively. So in learning from random examples, ANA-EBL is within a factor of (log $)” from the optimum. Note also that as K increases, n (the optimal size of Tb) will decrease; the theory thus predicts that increas- ing X: will improve the convergence rate of ANA-EBL. Of course, in the context of learning from textbooks, training examples will be carefully chosen, not ran- domly selected; this is in fact one of the principle ad- vantages of learning from textbooks. However, this result is still important; it suggests that ANA-EBL is robust with respect to which training examples are chosen, and reinforces the claim that ANA-EBL is a general learning algorithm - in particular, that it is not specific to the contract bridge domain. Experimental results To further evaluate the ANA-EBL algorithm, a series of experiments were conducted. The first set of experi- ments used as an initial theory Ti a transcription of the first three chapters of [Sheinwold, 19641, and used as training data the forty-eight examples used by Shein- wold in the first three chapters, with no additions, and five omissions. The omitted examples dealt with open- ing in third- or fourth-hand position; they were omit- ted because eliminating position information greatly simplified our representation of the bidding problem. As test data we used the relevant portion of the sam- ple test in [Sheinwold, 19641; this consisted of sixteen bidding problems. The examples and test data taken from [Sheinwold, 19641 are a fair test of the learner in two ways; they are representatives of a naturally-occurring concept of some complexity, and they were chosen without knowl- edge of the learning algorithm. It is not an ideal test, however, because of its small size. To circumvent this problem, a program was written that randomly generated bridge hands and then opened them using hand-coded bidding rules. The hand-coded rules are a reasonable implementation of the bidding system pre- sented in [Sheinwold, 19641; for instance, they bid all of the problem hands in the sample test correctly. By using this program as a classifier, unlimited amount of training and test data can be generated; however, this introduces another source of potential bias, because the data no longer consists of true representatives of Sheinwold’s opening-bid concept, but of representatives of our own interpretation of that concept. Experiments with textbook data The ANA-EBL algorithm was used to learn a bridge bidding strategy in two phases. First, the textbook theory was completed by adding all possible comple- tions (subject to common-sense constraints) of the un- defined predicates. The predicate opening-strength was then learned from the completed theory and the train- ing examples, using ANA-EBL with L = 0. All of 746 MACHINE LEARNING 1 Theory I Accuracy ] Ti with learned* opening-strength ~1 Table 1: Learning opening-bid from textbook data the undefined predicates appear in the definition of opening-strength, and none of them appear anywhere else; hence learning this predicate is equivalent to si- multaneously learning definitions of all of the unde- fined predicates. Opening-strength is the least general predicate that has this property and that is also “ob- servable”, in the sense that one can look at a training example and readily determine whether the hand in question makes opening-strength true. The learned definition of opening-strength was then spliced into the original initial theory, and the predi- cate opening-bid was learned from the training exam- ples, using ANA-EBL with L = 0 and k: = 1. This predicate says which bids are correct opening bids for a given hand; teaching this is the main object of the first three chapters of the text. The learned predicates were then tested on the sample test. A problem was judged to be correct if no incorrect bids were suggested, and at least one correct bid was suggested. The results are shown in Table 1; for comparison, we also give the performance of the initial domain theory Ti, and of Ti with the learned version of the opening-strength pred- icate. It would be preferable to learn opening-bid directly, rather than first learning opening-strength in a sepa- rate pass. However, because there are many possible definitions for each of several undefined concepts, the original theory generates hundreds of alternative ex- planations of each openingstrength goal. Our imple- mentation can handle this degree of ambiguity, but only for extremely low values of h, so learning in a sin- gle pass would preclude experimentation with larger values of L. This issue is discussed more completely in [Cohen, 19891. Experiments with random data The experiments above show that the learning algo- rithm works well for a small set of carefully selected il- lustrative examples. Experiments were also performed with randomly selected data. The goals of these ex- periments were first, to measure the benefit of using “textbook cases” for examples, rather than randomly chosen examples; and second, to further test the hy- pothesis that analogical reasoning is necessary in this domain, but that limited analogical reasoning is suffi- cient to solve most problems. Some evidence for the latter hypothesis is given by the performance of the Figure 2: Learning opening-bid from random data learning algorithm on the sample test, since Ic = 1 is sufficient to solve all but one of the test problems; however, because the sample test is so small, additional evidence is desirable. Experiments were done in learning opening-bid from the initial theory with a correct definition of open- ing-strength. A test set of 1000 hands was generated and classified by the generation program. Then a sep- arate training set of 300 hands was generated and clas- sified by the program. ANA-EBL, with X: = O,l, and 2, was then given progressively larger subsets of the training set, and the accuracy of each TB was mea- sured by using it to classify the hands in the test set, and comparing the classifications to the correct ones. This experiment was repeated 10 times and the error rates were averaged, using the same test set in each trial. The result is the “learning curve” shown in Fig- ure 2 that plots the accuracy of the hypothesis against the number of training examples. The experiments show that the algorithm has good convergence properties, even on randomly selected data. In learning opening-bid, ANA-EBL with k: = 1 learns substantially faster than ANA-EBL with L = 0, and only marginally slower than ANA-EBL with X: = 2. This substantiates the conjecture that some analogi- cal reasoning seems to be necessary, but that limited analogical reasoning is sufficient, and confirms the pre- diction made by the formal analysis that increasing Ic improves the rate of learning. It also shows that Shein- wold’s examples are much more informative than ran- domly selected ones: about 7 times as many examples are needed to achieve comparable levels of accuracy using random examples. COHEN 747 Conclusions Acknowledgements I am grateful to Alex Borgida, Haym Hirsh, Chun Liew and many other members of the Rutgers AI commu- nity. The author is supported by an AT&T Fellowship. Initial stages of this research were supported by a Mar- ion Johnson Fellowship. To summarize, we have identified a problem that arises in learning from the knowledge in textbooks: the problem of learning from knowledge including omis- sions and inconsistencies that are clarified by illustra- tive examples. This learning problem is solvable by a technique that we call analogical abductive explanation based learning (ANA-EBL). ANA-EBL actually solves the more general problem of learning from understand- ing examples using an approximate theory. It is an ex- planation based learning technique that combines tech- niques used to choose between multiple inconsistent ex- planations with explanation based analogical reasoning techniques along the lines of [Huhns and Acosta, 1987; Kedar-Cabelli, 19871. Learning from textbook knowledge is a hard prob- lem; even if the natural language problems are finessed by manually translating a theory into logic, the prob- lem of correcting and completing the resulting theory is difficult. The major contribution of this paper is isolation of some subproblems involved in the general problem of learning from textbooks, and presentation of techniques that address these subproblems. The techniques developed to solve this problem, however, are of independent interest. ANA-EBL is a theory specialization technique, like the techniques described in [Drastal et al., 1989; Flann and Diet- terich, 1989; Hirsh, 19891; however, ANA-EBL works even in situations in which the original theory is re- lational and/or generates multiple inconsistent expla- nations, and in which the target theory is disjunc- tive. Experimental results indicate that the tech- nique is effective on randomly selected examples, as well as on well-chosen “textbook” examples. ANA- EBL also builds on techniques described in [Pazzani, 19881 and [Fawcett, 19891 for solving the multiple ex- planation problem but extends these results by first, incorporating analogical reasoning techniques similar in flavor to those used in [Huhns and Acosta, 1987; Kedar-Cabelli, 19871; and second, giving a precise way of weighting the complexity of an explanation and the number of observations that it covers, and justifying this heuristic with a formal analysis. ANA-EBL is far from a complete solution to the problem of learning from textbook knowledge; how- ever, we feel that it addresses at least some of the issues that must be confronted. An important topic for fur- ther research would be to integrate ANA-EBL with an automatic text understanding system. This would ad- dress the major shortcoming of our evaluation of ANA- EBL: in the process of manually translating a text into Horn clause logic, representational choices that affect learning inevitably must be made. Because of this, the skeptical reader may wish to view this work as learning from a synthetic theory that is prototypical of the sort of theories that could be automatically derived from a textbook. References (Cohen, 1989) William W. Cohen. Abductive explanation based learning: A solution to the multiple explanation problem. Technical Report ML-TR-26, Rutgers Univer- sity, 1989. (Drastd et cd., 1989) George Drastal, Gabor Czako, and Stan Raatz. Induction in abstraction spaces: A form of constructive induction. In Proceedings of the Eleventh International Joint Conference on Artificial Intelligence. IJCAI, 1989. (Fawcett, 1989) Tom Fawcett. Learning from plausible ex- planations. In Proceedings of the Sixth International Workshop on Machine Learning. Morgan Kaufinann, 1989. (Flann and Dietterich, 1989) Nicholas Flann and Thomas Dietterich. A study of explanation-based methods for inductive learning. Machine Learning, 4(2), 1989. (Hirsh, 1989) Haym Hirsh. Incremental version space merging: A general framework for concept learning. PhD Thesis, Stanford University Department of Computer Science, 1989. (Huhns and Acosta, 1987) Michael Huhns and Ramon D. Acosta. ARGO: An analogical reasoning system for solv- ing design problems. Technical Report AI/CAD-092-87, MCC, 1987. (Kedar-Cabelli, 1987) Smadar Kedar-Cabelli. Formulat- ing concepts according to purpose. In Proceedings of the Sixth National Conference on Artificial Intelligence. AAAI, 1987. (Mitchell et al., 1986) T. Mitchell, R. Keller, and S. Kedar-Cabelli. Explanation-based generalization: A unifying view. Machine Learning, l(l), 1986. (O’Rorke, 1988) Paul O’Rorke. Automated abduction and machine learning. In Proceedings of the 1988 Spring Symposium on EBL. AAAI, 1988. (Pazzani, 1988) Michael Pazzani. Selecting the best explai- nation in explanation-based learning. In Proceedings of the 1988 Spring Symposium on EBL. AAAI, 1988. (Rajamoney and DeJong, 1988) Shankar Rajamoney and Gerald DeJong. Active explanation reduction: An ap- proach to the multiple explanation problem. In Proceed- ings of the Fifth International Conference on Machine Learning. Morgan Kaufmann, 1988. (Sheinwold, 1964) Alfred Sheinwold. 5 Weeks to Winning Bridge. Simon & Schuster, 1964. (Valiant, 1984) L. G. Valiant. A theory of the learnable. Communications of the ACM, 27(11), November 1984. (Van Lehn, 1987) K. V an Lehn. Learning one subproce- dure per lesson. Artificial Intelligence, 31:1-40, 1987. 748 MACHINE LEARNING
|
1990
|
154
|
909
|
Myths and Legends in Learning Wray Buntine* Turing Institute Classification George House, 36 Nth. Hanover St. Glasgow, Gl 2AD, UK Abstract This paper is a discussion of machine learning theory on empirically learning classification rules. The pa- per proposes six myths in the machine learning com- munity that address issues of bias, learning as search, computational learning theory, Occam’s razor, “uni- versal” learning algorithms, and interactive learning. Some of the problems raised are also nddrcssed from a Bayesian perspective. The paper concludes by suggest- ing questions that machine learning researchers should be addressing both theoretically and experimentally. Introduction Machine learning addresses the computational problem of learning, whether it be for insight into the corre- sponding psychological process or for prospective com- mercial gain from knowledge learned. Empirical learn- ing is sometimes intended to replace the manual elicits tion of classification rules from a domain expert (Quin- lan et al. 1987), as a knowledge acquisition sub-task for building classification systems. A classification rule is used to predict the class of a new example, where the class is some discrete variable of practical importance. For instance, an example might correspond to a patient described by attributes such as age, sex, and various measurements taken from a blood sanlplc, and we want to predict a binary-valued class of whcthcr the patient has an overactive thyroid gland. Empirical learning here would be the learning of the classification rule from a set of patient records. The knowledge acquisition environment provides specific goals for and constraints on all empirical learn- ing system: the system sho~~ltl fit neatly illto some broader knowledge acquisition strategy, the system should be able to take advalltnge of ally additional information over and above the cxmip1cs, for in- stance, acquired interactively from an expert, the sys- tem should only require the use of readily available information, and of course tllc systcul slloldd learn ef- ficiently and as well as possible. This paper proposes and tliscwscs mm: nlytlls in the machine learning comntunit,y. All of t,l~csc arc twists on *Current address: RIACS, NASA A~ncu l?es., MS 244- 17, Moffet Field, CA 94035, ( wr~Ly~~~‘t~ol~“uy.iL~~.I~~Ls~.~ov). 736 MACHINE LEARNING frameworks that have made significant contributions to our research, so the emphasis of the discussion is on qualifying the problems and suggesting solutions. The current flavour of machine learning research is first briefly reviewed before the so-called myths are introduced. The myths address the framework of bias, learning as search, computational learning the- ory, Occam’s razor, the continuing quest for %niver- Sal” learning algorithms, and the notion of automatic non-interactive learning. While discussing these, a Bayesian perspective is also presented that addresses some of the issues raised. However, the arguments in- troducing the myths are intended to be independent of this Bayesian perspective. The conclusion raises some general questions for a theory of empirical learning. Machine learning research The development of learning systems in the machine learning community has been largely empirical and ideas-driven in nature, rather than theoretically moti- vated. That is, learning methods are developed based around good ideas, some with strong psychological sup- port, and the methods are of course honed through experinicn tal evaluation. Such development is arguably the right approach in a relatively young area. It allows basic issues and prob- lems to come to the fore, and basic techniques and methodologies to be developed. Although it should be more and more augmented with theory as the area progresses, especially where suitable theory is available from 0 ther sciences. Early comments by Minsky and Papert (Minsky & Papert 1972) throw some light onto this kind of de- velopment approach. They were discussing history of research in the “perceptron” which is a simple linear thresholding unit that was a subject of intense study in early machine learning and pattern recognition. They first comment on the attraction of the percep- tron paradigm (Minsky 6c Papert 1972, page 18). Part of the attraction of the perceptron lies in the possibility of using very simple physical devices-“analogue computers”-to evaluate the linear threshold functions. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. The popularity of the perceptron as a model for an intelligent, general purpose learning machine has roots, we think, in an image of the brain itself . . . Good ideas and apparent plausibility were clearly the initial motivating force. While perceptrons usually worked quite well on sim- ple problems, their performance deteriorated rapidly on the more ambitious problems. Minsky and Papert sum up much of the research as follows (Minsky & Pa- pert 1972, page 19): The results of these hundreds of projects and ex- periments were generally disappointing, and the explanations inconclusive. It was only after this apparent lack of success that Minsky and Papert set about developing a more com- prehensive theory of perceptrons and their capabilities. Their theory led to a more mature understanding of these systems from which improved approaches might have been developed. The lack of success, however, had already dampened research so the good ideas un- derlying the approach were virtually forgotten for an- other decade. Fortunately, a second wave of promising “neural net” research is now underway. The major claim of this paper is that research on empirical learning within the machine learning commu- nity is at a similar juncture. Several promising frame- works have been developed for learning such as the bias framework (Mitchell 1980), the notion of learn- ing as search (Simon St Lea 1974) and computational learning theory (Valiant 1985). It is argued in this pa- per that to progress we still need more directed theory to give us insight about designing learning algorithms. A catalogue of myths and legends The theoretical basis for bias research If a learning system is to come up with ally hypotheses at all, it will need to somehow make a choice based on information that is not logically present in the learning sample. The first clear enunciation of this problem in the machine learning community was by Mitchell, who referred to it as the problem of bin.s (Mitchell 1980). Utgoff developed this idea further, saying (Utgoff 1986, Page 5) Given a set of training instances, hiu.s is the set of all factors that collcctivcly infillence hypothe- sis selection. These factors include the definition of the space of hypothcscs an(l tlcfinition of the algorithm that searches the space of couccpt de- scriptions. Utgoff also introduced a number of t.cr1ll.s: good bias is appropriate to learn the actual concept, strong bias restricts the search space consitlcral)ly tm t indepen- dent of appropriat encss, (le<hr;~tSivc: bias is defined declaratively as opposed to proc:cdurally, and prefer- ence bias is implemented as soft prcfcrcnces rather than definite restrictions to the search space. Several researchers have since extended this theory by consid- ering the strength of bias (Haussler 1988), declarative bias (Russell & Grosof 1987), the appropriateness of bias, and the learning of bias (Tcheng et al. 1989; Utgoff 1986). Much of this research has concentrated on domains without noise or uncertainty. In noisy do- mains, some researchers have considered the “bias to- wards simplicity”, “overfitting”, or the “accuracy vs. complexity tradeoff (Fisher & Schlimmer 1988) first noticed in AI with decision tree learning algorithms (Cestnik et al. 1987). There are, however, remaining open issues on this line of research. First, where does the original bias come from for a particular application? Are there domain independent biases that all learning systems should use? Researchers have managed to uncover through experimentation rough descriptions of useful biases, but a generative theory of bias has really only been presented for the case of a logical declarative bias. Second, investigation of bias in noisy or uncertain do- mains (where perfect classification is not possible) is fairly sparse, and the relation between the machine learning notion of bias and the decades of literature in statistics needs more attention. Third, there seems to be no separation between that component of bias ex- isting due to computational limitations on the learner, bias input as knowledge to the original system, for in- stance defining a search goal, and therefore unaffected by computational limitations, and the interaction be- tween bias and the sample itself. What is required is a more precise definition of bias, its various functional components and how they can be pieced together so that we can generate or at least reason about a good bias for a particular application without having to resort to experimentation. So while important early research identified the ma- jor problem in learning as bias, and mapped out some broad issues particularly concerning declarative bias, we have not since refined this to where we can rea son about what makes a bias good. The first myth is that there is currently a sufficient theoretical basis for understanding the problem of bias. Utgoff’s definition of bias could, for instance, be de- composed into separate functional components. Hypothesis space bias: This component of bias defines the space of hypotheses that are being searched, but not the manner of search. Ideal search bias: This component of bias defines what a learning system should be searching for given the sample, that is, assuming infinite computing re- sources are available for search. As a contrast, one could consider algorithm bias as defining how the algorithm differs from the ideal. Application-specific bias: This is the component of the bias that is determined by the application. This decomp losition is suggested by Bayesian tech- niques which give prescriptions for dealing with each BUNTINE 737 of these components (Buntine 1990). Bayesian tech- niques deal with belief in hypotheses, where belief is a form of preference bias. This gives, for instance, prescriptions for learning from positive-only examples, and for noisy or uncertain examples of different kinds. For many learning systems described in the litera- ture, ideal search bias is never actually specified, al- though notable exceptions exist (Quinlan & Rivest 1989; Muggleton 1987). Many publications describe an algorithm and results of the algorithm but never describe in general goal-oriented terms what the algo- rithm should be searching for, although they give the local heuristics used by the algorithm. Hence it is often difficult to determine the limitations of or assumptions clnderlying the algorithm. In areas such as construc- tive induction, where one is trying to construct new terms from existing terms used to describe examples, this becomes critical because the careful evaluation of potential new terms is needed for success. A survey of constructive induction methods (Mathcus & Rendell 1989) reveals that few use a coherent evaluation strat- egy for new terms. This issue of search is the subject of the next myth. Learning is a well-specified search problem A seminal paper by Simon and Lea argued that learn- ing should be cast as a search problem (Simon & Lea 1974). While few would disagree with this general idea, there appears to be no broad agreement in the machine learning community as to what precise goals a learn- ing algorithm should be searching for. For a particular application, can we obtain a precise notion of the goal of search at all? Of course, the problems of bias and overfitting are just different perspectives of this same problem. The second myth, related to the first, is that under the current view of learning as search, the goal of search &Z well-specified. If it was generally known how to design a good bias then the search problem could be made well-specified. Recurrent problems in machine learning such as splitting and pruning rules for decision trees (Mingers 1989) and the evaluation of new predicates for con- structive induction (Matheus St Renclell 1989) are just some symptoms of this broad search problem. There is one context, however, where learning as search is well-specified according to most current learn- ing theories. Any reasonable model of learning or statistics has asymptotic propertics that guarantee the model will converge on an optimal hypothesis. When a large enough quantity of data is nvailablc, it is easy to show the various statistical approaches become almost indistinguishable in result: mcaximunl likelihood meth- ods from classical statistics, uniform convergence and empirical risk minimisation tcchniqucs (Vapnik 1989) adopted by the computational learuing community for handling logical, noisy and uncertain data, minimum encoding approaches (Wallace Sr; Freeman 1987) and Bayesian methods (Buntine 1990). For instance, prob- ably approximate correctness (PACncss) is a notion used in computational learning theory to measure con- fidence in learning error (Valiant 1985). Under the usual definition of PACness, if confidence is high that error is low then the same will hold for a Bayesian method no matter what prior was used (this is a di- rect corollary of (Buntine 1990, Lemma 4.2.1)). In Bayesian statistics, “large enough” data means there is so much data that the result of a Bayesian method is virtually the same no matter what prior was used for the analysis; this situation is referred to as stable estimation (Berger 1985). We say a sample is suficient when the condition of “large enough” more or less holds for the sample. (Be- cause the condition is about asymptotic convergence, it will only ever hold approximately.) This definition is about as precise as is needed for this paper. This means, for instance, that a sufficient sample is a rea- sonably complete specification of the semantics of the “true” concept but not its representational form. (As- sume the classification being learned is time indepen- dent so the existence of a true concept is a reasonable assumption.) A sufficient sample makes the search well-specified. For instance, if we are seeking an accurate classifier, then with a sufficient sample we can determine the “true” accuracy of all hypotheses in the search space reasonably well just by checking each one against the sample. That is, we just apply the principle of em- pirical risk minimisation (Vapnik 1989). With an in- sufficient sample, we can often check the accuracy of some hypotheses the same way-this is often the pur- pose of an independent test set-but the catch is we cannot check the accuracy of all hypotheses because inaccurate hypotheses can easily have high accuracy on the sample by chance. For instance, this happens with decision trees; it is well known they often have to be pruned because a fully grown tree has been “fitted to the noise” in the data (Cestnik et al. 1987). A variation on this theme has been made by Weiss and colleagues who report a competitive method for learning probabilistic conjunctive rules (Weiss & Kapouleas 1989). They make the hypothesis space small (conjuncts of size three or less), so the sample size is nearly “sufficient”. They then do a near ex- haustive search of the space of hypothesesyomething not often done in machine learning-to uncover the rule minimising empirical risk. It is unfortunate, though, that a sufficient sample is not always available. We may only have a limited supply of data, as is often the case in medical or bank- ing domains. In this case we would hope our learning algorithm will make the best use of the limited supply of data available. How can this be done? Computational learning theory gives a basis for learning algorithms Valiant’s “theory of the learnable” was concerned with whether a machine can learn a particular class of con- 738 MACHINELEARNING cepts in feasible computation (Valiant 1985). This theory centered around three notions: uniform con- vergence or distribution-free learning, that learning should converge regardless of the underlying distri- butions, probable approzimate correctness (PACness), that the best a learner can do is probably be close to correct, and the need for tractible algorithms for learn- ing. These three notions and variations have since been vigorously adopted for a wider range of learning prob- lems by the theoretical community to create an area called computational learning theory. The theory has been concentrated on the strength of bias and resultant worst-case complexity results about learning logical concepts . Evidence exists , however, that these results can be improved so better principles exist for the algorithm designer. Simulations reported in (Buntine 1990) indicate a large gap exists between current worst-case error bounds obtained using uniform convergence and the kinds of errors that might occur in practice. The same gap did not occur when using a Baycsian method to estimate error, although the question of priors clouds these results. In addition, the current bounds only consider the size of the sample and not the contents of the sample. In the simulations, for instance, the space of consistent hypotheses sometimes reduced to one hy- pothesis quite quickly, indicating the “true” concept had been identified; yet bounds based on just the size of the sample cannot recognise this. This identifica- tion can occur approximately in that an algorithm may recognise parts of the concept have been identified. This behaviour has been captured using the “reliably probably almost always usefully” learning framework (Rivest & Sloan 1988), and a technique that generalises this same behaviour is implicit in a Bayesian method (Buntine 1990). It is argued in (Buntine 1990) that these issues arise because of the worst-case properties of the standard PACness notion which is bcased on uniform conver- gence. While uniform convergence has desirable prop- erties, it cannot be achieved when there is less data. In this context, less stringent principles give stronger guides. This is especially relevant in the context of learning noisy or uncertain concepts where a variety of other statistical principles could be used instead. So the third myth is that computational learning the- ory, in its current form, provides a solid basis on which the algorithm designer can perform his d,uties. There are two important qualifications where this is not a myth. First, computational learning theory currently provides the algorithm designer with a skeletal theory of learning that gives a rough guide as to what to do and where further effort should be invested. Second, there are some areas where computational learning the- ory has provided significant support to the algorithm designer. For instance, in the previous section it was argued that with the notion of probably approximate correctness, computational learuing theory provides a basis for learning in the context of a sufficient sample. Qccam’s razor has a simple explanation A standard explanation of Occam’s razor (Blumer et aI. 1987) can be summarized as follows (Dietterich 1989): The famous bias of Occam’s Razor (prefer the sim- plest hypothesis consistent with the data) can thus be seen to have a mathematical basis. If we choose our simplicity ordering before examining the data, then a simple hypothesis that is consistent with the data is provably likely to be approximately correct. This is true regardless of the nature of the simplicity ordering, because no matter what the ordering, there are relatively few simple hy- potheses. An algorithm that looks for a simpler hypothesis un- der certain computational limitations has been called an Occam algorithm (Blumer et al. 1987). While the mathematical basis of Occam algorithms is solid, their useful application can be elusive. A poorly chosen Oc- cam algorithm is rather like the drunk who, having lost his keys further down the road, only searches for them around the lamp post because that is the place where the light is strongest. Search should be directed more carefully. Clearly, an Occam algorithm can only be said to pro- vide useful support for Occam’s razor if it will at least sometimes (not infrequently) find simpler hypotheses that are good approximations. The catch with Occam algorithms is that there is no guarantee they will do so. Suppose all reasonable approximations to the “true” concept are complex. Notice almost all hypotheses in a large space can be considered complex (since size is usually determined from the length of a non-redundant code). Then the framework of constructing a simplic- ity ordering and searching for simpler hypotheses has been pointless. If this almost always turns out to be the case, then the Occam algorithm approach will al- most always not be useful. Certainly no proof has been presented that a guarantee of useful application exists; the main theorem in (Blumer et al. 1987) ignores this problem by assuming the “true” function is of size “at most nn. In other words, we need at least a weak guarantee that during learning, simpler hypotheses will some- times be found that are good approximations. There are two potential arguments for this. The first potential argument is that since we only re- quire a good approximation, the hypothesis space can be reduced in size to one that is sufficient for finding a good approximation. A thorough treatment of this appears in (Amsterdam 1988). For the purposes of discussion, assume there is a uniform distribution on the examples and we are considering the space of all possible hypotheses defined over E kinds of examples. Such a space has size 2E because each kind of example is either in the concept or not. Notice that for any one hypothesis, there are 2EE hypotheses within error e of it. So the smallest space of hypotheses guaranteed BUNTINE 739 to contain a hypothesis within c of the “true” concept must be at least of size 2( lwEjE. So this first argument provides some support, but the reduction factor of just (1 - E) shows the argument is clearly not sufficient to provide a guarantee on its own. Second, if we believe the simplicity ordering implicit in the Occam algorithm is somehow appropriate, that is, simpler hypotheses should be expected to be good approximations, then the Occam algorithm should be useful. Here, the power of the Occam algorithm comes from choosing a simplicity ordering appropriate for the problem in the first place. Bayesian methods sup- port this principle because the simplicity ordering cor- responds to prior belief. In minimum encoding ap- proaches (Wallace & Freeman 1987) the principle is achieved by choosing an appropriate representation in which the “true” concept should be simple. So the complexity argument above needs to be qual- ified: it is not useful in learning “regardless of the na- ture of the simplicity ordering”. Either way, we need to think carefully about an appropriate simplicity order- ing if we are to usefully employ the Occam algorithm. The explanation for Occam’s razor quoted above provides a mathematical basis for Occam’s razor. How- ever, the fourth myth is that this mathematical basis provides a full and useful explanation of &cam’s Ta- ZOT. Two other supporting explanations have been pre- sented that seem necessary to engage this mathemat- ical basis. And we have not yet considered the case where concepts have noise or uncertainty. In this con- text different complementary arguments for Occam’s razor become apparent (Wallace & Freeman 1987). Perhaps the key point is that Occam’s razor finds prac- tical application because of people’s inherent ability to select key attributes and appropriate representations for expressing a learning problem in the first place (Michie 1986). Th ere may also be other more subtle psychological explanations for its use. WniversaP learning methods are best Empirical learning seems to ignore one of the key lessons for AI in the 1970s called the strong knowledge principle (Waterman 1986, page 4): . . . to make a program intelligent, provide it with lots of high quality specific knowledge about some problem area. Whereas techniques such as explanation-based learn- ing, analogical learning, aud knowledge integration and refinement certainly embrace the strong knowledge principle, in empirical learning, as it is often described in the literature, one simply picks a universal learning method, inputs the data and then receive as output a classification rule. While early logical induction sys- terns like Shapiro’s MIS (Shapiro 19S3) and subsequent similar systems do appear to incorporate background knowledge, they usually do so to extend the search space rather than to guide the search (Buntine 1988). Some successful machine learning methodologies do incorporate weaker application-specific knowledge by some means. Two approaches are the careful selection of attributes in which examples are described (Quin- lan et al. 1987; Michie 1986) and the use of various forms of interaction with an expert (Buntine & Stir- ling 1990). I n addition, Bayesian statistics, with its notion of subjective knowledge or prior belief, could provide a means by which application-specific knowl- edge can be cautiously incorporated into the learning process. Yet many comparative studies from the machine learning community, for instance, fail to consider even weak kinds of knowledge about an application that would help decide whether an algorithm is appropriate for an application, and hence whether the comparison of algorithms on the application is a fair one. Algo- rithms are applied universally to all problems without consideration of their applicability. A similar issue has been noted by Fisher and Schlimmer (Fisher & Schlim- mer 1988, page 27). Using a statistical measure to characterize predic- tion tasks instantiates a methodology forwarded by Simon (1969) - d omains must be characterized before an AI system’s effectiveness can be prop- erly evaluated. There is little benefit in stating that a system performs in a certain manner un- less performance is tied to domain properties that predict system performance in other domains. Ad- herence to this strategy is relatively novel in ma- chine learning. The fifth myth is that there exist universal learning algorithms that perform well on any application regard- Zess. Rather, there exist universal learning algorithms (and each of us provides living proof), but these can always be outperformed by a second class of algorithms better selected and modified for the particular appli- cation. A way to develop this second class of non-universal learning algorithms is to develop “targeted” learning methods that, first, are suitable for specific kinds of classification tasks or specific inference models, and, second are able to be fine tuned or primed for the application at hand. The choices necessary in using these algorithms could be made in the light of sub- jective knowledge available, for instance, elicited in an interview with an expert. The correct choice of model is known to have considerable bearing on statistical problems like learning (Berger 1985, page 110). At the broadest level we could choose to model the classification process with probabilistic decision trees or DNF rules, Bayesian or belief nets, linear classifiers, or perhaps even rules in a pseudo lst-order logic such as DATALOG. And for each of these models there are many additional constraints or preferences that could be imposed on the representation to give the learning algorithm some of the flavour of the strong knowledge learning methods. One could choose to favour some 740 MACHINE LEARNING attributes over others in a tree algorithm or prime a belief net algorithm with potential causes and known independencies. Learning should be non-interactive One aspect of learning for knowledge acquisition, not sufficiently well highlighted in earlier statistical ap- proaches, is the capability of promoting interaction with the expert to assist learning. This is done to obtain additional knowledge from the expert that may well be equivalent in value to a possibly expensive sam- ple. The importance of interactive learning was recog- nised as early as 1947 by Alan Turing (Turing 1986, page 124), who said: No man adds very much to the body of knowledge, [sic] why should we expect more of a machine? Putting the same point differently, the machine must be allowed to have contact with human be- ings in order that it may adapt itself to their stan- dards. Interactive learning should be used with caution, however, because experts are often unreliable sources of knowledge. In the context of uncertainty, people have limitations with reasoning and in articulating their reasoning, so knowledge elicited must be inter- preted with caution (Cleaves 1988). Also, we would hope that learning could still be achieved without in- teraction, perhaps at the expense of needing larger samples. However, interaction is not always possible. Some applications require a so-called “autonomous agent”. With these, not only should learning be entirely au- tomatic, there may also be no-one present to help se- lect an appropriate targeted learning algorithm as sug- gested in the previous section. While most researchers now believe that learning can profit with careful expert interaction where pos- sible, and research in this area exists (Angluin 1988; Buntine & Stirling 1990), the sixth myth, that Zearn- ing should be automatic and non-interactive, lives on in many experimental studies reported and many of the algorithms under development. Requirements for a theory of empirical learning This section suggests questions that a theory for learn- ing of classification rules should be addressing. How does the use of a learning system fit in a broader knowledge-acquisition strategy? According to what inference model should classifica- tion proceed, or in other words, what form of classi- fication rules should be learned? What is the induction protocol or typical course of an induction session ? What sorts of questions can the trainer reasonably answer, and with what sort of knowledge can the trainer prime the learning sys- tem? For a particular induction protocol and inference model, how should the system perform induction given its computational resources? What is being searched for, and how should this search be per- formed? What are the average and worst-case computa- tional and data requirements of the system for a given problem ? Furthermore, what problems can be solved with reasonable computational resources, and what amounts of data should be needed? How does a theory of uncertainty relate to the prob- lem of learning classification rules? How can this then throw light on the previous search problem? When and how should subjective knowledge, weak or strong domain knowledge, or other information extraneous to the sample be incorporated into the learning process ? If this is done but poorly, how can the system subsequently detect from evidence in the sample that the incorporated subjective knowledge is actually inappropriate to the application? How reliable are the classification rules learned by the system from available data? How much more data is required, and of which type? Can the sys- tem ask a few pertinent questions or design a few key experiments to improve subsequent results? Are the results sensitive to assumptions implicit in the system? (In Bayesian methods, this includes priors.) It has been argued at various places throughout this paper that Bayesian theory can address at least some of these questions. It is certainly a (seventh) myth, however, that Bayesian methods provide a com- plete theory for designing learning algorithms. There are many complementary statistical perspectives and many complementary theoretical tools such as optimi- sation and search, decision theory, resource-bounded reasoning, computational complexity, models of man- machine interaction, and the psychology of learning, etc. In addition, some of the above questions require a pragmatic and experimental perspective, particular those concerned with the human interface and learning methodology. Acknowledgements Brian Ripley, Donald Michie and RIACS gave sup- port and Peter Cheeseman, Pete Clark, David Haus- sler, Phil Laird, Steve Muggleton, Tim Niblett, and the AAAI reviewers provided constructive feedback. Any remaining errors are my own. References Amsterdam, J. 1988. Extending the Valiant learn- ing model. In Fifth International Conference on Ma- chine Learning, 381-394, Ann Arbor, Michigan. Mor- gan Kaufmann. Angluin, D. 1988. Queries and concept learning. Ma- chine Learning, 2(4):319-343. BUNTINE 74 1 Berger, J. 0. 1985. Statistical Decision Theory and Bayesian Analysis. Springer-Verlag, New York. Blumer, A.; Ehrenfeucht, A.; Haussler, D.; and War- muth, M.K. 1987. Occam’s razor. Information Pro- cessing Letters, 24:377-380. Buntine, W.L. and Stirling, D.A. 1990. Interactive induction. In Hayes, J.; Michie, D.; and Tyugu, E., ed- itors, MI-12: Machine Intelligence 12, Machine Anal- ysis and Synthesis of Knowledge. Oxford University Press, Oxford. Buntine, W.L. 1988. Generalised subsumption and its applications to induction and redundancy. Artificial Intelligence, 36(2):149-176. Buntine, W.L. 1990. A Theory of Learning Classi- fication Rules. PhD thesis, University of Technology, Sydney. Forthcoming. Cestnik, B.; Kononenko, I.; and Bratko, I. 1987. Assistant 86: A knowledge-elicitation tool for sophis- ticated users. In Bratko, I. and Lavrti, N., editors, Progress in Machine Learning: Proceedings of EWSL- 87, 3145, Bled, Yugoslavia. Sigma Press. Cleaves, D.A. 1988. Cognitive biases and corrective techniques: proposals for improving elicitation pro- cedures for knowledge-based systems. In Gaines, B. and Boose, J., editors, Knowledge Acquisition for Knowledge-Based Systems, 23-34. Academic Press, London. Dietterich, T.G. 1989. Machine learning, Tech. Report 89-30-6, Dept. Comp. SC., Oregon State University. To appear, Annual Review of Computer Science, Vol. 4, Spring 1990. Fisher, D.H. and Schlimmer, J.C. 1988. Concept sim- plification and prediction accuracy. In Fifth Interna- tional Conference on Machine Learning, 22-28, Ann Arbor, Michigan. Morgan Kaufmann. Haussler, D. 1988, Quantifying inductive bias: AI learning algorithms and Valiant’s learning framework. Artificial Intelligence, 36(2):177-222. Matheus, C.J. and Rendell, L.A. 1989. Construc- tive induction on decision trees. In International Joint Conference on Artificial Intelligence, 645-650, Detroit. Morgan Kaufmann. Michie, D. 1986. The superarticulacy phenomenon in the context of software manufacture. PTOC. Roy. Sot. (A), 405:185-212. Mingers, J. 1989. An empirical comparison of selection measures for decision-tree induction. Machine Learn- ing, 3(4):319-342. Minsky, M. and Papert, S. 1972. Perceptrons: An Introduction to Computational Geometry. MIT Press, second edition. Mitchell, T.M. 1980. The need for biases in learn- ing generalisations, CBM-TR 5-110, Rutgers Univer- sity, New Brunswick, NJ. Muggleton, S.H. 1987. Duce, an oracle based approach to constructive induction. In International Joint Con- ference on Artificial Intelligence, 287-292, Milan. Quinlan, J.R. and Rivest, R.L. 1989. Inferring decision trees using the minimum description length principle. Information and Computation, 80~227-248. Quinlan, J.R.; Compton, P.J.; Horn, K.A.; and Lazarus, L. 1987. Inductive knowledge acquisition: A case study. In Quinlan, J.R., editor, Applications of Expert Systems. Addison Wesley, London. Rivest, R.L. and Sloan, R. 1988. Learning complicated concepts reliably and usefully (extended abstract). In Seventh National Conference on Artificial Intelligence, 635-640, Saint Paul, Minnesota. Russell, S.J. and Grosof, B.N. 1987. A declarative approach to bias in concept learning. In Sixth National Conference on Artificial Intelligence, 505-510, Seattle. Shapiro, E.Y. 1983. Algorithmic Program Debugging. MIT Press. Simon, H.A. and Lea, G. 1974. Knowledge and cogni- tion. In Gregg, L.W., editor, Knowledge and Cognition, 105-127. Lawrence Erlbaum Associates. Tcheng, D.; Lambert, B.; Lu, S. C-Y.; and Rendell, L. 1989. Building robust learning systems by combin- ing induction and optimization. In International Joint Conference on Artificial Intelligence, 806-812, Detroit. Morgan Kaufmann. Turing, A.M. 1986. Lecture to the London Mathemat- ical Society on 2 February 1947. In Carpenter, B.E. and Doran, R.W., editors, AM Turing’s Ace Report of 1946 and other papers, 106-124. MIT Press. Utgoff, P.E. 1986. Machine Learning of Inductive Bias. Kluwer Academic Publishers. Valiant, L.G. 1985. A theory of the learnable. CACM, 27(11):1134-1142. Vapnik, V.N. 1989. Inductive principles of the search for empirical dependencies. In Rivest, R.; Haussler, D.; and Warmuth, M.K., editors, COLT’89: Second Work- shop on Computational Learning Theory, 3-21, Univer- sity of California, Santa Cruz. Morgan Kaufmann. Wallace, C.S. and Freeman, P.R. 1987. Estimation and inference by compact encoding. J. Roy. Statist. Sot. B, 49(3):240-265. Waterman, D.A. 1986. A Guide to Expert Systems. Addison Wesley. Weiss, S.M. and Kapouleas, I. 1989. An empirical comparison of pattern recognition, neural nets, and machine learning classification methods. In Intema- tional Joint Conference on Artificial Intelligence, 781-- 787, Detroit. Morgan Kaufmann. 742 MACHINE LEARNING
|
1990
|
155
|
910
|
Inductive Learning in a ixed aradigm Setting* David B. Skalak and Edwina E. R&land Department of Computer and Information Science University of Massachusetts, Amherst, MA 01003 SKALAK@CS.UMASS.EDU Abstract In a precedent-bused domain one appeals to previ- ous cases to support a solution, decision, explana- tion, or an argument. Experts typically use care in choosing cases in precedent-based domains, and apply such criteria as case relevance, prototypical- ity, and importance. In domains where both cases and rules are used, experts use an additional case selection criterion: the generalizations that a par- ticular group of cases support. Domain experts use their knowledge of cases to forge the rules learned from those cases. In this paper, we explore inductive learning in a “mixed paradigm” setting, where both rule-based and case-based reasoning methods are used. In particular, we consider how the techniques of case- based reasoning in an adversarial, precedent-based domain can be used to aid a decision-tree based classification algorithm for (1) training set selec- tion, (2) branching feature choice, and (3) induc- tion policy preference and deliberate exploitation of inductive bias. We focus on how precedent- based argumentation may inform the selection of training examples used to build classification trees. The resulting decision trees may then be re- expressed as rules and incorporated into the mixed paradigm system. We discuss the heuristic con- trol problems involved in incorporating an induc- tive learner into CABARET, a mixed paradigm reasoner. Finally, we present an empirical study in a legal domain of the classification trees gen- erated by various training sets constructed by a case-based reasoning module. Introduction Precedent-based domains are areas where one appeals to previous cases to support a solution, decision, ex- *This work was supported in part by the National Sci- ence Foundation, contract IRI-8908481, the Office of Naval Research under a University Research Initiative Grant, con- tract N00014-87-K-0238, and a grant from GTE Laborato- ries, Inc., Waltham, Mass. 840 MACHINE LEARNING planation, or an argument. In such domains, experts typically use care in choosing cases, and apply such criteria as case relevance, prototypicality and impor- tance. In precedent-based domains where both cases and rules are used, experts use an additional selection criterion: the generalizations that a particular group of cases support. Domain experts use their knowledge of cases to forge the rules learned from those cases. Our focus in this paper is the use of a machine learning technique to induce rules from the case base of a mixed paradigm case-based reasoning/rule-based reasoning (“CBR-RBR”) system. Thus, this work is aimed toward a tripartite cooperative “CBR-RBR- ML” system. In this paper, we report on our prelimi- nary steps in this direction. We discuss several ways that CBR can be used syn- ergistically to aid a cooperating inductive decision- tree based learning algorithm: training set selection, branching feature selection, deliberate bias creation, and specification of induction policy. After a brief in- troduction to the hybrid architecture of CABARET [Rissland and Skalak, 19891, our mixed paradigm rea- soning environment, we investigate the control heuris- tics that must mediate between the system goals and the learning goals of a mixed paradigm reasoner. We close with a report on our experience in using ID5 [Ut- gaff, 19881 with the CABARET system. ID5 is an incremental version of the classification algorithm ID3 [Quinlan, 19861, h h w ic applies an information-theoretic test to select an attribute upon which to branch at each stage in the creation of a decision tree. Background: Mixed Paradigm Reasoning Systems Now that some of the basic aspects of CBR are better understood [Kolodner, 1988; Rissland and King, 19881, some researchers have been investigating how to com- bine CBR with other reasoning paradigms. In particu- lar, recent projects have combined CBR with reasoning using production rules, approximate rule-based sys- tems, causal models, and utility-based preference anal- ysis [Rissland and Skalak, 1989; Bonissone et al., 1990; Koton, 1988; Oskamp et ab., 1989; Goel and Chan- From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. drasekaran, 1988; Sycara, 19871. Our own work has focused on combining precedent-based CBR with rule- based reasoning in adversarial domains. In general, a hybrid approach offers several potential strengths: (1) the ability to overcome blind spots of the individ- ual co-reasoners, (2) the capacity to let the most ef- ficient or somehow most appropriate reasoner handle the tasks for which it is best suited, and (3) the Aexibil- ity, power and robustness that arise from representing domain knowledge in a variety of forms. Domains that have been the subject for such sys- tems include the law and the interpretation of legal rules, corporate mergers and acquisitions, medical and mechanical diagnosis, and labor mediation. Our own research has been primarily in the legal domain, an area we feel presents some of the problems of mixed paradigm systems in a pure and often extreme form: 1. The necessity of understanding the ambiguous terms in which rules are stated. 2. The need to extract the meaning of an individ- ual case in the context of other cases. 3. The modeling of the interaction of a given set of rules and a large mass of cases, each purporting to deal with the same subject matter, each simul- taneously limiting and expanding the knowledge of the other. Applying different knowledge representations and reasoning modes in a hybrid architecture requires so- phisticated control mechanisms. One general control approach is to apply knowledge handled initially in one form (e.g., cases) in another form (e.g., rules). This shift in perspective can aid the reasoners’ cooperative efforts and afford a common basis to compare differ- ences in the knowledge of diverse knowledge sources. Thus, one of the advantages of a hybrid approach is that domain knowledge can be represented in a vari- ety of ways. A knowledge engineer working in a mixed paradigm environment strives for an appropriate ini- tial mix. Of course, no unique or optimal mix exists and, more importantly, the mix should be amenable to change as the total system evolves. For instance, certain clusters of cases might be inductively general- ized into learned rules. Coalescing cases into general- ized rules typically occurs during the initial knowledge engineering. (In fact, in pure RBR systems, this pro- cess is carried to an extreme in that all case knowledge must be represented in rule form.) However, in most domains, such re-representation of cases as rules (and sometimes vice versa) is a continuing process. Thus, concerns about learning - whether done initially by the knowledge engineer or over time by a learning mechanism - are paramount in mixed paradigm sys- tems. What distinguishes a mixed paradigm CBR-RBR system from a pure RBR system, for instance, is the continuing availability of the cases for learning. This feature benefits the application of learning tech- niques: inductive learning methods can be applied at any time and training instances need not be manufac- tured. However, one usually does not want to have the system learn at every turn, and, furthermore, one does not usually feel every case is equally important to the learning. -Control is- the issue,-both in-the basis and the timing of learning. Using CBR in the Service of Inductive Learning In this section we address several areas in which CBR can be used to aid inductive learning: 1. Training set selection 2. Feature selection 3. Creation of deliberate bias and selection of induction policy. In a final section, we discuss our empirical results as to the first of these, training set selection. Using CBR for Training Set Selection In many domains it may be inefficient, impracticable or inadvisable to include all the members of a case base in the training set to be put to an inductive learning algorithm. The sheer number of available cases can be prohibitive. The incremental benefit of including many cases of the same ilk may be small. Human experts themselves are selective in the use of cases. These observations are borne out in our domain, the law, where the case base is large, many cases are sim- ilar to other cases, and neither judges nor attorneys use alI the cases available to them to formulate rules. These observations point to a sampling problem: how to select a proper subset of a case base that accurately reflects the entirety. In our implemented systems, sta- tistical sampling has not been possible in view of the “small” number of cases represented. But the question remains as to the means of-selecting a set of cases that can serve as a surrogate for the entire case base. The various clas&cations of cases recognized in CBR suggest an attack on this sampling problem: use CBR-generated classes to construct surrogate training sets. In CBR, cases may be ranked by their similar- ity to a given cases (e.g., most-on-point), their use- fulness in a given situation (e.g., most salient), their precedential capacity (e.g., “best case to cite”, counter- example), and on finer distinctions (e.g., counterex- amples may be anomalous, extreme, or “incursive”). Recognition of case taxonomies of these sorts contrasts with the usual treatment of instances in inductive learning, where are all examples are treated equally, without regard to the various roles they play, aside from their classification, say as positive or negative in- stances. Notable exceptions to this democratic treat- ment include examples that have the power to dras- tically reduce a search space, such as “near misses,” [Winston, 1975; Buchanan et al., 19901 and, under the Candidate Elimination Algorithm [Mitchell, 19781, ex- amples that can halve a version space. SKALAKANDRISSLAND 841 If the thesis is borne out that certain subclasses can stand as surrogates for the entire case base, then the specially selected training sets may improve (1) the efficiency of the learning (e.g., a given level of perfor- mance can be achieved with fewer cases) and (2) its quality (e.g., a given number of special cases can lead to better performance than an equal number of non- special cases). In a mixed paradigm setting, where such categorization of cases is done by the CBR mod- ule during the normal course of problem solving, little or no additional overhead is spent in generating the training sets we propose for consideration. It remains for further experiments to determine whether outside a mixed paradigm environment any benefits from us- ing CBR to select a useful subset of training instances outweigh the cost of the CBR analysis. To test our hypothesis, we have performed a series of experiments on rule generation from sets of cases generated by a case-based reasoner. The categories we have used to form training sets include: (1) “Most-On-Point” cases; (2) “Best” cases; (3) “Near Miss” cases; (4) “Trumping” cases; and (5) “Conflict” cases. Empirical results using these five training sets are pre- sented below, after a description of the construction of these case sets. Most-On-Point Cases Training Set To construct the most-on-point training set, we first performed a CBR analysis of each case in the case base, regarding each case as a problem situation presented de novo to the system. The most-on-point cases for a problem case are defined as those maximal in a partial ordering of cases according to similarity with the prob- lem case. To form a training set composed of most-on- point cases, we take the union (over all the cases in the case base) of the cases that have appeared as a most similar (most-on-point) case for any problem case in the case base. Specifically, the partial ordering by similarity used in these experiments is created as follows. The universe of factors or “dimensions” used to determine similarity is first restricted to those dimensions that are applicable to the problem case. The similarity relation on cases is then defined in terms only of the dimensions from this new, restricted universe. Specifically, a case B is more similar to the problem case than Case A if case A’s applicable dimensions (taken from the restricted universe) are a subset of case B’s applicable dimen- sions. This similarity relation defines a partial order on the case base. It can be represented as a rooted directed graph, which for historical reasons is called a “claim lattice” [Ashley, 19901. The most-on-point cases are the maximal elements in this rooted graph, and are found in the nodes closest to the root node, which contains the problem case. Best Cases Training Set To form the training set consisting of “best” cases, we take the union (over all the cases in the case base) of the cases that have appeared as a best case to cite in support of one side or the other in a problem case. Given a problem case and a point of view (say, plain- tiff’s or defendant’s), the best cases to cite are defined as most-on-point cases that have been decided for that viewpoint and that share strength with the problem situation along at least one dimension. Near Miss Cases Training Set To form the training set consisting of near miss cases, we take the union (over all the cases in the case base) of the cases that have appeared as a “near miss” case for another case. For the purpose of these experiments, a near miss case was defined as a case that appeared as a most-on-point case in an “extended” claim lattice but not as a most-on-point case in the usual claim lattice. The extended claim lattice is constructed analo- gously to the usual lattice, but instead of restricting the relevant universe of dimensions to those applicable to the problem case, the universe of dimensions is taken as the union of the applicable and the “near miss” di- mensions. A near miss dimensionis a dimension all of whose prerequisites are satisfied, except a single, pre- viously designated prerequisite. Dimensional prereq- uisites ensure that enough background information is available in the case for it to make sense to analyze a case with respect to that factor. Thus a near miss case is a case that would be com- pelling if some additional factor(s) were present in the problem case. Near misses are often probative because they embody situations that are nearly most-on-point but nonetheless exhibit well-focused differences with a problem situation. Trumping Cases Training Set To form this training set, we take the union (over all the cases in the case base) of pairs of cases that have appeared as a “trumping” and a “trumped” case for a problem case, where the trumping and trumped cases are the best cases that can be cited for their respective viewpoints. One case is said to “trump” another if (1) it is strictly more-on-point than the other: that is, the trumped case applicable factors are a proper subset of those of the trumping case, and (2) it has been decided oppositely. Conflict Cases Training Set To form this training set, we take the union (over all the cases in the case base) of groups of cases that have appeared in “conflict nodes” in the claim lattice. They are cases of equal similarity but of opposite clas- sification. A conflict node is a node containing cases that have been classified differently (e.g., held for plaintiff, held for defendant) despite the fact that each is equally sim- 842 MACHINE LEARNING ilar to a given case. Such cases share the same applica- ble factors at the dimensional level (at least where the universe of applicable dimensions is restricted to those applicable to a given case.) The choice of these sets as candidates for experimen- tation is supported by various intuitions. To find an ef- fective training set requires a selection of the most rep- resentative examples or those packing the most punch. If one thinks of the cases as embedded in a many- dimensioned space, where the dimensions are the rele- vant domain factors or other features used in the case representation, relevant cases cluster in the subspace occupied by the current problem case. The rationale for using training sets of most-on-point and best cases is that by selecting only these cases one selects the clus- ters for training, and avoids some of the outliers, cases that exist in a different subspace from the others. The examination of a training set incorporating near misses relies on previous work that recognizes the ca- pacity of the near miss to decrease the size of a search space [Winston, 1975; Buchanan et al., 19901. The intuition here is that in order to delimit a concept, examples immediately inside (“near hits”) and imme- diately outside (near misses) should be included. The near-miss training set incorporates cases that would be among the most relevant, if at least one more feature were known about the case. One of the benefits of a near-miss case is that it isolates one or a few features and “controls” for their presence. The trumping and conflict case training sets reflect the intuition that induction may be enhanced by in- cluding groups of quite similar cases of positive and negative classification. Further, examples that high- light problems in classification can be telling. In a trumping/trumped pair, the problem is that the pres- ence of one or more additional factors can toggle the outcome of a case (cf. [Subramanian and Feigenbaum, 1986]). I nc u m conflict cases exploits the similar in- 1 d’ g tuitive idea that some differences in magnitude of the applicable factors must be responsible for distinctions in classification. These training sets are particularly relevant to the credit assignment problem as it applies to factor analysis: finding differences that make a dif- ference. Of course, alternative training sets exist, and there are reasons why the suggested training sets may be inadequate. For instance, the most-on-point training set has been described as eliminating outlying cases, but these outliers can provide important exceptions to a general rule. A couple of responses to this partic- ular observation are possible. One possible response is that in a mixed paradigm setting, other CBR meth- ods, such as “distinguishing,” can be invoked to explain these outlying cases. Distinguishing identifies, high- lights and manipulates relevant differences between cases. Distinguishing is a useful technique, both in the law, and in CBR, where difference links are fre- quently maintained to index a case base [Ashley, 1987; Bareiss et ab., 1987; Falkenhainer, 19881. A case that can be distinguished easily from a group of other cases need not be used to support rule induction. Our task here is merely to come up with domain rules of thumb that reflect the classification knowledge inherent in a case base. From this perspective, exceptions are not as bothersome, since the usual functions inherent in a CBR module can compensate for shortcomings in heuristic rules. Using CBR for Feature Selection One of the major drawbacks of a similarity-based in- ductive learning system is the lack of domain knowl- edge available to the learner. Frequently, features are treated syntactically, without supporting semantic knowledge. In ID5 for instance, the attributes chosen for branching depend ultimately on the frequency of their associated values, without regard to the impor- tance of the attribute to that domain. CBR methods and the domain knowledge implicit in the cases can be used to overcome this drawback, The basic idea behind using CBR to aid the selec- tion of features for decision tree branching is that CBR elicits domain knowledge inherent in the cases that is ignored by the fundamentally statistical classification scheme used by ID3 family of algorithms. CBR analy- sis can provide some of the domain theory through its identification of important factors. For instance, fea- tures that are used as distinguishing features in CBR may be good candidates for branching. As we have mentioned, distinguishing is used in precedent-based argumentation to show why a distinction makes a dif- ference in the outcome of a case. Typically one shows that factors that have appeared in one case but not in another account for the difference in their outcomes. An advocate distinguishes cases cited by an opponent (or anticipated by the advocate that the opponent will cite), to show that the result the opponent seeks is de- pendent on additional factors not present in the cur- rent case, or on features that the current case possesses that are absent in the cited case. Distinguishing fac- tors are exactly the sort of features one should consider at branches in a decision tree. The use of a component that takes advantage of CBR-provided domain knowledge as well as of information-theoretic methods may provide a basis for enhanced classification techniques. Mingres [1989] has shown that using a variety information-theoretic tests alone to select branching features results in no more accurate classification than does a random selection of branching attributes. Mingres’s results suggest a need to bring domain knowledge into the choice of branch- ing attributes. CBR can elicit such knowledge inherent in the training cases themselves. SKALAKANDRISSLAND 843 Using CBR for Other Learning Tasks CBR has additional potential to aid inductive learn- ing. First, CBR can be used to take advantage of the bias inherent in inductive generalization. In an adver- sarial domain such as the law, a case-based reasoner can deliberately use bias advantageously by selecting (only) those cases that are most favorable or by de- scribing cases in terms that are most favorable. Fa- vorable precedents can then be used in the training set to create a rule favorable to that party. In fact, any domain can be considered “adversarial” where one can assume differing viewpoints or hypothetically as- sess the strength of the argument for one outcome or another. Second, CBR can be used to formulate induction policy. Every case that would alter an induced rule need not drive incremental generalization or specializa- tion. CBR’s capacity to tag examples by subcategory, such as “anomalous” or “distinguishable,” can be used by an inductive learner to avoid generalization on the basis of an unrepresentative example. Inductive Learning and CABARET In this section, we describe our preliminary investi- gation of the addition of a similarity-based learning component to an existing hybrid architecture. A Mixed Paradigm Reasoning Program CABARET (“CAse-BAsed REasoning Tool”) provides an environment to explore mixed paradigm CBR-RBR reasoning [Rissland and Skalak, 19891. The current ar- chitecture includes six major knowledge sources: (1) a case-based reasoner modelled after the architecture of HYPO [Ashley, 19901; (2) a production system, per- mitting forward and backward chaining; (3) an agenda- based control module, which, on the basis on the cur- rent state of problem solving, places prioritized tasks on an agenda to be performed by either the CBR or RBR module; (4) a CBR monitor, which monitors the progress of the case-based reasoner and extracts infor- mation relevant to the control module; (5) an RBR monitor, which performs the analogous task for the rule-based reasoner; and (6) a corpus of domain knowl- edge, in such form as hierarchical nets, which is prof- itably expressed independently of the other knowledge sources because it cannot be expressed most suitably as rules or cases or simply because both RBR and CBR components make use of it. CABARET’s CBR component is somewhat different from a stand-alone CBR reasoner like HYPO [Ashley, 19901, in that it is augmented by the ability to distin- guish and analogize cases on the basis of their behavior under a rule-set as well as on the basis of “dimensions” internal to the CBR module. Heuristics to Invoke Learning Ongoing experiments in CABARET involve the ad- dition of one more knowledge source: the ID5 learn- ing algorithm [Utgoff, 19881. To trigger this additional knowledge source, several control heuristics based on broadening and narrowing of rules have been devel- oped. Rule “broadening” is applied when a domain rule with a given conclusion fails to fire, but the user has assumed a point of view that wants to establish the rule consequent. Narrowing is used when one wants to prevent a rule from firing. In CBR, broadening is accomplished in a variety of ways. For instance, one can show that a rule- antecedent is not necessary, expand the scope of a poly- morphic (“open-textured”) antecedent, or construct analogies with cases where the rule has in fact fired, and so forth. Inductive learning can be used to support such meth- ods, such as expanding the scope of important rule terms. Since in the law, as in some other domains, cases record whether certain terms in the statute are satisfied by the case at hand, these determinations can classify cases for use as training examples to induce the meaning of the term. In our experiments, we have used a court’s determinations about particular terms in a legal statute (governing the home office deduction under Federal income tax law), to have CABARET and ID5 induce rules regarding these important statu- tory predicates. One can also use inductive techniques to create a rule that competes with existing rules. Then, if the current problem case satisfies the induced rule, one may ar- gue that the consequent is established on the basis of precedent. In the law, this sort of use of rules induced from common law cases (a part of the cLblackletter” law) plays a major role in appellate argument. The bias inherent in an adversarial domain also per- mits creative use of an inductive learning algorithm to manipulate bias deliberately through selection of the cases that go into the training set, as noted above. In addition, pointers between cases provided by the cases themselves can be used in some domains in conjunc- tion with CBR to select “biased” training sets. Legal cases often cite a variety of other cases. To broaden a rule upon the failure of other approaches to rule- expansion, CABARET may include heuristics for the studied selection of a training set that favors one side or another. Similar techniques may be used for narrowing, in which one discredits a rule or limits its scope. CABARET attempts to narrow a rule when it has fired but the vantage point of the user is against its appli- cation. An Experiment in Federal Taxation In order to gain some experience with inductive learn- ing in a mixed paradigm setting, to test some of the proposed uses of CBR for inductive learning and to evaluate the domain rules induced by ID5, we have performed a series of experiments with a case base of actual Federal income tax cases dealing with the so- 844 MACHINE LEARNING called “home office deduction.” Under certain strin- gent conditions set forth in $280A of the Internal Rev- enue Code, relating to the regular and exclusive use of the space as an office and other requirements, a taxpayer may take a deduction against gross income for expenses incurred in connection with the home of- fice, such as a proportion of the rent, utilities, and equipment?. The case base used for these experiments consisted of 25 litigated cases drawn mostly from Fed- eral Tax Court and the Federal Courts of Appeal. In order to test the efficacy of each of the train- ing sets discussed above, we have run ID5 at each of two levels of representation produced by the case-based analysis of a case: 1. the factual-predicate (“F.P.“, also called the inter- pretation @zme level), of features and values de- rived by the CBR component of CABARET from the base-level features (there are 20 factual predi- cates); 2. the dimension (“Dim.“) level, with values t or nil, according to whether or not the dimension was ap- plicable in the case-based analysis of that case ( 14 dimensions). Cases at both levels of representation were classi- fied as + or -, according to whether the taxpayer re- ceived the home office deduction in the actual legal case. Since no acknowledged “correct” theory of the home office deduction domain is available, the trees derived from each training set were compared to the classification tree derived from the entire case base (the “All Cases” training set). The tree derived from the entire case base served as a surrogate for a target con- cept definition. All the cases were then classified by the resulting classification trees to test each tree’s classifi- cation accuracy. If a case was classified incorrectly by the tree, the case was counted as an error below. If a case was unable to be classified by a decision tree, it was recorded as “No Class” in the tables following. To serve as a control for each CBR training set of a given size, a collection of training sets of that size was generated, containing a random selection of cases from the case base 2. The average number of errors and un- classified cases were then computed for these random collections. For the random sets of size 19 and 8, 20 trees generated from random cases were constructed; for the random sets of size 3, 100 trees were used to compute the average errors3. We present empirical re- sults and summarize the performance of each training set. ‘Nothing herein may be construed as legal advice, for which the reader should consult his own tax practitioner. 2Except that no collection of precisely 18 random cases was generated. 3More variation was observed in the classification accu- racy of the training sets of sise 3; hence the larger sample. 1 All Cases, Most-on-point & Best Cases Training Sets 1 Contrary to intuition, the random training sets per- formed as well as or better than the most-on-point and best cases training sets. On the other hand, the size of the most-on-point and best cases sets was nearly that of the entire case base, and one might expect similar performance from any training collection of this rela- tive size. It remains for experiments with other case bases to determine if the most-on-point and best cases training sets (as we have constructed them) are often almost as large as the case base itself. We note that the dimensions did not completely dis- criminate the case base. This observation underlines the necessity of comparing the magnitudes of relevant factors, and not just their presence or absence. The comparison of values along dimensions is an integral feature of the argument generation module of HYPO [Ashley, 19901. Near Miss Cases Training Sets Training Set I Level 1 Cases 1 Errors ) No Class Near Mi I sses Dim. 8 4 0 L Dim. 8 5.25 0.80 .sses F.P. 8 3 3 n F.P. 8 3.75 3.55 At the dimension level, near misses yielded slightly fewer errors and unclassified cases than random case sets. These results may tend to confirm the efficiency of including near misses in a training set. At the fac- tual predicate level, performance was approximately equivalent. Trumping Cases Training Sets ‘~ In this domain, it is rare that one side can cite a case that is strictly better than its opponent’s best case. Only three cases that were members of a trumping- trumped pair of cases were found. Nevertheless, even using this minuscule training set, only 4 errors were produced at the dimension level. Random collections of three cases generated trees that yielded over 8 errors. SKALAKANDRISSLAND 845 In part, the superior performance of the trumping cases may be attributed to their providing pairs of cases of opposing classification that possess highlighted differ- ences. Trumping case pairs can therefore illuminate the credit assignment problem. They implicitly isolate factors whose presence or absence makes a critical dif- ference, and thus can be assigned the blame or credit for a classification. Conflict Cases Training Sets ‘~~ Ten sets of training examples, each containing only cases derived from a conflict node were generated for this experiment. All conflict nodes for all cases were generated, and were then filtered to eliminate conflict nodes that contained too few cases to present two suf- ficiently strong opposing viewpoints, or too many to provide a focused conflict 4. Average figures are used for the number of cases, errors and unclassified cases in the table above. At the factual predicate level, random training sets performed better than the conflicts training sets. How- ever, at the dimension level, while the total number of errors and unclassified cases were the same for the conflicts and random sets, the distribution of these er- rors was notably different. Random training yielded a number of mistakes in classification, but almost no cases that could not be classified. The conflicts cases resulted in a tree that recognized that alternative ar- guments were available: a relatively large number of cases were unclassifiable, but a more reliable classifica- tion resulted when made. Branching Feature Selection While we have not yet performed a formal study of the utility of the home office classification trees, several in- formal observations may be noteworthy. We noted, for example, significant agreement in the attributes that appear in the top several levels of many of the deci- sion trees generated in these experiments. These fac- tors include the relative time that the taxpayer spent in the home office and any other office, whether the home office was in a separate structure, whether the home office was necessary to perform the taxpayer’s assigned responsibilities, whether it was used occasion- ally or regularly, and how many hours per week the home office was used. As discussed in more detail else- where [R&land and Skalak, 1990; Skalak, 19891, these factors are arguably among the most crucial to one’s home office deduction claim. ‘Specifically, nodes containing fewer than 4 or more than 8 cases were eliminated. Finally, the shape of the following tree based on a most-on-point training set is representative of the un- balanced trees observed throughout these experiments. relative-time-in-home-off ice f A t in-separa e-structure A + f t net-to-perform-duties A + f/ \t / \ - primary-responsibility-location / \ / \ Figure 1: Classification tree generated by ID5 using Most-On-Point Training Set, Dimension level (pruned to show first several branching features) Conclusions Just as experts can use cases to create a new rule or refine an old one, cases can be so used by a mixed paradigm system with a learning component. We have shown how the incorporation of an inductive learning component into a mixed paradigm CBR-RBR system provides many opportunities for fruitful synergy. Gen- erally, a learning capability can help the system evolve. Specifically, CBR can aid an inductive learning algo- rithm through the informed selection of training in- stances and branching attributes, the control over in- duction policy, and the deliberate exploitation of in- ductive bias. Empirical results are mixed as to the utility of CBR to select training sets. Relatively large training sets suggested by CBR ( most-on-point, best cases) did no better than a random selection of cases at each of two representation levels. Smaller training sets that explic- itly incorporated similar training instances of opposite classifications (trumping, conflict, near miss) yielded fewer classification errors at a domain factor level. Acknowledgments We are grateful to Paul Utgoff for supplying the code for ID5 and to Dan Suthers for providing many of the software tools underlying the system. We thank also Elizabeth Gene and Tony Reish for their assistance in coding CABARET. 846 MACHINE LEARNING References [Ashley, 19871 Kevin D. Ashley. Distinguishing - A Reasoner’s Wedge. In Ninth Annual Cognitive Sci- ence Society Conference, University of Washington, Seattle, 198’7. [Ashley, 19901 K evin D. Ashley. Modebling Legal Ar- gument: Reasoning with Cases and Hypotheticals. M.I.T. Press, Cambridge, 1990. In press. [Bareiss et al., 19871 E. Ray Bare&s, Bruce W. Porter, and Craig C. Wier. Protos: An Exemplar-Based Learning Apprentice. In Proceedings Fourth Inter- nationaE Workshop on Machine Learning, pages 12- 23, University of California at Irvine, June 1987. [Bonissone et al., 19901 Piero Bonissone, Lauren Blau, and Saad Ayub. Leveraging the Integration of Ap- proximate Reasoning Systems. In Proceedings of the AAAI Symposium on Case-Based Reasoning-l 990, Palo Alto, March 1990. [Buchanan et aE., 19901 B. G. Buchanan, E.L. Riss- land, P. R. Rosenbloom, H. T. Ng, and J. Sullivan. Intelligent Example Selection for Learning Systems, 1990. In press. [Falkenhainer, 19881 Brian Falkenhainer. The Util- ity of Difference-Based Reasoning. In Proceedings AAAI-88, St. Paul, August 1988. American Associ- ation for Artificial Intelligence. [Goel and Chandrasekaran, 19881 Ashok Goel and B. Chandrasekaran. Integrating Model-Based Rea- soning and Case-Based Reasoning. In Proceedings of the AAAI Workshop on AI in Design. American Association for Artificial Intelligence, August 1988. St. Paul. [Kolodner, 19881 Janet L. Kolodner, editor. Pro- ceedings of the DARPA Case-Based Reasoning Workshop-1988, Clearwater Beach, FL, May 1988. [Koton, 19881 Phyllis A. Koton. Using Experience in Learning and Problem Solving. PhD thesis, Depart- ment of Electrical Engineering and Computer Sci- ence, MIT, 1988. [Mingres, 19891 John Mingres. An Empirical Compar- ison of Selection Measures for Decision-Tree Algo- rithms. Machine Learning Journal, 3:319-342, 1989. [Mitchell, 19781 Tom Mitchell. Version Spaces: An Approach to Concept Learning. PhD thesis, Com- puter Science Dept., Stanford University, 1978. Rep. No. STAN-CS-78-711. [Oskamp et ad., 19891 A. Oskamp, R.F. Walker, J.A. Schrickx, and P.H. van den Berg. PROLEX, Di- vide and Rule: A Legal Application. In Proceedings of the Second Internationab Conference on Artificial Intelligence and Law, Vancouver, B.C., June 1989. [Quinlan, 19861 J.R. Quinlan. Induction of Decision Trees. In Machine Learning Z(l), pages 81 - 106. Kluwer Academic. Boston. 1986. [Rissland and King, 19881 Edwina L. Rissland and James A. King, editors. Proceedings of the AAAI- 88 Case-Based Reasoning Workshop, St. Paul, Au- gust 1988. American Association for Artificial Intel- ligence. [Rissland and Skalak, 19891 Edwina L. Rissland and David B. Skalak. Combining Case-Based and Rule- Based Reasoning: A Heuristic Approach. In Pro- ceedings IJCAI-89, Detroit, August 1989. Interna- tional Joint Conferences on Artificial Intelligence, Inc. [Rissland and Skalak, 19901 Edwina L. Rissland and David B. Skalak. Opportunities for Learning With and Within CBR. In Proceedings of the AAAI Sym- posium on Case-Based Reasoning-1990, Palo Alto, March 1990. [Skalak, 19891 David B. Skalak. An Experiment with Decision Trees and Legal Cases. Internal Memo- randum, Department of Computer and Information Science, University of Massachusetts, Amherst, MA, 1989. [Subramanian and Feigenbaum, 19861 Devika Subra- manian and Joan Feigenbaum. Factorization in Experiment Generation. In Proceedings AAAI-86, Philadelphia, August 1986. American Association for Artificial Intelligence. [Sycara, 19871 Katia Sycara. ResoEving Adversarial Conflicts: An Approach Integrating Case- Based and Analytic Methods. PBD thesis, School of Information and Computer Science, Georgia Institute of Technol- ogy, 1987. [Utgoff, 19881 Paul E. Utgoff. ID5: An Incremen- tal ID3. In Proceedings of the Fifih Internationab Conference on Machine Learning, Ann Arbor, June 1988. [Winston, 19751 Patrick H. Winston. Learning Struc- tural Descriptions from Examples. In Winston, P.H., editor, The Psychology of Computer Vision, pages 157 - 209. McGraw-Hill, New York, 1975. Reprint of Rep. No. TR-231, AI Laboratory, MIT. SKALAKANDRISSLAND 847
|
1990
|
156
|
911
|
A Hybrid Connectionist, Sy b&c Learning System Lawrence 0. Hall and Steve G. Romaniuk Department of Computer Science and Engineering University of South Florida Tampa, Fl. 33620 email:hall@sol.usf.edu romaniuk@sol.usf.edu Abstract This paper describes the learning part of a sys- tem which has been developed to provide ex- pert systems capability augmented with learning. The learning scheme is a hybrid connectionist, symbolic one. A network representation is used. Learning may be done incrementally and requires only one pass through the data set to be learned. Attribute, value pairs are supported as a vari- able implementation. Variables are represented by groups of connected cells in the network. The learning algorithm is described and an example given. Current results are discussed, which in- clude learning the well-known Iris data set. The results show that the system has promise. Introduction This paper describes a hybrid connectionist, symbolic approach to learning the type of information that would be used in rule-based expert systems. The sys- tem does its learning from examples. They are encoded in much the same way that examples to connection- ist systems would be presented. The exceptions are due to our variable representation. The system can learn concepts where imprecision is involved. The net- work representation allows for variables in the form of attribute, value pairs to be used. Relational com- parators are supported. The system has been used to learn knowledge bases from some small examples orig- inally done in EMYCIN [Van Melle, et. al. 19841. It has also been used in learning defects in CMOS semi- conductor chips [Romaniuk and Hall 19891 and the Iris data set [Weiss, et. al 19891. In this paper, the em- phasis is on the learning algorithm. It uses a network structure, which is configured based on the distinct ex- amples presented to the system. For examples which resemble others previously seen, bias values of cells in the network are adjusted. The system can learn in- crement ally. Rules may also be directly encoded in the network [Romaniuk and Hall 19891, but this is not shown here. SC-net - A Fuzzy Connectionist Expert System A connectionist model is a network, which in its sim- plest format has no feedback loops. It consists of three types of cells (input, output, and hidden cells). Ev- ery cell has a bias associated with it, which lies on the real number scale. Cells are connected through links which have weights associated with them. In the SC- net model of a connectionist network, each cell can take on an activation value within the range [O..l]. This cor- responds to the fuzzy membership values of fuzzy sets. The uncertainty handling constructs come from fuzzy set theory [Kandel 19861. In fuzzy logic one may define disjunction (fOR) as the maximum operation, conjunction (fAND) as the minimum operation and complement (fNOT) as strong negation. Since fOR and fAND are defined as maxi- mum and minimum operations, we let certain cells act as max and min functions, in order to provide for the above operators. In order to be able to distinguish cells as modeling the min (fAND) or the max (fOR) func- tion we use the sign of the bias of a cell to determine which of the two functions is to be modeled. Further- more, we denote a bias value of zero to indicate when a cell should operate as an inverter (fNOT). The Network Structure We can think of every cell in a network accommodat- ing n inputs I, with associated weights CW,. Every cell contains a bias value, which indicates what type of fuzzy function a cell models, and its absolute value represents the rule-range. Every cell Ci with a cell ac- tivation of CAa (except for input cells) computes its new cell activation according to the formula given in Figure 1. If cell Ca (with CA;) and cell Cj (with CAj ) are connected then the weight of the connecting link is given as CWi,j, otherwise CWa,j = 0. Note, an activation value outside the given range is truncated. An activation of 0 indicates no presence, 0.5 indicates unknown and 1 indicates true. In the initial topol- ogy, an extra layer of two cells (denoted as the positive and the negative cell) is placed before every output cell. These two cells will be collecting information for HALLANDROMANIUK 783 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. CAi - cell activation for cell Ci, CAi in [O..l]. CWi,j - weight for connection between cell Ci and Cj, CWi,j in R. CBi - cell bias for cell C’s, CBi in [-l..+l]. . CA; = mznj=o ,.., i-l,i+l,..n (CAj * CWi,j) * ICBiI CBi < 0 maXj=o ,.., i-i,i+l,..n (CAj * CWi,j) * ICBiI CBi > 0 1 - (CAj * CWi,j) CBi = 0 and CWi,j # 0 Figure 1: Cell activation formula (positive cell) and against the presence of a conclusion (negative cell). These collecting cells are connected to every output cell, and every concluding intermediate cell (these are cells defined by the user in the SC-net program specification). The final cell activation for the concluding cell is given as: CAoutput=CApositive-cell+CAnegative-cell-O.5 . Note, the use of the cell labeled UK (unknown cell) in Figure 2. This cell always propagates a fixed activa- tion of 0.5 and, therefore, acts on the positive and the negative cells as a threshold. The positive cell will only propagate an activation >= 0.5, whereas the negative cell will propagate an ac- tivation of <= 0.5. Whenever there is a contradiction in the derivation of a conclusion, this fact will be repre- sented in a final cell activation close to 0.5. For exam- ple, if CApositive-cell=0.9 and CAnegative-cell=O.l, then CAoutput=0.5, which means it is unknown. If ei- ther CApositive,cell or CAnegative-cell is equal to 0.5, then CAoutput will be equal to the others cell activa- tion (indicating that no contradiction is present). Learning and Modifying Informat ion The system can be used (after learning) as an ex- pert system. Alternatively rules can be generated for use in another system, which is discussed in [Romaniuk and Hall 19891. We will next give a formal description of the learning algorithm used in the SC- net network model. This description is then followed by an example. Recruitment of Cells Learning Algorithm: Let Vc be given as a learn vector with the following format: With wk E [l, N] , where N 2 h + 1 is the number of input, intermediate and output nodes. The number VI, represents a component of the learn vector. Each of the 6, are thresholds for the individual components of the learn vector. Here the S,, , L = 1, . . . , h are either facts or intermediate results. The S,, , I = h + 1, . . . , h + i are either intermediate or final results. The ok: and the vl components can both be intermediate results, since one can be an input to the other. For every learn vector V, do (1) Apply learn vector Vc to the current network, by assigning the thresholds of all facts and intermediate 784 MACHINE LEARNING results to the appropriate cells as their new activation. ForallIc=l,...,hdo let CA,, = S,, , that is assign the threshold S,, of every component Q to its corresponding cell CVk as an activation. The above is called the initialization phase. (2) Simulate the network in one pass by starting at level 1 and ending at level n (n is the maximum level of the network). In this simulation phase the new cell activation of every cell is calculated using the ear- lier listed formula for cell activation calculation. The only cells that are excluded from the simulation are input cells, or intermediate cells which correspond to any C,,,k = l,..., h of the learn vector. Their cell activation is provided through the use of the S,, . (3) For all the I = h + 1, . . . , h + i component values of the learn vector V, compare these (expected out- puts S,,) with the actual outputs CA,, . These are given through the cell activation of cell C,,* after the simulation phase. (3.1) Let S,, denote the expected (i.e. desired) out- put of cell Cvr and CA,, the actual (activation) out- put of this cell. Let E be the error threshold (currently c = 0.01). If (CA,, -E) 5 S,, and (CA,, +c) 2 S,, then consider the vector V, learned for the output compo- nent CV,. return to (3) until done with the h+i component. else go to (3.2) (3.2) In the case that there is a contradiction in expected output and calculated activation, it will be noted and the next 1 value processed at step 3. Other- wise, if (lb, - CA,, I > 5 * E) then go to (3.4) if (CA,, > 0.5) then for all cells Cj connected to the positive collector cell of cell C,,, and # C,,* do calculate the new cell bias CB; as follows: (3.2.1) if ICAj - S,, I 5 5 * E then if CAj > S,, CB; = sign(CBj) * ICBjl - I(ICBj I - (!Lt)l a! > else CB; = sign(CBj) * ICBjl + I(lCBj I - 6vt )I cx > end for where o indicates the degree in change of the cell bias based on the old cell bias and the given threshold (cur- rently o is set to 6). The more o is increased the less impact the newly learned information has. return to (3) until done with the h+i component. else go to (3.3) (3.3) If CA,, < 0.5 then for all Cj connected to the negative collector cell of cell CVl and # C&do (3.3.1) if ICAj - S,, I 5 5 * c then if CAj > S,, CB; = sign(CBj) * ICBjl - I(ICBj I - b )I cl > else CB; I(IcBj I - a~, )I a! > end for return to (3) until done with the h+i component. (3.4) Consider the vector I/e as unknown to the cur- rent network. Therefore, recruit a new cell, call it C,, from a conceptual pool of cells. Make appropriate con- nections to C, as follows: For all C,,k in Vc do for k = 1, . . . , h (3.4.1) if the threshold S,, > 0.5 then connect C~k to C, with weight CW,,,, =$. (3.4.2) if the threshold S,, z 0.5 then recruit a nega- tion cell, call it Cn, from the conceptual pool of cells (a negation cell has a bias of zero). Let CB, = 0. Next, connect cell CZlk to cell Cn and assign the weight cwv,,, = 1. Then connect cell Cn to cell C, and as- 1 sign as a weight CWn,, = - . (3.5) If the threshold ii,‘*‘> 0.5 then connect Cm to the positive collector ~21 CZ),pOstl,ye and let Cwm~V1pasilzve = 1. Additionally, let CBm = -S,, . Go to step (3) until the h+i component has been pro- cessed. (3.6) if the threshold 6,, < 0.5 then recruit a new cell C, from the pool of cells. Assign bias of 0 to CBn. Connect Cm to C, and make CWm,, = 1. Let CBm = -(l - Sv,). N ow connect cell C, to the nega- tive collector cellVCvl,,,,fty,. Let CW~,V~~,,,~,,~ = 11 Go to step (3) until the h+i component has been pro- cessed. In step (3), f rom 3.1-3.3, the algorithm is checking an error tolerance. If the example is within the tol- erance, nothing is done. Otherwise, the biases of the appropriate cells connected to an information collector cell are modified to reduce the error, if the concept is close to an old one. The parameter alpha is used for tuning the algorithm. If the value is 1 the just learned vector takes precedence over everything previous. If it was set to infinity, no change would occur as a result of the new learn vector. The steps 3.4, 3.5 and 3.6 of the algorithm are used when a new concept (or version of) is encountered. A dl negative collector totally unfamiliar concept is indicated by an activa- tion value of 0.5. The algorithm essentially creates a new reasoning path to the desired output in a man- - - ner somewhat analogous to an induced decision tree [Michalski, et .al. 19831. We will now exemplify the above listed algorithm on a small example. Assume our initial network contains no information. The only thing we initially know about are its input, intermediate and output cells. Let these be given as follows: input cells s(3); output cells d(1); The above represents a fragment of the SC-net pro- gramming language for setting up the initial network configuration (Note, that the si represent inputs and the di outputs). In our example we will not consider intermediate results. Let us further assume, we want the uncertainty values of the inputs to be defined over the range [O,l]. This means we use a value of 1 to represent complete presence of a fact/conclusion, a value of 0 complete absence, and finally let 0.5 de- note the fact that nothing is known. We also al- low uncertainty in any of the responses. Our initially empty network is given in Figure 2, if you subtract cells Cl, C2 and all connections associated with them. Let us next attempt to learn the following vector: VI = {sl = .8, s2 = .2,s3 = 1,dl = 0.9) Simulation of cell recruitment learning algorithm: Since we have 3 facts and 1 conclusion, h=3 and i=l. Step (1): In the initialization phase we assign the thresholds of every fact to the corresponding input cell as its new activation. This results in the following as- signments: CAsl = .8, CA,;! = .2, CAs3 = 1. HALLANDROMANIUK 785 Step (2): Next, the network is simulated. Since it is initially empty the resulting cell activation of dl will be 0.5. Step (3): Here 1 runs from 4 to 4. In the chosen ex- ample, there is only one conclusion (dl). Therefore, C&l = 0.5 and &Jl = 0.9. Step (3.1): Th e condition is false. We can conclude that VI is an unknown concept to the network. Step (3.2): Since &I = 0.9 and CAdI = 0.5 the condi- tion is also false. Step (3.4): Having reached this point in the algorithm, we can conclude, that the concept represented by VI has no representation within the network. This leads to recruiting a new cell Ci from the conceptual pool. We then connect the cells of all facts to the newly re- cruited cell Cr. k=l. Step (3.4.1): S ince S, 1 = 0.8 we connect cell Csi to cell Cl and assign it a weight of &s = 1.25. k=2. Step (3.4.2): b92 = 0.2, therefore a new cell Cz is recruited. CBS = 0. Connect Cs2 to cell C2 and assign a weight of 1. Connect C2 to Cl and let the weight be 1 p&g=-* k=3. Step’G.4.1): S’ mce Sss = 1, it is connected to Cl and the connection assigned a weight of 1. Step (3.5): Since we connect to the positive collector cell for dl, a weight of 1 is assigned. Finally CB1 is set to -0.9. Fig. 2 shows the network after learning the first learn vector. Let V2 = {sl = 0.9,s2 = 0.1, s3 = l,dl = 0.85) be a second learn vector. Then step 3.2.1 of the algorithm will cause the bias for cell Cl to change. The bias will become -0.8916 after learning -- v2. In the case of contradictory information (over time or whatever) we will actually let the network learn the complement of what we want to forget. Therefore, if any fact fires in the network, so will its complement and the anding of the two will result in an unknown conclusion. It may surprise the reader that we are not deleting information from the network by changing the appropriate weights, which seems to have the same ef- fect. This is done because some rules may be given to (encoded in) the system a priori. When the net- work is constructed solely through learning, changing connection weights serves the same purpose. Implementation of variables Overview Variables are of great value in implementing power- ful constructs in conventional symbolic expert systems. MYCIN [Waterman 19861 is a good example of such an expert system. It uses <Object, Attribute, Value> triplets for the implementation of variables. Connec- tionist type expert systems hardly make use of vari- ables at all, since it seems that their implementation is far from being simple, if even possible to realize. As Samad [Samad 19881 pointed out, variable bind- ings can be handled more elegantly using microfea- tures, which will be associated with every cell (slots in the cell could be used to hold certain information, like variable values, binding information, separation of attributes and values etc.), or one could think of every cell representing a microfeature by itself. It is obvious that one can associate microfeatures with every cell in a neural network. The amount of microfeatures have to be fixed in the design phase and once they have been chosen they cannot be changed. In another implementation one can think of every cell having just one or two microfeatures (actually in- dexes into some memory module) which point to some memory area, containing all the information for the im- plementation of variables and their values. Since one of the main purposes for using connectionist networks is speed (parallel processing), making use of the informa- tion in some central storage place seems to contradict the notion of parallel processing. Variables in SC-net The approach here differs from the above in an attempt to avoid the problems discussed. The SC-net system distinguishes between two different types of variables. The first category consists of fuzzy variables. They allow the user to divide a numerical range of a vari- able into its fuzzy equivalent. Consider for example the age of a person. Let us refer to the variable as age. Age can now take on values in the closed inter- val [O..lOO] (th is is accomplished by defining age as a variable in the declaration part of a SC-net program). Let us further assume that the following attributes are associated with this variable: child : 0..12 teenager : 13..19(5,25) If age is assigned the value 15 then we might like the associated attribute teenager to be completely true and the attribute child somewhat true, too. The rea- son for this is that the age of 15 is still reasonably close to the child interval, causing it to be activated with some belief. The numbers in parentheses after the main range for the teenager declaration indicate how far on either side of the range some belief (less than total and going to 0 at the age of 5 and 25) will persist. The representation is accomplished by the use of a group of cells to represent the variable and at- tribute. This is true of both the fuzzy variables dis- cussed above and the scalar variables, such as color [Romaniuk and Hall 19891. Due to space considera- tions, only an example of age[teenager] is shown be- low. The age for our example has been compressed into [0, 11, such that an age of 17 would map to 0.17. In general we will have the following format (pi- shaped function definition): attribute-value : lower-bound..upper-bound (lower-plateau, upper-pdateau). 786 MACHINE LEARNING age[te*enagerI e) 1 1.87 167 Figure 3: age[teenager] network In case of the value teenager, we guarantee that a value < 5 and > 25 is certainly no longer a teenager (membership value equal 0)) and a value of >= -13 and <= 19 returns a membership value of 1. Figure 3 shows the resulting network. The weights have been calculated as follows: a) weight: 1 upper-plateau = 0.25 1 = 4. b) weight: 1. pp plateau ‘) weight’ (upper-~at~~~-upper-*ound) = (0.2ifZ.19) = 4.167 d, weight’ (I-lowertplateau) =7i=h= 1.053. e) weight: (1-her-pliteauj ' (l-0.05) 11.875. ( lower-bound-lower-plateauj = (0.13-0.05) = Current results Our current research has been dealing with medium sized data sets. The results Obtained have been quite promising. After allowing the sys- tem to learn the knowledge bases of GEMS and FEVERS, comparisons where made with an EMYCIN [Van Melle, et. al. 19841 version of these two knowl- edge bases running under MultiLisp [Halstead 19851. All our tests were conducted by randomly sampling the rule bases, and determining possible assignments to the inputs (facts), that would fire the premise of some rule. In all cases the results where almost identi- cal and only differed by a few percent in the certainty factor of the final conclusion. In the following, a couple of examples are given. Fig. 4 gives a set of selected rules which were taken from the FEVERS knowledge base for the purpose of (putprops rule032 subject patientrules action (conclude patient comb-ab abdom-pain tally 1000) premise ($and (same patient sympl abdom-symp) ($01 (same patient abdominal rt-upper-pain) (same patient abdominal lft-upper-pain) (same patient abdominal lower-pain)))) (putprops rule033 subject patientrules action (conclude patient disease fabry’s tally 750) premise @and (same patient sex male)(same patient comb-ab abdom-pain) ($01 ($and (same patient comp- host dis) (same patient dis-histl stroke)) ($and (same patient sympl skin-symp) (same patient skin punctate- lesions)) (same patient symp4 edema)))) (putprops rule 054 subject patientrules action (conclude patient disease rheumatic-fever tally 800) premise ($and (between* (vall patient age) 4 16) ($01 ($and (same patient camp-host dis) ($or (same patient dis-hist3 strep-hist) (same patient dis-hist3 rheumatic-fever-hist))) ( same patient sympl cardiac- symp)(same patient symp5 chorea) ($and (same pa- tient sympl skin-symp) ( same patient skin erythema- marginatum))))) Figure 4: Sample of randomly selected rules of the FEVERS knowledge base this simulation. An approximate translation of rule 032 is the following. rule032: if the patient has abdominal symptoms and the patient has right upper abdominal pain or left up- per abdominal pain or lower abdominal pain then there is conclusive evidence (1000) that the pa- tient’s abdominal symptom is abdominal pain. Tables 1 and 2 demonstrate two examples of actual simulations after learning. Each table indicates what rule(s) were fired in the EMYCIN version, lists the facts that were supplied and their certainty values. The system provided certainties are given under the goals derived with the EMYCIN certainty given first and our systems’ second. The accuracy of the certainty values of the results are in all cases, within several percent, almost identical. The range of certainty is given as [-1000,+1000]. A straightforward mapping was done. In comparison with the Iris data of 150 examples, we followed the example of Weiss [Weiss, et. al 19891. After learning all cases, there was no apparent error. In our system this means that the solution presented with the most certainty was correct. It was occasion- ally the case that one or more other conclusions would have some certainty. In some cases the certainties were HALLANDROMANIUK 787 goals rheumatic-fever 7991799 1 Table 1: Example of crisp and uncertain input rule I facts I goals I 032 033 ~ abdom-symp (700) rt-upper-pain (750) male (800) edema (750) abdom-pain 700/700 cholecystitis 560/530 fabry ‘s 525/488 Table 2: Example with uncertainty and chaining close to the chosen value. When the system was tested by learning all the cases except one and then being pre- sented the left out case, the error rate was 0.04. These results compare favorably with the results shown by Weiss. Summary In this paper we have presented a hybrid connection- ist, symbolic learning system. This algorithm is based mainly on changing the network topology, then chang- ing weights, as can be found in most conventional con- nectionist learning paradigms. An interesting fact one may have noticed about the simulation phase for learn- ing is that it will not make a guess on an unseen ex- ample, if all the data is crisp and there are discrete ranges for all variables. The non-learning simulation is slightly modified to allow for partial pattern matches. This system has some important expert systems fea- tures, which normally have been neglected in other ap- proaches to constructing connectionist expert systems. These include the representation of variables, variable binding, and relational and fuzzy comparators. Other features such as consultation and explanation facili- ties have been added and tested favorably in several different applications. Finally, tests with several do- mains show good performance. On the one widely tested data set used, the system compares favorably with other methods. Acknowledgements This research partially supported by a grant from the Florida High Technology and Industry Council, Com- puter Integrated Engineering and Manufacturing Divi- sion. References [Halstead 19851 Halstead, R. H. 1985. Multilisp: A Language for Concurrent Symbolic Computa- tion. ACM Transactions on Programming Lan- guages and Systems, Vol. 7, No. 4, October. [Kandel 19861 Kandel, A. (1986), Fuzzy Mathemati- cal Techniques with Applications, Reading Ma., Addison- Wesley. [Keller, et. al. 19901 Keller, J. M., and Tahani, H. 1989. Backpropagation Neural Networks for Fuzzy Logic. To appear Information Sciences. [Van Melle, et. al. 19841 van Melle, W. , Shortlifie, E. H., and Buchanan, B. G. 1984. EMYCIN: A Knowledge Engineer’s tool for constructing rule- based expert systems. In Rule-based Expert Sys- tems, B. Buchanan and E. Shortliffe (eds)., Read- ing Ma. Addison-Wesley, 302-328. [Michalski, et.al. 19831 Michalski, R. S., Carbonell, J. G., Mitchell, T. M. 1983. Machine Learning: An Artificial Intelligence Approach. Palo Alto, Ca., Tioga Publishing. [Minsky and Papert 19881 Minsky, Marvin L., Papert, Seymour A. (1988). P erceptrons. Second Edition. Cambridge, Ma. The MIT Press. [Rummelhart, et. al. 19861 Rummelhart, D. E. , Mc- Clelland, J. L., (Eds.) 1986. Parallel Distributed Processing: Exploration in the Microstructure of Cognition, Vol I, Cambridge, Ma. MIT Press. [Waterman 19861 Waterman, Donald A. 1986, A Guide to Expert Systems. Reading, Mass:Addison-Wesley. [Weiss, et. al 19891 Weiss, S.M. and Kapouleas, I. 1989, An Empirical Comparison of Pattern Recognition, Neural Nets, and Machine Learn- ing Classification Methods, Proceedings of IJCAI ‘89, Detroit, Mi. [Romaniuk and Hall 19891 Romaniuk, S. and Hall, L.O. 1989, FUZZNET, A Fuzzy Connection- ist Expert System, Technical Report CSE-89- 07, Dept. of Computer Science and Engineering, Univ. of South Florida, Tampa, Fl. [Romaniuk and Hall 19901 Romaniuk, S. G., Hall, L. 0. 1990, FUZZNET: Towards a Fuzzy Connec- tionist Expert System Development Tool, In Pro- ceedings of IJCNN, Washington D.C., January, [Samad 19881 Samad, T. 1988, Towards Connection- ist Rule-Based Systems, In. Vol. II, Proceedings of the International Conference on Neural Net- works. 788 MACHINE LEARNING
|
1990
|
157
|
912
|
Automated iscovery in a Che aboratory* Jan M. kytkovvt Jieming Zhu Abul Hussam Department of Computer Science Department of Chemistry zytkow@gmuvax.gmu.edu jzhu@gmuvax.gmu.edu George Mason University, Fairfax, VA 22030 U.S.A. Abstract We describe an application of the discovery system FAHRENHEIT in a chemistry laboratory. Our em- phasis is on automation of the discovery process as oposed to human intervention and on computer con- trol over real experiments and data collection as op- posed to the use of simulation. FAHRENHEIT per- forms automatically many cycles of experimentation, data collection and theory formation. We report on electrochemistry experiments of several hour duration, in which FAHRENHEIT has developed empirical equa- tions (quantitative regularities) equivalent to those de- veloped by an analytical chemist working on the same problem. The theoretical capabilities of FAHREN- HEIT have been expanded, allowing the system to find maxima in a dataset, evaluate error for all con- cepts, and determine reproducibility of results. After minor adjustments FAHRENHEIT has been able to discover regularities in maxima locations and heights, and to analyse repeatability of measurements by the same mechanism, adapted from BACON, by which all numerical regularities are detected. 1. Introduction and motivation Our current research on computer discovery systems has been guided by three long term goals. First, we are pursuing real, not simulated applications in a sci- ence laboratory. Second, we want to minimize human intervention in the working of our system, eventually aiming at a fully automated discovery. The third goal is generality of the discovery mechanism. We want to make our system useful to any experimental scien- tist dealing with acquisition and analysis of numerical data. Although much remains to be done, our discov- ery system FAHRENHEIT has made progress on all of these goals. Discovery systems: a brief summary In the last dozen of years many computer programs have been ‘The work described in this paper was supported by Office of Naval Research under grant No. N00014-88-K- 0226 +On leave from Wichita State University. constructed that simulate various aspects of scientific discovery. The earlier systems concentrated on qualita- tive and quantitative regularities, discovery of intrinsic concepts, the scope of the laws, and explanation of the hidden structure (Buchanan and Mitchell, 1978; Lang- ley, 1978, 1981; Bradshaw, Langley, and Simon, 1980; Langley et al. 1983, 1987; Zytkow and Simon, 1986; Zytkow and Koehn, 1986; Falkenhainer and Michalski, 1986). The growth of discovery systems has accelerated in the last three years. Several abilities lacking in ear- lier discovery systems have been introduced, primarily the ability to consider empirical context of a law (IDS: Langley and Nordhausen, 1990; GALILEO: Zytkow 1990; Sleeman, Stacey, Edwards, and Gray, 1989), the ability to design experiments (KEKADA: Kulka- rni and Simon, 1987; FAHRENHEIT: Zytkow, 1987; Langley and Zytkow 1989), the ability to represent ob- jects, states and processes (Langley and Nordhausen, 1990; iytkow 1990) and the ability to reason by anal- ogy (Falkenhainer, 1987; Falkenhainer and Rajamoney, 1988). Sleeman et al. (1989) suggested an interesting search in the space of qualitative models of a chemi- cal system. All these new abilities have deepened our understanding of selected aspects of discovery, but sig- nificant progress has been made also on the impor- tant issue of integration. Two systems, both descen- dents of BACON, reached a considerable integration: IDS and FAHRENHEIT, the latter augmented by the GALILEO system that generalizes laws by decompos- ing them into simpler expressions. Data acquisition problems. Virtually all discovery systems are simplistic in handling data acquisition and experimental error. Error handling. Discovery systems were typically limited to ‘clean’ input data. Although many systems include some error-related parameters, they disregard the breadth and notoriety of real scientist’s problems with raw data. For instance, a single error param- eter for the whole system in BACON and ABACUS produces a funny result when a system cannot find a regularity for a variable V, but then it finds that V4 is constant. This may happen when the values of V are ZYTKOW ET AL. 889 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. c between 1 and 0 because for each power of V they dif- fer less and less with respect to the unchanging value of error. Experimental science not only requires that the empirical error is determined, but also that it is reduced as much as possible. This involves analysis of repeatability and detection of abnormal experimen- tal conditions that invalidate a particular collection of data, such as a contaminated electrode. Data acquisition bottleneck. As the discovery sys- tem&ey require more input data. A computer system can be provided with data in several ways. In the simplest variant, a human oper- ator responds to the system’s request for data by cal- culating and typing in the appropriate values. Some of BACON’s original experiments were conducted in this way. When the number of requested experiments becomes large, it is preferred to use a simulation. Sim- ulation is easy for toy problems, but it is difficult to build a simulator that would model a situation typical in a science laboratory where a variety of unexpected and unwanted phenomena influence the experiments, causing error of measurement and inducing sophisti- cated measurement procedures. If we want our discov- ery systems to deal with these effects, it is easier to study them in interaction with the real world. Empirical semantics. The role of operational seman- tics, which 1’ * & inks terms in scientific theories with direct observations and manipulations (Bridgman, 1927; Car- nap, 1936; iytkow, 1982) is negligible in the existing discovery systems, while it is very important in real science. Especially the use of instruments has been disregarded by research on machine discovery. While the simplistic approach to experimentation was useful at the early stage of research on discovery systems, at the present time we may directly confront the main goal of science, which is developing theories of the real world in an interaction with the world. If discovery systems are going to satisfy the needs of the experimental scientist, we must spend more time work- ing on real experiments and on processing real data. Because even a simple discovery in modern science is based on the analysis of many thousand datapoints, discovery systems should be ready to handle massive data rather than few datapoints on which we tested our early systems. Automation in chemistry. Automation of the thinking processes which we are building into discov- ery systems must be matched by automation of the actual experimentation and data collection in the sci- ence lab. Are scientists getting ready for that? Actu- ally, the automation and computer support in a science lab has already reached a massive scale, including data acquisition and data analysis. Recently the robot tech- nology has been tested in the chemistry laboratory on the tasks of sample preparation, and in a relatively short time a number of complex lab operations can be automated by combination of simple steps (Sharp, Whitfield, and Fox, 1988). To all for whom automation of discovery looks like a science fiction, we would like to deliver a practical proof that it is already possible on a limited scale. This paper reports our first results. But if it is possible to use a discovery system as a scientist’s associate, does it pay to do so ? It depends on the generality of the sys- tem. The BACON family of discovery systems, includ- ing BACON, IDS, and FAHRENHEIT, comes off very favorably on this account. Not only does each experi- mental scientist speak in terms of independent and de- pendent variables, empirical equations, their stepwise generalization, and their range of application, measure- ment error, relevant and irrelevant variables, but these terms refer to a larger part of their laboratory work. A reliable discovery system can become a workhorse that carries out a considerable amount of work in any science lab. 2. Chemistry experiments We selected electrochemistry as the application area for a number of reasons. First, the computer operated sensors and actuators are readily available in a typical chemistry lab. Second, it is relatively easy to auto- mate various electrochemical operations on chemical samples. Third, chemists often work with relatively simple equations, which do not exceed the theorizing capabilities of the systems in the BACON family. We report on an automated experiment in differen- tial pulse voltammetry. Our experiments parallel an ongoing research conducted by a chemist working on construction of new instrumentation. This gives us an opportunity to compare and verify our results. Problem 1: Detection of low concentration ions. Differential pulse voltametry (DPV) can be used to measure concentration of ions such as Cu2+, Pb2+, and Cd2+, simultaneously and at a very low concen- trations of few particles per million (ppm) and lower (Bard and Faulkner, 1974). The problem is important since those ions are toxic at ppm and sub-ppm levels. DPV uses excitation of a sample by potential pulses characterized by the pulse height, width, and the delay between pulses (Figure la), and measures the response as a function of current in potential (Figure lb). Figure 3 shows a typical result of a single series of experiments in which a particular pulse height, width, and delay between pulses have been used and three types of ions have been detected: cadmium, lead and copper. The type of an ion is determined by peak’s location whereas concentration is proportional to peak’s height. The lo- cation and height of each peak as well as the errors with which they are determined vary with the pulse parameters. Typically the resolution (discrimination between types of ions) is better at low values of pulse height, while the sensitivity is higher at larger values, that is, the concentration is measured with smaller er- ror. When the values of pulse height become too high, 890 MACHINE LEARNING GO EXCITATION easured before the pe-ak Ai t 09 Ai=iz -il RESPONSE + ++ + + + + Fig. 1 Differential pulse voltammetry (a) control signal -- voltage E as a function of time (b) response -- difference in current Ai as a function of voltage E however, the error in determining peak paramaters in- creases dramatically. To obtain the best resolution and sensitivity, not only the pulse height, but also the width, and the delay between pulses should be opti- mized. Instrumental to the optimization that would be efficient under different circumstances is a theory that describes how the peak parameters and their er- ror depend on the pulse parameters. The final objective for our FAHRENHEIT system on Problem 1 is to find such a theory in a fully automated way. In this paper we report on our initial results. Problem 2: Peak repeatability. The initial phase of any scientific experiment is focused on experimen- tal error and repeatability of results. The working electrode (Figure 2) poses repeatability problems be- cause the measurements may deteriorate due to chemi- cal changes at the electrode. To make the replacement of an electrode easy, chemists use mercury electrodes in which a hanging drop of mercury forms a working surface. When the performance of the electrode de- teriorates, a drop of mercury can be forced out of the working electrode and replaced by a fresh, not contam- inated drop. How many measurements can we perform with the use of the same drop? This is a typical re- peatability problem, common for every sensor, and the procedure is also typical: perform a sequence of exper- iments trying to keep constant the values of all con- trollable parameters, and find the border between the area of repeatability, in which the results are constant Fig. 2 Hardware and software configuration within small error, and the area in which the results change or the error increases. By the analysis of the same sequence of experiments we must determine both the range of repeatability and the measurement error. Another source of error is the varying size of the drop. The amount of the current Ai is proportional to the surface of the drop. To determine the error we must experimentaly answer the question: “How accurately can we reproduce the drop size?” Hardware and Software configuration Figure 2 illustrates hardware and software components and con- nections in our automated system, including the chem- istry equipment. Our system runs a complete loop in which experiments are designed by FAHRENHEIT, performed under the control of PC in the electrochem- ical cell, the experimental results are sent to the Sun where FAHRENHEIT uses them to build a theory. Hu- man interference is reduced to sample preparation and occasional assistance. 3. FAHRENHEIT’s new features FAHRENHEIT has b een described by Koehn and Zytkow (1986), Zytkow (1987), and by Langley and Zytkow (1989). It uses BACON’s mechanism for mul- tidimensional control of experiments and for detection of multidimensional regularities, but it extends BA- CON in several directions. FAHRENHEIT searches for the scope of the laws it has discovered, it can find several regularities in data, change the order in which ZYTKOW ET AL. 891 it varies independent variables, and detect irrelevant variables. Placing FAHRENHEIT ‘(in charge” of laboratory ex- periments challenged us with new tasks. To be suc- cessful in the chemistry experiments, FAHRENHEIT must be able to (1) find “points of special interest”, such as maxima, and incorporate them into a recur- sive mechanism for detection of multidimensional reg- ularities, (2) determine reproducibility of results, (3) determine the error for each new concept, (4) establish empirical semantics, and (5) establish the communica- tion between the brain (FAHRENHEIT) and the hands and eyes (PC), including a command language used by FAHRENHEIT. We will briefly describe the first four. Handling ‘especial points”. Quantitative discovery systems were traditionally preoccupied with numerical regularities, whereas scientists are also interested in other aspects of numerical data, especially in “special points” such as maxima, minima, discontinuities, ze- ros, and so forth. Sometimes finding a special point is more important than detecting a regularity. FAHREN- HEIT has been able to find many special points but it has used them for another purpose. FAHRENHEIT has been able to find boundaries of regularities, reg- ularities on boundaries and boundaries of boundaries. It turned out that the same recursive mechanism for generalization to new variables applies to all types of special points. The system needed only a small change in code, after which it can mix and match various tasks of function analysis for different independent variables. For instance, FAHRENHEIT can now search for the maxima of regularities, for regularities on maxima, or for maxima of a regularity on minima. Problem 1 in section 2 requires detection of the location and height of each peak in a sequence of data for each pulse height, such as shown in Figure 3. Then, FAHRENHEIT is supposed to find separate regularities for the locations and heights of maxima for different ions. The electrode potential is .the independent variable for the former, while pulse height is the independent variable for the latter. Determining the reproducibility of results. In the repeatability study FAHRENHEIT performs a number of experiments without changing any values of controlled variables. Then it analyses the data, trying to separate an area of constancy from the remaining data in which there is either another regularity or no regularity can be found. FAHRENHEIT’s capability for finding multiple regularities and their boundaries is essential on this task. Handling experimental error. For each new vari- able generated by FAHRENHEIT, such as the maxi- mum location or the slope of a linear regularity, the system finds the error. Each error is computed from appropriate data. For instance, the error of maxima lo- cation and height can be inferred from the repeatability study. The error is necessary for the generalization of results to new dimensions. It also allows to determine the quality of final results. 892 MACHINE LEARNING Fig. 3 DPV of metal ions (20ppm CL?, Pb2’,nd C%‘) Ai Regularities for height .- Regularities for location: _I Fig. 4 Regularities for the maximum 4. Results of experiments We started with the repeatability study, that is with problem 2 in section 2, using the pulse height of 15 mV. We repeated the experiment 20 times. Each time our system collected 360 datapoints, measuring the current as a function of potential of the working electrode. For a single pulse the results are plotted in Figure 3. In 120 minutes 7200 datapoints were collected and analysed, 60 maxima have been located and nine regularities, in- cluding six constancies, have been found. By analysing the ranges of constancy FAHRENHEIT detected that repeatability of maxima heights are different for differ- ent ions, and that each maximum is measured with a specific error as described in the “rows” errors and “re- peatability” in Table 1. As a result, we use the number of 7 repetitions before we change the drop of mercury. In the next experiment, reported in Figure 4 and in Table 1, we aimed at the detection of regularities that’ describe changes of the peaks as a function of the pulse .$ CONST “1 !Y -553.87 LIN LIN 0.01 0.36 0.4406 -168 -45 QUAD -0.001 0.17 OAfI Table 1. Summary of DPV experiments. The upper part shows the parameters of the maxima. The first number in the row “error/repeatability” indicates the error, either absolute or relative(%), the second number indicates the range of repeatability. The lower part gives the type of the regularity and the numerical values of coefficients. height. Figure 4 illustrates a sequence of experiments with a varying pulse height. FAHRENHEIT found the locations and heights of the maxima, reported in the upper portion of Table 1, then it found regularities both for peak locations and heights, depicted in Figure 4 and described in the lower portion of Table 1, where the type of regularity is given and the numerical values of the coefficients for each regularity. The experiment lasted 50 minutes, during which for seven pulse heights the total of 2320 datapoints were collected and anal- ysed, 21 maxima have been located and six regularities have been found. 5. Evaluation System’s performance can be evaluated according to accuracy, range of application, and usefulness. The accuracy of our results is compatible with the accuracy achieved by human researchers. When we were able to compare the results, our system finds both the maxima and regularities which are equivalent within empirical error. The range of applications of FAHRENHEIT goes far beyond electrochemistry, because FAHRENHEIT can deal with numerical data regardless of the application domain, provided that the laboratory hardware is re- arranged and the appropriate operational procedures are defined. Is our system useful? How fast it performs? The performance is still subject to many improvements, but the first results are encouraging. When we compare the theoretical work on the data made by FAHRENHEIT with an off-line analysis by the chemists, the results are very favorable. More than one day of work on data by a research assistant corresponds to 1 minute of data analysis by FAHRENHEIT. Altogether, several days work of research assistants corresponds to 50 minutes work of our system. The cost of the system installation is still enormous, measured in man-months of work, and it will take some time before we reach satisfactory portability. 6. Limitations and Future Directions Limit ations. Although FAHRENHEIT can auto- matically determine the repeatability conditions and it can find regularities for the peaks, the transition from the first to the second requires our intervention. We would like our system to understand the notion of repeatability, so it would investigate repeatability automatically whenever necessary, and it would be able to automatically use the results. The results of repeatability study influence the experimentation be- cause they impose a limit after which the experiments can continue only after the electrode has been changed. The corresponding change in operational procedure, however, has not been automated and must be done manually. Immediate future steps. We are planning to work on these limitations, and then to expand the theory of DPV measurements to additional independent vari- ables, including pulse width, delay between pulses, and concentration of ions in the sample. 7. Conclusions Our preliminary results demonstrate how a quantita- tive discovery system can be used in a chemistry lab- oratory on the experimental problems of interest to a contemporary chemist. Both an experimental scientist and a machine learning researcher can benefit from the application of a discovery system in a science labora- tory. The scientist may save enormously on time and effort spent on data analysis, while the ML researcher may gain a valuable exposure to problems of real world experimentation and real data analysis. FAHRENHEIT is superior over the existing statis- tical packages from the perspective of theory genera- tion in that it can infer multidimensional regularities and it integrates many discovery steps. Various soft- ware packages are available that can help scientists in data processing, but they only automate single small steps, like smoothing and regression. The result of ZYTKOW ET AL. 893 each step must be inspected by a scientist before he decides about the next step and prepares the input for that step. In contrast, FAHRENHEIT automates large portions of the inference process. Another advantage is a flexible data collection. Many chemistry labs use automated procedures for data collection which vary the independent variables in a predetermined pattern. These procedures do not provide automated feedback from the theoretical re- sults, because theoretical analysis is done after empir- ical data have been collected. In contrast, FAHREN- HEIT builds the theories on-Zinc and it changes the ex- perimentation pattern to concentrate new experiments on a particular area that best contribute to the growth of the emerging theory. Researchers on discovery can also benefit because a real lab interface allows to overcome the bottleneck of data generation, provides realistic raw data, and yields new research problems such as on-line refinement of experimental procedures. References Bard, A.J., and Faulkner, L.R. 1974 EZectrochemicaZ Methods: Fundamentals and Applications, Wiley: New York. Bradshaw, G., Langley, P., and Simon H.A. 1980. BA- CON 4: The Discovery of Intrinsic Properties. Pro- ceedings of the Third National Conference of the Cana- dian Society for Computational Studies of Intelligence, 19-25. Bridgman, P.W. 1927. The Logic of Modern Physics. Macmillan, New York. Buchanan, B.G., and Mitchell, T.M. 1978. Model- directed learning of production rules, in: Waterman A., Hayes-Roth F. eds., Pattern-Directed Inference Systems, Academic Press, New York. Carnap, R. 1936. Testability and Meaning, Philosophy of Science, 3. Falkenhainer, B.C. 1987. Scientific Theory Formation Through Analogical Inference, Proceedings of Fourth International Workshop on Machine Learning, Los Al- tos, California: Morgan Kaufmann Publ., 218-229. Falkenhainer, B.C., and Michalski, R.S. 1986. Inte- grating Quantitative and Qualitative Discovery: The ABACUS System, Machine Learning, I, 367-401. Falkenhainer, B.C., and Rajamoney, S. 1987. The In- terdependencies of Theory Formation, Revision, and Experimentation, Proceedings of the Fifth Interna- tional Conference on Machine Learning. Morgan Kaufmann Publ.: Los Altos, California, 353-366. Koehn, B., and Zytkow, J.M. 1986. Experiment- ing and Theorizing in Theory Formation. In Ras Z. ed., Proceedings of the International Symposium on Methodologies for Intelligent Systems 296-307. ACM SIGART Press. Kulkarni, D., and Simon, H.A. 1987. The Processes of Scientific Discovery: The Strategy of Experimentation, Cognitive Science, 12: 139-175. Langley P.W. 1978. BACON 1: A General Discovery System, Proceedings of the Second National Confer- ence of the Canadian Society for Computational Stud- ies, 173-180. Langley, P.W. 1981. Data-driven Discovery of Physical Laws. Cognitive Science, 5: 31-54. Langley, P., Zytkow, J.M., Bradshaw, G., and Simon, H.A. 1983. Three facets of scientific discovery, Pro- ceedings of the Eighth International Joint Conference on Artificial Intelligence. Langley, P., and Nordhausen, B. 1986. A framework for empirical discovery. Proceedings of the Interna- tional Meeting on Advances in Learning. Les Arc, France. Langley, P.W., Simon, H.A., Bradshaw, G., and Zytkow J.M. 1987. Scientific Discovery; An Account of the Creative Processes. Boston, MA: MIT Press. Langley, P.W., and iytkow, J.M. 1989. Data-Driven Approaches to Empirical Discovery. Artificial Intel&- gence, 40: 283-312. Nordhausen, B., and Langley, P. 1990. An Integrated Approach to Empirical Discovery. in: J.Shrager and P. Langley eds. Computational Models of Discovery and Theory Formation, Morgan Kaufmann Publishers, San ” Mateo, CA. in press. Sharp, R.L., Whitfield, R.G., and Fox, L.E. 1988 Robotics in the Laboratory: a Generic Approach, An- alytical Chemistry, 60: 1056-1062. Sleeman, D.H., Stacey, M.K., Edwards, P., and Gray, N.A.B. 1989. An Architecture for Theory-Driven Sci- entific Discovery, Proceedings of E WSL- 89. Zytkow, J.M., and Simon, H.A. 1986, A Theory of His- torical Discovery: The Construction of Componential Models, Machine Learning, 1: 107-36. iytkow, J.M. 1982. An interpretation of a concept in science by a set of operational procedures. Polish Essays in the Philosophy of the Natural Sciences 169- 185. Dordrecht: Reidel. Zytkow, J.M. 1987. Combining many searches in the FAHRENHEIT discovery system. Proceedings of Fourth International Workshop on Machine Learning 281-287. Los Altos, CA: Morgan Kaufinann. Zytkow, J.M. 1990. ‘Deriving basic laws by analysis of processes and equations’, in: J.Shrager and P. Langley eds. Computational Models of Discovery and Theory Formation, Morgan Kaufmann Publishers, San Mateo, CA. in press, 1990. 894 MACHINE LEARNING
|
1990
|
158
|
913
|
tive Search lanat ion- ased Learning of ic Censors Neeraj Bhatnagar Learning and Knowledge Acquisition Group Siemens Corporate Research, Inc. 755 College Road (E), Princeton, NJ 08540. neeraj@learning.siemens.com Abstract We introduce an adaptive search technique that speeds up state space search by learning heuris- tic censors while searching. The censors speed up search by pruning away moTe and more of the space until a solution is found in the pruned space. Censors are learned by explaining dead ends and other search failures. To learn quickly, the technique over-generalizes by assuming that cer- tain constraints aTe preservable, i.e., remain true on at least one solution path. A recovery mecha- nism detects violations of this assumption and se- lectively relaxes learned censors. The technique, implemented in an adaptive problem solver named FAILSAFE-g, learns useful heuristics that cannot be learned by other reported methods. Its effective- ness is indicated by a preliminary complexity anal- ysis and by experimental results in three domains, including one in which PRODIGY failed to learn eflective search control rules. 1 Introduction This paper introduces a machine learning technique for improving the efficiency of state space search, and an adaptive planner, FAILSAFE-2 (abbreviated FS2), that uses this technique. FS2 learns adaptively from its ex- ecution time failures. In complex domains it is not suf- *The second author is supported in part by the De- fense Advanced Research Projects Agency (DARPA) un- der Contract number N00014-85-K-0116, in part by the National Science Foundation (NSF) under Grant Number DMC-861050’7, and in part by the Center for Computer Aids to Industrial Productivity (CAIP), an Advanced Technol- ogy Center of the New Jersey Commission on Science and Technology, at Rutgers University, Piscataway, New Jersey. The opinions expressed in this report are those of the au- thors and do not reflect any policies, either expressed or im- plied, of any granting agency. We thank Andrea Danyluk, Oren Etzioni, Steven Minton, Stellan Ohlsson, and Prasad Tadepalli for commenting on the earlier drafts of this paper. Thanks are also due to Alex Borgida, Steve Hanson, Joan Lucas, Lou Steinberg, and many others for their assistance. Jack Mostow Department of Computer Science Rutgers University New Brunswick, NJ 08903.* mostow@cs.rutgers.edu ficient to learn only from success because the problem solver may exhaust its resources even before it, reaches its first partial success. We hypothesize that search in- efficiency is mainly due to actions that lead to obvious failures. Thus, search can be made more efficient by learning negative heuristics at execution time from fail- ures to avoid such actions. FS2 learns such heuristics by explaining its failures. PRODIGY (Minton, 1988a, Minton, 198823) and STATIC (Etzioni, 1990) also employ explanation-based learning from failure. However, they suffer from three basic problems. First,, they wait to learn from failures until a dead end is reached during problem solving. In complex problems, even a dead end may occur too late. Second, they explain failures by exhaustively examining the alternatives. Such conservative learning can be too expensive to do while problem solving. Third, if the ex- planation involves recursion, they either learn too many rules of relatively low utility (Minton, 1988b), or simply refrain from trying to learn (Etzioni, 1990). The FS2 system reported in this paper attempts to alleviate these problems. While solving complex prob- lems, FS2 declares failure early to avoid exhaustive searches. It builds incomplete over-general explanations of failures to avoid many exhaustive or recursive proofs. Over-generalization of failures in FS2 sometimes causes it to exclude all solutions of the problem. When this case occurs, FS2’s problem solver overrules the recom- mendations of its learner. FS2 searches alternately at two different levels. At the base level, the problem solver performs forward- chaining search in a problem space defined by an initial state, a goal, a set of operators, and a knowledge base of search control rules. The object of this search is to find a path from the initial state to a goal state. At the meta-level, the learner tunes the search control knowledge by adding, relaxing, and modifying search control rules. The object of this tuning is to speed up the base-level search by converging on search control knowledge which defines a base-level space that is small enough to search quickly yet large enough to contain a solution path. The idea is to prune away more and BHATNAGARANDMOSTOW 895 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. more of the space until a solution is found. FS2 views state space search as an enumeration of allowed paths until a solution path is found (Mostow, 1983). FS2 addresses the case where the pur- pose of search is to find a legal but not necessarily op- timal solution path quickly. Learning speeds up the search by constraining the generation of paths so that paths that are likely to fail are not generated. z Types of constraints on paths Consider a constraint on the states occurring on a path. We shall say that such a constraint holds for a path if it holds for every state in that path. We classify such constraints into three types. A nec- essary constraint holds for all solution paths and, there- fore, must be preserved on the generated paths. If a nec- essary constraint is violated, the problem solver must backtrack. A preservable constraint holds for some, but not necessarily all solution paths. If a preservable con- straint is violated, the problem solver may backtrack, since other paths on which it is not violated also lead to solutions. An unpreservable constraint does not hold for any solution path, and must temporarily be vio- lated in order to reach the goal. If the problem solver backtracks every time an unpreservable constraint is violated, it will cut off all solution paths. The type of a constraint depends on the operators available to the problem solver, and on the other constraints that the problem solver is currently imposing. FS2 extends previous work on FOO (Mostow, 1983) and FAILSAFE (Mostow and Bhatnagar, 1987). FOO used the idea of necessary constraints to interactively derive heuristics for pruning the search. FAILSAFE au- tomated the derivation of such heuristics. FS2 learns preservable path constraints, backtracks whenever they are violated, and recovers from unpreservable con- straints. 3 FS2’s base-level problem solver A state space problem is specified in FS2 by an ini- tial state and a goal, both expressed as conjunctions of ground literals. The problem solver does depth-first forward search from the initial state. At every state it has a current goal that it is currently trying to achieve, and zero or more pending goals to achieve subsequently. When the current goal is achieved, it is marked as pro- tected, and the problem solver chooses an unsatisfied pending goal as the new current goal. The problem solver uses two types of search control knowledge. Goal selection rules constrain the selection of which goal to pick as the next current goal. Censors constrain the selection of which operator to apply to the current state. If the problem solver tries to apply an operator to a state, and the the preconditions of the operator are satisfied but applying it would violate a censor, FS2 marks the state as suspended so that it can be reconsidered if no solution is found otherwise. In FS2 the problem solver and the learner have two types of interactions. The first type occurs when the search is under-constrained. Perfectly constrained search proceeds straight to the goal without backtrack- ing. Thus one symptom of under-constrained search is a dead end where no operators can be applied without returning to an already-visited state. Another symp- tom is the violation of a protected goal. The problem solver searches depth-first until any of these symptoms occurs, at which point it declares a failure and invokes the learner. The problem solver also declares a failure and invokes the learner whenever the search depth for the current goal exceeds a preset heuristic limit. The purpose of this limit is to prevent runaway search down fruitless alleys that have exponentially deep dead ends and never reach the goal. If the learner is able to identify the problem solv- ing step that led to the failure, it adds a new cen- sor to prevent similar failures in future and instructs the problem solver to resume search at the state just before that step. Otherwise (for example, when it cannot explain the failure) it does not learn .a new censor, and instructs the problem solver to backtrack chronologically. FS2’s resumption of search at the blamed point resembles dependency directed backtrack- ing (Stallman and Sussman, 1977). The other type of interaction between the problem solver and the learner occurs when the search is over- constrained. Over-constrained search prunes away all solution paths. It is manifested when the problem solver fails to continue making progress. For example, it runs out of states to expand but has not achieved the goal. Besides detecting this extreme case, FS2 uses some domain-independent heuristics to monitor progress. These heuristics detect sudden jumps from a “good stat e” to a “bad state,” or from a “deep state” to a “shallow state”. The first type of jump is defined as a reduction of 50% or more in the number of satis- fied goals between successively expanded states. Such a reduction may indicate an increase in the distance to a total solution. The other type of jump is defined as a reduction of 50% or more in search depth between suc- cessively expanded states. Since the search is ordered depth-first, such a jump may indicate that progress is being blocked by over-general censors. These heuristics attempt to prevent FS2 from exploring a search space rendered barren by over-general censors. Whenever any of these heuristics apply, FS2 pre- sumes that at least one of the suspended states was wrongly suspended. At this point the problem solver calls a heuristic procedure that returns a pair <St, op> and a censor C such that operator op is blocked by the censor C in the suspended state st. The problem solver resumes search by overruling C and applying op to st. We call this process censor relaxation. The meth- ods used to select st and op will be described in Section 4.3. If relaxing the censor leads to achieving the current goal, FS2 infers that the censor was over-general and calls the learner to specialize it. If the space remains 896 MACHINE LEARNING over-constrained, the heuristic procedure will eventu- ally be called again. Problem solving continues until the goal is achieved or all censors are relaxed and no solution is found. 4 How FS2 learns control knowledge FS2’s learner acquires several kinds of control knowl- edge, It learns rules to avoid hitting dead ends and clobbering protected goals. It learns rules to reorder subgoals. Since it sometimes over-generalizes, it also identifies and repairs over-general rules. When the learner is invoked, it is given the current state, the path that led to it (but no other branches of the search), the goals at each point on the path, and the current set of censors. In addition to this dynamic information the learner also makes use of the follow- ing static knowledge, which depends on the problem domain but does not change during problem-solving. The operator definitions describe the problem solving operators for the domain in a STRIPS-like representa- tion conducive to goal regression. The domain theory represents static aspects of the state or problem, e.g., (block a), (connects door12 room1 rooma). While the operator definitions and domain theory may suffice to explain success, they may not explain failures. There- fore a domain-specific theory of failure is used to explain why a given state fails to satisfy the current goal. This theory specifies pairs A and B such that A is a pos- sible goal, B is a conjunctive condition, and A and B cannot hold simultaneously. The explanation takes the form current-goal(A) AB, where B is true in the current state. For the blocks world, FS2 is given 10 such rules, for example, f aiIure(?State) e current-goal((ontable ?X)) A (on ?X ?Y) (Note: Variable names start with ‘?’ in our notation.) Alternatively, a failed state may be explained by the violation of a goal marked as protected in the previous state. We shall now describe some episodes of FS2’s learn- ing behavior in the course of solving the blocks world problem shown in Figure la. To simplify the example, we gave FS2 the correct goal ordering rules to begin with. It found a solution to this problem after expand- ing 60 states, and learned 14 censors in the process. Out of these 14, it found 3 censors to be over-general and specialized them. Without adaptive learning, FS2 took 99 states to solve this problem. None of the goals is satisfied in the initial state. FS2 picks (ontable C) as the first goal to work on. In the first two steps it unstacks C from D and puts C on the table. It now protects the goal (ontable C) and makes (ontable E) the current goal. FS2 learns an interesting rule at the 15th state that it generates, which turns out to be a dead end because the only applicable operator is (unstack E D), which leads back to the state Sr4. Figure lb shows the step that leads to the dead end. 4.1 Learning to avoid obvious failures We shall now show how FS2 learns a censor by (1) explaining a search failure, (2) generalizing the failure (A) The example problem (b) A bad step ’ - Figure 1: The example problem and learning a useful censor condition, (3) assigning blame to the step that caused the condition, and (4) g re ressing the cause of failure through the operator used in the step. This learning episode starts when the problem solver detects a failure at state $5. The learner uses explanation-based generalization (Mitchell et al., 1986, DeJong and Mooney, 1986) to explain and generalize the failure. The specific failure condition at $5 is current-goal((ontable E)) A (on E D). The generalized failure condition is given by the right hand side of the failure rule described ear1ier.l Next the learner assigns blame to the (most recent) step that made the specific failure condition true. In this example, it blames the step that stacked E on D, namely the application of operator (stack E D) leading from state 5’14 to state Slz. In general, the blamed step may precede the failure by a number of steps, since the rules for explaining failure differ detecting it. from the criteria for Finally, the learner regresses the generalized failure condition through the general definition of the blamed operator to derive a censor on the operator. The gen- eral definition of (stacle ?X ?Y) is: nre and delete: (holdina ?X) A (clear ?YL &I: (on ?X ?Yj A (clear ?;6) i (hand-e&t?l). The standard regression method is used except that the meta-predicate current-goal regresses to itself. Thus the following regressed generalized failure condition be- comes a censor on the operator (stack ?X ?Y): current-goal((ontable ?X)) A (holding ?X) A (clear ?Y). Its effect is to prevent the problem solver from stacking block ?X on block ?Y whenever the goal is to put block ‘A more comprehensive explanation of failure would not merely explain why a state does not satisfy the current goal, but also why none of the operator sequences that can achieve the goal apply. PRODIGY and STATIC build such expla- nations. In contrast, FS2 hopes that the violated constraint is preservable on at least one solution path, and ignores the alternative operator sequences, thereby avoiding an exhaus- tive search. BHATNAGARANDMOSTOW 897 &- 6 states - S 25 S 26 Figure 2: Learning a bad censor ?X on the table. After learning this censor, the problem solver resumes at the state S&-where the blamed operator was applied. The learned censor corresponds to a preservable con- straint (that stays true on at least one solution path) since it is always possible to get a block onto the-table without stacking it on another block. By the same pro- cess, FS2 learns not to put block ?X on block ?Y when the goal is to put ?X on block ?Z. PRODIGY and STATIC would not learn this or similar rules because they do not over-generalize. 4.2 Learning a bad censor FS2 learns a bad censor while expanding the 26th state (Figure 2). Even though $6 has many applicable op- erators, all of them get censored by the censors learned earlier. The current goal at &e is (on B C). FS2 ex- plains the failure and gets the specific failure condition current-goal((on B C)) A (ontable B). It blames ap- plication of the operator (putdown B’) in state S17 for \- , making the specific failure condition true. Regressing the generalized failure condition current-goal((on ?B ?C))A(ontable ?B) through the operator (putdown ?B) yields a censor which prevents the problem solver from putting a block down on the table if the goal is to put it on some other block. Since keeping a block off the table is an unpreservable constraint, this censor is bad - it blocks all solution paths. We now show how FS2 recovers. 4.3 Relaxation of bad censors By learning to preserve an unpreservable constraint, FS2 excludes all solutions. Using the heuristics de- scribed in Section 3, the problem solver eventually de- tects its lack of progress, and invokes the heuristic pro- cedure mentioned earlier to return a <st, op> pair. The heuristic procedure first finds a state that is likely to be closest to the goal. The heuristic to choose the state de- pends on such factors as its depth and the number of goals (protected or not) that it satisfies. Once a state is chosen for expansion, the method for finding an operator is more interesting. ‘For this purpose FS2 uses a weak form of backward chaining (WBC). Normal backward chaining recurses on all failed pre- conditions of an operator that could achieve the goal, macro [(putdown A);(unstack C B); current-goal: (putdown C);(pickup A); (stack A B)] (on A B) will achieve the goal I -U-c- -EL sequence of B 5 operators ‘initial S last (putdown A) suggested by WBC. Figure 3: Relaxing a censor and so is expensive to use. To reduce the cost of relax- ation, FS2 does a less expensive backward search that recurses on the failed preconditions one at a time. That is, it treats the and-or search graph as an or-or search graph. The process stops when an operator applicable in the failed state is found. The problem solver opens up the search space by applying this operator. If a solu- tion is found in the subtree exposed by this relaxation, the censor is specialized so that it does not prevent the expansion of this subtree in the future. Consider the censor learned in Section 4.2. This cen- sor will stop the problem solver from reaching the goal in the problem of Figure 3. In the initial state, the prob- lem solver is holding block A, and the goal is to stack A on block B, which is under block C. In this case WBC discovers that the operator (stack: A B) will achieve the desired goal. It recurses on the failed precondition (clear B) of this operator, finding (unstack C B) and (hand-empty) as the next operator and precondition. (hand-empty) can be achieved by either (putdown A) - the correct operator, as it turns out - or by (stack A 0 The goal is eventually achieved by applying the oper- ator sequence [(putdown A), (unstack C B), (putdown C), (pick-up A), (stack A B)]. To prevent the above censor from repeating this error, the specialization mechanism generalizes this operator sequence and sub- tracts the weakest preconditions of the resultant macro from the applicability conditions of the censor. FS2 also learns to reorder goals, to protect precondi- tions that may be required in the process of achiev- ing pending goals, and to identify operator applica tions that are likely to be irrelevant to the current goal. These other types of learning are described in (Bhatnagar and Mostow, 1990). 5 Experimental results We carried out experiments to answer some questions about FS2’s effectiveness. Is it really adaptive? Does the learned knowledge transfer to larger problems? How does FS2 compare with PRODIGY? We tested FS2 in three easy to model domains, namely, the standard blocks world, a modified blocks world (introduced in (Etzioni, 1990)), and a version of the STRIPS robot world (Fikes and Nilsson, 1971). The modified blocks world is the same as the standard blocks world, but with one additional operator that al- lows the problem solver to grasp a block that is second 898 MACHINELEARNING (b) problems solved 30,000 B Strips Robot World B: before; W: while; A: a In the “before” cass problems could not be solved even 1000 In the “before” 0 2 4 6 8 10 12 0 2 4 6 a Figure 4: problems solved FS2’s Performance (cumulative time) from the top of a tower. We chose this domain because PRODIGY reportedly (Etzioni, 1990) could not acquire effective control rules for it. Figures 4a and 5a show FS2’s cumulative search effort in the blocks world domain, measured in time and num- ber of states, respectively. In the before-Zearning case, FS2 was given no control knowledge, and learning was switched off. In the while-learning case, each problem was solved starting with no control knowledge, but with learning switched on. In the after-learning case, learn- ing was switched off, but FS2 used 22 censors learned earlier by training on 24 randomly generated problems. None of the training problems had more than six blocks. We tested FS2 on 36 test problems ranging in size from three to eight blocks, with 6 of each size. FS2’s performance in the after-learning case was sig- nificantly better than in the without-learning case. In the while-learning case, FS2 also solved larger prob- lems in less time and fewer states than in the without- learning case, supporting the adaptive search claim. To test how well FS2’s learned knowledge scales up, we tried using the same set of 22 censors to solve ran- dom problems with more blocks. They enabled FS2 to solve 23 out of 27 problems with seven to fifteen blocks ---- 1 Blocks World In the “before” case 14 problems could not be solved even 20 30 problems solved 4000 2000 problems solved Figure 5: FS2’s Performance (cumulative states) (3 of each size) given the same limit of 350 on the num- ber of states generated. In the without-learning case, it could not solve any of these problems. Figures 4b and 5b show the results of FS2’s perfor- mance in the modified blocks world. Unlike PRODIGY, FS2 was able to acquire effective search control rules in this domain. FS2 solved the same 36 test problems after expanding a total of 522 states in the modified blocks world. It took a comparable 557 states in the standard blocks world. Thus, the increased branching factor due to the additional operator did not impair FS2’s effi- cacy. FS2 learned effective search control rules in this domain because it does not build complete explanations and thus avoids many of the recursive proofs. Figures 4c and 5c show similar results for problems in the STRIPS robot world domain, ranging from 2 blocks in 2 rooms to 4 blocks in 4 rooms. Given a specified configuration of rooms, the initial state and goal for each problem were generated by randomly assigning blocks to rooms. 6 Analysis of utility What is the cost of problem solving in the presence of over-general censors ? FS2 searches by selectively ex- panding subtrees of the original search space. It grows a subtree until all states in it are suspended by censors. BHATNAGARANDMOSTOW 899 It then relaxes a censor in some state, resulting in the expansion of another subtree. This process continues until a solution is reached. We will estimate the cost of processing one such subtree and the number of such subtrees expanded to reach a solution. Let the branching factor of the blind search be B and the expected depth of the solution be DSolaed. Suppose that there are h& censors out of which .&on censors are bad. Let p be the probability that a given censor prevents the application of a given operator. Assuming probabilistic independence of the censors, the probabil- ity that an operator is censored is pCensOred = 1 - (1 - P)“- so Dcensored, the expected number -of steps until some censor applies, is c i*( l-pCeneored)**pCenso~ed = UPC encored - 1. Similarly, DBlocked, the length of the path until a bad censor applies, is I/pBlo&ed - 1, where PBlocked = 1-(1-p) MBad is the probability that some bad censor applies, cutting off all solution paths. Therefore the expected number of censor relaxations required along the solution path is DSolved/DBlocked. Every time a state is relaxed, a subtree of depth Dcensored is generated. We will assume for simplic- ity that all suspended nodes occur at the leaf nodes of this tree. The number of nodes in this tree will be approximately BDCensored. Let Nsuapended be the number of suspended <at, op> pairs in such a subtree. FS2 must guess which of these pairs falls on a solution path. Let ~~~~~~~~~ be the probability of making a correct guess when there are P such pairs. The expected number of censors relaxed until a correct relaxation is found is given bY NRelazations = 1 * PGaess(NSuspended) + 2 * (1 - PGuesa(NSuspended)) * PGaees(2NSuspended) + 3 * (I- PGueas(NSuspended))(l - PGuers(2NSuspended)) * PGue@r(3NSuapended) + l l l - Selecting the <st,op> pair randomly, so that PGW& * Nsuepended) = l/(i * NSuspended), will not be acceptable because then the above expression for NRelazation* will not converge. However, if povess (i * NSaspede.d) = PGuers(Nsmpended) 2 PGuess, that is, if the probability of finding a correct pair has a con- stant lower bound pGues#, then NRelasationa converges to l/pGueas- In practice, it is difficult to find a constant probability algorithm to give a correct state-operator pair to relax. But we can concentrate on finding heuris- tics that will maximize that probability. The learning in FS2 reduces the search task from a single tree of depth DSolved and branching factor B to NRelazations * DSolved/DBlo&ed subtrees of depth DCensored and branching factor B. The cost of process- in a subtree of depth DCendmed can be estimated as B s Cen*orad *B * M *(CO&Q, +CostCensor), where COSI&, and COStCen,o, are the costs of testing the preconditions of an operator and of a censor respectively. For each correct relaxation, NRelaratims (= l/pGuess) such sub- trees must be processed. If we assume that the cost of guessing is negligible, the total cost of search with cen- sors is approximately BDCensorad+l * M * (costCensoT + CostOp) * l/PGueda * DSolved/DBlocked- If this estimate is accurate, what does it signify? Since the cost of blind forward search is approximately BDSoluad * costOp, search using the learned censors will be substantially faster than blind forward search when DSolved >> DCens,ored, assuming that costo, and costCensoT are comparable. For a given set of M cen- sors, the search cost is exponential only in DCensoTed, the expected number of steps until some censor applies, which is determined by ‘J?Cendored. If this probability is independent of the solution depth DSolved, the learned censors should reduce the cost of search from exponen- tial to polynomial in solution depth. These results must be treated with caution, since the analysis is based on very strong simplifying assump- tions. Further work is needed to see if these assump- tions can be weakened, and to extend the analysis to take the cost of learning into account. However, the analysis does offer some preliminary insights into the utility of a set of learned censors. 7 Other related work As indicated earlier, FS2 is very closely related to PRODIGY and STATIC. We shall now compare FS2 with other related work. FS2 can be studied from two points of view. First, it builds incomplete explanations in order to alleviate the intractable theory problem de- scribed in the context of explanation-based learning (Mitchell et al., 1986). S econd, it uses its failures to prune search, and consequently improves its search effi- ciency. We shall compare FS2 with work falling in these two broad categories. Like FS2, the LEBLOC system (Tadepalli, 1989) and the system in (Chien, 1989) make assumptions to sim- plify explanations. LEBLOC simplifies its explana- tions based on an omniscience assumption: it considers only the plans that it knows at the time of explana- tion and ignores all other possibilities. (Chien, 1989) simplifies explanations based on a persistence assump- tion: it assumes that conditions not explicitly men- tioned in the effects of the operators persist between successive states. Both systems refine their explana- tions when an unexpected event occurs, and eventually converge to correct rules. FS2 employs a necessity as- sumption: it assumes that violated constraints must be preserved, and prunes paths that violate them. It re- covers from this assumption in the case of unpreservable constraints, but does not need or try to recover when the violated constraints turn out to be preservable. HS (Ohlsson and Rees, 1990), like FS2, uses its exe- cution time failures to learn search control rules. HS treats paths that preserve the constraints as correct paths and paths that lead to the goals as useful paths. It depends on a high ratio of correct to useful paths for its success. FS2 improves this ratio by exploiting preservable constraints. 900 MACHINE LEARNING (Laird, 1988) describes an extension of SOAR (Laird et uZ., 1985) that learns from its incorrect deci- sions. Rather than modify chunks, it creates additional chunks that prevent the use of the chunks that led to incorrect decisions. Unlike FS2, which uses failures to learn censors on individual operators in the course of synthesizing a plan, the systems described in (Hammond, 1986) and (Gupta, 1987) p s ecialize the preconditions of known macro-operators and plans after they fail. 8 Conclusions In this paper we presented FS2, a system that per- forms adaptive search by learning from its failures. We demonstrated FS2’s performance improvement in three domains and analytically estimated the utility of the rules it learns. The key contribution of FS2 is its use of preserv- able constraints to prune search. The use of these con- straints allows FS2 to learn search control rules which cannot be learned by previous systems like PRODIGY and STATIC that refrain from over-generalization. Our approach should improve on these systems in domains where there are many preservable constraints, espe- cially when simple censors based on such constraints can avoid the recursive explanation problem reported in (Etzioni, 1990). H owever, further empirical and ana- lytic comparison is needed to better understand the rel- ative advantages of these approaches and identify how best to combine them. References (Bhatnagar and Mostow, 1990) Neeraj Bhatnagar and D. J. Mostow. Adaptive search by online explanation- based learning of approximate negative heuristics. Rutgers AI-Design group Working Paper No. 158, 1990. (Chien, 1989) Steve A. Chien. Using and refining sim- plifications: Explanation-based learning of plans in intractable domains. In International Joint Confer- ence on Artificial Intelligence, pages 590-595, 1989. (DeJong and Mooney, 1986) G. F. DeJong and R. J. Mooney. Explanation-based learning: An alternative view. Machine Learning, 1(2):145-176, 1986. (Etzioni, 1990) Oren Etzioni. Why Prodigy/EBL works. In National Conference on ArtijkiuZ InteZ- Zigence, 1990. (Fikes and Nilsson, 1971) R. E. Fikes and N. J. Nils- son. STRIPS: A new approach to the application of theorem proving to problem solving. Artificial InteZ- Zigence, 2:189-208, 1971. (Gupta, 1987) Ajay Gupta. Explanation-based failure recovery. In National Conference on Artificial InteZ- Zigence, pages 606-610, 1987. (Hammond, 1986) Kristian J. Hammond. Learning to anticipate and avoid planning problems through the explanation of failures. In National Conference on Artificial Intelligence, pages 556-560, 1986. (Laird et al., 1985) J.E. Laird, P.S. Rosenbloom, and A. Newell. Chunking in SOAR: the anatomy of a gen- eral learning mechanism. Machine Learning, l(1) : 1 l- 46, 1985. (Laird, 1988) J.E. Laird. Recovery from incorrect knowledge in SOAR. In National Conference on Ar- tificial InteZZigence, pages 618-623, 1988. (Minton, 1988a) Steven Minton. Learning Eflective Search ControZ Knowkedge: An Explanation-Bused Approach. PhD thesis, Carnegie Mellon University, 1988. (Minton, 1988b) Steven Minton. Quantitative results concerning the utility of Explanation-Based Learn- ing. In National Conference on Artificial Intelligence, pages 564-569,1988. (Mitchell et al., 1986) Tom M. Mitchell, R. Keller, and S. Kedar-Cabelli. Explanation-based generalization: A unifying view. Machine Learning, l( 1):47-80, 1986. (Mostow and Bhatnagar, 1987) D. J. Mostow and N. Bhatnagar. Failsafe-a floor planner that uses EBG to learn from its failures. In International Joint Conference on Artificiuk Intelligence, pages 249-255, 1987. (Mostow, 1983) D. J. Mostow. Machine transforma- tion of advice into a heuristic search procedure. In R.S. Michalski, J.G. Carbonell, and T.M. Mitchell, editors, Machine Learning: An Artificial Intelligence Approach, Volume I. Tioga Publishing Company, Palo Alto, California, 1983. (Ohlsson and Rees, 1990) Stellan Ohlsson and Ernest Rees. Adaptive search through constraint violations. Technical Report KUL-90-01, Learning Research and Development Center, University of Pittsburgh, Pitts- burgh, PA, 1990. (Stallman and Sussman, 1977) R. Stallman and G. Sussman. Forward reasoning and dependency directed backtracking in a system for computer-aided circuit analysis. Artificial Intel- Zigence, 9:135-196, 1977. (Tadepalli, 1989) P rasad Tadepalli. Lazy explanation- based learning: A solution to the intractable theory problem. In International Joint Conference on Arti- ficial InteZZigence, pages 694-700, 1989. BHATNAGAR AND MOSTOW 901
|
1990
|
159
|
914
|
Probabilistic Semantics for Cost Based Abduction* Eugene Charniak and Solomon E. Shimony Computer Science Department Box 1910, Brown University Providence, RI 02906 ec@cs.brown.edu and ses@cs.brown.edu Abstract Cost-based abduction attempts to find the best expla- nation for a set of facts by finding a minimal cost proof for the facts. The costs are computed by summing the costs of the assumptions necessary for the proof plus the cost of the rules. We examine existing methods for constructing explanations (proofs), as a minimiza- tion problem on a DAG. We then define a probabilistic semantics for the costs, and prove the equivalence of the cost minimization problem to the Bayesian network MAP solution of the system. Introduction The deductive nomological theory of explanation has it that an explanation is a proof of what is to be explained from knowledge of the world plus a set of assumptions. While there are well known problems with the theory [McDermott, 19871, it is nevertheless an attractive one for people in AI, since it ties something we know little about (explanation) to something we as a community know quite a bit more about (theorem proving). From an AI viewpoint the real problems with the de- ductive nomological theory are not the abstract ones of the philosopher, but rather the immediate one that there are many possible sets of assumptions, which to- gether with our knowledge of the world would serve to explain (prove) the desired fact. Somehow, a choice between the sets must be made. Several researchers ([Kautz and Allen, 19861, [Genesereth, 1984]), have used the above technique and graded assumption sets by a) only allowing some formulas to be assumed, and b) preferring sets with the minimum number of as- sumptions. Obviously, these simplifying assumptions are severely limiting. Cost-based abduction is the obvious generalization of these theorem proving techniques. It allows any for- mula to be assumed, and assigns all assumed formulas *This work has been supported in part by the National Science Foundation under grants IST 8416034 and IST 8515005 and Office of Naval Research under grant N00014- ‘79-C-0529. We also wish to thank Robert Goldman for helpful comments about the semantics, and Randy Calistri for proof reading earlier versions of this paper. a non-negative real number cost. The best explana- tion is then the proof with the minimum cost (a formal definition of cost-based abduction will be given in the next section). Something very similar to what we are calling “cost-based abduction” has been proposed and implemented by Hobbs and Stickel [Hobbs and Stickel, 19881, and it appears to be a promising method for handling abductive problems. However, their scheme has one immediate drawback; at the present moment the “costs” have no adequate semantics: for Hobbs and Stickel they are simply numbers pulled out of a hat. In what follows we will provide a probabilistic se- mantics for cost-based abduction, according to the fol- lowing outline. First, we will formalize a cost-based proof (explanation) of some facts as an augmented DAG, and exploit the similarity of the DAG to a belief network (Bayesian network, [Pearl, 19881) to define a probability distribution using the topology of the DAG plus the costs. A major theorem of the paper will show that the maximum a-posteriori (MAP) assignment of truth values to the network corresponds to the mini- mal cost proof ‘. In the discussion these results will be explained in a more intuitive fashion. Appelt, in [Appelt, 19901, has attempted to give a semantics for the Hobbs-Stickel cost scheme. We will discuss the Hobbs-Stickel approach in more detail, and show why Appelt’s semantics is not adequate. Lastly, we will briefly mention our practical experience with an implementation of cost-based abduction. AG Representation for A rule based system with assumability costs has rules of the form: R: Pl A P2 A a*- A Pn ---) Q with costs c(pi) for each conjunct, and a cost c(R) for applying the rule. A conjunct has the same cost in all the rules where it appears on the left hand side (LHS). The cost of proving q with this rule is the cost of all the conjuncts assumed, plus the cost of the rule. For ‘A MAP assignment is the way to set the values of all random variables such that their joint probability is highest. 106 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. the rest of this section and the next one, we assume without loss of generality that all rule costs are 0. We can do this by adding a po (that appears nowhere else) to the LHS, with a cost c(p0) = c(R). We want to find a minimal cost proof for some fact set E (“the evidence”). We now formalize the minimum cost proof problem as a minimization problem on a weighted AND/OR DAG (acronym WAODAG). We use a three val- ued logic (values (T, F, U}), augmented by sym- bols for keeping track of assumed nodes, versus implied nodes. The values we actually use are Q = (TA, T, U, FA, F}, where U stands for undeter- mined (intuitively: either true or false), T for true, F for false, and the A superscript stands for “assumed”. We use U\ v to say that u is an immediate parent of 21. Definition 1 A WAODAG is a 4-tupte (G, c, r, s), where: 1. G is a connected directed acyclic graph, G = (V, E). 2. c is a function from (IV x Q} to the non-negative reals, called the cost function. For values T, F, U, we have zero cost. c(v) - c(v, TA). 3. r is a function from V to {AND, OR}, called the label. A node labeled AND is called an AND node, etc. 4. s is an AND node with outdegree 0 (evidence node). Definition 2 A truth assignment for a WAODAG is a function f from V to Q. A truth assignment is a (pos- sibty partial) model i# the following conditions hold: 1. If v is a root node (a node with in-degree 0) then f (v> E PA, u, FA). 2. If v is a non-root node, then it can only be assigned values consistent with its parents and its label (AND or OR), and if its parents do not uniquely deter- mine the node’s truth value, it can have any value in (TA, FA, U). The exact details of consistency are pursued in [Charniak and Shimony, 19901, but should be obvious from the well-known definitions of AND and OR in S-valued logic. Note that in our DAG, an OR node is true if at least one of its parents is true, as in belief net- works, but not as commonly used for search AND/OR trees. A non-root node may still be assumed true if its parents determine that it has to be true. Intuitively, an assignment is a model if the AND/OR constraints are obeyed. A node v where f(v) = TA in an assignment, is called an assumed true node relative to the assignment. Likewise for other values of f(v). Definition 3 A model for a WAODAG is satisfying iI-7 f(s) E iTA, Tl. Definition 4 The cost of an assignment A for a WAODAG is the sum c = c +u, f(v)) VEV The Best Selection Problem is the problem of finding a minimal cost (possibly not unique) satisfying model for a given WAODAG. The Given Cost Selection Prob- lem is that of finding a satisfying model with cost less than or equal to a given cost. Note that in a par- tial model, assuming a node false is useless, as such an assumption cannot contribute towards a satisfying model. Theorem 1 The Given Cost Selection Problem is NP-complete. The theorem is easily proved via a reduction from Vertex Cover (see [Garey and Johnson, 19791). We present the complete proof in [Charniak and Shimony, 19901. The Best Selection Problem is clearly at least as hard as the Given Cost Selection Problem, because if we had a minimal cost satisfying model, we can find its cost in O(lVj), and give an answer to the Given Cost Selection Problem. Thus, the Best Selection Problem is NP-hard. We will now make the connection between the graphs and the rule based system. We assume that exactly all possibly relevant rule and fact instances are given. How that may be achieved is beyond the scope of this paper. Theorem 2 The Best Selection Problem subsumes the problem of finding a minimal cost proof for the rute- based system with assumability costs, assuming that the rule based system is acyclic. Informal proof: by constructing a WAODAG (i.e. constructing the graph G, and assigning labels and costs) for the rule instance set, as follows: For each literal in any rule2 R’s LHS, construct OR node v, and set c(vrTA) to the cost of the literal in the system. For each literal appearing only on the RHS of rules, construct an OR node v, with c(v, TA) = 00. For each LHS of a rule R, construct and AND node v with c(v,TA) = 00, make it a parent of the node constructed for the literal on the RHS of R (in step l), and make it a child of all the nodes constructed for the literals in the LHS of R. Construct an AND node s, with parent nodes corre- sponding to the facts to be proved. Example: Given the rule instances in the table, used for word-sense disambiguation in natural language, with rb=river-bank(bankl), sb=savings-bank(bankl), w=water(water5), p=plant(plant7), we want to ex- plain the evidence: say(bankl)Asay(water5). I Rules II Literal Cost 1 ‘We assume that literals with the same name in different rules are the same literal. CHARNIAKAND~HIMONY 107 Figure 1: WAODAG for our example rules Using the above construction, we get the WAODAG in figure 1, with best partial model (total cost 5) shown. Definition 5 A root-only assignment for a WAODAG is an assignment where only root nodes may be assumed (i.e. have values in {FA,TA)). It is possible to force root-only assignments for a WAODAG to be globally minimal by setting the cost of all non-root nodes to infinity (in practice, it suffices to set a cost greater than the sum of the root costs). We now show that given an WAODAG D, we can cre- ate another WAODAG D’, such that the semantics of minimal models is not changed, i.e. if a non-root node is selected in D, some corresponding new root node is selected in D’. Proof: by construction, as follows (D’ = D initially): 1. For each AND node v with cost c(v, TA) < 00 in D’, construct an OR node w in D’, and a new root node u, where c(u, TA) = c(v, TA), and make both v \w and u \ w. Transfer all the children3 of v to zu. 2. For each OR node v with cost c(v, TA) < 00, create a new root-node u, with C(ZL, TA) = c(v, TA). Make u\v. 3. For all non-root nodes v in D’, set c(v, TA) = 00. It is clear that each time a node is selected in a minimal cost model of D to be assumed true, the node constructed from it in D’ will be assumed true in some root-only minimal cost model for I)‘. Definition 6 An assignment (or model) is complete ipAJEV, f(v)#U. - * A variant of the Best Selection Problem is one of selecting a minimal cost complete model. Clearly, if the cost of assuming a node false is 0 for all nodes, the solution will be exactly the same as for the par- tial model Best Selection Problem. However, in our ‘If the AND node is s, create a new sink AND node, s’, semantics we intend to treat assumability costs as negative logarithms of probabilities (so that summing costs is akin to multiplying probabilities), and we want W(v) = FA> = 1 - P(f(v) = TA) to hold for all root nodes. Thus, the cost of assuming a node v false c(v, FA) = -log(l - e-+* TA’) robabilistic Semantics for WAODAGs We now provide a probabilistic semantics for the cost based abduction system. We construct a boolean be- lief network out of the weighted AND/OR DAG, and show the correspondence between the solution to the Best Selection Problem and finding the most likely ex- planation for a given fact (or set of facts). We assume that the rule based system is in the WAODAG format with root-only assignment. We now construct a belief network from the given WAODAG, and show that a minimal cost satisfying complete model for the WAODAG corresponds to a maximum- probability assignment of root-nodes given the evi- dence in the belief network (where the evidence is ex- actly the set of facts to be proved using the rule sys- tem). From a WAODAG D we construct a belief network B as follows: B has exactly the nodes and arcs of D. Thus, we use the same name for a node of B and the corresponding node of D. Nodes retain their labels4. Each root node v in B has a prior probability of e-c(u, TA)e The node s is the “evidence node”, i.e. the event of node s being true is the evidence & . Defining an assignment for the network analogously with the WAODAG assignment, we assume, without loss of generality, that we are only interested in assign- ment to the set of root nodes5. We want to find the “best” satisfying model A , which assigns values from (TA, FA, V} to the set of all root nodes, i.e. the assignment that maximizes P(d ] E). An assignment of U to a root node means that it is omitted from the calculation of joint probabilities, as P(vi = U) = 1. Intuitively, we are searching for the most probable ex- planation for the given evidence. This can be done by running a Bayesian network algorithm for finding Bel* on the root nodes, as defined in [Pearl, 19881. We now show the following result: Theorem 3 In a boolean belief network B constructed as above, a satisfying complete model A that maximizes 4A belief network AND node has a 1 in its conditional distribution array for the case of all parents being true, and 0 elsewhere. An OR node is defined analogously. ‘Maximizing the probability over assignments to root nodes is equivalent to finding the MAP, when we allow only complete models, because a complete assignment for the root nodes induces a unique model for all other nodes. and make w\s’. 108 AUTOMATEDREASONING P(dI E) 11 1 b wi a so e a minimal cost satisfying complete prover, as found in typical rule-based systems, the the- model for D. orem prover will itself only generate AND/OR DAGS. Proof: In a belief network, all root nodes (given no evidence) are mutually independent. Thus, for any as- signment of values to root nodes, A = (al, a2, . . . . a,,), where ai = (vi, s(i) and qi E {FA, TA}6. q1, a2, “*) %a 1 = P(a1) P(a2) . . . P(an) However, we also have (by definition of conditional probabilities): w I W(A) P(d 1 E)= P(E) But as P(z? I d) = 1 when the assignment is a satis- fying model (because all nodes are strict OR and AND nodes), and 0 otherwise, and P(E) is a constant, we can eliminate everything but P(d) from the maximization. Also, we have: - - - n n P(d) = P(u;) = e-+;) = e- x;=, 44 i=l i=l Since es is monotonically increasing in Z, we see that maximizing P(d I 8) is equivalent to minimizing the cost of the assignment, Q.E.D. We now generalize the DAG so that nodes can have any gating function 7. The definition of a model is ex- tended in the obvious way. Theorem 4 Given a gate-only belief network, with a single evidence node, the problem of finding the most probable complete satisfying model given the evidence is equivalent to finding a minimal cost complete model for the weighted gated DAG. So unless one is willing to add capabilities to the the- orem prover, arbitrary gates are pointless. Also, since AND/OR gates do not require the labels FA and F, they are marginally simplier to implement. (However, as we will note in the section on implementation, we found that we needed the capabilities of arbitrary gates for our domain.). The second distinction is between partial and com- plete models. The distinction here is whether we sim- ply assign costs to those facts which we must assume true (or false) to make the proof work, or go on to make decisions about every fact in the domain, whether or not it plays a role in the proof. Intuitively the former makes more sense. Unfortunately, our theorem (that we would get the MAP assignment) is only true for complete models, and counterexamples exist for non- complete models. Also, the minimal cost complete model will not agree, in general, with the minimal cost partial model, even if we compare only the sets of nodes assumed. However, the minimal solution of the complete model problem will be a nearly minimal solution for the partial model, provided a) there is no other complete model with nearly the same cost as the minimum, and b) the cost for assuming nodes false is low. These are reasonable assumptions in many cases. For example, the probabilistic semantics presented in [Charniak and Goldman, 19881 is characterized by low prior probabilities, thus low costs for assuming nodes false. Lastly, a further word is required about the relation between the costs and the probabilities. In our defini- tion of cost-based abduction there were three sorts of entities which received costs: rules, root nodes, and in- terior nodes. By the time we reached theorems 3 and 4, however, we had reduced this to one, by showing that rule and interior node costs could be replaced by added root node costs. But how do these transforma- tions affect our interpretation of what the costs mean in terms of probabilities? Proof: The proof of theorem 3 relies only on the fact that the probability of the evidence given a satisfying model is 1, and 0 given any other complete model. Thus, we can use exactly the same proof here. If we want to find the best partial model, and are only interested in satisfying models, the above theorem still holds. It is no longer true, however, that finding the minimum cost model is equivalent to finding the MAP over the entire belief net. Evaluation of Cost Based Abduction In essence, the theorems of the last two section serve to define not one scheme of cost-based abduction, but four. The most obvious distinction is between Theo- rems 3 and 4. The first restricts itself to WAODAGs, while the second generalizes to arbitrary gating func- tions. There are two things to keep in mind about this distinction. First, if one is using a standard theorem ‘Additionally, we use the a;‘s to denote the event of node vi having value qi. 7Gate nodes are any p robabilistic nodes which have only entries of 1 and 0 in their conditional distribution arrays. Things are most obvious for root nodes. As stated earlier, the cost of assuming a root node must be -log( P(node)). F or rules and interior nodes, however, things are slightly more complex. The cost of a rule got moved to the cost of a new root node. Suppose for rule R we add the new root node R’. We can, of course, say that the cost of a rule must be -log(P(R’)). However, R’ does not correspond to anything in our model of the world (it is merely a mathematical fiction designed to make the proof simpler). We need to define the cost in terms of elements of our world model. Thus, suppose R is the rule: and we will denote the AND node corresponding to its left-hand side as AR’. We will refer to the AND node without the added cost root attached as AR. CHARNIAKAND~HIMONY 109 Suppose that the other rules which can prove q” are RI, ...I R, with the corresponding AND nodes (with- out attached cost roots) ARK, . . . . AR,. It is easy to see that P(q I AR A BARD A . . . A -AR,) = P(R’). That is, the cost of a rule is minus log probability of its consequent being true given that a) its antecedent is true, and b) none of the other ways of proving (or assuming) the consequent are true. Analogously, we can show that the cost of assuming an interior OR node v is -log(P(v I all the ways of proving it are false)). Finally, since in practice there is never a need for assuming an AND node, we will ignore it here. The above analysis only holds when we are considering complete assignments. When par- tial assignments are allowed, a case may be made for setting the cost of assuming an interior OR node to k-hlw4)), b ecause if non of its parents are assigned (i.e. we are not proving the node, just assuming it), then presumably the probability of the node reverts to its prior probability. Given that the notion of partial MAP’s is not well defined in the literature, we defer the solution to this problem to future research. We believe, however, that decision theoretic methods may have to be applied in the latter case. Appelt’s Semantics for Hobbs-Stickel In [Hobbs and Stickel, 19881, Hobbs and Stickel have proposed a scheme very similar to what we have pro- posed. In their scheme, the initial facts to be explained are each assigned an assumption cost ci. All inference rules are of the form: The cost of the pi’s are then given by cost(p;) = ?lJi cost(q). However, if two separate portions of the proof-tree require the same assumption, the proof is only charged once for the assumption (and is charged the minimum of the two costs being charged for the fact). Hobbs and Stickel point out that C = Cr==, wi does not have to equal 1. If C < 1 then the system will prefer to assume pr , . . . . pn, since that will be less ex- pensive than assuming q. They refer to this as most- specific abduction. On the other hand, if C > 1, then, everything else being equal, the system will tend to just assume q (least-specific abduction). Note, how- ever, that even with least-specific abduction, cost shar- ing on common assumptions can make a more specific scenario cost less. Hobbs and Stickel believe that least- specific abduction (with cost sharing) is the way to go, at least for the abductive problems they are concerned with (natural language comprehension). In general we agree with this assessment. As we have noted, Hobbs and Stickel did not give a semantics for their weights, and Appelt in [Appelt, 19901 is concerned with overcoming this deficit. Appelt takes as his starting point Selman and Kautz’s theory of default reasoning [Selman and Kautz, 19891 called model preference theory. In this theory a default rule p + q is interpreted as meaning that in all models in which p is true, the models in which q is also true are to be preferred. Appelt, in the spirit of abduction, re- verses this by saying that a rule p”p ---) q where wp < 1 is to be interpreted as a model preference among those models which have q for those which have p was well. However, it is possible to have another rule ~~~ ----) s (where wr < l), but where p and f are not compatible. Thus if s is also in our model we must choose which rules to use. Appelt specifies that if wp < w1 then use p --) q, and vice versa. Appelt calls this scheme weighted abduction. The most obvious difference between Hobbs-Stickel, and weighted abduction is that the former use rules of the form: p;’ A . . . A pzn ---) q where weighted abduction only has rules of the form wp P --) q. We assume that what Appelt has in mind is recasting the Hobbs Stickel rules as (pr A . . . A P,)~P ---) q. With wp = xi wi. Assuming this is correct, there are two immediate problems with Appelt’s semantics. First, it only handles the case where the sum of the wi’s is less than 1. This is what Hobbs and Stickel call more-specific abduction. But as they note, less-specific abduction seems to be the more important case, and Appelt says nothing about it8. Secondly, Appelt can give no obvious guidance to how to apportion We into the individual wi’s required by Hobbs-Stickel. But even if we restrict ourselves to finding the single wp, and also restrict ourselves to more-specific abduc- tion, it would seem that Appelt’s semantics gives little guidance when trying to judge if a number is “right”. Suppose we have a system with a group of w’s for var- ious rules (w,, wb . . . wy} and we now want to add a rule with the number wz , and we want to know what w, should be. Following Appelt we will look for models in which the rules wa, wb, . . . wY are used but where the rule Z conflicts with their use. In each case we see which rule takes precedence. But this is not sufficient. Suppose we have a model in which A and B are used but where Z makes both unusable. Since costs are ad- ditive we have several possibilities: {A + B > 2, but A < Z}, (B < 2 but A + B < 23, etc. Depending on the numbers, in some cases we should prefer using rules A and B together over Z, in other cases not. But this is not sufficient either, what about A + C, and A + B + C, and B + C, etc. In fact, the number of models which need to be checked grows exponentially with the number of costs in the system. ‘In his talk at the Symposium on Abduction 1990, Ap- pelt has extended the scheme for some cases where the weights sum to more than 1. We doubt, however, whether this extension can be generalized. 110 AUTOMATEDREASONING Implementation As we have showed in this paper, anything that can be done with cost-based abduction can also be done by probabilistic methods. One might then ask, why not use the more standard probability theory? The rea- son would have to be that the standard probabilistic methods are computationally expensive. Evaluating general belief nets is NP-hard. Unfortunately, as we saw in Theorem 1, so is the minimal cost proof prob- lem. However, as the mathematics is quite a bit sim- pler for minimal cost proofs, one might hope that the constant in front is a lot less. Also, thinking in terms of minimal-cost proofs suggests different ways of look- ing for solutions. There are well known techniques for doing best first search on AND/OR search spaces, and this looks like an obvious application. We have implemented a best-first search scheme for finding minimal cost the work described in Charniak and Goldman, 19881, P roofs. We have applied it to which uses belief nets to make abductive decisions on problems that come up in natural language under- standing, such as noun-phrase reference, or plan recog- nition. Thus, we had a ready-made source of networks and probabilities upon which we could test the system, and a benchmark (the speed of our current probabilis- tic methods). The approach seems to have some promise. We were able to adapt our networks to the new scheme with lit- tle difficulty. (Of the four versions of cost-based abduc- tion mentioned above, we found that complete models did not seem to be required for our networks, but we did need general gates, and not just WAODAGs.). Be- cause we did not use MAP labelings in our earlier work, but rather decided what to believe on the basis of the probability of individual statements, we simulated this by looking for multiple MAP solutions when there were several within some epsilon of each other, and only be- lieving the statements which were in all of them. For the examples we have tried it on, this gave the same results as our belief network calculations. After minor tuning, our cost algorithm seems to be running significantly faster than the belief-network up- dating scheme we were using. However, we have not yet done formal timing comparisons between them, and at the moment both the cost algorithm, and the belief- network updating scheme, are very sensitive to effi- ciency measures. Thus it is unclear how much the tim- ing will prove. It does, however, seem safe to say that cost-based abduction deserves serious consideration. We should note that this speed-up occurs despite the fact that we do not have a good admissible heuristic cost estimator for our best-first search. We are using the simplest heuristic imaginable - at any point in a partial proof, we assume that the final cost of the proof will be the costs incurred to date. This is a very poor estimator because the bulk of a proof’s cost comes from the root assumptions, and they are not found until the end. We are currently exploring other estimator pos- sibilities, such as logic minimization approaches and factoring in assumption costs earlier in the search. Conclusion We have shown that cost-based abduction can be given an adequate semantics based upon probability theory, and that under the appropriate circumstances it is guaranteed to find the best MAP assignment of truth values to the propositions in our theory. Initial experi- ments with the model show that it does produce results consistent with full blown posterior probability calcu- lation, and does so quickly compared to our current probabilistic methods. However, further experimenta- tion is clearly required. References [Appelt, 19901 Douglas E. Appelt. A theory of abduc- tion based on model preference. In Proceedings of the AAAI Symposium on Abduction, 1990. [Charniak and Goldman, 19881 Eugene Charniak and Robert Goldman. A logic for semantic interpreta- tion. In Proceedings of the AAAI Conference, 1988. [Charniak and Shimony, 19901 Eugene Charniak and Solomon E. Shimony. Probabilistic semantics for rule based systems. Technical Report CS-90-02, Computer Science Department, Brown University, February 1990. [Garey and Johnson, 19791 M. R. Garey and D. S. Johnson. Computers and Intractibility, A Guide to the Theory of NP-completeness, page 190. W. H. Freeman and Co., 1979. [Genesereth, 19841 Michael R. Genesereth. The use of design descriptions in automated diagnosis. Artifi- cial Intelligence, pages 411-436, 1984. [Hobbs and Stickel, 19881 Jerry R. Hobbs and Mark Stickel. Interpretation as abduction. In Proceedings of the 26th Conference of the ACL, 1988. Kautz and Allen, 19861 Henry A. Kautz and James F. Allen. Generalized plan recognotion. In Proceedings of the Fi;fth Con- ference of AAAI, August 1986. McDermott, 19871 Drew V. McDermott. Critique of pure reason. Computational Intelligence, 3:151-60, November 1987. [Pearl, 19881 J. Pearl. Probabilistic Reasoning in In- telligent Systems: Networks of Plausible Inference. Morgan Kaufmann, San Mateo, CA, 1988. [Selman and Kautz, 19891 Bart Selman and Henry Kautz. The complexity of model-preference default theories. In Reinfrank et. al., editor, Non-Monotonic Reasoning, pages 115-130. Springer Verlag, Berlin, 1989. CHARNIAKAND SHIMONY 111
|
1990
|
16
|
915
|
Empirical Comparisons of Some Design Replay Algorit Brad Blumenthal t Department of Computer Sciences University of Texas at Austin Austin, Texas 78712 brad@cs.utexas.edu Abstract Although most design replay techniques have been em- pirically tested against some performance program, there has been very little empirical evidence published that compares various approaches on the same prob- lems to determine the source of power. Six different design replay algorithms based on approaches in the lit- erature are implemented and tested on 20 different de- sign replay problems. The resulting data indicate that there is a trade-off between efficiency and autonomy for certain types of adaptation strategies. Based on some of the lessons drawn from this data, a new algo- rithm, REMAID, has been developed. This algorithm recognizes two different types of mis-matches between previous experience and current problems: detours and pretours. The REMAID strategy takes advantage of its knowledge of m&matches to improve replay auton- omy without sacrificing efficiency. The success of the REMAID algorithm is empirically verified. Introduction Design replay has been proposed as a way of us- ing previous design experience to improve the perfor- mance of automated design systems [Carbonell, 1986; Mostow, 19891. Instead of attempting to reuse a pre- vious solution, the design replay technique records the steps that went into producing a previous solution and replays the sequence of steps. This approach provides more flexibility in reusing experience by preserving in- termediate steps of the problem solution and thus al- lowing partial reuse of the appropriate parts of the solution. However, this flexibility depends on a ca- pability to adapt previous solution steps to fit a new problem. Mostow enumerates the dimensions on which a de- sign replay technique can be evaluated [Mostow, 19891. This paper will concentrate on the dimensions of ef- ficiency, or how much computation is required, and + Support for this research was provided by the National Science Foundation under grant IRI-8620052, Apple Com- puter Corp., and by the Army Research Office under grant ARO-DAAG29-84-K-0060. autonomy, or how much of the problem the replay al- gorithm addresses. An ablation study was performed using six algorithms that vary only in what strategies they use to adapt previous experience to fit a new prob- lem. These strategies are based on replay strategies presented in the literature. The resulting data isolate and quantify the contributions of each of these adap- tation strategies to replay efficiency and autonomy. The data support several hypotheses. Some are un- surprising: design replay is generally an effective tech- nique, and increased flexibility in adapting recorded experience to new problems increases both efficiency and autonomy. More informatively, the data also in- dicate that calling an automated design performance program to help adapt to replay failures can be a suc- cessful strategy, but that there may be a trade-off be- tween efficiency and autonomy unless the execution of the replay program and the performance program are interleaved intelligently. The lessons learned from this study have led to the development of a seventh algorithm: REMA1D.l This algorithm increases both the efficiency and autonomy of the design replay process by appropriately interleav- ing execution of design replay and automated design. It does so by recognizing two types of replay failures that occur, detours and pretours, and by appropriately adapting design experience during replay. The RE- MAID algorithm was run on the design replay prob- lems from the ablation study, and empirically, it per- formed with the best. For clarity, the following terminology will be used in this paper: a design episode is a computation which takes a specification as input and produces a design as output. A design experience is a previously completed design episode. A design goal is a description of a de- sign (sub-)problem and includes information about the entity being addressed and the desired outcome of ad- dressing that goal. A rule is a heuristic used to select or “‘MAID” is an acronym for “Metaphoric Application Interface Designer;” MAID is the performance component of this system which produces interface designs that re- semble real world objects. “REMAID” is an acronym for “Replaying Episodes of MAID.” 902 MACHINE LEARNING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. address a design goal. A design history is a recording of the goals and rules that make up a design experience. “Step” is short for a recorded goal and its associated rules and decisions. Thus, for the purposes of this pa- per, design replay is concerned with recording design experience and using the resulting design history to improve the efficiency and autonomy of a new design episode. Typically this is done by matching a goal in the history to a goal in the current episode, replaying the corresponding design rule, and continuing with the next step. The Domain To test the various replay algorithms, a performance program was written which automates the design of hu- man interfaces for computer applications. Thedomain of automated human interface design is an especially appropriate one because interface design is expensive and time-consuming, yet it is often desirable to have multiple, alternate interface designs to a computer ap- plication. Such a collection of designs might be used to conduct user studies to determine what techniques are most effective or to tailor computer applications for specialized user communities. The Performance Program The performance program used for this study is the MAID interface designer. This program takes as input a frame-based description of the objects and operations that a computer program makes available to a user. It produces as output a design for a human interface to that application in terms of a set of interface techniques such as menus, graphics, text, etc. In addition, the MAID interface designer uses a knowledge base of real- world objects to produce metaphoric interfaces which mimic the appearance and behavior of such objects [Blumenthal, 19901. One of the most expensive operations in the MAID program is choosing the next design goal to be ad- dressed. A characteristic of the interface design do- main is that there are default rules for addressing any design goal. As a consequence, MAID is not required to do any backtracking ; however, in order to achieve the best designs possible, MAID has to spend more effort ordering the design goals. Essentially, MAID trades backtracking for extra goal-ordering effort and the possibility of sub-optimal designs. Therefore, at the heart of the MAID program is an agenda of pending design goals. MAID uses a set of or- dering heuristics to select a goal from the agenda based - on the features the agenda, and then uses the goal. a separate set of design heuristics to-address of each goal, what other goals are on the state of the design in progress. It Applying design replay techniques to this problem of selecting goals from the MAID agenda is promising for the following reasons: since there is no backtrack- ing in MAID, the order in which design subgoals are addressed can significantly affect the resulting inter- face design; it is necessary to run the agenda ordering heuristics at every step, since the relevant factors can change in unpredictable ways during the course of a design; however, running all of the heuristics is expen- sive and only a small percentage of the heuristics tried at any step usefully reduce the size of the conflict set. The Experiment The MAID design program is currently capable of de- signing five interfaces to a single application.2 Thus, there are five possible design histories, each of which can be used in the design of any of the five interfaces. This gives a total of 25 possible design replay episodes, including five trivial cases designing the same interface in both the recorded experience and the new episode. The six algorithms summarized below were imple- mented and run on all 25 cases. Data were collected from the 20 non-trivial cases on the total number of goals addressed, the number of goals replayed from the recorded experience, the total number of order- ing heuristics which were applied to the agenda, and the number of ordering heuristics that were useful in selecting the next goal to be addressed.3 Current Techniques Mostow outlines the important issues in successfully applying the design replay technique, including ac- quiring design experience, determining the correspon- dence between previously and newly encountered de- sign goals, and determining the appropriateness of a previously executed design step in a new situation [Mostow, 19891. This paper will focus solely on the issue of adaptation: the problem of reusing design ex- perience when parts of a new design episode do not match the previous experience. There are two parts to this problem which Mostow refers to as the adaptation process. This paper de- parts from that terminology slightly. The first part of this problem, which is here referred to as “adaptation,” is the question of what to do when a particular step in a recorded history fails to match or address a corre- sponding goal in the current design episode. Strategies for adaptation vary from simply ignoring the failing recorded goal to trying to modify the state of the cur- rent design episode so that the recorded step succeeds in finding or addressing a corresponding goal. The second part is referred to as “recovery” and is the question of what to do when none of the goals in a recorded history can be successfully used to select a 2This is limited by the amount of knowledge entered in the knowledge base, not by any inherent limitations of the MAID program. 3Due to irrelevant technical details, accurate CPU times were unavailable. All of the ordering heuristics use similar amounts of CPU time, so for purposes of comparison, a count of heuristic applications is adequate. BLUMENTHAL 903 corresponding goal from the current design state. Re- covery strategies range from simply halting replay to invoking a performance program and then attempting to restart replay. There have been a number of projects address- ing the problems in design replay since Carbonell’s derivational analogy proposal [Carbonell, 19861. Three projects that the REMAID research builds on are the BOGART/VEXED project [Mostow, 19891, the work by Carbonell and Veloso on using derivational anal- ogy in the PRODIGY system [Carbonell and Veloso, 19881, and the PRIAR project [Kambhampati, 1989a; Kambhampati, 1989b]. The following algorithms vary only in their ap- proaches to adaptation. Since the domains used for research in these techniques have varied from circuit design to matrix manipulations to blocks world plan- ning it has not been possible to reimplement exact ver- sions of the various algorithms for use in the interface design domain. However, the approaches toward adap- tation and recovery are domain-independent, and they have been preserved and implemented in order to de- termine how they affect the replay process. Table 1 summarizes the six replay algorithms. There are two adaptation strategies: simply skip the recorded goal and try later or use alternate design rules. There are three recovery strategies: halt replay, use MAID for one goal then restart replay, or use MAID for all remaining goals. A short description of the research motivating each adaptation and recovery strategy fol- lows. BOGART/VEXED The replay program, BOG- ART [Mostow, 19891, records design goals and the de- sign rules for achieving those goals as they are chosen by a designer who is using the VEXED circuit design tool. BOGART then applies the design rules in the order in which they were recorded. BOGART fails to reuse a design rule if the corresponding recorded goal fails to match a goal in the current episode or if the rule preconditions are not satisfied by the matching goal. The BOGART approach to adaptation is to sim- ply skip any design step that fails to be replayed. It continues until it has tried every step remaining on the history without success. BOGART’s approach to re- covery is to halt replay and ask the human designer for a new history to replay. HOBART4 implements the BOGART approach to adaptation and recovery. HOBART attempts to match a goal from the history to a goal on the current agenda of pending goals. HOBART simply skips any step whose goal does not match a goal on the agenda or whose design rule does not address the matching goal. When no more goals on the history match any goals on the agenda, HOBART halts. 4The names of the reimplementations for their phonemic similarity. were chosen solely PRODIGY Extensions Carbonell and Veloso’s ex- tensions to the PRODIGY system [Carbonell and Veloso, 19881 reuse a history that records the goal or- dering decisions, variable bindings, and problem solv- ing rule choices that produce a solution to a matrix manipulation problem, as well as the justifications for each of these decisions. When PRODIGY fails to reuse a recorded step, then it follows what Carbonell and Veloso call the “sat- isficing approach” to adaptation and recovery. One strategy described for this approach is to address the matched goal in some other fashion and then continue replay at the next step. A second is to attempt to satisfy the violated justification(s) in some way and continue replay at the current step. There are a number of ways these strategies can be implemented, so one simple adaptation strategy and one simple recovery strategy were developed and added to the basic HOBART algorithm, both separately and together. The adaptation strategy is based on the first satisficing strategy and is used when a recorded goal from the history matches a goal on the current agenda, but the recorded design rule does not apply. This strat- egy tries other design rules until one succeeds (recall from section that there is always a default rule which is guaranteed the next step. to succeed) and then continues replay at The recovery strategy is invoked when all of the goals on the recorded history have been tried and none of them match a goal on the current agenda. In this case the MAID algorithm is invoked to select and address a goal on the agenda, and replay is started again where it was stopped. This is based on the second strategy; something is done to satisfy the justifications of some recorded goal and replay is started where it left off. The implementation of HOBART with the PRODIGY-inspired adaptation strategy (al- ternate design rules) is called “PROBART.” The im- plementation which has the recovery strategy (select and address one goal with a performance program) is called “POSSIBLY.” The implementation with both the adaptation strategy and the recovery strategy is called “PROBABLY.” PRIAR Kambhampati’s PRIAR system reuses plans produced by a non-linear planner to solve new planning problems [Kambhampati, 1989b]. PRIAR’s adaptation strategy uses the pre- and post-conditions of the recorded plan operations to determine what op- erations in the recorded plan to reuse. This strategy is not feasible in the MAID domain5 PRIAR’s recovery strategy takes any goals that are not satisfied by the old plan and posts them as new goals that are then solved by the same non-linear plan- 5For one reason, the MAID domain has rules with con- ditional consequents. This prevents PRIAR from analyzing the recorded rules to determine whether they will have the desired effect. 904 MACHINE LEARNING 1 Algortihm 11 Adaptation Strategy 1 Recovery Strategy II Table 1: Summary of algorithms tested: strategy for adapting to single recorded rule failures, and strategy for recovering when recorded history can suggest no more goals. ner that produced the recorded plan. This strategy inspired a recovery strategy which use the MAID de- sign program to address any goals left on the agenda without attempting to restart replay. The first, called “BRIAR,” uses the HOBART algorithm until replay fails, and then invokes the MAID algorithm to ad- dress any left-over design goals. The second algorithm, called “PYRE,” uses the PRODIGY-inspired adapta- tion strategy (using alternate design rules) and the PRIAR-inspired recovery strategy (turn control over to the performance program to finish the design). Results Table 2 presents the averages of the data collected from 20 different replay episodes of each algorithm. The data for MAID give the average number of goals ad- dressed and the average number of heuristics tried and used by the MAID performance program over five de- signs and is presented for comparison. The efficiency of the various algorithms is measured in terms of the number of applications of ordering heuristics that were needed to complete a design. All of the ordering and match heuristics measured use similar amounts of CPU time, so for purposes of comparison, searching the agenda for a goal matching a recorded goal on the history was counted as one heuristic ap- plication. Since all of the algorithms use ordering and match heuristics for adaptation and recovery, this met- ric adequately captures the overhead due to replay. The number of heuristics tried represents the num- ber of heuristics which were applied (successfully or not) in an attempt to select a goal from the agenda. The number of heuristics used represents the number of heuristics which successfully reduced the size of the conflict set (including those that actually chose a goal). The autonomy of each algorithm was measured by the number of goals that it successfully replayed. All of the algorithms that used the MAID algorithm for recovery completed all of the designs. HOBART and PROBART halted when there were no more goals that could be replayed. Both the PRODIGY-inspired adaptation plan (ex- pand one goal and restart replay) and the PRODIGY- inspired recovery plan (try alternate design rules) added similar amounts of autonomy. This is evidenced by comparing the difference in goals replayed between HOBART and PROBART or POSSIBLY and PROB- ABLY (difference due to adaptation) with that be- tween HOBART and POSSIBLY or PROBART and PROBABLY (difference due to recovery). The PRODIGY-inspired adaptation strategy of us- ing alternate design rules also contributed to efficiency. This is evidenced by the data for PROBART, PROB- ABLY, and PYRE. Since checking the preconditions of alternate design rules is very cheap compared to apply- ing goal selection rules, the overhead for this approach is nominal. In terms of efficiency, the PRODIGY-inspired recov- ery strategy was the most expensive, as seen by the results for POSSIBLY and PROBABLY. The most ef- ficient performer is the PYRE algorithm which takes advantage of flexible adaptation with a less expensive recovery strategy. The least efficient is the POSSIBLY algorithm which used the more rigid adaptation strat- egy and the most expensive recovery strategy. Discussion The foremost lesson of the empirical data is that, in terms of efficiency, design replay is a successful ap- proach. Although the implementations employed very simple adaptation and recovery strategies, all but one of the algorithms required fewer ordering heuristics than the MAID performance program. Even the sim- plest approach, HOBART, replayed 43.4% of the de- sign goals. Autonomy vs. Efficiency Another important point supported by the empiri- cal data is that using the performance program for recovery when the replay algorithm cannot find any more corresponding goals to replay is generally an ef- fective strategy. Although this has been suggested by Carbonell [Carbonell, 1986] and demonstrated for non-linear planners by Kambhampati [Kambhampati, 1989a], the empirical data show that this is true if the replay strategy is sufficiently flexible. However, there seems to be a trade-off between the amount of autonomy afforded by using the perfor- mance program for recovery, and the cost of such a strategy. The PRODIGY- and PRIAR-inspired recov- ery strategies represent two extremes. In general, more BLUMENTHAL 905 Algorithm MAID Goals Goals Heuristics Heuristics % Used/Tried Addressed Replayed Fried Used 145.2 NA 1677.0 331.6 21.7 c 1 REMAID 11 145.2 1 ill.7 1 584.5 1 276.8 1 59.6 Table 2: Results of running each algorithm on 20 design replay problems. steps are reused when the history is examined every time a goal is addressed. This is the case in the POS- SIBLY and PROBABLY algorithms. The problem is that it is very expensive to determine that more recov- ery is needed, and this usually must be done multiple times. The other extreme is to avoid the expense of recov- ery altogether by giving up on the replay algorithm as soon as it can no longer suggest a goal to address. This is the approach taken by the BRIAR and PYRE algorithms. Such an approach takes advantage of the efficiency of design replay when corresponding goals are readily apparent, without spending any more ef- fort on replay once the replay algorithm fails to find a matching goal. This technique can tolerate a larger number of goals in the new design episode that do not correspond to goals in the recorded history; however, it requires that most of the corresponding goals appear on the agenda before the replay strategy is abandoned and control is turned over to the performance program. The REMAID Strategy One conclusion that can be drawn from the trade-off between recovery cost and recovery autonomy is that some guide to navigating the history, other than lin- ear search, is needed. One of the goals of the REMAID project is to find a technique for intelligently interleav- ing design replay and automated design. Each of the six algorithms compared above follows a strategy of ag- gressively pursuing only those agenda goals in the cur- rent episode that correspond to goals on the recorded history. If a single step on the history fails to find or ad- dress a corresponding goal on the agenda, it is ignored and the next step is considered. Recovery strategies are only invoked when replayable goals on the history are exhausted. REMAID, on the other hand, attends to the kinds of failures that occur and uses that information to mod- ify the order in which the recorded history is used so that it better matches the current agenda. Thus, it intelligently interleaves replay and automated design and produces both an efficient and autonomous design episode. The REMAID Algorithm The REMAID algorithm reuses the experience of the MAID automated interface design system. In addition to each goal that was addressed, and the design rule used to address it, REMAID records the heuristics that usefully reduced the size of the conflict set when the goal was selected.6 During replay, REMAID applies the recorded or- dering heuristics to the agenda and compares the re- sulting candidate goals with the chosen goal recorded in the history. If only one goal is chosen from the agenda by the recorded ordering heuristics, and that goal matches 7 the chosen goal recorded on the his- tory, then REMAID addresses that goal and contin- ues replay with the next step recorded on the history. The assumption here is that the same goal was cho- sen for the same reasons, and that replay is therefore proceeding correctly. REMAID uses the PRODIGY- inspired adaptation strategy of considering alternate design rules if the recorded design rule fails. When the recorded ordering rules do not select a matching goal on the agenda or when they select more than one goal, REMAID attempts to determine why the recorded ordering rules have failed and attempts to recover from such failures in a more appropriate way than by just going to the next step in the linear ordering of the design history. Currently, REMAID recognizes two classes of ordering rule failure: detours and pretours. Detours If the recorded ordering rules choose more than one goal, and one of the selected goals corre- sponds to the chosen goal recorded on the history, then REMAID has encountered a situation where there are new goals in the current design episode that were not present in the design experience recorded in the his- tory. Such a situation is called a detour. REMAID addresses the goal corresponding to the chosen goal 6Recall from the discussion of MAID that the number of useful heuristics is a small percentage of the number of heuristics tried. 7REMAID uses the same matching algorithm used by the other six algorithms. 906 MACHINE LEARNING recorded on the history first. Any other goals are as- sumed to be new goals which are similar enough to the chosen goal recorded on the history that they should be addressed at the same time. By recognizing de- tours, REMAID can use its replay strategy on goals that do not correspond to any goal recorded on the history. This strategy increases autonomy, thereby re- ducing the number of goals in the current episode that have to be addressed with the performance program. Pretours If the recorded ordering heuristics choose at least one goal, and none of the goals chosen match the chosen goal recorded on the history, then REMAID assumes that there are goals in the recorded history that are not in the current design episode. Such a situ- ation is called a pretour. If REMAID can find recorded goals on the history that correspond to the goals cho- sen in this step, then it chooses the nearest goal in the linear order of the history and continues replay there. Instead of matching each goal on the history, one at a time, against the agenda, REMAID effectively reorders the history to better fit the current agenda. If REMAID cannot find any recorded goals on the history to match the ones chosen, or if the ordering heuristics recorded on the history for this step do not choose any goals, then it calls on MAID to select a goal. If the goal MAID selects corresponds to some goal on the history, then REMAID restarts replay with that goal, again, effectively reordering the history. Other- wise, it continues to call MAID until MAID selects a goal that corresponds to some goal on the history or the design is complete. By recognizing pretours, and using the performance program to suggest where to restart replay, REMAID can navigate through the history, intelligently inter- leaving the execution of the replay and performance programs. This strategy increases autonomy without sacrificing efficiency. REMAID Results The REMAID algorithm was run on the same replay problems given to the other six algorithms. The av- erages for the 20 runs are presented in Table 2. Even though REMAID has more overhead for straightfor- ward replay (i.e. replay with no pretours or detours), it performed as autonomously as PROBABLY and as efficiently as PYRE. Conclusion Most replay algorithms have been empirically tested against some performance program, but very little em- pirical data have been published that compare vari- ous approaches in the same domain to establish the source of power. The data presented here indicate that a flexible technique for adapting to single goal n&-matches increases both the efficiency and auton- omy of replay. Further, using a performance program for recovery from replay failures is a promising tech- nique, but there is a trade-off between efficiency and autonomy unless the replay algorithm can intelligently interleave execution of the replay program and the per- formance program. Although efficiency and autonomy are not the only ways that derivational analogy can be evaluated, they do give a rough comparison of the effectiveness of various approaches. The REM AID algorithm recognizes the kinds of mis- matches that occur during replay. By recognizing and addressing detours, REMAID increases the autonomy of design replay. By recognizing pretours, REMAID increases autonomy and maintains efficiency by intel- ligently interleaving design replay and automated de- sign. Acknowledgements I am grateful to Subbarao Kambhampati, Ray Mooney, Jack Mostow, Ken Murray, Bruce Porter, and Manuela Veloso for comments, discussions and correspondence on design replay and derivational analogy. I would also like to thank Liane Acker, James Lester, and Penni Sibun for comments on early drafts of this paper. References [Blumenthal, 19901 Brad Blumenthal. Replaying Episodes of a Metaphoric Application Interface De- signer. PhD thesis, University of Texas Artificial Intelligence Lab, Austin, TX, Forthcoming 1990. [Carbonell and Veloso, 1988] Jamie G. Carbonell and Manuela Veloso. Integrating problem solving and derivational analogy. In Proceedings of the First Workshop on Case-Based Reasoning, 1988. [Carbonell, 19861 J amie G. Carbonell. Derivational analogy: A theory of reconstructive problem solv- ing. In R. S. Michalski, Jamie G. Carbonell, and T. M. Mitchell, editors, Machine Learning: An Ar- tificial Intelligence Approach, volume II, chapter 14. Morgan Kaufman, Los Altos, CA, 1986. [Kambhampati, 1989a] Subbarao Kambhampati. Control of refitting during plan reuse. In Proceedings of the International Joint Conference on Artificial Intelligence 1989, Detroit, MI, 1989. [Kambhampati, 1989b] Subbarao Kambham- pati. Flexible Reuse and Modification in Hierarchical Planning: A Validation Structure Based Approach. PhD thesis, Computer Vision Laboratory, Center for Automation Research, University of Maryland, Col- lege Park, MD, 1989. [Mostow, 19891 Jack Mostow. Design by derivational analogy: Issues in the automated replay of design plans. Artificial Intelligence, 40( l-3), 1989. BLUMENTHAL 907
|
1990
|
160
|
916
|
Megan Eskey and Monte Zweben NASA Ames Research Center M.S. 244-17 Moffett Field, California 94035 eskey@pluto.arc.nasa.gov, zweben@!pluto.arc.nasa.gov Abstract This paper describes an application of an analyti- cal learning technique, Plausible Explanation-Based Learning (PEB L), that dynamically acquires search control knowledge for a constraint-based scheduling system. In general, the efficiency of a scheduling sys- tem suffers because of resource contention among ac- tivities. Our system learns the general conditions un- der which chronic contention occurs and uses search control to avoid repeating mistakes. Because it is im- possible to prove that a chronic contention will occur with only one example, traditional EBL techniques are insufficient. We extend classical EBL by adding an em- pirical component that creates search control rules only when the system gains enough confidence in the plau- sible explanations. This extension to EBL was driven by our observations about the behavior of our schedul- ing system when applied to the real-world problem of scheduling tasks for NASA Space Shuttle payload pro- cessing. We demonstrate the utility of this approach and provide experimental results. Introduction In many real-world scheduling domains, activities are highly constrained by their need to share a finite set of resources. Efficient allocation of these resources and ef- ficient search strategies are imperative in any schedul- ing system. Recognizing and anticipating situations of likely resource contention and determining an appro- priate search strategy to avoid backtracking can im- prove scheduling and resource allocation. To synthe- size schedules with minimum work-in-process (WIP) time, activities are scheduled from a temporally-based perspective. In a constraint-based scheduling system, this means committing to an activity’s first available start and end times consistent with all temporal con- straints, then selecting a resource that is available in that time interval. However, if there is no resource of the appropriate type available at that time, new start and end times must be chosen, causing back- tracking. Scheduling from a resource-based perspec- tive means choosing an appropriate resource, then find- ing an activity’s start and end times based on the capacity constraints of that resource (i.e., the next time the resource is available). This strategy re- duces backtracking, but the efficiency improvement is gained at the expense of increased WIP time. Previ- ous scheduling methods have been to perform a heuris- tic look-ahead to determine contentious resources, and to schedule only these “bottleneck resources” from the resource-based perspective [Smith and Ow, 1985, Fox, 19871. Rather than relying onZy on opportunistic schemes, we exploit previous experience by learning the general conditions under which backtracking oc- curs. We use the learned search control knowledge in future situations to alter the search strategy accord- ingly. Because of the exponential size of the search space, the ability to use search control knowledge has been shown to be critical in many domain-independent problem solvers, including planning, scheduling, and theorem-proving systems [Minton, 1988b, Laird et al., 1986, Smith and Ow, 19851. We use (and extend) exist- ing explanation-based learning (EBL) methods to dy- namically acquire search control rules. We have added an empirical component to EBL, in which multiple ex- amples confirm plausible conjectures. Unlike most pre- vious work that combines empirical techniques with EBL [Pazzani et al., 1986, Mooney and Ourston, 1989, Hirsh, 1989, Danyluk, 19891, our empirical component is not used to make inductive leaps. Rather, it is used because of the inherent characteristics of the target concept; the target concept cannot be proved with a single example and requires a distribution of examples. This extension was driven by the application of EBL to the real-world problem of scheduling tasks for Space Shuttle payload processing. The target concept in this domain is a chronic resource contention and cannot be confirmed with one example. We call this exten- sion to EBL “Plausible Explanation-Based Learning” (PEBL). This paper discusses the integration of PEBL into a constraint-based scheduling system. After a brief de- scription of the scheduling system and the Kennedy Space Center (KSC) payload processing domain, we describe PEBL and how it is used in the context of 908 MACHINE LEARNING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. scheduling. We then present results of a set of experi- ments that reveal the advantages and disadvantages of using the learned search control rules. Constraint-based Scheduling In this section, we describe our formulation of a constraint-based scheduling problem, and the specific problem of payload processing. Scheduling as a Constraint Satisfaction Problem A constraint satisfaction problem (CSP) is character- ized by a finite set of variables V = {Vl...V,), their respective domains Dl...Dn, and a set of constraints C(V;:, Vi, ..). A solution to a CSP is an assignment of values pi to all V;: such that all constraints are satis- fied. A constraint is a subset of the Cartesian product C E D1 x D2 x . . . x D,, that specifies the consistent and inconsistent choices among variable values. Con- straints may be specified extensionally by enumerating all consistent values, or specified intensionally as func- tions. A scheduling problem can be viewed as a constraint satisfaction problem. In our scheduling system, we for- mulate a resource allocation and scheduling problem as a set of task and resource objects [Zweben and Eskey, 19891. Task objects contain information (slots) about an activity’s start time, end time, duration, and re- source requirements. This information is represented by distinct variables each having a domain of possible values and a set of domain constraints. Resource re- quirements of a task include information about type and quantity needed. Resource objects contain infor- mation about the availability of the resources. Con- straints in the system define temporal relations and resource capacity requirements. We specify constraints intensionally. The scheduling process begins by placing all tasks on a priority queue of unscheduled tasks. The prior- ity queue generally prefers tasks that are close to the anchors of the schedule (the tasks fixed in time due to external forces). As the tasks are removed from the queue, a variable commitment strategy is used to guide the search for appropriate times and resources for the task. When scheduling from a temporally-based per- spective, start time, end time and duration variables are instantiated before resource requirement variables. When scheduling from a resource-based perspective, resource requirement variables are instantiated before temporal variables. A solution to the scheduling prob- lem is an assignment of times and resources to each task, such that all constraints are satisfied. The Kennedy Space Center Payload Processing Domain We have formulated a scheduling problem based on the NASA space shuttle’s payload processing domain [Hankins et al., 1985, Brown, 19871. Payloads that fly on the shuttle rest on modular containers called carri- ers. Kennedy Space Center personnel have generated a partially ordered hierarchy of tasks necessary to pro- cess the payloads and carriers before and after a shut- tle flight. Resource type and quantity requirements for each task have also been determined. The anchor of the schedule in this domain is the launch date of the shuttle. The task queue is ordered such that post- launch tasks are scheduled forward in chronological or- der (with respect to the partial order) and pre-launch tasks are scheduled backwards from launch in reverse chronological order. In this domain there are a limited number of ex- pensive, specialized resources (e.g., the carriers) and a number of other scarce resources. Each mission’s processing tasks must be completed in time for the next mission that requires the specialized or scarce re- source. Thus, if WIP time is too long, a mission’s launch date could potentially slip. Additionally, one must quickly synthesize viable schedules since time is also a critical resource. Although scheduling from the resource perspective generally improves the efficiency of the system, if used without restraint it can degrade the optimality of the solution by creating schedules with unacceptably long WIP times. Thus, our goal is to restrict the changes in the search strategy to the most critical points in the scheduling process. Plausible Explanation-based Learning In this section we describe to improve search. the learning technique used The Basic Learning Method Explanation-based learning is an analytical technique that can be used to learn search control knowledge [Mitchell et al., 1986, DeJong and Mooney, 1986, Minton, 1988a]. EBL begins with a high-level target concept and a training example. Then, using a do- main theory (a set of axioms describing the domain), it generates an explanation of why the particular train- ing example is an instance of the target concept. The explanation is a proof that the training example satis- fies the target concept. The EBL approach finds the weakest preconditions of the explanation, producing a learned description that implies the target concept. The description is a generalization of the training ex- ample and a specialization of the target concept and must satisfy some operationality criterion that requires that it be in a usable form. In the domain of scheduling, the resources that are in high demand are considered bottlenecks if their ca- pacity is insufficient for the resource requirements of concurrent tasks. The tasks competing for the bottle- neck resources vary depending on the specific condi- tions of the current schedule. In each instance of con- tention, it is unlikely that the exact configuration of tasks will compete for some resource more than once. ESKEY AND ZWEBEN 909 Given: 1. 2. 3. 4. 1. 2. 3. 4. 5. A domain theory A target concept An example instance A library of previously generated explanations Try to instantiate one of the previously generated explanations for the given example instance. If no explanation applies to the example instance, then use standard EBL to explain the instance: us- ing the domain theory, prove that the example in- stance entails the target concept and generalize the explanation. Go to 5. If an explanation applies to the example instance, augment the confidence in the explanation. If the stored explanation has reached its con- fidence level, (based on some decision function, D uaefuz-explan), th en extract an operational concept from the explanation and form a search control rule. Continue problem solving. Figure 1: The PEBL Procedure On the other hand, some subset of these tasks may reappear in a similar configuration. With standard EBL, one must be able to prove that the example en- tails the target concept, but proving that some resource contention is chronic requires multiple examples. We define our target concept in this domain as a “plausi- bly chronic resource bottleneck”. Thus, each example of contention is only a plausible conjecture of chronic contention, and empirical confirmation with multiple examples is needed to prove the target concept. Only when the system has gained enough confidence in the plausible explanation is a search control rule created. The confidence in an explanation can be described as a decision function, Duseful-ezplan, where: D usef ul-explan . ’ Pexplan x c, x c, - {O,l}. P explan is the probability that the explanation is cor- rect, Cm is the expected cost to match the search control rule [Minton, 1988a], and Co is a measure of the expected degradation in the quality of the solu- tion. The semantics of the rules in the domain theory can be viewed as conditional probabilities. Then, the conditional probabilities associated with the plausible implications can be used to determine the probability that an explanation is correct over some sample space [Pearl, 19851. The PEBL procedure is shown in Fig- ure 1. 9 10 MACHINE LEARNING An Example in the Payload Processing Domain In the payload processing domain, the target concepts to be learned are the plausibly chronic resource bot- tlenecks. The domain theory contains information de- scribing the conditions under which contention might occur, such as proximity of multi-mission launch dates, types of carriers, types of tasks, and types of resources. The training example is an instance of a task whose resource requirements were not met. As an example, we illustrate the generalization problem for a plausi- bly chronic resource bottleneck between tasks in two different missions (see Table 1). The domain theory is used to create a specialized instance of the target con- cept (with each of the variables instantiated). Then a goal regression algorithm generalizes the description by regressing the target concept’s preconditions back through the results of the inference process, and finds the weakest preconditions under which the explanation holds. For example, consider a task spucelab-systems- experiment-test that is a subtask of spucelub- experiment-integration. SpaceZub-systems-experiment- test is part of a biological mission that uses a long- module-2 carrier. Among its resource requirements is a request for automatic test equipment. If there is no automatic test equipment available at the first time consistent with its temporal constraints, learning would be initiated. First, all previously generated ex- planations are tested to see if their preconditions apply to this particular example. If no explanation holds, a new one is generated that describes the current situa- tion. In this example, by using the domain theory, the system would determine that the bottleneck is a result of contention with a set of previously scheduled tasks in some other biological mission that use all of the au- tomatic test equipment. Both missions have launch dates within six months of each other. If a previously generated explanation held, its con- fidence would be augmented. If the confidence in the explanation, as determined by the decision function, D useful-esplan, was sufficient, a new search control rule would be generated. Then, this and other rules would be used to guide search in future scheduling runs. If, in this example, the confidence was high, the search control rule shown in Figure 2 would be created. Evaluating the Method In this section we describe the empirical analysis of the PEBL method. Empirical Results To evaluate the success of this approach we randomly generated sixteen sets of missions with varying prox- imity of launch dates and various carrier types. For the training phase, we used six sets of missions (with TABLE 1: THE PLAUSIBLY-CHRONIC-RESOURCE-BOTT~ENECK-ACROSS-TWO-MISSIONS GENERALIZATION PROBLEM Given: 0 et Cu Class of where: instances of a chronic resource bottleneck across two missions ~AUSlBLY-CHRONlC-RESOURCE-BOTTLENECK-ACROSS-TWO-MISSIONS(taskf.res) IN-MlSSlON(taskf.missZ) A CONFLICTING-TASKS(taskf.res,task-ffsr) A 1SA(missZ.MlSSlON) A NOT-EQUAL(mfssf.mfssZ) A NEARBY(mfssf.mfss2) A CONFLICT-IN-MISSlON(task-ffst.mfss2.task2) A USES-CARRlER(missf,carrf) A USES-CARRIER(mfss2,carr2) A CARRIER-TYPE(carrf .carr-typef) A CARRIER-TYPE(carr2,carr-type21 A RESOURCE-TYPE(res,res-type) A TASK-TYPE(taskf,task-typef) A TASK-TYPE(task2,task-type2). RESOURCE-BOTTLENECK(spacelab-systems-experiment-test 1. automatic-test-equipment 1) ISA(spacelab-systems-experiment-test l.SPACELAB-SYSTEMS-EXPERIMENT-TEST) IN-MISSlON(spacelab-systems-experiment-test 1 .sts-62) lSA(sts-62.MlSSION) USES-CARRlER(sts-62.lm2- 1) lSA(lm2- l.LONG-MODULE-21 USERS(res.task-fist) A EQ(paraffef-tasks. {task E task-fist I lNTERSECTS(task.taskf))) + CONFLICTING-TASKS(taskf.res.paraffef-tasks) START-TIME(taskf .st 1) A END-TIME(taskf .et f 1 A START-TIME(task2.st2) A END-TlME(task2.et2) A (LEQ(stf.et2) A LEQ(et2,etf 1) v(LEQ(stf.st2) A LEQ(st2,etf 1) + lNTERSECTS(taskf,task2) lSA(mf.MlSSlON) A ISA(m2.MlSSlON) A NOT-EQUAL(mf .m2) A LAUNCH(mf .timef 1 A LAUNCH(m2.tfme2) A MINUS(tfmef.tfme2.df/f3 A ABSOLUTE-VALUE(dfff.abs-vaf) A LESS-THAN(abs-vaf.SlX-MONTHS) + NEARBY(mf.rn2) CONFLICTING-TASKS(conf-task.res.task-ffst) A 3 task E task-fist IN-MISSlON(task.miss) + CONFLICT-IN-MISSION(task-ffst.miss.fask) lSA(task.SPACELAB-SYSTEMS-EXPERIMENT-TEST) + TASK-TYPE(task.SPACELAB-EXPERIMENT-INTEGRATION) ISA(task.PAD-OPERATIONS) + TASK-TYPE(task.LEVEL-I) e EQ(res. AUTOM ATIC-TEST-EQUIPMENT I) + RESOURCE-TYPE(res. AUTOM ATIC-TEST-EQUIPMENT) EQ(res.EAST-CRANE) -+ RESOURCE-TYPE(res.CRANE) e lSA(c.MPESS) + CARRIER-TYPE(c.MISSlON-PECULIAR) lSA(c.LONG-MODULE- 1) v lSA(c.LONG-MODULE-21 v lSA(c.PALLET-IGLOO) + CARRIER-TYPE(c.BIOLC#$AL) tv Critefipa; The concept definition must be expressed in terms of the predicates used to describe the examples (e.g.. IN-MlSSlON(fask.mfss). USES-CARRlER(mfss.carrJ) or other selected. easily evaluated predicates from the domain theory (e.g..MlNUS. LAUNCH. TASK-TYPE). A generalization of the training example that is a sufficient concept definition for the target concept and that satisfies the operationality criterion. ESKEY AND ZWEBEN 911 If Discussion of the Results TASK-TYPE( taskf, SPACELAB-EXPERIMENT-INTEGRATION) A RESOURCE-TYPE( res, AUTOMATIC-TEST-EQUIPMENT) A IN-MISSION( taskf,nadssf) A LAUNCH( missf, timef) A ISA( mis&,MISSION) A LAUNCH( rniss2, timei?) A MINUS( timef , time& difl A ABS-VAL( di#,abs-val) A LESS-THAN( ah-val,SIX-MONTHS) A USES-CARRIER( missf ,carrf) A CARRIER-TYPE( carrf,BIOLOGICAL) A USES-CARRIER( missS!,carr2) A CARRIER-TYPE( carr2,BIOLOGICAL) A Then SCHEDULING-PERSPECTIVE( taskf, RESOURCE-BASED) Figure 2: An Example Search Control Rule - 300 examples of resource contention). In our cur- rent implementation of PEBL, the decision function, D usefui-explan, is a simple threshold value. We ana- lyzed the characteristics of the search space of schedul- ing this training set of missions to determine a likely range of threshold values. In this problem, a rule was created from an explanation if the explanation was ap- plicable to four examples in a sample of one hundred. After training, we compared the respective speeds and WIP times for the resulting schedules generated with and without the learned search control rules created by PEBL, and for the schedules generated with rules created by using a zero threshold on ten different sets of missions. Using a threshold of zero is analogous to using standard EBL, where each explanation would be used to create a search control rule. This falsely implies that every resource bottleneck is chronic, how- ever, so we refer to this as the “Learn Always” method. The results of the efficiency gain of synthesizing sched- ules using the learned knowledge are shown in Table 2. The results of the increased WIP times for the sched- ules generated with search control rules are shown in Table 3. The number of tasks in each set of missions varied from 362 in Test-3 to 652 in Test-8 From 296 ex- amples, PEBL created 19 search control rules. The number of times that the search control rules applied in each set of missions varied from 70 times in Test-3 to 138 times in Test-7 and Test-lo. The rules were tested before scheduling each task. When using the Learn Always technique, 78 search control rules were created. The number of times the rules applied ranged from 117 times in Test-3 to 233 times in Test-lo. In any learning system that generates search control rules, the utility of the rules is of primary importance [Minton, 198813, Keller, 19871. Minton defines search control knowledge as being useful when the cumulative benefits of applying the knowledge outweigh the cumu- lative costs of testing whether the knowledge is appli- cable. He defines performance improvement in terms of run time speed-up. But utility can also be mea- sured in terms of solution quality. In many scheduling domains, the optimality of a schedule cannot be com- promised for efficiency gain. Thus, when measuring the utility of the search control knowledge in schedul- ing, one must also take into account the quality of the generated schedule. In this domain, the optimization criterion for schedule quality is minimal WIP time. In our experiments, the empirical component of PEBL proved essential. With too many rules, schedul- ing with the learned knowledge is worse than schedul- ing without the learned knowledge. The cost of test- ing the rules results in decreased system efficiency, and over-applying the non-optimizing search strategy cre- ates poor schedules. The results of our empirical analysis indicate that we must address the utility problem in terms of so- lution quality. The speed-up of the system is sig- nificant, ranging from - 19 % to - 77 % when the search control knowledge is applied. Test-9 showed the most significant efficiency improvement (76.99 %) be- cause of the configuration of carriers and launch dates (three biological carriers with launch dates within six months, thus, high contention for human resources). The overall average speed-up was 34.25 %. However, the increase in WIP time varies from one set of mis- sions to another. In some instances, the degradation in the quality of the synthesized schedules is noticeable, in others, the total WIP time is maintained. In this and other real-world domains, however, the ability to rapidly generate viable schedules is essential, and in some cases, worth marginal increases in WIP time. When scheduling from the resource perspective, we choose resources randomly and then choose times based on these resources’ availability. Some processing to select the “best” resource (the resource that has the maximum availability or that has a sufficient quantity available during a time interval closest to the desired time) may improve the synthesized schedules, because the choice of resource determines the values for start and end times when scheduling from the resource per- spective. This is similar to the look-ahead schemes of [Smith and Ow, 19851 however, and would incur addi- tional costs to the efficiency of the system. Additionally, we believe that scheduling tasks from individual missions such that WIP time is minimized does not necessarily create schedules in which total WIP time is minimized. That is, there may be some cases when a sparser distribution of resource utilization in one mission allows the tasks in a second mission to 9 12 MACHINE LEARNING arch Control Table 2: Program Efficiency with and without the Learned Search Control Knowledge Increase in Table 3: WIP time with and without the Learned Search Control Knowledge ESKEY AND ZWEBEN 913 better interleave with the tasks in the first mission, thus reducing total WIP time across both missions. elated Work The PEBL approach extends previous work in EBL [Mitchell et aL, 1986, Minton, 1988a, DeJong and Mooney, 19861 by applying it to a real-world prob- lem and by adding an empirical component to con- firm plausible explanations. In the real-world domain of payload processing scheduling, contention for a bot- tleneck resource is only plausibly chronic. This ob- servation inspired the integration of plausibility into EBL, and ultimately, the creation of PEBL. The PEBL method is similar to other empirical learn- ing techniques [Pazzani et al., 1986, Danyluk, 1989, Hirsh, 1989, Mooney and Ourston, 19891. However, our empirical component is not used to make induc- tive leaps. Rather, the target concept itself cannot be proved without a distribution of examples. In the PEBL framework, the decision to create a rule is determined by the expected cost to solution quality, the conditional probabilities associated with plausible implications, and the expected match cost of applying a rule. Prior work [Minton, 1988b] in learning search control rules calculates the utility of a rule as a func- tion of the frequency of application, the match cost and the efficiency gain. This is similar to work in learn- ing macro-operators [Iba, 19891; a macro-operator is deemed useful if its expanded length does not exceed some threshold, and if it appears in a successful solu- tion path. Since our system does not create rules from every plausible explanation, we avoid having to reject useless or incorrect knowledge. Finally, we extend previous work in scheduling us- ing multiple perspectives [Smith and Ow, 19851 by ap- plying machine learning techniques to minimize the changes in the search strategy to the most critical points in the search space. Conclusions and Future Work In the domain of scheduling, the balance between pro- gram efficiency and solution quality is essential. As our preliminary results are promising, we plan to thor- oughly test these ideas on a set of comprehensive exper- iments. We will incorporate some look-ahead process- ing for resource selection and investigate other variable commitment search strategies. We will repeat the tests shown above, this time randomly varying the resource capacities. We intend to further analyze the character- istics of a good interleaving of tasks across missions. If we can incorporate these characteristics into the do- main theory, we can then create search control rules that are likely to minimize WIP time. Because the number of generated search control rules effects the utility of the learned knowledge, accurately deciding whether a rule will be useful is essential. We intend to replace our current implementation of D,,ef UJ-explan as a simple threshold, by adding heuristic measures to determine good solutions, and by extending the do- main theory to include conditional probabilities that conjectured implications will be proven. In the future, we plan to extend our work in machine learning and scheduling. We intend to apply PEBL to different search frameworks (e.g., constraint-based sim- ulated annealing [Zweben, 19901) and will investigate the idea of forming macro-constraints. Although indi- vidual constraints may not be restrictive, small sub- sets can effectively prune the search space. The appli- cation of these macro-constraints may quickly restrict the possible values for a variable. Other ideas include learning constraint ordering to find failure points early in the search process. Acknowledgements We thank Steve Minton for many valuable discussions and the use of Prodigy’s rule system, John Bresina for his ideas about plausibility and John, Steve, Smadar Kedar, Pat Langley and Peter Friedland for carefully reviewing this paper. References [Brown, 19871 Brown, Richard H. Knowledge-based Scheduling and Resource Allocation in the CAMPS Architecture. In Proceedings from the IEEE In- ternational Conference on Expert Systems and the Leading Edge in Planning and Control. Ben- jamin/Cummings, 1987. [Danyluk, 19891 Danyluk, A. Finding New Rules for Incomplete Theories. In Proceedings of the 222th In- ternational Workshop on Machine Learning, 1989. [DeJong and Mooney, 19861 DeJong, G.F., Mooney, R. Explanation-Based Generalization: An Alterna- tive View. Machine Learning, 1, 1986. [Fox, 19871 Fox, Mark S. Constraint-Directed Search: A Case Study of Job Shop Scheduling. Research Notes in AI, Morgan Kaufmann Publishers, Inc., Los Altos, CA, 1987. [Hankins et al., 19851 Hankins, G.B., Jordan, J.W., Katz, J.L., Mulvehill, A.M., Dumoulin, J.N., Ra- gusa, J. EMPRESS: Expert Mission Planning and Re-planning Scheduling System. In &pert Systems in Government Symposium, 1985. [Hirsh, 19891 Hirsh, H. Combining Empirical and An- alytical Learning with Version Spaces. In Proceed- ings of the Sixth International Workshop on Ma- chine Learning, 1989. [Iba, 19891 Iba, G.A. A Heuristic Approach to the Dis- covery of Macro-operators. Machine Learning, 3(4), 1989. [Keller, 19871 Keller, R.M. Defining Operationality for Explanation-Based Learning. In AAAI-87 Proceed- ings, 1987. 9 14 MACHINE LEARNING [Keller, 19871 Keller, R.M. Defining Operationality for Explanation-Based Learning. In AA AI-87 Proceed- ings, 1987. [Laird et crl., 1986] Laird, J., Rosenbloom, P., Newell, A. Universal Subgoaling and Chunking. Kluwer Aca- demic, Hingham, MA, 1986. [Minton, 1988a] Minton, S. Learning Effective Search Control Knowledge: An Explanation- based Ap- proach. PhD thesis, Carnegie Mellon University, 1988. [Minton, 1988133 M’ t m on, S. Quantitative Results Con- cerning the Utility of Explanation-Based Learning. In AAAI-88 Proceedings, 1988. [Mitchell et al., 19861 Mitchell, T.M., Keller, R.M., Kedar-Cabelli, S.T. Explanation-Based Learning: A Unifying View. Machine Learning, 1, 1986. [Mooney and Ourston, 19891 Mooney, R., Ourston, D. Induction over the Unexplained: Integrated Learn- ing of Concepts with Both Explainable and Conven- tional Aspects. In Proceedings of the Sixth Intema- tional Workshop on Machine Learning, 1989. [Pazzani et al., 1986] Pazzani, M., Dyer, M., Flowers, M. The Role of Prior Causal Theories in General- ization. In AAAI-86 Proceedings, 1986. [Pearl, 19851 Pearl, J. Probabilistic Reasoning in In- telligent Systems: Networks of Plausible Inference. Morgan Kaufmann Publishers, Inc., San Mateo, CA, 1988. [Smith and Ow, 19851 Smith, S.F., Ow, P.S. The Use of Multiple Problem Decompositions in Time- Constrained Planning Tasks. In IJCAI-85 Proceed- ings, 1985. [Zweben and Eskey, 19891 Zweben, M., Eskey, M. Constraint Satisfaction with Delayed Evaluation. In IJCAI-89 Proceedings, 1989. [Zweben, 19901 Zweben, M. A Framework for Itera- tive Improvement Search Algorithms Suited for Con- straint Satisfaction Problems. Technical Report, NASA Ames Research Center, 1990. ESKEY AND ZWEBEN 9 15
|
1990
|
161
|
917
|
Why PRODIGY/EBL Works Oren Etzioni* School of Computer Science Carnegie Mellon University Pittsburgh, PA 15213 etzi@cs.cmu.edu Abstract Explanation-Based Learning (EBL) fails to accel- erate problem solving in some problem spaces. How do these problem spaces differ from the ones in Minton’s experiments [1988b]? Can minute modifications to problem space encod- ing drastically alter EBL’s performance? Will PRODIGY/EBL'S success scale to real-world do- mains? This paper presents a formal the- ory of problem space structure that answers these questions. The central observation is that PRODIGY/EBL relies on finding nonrecur- sive explanations of PRODIGY'S problem-solving behavior. The theory explains and predicts PRODIGY/EBL'S performance in a wide range of problem spaces. The theory also predicts that a static program transformer, called STATIC, can match PRODIGY/EBL'S performance in some cases. The paper reports on an array of experiments that confirms this prediction. STATIC matches PRODIGY/EBL'S performance in each of Minton’s problem spaces. Motivation “It is rare that one sees an AI system evaluated carefully by anyone other than its creator.” [Bobrow, 19841 Minton [1988b] showed that Explanation-Based Learning (EBL) can significantly accelerate problem solving. PRODIGY/EBL accelerated the PRODIGY prob- lem solver in the Blocksworld, the Stripsworld (a STRIPS-like problem space), and the Schedworld (a scheduling problem space). EBL fails to reduce PRODIGY'S problem-solving time in certain problem spaces, however. This observation is particularly tantalizing because minute modifications to problem space encoding can *The author is supported by an AT&T Bell Labs Ph.D. Scholarship. This research is sponsored in part by the De- fense Advanced Research Projects Agency (DOD), ARPA Order No. 4976, Amendment 20, under contract number F33615-87-C-1499. 9 16 MACHINELEARNING drastically alter EBL’s efficacy. For example, adding a single, carefully chosen, macro-operator to PRODIGY'S Blocksworld operator set suffices to foil PRODIGY/EBL. The macro-operator allows PRODIGY to grasp a block that is second-from-the-top of a tower. Running PRODIGY/EBL on this augmented Blocksworld (follow- ing the training procedure outlined in Minton’s the- sis [19SSa]) produced a rule set that actually slowed PRODIGY down on Minton’s test problems. A discus- sion of this experiment appears in [Etzioni, 19901. Why is PRODIGY/EBL foiled in the augmented Blocksworld ? This paper reports on a formal the- ory of problem space structure that answers this ques- tion. The failure is not due to an idiosyncrasy of PRODIGY/EBL. As explained later, the augmented Blocksworld presents a rigorous challenge to any EBL system that shares PRODIGY'S problem-solving method. Note that controlling search is easy in the aug- mented Blocksworld. Merely ignoring the added macro-operator yields Minton’s original Blocksworld. Indeed, the rules learned by PRODIGY/EBL in Minton’s Blocksworld lead to adequate performance even in the augmented Blocksworld. The added macro-operator makes learning to control search difficult. Overview Learning problem solvers such as Soar [Laird et al., 19871 and prodigy [Minton et al., 19891 attempt to re- duce problem-solving time by acquiring control rules. To choose between alternative actions, the problem solver matches the rules against its current state and adheres to the preferences expressed by the rules that matched successfully. The preferences can prune por- tions of the search space by rejecting alternatives, or by suggesting promising alternatives to try first. Utilizing control rules trades problem space search for matching. I analyze a class of problem spaces for which this tradeoff is favorable: problem spaces that yield nonrecursive explanations of problem-solving be- havior. Although I focus on PRODIGY/EBL, my conclu- sions apply to a wide range of EBL systems. Studying prodigy has enabled me to empirically test my analysis. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Since the cost of matching a control rule grows ex- ponentially with the size of that rule, acquiring con- trol rules can fail to accelerate problem solving. This problem has been dubbed the utility problem [Minton, 1988b]. The match cost of a bounded-size control rule is polynomial in the problem size, however. Thus, the utility problem could be solved by bounding the size of the control rules acquired. Unfortunately, the size of EBL’s rules is not bounded. Why is that? When EBL’s explana- tions are recursive, distinct rules are learned at ev- ery recursive depth to which the explanations are ex- panded. This is known as the generalization-to-N problem [Cheng and Carbonell, 1986, Prieditis, 1986, Shavlik and DeJong, 19851. In the Blocksworld, for ex- ample, PRODIGY/EBL learns distinct rules for clearing the bottom block of a two-block tower, a three-block tower, and so on. This is problematic in two regards. First, after learning from examples of two, three, and four block towers, PRODIGY/EBL will fail to general- ize to five-block towers; in fact, any finite rule set will fail to cover all possible Blocksworld problems. Sec- ond, the match cost of the rules formed in this manner grows exponentially with the problem size. Recursion abounds in problem spaces, even ones as simple as the Blocksworld. How is PRODIGY/EBL able to acquire effective control knowledge then? The an- swer is: PRODIGY/EBL relies on finding nonrecursive explanations of PRODIGY's problem solving behavior. Nonrecursive explanations provide a natural, problem- space-specific bound on rule size. The cost of matching rules based on nonrecursive explanations is polynomial in the size of the problems encountered. PRODIGY/EBL'S ability to learn from failure al- lows it to find nonrecursive explanations even when PRODIGY'S solutions are recursive. When PRODIGY'S failure paths are recursive, PRODIGY/EBL can some- times learn from success. When both success and failure can only be explained recursively, however, PRODIGY/EBL is foiled. PRODIGY/EBL'S explanations are not arbitrary proofs. The explanations mirror the structure of PRODIGY'S problem spaces. I formalize this no- tion by defining the problem space graph (PSG), a compact representation of problem space structure. PRODIGY/EBL'S explanations correspond to PSG sub- graphs. PRODIGY/EBL finds nonrecursive explanations only when the appropriate nonrecursive subgraphs are present in the PSG. The absence of such subgraphs from the augmented Blocksworld foils PRODIGY/EBL. A program that does not utilize training examples can form roughly the same rules as PRODIGY/EBL. The program, called STATIC, detects the PSG sub- graphs that correspond to nonrecursive explanations, and extracts control rules directly from the sub- graphs. STATIC matches PRODIGY/EBL'S performance in Minton’s problem spaces. This surprising result con- firms my central claim: nonrecursive problem space structure is the primary source of PRODIGY/EBL'S power. The following section shows how recursive expla- nations lead to rules whose size cannot be bounded. The subsequent section defines the PSG, and formal- izes the notion of problem space structure. I then demonstrate how EBL’s performance can be analyzed in terms of the PSG. I describe STATIC briefly, and evaluate its performance experimentally. A discussion of generalization-to-N and other related work follows. Recursive Explanations This section shows that the size of PRODIGY/EBL'S rules cannot be bounded due to recursive explana- tions. PRODIGY/EBL explains how choices made by the PRODIGY problem solver led to success, failure, or goal interaction. The explanations translate portions of PRODIGY'S problem-solving trace into logical proofs. The proofs contain domain-specific axioms that cor- respond to PRODIGY'S operators. When a trace con- tains recursive operator application, the corresponding proof is thus recursive. The depth of the recursion in the proof equals the depth of operator recursion in the trace. Distinct control rules are learned at each recur- sive depth. Moreover, larger rules are learned as the recursive depth increases. In the Blocksworld, for example, clearing a block is a recursive operation. Clearing the bottom block of an N-block tower requires N-l calls to the UNSTACK op- erator. As a result, PRODIGY/EBL forms distinct rules for the two-block tower, the three-block tower, and so on. Each rule only applies to towers of a given height. As the state size increases, and increasingly taller tow- ers are possible, more rules are necessary for guiding PRODIGY to choose UNSTACK. Recursive explanations are not unique to learning from success. Failure and goal interaction can require recursive explanations as well. As PRODIGY encounters problems which require deeper recursions, EBL will form successively larger rules. When the size of the problems is not bounded, the size of the rules learned from recursive explana- tions cannot be bounded either. In the worst case, the size of the learned rules scales linearly with the size of PRODIGY'S problems. The size of rules learned from nonrecursive explanations, in contrast, is bounded by the number of predicates and operators in the problem space. Of course, the size of nonrecursive explanations can scale up as we consider increasingly larger problem spaces. The size is bounded, however, as PRODIGY en- counters larger and larger problems in a fixed problem space. Problem Space Graphs PRODIGY/EBL'S explanations mirror the structure of PRODIGY'S problem space. Successfully clearing a block has a recursive explanation because plans that achieve the clear goal are recursive. Thus, whether ETZIONI 9 17 the size of PRODIGY/EBL’S rules is bounded depends on where recursion occurs in the problem space. I for- malize this notion using PSGs. A PSG is an AND/OR graph which represents the goal/subgoal relationships in a problem space. The PSG is independent of any state information; it is derived from the problem space definition. EBL’s explanations correspond to PSG sub- graphs. Since PSGs make recursion explicit, they fa- cilitate finding nonrecursive explanations. This section introduces PSGs, and describes their relation to EBL’s explanations. A PSG consists of disjoint subgraphs each of which is rooted in a distinct goal literal. Each subgraph is derived by symbolically back chaining on the problem space’s operators from the root. The root literal is con- nected via o&links to all the operators that achieve the literal, and each operator is connected via AND- links to its preconditions. Thus, the PSG nodes are an alternating sequence of (sub)goals and operators; the PSG edges are either AND-links or OR-links. Fig- ure 1 depicts the Blocksworld PSG subgraph rooted in (holding block). The graph is directed and acyclic. Two operators that share a precondition have AND- links to the same node, so the graph is not a tree. Figure 1: The holding PSG Subgraph. An operator achieves a goal if the operator’s effects successfully unify with the goal. This unification im- poses codesignation constraints between the arguments to the goal literal, and the operator’s variables. The operator’s preconditions are partially instantiated to reflect these constraints. For example, since the goal is (holding block), UNSTACK’S first precondition is (on block <vi>). The graph terminates in one of four cases: A leaf lit- eral (labeled gs-cycle) already appears on a path from the leaf to the root. This is known as a goal-stack cycle. A literal’s predicate (labeled recurs) recurs on a path to the root with no goal-stack cycle. No operators unify with a literal (this never happens in the Blocksworld). Finally, a literal (labeled holds) is known to be true given the current goal stack. This fact can be inferred from constraints on legal states, and the observation that literals on the goal stack are not true in the cur- rent state. For example, PRODIGY is either holding a block or its arm is empty. Hence, if the current goal is (holding block), then arm-empty must be true.’ The PSG and EBL’s Proofs The notion of representing programs (or problem spaces) as graphs is well-known in computer science (see, for example, [Kowalski, 19741). It is surprising to note, however, that PRODIGY/EBL’S proofs correspond to PSG subgraphs. PRODIGY/EBL’S failure proofs, for example, have the following flavor: an operator cannot be executed be- cause one of its preconditions cannot be achieved. A precondition cannot be achieved because all of the op- erators that could potentially achieve it cannot be ex- ecuted and so on. Each proof “explains” a failure by an alternating series of existentially and universally quantified statements about the relevant preconditions and operators. Success proofs have the same nature, but the quantifiers are reversed. These alternating se- quences correspond to the alternating sequences of op- erator and precondition nodes in the PSG. For example, UNSTACK fails because one of its pre- conditions, (on block <vi>), cannot be achieved in the context of (holding block). on cannot be achieved because all of the relevant operators (STACK is the only one) cannot be executed. STACK cannot be executed because one of its preconditions, (holding block), results in a goal-stack cycle. This proof mir- rors the subgraph in Figure 2. The example illus- trates the correspondence between PSG subgraphs and PRODIGY/EBL’s explanations. A formal exposition of this correspondence appears in [Etzioni, 19901. Figure 2: The Failure Subgraph for UNSTACK. Recursion in the PSG occurs at the nodes labeled recurs. An explanation is recursive only if one of the nodes in its corresponding PSG subgraph is labeled re- curs. Thus, the PSG provides an easy means of avoid- ing recursive proofs. The only source of recursion in the holding PSG is the application of UNSTACK to achieve clear. Prov- ing that an operator can achieve (holding block) re- quires demonstrating that block can be cleared-a re- cursive proof. Hence, in the Blocksworld, learning from ‘This statement and the PSG’s depiction are slightly simplified. Since the holding goal is satisfied only when a particular block is held, (arm-empty) will be false when PRODIGY is grasping a different block. Expanding the (arm-empty) node one step further, however, reaches the precondition (holding <v2>) which is guaranteed to be true in this context. 9 18 MACHINE LEARNING success results in recursive explanations and overly- specific rules. Proving that an operator will fail to achieve holding, however, does not require mentioning clear at all. PICK-UP fails if (on-table block) is not true; UNSTACK fails if (on block <vi>) is not true. As the PSG indicates, a goal-stack cycle results in either case. This occurs in Blocksworld problems of any size. Thus, EBL is able to form general rules by analyzing failures. In fact, five failure proofs yield all the con- trol rules necessary to make appropriate operator and bindings choices. The failure proofs are nonrecursive, yielding rules that are compact, general, and cheap-to- match. The Blocksworld example illustrates an important point. The nature of PRODIGY/EBL'S rules depends both on the problem space and on the target concept employed to acquire the rules. Proofs based on dis- tinct target concepts pick out distinct PSG subgraphs. In the example, the success subgraphs are recursive whereas the failure subgraphs are not. This obser- vation suggests a criterion for choosing which target concept to utilize in learning control knowledge: learn from the target concept that yields a nonrecursive proof. STATIC, described in the following section, employs this criterion to choose which control rules to form. PRODIGY/EBL does not employ this criterion. In the case of holding, for example, it learns from both success and failure. PRODIGY/EBL relies on its utility analysis mechanism to weed out ineffective rules. Predicting EBL’s Performance In the Blocksworld, nonrecursive explanations can be found for most problem-solving phenomena. When ex- plaining the success of an operator is recursive, ex- plaining the failure of its sibling operators is not. Consequently, given a sufficient number of examples, PRODIGY/EBL is able to accelerate PRODIGY signifi- cantly on Blocksworld problems. In the augmented Blocksworld, by way of contrast, recursion occurs both on the route to failure and to success. Consider, for example, choosing UNSTACK to achieve the goal (holding block) when the block is on the table. This path is doomed to failure in both Blocksworlds. In the Blocksworld, the failure can be explained nonrecursively since trying to achieve on leads to a goal-stack cycle immediately (Figure 2). In the augmented Blocksworld, in contrast, on can be achieved by the macro-operator added to PRODIGY'S operator set. The macro-operator allows PRODIGY to grasp the block that’s second-from-the-top of a tower. The top block lands on the block that is third-from-the- top as a side effect. Thus, PRODIGY has another means of achieving on which does not immediately cause a goal-stack cycle. Since prodigy explores the recur- sive path that begins with the macro-operator before failing, PRODIGY/EBL is forced to analyze that path in order to explain PRODIGY'S failure. Consequently, explaining the failure of UNSTACK in the augmented Blocksworld is recursive. This example illustrates how adding a macro- operator to the Blocksworld led to PRODIGY/EBL'S lackluster performance. Problem spaces that yield only recursive explanations, relative to the learner’s target concept and the problem solver’s search method, will challenge PRODIGY/EBL, Soar, and a wide range of EBL systems. Whether a problem space yields recursive or non- recursive explanations can be determined by analyz- ing the problem space’s PSG. EBL will accelerate problem solving when the PSG yields nonrecursive explanations. 2 Hence, analyzing PSGs is a powerful methodology for predicting and explaining EBL’s per- formance. I return to this idea in the conclusion of the paper. Static Analysis of PSGs Thus far I have argued that PRODIGY/EBL exploits nonrecursive proofs to extract cheap but effective con- trol rules, and that the existence of these proofs is a function of both problem space structure and PRODIGY/EBL's “prOOf strategies” or target concepts. Furthermore, I have shown that nonrecursive proofs correspond to nonrecursive PSG subgraphs. It follows that we can extract effective control rules directly from the PSG. To test this prediction I wrote the STATIC program which forms control rules by ap- plying a select subset of PRODIGY/EBL'S proof strate- gies directly to the PSG. Given a problem space en- coded as a set of operators and a set of constraints on legal states, STATIC constructs the PSG corresponding to that problem space. The PSG subgraph in Fig- ure 1 depicts an instance of STATIC's PSG data struc- ture. STATIC embarks on a depth-first search for non- recursive PSG subgraphs, and extracts control rules from the nonrecursive subgraphs it finds. STATIC only forms control rules when the nonrecursive learning cri- terion, articulated earlier, is met. No examples, rule compression, or utility analysis are used. A sketch of STATIC'S algorithm for analyzing failure appears in Ta- ble 1. STATIC'S algorithm for analyzing success is anal- ogous. To illustrate the algorithm’s execution consider the failure subgraph in Figure 2. STATIC computes the fc, or failure condition, and label fields of each node in postorder. STACK, at the right of the subgraph, is labeled failure, and its fc is ogs((holding block)). That is, sTAcI<(block,<vl>) will fail when (holding block) is on PRODIGY'S goal stack. The fc of (on block <vi>) is the same. UNSTACK'S only failed pre- condition is (on block <vi>). UNSTACK is labeled failure and its fc is ogs( (holding block)) Al(on 20f course, in cases where different bounds on the cost of matching EBL’s rules can be enforced, EBL will accelerate problem solving as well. ETZIONI 919 Input: operator set + constraints on legal states. Output: Operator rejection rules. ;;; ops(lit) refers to the operators that achieve lit. ;;; fc(z) refers to the conditions under which I fails. Main loop: for lit in goal-lits do Create PSG subgraph rooted in lit (e.g., Figure 1). for o in ops(lit) do LABEL-OP(o). Find operators labeled failure and form rejection rules whose antecedents are the operators’ fcs. ;;;failure-labels: {failure, gs-cycle, unachievable}. ;;;Additional labels: {success, holds, recurs}. ;;; p E fail-precs(o) iff p E ptecs(o) A label(p) E failure-labels. ;;; ogs(p) is true when p is on prodigy’s goal-stack. procedure LABEL-OP(o) for unlabeled lit in precs(o) do LABEL-LIT(lit). if Tempty(fail-precs(o)) then {label(o) + failure; if 3p E fail-precs(o) s.t. label(p)=gs-cycle then fc(o) c ogs(p). else for p in fail-precs(o) do fc(o) c fc(o) V(fc(p) A up).} else if 3p E precs(o) s.t. label(p)=recurs then label(o) + recurs. STATIC matches PRODIGY/EBL’S performance in Minton’s problem spaces as shown in Figure 3. The figure depicts cumulative running times for PRODIGY given STATIC’S rules, PRODIGY/EBL’S rules, and rules written by human experts. EBL’s rules, the human rules, the randomly generated problem sets, and the cumulative graphs format are taken from Minton’s ex- periments. The time to solve each problem was lim- ited to 150 CPU seconds. Several Schedworld prob- lems could not be solved within this time limit using one or more of the rule sets. All such problems were excluded from the Schedworld graphs. STATIC out- performed PRODIGY/EBL slightly in all three problem spaces. However, all the rule sets accelerated PRODIGY significantly. Nc------#c Prodigy+EBL rules. n Prodigy+STATIC rules. Q- - -0 Prodigy+human rules. else label(o) + success. ;;;LABEL-LIT(lit) is never called when ops(lit)=NIL. ;;;o E fail-ops(lit) iff o E ops(Zit) A label(o) = failure. procedure LABEL-LIT(lit) for o in ops(lit) do LABEL-OP(o). if 30 E ops(Zit) s.t. label(o)=success then label(lit) + success. else if 30 E ops(Zit) s.t. label(o)=recurs then label(lit) c recurs. else {label(lit) + failure; for o in fail-ops(lit) do fc(lit) t- fc(lit) A fc(o).} 160 140 Blocksworld. 120 100 80 60 40 20 0 0 400 350 Stripsworld. .** Table 1: STATIC’S algorithm for analyzing failure.3 block <vi>). Thus, STATIC forms a rule that rejects UNSTACK when PRODIGY’S goal is (holding block) and (on block <vi>) is false. An analogous rule re- jects PICK-UP when (on-table block) is false. Since both UNSTACK and PICK-UP require achieving (clear block), a precondition that is achieved recursively, no rules are learned from success. To acquire goal-ordering rules STATIC considers all possible goal pairs. For each pair, STATIC checks whether achieving one goal necessarily clobbers the other goal. If so, STATIC tells PRODIGY to achieve the clobbering goal first. The clobbering can be avoided in this manner. For example, achieving (on block1 block2) clobbers (holding block3) because (holding blockl) is a necessary precondition of (on block1 block2) and only one block can be held at any giVen time. COnSeqUently, STATIC infOrmS PRODIGY that on should be achieved before holding. Schop- pers [Schoppers, 19891 reports on a related technique for detecting goal conflicts. See [Etzioni, 19901 for a comparison, and a complete discussion of STATIC. 400 350 E Schedworld. 300 EBL: 8 Unsolved. Number of Problems STATIC’S Performance in the Blocksworld, the Stripsworld, and the Schedworld. 3Tlie V, A operators are not applied to their arguments. Since STATIC is biased to only form rules based on Thus, logical formulae are incrementally constructed by the nonrecursive PSG subgraphs, it does not necessarily above procedures. Treatment of failures due to inconsistent form a superset of PRODIGY/EBL’S rules. On Minton’s variable bindings is omitted for brevity. problem spaces, for example, STATIC acquired only 920 MACHINE LEARNING one rule based on analyzing successful paths whereas PRODIGY/EBL formed thirteen. STATIC does rely on “success rules” in other problem spaces, however. PRODIGY/EBL'S rule sets contained a variety of overly- specific rules that STATIC did not form. The overly- specific rules were formed when PRODIGY/EBL retained features of its training examples, such as recursion depth, unnecessarily. Finally, STATIC formed useful rules that PRODIGY/EBL missed, when PRODIGY/EBL did not encounter the requisite examples in its training sequences. Prieditis [1988] and van Harmelen & Bundy [1988] have pointed to the affinity between partial evalua- tion and EBL. Indeed, STATIC constructs the PSG by partially evaluating PRODIGY'S problem space defini- tion. However, the control rules acquired modify the order in which PRODIGY considers operators and sub- goals. These reordering transformations are not part of the usual arsenal of partial evaluators. Thus, STATIC and EBL’s impact on PRODIGY is more appropriately viewed as program transformation. Caveats STATIC will not match PRODIGY/EBL'S performance in every case. PRODIGY/EBL can exploit the distribution of problems encountered by PRODIGY whereas STATIC cannot. STATIC is particularly sensitive to the con- straints on legal states that define the PSG. If some of the constraints are omitted, STATIC will analyze vari- ous impossible paths and form a host of unnecessary rules. Finally, STATIC only utilizes a select subset of PRODIGY/EBL'S proof strategies. For example, STATIC only searches for pairwise goal interactions, and will overlook more complex ones. Although learning from complex goal interactions can be useful, analyzing such interactions often leads PRODIGY/EBL to form highly specific rules that are expensive to match. STATIC'S scope is restricted (relative to PRODIGY/EBL'S) for two reasons: to avoid potentially expensive rules, and to keep the static analysis tractable. STATIC is not meant as an alternative to EBL. A hy- brid algorithm consisting of some static preprocessing followed by EBL may well prove most effective. STATIC appears in this paper merely to empirically demon- strate the utility and importance of nonrecursive PSG subgraphs for acquiring control knowledge. Related Work Formal analyses of EBL have been reported by [Cohen, 1989, Greiner and Likuski, 1989, Mahadevan et al., 1988]. None of these analyses point to nonrecursive explanations as EBL’s primary source of power. Subermanian & Feldman [1990] show that for horn- clause theories in which recursion is structural and the cost of choosing which rule to apply is bounded, learn- ing from recursive explanations is unlikely to reduce theorem-proving time. They do not consider learning from failure and goal interaction, representing problem spaces as graphs, or statically deriving nonrecursive explanations. Although a simple complexity analysis suffices to argue against learning from recursive expla- nations via EBL (the overhead of utilizing rules learned from such explanations is exponential in the depth of the recursions encountered), Subermanian & Feldman develop an elaborate cost model of horn-clause theorem proving. This detailed model is motivated by Suber- manian & Feldman’s broader project which seeks to “quantitatively estimate” the cost of inference. Remarkably, despite our focus on different EBL al- gorithms and different problem spaces, we reached sim- ilar conclusions. This provides further confirmation of the ideas in both papers. Research on generalization-to-N (e.g., [Cohen, 1988, Shavlik, 1990, Shell and Carbonell, 19891) has also identified recursion as a problem for EBL. The focus of that body of work, however, is on forming general rules based on recursive explanations. Shavlik’s program, for example, learns horn-clauses that retain recursive calls in their antecedents. Thus, a particular recur- sive depth is not captured by the antecedent. Unfor- tunately, the cost of utilizing such rules can increase exponentially with the depth to which the recursive calls are expanded at run-time. Letovsky’s RECEBG algorithm [Letovsky, 19901 is able to expand some recursive calls at compile-time without forming overly-specific rules. RECEBG ex- pands recursive calls when it can prove, using struc- tural induction, that the recursion will terminate. Conclusion Utilizing control rules trades problem space search for matching. I have analyzed a class of recursive prob- lem spaces for which this tradeoff is favorable: problem spaces that yield nonrecursive explanations of problem- solving behavior. Such explanations yield bounded- size control rules. The match cost of bounded-size control rules is polynomial in the size of the problem solver’s input. I formalized the notion of nonrecursive explana- tions in terms of the problem space graph (PSG), a compact representation of problem space structure. PRODIGY/EBL'S nonrecursive explanations correspond to nonrecursive PSG subgraphs. EBL’s performance can be analyzed using the PSG. I demonstrated the practical import of this anal- ysis via two experiments. First, I showed that PRODIGY/EBL'S performance degrades in the aug- mented Blocksworld, a problem space robbed of its nonrecursive PSG subgraphs. Second, I showed that a program that extracts nonrecursive explanations di- rectly from the PSG matches PRODIGY/EBL'S perfor- mance on Minton’s problem spaces. Both experiments lend credence to the claim that PRODIGY/EBL'S pri- mary source of power is nonrecursive problem space structure. The theory developed in this paper addresses the ETZIONI 921 questions posed at the outset. PRODIGY/EBL'S effi- cacy in “real-world domains” depends on the struc- ture of their PSGs. Its success will scale to consid- erably larger and more complex domains whose en- codings yield the appropriate nonrecursive PSG sub- graphs. Minor modifications to the problem space’s representation can result in major changes to its PSG, however. Consequently, PRODIGY/EBL'S performance can vary as seemingly minor changes are made to the problem space representation. Analyzing problem spaces in terms of PSG structure enables us to under- stand this behavior. The problem studied in this paper transcends PRODIGY and EBL. Currently, most learning pro- grams are halted after relatively short running times (compared with a human’s life-time of learning) lest they swamp their performance systems with massive amounts of knowledge. Any system that accumulates knowledge over time must come to terms with the cost of utilizing that knowledge. Thus, it is not sufficient to have a powerful learning algorithm. The algorithm must be appropriately embedded in a performance sys- tem. This raises a host of challenging technical ques- tions that research on memory organization, selective learning, and bounded match cost has to address. My work is an instance of such research. Acknowledgments I would like to thank William Cohen, Scott Dietzen, Haym Hirsh, Daniel Kahn, Jack Mostow, David Steier, Prasad Tadepalli, and Ralil Valdds-Perez for comments on previous drafts. The following made invaluable contribu- tions to the ideas herein: Craig Knoblock, Stan Letovsky, Tom Mitchell, Steve Minton, and Paul Rosenbloom. Spe- cial thanks go to Steve Minton-whose thesis work made studying PRODIGY/EBL possible. References [Bobrow, 19841 Daniel G. Bobrow. Retrospectives: A note from the editor. Artificial Intelligence, 23, 1984. [Cheng and Carbonell, 1986] P. Cheng and J. G. Car- bonell. The FERMI system: Inducing iterative macro- operators from experience. In Proceedings of the Fifth National Conference on Artificial Intelligence, pages 490-495, 1986. [Cohen, 19881 William W. Cohen. Generalizing number and learning from multiple examples in explanation based learning. In Proceedings of the Fifth International Conference on Machine Learning, pages 256-269, 1988. [Cohen, 19891 William W. Cohen. Solution path caching mechanisms which proveably improve performance. Technical Report DCS-TR-254, Rutgers University, 1989. [Etzioni, 19901 Oren Etzioni. A Structural Theory of Search Control. PhD thesis, Carnegie Mellon University, 1990. In preparation. [Greiner and Likuski, 19891 Russell Greiner and Joseph Likuski. Incorporating redundant learned rules: A pre- liminary formal analysis of EBL. In Proceedings of the Eleventh International Joint Conference on Artificial In- telligence, 1989. [Kowalski, 19741 Robert A. Kowalski. A proof procedure using connection graphs. Journal of the ACM, 22:572- 595, 1974. [Laird et al., 19871 J. E. Laird, A. Newell, and P. S. Rosen- bloom. Soar: An architecture for general intelligence. Artificial Intelligence, 33:1-64, 1987. [Letovsky, 19901 Stanley Letovsky. Operationality criteria for recursive predicates. In Proceedings of the Eighth National Conference on Artificial Intelligence, 1990. [Mahadevan et al., 19881 Sridhar Mahadevan, B. K. Natarajan, and Prasad Tade- palli. A framework for learning as improving problem- solving performance. In Proceedings of the AAAI Spring Symposium on Explanation-Based Learning, 1988. [Minton et al., 19891 Steven Minton, Jaime G. Carbonell, Craig A. Knoblock, Daniel R. Kuokka, Oren Etzioni, and Yolanda Gil. Explanation-based learning: A problem- solving perspective. Artificial Intelligence, 40:63-118, 1989. Available as techincd report CMU-CS-89-103. [Minton, 1988a] Steven Minton. Learning Eflective Search Control Knolwedge: An Explanation- Based Approach. PhD thesis, Carnegie Mellon University, 1988. Available as technical report CMU-CS-88-133. [Minton, 1988131 Steven Minton. Quantitative results con- cerning the utility of explanation-based learning. In Pro- ceedings of the Seventh National Conference on Artificial Intelligence. Morgan Kaufmann, 1988. [Prieditis, 19861 A. E. Prieditis. Discovery of algorithms from weak methods. In Proceedings of the international meeting on advances in learning, pages 37-52, 1986. [Prieditis, 19881 A. E. P * d’t’ rre r 1s. Environment-guided pro- gram transformation. In Proceedings of the AAAI Spring Symposium on Explanation-Based Learning, 1988. [Schoppers, 19891 Marcel Joachim Schoppers. Represen- tation and Automatic Synthesis of Reaction Plans. PhD thesis, University of Illinois at Urbana-Champaign, 1989. Available as technical report UIUCDCS-R-89-1546. [Shavlik and DeJong, 19851 Jude W. Shavlik and G. F. De- Jong. Building a computer model of classical mechanics. In Proceedings of the Seventh Annual Conference of the Cognitive Science Society, pages 351-355, 1985. [Shavlik, 19901 Jude W. Shavlik. Acquiring recursive con- cepts and iterative concepts with explanation-based learning. Machine Learning, 5(l), 1990. To appear. [Shell and Carbonell, 19891 Peter Shell and Jaime G. Car- bonell. Towards a general framework for composing dis- junctive and iterative macro-operators. In Proceedings of the Eleventh International Joint Conference on Artificial Intelligence, 1989. . [Subermanian and Feldman, 19901 Devika Subermanian and Ronen Feldman. The utility of ebl in recursive domain theories. In Proceedings of the Eighth National Conference on Artificial Intelligence, 1990. [van Harmelen and Bundy, 19881 Frank van Harmelen and Alan Bundy. Explanation-based generalisation = partial evaluation. Artificial Intelligence, 36, 1988. Research Note. 922 MACHINELEARNING
|
1990
|
162
|
918
|
Learning Abstraction Hierarchies for Problem Solving Craig A. Knoblock* School of Computer Science Carnegie Mellon University Pittsburgh, PA 15213 cak@cs.cmu.edu Abstract The use of abstraction in problem solving is an effective approach to reducing search, but finding good abstractions is a difficult problem, even for people. This paper identifies a criterion for se- lecting useful abstractions, describes a tractable algorithm for generating them, and empirically demonstrates that the abstractions reduce search. The abstraction learner, called ALPINE, is inte- grated with the PRODIGY problem solver [Minton et ab., 1989b, Carbonell et al., 19901 and has been tested on large problem sets in multiple domains. Introduction Hierarchical problem solving uses abstraction to re- duce the complexity of search by dividing up a prob- lem into smaller subproblems [Korf, 1987, Knoblock, 1989131. Given a problem space and a hierarchy of abstractions, called abstraction spaces, a hierarchi- cal problem solver first solves a problem in an ab- stract space, and then uses the abstract solution to guide the search for a solution in successively more detailed spaces. The technique was first used in GPS [Newell and Simon, 19721 and has since been used in a number of problem solvers. ABSTRIPS [Sacerdoti, 19741 was the first system that attempted to auto- mate the formation of abstraction spaces, but only par- tially automated the process. Most hierarchical prob- lem solvers are simply provided with abstractions that are hand-tailored to a specific domain [Sacerdoti, 1977, Tate, 1977, Wilkins, 19841. This paper describes an abstraction learner, called ALPINE, that completely automates the formation of abstraction hierarchies. Given a problem space, which *The author is supported by an Air Force Laboratory Graduate Fellowship through the Human Resources Labo- ratory at Brooks Air Force Base. This research was spon- sored in part by the Office of Naval Research under contract number N00014-84-K-0415, and in part by the Defense Ad- vanced Research Projects Agency (DOD), ARPA Order No. 4976, Amendment 20, under contract number F33615-87- c-1499. consists of a set of operators with preconditions and ef- fects, and a problem to be solved, ALPINE reformulates this space into successively more abstract ones. Each abstraction space is an approximation of the original problem space (base space), formed by dropping lit- erals in the domain. The system determines what to abstract based on the ordered monotonicity property. This property separates out those features of the prob- lem that can be solved and then held invariant while the remaining parts of the problem are solved. Since this property depends on the problem to be solved, ALPINE produces abstraction hierarchies that are tai- lored to the individual problems. The paper is organized as follows. The next sec- tion defines the ordered monotonicity property. The third section describes the algorithm for generating ab- straction hierarchies in ALPINE. The fourth section de- scribes the use of the abstractions for hierarchical prob- lem solving, which is implemented in PRODIGY. The fifth section presents extensive empirical results that demonstrate the effectiveness of the abstractions in re- ducing search. The sixth section outlines the related work on automatically generating abstractions. The last section summarizes the contributions and sketches some directions for future work. Ordered Abstraction Hierarchies This section defines the ordered monotonicity property and describes how this property can be used as the basis for generating useful abstraction hierarchies. The ordered monotonicity property captures the idea that as an abstract solution is refined, the structure of the abstract solution should be maintained. The process of refining an abstract plan requires inserting additional steps to achieve the literals (possibly negated atomic formula) ignored at the abstract level. The property constrains this refinement process. The ordered monotonicity property of an abstrac- tion hierarchy is defined as follows. (A more formal definition of this property can be found in [Knoblock, 19901.) Ordered Monotonic Refinement: A refinement of an abstract plan that leaves the truth value of every KNOBLOCK 923 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. (Throughout the remainder of the paper ordered is used literal in an abstract space unchanged.’ to mean ordered monotonic.) An ordered hierarchy can Ordered Monotonic Hierarchy An abstraction hi- be constructed by dividing the literals that comprise a erarchy with the property that for every solvable domain into levels (abstraction spaces) such that the problem there exists an abstract solution that has a literals in a given level do not interact with any lit- sequence of ordered monotonic refinements into the erals in a more abstract level. If a solution exists it base space. Using the ordered monotonicity property, ALPINE produces problem-specific abstraction hierarchies. The standard approach to using abstraction spaces is to provide a system with a single, fixed abstraction hi- erarchy, which is then used for all problem solving in a given domain. The disadvantage of this approach is that it limits the possible abstractions in a domain since the hard parts-of one problem may be details in another problem and vice versa. Instead of attempt- ing to find a fixed abstraction hierarchy to use for all problems, ALPINE dynamically generates an abstrac- tion hierarchy that is tailored to the particular problem to be solved. The next section describes how ALPINE generates these abstraction hierarchies. will be found by searching for abstract solutions and ordered refinements of those solutions. If there is no abstract solution, the problem is unsolvable. Unfortu- nately, there is no guarantee that an ordered abstrac- tion hierarchy will reduce the overall search, since it may be necessary to backtrack to find alternative ab- stract solutions. In practice, this property provides a surprisingly good criterion for producing useful ab- straction hierarchies. Consider an example that distinguishes an ordered abstraction hierarchy from an unconstrained one. A simple machine-shop scheduling domain consists of op- erations for changing the shape, making holes, and painting parts. The operations interact in various ways. For example, changing the shape of a part also removes any holes or paint. A problem solver is given the problem of producing a black, cylindrical part with a hole drilled through it. Imagine that the problem solver uses an abstraction that ignores shape and pro- duces an abstract plan that drills the hole and paints the part black. The plan is then refined in the next ab- straction level to make the part cylindrical, but when this step is inserted in the abstract plan it changes the truth values of the literals involving both holes and paint that were achieved in the abstract space. The resulting refined plan might be: drill hole, paint black, make cylindrical, drill hole, paint black. This is a valid refinement in the sense that it achieves the goal, but not an ordered refinement because it altered the paint and hole properties, which had already been achieved in a more abstract space. The ordered mono- tonicity property requires that the operation of making the shape of a part cylindrical is placed at the same or more abstract level as the other two operators because changing the shape undoes the effects of the other op- erators. If shape were dealt with first, the problem solver would produce an abstract plan that made the part cylindrical and then insert the steps to make the hole and paint the object. ‘An ordered monotonic refinement is more restrictive than a monotonic refinement [Knoblock, 1989b] because it requires that every literal in the abstract space is left un- changed instead of just the specific literals that comprise the abstract plan. The distinction between an ordered mon- otonic hierarchy and a monotonic one is analogous. Learning Abstraction Hierarchies ALPINE is a fully implemented abstraction learner, which produces abstraction hierarchies for use in the PRODIGY problem solver. The system is given a do- main specification, which consists of the operators and axioms that define a problem space. For each problem to be solved, ALPINE selects an abstraction hierarchy and uses that hierarchy for problem solving. ALPINE forms abstraction hierarchies by grouping the literals in a domain into classes and ordering the classes. Initially, literals of the same type are placed in the same class (e.g., (SHAPE A CYLINDRICAL) and (SHAPE B RECTANGULAR) are both instances of the lit- eral type (SHAPE ob j shape)). The initial classes are further combined and then ordered based on an anal- ysis of the domain. The abstraction spaces are then formed by successively removing the literal classes from the original problem space. An abstract space does not simply involve dropping preconditions or goals; instead an abstract space is an abstract model of the original problem space, where both the operators and states are simplified. Table 1 defines the algorithm for creating a problem- specific abstraction hierarchy. The first step in the al- gorithm produces a set of constraints on the order of the literals in an abstraction hierarchy. The constraints are placed in a directed graph, where the literals form the nodes and the constraints form the edges. A con- straint in the graph indicates that some literal must be higher (in a more abstract space) or at the same level in the abstraction hierarchy as some other literal. The constraints are sufficient to guarantee that a hierar- chy built from these constraints will have the ordered monotonicity property. The algorithm for determining these constraints is described below. The second step in the procedure finds the strongly connected compo- nents and combines the literal classes within each con- nected component. Each strongly connected compo- nent contains the literals that comprise an abstraction space, and the constraints between components deter- mines a partial order of abstraction spaces. The third step in the procedure performs a topological sort of the strongly connected components to find a total ordering 924 MACHINE LEARNING of the literal classes, which forms an abstraction hierar- chy. Efficient algorithms for determining the strongly connected components and performing a topological sort can be found in [Aho et al., 19’741. Input: Domain operators and a problem to be solved. Output: An ordered hierarchy for the given problem. procedure CreateHierarchy(goal,operators): 1. Find-Constraints(goal,operators); 2. CombineStronglyXonnectedComponents(GRAPH); 3. Topological-sort(GR~PH1 Table 1: Creating an Abstraction Hierarchy Table 2 defines a recursive procedure for finding a sufficient set of constraints to guarantee the ordered monotonicity property. Lines l-4 loop through each of the literals in the goal and find the operators that can be used to achieve these literals. An operator can only be used to achieve a literal if the literal is in the primary effects of the operator, which is part of the op- erator definition. Lines 5-6 add constraints that force the other effects of those operators to be at the same or lower level in the abstraction hierarchy as the goal lit- erals. Lines 7-10 determine the preconditions of the op- erator that could be subgoaled on and add constraints that force these potential subgoals to be at the same or lower level in the hierarchy as the goal literals. Lastly, line 11 calls the procedure recursively on the potential subgoals. Input: Domain operators and a problem to be solved. Output: A sufficient set of constraints to guarantee an ordered abstraction hierarchy for the given problem. procedure FindXonstraints(goaLlits ,operators) : l.for each lit in goallits do 2. if Constraints-NotDetermined(lit,GRAPH) then 3. for each op in operators do 4. iflit in Primary-Effects(op) do { 5. for each other-lit in Effects(op) do 6. AddDirectedJZdge(lit,other-lit,GRAPH); 7. preconds t Preconditions(op); 8. subgoals t CanBe-SugoalehOn(preconds); 9. for each prec-lit in subgoals do 10. AddDirectedXdge(lit,prec-lit,GRAPH); 11. FindXonstraints(subgoals,operators) ) Table 2: Finding the Constraints on a Hierarchy The procedure for determining the potential sub- goals, Can_BsSubgoaled-On, returns only those pre- conditions that could be subgoaled on while solving the given problem. The naive approach is simply to mark every precondition that can be achieved by some oper- ator as a potential subgoal. However, this would over- constrain the final abstraction hierarchy since there are preconditions of an operator will never be subgoaled on and there are other preconditions that would not be subgoaled on in the context of achieving particular goals. Instead, ALPINE determines the subgoals based on the goal context and some simple domain axioms. This analysis is performed in a preprocessing step that only needs to be done once for a domain. When an hierarchy is created the algorithm simply looks up the potential subgoals in a table. This step is completely described in [Knoblock, 19901. When there are no abstractions for a problem the directed graph will collapse into a single node. An im- portant advantage of the problem-specific abstractions is that the algorithm will produce fewer constraints, which reduces the likelihood that the hierarchy will collapse. Consider a problem in the scheduling domain that requires making a part cylindrical, painting it black, and joining it to another part. Each of these top-level goals would generate constraints on the final abstrac- tion hierarchy. For example, a part can be made cylin- drical using the lathe operator, which has the side ef- fect of removing any paint. Thus a constraint would be generated that forces shape to be higher or at the same level in the hierarchy as painted. A part can be joined to another part by bolting the two parts to- gether, and the bolt operator has a precondition that the two parts have holes. Thus another constraint is generated that forces joined to be higher or at the same level as has-hole. This process continues un- til all the required constraints have been generated. The final directed graph for this problem is shown in Figure 1. The dotted boxes indicate the connected components and the arrows indicate the constraints. . . . . . . . . . . . . . . . . . . . . . . . . ..~ i (SHAPE obj shape): L . . . . . . . . . . . . . . . . . . . . . . . . . . 4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ..~............................................ , : (HAS-HOLE obj width orientation) : : : : : : : f (PAINTED obj covlor)- 4 (JOINED obj obj orientation) i ....................................... ............ ...... ...... .................. . : .................... : (SCHEDULED obj machine time) 3 i .. ............... ...... ............ ........ . Figure 1: Directed Graph for a Scheduling Problem Each abstraction hierarchy generated by the algo- rithm above has the ordered monotonicity property. The constraints guarantee that once the literals in a given space are achieved they cannot be undone in the process of refining the plan. This holds because the constraints force any literal that could be changed, ei- ther directly or indirectly in the process of achieving some goal, to be placed at the same or lower level in the abstraction hierarchy as the goal literal. The proof KNOBLOCK 925 that the basic algorithm produces ordered abstraction hierarchies is given in [Knoblock, 1989131. The complexity of determining the constraints, and thus the complexity of creating the problem-specific abstraction hierarchies, is O(o * n2), where o is the maximum number of operators relevant to achieving any given literal and n is the number of different types of literal in the domain. The complexity of the other steps in creating the abstraction hierarchies, combining the strongly connected components and performing the topological sort, are quadratic in the number of literal types. Thus, for reasonable values of n, it is tractable to produce problem-specific abstraction hierarchies. Hierarchical Problem Solving To plan hierarchically, a problem is first mapped into the highest level of the abstraction hierarchy. This is done by removing details from the initial and goal states to form the corresponding abstract states and removing details from the preconditions and effects of the operators to form a set of abstract operators. Next, the problem is solved in this abstract problem space. The resulting abstract plan is then mapped into suc- cessively more detailed levels by forming subproblems where each intermediate state in an abstract plan forms an intermediate goal at the next level of detail. When the problem has been refined into the base space (the original problem space), the problem is solved. If an abstract plan cannot be refined (e.g., conditions intro- duced at the current abstraction level cannot be satis- fied), then the problem solver backtracks to reformu- late the plan at a higher level of abstraction. The hierarchical problem solving is implemented in the PRODIGY architecture [Carbonell et al., 19901. PRODIGY is a means-ends analysis problem solver, which has been extended to perform the necessary hi- erarchical control and bookkeeping. The system can backtrack efficiently both across abstractions levels and within an abstraction level by maintaining the rel- evant problem-solving traces. While PRODIGY makes effective use of alpine’s abstraction spaces, they are suf- ficiently general to be used by any hierarchical problem solver that employs a state-space representation. Results ALPINE produces useful abstraction hierarchies in a number of problem domains. This section demon- strates the effectiveness of ALPINE'S abstractions in a machine-shop scheduling domain and a robot planning domain [Minton, 1988, Minton et aZ., 1989a]. These domains were originally used to evaluate explanation- based learning (EBL) in PRODIGY. A problem in the machine-shop scheduling domain involves finding a valid sequence of machining operations and scheduling the operations to produce various parts. The robot plannin domain is an extended version of the STRIPS domain ‘i Fikes and Nilsson, 19711, which includes locks, keys, and a robot that can both push and carry objects. 926 MACHINELEARNING ALPINE produces useful abstraction hierarchies in both problem domains. In the scheduling domain, the abstraction hierarchies provide an order on the op- erations that need to be performed and separate the planning of the operations from the scheduling. In the robot planning domain the movement of boxes, keys, and the robot are separated from the details. To evaluate the abstraction hierarchies produced by ALPINE, this section compares problem solving with ALPINE'S abstractions to problem solving in PRODIGY. In the scheduling domain, the use of ALPINE'S abstrac- tions is also compared to the use of search control rules generated using explanation-based learning [Minton, 19881. The systems were tested on 100-200 randomly generated problems in each domain and were allowed to run on each problem until it was solved or the 300 second CPU time limit was exceeded. Since ALPINE uses problem-specific abstraction hierarchies, the time spent creating the abstraction hierarchy for each prob- lem (between 0.5 and 3.5 seconds) was included in the cost of solving a problem. Figure 2 compares ALPINE, PRODIGY, and EBL in the scheduling domain. The graph shows the cumulative CPU time (in seconds) on all solved problems up to the given problem number. The systems were run on the 100 problems that were originally used for testing EBL, but the graph only includes the problems that could be solved by all three systems within the time limit. The number of problems that could not be solved by each system is shown in the key. Since the problems are ordered by increasing size, the cumulative time curves upward. The graph shows that ALPINE and EBL pro- duce comparable speedups, and both systems produce significant speedups over the basic problem solver. In addition, ALPINE solved 98% of the problems within the time limit, while EBL solved 94%, and PRODIGY solved only 76%. As discussed later, future work will explore the integration of abstraction and EBL. PRODIGY: 24 Unsolved EBL: 6 Unsolved ALPINE: 2 Unsolved p a / / Number of Problems Figure 2: Comparison in the Scheduling Domain Figure 3 shows an analogous graph that compares ALPINE and PRODIGY in the robot planning domain. EBL was not included in this comparison because ALPINE uses knowledge about the primary effects of the operators to produce the abstractions in this do- main, and EBL was not originally provided with this knowledge. To avoid an unfair -bias in the favor of ALPINE, both ALPINE and PRODIGY are given control knowledge to exploit the information about primary effects. -The systems were run on 200 problems, in- cluding the 100 problems used for testing EBL. As the graph shows, ALPINE performed significantly better than PRODIGY on the solvable problems, and ALPINE was able solve 99% of the problems within the time limit, while PRODIGY only solved 90%. 2 3500 a- - -Al PRODIGY: 20 Unsolved g ALPINE: 2 Unsolved w 3000 1 /I P / Number of Problems Figure 3: Comparison in the Robot Planning Domain Related Work ABSTRIPS [Sacerdoti, 19741 was one of the earliest at- tempts at automating the formation of abstraction hi- erarchies. The system was provided with an initial ab- straction hierarchy, which was used to automatically assign criticalities to the preconditions of the opera- tors: ABSTRIPS formed the abstraction levels by plac- ing those preconditions which could not be achieved by a “short plan” in a separate level. Any further refinement of-the levels came from the user-defined ab- straction hierarchy. In the ABSTRIPS'S domain, ALPINE completely automates the formation of the abstraction hierarchies and nroduces abstractions that are con- siderably more eifective at reducing search [Knoblock, 1989a]. Unruh and Rosenbloom [1989] describe a weak method implemented in SOAR that dynamically forms abstractions for look-ahead search by ignoring un- matched preconditions. The choices m&de& the-look- ahead search are stored by SOAR'S chunking mecha- nism and the chunks are then used to guide the search in the original space. This approach forms abstrac- tions based on which conditions hold during problem solving, while ALPINE forms abstractions based on the structure of the domain, PABLO [Christensen, 19901 is a hierarchical planner that also forms its own abstraction hierarchies, but the system uses a completely different approach from the one described in this paper. The operators are par- tially evaluated before problem solving to determine the number of steps required to achieve any given goal. The system then solves a problem in successive ab- straction levels by first working on the parts of the problem that require the greatest number of steps. GPS did not create abstractions, but did automat- ically generate difference orderings [Eavarone, 1969, Ernst and Goldstein, 19821, which specify the order in which to work on the various goal conditions. The algorithm described in this paper is similar to the tech- niques for ordering differences, but the difference order- ing algorithm only considers the interactions between effects of operators, while the algorithm described in this paper considers the interactions between both ef- fects and preconditions of operators. Mostow and Prieditis [1989] identify a set of trans- formations that can be used to form admissible heuris- tics. One of these is the drop-predicate transformation, which produces abstract problem spaces. Since the ab- stractions are formed using a brute-force generate and test procedure, the techniques described in this paper could be applied to their work. Discussion This paper described a general criterion for selecting abstraction hierarchies and presented a tractable al- gorithm for generating them. The approach has been applied to a variety of problem-solving domains and, as shown in this paper, produces abstractions that are effective at reducing search. A current limitation of ALPINE is that the gran- ularity of the abstractions is limited to the literal types in a domain. To address this problem the sys- tem has been extended to abstract specific instances of literals. Thus, instead of dropping all the liter- als of the same type, the system can drop instances of literals that can been shown not to interact with different instances of the same literal (e.g., (SHAPE A CYLINDRICAL) could be separated from (SHAPE B RECTANGULAR)). The difficulty is that the cost of form- ing these finer-grained abstraction hierarchies becomes prohibitive as the number of literal classes gets large. Future work will include developing techniques to effi- ciently generate these finer-grained hierarchies. Another promising direction for future work is the integration of ALPINE with other types of learning, such as explanation-based learning and learning by analogy [Veloso and Carbonell, 19891. Since ALPINE forms ab- stract models of the original problem space, these other types of learning can be applied within the abstract spaces. Thus, EBL could produce control knowledge KNOBLOCK 927 within an abstract space, and analogy could reuse abstract problem-solving episodes. store and Acknowledgements I am grateful to Jaime Carbonell, James Altucher, Oren Etzioni, Steve Minton, Josh Tenenberg, and Qiang Yang for their insights on the work presented in this paper. I would also like to thank Claire Bono, Dan Kahn, Alicia Perez, and Manuela Veloso for their comments on earlier drafts of this paper. References [Aho et a!., 19741 Alfred V. Aho, John E. Hopcroft, and Jeffrey D. Ullman. The Design and Analysis of Computer Algorithms. Addison-Wesley, Reading, Massachusetts, 1974. [Carbonell et ab., 19901 J aime G. Carbonell, Craig A. Knoblock, and Steven Minton. Prodigy: An inte- grated architecture for planning and learning. In Kurt VanLehn, editor, Architectures for Intelligence. Erlbaum, Hillsdale, NJ, 1990. Also Technical Report CMU-CS-89-189. [Christensen, 19901 Jens Christensen. A hierarchical planner that creates its own hieararchies. In Pro- ceedings of Eighth National Conference on Artificial Intelligence, Boston, MA, 1990. [Eavarone, 19691 Daniel S. Eavarone. A program that generates difference orderings for GPS. Technical Report SRC-69-6, Systems Research Center, Case Western Reserve University, Cleveland, OH, 1969. [Ernst and Goldstein, 19821 George W. Ernst and Michael M. Goldstein. Mechanical discovery of classes of problem-solving strategies. Journal of the Association for Computing Machinery, 29:1-23, 1982. [Fikes and Nilsson, 19711 Richard E. Fikes and Nils J. Nilsson. Strips: A new approach to the application of theorem proving to problem solving. Artificial Intelligence, 2:189-208, 1971. [Knoblock, 1989a] Craig A. Knoblock. Learning hier- archies of abstraction spaces. In Proceedings of the Sixth International Workshop on Machine Learning, pages 241-245, Los Altos, CA, 1989. Morgan Kauf- Mann. [Knoblock, 1989101 Craig A. Knoblock. A theory of abstraction for hierarchical planning. In Paul Benjamin, editor, Proceedings of the Workshop on Change of Representation and Inductive Bias. Kluwer, Boston, MA, 1989. [Knoblock, 19901 Craig A. Knoblock. Learning and Using Abstractions for Hierarchical Problem Solving. PhD thesis, School of Computer Science, Carnegie Mellon University, Pittsburgh, PA, 1990. In prepa- ration. [Korf, 19871 Richard E. Korf. Planning as search: A quantitative approach. Artificial Intelligence, 33( 1):65-88, 1987. [Minton et al., 1989a] Steven Minton, Jaime G. Car- bonell, Craig A. Knoblock, Daniel R. Kuokka, Oren Etzioni, and Yolanda Gil. Explanation-based learn- ing: A problem solving perspective. Artificial Intel- ligence, 40(1-3):63-l 18, 1989. [Minton et al., 1989b] Steven Minton, Craig A. Knoblock, Daniel R. Kuokka, Yolanda Gil, Robert L. Joseph, and Jaime G. Carbonell. PRODIGY 2.0: The manual and tutorial. Technical Report CMU- CS-89-146, School of Computer Science, Carnegie Mellon University, Pittsburgh, PA, May 1989. [Minton, 19881 Steven Minton. Learning Effective Search Control Knowledge: An Explanation-Based Approach. PhD thesis, Computer Science Depart- ment, Carnegie Mellon University, Pittsburgh, PA, 1988. [Mostow and Prieditis, 19891 Jack Mostow and Ar- mand E. Prieditis. Discovering admissible heuristics by abstracting and optimizing: A transformational approach. In Proceedings of the Eleventh Interna- tional Joint Conference on Artificial Intelligence, pages 701-707, San Mateo, CA, 1989. Morgan Kauf- mann. [Newell and Simon, 19721 Allen Newell and Herbert A. Simon. Human Problem Solving. Prentice-Hall, Englewood Cliffs, NJ, 1972. [Sacerdoti, 19741 Earl D. Sacerdoti. Planning in a hi- erarchy of abstraction spaces. Artificial Intelligence, 5(2):115-135, 1974. [Sacerdoti, 19771 Earl D. Sacerdoti. A Structure for Plans and Behavior. American Elsevier, New York, 1977. [Tate, 19771 Austin Tate. Generating project net- works. In Proceedings of the Fifth International Joint Conference on Artificial Intelligence, pages 888-900, 1977. [Unruh and Rosenbloom, 19891 Amy Unruh and Paul S. Rosenbloom. Abstraction in problem solving and learning. In Proceedings of th.e Eleventh Interna- tional Joint Conference on Artificial Intelligence, pages 681-687, San Mateo, CA, 1989. Morgan Kauf- mann. [Veloso and Carbonell, 19891 M. M. Veloso and J. G. Carbonell. Learning analogies by analogy - the closed loop of memory organization and problem solving. In Proceedings of the Second Workshop on Case-Bused Reasoning, pages 153-159, Los Altos, CA, May 1989. Morgan Kaufmann. [Wilkins, 19841 David E. Wilkins. Domain-indepen- dent planning: Representation and plan generation. Artificial Intelligence, 22(3):269-301, 1984. 928 MACHINE LEARNING
|
1990
|
163
|
919
|
Extending EBG to Term-Rewriting Systems Philip Laird Evan Gamble (LAIRII@FWJT~.MW.WWLGO~) (GAMBLE@PL~T~.ARc.NAsA.Gov) AI Research Branch Sterling Federal Systems, Inc. NASA Ames Research Center Moffett Field, CA 94035 Abstract We show that the familiar explanation-based general- ization (EBG) procedure is applicable to a large fam- ily of programming languages, including three families of importance to AI: logic programming (such as Pro- log); lambda calculus (such as LISP); and combinator languages (such as FP). The main application of this re- sult is to extend the algorithm to domains for which pred- icate calculus is a poor representation. In addition, many issues in analytical learning become clearer and easier to reason about. Introduction Analytical learning, including the various met hods collec- tively known as explanation-based learning (EBL), is mo- tivated by the observation that much of human learning derives from studying a very small set of examples (“ex- planations”) in the context of a large knowledge store. EBL algorithms may be partitioned into those that use explanatory examples to modify a deficient theory and those that rework a complete and correct theory into a more useful form. Among the latter are algorithms, such as the familiar EBG algorithm (Mitchell et al. 86, Kedar & McCarty ‘87) that learn from success, and other al- gorithms (e.g., (Minton 88, Mostow & Bhatnagar 87) ) that learn from failure. The EBG algorithm is the focus of this paper. The EBG algorithm changes certain constants in the explanation to variables in such a way that similar in- stances may then be solved in one step without having to repeat the search for a solution. For example, given this simple logic program for integer addition: PJUS(O, 21, Xl) a--hue. plus(+2),x3,+4)) I- P~us(x2,x3,x4)* and the instance plus(s(O),O, s(O)), the EBG algorithm finds the new rule, pZus(s(O), Z, s(z)) : - true by analyz- ing the proof and changing certain occurrences of the constant 0 to a variable Z. Subsequently, the new in- stance pZus(s(O), s(O), s(s(0))) can be solved in one step using this new rule, instead of the two steps required by the original program, provided the program can decide quickly that this new rule is the appropriate one for solv- ing this new instance. The results from applying this technique have been a bit disappointing. Among the reasons identified in the literature are the following: The generalizations tend to be rather weak. Indeed, the longer the proof-and thus the more information in the example-the fewer new examples are covered by the generalization. Many reasonable generalizations (such as the rule phs(z, s(O), s(z)) : - true in the above example) are not available using this method alone. Over time, as more rules are derived, simple schemes for incorporating these rules into the program even- tually degrade the performance of the program, in- stead of improving it. The program spends most of its time finding the appropriate rule. Other issues also need to be raised. While EBG is often described as a “domain-independent technique for gener- alizing explanations” (Mooney, 88) , it is not a language- independent technique. Virtually all variants of the algo- rithm depend on a first-order logical language, in which terms can be replaced by variables to obtain a more gen- eral rule. Even when the algorithm is coded in, say, Lisp, one typically represents the rules in predicate calculus and simulates a first-order theorem prover. Yet, on oc- casion, researchers (e.g., Mitchell, Utgoff, & Banerji 83, Mooney 88) have encountered domains where predicate calculus is at best an awkward representation for the es- sential domain properties. In these situations the ability to use another language and still be able to apply ana- lytical learning algorithms would be highly desirable. One may ask whether EBG is just a syntactical trick that depends on logic for its existence. If so, its status LAIRDANDGAMBLE 929 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. as a bona fide learning method is dubious: important learning phenomena ought not to depend upon a partic- ular programming language. If EBG is not dependent on logic, then how do we port EBG directly to other lan- guages? For example, in a functional language the plus program might be coded: pkus x y := if x = 0 then y else s (plus z y), where x = s(z). Given the input pIus s(0) 0, this program computes s(0) as output. Surely an EBG algorithm for this language should be able to generalize this example such that the input pZus s(0) y produces s(y), without having to revert to a logical representation. Also, while the formal foundations of EBL have been studied (e.g., (Greiner 89, Natarajan 88, Natarajan 89, Cohen 89) ), most of this work has abstracted away the generalization process in order to model the benefits of path compression. (See, however, (Bhatnagar 88) and (Dietzen & Pfenning 89) .) This is reasonable, since one might assume that the basic EBG algorithm is well un- derstood by now. But such is not the case: presenta- tions of the algorithm in the literature have generally been informal, and occasionally inaccurate. The ele- gant PROLOG-EBG algorithm (Kedar & McCarty 87) is a case in point; in certain cases it will overgeneralize. (As an example, given the instance pZus(O,O, 0) and the pZus program above, it produces the overgeneralization pZus(z, y, z) : - true.) In the past two years several pa- pers, a thesis, and even a textbook have reproduced this algorithm without noticing or correcting the problem. This paper addresses two issues: Language: W e s ow h that the EBG algorithm is a special case of an algorithm that we call AL-l. We present this algorithm formally in a framework based on term-rewriting systems (TRS), a formal- ism that includes, as special cases, logic program- ming, lambda calculus, applicative languages, and other languages, showing that EBG is more than a logic programming hack. Correctness: In this formalism, the correctness, power, and limitations of the algorithm can be care- fully studied. Proofs then apply irnrnediately to each of the languages mentioned above. In addition, many difficult issues (operationality, utility, etc.) become clearer because the TRS formalism sep- arates the generalization aspects of the problem from other, language dependent, issues. A more complete presentation of the ideas in this paper can be found in a report (Laird & Gamble 90) available from the authors. Goal ---) Formula 1 Conjunction 1 true Goal + gi (for ;>l) Formula -+ plus ( Term , Term, Term ) Conjunction --, ( A Goal Goal) Term -+ Term1 1 0 Term + xi (for &zl) Term1 + s ( Term) Figure 1: Grammar for a logic-programming language. Typed-Term Languages We first define a family of typed languages. Like many programming languages, the syntax is described by a context-free grammar. We constrain the form of these grammars so as to include certain features, mainly types and variables, that allow us to generalize expressions. A typed-term grammar (ttg) is an unambiguous context-free grammar with the following characteristics: The set of nonterminal symbols is divided into two subsets: a set of general types, denoted {GO, G1,. . .}, and a set of special types, denoted {Sl, S2, . . .}. Go is the “start” symbol for the grammar. The set of terminal symbols is likewise divided into subsets. There is a finite set of constants, { Cl,C2,*.., c ) and for each general type Gi there p , is a countable set of variabzes, denoted {xi, xi,. . .}. The set of productions satisfies three conditions: (1) For any nonterminal N, the set of sentences gener- ated by N is nonempty and does not contain the empty string. (2) For any nonterminal N, the right- hand sides of all its productions (N --) (~1.. .akN) have the same length ICN. For general types this length is one. (3) For each general type Gi and each variable ~3 of that type, there is a production G’ ---) xf . No other productions contain variables. The ttg is used to define, not the programs in the lan- guage, but the states of the computationab model to which that language applies. In the case of logic programs, the states are sets of goals to be satisfied. For lambda cal- culus, states are lambda abstractions and applications to be reduced. Example 1. The productions in Figure 1 generate the class of goals for the logic-programming language used in the phs example above. Instead of G” and Si we choose more mnemonic names for the nonterminals. Goal and Term are general types whose respective variables are g; and za. Formula, Conjunction, and Term1 are special types. Goal is the start symbol. The constant sym- bols are true, plus, s, 0, A, comma, and two parenthe- ses. Examples of goals generated by this language are 930 MACHINE LEAFWING Expression -+ Expression 3 Expression + Expression + ExpressQonl + Expression1 + Lambda-param 3 Expression1 Lambda-param plus 1 succ 1 zero? 1 second xj (for i 2 1) X Lambda-param. Expression ( Expression Expression ) vj (for i 2 1) Figure 2: Grammar for a lambda-calculus language. pZu+(O), x17,0) and 911. A conjunctive goal (with two or more subgoals) is represented in this language by a conjunction, e.g., (A pZus(O,O, 0) pZzLs(s(O), 0, s(0)) ). Example 2. The productions in Figure 2 generate the class of terms of a lambda calculus-based program- ming language. This language has two general types: Expression and Lambda-param, whose respective vari- ables are labeled xi and vi. Expression is the start sym- bol. The type Lambda-param is unusual in that variables are the only strings of that type. Expression1 is a spe- cial type. The constants of the language are A, period, open-paren, close-paren, pZuus, and others whose utility will become apparent in subsequent examples. Examples of terms generated by this grammar are: pIus, x5, (plus (succ x:4)), and Xv7 . (phs (vz VT)). As with first-order terms, we define substitutions and replacements over the sentences of a typed-term gram- mar. We say that a sentence has type N if it can be generated by the grammar starting from nonterminal N. Note that a sentence may have several types. Let 7 and p be sentences of type N and Gi, respectively, and let x1 be a variable of type Gi. The substitution 8 = (p/xii is applied to 7 by simultaneously replacing each occur- rence of the variable xj in 7 by /3. Substitutions may be composed: (6 0 Q(y) = @l@(y)) ). For replacements we first need a measure of Zocation in a sentence. If 7 is a sentence of type G” it has a unique parse tree Tr , since the grammar is unambiguous. To each node in T, we assign a location as follows: the root has location 0; and the k: subtrees of a node whose location is o have locations w-0, . . ., w.(k-1). A substring 7’ of y is a subterm if it is the yield of a subtree of Tr . We also define the type of a nonleaf subtree of Tr to be the label of its root node. We shall denote the subterm of y at location w by +I. If p is a sentence of type N and y’ = r[w] is a subterm of y of type N, then the replacement ~[w t ,B] is obtained by replacing the occurrence 7’ in y at location w by /3. Example 3. In the grammar of Example 1, 7 = pZus(xr, 0, xl) is a sentence of type GoaZ and type Formula. When we apply the substitution 8 = {s(O)/xl}, the result is pZus(s(O), 0, s(O)). The subterm 0 occurs at location w = 0.0-4 in 7 with type Term The replacement $0 -0 l 4 +- 9(x2)] gives pZuus(xr, 3(x2), 51). Other properties of first-order terms extend to ttg lan- guages. Terms can be ordered by subsumption: 71 2 72 if there is a substitution 6 such that 6(yl) = 72. If we treat variants, that is, terms that differ only by renaming variables, as equivalent, subsumption is a partial order. 8 is a unifier for terms yr and 72 if @(yr) = @(y,). One can readily extend the first-order unification algorithm to compute the most general unifier 8 = mgu(+yl, 72) of two ttg terms, if they are unifiable. It can be shown that, for each general type G”, if we regard variants as equivalent, the set of sentences of type Gi with the addition of a dis- tinguished least element _L is a complete lattice partially ordered by 7. This property allows us to generalize and specialize sentences. Nondeterminist ic Term-Rewriting Systems As a computational model of typed-term languages, we adopt a class of nondetenninistic term-rewriting systems. TRS’s are an active research area of theoretical computer science (Avenhaus & Madlener 90) and have already been applied to machine learning (e.g., (Kodratoff 88, Laird 88)). Mooney (Mooney 89) has applied them specifically to analytical learning as an alternative to predicate logic. Using a TRS we are able to express our learning algo- rithms in a form applicable to many formal systems, like logic programming and lambda calculus. The sentences generated by a ttg are interpreted as states of a computation. States are transformed by rewriting steps in which one of a fixed set of rewrite rules is chosen and used to modify a subterm of the state. Non- determinism enters in two ways: in the choice of the rule and in the choice of the subterm to be rewritten. A rewrite rule CY + p is a pair of terms (CX and /3) of the same type T. The set of rules is closed under substitution: if a! 3 ,B is a rule and 8 is a substitution, then 6(o) * e(p) is a rule. A rewriting step is carried out as follows. Let y be a state and let w be a location such that +] = cr-i.e., r[w] is the string Q and has type T. Then y can be rewritten to y’ = y[w + /3]. The notation +yl a* 72 indicates that a sequence of zero or more steps transforms yr into 72. A computation is a finite sequence of state-location-rule triples, ["Il,W,~l * Pll,. - '3 [Yn,ws,~n * Pnl, [x+1,*, *I (1) LAIRDANDGAMBLE 931 where, for 1 5 i 5 n, a substitution instance of the rule The program consists of rewrite rules for succ, zero?, c~yi + /3i applied to ~yi at location wi yields yiyi+r. (* and second above, and the following rule for plus: indicates “don’t care”.) The path of the computation consists of just the locations and the rules (omitting the Plus * states). Xvr . Xv2 . (((zero? VI)O~) (succ ((plus (second ~1)) 212))). Example 4. In a logic program clauses serve as the rewrite rules, and the state is a (single or conjunctive) goal. For example, the rule plus(O,z, 2) := tme says that any instance of the term pZ&s(O, CC, CC) can be re- placed by the term true. When applied to the state (A plus(s(O), 0, s(O)) plus(O, 0,O)) at the underlined posi- tion, the result is (A-0, s(O)) true). Using the plus program to continue this computation for two more steps gives (A true true), at which point no more rules apply * Example 5. Consider a lambda-calculus language with explicit recursion (like Lisp, but unlike pure lambda cal- culus, which uses the Y combinator) in which there are two groups of rules. The first contains. all rules of the form: ((Xvi-Q) R) * [R/vi] 9, where [R/vi]& is the result of simultaneously replac- ing every free occurrence of vi in Q by R, i.e., a fl- reducti0n.l The second group-the rules comprising the actual program-is a list of name-expression pairs, f a expression, indicating that the constant f can be replaced by the given expression. For example, we can recode the plus program in lambda calculus as follows. “Zero” (0) is encoded by the expres- sion XV. v. We represent pairs [tl, tz] of objects tl and t2 as [t1, t21 = AVl l ((w t1) t2). The integer “one” is represented by [s, 01, “two” by [s, [s, 0]], etc., where s is the expression XV~.XV~.V~. The successor (succ t) of an integer t is computed by the func- tion succ j XV. [s, v] Let Xv1.Xv2.21r and Xur .X2)2.2)2 represent true and false, respectively. A predicate zero. * that tests whether an integer is zero, giving true if so and false if not, is as follows: zero? * XVI . (~11 (Au2 . Xv3 .2)2)). One can check that (zero? 0) J* true and (zero? (succ v)) ** false. We also need a predicate that returns the second mem- plus begins by applying zero? to its first argument. If the result is true, the true expression selects the second of the two arguments, ~2. If false, the result is the successor of ((plus (second ~1)) 212), with plus applied recursively. Although the lambda-calculus TRS is completely dif- ferent from the logic programming one, the semantic structures of the two pks programs are quite similar. Thus we should expect the rules learned by AL-l in the two languages to be sematically comparable. The AL-1 Algorithm The AL-l algorithm (Figure 3) takes an example compu- tation and determines the most general rewrite rule that accomplishes in one step the same sequence of rewrites. The algorithm starts with a variable 2 initialized to zp, a fresh variable representing the most general state. Within the loop the same sequence of reductions is ap- plied to 2, at the same locations, as in the original com- putation. (Recall that Ti denotes the state before the 9th rule is applied at position wi.) A problem arises if there is no subterm at the re- quired location wi in the generalization 2. The proce- dure Stretch is called so that, if necessary, 2 acquires a subterm at wi (see next paragraph). The rule (pi 3 pi is then applied to the subterm at this location. The for loop of the algorithm accumulates in the variable 8 all substitutions applied to 2 during stretching and rewrit- ing. These substitutions are the weakest conditions that the variables must satisfy in order for the computation to follow the path of the example. e(zy) is then the most general sentence to which the path can be applied, and the final value of 2 is the result of all these rewrites. The final output is the new rule: 0(~:) + 2. Suppose now that the state 2 lacks a subterm at location Oi . Stretch (Fig. 4) determines the most general state 2’ such that 2 J 2’ J Ti and 2’ has a subterm at oi. For example, if the general- ized state 2 is just the variable gy, the example Ti is (A plus(O,O,O) pZus(s(O),O, s(O))), and wi is the location of the underlined subterm, then Stretch would specialize Z to 2’ = (A g!j gi). The main prop&y of the AL-l algorithm is given by ber of a pair: the following theorem: Theorem. second 3 XVI . (VI (A02 . Xvg . ~3)). Let 71 be the initial state of the input com- putation, and let & 3 p be the rule output by the AL-l l Some renaming of parameters may also be needed to avoid algorithm. Then & is the most general state 2 y1 such variable capture (Hindley & Seldin 86) . that the sequence of rules in the input computation is 932 MACHINE LEARNING Input: An n-step computation with 7i the i’th state and (Y$ 3 fli the i’th rule. Procedure: 1. Initialize: 0 = the empty substitution. 2 = z!, a fresh variable of type Go. 2. For i = 1 up to n: 2.1 2’ := Stretch(Z, r;, wj). /* If necessary, extend 2 so that location wi exists. */ /* (See Fig. 4 and related text.) */ 2.2 e1:= rngu(Z’, 2). /* Unifier for unstretched and stretched 2 */ 2.3 02 := ~gu(Z’[w],w)* /* Unifier for CYI’ and the subterm at location w; */ 2.4 2’ :=&(Z’[oi c pi]). /* Apply an instance of the rule to 2’ at wi */ 2.5 O:=& o& 08. /* Accumulate the substitutions applied to 2 */ 2.6 Z:=Z’. /* Update 2 for the next iteration. */ 3. Output the new rule: @(CC!) + 2. Figure 3: The AL-l Algorithm. applicable; and b is the configuration that results from applying this sequence of rules to &. Example 6. With the plus program in Example 5 ((plus ES9 01) 0) rewrites to [s, 0] in about twenty steps. If this computation is given to AL-l as input, the result is the new rule: ((plus [s, 01) Z) + [s, CC]. Space does not allow us to follow the entire process, but we can trace the first few steps. In the first step of the computation, pbs is replaced by its lambda definition: . ((plus is, 01) 0) =j ((h . h. (((Zero? m)w) Q[w, 4) [s, 01) O), where Q[q, 214 stands for the subterm (succ.. .). In AL-l, 2 is initially ~1; and since this expression has no term at the location (underlined) of plus in the example, Stretch is called to specialize 2, with the result: 2’ := ((x2 x3) x*). - Now we apply the plus rule to x2, with the result: 2’ := ((XV, . Xv2 . (((zero? ‘ur)‘u2) Q[v~, ~21) xs) x4). For this first Pa= through the for loop, or:= (((x2 xs) xq)/xr), and $2 := (plus/x2). The next rewrite is a P-reduction based on the rule: &'3-~f'4-(((x71~3) v4)(x72((x73 (x74 b3))214))) x75) =+ Au4*(((x71 x75) v4)(x72((x73 (x74 x75))v4)))* The location (~2 = 0) of the rewrite already exists in the generalization, so Stretch has no effect on Z. Applying the rule to 2 gives 2’ := (Xw2. ((( as-O+’ x3)212) Q[x3, v2]) X4)- For this pass through the loop, 61 is empty, and 02:= (Vl/V3,V2/V4,zero?/x71,...}. The remainder of the computation proceeds similarly. Eventually we find that [s, 0] is substituted for x3, while no further substitution for x4 is required. At the termi- nation of the for loop, 2 ends up with the value, [s, x4]. The resulting rule, therefore, is: ((plus ES, 01) x4) * [6 X41. Example 7. Let us see how the AL- 1 algorithm gener- alizes the example pluzls( s(O), 0, s( 0)) using the logic pro- gram for plus. The proof of the example has only two steps. Initialized to gr, 2 possesses the location 0 where the first rewrite occurs, so Stretch has no effect. Applying the second rule to gr gives 2' := phs(zl, 22, x3), and results in the substitution 82 := {P~++a), x2,S(tg))/gl). The second step is to apply the first rule at location 0, and again, no Stretching is required. 2 is rewritten to true, with the substitution @2:=(0/x1,53/52}. The resulting rule is: plus(s(O), 23,423)) : - true. Considering how different the lambda-calculus and logic-program computations are (22 steps vs. 2 steps) in the two examples above, the semantic similarity among the resulting rules is remarkable. LAIRDANDGAMBLE 933 Conclusions The nondeterministic TRS model has three features that enable it to extend the EBG algorithm to other lan- guages: The ability to generalize and specialize while pre- serving types. A general computational process (rewriting) com- mon to the programming languages used in AI. Nondet erminism. The use of a nondeterministic model is appropriate be- cause the algorithm learns from success, and the non- determinism assumption abstracts away all of the back- tracking search that occurs in any actual, deterministic system. Also many programming systems that are closely related when viewed as nondeterministic look very differ- ent when implemented as deterministic languages. We would lose much of our generality if we focused only on the deterministic models. To go from a nondeterminis- tic system to a deterministic one, we require a function that chooses the location and the rewrite rule to apply at each step. Adding a new rewrite rule necessitates chang- ing this function. The AL-l algorithm proposes a new rule, but leaves unanswered the question of how best to modify the choice function. By separating the process of proposing new rules from questions of utility, the formal model makes it easier to reason about such questions. Finally, in our scheme, a computation is any finite se- quence of rewrites. In particular, there is no requirement that the length of the computation be maximal, i.e., that no further rules apply to the final state in the sequence. Thus given a computation of length 5, we could apply AL-l to the entire computation, or only the first four steps, or the first three, or the last three, etc. Each of these yields a new rule that may, potentially, be used to improve the program. Which sub-computation(s) should we give to AL-1 for anaZysis? This issue is fundamental to the concept of operationality that has been a focus of much discussion (Mostow 81, Mitchell et al. 86, Keller 87). * Since AL-l generalizes over a path, it is easy to see that when a path is extended, more restrictions (6, and 02 in steps 2.2 and 2.3) apply, and the resulting rule is therefore less general. For this reason it seems reasonable to us to recommend the following strategy: in any given computation, apply AL-1 to all sub-computations with a Zeqgth of two steps. Why length two? Length one is too small: AL-l will never generalize. Lengths longer than two are compositions of two-step paths, so if a partic- ular path of length lc > 2 occurs sufficiently often, the single rule compressing that path will eventually be ob- tained, two steps at a time, by successive applications of Initialize: 2’ := 2. While 2’ has no subterm at w, 2.1 Let i;, be the longest prefix of w such that 2’ has a variable z( at 0. 2.2 Let 8 be the substitution (E&ond(yi,ti) / z{}. 2.3 2’ := 6’(2’). Return 2’. where Expand( r;, i;t ) is: In the parse tree of yi, let the production for the non- terminal N at location G be N -+ t . . . Ch. Initialize Pi := empty-string for all i, 0 5 i < k - 1. For each i from 0 to k - 1: Case: 2.1 <i is a constant C: Pi := C. 2.2 <i is a general type G’ or a variable xg: Pi := xx, where x’, is a fresh variable unused in any expres- sion so far in this or any calling routine. 2.3 Ci is any other nonterminal: Pi := Expand(ri,ti . i). Return the string PO l . . . . Pk-1. Figure 4: The routine Stret&( Z, ri, wi). AL-l. It would be worthwhile to evaluate this conjecture theoretically or experimentally. Acknowledgments Helpful discussions with Peter Friedland, Smadar Kedar, Rich Keller, Steve Minton, and Masa Numao, and the support of the AI Research Branch at NASA-Ames, have all contributed significantly to this paper. References Avenhaus, J. and K. Madlener. 1990. Term rewriting and equational reasoning. In Form& Techniques in Ar- tificial Intelligence. A Sourcebook, R. Banerji, editor. Elsevier Science. Bhatnagar, N. 1988. A correctness proof of explanation-based generalization as resolution theo- rem proving. In Proceedings: AAAI Explanation-based Learning Symposium, AAAI (Spring Symposium Se- ries). Cohen, W. W. 1989. SoluGon path caching mecha- nisms which provably improve performance. Technical Report DCS-TR-254, Rutgers University. 934 MACHINE LEARNING Dietzen, S. and F. Pfenning. 1989. Higher-order and modal logic as a frameowrk for explanation-based generalization. Technical Report CMU-CS-89-160, Carnegie-Mellon University School of Computer Sci- ence. Natarajan, B. 1989. Cn learning from exercises. In Proc. 2nd Workshop on Computational Learning The- ory. Greiner, R. 1989. Towards a formal analysis of EBL. In Proc. Sixth Int. Machine Learning Workshop, Morgan Kaufmann. Hindley, J. R. and J. P. Seldin. 1986. Introduction to Combinators and Lambda-Calculus. Cambridge Uni- versity Press. Kedar-Cabelli, S. and T. McCarty. 1987 Explanation- based generalization as resolution theorem proving. In Proc. 4th International Workshop on Machine Learn- ing, 1987. Keller, R. M. 1987. Defining operationality for explanation-based learning. In Proceedings of AAAI- 87, Morgan Kauffman. Kodratoff, Y. 1988. Introduction to Machine Learning. Morgan Kaufmann, 1988. Laird, P. 1988. Learning from Good and Bad Data. Kluwer Academic. Laird, P. and E. Gamble. 1990. On Analytical Learn- ing. Technical Report RIA-90-01-17-7, NASA Ames Research Center, AI Research Branch. Minton, S. 1988. Learning eflective search control knowledge: an explanation- based approach. PhD the- sis, Carnegie Mellon University. Mitchell, T. M., P. Utgoff, and R. Banerji. 1983. Learn- ing by experimentation. In Machine Learning: An Ar- tificial Intelligence Approach, Morgan Kaufmann. Mitchell, T. M. , R. M. Keller, and S. Kedar-Cabelli 1986. Explanation-based generalization: a unifying view. Machine Learning, 1. Mooney, R. 1988. A general explanation-based learn- ing mechanism and its application to narrative under- standing. PhD thesis, University of Illinois at Urbana- Champaign. Mostow, J. 1981. Mechanical transformation of task heuristics into operationsl procedures. PhD thesis, Carnegie Mellon University. Mostow, J. and N. Bhatnagar. 1987 Failsafe - a floor planner that uses EBG to learn from its failures. In IJCAI’87 Proceedings, pages 249-255, IJCAI/Morgan Kaufmann. Natarajan, B. and P. Tadepalli. 1988. Two new frame- works for learning. In Proceedings, 5th International Machine Learning Conference, pages 402-415. LAIRDANDGAMBLE 935
|
1990
|
164
|
920
|
Operationality Criteria for Recursive Predicates Stanley Letovsky School of Computer Science Carnegie-Mellon University Pittsburgh, PA 15213 letovsky@cs.cmu.edu Abstract Current explanation-based generalization (EBG) tech- niques can perform badly when the problem being solved involves recursion. Often an infinite series of learned concepts are generated that correspond to the expansion of recursive solutions over every finite depth. Previous attempts to address the problem, such as Shavlik’s generalization-to-N EBG method, are overly reluctant to expand recursions; this reluctance can lead to inefficient rules. In this paper EBG is viewed as a program transformation technique on logic programs. Within that framework an improved operationality cri- terion for controlling the expansion of recursions is presented. This criterion prevents certain infinite and combinatorially explosive rule classes from being gen- erated, yet permits expansion in some useful circum- stances, allowing more efficient rules to be learned. Introduction Despite the promise of machine learning as a tech- nique for making it easier to get knowledge into ma- chines, the current status of EBG [Mitchell et al., 1986; Mooney and Bennett, 19861 learning techniques is such that it is often much harder to write a program which an EBG-based learning system will transform into something reasonable than it is to write that “reason- able” program directly. It is not the case that EBG systems can take any, or even most, inefficient encod- ings of a task and turn out an efficient version; rather it is sometimes the case that there exists sume encoding of a task for which an EBG system can do something reasonable. If EBG systems are to become a useful technology they must transcend this limitation. Re- cursions in the initial program or rule set supplied to an EBG system are a common cause of undesirable learned rules. For example Minton’s PRODIGY sys- tem [Minton, 19881, operating in the blocks world do- main, can learn rules for constructing towers 2 blocks high, 3 blocks, high, and so on. Etzioni [Etzioni, 19901 makes this same observation, but does not provide a solution. The problem of learning rules which are ap- plicable to similar problems regardless of their size has been called the generalization-to-N problem. [Shavlik, 936 MACHINE LEARNING 19891 has presented a modification of EBG that per- mits such rules to be learned. The change involves making the EBG algorithm more reluctant to unfold definitions. This paper presents a more general so- lution to the problem of controlling the unfolding of recursion, which was implemented in an EBG-engine called RECEBG. The issue of recursion control extends beyond the problem of simply generalizing to N, however; the work described here was motivated by a different problem involving recursion and EBG. An important technique for specifying search control knowledge to a problem solver involves providing some sort of progress met- ric to be used for evaluation of intermediate states of problem solving. Heuristic search algorithms such as A* are based on this principle. Frequently such met- rics work by counting some aspect of the state, which means they are recursively defined on the state rep- resentation. For example, in simplifying algebraic ex- pressions, the metric of expression size can be used to impose directionality on the application of a set of undirected equality rules. When search control knowl- edge is provided in this manner, it is often possible to statically evaluate the effects of the available opera- tors on the value of the metric in order to learn search control for the operators. For example, one could stat- ically determine that the equality rule X*1=X reduces expression size when used as a rewrite rule in the left- to-right direction, but not in the reverse direction. If this fact can be established in general for all applica- tions of the rule, then it is not necessary to evaluate the size of every expression before and after applica- tion of the rule in order to see if progress is being made - in effect, the evaluation of the metric is performed once ‘at compile time’ (or ‘learning time’) rather than repeatedly at run-time. 1 In order to perform such compile-time evaluation of recursive metrics, it is nec- essary to unfold recursions. In the example, one would ‘Such precomputation of parts of a program at compile- time is known as partial evaluation of a program. Several authors have recently pointed out the close relationship between partial evaluation and EBG.[van Harmelen and Bundy, 19881 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. need to count the expression sizes on the left and right hand sides of the rewrite rule. This in turn requires un- folding the definition of the expression sire metric over the terms on each side of the equation. Since these terms contain variables, the unfolding of the metric is only partial, and the compile time value of the met- ric is not a number but an algebraic expression. The effects of the rule on the metric can nontheless be as- sessed by reasoning about alegebraic inequalities, such as whether size(X)+2 > size(X), must be true. In summary we have the observation that unfolding of recursions must be limited in order to prevent the generation of infinite rule sets, yet it must be permitted in order to allow static evaluation of recursive proper- ties where possible. This paper presents a strategy for controlling the unfolding of recursions which attempts to satisfy both of these goals. We will see that there are limits on solving this problem in general - a strong ver- sion of it is equivalent to the halting problem - but that there are incomplete solutions of demonstrable practi- cal utility. This paper first describes a model of EBG as transformation of logic programs, then presents the modifications to the operationality criterion of EBG that control unfolding. Finally we describe the per- formance of a series of EBG-like systems on a static metric evaluation learning problem, including SOAR, a simple PROLOG-EBG engine, a PROLOG partial evaluator, and the RECEBG system presented here, and show that only the last adequately handles the problem. EBG as Transformation of PROLOG Programs In this paper we view EBG as a technique for trans- forming logic programs [Prieditis and Mostow, 1987; Hirsh, 1987; van Harmelen and Bundy, 19881, specifi- cally pure PROLOG programs. The advantages of this model of EBG are several. Pure PROLOG programs have a very simple structure that is convenient to an- alyze, yet they are expressively as or more powerful than any other formalism to which EBG techniques have been applied. A PROLOG program is simply an AND/OR tree, augmented with recursion and variable- binding mat hinery. This may be contrasted, for ex- ample, with the languages used by EBL-systems such as PRODIGY. PRODIGY specifies programs as sets of operators with first-order pre- and post-conditions, plus separate sublanguages for specifying domain the- ories and search control rules. The language is con- siderably more complex without being more expres- sively powerful. PROLOG has the additional advan- tage of being better known and more widely available, so that program transformation algorithms expressed relative to PROLOG can be more readily understood and tested by others. The relative simplicity of PROLOG as a program- ming language carries over to program transforma- tions on the language. EBG has a very simple de- scription in terms of PROLOG programs [van Harme- len and Bundy, 19881: it corresponds to repeated ap- plication of a program transformation I will call ex- pansion, which means the replacement of a subgoal by one of its definitions. 2 Since PROLOG goals may have more than one than one definition, more than one such substitution is possible. Eg. given p(X) :-q(X), q(X) :-r(X) and q(X) :-s(X), expansion of the defini- tion of q within the definition of p generates two new definitions of p: p(X) :-r(X) and p(X) :-s(X). Ex- haustive application of this transformation converts nonrecursive PROLOG programs to disjunctive nor- mal form. 3 Expansion of recursive programs can generate infinitely many expansions or simply fail to terminate. Note that this model captures only certain aspects of EBG, chiefly learning from success. In order to capture other aspects, notably learning from failure, one must consider transformations that reorder conjuncts and rules (see eg. [Etzioni, 19901). The RECEBG Operationality Criterion Within the model of EBG set forth in [Mitchell et al., 19861 and [Keller, 19861 expansion is controlled by an operutionulity criterion, which determines which pred- icates may be replaced by their definitions during the creation of learned rules. The operationality criterion controls the level of generality of the learned rules: if it is reluctant to expand, the rules produced will be more general; if too eager, the rules will be more specialized. In order to permit possible nonexpansion of recursive definitions, the basic EBG algorithm must be modified to allow for the possibility that more than one learned rule will be produced from a single example. For exam- ple, suppose that a call to a recursively defined predi- cate called subgoal occurs somewhere in the middle of a computation of a predicate called goal. If the deci- sion is made not to expand the occurrence of subgoal, then two rules may be learned: one for goal, contain- ing an unexpanded reference to subgoal, and one for subgoal, which captures the specialized aspects of the example with respect to subgoal. [Shavlik, 19891 also describes this modification. Once the algorithm has been modified in this way to permit nonexpansion of recursions, the interesting question is when to expand. The following example will be used to elucidate the operationality criterion: 2Expansion is the PROLOG analog of the X-calculus operation of P-reduction. The term unfolding is also widely used for this transformation. 3Such exhau st ve expansion in general causes an expo- i nential blow-up in program size, which is certain to increase the time to fail a goal and very likely to increase the av- erage time to succeed. This highlights the importance of the operationality criterion for controlling the application of this potentially dangerous transformation. LETOVSKY 937 goal(X) :- . . . ,getlist(Y) ,member(X,Y) ,... . member (A, [A I Rest] > . member(A, [BIRest]) :- member(A,Rest). Here a nonrecursive predicate, called goal, contains a reference to the recursively defined predicate member. The list argument to member is supplied by a second predicate called getlist whose definition is not shown. It is important to distinguish between references to a recursive predicate that appear outside of the predi- cate’s definition, such as the call to member inside goal, and recursive calls occurring within a predicate’s defi- nition, such as the call to member in the second clause of member. We will refer to the former as external culls, and the latter as internal culls. The following sections explain the different components of the operationality criterion. Rule#l: Never Expand Internal Calls Expansion of internal calls can license an infinite number of learned rules, corresponding to the in- finitely many possible finite recursion depths. In the PRODIGY blocks-world example, such expansion leads to rules for 2-towers, S-towers, etc. In the case of member, it leads to additional clauses such as member(A, [B,A/T])., member(A, [B,C,AIT])., member (A, [B, C ,D, A I Tl > . , etc. The assumption that the cost of matching such rules will remain small as their number grows without bound is questionable. Rule#l says to never do this, that such expansions will not, in general, be a win over simply keeping the compact recursive definition around. Even if recursion depth is bounded, if a predicate has several recursive clauses in its definition, expansion of internal calls can generate explosively many learned rules: in fact, BD learned rules, where B is the branching factor - i.e., number of disjuncts - and D is the depth of recur- sion. In the algebraic equation solving domain that was studied in this research, this effect led to learned rules that were formed by composing primitive alge- braic rewrite rules so that the example equation could be solved in a single rule; such rules were highly specific and very numerous. Rule#l, in conjunction with the algorithmic modifi- cations that allow multiple learned rules from a single example, is equivalent to Shavlik’s generalization to N technique. Rule#2: Well-Founded Expansion of External Calls Overly eager expansion of external calls can poten- tially reproduce all of the problems arising from ex- pansion of internal calls, by creating new defini- tions of the caller instead of the recursive predi- cate. For example we could generate the follow- ing rules for goal by expanding the calls that led to the infinite set of rules for member shown above: goal(X) :- . . . , getlist([XiT]), . . . . . goal(X) :- . . . , getlist([A,XIT]), . . . . . etc. However, if expansion of getlist were to result in a binding of the list variable Y to a list such as [a,b] , as in goal(X) :- . . . , member(X, [a,b]), . . . . then expanding the call to member would be a good thing, because the predicate could be satisfied at compile (or learning) time. (Two different rules could be generated by such an expansion, in which X would be bound in turn to a and to b.) The problem is to find a way to license those expan- sions which can perform useful work at compile time, without opening the door to infinite rule sets in the caller. The solution used in RECEBG is to allow the expansion of an external call where that expansion can be shown to be making progress. The technique is sim- ilar to the approach used in [Boyer and Moore, 19791 theorem prover to show that inductive proofs are valid; the same idea is used in proving termination of pro- grams. The key idea is that in order for the expansion to be safe, there must exist a well-founded ordering on the arguments to the recursive predicate which is de- creasing over the expansion, and which has a smallest value. 4 Finding such an ordering in general is equiv- alent to being able to show whether any program will terminate; i.e., it is equivalent to the halting problem. However, in practice a few simple heuristics are capa- ble of generating progress metrics for a broad class of common problems. For programs that manipulate list structure, a structural induction metric which counts the size of the (partially instantiated) list structure is usually sufficient to provide a well-founded ordering. Progress metrics for programs which count down to zero or count up to a fixed value can also be defined. Together these metrics are sufficient to prove termina- tion for the class of bounded loop programs, i.e., those programs that can be written using only for-loop-type iteration constructs. The structural induction metric in RECEBG counts the number of leaves in a term’s expression tree, with variables and atoms counting as one. To determine whether an external call is well-founded, RECEBG compares the size of the arguments in the call with the size of the arguments in the recursive call, i.e., the recursive call in the body of the predicate after the head has been unified with the external call. This cri- terion can easily be improved, since a recursion is well founded if any argument (or subset of the arguments) is getting smaller, which may be true even when the size of all of the arguments together is remaining con- stant - eg., list reverse. Another simple extension would be handling of counter controlled loops, where < on the natural numbers provides the well-founded ordering. Rule#2 says that external calls can be expanded if a 938 MACHINELEARNING well-founded ordering can be found on any of the argu- ments. For example, if expansion of getlist resulted in Y being bound to [A ,B , Xl , the second argument to the member call would be [A,B ,X1 before expansion, and [B ,X] in the new call resulting from the expan- sion (assuming that A was not equal to X in the exam- ple). Since [B ,X] has fewer list elements than [A ,B , Xl the expansion is making progress, and therefore can be carried out safely. Note that an external call containing only variables, such as member (X, Y) , would never be expanded under this rule, while an call containing partially instanti- ated variables, such as member(X, [Y, Z] ) , will be ex- panded. In the former case, however, expansion of other predicates that share the variable Y could special- ize it so that the call to member would become expand- able. Therefore whenever a variable is specialized by expansion during the EBG process, any unexpanded recursive calls must be rechecked to see if they have become expandable. Note also that such variable spe- cializations are determined by the code only, they are not supplied by the example. The example enters in only in the selection of control flow paths through the code. The result is that calls are expanded only to the extent warranted by the variable specializations in the learned rule, rather than the bindings in the example. Rule#3: Forced Termination Expansion The trickiest aspect of the expansion control concerns the conditions under which, when the example chose the terminal case in an external call, the learned rule should incorporate that choice rather than simply re- taining the call to the recursive predicate. Eg., suppose that during an call of member(X,Y) , the correspond- ing goal in the example was member (1, [l ,21> , which succeeds immediately. Should the call be expanded, eliminating the call to member and binding Y to [Xl in the learned rule? Unwanted expansions yield overly specific learned rules that incorporate too much detail from the example, while missed opportunities to ex- pand can lead to inefficient rules that fail to exploit the information provided by the example. The inefficiency can extend well beyond the predicate in question, since the failure to expand one predicate can cause variables to go unspecialized, leading to a failure to expand other predicates via Rule #2. Examination of numerous examples suggests that sometimes expanding the terminal case is the right thing to do, while other times retaining the call leads to better rules. The feature that distinguishes those cases where expansion is desirable is that in those cases, the terminal branch is the only logically possible choice, at the level of the learned rule rather than the example. In other words, the recursive branch(es) can be stati- cally shown to be contradictory, so that the recursive branch can never be taken. Rule#3 says that if this can be proved, then the recursive call should be replaced by its terminal case definition. Proving the applicability of Rule#3 requires stati- cally showing that the recursive definitions are inap- plicable. The example cannot be appealed to to assist in this proof, because the proof must hold across all examples. It is not possible to provide a complete ca- pability for detecting forced termination, short of pro- viding a complete theorem prover. However, numerous simple cases can be recognized, which provide consid- erable leverage in practice. The easiest refutations are obtained when the call fails to unify with the heads of the recursive clauses, as occurs in the most common PROLOG recursion cliche, where p( Cl > cannot match p( [H 1 T] ) . If no recursive clause can unify, termina- tion is forced. In addition, RECEBG contains a small set of simplification rules which can sometimes sim- plify conjuncts in the recursive clause to false after the head has been unified with external call, thus showing the inapplicability of the clause. These rules provide a poor-man’s theorem prover; adding strong typing and static type-checking machinery would be a useful ex- tension of this idea. Incompleteness in the reasoner’s ability to refute the recursive branches causes Rule#S to fail to apply in places where it ought to, resulting in inefficient, overly general learned rules. If one must err, it is better to err on the side of overly general rules, because there are usually fewer of them than overly specific rules, and the effect on performance is likely to be less bad. Evaluating RECEBG This section describes the outcome of attempts to solve a learning problem involving complex recursion unfold- ings on four different EBG-like systems: the SOAR learning architecture, a simple EBG-engine for pure PROLOG, a partial evaluator for pure PROLOG, and finally the RECEBG system that incorporates the op- erationality criterion described above. We first de- scribe the target problem. The Isolation Example PRESS [Bundy, 19831 is a program for solving alge- braic equations. It is notable in that it provides a coherent theory of search control for the application of algebraic rewrite rules. In PRESS, the rewrite rules of algebra are grouped into sets called strategies, each of which helps achieve a different subgoal of the task of solving an equation. Here we will consider only one such strategy, called Isolation, which applies to equa- tions that contain a single occurence of the unknown on the left hand side, and no occurrences on the right hand side. Isolation strips away away function appli- cations from the left hand side until the unknown is isolated. At that point the equation is solved. Isola- tion rules work by applying the inverse of the function being eliminated to both sides of the equation. Eg. A+B=C =+ A=C-B A*B=C a A=C/B sin(A) = B j A = arcsin LETOVSKY 939 PRESS’s search-control theory can be viewed as a se- quence of loops, each of which applies operators until some metric of badness is reduced to zero. In the case of the isolation strategy, the metric is depth of nesting of the unknown on the left-hand side. The problem of learning search control for an op- erator given a progress metric can be formulated as follows: form new “search-controlled” operators from the original uncontrolled operator by adding to its pre- conditions the weakest additional constraints that will guarantee that the operator application reduces the metric. For example, if the operator is the rewrite rule A+B=C 3 A=C-B and the metric is depth of nesting of the unknown on the LHS, the additional precondition would be that the unknown is a subterm of A. To do this, the learner must statically evaluate the operators’ effects on the metric’s value. Below we describe at- tempts to implement this behavior in 4 different EBG- engines. PRESS-SOAR PRESS-SOAR is an attempt to learn PRESS-style search control within SOAR. SOAR [Laird et al., 1987; Rosenbloom and Laird, 19861 is a problem-solver that incorporates an EBG-style learning component. The intent was to provide the system with algebraic oper- ators - rewrite rules - together with a metric for as- sessing progress, and have it learn the conditions under which the operators make progress in reducing the met- ric. The metric used was the depth-of-nesting metric appropriate for isolation. In PRESS-SOAR problem solving begins in a problem space containing only rules with the desired search control knowledge; this space is initially empty. When no operator is applicable, an impasse occurs, invoking a promiscuous-proposal prob- lem space. In this space any rewrite rule matching the expression can apply, but a check must be performed to verify that the rule application does in fact reduce depth of nesting before the rule will be selected. The goal was to have SOAR’s chunking machinery chunk over these impasses to yield rewrite rules which are only considered in circumstances where they reduce depth of nesting. The early versions of PRESS-SOAR which func- tioned correctly apart from chunking did not generate the desired chunks. Instead they generated radically overspecific chunks, which incorporated many of the features of the particular problem instances that SOAR had been exposed to, including such features as the entire left hand side term structure, or the particular nesting depth before and after rewriting. Developing a version of PRESS-SOAR which produced the desired chunks required careful attention to what information was computed before versus during the impasse. In general, to get desired chunks in SOAR, one must ensure that all the “compile time” computations oc- cur within an impasse. In effect the impasse/multiple problem space mechanisms in SOAR function to allow the programmer to determine which parts of compu- tation should occur “at compile time”, thereby allow- ing the programmer to define an operationality crite- rion tailored to the problem at hand. The question of how to automatically determine operationality is thus closely related to the question of how to automatically organize knowledge into separate problem spaces. PROEBG: A PROLOG EBG-Engine PROEBG is a simple EBG-engine for pure PROLOG, closely modelled on the ebg program presented in [van Harmelen and Bundy, 1988]. It builds a new disjunct for a goal by finding the set of primitives evaluated in the course of solving an example. The results contain no calls to defined functions, and tend to contain many trivial wasteful steps - eg., goals that are obviously true by inspection, regardless of how the variables are bound - that are simplified in a postprocessing step. % Apply rewrite rules that reduce the vneasure, until done. isolate(X,X=Exp,X=Exp). isolate(X,LHS=RHS,Solution) :- not(LHS=X), rule(LHS=RBS,NeuLHS=NewRHS), don(X,LHS,Don), don(X,NewLHS,NewDon), NewDon < Don, isolate(X,NewLHS=NewRHS,Solution). don(Var,Var,O). don(Var,Trm,Don) :- Trm 8.. cop I Argsl , member(Sub,Args). don(Var,Sub,D), Don is D+l. rule(A+B=C,A=C-B). rule(A+B=C,B=C-A). rule(A*B=C,A=C/B). . . . PROEBG was applied to the PROLOG version of isolate shown above. From the standpoint of the isolation search-control learning task, PROEBG was a disappointment. Its problems were very sim- ilar to those of PRESS-SOAR: unwanted incorpora- tion of specific details of the examples resulting in undergeneral chunks. A rule learned by PROEBG is essentially a composition of all the rewrite rules used in solving the example. For example, given the goal isolate(x,3*~+2=y,Result), it would learn isolate(X,A*X+B=C,X=(C-B)/A). PROPE: A PROLOG Partial Evaluator PROPE is a partial evaluator for pure PROLOG pro- grams written by the author. To the simple peval code of described in [van Harmelen and Bundy, 19881, PROPE adds the full RECEBG operationality crite- rion, plus some algebraic simplification capabilities. Note however that a partial evaluator, unlike an EBG engine, performs its analysis statically, without benefit of an example. 940 MACHINE LEARNING The problem with PROPE was that, although it was able to generate the desired rules, it generated too many learned rules, many of which corresponded to computations that could never occur. For exam- ple, when expanding the rule A+B=C + A=C-B inside isolate, it was able to perform well-founded expan- sions of the don predicate over the equations A+B=C and A=C-B. The predicate member is expanded two dif- ferent ways within the first call to don - one assumes that X is a subterm of A, the other, B. The second call to don assumes X is a subterm of A. Hence, one pair of assumptions will be impossible: isolate(X,A+B=C,New) :- . . . , don(X,B,I), don(X,A, J>, I < J,... . The problem is that PROEBG lacks some knowledge about these equations, namely, that there is only one occurence of X and that if it is a subterm of a rule variable before rewriting, it will be a subterm of that same variable after rewriting. Both domain knowledge and some reasoning ability are required to prove that the execution paths corresponding to these “impossi- ble” rules contained contradictory assumptions. Here we see the EBG advantage over partial evaluation: by focussing attention on paths that are known to be re- alizable, EBG gets the equivalent of theorem-proving power and domain-knowledge from the world cheaply. RECEBG RECEBG incorporates the inproved operationality cri- terion within an example-guided framework. In addi- tion to the modified operationality criterion described above, RECEBG incorporates a Fortuitous Unification Rude, which allows it to collapse 2 calls to the same predicate when those calls return identical results in an example. This rule allows the two calls to don in isolate to be reduced to a single call, after expansion has rendered their arguments identical. RECEBG also requires some post-EBG simplification of algebraic in- equalities in learned rules. RECEBG is able to produce the desired rules by ex- panding recursions at compile time as much as possi- ble, while restricting its attention to logically possible control-flow paths because of the example guidance. For example, the rule learned to govern the isolation of sum-terms is: isolate(X,A+B=C,New) :- don(X,A,I), isolate(X,A=C-B,New). Note that the output I of don is no longer used; the call to don now functions only to ensure that A contains X. Similar rules are learned for the other operators. Conclusions Recursive predicates are not well-handled by current EBG systems. A simple-minded, overly eager opera- tionality criterion can produce an infinite number of overly specific learned rules that incorporate too much example detail and provide very little coverage. An operationality criterion which is overly conservative about expanding recursions will avoid these infinities but be condemned to repeatedly computing at run- time results which could be computed at learning time. A partial evaluator which statically expands recursions as much as possible can generate large numbers of spu- rious learned rules due to lack of domain knowledge and/or theorem proving power. An EBG engine that opportunistically expands recursions at learning time was exhibited which avoids all of these pitfalls. Acknowledgements The author thanks Scott Dietzen, Oren Etzioni and Allen Newell for helpful comments on this manuscript. References Boyer, Robert S. and Moore, J. Strother 1979. A Compu- tational Logic. Academic Press. Bundy, Alan 1983. The Computer Modelling of Mathe- maticaZ Reasoning. Academic Press. Etzioni, Oren 1990. Why prodigy/ebl works. In Pro- ceedings of the Eighth National Conference on Artijkial Intelligence. Hirsh, Haym 1987. Explanation-based generalization in a logic-programming environment. In Proceedings of AAAI- 87. American Association for Artificial Intelligence. Keller, Richard 1986. Defining operationality for explanation-based learning. In Proceedings of AAAI-87. American Association for Artificial Intelligence. Laird, J.; Newell, A.; and Rosenbloom, P. 1987. SOAR: An architecture for general intelligence. Artificial Intelli- gence 33( l):l-64. Minton, Steve 1988. Learning Eflective Search-Control Knowledge: An Explanation-Based Approach. Ph.D. Dis- sertation, Carnegie-Mellon University. Mitchell, T.; R.Keller, ; and S.Kedar-Cabelli, 1986. Explanation-based generalization: A unifying view. Ma- chine Learning l(1). Mooney, Raymond and Bennett, Scott 1986. A domain in- dependent explanation-based generalizer. In Proceedings of AAAI-86. American Association for Artificial Intelli- gence. Prieditis, Armand and Mostow, Jack 1987. Prolearn: To- wards a prolog interpreter that learns. In Proceedings of AAAI-87. American Association for Artificial Intelligence. Rosenbloom, Paul and Laird, John 1986. Mapping Explanation-Based Generalization onto SOAR. In Pro- ceedings of AAAI-86. American Association for Artificial Intelligence. Shavlik, Jude 1989. Acquiring recursive and iterative con- cepts with explanation-based learning. Technical Report #876, University of Wisconsin, Madison. van Harmelen, Frank and Bundy, Alan 1988. Explanation- Based Generalisation = Partial Evaluation. AI Journal 36:401-412. LETOVSKY 941
|
1990
|
165
|
921
|
e Utility of in ecursive ain Theories Devika Subramanian* and Ronen Feldman Computer Science Department Cornell University Ithaca, NY 14853 Abstract We investigate the utility of explanation-based learning in recursive domain theories and examine the cost of using macro-rules in these theories. The compilation options in a recursive domain theory range from constructing partial unwindings of the recursive rules to converting recursive rules into iterative ones. We compare these options against using appropriately ordered rules in the original domain theory and demonstrate that unless we make very strong assumptions about the nature of the distribution of future problems, it is not profitable to form recursive macro-rules via explanation-based learning in these domains. Introduction The power of explanation-based learning (EBL) has been established, [TMKC86], questioned [Min88, Gre89] and subsequently re-affirmed [ShaSO] in the ma- chine learning literature. The specific objectives of this paper are to demonstrate the conditions under which it is useful to use EBL to learn macro-rules in recur- sive domain theories. In these theories the compila- tion options range from forming rules for a specific number of unwindings of a recursive rule (as gener- ated by standard EBL) to ones that generalize-to-n [Tad86,Coh88,Sha90,SC89]. We study the cost and benefits of forming fixed-length and iterative/recursive macros and compare it with the costs of using the orig- inal domain theory and subsets thereof, with appropri- ately ordered rules. The impetus for this research was provided by Shav- lik’s [ShaSO] existence proof for the utility of EBL in some recursive theories - the objective of our work is to find a generalization of his empirical results and to provide a model that will predict not only his results but also prove optimality conditions for some compi- lations of recursive theories. A secondary objective is to evaluate some of the performance metrics cho- sen by previous researchers for the evaluation of EBL [Sha90,Min88,Moo89]. For instance, one of our find- ings is that the utility metric adopted in [ShaSO] makes *This research is supported by NSF grant IRI-8902721. implicit assumptions about the distribution of future problems. We begin with a logical account of the macro forma- tion process in recursive theories with a view to under- standing the following questions. What is the space of possible macro-rules that can be learnt in a recursive domain theory ? How can we quantitatively estimate the cost of solving a class of goal formulas in a re- cursive theory with macro-rules? How should macros be indexed and used so as not to nullify the potential gains obtained by compressing chains of reasoning in the original domain theory. 7 Under what conditions is using the original domain theory with the rules prop- erly ordered, better than forming partial unwindings of a recursive domain theory? We will answer these questions in turn in the sections below relative to our cost model and then provide ex- perimental data that validate our theoretical claims. The main results are 1. 2. 3. For a special class of linear recursive theories, re- formulation into an iterative theory is the optimal compilation for any distribution of future queries. Se&unwindings of recursive rules generated by some approaches to the problem of generalization to n have a harmful effect on the overall efficiency of a domain theory for most distributions of queries. By ordering rules in the domain theory and by only generating unwindings that are not self-unwindings of recursive rules, we can get the same efficiency ad- vantages claimed by some generalization-to-n meth- ods. We prove these results using our cost model and ex- perimentally verify our results on the domain of syn- thesizing combinational circuits. Our paper is struc- tured as follows. First, we outline the compilation op- tions for recursive domain theories. Then we explain the generalization-to-n approach to compiling recursive theories. The utility problem in EBL especially for re- cursive theories is outlined in the next section along with a cost model for evaluating the various compila- tions. The main results of this paper are then stated and proved. Subsequently, we describe a series of ex- 942 MACHINE LEARNING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. periments conducted in the circuits domain that vali- date our cost model and provide evidence for our the- oretical results. We conclude with the main points of this paper and suggest directions for future work in the analysis of the utility of explanation-based learning. Compilation Options in Recursive Domain Theories In non-recursive domain theories like the cup and the suicide examples in the literature, the macro rules that can be generated are finite compositions of the given rules. The number of such macro rules is also finite. Recursive domain theories are more complicated be- cause we can form an infinite number of rule composi- tions each of which could be infinite. Correct (or de- ductively justifiable) macros in any domain theory can be generated by unwinding the rules in a domain the- ory. We will confine ourselves to Horn clause theories for this paper. This is not an unreasonable assumption, because the theories used by experimental researchers in EBL are Horn. Unwinding Rules Definition 1 An l-level unwinding of a Horn rule Head e Antecedents consists of replacing some clause c in the list Antecedents by the antecedents of another rule in the domain theory whose head unifies with c. An n+l level unwinding of a rule is obtained by a l- level unwinding of a rule that has been unwound n lev- els (n> 1). Definition 2 A l-level self-unwinding of a recursive Horn rule r: Head -+ Antecedents is a l-level unwind- ing where the clause c that is chosen for replacement in the Antecedents list unifies with Head of the rule r. An n+i level self-unwinding is defined in the same way that n+l level unwindings are. We can specialize an unwound rule by substituting valid expressions for variables in the rule. The set of all macro rules that EBL can learn in a Horn theory is the closure of that theory under the unwinding and substitution operations. Consider the non-linear recursive domain theory about kinship. In this theory, x, y and z are variables; Joe and Bob are constants. I. ancestor(x, y) -+ futher(x, y) 2. ancestor(x, y) t- ancestor(x, z) A ancestor(z, y) 3. f ather( Joe, Bob) Assume that all ground facts in our theory are father facts. One 2-level unwinding of rule 2 is the rule for grandfather shown below. 4. ancestor(x, y) e father(x, z) A father(z, y) A self-unwinding of rule 2 is the following 5. ancestor(x, y) -k ancestor(x, xl)Aancestor(xl, z) A ancestor(z, y) EBL methods pick rule unwindings and specializa- tions directed by a training example. They compress chains of reasoning in a domain theory: the cost of looking for an appropriate rule to solve an antecedent of a given goal or subgoal (paid once during the cre- ation of the proof of the training instance) is eliminated by in-line expansion of that antecedent by the body of a rule that concludes it. If there is more than one rule that concludes a given clause, then EBL methods make the inductive generalization from a single train- ing instance that the rule used for solving the training example is the preferred rule for future goals. Consider the recursive theory below that describes how expressions in propositional logic can be imple- mented as combinational circuits. This is part of a domain theory described in [Sha90]. Imp(x,y) stands for 2 is implemented by y. In the theory below, 2, y, a and b are variables. WC refers to the wire C. The Ci’s are constants. We will assume that wz unifies with wCi with a: being bound to Cr. Rule SI. states that a wire is its own implementation. A typical goal that is ;c$ved by this theory is Imp(~((~wC~v~wC~)v~wC~) . sl . Imp(wx, wx) s2. ImP(+x), Y) t- Imp@, Y) s3. Imp(l(xvy), aAb) e Imp(~x, a) A Imp(ly, b) s4. Imp(l(x A y), aNandb) X= Imp(x, a) A Imp(y, b) Note that this theory is rather different from the kin- ship theory. It is a structural recursive theory, where the arguments to the Imp relation are recursively re- duced into simpler subexpressions. The base case oc- curs when the the expression to be implemented is a constant or a negation of a constant. Standard EBL on the goal above will produce the following rule. Imp(-((lwxlVlwxz)V7wxs), ((w~~Awx~)Awx~)) This rule can be seen as being generated by first substituting the variablized goal expression to be syn- thesized into the first argument of the head of rule s3, and then unwinding the specializations of the an- tecedents of s3 thus generated. Note that this is a very special purpose rule applicable only to those cases that share this sequence of substitutions and unwind- ing. For structurally recursive theories, an extension to standard EBL, called generalization-to-n has been proposed, steps. that generalizes the number of unwinding Generalization to n One such method, BAGGER2 [ShaSO] produces the following rule from this example. s5.Imp(l(xl V x2), yl A y2) -e (Xl = lwC1) A (x2 = 7wC2) A (Yl = wcl) A (y2 = wC2) V (xl = zl V ~2) A (x2 = 7wC2) A (y2 = wC2) A Imp(lx1, yl) v (xl = lwcl) A (x2 = zl V 22) A (yl = wcl) A Imp(lx2, y2) v (xl = ~1 V 22) A (x2 = 23 V 24) A Imp(lx1, yl) A Imp(lx2, y2) SUBRAMANIANANDFELDMAN 943 This can conceptually1 be treated as 4 rules that can be generated by substituting in the values shown for the variables ~1, ~1, ~2 and y2. Note that the first disjunction can be seen as the rule s6.Imp(l(lwxl V -JWX~), wxl A ~0x2) s6 can be generated by unwindings that unify both antecedents of s3 with the head of sl and propagating the bindings generated throughout the rule s3. One way of understanding rule s5 is that it unwinds a recursive rule like s3 into cases based on examining the structure of the input expression which will be syn- thesized into a circuit. s5 unrolls the input expression one more level than the original domain theory does. [SF901 examines how the other rules can be viewed as unwindings, our focus in this paper is in evaluating the utility of such rules over wide ranges of problem distri- butions which vary the percentage of problems solvable by s5 and which vary the depth and structure of input expressions to be implemented. Note that we could have formed a similar rule for s4. Another class of methods work by explicitly iden- tifying rule sequences that can be composed, using a training example as a guide. One such method is due to Cohen [Coh88]. Instead of generating a new redundant rule in the manner of EBL he designs an automaton that picks the right domain theory rule to apply for a given subgoal during the course of the proof. We have modified his algorithm to actually generate a macro rule that captures the recursive structure of the proof. Here is the algorithm. Algorithm Rl Inputs: Proof for a goal formula and a domain theory Output: The simplest context-free (CF grammar) that generates the rules sequence in the proof of the goal formula. 1. Mark the ith node in the proof tree by a new symbol Ai. The content of this node is denoted by T(Ai). 2. Re-express the proof tree as a list of productions: i.e. for proof node Ai with children Ai, . . . Ai,, create a production Ai 3 Ai,, . . . Ai,. Label the production by the name of the domain theory rule used to gener- ate the subgoals of this proof node. This label is also associated with the head of the production Ai, and we will call it L(Ai). We will denote the resulting CF grammar as G. This CF grammar is special be- cause every symbol in the grammar appears at most twice. 3. G’ = Minimize(G) 4. D’ = Build-Rules(Ao) where A0 is the start symbol for G’. Algorithm Minimize Inputs: A labeled context-free grammar of rule se- quences. ‘In our experiments we implemented junction to prevent the overhead incurred ing by treating this as 4 separate rules the internal dis- due to backtrack- Output: A minimal (in the number of non-terminals) context-free grammar that is behaviourally equivalent to the input grammar on the given goal. 1. V Ai,Aj such that L(Ai) = L(Aj) put Ai and Aj in the same equivalence class. 2. For each pair of productions in the input grammar Ai 3 Ai,, . . . Ai, and Aj =+ Ajl, . . . Ajm, such that Ai and Aj are in the same equivalence class, place Ai, and Ajk in the same equivalence class, if L(Ai,) = L(Ajk) or if L(Ai,) and L(Aj,) are both recursive productions for the same predicate (as s3 and s4 are), for 1 5 k: 5 m. 3. Eliminate structurally equivalent productions. Two productions Ai 3 A;, , . . . Ai, and Aj 3 Aj 1, . . . A jm, are structurally equivalent, if L(Ai) is the same as L(Aj ) and if terms associated with corresponding symbols X and Y (X and Y could be A; and Aj or Ai, and Ajk) in the production, namely T(X) and T(Y) are structurally equivalent. T(X) and T(Y) are by definition derived by substitution from the head of the same domain theory rule. For structural equivalence we require that the substitutions have the same structure. Algorithm Build-rules(X) Inputs: A labeled minimal CF grammar in which X is a non-terminal symbol. Outputs: A rule for T(X), the domain theory term cor- responding to X. Collect all productions in the grammar X j X1, . . . X, that have X at their head. Let Li be the set of labels of domain theory rules associated with the symbols that are in the same equivalence class as the symbol Xi. The rule corresponding to the production above is T(X) t- AL1 check - unwind(Xi). Check-unwind does the following: If the cardinality of Li > 1 then Xi is not unwound (since we have then more than one option). If N = 1 then we perform unwinding (and propagate the constraints found in the head to the body). An example makes this algorithm clear. The proof tree for a goal constructed using the original domain theory is shown in Figure 1. The CF grammar of rule sequences we get from this proof are the following. 4 - A2 A3 (~3) A2 = 4 Ati (~3) A3 - As ts21 A4 - 4 is21 A5 - As b21 ~46 - A9 WI A7 = 40 w3 A8 = AH WI The final equivalence classes generated by the min- imizing phase are (Al, AQ, As, Ad, As), {AG, A7, AFJ}, and {Ag, Alo, All}. The minimized grammar is 944 MACHINE LEARNING Y2 = W(C3) M imp(-=. r(Cl).YlI) Yll - w&l) WI imp(-- r(Cl~.~Cl)) imp(-1 ;r(C2).YI2) Yl2 = rfC2) IN id-- -fP).r(~)) imp(-.- w(C3).w(C3)) [.-I ~PhtcJ).ru(cJH Pig-l The Proof lh Figure 1: Proof Tree for Example Synthesis Al - Al AI Is31 Al ==+ 4 w ~46 - 4 WI The only rule that is learned is the compression of s2 and SI to one rule: 97. Imp(-(lwx), wx) which is simply the compression of the base cases of the recursion. Rules which are self-unwindings of the original domain theory rules are not learned. Rl is an algorithm that generates useful generalizations-to- n. When applied to the blockworld example formu- lated in [EtzSO], this algorithm learns the tail-recursive formulation of the rule for unstacking towers of height n. The enumeration of the space of possible macro rules that can be learned by EBL as well as augmentations like generalization-to-n methods in terms of unwind- ings and specializations allows us to study two ques- tions: what subset of these possible macros are useful, and how hard is it to learn that class of macros. Else- where [SF901 we study the former question, here we focus on the latter for the following four classes,of un- windings/specializations for compiling a domain the- ory. These four classes are chosen because they have been experimentally tested in the EBL literature. 1. 2. 3. 4. Keep the original domain theory (or a subset of the domain theory), ordered in such a way to optimise the set of goals we are interested in. Augment domain theory by BAGGER2 style rules and order all the rules appropriately. Augment domain theory by BAGGER2 style rules where the cases are indexed as a tree and order all rules appropriately. Add only the rules learned by Rl. To better explain the four choices for compilation, we continue with the circuits example introduced ear- lier. For Option 1 we have a theory with rules sl, s2, s3 and s4 in that order. For Option 2 we have a theory with the rules s5, si, s2, 93 and s4. For Option 3 we use the rules s5 with the cases indexed appropriately, sl, s2, s3 and s4. And for Option 4, we use the rules ~7, s3, si, s2 and s4. Converting Recursion to Iteration There is another possibility for optimising recursive theories: some linear recursions can be reformula.ted to a more efficient iterative form by the introduction of new auxiliary predicates (a classic example is the optimisation of the standard presentation of the Facto- rial function to a tail-recursive or iterative form). This class is interesting because optimatility results for this style of compilation under arbitrary distributions of future queries has been proven [WarSO]. An analysis of compilation strategies In this paper we seek a dominance result: i.e., we wish to compare the costs of deriving a class of goals in the 4 compilations of recursive theories generated by EBL and generalization-to-n methods, against using the original domain theory (or a subset of it) a.ppro- priately ordered. This seeks to formalize and experi- mentally validate the intuition that for most cases, the cost of using an unwound recursive rule outweighs the cost of using the domain theory rules directly. This work is part of a larger effort [SF901 in identi- fying cases in which macro rules provably reduce the effort a problem solver expends to solve a distribution of queries. The Utility of Macro Rules The utility problem in EBL is to justify the addition of macro rules by proving that for certain future query distributions and with some problem solvers, the ben- efit accrued by not having to perform a backtracking search through the domain theory for the right rule, is greater than the unification overhead incurred in estab- lishing the antecedents of the macro rule. As Tambe and Newell [TN881 p oint out, EBL converts search in the original problem space to matching: we trade off time to pick the right rule to solve a sub-problem plus the time needed to solve the subproblem, against the time to establish the antecedents of the macro rule. One way of casting this problem is to conceptu- ally attach with every macro rule, two classes of an- tecedents: one elaborates the conditions under which it is correct to use that rule (this is phrased entirely in terms of the vocabulary of the domain), another class of antecedents elaborates the conditions under which it is computationally beneficial to use that rule (this is phrased entirely in terms that describe a problem solver, the distribution of future queries, the distribu- tion of ground facts in the domain theory, as well as SUBRAMANIANANDFELDMAN 945 performance constraints: time and space limitations). Learning is not mere accretion of new rules, we have to learn when to use the new rule. Most EBL systems learn just the correctness conditions and learn the de- fault goodness conditions: every rule is unconditionally good.- Minton’s thesis work took a step toward iden- tifying the goodness conditions by using axioms about the problem solver. His later empirical results [Min88] showed the negative effects the extra matching had on the overall problem solver performance on an interest- ing recursive domain theory. Our analysis has the following form: we compute the cost of establishing a given class of goals in the original domain theory and compare it with the cost of doing the same in a domain theory augmented by a macro rule generated by standard EBL or generalization-to-n methods. We construct a cost model of exactly how rules are used by a problem solver. Since most of the empiricists use depth-first backward-chaining problem solvers, the Prolog model is quite adequate. In fact, we extend the Greiner and Likuski model to cover con- junctive and recursive domain theories [Gre89]. We illustrate our cost model in the context of the kinship example. We will assume that it costs i units to reduce a goal to its subgoals using a rule in the domain theory, and that it costs d units to check if a fact occurs in the domain theory. Let C’A.~~ denote the cost of solving an ancestor query with variable bindings x and y. Let the probability that q is in the domain theory be L,. We abbreviate ancestor(x, y) by A,, and father(w) by f’&,. Here x, y, z stand for variables. CAZY = i+d+(l-Pr(LF,,)[i+CA,, +Pr(&,)*CAzv] The probability that we succeed in proving a given ancestor(x,y) goal is Note that the cost equation is a recurrence equation. The base case occurs when when father(x,y) is in the ’ . domain theory: the cost then is i + d. Assume now, that we have the following ground facts about father in theory Tl that includes rules 1. and 2. from a previous section. father(c, d) fat her(d, e) fathe+, f > The cost in Tl for answering Ancestor(c,f) calcu- lated using the equations above is is 7i + 5d. This was a particularly simple case because we know that this co-mputations terminate deterministically for the above database. and thus we can replace probabili- ties in the above equations by 0 or 1. The worst case occurs when the probabilities (0 or 1) work to our dis- advantage and we explore the full search tree and the best case occurs when there is no backtracking over the rules. To analyze average case performance, we need to get estimates of the lookup probabilities above based on distributions of ground facts in the database, and solve the rather complex recurrence relations. In [SF901 we pursue simplifications of these recurrence re- lations that allow us to get qualitative cost measures. For this paper, we will analyse best and worst cases using our model to make the arguments for or against the various strategies. Simplified Cost Models for Analyzing Recursive Compilations Option 1: Keep the original domain theory Let us calculate the cost in the original theory of prov- ing a goal of the form Imp(l(x V y), a A b) where x and y are bound. The objective is to find bindings for a and b. Again, since the goal class is specified and since all recursion terminates on s4, we can analytically cal- culate the cost without doing the average case analysis that the equations allow us to compute. We will have a finer grained accounting of i which is the cost to match against the head of a rule and generate the subgoals. For goals of the form Imp(X, Y) let t be the cost of determining thata given rule rule applies. In our rule set, t = 2 because we only need to read the first two symbols in the input expression to determine if a rule applies. Since there are no ground facts here, we let d be zero. The non-linear recursive rule s3 is decomposed into two Imp subgoals, we will say its degree is 2. Let m be the degree of rule with the highest non-linearity in the rule set. In a proof of goals of the form Imp(l(Xl~X2), Y) where the Xl and X2 themselves are -(...v...) expressions or wires, there are two classes of nodes in the proof tree: the terminal and the interior nodes. Each terminal node is solvable by sl and/or s2 and costs 3t. The interior nodes which are reduced by s3 each cost 2t for the failed matches on sl and s2 and then t for the reduction by s3 itself. We add a cost of m for extracting the m components in the input to unify with the m subgoals that are generated. The cost is 3t*n+(3t+m)*+ m- Note that the costs here are linear in the length of the expression to be synthesized. This has to do with the fact that this theory has a low branching factor and that the unification costs to determine if a rule applies is constant! Option 2: Add BAGGER2 style rules in front In the best case, we only need to consider the first two disjunctions of a rule like s5. Let n be the number of leaf nodes in the proof tree and m the degree of the rule with the highest non-linearity. In the best case, we use the second disjunct w times. The total cost is t*(m+l)+m+(t*(m+2)+2*m)*~ The worst case for BAGGER2 style rules occurs when the internal nodes in the proof tree are instances 946 MACHINE LEARNING of the last disjunct in a rule like s5 and the leaf nodes are handled by the first disjunct. The total cost for this scenario is n-m ‘(m-1)*m((t+m)*(2m+m+1)+t*(2m-1)) From this expression we can see that we have exponen- tial growth in m as opposed to the cost in the domain theory which is linear in m. Option 3: Add tree-indexed BAGGER2 style rules in front As in the previous option, we will do best case and worst case analysis. The best case for Rl is also the best case for BAGGER2, the worst case for Rl is the worst case for BAGGER2. The cost for the best case computed just as before but with the tree rule (with 2 disjunctions) is czn--m 7*(2m+2t$m*t)+t+(t+1)*m m- In the worst case, we obtain the following cost for- mula. c = ‘(t + m * (t + 1)) + m (m”-i;“* m (t + m + m * (2t + m)) Option 4: Keep rules generated by Rl The analysis is similar to that done for the first option. The total cost is 1 t*n+(2t+m)*n m- l Note that Option 4 is the best for this class of struc- tural recursive theories where the unification cost to determine the domain rule to apply is bounded. In fact, Mooney ensures that this is the case, by never doing theorem proving to establish the antecedents of a learned rule, and Tambe and Rosenbloom ensure this by only learning macro rules whose antecedents have a bounded match cost. We have only computed the cost of solving the l(. . . V . . .) type of synthesis goals because that is what these macros were designed to solve. For expressions that contain operations other than -) and V , the cost of determining that the macro rule fails to apply will be exponential in the depth at which operations other than the ones above appear in the input expression. The total cost of solving such goals will be the failure cost (worst case costs com- puted above) plus the regular cost of solving it in the original domain theory. Experimental Verification of results We experimentally verify the performance characteris- tics of strategies 1 through 4 given below for a variety of problem distributions. 1. Use domain theory to solve goals. 2. Use domain theory augmented by rule generated by Bagger2 to solve goals. 3. Use domain theory augmented by tree indexed Bag- ger2 rules. 4. Use domain theory augmented by rules generated by Rl. We test these specific hypotheses. Hypothesis 1 Only when we have a priori knowledge about problem distribution is it effective to learn macro rules a la BAGGER2 or Rl. As the percentage of the problems that can solved by the added macro rule is decreased, the overall performance will decrease till we get to a point when the original ordered domain theory does better than the augmented theory with the macro rules. That is, Strategy 1 outdoes Strategies 2 and 3 as the problem distribution is skewed away from the original training instance. The role of the experiments is to find the exact cut- off points for the domination of Strategy 2 and 3 by Strategy 1 as a function of the problem distribution. Hypothesis 2 As we increase the degree of non- linearity of the recursive rules, there is exponential degradation in performance upon additi0n of macro rules a la BAGGER& I.e., Strategy 2 is dominated by all others as structural recursive theories get more complex. Hypothesis 3 In domains where the recursion is structural and the matching cost for choice of rule to apply is bound, it is better to learn the unwinding of the non-recursive rules as in Strategy 4 instead of self- unwindings of the recursive rules as in Strategies 2 and 0 3. In order to check our hypotheses we built (using C- prolog on a Sun-4) a program which given the arity of operations in the boolean algebra and the rules for synthesizing binary expressions generates the domain theories for strategies 2,3 and 4. A goal to be solved by these strategies is randomly generated by a program that accepts a depth limit (this limits the depth of the proof of the instance) and the allowed boolean opera- tions in the expression. Problem or goal distributions are produced by first picking a percentage of problems that can be solved by the macro rule alone. If that percentage is 80, say, and the problem set has 10 prob- lems, we call the individual goal generator 8 times with a depth limit and with the operators 1, v and then 2 times with the same depth limit and with the whole range of boolean operations that the domain theory can handle. We solve the problem set using each one of the 4 strategies and estimate the cost using the cost model developed in the previous section. To do the cost counting, we use a meta-interpreter also written in C-Prolog. In all these cases, we experimented with various orderings of the rules in the theory. The results SUBRAMANIANANDFELDMAN 947 Performance of Macro Rules (3,3) Performance of Macro Rules (5,3) 9000 1 I I I I 1 1800 1600 1400 1200 1000 800 600 400 8000 7000 6000 5000 3000 “......X.......*........ . 1 *. 4000 “‘-+.+* X . . . . . . ‘X.......X..... “‘..+ 2000 “X..... ‘96 . . . . . j<. . . . . . 1 ..*.::::::, 1000 1 I I I I I 0 20 40 60 80 100 0 20 40 60 80 100 problem distribution Fig-2 problem distribution Fig-3 reported for each method are for the best orderings for that method. also arrived at independently by [EtzSO]. Macro rules that decompose cases of a recursive rule to a finer grain than what is available in the domain theory to begin with are more expensive than the original domain the- ory. We wanted to check how these strategies react to exponential growth in the the problem size: i.e. we ask the theories to synthesize boolean expressions con- taining 2i wires (2 5 i 5 8). The problem set solved by each strategy was such that 50 percent of the prob- lems could be solved by BAGGER2 style macro rules and the rest were solvable by the other rules in the domain theory. As expected, we get exponential be- haviour from all strateaies because-n is exponential in all cases. However, Strategy 4 has the slowest rising exponent. The domain theory has a higher exponent than Strategy 4 because it does not havethe benefit of the unwinding of s2 by s I. This compression which can be generated-by ordinary EBL methods is the source of the performance improvement see in Figure 5. Interpretation of Results All our experimental hypotheses are verified in our do- main. Figure 2 shows that unless the percentage of problems in the future queries that are solvable by the macro rules alone exceeds 60 percent for input expres- sions of arity 3 (e.g. (x V yV Z) and 80 percent for arity 5, BAGGER2 style macro rules are not useful. The key for interpreting the symbols in the figures is given below. Ix Rl I The utility cutoff point for tree indexed BAGGER2 rules is better, but the overall trend is similar to the BAGGER2 rules. These two styles of compilation suf- fer because they unwind recursion into cases: they save on unifications when they are the right rule to use, however for problems for which they are not the right rule - the instantiated recursive rules increase cost of problem solving. Thus, in the absence of strong guar- antees about the repetition of problems like the initial training instance, macro rules that unwind recursion should not be learned. Another interesting experiment is to see how the strategies react to inputs that cause extensive back- tracking. We observe that the Strategy 2 has the worst behaviour. And that strategies 1 and 4 do much bet- ter than the others. The reason for this is the heavy backtracking cost that is incurred for inputs where the inapplicability of the macro rule is discovered several levels into the recursion in the internally disjunctive rule. All other disjuncts in that rule are tried before the other regular domain theory rules are tried. Strategy 3 suffers- from a similar drawback, but because fewer cases are unwound, the exponent is smaller. In Figure 3 we note the degradation of performance of BAGGER2 type rules in synthesizing expressions of arity 5: learning BAGGER2 style rules in structural recursive domain theories with bounded rule selection cost is not useful. This is consistent with our obser- vation before that BAGGER2’s performance is expo- nential in m. In both these figures, the best perfor- mance is observed for Strategy 4 where a subset of the non-recursive portion of the original domain theory has been compressed to a single rule, and where the recur- sive rules are not unwound at all. This observation was Conclusions The overall message is that for structural recursive do- main theories whire we can find if a rule potentially 948 MACHINE LEARNING Performance of Macro Rules 12000 10000 8000 6000 4000 2000 0 2 3 4 5 6 7 8 depth of input structure Fig-4 Performance of Macro Rules (2,6) 9000 . . I I I I "".Q..* 8000 - "Q... 7000 - “Q, 6000 - “‘.Q. ‘= .Q* 5000 - @ w::: . . . ..a + ““4z......n “‘x2..* 4000 - -.... -... 0 20 40 60 80 100 problem distribution Fig-5 applies by a small amount of computation, forming self-unwindings of recursive rules is wasteful. The best strategy appears to be compressing the base case rea soning and leaving the recursive rules alone. We proved this using a simple cost model and validated this by a series of experiments. We also provided the algorithm Rl for extracting the base case compressions in such a theory. Acknowledgments Discussions with Stuart Russell, K. Sivaramakrishnan, Albert0 Segre, and John Woodfill were valuable. Our thanks to Jane Hsu for providing careful feedback on an earlier draft. multiple examples in explanation-based learning. In Proceedings of the Fifth International Conference on Machine Learning, pages 256-269. Morgan Kauf- mann, 1988. 0. Etzioni. Why prodigy/ebl works. Technical report, Computer Science Department, Carnegie-Mellon Uni- versity, January 1990. R. Greiner. Finding the optimal derivation strategy in a redundant knowledge base. In Proceedings of the Sixth International Workshop on Machine Learning. Morgan Kaufmann, 1989. S. Minton. Quantitative results concerning the util- ity of explanation-based learning. In Proceedings of the Seventh National Conference on Artificial Intelli- gence, pages 564-569. Morgan Kaufmann, 1988. R. Mooney. The effect of rule use on the utility of explanation-based learning. In Proceedings of the Eleventh International Conference on Artificial Intel- ligence. Morgan Kaufmann, 1989. P. Shell and J. Carbonell. Towards a general frame- work for composing disjunctive and iterative macro- operators. In Proceedings of the Eleventh Inter- national Conference on Artificial Intelligence, pages 596-602. Morgan Kaufmann, 1989. D. Subramanian and R. Feldman. The utility of ebl in recursive domain theories (extended version). Tech- nical report, Computer Science Department, Cornell University, 1990. J. Shavlik. Acquiring recursive and iterative concepts with explanation-based learning. Machine Learning, 1990. P. Tadepalli. Learning approximate plans in games. Thesis proposal, Computer Science Department, Rut- gers University, 1986. R. Keller T. Mitchell and S. Kedar-Cabelli. Explanation-based learning: A unified view. Machine Learning, l( 1):47-80, 1986. M. Tambe and A. Newell. Some chunks are expensive. In Proceedings of the Fifth International Conference on Machine Learning, pages 451-458. Morgan Kauf- mann, 1988. D.H.D. Warren. An improved prolog implementa- tion which optimises tail recursion. Technical report, Dept. of Artificial Intelligence, University of Edin- burgh, 1980. References W. Cohen. Generalizing number and learning from SUBRAMANIANANDFELDMAN 949
|
1990
|
166
|
922
|
Integrating Natural Language Processing and Knowledge Based Processing* Rebecca Passonneau and Carl Weir and Tim Finin and Martha Palmer Unisys Corporation The Center for Advanced Information Technology Paoli, Pennsylvania Abstract A central problem in text-understanding research is the in- determinacy of natural language. Two related issues that arise in confronting this problem are the need to make com- plex interactions possible among the system components that search for cues, and the need to control the amount of reasoning that is done once cues have been discovered. We identify a key d.ifEculty iu enabling true interaction among system components and we propose an architectural frame- work that minimizes this difficulty. A concrete example of a reasoning task encountered iu an actual text+mderstanding application is used to motivate the design principles of our framework. Introduction The central problem confronting text-understanding re- search is what in recent years has been characterized as the economy of natural language [Barwise and Perry, 19831. Natural languages possess an economy of ex- pression because humans take advantage of situational cues in conveying whatever information they intend to partially encode as a natural language utterance. For a text-understanding system to approach human com- petence in coping with natural language, it must be capable of exploiting the same linguistic cues and gen- eral knowledge that humans exploit. Two related issues that arise in efforts to endow systems with this capa- bility are the need to make complex interactions pos- sible among the processing components, or knowledge sources, that search for cues, and the need to control how much reasoning is done with the cues;once they are discovered. In the following section, a conflict between two dif- ferent, processing methodologies is identified as the key difficulty in enabling complex interactions among the processing components of text understanding systems. An architecture is proposed that minimizes this prob- lem, but that places a burden on system designers to insure that the underlying representation language used as a communication medium among the system’s pro- *This work was partially supported by DARPA Contract N0001485-C-0012. 976 NATURALLANGUAGE cessing components is rich enough to capture the in- formation content of an input text at a sufficient level of detail to be useful for the application-specific tasks the system is serving. We propose six design princi- ples addressing the issue of how expressive the under- lying representation language needs to be, and how the reasoning processes that manipulate expressions in this language should be controlled. In order to convey as concretely as possible the depth of understanding that text, understanding systems are expected to achieve, we have selected a particularly instructive example from a recent evaluation effort in which participating text-understanding systems per- formed a summarization task. Our discussion of this example will motivate our six design principles and in- dicate how our proposed framework permits evolution- ary progress towards more reliable text analysis. Component Interaction The flow of control in most text-understanding systems generally consists of an initial phase of syntactic pars- ing and semantic interpretation that results in a logi- cal form which is then translated into a less expressive, unambiguous representation serving as input to what- ever general reasoning modules the system has access to. Although there are many variations on this general theme, systems that rely on a careful syntactic analysis of textual input typically enumerate a set of unambigu- ous or partially ambiguous (least commitment) parses for a given utterance that are semantically interpreted, and the first coherent interpretation is passed on to the knowledge representation and reasoning component as the literal information content of the utterance. In systems possessing such architectures, the interaction between linguistic processing and general reasoning is minimal, since the general reasoning mechanisms are not defined over the data structures used in linguistic processing. A similar lack of interaction between linguistic processing and general reasoning is present in text- understanding systems that are less dependent on a Careful Syntactic analysis of textual input. SCISOR is From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. an example of such a system [Rau and Jacobs, 19881. When SCISOR processes a sentence in a text, it first tries to derive a full parse using a chart-based parsing algo- rithm. If this is not possible, a partial parse can be used to instantiate event descriptions based on expectations of how a given type of event is structured, including script-based intuitions about likely orderings of events in a typical scenario. Although this use of a backup, expectation-based processing strategy is a promising technique for handling gaps in coverage, it doesn’t ac- tually result in true interaction between the parser and the reasoning mechanisms used to analyze situation structure. Other well documented text-understanding systems that are heavily dependent on knowledge-based techniques exhibit difficulty in taking advantage of lin- guistic cues. In Hirst’s Absity system, e.g., the use of marker-passing as the principal reasoning mechanism makes it difficult to accommodate syntactic cues in lex- ical disambiguation [Hirst, 19861. Efficient linguistic processing is based upon a generate-and-test search methodology. In contrast, general reasoning techniques involve the creation and maintenance of persistent, complex, data structures. A generate-and-test methodology is effective if the cost of creating data-structures representing hypotheses is rela- tively cheap, which is not the case with the sorts of data structures that must be created and maintained when doing general reasoning. Consequently, there is a fun- damental conflict between efficient linguistic processing techniques and general reasoning techniques that re- sults in a natural tendency to separate the two forms of processing [Passonneau et al., 19891. There is a growing realization that although a strict separation between linguistic processing and general reasoning makes for a modular, efficient system archi- tecture, it is ultimately untenable because it, doesn’t al- low processing decisions to be postponed until adequate information is available to make well-motivated choices [Allen, 19891. Efforts to allow for the postponement of such decisions through the use of canonical struc- tures intended to capture multiple interpretations have been problematic. For example, Wittenberg and Bar- nett have observed that the use of canonical structures in the Lucy system developed at MCC resulted in aban- donment of bot h compositional interpretation and mod- ularity in the declarative representation of information [Wittenburg and Barnett, 19881. We conclude that current text-understanding sys- tems are not properly designed for the sort of inter- action among components that is required to cope with the indeterminacy of natural language. An obvious framework for achieving this sort of interaction is a blackboard architecture in which individual processing components communicate with one another via a com- mon language that they use to post and examine facts in some globally accessible data-structure. A few nat- ural language processing systems already make limited use of a blackboard architecture. Thus, the manner in which Polaroid words in Graeme Hirst’s Absity seman- tic intepreter communicate with one another is via a blackboard structure [Mirst, 1986]. The discourse com- ponent in the Lucy system developed at MCC exhibits a blackboard style of interaction among a number of sub-components that are used to perform reference res- olution [Rich and LuperFoy, 19881. We believe text- understanding systems should incorporate a blackboard architecture in which all components communicate via a common language over which the system’s available reasoning mechanisms have been defined, and that this language be expressive enough to capture all of the in- formation that the various system components are ca- pable of contributing to the text-understanding task. Six Design Principles Unfortunately, it is currently impossible to design a text-understanding system in which all components communicate via a common language with great, expres- sive power over which sophisticated reasoning mecha- nisms have been defined. The knowledge representation and reasoning techniques currently available are simply not up to the task of capturing the nuances of mean- ing in natural language. James Allen has suggested that this inadequacy is the principal reason that data structures commonly referred to as representations of logical form are created; they capture more of the ex- pressiveness of natural language than do current, knowl- edge representation formalisms with well-defined infer- ence mechanisms [Allen, 19891. Given this state of affairs, one can either abandon the design of text understanding systems based on the existence of a communication medium of the sort that is required, or one can pursue the design of such sys- tems with the hope that appropriate representation lan- guages will be developed in the near future. We recom- mend the latter choice for two reasons. First, experi- ence has shown that research and development efforts based on the old enumeration paradigm have begun to show diminishing returns. Second, there is a growing recognition in the knowledge representation and rea- soning community that general purpose knowledge rep- resentation systems need to be built that incorporate more expressive languages, even if doing so requires the abandonment of completeness [Doyle and Patil, 19891. We propose a design methodology based on the fol- lowing six principles: 1. A capability for data-driven reasoning. The system should be endowed with the intelligence to know when available data suggests that a particular line of reasoning would be worth pursuing. 2. A capability for constraint reasoning. The system should be capable of propagating constraints on an interpretation and reasoning about them. PASSONNEAU ET AL. 977 3. An MRL with adequate expressive power. In selecting a knowledge representation and reasoning component, the expressive power of the MRL should take precedence over completeness and worst-case time com- plexity. 4. A single MRL. The system knowledge representation and reasoning component should provide a single meaning representa- tion language (MRL) h h w ic may be used as a medium of communication for all system components. This language should serve both domain-specific and application-specific representation and reasoning tasks. 5. A capability for delayed reasoning. The system should be able to postpone making a decision if insufficient information is available to make a reason- able choice. 6. A capability for demand-driven reasoning. The system must be intelligent enough to know that cer- tam decisions simply do not need to be made. In the following sections, we provide a detailed exam- ple of a reasoning problem encountered in a text under- standing task and illustrate how the design principles we have proposed make it possible to properly confront it. To follow our discussion, it is necessary to have a ba- sic understanding of the knowledge representation and reasoning component used in the KERNEL text under- standing system that, we are currently building. The knowledge representation and reasoning compo- nent in KERNEL is based on the tripartite model popu- larized by Brachman, Fikes, and Levesque in the KRYP- TON system [Brachman et ul., 19851. The key feature in this architecture is the use of an interface language to insulate other processing components from the imple- mentation details of the knowledge representation and reasoning modules. This interface language, called PKR in KERNEL, serves as a protocol for asserting what to include in representations of the information content of texts, and for asking queries about the current state of such representations [Weir, 19881. PKR does not possess all the expressive power ultimately needed for text un- derstanding, but it does provide adequate access to the two knowledge representation and reasoning modules that KERNEL currently uses, as shown in Fig. 1. Concept hierarchies are currently defined in KERNEL using a KL-ONE style representation language called KNET [Matuszek, 19871. Assertions are expressed in terms of facts posted to the database of a forward- chaining system called Pfc [Finin et al., 19891. It is the forward-chaining database maintained by Pfc that serves as a blackboard structure in KERNEL. Pfc is built on top of Prolog and provides justification-based truth maintenance for expressing and reasoning about instances of concepts. Moreover, Pfc is able to manip- ulate two fundamentally different types of rules: eager rules and persistent rules. An eager rule is a typical forward-chaining rule that provides KERNEL with the capability to do data-driven reasoning. A persistent 978 NATURAL LANGUAGE Figure 1: Kernel current knowledge representation and rea- soning system has four components: PKR provides an abstract interface; KNET is a terminological representation system, Pro- log is used for some backward chaining, and Pfc provides a more flexible reasoning component with an integrated truth maintenance system. rule is a rule that is posted to the forward-chaining database, but that remains inert until a consumer ap- pears for one of its conclusions. When a consumer ap- pears, an instance of the rule is instantiated as an ea- ger rule to satisfy that consumer. The use of persistent rules helps control the amount of reasoning engaged in by the system. Archetypal NL As part of an effort to develop evaluation metrics for text understanding systems, NOSC sponsored a work- shop in which participating systems trained and were tested on a summarization task for a corpus of mili- tary messages [Sundheim, 19891. The texts consisted of OPREP (Operational REPort) messages describing naval sightings of surface, subsurface and airborne ves- sels. Fig. 2 illustrates a sample text and the target output. To demonstrate understanding, each partici- pating system had to recognize the events mentioned in a message and determine whether they fell into one of 5 critical types of events. At most, two such events were to be identified per message: the most important such event initiated by the friendly forces and, similarly, the most important one initiated by the hostile forces. Generating one template per reported event and cor- rectly filling the 10 slots of each template constituted successful understanding. In cases where two templates were generated, the system was to determine the cor- rect temporal ordering. Fig. 2 illustrates a message with two event templates where the correct temporal ordering is not provided explicitly in the message, but instead must be inferred from the message content. The critical sentence of the sample message is: friendly CAP a/c splashed hostile tu-16 proceeding Narrative text horn message Friendly CAR A/C splashed hostile TU-16 proceeding inbound to Enterprire at Sbnm. Last hostile acft in vicinity. Air warning red weapons tight. Remaining alert for additional attacks. Paraphrase of narrative text A friendly combat air patrol aircraft shot down a hostile TU-16 aircraft thirty-five nautical miles away from the carrier Enterprise. The hostile aircraft had been proceeding towards the carrier at the time of the attack. It was the last hostile aircraft in the area. All friendly forces should remain at the highest level of alert, but are not given permission to fire their weapons. Figure 2: This figure shows an example of the narrative free text portion of one of the Oprep messages, a paraphrase of the intended meaning, and the properly filled database templates which represent the meaning. inbound to enterprise at 35nm.l In this domain, an aircraft proceeding towards an op- posing carrier constitutes a track event, thus licensing the first template shown above. An aircraft that gets splashed has been shot down into the ocean, which counts as an attack event. Note that the track tem- plate is correctly ordered prior to the attack template.2 An accurate analysis of the sentence shown above leads to the correct ordering of the two templates demanded by the application, but requires close cooperation be- tween linguistic and knowledge-based processing. We describe below how this sentence illustrates the need to simultaneously make use of local linguistic information and global contextual information. But note that the information required by the application cannot predict in general the degree to which such reasoning will be required. For messages with more explicit temporal in- formation, linguistic analysis alone may be sufficient to provide the correct template fills. Given that the template filling task requires tem- poral information, the system should provide its best guess regarding the temporal order of the proceed and ‘See Fig. 2 for a paraphrase. ‘The Kernel system generates the template output shown in Fig. 2, relying on a combination of linguistic pro- cessing, deep reasoning, and application-specific heuristics; however, we have not fully implemented the architecture proposed here. spkash events even in the absence of explicit assertions. But since the system may have access to many different kinds of knowledge, the need to control deep reasoning with respect to specific goals arises. For example, for this task, the system should not attempt to infer the tu-16’s location of origin because it is irrelevant. As we describe the inference problem in more detail, it should be clear both that the original sentence does not explic- itly order the two relevant events, and also that infer- ring the temporal order depends on multiple knowledge sources. The proceeding event, a temporally situated occur- rence involving the referent of the noun phrase hostile tul6, is mentioned in a post-modifier with no explicit temporal information, i.e., no tense and no temporal locatives. Given the sentence structure, there are three possible temporal locations for the event. These three possibilities are that the reference time of the event is the same as the matrix clause reference time specified by the simple past tense, a different past time, or the present time (utterance time, or here, message composi- tion time). Graphic representations of three illustrative sentences are shown in Figs. 3-5.3 Given that the linguistic structure permits three tem- ‘A Reichenbachian interpretation of tense involves three temporal indices, one of which, ST, represents the time at which a speech or text event occurs [Reichenbach, 19471. Since in these examples event time (ET) and reference time (RT) are identical, only ST and RT are used. PASSONNEAUETAL. 979 We votedfor the woman (now) wearing the blue dress. voting wearing utterance RT ST TEMPORAL RELATIONS: @ The utterance occurs at time ST. a The voting occurs at time RT. o RT<ST. l The wearing occurs at time ST. Figure 3: The first possibility for the reference time of the Figure 4: The second possibility for the reference time of the modifier is that it is the same as the time when the sentence modifier is that it is the same as the time specified by the or utterance is produced (ST). matrix clause tense (RT). poral interpretations for the time of the proceeding, the next step is to examine what factors favor one interpre- tation over another. The three inference rules presented in Figs. 6, 7 and 8 illustrate a reliance on multiple knowledge sources. Note that the rules use the follow- ing symbols and relations4: e SI - the event or situation mentioned in the matrix clause o S2 - the event or situation mentioned in the postmodifier l s3 - the situational context at the time of the utterance o holds(S, RT) - t rue if event or situation S holds at time RT l salient(E, S, ST) - t rue if entity E is salient in situational context S at time ST o consistent(E, SI, S2, RT) - true if what is predicated of entity E in situation SI, where SZ holds at RT, is consis- tent with the assumption that Sr also holds at RT In all three rules, the first 5 clauses are the same, and depend on the local linguistic structure. They make reference to syntactic relations like matrix clause or se- mantic correlates thereof, such as the event or situation evoked by a clause, the specification of a reference time for that event or situation, e.g., a known RZ’l for the tensed matrix clause and an unknown RT2 for the un- tensed reduced relative. Similarly, the first 5 clauses of all three rules make reference to the consistency of the -ing predicate with what is known about the modi- fied entity at various other known times. In general, the three rules depend on both context-independent semantic interpretation and context-dependent prag- matic processes such as determing the reference time of 4Terminological note: an event is a specialization of a situation; a situational context for an utterance or text is also a specialization of a situation. 980 NATURALLANGUAGE Friendly CAP ale splashed hostile tu-16 proceeding inbound to enterprise at 35nm. proceeding splashing utterance RT ST TEMPORAL RELATIONS: 0 The utterance occurs at time ST. 0 The splashing occurs at time RT. o RT<ST. o The proceeding occurs at RT. the matrix clause, determining the referent of the noun phrase, and determining the salience and consistency of entities in the discourse context. While there is no space here to discuss salience and consistency in detail, salience of an entity can be taken as a discourse prop- erty that involves the notions of local and global focus [Grosz and Sidner, 19861. Consistency involves a com- bination of lexically driven inference (i.e., what facts about X and Y follow from splash@, Y); likewise for proceed(X Y)h g eneral world knowledge about times and situations, and an evaluation of what is known about the relevant entity and situations at a particu- lar reference time. The three inference rules capture a general reasoning process that can be described as follows: when resolv- ing the referent E, attempt to find a known time to assign the situation S2 that is the same or prior to ST by insuring the consistency of S2 with everything else that is known about E for that time. The question is when and how to execute this reasoning process, and more crucially, whether it can be performed as a simple sequential process. We believe it cannot be performed as a sequence of distinct steps in distinct semantic and pragmatic processing stages for the following reasons. If the reasoning is done incrementally, as a semantic interpretation for each phrase is arrived at, then all the relevant local syntactic and semantic information specified in the first 5 clauses of the inference rules in Figs. 6-8 will indeed be available. But the problem here would be to handle the interdependence between the two pragmatic processes of resolving the referent of the noun phrase and finding the temporal location of its modifier. There is a cirularity in that knowing the referent of the noun phrase might eliminate certain temporal locations for the situation predicated of that We voted (this morning) for the woman distributing leaflets at the meeting (yesterday). distributing voting utterance RT2 RTl ST TEMPORAL RELATIONS: o The utterance occurs at time ST. * The votin .RTl <S 9 occurs at time RTl. . 0 The distributing occurs at time RT2. .RT2<RTl. We voted for the woman wearing the blue dress. a) holds(Sx, RTI) b) RTI < ST c) hold+, RT2) d) unknown( RT2 ) e) saZient(E, SS, ST) f) wnsident( E, SZ ,233, ST) ;Ta = ST. L J Figure 6: This rule handles cases where the RT of the post- modifier (RT2) and ST are the same. Figure 5: The third possibility for the reference time of the modifier (RT2) is that it is prior to the utterance time (ST) but distinct from the reference time of the matrix clause (RTl). The figure illustrates the case where RT2 precedes, rather than follows, RTl. Figure 7: This rule handles cases where RT of the matrix clause (RTl) and RT of the post-modifier (RTa) are the same. referent in the postmodifier; but, knowing the temporal location of the situation in the postmodifier might help determine the referent of the noun phrase. This argues for a solution which circumvents the problem of having to order the two pragmatic processes with respect to one another. We show in the following section how the six principles outlined in the section preceding this one provide this feature, as well as other advantages. An alternative to performing the reasoning incremen- tally would be to postpone it until a semantic interpre- tation for the whole sentence has been performed. Here there are two potential problems. The first is that if the linguistic input has alternative analyses, then being able to reason from the current discourse context might help choose among them. In contrast, if the reasoning is carried out after the semantic interpretation of the sentence, then the global discourse information may be available but the output of linguistic processing con- tains representations of entities, situations and times in a form quite remote from surface linguistic structure. The reasoning mechanism would need access to the lo- cal linguistic information specified in the rules above, i.e., that there was a particular syntactic configuration and consequent semantic relations. Again, the solution we propose in the following section circumvents this dif- ficulty. In addition, our solution maximizes the ability of the system to accurately solve for the unknown refer- ence time, and thus to perform the required application task as accurately as possible. Friendly cap a/c splashed hostile k-1 6 proceeding inbound to enterprise a)-d) same as above e) not( sahent(E, SS , RTI )) f) consistent(E, S2, Sl, RTI) ;Tz = RTl. We voted for the woman pa&rag out leaflets at Tom ‘8 party yesterday a)-d) same as above e) not( sahent(E, SS , RTI )) f) not(consistent(E, SZ , Sl , RTI )) RjTa < ST, RTs # RTl. J Figure 8: This rule handles cases in which RT of the post- modifier (RT2) is distinct from ST and RT of the matrix clause (RZ). Improved Integration The six principles we have proposed comprise a package in which maximum benefit of each principle follows from implementing the whole. Below we use the example described in the previous section to illustrate how this combination of principles would circumvent many oft he processing difficulties posed by this example. We assume that when the modifier in the example sentence is semantically interpreted, the available data consists of the full parse tree and a partial semantic analysis. We also assume that in general, during lin- PASSONNEAUETAL. 981 guistic processing of a sentence, the status in the dis- course model of entities referenced in the same sentence may or may not be available. Principle 1, data driven reasoning, dictates that elaboration of the MRL repre- sentation of a sentence be data-driven. We have shown that the reference time of the postmodifler in the sam- ple sentence is constrained by the three inference rules provided in Figs. 6-8, irrespective of what other data may OP may not have been already derived about the entities and situations mentioned in the sentence. We therefore conclude that the knowledge represented in the three inference rules ought to be included in the output of linguistic processing. KERNEL currently en- forces data-driven reasoning in that facts derived from linguistic processing are posted to PKR during linguis- tic processing and the KR&R modules must then reason from this data. Principle 2 asserts that the MRL expressions repre- senting the output of linguistic processing must express no more nor less than can be justified by the linguis- tic input. Thus in cases where the linguistic input is indeterminate, as in the example sentence, the output of linguistic processing should preserve this indetermi- nacy. At present, we can reason with constraint rules such as those shown in Figs. 6-8, but we do not have a concise means of reasoning about constraints as first class objects. To return to OUP example, it might prove useful in some circumstances to reason about the pro- ceeding and the splash events in a way that takes into account the constraints on the reference time of the proceeding, e.g., that RT2 5 ST, prior to being able to resolve the constraints. Principle 3 embodies our belief that the expressive power of the MRL should take precedence over the ability to reason efficiently over MRL expressions (cf. [Allen, 19891 [Doyle and Patil, 19891). The relation of linguistically derived temporal information to tempo- ral reasoning is a good example of the potential need to sacrifice completeness, since temporal-interpretation of textual input generally results in partially ordered times at best [Allen, 19831. Principle 4 requires that the information be repre- sented in a common MRL so that any other process- ing components can potentially contribute to-or rea- son over the representation. The semantic and prag- matic interpretation procedures in KERNEL currently use PKR to determine how to express the facts it derives, thus PKR provides access to whatever KR&R compo- nents are available while insulating the semantic and pragmatic interpreters from dependence on a particu- lar KR framework. It is only necessary that for each query from KERNEL there be an equivalent MRL ex- pression. In thii caSe, PKR insures that all facts about entities, times, situations and temporal relations that are derived from the sample sentence are expressed in MRL expressions that can mediate between the linguis- tic modules and KR&R resources. By restricting the responsibility of the linguistic mod- ules to that of posting linguistically justifiable conclu- sions, the time at which deep reasoning takes place is open. For example, it can be postponed until contin- gent information is more likely to be available, as noted in Principle 5. For efficiency reasons, we currently post- poneinvocationof PFC Until after hgUiStiC PrOCeSSiUg of an input sentence. At this point, PFC would have access to the maximum set of facts pertaining to the determination of RT2 in the sample sentence. Accord- ing to our model, if the data support a specific conclu- sion about the identity of RTZ, that conclusion should be derived. If not, the representation of RT2 should remain expressed in terms of constraints. The final principle, demand-driven reasoning, com- plements datccdriven reasoning in a way which inte- grates well with application requirements. If we take our example sentence in isolation from its discourse context, there is insufficient linguistic data to equate RT2 with either RTI or ST; there is also insufficient data to unequivocally distinguish it from RTl or ST. A particular discourse context and the additional data it provides might justify more specific conclusions about RT2. FOP example, if the discourse context definitively supports the conclusion that “not (salient (E,Se, RTI))” (cf. clause e) of the rules in Figs. 7-8), then perhaps the mere presence of this extra data should trigger the reasoning process that would eliminate ST as a possi- ble value of RT2. On the other hand, it is not nec- essarily useful to derive all justifiable conclusions from a particular set of data. Even in a discourse context which could further constrain RT2, it may be prefer- able for the additional reasoning to be suspended until there is an explicit demand. We speculate that such a demand could originate either from other application- independent processing or from application-dependent tasks. In OUP example, the application should drive the search for relevant temporal information. Conclusion We see a fundamental conflict between linguistic pro- cessing strategies and knowledge-based reasoning pro- cesses. In adapting KERNEL to a specific application task, we confronted a tradeoff between our long term goals of designing a general purpose, application in- dependent NL system and the specific requirements of the appplication task. Although we were able to sat- isfy the immediate demands of the application without changing the fundamental architecture of the system, we felt that it should be possible in the long run to achieve a better balance between application-specific post-processing modules and the underlying text un- derstanding system. We have described our recent ef- forts to achieve a better solution and our current views regarding the promise of closer integration of general purpose reasoning, linguistic processing, and applica- tion oriented reasoning. It is our conviction that long- 982 NATURALLANGUAGE term research goals concerning the development of prac- tical applications of text understanding systems must focus on the problem of integrating multiple knowledge sources as cleanly as possible. Acknowledgements The authors would like to thank James Allen for his valuable comments on 8 previous draft, as well as two anonymous reviewers. We also thank Rich Fritzson and Dave Matusek for help and inspiration. References [Allen, 19831 James Allen. Maintaining knowledge about temporal intervals. Communications of the ACM, 26:832- 43, 1983. [Allen, 19891 James Allen. Natural language, knowledge representation and logical form, November 1989. Paper delivered at BBN symposium, Natural Language Process- ing: Language and Action in the World. [Barwise and Perry, 19831 J. Barwise and J. Perry. Situa- tions and Attitudes. Bradford Books, MIT Press, Cam- bridge, Mass., 1983. [Brachman et al., 19851 R. J. Bra&man, R. E. Fikes, and H. J. Levesque. Krypton: A functional approach to knowledge representation. In R. J. Bra&man and H. J. Levesque, editors, Readings in Knowledge Representa- tion, pages 411-430. Morgan Kaufmann Publishers, Inc., Los Altos, CA, 1985. [Doyle and Patil, 19891 J on Doyle and Ramesh S. Patil. Two dogmas of knowledge representation. Technical Re- port MIT/LCS/TM-387.b, MIT Laboratory for Com- puter Science, Cambridge, MA., September 1989. [Finin et aL, 19891 T. Finin, R. Fritzson, and D. Matuzsek. Adding forward chaining and truth maintenance to pro- log. In CAIA-89, pages 123-130, March 1989. [Gross and Sidner, 19861 Barbara J. Grosz and Candace L. Sidner. Attention, intentions and the structure of dis- course. Computational Linguistics, 1986. [H&t, 19861 Graeme Hirst. Semantic Interpretation and the resolution of ambiguity. Studies in Natural Lan- guage Processing. Cambridge University Press, Cam- bridge, 1986. [Matuszek, 19871 David L. Matuszek. K-Pack: A program- mer’s interface to KNET. Technical Memo 61, Unisys Corporation, P.O. Box 517, Paoli, PA 19301, October 1987. [Passonneau et al., 19891 Rebecca Passonneau, Carl Weir, and Tim Finin. Interfacing natural language processing and knowledge-based processing in Pundit, 1989. Darpa Spoken Language/Natural Language Meeting. [Rau and Jacobs, 19881 Lisa F. Rau and Paul S. Jacobs. In- tegrating top-down and bottom-up strategies in a text processing system. In Second Conference on Applied Nat- ural Language Processing, pages 129-135, Austin, Texas, February 1988. Association for Computational Linguis- tics. [Reichenbach, 19471 H ans Reichenbach. Elements of Sym- bolic Look. The Free Press. New York. 1947. [Rich and LuperFoy, 19881 Elaine Rich and Susann Luper- Foy. An architecture for anaphora resolution. In Proceed- ings of the second conference on applied natural language processing, pages 18-24, Austin, TX, February 1988. As- sociation for Computational Linguistics. [Sundheim, 19891 B. M. Sundheim. Plans for a task- oriented evaluation of natural language understanding systems. In Proceedings of the DARPA Speech and Nat- ural Language Workshop, pages 197-202. Morgan Kauf- man Publishers, Inc., Philadelphia, PA, 1989. [Weir, 19881 Carl W eir. Knowledge representation in Pun- dit. Technical Report PRC-LBS-8914, Unisys, Paoli, PA, October 1988. [Wittenburg and Barnett, 19881 Kent Wittenburg and Jim Barnett. Canonical representation in NLP system design: a critical evaluation. In Proceedings of the second confer- ence on applied natural language processing, pages 253- 259, Austin, TX, February 1988. Association for Compu- tational Linguistics. PASSONNEAU ET AL. 983
|
1990
|
167
|
923
|
Towards Incremental iguat ion with a Generalized iscrimination Network Manabu Okumura and Hozumi Tanaka Department of Computer Science, Tokyo Institute of Technology 2-12-1, 0-okayama, Meguro-ku, Tokyo, 152, Japan dora@cs.titech.ac.jp Abstract Semantic disambiguation is a difficult problem in natural language analysis. A better strategy for semantic disambiguation is to accumulate con- straints obtained during the analytical process of a sentence, and disambiguate as early as possible the meaning incrementally using the constraints. We propose such a computational model of natural language analysis, and call it the ‘incremental dis- ambiguation model.’ The semantic disambigua- tion process can be equated with the downward traversal of a discrimination network. However, the discrimination network has a problem in that it cannot be traversed unless constraints are en- tered in an a priori-fixed order. In general, the order in which constraints are obtained cannot be a priori fixed, so it is not always possible to tra- verse the network downward during the analytical process. In this paper, we propose a method which can traverse the discrimination network according to the order in which constraints a.re obtained in- crementally during the analytical process. This order is independent of the a priori-fixed order of the network. Introduction Semantic disambiguation is a difficult problem in nat- ural language analysis. The meaning of a word is am- biguous because it cannot be uniquely determined un- less information about other words in the sentence is obtained. A possible strategy for semantic disambiguation would be to determine the meaning of words at the end of the sentence. Yet this strategy might cause a combinatorial explosion of the number of total ambi- guities if the sentence were long. We think it is im- practicable for a natural language analysis system to determine the meaning of words from a number of can- didates after it has finished reading the whole sentence. Another strategy, trying to force a decision with insuf- ficient information, would be faced with serious uncer- taint ies. A better strategy for semantic disambigua- tion would be to accumulate information(constraints) 990 NATURAL LANGUAGE obtained during the analytical process of a sentence, and disambiguate as early as possible the meaning in- crementally using the constraints. We propose such a computational model of natural language analysis, and call it the ‘incremental disambiguation model[Mellish, 19851.’ The incremental disambiguation process is consid- ered to be the refinement of ambiguous(undetermined) results of semantic processing by newly obtained con- straints. Therefore, the incremental disambiguat ion approach allows us to deal with cases where it is im- possible to disambiguate unless information about suc- ceeding sentences is taken into account. The semantic disambiguation process can be equated with the downward traversal of a discrimination network[Charniak et al., 19801. Using a discrimination network for semantic disambiguation has the following advantages: a a discrimination network doesn’t treat multiple word senses as being unrelated, and allows us to take into account interrelationships among multiple word senses; e multiple word senses represented as elements of a list, the algorithm of selecting among them, that is, a linear search of the list, is very inefficient when candidate word senses are too numerous. On the other hand, the discrimination network’s search al- gorithm is considered to be more efficient because the downward traversal from the root node to a leaf node which represents a word sense is guided by con- straints which are labels of branches. The partial traversal of a discrimination network is considered to be the representation of the ambiguous result of partial semantic processing which is easily rep- resented by nodes in the network except leaf nodes. Making a new decision by additional constraints from subsequent ‘inputs naturally corresponds to traversing from the current node further downward using newly obtained constraints. This method is therefore well suited for the incremental disambiguation approach. However, the discrimination network has a problem in that it cannot be traversed unless constraints are From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. entered in an a priori-fixed order. In general, the or- der in which constraints are obtained cannot be a pri- ori fixed, so it is not always possible to traverse the network downward during the analytical process. In this paper, we propose a method which can traverse the discrimination network according to the order in which constraints are obtained incrementally during the analytical process. This order is independent of the a priori-fixed order of the network. This method is based on the notion of constraint logic programming and is implemented by extended unification. We call it a ‘generalized discrimination network.’ In section two, the advantages and problems of using a discrimination network for semantic disambiguation are described and in section three, principles of gener- alized discrimination networks are presented. Finally, in section four, the merits of the generalized discrimi- nation network are described. Semantic disambiguation using discrimination networks Figure 1 is a portion of the discrimination network which represents the word senses of the verb ‘to take.’ Each branch of the network has as its label a selectional restriction on surface cases such as subject(S), ob- ject(O), prepositions like ‘with,’ ‘to,’ and so on. Each leaf node of the network points to a unique word sense, which is represented by the underlined label1 . Other nodes represent ambiguous word meanings which in- clude all word senses corresponding to the leaf nodes below them, because from these, the further traversal along branches to multiple nodes are possible. The root node corresponds to the most ambiguous mean- ing: it is a representation which includes all leaves, namely all word senses. The semantic disambiguation process using a dis- crimination network is a step by step downward traver- sal of the network from the root node to a leaf node guided by branches which satisfy the obtained con- straints. In this process, semantically inappropriate alternatives are rejected and appropriate word senses are selected by virtue of information about other words in the sentence. The reaching of a leaf node means that the ambiguity has been fully resolved. We can say a verb is semantically ambiguous if a leaf node cannot be reached when the analysis of the whole sentence is finished. Reached nodes at that time are semantic representations of ambiguous verb meanings. Consider the analytical process of the sentence ‘John took a plane to London.’ From the sentence, con- straints such as [S/John, O/plane, to/London] are ob- tained. Traversal of Figure 1 guided by these con- straints succeeds as follows: ‘John’ is human and sat- isfies a selectional restriction of subject, so node 1 is reached; it proceeds the same for ‘plane’ and ‘London,’ ‘Some under lined labels are omitted in Figure 1 for clarity. convey receive into the body go somewhere by Figure 1: A por tion of the discriminat rion the word senses of the verb ‘to take’ wit t eapon ‘0 go somewhere by hijacking network of and the node is reached representing the word sense ‘going somewhere by some form of transportation.’ In the next two subsections, we describe the mer- its and problems of using a discrimination network for semantic disambiguation. Merits of using discrimination networks for semantic disambiguation Works such as [Jacobs, 1988, Moerdler and McKeown, 1988, Lytinen, 1988, Adriaens and Small, 1988] realize the semantic disambiguation process as a downward traversal of the discrimination network. In these works, the following merits of such a network are described: in traditional approaches to word sense ambiguities, such as Hirst’s Polaroid Words[IIirst, 19871, multiple word senses tend to be treated as being unrelated to each other. The problem with this approach is that it fails to grasp common characteristics of mul- tiple word senses. The discrimination network, on the other hand, can represent similar word senses as close nodes in the network and less similar word senses as farther nodes. Therefore, the downward traversal of the network corresponds to the continu- ous refinement of an ambiguous word meaning into a more specific one[Jacobs, 1988]. a set of multiple word senses can be represented by a list, where each item in the list is a word sense. The algorithm for selecting among them - a linear search of the list - is very inefficient when candidate word senses are too numerous. It takes time 0(n), where n is the number of candidate word senses, namely the length of the list. On the other hand, the dis- crimination network’s search algorithm is considered more efficient because the downward traversal from OKUMURA AND TANAKA 991 the root node to a leaf node which represents a word sense is guided by constraints which are labels of branches, so the search space can be gradually nar- rowed down[Lytinen, 19881. This search takes time O(I), where I is the height of the tree, and is inde- pendent of the number of word senses n[Aho et al., 19831. The ambiguity in a sentence is often not fully re- solved unless information about subsequent inputs is taken into account. To cope with these cases, it must be possible to produce a partial semantic interpreta- tion of a sentence and disambiguate it by additional constraints from subsequent inputs. This is the aim of the incremental disambiguation model. The partial traversal of the discrimination network is considered to be the representation of the ambigu- ous result of partial semantic processing; the ambigu- ous result is easily represented by nodes in the net- work except leaf nodes. Making a new decision by ad- ditional constraints from subsequent inputs naturally corresponds to traversing from the current node fur- ther downward using newly obtained constraints. This method is therefore well suited for the incremental dis- ambiguation approach[Moerdler and McKeown, 19881. In the next section, we will describe some problems of past works which used the discrimination network. Problems of using discrimination networks for semantic disambiguation In the last section, we described the merits of using the discrimination network for semantic disambiguation, and asserted that the discrimination network is suited for the incremental disambiguation approach. However, the discrimination network has a problem in that it cannot be traversed and the analysis may be suspended in some node unless constraints are entered in an a priori-fixed order. Because the network is tra- versed downward from the root node, constraints must be entered one by one from thoses which are labels of branches connected to the root node. This order depends on the original structure of the network. In the above example of the sentence ‘John took a plane to London,’ constraints must be entered in the order of S/John, O/plane, to/London. Unfortunately, sur- face variations such as passive forms make it difficult . to assume that constraints are obtained in any fixed order during the analytical process. Therefore, it is not always possible to traverse the network downward during the analytical process. Adopting the semantic analysis method integrated with traditional bottom- up parsing[Matsumoto et ab., 19831, the natural or- der of the obtained constraints is O/plane, to/London, S/John for the above sentence. Traversal of Figure 1 is thus impossible. In addition, if the subject constraint is omitted, as in the case of passive sentences, traversal of the network will reach a deadlock. To cope with this problem, a solution has been sug- gested where traversal of the network is performed af- ter the total set of constraints is obtained. However, this strategy might cause combinatorial explosion of the number of total ambiguities, because semantic dis- ambiguation is delayed after the analysis of the whole sentence is finished. This approach conflicts with the idea of the incremental disambi uation model. WEP(Word Expert Parser) Adriaens and Small, B 19881 suggests another solution where special proce- dures such as demons[Charniak et al., 19801 are pro- vided for cases of irregular order of constraints, e.g. relative clause constructions. In general, the order of constraints obtained during the analytical process de- pends on the word order of the input sentence. So the degree of deviation from the a priori-fixed order is pro- portional to the degree of word-order freedom of the language to be analyzed. Therefore, this ‘special pro- cedure’ approach seems to cope with languages having less word-order freedom such as English. However, in the case of languages having greater word-order free- dom such as Japanese, the procedures for the cases of deviated order will be very large and their readability lost, if describable. The taxonomic lattice[Woods, 1978, Bobrow and Webber, 1980] is a generalization of a discrimination tree which can be traversed independently of order. However, transforming a tree into a lattice makes in- ternal representation very redundant and requires a lot of memory space in the computer system. In the next section, we propose a method which can traverse the discrimination network according to the order in which constraints are obtained incrementally during the analytical process. We call our system a ‘generalized discrimination network.’ This approach is considered to be an implementation of the incremental disambiguation model with a discrimination network. It seems to have the same expressive power as the tax- onomic lattice, but doesn’t necessiate increased mem- ory space because it uses the original ‘tree’ form as its representation. Principles of generalized discrimination networks Consider the discrimination network shown in Figure 2. Labels of branches stand for discrimination con- straints. First, a numerical string is assigned to each node as a unique identifier. ‘1’ is assigned to the root node. To each child node of the root node, an iden- tifier of two digits li(where i is an integer between 1 and n which represents the number of child nodes) is assigned. Similarly, to each child node of the node li&...im, an identifier liiiz . ..i.i(where i is an integer between 1 and n which represents the number of child nodes) is assigned. To the nodes in Figure 2, identifiers are assigned as shown in Figure 3. Second, to each node identifier a bit vector is at- tached which has the same length as the identifier and consists of l’s except for the leftmost and rightmost bits. To the identifiers in Figure 3, bit vectors are at- 992 NATURALLANGUAGE 1 0 11,12 00 111,112,113,121,122,123,124 010 1231,1232,1233 0110 Table 1: Correspondence between node identifier and bit vector alal 11 a/a2 12 bIbI { 111,1231} b/b2 (112,1232) b/b3 (113,1233} C/Cl 121 cIc2 122 cIc3 123 c/c4 124 Table 2: Correspondence between constraint and node identifier Figure 2: A sample discrimination network tached as in Table 1. This bit vector represents the positions of the unsatisfied constraints in the network. For example, identifier 122 has the bit vector 010. Be- cause the second bit from the left is 1, this vector indicates that constraint a/az, which corresponds to 12(the two digit identifier from the left of 122),2 is unsatisfied. Similarly, in the case of identifier 1232, the attached bit vector 0110 signifies that constraints a/a2 and c/cs(which correspond to the two and three digit identifiers 12, 123 of 1232), are both unsatisfied because the second and third digits are 1. Third, constraint-identifier pairs are extracted from the network in the following form: a branch and the subordinate node which is directly connected by that branch. From Figure 3, pairs in Table 2 are obtained. For the constraints of attribute name b, multiple pairs exist and so sets like { 111,1231) correspond to them. This correspondence between constraint and identifier means that if a constraint in Table 2 is satisfied, the nodes of corresponding identifiers can be reached in the network. For example, if constraint c/c, is satisfied, the network can be traversed downward to the node of corresponding identifier 122. Here, we must pay attention to the bit vector at- tached to the identifier. In the case of the above identi- 1231 1232 1233 fier 122, the corresponding bit vector 010 indicates that constraint a/a2 is unsatisfied. Therefore, the reachabil- ity of node 122 is ‘conditional’ in that node 122 can be Figure 3: Discrimination network with identifier- assigned nodes reached if constraint a/a2 is satisfied. The existence of multiple pairs means that multiple corresponding nodes can be reached if a. constraint is satisfied. The regular order of constraints is a/a2, C/Q, bIbI for traversal of the network in Figure 3 downward to 2The corresp ondence between constraint and identifier is given in Table 2 and explained later. OKUMURA AND TANAKA 993 node 1231. Here, in contrast, the case where con- straints are obtained in the order of C/Q, b/bl, u/u:! is considered. The discrimination process in our ap- proach for that case is described below. We introduce a ‘state’ which represents a discrimination process. A state is expressed as a pair ( a node identifier which can be reached, and a bit vector which represents the po- sitions of unsatisfied constraints ). The initial state(a state where no constraints are obtained) is ( l(the iden- tifier of root node),O(the bit vector corresponding to identifier 1) ). After constraint c/c3 is obtained, the state is computed as follows, with the current state(the initial state), identifier 123 corresponding to the ob- tained constraint by Table 2, and bit vector 010 corre- sponding to the identifier 123 by Table 1: operation between identifiers If one identifier in- cludes the other as a prefix-numerical string, return the longer string; operation between bit vectors After adjusting the length of bit vectors by attaching l’s to the end of the shorter vector, return the bit vector for which each bit is a conjunction of the bits of two vectors. The operation between identifiers checks whether one node can be reached from the other in the network. As shown in Figure 3, identifiers of mutually reachable nodes in the network are in prefix-numerical string re- lation with each other. For example, from node 12, nodes 121, 1232 are reachable by satisfying some con- straints, but it is impossible to reach node 112 from node 12 on any account. If one node is reachable from the other, the identifier of the subordinate one is re- turned. This operation corresponds to a downward traversal of the network by satisfying the obtained con- straints. The analysis will fail if one identifier is not a prefix of the other. For example, even if constraint c/c2 is obtained when node 11 is reached, the network cannot be traversed any more because identifier 11 is not a prefix of identifier 122, which corresponds to constraint cIc2. The operation between bit vectors allows us to cope with the irregular order of the obtained constraints. The bit vector represents all the constraints that must be satisfied between the root node and the reached node. A bit of 1 means that the corresponding con- straint is unsatisfied. Because no constraints are ob- tained, bits of the initial state bit vector are all 1 ex- cept the leftmost bit3. However, at the initial state, the reached node is unknown and the vector length is obscure. Therefore, the initial state bit vector is 0, and the vector length is adjusted by adding l’s to the end whenever a constraint is obtained. Bit vectors in Table 1 have the same length as cor- responding identifiers and their rightmost digit is 0. This means that the constraint which corresponds to 3The leftmost bit has no 1 corresponding constraint and makes the vector length the same as that of the identifier. that digit by combination of Tables 1 and 2 is satis- fied. For example, identifiers 12(with bit vector 00) and 1232(with bit vector 0110) represent the satisfac- tion of constraints CL/Q and b/b2 respectively. By tak- ing the conjunction of bits of these vectors, which rep- resent the position of the satisfied constraint as 0, bits of the current state vector are incrementally changed to 0. If all vector bits are 0, it means that all con- straints are satisfied and the network can be traversed to the reached node unconditionally. The bit conjunc- tion operation which changes bits to 0 is executable in any order from any bit, so it is possible to cope with an arbitrary order of the obtained constraints4. The next state becomes ( 123,010 ) after constraint c/c3 is obtained as the result of the above operations. The state bit vector shows that constraint U/Q, which corresponds to identifier 12, is unsatisfied. Therefore, state ( 123,010 ) means ‘the discrimination network can be traversed to node 123 if constraint u/u2 is satisfied’. Next, constraint b/b1 has multiple corresponding identifier-bit vector pairs {( 111,010 ), ( 1231,OllO )}. Operations are performed on each pair with the current state. As for ( 111,010 ), the identifiers are not in a pre- fix relation, so the analysis fails. Therefore, the result is necessary only for pair ( 1231,OllO ). The resultant identifier is 1231 from identifiers 123, 1231. The re- sultant bit vector is 0100 from the conjunction of bit vectors OlOl(the length-adjusted vector) and 0110. Bit vector 0100 shows that constraint u/u2(corresponding to identifier 12) is still unsatisfied. Finally, when constraint u/a2 is obtained, operations are performed between ( 1231,OlOO ) and ( 12,00 ). The resultant state is ( 1231,0000 ). Because all vector bits are 0, all constraints are satisfied and the discrimina- tion network can be traversed to node 1231 uncondi- t ionally. Conclusion We have proposed a method which can traverse the discrimination network according to the order in which constraints are obtained incrementally during the an- alytical process. This order is independent of the a priori-fixed order of the network. This approach is considered to be an implementation of the incremen- tal disambiguation model with a discrimination net- work. The operation between identifiers is regarded as the extended unification on class hierarchy[Dahlgren and McDowell, 1986, Sowa, 19841 in that the mutual reachability of two entered nodes is checked and, if successful, the resulting subordinate node is returned. Our approach is based on the notion of constraint logic programming[Dincbas, 19861: it gives the table be- tween constraints and corresponding identifiers, and reduces the possibilities of identifiers by unification be- *When cons traints are obtained in the regular order of the network, bits of the vector are changed to 0 from left to right in turn. 994 NATURAL LANGUAGE tween them, and renders the search space incremen- tally smaller. The problem of constraint order freedom in the dis- crimination network traversal has been countered in the past by transforming the network into a lattice. Our approach allows us to resolve the problem using the original network. This approach seems to have the same expressive power as a taxonomic lattice, but doesn’t require as much additional memory space. We think it is also possible to apply the generalized dis- crimination network to the compilation of production rules[Forgy, 19821. References [Adriaens and Small, 19881 G. Adriaens and S.L. Small. Word expert parsing revisited in a cogni- tive science perspective. In S.L. Small, G.W. Cot- trell, and M.K. Tanenhaus, editors, &e&al Ambigu- ity Resolution : Perspectives from Psycholinguitics, Neuropsychology, and Artificial Intelligence, pages 13-43. Morgan Kaufmann Publishers, 1988. [Aho et al., 19831 A. V. Aho, J. E. Hopcroft, and J. D. Ullman. Data Structures and Algorithms. Addison- Wesley, 1983. [Bobrow and Webber, 19801 R.J. Bobrow and B.L. Webber. Knowledge representation for syntac- tic/semantic processing. In Proc. of the 1st National Conference on Artificial Intelligence, pages 316-323, 1980. [Charniak et al., 19801 E. Charniak, C.K. Riesbeck, and D.V. McDermott. Artificial Intelligence Pro- gramming. Lawrence Erlbaum Associates, 1980. [Dahlgren and McDowell, 19861 K. Dahlgren and J. McDowell. Kind types in knowledge representa- tion. In Proc. of the 11th International Conference on Computational Linguistics, pages 216-221, 1986. [Dincbas, 19861 M. Dincbas. Constraints, logic pro- gramming and deductive databases. In Proc. of the France- Japan Artificial Intelligence and Computer Science Symposium 86, pages l-27, 1986. [Forgy, 19821 C.L. Forgy. Rete: A fast algorithm for the many pattern/many object pattern match prob- lem. Artificial Intelligence, 19(1):17-37, 1982. [Hirst, 19871 G. Hirst. Semantic interpretation and the resolution of ambiguity. Cambridge University Press, 1987. [Jacobs, 1988] P.S. Jacobs. Concretion: Assumption- based understanding. In Proc. of the 12th Inter- national Conference on Computational Linguistics, pages 270-274, 1988. [Lytinen, 19SS] S.L. Lytinen. Are vague words am- biguous? In S.L. Small, G.W. Cottrell, and M.K. Tanenhaus, editors, LezicaI Ambiguity Resolution * Perspectives from Psychodinguitics, Neuropsychol- . ogy, and Artificial Intelligence, pages 109-128. Mor- gan Kaufmann Publishers, 1988. [Mellish, 19851 C.S. Mellish. Computer Interpretation of Natural Language Descriptions. Ellis Horwood, 1985. [Moerdler and McKeown, 19881 G.D. Moerdler and K.R. McKeown. Beyond semantic ambiguity. In Proc. of the 7th National Conference on Artificial Intelligence, pages 751-755, 1988. [Sowa, 19841 J. F. Sowa. Conceptual Structures: Infor- mation Processing in Mind and Machine. Addison- Wesley, 1984. [Woods, 19781 W.A. Woods. Taxonomic lattice struc- tures for situation recognition. In Theoretical Is- sues in Natural Language Processing 2, pages 33-41, 1978. [Matsumoto et al., 19831 Y. Matsumoto, et.al. BUP:a bottom-up parser embedded in Prolog. New Gener- ation Computing, 1(2):145-158, 1983. OKUMURAANDTANAKA 995
|
1990
|
168
|
924
|
uly Parallel u g of Text* Yeong-Ho Yu and Robert F. Simmons Artificial Intelligence Laboratory The University of Texas at Austin Austin, Texas 787’12 yu@cs.utexas.edu, simmons@cs.utexas.edu Abstract Understanding a text requires two basic tasks: making inferences at several levels of knowledge and compos- ing a global interpretation of the given text from those various types of inferences. Since making inferences at each level demands an extensive computations, there have been several attempts to use parallel inference mechanisms such as parallel marker passing (PMP) to increase the productivity of the inference mecha nism. Such a mechanism, when used with many local processors, is capable of making inferences in paral- lel. However, it often poses a large burden on the task of composing the global interpretation by producing a number of meaningless inferences which should be filtered out. Therefore, the increased productivity of the inference mechanism causes the slow down of the task of forming the global interpretation and makes it the bottleneck of the whole system. Our system, TRUE, effectively solves this problem with the Con- strained Marker Passing mechanism. The new mech- anism not only allows the system to make necessary inferences in parallel, but also provides a way to com- pose the global interpretation in parallel. Therefore, the system is truly parallel, and does not suffer from any single bottleneck. Introduction Understanding a text requires making inferences from several levels of knowledge such as syntax, semantics, and pragmatics (Allen 1987). Since the computation needed for this tends to be huge,there has been a trend toward utilizing parallel inference mechanisms such as parallel marker passing (PMP) to reduce the computational burden (Norvig 1987, Charniak 1986, Eiselt 1985, Riesbeck & Martin 1985). Such a mechanism, when used with many local pro- cessors, is capable of making inferences on different parts of a sentence in parallel and finding all possible inferences in a short time. For example, in a sentence like “John saw a man on a hill,” some local processors may be used to make the necessary inferences between *This work is sponsored by the Army Research Office under contract DAAG29-84-K-0060. 996 NATURALLANGUAGE INPUT TEXT + GLOBAL Figure 1: A Bottleneck in PMP John and sutu, while other local processors are making inferences between suw and a man. Moreover, the mechanism allows the system to pur- sue all possible inferences at the same time if there is any ambiguity in the given text. For instance, in the previous sentence, there is a PP-attachment ambiguity of “on a hill.” In this case, such a system may make all possible inferences and decide later which one is correct (or better) in the given context. Since there are many types of possible parallelism - inter-level parallelism, inter-phrasal parallelism, and inter-sentential parallelism- the potential gain from PMP is very large. However, making the inferences is not the only task in a text understanding system. As a matter fact, it is only a part of it. The other part is to construct a global interpretation of the given text from those inferences. Unfortunately, the parallel inference mech- anisms used in most previous works generate a huge number of inferences, most of which are meaningless. For instance, (Norvig 1987) had to generate over 230 inferences to understand a three-sentence text, even though only seven of them were meaningful. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Figure 2: TRUE Architecture Figure 3: Parallel Marker Passing Therefore, a fibtering/evabuation step is needed to re- move those meaningless inferences. Also, to find the best interpretation in the presence of ambiguities, the filtering/evaluation step often has to compare several inferences and has to be implemented as a serial pro- cess like Figure 1. From the system’s viewpoint, the filtering step tends to be the bottleneck of the whole system, and negates the benefits of PMP. Our system, TRUEl, solves the problem in two ways. First, it reduces the number of total inferences by pruning meaningless inferences as soon as possi- ble and by utilizing the interactions of three levels of knowledge so that only necessary inferences are made. Secondly, TRUE distributes the filtering step over lo- cal processors so that there is no single bottleneck. The basic mechanism behind all of these is a parallel mechanism called Constrained Marker Passing, which is the subject of the next section. Constrained Marker Passing Figure 2 shows the architecture of TRUE with its three levels of knowledge: syntax, semantics, and pragmat- its. All three levels are homogeneous in their repre- sentation and processing mechanisms: they each use a network of connected nodes2 to represent their knowl- edge and all use a parallel mechanism called Con- strained Marker Passing (CMP) in making inferences. The result of the whole computation is a text network that represents an understanding of the given text in the form of a connected, coherent network of semantic concepts. Initially, the text network is empty. When a new sentence is read, the system makes nodes for all ‘It stands for True Readers Understand Efficiently. 2Even though concept, otode, and locasl processor- are three different entities, they are used interchangeably in this paper. The actual distinction is that a concept is rep- resented as a pzode in our network representation while a node is implemented by a loccal processor in our parallel implementation. possible concepts for each word in the sentence3, while connecting them to the syntactic category nodes and semantic superclass nodes in the knowledge network as well as to the nodes for the words in the sentence4. Managing the text network and creating new nodes for newly-inferenced relations among concepts in the text network are the only tasks required of the central pro- cess; all other computations are localized in the nodes. Like all the other parallel marker passing mecha- nisms, CMP finds an inference by detecting the colli- sion of two markers which have traveled through the connected nodes of the knowledge base. However, it is different from other parallel marker passing mech- anisms in that it has programmable markers. While other PMP mechanisms utilize only one or two types of markers which are passed to all the neighbors indis- criminately and collide with other markers anywhere as in Figure 3, in CMP, there are many types of mark- ers each of which is constrained to travel only through pre-defined patterns of paths in levels of the networks and to interact only with pre-specified markers at pre- specified locations as in Figure 4. The number of markers and the definitions of them are decided by the programmer. For the given task of making some specific types of inferences- inference paths in the network- the programmer decides how such paths may be found and defines markers for them. For instance, in Figure 4, to find a case (or seman- tic) relation, a programmer defines new types of mark- ers which ascend isa hierarchies and collide with each other at a case relation. To help the programmer to define markers easily and efficiently, TRUE provides Marker Definition Lan- guage (MDL). 3Lexical ambiguities will cause multiple concept nodes for words, and they will be resolved in the same way as other types of ambiguities are resolved. 4See Figure 7 for an example of the text network. YUAND SIMMONS 997 Markers are &itiated w markers from ---+ markers from Figure 4: Constrained Marker Passing Marker Definitions and MDL A marker definition consists of the four fields: marker type, authorized paths, special actions, and collision specifications. Marker type represents the identifica- tion symbol for the marker while authorized paths specify the pattern of paths which the marker may travel. These paths are described in the form of regu- lar expressions. Special actions are actions to be taken in the middle of the paths. Collision specifications de- fine the details of marker collision such as with what marker to collide, where, when, and what actions to be taken after a collision. Currently, MDL is a LISP function and all the values of the fields are given as arguments of the function. Figure 5 shows the definition of the marker used in Figure 4. Note that the patterns are given as regular expressions and may be used to find an infinite number of different paths. Marker Processing Tables Even though it is easier for the programmer to en- vision a marker as an active entity which travels the network for itself, and to define the definition for it, in the actual implementation , a marker is a passive entity passed around by the local processors (nodes). Therefore, it is the responsibility of the nodes to pro- cess the markers appropriately. The instructions of how to handle arriving markers are given as a table called the Marker Processing Ta- ble (MPT). This table has four fields: marker type, conditions, actions, and out-going markers, and may have several entries for different types of markers. The algorithm for processing markers at a node is shown in Figure 6. A marker is terminated when there is no MPT entry for its type or when the conditions of the entry fail. Otherwise, the specified actions are taken, and new markers are passed to the appropriate neigh- bors. marker type CS(case-search) A marker for finding a case relation. authorized path instxpt.(isa.cpt)*.case-rel It travels through an instance-of link to a concept node, then, a chain of isa links and concept nodes to a case relation node. special actions None. This one has none. However, other types of markers have actions like getting some values from the nodes in the middle of the path. collision specifics with: CS where: at the end of the path when: always actions: send NC to CP send ARG to INST It collides only with another CS at the end of a path of the defined pattern under any condition. As a result, a NC marker will be sent to CP and a ARG marker to INST neighbors. Figure 5: A Marker Definition All the nodes use the same algorithm, but have dif- ferent MPT’s which are compiled from the marker def- initions. Therefore, in the example of Figure 4 and Figure 5, the MPT’s of all those nodes (i.e., isa, con- cept, and agent) of the authorized paths have entries for that type of marker while others don’t. This al- gorithm provides an efficient way for automatic termi- nations of markers as soon as they deviate from the authorized paths. Advantages of CMP The most important advantage of CMP is that, through careful programming, the system only gener- ates the necessary inferences without making meaning- less ones. Secondly, since the markers are terminated as early as possible, the marker traffic is very light compared with other mechanisms. Since the overall performance of a parallel system often depends on the communication time among local processors, this light traffic may improve the overall system performance substantially. Finally, the programmability of markers and MDL provides the programmer with a way to define markers for fine-gruined interactions among nodes at different levels. As it will be shown in the following sections, through these interactions between levels, TRUE not only generates the necessary inferences, but also finds the best inference in the presence of ambiguities. Three Levels and Their Interactions In this section, the summaries of how several kinds of inferences are made in those three levels and how 998 NATURAL LANGUAGE Figure 6: Algorithm for Local Processors interactions between levels minimize the number of in- ferences generated are presented. More details can be found in (Yu & Simmons 90). Each level makes different types of inferences. The syntax level looks for syntactic relations such as spec- ify and modify which have their origins in x grammar. Roughly speaking, they are equivalent to the left and right branches in conventional parse trees. When the initial text network is instantiated with the given sen- tence, all the concept nodes in the network send out markers for syntactic relations. The markers travel through the syntax network which has the knowledge of English grammar such as “an NP specifies a VP” and “a PP modifies an NP or a VP.” As a result, this network will find all possible syntactic relations in the text. The semantic level searches for case relations among concepts in the text such as agent between saw and John or uflected-entity(ae) between su2u and a man in the sentence “John saw a man on a hill”. The search for a case relation is initiated when a syntac- tic relation is found in the syntax level. For instance, in the previous sentence, the new syntax relations be- tween John - saw, saw - a mun, a - hill, etc. initiate the searches for case relations between those concepts resulting in the case relations, agent, uflected-entity, and number respectively. The rationale behind this bottom-up interaction is to prevent the system from finding a syntactically-incorrect case relation such as uflected-entity between saw and a hill, and to reduce the amount of computation in the semantic level with the help from the syntax level. In TRUE, this interaction is stated in the definition of markers for the syntactic relations. That is, the definitions of the markers for syntactic relations have collision specifications, a part of which tells the node to fire markers for case relations when a collision between ABBREV: 0 CASEREL <::3 SYNTATIC REL --_- COND link NUM: NUMBER L-DC: LOCATION MOD: MODIFY SPEC: SPECIFY Figure 7: A Sample Text Network two syntactic markers occurs. Figure 7 shows the text network after the syntax and semantic levels have made all possible inferences for the sentence “John saw a man on a hill.” Note that there are two possible syntactic relations coming out from “on a hill” due to the PP-attachment ambiguity. The dotted lines- a graphical abbreviation for cond links- connect the related syntactic and case relations. The pragmatic level tries to find the coherence relations between event and state concepts (usually verbs)(Alterman 1982) in the given text. For instance, there is a coherence relation(untecedent) between a concept give and have- to give something to some- body, one hus to have it first. The knowledge about this coherence relation can be stated as a rule as be- low: If ugent(ownership) = ugent(ownership-transfer) and uflected-entity(ownership) = uflected-entity(ownership-transfer) then ownership is an antecedent of ownership-transfer. This rule requires some argument matchings for the coherence relation to be instantiated. This is to pre- vent a false coherence relation from being inferred. For instance, it is wrong to infer an antecedent relation be- tween had and gave in the sentences like “John had an old bike. His father gave him a new bike.” In the same way that the syntax level activates the semantic level, the inferences made at the semantic level activate the search for coherence relations at the pragmatic level. When a case relation is instantiated as a node in the text network, it initiates markers which travel through the part of the pragmatic network which represents the argument matching conditions. If all the conditions of a coherence relation are met through the collisions of markers from the arguments, then the coherence relation is instantiated in the text network. Through this guidance from a low level to a high level, TRUE accomplishes the task of minimizing the YUAND SIMMONS 999 number of inferences without loosing any valid ones. There is another type of inference which has not been described so far. It is that of finding possible referents for pronouns in the sentence. This is also done through separate types of markers which are ac- tivated as soon as the sentence is instantiated in the text network. Distributed Filtering There are two reasons for filtering the inferences in other systems: to eliminate the meaningless inferences, and to find the best inference out of several inferences generated from an ambiguity and form a globally co- herent interpretation for the given text. In TRUE, there are no meaningless inferences and subsequently no need for such elimination. However, TRUE still generates multiple inferences for ambiguous parts of the text, and has to find the best one among them. For instance, in a three-sentence text, “John had a bike. Bill wanted it. He gave it to him.“, there are ambiguities in the referents for pronouns he and him. In the beginning, markers for pronoun referents find both John and BilZ as possible candidates for both pronouns. To resolve this kind of ambiguity, the system has to depend on the inferences made at the higher levels. For instance, the inference of a coherence relation between have and give makes John as the preferable referent for He since the knowledge says that the agents of have and give have to be the same to have such a coherence relation. In reality, there are many kinds of ambiguities and this constitutes the biggest problem in understanding a text. There have been two approaches in finding the best out of multiple inferences: centralized and dis- tributed. The centralized approaches like (Charniak 1986, Norvig 1987) gather all inferences at a central process and compare them by applying several heuristics. This approach, even though it is easier to implement, has an apparent disadvantage over the distributed approach: the central process may turn out to be the bottleneck of the system. Therefore, TRUE takes a distributed approach sim- ilar to those of (Waltz & Pollack 1985, Howells 1988). In these local connectionist systems, each node has a real value called its activation leveZ and links between nodes have weights. The activation level of a node is computed from the sum of the products of the acti- vation levels of neighbors and the weights of the links between itself and the neighbors. In this scheme, a negative weight between two nodes indicates that they are mutually exclusive while a positive weight indicates that they are mutually inclusive. After a number of cy- cles, the activation levels of all nodes may converge to stable values. Then, the nodes with high activation levels are declared as winners. However, this approach also has a disadvantage. That is, the network should be pre-wired with appro- priate weights. In TRUE, the text network grows as a new sentence comes in and as new inferences-are made. So, it has no way to decide the proper weights in ad- vance and has to use another method to compute the activation levels. Instead of re-calculating its activation level periodi- cally, a node in TRUE changes its activation level only when an activation-change marker arrives either from a node which is connected to it through a cond link, or from its competitor. In the first case, the activa- tion level is increased while, in the second case, it is decreased5. Note that a node is connected to another through a cond link only when two nodes are at dif- ferent-levels and they are related. For example, a case relation is connected to a syntactic rel .ation through a cond only when the search for the initiated from the syntactic relation case relation WaS Therefore, when a marker initiated from a low level succeeds in 6 nding a relation in a higher level, the new _ node for the high level relation sends out an uctivution- change marker-which will increase the activation level of the node for the low level relation. This top-down interaction may be interpreted as the principle that, when an inference made at a low level results in an inference at a high level, the inference at the low level is rewarded through an increase of its activation level. When the activation level of a node changes, it sends out activation-change markers to its competitors and the nodes which are connected with it through cond links so that they may adjust their activation levels. Figure 8 shows a simplified6 final text network of the three-sentence text mentioned above. In the fig- ure, those concepts and relations which are involved in the ambiguities are drawn with bold lines, while irrel- evant ones are drawn with shaded lines. Two shaded boxes emphasize two ambiguities resulting from two prosnouns - He and him. Among those ambiguous relations, the winners -those that are included in the global interpretation- are drawn with the white back- ground. In the beginning, the ambiguity of He causes two ref- erent relations (refer-3, refer-d) to be generated, which in turn enable two ugent relations (agent-3, agent-d) to be generated and connected to them through cond rela- tions (dotted lines). When an antecedent relation is in- ferenced between had and gave, the argument match- ings increase the activation level of agent-3, which in turn increases that of refer-3. Then, they decrease the activation levels of their competitors- agent-4 and refer-4 respectively. Discussion Parallelizing a part of a system does not necessarily im- prove the overall system performance. In some cases, it 5The amount of change depends on several factors. Re- fer (Yu & Simmons 90) for more details. ‘For the sake of readability, the syntactic relations, isa relations, and some other relations are not shown. 1000 NATURALLANGUAGE 1 To 1 1 Him [ M He Figure 8: A Simplified Final Text Network may worsen the system performance by putting a huge burden on a single bottleneck. Unfortunately, this is the case for most systems based on parallel marker passing. Their major bottleneck has been the filtering step which slows down the system greatly due to the huge number of meaningless or ambiguous inferences. TRUE, on the other hand, does not generate any meaningless inferences and finds the best inference among ambiguous ones efficiently. This is accom- plished through Constrained Marker Passing, the bi- directional interactions between three levels of knowl- edge, and the distributed filtering step. There are other systems which share some common characteristics with TRUE. For instance, (Sumida, Dyer, & Flower 1989) uses another type of constrained marker passing which is similar to CMP. However, CMP is more general and powerful and pro- vides a programmer with MDL and its compiler so that the programmer may define new types of markers freely without affecting existing ones. (Norvig 1987, Eiselt 1985) use the technique of pruning meaningless inferences paths. But, the prun- ing is done at a centralized process and tends to be the bottleneck of the systems. Currently, TRUE is implemented in a Symbolics LISP machine on top of a simulator for CMP. All the knowledge base and marker definitions are written in a format easy for a programmer and compiled into a knowledge network and a set of MPT’s. Currently, there are about thirty types of markers in TRUE. The implementation of TRUE in the Connection Machine is under way. References Allen, J. 1987. Natural Language Understanding, Ben- jamin/ Bummings Publishing Co. Alterman R-E.. A System of Seven Coherence Rela- tions for Hierarchically Organizing event concepts in text. Tech Report, TR-209, AI Lab, Univ of Texas. Charniak, E. 1986. A Neat Theory of Marker Passing. In Proceedings of the Fifth National Conference on Artificial Intelligence. Menlo Park, Calif.: AAAI. Eiselt, K.P. 1985. A Parallel-Process Model of On-Line Inference Processing. In Proceedings of the Ninth In- ternational Joint Conference on Artificial Intelligence. Menlo Park, Calif.: IJCAI, Inc. Howells, T. 1988. Vital: A Connectionist Parser. In Proceedings of the Tenth Annual Conference of the Cognitive Science Society P. Norvig. 1987. Unified Theory of Inference for Text Understanding. Ph.D. diss., EECS, UC Berkeley. Riesbeck, C.K., and Martin, C.E. 1985. Direct Mem- ory Access Parsing, Technical Report YALEU-DCS- RR 354, Dept of Computer Science, Yale University. Sumida, R.A.; Dyer, M.G.; and Flowers, M. 1988. In- tegrating Marker Passing and Connectionism for Han- dling Conceptual and Structural Ambiguities. In Pro- ceedings of the Tenth Annual Conference of the Cog- nitive Science Society. Waltz, D.L., and Pollack, J.B. 1985. Massively Parallel Processing: A Strongly Interactive Model of Natural Language Interpretation. Cognitive Science, 9( 1). Yu, Y., and Simmons, R.F. 1990. Bi-Directional Inter- actions in a Parallel Text Understanding System, Tech Report, AI90-131, AI Lab, University of Texas. Yu AND SIMMONS 1001
|
1990
|
169
|
925
|
Two views of beliefi Belief as generalized robability and belief as evidence Joseph Y. Halpern Ronald Fagin IBM Almaden Research Center San Jose, CA 95120 email: halpern@ibm.com, fagin@ibm.com Abstract Belief functions are mathematical objects defined to satisfy three axioms that look somewhat similar to the axioms defining probability functions. We argue that there are (at least) two useful and quite different ways of understanding belief functions. The first is as a gen- eralized probability function (which technically corre- sponds to the lower envelope or i&mum of a family of probability functions). The second is as a way of repre- senting evidence. Evidence, in turn, can be understood as a mapping from probability functions to probability functions. It makes sense to think of tipdating a be- lief if we think of it as a generalized probability. On the other hand, it makes sense to combine two beliefs (using, say, Dempster’s t%Ze of combination) only if we think of the belief functions as representing evidence. Many previous papers have pointed out problems with the belief function approach; the claim of this paper is that these problems can be explained as a consequence of confounding these two views of belief functions. 1 Introduction A beZief &n&ion is a function that assigns to every subset of a given set S a number between 0 and 1. Intuitively, the belief in a set (or event) A is meant to describe a lower bound on the degree of belief of an agent that A is actually the case. The cor- responding upper bound is provided by a plaslsibil- ity finction. The idea of a belief function was in- troduced by Dempster [Dem67, Dem68] (he uses the terms lower probabizity for belief and upper probabiz- its, for plausibility ), and then put forth as a frame- work for reasoning about uncertainty in Shafer’s semi- nal work A Mathematical Theory of Evidence [Sha76a]. Since then belief functions have become a standard tool in expert systems applications (see, for example, [Abe88, Fa188, LU88, I&83]). While belief functions have an attractive mathemat- 112 AUTOMATEDREASONING ical theory and many intuitively appealing properties, there has been a constant barrage of criticism directed against them, going back to when they were first in- troduced by Dempster (see the discussion papers that appear after [Dem68], particularly the comments of Smith, Aitchison, and Thompson). The fundamental concern seems to be how we should interpret belief functions. This point is made in a particularly sharp way by Diaconis and ZabeIl [Dia78, DZ82]. They con- sider the three prisoners problem, and show that apply- ing the the belief function approach to this problem, particularly Dempster’s WZe of combination (which is a rule for combining two belief functions to produce a new belief functions) leads to counterintuitive re- sults. Other authors have shown that the belief func- tion approach leads to counterintuitive or incorrect au- swers in a number of other situations (see, for example, [Ait68, Bla87, Hun87, Lem86, Pea88, Pea89]). In this paper, we argue that all these problems stem from a confounding of two different views of belief fimc- tions: the first is as a generalized probability function, while the second is as a representation of evidence. In the remainder of this introduction, we briefly sketch these two views. Formally, a belief function can be defined as a func- tion satisfying three axioms (just as a grosLp is a math- ematical object satisfying a certain set of axioms). These axioms can be viewed as a weakening of the axioms that characterize probability functions. From that point of view, it seems reasonable to try to un- derstand a belief function as a generalized probability function. There are in fact many ways of relating belief functions to probability functions (see, e.g., [Dem67, Dem68, FH89b, FH89a, Kyb87, Rus87, Sha79]). The approach we focus on here is a well-known one, going back to [Dem67], where a belief function is viewed as the lower enveZope of a family of probability functions: the belief in a set A is the infimum of the probability of A, where the infimum is taken over all probability functions in the family. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. This view of a belief function as a generalized prob- ability function is quite different from the view taken by Shafer in [Sha76a]. Here, belief is viewed as a rep- resentation of evidence. The more evidence we have to support a particular proposition, the greater our belief in that proposition. Now the question arises as to what exactly evidence is, and how it relates to probability (if at all). Notice that if we start with a probability function and then we get some evidence, then we can update our original probability function to take this evidence into account. If the evidence comes in the form of an observation of some event B, then this updating is typically done by moving to the conditional probability. Starting with a probability function Pr, we update it to get the (con- ditional) probability function Pt(-IB). This suggests that evidence can be viewed as a function that takes as an argument a probability function and returns an updated probability function. By using ideas that al- ready appear in [Sha76a], it can be shown that a belief function can in fact be viewed as representing evidence in this sense. This point is perhaps best understood in terms of an example. Imagine we toss a coin that is either a fair coin or a double-headed coin. We see k heads in a row. Intuitively, that should provide strong evidence in favor of the coin being a double-headed coin. And, indeed, if we encode this evidence as a belief function following the methodology suggested in [Sha76a], we find that the larger k is, the stronger our belief that the coin is double-headed. On the other hand, seeing k heads in a row tells us nothing about the probabil- ity that the coin is double-headed. For example, if we know that a priori, the probability of the coin being fair is .9999 and k = 8, then it is still quite probable that the coin is fair. Once we are given a prior prob- ability on the coin being fair then, using conditional probability, we can compute the probability that the coin is fair given that we have observed k heads. If we use Shafer’s method, then it can be shown that the conditional probability is exactly the result of using the rule of combination to combine the prior probabil- ity with the belief function that encodes our evidence (the fact that we have seen k heads). Thus, the belief function provides us a way of updating the probabil- ity function, that is, with a way of going from a prior probability to a posterior (conditional) probability. Once we decide to view belief functions as repre- sentations of evidence, we must tackle the question of how to go about representing evidence using belief functions. A number of different representations have been suggested in the literature. We have already men- tioned the one due to Shafer; still others have been sug- gested by Dempster and Smets [Dem68, Sha82]. Wal- ley [Wal87] compares a number of representations of evidence in a general framework. In the full paper we review his framework, and present a slight strength- ening of one of his results, showing that perhaps the best representation is given by a certain belief function that is also a probability function, in that it is the only representation satisfying certain reasonable properties that acts correctly under the combination of evidence. Both of the viewpoints discussed here give us a way of understanding belief in terms of well-understood ideas of probability theory. (Indeed, the distinction between the approaches is closely related to the well- known distinction in probability theory between abso- Z&e beliefs and belief updates; see [HH86] for discussion and further references.) However, as we show by exam- ple, these two viewpoints result in very different ways of modelling situations (although, if we do things right, we expect to reach the same conclusions no matter which viewpoint we take!). The major difference be- tween the viewpoints is how they treat new evidence. If we view belief as a generalized probability, then it makes sense to update beliefs but not combine them. On the other hand, if we view beliefs as a representa- tion of evidence, then it makes sense to combine them, but not update them. This suggests that the rule of combination is appropriate only when we view beliefs as representations of evidence. A way of updating be- liefs, appropriate when we view beliefs as generalized probabilities, is described in [FH89a]. It seems that all the examples showing the counterintuitive nature of the rule of combination arise Corn an attempt to combine two beliefs that are really being viewed as generalized probabilities. The confusion between the two views seems preva- lent throughout the literature. For example, in [LG83], belief functions are used to represent the evidence of sensors; yet, they are introduced as generalized prob- abilities. That is, it is argued that a belief function which assigns BeZ(A) = l/3 and PI(A) = 2/3 is appro- priate to represent the fact that a reading on a sensor gives us uncertain information about the true probabil- ity of A, and all that can be said about the probability of A is that it is between l/3 aud 2/3. Yet these belief functions which are viewed as generalized probabilities are combined using the rule of combination. As our results suggest, this may lead to inappropriate repre- sentations of evidence. In the remainder of the report, we give a brief overview of our results. The reader is encouraged to consult the full paper [HF89] for details. HALPERNANDFAGIN 113 2 Belief as generalized probability A belief function on a set S is a function BeZ: 2’ + [0, l] satisfying: BO. BeZ(0) = 0 Bl. BeZ(A) 2 0 B2. BeZ(S) = 1 BS. BeZ(A1 U . . . U Ak) 2 c IC{ l,..., kj, &-l)~‘~+lWfli~~ Ai). For every set A, we deJ.ne PI(A), the pkusibility of A, as PI(A) = 1 - BeZ(A) (where we use A to denote the complement of A). It is not hard to show (using Bl, B2, and B3) that PI(A) 2 BeZ(A) for every set A. intuitively, we can view the interval [BeZ(A), PI(A)] as providing lower and upper bounds on the “likelihood” or probability of A. There are a number of ways of making this precise. We focus on one that goes back to [Dem67]. Given a set P of probability functions all defined on a sample space S, defme’the Zower envelope of P to be the function f such that for each A C S, we have f(A) = inf{Pr(A) : Pt E P}. We have the cor- responding definition of upper envelope of P. It was already known to Dempster [Dem67] that a belief func- tion can be viewed as a lower envelope. More formally, let BeZ be a belief function defined on S, and let Pr be a probability function on S. We say that Pr is con- sistent with BeZ if BeZ(A) 5 Pr(A) 5 PZ(A) for each A C S. lutuitively, Pr is consistent with BeZ if the probabilities assigned by P+ are consistent with the intervals [BeZ(A), PI(A)] given by the belief function BeZ. Let ~~~~ be the set of all probability functions consistent with BeZ. The next theorem tells us that the belief function BeZ is the lower envelope of PBel and PI is the upper envelope. Theorem 2.1: Let BeZ be a belief fmction on S. Then for all A C_ S, we have Bez(A) = inf~+~~~.~ Pt(A) WA) = s”PPscg7Q3cl Pt(A). We remark that the converse to Theorem 2.1 does not hold: not every lower envelope is a belief function (see [Dem67, Kyb87, Bla87, Pea891 for counterexamples). If we start with a probability function Pr and then get some new evidence B, we update it to the con- ditional probability function Pr(m1.B). Analogously, we can update a belief function viewed as a lower envelope by taking the lower envelope of the family of probabil- ity functions. Thus, we define: BeZ(AjB) = p,gB I WW) P+W) = pr;yB e 1 P+lB). It is not hard to see that the infmmm and supre- mum above me not well-defined unless BeZ(B) > 0; therefore, we define BeZ(AIB) and PZ(AIB) only if BeZ(B) > 0. It is also straightforward to check that if BeZ is actually the probability function Pt, and A and B are measurable sets with respect to Pr, then BeZ(AIB) = Pt(A(B). Thus, our definition of condi- tional belief generalizes that of conditional probability. As shown in [FH89a], there are elegant closed form expressions for conditional belief and plausibility. Theorem 2.2: If BeZ is a belief finction on S such that BeZ(B) > 0, we have BeZ(AIB) = BeZ(A n B) BeZ(A n B) + PZ(An B) PZ(AIB) = PZ(A n B) PZ(A n B) + BeZ(xn B)’ In order to argue that this is a reasonable way to update belief functions, we must also show that, just as the conditional probability function is a probability function, the conditional belief function is a belief func- tion. Fortunately, we have the following result from [FH89a]: Theorem 2.3: Let BeZ be a beZief fxnction defined on S and PZ the corresponding plausibility fqmction. Let B E S be smh that BeZ(B) > 0. Then BeZ(=(B) is a belief function and PZ(.IB) is the corresponding plausibility function. Our definition of conditional belief and plausibility is quite different from that given by Dempster. He defines BeZ(AIIB) = BeZ(A U 3) - BeZ(B) 1 - BeZ(B) * BeZ(.IIB) is indeed a belief function, and the corre- sponding plausibility function satisfies PZ(AIIB) = “&;;). For the remainder of this paper, we call this the DS notion of conditioning. While this definition has a rea- sonable motivation (which we discuss in the next sec- tion), it is well known to occasionally give counterin- tuitive answers. In [FH89a], the DS notion is carefully compared to our notion of conditioning. Our notion is shown to give reasonable answers in the cases where the DS notion does not. The discrepancy between the two notions can be explained by analyzing both in terms of conditional probability; the DS notion can be shown to correspond to a somewhat unusual updating process. (The reader is encouraged to consult [FHSSa] for more details.) 114 AUTOMATED REASONING 3 Belief as evidence function BeZ and a prior probability Pt, we transform this to a posterior probability PT’ by using the rule of combination. That is, we can consider the mapping Pr I-+ P# = Pr $ BeZ. A p~iori, it is not clear that this mapping does anything interesting. Clearly, for this mapping to have the “right” properties, we need to consider how to represent evidence as a belief func- Up to now we have viewed belief as a generalized prob- ability. This does not seem to be the view of belief that Shafer espouses in [Sha76a]. He talks of belief as being a representation of a body of evidence. To say that BeZ(A) = p is to say that, as a result of the evidence encoded by BeZ, the agent has a degree of belief p in the proposition represented by the set A. From this point of view, it makes sense to combine two belief functions BeZl and BeIs. The resulting be- lief function BeZ is meant to represent the combined evidence encoded by each of BeZl and BeZz separately. In order to combine two or more independent pieces of evidence, Shafer suggests the use of Dempst er’s mZe of combination. For reasons of space, we omit the defi- nition of the rule of combination in this abstract; de- tails can be found in [Sha76a]. The reader not familiar with it should still be able to follow our main points. We denote by Bell $ BeZs the belief function obtained by combining the belief functions BeZl and BeZ2 using Dempster’s rule of combination. Shafer presents many examples of the intuitively ap- pealing nature of the rule of combination in [Sha76a]. He also shows that in some sense we can use the rule of combination to capture the idea of updating a belief function as the result of learning new evidence. The effect of learning B can be captured by the belief fimc- tion Leaf nB, which assigns belief 1 to every superset of B, and belief 0 to every set which is not a superset of B. It is this idea of learning that is used to define the DS notion of conditional belief. In fact, it can be shown that BeZ(-IIB) = BeZ $ LearnB; i.e., BeZ(-IIB) is the result of combining BeZ with the belief function that corresponds to learning B. This definition may seem quite natural. If we view BeZ as a representation of evidence, then a case can be made that BeZ(-IIB) p re resents that body of evidence that results from combining the evidence encoded by BeZ with the evidence that B is actually the case. On the other hand, if we view BeZ as a generalized prob- ability distribution, we can no longer expect that the rule of combination should correspond to a natural up- dating process. In fact, as shown in [FH89a], it does not. The key point here is that updating and combin- ing are different processes; what makes sense in one context does not necessarily make sense in the other. The discussion above suggests that, whatever evi- dence is, evidence and probability are different. They are related though. A probability function gets up- dated as a result of evidence. This suggests that one way we can represent evidence is as an update function. As we shall see, belief functions can indeed be viewed as update functions. The idea is that given a belief tion. 3.1 Representing evidence In most of the examples given in [Sha76a], subjec- tive degrees of belief are assigned to various events in the light of evidence. Although Shafer shows that the degrees of belief seem to have reasonable qualit a- tive behavior when the evidence is combined, there is no external notion of “reasonable” against which we can evaluate how reasonable these numbers are. The one place where there is an external of reasonableness comes in the area that Shafer terms statistical evidence. In this case, we have numbers provided by certain con- ditional probabilities. A prototypical example of this type of situation is given by the following coin-tossing situation. Imagine a coin is chosen from a collection of coins, each of which is either biased towards heads or biased towards tails. The coins biased towards heads land heads with probability 2/3 and tails with probability l/3, while those biased towards tails land tails with probability 2/3 and heads with probability l/3. We start tossing the coin in order to determine its bias. We observe that the first k tosses result in heads. Intu- itively, the more heads we see without seeing a tail, the more evidence we have that the coin is in fact biased towards heads. How should we represent this evidence in terms of belief functions? Suppose that we have a space S = (BH, BT}, where BH stands for biased towards heads, and BT stands for biased towards tails. Let BeZh be the belief function on S that captures the evidence in favor of BH and BT as a result of seeing the coin land heads once. We would certainly expect that BeZh(BH) > BeZh(BT), since seeing the coin lands heads provides more evidence in favor of the coin being biased towards heads than it does in favor of the coin being biased towards tails. But what numeric values should we assign to BeZh( BH) and BeZh(BT)? A ccording to a convention introduced by Shafer [Sha76a, Chap. 111 (discussed in detail in the full paper), we should take BeZh(BH) = l/2 and BeZh(BT) = 0. By symmetry, the belief function Belt representing the evidence of the coin landing tails sat- isfies Belt (B H) = 0 and BeZl(BT) = l/2. Note that PZh(BH) = 1 and PZ,JBT) = l/2. Thus, the ratio PZh(BH) : PZ,JBT) = 2 : 1, which is precisely the HALPERNANDFAGIN 115 ratio of the probability of the observation heads given BH (namely, 2/3) to the probability of heads given BT (namely, l/3). We will make use of this fact later. If we assume that our observations are indepen- dent, then it seems reasonable to expect that the belief function which represents the observation of k heads should correspond in some sense to combin- ing the evidence of observing one head k times. Let BeZk = BeZh $ n - - $ BeZh (k times); it can be shown that BeZk(BT) = 0 and BeZk(BH) = (2” -1)/2k. This seems qualitatively reasonable. ‘lcf we see k heads in a row, then it is much more likely that the coin is biased towards heads than that it is biased towards tails. It is also easy to compute that (BeZh @ BeZt)(BH) = (BeZh @ BeZt)(BT) = l/3. Again, it seems reasonable that if we see heads followed by tails, we should have no more evidence in favor of the coin being biased towards heads than it being bi- ased towards heads (although the particular choice of l/3 as the appropriate amount of evidence may seem somewhat mysterious). What do these numbers tell us about the probability that the coin is biased towards heads or biased towards tails? Without knowing something about how the coin is chosen, probability theory does not give us much guidance. For example, if the coin was chosen at ran- dom from a collection of 1, 000,000 coins only one of was biased towards heads and all the rest biased to- wards tails, then even after seeing 10 heads in a row, we would still say that it is extremely likely that the coin is biased towards tails. Now suppose that we know that the coin was chosen at random from a collection with proportion ar of coins biased towards heads and 1 - (Y of coins biased towards tails. By definition, Pr(BHlk heads) = P+(BH A k heads)/Pt(k heads). A straightforward computation now shows that the conditional probability is 2'a/(l+ (2" - 1)cr). As ex- pected, this probability approaches 1 as k gets larger. Let BeZ be the belief function that describes the ini- tial probability; thus BeZ(BH) = a and BeZ(BT) = 1 - a. If we define Bell = BeZ @ BeZh and BeZk = BeZ @ BeZk, then a straightforward computation shows BeZl = Pr(-Iheads) and BeZk = Pt(-IX: heads). By combining the prior with the belief function that rep- resents the evidence, we get the posterior. The same phenomenon occurs if we combine the prior with Belt. Judging by this example, Shafer’s definition of BeZh and Belt has two very interesting properties, namely: e when we combine BeZh with a prior on S = 116 AUTOMATED REASONING 0 3.2 (BH, BT}, we get the conditional (posterior) probability on S given that heads is observed. BeliZ in some sense represents the evidence en- coded observing k heads, and BeZh $ Bell rep- resents the evidence encoded by observing heads and then tails, in that if we combine these belief functions with the prior, we get the appropriate conditional probability. Choosing the right representation Obviously, we now want to know whether these prop- erties hold not just for certain observations made in this coin-tossing example, but in general. The answer is yes, and the appropriate theorems that show this can already be found in [Sha76a]. We review Shafer’s theorems in the full paper in detail, as well as his way of representing evidence. The upshot is that any be- lief functions BeZh and Belt can be used to represent the observations heads and tails respectively and will satisfy the two properties above, provided that the ra- tio of PZh(BH) : PZh(BT) = 2 : 1 = Pr(heudslBH) : Pt(heuds(BT), and PZ,(BH) : PIi = 1 : 2 = Pt(tuiZslBH) : Pt(tuiZslBT). (As we observed above, Shafer’s representation indeed has this property.) There are other reasonably motivated representa- tion schemes with these properties, besides the one suggested by Shafer. One is suggested by Dempster [Dem68] (see [Sha76b] for a comparison between his ap- proach and that of Dempster). Yet another is defined by Smets (see [Sha82] for a discussion of Smets’ rep- resentation). We consider a fourth reasonable choice (also considered in [Sha82]), which we would claim is perhaps the most natural of all; namely, to consider the unique belief function that satisfies the condition stated above that is also a probability function. In our coin-tossing example, let Pth and Ptt rep- resent the probabilistic belief function that captures the observations of heads and tuifs respectively. Ln order to get Prh(BH) : Prh(BT) = 2 : 1, we must have Pth(BH) = 2/3, Prh(BT) = l/3. Similarly, we have Prt(BH) = l/3, Ptt(BT) = 2/3. Al- though Pth and Pr t can be viewed as probability functions, they should not be thought of as represent- ing the probability of BH or BT in any sense cor- responding to the frequentist or subjectivist interpre- tation of probability. Rather, these are encodings of the evidence for BH and BT given the observations heads and tails respective1y.l It is easy to check that, ‘They are, in fact, closely related to the likelihood functions introduced by R. A. Fisher. We discuss the relationship in more detail in the full paper. See also [Ha&51 for further discussion of likelihoods. for example, we have Prt(BH) = 2k/(2k + 1) and Pri(BT) = 1/(2k + l), where Pti = Prh @ 0.. $ Prh (k times). Again, the more heads we see, the greater the evidence that the coin is biased towards heads. And if we combine this with a prior Pr such that Pt(BH) = cw, then an easy computation shows that (Pr @ Pr;)(BH) = 2ka/(1 + (2k - l)(y). Thus, (Pr $ PrL)(BH) = Pt(BHlk heads). This shows that (at least in this example) the probabilistic representa- tion of evidence has the same properties we observed with Shafer’s representation. There is one additional property we might require of a representation of evidence. Suppose that we make k independent observations. It seems that this should be equivalent to making one joint observation. In our coin-tossing example, we might expect that observing heads and then observing tails should be identical to making the joint observation (heads, tails). Unfortu- nately, as Shafer already observed [Sha76a, p. 249- 2501, his representation does noi have this property in general. Ret urning to our coin tossing example, recah that (Belh $ BeZt )( BH) = l/3. As we show in the full paper, it follows from Shafer’s definitions that if BeZ(hlt) is the belief function that represents the joint observation “heads followed by tails”, then BeZp,t) (BH) = 0. Thus BeZh $ BeZt # BeZlhlt). The fact that Shafer’s approach to representing ev- idence does not represent a joint observation in the same way that it represents the combination of the individual observations has disturbed a number of au- thors [Dia78, Sei81, Wil78]. In fact, in a later paper [Sha82], Shafer has indicated that he is inclined to agree that this property is unacceptabIe. In the full paper we focus on this problem in more detaX We show that the probabilistic representation of evidence discussed above does satisfy it. l’vIoreover, we show that if we make one reasonable assumption, then the proba- bilistic representation of evidence is the only represen- tation that satisfies this additional property. Roughly speaking, our assumption says that all that matters is the relutiee likelihood of observations. In terms of our coin-tossing example, this means that all that mat- ters is the ratio of Pt(headeJBH) : Pr(heudslBT), and not the actual values of the conditional proba- bilities. Of the representations mentioned above, this assumption is satisfied by Shafer’s representation and by the probabilistic representation, but is not satisfied by either Dempster’s representation or Smets’ repre- sentation. For a more general discussion of the issue of representing belief, the reader is encouraged to consult [WaI87]. 4 Examples Depending on which of the two views of belief functions we take, we wiIl model a situation in very different ways. For example, it is typically assumed that lack of information about an event E should be modelled by the vacuous belief function BeZ, so that BeZ(E) = 0 and PI(E) = 1. While this way of modelling the lack of information is consistent with the view of belief as a generalized probability (intuitively, our information is consistent with E having any probability between 0 and l), it is not in general consistent with the view of belief as evidence. To take a simple example, suppose we have two fair coins, call them coin A and coin B. Someone tosses one of the two coins aud announces that it lands heads. Iutuitively, we now have no evi- dence to favor the coin being either coin A or coin B. Taking the view of belief as generalized probability, we would have BeZ( A tossed) = 0 and PZ( A tossed) = 1. However, taking the view of belief as evidence and us- ing the probabilistic representation of belief, we get BeZ(A tossed) = PZ(A tossed) = l/2. Lack of infor- mation is not being represented by the vacuous belief function under this viewpoint. In general, starting with a (belief function represent- ing a) prior, if we get new evidence, we can either up- date the prior, or combine it with a belief function representing the evidence. As we already saw in the coin-tossing example of Section 3, we get the same an- swer no matter how we do it (although the interme- diate comptuations are quite different), providing we represent the evidence appropriately. The one thing we must be careful not to do is to represent the evi- dence as a generalized probability, and then combine it with the prior. To understand this issue, consider the following slightly simplified version of a puzzle appearing in [IIu.u87]: Suppose that we have 100 agents, all hold- ing a Iottery ticket, numbered 00 to 99. Suppose that agent al holds ticket number 17. Assume that the lot- tery is fair, so, a priori, the probability that a given agent will win is l/100. We are then told that the first digit of the winning ticket is 1. Straightforward probability arguments show that the probability that the winning ticket is 17 given that the first digit of the winning ticket is 1 is l/10; thus, agent l’s probability of winning in light of the new information is l/10. How can we represent this information using belief functions? Hunter essentially considers two belief func- tions on the space S = (al,. . . , ~100)~ where BeZ(u;) represents the belief that a; wins. It seems reason- able to represent the information that the lottery is fair by the belief function Bell where BeZl((a;}) = PZl((ui}) = l/100, for i = 1,. . . ,100. (Note that this HALPERN AND FAGIN 117 belief function is actually a probability function.) Now how should we represent the second piece of information? Hunter suggests representing it by the belief function BeZz which is the lower envelope of the set P of probability functions on S that assign {al} probability l/10. Thus, we have BeZs((u1)) = l/10 and BeZz({uz, . . . , aloo}) = 9/10, but BeZz(A) = 0 if A is a strict subset of (a~, . . . , aloo}. Hunter then considers the result of combining these two belief functions by using the rule of combination. In the light of our previous discussion, it should not be surprising that the result does not seem to represent the combined evidence at all. In fact, an easy com- putation shows that the result of combining BetI and BeZz is a probability function that places probability l/892 on al winning, and probability 9/892 OIL ai win- ning, for i = 2,. . ., 100. It certainly does not seem appropriate that the evidence that al’s probability of winning is l/10, when combined with the information that the lottery is fair, should decrease our belief that u1 will win and, in fact, result is a belief that any other agent is 9 times as likely to win as al! There may be some objections to the appropriate- ness of the use of the rule of combination here (these are discussed in the full paper), but as the discussion in the previous section suggests, the real problem here is that we are trying to use the rule of combination with a belief function that is meant to represent a generalized probability. The point is that BeZz does not represent the evidence appropriately. In order to apply the tech- niques discussed in the previous section for represent- ing the evidence, we need to know the likelihood, for each agent Ui, that the first digit of the winning num- ber is 1, given the hypothesis that ai wins the lottery. In the case of al, it is easy to compute this probability: since al’s number is 17, the probability that the first digit of the winning number is 1 given that al wins is 1. In the case of the other agents, we cannot compute this probability at all, since we do not know what their lottery numbers are. In order to deal with this problem, first consider a fixed assignment A of lottery numbers to agents, so that A(i) is the lottery number of ai. We assume (as is the case in the story) that A(1) = 17. With re- spect to this fixed assignment, it is easy to see that there are 10 agents oi for which the probability that the fist digit of the winning number is 1 given that oi wins is 1; namely, all those agents a; such that the fist digit of A(i) is 1. For every other agent ai, the probability that the fist digit of the winning num- ber is 1 given that ai wins is 0. Using the probabilis- tic representation of evidence discussed in the previ- ous section, we would thus represent the evidence that 118 AUTOMATED REASONING the first digit of the winning lottery number is 1 by the belief function Belt such that the mass function Vi? ({“il) = l/10 for each agent oi such that the first digit of A(i) is 1 (note that, in particular, this includes al), and m$((oi}) = 0 if the first digit of A(i) is not 1. It is now easy to check that BeZl $ Belt = Belt. Thus, independent of the assignment A of lottery numbers, we have (Bell @BeZt)((al}) = l/10, as expected. (We would get essentially the same results using the other representations discussed in the previous section.) In the full paper, we also consider in detail the puz- zle of of Mr. Jones’ murderer, introduced in [SK89]. Our analysis of this puzzle can also be applied to the three prisoners problem (this problem is analyzed un- der the viewpoint of beliefs as generalized probabilities in [FH89a]). Acknowledgements: This paper benefitted from discussions with numerous people, including Fahiem Bacchus, Alan Bundy, Dan Hunter, Ben Grosof, Ric Horvitz, Judea Pearl, Tom Strat, Moshe Vardi, and Larry Wasserman. References [Abe881 [Ait68] [Bla87] [Dem67] [Dem68] [Dia78] [DZ82] S. Abel. The sum-and-lattice-points method based on an evidential-reasoning system ap- plied to the real-time vehicle guidance prob- lem. In Uncertainty in Artificial InteZZigence &pages 365-370,1988. J. Aitchison. Discussion on Professor Demp- ster’s paper. Joplrnal of the Royal Statistical Society, Series B, 30:234-237,1968. P. Black. Is Shafer general Bayes? IIn Pmt. Third AAAI Uncertainty in Artificial InteZZi- gence Workshop, pages 2-9, 1987. A. P. Dempster. Upper and lower probabili- ties induced by a multivalued mapping. An- naZs of Mathematicaf Statistics, 381325-339, 1967. A. P. Dempster. A generalization of Bayesian inference. JotimaZ of the Royal StatisticaZ So- ciety, Series B, 30:205-247,1968. P. Diaconis. Review of “A Mathematical The- ory of Evidence”. JosllrnaZ of the American Statistical Society, 73(363):677-678,1978. P. Diaconis and S. L. Zabell. Updating sub- jective probability. Jotiplrnal of the American StatisticaZ Society, 77(380):822-830,1982. [Fal88] [FH89a] [FH89b] [Hac65] [HF89] [HH86] [Hun871 IKYb871 [Lem86] [LG83] [LU88] [Pea881 B. Fakmhainer. Towards a general-purpose belief maintenance system. Zn Uncertainty in A&fkiaZ InteZZigence 2, pages 125-131, 1988. R. Fagin and J. Y. Halpern. A new approach to updating beliefs. Research Report RJ 7222, IBM, 1989. A revised version will appear in May, 1990. R. Fagin and J. Y. HaIpern. Uncertainty, belief, and probability. In Eleventh Inter- national Joint Conference on Artificial Intel- ligence (IJCAI-89), pages 1161-1167, 1989. An expanded version of this paper appears as IBM Research Report RJ 6191, April 1988. I. Hacking. Logic of Statistical Inference. Cambridge University Press, 1965. J. Y. Htzlpern and R. Fagin. Two views of belief: Belief as generalized probability and belief as evidence. Research Report RJ 7221, IBM, 1989. A revised version will appear in May, 1990. E. Horvitz and D. Heckerman. The incon- sistent use of measures of certainty in arti- ficial intelligence research. In L. N. Kanal and J. F. Lemmer, editors, Uncertainty in ArtificiaZ Intelligence, pages 137-151. North- Holland, 1986. D. Hunter. Dempster-Shafer vs. probabilistic logic. In PTOC. Third AAAI Uncertainty in Art$ciaz Iniehgence workshop, pages 22-29, 1987. H. E. Kyburg, Jr. Bayesian and non-Bayesian evidential updating. Art$ciaZ InteZZigence, 31:271-293, 1987. J. F. Lemmer. Confidence factors, empiri- cism, and the Dempster-Shafer theory of ev- idence. Iu L. N. Kanal and J. F. Lemmer, editors, Uncertainty in AftificiaZ Intelligence, pages 167-196. North-Holland, 1986. J. D. Lowrance and T. D. Garvey. Evidential reasoning: an implementation for multisensor integration. Technical Report TN 307, SRI International, 1983. Z. Li and L. Uhr. Evidential reasoning in a computer vision system. lk Uncertainty in Art$ciaZ InteZZigence 2, pages 403-412, 1988. J. Pearl. ProbabiZistic Reasoning in Intelligent Systems. Morgan Kaufmaun, 1988. [Pea891 J. Pearl. Reasoning with belief functions: a critical assessment. Technical Report R-136, UCLA, 1989. [Rus87] E. H. R us p ini. The logical foundations of evi- dential reasoning. Research Note 408, revised version, SRI International, 1987. [Se;811 T. Seidenfeld. Statistical evidence and belief functions. PSA 1974 2:478-489, 1981. [Sha76a] 6. Shafer. A Mathematical Theory of Evi- dence. Princeton University Press, 1976. [Sha76b] G. Shaf er. A theory of statistical evidence. [Sha79] [Sha82] [SK891 [Wd87] [ Wil78] In W. L. Harper and C. A. Hooker, editors, Foundations of Probability Theory, StatiaticaZ Inference, and StatisticaZ Theories of Science, Vol. II. Reidel, 1976. G. Shafer. Allocations of probability. Annals of ProbabiZity, 7(5):827-839, 1979. G. Shafer. Belief functions and parametric models (with commentary). JownaZ of the Royal Statistical Society, Series B, 44:322- 352,1982. P. Smets and R. Kennes. The transferable be- lief model: comparison with Bayesian models, unpublished manuscript. 1989. P. Walley. Belief function representations of statistical evidence. AnnaZs of Statistics, 18(4):1439-1465,1987. P. M. Williams. On a new theory of epistemic probability ( review of “A Mathematical The- ory of Evidence”). The British JownaZ for the Philosophy of Science, 29:357-387, 1978. HALPERNANDFAGEN 119
|
1990
|
17
|
926
|
Parsing a Natural Language Using Mutual Information Statistics* David M. Magerman and Mitchell P. Marcus CIS Department University of Pennsylvania Philadelphia, PA 19104 E-mail: magerman@linc.cis.upenn.edu Abstract The purpose of this paper is to characterize a constituent boundary parsing algorithm, using an information-theoretic measure called generalized mutual information, which serves as an alterna- tive to traditional grammar-based parsing meth- ods. This method is based on the hypothesis that constituent boundaries can be extracted from a given sentence (or word sequence) by analyz- ing the mutual information values of the part-of- speech n-grams within the sentence. This hypoth- esis is supported by the performance of an im- plementation of this parsing algorithm which de- termines a recursive unlabeled bracketing of un- restricted English text with a relatively low er- ror rate. This paper derives the generalized mu- tual information statistic, describes the parsing al- gorithm, and presents results and sample output from the parser. Introduction A standard approach to parsing a natural language is to characterize the language using a set of rules, a grammar. A grammar-based parsing algorithm recursively determines a sequence of applications of these rules which reduces the sentence to a single category. Besides determining sentence structure, grammar-based approaches can also identify attributes of phrases, such as case, tense, and number, and they are known to be extremely effective at characteriz- ing and classifying sentences. But these techniques are generally demonstrated using only a subset of the grammar of the language. In order for a grammar- based parser to be applied to unrestricted natural lan- guage text, it must account for most of the complexities of the natural language. Thus, one must first concisely *This work was partially supported by DARPA grant No. N0014-85-K0018, by DARPA and AFOSR jointly un- der grant No. AFOSR-90-0066, and by AR0 grant No. DAAL 03-89-COO31 PRI. Special thanks to Ken Church, Stuart Shieber, Max Mintz, Beatrice Santorini, and Tom Veatch for their valued input, guidance and support. 984 NATURAL LAN~;UAGE describe the bulk of the grammar of that language, an extremely difficult task. This characterization suggests that a solution to the problem of parsing unrestricted natural language text must rely on an alternative to the grammar-based approach. The approach presented in this paper is based on viewing part-of-speech sequences as stochas- tic events and applying probabilistic models to these events. Our hypothesis is that constituent boundaries, or “distituents,” can be extracted from a sequence of n categories, or an n-gram, by analyzing the mutual in- formation values of the part-of-speech sequences within that n-gram. In particular, we will demonstrate that the generalized mutual information statistic, an exten- sion of the bigram (pairwise) mutual information of two events into n-space, acts as a viable measure of continuity in a sentence. One notable attribute of our algorithm is that it ac- tually includes a grammar - a distituent grammar, to be precise. A distituent grammar is a list of tag pairs which cannot be adjacent within a constituent. For instance, noun prep is a known distituent in English, since the grammar of English does not allow a con- stituent consisting of a noun followed by a preposition. Notice that the nominal head of a noun phrase. may be followed by a prepositional phrase; in the context of distituent parsing, once a sequence of tags, such as (prep noun), is grouped as a constituent, it is consid- ered as a unit. Based on our claim, mutual information should de- tect distituents without aid, and a distituent grammar should not be necessary. However, the application of mutual information to natural language parsing de- pends on a crucial assumption about constituents in a natural language. Given any constituent n-gram, ala2.. . a,, the probability of that constituent occur- ring is usually significantly higher than the probability of ala2.. . a,a,+i occurring. This is true, in general, because most constituents appear in a variety of con- texts. Once a constituent is detected, it is usually very difficult to predict what part-of-speech will come next. While this assumption is not valid in every case, it turns out that a handful of cases in which it is invalid From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. are responsible for a majority of the errors made bY the parser. It is in these few cases that we appeal to the distituent grammar to prevent these errors: The distituent parsing algorithm is an example of a stochastic, corpus-based approach to parsing. In the past, a significant disadvantage of probabilistic parsing techniques has been that these methods were prone to higher than acceptable error rates. By contrast, the mutual information parsing method presented in this paper is based on a statistic which is both highly ac- curate and, in the cases where it is inaccurate, highly consistent. Taking advantage of these two attributes, the generalized mutual information statistic and the distituent grammar combine to parse sentences with, on average, two errors per sentence for sentences of 15 words or less, and five errors per sentence for sen- tences of 30 words or less (based on sentences from a reserved test subset of the Tagged Brown Corpus, see footnote 1). Many of the errors on longer sentences re- sult from conjunctions, which are traditionally trouble- some for grammar-based algorithms as well. Further, this parsing technique is extremely efficient, parsing a 35,000 word corpus in under 10 minutes on a Sun 4/280. tant at this point, since there are actually two statistics which are associated w rith the term “mutual informa- tion,” the second being an extension of the first. In his treatise on information theory, Transmission of Information (Fano 1961), Fano discusses the mutual information statistic as a measure of the interdepen- dence of two signals in a message. This bigram mutual information is a function of the probabilities of the two events: MZ(z, y) = log PxPy(ZY y, px (4PY (Y) * (1) Consider these events not as signals but as parts-of- speech in sequence in a sentence. Then an estimate of the mutual information of two categories, zy, is: # xy in corpus MZ(z,y) w log total # of bigrams in corpus #x >( - (2) # y corpus size corpus size > It should be noted at this point that, while many stochastic approaches to natural language processing that utilize frequencies to estimate probabilities suffer from sparse data, sparse data is not a concern in the domain of our algorithm. Sparse data usually results from the infrequency of word sequences in a corpus. The statistics extracted from our training corpus are based on tag n-grams for a set of 64 tags, not word n-grams.l The corpus size is sufficiently large that enough tag n-grams occur with sufficient frequency to permit accurate estimates of their probabilities. There- fore, the kinds of estimation methods of (n + 1)-gram probabilities using n-gram probabilities discussed in Katz (1987) and Church & Gale (1989) are not needed. This line of research was motivated by a series of successful applications of mutual information statis- tics to other problems in natural language processing. In the last decade, research in speech recognition (Je- linek 1985), noun classification (Hindle 1988), predi- cate argument relations (Church & Hanks 1989), and . I other areas have shown that mutual information statis- tics provide a wealth of information for solving these problems. In order to take advantage of context in determin- ing distituents in a sentence, however, one cannot re- strict oneself to looking at pairs of tokens, or bigrams; one must be able to consider n-grams as well, where n spans more than one constituent. To satisfy this con- dition, we can simply extend mutual information from bigrams to n-grams by allowing the events d: and y to be part-of-speech n-grams instead of single parts-of- speech. We will show that this extension is not suffi- cient for the task at hand. The second statistic associated with mutual informa- tion is what we will call “generalized mutual informa- tion,” because it is a generalization of the mutual in- formation of part-of-speech bigrams into n-space. Gen- eralized mutual information uses the context on both sides of adjacent parts-of-speech to determine a mea- sure of its distituency in a given sentence. We will discuss this measure below. While our distituent parsing technique relies on gen- eralized mutual information of n-grams, the founda- tions of the technique will be illustrated with the base case of simple mutual information over the space of bigrams for expository convenience. Notat ion Mutual Information Statistics Before discussing the mutual information parsing al- gorithm, we will demonstrate the mathematical basis for using mutual information statistics to locate con- stituent boundaries. Terminology becomes very impor- ‘The corpus we use to train our parser is the Tagged Brown Corpus (Francis and Kucera, 1982). Ninety percent of the corpus is used for training the parser, and the other ten percent is used for testing. The tag set used is a subset of the Brown Corpus tag set. Before continuing with a mathematical derivation of the generalized mutual information statistic, some mathematical and statistical notation should be ex- nlained. A Many different probability functions will be referred to in this paper. Ps~, represents a probability function which maps the set 52 onto the interval [0, 11. In equa- tion 1, reference is made to three different probability functions: Px, Py , and Px,y . The subscripts of these functions indicate their domains, X, Y, and X x Y, re- spectively. However, these subscripts will be omitted from the remaining equations, since the domain of each probability function will be indicated by its arguments. MAGERMAN AND MARCUS 985 The subscripts and superscripts of the mutual infor- mation functions can also be somewhat confusing. The bigram mutual information function, denoted as MI, maps the cross-product of two event spaces onto the real numbers. MI, is a vector-valued function indi- cating the mutual information of any two parts of an n-gram, 21 . . . x,. The Kth component of this vector, 1 5 k < 12, is MT:, representing the bigram mutual information of x1 . . . xk and xk+l . . .x,. The meaning of this vector function will be further explained in the next section. Finally, the generalized mutual informa- tion function of two adjacent elements xy in an n-gram is denoted by gMZ,(x, y). Mutual Informat ion The bigram mutual information of two events is a mea- sure of the interdependence of these events in sequence. In applying the concept of mutual information to the analysis of sentences, we are concerned with more than just the interdependence of a bigram. In order to take into account the context of the bigram, the interdepen- dence of part-of-speech n-grams (sequences of n parts- of-speech) must be considered. Thus, we consider an n-gram as a bigram of an nl-gram and an n2-gram, where nl + n2 = n. The mutual information of this bigram is MZ(nr-gram, n2-gram) = log P [n-gram] P[nr-gram]P[nz-gram] ’ (3) Notice that there are (n - 1) ways of partitioning an n-gram. Thus, for each n-gram, there is an (n - 1) vector of mutual information values. For a given n- gram xi . . . x,, we can define the mutual information values of x by: MZ;(xl . . . x:ra) = MZ(xl . . . xk,xk+l . . . Xn) (4) = log P(x, . . P(Xl . . - xn) - xk)p(xk+l * - * xn where 1 5 Ic < n. Notice that, in the above equation, for each Ml?:(x), the numerator, P(xr . . . xn), remains the same while the denominator, P(x, . . . xk)P(xk+r . . .x,), depends on L. Thus, the mutual information value achieves its minimum at the point where the denominator is max- imized. The empirical claim to be tested in this paper is that the minimum is achieved when the two compo- nents of this n-gram are in two different constituents, i.e. when xkxk+l is a distituent. Our experiments show that this claim is largely true with a few interesting ex- ceptions. The motivation for this claim comes from examin- ing the characteristics of n-grams which contain pairs of constituents. Consider a tag sequence, x1 . . . xn, which is composed of two constituents x1 . . . xk and xk+l . . . xn. since xl . . . xk is a constituent, xl . . . xk-1 is very likely to be followed by xk. Thus, P(x, . . . xk) = P(x, . . .x&l). (6) By the same logic, P(xk+l s a s 2,) M P(xk+‘J s s e Xn). (7) On the other hand, assuming xk and zk+l are uncor- related (in the general case),- and P(xk . . . xn) < p(xk+l - - -xn) P(x, . . . xk+l) < P(xl . . . xk). Therefore, MZ(xl . . . xk, XL+1 . . - X:n) P(Xl . . .x,) = log P(Xl - - - xk)p(xk+l . . . Xn) M P(X1 . . . Xn) log P(Xl - - - xk-l)p(xk+l . . . Xn) ’ P(Xl . . . xn) log P(x, . . . xk-l)p(x, . . . xn) = MZ(xl . . . xk-1, xk . . .X,). (8) (9) (10) (11) (12) (13) By applying a symmetry argument and using induc- tion, the above logic suggests the hypothesis that, in the general case, if a distituent exists in an n-gram, it should be found where the minimum value of the mutual information vector occurs. There is no significance to the individual mutual in- formation values of an n-gram other than the mini- mum; however, the distribution of the values is signif- icant. If all the values are very close together, then, while the most likely location of the distituent is still where the minimum occurs, the confidence associated with this selection is low. Conversely, if these values are distributed over a large range, and the minimum is much lower than the maximum, then the confidence is much higher that there is a distituent where the mini- mum occurs. Thus, the standard deviation of the mu- tual information values of an n-gram is an estimate of the confidence of the selected distituent. Generalized Mutual Information Although bigram mutual information can be extended simply to n-space by the technique described in the previous section, this extension does not satisfy the needs of a distituent parser. A distituent parsing tech- nique attempts to select the most likely distituents based on its statistic. Thus, a straightforward ap- proach would assign each potential distituent a single real number corresponding to the extent to which its context suggests it is a distituent. But the simple ex- tension of bigram mutual information assigns each po- tential distituent a number for each n-gram of which it is a part. The question remains how to combine these numbers in order to achieve a valid measure of distituency. Our investigations revealed that a useful way to com- bine mutual information values is, for each possible distituent xy, to take a weighted sum of the mutual 986 NATURAL LANGUAGE information values of all possible pairings of n-grams ending with x and n-grams beginning with y, within a fixed size window. So, for a window of size w = 4, given the context xlx2xsx4, the generalized mUtUa1 in- formation of X2X3 : gMZ4(XlX2, X3X4), = hMZ(x2, X3) + k2MZ(x2, ~3x4) + (14) k3MZ(XlX2, X3) + k4Mr(XlX2, X3X4) (15) which is equivalent to (16) In general, the generalized mutual information of any given bigram xy in the context x1 . . . xi-ixyyr . . . yj-1 is equivalent to n 1% Xcrosses xy rI (17) \Xdoes not cross xy / This formula behaves in a manner consistent with one’s expectation of a generalized mutual information statistic. It incorporates all of the mutual information data within the given window in a symmetric man- ner. Since it is the sum of bigram mutual information values, its behavior parallels that of bigram mutual in- format ion. The weighting function which should be used for each term in the equation was alluded to earlier. The standard deviation of the values of the bigram mutual information vector of an n-gram is a valid measure of the confidence of these values. Since distituency is in- dicated by mutual information minima, the weighting function should be the reciprocal of the standard devi- ation. In summary, the generalized mutual information statistic is defined to be: = c X ends with xi &WV), (18) Y begins with yl where UXY is the standard deviation of the MZfxyI values within XY. The Parsing Algorithm The generalized mutual information statistic is the most theoretically significant aspect of the mutual in- formation parser. However, if it were used in a com- pletely straightforward way, it would perform rather poorly on sentences which exceed the size of the max- imum word window. Generalized mutual informat ion is a local measure which can only be compared in a meaningful way with other values which are less than a word window away. In fact, the further apart two po- tential distituents are, the less meaningful the compar- ison between their corresponding GMT values. Thus, it is necessary to compensate for the local nature of this measure algorithmically. He directed the cortege near Santa Monica. of autos to the Figure 1: Sample sentence from the Brown Corpus We will describe the parsing algorithm as it parses a sample sentence (Figure 1) selected from the section of the Tagged Brown Corpus which was not used for training the parser. The sample sentence is viewed by the parser as a tag sequence, since the words in the sentence are not accounted for in the parser’s statisti- cal model. The sentence is padded on both sides with w - 1 blank tags (where w is the maximum word win- dow size) so there will be adequate context to calculate generalized mutual information values for all possible distituents in the sentence. A bigram mutual information value vector and its standard deviation are calculated for each n-gram in the sentence, where 2 5-n 5 1O.2 If the frequency of an n-gram is below a certain threshold (< 10, determined experimentally), then the mutual information values are all assumed to be 1, indicating that no information is given by that n-gram. These values are calculated once for each sentence and referenced frequently in the parse process. Distituent pass pro verb 3.28 verb det 3.13 det noun 11.18 noun prep 11.14 prep noun 1.20 noun prep 7.41 prep det 16.89 det noun 16.43 noun prep 12.73 prep noun 7.36 DG 3.28 3.13 11.18 -00 1.20 IiG 16.43 iii Pass Pass 3 3.28 3.28 3.13 3.13 8.18 3.91 10.83 7.64 2.45 4.13 Figure 2: Parse node table for sample sentence Next, a parse node is allocated for each tag in the sentence. A generalized mutual information value is 2The optimal maximum word window size, w = 10, was determined experimentally. However, since there were only 46 ll-grams and 15 12-grams which occurred more than 10 times in the training corpus, it is obvious why virtually no information is gained by expanding this window beyond 10. By training the parser on a larger corpus, or a corpus with a higher average sentence length, the optimal maximum word window size might be larger. MAGERMAN AND MARCUS 987 computed for each possible distituent, i.e. each pair of parse nodes, using the previously calculated bigram mutual information values. The resulting parse node table for the sample sentence is indicated by Pass 1 in the parse node table (Figure 2). At this point, the algorithm deviates from what one might expect. As a preprocessing step, the distituent grammar is invoked to flag any known distituents by replacing their (3MZ value with -oo. The results of this phase are indicated in the DG column in the parse node table. The first w tags in the sentence are processed using an n-ary-branching recursive function which branches at the minimum GMT value of the given window. The local minima at which branching occurs in each pass of the parse are indicated by italics in the parse node table. One should note that marginal differences be- tween 5;MZ values are not considered significant. So, for instance, the distituency of pro verb (3.28) is con- sidered equivalent to the distituency of verb det (3.13) in the sample sentence. This behavior results in n-ary trees instead of binary trees. Instead of using this tree in its entirety, only the nodes in the leftmost constituent leaf are pruned. The rest of the nodes in the window are thrown back into the pool of nodes. The same process is applied to the last u) remaining tags in the sentence, but this time the rightmost constituent leaf is pruned from the resulting parse tree. The algorithm is applied again to the left- most TN remaining tags, and then the rightmost zu tags, until no more tags remain. The first pass of the parser is complete, and the sentence has been partitioned into constituents (Figure 3). (He) (directed) (the cortege) (of autos) (to) (the dunes) (near Santa Monica) Figure 3: Constituent structure after Pass 1 In pass 2, a parse node is assigned to each con- stituent unit determined from the first pass, GM1 val- ues are calculated for these parse nodes, and the left- right pruning algorithm is applied to them. The algorithm terminates when no new structure has been ascertained on a pass, or when the lengths of two adjacent constituents sum to greater than 20. In both cases, the parser can extract no more information about the distituency of the nodes from the statistics available. In the first case, the resulting distituency confidence values are too close together to determine distituency; and in the second case, since the word window can no longer span a potential distituent, the algorithm must give up. After the third pass of the algorithm, the sample sentence is partitioned into two adjacent constituents, and thus the algorithm termi- nates, with the result in figure 4. Processing only a word-window of information at a time and pruning the leftmost and rightmost leaves (He (directed ((the cortege) (of autos))) ((to (the dunes)) (near Santa Monica))) Figure 4: Resulting constituent structure after Pass 3 of the resulting subtrees are the keys to minimizing the error introduced by the use of a non-global, esti- mated statistic. Since we know that the parser tends to make errors, our goal is to minimize these errors. Finding constituents in the middle of a sentence re- quires locating two distituents, whereas finding them at the beginning or end of a sentence requires locating only one distituent. Thus, pruning constituents from the beginning and end of a tag sequence produces a far more accurate partitioning of the sentence than trying to guess them all at once. It is important to note that, on a given pass of the parser, many of the ‘constituents’ which are pruned are actually only single nodes. For instance, in the sample sentence, the first pass partitions the phrase “to the dunes” as “(to) (the dunes).” A subsequent pass of the parsing algorithm attaches the preposition to the noun phrase (although the parser has no knowledge of these constituent names). However, once the entire phrase is found to be a constituent, it is not scanned for any further structural information. Thus, if the first pass had grouped the phrase as “(to the dunes),” then the noun phrase within the prepositional phrase would never be marked as a constituent. As a result of this behavior, the prepositional phrase “near Santa Monica” will not attach to the noun phrase “the dunes” (or to the noun “dunes” as many lin- guists believe it should) once the prepositional phrase is formed. Therefore, the parser output for the sample sentence has one error. Results Evaluating the accuracy of a natural language parser is as difficult as writing a full grammar for that natural language, since one must make decisions about gram- mar rules in order to decide what is an error and what is not. Serious thought must be put into questions like: where does a conjunction bind in a conjunct, and does it matter? or where do prepositional phrases attach, and can we even decide? These very problems are the reason we sought an alternative to a grammar-based parser. Thus, while the error rate for short sentences (15 words or less) with simple constructs can be de- termined very accurately, the error rate for longer sen- tences is more of an approximation than a rigorous value. Our parser is very good at parsing short sentences of unrestricted text without conjunctions. On these sentences, the parser averages close to one error per sentence. However, if free text with conjunctions is 988 NATURALLANGUAGE included, the performance falls to close to two errors per sentence. An error is defined as a misparse which can be corrected by moving one subtree. As one would expect, our parser’s performance is not as accurate for longer sentences, but it is certainly respectable. On sentences between 16 and 30 tokens in length, the parser averages between 5 and 6 errors per sentence. However, in nearly all of these longer sentences and many of shorter ones, at least one of the errors is caused by confusion about conjuncts, espe- cially sentences joined by conjunctions. Considering the parser is trained on n-grams with a word window no larger than 10 tokens, it is not surprising that it fails on sentences more than twice that size. Given a larger training corpus with a significant number of these long sentences, the maximum word window could be in- creased and the parser would undoubtedly improve on these longer sentences. The output from the mutual information parser is unique in that it gives both more and less information than most other statistical parsers. Most statistical parsers depend on internal grammar rules which al- low them both to estimate and to label sentence struc- ture. Once again, because of the complexity of natu- ral language grammars, these approaches can only ex- tract limited levels of structure. Hindle’s FIDDITCH parser (1988) attempts to extract not only sentence structure but also noun classifications using cooccur- rence of word pairs, another variation of bigram mu- t ual information. While his technique performs the noun classification task extremely well, it does not se- riously attempt to parse sentences completely, since its grammar cannot handle complex sentence structures. Our parser is capable of determining all levels of sen- tence structure, although it is incapable of labeling the resulting constituents. Conclusion The performance of this parsing algorithm demon- strates that a purely syntactic, stochastic technique can effectively determine all levels of sentence structure with a relatively high degree of accuracy. The most im- portant question to ask at this juncture is: where do we go from here? An immediate extension of this research would be to apply a simple grammar-based filter to each pass of our statistical parser to verify the validity of the con- stituents it determines. Applying a very simple gram- mar which defines only constituency of terminal sym- bols would eliminate many of the errors made by our parser. The implementation of an effective deterministic parsing algorithm, however, should not overshadow the real discovery of this research. The generalized mutual information statistic is a powerful statistical measure which has many other applications in natu- ral language processing. Bigram mutual information has been applied to many different problems requiring PI PI PI PI PI PI PI PI n-gram analysis. It would be interesting to reinvesti- gate these problems using generalized mutual informa- tion. In particular, Hindle’s noun classification work (Hindle 1988) and Ch urch’s part-of-speech assignment (Church 1988) might b enefit from this statistic. Another way in which this research might be used is as a supplement to a grammar-based parser. The distituent parsing method could be used in whole as a pre-processor to supply hints for a grammar-based parser; or it could be used incrementally in a bottom- up parsing technique to provide guidelines for search so that non-deterministic algorithms do not realize their worst-case inefficiency. Another interesting possibility is to use the general- ized mutual information statistic to extract a grammar from a corpus. Since the statistic is consistent, and its window can span more than two constituents, it could be used to find constituent units which occur with the same distribution in similar contexts. There are many problems in natural language pro- cessing which cannot be solved eficiently by grammar- based algorithms and other problems which cannot be solved accurately by stochastic algorithms. This re- search suggests that the solution to some of these prob- lems is a combination of both. References Church, K. 1988. A Stochastic Parts Program and Noun Phrase Parser for Unrestricted Text. In Proceedings of the Second Conference on Applied Natural Language Processing. Austin, Texas. Church, K.; and Gale, W. 1990. Enhanced Good- Turing and Cat-Cal: Two New Methods for Es- timating Probabilities of English Bigrams. Com- puters, Speech and Language. Church, K.; and Hanks, P. 1989. Word Associ- ation Norms, Mutual Information, and Lexicog- raphy. In Proceedings of the 27th Annual Confer- ence of the Association of Computational Linguis- tics. , Fano, R. 1961. Transmission of Information. New York, New York: MIT Press. Francis, W.; and Kucera, H. 1982. Frequency Analysis of English Usage: Lexicon and Gram- mar. Boston, Mass.: Houghton Mifflin Company. Hindle, D. 1988. Acquiring a Noun Classification from Predicate-Argument Structures. Bell Labo- ratories. Jelinek, F. 1985. Self-organizing Language Mod- eling for Speech Recognition. IBM Report. Katz, S. M. 1987. Estimation of Probabilities from Sparse Data for the Language Model Compo- nent of a Speech Recognizer. IEEE Transactions on Acoustics, Speech, and Signal Processing, Vol. ASSP-35, No. 3. MAGERMANANDMARCUS 989
|
1990
|
170
|
927
|
Accent and Discourse Context: Assigning Pitch Accent in Synthetic Speech Julia Hirschberg AT&T Bell Laboratories 600 Mountain Avenue Murray Hill NJ 07974 julia@research.att .com Abstract Identifying the regularities underlying speaker deci- sions to emphasize or de-emphasize an item intona- tionally has long been the subject of speculation and controversy. This paper describes a study of ac- cent assignment based upon the analysis of natural recorded (read) speech. Results are being incorporated in NewSpeak, an interface to the Bell Laboratories Text-to-Speech System, which varies intonational fea- tures based upon syntactic structure and higher-level discourse information inferred from unrestricted text, in order to generate more natural synthetic speech. Im- plications of the work for the evaluation of discourse models, for automatic labeling of prosodic features, and for speech synthesis are discussed. Introduction The question of how speakers decide which items to emphasize intonationally and which to de-emphasize has been a popular but vexing problem in studies of in- tonation and discourse. While most researchers today accept Bolinger’s pessimistic “Accent is Predictable (if you’re a mind-reader)” (Bolinger 1972), mind-reading attempts continue, fueled in particular by the need to assign acceptable accentuation in speech synthesis. Al- though current systems generally use only simple syn- tactic information for this purpose, it is abundantly clear that ‘higher-level’ discourse information will have to be brought to bear as well, especially as applications requiring the synthesis of longer texts (as opposed to single words or sentences) become important. It also appears that pitch accent assignment, in turn, may provide a useful metric in the evaluation of current models of discourse. While the most objective crite- rion currently available for such evaluation has been the proper resolution of pronominal reference (Walker 1989), the ability of discourse models to support ac- cent placement comparable to that observed in natu- ral speech should provide a useful new evaluation cri- terion. This paper describes the assignment of pitch accent in NewSpeak, an interface to the Bell Laboratories Text-to-Speech System (TTS) (Olive and Liberman 1985), which varies intonational features based upon syntactic structure and higher-level discourse informa- tion inferred from unrestricted text, in order to gener- ate more natural speech. It compares the strategy of accent assignment initially implemented in NewSpeak with traditional strategies in speech synthesis - and with more sophisticated variants suggested by compar- ison with natural speech. First, previous work on the interpretation of pitch accent and on attempts to de- fine rule systems for accent assignment are discussed, with an emphasis on speech synthesis efforts. Next, NewSpeak itself and its initial accent assignment al- gorithm are described. Then, the empirical data cur- rently being used to refine this algorithm is examined, together with some preliminary results. Finally, future directions for the work are discussed. Pitch Accent in Natural and Synthetic Speech In natural speech, some words appear more intona- tionally prominent than others. We say that these words bear PITCH ACCENTS. While, in English, each word has a characteristic stress pattern, not every word is accented. Thus, LEXICAL STRESS must be distin- guished from pitch accent. Although pitch accent is a perceptual phenomenon, words that hearers iden- tify as accented tend to differ from their DEACCENTED versions (those not bearing pitch accents) in terms of some combination of pitch, duration, amplitude, and spectral characteristics. Accented words are usually identifiable in the FUNDAMENTAL FREQUENCY CON- TOUR (f0) as local maxima or minima, aligned with the word’s stressed syllable; deaccented items are not aligned with such pitch excursions. Words perceived as accented also tend to be somewhat longer and louder than deaccented words. The vowel in the stressed syl- lable of a deaccented word is often reduced from the full vowel of the accented version. The role that accent plays in utterance interpreta- tion is as yet not well understood. While attempts to explain the effect of pitch accent on the interpre- tation of particular syntactic, semantic, or pragmatic phenomena abound, and while some more general ac- 952 NATURALLANGUAGE From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. counts of accent meaning have been proposed either for particular word classes or for accent in general, the former accounts are too restricted and the latter too preliminary to provide much practical guidance for the construction of accent assignment algorithms. Currently, most researchers recognize certain ‘de- faults’ for accent placement, arising from some combi- nation of word class, syntactic constituency, and sur- face position, which can be ‘overridden’ by phenomena described variously ils CONTRASTIVENESS (Bolinger 1961), FOCUS (Jackendoff 1972; Rooth 1985), or IN- FORMATION STATUS (such as the GIVEN/NEW dis- tinction) (Chafe 1976; Halliday and Hassan 1976; Clark and Clark 1977; Prince 1981). However, the difficulty of defining such phenomena and, conse- quently, of predicting when speakers will wish to con- vey them has made it difficult to incorporate higher- level discourse or intentional considerations into al- gorithms describing speakers’ accent placement strat- egy. Nonetheless, whereas structural considerations were once thought to be primary in speakers’ accent placement decisions (Quirk et abl. 1964; Crystal 1975; Cruttenden 1986), now the role assigned to syntax in determining accent has shrunk markedly, as the role of discourse features and inferred speaker intention in determining accent location has grown. So the thrust of work on accent placement has been to seek solutions at the level of discourse context. Much of the progress in both the interpretation and the location of pitch accent currently being made arises from experimental studies such as (Brown 1983) and analyses of large corpora of recorded speech such as (Altenberg 1987). H owever, applications of such re- sults to speech synthesis are so far in their infancy. Most text-to-speech systems make accenting decisions based purely upon word class, with CLOSED-CLASS items (function words, such as articles, prepositions and pronouns) generally deaccented and OPEN-CLASS items (content words, such as nouns and verbs) ac- cented. Such approaches tend to ‘accent too many words in synthesis of longer stretches of text. And general inadequacies in part-of-speech tagging make it difficult to distinguish between items which are osten- sibly closed-class but are commonly accented (e.g. ver- bal prepositions and particles) and those that are not. Exceptions to the standard approach are found in message-to-speech systems, which synthesize speech from more abstract syntactic or semantic representa- tions (Young and Fallside 1979; Danlos et QI. 1986; Davis and Hirschberg 1988). And in one experimental text-to-speech system, (Silverman 1987) used a FIFO queue of roots of mentioned open-class items to deter- mine whether subsequent items should be deaccented, clearing the queue at paragraph boundaries. But most experimental systems, and all commercial systems rely upon the simple closed-open class distinction, dealing with exceptions simply by permitting varying degrees of user ability to override incorrect system defaults. Assigning Pitch Accent in NewSpeak The development of NewSpeak as an interface to TTS was motivated by both theoretical and practical con- siderations. On the one hand, the improvement of speech analysis technology makes it feasible to test hy- potheses about the relationship between intonational features and syntactic, semantic, and discourse char- acteristics of a text against large amounts of recorded speech. On the other hand, the deficiencies of current text-to-speech systems in synthesizing longer stretches of text, combined with the emergence of new appli- cations for text-to-speech systems which require such synthesis, makes the improvement of strategies for as- signing intonational features more pressing. Imple- mented in Quintus Prolog, NewSpeak currently uses syntactic information plus a simple discourse model to assign pitch accent type and placement, intonational phrasing, pausal duration, speaking rate, and phrasing in unrestricted text. Output from this interface in the form of text annotated with escape sequences which control intonational decisions is then passed to TTS for realization in speech. In this paper, NewSpeak’s accent placement strategy will be described, together with preliminary results from current investigations which have improved that strategy by making more sophisticated use of discourse information. NewSpeak originally assigned pitch accent using part-of-speech information provided by the Fidditch parser (Hindle 1989), a compound nominal parser based upon (Liberman and Sproat Forthcoming) (and implemented by Richard Sproat), and a partial model of the current text, based upon (Grosz and Sidner 1986)‘snotionofthe ATTENTIONAL STRUCTURE ofdis- course. A word’s part-of-speech identified its default pitch accent: closed-class items were deaccented and open-class accented. Structural information also per- mited identification of possible nominal compounds, which NewSpeak passed to the compound stress as- signment program for default (citation form) stress as- signment (e.g. ‘city ha0 was assigned right stress and ‘parking lot’, left stress). Output from this assignment was then passed to NewSpeak’s discourse model. The chief innovative aspect of accent assignment in NewSpeak was and is the use made of a discourse model. This model is based upon (Grosz and Sidner 1986)‘s notion of a discourse’s ATTENTIONAL STRUC- TURE, and is implemented as a simple stack of sets of roots of open-class items mentioned in the text. In the (Gross and Sidner 1986) model of discourse, dis- course structure comprises three structures, a LINGUIS- TIC STRUCTURE, which is the text/speech itself; an AT- TENTIONAL STRUCTURE, which includes information about the relative salience of objects, properties, rela- tions, and intentions at any point in the discourse; and an INTENTIONAL STRUCTURE, which relates theinten- tions underlying the production of speech segments to one another. In NewSpeak, attentional structure is represented as a stack of FOCUS SPACES, each of which HIRSCHBERG 953 comprises the set of roots of open-class words produced in the intonational phrase currently being constructed. The attentional state is updated - i.e., focus spaces are pushed or popped - by a simple algorithm which infers topic structure from orthographic cues, such as paragraphing and punctuation, and lexical cues, such as CUE PHRASES (words such as now, we& and by the way, which provide explicit information about the structure of a discourse); each cue phrase has associ- ated with it a ‘push’ or ‘pop’ operation for this pur- pose (Litman and Hirschberg 1990). In NewSpeak’s original discourse model, this stack was popped at each paragraph boundary. In addition to this model of LOCAL FOCUS (Sidner 1983; Grosz et al. 1983; Brennan et al. 1987), NewSpeak creates a GLOBAL FOCUS SPACE from the set of roots of open-class items mentioned in the first sentence of the text, assuming that that sentence can be treated as topic-defining. While the set of items in local focus is constantly sub- ject to change, items in global focus remain so through- out the discourse. Note that no attempt has been made at this stage to model (Grosz and Sidner 1986)‘s atten- tional structure entirely. In particular, no aspect of in- tentional structure is included, and objects, properties and relations are represented here by their roots rather than by some more abstract conceptual representation. Also, no positional distinction is made among items on in a focus space - or between focus spaces, except for the local-global distinction. In NewSpeak’s original accent assignment algorithm, items in either global or local focus were treated as GIVEN, representing OLD INFORMATION in the dis- course (Halliday and Hassan 1976; Chafe 1976; Clark and Clark 1977; Prince 1981), which a speaker is en- titled to believe is shared with his/her hearer. Subse- quent mention of this item was deaccented, in line with empirical results (Brown 1983) suggesting that listen- ers associate accented items with NEW information and deaccented items with given information. In sum, the original accent assignment algorithm in NewSpeak operated as follows: o If the current word was a cue phrase, it received pitch accent assignment based upon its phrasal position, as described in (Litman and Hirschberg 1990); word was a closed class e If the current deaccented; item, it was 0 If the current word’s it was deaccented; root was in local or global focus, e If compound-stress assignment indicated that the word should be deaccented, it was deaccented; o Otherwise, the word was accented. While this algorithm proved fairly successful at pro- ducing natural-sounding speech from text such as AP News stories, it was clear from observations of human speech that not all that is ‘given’ is deaccented. It was also clear that NewSpeak’s model of attentional state was insufficient to model even the given/new dis- tinction. In particular, the domain over which items remain given - and the process by which they lose that ‘givenness’ - are open research questions. To refine this original approach to accent assign- ment, to develop some evaluation procedures for prosodic assignment in speech synthesis, and to con- tribute more generally to research on models of dis- course, NewSpeak’s pitch accent assignment algorithm is being tested against prosodic labeling of natural speech. Certain interesting disparities have been found so far between NewSpeak output and labeled read speech. Some of the deficiencies in the original algorithm ap- pear due to an over-simplistic mapping between part- of-speech information and pitch accent. Some lexical items commonly counted as closed-class items regu- larly receive pitch accents. More difficult to correct are inadequacies in the discourse model. The simple identification of given information with deaccented lex- ical items and new information with accented items is clearly inadequate. Items which are quite plausi- bly deaccentabIe in terms of their information status are frequently not deaccented. And the behavior of nominal compounds with respect to both the impart- ing of ‘givenness’ to subsequent discourse and the con- sequences of ‘givenness’ on accent strategies for the compound, reveals considerable complexity. However, whether these problems can be addressed simply by refining the collection, representation, and updating of the attentional state, or must be supplemented by the representation of additional discourse features such as focus of attention and contrast remains to be deter- mined. Comparisons with Recorded Speech The corpus being examined for prosodic comparison is the FM Radio Newscasting Database, a series of studio recordings of newscasts provided by National Public Radio Station WBUR in association with Boston Uni- versity, which is being collected by SRI International (Patti Price), Boston University (Mari Ostendorf), and MIT (Stefanie Shattuck-Hufnagel). The prosodic anal- ysis of this data which serves as the basis for the discus- sion below employs Pierrehumbert’s (Pierrehumbert 1980) description of English intonation. In this sys- tem, intonational contours are described as sequences of low (L) and high (II) t ones in the FUNDAMENTAL FREQUENCY CONTOUR (f0). A phrase’s TUNE isrepre- sented as a sequence of one or more PITCH ACCENT(S), ~PHRASE ACCENT, and ~BOUNDARY TONE. ForPier- rehumbert, there are six types of pitch accent in En- glish, two simple tones - high and low - and four com- plex ones. The high tone, the most frequently used ac- cent, comes out as a peak on the accented syllable and is represented as ‘H *‘; the ‘H’ indicates a high tone, and the ‘*’ that the tone is aligned with a stressed syl- lable. Low (L*) accents occur much lower in the pitch 954 NATURAL LANGUAGE range than H* and are phonetically realized as local fo minima. Complex accents have two tones, one of which is aligned with the stress. Using the diacritic ‘*’ to indicate this alignment, these accents can be rep- resented as L*+H, L+H *, H*+L, and H+L*. A well-formed INTERMEDIATE PHRASE consists of one or more pitch accents, plus a simple H or L tone which characterizes the phrase accent. The phrase accent spreads over the material between the last pitch accent of the current intermediate phrase and the beginning of the next - or the end of the utterance. INTONA- TIONAL PHRASES are composed of one of more such intermediate phrases plus a BOUNDARY TONE, which may also be H or L and is indicated by ‘%‘. It falls exactly at the phrase boundary. A sample of this prosodic labeling for the FM Radio database appears below: Wanted. Chief Justice of the Massachusetts Ii* LLX H*+L H*+L - - L+H* Supreme Court. In April(l) the SJC's current H*+L H* LL% L* H* - - H* leader Edward Hennessy reaches the mandatory H* H* LHX H* - H* retirement age of seventy and a successor is H* - - L+H* L - - L+H* - expected to be named in March. It may be the H* - - H* - H*+L LL% - L+H* H*+L - most important appointment Governor Michael H* L+H* H* H* Dukakis makes during the remainder of his H* L+H* L - - L+H* - - administration and one of the toughest. As H* L L+H* L L* - - H+L* LH% - W BUR's Margo Millnicove reports, Hennessy(2) will H* - H* H* H* L H* be a hard act to follow. - - H*+L H*+L - H* T-LX Results of Initial Comparisons For experimental purposes, structural information used for accent assignment was limited to the part- of-speech tagging and NP identification available from Church’s tagger (Church 1988). Also, NewSpeak’s ini- tial model of attentional state was replaced by one which allows procedures for constructing the atten- tional state to be varied systematically, and also per- mits additional sources of discourse information, such as FOCUS OF ATTENTION ( ‘what attention is now to be focussed upon’) to interact with given/new status and word class in pitch accent assignment. In the cur- rent implementation, such features can be added or subtracted from the model and methods of calculating their values can also be varied. The goal of such vari- ation is of course the determination of which features, and which methods of calculating them, best predict pitch accent strategies in actual speech. Initial comparisons have varied the following: o how items are divided into closed/open-class by part-of-speech; which classes of items are considered in developing the attentional state model, e.g. all open-class items, nouns only, and so on; the mapping between word root and givenness (e.g., should mentioning helpfil make heZp ‘given’? un- helpfil?); whether the attentional state should be structured as a simple stack of sets, or whether order should be imposed within the focal spaces, or whether dis- tance between focal spaces on the stack should be important; how the attentional stack should be updated (e.g., by phrase, sentence, paragraph boundary or something else); whether nominal compounds function as ANAPHORIC ISLANDS for accenting purposes, as they do to some extent for pronominalization (i.e., whether the utterance of a compound nominal li- censes the subsequent deaccenting of its subparts or not); whether notions of focus of attention and contrast, insofar as they can be inferred from unrestricted text, improve the model of accent assignment, and, if so, how they interact with word class and given/new distinctions. Thus far, results from testing variations of NewSpeak’s algorithm on two samples (each about five minutes long) from the FM Radio corpus suggest certain refinements of the original algorithm. Some of these are discussed below. However, it should be stressed that analysis of a much larger amount of la- beled speech will be necessary to demonstrate their usefulness - and will also permit the analysis of in- teractions among the structural and discourse features described below. Even from such slim data, it appears that the sim- ple mapping between closed-class and deaccentuation employed in most text-to-speech systems must be mod- ified. Word classes properly treated as closed for some purposes may nonetheless commonly be accented. In a more sophisticated variant of the NewSpeak’s ac- cent assignment algorithm, closed-class items are di- vided into three categories. Possessive pronouns (in- cluding wh-pronouns), definite and indefinite articles, copulas, coordinating and subordinating conjunctions, existential there, have, accusative pronouns and wh adverbials, most prepositions, positive modals, posi- tive do, a8 well as some particular adverbials like orgo, nominative and accusative it and nominative they, and some nominal pronouns (e.g. something) are iden- tified as ‘closed, deaccented’. And certain of these classes are marked for further reduction in synthesis via CLITICIZATION, involving the removal of adjacent word boundaries and vowel reduction. ‘Closed, ac- cented’ items, on the other hand, include the negative article, negative modals, negative do, most nominal HIRSCHBERG 955 pronouns, most nominative and all reflexive pronouns, pre- and post-qualifiers (e.g. q&e), pre-quantifiers (e.g. (~24, post-determiners (e.g. nezt), nominal ad- verbials (e.g. here), interjections, particles, most wlb words, plus some prepositions (e.g. despite, unlike). Other word classes (adjectives, adverbials,common and proper nouns, verbs) are deemed ‘open’. For purposes of acquiring given/new information, only open-class items are considered, although how much of this cate- gory to consider is also subject to variation. The collection and manipulation of the attentional state representation has been varied experimentally in the following ways: both global and local focus repre- sentations have been manipulated independently such that the global focus space may be set, and the lo- cal focus spaces updated, by the orthographic phrase, the sentence, or the paragraph. So, for example, the global space may be set after the first phrase, sentence or paragraph of a text. The local stack can be updated independently at the end of each phrase, sentence or paragraph - although cue phrases will push or pop the stack as well. For the current experiments, the best results to date have come when the global space is de- fined to be the first full sentence of the text and the local attentional stack is updated by paragraph. The content of both global and local focus spaces have also been varied systematically by word class, so that all open-class words, nouns only, or nouns plus some com- bination of verbs and modifiers are allowed to affect - and be affected by - the attentional state representa- tion. Preliminary results, which again should be taken as suggestive only, indicate that focal spaces defined in terms of roots of all content words, rather than nom- inals only, or even all nonverb roots, provide the best accent prediction. Finally, some experimentation has been done to re- late the accenting of items currently in local focus with structural and discourse-based indicators of con- trastiveness. For example, the referential strategy of PROPER-NAMING (Sanford et ~bl. ), in which the use of proper names was found to focus attention, may pro- vide an explanation for an observed propensity in the FM Radio data for accenting proper names on subse- quent mention (e.g. the pitch accent on Hennessy ((2) in the FM database sample). It is conjectured that such referential behavior might indicate the speaker’s attempt to focus attention upon persons recently men- tioned, when other focii have intervened since their in- troduction. This strategy, together with others which can be inferred from surface and syntactic features of the text, such as the preposing of adverbials and of prepositional phrases (e.g., In April ((1) in the sam- ple), and the reintroduction of items in global but not in local focus, are hypothesized as predictors of con- trastive focussing accents. Such considerations often appear to account for the accenting of items which seem clearly ‘given’ and thus potentially deaccentable. Hypothesizing such focussing behavior appears to be useful enough in accent prediction to warrant the in- vestigation of other structural and discourse correlates of focus in future work. Discussion This paper has described the pitch accent assignment strategy employed in NewSpeak, an interface to the Bell Labs Text-to-Speech System, which employs a hi- erarchical representation of the attentional structure of the discourse, together with more traditional syntactic information, to assign intonational features in the syn- thesis of unrestricted text. It has also described exper- iments currently being performed to refine that algo- rithm, by modifying traditional uses of word class, key word, and surface position information, and by varying the construction of and interaction between the com- ponents of a model of attentional state. The testing of various discourse models against pitch accent place- ment in actual speech, should also add to our set of evaluation criteria for such models. From a theoretical point of view, such analysis should bring us closer to understanding how to model pitch accent in human speech. However, real progress will depend upon the availability of large amounts of prosodically labeled data. From a more practical point of view, an immediate use of the accent assignment al- gorithm being developed will be to facilitate just such data analysis, providing hypotheses about prosodic features which can then be post-edited by hand - to speed up the labeling process. The resulting labeled speech can then of course be used for further training of the algorithm. While the use of higher level discourse information to inform algorithms for pitch accent assignment ap- pears to be a useful strategy for modeling accent as- signment in natural speech, it may indeed turn out not to be desirable to emulate natural speech in syn- thetic speech. The work described above assumes, however, that whatever variation eventually emerges as desirable between synthetic speech and human speech should clearly be intentional and principled rather than chance. Proving that one speech synthesizer is prefer- able to another, or that one prosodic strategy is to be favored over another, in terms of simple human preference is notoriously difficult to accomplish. So, comparison of the output of algorithms used to assign intonational features in synthetic speech with prosodic features in natural speech would appear to be our most effective test of whether or not we are making actual improvements in the prosody of speech synthesis. Acknowledgments Thanks to Ken Church, Rick Omanson, and Richard Sproat for helpful comments. References Altenberg, B. 1987. Proso& Patterns in Spoken English: Studies in the Correlation between Prosody 956 NATURALLANGUAGE and Grammar for Text-to-Speech Conversion, vol- ume 76 of Lund Studies in English. Lund University Press, Lund. Bolinger , D . 1961. Contrastive accent and con- trastive stress. Language, 37:83-96. Bolinger, D. 1972. Accent is predictable (if you’re a mindreader). Language, 48:633-644. Brennan, S. E., Friedman, M. W., and Pollard, C. J. 1987. A centering approach to pronouns. In PTO- ceedings of the 25th Annual Meeting, pages 155-162, Buffalo. Association for Computational Linguistics. Brown, 6. 1983. Prosodic structure and the given/new distinction. In Ladd, D. R. and Cut- ler, A., editors, PTOSOdy: Models and Measurements. Springer Verlag, Berlin. Chafe, W. 1976. Givenness, contrastiveness, defi- niteness, subjects, topics, and point of view. In Li, C., editor, Subject and Topic. Academic Press, New York. Church, K. W. 1988. A stochastic parts program and noun phrase parser for unrestricted text. In Proceed- ings of the Second Conference on Applied Natural Language Processing, pages 136-143, Austin. Asso- ciation for Computational Linguistics. Clark, H. H. and Clark, E. V. 1977. Psychology and Language. Harcourt, Brace, Jovanovich, Inc. Cruttenden, A. 1986. Intonation. Cambridge Uni- versity Press, Cambridge UK. Crystal, D. 1975. The English Tone of Voice: Essays in Intonation, Prosody, and Paralanguage. Edward Arnold, London. Danlos, L., LaPorte, E., and Emerard, F. 1986. Syn- thesis of spoken message from semantic representa- tion. In Proceedings of COLING-86, pages 599-604. COLING. Davis, J. R. and Hirschberg, J. 1988. Assigning intonational features in synthesized spoken direc- tions. In Proceedings of the 26th Annual Meeting, pages 187-193, Buffalo. Association for Computa- tional Linguistics. Grosz, B. and Sidner, C. 1986. Attention, inten- tions, and the structure of discourse. Computationa Linguistics, 12(3):175-204. Grosz, B., Joshi, A., and Weinstein, S. June 1983. Providing a unified account of definite noun phrases in discourse. In Proceedings of the 2lst Annual Meet- ing, pages 44-50, Cambridge MA. Association for Computational Linguistics. Halliday, M. A. K. and Hassan, R. 1976. Cohesion in English. Longman. Hindle, D. M. 1989. Acquiring disambiguation rules from text. In Proceedings of the 27th Annual Meeting, pages 118-125, Vancouver. Association for Computational Linguistics. Jackendoff, R. S. 1972. Semantic Interpretation in Generative Grammar. MIT Press, Cambridge MA. Liberman, M. and Sproat, R. Forthcoming. The stress and structure of modified noun phrases in En- glish. In Sag, I., editor, Lezical Matters. University of Chicago Press. Litman, D. and Hirschberg, J. August 1990. Disam- biguating cue phrases in text and speech. In Pro- ceedings of COLINGSU, Helsinki. COLING. Olive, J. P. and Liberman, M. Y. 1985. Text to speech - an overview. Journal of the Acoustic Soci- ety of America, Suppl. 1, 78(Fall):s6. Pierrehumbert , J. B. 1980. The Phonology and Phonetics of English Intonation. PhD thesis, Mas- sachusetts Institute of Technology. Prince, E. 1981. Toward a taxonomy of given-new information. In Cole, P., editor, Radical Pragmatics. Academic Press, New York. Quirk, R., Svartvik, J., Duckworth, A. P., Rusiecki, J. P. L., and Colin, A. J. T. 1964. Studies in the correspondence of prosodic to grammatical features in English. In Proceedings of the Ninth International Congress, pages 679-691. International Congress of Linguists. Rooth, M. 1985. Association with Focus. PhD thesis, University of Massachusetts, Amherst MA. Sanford, A. J., Garrod, S. C., Moar, K., and Al- Ahmar, H. 1985. Naming, role-descriptions, and main and secondary characters in discourse compre- hension. Reported in Sanford, A. J. Aspects of pro- noun interpretation: Evaluation of search formula- tions of inference. In Rickheit, G. and Strohner, H., editors, Inferences in Text Processing, pages 183- 204. North-Holland, Amsterdam. Sidner, C. L. 1983. Focusing in the comprehension of definite anaphora. In Brady, M., editor, Compu- tational Models of Discourse. MIT Press, Cambridge MA. Silverman, K. 1987. The Structure and Processing of Fundamental Frequency Contours. PhD thesis, Cambridge University, Cambridge UK. Walker, M. A. 1989. Evaluating discourse process- ing algorithms. In Proceedings of the 27th Annual Meeting, pages 25 l-26 1, Vancouver. Association for Computational Linguistics. Young, S. J. and Fallside, F. 1979. Speech synthesis from concept: A method for speech output from in- formation systems. Journal of the Acoustic Society of America, 66(3):685-695. HIRSCHBERG 957
|
1990
|
171
|
928
|
Structure of Perspectivity: A Case of Japanese Reflexive Pronoun “dwP 3-9-l 1 Abstract Yasuhiro Katagiri NTT Basic Research Laboratories Midori-cho, Musashino, Tokyo, 180 Japan katagiri%atom.ntt.jp@relay.cs.net A theory of perspectivity is proposed to establish the foundation of the theory of situated agents. An ac- count is then given, based on the theory of perspectiv- ity, of the use of a seemingly perspectivity related ex- pression, Japanese long-range reflexive “zibun. ” The theory we proposed for perspectival mental states in- corporates two independent notions, indexicality and world view. The first captures the situatedness of agents within physical environments, and the second captures the mode of reasoning adopted by agents in interacting with other agents. The relationship be- tween these two notions were also discussed. Based on the proposed theory of perspectivity, we argued that, contrary to wide-spread beliefs, the usage of “zibzsn” is not directly related to perspectivity. We gave an alter- native explication for the interaction of the usage of “zibun” with perspectivity sensitive expressions and the indexical pronoun “w&ash% (I),” in terms of the coreference rule for “zibun,” the constraint on the two components of perspectivity, and the agent awareness default principle for the world view. Introduction The aim of this paper is twofold. The first is to pro- pose a theory of perspectivity that is reasonable and powerful enough to be the basis of the theory of sit- uated agents. And the second is to give, based on the theory of perspectivity, an account of the use of a seemingly perspectivity related expression, namely, Japanese long-range reflexive “ibun. ” Intelligent agents acting in an environment are not outside observers of what’s happening in the world. They are embedded in and interacting with their sur- rounding environments. For that reason, they perceive, recognize and even describe facts of the environment not from a detached, god’s eye view, but from where they stand in it. Perspectivity, I take, has its origin in this kind of situatedness of agents within environ- ments. On the other hand, we could and do sometimes imag- ine a situation from other person’s perspective. How things would look like if I were her? This mode of recognition and reasoning is a fairly common practice in our daily activities, including such cases as when we are thinking of, trying to explain, or making sense of other person’s behaviors, be they real or imaginary. Since perspectivity is deeply rooted in human na- ture as situated agents, it is quite natural that sys- tems of our languages be prepared with mechanisms to reflect and express perspectivity. Different from En- glish reflexive pronouns, which should be co-referential with the subject noun phrases of the same clauses that reflexives appear in, there are several languages in- cluding Japanese that have so called long-range re- flexives, which could have their antecedents outside the clauses where original reflexives appear. The use of these long-range reflexives have been accounted for by several authors in terms of such notions as empathy[Kuno & Kaburaki, 1977, Kuno, 19871 and logophoricity[Kameyama, 1984, Sells, 1987, Iida & Sells, 1988]. Simply put, all of these accounts are based on the intuition that the use of these long-range re- flexives are governed by perspectivity, i.e., from whose point of view the sentence is uttered. I would argue in this paper first that perspectivity phenomena have two independent ingredients, which I would call indexicality and world view, and second that, contrary to the explications currently wide-spread, the use of Japanese reflexive “zibun” is not directly related to perspectivity. I will give an alternative explanation for the apparent interaction of “zibun” and perspectiv- ity based on the two-part theory of perspectivity. Perspectivity and perspectival utterances Our perspectival recognition of environments must pri- marily be reflected in the structure and organization of our representations. Based ori our perspectival repre- sentation of the environment, when we use language, we sometimes use expressions that are sensitive to per- spectivity. So, perspectivity in our representation must be reflected in both the system and the use of our lan- guage. The following characteristics is particularly impor- tant when we think of perspectivity of our representa- tion. 958 NATURAL LANGUAGE From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. e Missing arguments An agent’s perspectival recognition of facts amounts to the omission of certain arguments for relations in them. To put it differently, in a perspectival rep- resentation an agent is adopting argument-reduced relations. Think of the relation LEFT-OF. My coffee cup being left of my computer terminal is actually a fact con- sisting of the three-place relation LEFT-OFa, my coffee cup, my computer terminal, and myself; my coffee cup is left of my computer terminal seen from me. But I do not and need not be aware of the third argument, myself, when I move my left hand to reach for the cup. This argument is missing in my representation. To say it differently, I am, in that case, conceiving of this fact as if it consisted of the two-place relation LEFT-OF2, my coffee cup, and the terminal. In addition to taking into account missing argu- ments, giving reasonable accounts to the following two phenomena has also to be taken as the requirement for any theory of perspectivity. Account of transferability Not only we can recognize our environment from points of view of ourselves, we can take on others’ perspectives and could conceive of what the environ- ment would look like if we were they. This ability of assuming other agent’s perspective is one of the cen- tral functions that differentiates perspectivity from self-identity. The goal of perspective transfer is nor- mally restricted to animate agents. Account of interaction between representa- tion and language In addition to the fact that in perspectival utterances the person whose perspective the speaker is assum- ing is often omitted and made implicit in sentences uttered, each language has a set of perspectivity sen- sitive expressions. The theory of perspectivity has to give an account of the interaction between perspec- tival representation of the speaker and the linguistic expressions used in utterances. Japanese long-range reflexive “zibun” Each language has its own repertoire of perspectiv- ity sensitive experssions, and Japanese, too, has its own distinctive set of them. Moreover, Japanese long- range reflexive “zibun” has been claimed to interact with them[Kuno & Kaburaki, 1977, Kameyama, 19841. In (l), lexical item “iku (go)” 1 requires the speaker’s point of view to be placed on the person at the source of the movement, which is realized as the subject of the sentence, e.g., “Taro.” Since the speaker herself has to be given the highest priority in the set of people on which to place the speaker’s point of view, the sen- tence (2), which requires a speaker to place her point of view on Taro rather than on herself, is judged bad for most Japanese native speakers. (1) Taro-ga Hanako-no ie-ni itta. SBJ GEN house-GOAL went (Tar0 went to Hanako’s house.) ?( 2) Taro-ga watashi-no ie-ni itta. SBJ I-GEN house-GOAL went (Taro went to my house .) Similarly, the auxiliary verb “kurervP2 indicates that the speaker’s point of view is placed on the person at the indirect object (10~) position. Due to this restriction posed by “kureru,” while (3) is acceptable with the speaker’s point of view being placed on the indirect object “Hanako,” (4) is bad because of the conflict in perspectivity requirement of “kureru” and that of “wa~ashi (I).” (3) *w Taro-ga Hanako-ni hon-wo SBJ IOB J book-OB J yonde-kureta. read -POV-IOBJ (Taro read a book for Hanako.) Watashi-ga Hanako-ni hon-wo I -SBJ IOBJ book-OBJ yonde-kureta. read -POV-IOBJ (I read a book for Hanako.) the use of these perspectivity sensitive expressions. Comparable to the contrast between (l)(3) and (2)(4), the sentence (5) is acceptable, whereas (6) is not. (5) *w Hanako-wa Taro-ga zibun-ni hon-wo TOP SBJ SELF-IOB J book-OB J yonde-kureta koto-wo oboeteiru. read -POV-IOBJ NOM-OBJ remember (Hanakoi remembered that Taro read a book for self; .) Hanako-wa zibun-ga Taro-ni hon-wo TOP SELF-SB J IOB J book-OB J yonde-kureta koto-wo oboeteiru. read -POV-IOB J NOM-OB J remember (Hanakoi remembered that selfi read a book for Taro.) Distribution of “zibun” is apparently correlated wit h Both in (5) and (6), the use of the auxiliary verb “kureru” requires the speaker’s point of view to be placed on indirect objects, that is, “zibun” in (5), but Taro and not “ribun” in (6). So, if we assume “zibun” refers to the person whose perspective the speaker is taking on, these acceptability judgments of (5) and (6) could well be explained. These observations apparently suggest that the func- tion of “.zibun” is to refer to the point of view location. l“itta” is the agglutination of the root of the verb “&es (go)” and the past tense marker “tu.” ’ “kureta” is the agglutination of the root of the verb “kureru” and the past tense marker “ta.” auxiliary KATAGIRI 959 But, the sentences below are known to be perfectly acceptable Japanese sentences[Iida & Sells, 19SS]. (7) (8) Taro-wa zibun-ga kaita hon-wo TOP SELF-SB J write book-OB J watashi-ni yonde-kureta. I -1OBJ read-POV-IOBJ (Taroi read the book selfi wrote to me.) Taro-wa wat ashi-ga zibun-wo buuta TOP I-SB J SELF-OBJ hit koto-wo oboeteiru. NOM -0BJ remember (Taroi remembers that I hit selfi.) Both in (7) and (S), “&bun” is acceptable without re- ferring to the speaker. Furthermore, in (7), point of view location do not even coincide with “zibun”. The use of “kureru” indicates that the speaker is uttering the sentence from her own perspective, whereas “zi- bun” refers successfully to Taro. These sentences apparently suggest, contrary to (5) and (6), that the use of “zibun” may not have any straightforward relationship to the notion of perspec- tivity. Any account of the use of “zibun” has to give a reasonable explanation to these conflicting intuitions for the relationship between perspectivity and “zibun”. Structure of perspectivity Apparent conflict concerning the relationship between usages of “zzibun” and perspectivity described above suggests that the notion of perspectivity needs some clarification. I will propose below a theory of perspec- tivity which claims that perspectivity actually consists of two independent notions, which I call indexicality and world view. Indexicality The first constituent of perspectivity is related to the situatedness of agents. An agent representing a certain state in her surrounding environment is in a mental state that is in some sense structurally isomorphic to the things represented. Under a situation semantical framework[Barwise & Perry, 19831, an agent A’S believ- ing that a block U is on another block V is a situation classified by the following state of affairs(SOA). ((Bel, A, [il.+ l= ((on, 2, i91)) A's mental state itself is classified by a parametric type of situation, [&IS k ((on,x,Y))], which shows that the mental state of A is structurally similar to the state represented, e.g., a situation where the block U is on V. Parameters li; and j, correspond respectively to A’s concepts of blocks U and V. The second and the third conjuncts in the above formula show that these two concepts are anchored to the real objects U and V, hence guaranteeing that A’s mental state is really a represen- tation of her surrounding environment. We observed that, in a perspectival representation of an environmental state, the entity from whose point of view the state is represented, typically the agent her- self, is omitted and functions as a missing argument. This is probably made possible by the fact that the agent is embedded in the environment and plays the particular role of the center of coordinates in her repre- sentation. All the perceptual information converges to the agent, and all the actions originate from the agent. We proposed elsewhere[Katagiri, 19891 to represent this kind of indexicality by incorporating a complex relation that has a reduced number of arguments to classify the agent’s perspectival mental states. Con- sider the block U located to the left of another block V seen from the agent A. A’s perspectival recognition of this situation can be classified by the SOA below, which incorporates a two-place complex relation LEFT-OF+, constructed out of the three-place relation LEFT-OF. ((Bel,A,[kIk + ((LEFT-OF~~,,I&+)) A ((=, pk, klf))])) A((of , % U)) A ((of, k V)) where the relation LEFT-OFpbv is a complex relation, [~,~~(((LEFT-OF&~, g&v))]. The SOA ((=, p6v, s&f)) in A’s belief shows that she is taking on her own perspective. The point of this repre- sentation is that the use of two-place complex relation LEFT-OFpo, is not merely for notational convenience, but the relation itself has significance in actual reason- ing processes within A’s perspectival mental states. World view Under the situation semantical formulation described above, the essential constituent determining an agent’s mental state is the type of situation classifying the mental state, e.g., the second argument of the Be1 SOA. And the type of situation in turn is determined by the set of parametric SOAs that are constituents of that type. So, we could regard the set of parametric SOAs as the agent’s mental state representing her surround- ing environment. When the set includes a SOA whose major constituent is a perspectival relation, the mental state is itself perspectival. Mental states could represent not only our physical environments but also our social environments. Among them are other agents and the way other agents con- ceive of their surrounding environments. As is shown in (5)~(8) > “zibun” is used mostly in sentences describ- ing other agent’s actions and states. In these sentences, uses of each clauses and descriptions have two possible origins. They could be based either on the judgment of the speaker herself, or on the judgment of the agent.3 'More precisely, on the belief of the speaker about the judgment of the agent. 960 NATURAL LANGUAGE S ((ON, k i>> ({LEPT-~P~~~, X, i)) . . . A ((RIGHT-OFpo,, x, i)) . . . Figure 1: World view of speaker S and agent A This division of judgments is depicted in figure 1. The speaker S has two sets of SOAs, one for her own conception of the environment, the other for (her con- ception of) the other agent’s (A’s) conception of the en- vironment. We call these sets of SOAs world views. The set of SOAs at the top level is S’s world view, whereas the set embedded is the world view of A’s (within S). S could use either of the world views in reasoning and in constructing expressions to make utterances. Sentence production process In a more serious model of language production, we have to take into account the fact that the speaker actually chooses an expression in uttering a sentence based on her conception of what is mutually believed by both the speaker and the hearer[Clark & Carlson, 1982, Appelt, 19851. But we ignore in this paper this mutual belief aspect involved in language production. This simplification is irrelevant for the essential point made in this paper. We assume here that, in producing sentences, particularly ones describing other agent’s actions and states, the speaker chooses, for every de- scription that comprises a noun phrase and for every sub-clause, to adopt either her own world view or the other agent’s world view. Consider an utterance of the following sentence. 3) Taro-wa ano koukana ie-wo TOP that expensive house-OB J yasui to itta. cheap COMP said (Tar0 said that that expensive house is cheap.) The only consistent interpretation of the utterance is that the description of the house being expensive is within the speaker’s world view, whereas the assertion of the house being cheap is within Taro’s world view. Interact ion between indexicality and world view So far, the two dimensions of perspectivity, indexical- ity and world view, are considered independently. But, there are restrictions on what values we could assume along these two dimensions. The table below summa- rizes the constraint. I(indexicality)=W( world view)=S( speaker) means that the speaker is taking her own perspective, whereas I=W=A(agent) corresponds to cases where the speaker is taking on the other agent A’s perspective. The asymmetry between I=A&W=S, which is legit- imate, and I=S&W=A, which is not, is because in the former situation, the speaker S raises A’s p6v value to her own world view, hence partially taking on A’s perspective with her own descriptive framework, while to realize the latter combination, the speaker S has to embed her own pOv value into the world view of the agent A, which is impossible, since S knows that her own pbv value is outside the A’s embedded world view and hence inaccessible from it. The former situation, I=A&W=S, is typical in a per- son having heard and comprehended a perspectival ut- terance. Upon comprehending what a speaker’s per- spectival utterance means, the hearer normally takes only on the speaker’s I value, but adopts her own stock of descriptions to describe/identify objects. Agent awareness default principle There is another constraint concerning world view and language production. This constraint is not the one which has to be strictly observed. Rather, it provides a default value for the world view in producing utter- antes. Agent awareness default principle When describing actions and states of an agent, the speaker adopts the agent world view by default. Agents usually perform actions consciously. They are conscious of the facts that they will perform, are per- forming, and have performed the actions. And they are aware of facts that had held before, having been held throughout, and were established by the actions. Hence, it is natural to assume, in an utterance report- ing an agent’s behavior, descriptions, and hence world view, are usually taken to be of the agent’s by default. Perspectivity and “zibun” Having developed the underlying theory of perspec- tivity, we can now state the hypothesis concerning the usage of “zibun” in the form of a coreference rule. Note that the rule below is not itself directly related to the notion of perspectivity. Coreference rule for “zibun” The use of “zibun” is based on the judgment of iden- tity of the referent of “zibun” to the logical agent of an action or to the logical experiencer of a mental state described in the sentence.4 *By “logical” I mean here that we take these case roles as relations at the level of semantic representation, which are relatively independent of surface syntactic realizations. KATAGIRI 96 1 The point of the coreference rule above is that the identity judgment for the use of “zibun” could either be based on the speaker’s world view or on the agent’s Although, by the agent awareness default principle, the judgment is taken to be of the agent’s by de- fault, in a special circumstances where the principle could be defeated, the judgment can be strictly of the speaker’s. The following sentence with “zibun” refer- ring to Taro can be used without any problems to de- scribe Taro’s amnesia story. Since Taro, being amne- siac, does not have the knowledge of his having been a baseball player, the agent awareness default has to be defeated and the identity judgment for “zibun” in this case is based on the speaker’s world view. -0) Taro-wa zibun-ga yakyuu-senshu datta TOP SELF-SB J baseball-player was koto-wo shira-nai. NOM -0BJ know-NEG (Taroi does not know that selfi was a baseball player .) Interaction of “zibun” and perspectivity Given the constraint on indexicality and world view, and the coreference rule for “&bun,” we can give an explanation to the possibility of apparent conflict be- tween the usage of “zibun” and perspectivity phenom- ena, namely, why sentences (7) and (8) are acceptable. According to the constraint, when an expression is originated from the speaker’s world view (W=S), there are two possibilities for the indexicality value, the speaker and the agent (I=S or I=A). If the speaker takes herself (S) as the indexicality value, “&bun” could refer to an agent without the agent necessarily occu- pying the value of indexicality p6v. In both of the sentences (7) and (8), we could inter- prete the judgment of the coreference of “&bun” and the agent of reading the book or the experiencer of remembering as originating from the speaker’s world view. Under that interpretation, these sentences can be construed without problems, even if we take the speaker as the indexicality value. After freeing %bun” from perspectivity, the remain- ing task is to explain apparent interaction between the two; namely, why (6) is judged bad. An explanation can be found by looking at the agent awareness default principle. The use of “0 boeteiru (remember)” in (6) enforces the application of the agent awareness default princi- ple, and the complement clause, what is remembered, is taken by default to be within the agent Hanako’s world view. But once that default value is assumed, the constraint on world view and indexicality restricts the possible value for indexicality to the agent Hanako. On the other hand, the auxiliary verb “kureru” requires the indexicality value to be the one in the indirect ob- ject position, e.g., Taro. The sentence is judged bad because of the incoherence caused by these two con- flicting requirements. The subtlety of the interaction of agent awareness default principle and perspectivity could be seen by the following pair of sentences. (11) (12) Taro-wa zibun-no tsuma-no migigawani TOP SELF-GEN wife-GEN to-the-right Hanako-ga iru noni kigatsuita. SBJ be COMP noticed (Taroi noticed that Hanako was to the right of selfi’s wife.) Taro-wa zibun-no tsuma-no migigawani TOP SELF-GEN wife-GEN to-the-right Hanako-ga iru noni kigatsuitei-nai youda. SBJ was COMP noticed-NEG seem (Taroa seems not to have noticed that Hanako is to the right of selfi’s wife.) In (ll), the use of “kigatsuita (notice)” enforces the agent awareness default and by the chain of reason- ing similar to the one for (6)) indexicality value, which fills the missing argument of RIGHT-OF,o,, has to be the agent Taro. In constrast, the negation of noticing in (12) together with uncertainty in judgment could prevent the application of the agent awareness default, and consequently the RIGHT-OF,o, of (12) can be in- terpreted from the point of view of the speaker. Conclusions We proposed our theory of perspectivity as a basis for the theory of situated agents. Situatedness has two aspects; situatedness in physical environment, and sit- uatedness in social environment. Each of the two as- pects has its own repercussions to the organization of representations. An agent can exploit environment as an extension of its representational medium and put as much information as possible into environment rather than into their own representation. Secondly an agent can use its own representation in reasoning about rea- soning performed by other agents. Our notions of in- dexicality and world view together with constraints on the interaction between the two capture both types of situatedness. Based on the theory of perspectivity, together with coreference rule for “zibun,” we showed that the use of Japanese long-range reflexive “zibun” is not directly related to perspectivity, and gave an alternative ex- planation for the interaction of “zibun” and perspec- tivity. We claimed that “zibun” simply corefers with the logical agent/experiencer of a sentence, and that behind the apparent interaction between perspectivity and “zibun” lies the interaction among this coreference function of “ribun, ” the constraint on the two compo- nents of perspectivity, and our default assumption on the world view speakers adopt in issuing utterances. One notable point of the account we gave of the use of “zibun” is that, although simple, the account is in 962 NATURALLANGUAGE the form of a process theory, which explains the us- age of “zibun” in terms of the structure of underlying representation and the mechanism of language produc- tion. As the account shows, this type of theory has far wider potential, compared with purely syntactic ap- proach conventional in linguistics, for explaining uses of linguistic expressions. Beyond the problem of perspectivity we discussed in this paper, we could expect our theory to be ex- tended, with relatively straightforward enrichment, to provide us with a new way of thinking of the con- cept of the discourse focus[Sidner, 19831 or that of the center[Grosz et al., 1983, Kameyama, 1986]. Our the- ory could then be accommodated to phenomena re- lated to the uses of elipsis and anaphora, in general, and to the use of Japanese zero-pronoun, in particu- lar. We are also thinking of applying our theoretical framework to problems in situated planning and plan recognition for situated agents. Acknowledgment The author would like to thank Ikumi Imani, Hajime Narita, Akira Shimazu, Ikuo Takeuchi, Syun Tutiya, and Masaaki Yamanashi for their helpful comments, criticisms, and supports. References Appelt, D. E. 1985. Planning English sentences. Cam- bridge University Press. Barwise, J. and Perry, J. 1983. Situations and Atti- tudes. MIT Press. Clark, H. H. and Carlson, T. B. 1982. Speech acts and hearers’ beliefs. In Smith, N. V., ed. 1982, Mutual Knowledge. Academic Press. chapter 1, l-36. Grosz, B. J.; Joshi, A. K.; and Weinstein, S. 1983. Providing a unified account of definite noun phrases in discourse. In Proceedings of the 2lst Annual Meeting of the Association of Computational Linguistics. 44- 50. Iida, M. and Sells, P. 1988. Discourse factors in the binding of zibun. In Poser, W. J., ed. 1988, Papers from the Second International Workshop on Japanese Syntax. Center for the Study of Language and Infor- mation, Stanford University. 23-46. Kameyama, M. 1984. Subjective/logophoric bound anaphora zibun. Chicago Linguistic Society 20:228- 238. Kameyama, M. 1986. A property-sharing constraint in centering. In Proceedings of the 24th Annual Meet- ing of the American Association for Computational Linguistics. 200-206. Katagiri, Y. 1989. Semantics of perspectival utter- ances. In Proceedings of the Eleventh International Joint Conference on Artificial Intelligence. Morgan Kaufmann. 1474-1479. Kuno, S. and Kaburaki, E. 1977. Empathy and syn- tax. Linguistic Inquiry 81627-672. Kuno, S. 1987. Functional Syntax: Anaphora, Dis- course and Empathy. The University of Chicago Press. Sells, P. 1987. Aspects of logophoricity. Linguistic Inquiry 18:445-479. Sidner, C. L. 1983. Focusing in the comprehension of definite anaphora. In Brady, M. and Berwick, R. C., eds. 1983, Computational Models of Discourse. MIT Press. KATAGIRI 963
|
1990
|
172
|
929
|
PRAGMA - A Flexible Bidirectional Dialogue System John M. Levine University of Cambridge, Computer Laboratory, Pembroke Street, Cambridge CB2 3QG, England. jml@uk.ac.cam.cl Abstract This paper gives an overview of a natural language dialogue system called PRAGMA. This system contains a number of novel and important features, as well as integrating previous work into a unified mechanism. The most important advance that PRAGMA represents compared with previous systems is the high degree of bidirectional@ employed in its design. A single grammar is used for interpretation and generation, and the same knowledge sources are used for plan recognition and response generation. The system is also flexible, in that it generates useful extended responses, not only to queries which allow the user’s plan to be inferred, but also to queries which do not allow this. 1. Introduction One of the most important and challenging areas of research in artificial intelligence is the design and construction of natural language dialogue systems. This task is one of the hardest artificial intelligence has to offer, since the overall goal is the implementation of a fully capable and fluent conversational partner. Research into the issues involved in building such a system is important for three main reasons. Firstly, it serves as an ideal context for the investigation of basic issues in natural language processing (e.g. syntax, semantics, parsing and generation) and artificial intelli- gence (e.g. knowledge representation, theorem proving, planning and plan recognition). Secondly, it is an important application area, in the form of natural language interfaces to database systems, explanation facilities for expert systems and interactive advisory services such as online help systems. Lastly, in terms of linguistic inquiry, it allows us to test existing theories of language and communication and to propose and test new ones by giving these substance in the form of a working computational model. This paper describes a natural language dialogue system which contains many novel and significant features, as well as integrating previous work from heterogenous sources into a unified mechanism. The 964 NATURALLANGUAGE system is called PRAGMA, which is an acronym for ‘Plan Recognition And Generation of Meaningful Answers.’ The most important advance that PRAGMA represents compared with previous systems is the high degree of bidirectionality employed. A single unification grammar with Montague semantics (Montague, 1974; Dowty, Wall and Peters, 1981) is used for literal interpretation and tactical generation (i.e. sentence real- isation from a representation of content and thematic organisation). Also, the same sources of information about possible plans, the domain, and the user’s beliefs are used to perform plan recognition and strategic generation (i.e. planning the content and thematic organisation of an appropriate response). Apart from this high degree of bidirectionality, there are three other aspects of the PRAGMA system which are novel and important. Firstly, we use a linguistically well-motivated set of functional features to specify the thematic organisation of a sentence. Secondly, the strategic generation component of the system provides useful extended responses, not only to queries which allow the user’s plan to be inferred, but also to queries which do not allow this. Lastly, we use a special algorithm for comparison of logical forms which solves the problem of logical form equivalence (Appelt, 1987; Shieber, 1988; Calder, Reape and Zeevat, 1989). The overall organisation of PRAGMA is shown in Figure 1. The Grammar Development Environment (Briscoe et al., 1987; Carroll et al., 1988) was used to define the bidirectional grammar and also acts as the major part of the literal interpretation component of the system. The propositional content of sentences is represented using standard first-order logical forms. Considered as a single unit, the logical form and functional features of a sentence are known as the logical message of that sentence. The plan recognition algorithm used in PRAGMA is based on research by Litman and Allen (1987) and Allen (1987). If plan recognition is successful, four significant pieces of information are inferred: the user’s discourse plan, discourse goal, domain plan, and domain goal. If plan recognition is unsuccessful, only From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Figure 1 The Organisation of the System the user’s discourse plan and discourse goal are in- ferred. The output from the plan inference process, together with the logical message of the user’s input sentence, is referred to as the fur2 meaning of the sentence. The strategic generation component of the system can deal with two types of dialogue. Task-oriented dialogues are handled by examining the user’s domain plan and planning speech acts to enable or disable this where appropriate. An example of this type of inter- action with PRAGMA is given below. Where is Pizzaland? It’s in Regent Street, but it isn’t open today. Is the Pizza Hut open today? No, but Pizza Express is. I don’t know where that is. It’s in St. Andrew’s Street. OK, thanks. the case of dialogues where no specific domain plan can be inferred, the functional features of the user’s query are used as a guide to the construction of appropriate extended responses. An example of this type of dialogue is shown below. Who designed Trinity’s library? It was designed by Wren. Was Trinity founded by Wren? No, it was founded by Henry the Eighth. Did Wren found King’s? No, it was Henry the Sixth who founded King’s. PRAGMA is written in Common Lisp and runs on a Hewlett Packard 9000 Series workstation under the HP-UX operating system. On average, a dialogue consisting of a single question and answer pair takes about 4 seconds of CPU time to run to completion. The next four sections of the paper describe each of the processing components of PRAGMA. To demon- strate how the system works, a single example will be traced through each of these stages. The example to be used for this purpose is as follows: Q: Is the Pizza Hut open today? A: No, but Pizza Express is. The final section of the paper briefly compares the work reported here with previously reported dialogue systems, evaluates PRAGMA, and discusses some directions for further research. LEVINE 965 2. Literal Interpretation The Grammar Development Environment (GDE) is a powerful software tool which facilitates the design and construction of large natural language grammars. Since it includes efficient facilities for parsing sentences and extracting the logical forms from the resulting parse trees, it is also used as the main part of the literal interpretation component of PRAGMA. The grammati- cal formalism employed by the GDE is similar to GPSG (Gazdar et al., 1985). This is compiled by the GDE to form a unification grammar consisting of a set of phrase structure rules whose categories are feature complexes. A simplified version of Montague seman- tics, similar to that used by Rosenschein and Shieber (1982), is used to compute the logical forms of sen- tences from their parse trees. The logical message formalism used for the intermediate representation of a sentence consists of a logical form plus a set of functional features. The notion of functional features is suggested by Appelt (1987), but he does not suggest a taxonomy; the work reported by Levine (1989) and in more detail by Levine and Fedder (1989) attempts to provide this. The purpose of these features is to provide the information contained in a sentence which is not reflected in the logical form, since this is important in both interpret- ation and generation. Five functional features are used in PRAGMA: theme, linguistic focus, emphasis, sen- tence type, and tense. The first three of these are the most important, and are adapted from the research of Quirk et al. (1985). In interpretation, the values of the functional features must be computed from the parse tree and logical form of the input sentence. The sentence level node of the parse tree contains three syntactic features: the sentence type (e.g. declarative), the tense (past or present), and the sentence style (e.g. passive). The sentence style is then used in conjunction with the logical form to determine the values of the three remaining features. For the example under consideration, the output from the literal interpretation module is shown below. Logical form = se.open(pizza-hut,e) A on(e,today) Sentence type = yes/no question Tense = present Theme = pizza-hut Linguistic focus = today Emphasis = false 3. Plan Recognition In order to perform plan recognition, we must first decide what kind of planning activity is going on in the mind of the user. The assumptions that we make about the nature of this process are as follows. The user has a domain goal and is constructing a domain plan to achieve this goal using the plan library. The plan library is a collection of action schemata and is assumed to be shared knowledge between the user and the system. The system is assisting the user in the process of constructing a domain plan, since the user has incomplete and possibly inaccurate knowledge of the domain. The system has complete and accurate knowledge of the domain, but incomplete knowledge about the user’s beliefs. The user needs to select an appropriate plan and then instantiate it so that it can be executed. During the plan construction process, the user may be considering a plan which cannot be proved valid or invalid given the incomplete nature of the user’s knowledge. The user will want to know whether such an undecidable plan is valid or not. This means that the user will have a discourse goal of the form knowif(user,p) or knowref(user,x,p(x)); the former arises from the need to find out whether the constraints on an action are true or false, the latter from the need to instantiate the variables of an action schema. The user then uses the plan library to construct a discourse plan to achieve the discourse goal, executes the first surface speech act of this discourse plan, and then waits for the system’s response. Having made these assumptions, the plan inference process can then proceed as follows. The system uses the plan library and its knowledge of the user’s beliefs to infer the user’s discourse plan and hence the user’s discourse goal. By knowing how discourse goals relate to domain plans under construction, the system can then attempt to infer the user’s domain plan, and hence the user’s domain goal. The formalism used for defining the plan library is based on that used by Litman and Allen (1987). Action schemata are defined by a header, a set of constraints, a set of preconditions, a list of effects, and a hierarchical decomposition. An example domain plan operator for the action of eating at a restaurant is shown below (actions are shown in capital letters to distinguish them from predicates and functions, and schema variables are shown with initial capital letters). Header: EAT-OUT (Agent ,Rest , Food ,Time) Constr: Zle.serve(Rest,Food,e) ge.open(Rest,e) A on(e,Time) Precond: 3e.have(Agent,Price,e) A on(e,Time) Effects: -Je.hungry(Agent,e) A on(e,Time) Decomp: MOVE (Agent ,Place ,Time) PURCHASE (Agent ,Rest ,Food ,Time) EAT(Agent,Food,Time) Where: Price: 3e.cost(Food,Price,e) Place: -Je.in(Rest,Place,e) 966 NATURALLANGUAGE Plan recognition is performed by identifying the surface speech act of the user’s input by examining the logical form and sentence type, and then using decomposition chaining followed by plan instantiation with respect to the mutual beliefs of the user and the system. These are defined, along with the system’s knowledge of the domain and of the user’s beliefs, using a simple epistemic theorem prover based on the design given by Allen (1987: 435ff). For our example query, the inferred discourse plan is an askif action, as shown below. The constant ‘prop’ is used here to represent the logical form of the input query, i.e. Ye.open(pizza-hut,e) A on(e,today). Header: ASKIF( user,pragma,prop) Constr: knowif ( pragma , prop) Effects: knowif (user, prop) Decomp: REQUEST(user,pragma, INFORMIF(pragma,user,prop)) INFORMIF(pragma,user,prop) The user’s discourse goal is thus identified as knowif( user,prop). This implies that it should be untied against the constraints of the plan schemata for the domain plan to be inferred. The eat-out action is thus identified, decomposition chaining is attempted, and the plan is instantiated using the information that it is shared knowledge that the Pizza Hut serves pizza. The important parts of inferred domain plan are shown below. Header: EAT-OUT(user,pizza-hut,pizza,today) Constr: ge.serve(pizza-hut,pizza,e) Ye.open(pizza-hut,e) A on(e,today) Precond . . . Effects: -Je.hungry(user,e) A on(e,today) Decomp: . . . Where: . . . Thus, the user’s domain goal is identified as the effect of this plan, i.e. not to be hungry today. All the plans and goals inferred collected together with the logical message Tom which they were inferred to form the full meaning of the user’s input query. 4. Strategic Generation The strategic generation component of the system performs four tasks. Firstly, it expands out the inferred discourse plan with respect to its knowledge of the domain; this dictates the surface speech act of the first part of the response. Secondly, it attempts to provide additional useful information based on the user’s domain plan (if one has been inferred) and the functional features of the user’s input. Thirdly, having decided on the content of its response, it computes the values of the functional features of the output so that the resulting utterance is natural and appropriate. Lastly, it computes the skeletal logical form of the output from the full logical form; this involves applying pronominal- isation and verb phrase ellipsis when these are appropriate. The module used for computing extended responses based only on the functional features of the question is described by Levine (1989) and in more detail by Levine and Fedder (1989). In essence, the linguistic focus is regarded as the element of the logical form that the user is most unsure about and so this can be used as a guide to the construction of an appropriate follow-up query. The problem with this work is that it is not always possible for the user to phrase the query in such a way that the most uncertain element will be identified as the linguistic focus and the most certain element identified as the theme; English syntax only allows a certain amount of flexibility in the thematic forms it provides. Hence, it is necessary to use the plan-based approach in preference to the thematic approach, and only to use the latter when the former fails. The plan-based approach to strategic generation attempts to assist in the achievement of the user’s domain goal. PRAGMA attempts to do this by a process of plan verification and repair in the context of the user’s query. The algorithm employed can be described briefly as follows. The inferred discourse plan dictates the first part of the system’s response. If the first part of the response implies that the domain plan is valid where in fact it is not valid, the system must inform the user that the plan will not work. An example of this type of response is shown below. Q: Where is Pizzaland? A: It’s in Regent Street, but it isn’t open today. If the first part of the response implies that the plan does not work, then the second part of the response should try to suggest an alternative plan. If no alternative plan is possible, then the second part of the response should address this instead. The suggestion of the alternative plan is constrained by the user’s domain goal and discourse goal. The domain goal may not be altered. If the discourse goal is of the form knowif( user,p) and p is false, then the user is probably interested in some related true proposition, p’. This related true proposition may be found by considering (a) which variants of p lead to reasonable plans, (b) how high up in a plan the terms in p are instantiated, and (c) the thematic organisation of the user’s input. The system can then inform the user ‘lp, but p’.’ In this situation, ‘but’ should be inserted between disablement-enablement pairs if the theme of the LEVINE 967 response is different to the theme of the query. For enablement-disablement pairs, ‘but’ should always be inserted. For the example under consideration, PRAGMA first finds that the Pizza Hut is closed today and so the first part of the response is ‘No,’ which disables the plan the user is considering. It then tries to enable a different but related plan. It finds that ‘today’ cannot be varied, since this is present in the user’sVdomain goal; however ‘pizza-hut’ can be varied and so this is replaced by a variable in the plan. The system then tries to verify this plan against its domain knowledge and this succeeds, with the variable being bound to ‘pizza-express’ in the process. The logical message of the output is then constructed, as shown below. Logical form = No, but 3 e . open (pizza-express, e) A on (e , today) Sentence type = declarative Tense = present Theme = pizza-express Linguistic focus = pizza-express Emphasis = false Finally, the full logical form is reduced to the skeletal logical form. For the example, this means that verb phrase ellipsis is applied by constructing a logical form containing a predicate which realises as the appropriate verb phrase anaphor. 5. Tactical Generation The tactical generation component of PRAGMA consists of two modules. The first uses the functional features of the output logical message to compute the sentence style, essentially reversing the process carried out during interpretation. The second module is the sentence generator (originally designed and imple- mented by Lee Fedder), which operates by forming trees top-down, breadth-first. This process is guided by the syntactic features attached to the sentence level node, but some semantic information from the goal logical form is also used to cut down the search space. One of the biggest difficulties in using a bidirec- tional grammar in a dialogue system is the problem of logical form equivalence. This occurs when the tactical generator is presented with a logical form which is logically equivalent to but syntactically distinct from one for which the grammar defines a set of surface forms. For example, this may occur because logical connectives are associative and commutative. The problem also arises with stative sentences like ‘Trinity is a college’ if the stative verb is translated as the predicate ‘equal’ to maintain compositionality in the semantics of the grammar. However, the problem of logical form equivalence can be solved relatively easily for the sentence generator used in PRAGMA, since it only attempts to equate the goal logical form with the constructed logical form when tree formation is complete. Hence, what is required is an algorithm which converts these &t-order logical forms into a standard format so that unification can then be applied. The algorithm used in PRAGMA to do this can be described as follows. First the logical form is skolemised and converted into Kowalski normal form; this process is described by Bundy (1983). Equalities are then massaged out of the resulting expression by replacing one side of an equality by the other when this is appropriate. A strict ordering is imposed on which side of the equality is eliminated to preserve information content: constants replace variables and skolems, variables replace skolems, skolem constants replace skolem functions, and skolem functions of arity n replace skolem functions of arity greater than n. Tautologies are then removed from the ifs and thens of all the clauses, and clauses with empty thens are removed. The ifs and thens of all the clauses are then sorted by alphabetical ordering, and the clauses are then sorted by similar means. The resulting expression is now in the standard form required, since all variants of the original logical form will convert to this standard form. For the example under consideration, the final natural language response produced by PRAGMA is ‘No, but Pizza Express is.’ This is only one example of the variety of useful extended responses that PRAGMA is capable of producing, but it is hoped that this example demonstrates the basic workings of the system. 6. Conclusions and Further Research The research reported here uses ideas from previously reported dialogue systems, such as those reported by Allen (1983), Kaplan (1983), and Wahlster et al. (1983), and integrates these ideas into a single system. However, it also represents a significant advance over these systems because of the high degree of bidirection- ality employed. The idea of a fully bidirectional system is yet to be rcalised, since the theory on which PRAGMA is built restricts it to being a supplier of cooperative responses. The next important step is to have two identically built systems conversing in natural language in order to achieve some task. A simple version of this would be to have one system emulate the user’s behaviour as described in Section 3. The plan recognition algorithm used in PRAGMA will only work well in domains where the plan library can be assumed to be shared knowledge. For the 968 NATURALLANGUAGE domain used in PRAGMA this is a reasonable assumption, but this will not always be the case, as demonstrated by Pollack (1986). An interesting piece of further research would involve the construction of a system which allowed Pollack’s work to run alongside the work reported here. Acknowledgements I would like to thank my supervisor, Steve Pulman, for his expert advice and for suggesting the original idea from which this research developed. I would also like to thank Lee Fedder for allowing me to use his generator, and for many useful discussions. This research was funded by a studentship from the Science and Engineering Research Council. References Allen, J. F. (1983) ‘Recognizing Intentions from Natural Language Utterances,’ in Brady, M. and Berwick, R. C. teds.) Computational Models of Discourse, MIT Press, 107-166. Allen, J. F. (1987) Natural Language Understanding, Benjamin/Cummings. Appelt, D. E. (1987) ‘Bidirectional Grammars and the Design of Natural Language Generation Systems,’ Position Papers for TINLAP-3, Association for Computational Linguistics, 206-212. Briscoe, T., Grover, C., Boguraev, B. and Carroll, J. (1987) ‘A Formalism and Environment for the Development of a Large Grammar of English,’ IJCAI-87,703-708. Bundy, A. (1983) The Computer Modelling of Math- ematical Reasoning, Academic Press. Calder, J., Reape, M. and Zeevat, H. (1989) ‘An Algorithm for Generation in Unification Categorial Grammar,’ Proceedings of the Fourth Conference of the European Chapter of the ACL, 233-240. Carroll, J., Boguraev, B., Grover, C. and Briscoe, T. (1988) A Development Environment for Large Natural Language Grammars, University of Cam- bridge, Computer Laboratory, Technical Report No. 127. Dowty, D. R., Wall, R. and Peters, S. (1981) An Introduction to Montague Semantics, D. Reidel. Gazdar, G., Klein, E., Pullum, G. K. and Sag, I. A. (1985) Generalized Phrase Structure Grammar, Basil Blackwell. Kaplan, S. J. (1983) ‘Cooperative Responses from a Portable Natural Language Database Query System,’ in Brady, M. and Berwick, R. C. (eds.) Computa- tional Models of Discourse, MIT Press, 167-208. Levine, J. M. (1989) ‘Taking Generation Seriously in a Natural Language Question Answering System,’ Ex- tended Abstracts Presented at the Second European Natural Language Generation Workshop, Department of Artificial Intelligence, University of Edinburgh, 45-51. Levine, J. M. and Fedder, L. (1989) The Theory and Implementation of a Bidirectional Question Answer- ing System, University of Cambridge, Computer Laboratory, Technical Report No. 182. Litman, D. J. and Allen, J. F. (1987) ‘A Plan Recog- nition Model for Subdialogues in Conversations,’ Cognitive Science I I, 163 -200. Montague, R. (1974) ‘The Proper Treatment of Quantification in Ordinary English,’ in Thomason, R. H. ted.) Formal Philosophy: Selected Papers of Richard Montague, Yale University Press, 247-270. Pollack, M. E. (1986) ‘A Model of Plan Inference that Distinguishes Between the Beliefs of Actors and Observers,’ Proceedings of the 24th Annual Meeting of the ACL, 207-214. Quirk, R., Greenbaum, S., Leech, G. and Svartvik, J. (1985) A Comprehensive Grammar of the English Language, Longman. Rosenschein, S. J. and S hieber, S. M. (1982) ‘Translat- ing English into Logical Form,’ Proceedings of the 20th Annual Meeting of the ACL, 1-8. Shieber, S. M. (1988) ‘A Uniform Architecture for Parsing and Generation,’ Proceedings of the 12th International Cor$erence on Computational Linguis- tics, 614-619. Wahlster, W., Marburger, H., Jameson, A. and Busemann, S. (1983) ‘Over-Answering Yes-No Questions: Extended Responses in a NL Interface to a Vision System,’ IJCAI-83, 643-646. LEVINE 969
|
1990
|
173
|
930
|
LOGICALTASKMODELLING FOR MAN-MACHINEDIALOGUE M.D. SADEK Centre National d’Etudes des Telecommunications Route de Tn5gastel - B.P.40 F 22301 Lannion Cedex - FRANCR Abstract To design a task-independent dialogue system, we present a task-oriented dialogue analysis in terms of finding the referents of definite descriptions and we show how this analysis leads to a goal-oriented inferential representation of the task. This representation provides a logical generic model of the task, which is compatible with a belief system. Then, we show how this task model, jointly used with the domain-specific user model for which we propose a formalization, enables a dialogue system to plan request negotiation dialogues. 1. Introduction The problem we deal with in tbis paper comes within a more general research concerning the logical plan-oriented approach to Man-machine oral communication. This research aims at designing a task-independant dialogue system. Briefly sketched, the adopted approach is based on a logical representation of mental attitudes and on a recast of speech acts theory (Searle 1969) into action theory (in a similar way as in (Cohen & Perrault 1979)). In this view, one main component of a communicating agent is a belief system’ involving several types of information such as a task model aud a user model, all formalized in the same logical language. Roughly speaking, a task-independant dialogue system is a portable dialogue system. When modelling such a system, information about the potential task must appear only as a formal parameter for which it is not necessary to know some specific instance. To reach this purpose, we have to find a formal expression for the information characterizing the task, that is, a logical abstract data structure. 1 Although other mental attitudes than belief are also dealt with, the use of the term “belief” in “belief system” is justified in that in our approach, we take an auteepistemic point of view. Hence, the agents we model are introspective; they believe all their mental attitudes and adopt all the mental attitudes they believe about themselves. In this paper, we present a task-oriented dialogue analysis in terms of finding the referents of definite descriptions and we show how it leads to a goal-oriented inferential representation of the task. This representation gives a logical generic model of the task, which is compatible with a belief system. Then, we show how this task model, jointly used with the domain-specific user model for which we propose a formalization, enables a dialogue system to plan request negotiation dialogues. For our concern here, we restrict our interest to data base inquiry dialogues. 2. Logical preliminaries To refer to objects in the discourse domain, one uses referring expressions such as proper names or definite descriptions (the green box on the table, the departure time ofthe flight toLannion, tbe wordI just uttered,...). Adefinite description is an expression one can formulate according to the syntactic pattern “the so (and so)“. It is intended to refer to* one and only one object, precisely that one which is “so (and so)“. In English (as in French), a definite description is a noun phrase starting with a definite article. To handle definite descriptions within a logical formalism, the first order logic language is augmented by the operator t (Russel 1905), which is a term-producing operator: if V(X) is a well formed formula with x as free variable then W&V) is a term. This term describes a definite description and can be read “the unique object which satisfies the property w”, or in a compact form “the y”. Intuitively, a formula of the form $(tx\y(x)) is false @here is no object in the discourse domain satisfying the description \v or if there is more than one object. Thus, if equality is provided in the logical language, one has the equivalence 2 Strictly speaking, we should say “an agent uses some description to refer to...” instead of “some description refers to...“. Though, in this paper, we continue using the latter expression or expressions equivalent to it. 970 NATURAL LANGUAGE From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Given this equivalence, the truth conditions of a formula of the form @(LO@)) can be easily stated. Let (M,v) be a first order (tarskian) interpretation where M is a first order assignment and v a variable valuation. Then, (M, v) I= $(txw(x)) if and only if (1) the projection of 1 w Iy on the component x is a singleton {d) c D (where D is the interpretation domain) and (2) d belongs to the projection of I$ lM on the component LO&X), where I= is the truth relation and 1 Q, lM and 1 w lM the respective extensions of the formulae + and y according to the assignment M. 3. On the mental attitudes formalization We base an agent mental model on three primitive mental attitudes: (autoepistemic) belief, uncertainty3 and choice (or goal, as called in (Cohen & Levesque 1986)), and we formalize it in a first order modal language. The concept of beEief is formalized by the modal operator K the logical (external) model of which is a KD45 possible-world semantical Kripke structure (Halpem & Moses 1985) with the fixed domain principle (Garson 1984). (A formula as K(i,p) can be read “p is a consequence of i’s beliefs”.) Moreover, it is assumed that there is in the language a set of constants which are rigiddesignators (calledinthis paper standard names), that is, constants which have the same extensions in all possible worlds. It is also assumed that this set of constants cover the interpretation domain. Equality is interpreted as contingent identity. D Now, let’s examine the way knowing something (or someone) is represented. A formula of the form K(i, @) is not relevant whenever one has to represent an assertion like “i knows j’s address” because the expression ‘j’s address” doesn’t denote a proposition. It is a referring expression potentially denoting some object in the discourse domain. A plausible formalization of the assertion “i knows j’s address” can be SxK(i,address(j) =x)). However, there is an information which is conveyed by the previous assertion and which is not expressed in the above formula: the uniqueness of j’s address. The above formula doesn’t reject the possibility that i knows more than one address for j. The fact that an agent i knows a definite description &5(x) is formalized by 3yK(i,wrG(x) = y), which we note below Kref (i, 8(x)). Now, looking at the concept of choice (or goal), it is formalized by the modal operator C which is interpreted, as the belief operator, in a possible-world semantical Kripke structure. The properties imposed to the semantical model, 3 We don’t make use here of the concept of uncertainty; so, it will not be iIltIQdUC&. (For a logical formalization of this concept, see (Sadek 1990).) make valid the schemas K(i,+) * C(i,# and CO3W, 4)) -MU, 41, where M is any well formed modality (the agent of which is i).’ The concept of intention, formalized by the modal operator l, is defined in a similar6 framework to that proposed in (Cohen & Levesque 1986), that is, from the primitive concepts of choice and belief. This definition implies that intention generates a planning process. For our concern here, we make use of a particular form of the concept of intention which we call need or potential intention. It is formalized by the modal operator W defined as follows: W(i,$) gC(i, 7 K(i,$) 3 I(i,K(i,+)) The formula W(i,p) can be read “i needs p to how. Intuitively, an agent i needsp to hold if and only if, seeing that p is not a consequence of her beliefs, she adopts the intention that it will be the case. Here, all that is useful to know about the concept of need is that both schemas W(i,@) A K(i,$)andW(i,$) A K(i, 1 +)aresatisfiable,that the following schemas are valid: Iti, $13 W, 4) Wi,$) -KWW,4)) (1) W(i,4Ay)~W(i,4)AW(i,y) (2) and that the following inference rule is sound: Wi,$) A W, 14) I(L 4) (3) 4. Dialogue and definite descriptions To design a task-independant dialogue system, we have to answer the following question: how to characterize the abstraction level at which the topic one is communicating about becomes merely a parameter which is not pertinent in the logical reasoning model ? In other words, how to build up a structural model for the task, which is compatible with the belief system ? The idea underlying the answer to this question is that in an informative task-oriented dialogue, the generic problem which agents pose to each other is to identify the refkrents of definite descriptions.7 The task-oriented (bi-agent) dialogue “game” can be sketched as follows: an agent i, through a request directed to an agent j, provides 4 This property is proposed in (Cohen & Levesque 1986). 5 For a detailed analysis of the concept of choice, see (Sadek 1990). 6 but fundamentally recast in order (among other things) to take into account the agents intospective and cooperative abilities (see (Sadek 1990)). 7 In (Clark & Marshall 1981), (Cohen & F+rault 1981) and (Nadathur & Joshi 1983), logical conditions (based on mutual beliefs) for the use and understanding of referring expressions are proposed. In (Appelt 1985). the problem of planning referring expressions is dealt with. SADEK 971 (in the primitive case’) a definite description, thereby (among other things) expecting j to identify the referent denoted by the description and, generally, to “return” a standard name (or an identifying description) of that referent. If the agentjevaluates the description not to be an identifying one, the negotiation “rule” consists in trying to get from i fuller information in order to construct, starting from the first description, an identifying one. To clarify this idea, let’s take an example of a task-oriented dialogue: (a) i: I’d like to know the telephone number of Mr DuPont at Lannion city (b) j: It’s the 96.00.00.00 (c) i: And those of Tent and Tassne companies (d) j: At Lannion city ? (e) i: Yes (f) j: Do you know the directory name ? (g) i: For Tent or for Tassne ? (h) j: . . . By (a), i (indirectly) request j to identify the referent denoted by the definite description “the telephone number of Mr DuPont at Lannion city” (and to “return” a standard name of this referent). This description can be formalized as follows:g u(Tel(x) A Belongs(x,ly(Person(y) A y = DuPont A Resides(y,tz(City(z) AZ =L.annion)))))) A slightly different formalization may be: wr(Tel(x) A Belongs(x,ly(Person(y) A y = DuPont A Resides(y,z)),tz(City(z) A z = Lannion))) The optimal formalization depends on the internal organization of the data base and, therefore, firom a computational point of view, on the control strategy of term evaluation. Though, one can note that probably the formula tx(Tel(x) A Belongs(x,ty(Person(y) A y = DuPont), tz (City(z) A z = Lunnion ))) doesn’t make an optimal formalization of the description “the telephone number of Mr DuPont at Lannion city” since it ignores the existing relation between “Mr DuPont” and “La&on city”. Let’s return to the dialogue above. The agent jevaluates the description uttered in (a) to be an identifying one and, thus, provides by (b) a constant which standardly names the referent of the description. By (c), the agent i makes a new request concerning the identification of the referents of two descriptions: “the telephone number of Tent company” and “the telephone number of Tassne company”. But, this time, j evaluates the descriptions not to be identifying ones and then starts a negotiation dialogue attempting to construct indentifying descriptions; This is illustrated by the exchanges starting at (d). Note that by (g), it’s i who evaluates the definite description “the directory name” not to be an identifying one. 5. From defmite description to goal-oriented inference rule The main point here is that in a task-oriented dialogue, the framework according to which a task-oriented dialogue system considers some description relating with the application attributes, to be or not an identifying one, is the basis of the task model. This framework is built up according to the two following criteria: (i) The way the dialogue system (designer) believes that the user conceives the application organization schema, and (ii) The integrity constraints which appear in a (fine-grained) conceptual schema describing the application. Let’s see through a generic example how the integrity constraints can be viewed as descriptions which are, then, formalized in a goal-oriented inferential form aud can, thus, be naturally included in the belief system. The resulting inference rules gives a logical model of the task. For simplicity, we don’t make account of the criterion (i) and we suppose that the integrity constraints reflect only functional dependencies between the attributes of the data base corresponding to the application. Let a, b, c and r be the data base attributes’o and a, b + r and c + r functional dependencies. These dependencies give rise to definite descriptions which can be formalized as follows: W-(x) *R l(mya(y),~b(z)~); ~X(~(X)*R~(X,~Y(C(Y))) where RI and R2 are some real or virtual relations respectively between a,b and r, and between c and r.” For example, the first expression can be read “the r given the a and the b”. From a functional point of view, the expressions above are jointly interpreted as follow: to identify an r 10 From a logical point of view, the attributes can be represented as unary predicates (namely classes). 11 RI and R2 would, for instance, correspond to the relations ‘Belongs” or “Resides” of the example above. 972 NATURALLANGUAGE differently from standardly naming it, a description must identify either an a and a b, or a c. l2 In terms of goal-oriented inference in a reasoning model, this proposition means that the potential intention of the server-agent (which is considered below to be a dialogue system) to know the referent of the description “the 8’ can be converted either in her potential intention to know the referents of the descriptions “the a” and “the b”, or in her potential intention to know the referent of the description “the c”. This is formalized by the following inference rule: WOQ-ef(s,a(.O ~Kref(s,b(y)))v W,~ref(s,&)N where s denotes the server-agent and X, y, z and u are individual variables. Expressed in this way, the model we propose, describes the task as a set of potential intention reduction rules the formalization of which comes within the knowledge representation schema required by the logical reasoning (and planning) model. When a particular application is chosen, these rules ate extracted from its corresponding conceptual schema taking into account the criteria (i) and (ii) we mentioned above. 6. Task modelling Russel’s theory of definite description (Russel 1905) imposes (the existence and) the uniqueness of the referent.13 In the case of data base inquiry dialogues, this constraint is too strong and, therefore, adopting it as such will lead, at least, to a nonfiiendly behaviour. Indeed, one cannot reasonably expect from the user to utter only descriptions whichidentify one and only one referent at one and the same time, otherwise one would be committed to draw the conclusion that what was uttered asserts some erroneous proposition. Thus, a user who requests to know “the telephone number of Mr Dupont” when it happens that Mr DuPont has two telephone numbers, must be able to obtain the information he is looking for, and should not be, in anyway, penalized for having uttered a non-identifying definite description according to Russel’s theory. 12 Note the recursive aspect of this assertion, the termination clause being the standard naming. Somehow, this calls to mind a problem dealt with in (Levesque 1984) where Levesque suggests a solution to avoid that a system loops indefinitely in collecting co-referential terms when answering a whquestion. 13 Consequently, it doesn’t take into account contextual information. A description like “the box on the table” (which can be formalized by w(Box(x) A On(x,tyTdde(y))) ) is considered to be a non-identifying one whenever there is more than one table, even if there is only one table on which there is a box. To overcome this problem, we have to broaden the concept of definite description in the framework of data base inquiry dialogues, by relaxing the referent uniqueness constraint and, therefore, by allowing a description to identify more than one referent. However, a maximal threshold must be imposed to the number of referents which can be identified by a given definite description. A description is considered to be a non-identifying one only beyond this degeneration threshold. In doing so, the interpretation of the definite description concept has just to be recast in terms of the size of the (non-empty) set of objects, the elements of which are referred to by the description, instead of a unique individual.‘4 First, takiug into account the criterion (i), adegeneration threshold is fixed for the attributes about which the dialogue system can be asked. Then, for each such an attribute and on the basis of the conceptual schema of the application, the sets of attributes, which satisfy the corresponding threshold, are selected. An attribute together with a corresponding set of this form, represents an identifying description. For example, a, b and r being attributes of the application, if the number of r which are identified given some a and some b is inferior to the fixed threshold, the description “the r corresponding to the a and the b” is considered to be an identifying one. The couple ({a,b},r) is then added to a set which we call the set of dependencies of the task model. Formally, if we let A be the set of all the attributes of the application and Z(A) the powerset ofA, there is a certain subset T of X(A) x A which describes the set of dependencies of the task model.‘* In terms of the data base, an element (E,e) is in T only if every concrete instance inst(E) of E, determines at most h instances of e, where h is the maximal threshold above which the description “the e corresponding to irut( is considered to be a non-identifying one. Now, considering the reasoning model, for every e about which the dialogue system can be asked, the set {(E,,e), . .., (E,,, e)) is stated as an inference rule of the form 14 This is not to be confused with the interpretation of multiple definite descriptions as in the expression “the telephone numbers of Mr Dupont”. In this case, the description is really intended to denote a set of objects, while in our case the description is intended to denote a unique object while, in fact, it may not. In other words, in the fust case, the referent is intended to be a set of objects while in the second case, it is the set of the (potential) referents which is dealt with. In practice, in the case of data base inquiry dialogues, the method we propose here can be adapted to deal with multiple definite descriptions and even with indefinite descriptions. 15 Note that it is also this subset which is affected when updating the task model. SADEK 973 WWWfhW)) W(s,Kref(s, E,)) v . . . v W(s, Kref(s, E,,)) Where Kref(s , Ei) is short for Kref (s, e/(x;)) A . . . A Kref (s , e/‘Q)(xP(i))) I , Ei being [e!, . . . , ePtiv. Precisely, these inference rules are the part of the reasoning model which corresponds to the task model. They enable the dialogue system to set up dialogues which aim to negotiate information to be acquired to satisfy the user’s request. Henceforth, a description is considered to be or not an identifying description according to the task model. Note that in a task-oriented dialogue, some description can be an identifying one according to the task model without being an identifying one according to the data base. This is precisely the case when the set of referents is empty. In a cooperative dialogue, this case should give rise to corrective and suggestive answers (Guyomard & Siroux 1989). 7. Domain-specific user model To show how the task model is used to plan request negotiation dialogues, we need to introduce auother part of the belief system, which concerns the domain-specific user model. In a conversational situation, an agent has a priori ’ assumptions about the beliefs and the behaviour of the other agents. These assumptions include the mutual beliefs about the speech acts and their usage conditions, or about the principles of cooperation. Another kind of assumptions made by an agent pertains to the pragmatics of the dialogue domain. We call them specific-domain presuppositions. Most of them characterize a default knowledge about the interlocutor. For instance, in some particular application, the server-agent has to consider that “generally, when a user requests to be informed about a flight arrival time, she/he knows the flight departure airport”. This kind of belief has to be formalized in the same way as the other components of the belief system. To preserve the homogeneity of the reasoning model, we propose to handle the specific-domain presuppositions from an autoepistemic perspective.16 Hence, considering the previous example, we have: K(s,Cont I\- K(s, 7 Kref(u&(x))) *Kref(u&(x))) 16 We have noted that presuppositions are generally default beliefs about the user and we formalize them as autoepistemic beliefs. Indeed, default reasoning and autoepistemic reasoning don’t have the same motivation (Moore 1985). However, as shown in (Konolige 1988), the corresponding logics are formally equivalent. This resultjustifies our proposition, notably when the homogeneity of the reasoning model of a computer system has to be preserved. where s denotes the dialogue system, u the user, Cont the context of being requested about the flight arrival time and da the attribute corresponding to the flight departure airport. ode1 to plan re negotiation dialogue We briefly sketch the way the dialogue system uses the task model jointly with the domain-specific user model to plan dialogue in order to complete a user’s request, that is, to construct an identifying description according to the task model. Let’s consider a very simplified form of the plan-oriented model of the illocutionary act (Cohen & Perrault 1979, Searle & Vanderveken 1985) Informerefli,j,reflx)), denoting the event of an agent i who informs an agent j of an identifying name of the referent ref. The applicability precondition of this act is Kref(i,reflx)) and its intended (or, somehow, its perlocutionary) effect is Kref(j,reflx)). Suppose that the task-component of the belief system involves the rule W(s,Kref(s,r(x))) W(s9Kref(s,a(yN A Kref(s,b(z))) (4) and that among the domain-specific presuppositions, we have K@, ~(~,~~qf(~, r(x))) ~1 W, -( KrefOO,))) * Kref(uNy))) (5) Suppose also that we have the cooperation rule KWW,49 A- w(s, l+)) ws949 (6) and the (simplified) belief transmissibility rule K(s,Ktw#O A- KG, -40) K(s ? 40 (7) Suppose now that the current model of the world (resulting from a request of the form “What is the r for which lxa (x) = h”) involves K(s,W(u,Kref(u,r(x)N ~lKref(u,r(x))) (8) KWWa(x,)N (9) In the following, we don’t mention all the inference steps, especially those related to the KD45 belief inference system. From (6), (1) and (8), in the one hand, and (7) and (9), in the other hand, we respectively have W(s,Kref(u,r(x))) (10) K(sdHx,)) (11) Now, s has a need to satisfy, namely (10). From (10),(3) and (8), I(s,Krefls,r(x))) is inferred and gives rise to a planning process. Suppose that the control strategy uses a backward chaining. So, the instance Informerefls,u,r(x)) is selected since its effect achieves Kref(u,r(x)). Its precondition Kr&s,r(x)) has now to be satisfied. This time, the instance InformerefTu,s,r(x)) is selected, then rejected: 974 NATURAL LANGUAGE its precondition is not satisfied (because of (6)) and is already a goal currently tracked. Here, the taskmodel comes into play. (2), (4) and (10) allow to infer Ws9~ref(s,&N~ (12) WWWfWWN (13) (12) doesn’t give rise to an intention since K (s, a (x0)) holds. But (13) allows to infer I(s,.Krefls,b(y))). The instance Infonwereflu,s,b(y)) is then selected. Its precondition is satisfied because of (5). This completes the planning process. The resulting plan is the sequence of illocutionary act instances dnformeref(u,s,b(y)),Informer~(s,u,r(x))>. Note that the first instance of the sequence is planned to be performed by the user. So, the server-agent has to make the user wanting its performance. This is brought about in a second planning step where the “want-precondition” (not mentioned here, for simplicity) of the selected act, has to be achieved. The planning step we described in this section is viewed as a task-oriented problem solving step. 9. Conclusion The task model&g method we propose here is completely transparent to the dialogue system model and independent of a specific application. The result is a set of goal-oriented inference rules. As defined, these rules give a logical generic model of the task. They are syntactically and semantically compatible with the other belief system components and, thus, constitutes a common-place part of the logical reasoning model. Used jointly with the domain-specific presuppositions, which are formalized in an autoepistemic statement form, the proposed task model enables the dialogue system to plan request negotiation dialogues in a natural way. Furthermore, grounded on the set of dependencies, it allows the dialogue system to efficiently inquire the data base, avoiding frequent accesses which leads in most cases to degenerate answers. References Appelt, D.E. 1985. Planning english referring expressions. Artificial intelligence 25(l): 1-33. Clark, H.H., and Marshall, C. 1981. Definite reference and Mutual Knowledge. In Joshi, A.K., Webber, B.L., and Sag, LA. eds. 1981. Elements of discourse understanding. Cambridge University Press, pp. 10-63. Cohen, P.R., and Levesque, H.J. 1986. Persistence, intention and commitment. In Georgeff, M.P., and Lansky, A.M. eds. 1986. Proceedings of the Timberline Workshop on Reasoning about Actions and Plans. Morgan Kaufmann Publishing Co, Los Altos, California, pp. 297-338. Cohen, P.R., and Perrault, C.R. 1979. Elements of plan-based theory of speech acts. Cognitive Science 3(3): 177-212,1979. Cohen, P.R., and Permult, C.R. 1981. It’s for your own good: a note on inaccurate reference. Joshi, AK., Webber,B.L., and Sag,I.A. eds. 1981. Elements of discourse understanding. Cambridge University Press, pp. 217-230. Garson, G.W. 1984. Quantification in modal logic. In Gabbay, D., and Guentner, F. eds. 1984. Handbook of philosophical logic. Volume II: Extensions of classical Logic. D. Reidel Publishing Company, pp 249-307. Guyomard, M., and Siroux, J. 1989. Suggestive and corrective answers: a single mechanism. In Taylor, M.M, Neel, F., and Bouwhuis, D.G. eds. 1989. The structure of multimodal dialogue. Elseiver Science Publishers B.V., North-Holland, pp. 361-374. Halpern, J.Y., and Moses, Y. 1985. A guide to the modal logics of knowledge and belief: a preliminary draft. In Proceedings of the ninth International Joint Conference on Artificial Intelligence. Los Angeles, CA, pp. 480-490. Konolige, K. 1988. On the relation between default and autoepistemic logic. Artificial Intelligence 35(3):343-382. Levesque, H.J. 1984. Foundations of functional approach to knowledge representation. Artificial Intelligence 23(2):155-212. Moore, R.C. 1985. Semantical consideration on nonmonotonic logic. Artificial Intelligence 25( 1):75-94. Nadathur, G., and Joshi, A.K. 1983. Mutual beliefs in conversational systems: their role in referring expressions. In Proceedings ofthe eighth International Joint Conference on Artificial Intelligence. Karlshe, Germany, pp. 603-605. Russel, B. 1905. On denoting. In D. Davidson and 6. Harman eds. 1975. The logic of grammar. Dickenson Publishing Company, pp. 184- 193. (For more detail, see the whole chapter entitled “Names and descriptions”). Sadek, M.D. 1990. Une approche logique orientee-plan de la communication orate Homme-machine. Ph.D. diss., Universite de Rennes I. Forthcoming. Searle, J.R. 1969. Speech acts. Cambridge University Press. Searle, J.R., and Vanderveken, D. 1985. Foundations of illocutionary logic. Cambridge University Press. SADEK 975
|
1990
|
174
|
931
|
The Belief Calculus and Uncertain Reasoning Yen-Teh Hsia* IRIDIA, Universitk Libre de Bruxelles 50 av. F. Roosevelt, CP 19416 1050, Brussels, Belgium rO1509@bbrbfuOl.bitnet Abstract We formulate the Dempster-Shafer formalism of belief functions [Shafer 761 in the spirit of logical inference systems. Our formulation (called the belief calculus) explicitly avoids the use of set-theoretic notations. As such, it serves as an alternative for the use of the Dempster-Shafer formalism for uncertain reasoning. I. Pntroduction Traditionally, the “syntax” of the Dempster-Shafer (D- S) formalism [Shafer 761 has been set-theoretic in nature (e.g., [Gordon and Shortliffe 84; Kong 86; Shafer et al. 87; Yen 891). In some cases, propositions may be used for belief specifications (e.g., [Smets 88; Zarley et al. 881). However, to date, there is no purely logic-oriented formulation of this formalism. Set-theoretic notations are appropriate when we are concerned with general theory rather than applications. But on the other hand, we might also find it difficult to use set-theoretic notations in some application domains. To overcome this notational disadvantage of the D-S formalism, we give an alternative formulation of belief functions in this paper. Our formulation (called the belief calculus) is developed along the lines of natural deduction systems, and it explicitly avoids the use of set-theoretic notations. This differs from the previous research wuspini 87; Fagin and Halpern 891 in which the main concern was the “structure” or semantics of the D-S formalism and not its syntax. To show how the belief calculus may be used for uncertain reasoning, we give three examples. These examples model different real world situations, and they address issues such as independent random variables, belief dependency structures, and “distinct” sources of evidence. The remainder of this paper is organized as follows. In Section 2, we describe the belief calculus. In Section 3, we show how the belief calculus may be used for uncertain reasoning. In Section 4, we discuss some related issues. Finally, Section 5 concludes. * This work was supported in part by the DRUMS project funded by the Commission of the European Communities under the ESPRIT II-Program, Basic Research Project 3085. 120 AUTOMATEDREASONING 2. The Belief Calculus The multivariate formalism. Our formulation of the D-S formalism starts with the multivariate formalism [Kong 861. That is, we assume that different aspects of the world that are of interests to us are already appropriately formulated as questions or variables (e.g., “Is the entity capable of flying?“, “Can the object be used to cross the river?” etc). Each of these variables is associated with a set of mutually exclusive and exhaustive values (called the frame of the variable) representing all possible answers to the question. A booZean variable is one that has an associated frame of (Yes, No}. Propositions. Primitive propositions (i.e., atoms) are of the form “SomeVariable = SomeValue”. From propositions, we build compound propositions using five logical connectives (with the usual semantics): 1 (not), v (or), A (and), + (if . . . then), H (if and only if). As a basic requirement of the multivariate formalism, we assume that, for every variable and its associated frame, there is a corresponding mutual exclusion axiom. For example, if the frame of the variable A is {h, m, I}, then the mutual exclusion axiom associated with A and its frame is ‘((A = h) A +A = m) A -(A = 1)) v (l(A = h) A (A = m) A T(A = 1)) v (T(A = h) A T(A = m) A (A = 1))‘. We use ME to denote the set of all mutual exclusion axioms. For convenience; we also use ‘A’ as an abbreviation for ‘A = Yes’ whenever A is a boolean variable (and ‘-A’ will be logically equivalent to ‘A = No’ under ME). Let Al, AZ, . . . , AN be all variables, and let 01,02, . . . , 0~ be their respective frames. A valuation is an assignment of an element of 0; (1 I i I N) to Ai for every i (i.e., an assignment of a value-vector to the variable-vector <Ai, AZ, . . . , AN>). A proposition P is said to be true under a valuation V if P is true when all variables occurring in P are replaced with their corresponding values in V; otherwise P is said to be false under V. Formally, a valuation is defined as an assignment of values to all variables. But when the situation permits, we also use the word ‘valuation’ to mean a (partial) valuation of all variables occurring in some proposition. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Example 1. “(PLACE = Africa) 4 (TEMP = high)” is a proposition. It is false under the valuation <PLACE, TEMp> = <Africa, medium> and true under the valuation <PLACE, TEMP> = <Europe, medium>. A contingent proposition, then, is a proposition that is true under one valuation but false under another valuation. A va2id proposition (or tautology), denoted as ‘T’, is a proposition that is true under every valuation, while an unsatisj?able proposition, denoted as ‘F’, is a proposition that is false under every valuation (and a satisfiable proposition is true under at least one valuation). Beliefs format: i. A belief is a formula specified in the following Pl N-4) V P2 b2) V . . . V Pn 0%) where V i (1 I i I n), Pi is a satisfiable proposition andO<m;Il, andCmi= 1. (1) As a convention, if ‘T’ appears in formula (l), it is usually specified at the end (i.e., as Pn). “T (1)” is called the vacuous belief. Intuitively, each mi (called the “m-value” of Pi) in formula (1) represents the amount of belief we specifically “allocate” to Pi. That is, formula (1) may be interpreted to mean the following: the world, as we understand it, is such that P1 holds (with the amount of belief ml being allocated to it), or P2 holds (with the amount of belief m2 being allocated to it), . . . . or Pn holds (with the remaining amount of belief mn being allocated to it). This is why we use the symbol ‘V’ to delimit the ‘Pi (mi)’ of a belief. However, this symbol ‘v’ is not to be confused with the usual logical symbol ‘v’ that occurs within a proposition. In the following, we use the term ‘intuitive belief (or ‘intuitive beliefs’) to denote the intuitive belief(s) we have in mind, and we also use the word ‘belief (or ‘beliefs’) to denote a formula (or formulas). Belief sets. We may be able to come up with one single belief (i.e., one formula) which appropriately formalizes our intuitive belief in (almost) every way. However, this is not a very easy task in general, and it may be argued whether the specification of such a joint belief is always necessary. As human problem solvers, we are often capable of identifying various “independent” aspects of a problem. Once such aspects have been identified, we can then specify a (unique) belief for each of these aspects and use some kind of inference mechanism to “combine” the specified (independent) beliefs. This philosophy is embodied in the D-S formalism. Accordingly, the belief calculus works with sets of beliefs (called belief sets)l; when using this calculus for reasoning, we first try to l with singleton sets as special cases. infer a singleton set (containing the combined belief) from the given belief set. A belief set IB is a non-empty set of beliefs. In notation, IB = (bl; b2; . . . ; br), where r 2 1, and V i (1 5 i 5 r), bi is a belief. (We use ‘;’ to delimit the specified beliefs. This specification of beliefs does not mean that the beliefs are implicitly ordered.) We now give the inference rules of the belief calculus2. The first three rules are trivial. (Notation: Throughout this paper, we use ‘I- P’ to mean that “the proposition P is provable in the propositional calculus from the set of mutual exclusion axioms MB”.) 1. Commutation: I... V Pi (mi) V . . . V Pj (mj) V . . . . b2; b3; . . . ; br) (... V Pj (mj) V . . . V Pi (mi) V . . . . b2; b3; . . . ; br) 2. Addition: I- P ++ W, {... V P (mi) V . . . V R (mj) V . . . . b2; (... V P (mi + mj) V . . . V . . . . b2; b3; . . . ; br} 3. Substitution: I- 0, tj R), { . . . V P (m) V . . . ; b2; b3; . . . ; br) { . . . V R (m) V . . . ; b2; b3; . . . ; br} We also need a fourth rule for inferring combined beliefs (0 is defined below). 4. Combination3: (bl; b2; b3; . . . ; br), bl Q b2 = {bc; b3; --- ; h-1 The combination operator 6. Let @ denote the set of all beliefs. The combination operator 8 (read as “Dempster’s combination”) is a partial function that maps from Ffl x ?Jl to $8. Intuitively, 0 (e.g., (A (.8) V (lA) (.2)) 0 (A (S) v B (.3) V T (.2))) may be thought of as a two step process. The first step is to apply the (independence) assumption that allocating pi to Pi in the first belief and allocating rj to Rj in the second belief should mean allocating pi*rj to 2The belief calculus is formulated along the lines of natural deduction systems. However, due to space limitations, we only describe the inference mechanism of this system. 3This is the only inference rule (in the context of the belief calculus) that can be used to reduce the number of beliefs in a belief set. HSIA 121 Pi A Rj in the combined belief (e.g., ((A A A) (.4) V (A A B) (.24) V (A A ‘I’) (.16) V (-A A A) (.l) V (-A A B) (.oQ v (1A A T) CW)). The second step is to apply the (coherence) assumption that the two beliefs that are being combined are meant to be coherent; this is done by taking away all “pairs” containing unsatisfiable propositions (e.g., (TA A A) (.l)) and redistributing their m-values (e.g., .l) to the remaining propositions by proportions (e.g., ((A A A) (.444) V (A A B) (267) V (A A T) (.178) V (-A A B) (.067) V ‘(7A A T) (.O44))). This step is also known as “renormalization”. Formally, 0 is defined as follows. (Notation: Let S be an ordered set of “pairs” (Pi (ml), P;? (mz), . .., Pn (m&J, then by ‘V S’, we mean the formula ‘Pi (ml) V P2 (m2) V . . . V Pn (mn)‘.) (pl (Pl) v p2 (p2) v l -- v PM (PM)) @ @I 61) V R2 (r2) V . . . V RN 0~)) = if 3 (i, j) E (1, . . . . M)x (1, . . . . N} such that Pi A Rj is satisfiable, then Example 3. BEL( ((A + B) (1))) B) = 0. Example 4. V {(Pi A Rj) @i*rj / (1 - z(h,k& sPh*rlc)) I S is the maximum subset of {L -a-, M}x( 1, . . . . N) such that b’ (h,k) E S, I- ((ph A Rk) H F), and (A (.8) v (1A) (.2); A (.5) v B (.3) v T (.2)) I-DS ((A A A) (444) V (A A B) (.267) V (A A T) (.178) V +A A B) (.067) V (-A A T) (.O44)) (i, j) E ((1, . . . . M)x (1, . . . . N))\S I4 I-,, (A (.444) V (A A B) (.267) V A (.178) other’wise undefined. V (--,A A B) (.O67) V -,A (.044)} 0 is an associative operation (i.e., (bl 0 b2) @ b3, if defined, is the same as bl 63 (b2 (33 b3 )). If we use Q to denote ‘Xl3 without renormalization”, then Q is obviously associative; but more importantly, bl @ b2 $ . . . $ br (whatever the order of combinations is), if defined, is the same as bl Bb2& . . . Q br followed by one single renormalization. I-DS (A (622) V (A A B) (267) V +A A B) (.O67) v --,A (044)) Therefore Addition BEL(lB , A) = .622 + .267 = .889, and BEL(IB, TA) = .067 + .O44 = .lll. Also, r beliefs b 1, b2, . . . . br are said to be incompatible whenever bl 0 b2 0 . . . 0 br (whatever the order of combinations is) is undefined. Example 2. (A (1)) 0 ((lA) (1)) is undefined. The calculus. The belief set IB2 is Dempster-Shafer provable from the belief set lB 1, denoted as ‘ll3 1 I-Ds IB2’, if lB2 can be inferred from IB 1 after a finite number of applications of the (four) inference rules. We are now ready to define the overall belief BEL in an arbitrary proposition. Let %g be the set of all belief sets and 3 be the set of all propositions. BEL is a partial Relating to the “usual” formulation. To see the relation between the belief calculus and the usual set- theoretic formulation of belief functions [Shafer 761, consider the following mapping: let Al, AZ, . . . , AN be all the variables, and let 01, 02 , . . . , 0~ be their respective frames. Then each proposition P corresponds to exactly one subset of the joint frame 01 x 02 x . . . x 0~ (i.e., the set of all “total” valuations that make P true). Similarly, for each subset of the joint frame, there is a corresponding set of logically equivalent propositions. Let Sp be the subset of the joint frame that corresponds to the proposition P and let SR be the subset of the joint frame that corresponds to the proposition R, then: I- (P + R) if and only if Sp c SR; Sp u SR corresponds to P v R; Sp n SR corresponds to P A R; and 01 x 02 x . . . x 0~ \ Sp corresponds to -P. This 4We assume these ‘Pi A Rj’ are lexicographically ordered in (i, j). function from %I%5 x @ to [0, 11, defined as follows (let IB be a belief set and R be a proposition.) BEL(B 3 R) = CI-(Pi”R) mi where IB I-D, (Pi (ml) V P2 (m2) V . . . V Pn (mn)) . p i.e., we must first deduce a singleton from IB */ Clearly, BEL(lB , R) will be undefined (for every proposition R) whenever the beliefs contained in lB are incompatible. Note that, even if BEL(IB , R) is defined for some contingent proposition R, it can still be zero. This simply means that we have no idea whether R holds in the world (because we are not aware of anything that logically supports it). But having no (intuitive) belief in R does not necessarily mean that we have any (intuitive) belief in TR (i.e., BEL( lB , -R) > 0), because our degree of belief in a proposition (-R in this case), as defined by BEL, is always dependent on whether we are aware of anything that logically supports it and not on whether we are ignorant of anything supporting its negation (i.e., R). This is one of the characteristics of the D-S formalism. /* i.e., lB */ Combination Substitution 122 AUTOMATEDREASONING provides a straightforward translation between the language of the belief calculus and the language of the usual set-theoretic formulation of belief functions. Example 5. We now use the belief calculus notations to describe the idea of combining the ATMS [de Kleer 86a] with belief functions (e.g., [Laskey and Lehner 891). Let 3 = (PI, P2, . . . . Pn } be the set of (boolean) propositional clauses that have been transmitted to the ATMS (premises are specified in 3 as “+ C” or “+ lC”)5. Let (Al, AZ, . . . . Ak} be a distinguished set of primitives (i.e., assumptions) such that either Ai or TAi (or both) occurs in 3. Furthermore, let II3 contain the following (and only the following) beliefs: (a) for each Pi, “Pi (1)” is in IB, (b) for each Ai, “A; (m) V TAi (1 -m)” is in lB6. Then for any literal B (i.e., a primitive Q or its negation 42) occurring in 3, we can compute BEL( lE3, B) using the nogoods and the label associated with B as a basis. For more details, see [D’Ambrosio 87, 88; Laskey and Lehner 88,89; Provan 89a, 89b]. 3. Uncertain Reasoning The specification of independent beliefs. The D-S formalism encourages the use of the following methodology: we first identify the “independent” aspects of the problem at hand; and then we specify a belief for each of the identified aspects. Therefore, the purpose of this section is to show how we can use the belief calculus for uncertain reasoning once the independent aspects of the problem at hand have been identljied. Example 6. (adapted from [Kong 861) Two sites A and B are connected by a one-way valve which, when working, allows water to flow from A to B. The probability that this valve is working (i.e., not blocked) is pl. Similarly, sites B and C are connected by a one- way valve (with a working probability of ~2). These two valves work independently. We have no information as to whether there is any water going into A or B or C, but we are interested in whether there is any water in each site. Therefore, we formulate the working of the two valves as two independent random variables, and 18 = {V 1 Working (pl) V -7V1Working (1-pl); (VlWorking + (WaterA + WaterB)) (1); V2Working (~2) v TV2Working (1-~2); (V2Working + (WaterB + WaterC)) (1)) , and the values of BEL(IB, WaterA), BEL(lB, WaterB) and BEL(IB, WaterC) are zero at the moment. %‘he ATMS actually uses a (positive) primitive to represent the negation of another (positive) primitive [de Kleer 86b]. However, for simplicity, we can think of the ATMS as if it accepted a negated primitive directly. 6A more general specification will be to specify exactly one of the following for Ai : “Ai (ml) V T (l-ml)“, “TAi (ml) V T (l-ml)“, or “Ai (ml) V TAi (m2) V T (1-ml-m2)” (the specification of “T (l-ml-m2)” is optional). Suppose we just learned that <WaterB> = <Yes>. Then BEL(lE3 u (WaterB (1))) WaterB) = 1, BEL(lB u (WaterB (l)), WaterC) = p2, and BEL(IB u (WaterB (l)}, WaterA) remains zero. Belief dependency structures. In general, the uncertainties we want to specify may be intuitively related. When this is the case, we can no longer formulate these uncertainties as independent random variables. Nevertheless, we can try to work out a dependency structure (in a sense similar to the idea of the Bayesian causal trees Cpearl861) among the variables, and we make sure that the way a variable (e.g., A) depends on a valuation of other variables (e.g., (B = Yes) A (C = h)) is independent of the ways this same variable (i.e., A) depends on other valuations of these other variables (i.e., (B = Yes) A (C = m); (B = No) A (C = 1); etc.). This is the rational behind the following technique which uses a method described in [Smets 781 for specifying a belief set from independent conditional beliefs: Let & = (Al, AZ, . . . , AN) (e.g., (Bird, Penguin, Fly}) be a set of variables. We first specify a set (II of categorical beliefs about these variables (e.g., (I = ((Penguin + Bird A -Sly) (1))). Then, we recursively apply the following three steps until the variables contained in Ai (i 10) do not directly “depend on” each other. Step 1: From Ai (e.g., &), we identify exactly one variable7 A (e.g., Fly) and also a subset 3Bi of ai\ SO that A directly “depends on” the valuation of the elements of Bi (e.g., So = (Bird, Penguin} is a subset of (Bird, Penguin, Fly)\{Fly) so that Fly directly depends on the valuation of the two variables Bird and Penguin). Step 2: For each and every logically possible valuation of the elements of Bi (e.g., <Bird, Penguin> = <Yes, No>; <Bird, Penguin> = <Yes, Yes>; <Bird, Penguin> = <No, No>), we assess an independent belief about the valuation of A (e.g., we assess the belief “(Fly = Yes) (.9) V ((Fly = Yes) v (Fly = No)) (.l)” for the valuation <Bird, Penguin> = <Yes, No>). If this assessed belief is non-vacuous and non-categorical, we (need to) translate it into the following beliefi (“the valuation” + A’s value is in ValueSetl) (ml) v (“the valuation” + A’s value is in ValueSet2) (m2) V . . . (“the valuation” + A’s value is in ValueSetM) (mM), (e.g., “(Bird A TPenguin + (Fly = Yes)) (.9) V (Bird A TPenguin + (Fly = Yes) v (Fly = No)) (.l)“, or simply, “(Bird A TPenguin + Fly) (.9) V T (.l)“). 7Actually, we can identify more than one variable if we want. Here, just for simplicity, we restrict it to be one. *This translation is based on the principle of minimum specificity [Dubois and Prade 861. HSIA 123 Step 3: Let ai+l be Ai\ (e.g., A 1 = (Bird, Penguin, Fly}\{ Fly) = (Bird, Penguin]). Once we get to &.id, we can, if we want, specify a (non-vacuous) belief for each of the variables remaining in Afind (e.g., &find = A2 = (Bird), and we have the option of specifying a belief such as “Bird (.7) V T (.3)” for the variable Bird; however, we prefer to have “T (1)” for Bird in this case). Example 8. The belief set B = ((Penguin + Bird A -J?ly) (1); (Bird A TPenguin + Fly) (.9) v T (. 1); (Bird + -Penguin) (.95) v T (.05);) is obtained from the following “constraints”: valuation belief about some variable Bird A -Penguin Fly (.9) v T (.l) Bird A Penguin +lY (1) lBird A -Penguin T (1) --,Bird A Penguin (logically impossible) Bird TPenguin (.95) v T (OS) -IBid -Penguin (1) Therefore, BEL(lB u (Bird (1))) -1Penguin) = .95, BEL( IB u (Bird A TPenguin (1))) Fly) = .9, BEL(lJ3 u (Bird A -Penguin (1))) -Fly) = 0, etc. In addition, BEL(lB, -;Penguin) = .95, BEL(IB , Bird) = 0, BEL(lB u (Bird (l)), Fly) = 855, BEL(lB u (Bird (l)), ~Fly) = 0, BEL(lB u (Fly (l)}, TPenguin) = 1.0, BEL(lB u (Fly (l)), Bird) = 0, BEL(IB u (Fly (l)), TBird) = 0, etc. “Distinct” sources of evidence. We sometimes encounter the following situationg: (1) there are one or more sources that provide us with information, and each source has full confidence in the information it provides; (2) the information provided by each source directly “indicts” some elements of the frame of the “main variable” (i.e., the one we are interested in); (3) we can make a reliability estimation for each of these sourceslo; (4) the reliabilities of the sources are independent. When we are in this kind of situation, we can put our evidence about each particular source into a unique group, and we specify a belief dependency structure according to each group of (related) evidence. The resulting belief set, then, consists of several belief dependency structures intersecting on the main variable. Example 7. Our friend is ill, and doctors can not pinpoint the problem. Since it may involve life and death, we bring our friend to two doctors B and C that are famous in this area. It is reasonable to assume that these 9The author thanks Nit Wilson and Philippe Smets for arriving at this characterization of distinctness. ‘OA source is reliable (with respect to the information it provides) if the information it provides is indeed true. two doctors are independent in making their diagnoses (because they received their trainings in different medical doctrines, they live in different cities, they do not confer to each other, etc.). We also did some background study about the two doctors. Therefore we know that B is extremely busy, B has more authority in this area than C does, and C has a reputation of always doing his best for his patients. Also, our actual experience with the two doctors seems to confirm this background information. We are interested in the reliabilities of the two doctors. We are also concerned that B’s being busy may mean that B does not spend enough time examining our friend’s case. Therefore we formulate our knowledge about the two doctors as two belief sets IB 1 and lB 2, with each IBi containing our (intuitive) beliefs about a doctor: IB 1 = ((AuthorityB A BusyB) (1); (BusyB + LessCaseStudyB) (8) v (BusyB + -LessCaseStudyB) (.2); AuthorityB A LessCaseStudyB + ReliableB) (.7) V AuthorityB A LessCaseStudyB + -ReliableB) (.3); (AuthorityB A -LessCaseStudyB + ReliableB) (95) V (AuthorityB A ~LessCaseStudyB + -ReliableB) (.05)) l6 2 = ((SemiAuthorityC A ReputationC) (1); (SemiAuthorityC A ReputationC + ReliableC) (.8) V (SemiAuthorityC A ReputationC + -ReliableC) (.2)) After diagnosis, doctor B determines with full confidence that the patient has either illness X or illness Y. Also after diagnosis, doctor C determines with full confidence that the patient has either illness Y or illness 2. It is a medical fact that a person can not have any two of these three illnesses at the same time. Therefore we let the frame of (the main variable) Illness to be (X, Y, Z, OTHER}, and we specify three more categorical beliefs: 833 = ((BSaysXY A CSaysYZ) (1); (BSaysXY A ReliableB + (Illness = Y) V (Illness = Z)) (1); (CSaysYZ A ReliableC + (Illness = Y) V (Illness = Z)) (1)). With IB = lB1 u lB2 u IB3, we get: BEL(& (Illness = X)) = 0; BEL(lB , (Illness = Z)) = 0; BEL(lB, (Illness = Y)) = .6; BEL(ll3, (Illness = X) v (illness = Y)) = .75; BEL( lB , (Illness = Y) v (Illness = Z)) = 8; BEL(lB , (Illness = X) v (Illness = Y) v (Illness = Z)) = -95, etc. 4. Discussion Appropriateness of the notation. The belief calculus serves as a (notational) alternative for the the use of the D-S formalism for uncertain reasoning. As such, the appropriateness of the belief calculus (as a notation) will have to depend on the application domain, and there may well be situations in which set-theoretic notations are more appropriate. 124 AUTOMATEDREASONING However, it may be worthwhile to point out a superficial but nevertheless important “difference” between the (uses of the) two notations: with the belief calculus, we can sometimes explicitly specify what our evidence is and how this evidence induces beliefs; whereas with the usual set-theoretic notations, the evidence is generally regarded as “outside of” our specifications of beliefs. Tractability. The computational complexity of the belief calculus is exponential with respect to the number of variables in a belief set, and there are ways for improving the speed of this computation (e.g., [Kennes and Smets 90; Shafer et al. 87; Wilson 891). We might also look at this complexity problem from a different perspective: if we treat propositional provability (which is well known for its NP-completeness!) as the basic operator, then the complexity of the belief calculus is exponential with respect to the number of beliefs in a belief set. Thus, if we have many variables but only a few beliefs in a belief set, then a deduction-based approach such as ATMS + D-S (see movan 89b] for a complexity analysis of ATMS + D-S) may turn out to be a more attractive way for computing BEL. 5. Conclusion We formulated the D-S formalism along the lines of natural deduction systems. This formulation (called the belief calculus) allows us to infer beliefs from beliefs without ever appealing to the use of set-theoretic notations. To show how the belief calculus may be used for uncertain reasoning, we gave three examples. These examples suggested different ways for modelling real world situations. Acknowledgements. The author thanks Mike Clarke, Robert Kennes, Alessandro Saffiotti, Philippe Smets, and Nit Wilson for stimulating discussions, and two anonymous referees for very helpful comments. References D’Ambrosio, B. (1987). Truth maintenance with numeric certainty estimates. Proceedings of the Third IEEE Conference on AI Applications, Orlando, Florida, 244- 249. B’Ambrosio, B. (1988). A hybrid approach to reasoning under uncertainty. International Journal of Approximate Reasoning, 2, 1,29-45. de Kleer, J. (1986a). An assumption-based truth maintenance system. Artificial Intelligence, 28,2, 127- 162. de Kleer, J. (1986b). Extending the ATMS. Artificial Intelligence, 28, 2, 163-196. Dubois, D. and Prade, H. (1986). The principle of minimum specificity as a basis for evidential reasoning. In Uncertainty in Knowledge-Based Systems (Bouchon and Yager eds.), Springer-Verlag, Berlin, 75-84. Fagin, R. and Halpem, J. Y. (1989). Uncertainty, belief, and probability. Proceedings of the Eleventh International Joint Conference on Artijicial Intelligence, Detroit, Michigan, Aug. 20-25, 1161-l 167. Gordon, J. and Shortliffe, E. H. (1984). The Dempster- Shafer theory of evidence. In Rule-Based Expert Systems: The MYCIN Experiments of the Stanford Heuristic Programming Project (Buchanan and Shortliffe eds.), Addison-Wesley, Reading, Mass., 272- 292. Kennes, R. and Smets, P. (1990). Fast algorithms for Dempster-Shafer theory. (submitted for publication). Kong, A. (1986). Multivariate belief functions and graphical models. Doctoral dissertation, Department of Statistics, Harvard University. Laskey, K. B. and Lehner, P. E. (1988). Belief maintenance: An integrated approach to uncertainty management. Proceedings of the Seventh AAA.I Conference, Saint Paul, Minnesota, Aug. 21-26,210- 214. Laskey, K. B. and Lehner, P. E. (1989). Assumptions, beliefs and probabilities. Artificial Intelligence, 41, 1, 65-77. Pearl, J. (1986). Fusion, propagation, and structuring in belief networks. Artificial Intelligence, 29, 241-288. Provan, G. (1989a). An analysis of ATMS-based techniques for computing Dempster-Shafer belief functions. Proceedings of the Eleventh International Joint Conference on Artljkial Intelligence, Detroit, Michigan, Aug. 20-25, 1115- 1120. Provan, G. (1989b). A logic-based analysis of Dempster Shafer theory. Technical Report 89-08, Computer Science Dept., University of British Columbia. Ruspini, E. H. (1987). Epistemic logics, probability, and the calculus of evidence. Proceedings of the Tenth International Joint Conference on Artificial Intelligence. Shafer, G. (1976). A Mathematical Theory of Evidence. Princeton University Press. Shafer, G., Shenoy, P. P. and Mellouli, K. (1987). Propagating belief functions in qualitative Markov trees. International Journal of Approximate Reasoning, 1, 349-400. Smets, P. (1978). Un modele mathematico-statistique simulant le processus du diagnostic medical. Doctoral dissertation, Universite Libre de Bruxelles, Bruxelles. Smets, P. (1988). Belief functions. In Non-Standard Logics for Automated Reasoning (p. Smets, E. H. Mamdani, D. Dubois and H. Prade eds.). Academic Press, London. Wilson, N. (1989). Justification, computational efficiency and generalisation of the Dempster-Shafer theory. Yen, J. (1989). Gertis: A Dempster-Shafer approach to diagnosing hierarchical hypotheses. Communications of the ACM, 32, 5, 573-585. Zarley, D., Hsia, Y.-T., and Shafer, G. (1988). Evidential reasoning using DELIEF. Proceedings of the Seventh AAAI Conference, St. Paul, Minnesota, 1, 205-209. HSIA 125
|
1990
|
18
|
932
|
Symbolic Probabilistic Inference in Belief Networks Ross D. Shachter, Bruce D’ Ambrosio, and Brendan A. Del Favero Engineering-Economic Systems Dept. Department of Computer Science Engineering-Economic Systems Dept. Stanford University Oregon State University Stanford University Stanford, CA 943054025 CorvalIis, OR 97331-3902 Stanford, CA 94305-4025 shachte@sumex-aim.stanford.edu dambrosic@cs.orst.edu a.apollo@macbetb.stanford.edu Abstract The Symbolic Probabilistic Inference (SPI) Algorithm [D’Ambrosio, 19891 provides an efficient framework for resolving general queries on a belief network. It applies the concept of dependency-directed backward search to probabilistic inference, and is incremental with respect to both queries and observations. Unlike most belief network algorithms, SPI is goal directed, performing only those calculations that are required to respond to queries. The directed graph of the underlying belief network is used to develop a tree structure for recursive query processing. This allows effective caching of intermediate results and significant opportunities for parallel computation. A simple preprocessing step ensures that, given the search tree, the algorithm will include no unnecessary distributions. The preprocessing step eliminates dimensions from the intermediate results and prunes the search path. 1. Introduction Belief networks, directed graphical stmctores representing the probabilistic dependency among a set of variables, are an increasingly popular knowledge representation for uncertain reasoning. Much of their success is due to a growing body of methods for evaluating queries and performing probabilistic inference. The most popular methods [Jensen et al., 1990; Kim and Pearl, 1983; Lam&en and Spiegelhalter, 1988; Pearl, 19861 gain much of their performance by efficient precomputation of simple queries in response to new observations. The Symbolic Probabilistic Inference Algorithm (SPI) [D’Ambrosio, 1989; D’Ambrosio and Shachter, 19901, on the other hand, is a goal-driven method, which can respond to arbitrary conditional or conjunctive queries. SPI is incremental with respect to both queries and observations. It uses the structural information in the belief network graph to construct a search tree of efficiently evaluahle factored symbolic expressions, which allows parallel computation and caching of intermediate results. By incorporating an efficient preprocessing step and recognizing when we do not need a full joint distribution, it can achieve additional savings in search and computation. Section 2 presents an overview of SPI and the key concepts which underlie it, while Section 3 is a formal 126 AUTOMATED R~SONING presentation of the framework and proofs of the correcmess of SPI. The details of the algorithm are presented in Section 4, and conclusions and extensions are in Section 5. 2. Overview SPI reorganizes the nodes in a belief network into a tree structure for query processing by a procedure in which every node is visited at most twice. Queries are directed to the root of the tree, which in tom generates queries for its subtrees and so forth until the response to a particular query can be determined and returned to the next higher level. Once a node has responses from all of its subtrees it can compute its own response. This process continues until the root of the tree retmns a response for the original query. The performance of SPI depends critically on the organization of this search !xee. There is a condition on the cons!ruction of the search tree: if there is an arc between two nodes in the original belief network, then one node mast be the root of a subtree containing the other. In other words, there can be no arcs in the belief net behveen nodes that are in parallel subtrees. Conversely, whenever two nodes are “separated” by higher root nodes, they can and should be placed in different subtrees. (Two nodes are said to be seuarated by a set if every undirected path between the nodes contains an element from the set.) Figure 1. Example belief network. For example, consider the belief network shown in Figure 1, containing nodes numbered 1 through 9. Any node can be chosen to be the root of a search tree, but node 4 seems like a promising choice, since it separates the other nodes into four subtrees, (1,2], (31, (5). and (6, 7, 8, 9). A possible search tree for this network is From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. shown in Figure 2a. Some other search trees for the network are drawn in Figure 2b and 2c. There are many different configurations for the subtree { 6,7,8,9} in a tree rooted by node 4. Several of these are shown in Figures 2d, 2e, 2f, and 2g. Note that in the tree drawn in Figure 2e, node 7 roots one of the subtrees for node 6. There is no requirement that a subtree root, such as node 7, have an arc in the belef network to-one of its higher level roots. The only requirement is that, since there is an arc (7, 9) in the belief net, node 9 must either be higher or lower than node 7 in the tree. a) 6 I 5 I 4 4-h I 1 e) 6 A I I 7 9 9) 6 f) I 9 7 A I I I" 8 9 Figure 2. Possible search trees for the network in Fig. I. In general, there are many alternate tree structures possible for a given. belief network. We would like to choose a structure that facilitates optimal performance for the anticipated queries. Since the processing in parallel subtrees is independent, it can be performed in parallel and using independent information. This suggests that a good heuristic might be to branch wherever possible and as high as possible in the tree. One rule of thumb might be to select that root node for which the largest subtree is as small as possible. In this respect the tree drawn in Figure 2a is better than the ones in 2b and 2c. We can illustrate the basic concepts underlying SPI with a few simple examples. Corresponding to each node j in the belief network is a conditional probability distribution 7Cj for the variable Xj, conditioned on j’s parents. The joint probability distribution for all of the variables is obtained in factored form by multiplying their conditional distributions, P(Xl’X1, . . . ,Xg=xg} = P(Xl’Xl} P(X,=x, I X1=x1} . . . ‘(‘9=‘9 ’ ‘4,6,7=‘4,6,7) = x1( xl > x2( x1,2 > -*- %j( x4,6,7,9 ) 9 where ‘4,6,7,9 is a vector whose components are symbolically matched to the proper dimensions. Suppose that we want to find P( Xl ). Of course, this is simply stored in xl, but we can find it by using the more general method of summing over the joint distribution, P( x1=x1 ) =cx2 P( x1=x1, . . . , xg=xg ) , a** , = =x2 , a** , g xlt xlu, 5d x1,2 > a.- + x4,jJCJ >- Now we can recognize that n1 does not vary in the summation, and thus it can be brought out of the sum. Using the property that conditional distributions sum to 1, we can eliminate each of the distributions in turn to obtain PI x1=x1 > = Z1( ‘1 ) cx2 , a-0 , g 7c2( ‘1,2 ) -0. “9( ‘4,6,7,9 ) = ☺q( Xl > l In a similar way we can find P( Xl I X2 ) , which can easily be computed1 from P( X 1, X2 ) , P( x1=x1, x2=x2 ) = cx3 , **a , g P( x1=x1, . . . , xg=xg ) = x1( Xl )7c2( x1,2 1. This approach can also be applied to more complex problems, such as P( X5 I X2), X5,2=x5,2 ) = “1,3,4,6,7,X,9 P( x1=x1, . . . , xg=xg ) = zx1,3,4,6,7,8,9 ?( ‘1 ) .Tc2( ‘1,2 ) 7c9( ‘4,6,7,9 ) ==x134 %(‘l) E2(x1,2) “3(‘3) 7c4(x1,2,3,4) 3 , Z5(x4,5) - We are unable to simplify this final expression any more by distributing terms. To compute any further, we must use the actual numbers. Nonetheless, it does still pay to order the terms so as to minimize the number of calculations and the size of intermediate results [D’Ambrosio and Shachter, 19901. Suppose that X3 has been observed with value x*~. The solution for P( X5, X2 I X3 = x*~ ) is similar to the one above, except that the specific value for x3 can be substituted into all of the distributions and it should not be summed, P( X5 2=X5 2 I X3=X*3 ) = ix1 , , ,kl(Xl) z2(xl,2) “3(x*3) z4(xl,2 47 x*3) 7c5(x4,5)- Finally, suppose that we want to find P( X5 I X4 ) . We could easily obtain this from P( X5, X4), but we can save work if we recognize the difference between the two ‘A conditional probability is defined as P(x~=x~lx2=x2} = P{X~‘X~,X2’X2} / cy] PW1=y1X2=x2). SHACHTERETAL. 127 queries. The former is simply the distribution, P{ X5=x5 I X4=x4 ) = ~s(x4,5), while the latter requires multiplication and summation. In general, we can recognize cases in which we can obtain the conditional more easily that the joint distribution. The operations shown in these examples correspond exactly to those in SPI. There are three basic operators: product of distributions, summation of a distribution over a set of variables, and substitution of an observed value into a distribution. We can apply these operators both symbolically and numerically. Symbolic operations help us recognize when we can apply the distributive law to pull a factor out of a summation. On the other hand, we must sooner or later evaluate to numbers. If we maintain a cache of numerical results, we can avoid repeating their calculation. 3. Framework and Notation In this section, we provide a formal description of the framework for the algorithm, and prove the fundamental results underlying it. We assume that we are given a fully specified belief network, which contains a directed acyclic graph on a set of nodes N. Each node j corresponds to a random variable X-, J which can take on a finite number of possible values X.E ~j with conditional nrobabilitv distribution n: J jw Asa convention, a lower case letter represents a single node while an upper case letter represents a set of nodes, so that XJ denotes the vector of variables indexed by the set J. Therefore, the conditional distribution xj for node j can be expressed in terms of its parents or conditional nredecessors C(i), 7cj ( Xj"C(i) ) = P{ Xj = Xj I XCci) = XC(i) }. If the node j has no parents, C(i) = 0 and “j is an unconditional probability distribution. Distribution ni has dimensions D(i), W)=juC(i), J and we can think of the distribution as a nonnegative function, 7cj: aD(j) + R . We can extend the definition of node conditional distributions and their dimensions to apply to sets so that ZJ ( ‘D(J) ) = =j, J 7cj( ‘D(j) )- We say that there is an-undirected path or chain between nodes i and j if we can get from node i to node j in the network along arcs ignoring their direction. When there is a chain between two nodes, they are said to be connected; otherwise they are disconnected. Clearly, if node i is connected to node j, then node i will be connected to node k if and only if j is connected to k. We can therefore identify the maximal connected sets of nodes, called components. If there is some set S such that every chain between nodes i and j contains a node from S , S is said to separate i and j. Any set of nodes disjoint from S can be partitioned into maximal sets which are the components separated by S. A structure on a set of nodes is said to be a tree if exactly one of the nodes is identified as its root and the others are partitioned into subtrees, which are themselves trees. In SPI, all of the nodes are organized into a search tree. For each node i, let T(i) be the nodes in the subtree rooted at node i and let S(i) be the roots of all subtrees containing i. The components of T(i) \ (i} 2 separated by S(i) form the subtrees of T(i), and the roots of those subtrees are given by R(i). For example, in the tree drawn in Figure 2a, T( 6 ) = (6, 8, 9, 7 } , S( 6 ) = ( 4, 6 ) , and R( 6 ) = ( 8,9 ) . If there are separate components in the original belief network, one can create a “fictitious node” 0 with no arcs, so D( 0 ) = 0 and no = 1. Each of the components is then a subtree in T(0). As stated earlier, the search tree has one restriction on its organization. If there is an arc between nodes i and j in the belief network then either i E S(j) or j E S(i). This is enforced automatically by including all (conditionally) connected nodes in the same subtree. There is still tremendous flexibility in the construction of the search tree, since the choice of root node for any tree is arbitrary. Generalized Distributions A nonnegative function Q: QJuK -+ R will be called a (generalized) distribution for J given K if it can be normalized to compute P( XJ 1 xK ) , nmdy, P( XJ=XJIXK=XK) Although the generalized distribution contains sufficient information to compute the conditional distribution, it might not have enough to compute the joint distribution p( XJ”K 1 * We define three operators on these distributions: product, summation, and substitution. l Given distributions Q I and Q2 on sets Jl and J2, the conformal product of the distributions is given by where Q( XJ~“J~ ) = Ql( xJI ) Q2( xJ21 - The summation over dimensions K is Q = ( c, K, Q1 > Lastly, the substitution of observation x*i in dimension i is Q = ( k, i, x*i, QI ) whereQ(xJI\(i} )=Ql( Xi=x*i,XJl\{i} =xJI\(i} 1. Note that the product increases the dimension of the resulting distribution, while the summation and substitution decrease it. Processing time is proportional to the size of the distributions, which are exponential in the number of dimensions, so it is advantageous to postpone performing the product operation as long as possible, and instead to perform summation and substitution as soon as possible. We can represent a distribution either by the actual *The symbol ‘T’ is set subtraction, A \ B = ( j E A : j E B }. 128 AUTOMATED REASONING function, or by a symbolic expression of operators applied to distributions. Symbolic manipulation to the expression allows us to reorder terms to reduce computation time. Of course, at any time, the expression can be evaluated to obtain the numerical distribution. The key to reordering operations is given by the following lemma, which just states the distributive law for addition and multiplication of real numbers in terms of the notation for SPI. Lemma 1. Distributive Law for Distributions Given distributions Ql and 42 on sets JI and J2 (C, K ( *, Q1, Q2 > > The lemma states that instead of summing after multiplying two distributions, we can sum one dis&bution over dimensions for which the other distribution does not vary before multiplying the distributions. Since this reduces the number of dimensions processed in the outer sum, it can lead to substantial savings. We will try to exploit this property whenever possible in evaluating a query. Consider the search tree shown in Figure 3, in which A, B, and C are now sets of nodes. This represents the general case in SPI, in which B is a subtree, C is the union of B’s sibling subtrees, if any, and A is the remainder of the nodes N in the network. If we want to find P( XM } for some subset M of N, then the distributive law can be applied to this search tree, by the following theorem. Figure 3. General Network for the Proof of SPI. Theorem 1. Given an arbitrary subset M of N, and a partition of N into sets A, B, and C, such that B and C are separated by A, then the generalized distribution Q(xM) = P( XM =xM] is Q=(C,M'\M,(*, ~A,(*~(C,B\M’J$), (ZC\M’,“c)HL where M’ = M u D(A) . Proof: Q can be obtained by summing all variables except M from the joint distribution, which is just the product of the node distributions, Q=(C,N\MP( XN 1) =(C,N\M,(*,~A,(*,~~B,~C))). Since dimensions D(A) appear in distributions XA we cannot pull ‘rcA out of the sum for D(A). Nonetheless, the construction of the search tree ensures that D(B) A D(C) c D(A), so three applications of Lemma 1 yield Q=(C,M'\MA*, ZA, (c, 0, ( *, ( c, B \M’, Kg), cLC\M’JcH)H. In general, the response to a query is a generalized distribution and not necessarily a full joint distribution. Suppose that the desired distribution has dimensions M and is obtained by multiplying the distributions in nodes L, where D(L) = MuL. The resulting distribution, p( XMnL I xm 1, is then obtained by summing over L/M. For example, Theorem 1 is the special case for which L = N. The search tree in Figure 3 can now be applied to the conditional case. Theorem 2, Given arbitrary subsets M and L of N such that D( L ) = M u L, and a partition of N into sets A, B, and C, such that B and C are separated by A, then the generalized distribution Q( xM ) = p( XMnL=XMnL I Xm=xm ) is Q=(C,M’\M, ( *? ~EA~L,(*,(C,B~L\M’,~~~,L), (C,CnL\M,xc,L)))), where M’ = L n [ M u D(AnL) ] . proof: Because D( L ) = M u L, summation and product yield Q=(~,L\M,(*,KAnL,(*,“BnL,~CnL))) =(C,M’\M,(*,“A,--,L, C,ar,(*,(C,BnL\M’,xg,L), (C,CnL\M,~cnL)))), by the same logic as Theorem 1. Incorporating Evidence Evidence is entered in the system in the form of exact observations of the values of variables. The set of variables which have been observed is denoted by E. Suppose that Xi has been observed with the value x*i. The substitution operator ( k, i, X*i, Q ) can now be applied to any distribution Q to incorporate that evidence into the distribution. There is no longer any need to sum out dimension i and, in fact, it would be an error to do so. Because dimension i can no longer be summed over and the substitution operator eliminates all instances of it, it can be freely distributed within all products, down to the node distributions themselves. This substitution at each node distribution can be performed at every computation, but it is much simpler to substitute for dimension i in every distribution in which it appears whenever its observation is reported. Those distributions in which dimension i appears belong to node i and its children. Therefore, the node distributions Zj for those nodes should be modified by “j( ‘D(j)w ) t “j( xD(j)/E, X*i ) = ( &, i, X*i, ~j > . Once the evidence has been incorporated into the node distributions, all of our earlier results can be applied, using SHACHTERETAL. 129 the new dimensions of the distributions. For example, obtained by multiplying the distributions in nodes L and suppose that a desired distribution has dimensions M and is summing over dimensions L \ ( E u M ), which must obtained by multiplying the distributions in nodes L, where therefore have dimensions W = M u [ D( L ) \ ( L u E) ] . D( L ) = M u L u E and M n E = 0. This is a The node’s response is a generalized distribution Q for straightforward extension of Theorem 2. W nL given W\L, Q( XW > = P( XWnL’XwnLy XEnL’X*EnL 1 xm=xw\L, xm=x*E\z, } . Corollarv 1. Given arbitrary subsets M and L of N such that D( L ) = M u L u E and M n E = 0, and a partition of N into sets A, B, and C, such that B and C are separated by A, then the generalized distribution Q(xM) = p( XMnL = XMnL, XEnL = X*EnL I xNI\L=x M\LI xE\L = x*E\L 1 is Q=(C,M'\M, ( *v n&&v ( *, ( c, B n L\(E ” M), “BnL), (C,CnL\(Eu M3,~cnL)))), whereM’=(L\E)n[MuD(AnL)]. 4. The Symbolic Probabilistic Inference Algorithm We can now present a complete description of SPI in terms of the framework developed in the previous section, given a belief network and a search tree. The general form of query received by SPI is of the formP{ XJlXK,XE= x*E ), where X*E are the recorded observations. This query is transformed and sent to the highest root node in the search tree. When that node has obtained a response to all of its queries from its subtrees, it returns a generalized distribution for J given K, which can then be normalized to the desired result. The query actually sent to the highest root node consists of the set of node distributions L needed to respond to the query and the dimensions M of the desired response. The sets L and M can be computed by an algorithm which runs in time linear in the number of nodes and arcs in the belief network graph [Geiger et al., 1989; Geiger et al., 1990; Shachter, 1988; Shachter, 19901. This algorithm operates on a copy of the graph: after deleting all outgoing arcs from K u E and deleting all nodes which are neither in nor ancestors of J u K u E, the set L is those nodes connected to J and M = ( J u K ) n D( L ) .3 These sets satisfy D(L)=MuLuEandMnE=0. Theformulaeare efficient and simple to implement. We refer the reader to the above-cited literature for more explanation. The response from the search tree will be a generalized distribution Q for J given K satisfying The heart of the SPI algorithm can now be described. At any node i, a request arrives for a distribution to be 3We assume without loss of generality that E, K, and J are disjoint. If they are not, then the response can be computed using E, ICE, and JYKuE), with an additional check for consistency among the overlapping values. Of course, if such a distribution had been computed earlier and cached, it could be returned immediately. Usually, however, it will be necessary to send requests to the subtrees below this node in order to compute the response. The recursive step of the SPI request is shown in Figure 4. The first three if statements check whether there is a cached result and whether the main processing block can be avoided by recognizing two important special cases. The main processing block in general has been verfied by Corollary 1. algorithm Request ( i, L, M ) begin if ( L, M ) is cached at this node then Qi t cached result else if L=Q) then Qit 1 else if L= (i} then Qi t n;i else begin main processing block if iEL then M’t(L\E)n[MuD(i)] else M’t M; Qi+l; for r E R(i) Qi t ( *, Qi, Request (r, LnT(r), M’nT(r)) ) ; if iEL then Qit(C,M'\M,(*,~i,Qi)); i f caching of result is desired then cache result Qi for (L, M) ; end main processing block ; return Qi ; end ; Figure 4. The recursive request procedure for each node in the SPI algorithm. The query nature of SPI is designed to allow caching of responses at each node. Whenever an observation is received for node i, and the substitution operation performed on the distribution of node i and its children, all caches above node i and its children in the search tree become suspect, and should be removed from the caches. Alternatively, a check similar to the algorithm for determining the original M set could be performed to recognize for which cached expressions the new evidence is relevant, and only those expressions need be removed from the cache [Shachter, 19901. The cache management scheme can exploit the generalized distributions being returned. Suppose that the 130 AUTOMATEDREASONING distribution Q,, the response to a request (L,, MC), has been cached. Q, can serve as the response to a subsequent request ( L, M ) with the same dimensions, provided that L c L,, since in that case Q, has “too much” information. On the other hand, if L r) L,, then a new response must be computed, and it might as well replace Q, in the cache. Examples Suppose that SPI were applied to the query P{ X5 I X2 ) for the belief network in Figure 1 using the search tree in Figure 2a. The following results would be obtained: Jt {5},Kt (2},Et0; Q + Request( 4, CL2,3,4,5), C&51 ) ; 44 + (C, {1,3,4), (*, ~4, Request( 2, 1123, (12) 1, RequeW, (31, (33 h Request(% {5L (5) >, Request( 6,0,0 ) > > ; Q2t(C,0,<*,~2,Request(l, W, (11 >H; Ql t~1;Q3t~3;Q5t~~;andQ6t1. Now, suppose that observations were made of X6 = x*6 and X9 = x*9. The caches for nodes 8,9, 6, and 4 would be invalidated and E t { 6,9) ; 75j + ( -k 6, x*6, ‘rcfj > ; 794 + ( k 6, x*6,7$3 ) ; and 7E9 * ( 439, x*9, x9 > - In response to query P( x2 1 x6 = x*6, x9 = x*9 ): Jt {2},K+QI; Q + Request( 4, I U,3,4,6,7,9), ( 11 > ; Q4 + ( C, { L3,41, l *, q, RequW 2, C W, { 12) 1, RequW 3, 131, (31 1, Request( 5,0,0 ), Request( 6, Hi’L919 0 ) > > ; Q2 t cached result from above ; Q6 + ( x:, 0, ( *, 7$j3 Rquest( 8,0, 0 >, Rquest( 9, (7,9L (01 > > > ; Q9 + ( C, (71, ( *, ng, Request( 7, (7),{7) ) > > ; Q3t~3;Q5tl,Q7t~7;andQstl; 5. Conclusions and Extensions In this paper, we have presented the Symbolic Probabilistic Inference Algorithm along with a proof of its correctness. SPI is a goal-driven rather than data-driven algorithm, which performs a variation of dependency-directed backward search in response to arbitrary conditional queries. There are many ways that SPI can be refined for practical implementation. The most significant issue is the construction of the search tree. A promising approach appears to be recursive decomposition, in which the search tree is made as balanced and shallow as possible [Cooper, 1990; Fiduccia and Mattheyses, 19821. This not only allows for parallel processing along the independent branches, but means that observations will invalidate the fewest possible caches. Given a search tree, there are still difficult (NP-hard) decisions to made, since there can be significant benefit to postponing evaluation of an expression, maintaining it in symbolic rather than numeric form. For example, if one factor in a distribution product shares none of the dimensions being summed over, then that factor can be pulled out of the sum as in Lemma 1. It might also be worthwhile to reorder the factors in the product before performing the summation [D’Ambrosio, 1989; D’Ambrosio and Shachter, 19903 . There are additional interesting tradeoffs between symbolic and numeric computations of intermediate results. By evaluating expressions completely at nodes, caches can be created to prevent repeated computations. Sometimes, however, postponing those evaluations can lead to improved factoring opportunities. Finally, the search tree can be constructed dynamically in response to queries, yielding the most efficient search structure, but eliminating caching opportunities. Much needs to be learned about the relative benefits of such customized query-processing versus maintaining the accumulated information. 6. Acknowledgements We benefited greatly from the comments of Greg Cooper, Mike Fehling, Eric Horvitz, Perry McCarty, Ramesh Patil, and Mike Wellman. 7. References Cooper, G. G. (1990). Bayesian belief-network inference using recursive decomposition (KSL 90-05). Knowledge Systems Laboratory, Stanford University. D’Ambrosio, B. (1989). Symbolic probabilistic inference in belief nets . Department of Computer Science, Oregon State University. D’Ambrosio, B. and Shachter, R. D. (1990). Factoring Heuristics for Generalized SPI. Conference on Uncertainty in Artificial Intelligence, Boston, submitted. Fiduccia, C. M. and Mattheyses, R. M. (1982). A linear-time heuristic for improving network reliability. Nineteenth Design Automation Conference, Las Vegas. Geiger, D., Verma, T., and Pearl, J. (1989). d-separation: from theorems to algorithms. Fifth Workshop on Uncertainty in Artificial Intelligence, University of Windsor, Ontario, 118- 125. Geiger, D., Verma, T., and Pearl., J. (1990). Identifying independence in Bayesian networks. Networks, to appear. Jensen, F. V., Olesen, K. G., and Andersen, S. K. (1990). An algebra of Bayesian belief universes for knowledge based systems. Networks, to appear. Kim, J. H. and Pearl, J. (1983). A computational model for causal and diagnostic reasoning in inference engines. 8th International Joint Conference on Artificial Intelligence, Karlsruhe, West Germany. Lauritzen, S. L. and Spiegelhalter, D. J. (1988). Local computations with probabilities on graphical structures and their application to expert systems. J. Royal Statist. Sot. B, 50(2), 157-224. Pearl, J. (1986). Fusion, propagation and structuring in belief networks. Artificial Intelligence, 29(3), 241-288. Shachter, R. D. (1988). Probabilistic Inference and Influence Diagrams. Operations Research, 36(July-August), 589-605. Shachter, R. D. (1990). An Ordered Examination of Influence Diagrams. Networks, to appear. SHACHTERETAL. 131
|
1990
|
19
|
933
|
A Hierarchical Protocol for Coordinating Multiagent Behaviors Edmund H. Durfee and Thomas A. Montgomery Department of Electrical Engineering and Computer Science University of Michigan Ann Arbor, Michigan 48109 durfee@caen.engin.umich.edu, monty@caen.engin.umich.edu Abstract . We describe how a behavior hierarchy can be used in a protocol that allows AI agents to discover and resolve interactions flexibly. Agents that initially do not know with whom they might interact use this hierarchy to exchange abstractions of their anticipated behaviors. By comparing behaviors, agents iteratively investigate interactions through more focused exchanges of successively detailed in- formation. They can also modify their behaviors along different dimensions to either avoid conflicts or promote cooperation. We explain why our pro- tocol gives agents a richer language for coordina- tion than they get through exchanging plans or goals, and we use a prototype implementation to illustrate our protocol. We argue that our hierar- chical protocol for coordinating behaviors provides a powerful representation for negotiation and can act as a common foundation for integrating theo- ries about plans and organizations. Introduction In a world inhabited by numerous active systems (agents), the agents often must engage in coopera- tive and competitive behavior in order to achieve their goals. To decide how they should behave, they need to know how agents with whom they might inter- act might behave. Just as important, they need to avoid expending their limited reasoning resources on studying how agents with whom they will not inter- act might behave. If potential interactions between agents can be predicted because each has some pre- defined role (due, for example, to commonly known organizational constraints [Corkill and Lesser, 1983; Durfee et al., 19871 or to functional or geographical relationships [Conry et al., 1988]), then channeling de- tailed information about planned actions is straight- forward. On the other hand, if agents are ignorant about with whom they might interact, then they need ‘This research was sponsored, in part, by the University of Michigan under a Rackham Faculty Research Grant, and by a Bell Northern Research Postgraduate Award. 86 AUTOMATED REASONING to narrow down the possibilities before they exchange detailed information, otherwise they might swamp the communication channels and each other. Mobile robots on a warehouse floor, for example, can have an ever-changing group of neighbors, and when plotting collision-free paths for the near future should identify and converse only with their current neighbors. We introduce a hierarchical protocol for this type of problem. In our protocol, an agent represents its an- ticipated behavior at numerous levels of abstraction. When it must decide with whom it might interact, the agent blindly broadcasts its most abstract behavioral information rather than details about its planned ac- tions. Then, as an agent receives abstract information from others, it compares anticipated behaviors to de- cide with whom it might interact, and then exchanges more detailed information with only those agents. In essence, the protocol allows the agents to engage in a dialogue in which they can move between different levels of detail about behavior, feeling each other out to discover who they can safely ignore and how they should change their behaviors based on anticipated in- teractions with agents that they cannot ignore. Our protocol advances the field of distributed ar- tificial intelligence (DAI) in two ways. The obvious way is that it adds to DAI’s arsenal of coordination techniques, permitting a form of coordination that has been unavailable. By enlarging the set of coordination techniques, we both extend the range of coordination problems that we can solve and learn more about the nature of intelligent coordination. The more subtle but potentially far-reaching contribution of our protocol is that it introduces the use of behaviors into multi-agent coordination. Behaviors subsume the more traditional representations of goals and plans, and even blur the boundaries between plans and organizations. As a re- sult, our protocol has the potential to integrate diverse theories and mechanisms for intelligent planning and organizational design. We return to these possibilities in the concluding section. First, we outline our proto- col, relate our protocol to other research, and describe a preliminary implementation of the protocol and ex- perimental results. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. lab-robots lab-dlean The Protocol At the heart of our protocol is the concept of a be- havior hierarchy. To define what this hierarchy is, we first indicate what it is not. It is not a plan hierar- chy, where plans are represented in varying levels of detail and detailed subplans are linked to their more abstract counterparts. Similarly, it is not a goal hierar- chy, that links goals and their subgoals for a given task. Although plan and goal hierarchies are useful for de- ciding on actions to achieve results, they only describe limited aspects of an agent’s behavior. For example, plan hierarchies emphasize how to do things: At the abstract levels are vague, encompassing instructions, while the detailed levels prescribe specific actions. Al- ternatively, goal hierarchies emphasize what to do: At the abstract levels are broad objectives, and at the de- tailed levels are specific, atomic goals. A behavior hierarchy subsumes plan and goal hierar- chies because it represents the what and how of agents, and also the who, when, where, and why. That is, an entry in the behavior hierarchy represents who are be- having in a particular way, what they are trying to achieve, when they are behaving this way, where they are behaving this way, how they are acting to accom- plish this behavior, and why they have initiated this behavior. Each of these 6 aspects represents a different dimension for composition or decomposition.’ In fact, we might have hierarchies for each dimension, as well as for the overall behavior. Example partial hierarchies are shown in Figure 1. Note that moving between en- tries in a behavior hierarchy can involve moving along several separate dimensions simultaneously. Our protocol currently assumes that all agents use the same language to describe the different behavioral dimensions. The agents thus can map a received be- havior into their local representations; in essence, the behavioral dimensions describe a 6-dimensional space, and an agent can find the region in this space that a received behavior occupies. From this mapping, an agent can recognize potential behavioral interactions when behaviors’ regions overlap or are proximal. The ability to recognize interacting behaviors and to move along dimensions to find alternative interactions is at the core of our protocol. With this representation in mind, we now present a generalized version of the protocol; a more detailed description for a particular application is given later. An agent with its own tasks (or a group of agents with group tasks) forms a behavior hierarchy repre- senting a decomposition of the tasks along the dimen- sions that are appropriate given the tasks and the en- vironment. Agents then exchange information at the highest level of abstraction, and map received informa- A:,- z-c, cl.,:.. 1 ,..,l L-l....,.:,.. L.:,,....,l.*. . Dv. :,,,,r.c.w.e IJlUll IllbU Clltxl- luGa lJrd11itv1uz lll~la4Llly. uy 1113pcLcllltj ‘Other dimensions might be incorporated into the rep- resentation in the future. However, the 6 currently included were an obvious initial choice. heros puma contai /---GA gone opus Odysseus bottles-recyc cans-recyc h A A (a) WHO (b) WHAT this-year this-month lab A this-week eastwingl westwingl today tomorrow A A A (c) GiEN (d) WHERE clean-up request colle external internal h A A coil-cans calf-bots A / user-command AT- (9) opus Behavioral Hierarchy In (a) is a partial personnel hierarchy, (b) is a partial goal hierarchy, (c) is a partial temporal hierarchy, (d) is a partial spatial hierarchy, (e) is a partial plan hi- erarchy, and (f) is a motivation hierarchy. In (g) and (h) are partial behavior hierarchies for robots OPUS and ODYSSEUS, respectively. Figure 1: Example Partial Hierarchies DURFEE AND MONTGOMERY 87 relationships between behaviors along the different di- mensions, an agent can recognize potential negative interactions (such as resource conflicts) with another agent. For example, if the robot Opus, with the be- havior hierarchy in Figure lg, receives from Odysseus its most abstract behavior (Figure lh), then it finds a potential conflict along the when and where dimen- sions. The robots will be on the same floor in the same time interval, and thus could collide. When an agent recognizes a potential negative inter- action, it has two alternatives. One choice is to modify its own behaviors such that the interaction is avoided. To do this, it searches through alternative values along the behavioral dimensions that lead to acceptable, but no longer interacting, behaviors.2 For example, Opus might modify its behavior so that it works on the floor next-week instead. The other choice an agent has is to refine its view of the potential interaction, so as to identify more specifically how the behaviors are inter- acting, or possibly to discover upon closer inspection that there is no interaction. To pursue this choice, the agents move down to the next level of the hierarchy and exchange only the behavioral information that is relevant to the potential interaction. When it receives new behavioral information at less abstract levels, an agent maps this information into its hierarchy and the process repeats. For example, at the more detailed level, Opus learns that he and Odysseus will be work- ing in different wings, and so no collision is possible (Figures lg and lh). If they discover that their be- haviors do not, in fact, interact, the agents discontinue their communications. Thus, agents that are not in- teracting discover this with minimal communication of more detailed information. Agents can also interact positively, and at times might change their behaviors to capitalize on positive interactions. For example, Opus and Odysseus might decide that one of them could achieve the goals of both. Opus might extend its behaviors for today and tomorrow along the “what” dimension (to “containers- recycled”) and along the “how” dimension (to “collect- containers”), while Odysseus is now free to pursue other behaviors. In our protocol, an agent has a choice between modifying its behavior at the current level of abstraction to improve interactions, or exchanging in- formation to probe more deeply into positive interac- tions and establish them at a more detailed level. De- tailed exchanges can lead to crisper coordination. For example, if Odysseus wants to meet Opus to cart away the containers collected in the morning, then going to more detailed levels allows them to decide more specif- ically when and where to meet. This outline of our protocol leaves many unan- swered questions. Some deal with the agents’ knowl- edge: Where does the hierarchical knowledge come from? How can we ensure consistency between agents? 2 Searching hyp othetical behaviors is similar to searching hypothetical cases for argumentation [Ashley, 19881. How do we represent constraints that moving along one dimension might impose on other dimensions? Other questions deal with effectively using the pro- tocol: When should agents initiate an exchange of abstract behavioral information? How do agents de- cide which of them should modify their behavior to avoid negative or promote positive interactions? How do agents decide which dimensions of their behavior to modify? What happens when modifying an inter- action with some agents introduces new interactions with other agents? Can the protocol guarantee conver- gence? What are the computational and communica- tion costs of the protocol? Answering these questions is an ongoing effort, and our initial answers to some of them are only a first step. Before discussing these, we relate our protocol to prior research. Relationship to Other Research Our protocol addresses problems where the spatial and functional relationships between agents change over time. These issues also arise in the air-traffic control problems studied at Rand [Cammarata et al., 1983; Steeb et al., 19SS]. Unlike our protocol, the Rand ap- proach involves centralizing authority. Specifically, in their approach a group of potentially interacting air- craft engage in a discussion to choose a group leader. Once chosen, the leader collects detailed information from each group member, designs a group plan to avoid negative interactions (aircraft collisions), and then tells each aircraft what it should do. Although the leader could send processing tasks to group members during the planning phase [Steeb ei al., 19861, control is cen- tralized. The Contract-Net protocol [Davis and Smith, 19831 provides a mechanism by which autonomous agents ne- gotiate to assign tasks among themselves to balance load and connect tasks with the agents that are most suited to pursuing them. The view taken by Contract- Net is that interactions between agents are due to mu- tually agreed upon task assignments; unlike our proto- col, the Contract-Net protocol does not anticipate that agents might independently take actions that could lead to unintended interactions. The multistage negotiation protocol developed by Conry and her colleagues [Conry et al., 19881 does ad- dress the need to identify and recover from resource conflicts. Developed in the context of a distributed network management task, their approach first propa- gates information about tasks (circuits to complete) through the network, so that each subnetwork con- troller can enumerate the possible ways it can assign its resources. The controllers then engage in an iterative dialogue where they tentatively choose combinations of assignments, exchange information to detect con- straint violations (over burdened channels that connect their subnetworks), and eventually converge on a con- sistent set of assignments (even if it means neglecting low-priority tasks). Unlike our protocol, multistage ne- 88 AUTOMATEDREASONING gotiation assumes a fixed topography that controllers use to guide communication. Also, their approach as- sumes that the agents can enumerate all of the pos- sible resource assignments, and so the protocol is a constraint labeling process. In our protocol, the space of possible behaviors can be intractable, so the search for acceptable combinations of behaviors involves mod- ifying behaviors on the fly. In the partial global plannin and Lesser, 1987; Durfee, 1988 f framework [Durfee local plans are ex- changed to recognize larger goals to work toward, and then the actions taken to achieve these goals are re- ordered to improve group performance. In the con- text of our new protocol, the information about what each problem solver is doing (the results it is trying to develop) is mapped into a hierarchy of goals in or- der to identify more encompassing results, and then the how and when of the plans are revised to improve group problem solving. Thus, partial global planning is subsumed by our new protocol. In addition, to avoid the overhead of unconstrained exchanges of the plans, partial global planning insists that the agents have static organizational knowledge, which essentially dic- tates who each agent should exchange plan informa- tion with. Our protocol assumes no such knowledge because agents instead broadly exchange abstract be- havioral information and use this to focus more de- tailed information appropriately. Our approach also differs from recent efforts to more generally classify plan and goal interactions [Decker and Lesser, 1989; von Martial, 19891 because of our extension to agent behaviors, not just plans and goals. Lansky has developed a formalism for specifying be- havioral information about agents, and has investi- gated its use for multi-agent domains [Lansky, 19851. Her use of the term “behavioral” and ours differ, in that she considers behavior in terms of the constraints on possible relationships between actions, whereas we see behavior in terms of (possibly underspecified) infor- mation about the who, what, when, where, how, and why of activity in the world. These views are not in- compatible, and her formalisms could be incorporated into our approach. Davis [Davis, 19811 also has enu- merated many of the issues involved in coordinating multiagent behavior. While Davis’ treatment is at a conceptual level, we have moved toward an experimen- tal investigation. Implementation and Experiments As a preliminary test of our new protocol, we have been investigating the general problem of detecting and resolving resource conflicts. As a representative ex- ample of this problem, consider an application where several mobile robots move in common areas and be- tween these areas through shared doorways. The com- mon space, and especially the space in and around the doorways, represents important resources for which the robots might contend. Yi) ni hy: user-comm For sll i&k: regioni contains reglonlj; lnterwal ti - tj contains Intewals tik - tlk+l Figure 2: A Robot’s Partial Behavior Hierarchy We have implemented and evaluated our protocol using a simulation of this application. A partial, gener- alized behavior hierarchy for the application is shown in Figure 2. What sets this type of hierarchy apart from more typical plan/goal decomposition hierarchies is that the representation at one level summarizes the information in the lower levels. For example, in a typi- cal plan/goal decomposition, a desire to move to a goal location might be decomposed into a sequence of inter- mediate locations to achieve, which might be further decomposed, and so on. In that type of decomposition, an entry at one level only reflects the expected end re- sult of the levels below it, and not the behavior of the agent in achieving this result. In contrast, the spatial (where) information of an entry in our behavior hierar- chy is computed as the smallest region that subsumes the regions below it, just as the temporal (when) in- terval is the shortest interval that includes all of the intervals below it. As a result, an entry essentially de- to where scribes where the robot might it is going) over an interval of be (as time. opposed The robots are currently limited to knowing how to move, who they are individually (they have no-concept of coalitions), and that commands come from external sources. They plan paths to goal locations by finding a sequence of inter tmediate locations that avoid obsta- cles, and represent spatial regions as rectangular areas. They use knowledge about their movement speeds to compute the time needed to move between locations. If they decide that their behaviors might lead to colli- sions, the agents can search along either the temporal or spatial dimensions to change their behaviors. Using the Protocol To implement the protocol for our experiments, we have made several assumptions to promote structured communication and algorithmic convergence. First, we assume that each robot is given a unique author- ity value, so that robots can decide, when their plans are equally ranked, whose should get priority. Sec- ond, we assume that there are distinct intervals during DURISE AND MONTGOMERY 89 which behavioral information is exchanged and mod- ified. Third, we assume that robots modify their be- haviors either by introducing delays in their actions or by choosing alternative routes. This choice is currently based on a user-supplied parameter. The process begins by each robot broadcasting a message indicating who it is and what goal it wants to pursue. After enough time elapses, the robots build a list of robots sorted by their goal priorities. When robots have equal priority goals, they are sorted by their unique authority values. Because robots develop identical lists, the highest authority (superior) robot knows who it is. This robot broadcasts its most ab- stract behavioral information to the other (inferior) robots, who in turn broadcast theirs back to acknowl- edge receipt. Each of the inferior robots compares its local information with what it has received, and checks for conflict. This is simply computed by determining whether it expects to be in an overlapping region at an overlapping time interval. If no conflict is possible, it sends an empty message back to the superior who records that no conflict exists. If a conflict exists, the inferior can either resolve it or more fully explore it. It can resolve the conflict by either delaying its activities until after the superior has completed its own, or by moving through another spatial region (if possible). Alternatively, it can ex- plore the conflict by comparing its more detailed an- ticipated behavior (at the next level of the hierarchy) with what it knows of the superior, and then sending information about those aspects of its behavior that might be conflicting back to the superior. The supe- rior compares these with its more detailed behaviors, and sends back only the more detailed behaviors that might interact. This process continues until either the inferior resolves the conflict at some level or it discovers on closer inspection that no conflict will occur. Either way, it sends an empty message back to the superior who records that no conflict exists anymore. When the superior has heard from all inferiors that no conflicts exists, it passes control to the next robot in the pecking order. The process repeats, and the new superior interacts with the remaining inferiors to re- move conflicts. When done, the process repeats again, and so on. At each repetition, the set of inferiors de- creases, until no inferiors remain. At this point, all of the conflicts have been removed. However, there is one wrinkle: When an inferior modifies its behaviors to avoid conflicting with the cur- rent superior, it might introduce behaviors that conflict with previous superiors. For this reason, before an infe- rior sends a message to the current superior indicating that no conflict exists anymore, it first communicates with previous superiors to ensure no new conflict has been introduced. If a new conflict has occurred, the in- ferior uses the same techniques as before to resolve the conflict with the previous superior, and then checks for new conflicts with the current superior. We can guar- antee that we will not enter infinite loops of refinement because of our assumption that a robot changes its be- havior either by introducing delays (always postponing actions) or by choosing a route that no superior has chosen. Using temporal modification, the robots could at worst serialize their actions so that no parallelism remains. Fortunately, such worst-case scenarios need seldom occur. Using spatial modification, the robots at worst pursue very roundabout routes. When the last robot in the pecking order is given control, it knows that all conflicts have been resolved and broadcasts this fact to the others. The robots synchronize and then begin carrying out their planned activities. As each completes its activities, it again broadcasts this fact (along with its next goal’s priority) to the others; when all have completed their activities, the protocol is initiated again for the next goals. This is just one possible implementation of the pro- tocol, and is primarily intended to test the implica- tions of communicating at different levels of the behav- ior hierarchy. To maintain computational tractability, to ensure convergence, and to guarantee that conflicts will be resolved ahead of time (which typically requires that some agent ultimately has authority), this imple- mentation assumes a total order on the agents and re- stricts how agents can modify their behaviors. We are developing more robust implementations in which new agents can join in at any time, agents can recover if one of them fails during the protocol process, and agents can dynamically allocate authority based on current circumstances. Experiments To investigate the performance of this implementa- tion of our protocol, we simulated 2 environments in MICE (the Michigan Intelligent Coordination Exper- iment testbed [Durfee and Montgomery, 19891). The first environment consists of 2 robots in 2 rooms that are joined by 2 doorways. Each doorway is only large enough for one robot (Figure 3a). The second environ- ment consist of 3 robots in 2 rooms joined by 1 doorway (Figure 3b). In these environments, if the robots at- tempt to occupy the same location at the same time, they “bounce off” each other and return to their pre- vious locations. Robots require 1 simulated time unit to move in any direction. Each robot has its own distinct blackboard-based ar- chitecture, implemented in GBB [Corkill et al., 19861. The robots are given appropriate knowledge sources for planning paths to goal positions, for building be- haviors based on these plans, for exchanging informa- tion at various levels of their behavior hierarchy, and for modifying behaviors along temporal and spatial di- mensions to avoid potential collisions. Communication delay between robots is 1 simu- lated time unit. To measure the protocol’s commu- nication overhead, we record the number of behav- iors exchanged. Similarly, to measure the computa- 90 AUTOMATEDREASONING Table 1: Experiment Summary. (4 (b) In (a), RobotA ( so i circle) is trying to get to the 1 d location marked with a hollow circle, RobotB (solid triangle) to the hollow triangle. In (b), RobotC (solid square) is also trying to get to the location marked with the hollow square. Figure 3: Experimental Scenarios in MICE tional overhead, we use MICE’s capabilities for charg- ing robots for time spent reasoning in the following way. As it compares behavioral information, a robot keeps track of how many comparisons between local and received behaviors it makes. For every n compar- isons (where n is a user-modifiable parameter), it tells MICE to increment its clock by 1 simulated time unit. We also measure the simulated time spent carrying out the activities (from the earliest time an agent begins moving to the latest time an agent arrives at its goal destination), and the overall time to achieve all of the goals. For simplicity, we only give each robot one goal. In our first set of experiments, consider the 2 robot case (Figure 3a). Unhindered, each robot requires 22 time units to move from start to goal locations. The re- sults of our experiments are given in Table 1. Without any exchange of behavioral information (experiment l), the robots spend a small amount of time initializ- ing their plans. The time that robots spend moving to their goal destinations, however, is infinite, because the robots perpetually collide at the doorway. When we allow the exchange of behavioral informa- tion, the robots can successfully make it to their goal destinations. First, consider the case where robots can make 5 comparisons of behaviors per simulated time unit. In experiment 2, the robots resolve potential con- flicts between their most abstract behaviors. The over- all expected regions of movement for the robots overlap at the doorway, so RobotB (the lower authority robot) changes the timing of its activities so that it does not begin moving anywhere in its overall region until Rob- otA expects to have finished. In essence, the robots have serialized their activities (with 1 extra time unit imposed between their activities to ensure no overlap). In experiment 3, we make the robots resolve poten- tial conflicts at an intermediate level. At this level, Ex En M Cps Rs Ex TP TA Done 1 a - - none 0 5 00 2 a t 5 abs 2 10 45 ii 3 a t 5 int 9 16 35 51 4 a t 5 det 16 77 24 101 5 a t 50 abs 2 10 45 55 6 a t 50 int 9 13 35 48 7 a t 50 det 16 23 24 47 8 a s 5 abs 2 10 32 42 9 a s 5 int 8 14 32 46 10 a s 5 det 13 47 32 79 11 a s 50 abs 2 10 32 42 12 a s 50 int 8 13 32 45 13 a s 50 det 13 17 32 49 14 a’ - - none 0 5 22 27 15 a’ t 5 abs 2 10 43 53 16 a’ t 5 int 8 15 33 48 17 a’ t 5 det 7 33 22 55 18 a’ t 50 abs 2 10 43 53 19 a’ t 50 int 8 13 33 46 20 a’ t 50 det 7 15 22 37 21 a’ s 5 abs 2 10 32 42 22 a’ s 5 int 7 14 32 46 23 a’ s 5 det 7 33 22 55 24 a’ s 50 abs 2 10 32 42 25 a’ s 50 int 7 13 32 45 26 a’ s 50 det 7 15 22 37 27 b - - none 0 5 28 b t 5 abs 6 14 z E 29 b t 5 int 23 27 54 81 30 b t 5 det 68 178 25 203 31 b t 20 abs 6 14 63 77 32 b t 20 int 23 21 54 75 33 b t 20 det 68 65 25 90 34 b t 50 abs 6 14 63 77 35 b t 50 int 23 21 54 75 36 b t 50 det 68 44 25 69 Ex: En: M: cps: Res: Ex: TP: TA: Done: Abbreviations Experiment number Environment Modification (temporal or spatial) Comparisons per simulated time unit Level where behavior conflicts are resolved: ABStract, INTermediate, or DETailed. Number of behaviors exchanged Time for planning non-conflicting behaviors Elapsed time for robot activities Time at which all robot goals achieved each has broken its overall behavior into 3 parts: to get in front of the door, to get to the other side of the door, and to get to the goal location. In the initial, abstract behavior exchange, they detect the potential conflict, and so RobotB requests intermediate information from RobotA. At first, RobotB changes its activities so that it will not begin its first intermediate behavior (going DURFEE AND MONTGOMERY 91 to the door) until RobotA begins its second behavior (entering the door). However, because RobotA’s sec- ond behavior includes being in front of the door, and because this overlaps with the region of RobotB’s first behavior, RobotB further delays its first behavior until RobotA has actually moved through the door. RobotB propagates the effects of this delay on the rest of its behaviors, and because subsequent time intervals are modified, no further conflicts between the robots’ be- haviors exist. The data shows that resolving potential conflicts at this level incurs more communication and further delays the start of the plans (compared to ex- periment 2), but results in more movement parallelism in the robots’ actions. As a result, the overall time to achieve the goals is lower. In experiment 4, the robots exchange abstract, then intermediate, and finally fully detailed behaviors (down to locations they will occupy at specific times). Based on this information, RobotB again modifies the intervals of its behaviors, but this time recognizes that it need not delay from the very start. Instead, it de- termines that trying to get in front of the door is what conflicts with RobotA, and delays this detailed behav- ior. Propagating this change removes all other con- flicts. The movements of the robots in this case have substantial parallelism so the time spent carrying out the plans is reduced, but the amount of communica- tion and the time spent resolving the conflicting plans is much greater. In fact, the overall time is much worse than the previous 2 experiments. Experiments 5-7 are the same as 2-4, except the number of comparisons per simulated time unit is 50. This serves to make computation cheaper with respect to movement, but does not change the quality of coor- dination. The implication of this change is that exert- ing computational effort to increase parallel movement is more worthwhile, so resolving conflicts at more de- tailed levels is better. In experiments 8-13, RobotB resolves the conflict along the spatial dimension by moving through the fur- ther doorway. This results in identical plans regardless of the level at which the conflicts are resolved, because once RobotB plans its new path, the robots’ behaviors no longer interact at any level of abstraction. To save on overhead, resolving conflicts at less detailed levels is thus better. Experiments 1426 are the same as 1-13, but now RobotA starts slightly closer to the door (environment a’). As a result, the robots’ actions will not conflict, and the best results are achieved without any coordi- nation (experiment 14). When the robots coordinate at the abstract and intermediate levels, they cannot ensure that no conflict will occur, so they modify their plans either temporally (experiments 15, 16, 18, 19) or spatially (experiments 21, 22, 24, 25). At the de- tailed level, the robots recognize that no resolution is needed, but only after substantial investment of effort. Sometimes this effort is worthwhile (experiments 20, 26) while at other times it is not (experiments 17, 23). Finally, experiments 27-36 are based on the 3 robot environment (Figure 3b). Without any conflict avoid- ance, the robots once again perpetually collide at the doorway (experiment 27). The addition of a third robot can dramatically increase the amount of informa- tion exchanged at the detailed and intermediate levels. As a result, when robots can do only 5 comparisons per simulated time unit (experiments 28-30), resolving conflicts at the abstract level is better than the inter- mediate level which is better than the detailed level. As the number of comparisons per simulated time unit increases (experiments 31-36), first the intermediate and then the detailed levels are best. Note that the time spent resolving conflicts at more detailed levels is always greater regardless of comparisons allowed per time unit, because of the communication delay. Sev- eral messages might be in transit at the same time, however, so the time spent resolving conflicts can be less than the number of behaviors exchanged (such as in experiments 35 and 36). In summary, these experiments highlight the fact that different circumst antes demand different amounts of communication and coordination. Sometimes not communicating or coordinating is best (experiment 14), but at other times such a strategy can be catas- trophic (experiments 1 and 27). Sometimes it is more cost effective to coordinate at a high-level, because it involves less overhead and results in relatively accept- able coordination (such as in experiments 8, 11,2 1, and 28). Coordinating at detailed levels has advantages in situations where the chances for parallelism are greater (such as in experiments 7 and 36), or where the robots can only ensure that they will not conflict when the examine their behaviors in detail (such as in experi- ment 26). And coordinating at an intermediate level is sometimes the best policy (such as in experiments 3 and 32). In short, conflicts should be resolved at differ- ent levels in different cases. Unlike previous protocols that work at a single level of detail, our new proto- col allows the robots to coordinate at different levels flexibly. The experiments also point toward further research directions. Issues in mediating between different per- spectives (which our current implementation avoids by imposing a total ordering on agents) and in deciding along what dimensions and at what level to resolve conflicts (recall our current implementation depends on user-supplied parameters) are focuses of our current re- search. In addition, using other dimensions for resolv- ing conflicts (or promoting cooperation) is important, and we are exploring issues in getting agents to adopt each other’s (or joint) goals or having them choose methods that achieve their goals in non-conflicting ways. The challenge in this research is in exploiting the richness of the behavior hierarchy while heuristi- cally restricting the search among behaviors to main- tain computational tractability. 92 AUTOMATEDREASONING Conclusions As we have demonstrated experimentally, our proto- col allows a form of coordination that is well suited to domains where interacting agents do not know, a priori, with whom they will interact. This is accom- plished through a dialogue between the agents in which they are free to exchange information at different lev- els of abstraction about their anticipated behavior. In essence, this dialogue is a rudimentary form of nego- tiation between the agents: Although our specific im- plementation identified which agent involved in a con- flict should modify its behavior, our protocol admits to more flexible (and arguably more computationally expensive) encounters, where each agent involved in a conflict moves along some of its behavioral dimensions until a compromise is found that eliminates the conflict and yet allows each agent to retain important behav- ioral attributes. Our work thus paves the way for a new investigation into intelligent negotiation. Another observation that we have made is that the dimensions of our behavior hierarchy correspond to problem decomposition directions found in human or- ganizations [Malone, 19871. If we decompose a behav- ior along the what dimension, for example, we are de- composing based on results (or products) of behavior, which leads to a product hierarchy. Similarly, decom- posing along the how dimension leads to a type of functional hierarchy. From other dimensions, we see personnel hierarchies, temporal hierarchies, spatial hi- erarchies, and even motivational hierarchies. We are intrigued by the possible relationship between our ap- proach and organizational theory, and indeed are work- ing toward experiments where groups of robots team up and represent their overall behavior in the behav- ior hierarchy. As a result, groups (or organizations) of individuals are viewed as single entities, and can ne- gotiate as a unit; yet, by traversing the hierarchy the behaviors of individuals are still represented. Based on these insights, we are currently exfiloring how to inte- grate organizational and planning theories within our single protocol. References [Ashley, 19881 Kevin D. Ashley. Model&rag Legal Argu- naent: Reasoning with Cases and Hypotheticals. PhD thesis, University of Massachusetts, February 1988. [Cammarata et al., 19831 Stephanie Cammarata, David McArthur, and Randall Steeb. Strategies of coopera- tion in distributed problem solving. In Proceedings of the Eighth International Joint Conference on Artificial Intelligence, pages 767-770, Karlsruhe, Federal Republic of Germany, August 1983. [Conry et al., 19881 S usan E. Conry, Robert A. Meyer, and Victor R. Lesser. Multistage negotiation in dis- tributed planning. In Alan H. Bond and Les Gasser, editors, Readings in Distributed Artificial Intelligence, pages 367-384. Morgan Kaufman, 1988. [Corkill and Lesser, 19831 Daniel D. Corkill and Victor R. Lesser. The use of meta-level control for coordination in a distributed problem solving network. In Proceedings of the Eighth International Joint Conference on Artificial Intelligence, pages 748-756, Karlsruhe, Federal Republic of Germany, August 1983. Corkill et al., 1986] Daniel D. Corkill, Kevin Q. Gal- lagher, and Kelly E. Murray. GBB: A generic black- board development system. In Proceedings of the Na- tional Conference on Artificial Intelligence, pages 1008- 1014, Philadelphia, Pennsylvania, August 1986. Davis and Smith, 19831 Randall Davis and Reid G. Smith. Negotiation as a metaphor for distributed prob- lem solving. Artificial Intelligence, pages 63-109, 1983. [Davis, 19811 Randall Davis. A model for planning in a multiagent environment: Steps toward principles for teamwork. AI Working Paper 217, Artificial Intelli- gence Laboratory, Massachusetts Institute of Technol- ogy, Cambridge, Massachusetts 02139, June 1981. [Decker and Lesser, 19891 Keith S. Decker and Victor R. Lesser. Some initial thoughts on a generic architecture for cdps network control. In Proceedings of the 1989 Distributed AI Workshop, pages 73-94, September 1989. [Durfee and Lesser, 19871 Edmund H. Durfee and Vic- tor R. Lesser. Using partial global plans to coordinate distributed problem solvers. In Proceedings of the Tenth International Joint Conference on Artificial Intelligence, pages 875-883, Milan, Italy, August 1987. [Durfee and Montgomery, 19891 Edmund H. Durfee and Thomas A. Montgomery. MICE: A flexible testbed for intelligent coordination experiments. In Proceedings of the 1989 Distributed AI Workshop, pages 25-40, Septem- ber 1989. [Durfee et al., 19871 Ed mund H. Durfee, Victor R. Lesser, and Daniel D. Corkill. Coherent cooperation among communicating problem solvers. IEEE Transactions on Computers, C-36(11):1275-1291, November 1987. [Durfee, 19881 Edmund H. Durfee. Coordination of Dis- tributed Problem Solvers. Kluwer Academic Publishers, 1988. [Lansky, 19851 Amy L. Lansky. Behavioral specification and planning for multiagent domains. Technical Report 360, SRI International, Menlo Park CA, 1985. [Malone, 19871 Thomas W. Malone. Modeling coordina- tion in organizations and markets. Management Science, 33(10):1317-1332, 1987. [Steeb et al., 1986] R. Steeb, S. Cammarata, S. Narain, J. Rothenburg, and W. Giarla. Cooperative intelligence for remotely piloted vehicle fleet control. Technical Re- port R-3408-ARPA, Rand Corporation, October 1986. [Steeb et al., 1988] R. Steeb, S. Cammarata, F. Hayes- Roth, P. Thorndyke, and R. Wesson. Architectures for distributed air-traffic control. In Alan H. Bond and Les Gasser, editors, Readings in Distributed Artificial Intel- ligence, pages 90-101. Morgan Kaufman, 1988. [von Martial, 19891 Frank von Martial. Multiagent plan relationships. In Proceedings of the 1989 Distributed AI Workshop, pages 59-72, September 1989. DURFEE AND MONTGOMERY 93
|
1990
|
2
|
934
|
Incremental, Approzimate Planning Charles Elkan Department of Computer Science University of Toronto* ABSTRACT: This paper shows how using a nonmono- tonic logic to describe the effects of actions enables plau- sible plans to be discovered quickly, and then refined if time permits. Candidate plans are found by allow- ing them to depend on unproved assumptions. The nonmonotonic logic makes explicit which antecedents of rules have the status of default conditions, and they are the only ones that may be left unproved, so only plausible candidate plans are produced. These are re- fined incrementally by trying to justify the assumptions on which they depend. The new planning strategy has been implemented, with good experimental results. 1 Introduction Because of uncertainty and because of the need to re- spond rapidly to events, the traditional view of planning (deriving from STRIPS [Fikes et al., 19721 and culminat- ing in TWEAK [Chapman, 19871) must be revised dras- tically. That much is conventional wisdom nowadays. One point of view is that planning should be replaced by some form of improvisation [Brooks, 19871. How- ever an improvising agent is doomed to choose actions whose optimality is only local. In many domains, goals can only be achieved by forecasting the consequences of actions, and choosing ones whose role in achieving a goal is indirect. Thus traditional planners must be improved, not discarded. This paper addresses the issue of how to design a plan- ner that is incremental and approximate. An approxi- mate planner is one that can find a plausible candidate plan quickly. An incremental planner is one that can revise its preliminary plan if necessary, when allowed more time. It is not clear how existing planning strategies can be made approximate and incremental. We therefore first outline a strategy for finding guaranteed plans using a *For correspondence: Department of Computer Science, Uni- versity of Toronto, Toronto M5S lA4, Canada, (416) 978-7797, cpe@ai. toronto . edu. new formalism for specifying planning problems, and then show how to extend this guaranteed strategy to make it approximate and incremental. Our approach draws inspiration from work on abduc- tive reasoning. A plan is an explanation of how a goal is achievable: a sequence of actions along with a proof that the sequence achieves the goal. An explanation is abductive (as opposed to purely deductive) if it depends on assumptions that are not known to be justified. We find approximate plans by allowing their proofs of cor- rectness to depend on unproved assumptions. Our plan- ner is incremental because, given more time, it refines and if necessary changes a candidate plan by trying to justify the assumptions on which the plan depends. The critical issue in abductive reasoning is to find plausible explanations. Our planning calculus uses a nonmonotonic logic that makes explicit when an an- tecedent of a rule has the epistemological status of a de- fault condition. The distinguishing property of a default condition is that it may plausibly be assumed. These antecedents are those that are allowed to be left un- justified in an approximate plan. Concretely, every de- fault condition in the planning calculus expresses either a claim that an achieved property of the world persists, or that an unwanted property is not achieved. Thus the approximate planning strategy only proposes reasonable candidate plans. Sections 2 and 3 below present the formalism for spec- ifying planning problems and the strategy for finding guaranteed plans. In Section 4 the strategy is extended to become approximate and incremental. Section 5 con- tains experimental results, and finally Section 6 dis- cusses related and future work. 2 The planning formalism Different formal frameworks for stating planning prob- lems vary widely in the complexity of the problems they can express. Using modal logics or reification, one can reason about multiple agents, a.bout the temporal prop- ELKAN 145 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. erties of actions, and about what agents know [Moore, 1985; Konolige, 1986; Cohen and Levesque, 19901. The simplest planning problems can be solved by augmented finite state machines [Brooks et al., 19881, whose be- haviour can be specified in a propositional logic. The planning problems considered here are intermediate in complexity. They cannot be solved by an agent reacting immediately to its environment, because they require maintaining an internal theory of the world, in order to project the indirect consequences of actions. On the other hand, they involve a single agent, and they do not require reasoning about knowledge or time. Our nonmonotonic logic for specifying this type of planning problem is called the PERFLOG calculus.’ Technically, the calculus is the language of locally strat- ified definite clauses with the minimal model semantics of [Przymusiriski, 19871 and certain “laws of nature” presented below. The PERFLOG calculus is distinctive in that it has a well-defined first-order semantics and it is practically usable for planning. Other proposed planning formalisms with a well-defined semantics ei- ther do not have first-order expressiveness (for example the TWEAK calculus [Chapman, 1987]), or else they use logics for which simple proof procedures capable of in- venting plans are not known (for example the circum- scriptive calculus of [Lifschitz and Rabinov, 19891). The Yale shooting problem [Hanks and McDermott, 19861 is at the simple end of the spectrum of planning problems for which the PERFLOG calculus is appropri- ate. It serves here to introduce the calculus by example. We start with the laws of nature mentioned above. In the following rules, think of s as denoting a state of the world, of a as denoting an action, and of do(s, a) a~ de- noting the state resulting from performing the action a in the initial state s. Finally, think of p as denoting a contingent property that holds in certain states of the world: a fluent. ‘da, s, p causes(u, s, p) - holds(p, do(s, a)) VU, s, p holds(p, s) A xuncels(u, s, p) - hodds(p, do(s, a)). (1) (2) The rules (1) and (2) are frame axioms. Rule (1) cap- tures the commonsense notion of causation, and rule (2) expresses the commonsense “law of inertia”: a fluent p holds after an action a if it holds before the action, and the action does not cancel the fluent. Note that since in addition to a, one argument of causes and of cancels is s, the results of an action (that is, the fluents it causes and cancels) may depend on the state in which the ac- tion is performed, and not just on which action it is. 1 PERFLOG is model logic.” an abbreviation for “performance-oriented perfect Given rules (1) and (2)) a particular planning domain is specified by writing axioms that mention the actions and fluents of the domain, and say which actions cause or cancel which fluents. In the world of the Yale shoot- ing problem, there are three fluents, loaded, alive, and dead, and three actions, loud, zuuit, and shoot. The re- lationships of these fluents and actions are specified by the following axioms: Vs cuuses(loud, s, loaded) (3) Vs hobds(douded, s) - cuuses(shoot, s, dead) (4) V’s holds(douded, s) + cuncels(shoot, s, alive) (5) Vs hodds(douded, s) - cuncels(shoot, s, loaded). (6) The initial state of the world SO is specified by saying which fluents are true in it: holds(ulive, so). (7) According to the nonmonotonic collections of rules, semantics of PERFLOG holds(deud, do(do(do(s,-,, loud), wait), shoot)) is entailed by rules (l)-(7). The Yale shooting problem is thus solved. The advantages and disadvantages of the PERFLOG calculus will be discussed in a forthcoming paper. It can be extended to match the expressiveness of compet- ing proposed nonmonotonic logics for reasoning about action. For the purposes of this paper, what is most im- portant is that the calculus is usable for inventing plans, not just for specifying when a plan is correct. Given clauses (l)-( 7) and the query 3p hobds(deud,p)?, the planning strategy of the next section quickly produces the answer substitution p = do(do(z, loud), shoot). (The variable d: in the generated plan indicates that it works whatever the initial situation.) g guaranteed plans The previous section showed how to state the relation- ships between the actions and fluents of a planning do- main as a PERFLOG set of axioms. This section describes a strategy for inventing plans using such a set of axioms; the next section extends the strategy to be approximate and incremental. A PERFLOG set of axioms is general logic program, and our planning strategy is a four-point extension of the standard PROLOG procedure for answering queries against a logic program. Iterative deepening. The standard PROLOG strat- egy can be viewed as depth-first exploration of an and/or tree representing the spa.ce of potential proofs 146 AUTOMATEDREASONING of the query posed by the user. Each or-node corre- sponds to a subgoal2 that must be unified with the head of some clause, and each and-node corresponds to the body of a clause. The root of the tree, always an or- node, is the user’s query. Depth-first exploration can be implemented many times more efficiently than other ex- ploration patterns, but it is liable to get lost on infinite paths. These paths can be cut off by imposing a depth bound. The idea of iterative deepening is to repeatedly explore a search space depth-first, each time with an increased depth bound [Stickel and Tyson, 19851. Conspiracy numbers. Iterative deepening algo- rithms differ in how the depth of a node is defined. The conspiracy idea underlies the best known way of defining depth in and/or trees. A conspiracy for a par- tially explored and/or tree is a minimal (with respect to subsets) set of subgoal leafs such that if all the subgoals in the conspiracy have compatible answer substitutions, then an answer substitution exists for the root goal of the tree. Suppose that for each member of a conspir- acy, whether it has an answer substitution is a statis- tically independent event. Even so, as the conspiracy gets larger, heuristically the chance that all the mem- bers have compatible answer substitutions decreases as if these events were negatively correlated. Thus a good definition of the depth of a leaf node is the size of the smallest conspiracy to which it belongs. Conspiracy sizes can be computed efficiently [Elkan, 19891. Negation-as-failure. The strategy described so far applies to positive subgoals only. Given a negated goal, the negation-as-failure idea is to attempt to prove the un-negated version of the goal. If this attempt suc- ceeds, the negated goal is taken as false. If no proof exists for the un-negated goal, then the negated goal is taken as true. Negation-as-failure is combined with iter- ative deepening by using the conspiracy depth measure to limit searches for proofs of un-negated notional sub- goals corresponding to negated actual subgoals. If the and/or tree representing the space of possible proofs of a notional subgoal is completely explored, without finding a proof, then the corresponding actual negated subgoal is taken as true. If a proof of the notional subgoal is found, then the actual negated subgoal is taken as false. If exploration of the possible proofs of the notional sub- goal is cut off by the current depth bound, it remains unknown whether or not the notional subgoal is prov- able, so for soundness the actual negated subgoal must be taken as false. Freezing and constructive negation. Negation- as-failure only works on ground negated subgoals. Sup- pose the unit clauses p(a) and a(b) are given, and con- sider the query 3~ lp(z) A q(x)?. This query should 2 Here and in si milar contexts, ‘goal’ an answer substitution is wanted. refers to a literal for which have one answer, x = b, but the strategy described so far produces no answer: naive negation-as-failure attempts to prove p(x), succeeds, deems -p(z) to be false, and fails on the whole query. The solution to this problem is to apply negation-as-failure to ground negated sub- goals only. When a negated subgoal is encountered, it is postponed until it becomec ground. Concretely, in the example above l&x:) is delayed, and q(x) is solved, obtaining the substitution x = b. Now lp(z)[x H b] is revived, and proved. This process is called freez- ing [Naish, 19861. If postponement is not sufficient to ground a negated subgoal, then an auxiliary subgoal is introduced to generate potential answers. This process is called constructive negation [Foo et al., 19881. The performance of the planning strategy just de- scribed could be improved significantly, notably by caching subgoals once they are proved or disproved [Elkan, 19891. Nevertheless it is already quite usable. More important as a basis for further work, it is sound and complete. Lemma: The guaranteed planning strategy is sound. Proof: Negation-as-failure is sound under the comple- tion semantics for general logic programs [Clark, 19781. The perfect model semantics allows a subclass of the class of models allowed by the completion semantics. Therefore given a query of the form 3p hoZds(a,p)?, if the strategy above returns with the answer substitution P = X, then hoZds(a, X) is true, and 7r is a correct plan. E Completeness is a more delicate issue. In general, per- fect models may be non-recursively enumerable [Apt and Blair, 19881, and all sufficiently expressive non- monotonic logics have non-computable entailment re- lations. However PERFLOG theories all have a similar structure, using the same three fundamental predicates, so their completion and perfect model semantics essen- tially coincide, and the strategy above is complete. 4 Finding plausible plans This section describes modifications to the strategy of the previous section that make it approximate and in- cremental. In the same way that the guaranteed plan- ning strategy is in fact a general query-answering proce- dure, the incremental planning strategy is really a gen- eral procedure for forming and revising plausible expla- nations using a default theory. Any planning strategy that produces plans relying on unproved assumptions is @so facto unsound, but by its incremental nature the strategy below tends to sound- ness: with more time, candidate plans are either proved to be valid, or changed. Approximation. The idea behind finding approx- imate plans is simple: an explanation is approximate ELKAN 147 if it depends on unproved assumptions. Strategies for forming approximate explanations can be distinguished according to the class of approximate explanations that each may generate. One way to define a class of ap- proximate explanations is to fix a certain class of sub- goals as the only ones that may be taken as assump- tions. Looking at the PERFLOG formalism, there is an obvious choice of what subgoals to allow to be assump- tions. Negated subgoals have the epistemological sta- tus of default conditions: the nonmonotonic semantics makes them true unless they are forced to be false. It is reasonable to assume that a default condition is true unless it it is provably false. There is a second, procedural, reason to allow negated subgoals to be assumed, but not positive subgoals. Without constructive negation, negated subgoals can only be answered true or false. Negation-as-failure never provides an answer substitution for a negated subgoal. Therefore unproved negated subgoals in an explanation never leave “holes” in the answer substitution induced by the explanation. Concretely, a plan whose correct- ness proof depends on unproved default conditions will never change because those defaults are proved to hold. In more detail, the guaranteed planning strategy is modified as follows. When a negated subgoal becomes ground, the proof of its notional positive counterpart is attempted. If this attempt succeeds or fails within the current depth bound, the negated subgoal is taken as false or true, respectively, as before. However, if the depth bound is reached during the attempted proof, then the negated subgoal is given the status of an as- sumption. Incrementality. An approximate explanation can be refined by trying to prove the assumptions it depends on. If an assumption is proved, the explanation thereby becomes “less approximate”. As just mentioned, prov- ing an assumption never causes a plan to change. On the other hand, if an assumption is disproved, the ap- proximate plan is thereby revealed to be invalid, and it is necessary to search for a different plan. Precisely, any negated subgoal is allowed to be as- sumed initially. Each iteration of iterative deepening takes place with an increased depth bound. For each particular (solvable) planning problem, there is a cer- tain minimum depth bound at which one or more ap- proximate plans can first be found. Each of these first approximate plans depends on a certain set of assump- tions. In later iterations, only subsets of these sets are allowed to be assumed. This restriction has the effect of concentrating attention on either refining the already discovered approximate plans, or finding new approxi- mate plans that depend on fewer assumptions. 148 AUTOMATEDREASONING % rules for how the world evolves holds(P,do(S,A)) :- causes(A,S,P). holds(P,do(S,A)) :- holds(P,S), not(cancelsU,S,P)). 3! the effects of actions causes(pounce(lion,X) ,S,eats(lion,X)) :- can(pounce(lion,X) ,S). can(pounce(X,Y) ,S) :- holds(in(X,L) ,S) , holds(in(Y ,L) ,S) , not(call(X = Y)), not(Z,holds(eats(X,Z) ,S)). causes(jump(X) ,S,in(X,arena>) :- can(jump(X) ,S), holds(in(X,cage) ,S>. cau(jump(lion),S) :- holds(eats(lion,centurion),S). cancels(drop(X,Y),S,eats(X,Y)I :- cauUrop(X,Y),S). can(drop(X,Y),S) :- holds(eats(X,Y),S). holds(in(X,H),S) :- holds(eats(lion,X) ,S), holds(in(lion,H),S). % the initial state of the world holds(in(christiau,aena),sO). holds(in(lion,cage) ,sO) . holds(in(centurion,cage),sO). Figure 1: The theory of a lion and a Christian. 5 Experimental results Implementing the planning strategies described above is straightforward, because the PERFLOG calculus is based on directed clauses. In general, it is insufficiently real- ized how efficiently logics with this basis, both mono- tonic and nonmonotonic, can be automated. The state of the art in PROLOG implementation is about nine RISC cycles per logical inference [Mills, 19891. Any PERFLOG theory could be compiled into a specialized incremental planner running at a comparable speed. The experiment reported here uses a classical plan- ning domain: a lion and a Christian in a stadium. The goal is for the lion to eat the Christian. Initially the lion is in its cage with a centurion, and the Christian is in the arena. The lion can jump from the cage into the arena only if it has eaten the centurion. The lion eats a person by pouncing, but it cannot pounce while it is already eating. The PERFLOG theory in Figure 1 describes this domain formally. Using the guaranteed planning strategy of Sec- tion 3, the query holds(eats(lion,christian),P)? is first solved with conspiracy depth bound 19, in 4.75 seconds.3 The plan found is P = do(do(do(do(sO,pounce(lion,centurion)), jump(lion)), drop(lion,centu.rion)), pounce(lion,cbristian)). Using the approximate planning strategy of Section 4, the same query is solvable in 0.17 seconds, with conspir- acy depth bound 17. The candidate plan found is P = do(do(do(sO,pounce(lion,centurion)), jump(lion)), pounce(lion,christian)). This plan depends on the assumption that no Z exists such that holds(eats(lion,Z),do(do(sO,pounce(lion,cent~ion)), jump(lion))). Although the assumption is false and the plan is not cor- rect, it is plausible. Note also that the first two actions it prescribes are the same as those of the correct plan: the approximate plan is an excellent guide to immediate action. 6 Discussion The strategy for incremental, approximate planning uses simplifying assumptions in a principled way: first the planner searches for a plan assuming that default conditions hold, then it attempts to prove that they do hold. The idea of relying on assumptions that are left unproven appears in [Feldman and Rich, 19861 and else- where. This paper shows how a formal nonmonotonic logic determines reasonable potential assumptions, and how iterative deepening can be used to modulate the ef- fort expended on checking these assumptions. The point that default theories suggest how to focus inference is made independently in [Ginsberg, 19901. To accommo- date arbitrary sources of knowledge about plausible as- sumptions, our implementation allows the user to say explicitly what must always be proved, and what may sometimes be left unproved, as in [Chien, 19891. From a knowledge-level point of view, approximate planning is a type of hierarchical planning. Each max- imum conspiracy size defines a different abstraction space in which to search for plans. In each space the 3All times are for an implementation in CProlog, a Silicon Graphics machine rated at 20 MIPS. running on available actions and their effects are the same. Bow- ever, the lower the maximum conspiracy size, the more each action is stripped of its difficult-to-check precondi- tions. Abstraction spaces defined in this way have the advantage that the execution of any plan invented using them can be initiated immediately if it is necessary to act instantly. Other hierarchical planners typically con- struct plans using abstract actions that must be elabo- rated before they can be executed [Knoblock, 19891. Selecting good simplifying assumptions is a type of abductive inference. Abduction mechanisms have been investigated a great deal for the task of plan recognition, not so much for the task of inventing plans, and not at all for the task of inventing plausible plans. These three different tasks lead to different choices of what facts may be assumed. In the work of [Shanahan, 19891 for example, properties of the initial state of the world may be assumed. In our work, the facts that may be assumed say either that an established property of the world persists, or that an unestablished property does not hold. An incremental approximate planner is an “anytime algorithm” for planning in the sense of [Dean and Boddy, 19881. Anytime planning algorithms have been proposed before, but not for problems of the tradi- tional type treated in this paper. For example, the real- time route planner of [Korf, I.9871 is a heuristic graph search algorithm, and the route improvement algorithm of [Boddy and Dean, 19891 relies on an initial plan that is guaranteed to be correct. For future work, one important direction is to quan- tify how an approximate plan is improved by allowing more time for its refinement. Another problem is to find a planning strategy that is focused as well as approxi- mate and incremental. A focused strategy would be one that concentrated preferentially on finding the first step in a plan-what to do next. References [Apt and Blair, 19881 Krzysztof R. Apt and Howard A. Blair. Arithmetic classification of perfect models of strat- ified programs. In Kenneth Bowen and Robert Kowalski, editors, Fifth International Conference and Symposium on Logic Programming, volume 2, pages 765-779, Seat- tle, Washington, August 1988. MIT Press. [Boddy and Dean, 19891 Mark Boddy and Thomas Dean. Solving time-dependent planning problems. In Proceed- ings of the Eleventh International Joint Conference on Artificial Intelligence, pages 979-984, August 1989. [Brooks et aZ., 19881 Rodney A. Brooks, Jonathan H. Con- nell, and Peter Ning. Herbert: A second generation mobile robot. MIT AI Memo 1016, January 1988. ELKAN 149 [Brooks, 19871 Rodney A. Brooks. Planning is just a way of avoiding figuring out what to do next. Technical Report 303, Artificial Intelligence Laboratory, MIT, September 1987. [Chapman, 19871 David Chapman. Planning for conjunctive gods. Artijicial Intelligence, 32:333-377, 1987. [Chien, 19891 Steve A. Chien. Using and refining simplifica- tions: Explanation-based learning of plans in intractable domains. In Proceedings of the Eleventh International Joint Conference on Artificial Intelligence, pages 590-595, 1989. [Clark, 19781 K enneth. L. Clark. Negation as failure. In Herve Gallaire and Jack Minker, editors, Logic and Databases, pages 293-322. Plenum Press, New York, 1978. [Cohen and Levesque, 19901 Philip R. Cohen and Hector J. Levesque. Intention is choice with commitment. Artificial Intelligence, 42(2-3):213-261, 1990. [Dean and Boddy, 19881 Thomas Dean and Mark Boddy. An analysis of time-dependent planning. In Proceedings of the National Conference on Artificial Intelligence, pages 49-54, August 1988. [Elkan, 19891 Charles Elkan. Conspiracy numbers and caching for searching and/or trees and theorem-proving. In Proceedings of the Eleventh International Joint Con- ference on Artificial Intelligence, pages 341-346, August 1989. [Feldman and Rich, 19861 Yishai A. Feldman and Charles Rich. Reasoning with simplifying assumptions: A methodology and example. In Proceedings of the National Conference on Artificial Intelligence, pages 2-7, August 1986. [Fikes et al., 19721 Richard E. Fikes, Peter E. Hart, and Nils J. Nilsson. Learning and executing generalized robot plans. Artificial Intelligence, 3:251-288, 1972. [Foo et al., 19881 N orman Y. Foo, Anand S. Rao, Andrew Taylor, and Adrian Walker. Deduced relevant types and constructive negation. In Kenneth Bowen and Robert Kowalski, editors, Fifth International Conference and Symposiztm on Logic Programming, volume 1, pages 126- 139, Seattle, Washington, August 1988. MIT Press. [Ginsberg, 19901 Matthew L. Ginsberg. Defaults and hier- archical problem solving. In Preprints of the Third In- ternational Workshop on Nonmonotonic Reasoning, Lake Tahoe, May/ June 1990. [Hanks and McDermott, 19861 Steve Hanks and Drew Mc- Dermott. Default reasoning, nonmonotonic logics, and the frame problem. In Proceedings of the National Confemnce on Artificial Intelligence, pages 328-333, August 1986. [Knoblock, 19891 Craig A. Knoblock. Learning hierarchies of abstraction spaces. In Proceedings of the Sixth Inter- national Workshop on Machine Learning, pages 241-245. Morgan Kaufmann Publishers, Inc., 1989. [Konolige, 1986] Kurt Konolige. A Deduction Model of Be- lief. Pitman, 1986. [Korf, 19871 Richard E. Korf. Real-time path planning. In Proceedings of the DARPA Knowledge-Based Planning Workshop, 1987. [Lifschitz and Rabinov, 19891 Vladimir Lifschitz and Arkady Rabinov. Things that change by themselves. In Proceedings of the Eleventh International Joint Confer- ence on Artificial Intelligence, pages 864-867, 1989. [Mills, 19891 J onathan W. Mills. A pipelined architecture for logic programming with a complex but single-cycle instruction set. In Proceedings of the IEEE First Interna- tional Tools for AI Workshop, September 1989. [Moore, 19851 Robert C. Moore. A formal theory of knowl- edge and action. In Formal Theories of the Commonsense World. Ablex, 1985. [Naish, 19861 Lee Naish. Negation and Control in PRO- LOG. Number 238 in Lecture Notes in Computer Science. Springer Verlag, 1986. [Przymusifiski, 19871 Teodor C. Przymusiuski. On the declarative semantics of stratified deductive databases and logic programs. In Jack Minker, editor, Foundations of Deductive Databases and Logic Programming, pages 193-216, Los Altos, California, 1987. Morgan Kaufmann Publishers, Inc. [Shanahan, 19891 Murray Shanahan. Prediction is deduc- tion but explanation is abduction. In Proceedings of the Eleventh International Joint Conference on Artificial In- telligence, pages 1055-1060, 1989. [Stickel and Tyson, 19851 Mark E. Stickel and W. M. Tyson. An analysis of consecutively bounded depth-first search with applications in automated deduction. In Pro- ceedings of the Ninth International Joint Confemnce on Artificial Intelligence, pages 1073-1075, August 1985. 150 AUTOMATEDREASONING
|
1990
|
20
|
935
|
Admissible Criteria Roy Feldman and Paul Morris IntelliCorp 1975 El Camino Real West Mountain View, CA 94040 feldman@intellicorp.com morris@intellicorp.com Abstract We introduce methods for identifying operator preconditions that need not be expanded further. The methods are proved to be admissible , that is, they will not cause a solution to be missed when one exists. In certain cases, the methods also identify operator reformulations that increase the number of nonexpandable preconditions. This ap- proach provides effective loop control in common situations. Moreover, the computation required can be performed during a precompilation of the operators in a domain; thus, there is no significant additional run-time overhead during planning. Introduction A major challenge facing the builder of a generative planner is to prevent undesired looping behavior. This is most clearly seen in “vicious circle” situations. For example, a planner, given the problem of opening a car door when the keys are locked in the car, may loop indefinitely in trying to find a solution. A more subtle form of the syndrome can occur during backtracking search. In these situations, time is wasted in consid- ering partial solutions that involve unnecessary digres- sions For example, a planner may consider going from one place to another by irrelevant circuitous routes. Missing a solution due to infinite looping can be avoided by a breadth-first search, such as used by Tweak [Chapman 19871. However, this kind of search is impractical for many types of problems, and in any event the efficiency issue remains. Clearly, a planner needs some way of determining when a subgoal should not be expanded further. The danger of any pruning criterion, however, is that for some problems it may prevent any solution from being found, even when a solution exists. What is needed is a guarantee that the criterion allows at least one This research was sponsored by a joint project of the Defense Advanced Research Projects Agency and the Na- tional Aeronautics and Space Administration under con- tract l?30602-88-C-0045. solution to be found for every solvable problem. A pruning strategy with this property is called admissible by Drummond and Currie [Drummond & Currie 19891. Similar difficulties with looping can arise in backward-chaining inference systems. Smith, et al. [Smith, Genesereth & Ginsberg 1986] show that the common idea of failing a subgoal that is identi- cal to one of its ancestors is an admissible strategy for inference systems. A similar approach has been used for loop control in planning (e.g., [Rich 1983, p. 2581). Unfortunately, as shown below, this strategy is not admissible for planning systems. Nonlinear plan- ning can be formulated as an inference task via Chap- man’s modal truth criterion [Chapman 19871. How- ever, failing repetitive subgoals in the inferential prob- lem appears to have little practical significance for the planning problem. An alternative approach to loop control in planning was introduced by Tate [Tate 1976; Tate 19771. In his NONLIN system, certain preconditions of opera- tors are designated as hold conditions (called usewhen conditions in [Tate 19771). Hold conditions are not al- lowed to be expanded. The difficulty here is that the user is required to specify these, and no guidance is provided for selecting them. If the user’s intuition is faulty, the strategy will be inadmissible. Furthermore, as we will see presently, for some ways of specifying the operators in a domain, there may not be any admissible hold conditions that provide adequate loop control. Nevertheless, the concept of a nonexpandable pre- condition will form the basis of our approach. We will present a way of determining when a precondition may admissibly be made nonexpandable. Moreover, the method automatically reformulates the operators in certain cases in order to increase the number of such determinations. In following sections, we first show the inadmissibil- ity in planning of failing subgoals that are identical to an ancestor. Then we present a formalization of plan graphs that serves as a framework for our approach. Next we introduce a structure called the predecessor graph that provides information about allowable oper- ator sequences of length 2. Finally, we show how to use FELDMAN AND MORRIS 15 1 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. this graph to identify admissibly nonexpandable pre- conditions. The proofs are contained in the appendix. Robot Recharging Problem In this section, we present an example that resists ex- isting methods of loop control. In particular, it shows the inadmissibility of failing a goal that is identical to an ancestor. The operator representation we will give for the problem, although a natural one, is also not amenable to control with hold conditions. We will see later that successful loop control requires a reformula- tion of one of the operators. The example, called the “robot recharging problem,” was first described in [Morris 19841. A robot is capable of holding a unit of charge. As long as it is charged, the robot may move around. We assume that moving uses a negligible amount of energy. The robot also needs to fix a hole in its body. We assume this uses up all its energy, so that the robot becomes discharged. The robot is initially at location A. There is a power source at location B where the robot can recharge. The goals of the robot are to fix the hole and be charged. The following is the STRIPS representation of the domain. FIX Preconditions and delete conditions: CHARGED,HOLE Add conditions: UNCHARGED, NO-HOLE RECHARGE Preconditions: AT(B), UNCHARGED Delete condition: UNCHARGED Add condition: CHARGED GO Preconditions: CHARGED, AT(?X) Delete condition: AT(?X) Add condition: AT (?Y) Initial state: AT(A), CHARGED, HOLE Goals: CHARGED,NO-HOLE Obviously, the robot must first go to location B. Only then can it perform its task and still be able to recharge. However, if we examine the structure of this plan, we see that AT(B) is a subgoal of CHARGED. When AT(B) is expanded by a Go action, this intro- duces a further subgoal of CHARGED, which is identical to the ancestor goal. Note that if we fail this subgoal, the problem will not be solved. (It may be helpful to refer to figure 1 below.) If we use no loop control method, the problem can be solved. Consider, however, the closely related problem where the robot is uncharged in the initial state. This has no solution. Without some loop control criterion, a planner faced with this problem will loop endlessly. The challenge is to find some method that cuts off the search in the second situation, but not in the first. The most obvious candidates for hold conditions are the UNCHARGED precondition in RECHARGE, the AT(?X) in GO, and the HOLE in FIX. Unfortunately, these are not sufficient to terminate looping in the sec- ond situation, since there is a cycle through the AT(B) precondition of RECHARGE and the CHARGED precon- dition of GO. Intuitively, it seems as if the AT(B) in RECHARGE might be a hold condition. However, we saw above that constructing the plan in the first situ- ation requires AT(B) to be expanded. Notice that the need for the GO action indirectly re- sults from the presence of the NO-HOLE goal, but this is not reflected in the goal ancestor path. Interest- ingly, the methods we will consider have the effect of reformulating the operators in a way that diverts the ancestor path to this goal. Plan Graphs We use the general framework of nonlinear planning in- troduced by Sacerdoti [Sacerdoti 19771 and Tate [Tate 19771. Planning proceeds in stages. At each stage, a goal is selected to work on. The planner satisfies the goal either by matching it to an already achieved fact, or by introducing a new action into the plan. In the former case, we say the goal is linked to the matching fact. In the latter case, we say the goal is expanded. The possible actions are determined by a set of STRIPS operators [Nilsson 19801. However, we require that the operators be formulated so that they are never applied in situations where one of their delete condi- tions is already false, or where one of their add condi- tions is already true; i.e., none of the adds or deletes are no-ops. This is not a severe restriction. First, op- erators that are constructed in practice generally have this property. Second, an operator that does not can always be replaced by several more specialized oper- ators that do satisfy the restriction. We also require that the operators be formulated to avoid the need for coincident solutions, that is, where two preconditions, or two add conditions, of the same operator become instantiated in such a way that they coincide. Again, this can be accomplished by using more specialized op- erators, if necessary. We associate each action with two sets of facts: the before-facts, consisting of the delete conditions and un- deleted preconditions; and the after-facts, comprised of the add conditions and undeleted preconditions. This division may be viewed as a relational production [Vere 19771 representation of the action. A plan graph is a graphical representation of a plan that shows how the after-facts of various actions con- tribute to the before-facts of other actions. Formally, a plan graph is a directed acyclic multigraph where the nodes are labeled with actions, and the edges are labeled with facts. The labeling on an edge connect- ing two actions must belong to the after-facts of the first action and the before-facts of the second. There is also a distinguished START action whose after-facts 152 AUTOMATEDREASONING Figure 1: Plan Graph For Robot Problem supply the initial facts for the plan, and a STOP action whose before-facts include the atomic top-level goals. Figure 1 shows the plan graph for a solution t; the robot problem. For linguistic convenience, we blur the distinction between a node and the action it is labeled with. For example, we may speak of the “before-facts” of a node, and the “incoming edges” of an action. The following concepts will be useful in the subse- quent discussion. Note that every directed acyclic multigraph deter- mines a partial order on its nodes and edges. Given a plan graph, we say a node or edge precedes another node or edge if it precedes it in this partial order. Fur- t hermore, we say a node or edge is parallel node or edge if neither precedes the other. to a second A plan graph is complete if the before-facts of each action in the plan are supplied by after-facts of other actions, i.e., if the incoming edges to each action cover - - all of the before-facts. This corresponds to a situation where there are no remaining unsolved goals. Unless otherwise stated, in the remainder of this paper we will assume plan graphs are complete. Also, unless other- wise clear from the context, we restrict our attention to plan graphs that are conflict-free in the following sense: no edge is parallel to an action that deletes the fact that the edge is labeled with. This is closely re- lated to the usual concept of plan conflict (e.g., [Tate 19761). It is never necessary for two incoming edges to an action to be labeled with the same fact, since we can simply drop one of the edges without affecting the com- pleteness of the plan. Expressed in terms of planning, a goal is satisfied by linking to a single matching fact. However, traditional approaches to planning allow a fact to satisfy more than one goal. Thus, it is possible for two outgoing edges from an action to be labeled with the same fact. We will call this a collision. The following result indicates that collisions are not essen- tial, and-could be excluded without seriously impairing a planner. Theorem 1 For every conflict-free plan graph, there is a collision-free plan graph with the same actions that solves the same problem. In light of theorem 1, we assume from now on that the plan graphs are collision-free. This restriction turns out to be very useful for proving results about plan graphs. Note that the theorem shows it is admissible to adopt an approach to planning where a fact that is linked to a goal is “used up” by the goal, i.e., becomes unavailable for linking by another goal. In the case where the consuming goal corresponds to a precondi- tion of an action that remains true after the action, the fact is “put back” as a postcondition of the action. This approach to planning has been studied in [Morris 19841. We now introduce a notion that is related to the concept of primary cut introduced by Drummond and Currie [Drummond & Currie 19891. We will say a set of edges is parallel if every edge in the set is parallel to every other edge in the set. A cut of a plan graph is a maximal parallel set of edges, i.e., a parallel set of edges that is not a subset of any other parallel set of edges. The following theorem (actually, its corollary) is cen- tral to reasoning about plan graphs. Theorem 2 For every cut, there is a reachable state of the domain that contains each fact in the labeling of the cut. Moreover, no two edges in the cut are labeled with the same fact. Corollary 2.1 Edges that are parallel cannot have the same label or contradictory labels. A node cannot be parallel to an edge whose label coincides with or con- flicts with one of its before-facts or after-facts. To apply the corollary, we need to reason about inconsistencies. In principle, any domain constraints could be used for this purpose. However, we have found the most useful constraints to be exclusive-or re- lationships. Inconsistencies based on such constraints can be efficiently determined. In [Morris & Feldman 19891, a method is presented for automatically extract- ing candidate exclusive-or relationships from operator descriptions. The Predecessor Graph Obviously, not every combination of actions is possible or useful. We now address the question of what actions can appear next to each other in a plan graph. Given a plan graph, we will say a node A is an im- mediate predecessor of a node B if A precedes B, and there is no other node C such that A precedes C and C precedes B. We are interested in necessary conditions for a node to be an immediate predecessor. It is easy to see that if A is an immediate predecessor of B, then some outgoing edge of A must be an incom- ing edge of B. (The converse is not necessarily true: A could be connected by an edge to B without being an immediate predecessor, since there may be a second route from A to B.) Corollary 2.1 provides additional requirements. Note that the after-facts of A must be FELDMANANDMORRIS 153 RCHRG FIX c Figure 2: Predecessor Graph For Robot Problem consistent with the before-facts of B; otherwise, we would have parallel contradictory edges. This requirement allows us to completely rule out certain combinations of operators. For example in the robot recharging problem, no instance of GO can be an immediate predecessor of RECHARGE because the CHARGED precondition of the former conflicts with the UNCHARGED precondition of the latter. Simi- larly, FIX cannot immediately precede GO or itself, and RECHARGE cannot immediately precede itself. Certain other combinations, although not impossi- ble, can be ruled out as not being sensible. Suppose, for example, an action A is immediately preceded by its exact inverse B. Since the actions are inverses, there is an exact match between the after-facts of B and the before-facts of A. Corollary 2.1 then implies that ev- ery outgoing edge of A must be an incoming edge of B and vice versa; otherwise we would have parallel edges with the same label. It follows that the plan graph could be simplified by excising the portion from A to B and directly joining the resulting dangling edges. There are no inverses in the robot problem. How- ever, a further example of a non-sensible situation oc- curs when a two operator combination is subsumed by a single operator. Suppose in the robot problem that GO is immediately preceded by itself. The bind- ing of ?Y in the earlier instance of GO must match the binding of ?X in the other; otherwise the consistency requirement is violated. But then the after-facts of the earlier instance coincide with the before-facts of the other, and all the edges from the former must con- nect to the latter. It follows that the portion of the plan graph containing the two GOs can be replaced by a single GO. Thus, we can assume that GO does not immediately precede itself. After using the techniques above to eliminate vari- ous combinations, we are left with a set of combina- tions that have not been ruled out. We can form a graph of the operators that reflects these. We call this the predecessor graph. Figure 2 shows the predecessor graph for the robot problem. The predecessor graph can often be annotated with constraints on bindings that arise from the immediate predecessor relationship. For example, if G 0 is im- mediately preceded by RECHARGE, then uniqueness of location requires that the variable ?x in GO be bound to B. The above uses consistency analysis to rule out po- tential operator combinations in forming the predeces- sor graph. Other applications of consistency analysis in planning appear in the work of Irani and Chen [Irani & Cheng 19871, and Drummond and Currie f Drum- mond & Currie 19891. Loop Control We now consider how to use the predecessor graph to determine nonexpandable preconditions. The method is based on results in this section. We define a plan graph to be minimal if it con- tains no unnecessary actions, i.e., there is no other plan graph that solves the same problem with a proper sub- set of the actions. To prove admissibility of a pruning criterion, it is enough to show that every minimal plan graph can be constructed within the bounds of the cri- terion. The following concept will also be useful. We say an operator A is guarded by one of its preconditions G if, for every minimal plan graph in which A occurs, the before-fact of A corresponding to G is an after-fact or a before-fact of every immediate predecessor of A. Our first theorem on loop control involves a special case of A being guarded by G. Theorem 3 It is admissible not to expand a precon- dition G of an operator A if for every minimal plan graph in which A occurs, the before-fact of A corre- sponding to G is a before-fact of every immediate pre- decessor of A. Intuitively, theorem 3 is used to make a operator precondition nonexpandable by way of deferral. If a precondition G meets the conditions of the theorem, it means that the expansion of any of the sibling precon- ditions of G are guaranteed to introduce a precondition identical to G. Thus, G can be expanded later. Our next result presents an alternative means of determin- ing nonexpandability. Theorem 4 It is admissible not to expand a deleted precondition G of an operator A if A is guarded by G and, for every minimal plan graph in which A appears, the facts added by A are contained in the before-facts of every immediate predecessor of A. Moreover, this criterion and that of theorem 3 are simultaneously admissible. The proof of theorem 4 is based on showing the ex- pansion of the precondition is unnecessary because ei- ther some other goal can be expanded to introduce the same action, or any possible expansion will produce a non-minimal plan graph. The following examples show how these theorems may be used. Our first example is a formalization of the car keys problem. We have the following operator descriptions. 154 AUTOMATEDREASONING OPEN-CAR-DOOR Preconditions: DOOR-CLOSED, HAVE-KEYS Delete condition: DOOR-CLOSED Add condition: DOOR-OPEN GET-KEYS-FROM-CAR Preconditions: KEYS-IN-CAR, DOOR-OPEN Delete condition: KEYS-IN-CAR Add condition: HAVE-KEYS In this example, consistency analysis shows that nei- ther operator can have any immediate predecessor, i.e., all operator sequences of length 2 are impossible. Thus, every precondition can admissibly be made non- expandable. This gives us the loop control we need. Our next example is the robot problem. Consider the AT(?X) precondition of GO. The only immediate predecessor of GO is RECHARGE, which has AT(B) as a precondition. We noted earlier that when GO is im- mediately preceded by RECHARGE the ?X in GO must be bound to B. Thus, the precondition is also a pre- condition of every possible immediate predecessor. We conclude by theorem 3 that AT(?X) is admissibly non- expandable for this domain. Also, consider the UNCHARGED precondition of RECHARGE. The only immediate predecessor is FIX. Thus, UNCHARGED guards RECHARGED. Note that the only fact added by RECHARGE is CHARGED. This is among the preconditions of FIX. Moreover, UN- CHARGED is deleted by RECHARGE. Thus, by theorem 4, it is a nonexpandable precondition. We would like to make the AT(B) precondition of RECHARGE nonexpandable. However, as things stand the method does not apply, since the immediate pre- decessor, FIX, does not have AT(?X) as a precondition. Indeed, we noted earlier that with this operator rep- resentation, AT(B) needs to be expanded to solve the robot problem. Observe, however, that if we include AT(?X) as an additional precondition in the FIX operator, then the criterion of the theorem is satisfied, and AT(B) can be made a nonexpandable precondition of RECHARGE. Moreover, it is admissible to augment the FIX operator in this way, since every state must satisfy some instance of AT(?x). The reason why the robot problem is now solvable is that the AT(?X) precondition of FIX can be expanded instead. Note that we have shifted the goal ancestor path for the expansion of AT(?X) so that it now leads to the NO-HOLE top-level goal. Intuitively, Figure 3: Reformulated Plan Graph available, the fact and its negation can be used.) Note that consistency requirements ensure that of the re- placement operators, only the one corresponding to the precondition is an immediate predecessor. It is easy to see that the modification procedure can be applied to make any precondition nonexpandable provided that no immediate predecessor has the pre- condition as an add condition. Observe that all the preconditions of RECHARGE are now nonexpandable. It can be verified that every po- tential loop in the robot problem passes through the RECHARGE operator. Thus, no loops remain. It is important to note that the methods provide only sufficient conditions for admissible nonexpandability, and it is not true in general that they will prevent all loops. We can think of theorem 3 as eliminating goal repetitions where a goal is an immediate subgoal of it- self. Theorem 4 applies to goals that repeat after two steps. Slightly larger repetition intervals can be han- died by combining operators as necessary to reduce the repetition distance. However, in the blocks world, for example, there can be repetitions with an indefi- nite number of intervening goals, and neither theorem applies in this case. Nevertheless, the results here ap- pear to cover many of the intuitive examples of hold conditions. Closing Remarks One of the features which distinguishes modern work in AI from that of earlier periods is an increasing con- tern for rigorous analysis and deeper understanding of the techniques studied. Previous loop control methods in planning may be classified as engineering art. In- deed, loop control is an important, but neglected issue in generative planning. We have presented provably correct methods that are effective in common situa- the problem with the original representation was that the expansions were not correctly motivated. Figure 3 tions. An important observation that follows from the shows the reformulated plan graph for this problem. results in this paper is that operator descriptions may need to be reformulated in order to facilitate control. This technique of modifying the operators can be The methods of the paper can be used to identify useful made systematic. In general, we may need to replace reformulations. the immediate predecessor operator with several oper- A system that identifies nonexpandable precondi- ators that are augmented with the different members tions based on the theorems in the paper has been of some exclusive-or set that includes the precondition successfully implemented. Our present implementa- under consideration. (If no better exclusive-or set is tion uses a full theorem prover (the Boyer-Moore the- FELDMANANDMORRIS 155 orem prover [Boyer & Moore 19791) to reason about inconsistency, which limits its applicability. However, in practice, less costly reasoning about exclusive-or re- lationships should be sufficient. Note also that the rea- soning is performed during a precompilation of the op- erators in a domain, so the cost is amortized over all problem-solving in that domain. Nonexpandability is only part of the content of the hold condition idea of Tate; the other part is a deter- mination that linking need not be delayed until side effects of other operators are available. This property is called eflective isolation in [Morris 19841. The prede- cessor graph may also be useful for determinations of effective isolation, and current work is exploring this. Acknowledgment We thank Bob gestions to improve the presentation. Filman for sug- Appendix: Proofs Theorem 1: For every conflict-free plan graph, there is a collision-free plan graph with the same actions that solves the same problem. Proof: Suppose an action has two outgoing edges labeled with the same fact F. If the two edges are re- ceived by a single action, then one edge is redundant and can be removed. Otherwise, the edges must be received by different actions. At least one of these, say A, is not preceded by the other, B. If the plan is conflict-free, then the receiving action A cannot delete the fact F, since it is parallel to the edge that goes to B. Thus, F must also occur as an after-fact of A. Now the original F-labeled edge to B can be replaced by an edge from A to B. If there is already an outgo- ing edge from A labeled with F, then the above process can be repeated. Note that each repetition moves the collision closer to the STOP node. Ultimately, either it disappears, or a redundancy occurs among the incom- ing edges to the STOP node and can be removed. Theorem 2: For every cut, there is a reachable state of the domain that contains each fact in the la- beling of the cut. Moreover, no two edges in the cut are labeled with the same fact. Proof: We say a node precedes a cut if it precedes some edge in the cut. The theorem will be proved by induction on the number of nodes that precede a cut. Note that the outgoing edges from the START node constitute a cut that is preceded only by the START node itself. We call this the initial cut. Clearly, the result holds for the initial cut. Now consider some other cut. Let A be a node pre- ceding the cut that is maximally close to the cut, i.e., A does not precede any other node that precedes the cut. Let e be any outgoing edge of A. We show e must belong to the cut. Suppose otherwise. Then e cannot precede any edge in the cut; otherwise there would be another node between A and the cut. Also, e cannot be preceded by any edge in the cut. If it did, then A could not precede the cut. Thus, e is parallel to every edge in the cut. But this contradicts the definition of a cut, which requires it to be a maximal parallel set of edges. We have shown that every outgoing edge of A be- longs to the cut. Let us call this cut C. Now consider the set of edges obtained from C by replacing the out- going edges of A with its incoming edges. It is not hard to verify that this is also a cut, which we will call C’. By the inductive hypothesis, the labels of edges in C’ are free of duplicates, and are contained in some reach- able state. The preconditions of A are satisfied in that state. Thus, the state resulting from applying A is also reachable. This state contains the facts corresponding to edges in C. This proves the first part of the result. Note that the only way that applying A could pro- duce a duplicate edge (we are assuming no collisions among the outgoing edges of A) would be if one of its outgoing edges had the same label as an edge common to the two cuts. But then A would be applicable in a situation where one of its add conditions is already true, contrary to our restriction on operators. This shows the second part of the result. Corollary 2.1: Edges that are parallel cannot have the same label or contradictory labels. A node cannot be parallel to an edge whose label coincides with or conflicts with one of its before-facts or after-facts. ProofiIf two edges are parallel, then there is some cut that contains them both. By the theorem, the cut has no duplicate labels. Furthermore, the labels are contained in some reachable state, so they cannot be contradictory. Now suppose a node A is parallel to an edge e. It is easy to see that the incoming and outgoing edges of A must also be parallel to e. Thus, the only case we need to consider is that of an unused after-fact. Note that the plan graph can be modified to include the after- fact as a top level goal without changing any of the labels. Then, the previous reasoning can be applied to the after-fact. The result follows. Lemma 1 Suppose A is guarded by a precondition G. Consider some minimal plan graph in which A occurs. Let e be the incoming edge to A that corresponds to G, and let B be the node of which e is an outgoing edge. Then B is an immediate predecessor of A, and is the only immediate predecessor of A in the plan graph. Proof: Clearly, B is a predecessor of A. Suppose there is some other node C that is an immediate prede- cessor of A. Then C has either an afler-fact or a before- fact that matches the label of e. Clearly, e is parallel to C, leading to a violation of corollary 2.1. Thus, there cannot be any other immediate predecessor. It follows that B must be the immediate predecessor of A. Theorem 3: It is admissible not to expand a pre- condition G of an operator A if, for every minimal plan graph in which A occurs, the before-fact of A cor- responding to G is a before-fact of every immediate predecessor of A. 156 AUTOMATEDREASONING Proof: Consider a minimal plan graph in which A occurs. There must be some incoming edge e of A that corresponds to G. Suppose the edge e comes from another node B. By the statement of the theorem, A is guarded by G. Hence, by lemma 1, B must be an immediate predecessor of A. By hypothesis, B has a before-fact that coincides with the label of e, and so e does not correspond to an add condition of B. It follows that during planning, B could not have been introduced into the plan as an expansion of G, i.e., it must have resulted from the expansion of some other goal (or be the START node). Thus, it is safe to make G nonexpandable. Theorem 4: It is admissible not to expand a deleted precondition G of an operator A if A is guarded by G and, for every minimal plan graph in which A appears, the facts added by A are contained in the before-facts of every immediate predecessor of A. Moreover, this criterion and that of theorem 3 are simultaneously admissible. Proof: In the following, We use the term add-fact to describe an after-fact that corresponds to an add condition. Similarly, delete-fact is a before-fact that corresponds to a delete condition. Consider any minimal plan graph in which a node B occurs. Let I be the set of outgoing edges of B that correspond to add-facts of B, and let A be the set of nodes that receive the edges in 1. Each edge e in C corresponds to a precondition G of some node A in A. We claim that at least one such G is not made nonexpandable by the criterion of the theorem. Assume otherwise. We will show that this leads to a contradiction. We note here that the assumption implies that every edge from an add-fact of B leads to a delete-fact of the connected node. We proceed by showing all the outgoing edges of the nodes in the set A U {B} (other than internal edges) can be replaced by equivalent incoming edges. This will allow all the nodes in the set to be excised, con- tradicting the minimality of the plan graph. By lemma 1, B is an immediate predecessor of each node in d. It follows that the edges being considered for replacement are all parallel to each other. By corol- lary 2.1, their labels are all different. Thus, there is no danger of two outgoing edges competing for a replace- ment among the incoming edges, so it is sufficient to show that the edges can be replaced individually. There are three cases to be considered: outgoing edges of (nodes in) A that correspond to add-facts; other outgoing edges of d; and outgoing edges of B that do not go to d. If e corresponds to an add-fact of some A in A, then by the condition of the theorem, it can be replaced by an equivalent incoming edge e’ to B. If e is an outgoing edge of some A, but does not correspond to an add-fact, then there must be an in- coming edge e’ of A that has the same label. If e’ is not an internal edge, then e can simply be replaced by e’. Otherwise, e’ is an outgoing edge of B. Since its label is not a delete-fact of A, it is not an add-fact of B (by the assumption; see above). Thus, there must be an incoming edge e” of B with the same label as e’. In this case e can be replaced by e”. If e is an outgoing edge of B that does not go to some A, then it is not in E. It follows that it is not an add-fact of B. Thus, there is some incoming edge e’ of B with the same label, and we can replace e with e’. This proves our claim. Thus, at least one edge in & must correspond to a precondition G that does not satisfy the criterion of the theorem. When the plan has been constructed up to the after-facts of B, this G can be expanded to introduce B into the plan. Note that the G exhibited here corresponds to an add-fact of B; thus, B does not have an equivalent before-fact. It follows that G is not made nonexpand- able by the criterion of theorem 3. References Boyer, R. S., and Moore, J.S. A Computational Logic. Academic Press, 1979. Chapman, D. Planning for conjunctive goals. Artifi- cial Intelligence, 321333-378, July 1987. Drummond, D., and Currie, K. Goal ordering in par- tially ordered plans. In Proc. IJCAI-89, pages 960- 965, Detroit, Michigan, 1989. Irani, Keki B., and Cheng J. Subgoal ordering and goal augmentation for heuristic problem solving. In Proc. IJCAI-87, pages 1018-1024, Milan, Italy, 1987. Morris P., and Feldman, R. Automatically derived heuristics for planning search. In Second Irish Con- ference on Artificial Intelligence and Cognitive Sci- ence, Dublin, Ireland, 1989. Proceedings to appear in Springer-Verlag Brit. Comp. Sot. Workshop Series. Morris, P. H. A Resource Oriented Formalism for Plan Generation. PhD thesis, University of Califor- nia, Irvine, 1984. Nilsson, N. J. Principles of Artificial Intelligence. Tioga Publishing Company, Palo Alto, Ca., 1980. Rich, E. Artificial Intelligence McGraw-Hill, 1983. Sacerdoti, E. D. A Structure for Plans and Behavior. Elsevier North-Holland, 1977. Smith, D. E.; Genesereth, M. R.; and Ginsberg, M.L. Controlling recursive inference. Artifkial Intelligence, 30(3):343-389, 1986. Tate, A. Project Planning Using A Hierarchic Non- Linear Planner. Research Report 25, Dept. of Artifi- cial Intelligence, Univ. of Edinburgh, Aug. 1976. Tate, A. Generating project networks. In Proc. IJCAI-77, pages 888-893, Cambridge, Ma., 1977. Vere S.A. Relational production systems. ArtificiaE Intelligence, 8~47-68, 1977. FELDMAN AND MORRIS 157
|
1990
|
21
|
936
|
Practical Temporal Projection Steve Hanks* Department of Computer Science and Engineering, FR-35 University of Washington hanks&s. washington.edu Abstract Temporal projection-predicting future states of a changing world-has been studied mainly as a formal problem. Researchers have been concerned with get- ting the concepts of causality and change right, and have ignored the practical issues surrounding projec- tion. In planning, for example, when the effects of a plan’s actions depend on the prevailing state of the world and that state of the world is not known with certainty, projecting the plan may generate an expo- nential number of possible outcomes. This problem has traditionally been eliminated by (1) restricting the domain so the world state is always known, and (2) by restricting the action representation so that either the action’s intended eflect is realized or the action cannot be projected at all. We argue against these restrictions and instead present a system that (1) represents and reasons about an uncertain world, (2) supports a rep- resentation that allows context-sensitive action effects, and (3) generates projections that reflect only the sig- nificant or reEeuant outcomes of the plans, where rele- vance is determined by the planner’s queries about the resulting world state. Introduction Temporal projection consists of taking (1) a model of some world, and (2) the description of a particular se- ries of e’vents that happen in the world, and trying to predict the world’s state after the events occur. In the planning community the events generally comprise a plan to be executed and the world model is a set of rules describing the effects of the actions that make up the p1an.l *This papeE describes part of the author’s thesis work at Yale University, advised by Drew McDermott and sup- ported in part by DARPA grant DAAA15-87-K-0001. Thanks to Dan Weld and Tony Barrett for comments on this paper. ‘Projection is a central problem in the area of qualita- tive physics as well. We will be concentrating on the area of planning and acting, but believe the problems we raise, and perhaps the solutions as well, are equally valid applied to QP situations. See, for example, [Kuipers and Chiu 19871 Temporal projection has been studied extensively in the literature on planning and acting,2 but mainly as a formal problem: one starts with a logic that purports to capture notions involving time, action, change and causality, and argues that the inferences the logic li- censes are the intuitively correct ones. This paper takes a somewhat different view, argu- ing that temporal projection is an interesting pructi- cal problem. We argue that computing the possible outcomes of a plan, even if formally well understood, is computationally intractable, and thus one must re- strict one’s attention to the “important” or “signifi- cant” outcomes. This is especially true in domains for which the agent lacks perfect knowledge, and in which forces not under the agent’s control can change the world-in other words, any interesting domain.3 We present an implemented framework for plan pro- jection, which is actually part of a system that main- tains the agent’s world model-a network of beliefs that are both dynamic and tentative. This paper will focus on how commitments to act (potential plans) change the model; the planning process, conversely, is con- cerned with how the model guides the agent’s choice of action. We first discuss briefly a subsystem that performs probabilistic temporal reasoning-computing the like- lihood that a proposition will be true at some point in time. We next motivate and present a representation for action and demonstrate the exact nature of the pro- jection problem, then proceed to sketch our algorithm. We end by discussing the system’s performance. Probabilistic Temporal Central to the problem of predicting a plan’s outcomes is determining the truth of various propositions (e.g. an action’s preconditions) at some point in time (e.g. the time at which the action is to be executed). Since the 2There are simply too many references to cite here, given the space limitations. An int,erested but uninformed reader might start with the relevant papers in [Ginsberg 19871 and work forward from there. 3See [Chapman 19871 for some discouraging results, even for artificially restricted domains. 158 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. agent will typically lack perfect information about the world (past, present, or future) we need some mecha- nism to express its uncertainty regarding the states of these propositions. We are using probabilities to rep- resent this uncertainty, thus are concerned with com- puting the quantity P( ‘$7 true at time V’), where cp is some proposition and t is a time point. We will abbre- viate this notation to P(pt). Three sorts of evidence get used in the computation: (1) reports from the sensors about cp’s state, (2) sym- bolic causal rules of the form “if event E occurs while some fact P is true, then cp will become true at the next instant in time,” and (3) background information (prior probabilities) about cp, E, P, and so on. Uncertainty can come from a number of sources: (1) one can doubt whether the sensor reported correctly on ‘p’s state, (2) one can be unsure as to whether a rel- evant event E actually occurred at some point in time, and (3) one can lack confidence in the causal rules: perhaps the rules mentioning cp aren’t really necessary and sufficient predictors of cp’s state changes. Our rep- resentation for propositions, rules, and the like takes into account all of these factors. Important computational problems arise in imple- menting this approach: a tremendous amount of evi- dence must be brought to bear in computing the prob- ability. Sensory observations of cp might extend arbi- trarily far back into the past, as do the relevant causal rules (since they are implicitly quantified over all time points). Most of this evidence, however, will not affect ‘p’s probability significantly. Although computing ‘p’s exact probability requires considering a potentially infinite amount of infor- mation, we might expect that under the right circumstances-sensors that are reasonably reliable and changes that occur reasonably infrequently-we can compute a good approximation of the probability using only a few pieces of evidence. The question is how good need a “good” approximation be? The application program (planner) provides this in- formation in the form of a probu bility threshodd r, indi- cating that it doesn’t care what cp’s probability is, but only to what side of r the probability falls. A “good” approximation is therefore one that reports correctly with respect to the threshold. [Hanks 19881 presents a heuristic algorithm for limiting the search for evi- dence, the limit depending on how close the current es- timate is to the threshold. The program also computes probabilities for joint events (logical conjunction), and monitors the database for new information that might invalidate the current approximation. Details of this subsystem appear in [Hanks 19881 and [Hanks 19901. The projector invokes the probability-calculation sub- system by posing a probubil’istic query-a question of the form “P(vt) > T?” The answer is returned in a data structure, called a beliei which is an assertion about which side of the threshold the probability lies (given current evidence). Action representation The typical action representation in the literature on action and planning (e.g. [Fikes and Nilsson 19711, [Lif- schitz 19871, [Ginsberg and Smith 1988]) describes an action as a mapping from preconditions into eflects. A good example is the “start the car” scenario, usually used to motivate the qualification problem: if there is fuel in the tank, the starter is working, . . . , and there is no potato obstructing the tailpipe, then turning the key causes the engine to start.4 A planner or projector faced with the hypothetical execution of such an ac- tion would first try to infer the action’s preconditions; if they turn out to be true the effects would be noted in the resulting world state; if false, the action is said to be infeasible, and the planner could not reason about subsequent execution of the plan. What’s troublesome here is the planner’s inability to reason about the action in cases where the precondition is false: in no sense is the action of turning the key of a car with, say, an obstructed tailpipe impossible or meaningless, yet that is what is implied by these systems’ failure to project further. In fact the action will have predictable effects even if the tailpipe is obstructed: it will take some time, wear down the battery, make some noise, perhaps gen- erate a spark. It turns out that one particular effect, the engine running, will not be realized, and it may be the case that in some situations that’s the only ef- fect the planner is interested in, but it does not mean that executing the action is meaningless. What these systems have done is confused the notion of an action being meuningfil or conceivable with the notion of an action’s achieving its intended effect.5 The former is rightfully a property of the action’s definition, but the latter depends on the situation at hand. Actions will typically have a variety of effects depending on the cir- cumstances, and it may be impossible to predict ahead of time which of those effects will turn out to be im- portant. If our representation for actions and plans is to sup- port clever detection of planning bugs (e.g. trying to start the engine too many times thus running down the battery, or generating a spark in a gas-filled room) or innovative planning or plan recognition (running the car to warm the garage or to light the headlights with- out taxing the battery) we must associate intention or relevance with the situation rather than with the ac- tion’s definition. Consider as an alternative the code in Figure 1.6 It is intended to represent the action “drive the truck *The point is that there are myriad preconditions to any action-too many to verify explicitly. ‘Pednault’s ADL [1988a] is an exception, since it ex- plicitly allows for context-dependent effects. In [Pednault 1988101 he notes various computational problems associated with using the representation for planning or projection. ‘This is a simplified version of an action based on the robot-truck world of [Firby and Hanks 19871. HANKS 159 (action (travel R Ll L2) (if (not (lot TRUCK Ll)) (A) (outcomes INFEASIBLE) (if (< FUEL-LEVEL IO) (B) (outcomes (1 oc TRUCK ON-ROAD) (status TRUCK OUT-OF-GAS) (consume FUEL 10) (duration 0 60)) cc> CD) (El (if (not (muddy R) > (outcomes (lot TRUCK L2) (consume JYUEL 10 15) (duration 45 60)) (if (chance 0.25) (outcomes (lot TRUCK ON-ROAD) (status TRUCK STUCK) (muddy TRUCK) (consume FUEL 0 30) (duration 0 75)) (outcomes (lot TRUCK L2) (muddy TRUCK) (consume FUEL 25 30) (duration 50 751 Figure 1: Traveling on a dirt road down road R from location Ll to location L2. The code describes a mapping from state descriptions to sets of outcomes.7 Note that actions can still be infeasible, as outcome set (A) indicates, but the idea is that it is truly meaningless to contemplate a trip starting at location Li if you are not at location Ll. Running out of gas or getting stuck in the mud may be inconve- nient, may even be impossible (probability 0) under some circumstances, but it is not inconceivable. The feasible outcome set (D) indicates that as a re- sult of executing the travel action the truck is some- where on the road, stuck in the mud, has used up some quantity of fuel less than 30 gallons, and somewhat less than 70 time units will have passed. An outcome set’s label, the conjunction of all the if propositions leading to it, describes states of the world in which the outcome set will be realized. Set (D), for example, will be realized if the action is executed when the world satisfies the the following condition: (lot TRUCK Ll)A (not (< FUEL-LEVEL 10) )A (muddy R)A (chance 0.25) The action’s if-then-else form ensures that the labels for different outcome sets will be mutually ex- clusive and that the labels for all an action’s outcome sets will be exhaustive. Therefore exactly one set’s label will be true at any point in time, so no matter when the action is executed exactly one set of outcomes will be realized. Of course we may not know what that state of the world is, even after the action is executed.8 70utcomes are essentially the same as the “effects” above, but extended to allow reasoning about sets, con- tinuous quantities, passing time, and so on. 8 We account for an action’s having indeterminate effects by introducing the chance predicate, e.g. Figure 1 outcome set (D), whose real truth value is never known, Flit whose Figure 2: Projecting a single action An outcome set’s label is a formula that can be posed as a probabilistic query (given a time point represent- ing the proposed time of execution). We can therefore compute a probability distribution over the outcome sets relative to a time point, asking, for each outcome set 00, “what is the probability that (X>‘s label will be true?” We can then view the process of projecting a sin- gle action as building a tree as pictured in Figure 2. Nodes are states of the worlds, and each arc represents the possibility that a particular outcome set will be re- alized, given that the world is in a state like that of its parent node. The probability associated with an arc, e.g. P(label(A) IW) is the probability that outcome set A’s label will be true, and thus its outcomes will be realized, given that the world is in state W at execution time. W-+A is then the state of the world resulting from the action’s outcome set A being realized in world W.’ Scenarios and Projection To project a sequence of actions Al, Aa, . . . , we just it- erate the process of single-action projection: we project action Ai+r, in each of the world states resulting from the execution of Ai. Projecting a plan therefore re- sults in a directed tree which branches forward in time. We call this tree a scenario structure, and each path through the tree a chronicle. Each chronicle has an as- sociated probability, and the probabilities of all chron- icles in a scenario must sum to 1. Figure 4(a) shows the structure generated by projecting the sequence (load 01); (load 02); (travel BR L3 L4) whose action descriptions appear in Figure 3. The load actions-load an object into the cargo bay-have a 0.1 chance of failing, but take 1 time unit in either case; BR is a bridge that will col- lapse if the truck is carrying two or more items when it crosses. The projection problem manifests itself in the pro- liferation of chronicles: a plan with n actions each containing an average of m outcome sets will gener- probability can easily be computed. ‘The projector can also account for the possibility that other relevant events occur while the action is executing, but that process is beyond the scope of this paper. 160 AUTOMATEDREASONJNG (action (load ?x> (if (not (reachable ?x)) (F) (outcomes INFEASIBLE) (if (chance 0.9) (G) (outcomes (holding ?x) (duration 1)) (H) (outcomes (duration 1))))) (action (travel BR L3 L4) (if (not (lot TRUCK L3) (I) (outcomes INFEASIBLE) (if (>= (card CARGO) 2) (J) (outcomes (lot TRUCK RAVINE) (status TRUCK MANGLED) (duration 0 7)) 00 (outcomes (lot TRUCK L4) (duration 3 7)))) Figure 3: More action code ate roughly mn chronicles. Although we can obvi- ously do some pruning of the tree, by eliminating zero- probability and infeasible chronicles for example, an impractical number of feasible and possible chronicles remain.l’ Figure 4(a) shows an exhaustive projection of the plan above. Every arc in the tree has a single outcome set associated with it, so the tree branches with every possible outcome for every possible action. We can reduce proliferation of the tree by instead associating a set of outcome sets with each arc. The intuition is that the distinctions noted by outcome sets within each set are irrelevant, while the distinctions between outcomes in di$erent sets are significant. Referring back to the travel action in Figure 1, sup- pose that we care only about whether the truck reaches its destination L2. In that case we don’t care about the distinctions implied by outcomes sets (A) (I31 and (D) , nor about the distinctions between (C) and (E). So we form two sets and produce two branches in the tree in- stead of five. We call each of these groupings a bundle. Each arc in the scenario tree has an associated bundle, which contains one or more outcome sets. Bundling outcome sets speeds the process of com- puting label probabilities as well, in that the label as- sociated with a bundle (the disjunction of its member’s labels) may be much simpler than the individual labels. As an extreme case suppose we are only interested in whether Figure l’s action is feasible or not. In that case we put (A) in one bundle and the rest of the out- come sets in another. Computing the probability of the second bundle (which has four members) is simply a matter of evaluating (lot TRUCK Ll). Note that as long as we assign each outcome set to exactly one --El (a) Fully aniculatdl (c)Paniallyunbundlcd Figure 4: Bundled and unbundled scenario trees “We have been testing the program with examples in which n = 10 and m = 6, which gives rise to some 6 x lo7 chronicles in the worst case. Pruning infeasible and impossible chronicles gets rid of some $ of them, but that still leaves more than ten million. HANKS 161 bundle, the bundles still partition the set of possible execution-time situations, and thus their probabilities sum to 1. The problem with bundling outcome sets is that we can make less precise predictions. When we project an action across a bundle of outcome sets we can infer only the weakest conclusion allowed by all members of that bundle. If we construct the bundle {(C) , (El} from Figure 1, for example, we can conclude that the truck will be at ~2, but we can only make vague pre- dictions about the fuel consumption (between 10 and 30 gallons), and the action’s duration, and we cannot predict whether or not the truck will be muddy. But then again we may not care. Practical projection, then, is a process of balancing the need for parsimony in the scenario tree and speed in computing chronicle probabilities against the need to make precise predictions about what the world will be like after the plan is executed. The former argues for keeping much of the tree’s structure implicit by forming a few large bundles; the latter argues for repre- senting the tree explicitly. Obviously we want to make explicit the “important” or “significant” or “relevant” distinctions in the tree and leave the rest implicit. But how do we determine which distinctions these are? The answer is that we can use the probabilistic tem- poral queries, which may be posed by the planner or generated as the projector computes a chronicle’s probabilities: the projector wants to articulate exactly enough of the tree to give the best possible answers to the queries it receives. Of course the nature of these queries will not be known in advance, so the projec- tor must be able to articulate the tree more fully-to “unbundle” outcome sets-on demand. To see how the process works, consider again the sequence (load 01); (load 02); (travel BR L3 L4). The planner additionally supplies the projec- tor with a time point at which to begin, initial assump- tions (the truck is at L3, objects 01 and 02 are reach- able, the cargo bay is empty, and the fuel tank is full), and a probability threshold. Chronicles whose proba- bilities fall below this threshold will be abandoned, at least initially. The projector proceeds to project each action in se- quence, assuming that the only distinction the planner is interested in is between feasible and infeasible out- comes. The initial projection appears in Figure 4(b).” The projector returns the (single) chronicle represent- ing a feasible plan completion: the chronicle ending in node 4. At this point we can say little about where the truck is or what it is carrying. Now suppose the planner poses the query “is the l1 We have pruned away O-probability outcomes, like one in which 01 instantaneously becomes unreachable, or the truck inexplicably gets moved away from LX Node 2 rep- resents a situation in which somebody removes object 02 during the time that 01 was being loaded, but it has a small enough probability that it is not projected further. truck at LR?” The projector notes that the current tree yields an ambiguous answer to this question, but that splitting the bundle {(J) ,(K)} would result in a more precise answer. In the process of splitting that bundle it needs to compute label probabilities for (J) and (K), leading it to ask “(>= (card CARGO) 2)?” So the projector poses that query with respect to node 3. Once again the answer is ambiguous: currently we can predict only that the cargo bay will contain be- tween 0 and 2 items, but two bundles, {(G), (H)} and {CC’), (H’)) contribute to the ambiguity, so the pro- jector considers the possibility of splitting them. De- tails of when and how the projector splits a bundle of outcome sets appear in [Hanks 1990, Chapter 41. When all the splitting completes, queries get an- swered, and projection finishes, the tree appears as in Figure 4(c). Now there are three feasible chronicles, each of which answers unambiguously the question “is the truck at ~3. 3”12 The probability for a query Q is the sum c, f’(Q 1 c)p( c w > h ere c varies over all chronicles. The probability for “is the truck at ~3” is therefore roughly 0.19. The probability of “is the truck at ~3 and carrying both 01 and 02" would be 0, and could be computed without further splitting. Maintaining the world model Our system performs three main functions: answering probabilistic queries, projecting plans, and monitoring the database for information that would change exist- ing beliefs.. It is interesting to note how closely inter- related the three processes are: adding plans causes label probabilities to be computed, which gives rise to queries. A query may demand that the scenario tree be split, thus causing more projection, and so on. A query may also cause previously abandoned chronicles, like the ones ending in Nodes 3 and 6, Figure 4(c), to be projected further. New information, like relevant sensor reports, may cause beliefs to change, plan com- mitments to be rethought, new queries to be posed, and new plans to be projected. The system can thus be regarded as maintaining the planner’s world model, one in which evidence takes the form of plan commitments and sensor reports, and aspects of the model are revealed through the belief data structures. Performance It is hard to make precise general statements about the projector’s performance. The worst case, involving a complete articulation of the tree, is exponential both in the number of actions and in the average number of outcome sets per action. In general the tree prolif- erates to the extent the planner asks questions about plan outcomes that depend on propositions whose state the projector cannot predict definitively (with proba- bilities near 0 or 1). So performance depends on the 12Node 8, Figure 4(c) says “no,” 9 and 10 say “yes.” 162 AUTOMATEDREASONING queries, both their types and their thresholds, and on the underlying probabilistic model. A more interesting question is whether the projector always produces the splits necessary, and on/y the splits necessary, to answer a particular query. If it fails to make a necessary split it will report an overly vague answer to a query; if it makes unnecessary splits it will report the correct answer but do so inefficiently. We address this question in [Hanks 19901, but the short answer is that the projector will never fail to make a relevant split in the tree, but will sometimes make unnecessary splits. The decision whether to split an arc is made locally at that arc, but we cannot always determine locally whether a split is really necessary given other splits that might be made. Superfluous splitting does not seem to be a problem in practice, however. We have implemented the projector and tested it on fairly complex examples, involving 15 or so plan steps including conditionals, loops, and information- gathering actions. Each projection took about 4 min- utes on average, but we have reason to believe that more powerful computing equipment and superficial code optimizations would cut this figure in half. We were surprised to learn that most of the time was spent in the temporal database manager module (which maintains the network of time points and constraints), so improving its efficiency will significantly improve performance as well. Conclusion Systems for action and planning have made stringent assumptions about the domains in which they operate and the nature of the actions they manipulate. They typically assume that no events occur apart from those the planner intends, and that an action either achieves its intended effect or cannot be meaningfully executed. These assumptions together mask an important practical problem: when the effects of one’s actions depend on the state of the world at execution time, and when one is uncertain about that world state, one faces an explosion of possible plan outcomes. The hope is that most of these outcomes can be dismissed as un- interesting, improbable, or both. We have presented a system to manage the process of hypothetical reasoning about actions and plans. The system builds a “scenario tree,” tracing the possible outcomes of a plan, but tries to keep as much of the tree’s structure implicit as possible, thus avoiding the explosion of possible plan outcomes. It uses the plan- ner’s queries as a guide to what aspects of the world, thus what outcomes of the plans, are important and deserve explicit consideration. [Fikes and Nilsson 19711 Richard Fikes and Nils J. Nilsson. STRIPS: A new approach to the application of theorem proving to problem solving. Artificial In- telligence, 2(3):189-208, 1971. [Firby and Hanks 19871 R. James Firby and Steven Hanks. The simulator manual. Technical Report 563, Yale University, Department of Computer Sci- ence, November 1987. [Ginsberg and Smith 19881 Matthew L. Ginsberg and David E. Smith. Reasoning about action I: A possible worlds approach. Artificial Intelligence, 35(2):165-196, 1988. [Ginsberg 19871 Matthew L. Ginsberg, editor. Read- ings in Nonmonotonic Reasoning. Morgan- Kaufmann, 1987. [Hanks 19881 Steven Hanks. Representing and com- puting temporally scoped beliefs. In Proceedings AAAI, pages 501-505, 1988. [Hanks 19901 St even Hanks. Projecting plans for un- certain worlds. Technical Report 756, Yale Uni- versity, Department of Computer Science, January 1990. [Kuipers and Chiu 19871 Benjamin Kuipers and Charles Chiu. Taming intractible branching in qualitative simulation. In Proceedings IJCAI, pages 1079-1085,1987. Also appears in [Weld and de Kleer 19891. [Lifschitz 19871 Vl a d imir Lifschitz. Formal theories of action. In Frank Brown, editor, The Frame Problem in Artificial Intelligence: Proceedings of the 1987 Workshop. Morgan-Kaufmann, 1987. [Pednault 1988a] Edwin P.D. Pednault. Extending conventional planning techniques to handle actions with context-dependent effects. In Proceedings AAAI, pages 55-59, 1988. [Pednault 1988131 Ed win P.D. Pednault. Synthesizing plans that contain actions with context-dependent effects. Computational Intelligence, 4(4):356-372, 1988. [Weld and de Kleer 19891 Daniel S. Weld and Johan de Kleer, editors. Readings in Qualitative Reasoning about Physical Systems. Morgan-Kaufmann, 1989. References [Chapman 19871 David Chapman. Planning for con- junctive goals. Artificial Intelligence, 32(3):333-378, 1987. HANKS 163
|
1990
|
22
|
937
|
Synthesis of eactive Plans for Multi-Path Environments* F. Kabanza Universitk de Likge Institut Mont&ore B28 4000 Likge Sart-Tilman; Belgium U519026QBLIULG 11 .bitnet Abstract We describe a planner that works on the description of a multi-pa*th environment and generates a conditional plan. The resulting plan is guaranteed to fulfill its goal whatever path of the description the environment follows during the plan execution. Introduction Classical planning systems [Fikes et CL/., 197’1; Cohen and Feigenbaum, 1982; Wilkins, 19841 assume tl1a.t. the planning agent operates in a. static environment (world). That is, at every moment of time, the world is in a given state and that state remains unchanged until an action is performed by the agent. Yet most interesting environments in which an in- telligent agent is expected to operate are not static. Most realistic worlds are changing and nondeterminis- tic. The assumption that the world remains static be- tween successive actions of the agent no longer holds. Furthermore, the agent usually has only nondetermin- istic information on how the world is going to evolve. Recent work has considered the problem of planning in such environments. Allen and Koomen [Allen and Koomen, 19831 use an interval tempora.1 logic to model the past, the present, and the future knowledge of the agent. The changes of the environment and the non- determinism of its behavior a.re conveyed by formu- las of the logic. McDermott [McDermott, I9821 uses a branching structure (tree of chronsets) to represent a. nondeterministic future. Pednault [Pedna,ult,, 19871 uses a. STRIP-like representation of aqctions to model some changing worlds, especially in motion problems for which one can give a prediction of the sta.te of the world after an action. Lansky [Lansky, 19871 uses a point-based logic and an event-based representation of states to express synchronization properties between a.gents in a multiagent domain. Dea.n [Dea.n, 19871 de- scribes a framework for scheduling tasks with imposed *The following text presents research results of the Bel- gian National incentive-program for fundamental research in artificial intelligence initiated by the Belgian State - Prime Minister’s Office - Science Policy Programming. The scientific responsibility is supported by its author. 164 AUTOMATED REASONING deadline constraints. In tha.t approach, the pla.nner can use statistical information to predict the future. In this pa.per, we a.lso consider the problem of plan- ning in a. multi-path environment. We irltroduce a planning method that is inspired by recent develoy- merits in program synthesis from tempora.1 logic speci- fica.tions [Abadi et al., 1989; Pnueli and Rosner, 1989a; Puueli and Rosner, 1989b]. The multi-path envirou- nlent is viewed as a. tree of states, which we ca.11 a world-automaton. Each path in the tree represents a possible behavior of the environment,. We call e?~u~- ronment knowledge the knowledge represented by the world-automa,ton. We assume that the planner has no control over this tree and that he cannot predict which path the world is actually going to follow. ‘l’he operational knowledge of the plan is given by a set of actions. The planning problem can now be stated a.s follows: given an environment characterized by a world-autonlaton, an operational knowledge, an ini- tial state, a.nd a goal, find a. (conditional) p1a.n tallat is guaranteed to achieve the goal wha.tever path of the world-automaton the environment a.ctua.lly follows. ‘10 handle this prohlelll, one first needs a forlnalislll for describing the enviroumeut knowledge. 011e could give the set, of world s~a.tes and the tr.a.nsitSioll r.elat,ioil bet,ween t,hese states, hut, such a description would IX tedious and hence prone to error iu complex euviron- me11ts. Instea.d, we use propositional brauclliug tillre temporal logic (CTL [E merson and Clarke, l&Q]). b‘or instance, let us assuiiw that the world-au tomato11 is specified by the (‘I’L formula ..ElOgua.rd A VOdark” stating that, it, niight be the case t,liat there is always a guard present, and tha.t. it, will definibely end up being dark. Consider the goal .*rob( $%O million) frown Ba.uk” and a,n init,ial sta.te where it is ilotS dark. Then the plan tl1a.t is genera.ted should work whether a guard is present or not, though it can wait for darkness to ap1~ea.r since this is guaranteed to happen. The problem of generating the plan is rela.ted to that, of synthesizing a. reactive module as described in [Rosenschein, 1989; Pnueli and Rosner, 1989a; Pnueli and Rosner, 1989b]. A reactive program is one tl1a.t continuously interacts with its envircrnmeut, dur- From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. ing execution. The environment controls some vari- ables, the program others. The synthesis problem con- sists in building a program that satisfies a given specifi- cation (expressed in temporal logic) for all possible be- haviors of the environment (also expressed in temporal logic). This is done by first building a formula. express- ing the statement : ‘Yor any execution of the environ- ment, there is an execution of the program that satis- fies the specification”. One then uses a decision proce- dure to generate a model for this formula. One could adapt the algorithms of [Pnueli and Rosner, 1989a; Pnueli and Rosner, 1989131 to the synthesis of plans. Unfortunately these methods are of very high compu- tational complexity (double exponential), which makes them of limited use in practice. The approach we follow proceeds in three steps. First, we genera.te a description of the world- automaton from the CTL formula describing the en- vironment. This can be done with the a.lgorithms de- scribed in [Emerson and Clarke, 1982; Emerson and Halpern, 1985; Manna and Wolper, 19841 and sum- marized in [Wolper , 19891. Then, from this world- automaton, the opera$iona.l knowledge, and the goal, we build a graph representing a synchronization of the executions of the agent and of the environment. A node of this graph represents an action that has to be executed by the agent. A transition between two nodes is la.beled by an event of the world-automaton, that, is, of the environment. Finally, we estra.ct the desired p1a.n from this gra.ph. This approach a.llows us to es- ploit classica. heuristic methods (a.s in SIPE [Wilkiub, 19841) to only explore a fra.gment of the search space of possible action sequences. In the next section, we sta.rt with a. forma.1 descrip- tion of world-automata. and pla.ns. NJe then discuss the specification language and the a.lgorithm that auto- matically generates the world-automa.ton from a. CTL specifica.tion. The following section describes the plan- ner. The last section is devoted to other features of the planner and to possible extensions. Describing Environment Knowledge and Plans Actions, Events, Goals, and Strategies Actions a.re described, as in classical systems such as STRIPS or SIPE [Fikes et al., 1971; Wilkins, 19841, essentially by their precondition and their effect. How- ever, we also allow an exclusive disjunction as the effect of an action to represent an effect that depends on the sta.te in which the a,ction is a.pplied. We will call ac- tions with disjunctive effects disjunctive actions. The action NULL means “do nothing”. Go& are also described, a.s in classical systems, I>> a. set, of propositions. But, in a.ddition, we allow co~dl- timal goals of the form y - ~1, where p is a. proposition and a is an action. Such a goal means “do u every time p is true”. A strategy is a set of linearly ordered goals. The or- der must be safe, that is, if a goal g1 precedes a goal g2, then all actions leading t>o yl have to be performed before a.ny action for gz during execution. Therefore a goal is a special strategy. Strategies are more or less similar to Chapma.n’s “cognitive cliches” [Chap- man and Agre, 19871. Environment Knowledge and Plans A world-automaton is a where tuple Q = {ql,. . .a,} is a set of states; E = {NOTH,el,. . . e,,,} is a set of events (the event NOTH is a special event indicating that nothing (in- teresting) ha.ppens in the environment); r:Q - E is a function mapping states to events; 2& is the transition relation between next : Q -+ st a.tes; (I E Q is the initial state. The fact that there is only one initial state is not re- strictive. If an automaton has many initial sta.tes we can make them the successors of an initial state with event NOTH. An execution of a world-automaton is defined as in classical automata theory. We start in the initia.1 state (I. The first, event) to appear is ~(‘1). Being in state (I! mea.ns t(hat, the rven~, -r( q2) is t,hc> last Ollt‘ too 11aw occurrecl. ‘I’he 611 u~w1~7~1~7t 1 ho toledgc is descrilxxl by a world- a.u tSonlatou. ‘IYlic possiblt~ esecutious of his a.u t,olila t.oll constitute an infinite t,ree. Each path of this Lrw cl+ scribes a. possible behavior of’ the environment. He~lce- forth, we will use the t*erius “esecut#ion”, %eliavior”. and “pa.th” of the environment, interchangeably. The pla~ls we generate a.re also represented by world- automata.. An aut,omatou representing a p1a.n contains both the actions (events) of the environment a.nd those of the planning a.geiit,. To execute a. plan, ail agelit performs the actions in the plan that are his own and wa.its for the environment t#o perform all other actions. Events can be generic, that is, lia.ve many possible insta.nces. But, at any molnent, only one insta.nce of an event n1a.y ha.ppen. For example, the event o?z(a, X) has o?z(a, table) and o?z(a, 6) among its insta.llces. In the world-automaton, a transition happens when an?. instance of the corresponding event ha,ppeus. Example 1 Suppose we ha.ve to build a reactive plan for robot Agent.2 stacking on table T2 parts produced on a separate ta.ble Tl by another robot Agentl. Agent11 produces parts by groups of four: blocks u, 6. c and cl. It stacks ea.41 block on a sepaxate rack a.ppropriat,c-> for ih tylw. Wiic~u a rack is occupit>d, tilt> ageut wait,s until it t)oc*ollles clear. ?‘lle i)locl; 6 is al- ways produced just aI’t.c>r t.lic I,locl; cl, alid d is al\1,;l~‘3 produced just. aft,er c. 111 figures a11d ill forlilulas, \VC~ abbrevia.te *‘rack i” by I’, . KABANZA 165 The environment knowledge for Agent2 is thus the production activity of Agentl. It is described by the world-automaton of Figure 1. A part of the plan that our method generates for Agent2 is given in Figure 2. In this figure, all actions that have to be performed by Agent2 are prefixed by ad. Figure 1: Enviromnent for Agent2 Specifying the World-Automaton We use propositional branching time temporal logic (CTL) to describe the environment. This logic is for- mally defined in [Emerson and Clarke, 1982; Wolper, 19891. We only introduce it informally here. CTL formulas are built from atomic propositions, boolean connectives, and eight temporal operators. A temporal operator is a path quantifier directly fol- lowed by a modality operator. The path quantifiers are V meaning “for all execution paths”, and 3 meaning “there is an execution path”. The modality operators are 0 (“eventually”), •I ( “always”), 0 (“next”) and I! “until”. They are all unary, except U which is binary. Proposional formulas (i.e. without temporal operator) are the basic CTL formulas. Any formula built by prefixing a CTL formula. with a temporal operator is also a CTL formula. Exa.mples of CTL formulas are : 30accep ted A V( lpresen ted U accep ted). Formulas are interpreted over infinite trees of propo- sitions. They can be naturally interpreted over world- automata. A formula is satisfied by an interpretation if it is satisfied by the initial state of the interpretation. A proposition is satisfied by a. state if it is true (iii the classical sense) of the event of that state. 3 0 f means “possibly nest f”. Its dual V 0 f I~W~JIS; “surely next f” . 3Of means “possibly f rvill hal>yelJ” . 1~s dual VOf means “surely eventually f” . 30f means “possibly it is the case that. alrvaJ7.s f”, w1ierea.s Vof means “surely alwa-vs f” . 0 3(fUy) means b‘possibly it is the case that f !rolds until y” , a.nd V( f[‘y) ineans “surely f holds UIJ til y” For instance, the world-automaton of Figure 2 satisfies the formula 3Opul;o?s( d, 7ad). Generating the World-Automaton We use the algorithm of [Emerson and Cla.rke, 19821 to generate the world-automaton from a CTL specifi- cation. The worst case complexity of the algorithm is exponential in the size of the formula. However, with an implementation that uses all possible optimiza.tions, it often gives good results. Example 2 The following formulas are the bulk of the specification from which the world-au toma.ton foi Agent2 (Figure 1) has been generated. 1. 2 3 4 I A block is produced if its rack is empty VJCl(puton(a, ra) 3 clear(r,)) (Similar axioms for b, c and cl.) Every time I*, is empty, u will eventually be pro- duced Wl( cleur(r,) 3 VOyuton( u, r, )) (A similar asiom is given for I*,.) The order of block production: wheu CL is producecl, tht~ following block rl~ust, be b vq/mtoll(u, I’,,) 3 v(~(put0n( (1. rtL) v puton (c, I’, ) v p’Llor/(cl. /-(1)) 1 ‘puton( G. rl,))) (Simila.rly for c aud cl. ) At each cycle we do not know the first block to be produced 301mton(a, ?a,,) A 3O]mton( c, 7’J adtalk 1 Figure 2: Plau for Ageut;! 166 AUTOMATEDREASONING The Planner goals, ii0 generic events, and the operational knowl- The General Idea We stast with the following data: a. world-a.utomaton, an operational knowledge, and a. strategy (set of goals). From this, we first build an intermediate structure. This structure is a directed graph whose nodes are la.- beled with actions of the operational knowledge and whose transitions are labeled with events of the world- automaton. This graph represents a synchronization of the agent trying to complete the goals with the en- vironment: at a node of the graph, the agent executes the associated action; it then waits for an event la- beling a transition from that node. When the event happens, the agent goes to the node indicated by the transition labeled by the event, executes the action cor- responding to that node, and waits again. Actions of the graph are chosen by the planner so that they 1ea.d to the goals. It then remains to extract a plan from the con- strutted graph. As mentioned in the knowledge de- scription section, the p1a.n has the form of a. world- automaton. Hence, it ca.n be used as input for another planning a.gent. Building the gra.ph is thus the core of the a.lgo- rithm. MJe associa.te the following additional informa- tion to each node of the graph: a state of the world- automatou, a. goa. to be completed within the uode. aad a. sta.ck of stra.tegies t,o be performed by desceu- da.uts of the node (the pa.rt of the initial strategy that still has to be completed). Recall that the strategy is the goa.1 of the a.gent. We build the graph sta.rting from a state in which the associated node of the world-a.utomaton is the initial sta.te of that automa.ton, the strategy is the overa. goa.l, and the action is NULL. The graph is then built incrementa.lly as follows. e A graph node with no successor a.nd with a nonempty strategy is chosen. e An action whose precondition is satisfied and tl1a.t reduces the distance from the goal is chosen (nonde- terministically ). e Successor nodes are constructed for each possible a.c- tion: the action chosen for the agent and a.11 possible environment actions. Of course, backtracking is used to implement the non- deterministic choices. Also, goal-reduction is used: when the precondition of the chosen action cannot be sa.tisfied, we attempt to apply goal reduction to the ac- tion. If this is impossible, we look ahead in the world- automa.ton to see if more promising states are coining up and we wait for them; if this is not. t,lie case. ~‘e backtrack. The Algorithm In this pa.per, we sketch the pla.nning a.lgorithul with the following restrictions: there are no conditional - edge does not contain disjunctive actions. The planning algorithm operates in oue of two modes: wait. and reduw. 111 the wait mode, it is search- ing the world-automaton for an event to happeu. In the reduce mode, it is trying to find an a.ction tl1a.t fulfills a goal. We use the following convention for varia.bles: s and s’ for nodes of the graph, e for events of the world-automaton. S is the set of nodes of the graph and E is the set of events of the environment. The data-structures used by the planning algorithm are: e The world-automaton (Q, E, y, next, ~0); e The intermediate structure (graph) in which: S is a set of nodes of the graph, succ : (S x E) -, S is the graph transition function. The information associated with each node s COII- sists of: an action actiol2(s), a world-automaton state was(s), a goal G(s), and a strategy stuck(s); e The va.riable J1ode that takes values l/1/ (wait) and R (reduce) ; o The event waited up011 when in mode I/T/ is wuhted- event. A sketch of construction of t,he intermediate graph is given iu Figure 3. The goal-reduction is ally of the heuristics available iu Al [Wilk ins, 1%4], used to deconlpow a goal into priuiiLivc> subgoalh. Aiij of’ Lh~sr heuristics ~‘a.11 be ap- plivcl siuccb we have Liir salilt~ l)roblt’lil: fiucl a srqueuce of act,ious I.0 coliipl(~L(~ a goal c-;(s) fro111 ali iuitial staCc> q0, giveu a set. of actioiis (t,h(> operatioiial kuowledg~). Nodes cali be fused wheu t#hep are tlefiued 1’3. t,llc> saine elements (action, stack,. ). Hence 1001)s Inight. be introduced. The planning algorithm has to check that the loops that are introduced are safe. This is done with techniques similar to those used to check that even tuulity for?,aulus are satisfied when build- ing models of temporal logic formu1a.s [Emerson aud Cla.rke, 1982; Manna and Wolper, 19841. Tl1.e plu7~. is extracted from the iutermediate struc- t,ure as follows. First. build a II~\V structure frolu t,he int,ermediate structure. by introducing between two successive nodes a new uode la.beled ivith the trau- sition label between those nodes. The plan is induced from tl1a.t la.st struct#ure by skipping MULL actions a11d NOTH events. Example 3 Consider the clnvironment. knowledgr of Example 1. Suppose we are given the following opera- tional knowledge: Actions lake( de) prec011d : OII (d’, 2 ) A clt n/j -1.) add-list.: hu rlf( .L’) A cltul( .t ) ]I(1 t 0 11( .C ) JJ ) pr”‘“lld : hu L’I’( x) A ( If?0 r( y) add-lisl. OII(.I*. y). ‘l’he goal of Ageut2 is t,o arrange blocks 011 a diffxellt table 7’2, as follo\Vs: Oll(W, 1’2) A Oll(d, a) A o/1(6, d) A O/l.(C, 6). KABANZA 167 Construct-Intermed-Struct (strategy) Create an initial node s with G(s) = NULL, stack(s)= strategy, and was(s) = ~0. Set Mode to R. Repeat Select a node s with stack(s) not empty and with no successors. If there is no such node, break from the loop. If Mode=W then: Check if was(s) =waited-event. If so, set Mode to R. If not, set action(s) to NULL; for each event e successor of was(s), create the node succ(s,e), set G(succ(s,e)) to G(s), and stuc~(succ(s,e)) to stuck(s). Else: -If G(s) is not an atomic action reduce it to a sequence of atomic actions by applying goal- reduction. If such a sequence can be found then update G(s) and stuck(s) and continue. -From now, we can assume G(s) is atomic. If the precondition of G(s) is not satisfied use the veri- fication algorithm of [Clarke et al., 19861 to see if the precondition of G( s) can be satisfied by further states of the world-automaton; if it, can, set Mod6 to I/T/, and set waited-event to the precondition of G(s); else backtrack. -If the precondition of G(s) is satisfied, set action(s) to G(s); then determine the strategy and the stack for successors nodes : for each event successor of was(s), create a, new node s’ of the graph and a transition, labeled by the event, from the current node to the new node s’; set G(s’) to the first element of &clc(s) and stack(s’) to the rest of stacl(s). End of Repeat End of Construct-Intermed-Struct Figure 3: Constructing the intermediate structure It is reduced to the strategy: take(a.) - pzlton(a,T2) - take(d) - yuton(d, u) - take(b) - pton(b, d) -- t&e(c) - puton(c, b). The initial part of the plan generated is show~l in Figure 2. I Additional Features and Possible Extensions The following features ha.ve also been developed: the use of past temporal formulas to express conditions of conditional goals. We keep a 1inea.r structure recording the past activity. We can then use a polynomial algo- rithm to verify if past preconditions of actions are sat- isfied on that structure. The verification algorithm is similar to that of [Clarke et ud., 19861. We can also use temporal formulas to describe the effects of an action. This is a partial response to the commitment problem [Cohen and Levesque 1 19871. When an action with a temporal effect is selected at a state in the intermedi- ate structure, we replace the sub-automaton rooted at the correspondin, T state in the world-automaton by a cross-poduct of the sub-automaton with an automaton representing the effects formula. If there are paths of the world-automaton on which it is impossible for the agent to achieve its goal, there is no solution to the planning problem. However, it seems reasonable for the agent to move ahead anyway mak- ing the assumption that the path for which he cannot plan is unlikely. This implies that it would be useful to have probabilistic information for each pa.th of the world automaton. The planner would then use that information to estimate the proba.bility that the plan will work. Another interesting approach is for the plan- ner to procrastinate when, for some goals, the future is very uncertain. He would delay planning for those goals until informa.tion about the future becomes more precise. Automatic genera.tion of environment, specifications is a problem we intend to investiga.te, possibly using t,ecliniques similar to those in [liautz and Allen, 1986; Kautz, 19873 to construct, a prediction module. Pla.nning is also expected to be interleaved with the execution. During execution some information could confirm or disconfirm the current, structure of the world-automaton. The planner can then deter- mine whether or not the plan could go awry and, if necessary, replan with respect to the new environment structure. Conclusions We have show11 how temporal logic can be fruitfully used for generating reactive pla.ns. The probleill we considered is that of planning for agents evolving in a changing and nondeterministic world. The generation algorithm is in fact. a blend of goal-reduction and envi- ronment enabling, and it ca.n be viewed in the tread of recent, work done by [Bresina a.nd Drunnnoiid, 19!)0]. The performa.nce of this planner depends on t,he availa.ble stra.tegies. ‘I‘he lower level the strategies are. the faster the plan generation is going to be. We he- lieve the method viable if refined strategies are avail- able. Such refined strategies are analogous to those used in human behavior. If you are told to go from Liege to Brussels, you immediately decide t,o t.ake a bus to the sta.tion, where you hope to catch a train. If you know there might, not be a bus, you iiiunediately plan to ta.ke a cab. ‘1’ha.t is, you act as if you had strategies triggered by goals you ha.ve to commit to. You don’t think “to be in Brussels I must. have been in a train; to be in a. train I must have been to the station, and so on.” Such reasoning only appears in rather unusual situations (lost in a. town, ). Clearly the method, as it stands now, has some limi- tations. The world-automaton has to be correct for the 168 AUTOMATEDREASONING plan to be correct too. Thus there is need for some way of dealing with unpredictable events. Another limita- tion is the seemingly great complexity of the algorithm. With all that in mind, we espect this work will serve as a. good guideline for future investigations towards a. tractable planner. Acknowledgments I would like to thank two anonymous referees for help- ful suggestions for a better presentation of this paper. I am also grateful to Marianne Baudinet, Jean-Marc Stevenne, and Pierre Wolper for careful reading of this paper and thoughtful comments. Philippe Simar helped in the typesetting of this pa-per. This work has been made possible only through the enthusiastic su- pervision of Professor Pierre Wolper, to whom I extend my thanks. References Abadi, M.; La.mport, L.; and Wolper, P. 1989. Re- alizable and unrea.liza.ble concurrent program spec- ifications. In Proc. 10th Int. Colloquizlnz on Au- tomutu, Languages and Progrumming. LNCS, Vol. 372, Springer-Verlag. 1-17. Allen, J.F. and Koomen, J.F. 1983. Pla.nning using a tempora.1 world wodel. In Bundy, A., editor 1983, 8th IJCA41. 741-747. Bresina., J . and Drummond, M. 1990. lntegra.ting planning and reaction. Ill A=-1AI w0rtw10p 011 YlU’ll- ning in Uncertain, Unpred~ctuble, or ChulLgzug h’:n UI- rouments, Stanford Univ. Cha.pma.n, D. and Agre, P. E. 1987. Abstra.ct reason- ing as emergent from concrete activity. In Georgeff, M. P. and Lansky, A., editors 1987, Reusonnzng ubout Actions and Plans, Proceedzn.gs of the 1986 Work- shop, Timberline, Oregon. Morgan Kaufmann. 411- 424. Clarke, E.M.; Emerson, E.A.; and Sistla, A.P. 19S6. Automatic verification of finite-sta.te concurrent8 sys- tems using temporal logic specifications. A CM Transactions on Programming Lunguuges and .>‘ys- tems 8( 2):244-263. Cohen, P. R. and Feigenbaum, E. A. 1982. Handbook of Artificial Intelligence. Pitman, London. Cohen, P. R. and Levesque, H. 3. 1987. Persistence, intention, and commitment. In Georgeff, M. P. and Lansky, A., editors 1987, Reusonnang uboui .4ctzons und Plans, Proceedings of the 19S6 Workshop2 Trw berline, Oregon. Morgan Kaufmann. 297-340. Dean, Thomas L. 1987. Intractability and time- dependent planning. Iii Georgeff, n4. P. and La.n- sky, Amy, editors 1987, Reasonnang ubouf Actzo~~ CCII~ Plu11.s. Proceedings of th E 198h’ kl?o~kshop. ?‘ll,r bc 1.11.l) 6. Oregon. M0rgall Iiaufmann. 245-266. Emerson, E.A. and Cla.rke, E.M. 1982. Using branch- ing time logic to synthesize synchronization skeletons. Science of Conaputel* Progrummng 2:241-266. Emerson, E.A. and Halpern, J.Y. 1985. Decision pro- cedures and expressiveness in the teniyoral logic of branching time. Jou~xul of C ‘or,Lputel. ur~d .Syste~~~ Sciences 30:1-24. Fikes, R.; Hart, P. E.; and Nilsson, NJ. 1971. STRIPS: A new approach to the application of theo- rem proving. Arti’czul Intellzgence 2:189-208. l&utz, H. A. and Allen, J. F. 1986. Generalized plan recognition. In 5th NCAI. AAAI, Morgan Kaufmann. 32-37. Kautz, H. A. 1987. A formal theory of plan recogni- tion. Technical Report 215, Univ. of Rochester, NY. Lansky, A. 1987. A representation of parallel ac- tivit*y based on events, structure, and causality. In Georgeff, M. P. and Lansky, A., editors 1987, Reu- sonning ubout Actzons uud Pla.w, Proceedxngs of the 19S6 Workshop, Tzmbe&ue. Oregon. Morgan Kauf- mann. 123-159. Manna., Z. a.nd Wolper, P. 19154. Synthesis of co~u~llu- nicating processes from temporal logic specifica.tions. A CM Trunsuctwns 011 Progmmmxng Lu1Lguages and ,C;ysteiiis 6( 1):68-93. McDer~~dt, D. 1982. A teinpora.1 logic for reason- ing about, processes aiid l)la.lis. c’og1L’1rlw S’c1ei,ce 6(2):101- 155. l’c~clnault. E. P.D. 198i. I~oriiiulating illult.iag~~ilc. dynamic-world problellls iu t,lie classical plaiulillg fra.lllt~worl;. 111 Gmgdf’, Rl. 1’. a11d La11sliy, A ., cYi- itors 1987, Keuson)bl~lg about .-1ct1ous UIL~ Pla~rs, YIO- ceedzngs of ih e 1986’ I/l~~o~-kshop. TLm be rlzlst , Ore!~o I). M0rga.11 l<aufma.nn. 47-82. Pnueli, A. and Rosner, R. 1989a.. On the synthesis of a reactive module. In 16th A~~nunl ACM Sy~nposa~unz on POPL, Austin. 179-189. Pnueli, A. and Rosner, R. 1989b. On the synthesis of an asynchronous reactive module. In 1C,‘ilLY. LNCS, Vol 372, Springer-Ver1a.g. 652-671. Rosenscheiu, S. .J . 1989. Synthesizing inforniation- tra.cking automa,ta from environment descriptions. In Brachman, R. J .; Lcvesque, H. .J .; mcl Reiter, It., editors 1989, E’rrsl I~~le~~l~nl~o~~al C’onjerelscc on PTLI~- czples of h~~~owledg~ Hepresentutxon u11d K.~USOILII~~, Toronto. Morgan liaufinann. 386 393. Wilkins. D. E. 1984. Domain-indepelldant planning: Representation and plan b. o‘eneration. .q rlzafic~cil lintel- ligence 22( 3) :26Y- 30 1. Wolper, P. 1989. 011 tl _ ie relation of prograiiis and coinputat~ions to niodels of t8eniporal logic. 111 Bali- ieybal. B.; Barringer, H.: a11t1 Pnueli, A., c>clit.ors 1989, hoc. Te~npoml Logrc 111 .5’pec~~fr;cut1on. LN(3, \;ol. 3%. Sprilqyr-Verlag. 75 123. KABANZA 169
|
1990
|
23
|
938
|
and Retrieval During Plan Reuse: ation Structure Based Approach Subbarao Kambhampati* Center for Design Research and Department of Computer Science Stanford University Bldg. 530, Duena Street, Stanford CA 94305-4026 e-mail: rao@sunrise.stanford.edu Abstract Effective mapping and retrieval are important issues in suc- cessful deployment of plan reuse strategies. In this paper we present a domain independent strategy for ranking a set of plausible reuse candidates in the order of cost of modifying them to solve a new planning problem. The cost of modification is estimated by measuring the amount of distur- bance caused to the validation structure of a reuse candidate if it were to be reused in the new problem situation. This strategy is more informed than the typical feature based re- trieval strategies, and is more efficient than the methods which require partial knowledge of the nature of the plan for the new problem situation to guide the retrieval process. We discuss the implementation of this retrieval strategy in PRIAR, a framework for flexible reuse and modification in hierarchi- cal planning. I. Introduction The utility of reusing existing plans to solve new planning prob- lems has been realized early in the planning research, and has more recently received considerable attention in case-based rea- soning [6,1]. A major obstacle to successful deployment of plan reuse schemes has been the problem of plan retrieval and mapping. Retrieving an appropriate plan that can be efficiently reused in the current problem situation, and choosing an appropriate mapping between the objects of the existing plan and the objects of the new planning problem is generally very hard [ 151. The payoff from plan reuse depends crucially on both the cost of retrieval and mapping, and the the cost of modifying the retrieved plan to solve the new problem. Thus, for reuse to be effective, the similarity metrics used should be capable of evaluating the ease of modifying an existing plan to solve the new problem, rather than merely measuring surface similarity. For efficiency reasons, most typical retrieval stra- tegies employ straight forward feature matching or domain dependent indexing schemes. Such schemes do not accurately reflect the cost of reusing the retrieved plan in the new problem *The support of the Defense Advanced Research Projects Agency and the U.S. Army Engineer Topographic Laboratories under contract DACA76-88-C-0008, and that of Office of Naval Research under con- tract NOOO14-88-K-0620 are gratefully acknowledged. situation. To be effective, such strategies should also be able to take into account the expected match between the plans for the two problem situations. While the above limitations have been recognized, many of the proposed alternatives failed to be cost-effective as they require comparison of the solution derivations for the old and new problems (e.g., [2]). In this paper, we provide a partial solution for the retrieval and mapping problem that does not depend on any prior knowledge of the plan for solving the new problem. It makes an informed estimate of the cost of modify- ing a given plan to solve a new problem by analyzing how the internal dependencies of that plan will be affected in the new problem situation. It utilizes a novel representation of the inter- nal dependency structure of the plan for this purpose. This stra- tegy has been implemented in PRIAR, a framework for flexible reuse and modification of plans [ 10,9,11,13]. PRIAR utilizes plan validation structure, a systematic internal dependency representation of hierarchically generated plans, to guide and control all phases of reuse of a given plan in a new problem situation. In PRIAR, plan modification is seen as a pro- cess of repairing the inconsistencies in the validation structure of an existing plan when it is interpreted in a new problem situa- tion. The cost of modification process depends upon the number and type of these inconsistencies. The retrieval strategy esti- mates the number inconsistencies for each reuse candidate, and rank orders the candidates based on that estimate. This ordering is facilitated through the development of the notion of the plan kernel of a plan. The plan kernel provides a way of encapsulat- ing the validation dependencies between a plan and its problem specification. In the rest of the paper, we briefly discuss PRLlR’s validation structure based plan reuse framework, and describe its plan kernel based ordering strategy for choosing among reuse candidates. 2. verview of PRIAR Plan Modification Frame- work 2.1. Validation Structure In PRZAR framework the building blocks of the stored plan dependency structure are validations. A validation is a 4-tuple (E ,n,,C ,nd) where the effect E of the task n, (called source node) in the hierarchical task network (HTN) is used to satisfy (support) the condition c of task nd (called destination node). 170 AUTOMATED REASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. For any plan synthesized by a hierarchical planner, there are a finite set of validations, corresponding to the protection intervals [3] that are maintained during planning; we denote this set by V. The individual validations are classified depending on the type of the conditions they support. Figure 1 shows the validation structure of the plan for solving the blocks world problem 3BS (shown in the figure). Validations are represented graphically as links between the effect of the source node and the condition of the destination node. (For the sake of exposition, validations supporting conditions of the type BZock(?x) have not been shown in the figure.) For example, (On (B ,C ),nls,On (B ,C ),n,) is a validation belonging to this plan since the condition On (B ,C ) is required at the goal state nc; , and is provided by the effect On (B ,C ) of node nrs. The uniqueness of PRIAR framework is in the way the plan validations are stored on the HTN. Each task n in the HTN is annotated with the set of validations that are supplied by, con- sumed by, or necessarily preserved by the tasks belonging to the sub-reduction (hierarchical wedge) rooted at n. We call these the external effect conditions (e-conditions), external precondi- tions (e -preconditions) and persistence conditions (p -conditions) respectively of task n. The annotations on a node encapsulate the node’s role in the validation structure of the plan. These annotations are computed efficiently for each node in the HTN in a bottom-up, breadth-first fashion at the planning time. In [lo], we provide a 0 (N2) algorithm (where N is the length of the plan) for doing this. Using the task annotations introduced before, PRIAR also defines the notion of the validation state preceding and follow- ing each primitive executable action in the plan. They specify the set of validations that should hold at each point during the IFf nnn p$L$i-j IA” B”c ’ 2 hut Situation plan execution for the rest of the plan to have a consistent vali- dation structure (thereby guaranteeing its successful execution). Of particular interest for the PRIAR retrieval strategy are the vali- dation state following the initial node in the JJTN, denoted by AS (n,), and the one preceding the goal node, denoted by AP (% ). The former contains all validations which are provided by the initial node, nf and the latter contains all the validations which are consumed by the goal node, no. The annotated validation structure effectively provides a hierarchical explanation of correctness of the plan with respect to the planner’s knowledge of the domain. In PRIAR, the valida- tion structure is used (i ) to locate the parts of the plan that would have to be modified, (ii ) to suggest appropriate modification actions, (iii) to control the modification process such that it changes the existing plan minimally to make it work in the new situation, and (iv ) to assist in plan mapping and retrieval. 2.2. Plan Modification via Annotation-Verification Given a plan to be reused to fit the constraints of a new problem situation, PRIAR fist maps the plan into the new problem situa- tion. This process, known as interpretation, marks the differences between the plan and the problem situation. These differences in turn are seen to produce inconsistencies in the plan validation structure (such as missing, failing, or redundant validations). In PRIAR framework, a plan is modified in response to inconsistencies in its validation structure. PRIAR uses a pro- cess called annotation-verification to suggest appropriate modification to the plan for removing those inconsistencies from the validation structure of the plan. These domain independent modifications depend on the type of the inconsistencies and On(A,B)SOn(B,C) On(A,Table)&Clear(A) &On( B,Table)&Clear( B) &On(C,Table)&Clear(C) Block(A)&Block(B)&BIock(C) input state Sch: Make-on(A,B) I goal state “G r 7 Figure 1. Validation structure of 3BS plan KAMBHAMPATI 17 1 involve removal of redundant parts of the plan, exploitation of any serendipitous effects of the changed situation to shorten the plan and addition of high level refit tasks to re-establish any failing validations. At the end of the annotation-verification, which is a polynomial time process process [lo], PRIAR will have a partially reduced plan with a consistent validation struc- ture. PIuAR’s hierarchical nonlinear planner accepts this partially reduced plan and produces a completely reduced m. The planner uses a conservative heuristic search control strategy called task kernel-based ordering (see [9]) to control this pro- cess of refitting, so as to localize the modification to the plan and preserve as many of its applicable portions as possible. (Further details of PRIAR modification process can be found in a companion paper [13] in this proceedings.) 3. Mapping and Retrieval in PRIAR In this section we will assume that PRIAR is given a new prob- lem Pn=[I” ,G “1 and a set of reuse candidates {(R O ,a)}, where R” is an existing plan and a is a mapping between the objects of R” and P" . PRIAR currently performs a partial unification on the goals of R” and P” to get an initial set of reuse candidates. This strategy is described in [lo], and is not of particular interest for the purposes of this paper. Here we will concentrate on strategies that exploit the validation structure of the plans to efficiently rank the initial set of reuse candidates in the order of the cost of modiig them to solve the new problem. The heuristic cost metric of each reuse candidate (R” ,01) is computed in terms of the number and type of validations of R” that will be failing in P” , for the mapping a. We detie the notion of plan kernel of a reuse candidate to facilitate efficient computa- tion of this cost metric. The degree of match between the plan kernel of the reuse candidate and the new problem situation will be used to guide the ordering. 3.1. Plan Kernels The plan kernel of a stored plan R” , PK (R” ), is intended to encapsulate the dependencies between R” and the features of its input and goal specification. We will formulate it as a collec- tion of validations of R” that are supported by or supporting the features of the input and goal states of the plan. These valida- tions are further divided into three categories based on the expected difficulty of re-establishing them, in the event that the input and goal state features on which they are dependent no longer hold in the new planning situation. Thus, we define it as a three tuple PK (R O ) = (g-features, f-features, PC-features) where the g-features, f-features and PC-features are in turn defined as follows: g-features (Goal Features): These correspond to the valida- tions of R” that directly support its goals. Thus g-features(PK (R O )) = AP (no ) (where AP (no ) is as defined in the previous section.) f-features (Filter Features): These correspond to the valida- tions supported by the input specification of R” to either the filter conditions (the unachievable applicability conditions) of the plan, or the phantom nodes that achieve some main goal of R”. Thus, a validation v:{E,nf,C,~) belongs to f- features(PK (R” )), iff v E A’ (Q) and either C is a filter con- dition or +‘:(E’,nd,C ‘,no) E AP (no) such that nAt = nd jiC=C’ pc-features (Precondition Features): These correspond to the the validations supported by the input specification of R” that support either the preconditions of some node of R” , or the phantom nodes achieving the preconditions of some node of R”. In the current framework, these will essentially be all the validations of A”(Q) that are not included in the f-features of the plan kernel. That is, pc-features(PK (R O )) = (v Iv E A”(nl) A vef-features(PK(R”))) Based on the above definition, the plan kernel of a plan can be computed in a straightforward fashion from the initial validation state A”(nl) and the final validation state AP (no ) of that plan. As an example, the plan kernel of 3BS plan shown in figure 1 will be: PK(3BS) = 9-features’ (on (A J hn 16,on (A & hn,) { (On (B ,C ),n Is,On (B ,C ),n,) (Block (B >,q ,Block (B hn 15) (Block CB h &lock (B h6) ‘features i (Block (A h Block (A h6) (Block (C >,nr ,Block (C ),n 15) (On (B ,Table ),nr ,On (B ,?x >,n 15) (On (A ,Table ),q ,On (A ,?n),nl6) k Clear (B ),nr ,Clear (B ),nb) pc-featwes’ (Clear (B ),nr ,Clear (B ),n,) t (Clear (C ),rq ,Clear (C ),ng) (Clear (A ),rq ,Clear (A ),nT) Notice that the different features of the problem specification enter the plan kernel only by virtue of the validations that they provide to the plan Moreover, if any features support multiple validations, they enter the plan kernel once for each of these validations. For example, the features Block(B ) and Clear (B ) enter PK(3BS ) more than once. Thus, the number of times a feature enters the plan kernel, and the type of validations it sup- ports implicitly reflect the relative importance of that feature during retrieval. 3.2. Plan Kernel Based Ordering of Reuse Candi- dates The degree of match between the plan kernel of a reuse candi- date and the input and goal specification of a new planning problem gives a rough indication as to how much of that plan would be applicable to the new problem and as to what type of validation failures would arise when it is reused in the new problem situation. Since the refitting cost depends to a large extent on the number and type of validation failures, it is rea- sonable to use this match to estimate the amount of modification that would be needed for reuse. Below we describe a three lay- ered ordering procedure to rank a set of reuse candidates with the help of their plan kernels. The procedure measures the difficulty of reusing the given plan in the new problem situation by estimating the number of inconsistencies that will arise in the validation structure of a plan because of the problem differences. Given. The new problem P” =[I” ,G” 1, and a set of reuse can- didates {(R O ,a) ) . StepO. The plan kernels of the reuse candidates are computed by translating the plan kernels of the corresponding plans, using the mapping. That is, PK((R”,or)) = R” *a, where “.” 172 AUTOMATEDREASONING refers to the operation of object substitution. Step 1. The reuse candidates are ranked based on of goals of P” that will not be supported by the g the number -features of the plan kernels of individual candidates. for this layer of ordering will be given by The cost function g-features(PiY ({R O ,a))) s.t. (whereF l--f istrueifff can be deductively inferred from F and the domain axioms.) Based on this step, the best candi- dates are those which will need to achieve the least number of extra goals to be reused in the new problem situation. Step 2. If more than one candidate is ranked best by the ord- ering of step 1, then the best candidates are ranked further based on the number of f-features of their plan kernels that do not hold in the input specification of the new problem. Thus the cost function for this layer is given by 1 (v Iv :(E ,nI ,C ,nd) E fifeatures(PK({RO ,a))) A I” I+-C ) 1 Step 3. Finally, the best ranked candidates in the ordering of step 2 are further rauked by the number of PC-features of their plan kernels that do not hold in the input state of the new problem. Thus, the cost function for this layer is given by 1 (v :(E ,nI C ,nd) 1 v E pc-features(PK(<R” ,a))) A I” I-K } I The best ranked reuse candidates at the end of this three layer ordering procedure are returned as the preferred candidates for reuse in solving P” . Remarks: Even if an old plan matches all the goals of P”, it may still be an inappropriate candidate for solving P” since the methods it uses to achieve those goals may not be applicable in the new problem situation. This, for example, is the case when a filter condition of the schema used to reduce the task achiev- ing a goal in R O is no longer true in P” , or the phantom goal node that achieved a goal in R” can no longer stay phantom in P”. The ranking with respect to f-features, carried out in step 2, essentially attempts to prefer candidates which will not have validations supporting such failing filter conditions or failing phantom goals. The implicit levels of importance attached to the validations at different layers of the plan kernel can be justified in terms of the computational effort needed for re-establishing them in the new problem situation. The main heuristic is -that a significant amount of task reduction and interaction resolution would be required to generate subplans to achieve goals of the new prob- lem that are not supported by the retrieved plan, or to replace subplans of the retrieved plan with failing filter conditions, in contrast to the effort required to reachieve the failing precondi- tions. The second heuristic is that in the event of filter condi- tion failwe, it is possible that to exploit some of the previous planning effort (e.g., effort expended in establishing the e- preconditions of the sub-reduction being replaced) in the new planning situation (see [lo]). For this reason, the failing filter conditions are considered less costly to handle than new goals. 3.3. Example Figure 2 shows the initial and goal state specification of 4BS1, a blocks world problem and lists four possible reuse candidates for that problem. For each reuse candidate, the figure shows the the initial and goal state specifications, the mapping between the candidate and the 4BSl problem, and the plan kernel of the reuse candidate (as an exercise, compare the plan kernels of the reuse candidates (3BS ,[A +L ,B +K,C -41) and 6 3BS,[A-+K,B+J,C+I]) with PK(3BS ) specified previously). or ease of exposition, the figure shows the validations of the plan kernels only by their supporting effects. It does not include facts of type Block(?x) in the specifications of the problems. Similarly, it also does not explicitly show the validations of the type (Block(?x),-,-,-). When these four reuse candidates are ordered with the help of their plan kernels, at the first layer the g-features of the plan kernels of all the reuse candidates fail to satisfy one goal each of the new problem (4BSl). Thus, they are all deemed equally costly at this layer, and all the candidates move to the ordering at the next layer. At this layer, the f -feature {On (B ,C ),-,-,-) of the plan kernel of {3BS-Phantom,[A +L $ -X,C +J]) is not preserved in the input state of the new problem (4BSl) as I” POn (B ,C ). (This basically means that the top level phantom goal of this reuse candidate has to be re-established if we want to use it to solve P” .) Similarly, the f -feature {Pyramid (L ),-,-,-) of the 41Ei: Init-state(l”): On (I .Tabfe). On(K .Table), On(L .Table). On (J ,L,), Clear(J), Clear(K). Clear (I), Goal-state(G “): On (L ,K). On (K .J), On (J J) Reuse Candidates ((R” ,a)) (3BS-Phantom. [A --+L ,B +K .C+J]): Init-state: On (A .Table), On (B $2). On (C ,Table), Clear (A ). Clear (B ) Goal-state: On (A 8). On@ .C) Plan: Put-Block-on-Block-Action(A ,B) PK(3BSPhantom)[A -L ,B -SK .C +J]: [g -features: (On (LX),-,-.-) On (K ,J).-,-.-) f -features: On (K J).-,-,- pc -features: \ 11 On (L .Table ).-,-.-) Clear(L).-.-.- Clear (K),-.-,-)I (3BS, [A +L ,B +K .C +J]): Init-state: On (A ,Table).On (E ,Table),On (C ,Table ).Clear (A),Clear (B ),Clear (C) Goal-state: On (A ,B), On@ ,C) Plan: Put-Block-on-Block-Action@ ,C)-+Put-Block-on-Block-Action(A ,B) PK(3BS)$A 4. ,B +K ,C-+J]: [g-features: (On (L ,K),-.-.-) f -features: (On (K +I),-.-,-) pc -features: (On (L ,Table ),-,-.-) (On (K ,Table),-.-.-) {Cfear (L ),-.-.-) (Clear (K).-.-.-) (Clear (J).-,-,-) ] (3BS. [A +K ,B +J .C +I]): Init-state:On (A ,Table),On (B .Table).On (C .Table ),Clear (A ),Clear (B ),Clear (C) Goal-state: On (A ,B), On (B C) Plan: Put-Block-on-Block-Action@ ,C)+Put-Block-on-Block-Action(A 8) PK(3BS)$A -+K ,B +J $2 -+I]: (g -features: (On (K J).-,-,-} f-features: \ (On (J 4 ),-,-,-) pc -features: On (J ,Table ),-.-,-) (On (K .Table ),-,-.-) Clear (I),-,-,-) (Clear (K),-,-,-) (Clear (J).-.-,-)I (3BS-PyramidJA -+L ,B +K $2 -*I I): Init-state: On(A ,Table), On (E .Table). On (C,Table), Clear (A), Clear (B ). Clear (C ). Pyramid (A ) Goal-state: On (A 8). On@ .C) Plan: Put-Block-on-Block-Action@ .C)+Put-Pyramid-on-Block(A J ) PK(3BS-Pyramid)$A +L ,L3 +K ,C+J]: [s -features: (On (L ,K),-,-.-} f-features: (On (K J).-,-,-) (F’yramid(L),-,-,-} (On (L ,Table ),-,-,-) pc -features: (On (K ,Table ),-,-,-) (Clear (K),-,-.-) (Clear (J).-;-,-)I Figure 2. Example for Plan Kernel Based Qrdering KAMBHAMPATI 173 kernel of the Pyrarnid,[A +L ,B +K ,C +J]) reuse is not candidate preserved (3BS- since I” tfpyramid (L ). If we wmi to solve 4BS 1 by this reuse can- didate, the sub-reduction dependent on this filter condition would have to be replaced. Further, the f-feature On (J ,Table ),-,-,-) t 1 of the plan kernel of the reuse candidate 3BS,[A-+K,B-+J,C-+Z]) is not preserved since I” I+ On (J,TabZe ). In contrast, none of the f -features of the reuse candidate (3BS ,[A +L ,B +K,C +J]) fail to hold in the new problem situation. Thus, this is ranked best by the ordering based on the f-features of the plan kernel. Since this is the only best ranked candidate, the ordering at the third layer is not required and (3BS ,[A +L ,B -+K ,C +J]) is returned as the pre- ferred reuse candidate for solving the problem 4BSl. Notice that the plan kernel based ordering is able to discrim- inate among these reuse candidates even though all the candi- dates satisfy the same number of goals of P”. Further, as we mentioned earlier, it is capable of discriminating among different plans as well as different mappings of the same plan. In the current example, candidates (3BS ,[A +L ,B +K ,C -+J]) iii (3B:;:K$3 -+J,C +Z]) correspond to two different mappings of the same (three blocks) plan. We have seen that the ordering prefers one of the map- pings over the other. 3.4. Cost Overestimation in the Ordering Heuristic annotation verification process, after a reuse candidate is selected (see prune-validation process in [lo]). Thus, to even- tually avoid overestimation of cost, the annotation verification procedure would have to be carried out partially before the reuse candidates are ranked by the plan kernel based ordering. Even though the annotation verification process is only a polynomial time process, we feel that using it during mapping and retrieval stage may still be too expensive. Because of thii, we retained the overestimating heuristic in the current implementation of PRL4R. However, this can be changed easily if required. 3.5. Refinements to Plan Kernel Based Ordering The informedness of the ordering procedure presented in section 3.2 can be further improved by exploiting the hierarchical struc- ture of the plan. In particular, the notion of the level of a vali- dation can be used as a means of differentiating further among the validations of the individual layers of the plan kernel (in terms of the estimated difficulty of re-establishing them in the event they are not preserved in the new problem situation). The level of a validation is defined as the reduction level at which that validation is first introduced into the HTN (see [lo] for the formalization of this notion). For example, in figure 1, the validation (BZock(A ),nl ,BZock (A ),nre) is considered to be of a higher level than the validation 6 On (A ,TabZe ),q ,On (A ,TabZe ),n 16), since the former is intro- uced into the HTN to facilitate the reduction of task n3 while the latter is introduced during the reduction of task ng. A useful characteristic of hierarchical planning is that its domain sche- mas are written in such a way that the more important condi- tions are established at higher levels, while the establishment of less important conditions is delegated to lower levels. Thus, the level at which a validation is first introduced into an HTN can be taken to be predictive of the importance of that validation, and the effort required to (re)establish it.2 The validation levels can be pre-computed efficiently at the time of annotation. To improve the informedness of the heuristic ordering, we can weight the validations of individual layers by their levels. The cost functions of the ordering procedure will then compute the weighted sum of the number of failing validations. For example, the cost function for the f-feature based ordering step in section 3.2 would now become c level(v), where In A = {v :(E ,nl,C ,nd) 1 v E f-features(PK ((R” il)) R I” t+C } . the current example this would mean that the failure of the vali- dation (Bzock(A ) n’$zock(A ) n 9 I 9 16 ) would be considered more costly than the failure of the validation (On (A ,TabZe ),n, ,On (A ,TabZe ),n 16) This is reasonable since the former necessitates the relacement of a larger sub-plan (the sub-plan rooted at ns) than the latter (which only leads to the replacement of the sub-plan rooted at ng; see figure 1). 4. Related Work A limitation of the plan kernel-based heuristic ordering strategy as discussed in the previous section is that it sometimes overes- timates the cost of reusing a plan in the new situation by count- ing some spurious inconsistencies. This happens when parts of the reuse candidate are rendered redundant in the new problem situation. For example, when the reuse candidate supports some unnecessary goals (the goals which are satisfied by the reuse candidate but are not required in the new planning situation), some of the failing validations may actually be supporting the parts of the plan whose sole purpose is to help achieve the unnecessary goal. Such failing validations should obviously not be counted as inconsistencies, as they can eventually be removed from the HTN and thus do not have to be re-established. As an example, suppose that we are judging the appropriateness of reusing the 3BS plan, shown in figure 1, in a new problem situation where there is no match for the goal On (A ,B ) (i.e., it . not required). czem (A h Clear (A > In) such . . a case’ *e ‘vhdahon ,n16 cannot be counted as a farhue, even if CZear (A ) is not true in the initial state of the new problem- this validation, being an e-precondition of the node n3:A [On (A ,B )], will be pruned away eventually thus making its failure inconsequential. Similar situation arises when some of the goals and sub-goals of the reuse candidate are directly satisfied in the input situation of the new problem (see p - phantom validations in [lo, 131). To avoid overestimation in these cases, the parts of the plan that are rendered redundant in the new problem situation would have to be removed, even Research in analogical problem solving has shown that the before reuse candidates are ordered by the plan kernel based appropriateness of reusing a previous problem’s solution to ordering. In PRTAR, this type of pruning is done only during solve a new problem cannot be accurately judged through a 1 We follow the convention of [20] and classify O~(J ,?x) as a filter condition rather than a precondition. Some effects of the plan depend on the binding of ?X and one way of correctly propagating the effects when the binding of ?X changes is to re-reduce the corresponding task. 2 We assume that domain schemas having this type of abstraction property have been supplied/encoded by the user in the first place. What we are doing here is to exploit the notion of importance implicit in that abstraction. 174 AUTOMATEDREASONING simple matching of the problem specifications. However, the alternatives, such as the one proposed by Carbonell [2] in derivational analogy, tend to be very costly, as they require that the solution derivations rather than the problem specifications be compared during retrieval. To compare derivations, the new problem would first have to be partially solved by some non- analogical methods. The retrieval method proposed here falls in the middle ground as it does essentially feature based matching, but takes the validation structure of the solution into account during the matching. This latter characteristic gives it the ability to make a more informed estimate of the importance of indivi- dual feature matches on the cost of the overall modification. The principle motivation behind our strategy is that mapping and retrieval should be guided by the features of the existing plans that are predictive of the amount of modification required to reuse them in the new problem situation. In this sense, it has some similarities to the CHEF [6] retrieval strategy which gives importance to the features that are predictive of execution time failures and interactions. However, in contrast to CHEF, which learns the features predictive of the interactions (through an explanation based generalization of execution time failures), PRIAR uses the existing validation structure of the plan to decide the relative importance of the individual features. To some extent, this difference is a reflection of the differing nature of the tasks that are addressed by the two systems-while PRIAR tries to modify plans in the presence of a generative planner, and ensure correctness of the modification with respect to that planner, CHEF relies on the heuristic modification of the retrieved plans and tests the correctness through a domain model based simulation. 5. Conclusion Gur main contribution to the mapping and retrieval problem is a domain independent heuristic strategy for utilizing the validation structure of the stored plan to decide the appropriate- ness of reusing it in a new problem situation. The central idea is to estimate the cost of modifying the plan to solve the new problem, and prefer the candidate with least expected modification cost. The modification cost is estimated by measuring the amount of disturbance that would be caused to the validation structure of a reuse candidate in new problem situation. We have discussed the implementation of this retrieval strategy in PRIAR, a framework for flexible reuse and modification of plans. We argued that our strategy is more informed than the typical feature based retrieval strategies, and more effkient than the methods which require partial knowledge of the nature of the plan for the new problem situation to guide the retrieval process. Retrieving plans based solely on the plan kernel based ordering may still be too expensive when the plan library is very large. In such cases, the initial retrieval of candi- date plans, prior to the plan kernel based ordering may have to be based on a domain dependent retrieval strategy. However, the plan kernel based ordering strategy can act in conjunction with such a gross feature-based retrieval strategy to make a more informed estimate of the utility of reusing a plan in the given problem situation. References 1. R. Alterman, “An Adaptive Planner”, Proceedings of 5th AAAZ, 1986, 65-69. 2. J. 6. Carbonell, “Derivational Analogy and its Role in Problem Solving”, Proceedings of AAAI, Washington 3. 4. 9. 10. 11. 12. 13. 14. 15. 16. 17. 18. 19. 20. 21. 22. D.C., 1983, 64-69. E. Charniak and D. McDermott, “Chapter 9: Managing Plans of Actions’ ‘, in Introduction to ArtiftciaZ Intelligence, Addison-Wesley Publishing Company, 1984, 485-554. L. Daniel, “Planning: Modifying non-linear plans”, DAI Working paper 24, University of Edinburgh, December 1977. (Also appears as “Planning and Operations Research, *’ in Artificial ZnteNigence: Tools, Techniques and Applications, Harper and Row, New York, 1983). R. Fikes, P. Hart and N. Nilsson, “Learning and Executing Generalized Robot Plans’ ‘, Artificial Intelligence 3 (1972), 251-288.. K. J. Hammond, “CHEF: A Model of Case-Based Planning”, Proceedings of 5th AAAI, 1986, 267-271. P. J. Hayes, “A Representation for Robot Plans”, Proceedings of 4th ZJCAI, 1975. M. N. Huhns and R. D. Acosta, “ARGO: A System for Design by Analogy”, IEEE Expert, Fall 1988, 53-68. (Also appears in Proc. of 4th IEEE Conf. on Apple. of AI, 1988). S. Kambhampati and J. A. Hendler, “Control of Refitting during Plan Reuse’ ‘, I1 th International Joint Cortference on Artificial Intelligence, Detroit, Michigan, USA, August 1989.943-948. S. Kambhampati, “Flexible Reuse and Modification in Hierarchical Planning: A Validation Structure Based Approach*‘, CS-Tech. Rep.-2334, CAR-Tech. Rep.-4698, Center for Automation Research, Department of Computer Science, University of Maryland, College Park, MD 20742, October 1989. (Ph.D. Dissertation). S. Kambhampati and J. A. Hendler, “Flexible Reuse of Plans via Annotation and Verification’ ‘. Proceedings of 5th IEEE Conf. on Applications of Artificial Intelligence, 1989, 37-44. S . Kambhampati, “Mapping and Retrieval during Plan Reuse: A Validation-Structure Based Approach”, Proceedings of Eighth AAAZ, Boston, MA, 1990. S . Kambhampati, “A Theory of Plan Modification”, Proceedings of Eighth AAAI, Boston, MA, 1990. J. L. Kolodner, “Maintaining Organization in a Dynamic Long-term Memory”, Cognitive Science 7 (1983), 243- 280. J. L. Kolodner, ‘ ‘Reconstructive Memory: a Computer Model”, Cognitive Science 7 (1983), 281-328. J. L. Kolodner, “Case-Based Problem Solving’*, Proceedings of the Fourth ZnternationaZ Workshop on Machine Learning, University of California, Irvine, June 1987, 167-178. E. D. Sacerdoti, A Structure for Plans and Behavior, Elsevier North-Holland, New York, 1977. R. Simmons, “A Theory of Debugging Plans and Interpretations”, Proceedings of 7th AAAI, 1988, 94-99. A. Tate, “Project Planning Using a Hierarchic Non-Linear Planner”, Research Report 25, Department of AI, University of Edinburgh, 1976. A. Tate, “Generating Project Networks”, Proceedings of 5th ZJCAI, 1977, 888-893. D. E. Wilkins, ‘ ‘Domain-independent planning: representation and plan generation”, Artificial Intelligence 22 (1984), 269. D. E. Wilkins, “Recovering horn execution errors in SIPE”, Computational Intelligence 1 (1985). KAMBHAMPATI 175
|
1990
|
24
|
939
|
A Theory of Plan Modification Subbarao Kambhampati* Center for Design Research and Department of Computer Science Stanford University Bldg. 530, Duena Street, Stanford CA 943054026 e-mail: rao@sunrise.stanford.edu Abstract We present a theory of plan modification applicable to hierarchical no&ear planning. Our theory utilizes the validation structure of the stored plans to yield a flexible and conservative plan modification framework The validation structure, which constitutes a hierarchical explanation of correctness of the plan with respect to the planner’s own knowledge of the domain, is annotated on the plan as a by- product of i&al planning. Plan modification is ch&cteri& as a brocess of remov&g inconsistencies in the validation structure of a &an when it is being reused in a new (changed) planning situation. The reuair of these -inconsistencies involves removing unnecessary pans of the plan and adding new non-primitive tasks to the plan to establish mi&g or failing validations. The resultant partially re- duced plan (with a consistent validation structure) is sent to the planner for complete reduction. We discuss the development of this theory in PMAR system, and characterize its completeness, coverage, efficiency and limitations. I. Introduction The ability to flexibly and conservatively modify existing plans to make them conform to the constraints of a new of changed planning situation is very useful in plan reuse, replanning and incremental planning. While the value of such capability has been acknowledged early in planning research [5,7], the stra- tegies developed were inflexible in that they could reuse or modify a given plan in only a limited number of situations, and could deal with only a limited variety of applicability failures. There was no general framework for conservatively modifying an existing plan to fit it to the constraints of a new problem situation. A major shortcoming with these approaches was that the stored plans did not represent enough information about the internal dependencies of the plan to permit flexible modification. For example, reuse based on macro-operators [5] built from sequences of primitive plan steps was unable to modify inter- mediate steps of the macro-operator, as macro-operators did not represent the intermediate decisions and dependencies corresponding to their internal steps. Even in cases where the need for the dependency information was recognized (e.g. [4,22]), a systematic representation and utilization of such struc- tures in plan reuse and modification was not attempted. *The support of the Defense Advanced Research Projects Agency and the U.S. Army Engineer Topographic Laboratories under contract DACA76-88-C-0008, and that of Office of Naval Research under con- tract NOOOl4-88-K-0620 are gratefully acknowledged. 176 AUTOMATEDREASONING We present a theory of plan modification that allows flexible and conservative modification of plans generated by a hierarchi- cal nonlinear planner. Hierarchical planning is a prominent method of abstraction and least-commitment in domain- independent planning [3]. Our theory of plan modification pro- poses validation structure as a way of representing the internal dependencies of a hierarchical plan and provides algorithms for annotating the validation structure on the plans during plan gen- eration. It systematically explores the utility of the annotated validation structure in guiding and controlling all the processes involved in flexible plan reuse and modification. The PRIAR plan modification system [9,11,10,12] is our implementation of this theory. The plan modification problem that is addressed in PRL4R is the following: Given (i ) a planning problem P ’ (specified by a partial description of the initial state I” and goal state G” ), (ii) an existing plan R” (generated by a hierarchical nonlinear planner), and the corresponding planning problem P”, Produce a plan for P” by minimally modifying R O. In the PRIAR reuse framework, the internal dependencies of a hierarchical plan which are relevant to guide its reuse and modification are formalized as the validation structure of the plan. The validation structure can be seen as a form of hierarchical explanation of correctness for the plan with respect to the planner. Individual tasks of the hierarchical plan are annotated with information about their role in the plan validation structure. PRIAR provides efficient algorithms for acquiring these annotations as a by-product of planning. When an existing plan is being reused in a new planning situation, the applicability failures, the redundancies, and the shortcomings that may arise in the process are formally charac- terized as inconsistencies in the plan’s validation structure. Reuse in the PRIAR framework is formally seen as a process of repairing the inconsistencies in the validation structure of a given plan when it is mapped into the new problem situation. Given the new problem P” , and an annotated plan R O, PRIAR'S reuse process proceeds in the following steps: (1) Mapping and Interpretation: An appropriate mapping a between the objects of [P” ,I? O ] and P” is computed, and R O is mapped into P” with it. Next, some important differences between P” and P” are marked. The resulting interpreted plan, R’, is typically a plan with an inconsistent validation structure. (2) Annotation Verification: The inconsistencies in the valida- tion structure of R’ are located, and appropriate repairs are From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. suggested. The repairs include removing parts of R’ that are unnecessary and adding non-primitive tasks (called reJit tasks) to establish any required new validations. The resulting annotation-verified plan R B will have a consistent validation structure but is typically only partially reduced. It consists of all the applicable parts of R’ and any refit tasks which are introduced. (3) Refitting: The refit tasks specified during the annotation verification phase constitute sub-planning problems for. the hierarchical planner. The refitting process involves reducing them with the help of the planner. Conservatism is ensured through the use of a heuristic control strategy which minimizes the disturbance to the applicable parts of R” during this pro- cess. Computational savings stem from the fact that the cost of solving the sub-planning problems during refitting is on the average much less than the cost of solving the entire planning problem from scratch. This is supported by the results of the empirical studies in blocks world, which showed that plan modification proveds 20-98% savings (corresponding to speedup factors of 1.5 to 50) over pure generative planning. This paper concentrates mainly on the development of the basic modiGcation framework; the details of mapping and refitting control strategies can be found in [9,12, lo]. The organization of this paper is as follows: Rest of this section pro- vides some necessary preliminaries of hierarchical planning. Section 2 presents the notion of plan validation structure, explains the motivation behind remembering it along with each generated plan, and presents a scheme for annotating it on the plan. Section 3 develops the basic modification processes, and explains how they utilize the plan validation structure. Section 4 contains a discussion completeness, coverage and efficiency of PRLAR modification theory and section 5 provides a brief discus- sion of related work. 1.1. Preliminaries This paper makes extensive use of the concepts of hierarchical planning paradigm. A good introduction to this methodology can be found in [3]. Some well known hierarchical planners include NOAH [ 171, NONLIN [20] and SIPE [21]. In hierarchical planning, a partial plan is represented as a task network. A task network is a 3-tuple T,O ,I$ where T is a collection of tasks, 6 0 defines a partial or ering over T, and ll is a set of protection intervals. A protection interval is a 3-tuple (E,tl,t2), where tl,t2 E T, E is an effect of fi, and E has to necessarily persist up to I 2 [3]. Planning proceeds by selecting a task from the current task network and reducing it with the help of a task reduction schema to more concrete subtasks. This reduction may introduce some harmful interactions with the existing pro- tection intervals, which are handled by introducing additional partial ordering relations among the tasks. The planner cannot reduce certain distinguished tasks of the domain called primitive tasks. (It is assumed that the planner ~‘knows” how to execute such tasks.) Further, if all the required effects of a task are already true in a given partial plan, then that task does not have to be reduced any further (such tasks are called phantom goals [3]). A task network is said to represent a completed pZan when none of its tasks have to be reduced further. The hierarchical development of a plan P :(T,O $I) is cap- tured by its hierarchical task network (abbreviated as HTN) . A HTN is a 3-tuple, (P:(T,O,n) ,T*,Ll), where T’ is a superset of T, and D deties a set of parent-child relations among the tasks of T*. (The immediate children of a task t are the tasks that resulted from its reduction during planning.) For conveni- ence, we will be referring to T’, the tasks of the HTN, also as its nodes. We shall refer to the number of leaf nodes in a HTN (IT I) as the length of the corresponding plan, and denote it by Np. For the sake of uniformity, we shall assume that the HTN has two special primitive bodes nI,nc E T* , corresponding respectively to the input state and the goal state of the planning problem. We shall use the notation “nl < n2” (where ni and n2 are nodes of HTN) to indicate that n i is ordered to precede n2 in the partially orderered plan represented by the HTN. Simi- laq, “nl > n2” denotes that nl is ordered to follow n2, and “ni // n2” denotes that there is no ordering relation between the two nodes (n, is parallel to nz). The set consisting of a node n and all its descendents in the HTN is called the sub-reduction of n, and is denoted by R (n). Following [3,20], we also distin- guish two types of plan applicability conditions: the precondi- tions (such as CZeur (A ) in the blocks world) which the planner can achieve, and the filter conditions (such as BZock(A ) in the blocks world) which the planner cannot achieve. Finally, we shall use the notation “F I- f ” to indicate that f deductively follows from the set of facts in F. 2. Validation Structure and Annotations 2.1. Validation Structure 52.1. Validation: A validation is a 4-tuple (E, n,, C, nd), where n, and nd are leaf nodes belonging to the HTN, and the effect E of node n, (called the source) is used to satisfy the applicability condition C of node nd (called the destination). C and E are referred to as the supported condition and the sup- porting efsect respectively of the validation. As a necessary con- dition for the existence of a validation v, the partial ordering among the tasks in HTN must satisfy the relation riseid. The type of a validation is defined as the type of the applicability condition that the validation supports (one of j2fer condition, precondition, phantom goal). Notice, from section 1.1 that every validation v : (E, n,, interval [3] {E ,n, ,nd). C , nd) corresponds to a protection This correspondence implies that there will only be a finite set of validations corresponding to a given HTN representing the development of a plan; we shall call this set V. (If 5 is the maximum number of applicability conditions for any action in the domain, then IV1 is o(&Vp) [lo].) Figure 1 shows the validation structure of the plan for solv- ing a block stacking problem 3BS (also shown in the figure). Validations are represented graphically as links between the effect of the source node and the condition of the destination node. (For the sake of exposition, validations supporting condi- tions of the type BZock(?x) have not been shown in the figure.) For example, (On (B ,C ), n15,On (B ,C ),nc) is a validation belonging to this plan since On (B ,C ) is required at the goal state n, , and is provided by the effect On (B ,C ) of node ni5. 52.2. Inconsistencies and Consistency of Validation Struc- ture: A validation v :(E ,n, ,C ,nd) is considered a failing valida- tion if either E 6 effects (n, ) or when there exists a node n E HTN such that n possibly falls between n, and nd. A vali- dation v: (E, n,, C, nd) is considered an unnecessary validation iff the node nd does not require the condition C . (This could happen, for example, if a goal of the plan is no longer necessary in the current problem situation.) Finally, we say that there is a KAMBHAMPATI 177 On(A,B)&On( B,C) On(A,Table)&Clear(A) &On( B,Table)&Clear( B) &On(C,Table)&Clear(C) Block(A)&Block(B)&Block(C) input state “I Inl:r\lOnis,CJI, /n3: AlOn(A,B)J t I I Input Situation Goal p” 3BS - -- .- -.- goal state ?c I Sch: Make-on(B.CJ Sch: Make-on(A,B) eff: On(A,B) \ \ validations r” 7 Figure 1. Validation structure of 3BS plan missing validation corresponding to a condition, node pair (C’,n’l of the EITN iff sv: (E, n,, C, nd) s.t. C=C’Rnd=n’. applicability conditions of the nodes that lie outside the sub- reduction. Thus, E-conditions(n) = The unnecessary, missing or failing validations in a HTN will be referred to as inconsistencies in its validation structure. An HTN is said to have a consistent validation structure if it does not have any inconsistencies. From these defkritions, it should be clear that in a HTN with a consistent validation structure, each applicability condition of a node (including each goal of no) will have a non-failing validation supporting it. (Thus, a com- pletely reduced HTN with a consistent validation structure consti- tutes a valid executable plan.) 2.2. Annotating Validation Structure Having developed the notion of validation in a plan, our next concern is representing the validation structure of the plan locally as annotations on individual nodes of a HTN. The intent is to let these annotations encapsulate the role played by the sub-reduction below that node in the validation structure of the overall plan, so that they can help in efficiently gauging the effect of any modification at that node on the overall validation structure of the plan. We achieve this as follows: For each node n E HTN we define the notions of (i ) e-condition.+ ), which are the externally useful validations supplied by the nodes belonging to R(n) (the sub-reduction below n) (ii) e-preconditions(n), which are the externally established validations that are con- sumed by nodes of R (n ), and (iii ) p-conditions(n), which are the external validations of the plan that are required to persist over the nodes of R (n). {vi: (E, n,, C, nd) IvieV; n,ER(n); nde R(n) ) For example, the e-conditions of the node It3 in the HTN of figure 1 contains just the validation (On (A ,I3 ), n16, On (A $ ), nc) since that is the only effect of R (n3) which is used outside of R (n3). The e-conditions provide a way of stating the exter- nally useful effects of a sub-reduction. They can be used to decide when a sub-reduction is no longer necessary, or how a change in its effects will affect the validation structure of the parts of the plan outside the sub-reduction. 52.4. E-Preconditions (External Preconditions): The e - preconditions of node n correspond to the validations supporting the applicability conditions of any node of R(n) that are satisfied by the effects of the nodes that lie outside of R(n). Thus, E-preconditions(n) = {vi: (E, n,, C, nd) 1 VieV; ndER(n); n,q R (n) } For example, the e-preconditions of the node ns in the HTN of figure 1 will include the validations (Clear (A ), nf, Clear (A ), n71 and (Clear (B ), nf , Clear (B ), ns). The e-preconditions can be used to locate the parts of rest of the plan that will become unnecessary or redundant, if the sub-reduction below this node is changed. 52.5. P -Conditions (Persistence Conditions): P-conditions of a node n correspond to the protection intervals of the HTN that are external to R(n), and have to persist over some part of R(n) for the rest of the plan to have a consistent validation structure. We define them in the following way: $2.3. E-Conditions (External Effect Conditions): The e- A validation vi: (E, n,, C, nd)EV is said to intersect the conditions of a node n correspond to the validations supported sub-reduction R (n) below a node n (denoted by “v 63 R(n)“) by the effects of any node of R (n ) which are used to satisfy if there exists a leaf node n E R (n ) such that n possibly falls 178 AUTOMATEDREASONING between n, and nd (for some total ordering of the tasks in the HTN). Using the definition of validation [lo], we have vi: {E, n,, C, Q) Q9 R(n) iff E R (n) s.t. children (n’)=0 A 1 A validation vi : {E, n,, C , nd)EV is considered a p- condition of a node n iff Vi intersects R (n ) and neither the source nor the destination of the validation belong to R (n ). Thus, P-conditions(n) = (vi: (E, n,, C, nd)l VicV; n,,ndgr R(n); vi@R(n)} From this definition, it follows that if the effects of any node of the R(n) violate the validations corresponding to the p- conditions of n, then there will be a potential for harmful interactions. As an example, the p-conditions of the node n3 in the I-RN of figure 1 will contain the validation (On (B ,C hnldn (B ,C ),nG) since the condition On (B ,C ), which is achieved at n15 would have to persist over R (n3) to support the condition (goal) On (B ,C ) at nG . The p-conditions help in gauging the effect of changes made at the sub-reduction below a node on the validations external to that sub-reduction. This is of particular importance in localizing the refitting [9]. 2.3. Computing Annotations Jn the PRIAR framework, at the end of a planning session, the HZ+N showing the development of the plan is retained, and each node of the HTN is annotated with the following information: (1) Schema(n), the schema instance that reduced node n (2) e- preconditions(n ) (3) e-conditions(n ), and (4) p-conditions(n ). The node annotations are computed in two phases: First, the annotations for the leaf nodes of the I-RN are computed with the help of the set of validations, V, and the partial ordering rela- tions of m. Next, using the relations between the annotations of a node and its children (which can be easily derived from the definitions of the previous section; see [lo]), the annotations are propagated to non-leaf nodes in a bottom up breadth-first fashion. The exact algorithms are given in [lo], and are fairly straightforward to understand given the development of the pre- vious sections. The time complexity of annotation computation is 0 (IV:), where Np is the length of the plan (number of leaf nodes in the HTN). While the procedures discussed above compute the annota- tions of a HTN in one-shot, often during plan modification, PRIAR needs to add and remove validations from the HTN one at a time. To handle this, PRIAR also provides algorithms to update node annotations consistently when incrementally adding or deleting validations from the HTN. These are used to re-annotate the HTN and to maintain a consistent validation structure after small changes are made to the plan. They can also be called by the planner any time it establishes or removes a new validation (or protection interval) during the development of the plan, to dynamically maintain a consistent validation structure. The time complexity of these algorithms is 0 (Np ) [lo]. 3. Modification by Annotation Verification We will now turn to the plan modification process, and demon- strate the utility of annotated validation structure in guiding plan modification. Throughout the ensuing discussion, we will be following the simple example case of modifying the plan for the three block stacking problem 3BS (i.e., R”= 3BS) shown on the left side in figure 2 to produce a plan for the four block stacking A 11 1 1 r-a-i-H a B c input Sltuatcon Goal Input situatton Goal P” 38s p” 4BSl Figure 2.3BS+4BSl Reuse problem problem 4BSl (i.e., P”= 4BSl) shown on the right side. We shall refer to this as the 3BS+4BSl example. 3.1. Mapping and Interpretation In PRIAR, the set of possible mappings between [P”,Ro] and P” are found through a partial unification of the goals of the two problems. There are typically several semantically consistent mappings between the two planning situations, and selecting the right mapping can considerably reduce the cost of modification. The mapping and retrieval methodology used by PRIAR [ 10,121 achieves this by selecting mappings based on the number and type of inconsistencies that would be caused in the validation structure of R”. As the details of this strategy are beyond the scope of this paper, for the purposes of this paper, we shall sim- ply assume that such a mapping is provided to us. (It should be noted that this mapping stage will not be required if the objec- tive is to modify an existing plan in response to changes in its own specifications.) Once a mapping a is selected, the inter- preted plan R’ is constructed by mapping R” along with its anno tations into the new planning situation P” , and marking the differences between the specifications of the old and new &an- ning situations. These differences, marked in I’ and G’, serve to focus the annotation verification procedure on the inconsisten- cies in the validation structure of the interpreted plan. In the 3BS+4BSl example, let us assume that the mapping strategy selects a = [A +L ,I? +K,C +J] as the mapping from 3BS and 4BSl. With this mapping, Clear(L) is no longer true in the input specification of 4BSl. So it will be marked out in I’. The facts On (J ,L ), On (Z ,TubZe ) and Clear (I) are true in 4BSl but not in 3BS, so they will be marked as nav facts in I’. Similarly, as On(J ,Z) is not a goal of 3BS but is a goal of 4BS 1, it will be marked as an exfru goal in G’ . There are no unnecessary goals. At the end of this processing, Ri, I’ and Gi are sent to the annotation verification procedure. 3.2. Annotation Verification and Refit Task Specification At the end of the interpretation procedure, R’ may not have a consistent validation structure (see 92.2) as the differences between the old and the new problem situations (as marked by the interpretation procedure) may be causing some inconsisten- cies in the validation structure of R’ . These inconsistencies will be referred to as applicability failures, as these are the reasons why R’ cannot be directly applied to P” . The purpose of the annotation verification procedure is to modify R’ such that the result, R” , will be a partially reduced HTN with a consistent vali- dation structure. The annotation verification procedure achieves this goal by fhst localizing and characterizing the applicability failures caused by the differences in I’ and G’ , and then appropriately modifying the validation structure of R’ to repair those failures. KAMBHAMPATI 179 It groups the applicability failures into one of several classes depending on the type of the inconsistencies and the type of the conditions involved in those inconsistencies. The repairs are suggested based on this classification, and involve removal of unnecessary parts of the HTN and/or addition of non-primitive tasks (called refit tasks) to establish missing and failing valida- tions. The individual repair actions taken to repair the different types of inconsistencies are briefly described below; they make judicious use of the node annotations to modify R’ appropriately (see [lo, 121 for the detailed procedures). In [lo], we show that the time complexity of the annotation-verification process is polynomial (0 (IV INp3)) in the length of the plan. [I] Unnecessary Validations-Pruning Unrequired Parts: If the supported condition C of a validation v :(E,n,,C ,nd) is no longer required, then v can be removed from the plan along with all the parts of the plan whose sole purpose is supplying those validations. The removal can be accomplished in a clean fashion with the help of the annotations on R i. After removing v validation from the HTN (which will also involve incremen- tally re-annotating the HTN, see section 2.3), the HTN is checked for any node n,, that has no e-conditions. If such a node exists, then its sub-reduction, R (n,,) has no useful purpose, and thus its nodes can be removed from the HTN. This essentially involves backtracking over the task reductions in that sub-reduction, and removing any ordering relations that were introduced as a result of those reductions. This removal turns the e-preconditions of n,, into unnecessary validations, and they are handled in the same way recursively. [2] Missing Validations-Adding Tasks for Achieving Extra Goals: An extra goal is any goal of the new problem that is not a goal of the old plan, and thus is unsupported by any valida- tion in R’. The general procedure for repairing missing valida- tions (including the extra goals, which are considered conditions of nc) is to create a refit task of the form Achieve [G], and to add it to the HTN in such a way that it follows the initial node nf, and precedes the node which requires the unsupported condi- tion (in this case nc). Establishing a new validation in this way necessitates checking to see if its introduction leads to any new failing validations in the plan; the planner’s interaction detection routines are used for this purpose. Finally, the annotations of the nodes of the HTN are updated (with the help of incremental annotation procedures) to reflect the introduction of the new validation. [3] Failing Validations: The facts of I’ which are marked “out ” during the interpretation process, may be supplying vali- dations to the applicability conditions or goals of the interpreted plan R’. The treatment of such failing validations depends upon the types of the conditions that are being supported by the vali- dation. We distinguish three types of validation failures- validations supporting preconditions, phantom goals and filter conditions respectively-and discuss each of them in turn below’. (3.i) Failing Precondition Validations: If a validation support- ing a precondition of some node in the HTN is found to be fail- ing, because its supporting effect E is marked out, it can sim- ply be reachieved. The procedure involves creating a refit task, n.,, Achieve [El, to re-establish the validation v, and adding it to the HTN in such a way that it follows the source node and ’ In NONLIN terminology [19] the precondition validations support the “unsupervised conditions” of a schema, while the phantom goal validations support the “supervised conditions” of a schema. precedes the destination node of the failing validation. The validation structure of the plan is updated so that the failing validation will be replaced by an equivalent validation to be supplied by n,,. Finally, the annotations on the other nodes of the HTN are adjusted incrementallv to reflect this change. - (3.ii) Failing Phantom Valia’ations: If the validation support- ing a phantom goal node is failing, then the node cannot remain phantom. The repair involves undoing the phantomiza- tion, so that the planner would know that it has to re-achieve that goal. Once this change is made, the failing validation is no longer required and can be removed. (3.iiG Failing Filter Condition Validations: In contrast to the validations supporting the preconditions and the phantom goals, the validations supporting failing filter conditions cannot be reachieved by the planner. Instead, the planning decisions which introduced those filter conditions into the plan have to be undone. That is, if the validation v:{E,n, ,C ,nd) supporting a filter condition C of a node nd is failing, and n ’ is the ances- tor of n, whose reduction introduced C into the HTN originally, then the sub-reduction R (n’) has to be replaced, and n ’ has to be re-reduced with the help of an alternate schema instance. So as to least affect the validation structure of the rest of the HTN, any new reduction of n’ is be expected to supply (or con- sume) the validations previously supplied (or consumed) by the replaced reduction. Any validations not supplied by the new reduction would have to be re-established by alternate means, and the validations not consumed by the new reduction would have to be pruned. Since there is no way of knowing what the new reduction will be until refitting time, this processing is deferred until that time. 141 P-Phantom-Validations-Exploiting Serendipitous Effects: It is possible that some of the validations that R’ estab- lishes via step addition can be established directly from the interpreted initial state, thus shortening the plan. Such valida- tions, called p-phantom validations, are located by collecting validations whose source node is not nf, and checking to see if their supporting effects are now true in the new facts of I’. For each p -phantom validation, PRIAR checks to see if an equivalent validation can actually be established from the initial state, nl without introducing new interactions (and thereby causing sub- stantial revisions) in the plan. If so, the p-phantom validation becomes redundant, and is treated as an unnecessary validation. The parts of the plan that are currently establishing this valida- tion are pruned from the HTN, thus effectively shortening the plan. Example: Figure 3 shows R”, the HTN produced by the annota- tion verification procedure for the 3BS+4BSl example. The input to the annotation verification procedure is the interpreted plan R i discussed in section 3.1. In this example, R i contains a failing phantom validation and a missing validation correspond- ing to an extra goal. The goal On (JJ) of G i is an extra goal, and is not supported by any validation of the HTN. So, the refit task n lolAchieve [On (J ,I)] is added to the task network, in parallel to the existing plan, such that nl<n la<nG . n 1o now sup- plies the validation (On (J ,I),nlo,On (J,I),n,) to the goal On (JJ). Next, the fact Clear(L), which is marked out in I’, causes the validation (Clear (L ),nr ,CZear (L ),n7) supporting the phantom goal node n 7 to fail. So, the phantom goal node n7 is converted into a refit task to be reduced. It no longer needs the failing phantom validation from nf . Notice that the HTN shown in this figure corresponds to a partially reduced task network which consists of the applicable parts of the old plan and the two refit tasks suggested by the annotation verification 180 AUTOMATEDREASONING Ff nl I Clear(J) --- / Clear{ K)L-- On(K,Table), On( L,Table) - n2: A[On(K,J)] r-r Sch: Make-on(K,J) eff: On(K.J) n15: Puton-Action Figure 3. Annotation-Verified plan for 3BS+4BSl procedure. It has a consistent validation structure, but it con- tains two unreduced refit tasks nlo and n7 which have to be reduced. 3.3. Refitting To produce an executable plan for P” , R” (the HTN after the annotation verification process) has to be completely reduced. This process, called refitting, essentially involves reduction of the refit tasks that were introduced into R” during the annotation verification process. The responsibility of reducing the refit tasks is delegated to the planner by sending R” to the planner. An important difference between refitting and from-scratch (or generative) planning is that in refitting the planner starts with an already partially reduced m. For this reason, solving P” by reducing R” is less expensive on the average than solving P n from scratch. The procedure used for reducing refit tasks is fairly similar to the one the planner normally uses for reducing non-primitive tasks (see section l.l), with the following important difference. An important consideration in refitting is to minimize the distur- bance to the applicable parts of R” during the reduction of the refit tasks. To ensure this conservatism of refitting, the default schema selection procedure is modified in such a way that for each refit task, it selects a schema instance that is expected to give rise to the least amount of disturbance to the validation structure of R”. The annotated validation structure of the plan helps in this selection by estimating the effect of reduction at a refit task on the rest of the plan. A detailed presentation of this heuristic control strategy is beyond the scope of this paper; the interested reader is referred to [9, lo]. Once the planer selects an appropriate schema instance in this way, it reduces the refit task by that schema instance in the normal way, detecting and resolv- ing any interactions arising in the process. Example: Figure 4 shows the hierarchical task reduction struc- ture of the plan for the 4BS 1 problem that PRIAR produces by reducing the annotation-verified task network (shown in Figure 3). (The top down hierarchical reductions are shown in left to right fashion in the figure. The dashed arrow lines show the temporal precedence relations developed between the nodes of the HTN.) The shaded nodes correspond to the parts of the interpreted plan R’ that survive after the annotation verification and refitting process. The white nodes represent the refit tasks added during the annotation verification process, and their subse- quent reductions. In the current example, the refitting control strategy recommends that the planner reduce the refit task A [Clear(L)] by putting J on I rather than putting J on Table or on K. This decision in turn leads to a shortened plan by allowing the extra goal refit task A [On (J J)] to be achieved by phantomization. 4. Completeness, Coverage and Efficiency Completeness : The validation structure based modification is complete in that it will correctly handle all types of applicability failures that can arise during plan modification, and provide the planner with a partially reduced HTN with a consistent validation structure. In particular, our definition of inconsistencies (see $2.2) captures all types of applicability failures that can arise due to a change in the specification of the problem; and our annotation verification procedure provides methods to correctly modify the plan validation structure to handle each type of inconsistency (see section 3.2), without introducing any new inconsistencies into the HTN (a proof is provided in [lo].) Coverage : The validation structure developed here covers the internal dependencies of the plans produced by most traditional Figure 4. The plan produced by PRIAR 3BS+4BSl KAMBHAMPATI 18 1 hierarchical planners. The captured dependencies can be seen as a form of explanation of correctness of the plan with respect to the planner’s own domain model. By ensuring the consistency of the validation structure of the modified plan, PRIAR guarantees correctness of the modified plan with respect to the planner. However, it should be noted that as the dependencies captured by the validation structure do not represent any optima&y con- siderations underlying the plan the optimal@ of modification is not guaranteed. Further, since the modi&ation is integrated with the planner, failures arising from the incorrectness or incompleteness of the planner’s own domain model will not be detected or handled by the modification theory. Of course, these should not be construed as limitations of the theory, as its goal is to improve the average case efficiency of the planner. Flexibility and Efficiency: In the worst case, when none of the steps of R” are applicable in the new situation, annotation verification will return a degenerate HTN containing refit tasks for all the goals of P” . In such extreme cases PRIAR may wind up doing a polynomial amount of extra work compared to a pure generative planner. In other words, the worst case com- plexity of plan modification remains same as the worst case complexity of generative planning. However, on the average, PFUAR will be able to minimize the repetition of planning effort (thereby accrue possibly exponential savings in planning time) by providing the planner with a partially reduced HTN, and con- servatively controlling refitting such that the already reduced (applicable) parts of R” are left undisturbed. The claims of flexibility and average case efficiency are also supported by the empirical evaluation experiments that were conducted on PRIAR. The plot in figure 5 shows the computa- tional savings achieved when different blocks world problems are solved from scratch and by reusing a range of existing blocks world plans (see [lo] for the details of the experimental strategy). For example, the curve marked 7BSl shows the sav- ings afforded by solving a particular seven-block problem by reusing several different blocks world plans (indicated on the x-axis). The relative savings over the entire corpus of experi- ments ranged from 30% to 98% (corresponding to speedup fac- tors of 1.5 to 50) with the highest gains shown for the more difficult problems tested. These results also showed that as the size of P” increases, the computational savings afforded by PRIAR stay very high for a range of reused plans with varying amount of similarity; consider, for example, the plot for the 12BSl problem in the figure. This latter behavior lends support to the claim of flexibility of the modification framework. s a IVR n a 9 u s s e f r % 0 m 1007 12851 3BS 4BS 4BSl 58s 6BS 785 7851 8BS 8BS.l 9BS Reused Problems Figure 5. Variation of performance with problem size and similarity 5. Related Work Representations of plan internal dependency structure have been used by several planners previously to guide plan modification (e.g., the triangle tables and the macro operators of [5] and [8]; the decision graphs of [7] and [4]; the plan rationale representa- tion of [22]). However, our work is the first to systematically characterize the nature of such dependency structures and their role in plan modification. It subsumes and formalizes the previ- ous approaches, provides a better coverage of applicability failures, and allows the reuse of a plan in a larger variety of new planning situations. Unlike the previous approaches, it also explicitly focuses on the flexibility and conservatism of the plan modification. The modification is fully integrated with the gen- erative planning, and aims to reduce the average case cost of producing correct plans. In this sense, PRL4R’s strategies are complementary to the plan debugging strategies proposed in GORDIUS [ 181 and CHEF [6], which use an explanation of correct- ness of the plan with respect to an external (deeper) domain model (generated through a causal simulation of the plan) to guide the debugging of the plan and to compensate for the inadequacies of the planner’s own domain model. Similarly, PRIAR’S validation structure based approach to plan modification stands in contrast to other approaches which rely on domain dependent heuristic modification of the plan (e.g. [6,1,16]). Our approach of grounding plan modification on validation structure guarantees the correctness of the modification with respect to planner’s domain model and reduces the need for a costly modify-test-debug type approach. 6. Conclusion Our theory of plan modification utilizes the validation structure of the stored plans to yield a flexible and conservative plan modification framework. The validation structure, which consti- tutes a hierarchical explanation of correctness of the plan with respect to the planner’s own knowledge of the domain, is anno- tated on the plan as a by-product of initial planning. Plan modification is characterized as a process of removing incon- sistencies in the validation structure of a plan, when it is being reused in a new (changed) planning situation. The repair of these inconsistencies involves removing unnecessary parts of the HTN, and adding new high-level tasks to it to re-establish failing validations. The resultant partially reduced HTN (with a con- sistent validation structure) is given to the planner for complete reduction. We discussed the development of this theory in PRIAR system, and characterized its completeness, coverage, efficiency and limitations. This theory provides unified treatment for plan modification involved in replanning, plan reuse and incremental planning. Acknowledgements Jim Hendler, Lindley Dar-den and Larry Davis have influenced the development of the ideas presented here. Jack Mostow and Austin Tate provided useful comments on previous drafts. All three AAAI referees provided very informative reviews. To all, my thanks. References [ Please consult the list of references under the companion arti- cle “Mapping and Retrieval During Plan Reuse: A Valida- tion Structure Based Approach,” also in these proceedings. ] 182 AUTOMATED REASONING
|
1990
|
25
|
940
|
Introducing the Tileworld: Experimentally Evaluating Agent Architectures * Martha E. Pollack Artificial Intelligence Center and Center for the Study of Language and Information Marc Ringuette School of Computer Science Carnegie Mellon University SRI International 333 Ravenswood Ave. Menlo Park, California 94025 pollack@ai.sri.com Pittsburgh, Pennsylvania 15123 mnr@cs.cmu.edu Abstract without regard to the amount of time it is taking or the changes meanwhile going on, is not likely to make ra.tional decisions. We describe a system called Tileworld, which con- sists of a simulated robot agent and a simulated environment which is both dynamic and unpre- dictable. Both the agent and the environment are highly parameterized, enabling one to control certain characteristics of each. We can thus ex- perimentally investigate the behavior of various meta-level reasoning strategies by tuning the pa- rameters of the agent, and can assess the success of alternative strategies in different environments by tuning the environmental parameters. Our hy- pothesis is that the appropriateness of a pa.rticu1a.r meta-level reasoning strategy will depend in large pa,rt upon the characteristics of the environment in which the agent incorporating that strategy is situated. We describe our initial experiments us- ing Tileworld, in which we have been evaluating a version of the meta-level reasoning strategy pro- posed in earlier work by one of the authors [Brat- man e2 al., 19SS]. One solution that has been proposed eliminates ex- plicit execution-time reasoning by compiling into the agent all decisions a.bout what to do in particular situations [Agre and Chapman, 1987, Brooks, 1987, Ka.elbling, 198S]. This is an interesting endeavor, but its ultimate feasibility for complex domains remains an open question. Introduction An alternative is to design a.gents that perform ex- plicit reasoning at execution time, but manage that reasoning by engaging in nzeta-level reasoning. Within the past few years, researchers in AI have provided the- oretical analyses of meta-level reasoning, often a.pply- ing decision-theoretic notions to it [Boddy and Dean, 19s9, Horvitz, 1987, Russell and Wefald, 1989]. In ad- dition, architectural specifications for agents perform- ing meta-level reasoning have been developed [Brat- man et al., 19881, and prototype systems that engage in meta-level reasoning have been implemented [Cohen et nl., 1989, Georgeff and Ingrand, 19891. The project we describe in this paper involves the implementa.tion competing Recently there has been a surge of interest in systems that are capable of intelligent behavior in dynamic, un- predictable environments. Because agents inevitably have bounded computational resources, their delibera- tions about what to do take time, and so, in dynamic environments, they run the risk that things will change while they reason. Indeed, things ma-y change in ways that undermine the very assumptions upon which the reasoning is proceeding. The agent may begin a delib- eration problem with a particular set of available op- tions, but, in a dynamic environment, new options ma,y arise, and formerly existing options disappear, during the course of the deliberation. An agent that blindly pushes forward with the original deliberation problem, of a system for experimentally evaluating theoretical and architectural proposals. *This research was supported by the Office of Naval Research under Contract No. N00014-89-C-0095, by a contract with the Nippon Telegraph and Telephone Cor- poration and by a gift from the System Development Foundation. More specifically, we ha.ve been constructing a sys- tern called Tileworld, which consists of a simulated robot agent and a sim&ted environment which is both dynamic and un)cedictable. Both the agent and the environment a.re highly parameterized, enabling one to control certain characteristics of each. We can thus ex- perimentally investigate the behavior of various meta- level reasoning strategies by tuning the parameters of the a.gent, and can assess the success of alternative strategies in different environments by tuning the en- vironmental parameters. Our hypothesis is that the appropriateness of a particular meta-level reasoning strategy will depend in large part upon the charac- teristics of the environment in which the agent incor- porating that strategy is situated. We shall describe below how the parameters of our simulated environ- ment correspond to interesting characteristics of real, dynamic environments. POLLACKANDRINGUETTE 183 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. ########I############ # T T T T # # # 22 T# # # 2 # # ##5 T # # ###5T # # 85 T a T# # T # # T T TT # # %T#T. T # # T %### # # # ## T # # # T T T T # # # # # # T # # # # T ##### # # #I#### # # # TT # # T T T# ###########I######### a. = wgent, # = obstacle, T = tile, < digits > = hole Figure 1: A Typical Tileworld Starting State In our initial experiments using Tileworld, we have been evaluating a version of the meta.-level reasoning strategy proposed in earlier work by one of the authors [I3 * t la. man et al., 19SS]. However, the Tileworld can be used to evaluate a range of competing proposals, such as the ones mentioned above: agents instantiating many alternative proposals can readily be imported into the Tileworld environment. The Tileworld Environment The Tileworld is a chessboard-like grid on which there a.re agents, tiles, obstacles, and holes. An agent is a unit square which is able to move up, down, left, or right, one cell at a time, and can, in so doing, move tiles. A tile is a unit square which “slides”: rows of tiles can be pushed by the agent. An obstacle is a group of grid cells which are immovable. A hole is a group of grid cells, each of which can be “filled in” by a tile when the tile is moved on top of the hole cell; the tile and particular hole cell disappear, leaving a blank cell. When all the cells in a hole are filled in, the a.gent gets points for filling the hole. The a.gent knows ahead of time how valuable the hole is; its overall goal is to get as many points as possible by filling in holes. Figure 1 depicts a typical Tileworld starting state. A Tileworld simulation takes place dynamically: it begins in a state which is randomly generated by the simulator according to a set of parameters, and changes contin- ually over time. Objects (holes, tiles, and obstacles) appear and disappear at rates determined by param- eters set by the experimenter, while at the same time the agent moves around and pushes tiles into holes. The dynamic aspect of a Tileworld simulation distin- guishes it from many earlier domains that have been used for studying AI planning, such as blocks-world. The Tileworld can be viewed a rough abstraction of the Robot Delivery Domain, in which a mobile robot roams the halls of an office delivering messages and ob- jects in response to human requests. We have been able to draw a fairly close correspondence between the two domains (i.e., the appearance of a hole corresponds to a. request, the hole itself corresponds to a delivery loca- tion, tiles correspond to messages or objects, the agent to the robot, the grid to hallways, and the simula.tor time to real time). Features of the domain put a variety of demands on the a.gent. Its spatial complexity is nontrivial: a sim- ple hill-climbing strategy can have modest success, but when efficient action is needed, more extensive reason- ing is necessary. But the time spent in reasoning has a.17 associated cost, both in lost opportunities and in unex- pected changes to the world; thus the agent must make trade-offs between speed and accuracy, and must mon- itor the execution of its plans to ensure success. Time pressures also become significant a.s multiple goals vie for the agent’s attention. Of course, a single Tileworld simulation, however.in- teresting, will give only one data point in the design space of robot a.gents. To explore the space more vigor- ously, we must be able to vary the challenges that the domain presents to the agent. We have therefore pa- rameterized the domain, and provided “knobs” which can be adjusted to set the values of those parameters. The knob settings control the evolution of a Tile- world simulation. Some of the knobs were alluded t,o earlier, for instance, those that control the frequency of a.ppearance and disappearance of each object type. Other knobs control the number and average size of each object type. Still other knobs are used to control factors such as the shape of the distribution of scores associa.ted with holes, or the choice between the instan- taneous disappearance of a hole and a slow decrease in value (a hard bound versus a soft bound). For each set of parameter settings, an agent can be tested on tens or hundreds of randomly generated runs automatically. Agents can be compared by running them on the same set of pseudo-random worlds; the simulator is designed to minimize noise and preserve fine distinctions in per- forma.nce. The Tileworld environment is intended to provide a testbed for studying a wide range of dynamic do- mains and tasks to be performed in them. It exhibits spatial complexity, a central feature of many such do- mains; and it includes tasks of varying degrees of im- portance and difficulty. It is generic: although we have explored connections between Tileworld and tasks in- volving robot delivery, Tileworld is not tightly coupled to any particular application domain, but instead al- lows an experimenter to study key characteristics of whatever domain he or she is interested in, by varying parameter settings. For example, the experimenter can focus on doma.ins in which the central characteristic is 184 AUTOMATEDREASONING a wide distribution of task values (simulated in Tile- world by hole scores), or of task difficulty (simulated by hole size). In this regard, Tileworld differs from the Phoenix simula.tor [Cohen e2 al., 19891, which is more closely tied to a pa.rticu1a.r a.pplica.tion. Instead, the goals of the Tileworld project are closer to those of the MICE simula.tor [Durfee and h’fontgomery, 19901. However, Tileworld is a more highly dynamic environ- ment than MICE. Also, where h4ICE is used to focus on issues of real-time inter-a.gent c6ordina.tion, Tile- world is intended as a framework for the more general investigation of intelligent behavior in dynamic envi- ronments. Using Plans to Constrain Reasoning The a.gent we have implemented and used in our exper- iments insta,ntiates IRMA-the Intelligent Resource- Bounded Machine Architecture [Bra.tma.n e-t al., 1988]. IRMA builds on observa.tions ma.de by Bratman [Brat- man, 19871 that agents who a.re situated in dynamic environments benefit from ha.ving plans because their plans ca.n constrain the amount of subsequent reason- ing they need to perform. Two constraining roles of plans concern us here: o An agent’s plans focus subsequent means-end rea- soning so that the agent can, in general, concentrate on elaborating its existing pla.ns, rather than on com- puting all possible courses of action that might be underta.ken. e An agent’s plans restrict the set of further poten- tial courses of action to which it needs to give full consideration, by filtering out options that are in- consistent with the performance of what the agent alrea.dy plans to do. The first role of plans has always been at least implicit in the standard models of AI planning: AI plamlers compute means to goals that the agent already has. The second has a more dramatic effect on the architec- ture we are investigating: it leads to the introduction of a filtering mechanism, which manages execution-time reasoning by restricting deliberation, in general, to op- tions that ‘are compatible with the performance of al- ready intended actions. (To have the desired effect of lessening the amount of reasoning needed, the filter- ing mechanism must be computationally inexpensive, relative to the cost of deliberation.) Of course, a rational agent cannot aEways remain committed to its existing plans. Sometimes plans may be subject to reconsideration or abandonment in light of changes in belief. But if an agent constantly recon- siders its plans, they will not limit deliberation in the way they need to. Thus, an agent’s plans should be reasonably stable. To achieve stability while at the same time allowing for reconsideration of plans when necessary, the filter- ing mechanism should have two components. The first checks a new option for compatibility with the exist- ing plans. The second, an override mecha.nism, encodes the conditions under which some portion of the exist- ing plans is to be suspended and weighed against some other option. The filter override mechanism operates in parallel with the compa.tibility filter. For a new option to pass through the filter, it must either pass the compatibility check or else trigger an override by matching one of the conditions in the override mecha- nism. A critical task for the designer of an IRMA-a.gent is to construct a filter override mechanism so tl1a.t it embodies the right degree of sensitivity to the problems and opportunities of the agent’s environment. The options that pass through the filter are subject to deliberation. The deliberation process is what actu- ally selects the actions the agent will form intentions towards. In other words, it is the deliberation pro- cess t.hat performs the type of decision-making that is the focus of traditional decision theory. The filter- ing mechanism thus serves to frame particular decision problems, which the deliberation process then solves. The process of deliberation is different from means- ends reasoning in our view, and this distinction is worth discussing further. As we see it, deliberation is deciding which of a set of options to pursue, while means-ends reasoning is more a process of determining how to achieve a given goal. We see means-ends rea- soning producing options (candidate plans to achieve a goal), which can then be the subject of deliberation. This ma.y be a surprising distinction to those fa,mil- ia.r with the sta.ndard AI planning paradigm, in which the job of a planner is usually to produce the single best p1a.n according to some set of criteria. Any delib- era.tion which is to be done in such a system is done by the planner, and it might be argued that a planner is the best place for such reasoning. Certainly some pruning of alternatives must be done by a planner; however, there are reasons to believe that some delib- eration belongs outside the planner. In some situations it is a.ppropriate to have several means-ends reasoners with differences in solution quality and time required; these must be invoked appropriately and a single so- lution chosen. In other circumstances it is desirable to engage in a decision-theoretic analysis of compet- ing alternatives. Consequently, we have maintained the distinction between deliberation and means-ends reasoning in our system. The Tileworld Agent In implementing an IRMA-agent for the Tileworld, we adopted a model of a robot with two sets of process- ing hardware. One processor executes a short control cycle (the act cycle), acting on previously formulated plans and monitoring the world for changes. The sec- ond processor executes a longer cycle (the reusoning cycle), which permits computations with lengths of up to several seconds. The act cycle is straightforward; the agent performs POLLACKANDRINGUEITE 185 al 1 existing intentions, or if it triggers an override. Compatibility checking of top-level options, as im- Action Figure 2: Tileworld Agent Architecture those acts that have been identified during the pre- vious reasoning cycle, monitoring for limited kinds of failures. Perception also occurs during the act cycle: the agent can access a global map of the world that in- dicates the loca.tions of all objects, as well as the score and time remaining to timeout for a.11 holes. The reasoning cycle makes decisions about what goa.ls to pursue and how to pursue them. The por- toion of the agent architecture that controls reasoning is depicted in Figure 2. Processing is aimed at main- taining the intention structure, a time-ordered set of tree-structured plans that represents that agent’s cur- rent intentions. During any given reasoning cycle, one of two things can happen: Potential additions to the intention structure, called options, can be considered by the filtering and delib- eration processes. These options can come from two sources. One, the agent may perceive environmen- ta.1 changes that suggest new options-in Tileworld, this occurs when new holes or tiles appear. Alterna- tively, options may be suggested by the means-end reasoner. Means-ends reasoning can be performed to produce new options that can serve as means to current in- tentions. The bulk of our means-ends reasoner is a special-purpose route planner. We will concentrate here on the filtering and deliber- ation mechanisms. All options are in principle subject to filtering and deliberation; so far, however, we have confined such reasoning to top-level options, i.e., op- tions to fill a particular hole. Recall that the IRMA filtering mechanism has two parts: the compatibility filter and the filter override. An option passes the filter if it is either compatible with plemented, is straightfo&ard. - A top-level option is either to fill a hole now or Inter; if the agent alrea.dy hcas a current intention to fill a particular hole now, then an option to fill some other hole now is incompat- ible. All intentions with each other. to fill a hole later a.re compatible The filter override must identify options that are potentially valuable enough that they warrant delib- eration even if they fail the compatibility test. The simplest override mechanism compares the score of a hole being considered as an option to that of the hole currently being filled. If the difference between them equals or exceeds some threshold value v, then the new option passes the filter. The threshold value is set by a Tileworld pa.rameter. Sometimes it may sensibly be set to a negative value: in that case, a new option could be subject to deliberation even if it involved fill- ing a hole with a lower score than the hole currently being filled. This might be reasonable, since the new hole may, for instance, be much easier to fill. Setting the threshold value to --co results in all options being subject to deliberation. Recall t1la.t an option’s passing the filter does not 1ea.d directly to its introduction into the intention structure: instea.d, it is passed to the deliberation pro- cess for more detailed consideration and comparison with the current intention. Deliberation may involve extensive analysis; deliberation stra.tegies ca.n be cho- sen in the Tileworld agent by the setting of a para.m- eter. We currently have implemented two deliberation strategies. The simpler deliberation module evaluates compet- ing top-level options by selecting the one with the higher score. When there is a nonnegative threshold value in the filter, this mode of deliberation always se- lects the new option; with a negative threshold value, it instead always maintains the current intention. This illustrates a general point: if deliberation is extremely simple, it may be redundant to posit separate deliber- ation and filtering processes. A more sophisticated deliberation strategy computes the likely value (LV) of a top-level goal. LV is an esti- mate of expected utility, combining information about reward (score) with information about likelihood of success. For a given option to fill a hole h, LV is com- puted as LV(h) = score(h) dist(a, h) + Ck, 2 * dist(h, ti) where score(h) is the reward for filling the hole, dist(a, h) is the distance between the agent and the hole, n is the number of tiles needed to fill the hole, and dist(h, ti) is the distance from the hole to the jth closest tile. The factor of 2 occurs because the agent must traverse the interval in both directions, i.e., it must make a “round trip”. If there are fewer than n 186 AUTOMATED REASONING tiles available, LV(h.) is zero. We intend to design additional deliberation modules, including one that performs complete means-end rea.- soning for all options under consideration before mak- ing its decision. Such a. deliberator must not be in- voked caxelessly; we expect our filtering mechanism to be increasingly useful as we add more sophisticated and time-consuming delibera.tion components. Prelhinary Experiments With both the simulator and the agent in place, we axe in a position to conduct experimental studies of the the performance of the agent. By a.djusting the Tileworld “knobs”, we ca.n control a. number of domain character- istics. We can vary what we call dynamism (the rate at which new holes a.ppear), hostility (the ra.te at which obsta.cles a.ppear), vurinbility of vdilily (differences in hole scores), variability of dificulty (differences in hole sizes and distances from tiles), and hnrd/soft bounds (holes having either hard timeouts or gra.dua.lly decay- ing in value). There are also variables we can a.djust in the a.gent: act/think rate (the relative speeds of act- ing and thinking), the filter’s ?hreshold level, and the sophisticution of the deliberidion m.echanism. Experiment 1 To begin with, we set all of these parameters to pro- vide a baseline enviromnent which is dyna.mic, vari- able, and moderately paced. In this environment, a competent agent ca.n achieve reasonable scores, but is pena.lized for wa.sting time or making poor choices. We will sta.rt by compaxing the simple deliberation mech- anism, based on score value, with the LV evaluator, which provides a better estimate of marginal utility. For orientation, we have also included the results of a human playing the role of the a.gent in the same sim- ulation; and to gain an idea of the benefit of acting in parallel with reasoning, we have included results for an agent that that acts and reasons serially. All of these agents were tested in the baseline en- vironment and in a similar but more rapidly changing one. In the faster environment, objects appear and dis- appear on the average ten times more quickly, but the agent can also move ten times more quickly. However, the agent’s reasoning takes place at the same rate of speed as in the baseline ca.se, so the opportunity cost of reasoning is correspondingly greater in the faster en- vironment. The agents were all eva.lusted by taking the average score from 30 trials; the huma,n performed 10. Each trial is a self-contained simulation with a du- ration of 5000 ticks of the clock, where the agent can move once per clock tick. ~1 Experiment #1 The differences here are quite apparent. In the nor- ma.1 speed environment, the human subject performed best, beca.use he had more-sophisticated planning ca- pa.bilities than the robot. But in the faster environ- ment, the human’s response speed was insufficient to allow him to keep up with the pace of change. The robot a.gents were better able to adjust to the more rapidly changing environments, but it is clear that the cost of reasoning is still significant for them. This is evident both from an overall decrease in score in the high-speed environment, and from the superi- ority of the robot agents that could reason and act in parallel. The other distinction of note is that the LV evalua.tor performs better than the simple evaluator, as expected. Experiment 2 We now move on to our initial experiments directed at understanding some of the design trade-offs in our agent. The use of Tileworld to experimentally evalu- ate our a.gent architecture is a.n ongoing project, and these a.re early results. We stress that the hypothe- ses presented below are preliminary; significantly more esperimenta.tion and statistical analysis of the results need to take place before we can make strong claims about the relative appropriateness of any particular agent-design strategy. In Experiment 2, we attempt to test the usefulness of the filtering mechanism in our a.gent as implemented, using the LV evaluator as the deliberation component, and using the most quickly computed evalua.tion met- ric, thresholding on tlhe score value, as the filter over- ride mechanism. We vary the threshold from -100 to 100. Since the score for each hole ranges from 1 to 100, a threshold setting of -100 means that every new option is subject to delibera.tion, while a setting of 100 means that no new option will ever be considered until the currently executing plan is complete. The result- ing scores are summarized in the following chart, where each value represents an average over 30 trials. 420 Score 320 -25 Threshold Experimen #2 SLOW q NORMAL q FAST At the slowest speed setting, 100 times slower than our “normal” setting, it is better to do no filtering at all. The scores achieved at this speed decrease con- sistently as the threshold is increa.sed. At the normal POLLACKANDRINGUETTE 187 speed setting, the effect of increased filtering still ap- pears to be negative, but less markedly so. At a setting 10 times faster than the normal one, there seems to be little correlation between threshold level and perfor- mance, although the uncertainty in the results, which appears to be in the range of lo-20 points, prevents a sure determination. We hope, in the future, to be able to maeke even these relatively subtle determinations; the noise in the data comes, we believe, largely from our decision to use actual CPU-time measurements to determine reasoning time. If we wish to get the clea,n- est trials possible, we ma.y need to use a time estimate that does not depend on the vagaries of the underlying machine and Lisp system. Failing that, we will need to model the uncertainty involved, and run larger trial sets. To sum up the results of this experiment, we see that filtering is harmful at slow speeds, and even at high speeds does not give a net benefit. Our hypothesis is that the time cost of the LV evaluator is not very high, a.nd consequently, it is usually worth taking the time to engage in extra deliberation about new opportunities. The fact that filtering is less detrimental in the faster environment leads us to hypothesize that there may be a break-even point at even faster speeds, above which filtering is useful; we intend to test for such a point. We also intend to implement more accurate (and costly) deliberation mechanisms in the near future. For these, filtering may be much more valuable; perhaps the LV- estimator is efficient enough that it can itself be used as the filter override mechanism for the more complex deliberation components. Experiment 3 In our third experiment, we attempt to test a conjec- ture that the LV evaluator as described is deficient in an important way: it does not consider the time cost of means-end reasoning already performed. We modify the deliberation functions by adding a bias in favor of existing intentions, since typically at deliberation time, some means-end reasoning about how to achieve these has already taken place. This is distinct from Experi- ment 2, in which we adjusted the filtering mechanism in an attempt to save deliberation time; here we inves- tigate a bias in the deliberation process itself with the intent of reducing the time cost of means-end reason- ing. We consider two cases. In the first, deliberation is done by the simple evaluator, and we apply a bias to- wards existing intentions equal to a fixed number of points. In the second, deliberation is done by the LV evaluator, and we apply a bias equal to a fraction of the current LV. Thus, for example, with a 100 percent bias, a newly appearing hole must have double the LV of the current one to be adopted as a new intention. The environment settings and simulation sizes are the same as for Experiment 2. 188 AUTOMATED REASONING 400 300 Score 200 100 0 0 25 50 100 200 Bias (points) n NORMAL m FAST Experiment #3: Simple Evaluator 420 370 =Ore 320 270 220 Blas (percent) Experiment #3: LV Evaluafor As shown by the experimental results, bias in the de- liberator does not appear to have a. clear effect on total performance. For the simple evaluator, this isn’t terri- bly surprising; it provides a fairly weak assessment of a hole’s actual potential value in any case. We expected to see much more effect of bias on the LV evaluator, however. Two hypotheses are availa.ble to espla.in this. First, our test environment may have too many oppor- tunities available, minimizing the potential cost of high bias: if the agent spends most of its time doing some- thing with high utility, a few missed opportunities will not have a significant impact on the final score. This hypothesis can be tested in a less fa.vorable environ- ment. Second, it may be tha.t means-end reasoning in the current implementation is too inexpensive, min- imizing the potential benefit of high bias. This hy- pothesis can be tested by increasing the size of the environment to increase the planning time required; the addition of more complex planning routines would also provide situations in which there is a higher time cost associated with planning. Conclusion The experiments we have run to date have included some important milestones in the Tileworld effort. The Tileworld domain has been demonstrated, and has been shown to be a viable system for evaluating agent architectures. The Tileworld agent was demonstrated and used to test differing deliberation and filtering strategies as described in [Bratman et nl., 19881. The Tileworld project is ongoing. There are a num- ber of specific research tasks that we intend to pur- sue in the near future. Perhaps most importantly, we will be continuing our experimental efforts. The hy- potheses we drew from our preliminary experiments suggested several obvious follow-ons, as described in the preceding section. It will be particularly useful to va.ry parameters other than those that control speed, for example, size of the overall space, distribution of task value and difficulty, and availability of limited re- sources such as tiles. We will also implement more sophisticated deliber- ation algorithms, and, having done so, will a.ttempt to identify better the principles separating the processing that is done in the filtering mechanism from that done in the delibera.tion procedure. In addition, we plan to implement a foveated perceptual scheme, in which the agent has access to detailed, precise informa.tion about its immediate surroundings and has only increasingly abstract, incomplete, and uncertain information about about more dista.nt locations in its environment. An- other possibility is to add learning to the system: two areas of potential benefit are in the means-ends rea- soner (e.g.,‘expla.nation-based lea.rning of control rules) a.nd in eva.lua.tions of ma.rginal utility (e.g., empiri- cal improvement of utility evalua.tions). Finally, we hope to extend the architecture to handle more difficult questions involving intention coordination. We expect that both means-end reasoning and deliberation will become much more difficult, and hence filtering much more important, when the intention structure involves more complex interactions among intentions. More generally, we continue to investigate the larger question of how an agent should structure and control its computa.tional effort. We believe that the a.rchitec- ture discussed here is a special case of a more genera.1 framework, and we are working towards a definition of tl1a.t fra.mework and its verification in our domain. We also see the Tileworld testbed as a good basis for com- parison of other agent architectures proposed in the litera.ture, and we strongly encoura.ge other researchers to demonstrate their agents in our domain.’ The overall goal of our project is an improved un- derstanding of the relation between agent design and environmental factors. In the future, when faced with a performance domain for an agent, one should be able to draw on such an understanding to choose more wisely from the wide range of implementation possibil- ities available. References [Agre and Chapman, 19871 P. E. Agre and D. Chap- man. Pengi: An implementation of a theory of activ- ity. In Proceedings of the Sixth National Conference on Artificial Intelligence, Seattle, WA, 1987. [Boddy and Dean, 19891 M. Boddy and T. Dean. Solving time-dependent planning problems. In Pro- ceedings of the Eleventh International Joint Confer- ence on Artificial Intelligence, Detroit, MI, 1989. [Bratman et al., 19881 M. E. Bratman, D. J. Israel, and M. E. Polla.ck. Plans and resource-bounded practical reasoning. Computational Intelligence, 4(4), 1988. [Bra.tma.n, 19871 M. E. Bra.tma.n. Intention, Plans and Practical Reason. Harvard University Press, Cam- bridge, MA, 1987. [Brooks, 19871 R. A. Brooks. Planning is just a way of avoiding figuring out what to do next. Technical Report 303, MIT, Cambridge, MA, 1987. [Cohen et al., 19891 P. R. Cohen, M. L Greenberg, D. M. Hart, and A. E. Howe. Real-time problem solving in the phoenix environment. In Proceedings of the Workshop on Real-Tim,e Artificial Intelligen.ce Problems, Detroit, MI, 1989. [Durfee and Montgomery, 19901 E. H. Durfee and T. A. Montgomery. MICE: A flexible testbed for in- telligent coordination experiments. In L. Erman, ed- itor, Intelligent Real-Time Problem So1vin.g: Work- shop Report, Palo Alto, CA, 1990. Cimflex Teknowl- edge Corp. [Georgeff and Ingrand, 19891 M. P. Georgeff and F. F. Ingrand. Decision-making in an embedded reasoning system. In Proceedings of the Eleventh International Join.2 Conference on Artificial Intelligence, Detroit, MI, 1989. [Horvitz, 19871 E. J. Horvitz. Reasoning about be- liefs and actions under computational resource con- straints. In Proceedings of the 1987 Workshop on Uncertainty in Artificial Intelligence, Seattle, WA, 1987. [Kaelbling, 19SS] L.P. Kaelbling. Goals as parallel pro- gram specifications. In Proceedings of the Seventh National Conference on Artificial Intelligence,St. Paul, MI, 1988. [Russell and Wefald, 19891 S. J. Russell and E. H. We- fald. Principles of metareasoning. In Proceedings of the First International Conference on Principles of Knowledge Representation and Reasoning, Toronto, 1989. POLLACKANDRINGUETTE 189
|
1990
|
26
|
941
|
Getting Serious about Parsing Plans: a Grammatical Analysis of Plan Recognition Marc Vilain The MITRE Corporation Burlington Road, Bedford, MA 01730 Internet: mbv@linus.mitre.org Abstract This paper is concerned with making precise the notion that recognizing plans is much like parsing text. To this end, it establishes a correspondence between Kautz’ plan recogni- tion formalism and existing grammatical frameworks. This mapping helps isolate subsets of Kautz’ formalism in which plan recognition can be efficiently performed by parsing. In recent years, plan recognition has emerged as one of the best-understood frameworks for analyzing goal- directed behavior. Interest in plan recognition has led to the development of diverse recognition strategies.l One approach suggested several times is that of parsing plan descriptions (Sidner (1985), Ross & Lewis (1987)). A plan is typically described as a sequence of steps, so interpreting some observations in terms of a plan can naturally be seen as a parsing task wherein observations are lexical tokens and plan libraries are grammars. My aim in this paper is to explore this parsing view of plan recognition by establishing a formal correspon- dence between an existing plan formalism and context- free grammars. By working through the details of this correspondence, the paper explores parsing algorithms for plan recognition, and delineates classes of problems for which these algorithms are applicable and tractable. Underlying this work is the plan recognition formalism of Henry Kautz (Kautz & Allen, 1986; Kautz, 1987). His approach is of particular interest because it is formal and well understood. It is also among the broadest of current formalisms, especially in the expressive richness of its plan representation. Finally, since general plan recognition in Kautz’ framework is intractable, there is intrinsic interest in identifying those aspects of his approach that cause this intractability, and those that avoid it. Kautz’ Framework In his dissertation work, Kautz defines a circumscrip- tive framework for plan recognition. He starts with a simple frame-like hierarchy of plans which is inter- pretable by first-order meaning postulates. Through a sequence of circumscriptive minimizations, Kautz “closes” the interpretation of the hierarchy, and thereby ‘E.g., Schmidt, Sridharan & Goodson (1978), Allen & Perrault (1980), Carberry (1983), Allen (1983), Litman (1986), Pollack (1986), Kautz (1987), Konolige & Pollack (1989), Goodman & Litman (1990). 190 AUTOMATEDREASONING introduces an additional set of first-order axioms. This expanded set of axioms enables some of the normally abductive aspects of plan recognition to be performed through a now deductive process. The Kautz plan representation The principal component of the Kautz representation is a hierarchy of event (or plan) types. Plans are hierarchically organized according to two relations, abstraction and decomposition. The former is a subtype (or IS-A) relation; for example, in Kautz’ cooking domain, the MAKE-MEAL plan abstracts the MAKE- PASTA-DISH plan. The second relation, decomposition, is borrowed from the non-linear planning literature (Sacerdoti, 1977; Wilkins, 1984, among many others), and identifies the steps making up a plan. For instance, MAKE-PASTA-DISH decomposes into a first step which is a MAKE-NOODLES plan, and a second, a MAKE- SAUCE plan. Each step is given a designator, so the MAKE-NOODLES step of MAKE-PASTA-DISH might be designated Sl, and the MAKE-SAUCE step S2. For more examples, see Figure 1. A plan hierarchy so defined is axiomatized with two meaning postulates, one per relation. For abstraction, let 91 and m be plans such that cpl abstracts m. This is interpreted as If x M0 1 v2(x) For decomposition, let p be a plan with steps designated ~1 . . . on, each of which is restricted to being a plan of type ~1.. . vn. This is interpreted as v x tix) 2 ~l(~l(x)) *---* Vn(on(X)) Finally, Kautz distinguishes an abstract plan class, END, encompassing those plans that are meaningful ends in and of themselves. MAKE-MEAL is abstracted by END, and is taken to be an independently meaningful plan. In contrast, MAKE-NOODLES is not abstracted by END, and is not considered independently meaningful - it only has meaning as a step of some other plan. Minimal plan models The bulk of Kautz’ work formalizes the notion that plan hierarchies such as these can be treated as a complete encoding of a system’s knowledge of plans. Kautz shows that a sequence of circumscriptive minimi- zations enforces a closed world assumption of sorts for plan hierarchies, with the effect that the hierarchies can From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Figure 1: A plan hierarchy abstraction decomposition be used to guide plan recognition. Briefly, the closure of a hierarchy proceeds by selecting among models of the hierarchy those models that minimize (1) the extensions of all non-leaf plan types (the hierarchy’s inner nodes); (2) the extensions of all plan types but ANY, the hierarchy’s root; and (3) the extensions of all non-END plan types. In effect, the first two minimizations enforce the assumption that no abstraction relations hold over the hierarchy which aren’t explicitly mentioned or derivable by transitive closure. The last minimization corresponds to assuming that non-END plans can only occur as com- ponents of some other plan. Kautz calls the resulting closed world models of a hierarchy its covering models. Recognizing Kautz’ plans Since they provide a closed world encoding of the hierarchy, covering models form the foundation of the plan recognition process. The recognition problem intuitively consists of finding the most parsimonious interpretation of some observed actions, given the closed world of the hierarchy. To formalize this notion, let H be a hierarchy described by A and D, the conjunctions of H’s abstraction and decomposition axioms respectively, and let cc) be a sentence describing some observations. From among the covering models of A AD AU, Kautz designates those models that explain w parsimoniously as those that minimize the cardinality of END. This selects those closed world models that postulate the minimum number of end events from H that can possibly account for the observations. To extend Kautz’ terminology, I will refer to these models as the minimal covering models of w with respect to H. Operationally, a plan recognizer doesn’t manipulate models so much as plan descriptions. So in Kautz’ framework, one should think of the plan recognizer’s task as the mapping of an observation sentence CI) to a plan sentence it that is the strongest description of the plans underlying w, and is valid in all minimal covering models of w with respect to the plan hierarchy. lan Hierarchies as Grammars There is much similarity between Kautz’ plan recognition assumptions and the assumptions underlying parsing. A parser interprets a grammar, in some sense, as a closed world; constituents can’t be derived unless they’re on the left hand side of a parse rule; constituents that don’t derive the start symbol directly must appear in the derivation of some other constituent; etc. As noted above, several authors have observed that plan hierarchies can be seen as defining a grammar of plans that could be used to “parse” a string of actions. This observation is attractive: parsing is a well- understood problem with efficient solutions, so a parsing approach to plan recognition might be expected to yield recognition strategies with better computational characteristics than those developed by Kautz. For certain classes of recognition problems, this is in fact true. With appropriate restrictions on the nature of the plan hierarchies, observations, or expected solutions, a broad class of plan recognition problems becomes tractable in a parsing framework. Initial Plan Grammar Considerations These tractability results are shown by constructing a mapping from Kautz’ plan hierarchies to context-free grammars. Note that context-free grammatical power is not strictly necessary to encode plan hierarchies in Kautz’ representation, since he nominally restricts them to being acyclic. An acyclic hierarchy does not contain any recursive plan definitions, and could in fact be encoded as a regular (finite-state) grammar. The broader context-free class is chosen here in part to allow for the possibility of recursive definitions. Further, since a major aspect of plan recognition is recovering the plan structure underlying one’s observa- tions, the natural grammatical implementation of plan recognition is as a chart-based parser (Kay, 1980; Thompson, 1983). In particular, one can extend Earley’s context-free recognition algorithm (Earley, 1970) with a chart, thus enabling it to return the structure of its VILAIN 191 MAKE-MARINARA/ Figure 2: A very simplified hierarchy. parses. Given such an algorithm, there is little motivation to restrict oneself to a finite-state encoding of plans. This is especially true with Earley’s algorithm, since its polynomial bound on context-free recognition time reduces to a linear bound for finite-state grammars. The complete mapping from plans into grammars is fairly involved, however. So for the sake of clarity, it is presented here as a sequence of simpler mappings into ever more expressive grammatical formalisms. As an overall simplifying assumption, I’ll start by only considering solutions that neither share nor interleave steps. In other words, if more than one plan must be hy- pothesized to account for some observations, each plan must be fully completed before the next one can begin. The Decomposition Grammar The process of converting a plan hierarchy H into an equivalent grammar G starts with an encoding of the decomposition axioms. Assume for now that the des- cription of the hierarchy contains no abstraction axioms (we can safely ignore the fact that all plan types are actually abstracted by ANY, the hierarchy’s root). The hierarchy is thus entirely described by axioms of form bf X ($Xx) 1 Wl(~l(X)) A.-.* Vn(%(X)) where (p is a plan, 01 . . . on are its steps, and I/Q.. . t/Yn are the type restrictions of these steps. In general, these steps may only be partially ordered, and may even overlap if actions are modeled as having non-zero temporal extent. However, as another temporary simpli- fication, assume that the steps of a decomposition are non-overlapping, and totally ordered according to their order in the decomposition axiom. With these simplifications, decomposition axioms of the form shown above are mapped to parse rules of form (P + Vl ..a Wn Note that the parse rule strips the names of steps from the decomposition. In addition, the following parse rule is necessary to produce the top of the parse tree, where S is the start symbol of the plan grammar. S+END 1 ENDS This rule introduces enough right-branching structure to account for all END plans appearing in the observations. For example, say the cooking hierarchy in Figure 1 is simplified so as to contain only one END plan, that Let !2 = 631 A... A O, be an observation sentence where Oi has fOrIll PLAN-TYPEi(ACTi). Let Chart[O..n x O..n] be an initially empty array of derived constituents. Let Stutes[O..n] be an initially empty array of intermediate parse states (dotted rules). (1) Initialize Chart[i-I ,i] with each PLAN-TYPEi in Q. (2) Add s(O) --> o END and S(O) --> o END s to States[O]. (3) For i t 0 to n do (4) Predict: If a~) -> -*SO P-B- is a dotted rule in Stutes[i], then add to States[i] a dotted rule BQ) -> 0 y .. for each rule deriving p in the grammar. (5) Scan: If a~) -> ---a /.3 y-e is in States[i] and p is a termi- nal, then if Chart[i,i+l] contains p, add a dotted rule of form a(i) -> s--p 0 y-a. to States[i+l]. (6) Complete: If a~) -> a.. p e is a complete dotted rule in States[i], then (7) Add a to Chart[j,i], using the AND-OR coding scheme. (8) For each y(h) -> ...o a &.. in Stutes[j], add to States[i] a dotted rule of form 6(i) -> . x.-e for each rule deriving 6 in the grammar. Figure 3: Earley’s algorithm. for making fettuccine marinara. This new hierarchy (see Figure 2) would produce the following grammar. S+END 1 ENDS END + MAKE-PASTA-DISH MAKE-PASTA-DISH + BOIL-WATER MAKE-FETTUCCINE MAKE-MARINARA Parsing the Decomposition Grammar As noted earlier, decomposition grammars can be applied to plan recognition with a chart-based version of Earley’s algorithm. Briefly, the algorithm operates by maintaining a chart, a two-dimensional table thr)t records the constituents spanning any two positions in the input stream. 2 If a constituent may be derived in more than one way between the same two positions, the multiple derivations are recorded as alternatives in an OR node (each derivation is itself an AND node). Earley records partial derivations by instantiating “dotted” versions of rules. For example, A --> B C, when first applied, has a dot to the left of B (A(i) -> o B C). After deriving B, a new instance of the rule is created, with the dot advanced past B (A(i) --> B 0 C). The subscripted index in this notation indicates the start position of the leftmost terminal derived by the rule. The algorithm indexes dotted rules in a set of states: if a dotted rule seeks to derive a constituent starting in some position k, the rule is added to the kth state set. When the dot is finally moved past the end of a rule, a derivation has been completed, and the derived 2 For a sentence of length n, the chart runs from 0 to n, with each terminal spanning [i, i+l], for some i. 192 AUTOMATEDREASONING S co)-+ .END S s(o)+ OEND s END (,,)+ .MAKEGP-DISH I Y\ MAKE-PASTA-DISH toj--+ eBOIL-WATER MAKFrFFITUCCINE . . . S J I I I I I BOIL-WATER . . . MAKE-PASTA-DISH MAKE-PASTA-DISH ’ 0 1 2 / ’ \ ’ \ 7 I \ I \ I . I \ \ / \ MAKE-PASTA-DISH to)-+ BOIL-WATER o MAKEMZTTUCCINE . . . BOIL-WATER BOIL-WATER Figure 4a: States of the parser Figure 4b: Corresponding parse trees constituent is added to cell [i, j] of the chart, where i is the start index of the leftmost terminal derived by the rule, and j is the end index of the rightmost one. The algorithm is sketched in Figure 3, with details in Earley (1970). With respect to applying the algorithm to plan recognition, three points need to be made. First, observations are entered into the chart in a straightforward way. To be precise, say we have observed the sentence Q = ~1 A.. . A mn, where each Ui has form PLAN-TYPEi(ACTi). Assuming observations are ordered and non-overlapping in time, Q is entered into the chart by placing the terminal constituent corresponding to each PLAN-TYPEi in chart cell [i-l, i]. The next point to note is that Earley’s algorithm proceeds left-to-right through the input stream. Each step in the traversal computes all partial derivations that account for the input up to that point. This can be exploited to allow for incremental observations in the manner of Kautz’ Incremental and Sticky Algorithms. That is, every time a new event is observed, it is added to the chart, and the main loop of the algorithm is simply restarted on the chart index for that event. Most important, Earley is a predictive top-down parser. Thus, whenever a terminal symbol is scanned by the parser, the incomplete parse tree that ultimately derives the terminal from the start symbol is implicit in the state sets of the parser. This parse tree can be recovered from the dotted rules making up these sets. For example, say the parser had been given the simplified cooking grammar corresponding to Figure 2, and say we had observed a BOIL-WATER action, B 1. The state of the parser and its chart would then be as shown in Figure 4a. The parser’s state can be interpreted as identifying two distinct incomplete parse trees for the BOIL-WATER observation (see Figure 4b). The first derives a single END plan to account for the observation. The second tree postulates a second END plan following the first (a third would be postulated in the parser’s prediction phase if the parser attempted to derive the second END plan, and so forth). These parse trees can be interpreted as first-order sentences. For terminals, the sentential form is the observation associated with the terminal (a proposition of form PLAN-TYPE(ACT)). For non-terminals, we begin by creating for each non-terminal node an existentially quantified plan instance (ignoring the start node). The links from a node to its children in turn correspond to steps named in the decomposition axiom for the rule that derived the node. The sentential form of a parse tree t, with children tl . . . t, is then the sentential forms of its children conjoined with 3 5. K(5) * q(5) = 51 A---* ql(5) = 5n where 5, &,..., tn are the variables for nodes t, tl,. . . , t, respectively (or constants if the nodes are terminals), K is the constituent associated with t, and the Gi are the step names associated with the derivation of t. Multiple derivations of a constituent simply introduce into the sentential form the disjunction of their respective parses. Under this mapping, the first parse in Figure 4b can be interpreted as: 3 x,y END(x) A SO(x) = y A MAKE-PASTA-DISH(y) A S l(y) = B 1 A BOIL-WATER(B 1) This interpretation scheme for parse trees is akin to that used by Kautz to interpret his algorithms’ E-graphs. Correctness and complexity To prove the correctness of the plan parser, it is necessary to show that for a given hierarchy H and observation W, the parser computes the minimal covering models of w with respect to H. This can be accomplished in two steps. First, the algorithm can be shown to compute the covering models of H by relying on a result from Kautz (1987). Kautz shows that the covering models of plan hierarchies with no abstraction are exactly those that satisfy all instantiations of his component/use axiom schema. The (slightly modified) schema is given by: tr’ x q(x) I> END(x) v 3 Yl Vl(Yl) A WYl) = x) v-.-v 3 Yn Wn(Yn) * @l(Yn) = Jo where cp is a plan type, and ~1.. . vn are those plan types that respectively restrict steps ~1.. . on to be of type p VILAIN 193 Extending this schema to parse trees is straight- forward. In light of the sentential interpretation of parse trees, the schema can be rephrased in terms of t, t1 , . . . ,tn, variables ranging over parse tree nodes: v t (p(t) z) END(t) v 3 t1...tn l/q(t1) A (t1 * t) A...A vnw * &I =j 0 where cp is the constituent corresponding to a plan type, and WI,..., vn are all those constituents that derive CJJ in the grammar. The notation q(t) indicates that node t has constituent type q, and the notation t * t’ indicates that node t derives node t’ in the parse tree. For the purpose of this schema, the start node S, which is only used to introduce END nodes, is once again ignored. It is easy to see that in this form, the component/use schema is fully instantiated by Earley’s algorithm. The ti are introduced into the parse tree by the prediction step, and the derivations are recorded by the completion step. By fully instantiating the schema, the algorithm thus computes the covering models of an observation with respect to a hierarchy. To obtain the minimal covering models, note that each alternative parse tree attached to the start symbol S will postulate the existence of some number of END plans. These END plans can be enumerated simply by traversing the topmost right-branching structure of the tree introduced by the rule S + END S. The minimal models are those that apply this derivation a minimal number of times. This, along with the preceding discussion, informally shows the following proposition. Proposition 1: Under the sentential interpretation of parse trees, Earley’s algorithm computes the minimal covering models of an observation m with respect to H, a decomposition hierarchy with ordered unshared steps. Earley (1970) shows that the run time of his recognizer for a sentence of length n is bounded by a factor of O(n3). Barton, Berwick, and Ristad (1987) note that this bound can be refined to O(G O 2 n3), where Go is the total number of possible dotted rules afforded by the grammar G. The addition of a chart, as is done in the algorithm of Figure 3, extends Earley’s recognizer into a parser, but can introduce performance degradation. Tomita (1986), for example, describes some pathological combinations of grammars and input strings that can require of his chart-based parser O(n5) space utilization, and a corresponding degradation in parse time. However, Billot and Lang (1989) suggest that by using structure sharing to implement the chart’s AND-OR graphs, the space requirements for storing the chart are bounded by O(n3), while the parse times also remain cubic. The Uses of Abstraction The preceding results are of some interest in establishing the tractability of plan recognition for one class of plan hierarchies, those expressible without abstraction. However, the resulting formal apparatus is so impoverished as to be useless in practice. Beyond allowing for the identification of significant abstract constructs of a domain, abstraction is used in Kautz’ framework to encode three different phenomena: the multiple expansions of a plan; the isolation of substeps common to all expansions of a plan (which are then shared through inheritance); and, indeterminate observations. Adding Abstraction to the Grammar It is easy to extend the mapping from plan hierarchies to grammars so as to allow for abstraction in the descriptions of plan types. Abstract observations, however, impose additional considerations, which I will return to later. Assume for now that observations are given in terms of base plan types (the leaves of the plan hierarchy), and again restrict plan steps to be fully ordered and unsharable. The mapping from a hierarchy H to a grammar G proceeds from the top of the hierarchy to its leaves, distinguishing two cases: Case I : Say q is a plan type decomposing into steps 01.. . on, and say 9 has children xl.. .xm. Then, for each xi, copy each Oj (and its type restriction vj) to the decomposition of Xi, unless Xi happens to further restrict Oj. Then for each xi, add a rule to the grammar of form P + Xi Case 2: Say q is a childless plan type that decom- poses into (possibly inherited) steps CJ~. . . on, with step restrictions vi.. . Wn. Then add to the grammar a decomposition rule of form V+ Yfl ... Wn Again, the root of the hierarchy (ANY) is ignored, and again, the grammar is completed by adding the initial parse rule S+END 1 ENDS Note that this scheme eliminates from a hierarchy the explicit decompositions of abstract actions, enforcing them implicitly by inheritance instead. Thus, returning to the plan hierarchy in Figure 1, the sub- hierarchy rooted at MAKE-PASTA-DISH would be encoded as MAKE-PASTA-DISH + MAKE-FETTUCCINE-MARINARA MAKE-FETTUCCINE-MARINARA + BOIL-WATER MAKE-FETTUCCINE MAKE-MARINARA The grammatical treatment of abstraction introduces additional complexity to the sentential interpretation of parse trees. Indeed, one must now distinguish nodes that were introduced by abstraction parse rules from those that were introduced by decomposition parse rules. As before, say t is a node with children tl... tn, and say t was introduced by a decomposition rule produced in 194 AUTOMATEDREASONING Case 2 of the grammatical mapping. Then the sentential form of t is that of its children conjoined with 3 5. K(6) * 01(C) = 51 *---A on(c) = cn For abstraction, say (p + W is a parse rule introduced to encode an abstraction axiom in Case 1 of the grammatical mapping. Let t be a node in a parse tree that derives a node t’ by this rule. Then the sentential interpretation of the tree rooted at t is that of t’ conjoined with the expression q(5), where 5 is the plan variable associated with the interpretation of t’. Properties of Abstraction Grammars The correctness and complexity properties of Earley’s algorithm for decomposition grammars are easy to verify for abstraction grammars. For correctness, one must once again show that the algorithm computes the minimal covering models of some observation W with respect to H, a hierarchy with abstraction. To begin with, Kautz (1987) showed that the covering models of a hierarchy with abstraction are precisely those that fully instantiate three axiom schemata, one of which (component/use) appeared above in a simplified form. Disjunction: let q be a plan type that directly abstracts types ~1,. . ., vn. Then: If X NX) 3 Vi(X) v-**v &l(X) Exclusion: let ~1 and (92 be incompatible plan types, i.e., ones for that there exists no 413 which is abstracted (directly or indirectly) by both ql and w. Then: ‘d x +pl(X) v +?200 Component/use: let q be a plan type, and let ~1.. . t//n be all those plan types that restrict some step crl. . . on to be (p or a plan type compatible with q. Then: \d x (P(X) II END(x) v 3 Yl W(Y1) * (Ol(Y1) = Jo v...v 3 Yn Wn(Yn) * (%(Yn) = X) Under the sentential interpretation of parse trees, the disjunction schema can be recast in terms of t and t’, variables ranging over nodes in the parse tree: v t q(t) 3 3 t’ (t 3 t’) A (vl(t’) V...V l&,(t))) Assuming that @ mentions only base level observations, this schema is verified by noting that a parse node corresponding to an abstract plan type cp is only introduced into the chart (during the completion step of the algorithm) if one of ~1,. . . , vn was previously introduced into the chart. A similar argument can be used to show that, assuming base level observations, the parser fully instantiates the exclusion schema. The argument can also be used to extend the proof of Proposition 1 in order to show that the parser fully instantiates the extended version of the component/use schema. This informally demonstrates that the algorithm computes the covering models of @ with respect to H. The minimal covering models can be obtained as before from those parses introducing fewest END nodes under S, thus showing: Proposition 2: Under the sentential interpretation of parse trees, Earley’s algorithm computes the minimal covering models of a base-level observation cr) with respect to H, a hierarchy with ordered unshared steps. As before, the time complexity of parsing an observation “sentence” is O(G O 2 n3). The G O term is related to the original hierarchy description in the following way. There is exactly one dotted rule for each abstraction axiom, and the latter’s number is bounded by P, the size of the set of plan types in the hierarchy. The original decomposition axioms are also bounded in number by P, and it is easy to verify that after step inheritance, the number of corresponding dotted decomposition rules is bounded by Pd, where d is the number of steps mentioned in the longest decomposition axiom. The overall size of G O is thus O(Pd). Abstract Observations The preceding discussion crucially relies on observed actions’ not being abstract. This is a severe limitation, since abstract plan types simplify the expression of indeterminate observations. For example, in Kautz’ cooking world, one might like to encode uncertainty on whether an agent is making fettuccine or spaghetti with an abstract MAKE-NOODLES observation. In gram- matical terms, this amounts to allowing non-terminal categories to appear directly in the input stream. For the plan parser to interpret these observations correctly is tricky. The problem is that to ensure that the minimal covering models are computed, the parser must expand the abstract observation into its possible specializations, and hypothesize that each may have occured. It would be appealing if this expansion could be effectuated by compiling additional parse rules out of the plan hierarchy. Unfortunately, though various naive strategies for doing so are conceivable, they all seem to have unacceptable problems. For instance, one could allow for abstract observations to be specialized down the abstraction hierarchy with “reverse” abstraction rules (e.g., MAKE- PASTA-DISH -+ MAKE-MEAL). However, this leads directly to violations of the disjunction schema. An alternative (and equally naive) approach would produce additional decomposition rules introducing the possible abstractions of a base action, e.g.: MAKE-FETTUCCINE-MARINARA-+ MAKE-NOODLES MAKE-SAUCE However, the number of such rules is bounded by O(dpJ, leading to an exponential increase in the size of the grammar and an exponential increase in parse times. A more practical alternative is to leave the grammar unchanged, and treat an abstract observation q,(e) disjunctively as Vi vi(e), where the I//i are those plan types that maximally specialize cp (i.e., that specialize (p and have no specializations in turn). This strategy can be seen as explicitly enforcing the disjunction axiom schema on abstract observations. VILAIN 195 At the grammatical level, this strategy has a natural analogue in lexical ambiguity, the ambiguity encountered when a terminal (e.g. the English word can) is derivable by more than one pre-terminal (e.g. V, N, or AUX). In linguistic parsers the terminals in a string are usually replaced with the corresponding pre-terminals, so lexical ambiguity can be simply dealt with by adding each ambiguous pre-terminal directly into the same cell of the chart. Similarly, the plan parsing algorithm in Figure 3 can be amended to enter any abstract observation q(e) into its chart cell as the set of I+Vi that it abstracts. A MAKE-NOODLES observation, for example, would be entered in the chart as a set of two terminals: {MAKE-SPAGHETTI MAKE-FETTUCCINE} . This approach to abstract observations preserves the correctness of the plan parser. As noted above, it directly enforces the disjunction schema. That the exclusion schema is enforced can be seen by noting that no two ambiguous terminal entries appear in the same parse. Consequently, under the sentential interpretation of parse trees, no two ambiguous but incompatible types can hold true of the same plan variable or plan constant. Finally, for each distinct parse, it is easy to verify that the algorithm will fully instantiate the component/use schema. The disjunctive treatment of abstraction also maintains the polynomial tractability of the plan parser. This can be seen by noting that the O(G O 2 n3) time bound on parsing an observation string of length n is obtained from a O(G O 2 n2) bound on each step of the main loop of the parser (which is iterated n times). Informally, one can think of an ambiguous observation q in position [i-l, i] as temporarily “augmenting” the grammar for iteration step i. The augmentation consists of introducing a new category OBSERVED-9 and new rules of form OBSERVED-9 + vi, for each I+Yi maxi- mally specializing (p. The abstract observation is then encoded as a token of OBSERVED-q. This has a net effect of temporarily adding no more than P rules to the grammar at each step of the parser’s main iteration, and so G O remains bounded at each step by O(Pd). This leaves the overall time complexity of parsing unaffected. The following proposition summarizes the discussion of the past few pages. Proposition 3: There is a O(n3)-time plan recognition algorithm for hierarchies with ordered, unshared steps, and for disjunctive or abstract observations. Further Extensions This result is of significant value, as it delineates a subset of Kautz’ plan formalism for which plan recog- nition is tractable. The parsing approach underlying this result can in fact be extended to cover further aspects of Kautz’ formalism, but unfortunately not without also sacrificing recognition tractability. Partial Step Order A number of recent linguistic formalisms refine the traditional phrase structure rules into two sets of rules: (1) indirect dominance (ID) rules, which specify which subconstituents may be derived by a constituent, and (2) linear precedence (LP) rules, which determine the left-to-right order of these subconstituents. This ID/LP strategy can be applied to plan hierarchies to allow for a compact encoding of partial step ordering. For example, the following two sketchy rules specify that the BOIL-WATER step of the MAKE-PASTA-DISH plan must be ordered before the MAKE-NOODLES step, but leaves all other step relations unordered. PASTA --=+ BOIL NOODLES SAUCE (ID rule) BOIL < NOODLES (LP rule) In effect, an ID rule of length n stands for an equivalent n! ordered context-free rules, some of which are then eliminated if they fail to satisfy the LP rules. In principle, one could thus parse an ID/LP grammar with Earley’s algorithm by first compiling it into the corresponding context-free rules. However, as the number of such rules is combinatorially explosive, the size of the resulting grammar would be correspondingly large, and parse times correspondingly lengthy. To alleviate this problem, Shieber (1983) produced a simple extension to Earley’s algorithm that allows for direct parsing of ID/LP grammars, thus circumventing the combinatorial explosion produced by compilation. Unfortunately, Shieber’s parser does not escape intractability. Barton et al. (1987) show that ID/LP parsing is NP-complete under certain conditions. The argument is complex, but for the purposes of this paper it suffices to note that a sufficient condition for NP- completeness is the kind of lexical ambiguity used above to encode abstract observations. In fact, this NP- completeness result can easily be extended to show the following proposition (offered here without proof). Proposition 4: Recognizing plans with abstraction and partial step order is NP-complete, regardless of recognition tactic. This pessimistic result must be taken in perspective. Shieber’s algorithm performs well in practice, and truly extreme derivational ambiguity is required to lead it to exponential performance. In fact, Barton et al. suggest that tractability may actually be regained by ensuring that the unordered steps of an ID decomposition are derivationally distinct. This is the case, for example, with the ID rule decomposing MAKE-PASTA-DISH, each of whose steps derives a set of constituents distinct from those derived by the others. However, a general plan distinguishability criterion has yet to be formulated. Action Parameters Kautz allows plans to have parameters, such as an agent. As with other aspects of plan recognition, action 196 AUTOMATEDREASONING parameters have a grammatical analogue, in this case with unification grammars (another extension of the context-free class). Without going into details, it is straightforward to show that plan parameters and constraints on these parameters can be encoded in the unification formalism. However, parsing unification grammars is again NP-complete in the presence of derivational ambiguity (Barton et al. (1987)). Plan Parsing in Perspective There are additional aspects of Kautz’ approach that may not be convincingly treated with a parsing strategy. Shared and interleaved steps are a particularly salient example of this. It is admittedly possible to formulate some kind of type 0 or perhaps context-sensitive phrase structure rules to encode the sharing or interleaving of steps. However, it is not at all clear how to do so without endowing the plan formalism with enough machinery to make plan recognition intractable or even undecidable (type 0 grammars being Turing-equivalent). Nevertheless, the main thrust of this work is not to show that all of Kautz’ approach can be reformulated as parsing, as much as it is to find those aspects of his approach that become tractable when so reformulated. Beyond the immediate gains of tractability, the parsing approach does provide an operational advantage over Kautz’ algorithms. Namely, it focuses recognition by predicting the existence of only those END plans sanctioned by all the observations taken together. Kautz’ algorithms perform the prediction on each individual observation, independent of the others, and then combine the resulting predictions. This is computationally much more onerous, but may turn out to be unavoidable if one wants to allow for sharing and interleaving of steps. Finally, I should note that there are many similarities between the parsing strategies described here and the plan recognition strategies in MITRE’S King Kong interface (Burger & Sider, 1990). As part of our current research, my colleagues and I are investigating further extensions to King Kong that rely on parsing strategies. Acknowledgements This work has benefitted from discussions over the years with James Allen and Henry Kautz. Special thanks to Ellen Hays for her untiring editorial attention. References Allen, J. (1983). Recognizing intentions from natural language utterances. In Brady, M. & Berwick, R. (eds) Computational Models of Discourse. Cambridge, MA: The MIT Press. Allen, J. & Perrault, R. (1980). Analyzing intention in dialogue. Artificial Intelligence 23(2), 832-843. Barton, 6. E., Berwick, R. & Ristad, E. (1987). Computational Complexity and Natural Language. Cambridge, MA: The MIT Press. Billot, S. & Lang, B. (1989). The structure of shared forests in ambiguous parsing. In Proceedings of ACL 89, 143-151. Burger, J. & Sider, J. (1990). Discourse Understanding in Expert System Interfaces. In preparation. Carberry, S. (1983). Tracking goals in an information seeking environment. In Proceedings of AAAI 83, 59-63. Earley, J. (1970). An efficient context-free parsing mechanism. Communications of the ACM 13(2), 94-102. Reprinted in Grosz et al. (1986). Goodman, B. & Litman, D. (1990). Plan recognition for intelligent interfaces. In Proceedings of the IEEE Conference on Artificial Intelligence AppZications 1990. Grosz, B., Sparck Jones, K., Webber, B. L. (1986). Readings in Natural Language Processing. San Mateo, CA: Morgan Kaufmann. Kay, M. (1980). Algorithm Schemata and Data Structures in Syntactic Processing. Tech Report CSL- 80-12, Xerox PARC. Reprinted in Grosz et al. (1986). Kautz, H. (1987). A Formal Theory of Plan Recognition. PhD dissertation, Dept. of Computer Science, University of Rochester. Available as Tech. Report 215. Kautz, H. & Allen A. (1986). Generalized plan recognition. In Proceedings of AAAI 86, 32-37. Konolige, K. & Pollack, M. (1989). Ascribing plans to agents - preliminary report. In Proceedings of IJCAI 89,924-930. Litman, D. (1986). Linguistic coherence: A plan-based alternative. In Proceedings of ACL 86, 215223. Pollack, M. (1986). A model of plan processing which distinguishes between the beliefs of actors and observers. In Proceedings of ACL 86, 207-214. Sacerdoti, E. (1977). A Structure for Plans and Behavior. New York: North-Holland. Schmidt, C. , Sridharan, N., & Goodson J. (1978). The plan recognition problem: An intersection of artificial intelligence and psychology. Artificial Intelligence, ll( l), 45-83. Shieber, S. (1983). Direct parsing of ID/LP grammars. Linguistics and Philosophy 7(2), 135- 154. Sidner, C. (1985). Plan parsing for intended response recognition in discourse. Computational Intelligence, I(l), l-10. Thompson, H. (1983). MCHART: A flexible, modular chart parsing system. In Proceedings of AAAZ 83, 408- 410. Tomita, M. (1986). Efficient Parsing for Natural Language. Boston: Kluwer Academic Publishers. Wilkins, D. (1984). Domain-independent planning: representation and generation. Artificial Intelligence 22, 269-301. VILAIN 197
|
1990
|
27
|
942
|
tion for Plannin Under Uncertainty Michael P. Wellman AI Technology Office, Wright R&D Center Wright-Patterson AFB, OH 45433 wellman@wrdc.af.mil Abstract The virtue of the STRIPS assumption for planning is that it bounds the information relevant to determin- ing the effects of actions. Viewing the “assumption” as a statement about beliefs, we find that it does not actually assume anything about the world itself. We can characterize the assertion about beliefs in terms of probabilistic independence, thereby facilitating analysis of representations for planning under uncertainty. This interpretation separates the STRIPS assumption from other necessary features of a planning architecture, such as its model of persistence and its inferential policies. By isolating these factors, we can understand the role of dependence across a wide range of planners and action represent ations. Graphical models of dependence de- veloped for probabilistic analysis provide a convenient tool for verifying the STRIPS assumption for a variety of planning systems. Investigation of a few representative systems reveals a Markovian event structure common to these planning models. The Frame Problem and the STRIPS Assumption The classic dilemma in representing and reasoning about the effects of actions is the frame problem, orig- inally identified by McCarthy and Hayes [1969]. The frame problem has come to stand for a variety of com- putational and notational complexities arising from the apparent necessity of considering the possible change in status of every proposition for each action. Char- acterizations of the problem vary widely [Brown, 1987; Pylyshyn, 19871, proposed solutions even more so, but a kernel of consensus does seem to exist. AI researchers agree that part of the problem, at least, has to do with specifying the effects of actions without explicitly de- scribing all ramifications and qualifications. In partic- ular, we want to avoid a requirement for explicit frame axioms specifying the propositions not affected by each action. Actual planners eschew frame axioms and restrict at- tention to propositions explicitly mentioned in their action specifications, a convention first applied by STRIPS [Fikes and Nilsson, 19711. Waldinger has named this policy the "STRIPS assumption” [1977]. McDer- mott [1987] asserts that no program since STRIPS has been practically bothered by the frame problem, which is true if we define the problem narrowly as the need for frame axioms in the deductive planning approach. Nev- ertheless, building planners that perform well in com- plex dynamic environments is no easy task, in large part due to difficulties of representing and reasoning about change. As McDermott also points out, the frame prob- lem does frustrate attempts at logical analyses of these programs and their environments, which should be rel- evant to the goal of designing better algorithms and representations. Much of the work on nonmonotonic logic is addressed to this issue. Understanding the nature of the STRIPS assump- tion and the extent to which it circumvents the frame problem is a first step to understanding the larger is- sues in reasoning about actions. Previous discussions of the STRIPS assumption, including the original by Waldinger [1977], tended to encompass all of these issues, failing to distinguish the relatively small role played by this particular notational convention. While the broader views provide fuller accounts of the plan- ners they address, their analyses are not transferable to planning frameworks that take significantly different approaches to representing and reasoning about change. For example, Lifschitz’s analysis [1986] focuses on conditions under which STRIPS'S add/delete mechanism will be guaranteed to produce only valid plans. The analysis concludes essentially that STRIPS systems are sound as long as 1. the use of non-atomic sentences in operator descrip- tions and world models is restricted (in a precise man- ner described by Lifschitz), and 2. a kind of strong persistence holds, where no changes occur except as specified in add and delete lists. These conditions (which clarify STRIPS significantly) apply to planning frameworks that adopt the same strong persistence model and forbid inference about the further consequences of specified effects. Many have been unwilling to accept these restrictions, and have 198 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. worked on methods and semantic accounts of systems that go beyond them. Research on the task of determining the implications of specified effects of actions (called the ramification problem), its counterpart for preconditions (the quulifi- cation problem), and development of models of persis- tence are important areas of investigation for AI plan- ning. The point of this paper is that there is a separable aspect of the STRIPS assumption that is orthogonal to these issues, and therefore applicable across a variety of planning frameworks. Generally stated, the STRIPS as- sumption per se dictates that the effect of an action on the world model be completely determined by the direct effects explicit in its specification. By saying only that it is “completely determined,” we permit the nature of the implicit effects to vary among planning systems. I examine this interpretation below from the perspec- tive of planning under uncertainty. Uncertainty pro- vides further motivation for this view of the STRIPS as- sumption, and concepts from uncertain reasoning help to characterize it more precisely for application to ex- isting planning frameworks. Planning under Uncertainty An agent plans under uncertainty whenever it can- not flawlessly predict the state of the environment re- sulting from its actions. By this definition, uncer- tainty is a characteristic of the agent’s knowledge rather than an inherent property of the environment. Given that we are never likely to achieve perfect prediction in realistic environments, all planning is actually per- formed under uncertainty; planning under certainty is an unrealizable-albeit often useful-idealization. The frame problem arises in planning under uncer- tainty just as it does in the idealized framework. Plan- ners must employ something like the STRIPS assump- tion to justify leaving non-effects of an action implicit in their omission from the action’s specification. However, semantic accounts of the STRIPS assumption in classical planning (e.g., STRIPS itself [Lifschitz, 19861) do not eas- ily map over to the uncertain case, The conventional interpretation, that planners assume that relations in the world model are unchanged unless explicitly speci- fied, cannot literally apply to planners that admit they have incomplete knowledge about the effects of their actions on the world. Perhaps we could modify the interpretation to as- sume that changes of unspecified relations are un- likely rather than impossible. The problem of this approach is identifying a particular, well-motivated, likelihood assumption that is sufficiently general for domain-independent planning. As demonstrated by some work along these lines [Dean and Kanazawa, 1988; Hanks, 19901, defining such a convention is tantamount to adopting a model of persistence and probabilistic in- ference. Moreover, these persistence models tend to be more varied and complicated than those proposed for planning under certainty. These differences provide further motivation for a characterization of the STRIPS assumption that does not depend on a particular model of persistence. The essential property of the STRIPS assumption that justifies implicit treatment of non-effects is the pre- sumption that the information specified explicitly is sufficient to describe the agent’s change in belief. In other words, once the direct effects are known, knowl- edge of the action itself is superfluous for purposes of prediction. Thus, the STRIPS assumption is fundamen- tally a statement that the agent’s beliefs about changes in propositions not mentioned in an action’s speciflca- tion are independent of the action, given those effects explicitly specified. For planning under uncertainty, we can characterize beliefs in terms of probability distribu- tions and use the concept of probabilistic independence to formalize this interpretation of the STRIPS assump- tion. Probabilistic Independence In a state of uncertainty, an agent’s beliefs are repre- sentable by a probability distribution over possible situ- ations (which is not to say that the agent’s beliefs need be encoded as such in some data structure). We take situations to be assignments on a universe of variables describing the world, including such things as what actions are performed and their consequences. Belief states are then probability distributions over this space. Note that this framework avoids imposing a temporal ontology, which, while providing essential structure for the planning problem, would also detract from the gen- erality of our analysis of the issue at hand. To capture the meaning of the STRIPS assumption proposed above, we need a way to express the suffi- ciency of explicitly specified effects to describe the full impact of an action on the agent’s beliefs about the world. For this purpose, the natural concept in proba- bility theory is conditional independence. We say that random variables z and y are conditionally independent given z iff Pr(zly,z) = Pr(zjz) (1) for any possible values of the variables. In other words, once the value z is known, finding out the value of y has no effect on the agent’s belief about 2. In this case, y is superfluous information. The STRIPS assumption is paraphrased by a schema for equation (1). Performance of an action is repre- sented by y, z stands for the explicit effects of y plus the “background,” and x represents “everything else.” The independence assertion is that for a given background, knowing the explicit effects of y provides all the infor- mation useful for predicting its implicit effects, that is, everything else. Given its explicit effects, knowledge about the action’s performance is redundant. For a satisfactory interpretation, we need a more complete account of concepts like “background” and WELLMAN 199 “everything else.” To understand their role in planning systems, we investigate a class of representations for actions and events based on graphical models. Graphs provide a formal language for expressing (via adja- cency) the locality of explicit effects in planning rep- resentations. Graphical Dependence Models A probabilistic network (also called a Buyesiun or belief network [Pearl, 19881 or influence diugrum) is a directed acyclic graph (DAG) with nodes for the random vari- ables connected by links indicating probabilistic rela tions. Associated with each node is a probability dis- tribution for its variable given the possible values for its predecessors in the graph. Thus, a link from x to y indicates that y might depend probabilistically on x. Conversely, the absence of links restricts the dependen- cies that can be encoded in the network. The graph- ical condition for conditional independence in proba- bilistic networks is called d-separation [Geiger, 1990; Pearl et ad., 19891. Two nodes 2 and y.are d-separated by a set of nodes 2 in a DAG iff for every undirected path between them either: 1. there is a node z E 2 on the path with of the incident edges leading out of Z, or at least one 2. there is a node z’ on the path with both incident edges leading in, and neither .z’ nor any of its succes- sors are in 2. A dependency graph for which all d-separations are valid conditional independencies is called an I-map. Al- though any joint distribution can be represented graph- ically by some probabilistic network (which are all I- maps), the most efficient representations are those with- out superfluous links, called minimal I-maps. We can characterize the independence condition un- derlying the STRIPS assumption in terms of these depen- dency graph concepts. Consider a probabilistic network with variables for all actions and events relevant to the planner. Every action node has an outgoing link exactly to those events explicitly represented as direct effects. Events may have arbitrary connections among them- selves, as dictated by some world model (outside the scope of discussion here). Action nodes have no incom- ing links, reflecting our presumption that the planner has control over which actions are to be performed. The STRIPS assumption is that the graph so con- structed is an I-map. Let Sa be the set of event vari- ables that action variable a directly affects, a’s imme- diate successors in the dependency graph. By virtue of I-mapness, a is conditionally independent of any e 4 S, given e’s predecessors (see, for example, [Well- man, 1990b, Lemma 4.11). Each predecessor d of e, in turn, is either a direct effect of a or is conditionally in- dependent given its own predecessors. Ultimately, the effect of a on e is completely determined by u’s direct effects and e’s relation to them. Note that we still need to describe the interaction, if any, between a and e in their joint effects. The probabilistic STRIPS assumption does not require that a be conditionally independent of e given the direct effects S,, or even by any subset of S,. In Figure 1, for example, a and e are d-separated by (s, b} but bY no other variable set. The variable b is necessary for conditional independence of a and e even though b itself is unconditionally independent of a. n “background” “other” event action Figure 1: Action a is conditionally independent of e given 2, = {s, b) but not given any subset of its direct effects Scr = (s). If we enlarge the conditioning set to include predeces- sors of u’s direct effects, however, we get another valid independence condition. Let Za = S, U I?,, where B, (the “background”) is the set of variables that affect u’s direct effects: B, = U predecessors(s) - {a}. SE-S, The d-separation condition implies that a is condition- ally independent of e given Za. In the graph of Figure 1, for example, the background B, = {b), and 2, = {s, b). The dependency graph model permits us to formalize the STRIPS assumption in terms of probabilistic condi- tional independence. In particular, there must exist an I-map of variables in the world model where any vari- able e not specified as an effect of action a is not directly connected to a. Under this condition there may be a probabilistic dependency between a and e in some situ- ations, but this-can always be described in terms of u’s and e’s relations to Sa. - We can apply the graph construction to the informal statement of the independence condition given in the previous section. Filling in the terms, our statement is that the complete effects of an action a are fully speci- fied by the direct effects, S,, and the background, B,. Everything else, e, is implicit in these variables. That is, e is conditionally independent of a given S, and BiZ . The fragment of Figure 1 can serve as a graphi- cal schema for this pattern of relations, by interpreting 200 AUTOMATEDREASONING the nodes as sets of variables and permitting the vari- ables e to be connected via arbitrary paths to b and S. Applications The conditional independence interpretation is a valu- able tool for studying specific planning systems and val- idating their use of the STRIPS assumption. A practical prerequisite for applying these results is identifying the relevant background context, B,, for the various plan- ners. Note that while planners adopt different policies regarding how the implicit effects are derived from the explicit effects and background, validity of the STRIPS assumption does not depend on these policies. In the following sections I illustrate the application of the independence concepts by analyzing aspects of three planning systems. The planners examined differ in their probabilistic or deterministic representations for the effects of actions, as well as the type of temporal structure imposed on the planning environment. SUDQ-Planner SUDO-PLANNER [Wellman, 199Oa] uses qualitative prob- abilistic networks (QPNs) [Wellman, 1990b], abstrac- tions of the models described above, for representing and reasoning about the effects of actions. When intro- ducing actions and events of interest, the planner mod- ifies the structure of the existing network to preserve the model’s validity. One class of constructs appear- ing in SUDO-PLANNER'S knowledge base, called Murkov influences, specify the effect of an action on an event variable and its dependence on the previous value of that variable. For example, consider a QPN for a medical therapy problem that includes a variable for the extent of a pa- tient’s coronary artery disease (CAD). One action con- sidered by the planner is a coronary artery bypass graft (CABG): bypass surgery to alleviate the coronary dis- ease. The effect of CABG is to decrease CAD (in a precise probabilistic sense [Wellman, 1990b]). Further- more, the Markov influence specifies that the decrease is greater for patients who have more severe CAD ini- tially. This relationship refers to the variable CAD at two distinct points in time-before and after CABG- and thus cannot be captured by simply adding CABG to the network. Instead, SUDO-PLANNER modifies the QPN by splitting CAD into two variables, CADi and CAD2. Figure 2 diagrams the result of this mitosis process. CABG negatively influences CAD2, which is otherwise positively related to its value before surgery, CADI. The boxed minus sign indicates the synergistic interaction of CABG with CADI. Predecessors of the original CAD variable are connected to CADl, while its successors before processing the Markov influence are transferred to CA D2. This process has direct implications for conditional independence (which indeed was the reason for calling CAD influences influences CAD Figure 2: The Markov influence of CABG on CAD. them Murkov influences). Specifically, influencers of the original variable CAD are independent of CAD2 given CA D1, and CAD’s original influences cannot depend on CA D1 given CAD2. (The reason is that any path be- tween influences and influencers that circumvents the CADi variables must include at least one node with both incident edges leading in.) These conditions in turn imply that any variable in the network is indepen- dent of CABG given CA D1 and CAD2. More generally, suppose the action a is defined ex- clusively by Markov influences on a set of event vari- ables E. The STRIPS assumption dictates that the ef- fects of a be completely captured by these influences. The corresponding independence condition is that any other event be conditionally independent of a, given za = S, U B,, where the direct effects S, = Es, the second halves of the split event variables, and the back- ground B, = El, the first halves produced by SUDO- PLANNER'S variable mitosis process. Markov Influence Diagrams Kanazawa and Dean [1989] propose a framework for planning under uncertainty based on “causal models,” influence diagrams with the Markov property and some other features inessential for our purposes. In a Markov influence diagram, there is a node corresponding to ev- ery proposition of interest at every distinguished instant of time. The Markov property is enforced by permit- ting nodes at time t to depend only on nodes from time t -1. If this convention applies to actions as well, then - - any event at time t is d-separated from actions at time t’ < t by the action’s direct effects (all at time t’ + l), plus the events of time t’. Figure 3 depicts the generic structure of a h4arkov influence diagram. Note that all links relate an action or event to an event at the next time point. It is pos- sible to relax this restriction-for example, by adding auxiliary atemporal variables-as long as the regular- ity of temporal states is retained. See, for instance, the variant scheme described by Berzuini et al. [1989]. WELLMAN 201 t t+l t+k situation t . actions even eoe 0.0 l .0 0.0 0 0 -ci% Figure 3: A schematic view of Markov influence dia grams. Actions and events at time t need not be con- nected to every event at t + 1. With respect to our statement of the STRIPS assump- tion, the background is (conservatively) the state of the world at the time of the action, that is, the actions and events appearing in the same column of Figure 3. The direct effects are the events from the next time point with links from the action node. In schemes for proba- bilistic temporal projection [Dean and Kanazawa, 1988; Hanks, 19901, these links are typically specified by a set of causaZ rules associating actions and events with their possible consequences. STRIPS Instantiated propositionally for a finite world, we find that a STRIPS model is actually a degenerate kind of Markov influence diagram. The Markov property fol- lows from the linearity of the situation calculus frame- work [McCarthy and Hayes, 19691. The propositions at a situation s are deterministic functions of those of the previous situation. And under Lifschitz’s soundness conditions [1986], the relation of functional dependence is defined by mention in add and delete lists. The per- sistence model of STRIPS is that for a given proposition this function is the identity in the absence of an ac- tion performed at s affecting that proposition. Thus, the background required for any proposition is only its value in the previous situation. In terms of dependency graphs, the STRIPS model is constructed as follows. Let a and e denote action and event types, with nodes at and et for every type in every 54 = {e ] e in a’s add or delete list), predecessors(et) = et-1 U (at-1 I e E S}. Most STRIPS-like systems do not specify what hap- pens when actions are performed in situations where their preconditions do not hold. To represent “context- dependent effects” [Pednault, 19881, we need only to add events mentioned in preconditions to the back- ground of affected events. For deterministic variables, there is a stronger graph- ical criterion for conditional independence, called D- sepamtion (note uppercase) [Pearl et ad., 19891. Al- though the independence condition for STRIPS’S sim- ple graph structure is trivial, the more powerful crite- rion might be useful for analyzing STRIPS-like systems that permit logical and perhaps probabilistic relations among propositions. Summary The interpretation presented here provides a new per- spective on the STRIPS assumption, constraining the se- mantics of a planner’s knowledge base of actions and events. Essehtially, it mandates that the implicit con- sequences of an action be completely specified by its di- rect effects. Although described and motivated in terms of probabilistic conditional independence, the interpre- tation has implications for planning systems regardless of whether they employ probabilistic representations. Moreover, it is sufficiently general to capture the princi- ple behind the STRIPS assumption for planning systems with action-event representations considerably more ex- pressive than that of STRIPS. The main advantage of this approach is that it dis- tinguishes the concept of belief dependency from the model of persistence of events in the world. It does not obviate the need for such a persistence theory, though it renders the issue orthogonal to the STRIPS assumption per se. Examination of a variety of planning systems indi- cates that the dependency graph is a useful analytical tool for investigating the structure of relations among actions and events. When the analysis reveals regular- ity in this structure (as should be expected for reason- able planning architectures), general d-separation pat- terns can be derived, yielding constraints on the impact of actions on the agent’s beliefs about the world. We can then exploit these constraints to design more effi- cient action representations and belief revision mecha- nisms. It is not surprising that all the analyses of planning systems above appeal to some sort of Markov prop- erty. Any temporal structure on a pattern of condi- tional independence constitutes a Markovian form of model. This suggests that the theory of Markov models may be a good place to search for structured patterns of uncertain relationships among events over time. 202 AUTOMATEDREASONING The most important limitation of the analysis is that dependency graphs are an inherently propositional represent ation. Application to planning systems with quantified constructs (any nontrivial action and event representation) requires some instantiation mechanism. A potential solution approach is to apply the first-order axioms of conditional independence directly. This tech- nique might be beneficial even for the propositional case, as the axiomatic theory may be stronger than the graphical [Pearl et al., 19891. References [Berzuini et al., 19891 Carlo Berzuini, Riccardo Bel- lazzi, and Silvana Quaglini. Temporal reasoning with probabilities. In Proceedings of the Workshop on Uncertainty in Artificial Intelligence, pages 14-21, Windsor, ON, 1989. [Brown, 19871 Frank M. Brown, editor. The Frame Problem in Artificial Intelligence: Proceedings of the 1987 Workshop. Morgan Kaufmann, 1987. [Dean and Kanazawa, 1988] Thomas Dean and Keiji Kanazawa. Probabilistic temporal reasoning. In Pro- ceedings of the National Conference on Artificial In- telligence, pages 524-528, 1988. [Fikes and Nilsson, 19711 Richard E. Fikes and Nils J. Nilsson. STRIPS: A new approach to the application of theorem proving to problem solving. Artificial In- telligence, 2:189-208, 1971. [Geiger, 19901 Dan Geiger. Graphoids: A qualitative framework for probabilistic inference. Technical Re- port R-142, UCLA Computer Science Department, January 1990. [Hanks, 19901 Steven John Hanks. Projecting plans for uncertain worlds. Technical Report 756, Yale Univer- sity Department of Computer Science, January 1990. [Kanazawa and Dean, 19891 Keiji Kanazawa and Thomas Dean. A model for pro- jection and action. In Proceedings of the Eleventh International Joint Conference on Artificial Intelli- gence, pages 985-990, 1989. [Lifschitz, 19861 Vladimir Lifschitz. On the semantics of STRIPS. In Michael P. Georgeff and Amy L. Lansky, editors, Reasoning about Actions and Plans: Proceed- ings of the 1986 Workshop, pages l-9. Morgan Kauf- mann, 1986. [McCarthy and Hayes, 19691 J. McCarthy and P. J. Hayes. Some philosophical problems from the stand- point of artificial intelligence. In B. Meltzer and D. Michie, editors, Machine Intelligence 4, pages 463-502. Edinburgh University Press, 1969. [McDermott, 19871 Drew McDermott. AI, logic, and the frame problem. In Brown [1987], pages 105-118. [Pearl et al., 19891 Judea Pearl, Dan Geiger, and Thomas Verma. Conditional independence and its representations. Kybernetiku, 25:33-44, 1989. [Pearl, 19881 Judea Pearl. Probu bilistic Reasoning in Intelligent Systems: Networks of Plausible Inference. Morgan Kaufmann, 1988. [Pednault, 1988] Ed win P. D. Pednault. Extending conventional planning techniques to handle actions with context-dependent effects. In Proceedings of the National Conference on Artificial Intelligence, pages 55-59. AAAI, 1988. [Pylyshyn, 19871 Zenon W. Pylyshyn, editor. The Robot’s Dilemma: The Frame Problem in Artificial Intelligence. Ablex, 1987. [Waldinger, 19771 Richard Waldinger. Achieving sev- eral goals simultaneously. In E. Elcock and D. Michie, editors, Machine Intelligence 8, pages 94-136. Edin- burgh University Press, 1977. [Wellman, 199Oa] Michael P. Wellman. Formulation of Trudeofi in Planning Under Uncertainty. Pitman and Morgan Kaufmann, 1990. [Wellman, 1990b] Michael P. Wellman. Fundamental concepts of qualitative probabilistic networks. Arti- ficial Intelligence, 1990. WELLMAN 203
|
1990
|
28
|
943
|
ABTWEAK: Abstracting a Nonlinear, Least Commitment Planner * Qiang Yang Computer Science Department University of Waterloo Waterloo, Ontario, Canada, N2L 3Gl qyang@watdragon.waterloo.edu. Abstract We present the system ABTWEAK, which extends the precondition-elimination abstraction of AB- STRIPS to hierarchical planners using the non- linear plan representation as defined in TWEAK. We show that ABTWEAK satisfies the mono- tonic property, whereby the existence of a lowest level solution II implies the existence of a high- est level solution that is structurally similar to II. This property enables one to prune a considerable amount of the search space without loss of com- pleteness. Abstracting Planning Systems Abstraction in planning systems can be viewed as a mapping from one problem description (at a concrete level) to another(at the abstract level). There has been a considerable amount of research recently in formalizing intuitions regarding abstraction and the hierarchical problem solving strategies that abstrac- tion gives rise to [Fikes et al., 1972; Knoblock, 1988; Korf, 1985b; Nau, 1987; Sacerdoti, 1974; Tate, 1977; Tenenberg, 1988; Wilkins, 1984; Yang, 19891. However, there has been little work in extending the formal results from linear STRIPS-like planners to richer temporal planners, such as the nonlinear plan- ners of Sacerdoti [1977] and Chapman [1985]. The ad- vantage of these planners over linear planners is that they allow temporal order and operator instantiations to be only partially specified through the posting of constraints; any fully specified plan consistent with *This work was supported in part by an interim re- search grant to Qian g Yang, from the Faculty of Mathe- matics at the University of Waterloo, and by grants to Josh D. Tenenberg in part from the Air Force Systems Com- mand, Rome Air Development Center, Griffiss Air Force Base, New York 13441-5700, and the Air Force Office of Scientific Research, Boiling AFB, DC 20332, under Con- tract Num. F30602-85-C-0008 which supports the North- east Artificial Intelligence Consortium (NAIC), in part by ONR/DARPA research contract #N00014-80-C-0197, and in part by US Army Communication-Electronics Command grant #DAABlO-87-D-022. 204 AUTOMATED REASONING Josh D. Tenenberg Computer Science Department University of Rochester Rochester, New York, U.S.A., 14627 josh@cs.rochester.edu these constraints is guaranteed to solve the given prob- lem. One particular type of abstraction that we have pre- viously formalized [Tenenberg, 19881, involves the elim- ination of a subset of the predicates in the language as one ascends the abstraction hierarchy (a generalization of the precondition elimination strategy of ABSTRIPS [Sacerdoti, 19741). The predicates of the planning sys- tem are partitioned, which induces a partition on the preconditions of the operators, and each partition is assigned an integer value, a criticality. Each abstract level i is derived from the previous level by eliminating those preconditions having criticality < i, otherwise being identical. We define the system ABTWEAK, and demonstrate in this paper that precondition-elimination abstraction can be naturally extended to nonlinear least commit- ment planners, and thus benefit from the advantages of both abstraction and nonlinearity. Most importantly, we show that each ABTWEAK system has a monoton- ically expandable abstraction space, whereby the exis- tence of a lowest level solution II implies the existence of a highest level solution that is structurally similar to II. This property enables one to prune a considerable amount of the search space without loss of complete- ness. In addition, the abstraction space is monotonic regardless of the criticality assignment, i.e., it does not depend upon obtaining the “right” assignment of crit- icality values to preconditions. We first present brief descriptions of TWEAK and ABSTRIPS, and then define ABTWEAK. We demon- strate that ABTWEAK has the monotonic property, and show how this affects search. All lemmas and the- orems are presented without proofs. These proofs can be found in the longer version of this paper [Yang and Tenenberg, 19901. Nonlinear Planning: TWEAK Chapman [1985] p rovides a formalization of a least commitment, nonlinear planner, TWEAK. TWEAK ex- tends STRIPS by allowing for 1. a partial plan, temporal ordering on the operators in a From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. 2. partial constraints on the binding ignations) of the operators. of variables (codes- A TWEAK plan thus represents a space of STRIPS plans: all totally ordered, fully ground plans that sat- isfy the ordering and codesignation constraints. Formally, a TWEAK system is a pair C = (L, 0). L is a restricted language consisting of countably many predicate, constant and variable symbols, but none of the logical connectives (and, therefore, not the quanti- fiers). The set of terms of L is the constants unioned with the variables, and the set of propositions is all expressions of the form where P is an n-ary predicate and the xi are terms. The set of liter&s of L is the set of propositions unioned with the set of negations of propositions. 0 is a set of operator templates (referred to simply as operators), defined in terms of preconditions and ef- fects, with the variables in each operator standardized apart. Each precondition or effect is a literal in L. If a E 0 is an operator, then P, is the set of precondi- tions of a, and 23, is the set of effects of a. An operator a asserts literal p if p E E,, and denies p if lp E E,. Chapman [1985] did not give a formal definition of a TWEAK plan. Because this concept is very important in defining a number of others later in the paper, we formally define it below: Definition 1 A plan II is a triple (A, B, C), where o A(n) is a set of operators, defined in terms of pre- conditions and effects, o B(H) is a partial ordering on A (“‘4 ‘), 0 C(II) is a set of codesignation and non-codesignation constraints of the form p w q or p $S q, where p and q are both either terms or propositions. If CL, b are operators in A(II), we say B(R) I- (a 3 b) if and only if (a + b) follows from the transitive closure of B(II). That is, a precedes b under every total ordering that satisfies B(II). If P(xr, . . . , x~) and P(yr, . . . , ym) are propositions, we say if and only if each (x; = yi) follows from the symmetric and transitive closure of the codesignation constraints of C(II). Likewise for non-codesignation. With the above definition, we can now restate for- mally several terminologies used in [Chapman, 19851. A complete plan is a plan where B(n) is a total or- dering on A( II), and C(II) is such that every variable in every operator of A(n) codesignates with some con- stant. A plan completion refers to any complete plan that satisfies the partial constraints of a plan. An input problem is taken to be a pair, p = (I, G), where I is the initial state, and G is the goal state, each state consisting of a finite set of literals. A com- plete plan for a problem implicitly defines a sequence of states: the first element of the sequence is the given initial state, and the i + lSt element of the sequence is the ith state without the literals denied by the ith operator, and including the literals asserted by the ith operator. A proposition is satisfied in a state if it is an element of that state. For simplicity, the goal G can be represented by a special operator g, where Ps = E, = G. The initial state I can likewise be viewed as a special operator i, with Z?i = 0 and Ei = I. These two operators will be an element of each plan II, under the constraint that, for every other operator a E A(II), (i 4 u) and (u 4 g). A complete plan is correct if all preconditions of each operator in the plan are satisfied in the state in which the operator is applied. A complete plan solves a prob- lem if it is correct, and the goal is satisfied in the final state. A .plan solves a problem if every completion solves the problem; similarly for correctness of plans. In a partial plan, two terms necessarily codesignate, that is, unify, if they codesignate under every comple- tion. Two terms possibly codesignate if they codesig- nate under some completion. Operator a necessarily precedes b if a precedes b under every completion. a possibly precedes b if a precedes b under some com- pletion. We will use •I and 0 to denote necessarily and possibly, and w, #, and < to denote codesignates, non-codesignates and precedes. Necessary and pos- sible precedence, codesignation and noncodesignation can be defined precisely, for plan P, as: The following definitions introduce simplifying nota- tion. O(a 4 c + b) e O(u 4 c) and O(c --x b), ~(a 4 c 4 b) e q (u + c) and q l(c 4 b). The Modal Truth Criterion The modal truth criterion (MTC) defines the condi- tions under which an assertion will be true at a point in a partially ordered plan. Chapman [1985] provides a concise statement of the criterion that is both nec- essary and sufficient. A problem with his definition is that it is stated in terms of situations, which are not well-defined in a partially ordered and instantiated plan. For that reason, we provide a modified version of the MTC, defined in terms of operators in a plan. Coarsely stated, a proposition p is necessarily true in the state in which operator b is applied if there exists, for every total ordering, some operator a that asserts p (adds a proposition that codesignates with p), and for which no operator between a and b asserts up. YANGANDTENENBERG 205 Definition 2 Proposition p is necessarily true in the state in which operator b is applied in plan II if and only if two conditions hold: 1. there is un operator a E A(D) and u E E,, such that q (u 4 b) and O(p M u), and 2. for every operator c E A(II) and q E E,, if O(c -X b), and O(lq M p), then there is an operator w E A(II) and r E EW such that q (c 4 w 4 b) and C(II) u +4 = PII I- (T = P)* This last condition says that (T x p) whenever (lq M P). ABTWEAK In ABSTRIPS, Sacerdoti developed an elegant means for generating abstract problem spaces, by assigning criticality values (an integer between 0 and h, for some small Ic) to preconditions, and abstracting at level i by eliminating all preconditions having criticality less than i. The formalisms for this system are straight- forward, and are provided below when criticalities are assigned to the precondition literals in a TWEAK sys- tem. A b level ABTWEAK system is a triple C = (L, 0, crit), where (1) L is a TWEAK language; (2) 0 is an operator set, as in TWEAK, and (3) crit is a function: U P, + (0, 1, . . .) Ic - l}. OEO Intuitively, crit is an assignment of criticality values to each proposition appearing in the precondition of an operator. Let a be an operator. We take iPa to be the set of preconditions of a which have criticality values of at least i: i Pa = (p 1 p E P, and crit(p) 2 i.}, and iu is operator a with preconditions iPa and effects E,. Let the set of all such ia be i0. This defines a TWEAK system on each level i of abstraction: ix = (L, i0). Upward Solution Property As with ABSTRIPS the strategy for planning with ABTWEAK is governed by length first search. When a problem is input, planning proceeds first at the most abstract, least constrained level. This plan is then ex- panded at the next lower level by inserting new oper- ators to satisfy the re-introduced preconditions. Only after all the preconditions are satisfied on the current level does the planner pass the plan to the level below. The primary reason for using this control strategy is for solving the frame problem. Implicit in this strategy is the assumption that short plans to solve a given problem are guaranteed to ex- ist at the abstract level which can be successively ex- panded, and that search strategies exist to find such abstract plans. Our intent is to formally prove this property, and to show how it places some useful con- straints on search. The intuition behind the proof is to show that if there exists a lowest (base) level solu- tion to a problem, then this solution will also solve the problem at each higher level of abstraction, since these higher levels do not place any new constraints on the problem. Further, since there are fewer preconditions at the higher levels, one can eliminate from this plan those operators whose purpose at lower levels is solely to satisfy one of the eliminated preconditions, either directly or indirectly. For instance, consider a plan for getting a box from one room into an adjacent room, in which the robot picks up the box, goes to the door, sets the box down, opens the door, picks up the box, and goes through the doorway. Suppose that the status of the door - whether it is open or closed - is ignored at the abstract level. In this case, since opening the door is no longer considered as a precondition, the intermediate steps of setting down and re-picking up the box are no longer necessary; their sole purpose was to free the agent’s hands for the door opening. Thus, the abstract level plan is simpler than the concrete level plan. Ascending Preserves Correctness For notational simplicity, if II is a plan on the base level, then for i = 1,2, . . . , Ic - 1, let ill represent the plan formed by replacing every occurrence of a (except i and g) in II by iu. As defined above, a plan II is cor- rect if and only if Vu E A(II), Vq E P,, q is necessarily true in the state in which a is applied. Removing a pre- condition of an operator while holding the plan fixed does not affect the necessary truth of any condition. Thus, after removing a precondition of an operator in II, the resulting plan II’ is still correct. However, we can establish a stronger property. Namely, if II is a plan correct at the base level, then a plan iIt’ is also a correct plan on level i, where iII’ is simpler than II in that it is ill with possibly one or more opera- tors removed. Thus, A(iII’) is possibly smaller than A(II). Moreover, the constraints in iII’ are B(II) and C(H) with possibly one or more constraints removed. Thus, the plan iII’ is less constrained than II. This will be shown by specifying the precondition establish- ment structure of the plan, that is, which operators satisfy preconditions of other operators, either directly or indirectly. Definition 3 Let II be a correct plan. Let a and b be operators in A(II), p b e a precondition of b, and u be an e#ect of a. Then a establishes p for b with u (‘Establishes(u, b, p, u)) if and only if I. q (u -x b), 206 AUTOMATEDREASONING 2. q (ue p), and 3. Vu’ E A(lI),Vu’ E -Eat, if q l(a 4 a’ 4 b), then lO(U’ x p). This final condition states that a must be the last such operator that necessarily precedes b which necessarily asserts precondition p. Given this definition, it can be proven that every precondition in every operator of a correct plan has an establisher. Nothing else is justified. Lemma 4 Let II be a correct plan, b E A(D), and p E Pb. 3u E A(II), 3~ E E, such that Establishes(u, b, p, u). Informally, a clobberer is an operator which possibly precedes and possibly denies the precondition of an- other operator in the plan. A white knight is another operator which necessarily re-establishes this clobbered precondition. Definition 5 c is a clobberer of b, (GB(c, b,p, 4)) if and only if (1) P E Pbr (2) 4 (5 EC, (3) OhI = P), (4) 3u, u such that Establishes(u, b, p, u), (5) O(a -< c 4 b). Definition 6 w is a white knight for b, PJw-4 b, c, P, 4, T)), if and only if (1) CB(c7 h P, cl), (2) r E E,, (3) q (c 4 w 4 b), and (4) C(l--g ” +4 = P)> I- (T = PI* An operator or constraint in a plan is justified if it is subservient, directly or indirectly, to the satisfaction of the goal. Definition 7 Let II be a plan, and i, g be the special operators for the initial and goal states. Then in plan JA Initial/Goal justification i and g are justified, Establishment justification If b is justified, and 3u,3u E E,, 3p E Pb such that Establishes(u, b,p, u), then (I) a is justified, (2) (a 4 b) is justified, (3) (u x p) is justified. White knight justification If WK(w, b, c,p, q, r) and b and c are justified, then w, (c < w), and ( w < b) are justified. Moreover, let D be a minimal set of codesignation constraints such that D U ((14 z p)} F (T ==: p). Then every codesignation constraint in D is also justified. Separation justification If c and b are justified, and 3p E Pb, 3q E E, such ihat q (p $ -q), then (p $ -q) is justified. Precedence Justification If b and c are justified and q l(b 4 c), then b 4 c is also justified. The justification of plan II, Jus(II), is the set of op- erators, precedence and codesignation constraints of II that are justified. It is obvious that the justified ver- sion of a plan is simpler than the plan itself, in the sense that the set of operators, precedence and codes- &nation constraints of the justified plan are a subset of those in the unjustified plan. Lemma 8 If II is a correct plan that solves goal G, then Jus(II) also is a correct plan that solves G. The following theorem establishes the Upward Solu- tion Property: if there is a solution to a problem at the base level, then the justified version of that solution at each higher level of abstraction is correct, and also solves the problem on that level. More formally, Theorem 9 If Il is a correct plan that solves G at the base level, then the justified version of iII is also a correct plan that solves G on the ith level, 0 < i < k- 1. - - Monotonic Expansion The Upward Solution Property guarantees the exis- tence of an abstract level solution to a problem, when- ever there exists a lowest level solution. Length-first search, on the other hand, proceeds from the highest level to the lowest. Since the converse of the Upward Solution Property does not hold, one cannot be sure that an arbitrary solution obtained at the abstract level is one which can be expanded into a low level solu- tion. It is therefore important to uncover constraints that will be helpful in plan expansion. The monotonic property is one such constraint, and was first defined by Knoblock, for linear ABSTRIPS systems [Knoblock, 1988]. We will define it here (in a slightly different form than Knoblock). Definition 10 Let II’ be a level i plan, and II a level i - 1 plan. c : A(II’) H A(II) is a correspondence function if and only if I. c is 1 - 1 and into, and 2. Vu E A(W), ;(~(a)) = a. Definition 11 Let II’ be an abstract plan that solves p at level i, i > 0. II’ monotonically expands to level i - 1 plan II if and only if I. II solves p at level i - 1, and .2. there exists a correspondence function c : II’ H II such that Va, b,p, u if Establishes(u, b,p, u) in II’ then Establishes(c(u), c(b),p, u) in II. Definition 12 A k-level ABTWEAK system is mono- tonic, if and only if, f or every problem p solvable at the concrete (Oth) level, there exists a sequence of plans &-1, . * -, II0 such that IIlk- solves p at level k - 1, and for 0 < i < k, II, monotonically expands to II,-1. The following Lemma can now be proven: Lemma 13 Every ABTWEAK system of k levels, for any k, is monotonic. YANGANDTENENBERG 207 Search Control In this section, we explore the implications of the Monotonic Property on search control in ABTWEAK. We will discuss global completeness of ABTWEAK as an abstraction system, and show that ABTWEAK can backtrack on violations of higher-level establishment relations and unresolvable conflicts. Completeness of ABTWEAK Search for a plan with ABTWEAK proceeds in a Eength- wise fashion, by first finding a plan at the most abstract level, and then, for each lower level i, expanding the plan II from level i + 1 by inserting operators into II, or imposing new constraints to satisfy the re-introduced preconditions in II. Thus, ABTWEAK searches for a correct concrete-level plan in a space of abstract plans. In this search space, if a plan II is not correct yet on an abstract level, then the set of state.-space operators applicable to II is the set of plan modification opera- tions in TWEAK. On the other hand, if a plan II is correct on level i > 0, then the state-space operator is simply plan expansion, which inserts all i - 1 level preconditions to each operator in II. In this section, we discuss the global search control strategy for ABTWEAK. Before describing it in detail, we first explain what seems to be an obvious choice for search control, and why it is not used for ABTWEAK. We first define what we mean by completeness, and monotonic completeness: Definition 14 A control strategy is complete if when- ever there is a solution at the concrete level, the strat- egy will terminate by finding a solution. Definition 15 A control strategy for a k-level ABTWEAK system is monotonically complete if and only if for every problem p solvable at the concrete (Ot”) level, the strategy outputs a sequence of plans Q&l,..., I& such that l&-l solves p at level k - 1, and for 0 < i < k, l& monotonically expands to Iii-1. Our aim is to explore control strategies that are mono- tonically complete. An intuitively obvious choice of control is to use a separate TWEAK for control on each level of abstrac- tion, similar to the way ABSTRIPS uses STRIPS. This is especially appealing, since it is not difficult to spec- ify complete control strategies for TWEAK, either us- ing a complete state-space search procedure such as A*, or breadth-first search, or the procedure provided by Chapman [1985]. Using this approach, if a plan is formed on abstraction level i, then it is passed down to the level below. At level i - 1, all the conditions of criticalities no less than i - 1 are planned for. The process continues, until either a correct plan is formed at the base level, or it is found that a plan cannot be made correct at a level. Then the planner backtracks to the level immediately above the current one, and tries to find an alternative solution. The fact that TWEAK is complete may lead one into believing that the above control structure is also mono- tonically complete. Unfortunately, this is not the case in general. The reason is that any search strategy for TWEAK will be semi-decidable, in the sense that if there is no solution, it is not guaranteed to termi- nate. Suppose that a plan II is found on level i + 1 that is not monotonically expandable, and is passed to the level i below. Then it is possible for TWEAK to run forever, without knowing it should backtrack to the level above. Incompleteness may result since there may exist a correct solution at the concrete level, and II cannot be expanded to that solution. Thus, although on each level of abstraction com- pleteness is guaranteed separately, it is not ensured monotonically. A complete search strategy will be obliged to do a “diagonalizing enumeration,” that is, it cannot simply pick an abstract plan, and attempt to specialize this plan further without regard to the re- maining abstract solutions, but must instead do only a quanta of planning steps, and go to the next abstract solution. But, it cannot be simple minded about this either, since there may be an infinite number of ab- stract solutions. So, it must do some quanta on the next abstraction, and then return to the first one. That is, the enumeration must “diagonalize in two dimen- sions.” The above argument suggests a monotonically com- plete control procedure, in the sense that any state in ABTWEAK’S search space may be selected next accord- ing to a complete search control strategy. Recall that ABTWEAK’S search space operations include not only the plan modifications of TWEAK, but also the plan expansions. Thus, if a path exists in the original state space from the initial state to a goal state, one such path will eventually be found. Any complete search strategy will suffice for the purpose: breadth-first, A* [Nilsson, 19801, depth-first iterative deepening[Korf, 1985a], etc. Backtracking on Protection Violations The monotonic property provides a powerful heuris- tic for guiding the search in ABTWEAK. It can be considered as a criteria for backtracking that does not sacrifice completeness. More specifically, one can back- track on precondition-establishment violations, that is, if for some operators a and b, and literals p and u, Establishes(u, b, p, u) in a plan at abstraction level i, then at level i - 1, if the only choices left are to insert an operator that possibly asserts lp, then ABTWEAK can backtrack without losing monotonic completeness. Thus, the causal relation between preconditions and effects should be preserved when going down abstrac- tion levels. This effectively imposes a strong constraint on how an abstract plan should be refined at a lower level. 208 AUTOMATED REASONING Backtracking on Incompleteable Plans Sometimes no solution can be found at a particular level of abstraction. In that case, one would like to know whether a solution exists at the base level. For ABTWEAK, it follows from the Upward-Solution Prop- erty that if there is no solution at one level, then no solution exists at all at any lower levels of abstraction. A related problem is whether to backtrack from an incompleteable plan. A plan II is said to be incom- pleteable if no correct completion of II exists, and no operators and constraints can be inserted to obtain a correct completion. One way for II to be incomplete- able is that it contains a set of clobberers of the oper- ators in II, and that no white knights and constraints exist to remove all of the clobbering. This situation corresponds to what is commonly known as the “un- resolvable conflicts” in nonlinear planning. It can be proven that ABTWEAK can backtrack from an incom- pleteable plan without losing completeness[Yang and Tenenberg, 19901. Conclusion This research has been aimed at formalizing domain- independent, nonlinear planning systems that plan in hierarchies of abstraction levels. The resultant plan- ner, ABTWEAK, extends the precondition-elimination methods in ABSTRIPS for building abstraction hierar- chies, and allows for least-commitment representations of plans in TWEAK. We have shown that ABTWEAK satisfies the monotonic property, that is, as planning descends from top to concrete levels of abstraction, the precondition establishment structure of a plan need not be changed. This, to a large extent, formalizes our in- tuition for using abstraction in planning: that it is generally more efficient to use an abstract solution to guide search at lower levels of abstractions than with- out abstraction. In addition, we have demonstrated that a simplistic application of a control strategy for a single-level problem solver to each level of the abstrac- tion hierarchy will not in general provide a complete multiple-level system. We also discussed how to ensure the monotonic completeness for ABTWEAK systems. We believe that ABTWEAK also offers computational advantages over some of the existing hierarchical plan- ning systems. However, to provide concrete evidence for this claim, it might take a considerable amount of experimentation. Indeed, our ongoing work is to implement ABTWEAK and make such computational comparisons. Acknowledgements We thank Craig Knoblock for many useful comments. [Fikes et al., 19721 Richard Fikes, Peter Hart, and Nils Nilsson. Learning and executing generalized robot plans. Artificial Intelligence, 3~251-288, 1972. [Knoblock, 19881 Craig Knoblock. A theory of ab- straction for hierarchical planning. In Proceedings of the First International Workshop in Change of Rep- resentation and Inductive Bias, pages 53-65, 1988. [Korf, 1985a] Richard Korf. Depth-first iterative- deepening: An optimal admissible tree search. Ar- tificial Intelligence, 27:97-109, 1985. [Korf, 1985131 Richard Korf. Planning as search: A quantitative approach. Artificial Intelligence, 33:65- 88, 1985. [Nau, 19871 Dana Nau. Hierarchical abstraction for process planning. In Proceedings of Second Interna- tional Conference in Applications of Artificial Intel- ligence in Engineering, 1987. [Nilsson, 19801 Nils Nilsson. Principles of Artificial In- telligence. Morgan Kaufmann Publishers Inc, 1980. [Sacerdoti, 19741 Earl S acerdoti. Planning in a hier- archy of abstraction spaces. Artificial Intelligence, 5:115-135, 1974. [Sacerdoti, 19771 Earl S acerdoti. A Structure for Plans and Behavior. American Elsevier, 1977. [Tate, 19771 Austin Tate. Generating project net,- works. In Proceedings of the 5th IJCAI, pages 888- 893, 1977. [Tenenberg, 19881 Josh Tenenberg. Abstraction in Planning. PhD thesis, University of Rochester, Dept. of Computer Science, Rochester, NY, May 1988. [Wilkins, 19841 David Wilkins. Domain-independent planning: Representation and plan generation. Ar- tificial Intelligence, 22, 1984. [Yang and Tenenberg, 19901 Qiang Yang and Josh Tenenberg. Abtweak: A hierarchical, least- commitment planner. Technical Report 90-09, Uni- versity of Waterloo, 1990. [Yang, 19891 Qiang Yang. Improving the Eficiency of Planning. PhD thesis, University of Maryland, 1989. References [Chapman, 19851 David Chapman. Planning for con- junctive goals. AI Technical Report 802, Mas- sachusetts Institute of Technology, 1985. YANGANDTENENBERG 209
|
1990
|
29
|
944
|
On Acting Together Hector J. Levesque* Philip R. Cohen Dept. of Computer Science AI Center and CSLI University of Toronto SRI International Toronto, Ont. M5S lA4 Menlo Park, CA 94025 hector@ai.toronto.edu pcohen@ai.sri.com Jo& H. T. Nunes Dept. of Computer Science University of Toronto Toronto, Ont. M5S lA4 nunes@ai.toronto.edu Abstract Joint action by a team does not consist merely of si- multaneous and coordinated individual actions; to act together, a team must be aware of and care about the status of the group effort as a whole. We present a formal definition of what it could mean for a group to jointly commit to a common goal, and explore how these joint commitments relate to the individual com- mitments of the team members. We then consider the case of joint intention, where the goal in question in- volves the team performing some action. In both cases, the theory is formulated in a logical language of belief, action, and time previously used to characterize indi- vidual commitment and intention. An important con- sequence of the theory is the types of communication among the team members that it predicts will often be necessary. Introduction What is involved when a group of people decide to do something together. 7 Joint action by a team involves more than just the union of simultaneous individual actions, even when those actions are coordinated. We would not say that there is any team work involved in ordinary automobile traffic, even though the drivers act simultaneously and are coordinated (one hopes) by the traffic signs and rules of the road. But when a group of drivers decide to do something together, such as driving somewhere as a con~fo~, it appears that the group acts as a single agent with beliefs, goals, and intentions of its own, over and above the individual ones. In this paper, we present a formal model of these mental properties of a group, and especially how joint intentions to act affect and are affected by (and ultimately reduce to) the mental states of the participants. In previous work, we have presented a belief-desire- intention model of the mental states of individuals in which intentions are seen as internal commitments to perform an action while in a certain mental state. To achieve a degree of realism required for successful au- tonomous behaviour, we model individual agents as sit- *Fellow of the Canadian Institute for Advanced Research uated in a dynamic, multi-agent world, as possessing neither complete nor correct beliefs about the world or the other agents, as having changeable goals and falli- ble actions, and as subject to interruption from exter- nal events. Whereas the model is sufficient to predict planning, replanning, and communication [Cohen and Levesque, in press; Cohen and Levesque, 19901, it does so only from the perspective of each individual agent, by constraining the rational balance that agents main- tain among their own beliefs, goals, commitments, in- tentions, and actions. This paper extends our previous work and characterizes joint intentions as shared com- mitments to perform an action (typically composite) while the group is in a certain shared mental state. Although we do not explore how these ideas can be applied in computational systems that reason about action, we take the research presented here to be es- sential groundwork. Some account of joint action is obviously needed to at least describe (or form plans containing) coordinated activities such as jointly lift- ing a heavy object or writing a paper, as well as pure group activities like games, plays, and dances. The theory also provides a basis for formalizing the type of agreement and commitment underlying legal contracts and treaties. In addition, it allows us to make sense of mundane utterances like “Uh-huh,” “OK,” “Right ,” “Go on,” “ Now” and others, that pepper all our natu- ral dialogues. These can be seen as attempts to estab- lish and maintain the mutual beliefs necessary to the achievement of joint intentions. Indeed, one of the main goals of this theory is to predict and interpret the sort of linguistic activity that arises when agents cooperate. A companion paper [Cohen et al., 19901 will provide details of the application of the theory to dialogue. In the rest of this paper, we discuss the problem of joint action in general, and then build a formal the- ory of joint commitment based on the same primitives as the individual case. We then examine some of the properties of joint commitment, and use it to define a simple form of joint intention. Finally, we discuss why it is rational for agents to form joint commitments at all. 94 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. A Convoy Example If team behaviour is more than coordinated individual behaviour, how does it work? When is it necessary? When should agents communicate? What should they communicate? These questions are perhaps best an- swered by considering what would happen in the case of a convoy example without the right sort of joint in- tention. Consider two agents, A and B, driving somewhere together, with A leading the way until B knows his’ way home. Assume that both agents have this as their intention, and furthermore, that these individual inten- tions are mutually believed to hold. In other words, it is mutually known to both agents that each will do his part (if he can) as long as the other agent does likewise. Will this work? This is essentially the model of joint intention pro- posed by Tuomela and Miller [1988] and by Grosz and Sidner [in press]. We feel that it runs into difficulties in cases where it is possible for one of the agents to come to believe (privately) that the intention either has been achieved or is impossible to achieve. We assume that in such a situation, a rational agent has no choice but to abandon the goal. For example, if A comes to re- alize that he was mistaken and in fact does not know where B lives, the intention to lead B must be given up. The trouble is that there is nothing in the agreement to stop A from just speeding away, ignoring a puzzled B behind him. Conversely, if B comes to realize that he now knows his way home, the goal has been satis- fied according to him, and there is nothing to stop him from pulling over to enjoy the scenery, without regard to how A might interpret his action. But the real problem with this characterization of joint intention is that it does not work even if both parties behave with the utmost of consideration for the other, and even if these private beliefs of failure or suc- cess do not arise. As long as these beliefs are thought to be possible, what can happen is that one agent may come to believe that something like this is happening to the other! For example, if A makes a turn, B could very well (falsely) conclude that A is no longer able to lead him, and so make other plans for getting home. Conversely, if B is forced to pull over (for example, be- cause of difficulties with his car), A could simply con- clude that B now knows the way, and continue driving without him. At a deeper level of misunderstanding, even if each agent does not misinterpret the other’s ac- tions, he has no way of knowing that the other agent will not misinterpret his! Even if A is indeed prepared to stop in case B does, B might not realize this, and not want to pull over in case A takes it to mean that B now knows his way home. This can continue in- definitely to deeper and deeper levels. Overall then, ‘We use masculine adjectives and pronouns throughout, but they should be read as “his,” “her” or “its” (for robots), as the reader desires. with the potential for this kind of misunderstanding, even with the best of intentions, nothing is holding the collective behaviour together. Individual intentions do not a convoy make. So what do we expect from a convoy? Among other things, robustness against misunderstandings like those above: A will signal when it is time to get started, A and B will endeavor to keep each other within sight and not pull over privately, A will not take actions that he believes would render B’s intentions impossible to achieve, B will signal when he knows his way, and with- out such a signal, A will still assume B is following. Of course, A and B do not need to explicitly agree to these actions; they should be consequences of what it means to act together. Before examining a definition of joint action that has these properties, we review the individ- ual case. Individual Commitment and Intention The account of intention given in [Cohen and Levesque, 19901 is formulated in a modal language that has the usual connectives of a first-order language with equal- ity, as well as operators for the propositional attitudes and for talking about sequences of events: (BEL x p) and (GOAL x p) say that x has p as a belief and goal respectively; (MB x y p) says that x and y mutually be- lieve that p holds; (AGT x1 . . . xn e) says that xi . . . X~ are the only agents for the sequence of events e; else2 says that el is an initial subsequence of en; and finally, (HAPPENED a), (HAPPENING a), and (HAPPENS a) say that a sequence of events describable by an action ex- pression a has just happened, is happening now, or will happen next, respectively. An action expression here is built from variables ranging over sequences of events using the constructs of dynamic logic: a;b is ac- tion composition; alb is nondeterministic choice; aljb is concurrent occurrence of a and b; p? is a test action; and finally, a* is repetition. The usual programming constructs like IF/THEN actions and WHILE loops can easily be formed from these.2 A few comments on how formulas of this language are semantically interpreted. BEL and GOAL are given a possible-world semantics, where a world is modeled as a function mapping each time point to a set of prim- itive event types (the events happening simultaneously at that point in time). We assume that each agent has perfect introspection about both his beliefs and goals, that beliefs are consistent, and that goals are consistent with each other and with what is believed. Sentences are evaluated at both a world and a current time point on that world. The truth value of sentences with HAP- PENED, HAPPENING, and HAPPENS differ only with re- 2Test actions occur frequently in our analysis, yet are potentially confusing. The expression p?;a should be read as “action a with p holding initially,” and analogously for a;p?. Note specifically that an agent can perform these without ever knowing the truth value of p. LEVESQUE ET AL. 95 spect to the position of the current time point: im- mediately after, straddled by, and immediately before the action, respectively. We will also use the following syntactic abbreviations: Actions: (DONE xl.. .xn a) cf (HAPPENED a) A (AGT xl.. .xn a) (DOING XI.. .xn a) Gf (HAPPENING a) A (AGT xl.. . xn a) (DOES xl.. .x,, a) cf (HAPPENS a) A (AGT XI.. .xn a). Eventually: Op def 3e (HAPPENS e;p?). There is something that happens, including the einpty sequence of events, after which p holds, i. e., p is true at some point in the future. Always: alp def 10-p. The wff p is true from now on. Until: (UNTIL p q) gf Vc (HAPPENS c;-q?) > 3a (a < c) A (HAPPENS a;p?). Until the wff p is true, the wff q will remain true. With these definitions in place, we can say what it means for an agent x to be (fanatically) committed to achieving a goal p: he should believe that p is false, but want it to be true at some point, and continue to want it to be true until he believes that it is true, or that it will never be true. Thus we have the following definition:3 Definition 1 (PGOAL x p q) sf (BELx-p) A (GOALxOp) A (UNTIL [(BEL x p) v (BEL x q p) v (BEL x ‘q)] (GOAL x 0~)) The extra condition q here (which we will occasionally omit) is simply a reason x may have for keeping the goal. It is most often used in an expression such as (PGOAL x p (GOAL x q)) to express a commitment to p as a subgoal relative to q. * Finally, we define what it means for x to intend to do an action a: Definition 2 (INTEND x a q) def (PGOAL x (DONE x [UNTIL (DONE x a) (BEL x (DOING x a))]?;a) 41 So an agent intends to do an action if he has a persis- tent goal to have done that action, and moreover, to have done it believing throughout that he was doing it. It is therefore a commitment to do the action de- liberately. Typically such a goal would arise within a subgoal-supergoal chain as a decision to do an action a to achieve a goal p by getting into a mental state where 3This is slightly different from the one appearing in [Co- hen and Levesque, 19901. 4A better way to do this would be to allow for a dy- namically evolving set of priorities, and to allow an agent to drop a goal if it is found to conflict with one of higher priority. a would be done knowingly.5 If the chain is something like (PGOAL x p) A (PGOAL x (HAPPENED a) (GOAL x 0~)) A (PGOAL x (DONE x a) (GOAL x O(HAPPENED a))) A (INTEND x a (GOAL x O(DONE x a))), then the goal could be given up if the agent discovers that a was performed somehow without his realizing it (or any other goal higher in the chain was achieved). Joint Commitment How should the definition of persistent goal and inten- tion be generalized to the case where a group is acting like a single agent? Restricting ourselves to two agents here (and throughout), a first attempt at a definition for JPG, joint persistent goal, would be to replace belief in the definition of PGOAL by mutual belief, and replace (GOAL x Op) by mutual belief in the goal as in Definition attempt: (JPG x y p q) dgf (MBxY~P) A (MGxYP) A (UNTIL [(MB x y p) v (MB x y o-p) v (MB x y -q)] where (MG x Y P)), (MG x y p) def (MB x y (GOAL x Op) A (GOAL y 0~)). This has the effect of treating x and y together as a sin- gle agent, but otherwise leaving the notion of persistent goal unchanged. However, the definition is not quite right: it will only work in cases where neither agent can come to believe privately that the goal p has succeeded or is impossible.6 To see why, suppose that x alone comes to believe that p is impossible; x must drop the goal, and so (MG x y p) must be false; but this mutual goal was supposed to persist until there was a certain mu- tual belief, and as there is as yet none, there cannot have been a JPG to start with. So joint commitment cannot be just a version of in- dividual commitment where a team is taken to be the agent, for the simple reason that the team members may diverge in their beliefs. If an agent comes to think a goal is impossible, then he must give up the goal, and fortunately knows enough to do so, since he be- lieves it is impossible. But when a member of a team finds out a goal is impossible, the team as a whole must again give up the goal, but the team does not necessar- ily know enough to do so. Although there will no longer be mutual belief that the goal is achievable, there need not be mutual belief that it is unachievable. Moreover, we cannot simply stipulate that a goal can be dropped when there is no longer mutual belief since that would allow agreements to be dissolved as soon as there was uncertainty about the state of the other team members. 5An alternative but less effective choice would be to blunder about at random, checking periodically to see whether or not the action had been done. 6We thank Henry Kautz for this observation. 96 AUTOMATEDREASONING This was precisely the problem with the failed convoy discussed above. Rather, we must insist on arriving at mutual belief, that is, at an agreement that the goal is impossible to achieve, before commitments can be discharged. Any team member who discovers privately that a goal is impossible (or has been achieved) should be left with a goal to make this fact known to the team as a whole, which, in effect, is what introspection does in the individual case. We therefore define the state of a team member x nominally working on p relative to another member y as follows: Definition 3 (WG x y p) ‘kf [-(BEL x p) A (GOAL x Op)] v [(BEL x p) A (GOAL x O(MB x y p))] v [(BEL x alp) A (GOAL x O(MB x y o-p))] This form of “weak goal” involves three mutually ex- clusive cases: either x has Op as a goal, or thinks that p is true and wants to make that mutually believed,7 or similarly for p never being true. If a team is jointly committed to achieving p, the team members cannot assume of each other that they have p as a goal, but only that they have p as a weak goal; each member has to allow that any other member may have discovered privately that p is impossible and be in the process of making that known to the team as a whole. A further possibility (that we will not deal with) is for an agent to discover that it is impossible to make the status of p known to the group as a whole, for example, when communication is impossible. For simplicity, we assume that once an agent comes to think that p is unachievable, he never changes his mind, and that it is always possible to achieve the correct mutual belief. Among other things, this restricts joint persistent goals to conditions where there will eventually be agreement among the team members regarding its achievement or impossibi1ity.s So the final definition of JPG replaces MG in the last clause of the previous definition by a weaker version: Definition 4 (JPG x y p q) dgf (MB x Y 1~) A (MG x Y P> A (UNTIL [(MB x y p) v (MB x y q p) V (MB x y ‘q)] (WMG x P)) where 7More accurately, we should say here that his goal is making it mutually believed that p had been true, in case p can become false again. 8Actually, agents do have the option of using the escape clause q to get around this difficulty. For example, lq could say that there was an unresolvable disagreement of some sort, or just claim that an expiry date had been reached. In this case, mutual belief in lq amounts to an agreement to dissolve the commitment regardless of the status of p. Properties of Joint Commitment The first thing to observe about this definition of JPG is that like its flawed predecessor, it also generalizes the concept of PGOAL, in that it reduces to the individual case when the two agents are the same: Theorem 1 + (JPG xx p) = (PGOAL x p) The proof is that if x has a weak goal that persists until he believes it to be true or impossible, he must also have an ordinary goal that persists. It can also be shown that like the previous account, this definition of joint commitment implies individual commitments from the team members: Theorem 2 j= (JPG x y p) > (PGOAL x p) A (PGOAL y p). To see why x has p as a persistent goal, imagine that at some point in the future x does not believe that p is true or impossible to achieve. Then there is no mutual belief either, and so p must still be a weak goal. But under these circumstances, this means that p must still be a real goal. Consequently, p persists as a goal until x believes it to be satisfied or impossible to achieve. So if two agents agree to do something, they become individually committed to achieving it. This was stated by Searle as one of the major puzzles of joint intention [Searle, in press]: given that joint intentions do not re- duce to the conjunction of individual ones, where do the individual intentions come from (since ultimately, it is the individuals who act)? In the Grosz and Sid- ner formulation, joint intentions are defined in terms of individual ones. But as we saw earlier, their definition had a drawback given the possibility of private discov- eries about the status of the goal. With our definition, however, an agent cannot give up the goal just because he suspects that the other agent has given it up (or suspects that the other suspects that he has, and so on). Until they know the status of the goal itself, they cannot drop it. So what does happen when one agent x discovers pri- vately that p is impossible to achieve?’ First observe that the agent must now drop the goal of achieving p, and so the PGOAL and the JPG must be false as well. This is as it should be: we would not want to say that the agents continue to be jointly committed to achiev- ing p, since one of them has now given it up. But (and this is the important point) the fact that there is no longer a joint commitment does not mean that the collective behaviour falls apart. Since there is as yet no mutual belief that p is impossible, we know that the (WMG x y p) must persist. This means that (WG x y p) must persist, and (GOAL x O(MB x y alp)) must persist too, since (BEL x q up) is true and will remain true. So although the original JPG no longer ‘Similar considerations apply when one of agents dis- covers that the goal has been achieved, or when the agent thinks that something like this is happening to the other. LEVESQUE ET AL. 97 holds, because of the UNTIL clause in that JPG, the goal to eventually achieve mutual belief persists until it is achieved. This goal is therefore a PGOAL: Theorem 3 k (JPG xy p) A . . . > (UNTIL [(MB x y p) v (MB x y alp)] [(BEL x ( q ~~)A+~B x y 01~)) > (PGOAL x (MB x y o-p))]) The ellipsis here is some condition that is sufficient to guarantee that x will not change his mind about the impossibility of p. The simplest and strongest such condition is q [(BEL x 0-p) > q I(BEL x o-p)], but others are possible. Similarly, when agent x discovers privately that p has been achieved, the goal of making p mutually believed persists until the JPG is discharged: Theorem 4 b (JPG x y p) A . . . > (UNTIL [(MB x y p) v (MB x y alp)] [(BEL x pAl(MB x y p)) > (PGOAL x (MB x Y P))I) To summarize: once a JPG has been established, if one of the agents comes to believe that the goal hasbeen achieved or is impossible, the individual commitment to achieve p is replaced by a new commitment the status of p mutually believed. to make This has two very important consequences. First, this PGOAL to attain mutual belief predicts that com- munication will take place as this is typically how mu- tual belief is attained, unless there is co-presence to begin with. To satisfy a contract, in other words, it is not enough to satisfy the agreed upon goal (or to find it to be unsatisfiable), one must be prepared to show the other that it has been satisfied. This explains why contracts normally have concrete deliverables, and why it would be strange to have a contract requiring one of the parties to merely think about something. Second, if there is a joint commitment, agents can count on the commitment of the other members, first to the goal in question, and then, if necessary, to the communication of the status of the goal. We do not merely require the agent to work on the goal while he believes the other agent to be doing the same, since in many natural cases, one agent will lose track of what the other is up to. Instead, he must work on a goal until there is mutual belief regarding the status of the goal. As we discuss below, what makes this at least reasonable is the fact that an agent can rely on the other to let him know if he is wasting his time on an impossible goal. Let us reexamine the convoy example in the light of these theorems. First, we introduce some (simplistic) notation: (know-way y) def 3z (BEL y (way-home y 2)). (done-convoy x y) def (DONE x y (WHILE l(know-way y) [(leads x);(follows y)])) The expression (know-way y) is intended to say that y knows his way home, and (done-convoy x y) says that x and y have just done the iterative action consisting of x leading and y following (whatever that means) until y knows his way home. If x and y are jointly committed to doing the convoy action, we can show that if y comes to know his way home, he cannot simply ignore x and go home; he re- mains committed to making it mutually believed that he knows his way home (for example, by signalling): Theorem 5 k (JPG x y (done-convoy x y)) A . . . > (UNTIL [(MB x y (done-convoy x y)) V (MB x y q l(done-convoy x y))] [(BEL y (know-way y) A -(MB x y (know-way y))) > (PGOAL y (MB x y (know-way y)))]) All that is needed to show that this theorem follows from Theorem 4 is the fact that the worlds where y knows his way home are precisely the worlds where the WHILE loop has just ended (after perhaps zero itera- tions). More complex properties of the convoy depend on a joint commitment to more than just the proper completion of the WHILE loop, as in joint intention, which we now turn to. Joint Actions Given the notion of joint commitment, we define JI, joint intention, as the obvious generalization of indi- vidual intention: Definition 5 (JI x y a q) dgf (JPG x y (DONE x y [UNTIL (DONE x y a) (MB x y (DOING x y a))]?;a) So joint intention is a joint commitment to do an action while mutually believing (throughout the execution of the action, that is) that the agents are doing it. Space permits us only to sketch broadly some of the implica- tions of this definition. Typically, the a in question will be a composite ac- tion involving parts to be done by each agent alone. For example, a could be alc;ay or a3: Ila,, where a, is some action to be performed by x alone, and similarly for ay. Since both parties are committed to getting all of a done, both parties care about the other’s actions and so will not intentionally do something that would make them impossible. If one agent does his part, but sees that the other agent has difficulty doing his, this definition predicts that the first agent will want to redo his part, to get the whole thing right. If there are turns to be played, each agent will have to make sure that the other knows when it is his turn, perhaps by a signal of some sort. In fact, neither agent is committed to his part of the bargain in isolation; individual intentions to do one’s part do no2 follow from a joint intention to 98 AUTOMATEDREASONING do a composite action. Acting alone could very well be ineffectual (as in lifting a piano) or worse (as in the “coordinated attack” problem [Halpern and Fagin, 19851). An agent that discovers that his partner’s ac- tion is impossible may refuse to do his part, even if it remains possible to do so. These properties suggest that an agent’s commitments to another’s actions will need to be treated quite similar to his commitments to his own.- Both will need to be part of-his plans, for example, even though only his own intentions lead him to act. The other feature of joint intention is that the action needs to be performed in a certain shared mental state. The main consequence of this is that it predicts that communication will be used to ensure that both parties are aware throughout the execution of a that the action is being done. In addition to signals that transfer con- trol when taking turns (noted above), one would expect to see a signal at the start of the action (like “Ready”), and various reassuring confirmation signals (like “Uh- huh”) to make sure the initial mutual belief does not dissipate over time [Cohen et al., 19901. Conclusion In our previous work, we discussed individual actions and intentions in terms of the rational balance agents maintain among their beliefs, goals, and commitments. We conclude here by discussing why we feel it is rutio- nal for agents to enter into joint commitments. Our account predicts (perhaps counterintuitively) that an agent will persist in trying to achieve a goal even if he happens to believe the other agent is in the process of informing him of why he had to give it up. Why is this persistence a better strategy than letting the other agent do all the work or dropping the goal as soon as there is uncertainty in the air? There are two reasons. First, the agent knows that he will eventually be told by his partner if he is working on a futile goal. If in fact he is doing more than he strictly needs to, he at least knows that his partner is committed to rescuing him. Second, if he were to take the more conservative strat- egy and quit immediately, or even if there were suspi- cions to that effect, the collective behaviour would fall apart and doom the project. This is not unlike the clas- sical Prisoner’s Dilemma problem where if both agents fail to cooperate and choose the locally optimal strat- egy, the global result is unacceptable to both parties. It is the mutual commitment to a non-conservative form of behaviour that binds the team together. Of course the real problem in interpersonal affairs is trying to arrive a truly shared commitment. If one of the parties is suspicious of the goals of the other, then by our definition, there is no joint commitment, even if the other party thinks there is. International treaties are most often predicated on verifiability, that is, on ways to assuage suspicions as they arise. But suspi- cion at any level (even a belief that the other party believes that you are suspicious) implies that there is no mutual belief that the goals of the treaty are shared. Thus, there is no joint commitment, and like the failed convoy example, the treaty will not be robust in diffi- cult situations. Sad, but true. What it takes to build trust in potentially adversarial situations is perhaps the single most delicate aspect of multi-agent interaction. Our account of joint commitment obviously does not provide criteria for avoiding deception or for recogniz- ing true commitment when it exists; but it does state precisely what one is trying to recognize, and what be- lieving in a commitment amounts to. Acknowledgments This research was supported by a grant from the Na- tional Aeronautics and Space Administration to SRI International, subcontracted from Stanford University, for work on “Intelligent Communicating Agents,” and by a contract from ATR International to SRI Interna- tional. The Toronto authors were supported in part by a grant from the Natural Sciences and Engineering Research Council of Canada. References [Cohen and Levesque, 19901 P. R. Cohen and H. J. Levesque. Intention is choice with commitment. Ar- tificial Intelligence, 42(3), 1990. [Cohen and Levesque, in press] P. R. Cohen and H. J. Levesque. Rational interaction as the basis for communication. In P. R. Cohen, J. Morgan, and M. E. Pollack, editors, Intentions in Communicu- tion. M.I.T. Press, Cambridge, Massachusetts, in press. [Cohen et al., 19901 P. R. Cohen, H. J. Levesque, J. Nunes, and S. L. Oviatt. Task-oriented dialogue as a consequence of joint activity, in preparation, 1990. [Grosz and Sidner, in press] B. Grosz and C. Sidner. Plans for discourse. In P. R. Cohen, J. Morgan, and M. E. Pollack, editors, Intentions in Commu- nication. M.I.T. Press, Cambridge, Massachusetts, in press. [Halpern and Fagin, 19851 J. Y. Halpern and R. Fagin. A formal model of knowledge, action, and communi- cation in distributed systems: Preliminary report. In Proceedings of the 4th ACM Conference on Princi- ples of Distributed Computing, New York City, New York, 1985. Association for Computing Machinery. [Searle, in press] J. R. Searle. Collective intentional- ity. In P. R. Cohen, J. Morgan, and M. E. Pollack, editors, Intentions in Communication. M.I.T. Press, Cambridge, Massachusetts, in press. [Tuomela and Miller, 1988] R. T’uomela and K. Miller. We-intentions. Philosophical Studies, 53:367-389, 1988. LEVESQUEETAL. 99
|
1990
|
3
|
945
|
An Approach to Reasoning About Continuous Change for Applications in Planning Thomas Dean* Greg Siegle Department of Computer Science Brown University Box 1910, Providence, RI 02912 Abstract There are many planning applications that require an agent to coordinate its activities with processes that change continuously over time. Several proposals have been made for combining a temporal logic of time with the differential and integral calculus to provide a hybrid calculus suitable for planning applications. We take one proposal and explore some of the issues involved in im- plementing a practical system that derives conclusions consistent with such a hybrid calculus. Models for real- valued parameters are specified as systems of ordinary differential equations, and constructs are provided for reasoning about how these models change over time. For planning problems that require projecting the con- sequences of a set of events from a set of initial con- ditions and causal rules, a combination of numerical approximation and symbolic math routines and a sim- ple default reasoning strategy provide for an efficient inference engine. Introduction Many problems in planning, scheduling, and decision support require reasoning about processes that change continuously over time (e.g., determining how long to leave a valve open in order to fill a container with- out causing it to overflow, or when to schedule the delivery of parts after the start of a machining pro- cess so as to minimize the total time spent in fabri- cation). While there has been some research involv- ing continuous change (e.g., [Hendrix, 1973]), much of the work on temporal reasoning in artificial intel- ligence has focused on discrete change [Allen, 1984, McDermott researchers 1 1982, Shoham, 19881. Recently, however, Sandewall, 1989, Rayner, 19891 have noted that the differential and integral calculus provide us *This work was supported in part by a National Sci- ence Foundation Presidential Young Investigator Award IRI-8957601 with matching funds from IBM, and by the Advanced Resea.rch Projects Agency of the Department of Defense and was monitored by the Air Force Office of Sci- entific Research under Contract No. F49620-88-C-0132. with a perfectly good means of reasoning about contin- uous change. Sandewall [1989] d escribes a hybrid cal- culus that combines an interval temporal logic with the differential calculus. In this paper, we discuss some of the issues involved in implementing a variant of Sande- wall’s hybrid calculus useful for applications in plan- ning. Discrete and Continuous Change Following [McDermott, 19821 and [Shoham, 19881, we treat time points as primitive and reason about inter- vals in terms of points. Time points are notated t or ti, i E 2 (e.g., tl, t2). V ariables ranging over time points are notated t or ti, i E 2 (e.g., tl, tz). We introduce a binary relation, 3, on time points indicating temporal precedence. If tl and t2 are time points, then (tl, t2) is an interval. We use the notation holds (t I, t2 ,p) to indicate that the proposition p is true throughout the interval (t 1, t2). For instance, holds(tl,t2,temp(room32)>72’) is meant to represent the fact that the temperature in a particular room is greater than 72’ throughout the interval (tl ,t2). We use the abbreviation holds(t, yl) for holds (t , t , y3), and q yl to indicate that cp is always true. In order to reason about discrete change, the logic has to be extended to deal with the problems that arise due to the frame and qualification problems. As an expedient, we adopt Shoham’s semantics of chronologi- cal minimization [Shoham, 19881, noting that, while not appropriate for all types of temporal reasoning, chrono- logical minimization is entirely satisfactory for the sim- ple sort of projection problems that arise in many plan- ning applications. In this paper, we are primarily interested in reasoning about quantities that change continuously as functions of time. Rather than invent new machinery within our temporal logic, we will import into the logic as much of the differential calculus as is needed for our planning applications. Our treatment here roughly follows that of Sandewall [1989]. 132 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. First, we introduce a set, U, of real-valued parame- ters closed under the differential operator, d. If u E U, then Pu E U, where Pu is the nth partial deriva- tive of u with respect to time. We can trivially extend the syntax to represent statements about the values of parameters at various time points. For instance, holds(tl,t2,y= 3.1472) is meant to indicate that the parameter y has the value of 3.1472 throughout the interval (tl ,t2). By restricting y to remain constant throughout the inter- val (t I, t2), we also restrict dy to remain 0 throughout the same interval. To guarantee this intended meaning, we have to aug- ment the semantics somewhat. In addition to a set of parameters U, we assume that each interpretation in- cludes a function Q : (R x U) ---) R, where we employ the set of real numbers, R, for the set of time points as well as for the set of all parameter values. Since we will find it convenient on occasion to model abrupt changes in the value of parameters as they change over time, we introduce the notion of a break- point. We assume that a physical process is modeled using a set of differential equations that describe con- tinuous changes in the parameters over intervals of time, and a set of axioms that determine what equations are appropriate over what intervals. Breakpoints are times at which the axioms signal a change in the differen- tial equations used to model a given quantity or set of quantities. Generally, at a breakpoint there is a discon- tinuity in some time varying parameter. We have to augment the semantics to account for the behavior of parameters with respect to breakpoints. Each interpretation must include a set of breakpoints S C R, so that for all u E U, Q(t, u) is continuous over every interval not containing an element of S, and for all t $Z S, $ = Q(t, au). Strange things can happen at breakpoints, but not so strange that we will allow a parameter to take on two different values. To avoid such anomalies, we will have to introduce some additional machinery. At time to, we have a set of differential equations and a set of initial va.lues for all of the parameters; these equations and initial values are known to hold until some indeterminate time Cl, at which point a break- point occurs and the axioms determine a new set of differential equations and a new set of “initial” values. In order to establish breakpoints and the values for pa- rameters immediately following breakpoints, we need to refer to the values of parameters “‘just before” and “just after” breakpoints. To do so, we define the left and right limits of a parameter I: at time t as: A discontinuity occurs at t with regard to a parameter x whenever the left and right limits are not equal: As long as there are no discontinuities, the differential equations tell us exactly how the parameters vary with time. The axioms tell us when breakpoints occur and what differential equations and initial conditions should be used to model processes between breakpoints. Dis- continuities play a role in reasoning about real-valued quantities analogous to the role played by clippings in reasoning about the persistence of propositions. Just as the axioms do not rule out spurious models result- ing from unexplained clippings, neither do they rule out models resulting from unexplained discontinuities. Suppose that we have two objects moving toward one another along a horizontal line. Assume that the sur- face is frictionless, the objects are represented as identi- cal point masses, and there are no external forces acting on the objects. Let ~1 and ~2 represent the parameters corresponding to the position of the first and second ob- jects, respectively, as measured from some reference on the horizontal line. At time 0, the first object is located at position 0, and the second object is located 10 meters to the right. A positive velocity indicates movement to the right. We make use of the standard conventions for notating position (a), velocity (ax = &), and acceler- ation (a2a: = Z). Here are the axioms indicating the initial conditions: holds(O,q =O> holds(0,a2 =lO) holds(O,+I= 2) holds(0,&2 = -3) holds(O,&=O) holds(0,g2 =O> where velocity is in units of meters per second. The next axiom determines the new velocities immediately following a collision breakpoint. q ((⌧1 = x2) A (($1~$2) > 0)) 3 ((2; = 6;) A (2; = 2;)) For the most part, the propositions corresponding to equations involving the parameters in U are constantly changing. In order for us to make useful predictions, however, certain equations have to persist over intervals of time. Suppose you are told that at time to, CC = 0, & = 2, and % = 0. If 3: = 0 persists, then there will be discontinuities in & and 2. If % = 0 persists, then 5 = 2 has to persist or be discontinuous in order to avoid a discontinuity in 5, and z is completely determined by &= 2. However, if none of 51: = 0, $ = 2, or ji: = 0 persist, there need not be a discontinuity in any one of a, &, or Z, but neither is there any way of predicting the changes in z over time. In this example, we force an interpretation by stating that the accelerations for the two objects are always 0: q ((Zl = 0) A (& = 0)). Using Sandewall’s extension of Shoham’s chronolog- ical minimization, there is a single discontinuity in the acceleration of the objects two seconds after time 0, af- ter which the objects, having exchanged velocities, head in opposite directions forever. We assume that the val- ues of parameters are established in intervals not con- 9th x2) # 9th xr) taining breakpoints by differential equations. In the DEAN AND SIEGLE 133 following, we distinguish propositions corresponding to real-valued parameters taking on specific values (e.g., % = 2) from propositions corresponding to truth-valued parameters (e.g., on(furnacel7)). In the previous example, O((Zl = O)A(~, = 0)) serves as the model for ~1 and ~2. In other cases, it may be convenient to infer a change in a model that persists over some indeterminate interval of time, just as we are able to infer changes in propositions that persist over intervals of time. To handle this sort of inference, we introduce a particular type of proposi- tion models(a, m) where a: is a real-valued parameter and m is a model for Z. If m is an nth-order differ- ential equation, then it is assumed that the nth-order equation determines all higher-order derivatives, and a.11 lower-order derivatives are known as part of the initial conditions. By stipulating q ($ = 0), we implicitly in- dicated holds(O,models(z,% = 0)) and that CC = 0 and & = 2 were the initial conditions at 0. Propositions of the form models(q m) persist according to standard chronological minimization. Suppose that we want to reason about the tempera- ture in a room heated by a furnace, and suppose that the furnace is controlled by a thermostat set to 70’. To make the example more interesting, suppose further that the thermostat has a 4’ differential (i.e., the fur- nace starts heating when the temperature drops to 68’ and stops when the temperature climbs to 72’). To rep- resent parameters “dropping to” (1) or “climbing to” (I) certain values, we define trans(J, u, V) (similarly for 1) where u f U and ‘u E R as follows: holds(t, trans( 1, U, v)) G Q(t, u) = ‘u A 3% t, Vt’-i t”d t, Q(t”, u) > Q(t, u) Propositions of the form trans ([J. ] I], u, V> are used to represent point events of the sort that trigger changes. To model changes in the room’s temperature when the furnace is off, we use Newton’s law of cooling dr , . z= --CEl(T - a) where r is the temperature of the room, a is the tem- perature outside the room, and ~1 depends on the in- sulation surrounding the room. To model changes in the room’s temperature when the furnace is running, we use dr - = IQ(f - T) - IGl(T - a) dt where f is the temperature of the furnace when it is running, and ~2 depends on the heat flow characteris- tics of the furnace. The following axioms describe the temperature in the room over time. q (trans(f,T,72’) ~on(furnacel7)) > models(r,drr = -nr(r - a)) O(trans(J, T, 68”) A on(furnacel7)) > models(r , arr = IGZ(f - T) - Kl(T - up Suppose that we are interested in the temperature in the room over the interval from time 0 to time 10. We are told that the temperature outside is 32’ throughout this interval, and that at time 0 the room is 75’ with the furnace on but currently not heating. We represent these facts as follows: holds(O,r = 75’) holds(O,& = -K~(T - u)) holds(O,lO,u = 32’) holds(O,on(furnacel7)) With a little extra work (e.g., in order to eliminate certain unintended models, we have to take steps to avoid simultaneous cause and effect), we can obtain the following inferences. The temperature drops off exponentially’ from 75’ to 68’ at which point the fur- nace starts heating and continues until the temperature reaches 72’, after which the furnace toggles on and off forever with the temperature always between 68’ and 72’. Note that we can always substitute a set of models that persist over different intervals of time for a single model that is true for all time but with additional pa- rameters that make the model behave differently over different intervals of time. In the furnace example, we might state that q (& = IG~( f - a) - ~1 (T - a)) and then have rules that govern the value of f over different intervals of time. The choice of whether to vary the model or employ a single model and vary the parame- ters of the model is a matter of preference. The system described in the next section supports either approach. Projection Involving Continuous Change In this section, we discuss the issues involved in building a temporal inference engine for reasoning about contin- uously changing quantities. We consider only a limited form of temporal reasoning called projection that can be performed by making a single sweep forward in time inferring at each point what things change and what things remain the same. Following [Dean and McDer- mott, 19871, we distinguish between a general type of event or proposition (e.g., “the furnace came on”) and a. specific instance of a general type (e.g., “the furnace came on at noon”). The latter are referred to as time tokens or simply tokens. A token associates a general type of event or proposition with a specific interval of time over which the event is said to occur or the propo- sition hold. Tokens are notated token(t, ;> where t is a type and i is an interval; begin(;) and end(i) indicate the begin and end points respectively of the interval i. Projection uses a set of initial tokens and causal rules ‘The behavior of the system can be described in terms of a piecewise continuous function in which the specific solutions for each piece are given, alternately, by r(t) = 32’ + (~0 - 32’)ewKt and r(t) = C + (TO - C)IT-(~~+“‘)~ where C = K~b00°+K1320 Kli-% , TO is the initial temperature of the room for that particular piece and t is the time elapsed from the beginning of that piece. 134 AUTOMATEDREASONING corresponding to events and propositions to generate additional tokens corresponding to the consequences of the events. Metric constraints are handled as in [Dean and McDermott, 19871 We require that the interval corresponding to a to- ken persist no further than the first subsequent interval corresponding to a token of a contradictory type. For any proposition type cp, cp and l(o are said to be con- tradictory. Additional contradictory types have to be explicitly asserted. For instance, the assertion contradicts(location(X,Y),location(X,Z)) t Y#Z. indicates that any two tokens of type location( arg1, arg2) are contradictory if their first arguments are the same, and their second arguments are different. The process of modifying the bounds on token intervals cor- responding to propositions to ensure that tokens of con- , tradictory types do not overlap is referred to as persis- tence clipping. Causal rules for reasoning about discrete change are of the form project ( antecedent-conditions, trig- ger-event, delay, consequent-effects) to indicate that, if an event of type trigger event occurs, and the antecedent conditions hold at the outset of the in- terval associated with trigger event, then the conse- quent effects are true after an interval of time de- termined by delay. The trigger event is specified as a type, the antecedent conditions and consequent ef- fects are specified as types or conjunctions of types, and the delay is optional defaulting to c, a positive in- finitesimal. As an exampleproject(lon(furnacel’l), toggle(switch42), on(furnacei7)) indicates that, if the switch on the furnace is toggled at a time when the furnace is not on, then, after a delay of E, it will come on. The basic algorithm for persistence clipping and projecting the consequences of events is described in [Dean and McDermott, 19871; in the following, we extend that algorithm to handle continuous change. Let U be a set of real-valued parameters, and P be a set of boolean-valued propositional variables.2 In ad- dition, we introduce two mappings Q : R x U ---) ZR and V : R x P + 2( truepfafse). The task of projection is to determine Q and V for some closed interval of R. We begin by considering the completely determined case in which both Q and IT map to singleton sets (i.e., Q : R x U -+ R and V : R x P --+ (true, fdse}). At the initial time point, we assume that the values of a.11 parameters and propositional variables are known. In addition, we are given a set of events specified to oc- cur at various times over the time interval of interest. We assume a set of projection rules as before. In addi- tion, we assume a set of modeling rules for parameters in U. A modeling rule is just a special sort of projec- tion rule; the basic form is the same as that introduced ‘It should be n oted that, despite the presence of vari- ables and complex terms in our rules, the underlying logic is purely propositional. earlier in this section, the only difference being that the delay is always assumed to be E, and the consequent ef- fects consist of parameter assignments in the form of or- dinary differential equations with constant coefficients (e.g., &A = 2, or a2u = 3au + 5u+ 4). The projection rule from the last section for reasoning about the temperature of the room in the case that the furnace is on but not running is encoded as follows, project(on(furnacel7),trans(T,r,72’), models(r, dr’ = -~l(r - a))). To make sure that persistence clipping is handled cor- rectly, we state that a given parameter can have only one model at a time. contradicts(models(X,F¶l)9models(X,M2)) t MlfM2. Now we can state the basic algorithm for perform- ing projection given some set of initial conditions and a projection interval (t8, tf). To simplify the description of the algorithm, we assume that all events are point events (i.e., if e is a type corresponding to the occur- rence of an event, token(e, k) > (begin(k) = end(h))), and all events described in the initial conditions begin after t,. Let A be the set of all currently active process models (i.e., all m such that holds(t,, models(z, m)) for some a). Let & be the set of pending events (i.e., the set of all events, token(e, Ic), generated so far such that t, 4 begin(k)). Let C be the set of current con- ditions (i.e., all u* = v such that there exists m E A such that holds(t,,models(z,m)), u = dnx for some n, and holds (t,, U” = v) . In the cases that we are interested in, we can recast a set of ordinary differential equations and their initial conditions as a system of first-order differential equa- tions. We can then solve these equations using numer- ical methods based on the Taylor expansion (e.g., the Runge-Kutta methods [Ralston and Rabinowitz, 19781) and various forms of linear and nonlinear extrapolation (e.g. the Adams-Bashforth and Adams-Moulton meth- ods t Shampine and Gordon, 19751). In the following, we assume the ability to generate solutions to ordinary differential equations efficiently, and refer to the proce- dure for generating such solutions as the extrapolation procedure. Given a set of initial conditions and a pro- jection interval (tJ, tf) projection is carried out by the following algorithm. 1. 2. 3. Set t, to be t,. Set & to be the set of events specified in the initial conditions. Using A, C, and the extrapolation procedure, find t, corresponding to the earliest point in time follow- ing t, such that the trigger for some projection rule is satisfied or tf whichever comes first. If t, # tf, then tn could be the time of occurrence of the earli- est event in I, or it could be earlier, corresponding to the solution of a set of simultaneous equations (e.g., ((XI = 352)A((& - k2) > 0))). DEANAND~IEGLE 135 4. 5. 6. 7. 8. 9. 10. 11. If t, = tf , then quit, else set t, to be t,. Find all of the projection rules with the trigger found in Step 3. For each rule found in Step 5 whose antecedent con- ditions are satisfied, create tokens corresponding to the types of the consequent effects, except in the case of consequent effects corresponding to parameter as- signments (e.g., zi = 2:). Constrain the new tokens according to the delay specified in the corresponding rule, and add them to the database. For each token added in Step 6 whose type corre- sponds to an event, add it to E. For each token added in Step 6 whose type does not correspond to an event, find all tokens of a contra- dictory type that begin before the newly added token and constrain them to end before the beginning of the new token. If the trigger found in Step 3 corresponds to the type of an event token’in I whose time of occurrence is t,, remove it from E. Use the consequent effects corresponding to param- eter assignments found in Step 6 and the results of extrapolation to determine c’. The parameter assign- ments corresponding to the consequent effects of pro- jection rules take precedence over the extrapolation results. A is also updated at this time. Go to Step 3. The above algorithm has been implemented in Prolog and C. We use C-Prolog as a front end and database for storing projection rules. The extrapolation proce- dure employs Runge-Kutta methods and is written in C. Differential equations are specified using the nota- tional conventions of Maple.3 Prolog routines are used to preprocess the differential equations converting each one into a system of first-order equations. We assume that all equations are 5th order or less, and that they can be rewritten so that the highest-order term is al- gebraically isolated on the left-hand side of the equa- tion. The system can make use of analytic solutions when available, but, for the planning problems we are concerned with, the extrapolation routine is more than accurate enough. It is also generally faster to use the extrapolation routine written in C than the analytic solver written in Prolog. To get a better idea of how the program works, con- sider the following simple benchmark problem. Figure 1 depicts a pipe leading into a holding tank used to fill portable tanks that are positioned beneath a second pipe leading out of the holding tank. There are rotary valves mounted on the pipes that restrict the flow of 3Maple is a widely distributed symbolic math package developed by the Symbolic Computation Group in the De- partment of Computer Science at the University of Water- loo, Waterloo, Ontario. K in 0 Figure 1: Reasoning about fluid flow % Constants: % Initial conditions: % Discrete events: constsnt(srea,b). holds(O,u=O). occurs( l,turn( B;,,lS)). constant(height,3). holds(O,v=O). occure(2,turn(Q,ut,QO)). constant(volume,2). holda( O,h=O). conatant(kin,6). holds(O,bi,=O). occurs(b,turn( Bin,4S)). occura(lO,turn( ej,,-60)). constsnt(koUt,3). holds( O,g,,t =O). occurs( ll,turn( gout,-90)). % Static models: holds(T,models(r,r(t)=ki,*8i,(t)/(k4ut*e~~t(t)))). holda( T,models( u,diff( u( t),t) = kin*8in( t ))). holds(T,models(v,diff(v(t),t) = k,,t*8,,t(t)*h(t))). holds(T,modele(sp,sp(t)=spl(t)+ep2(t))). holds(T,models(fI;,,diff(8i,(t),t)=O)). holds(T,models(e,,t,diff(e,,t(t),t)=o)). holds(T,modsls(P, -=C)) :- constsnt(P,C). % Dynamic models: holds(T,models(h,diff(h(t),t)=(k;,*8i,(t)-k,,t*B,,t(t)*h(t))/srea)) :- holds( T,h < height). project(always,trans(up,h,height),models(h,diff(h(t),t)=O)). project(always,trans(down,r,height), modals(h,diff(h(t),t)=(k;,*8;n(t)-kout*8,~t(t)*h(t))/area)). holds(T,models(spl,spl(t)=O)) :- holds(T,h <height). project(alwaya,trans(up,h,height),models(spl,spl(t)=u(t))). projcct(always,trans(down,r,hcight),models(spl,spl(t)=O)). holds(T,models( sp2,sp2( t)=O)) :- holds( T,v < volume). project(always,trana(up,v,volume),models(sp2,sp2(t)=v(t))). Figure 2: Prolog clauses for the fluid-flow problem fluid; the valves vary from 0’ to 90’. We are interested in the consequences of a plan involving a sequence of adjustments to the two valves. In particular, we are in- terested in the volume of the fluid in the portable tank after the output valve is finally closed, and the total amount of fluid spilled from either the holding tank or the portable tank during the filling process. Let Kin be the flow rate of the input valve in cu- bic meters per degree minute, Kout be the flow rate of the output valve in square meters per degree minute, H be the height of the holding tank in meters, A be the surface area of the portable tank, and V be its to- tal volume. In addition to these constants, we have the following state variables (functions of time): h is the height of the fluid in the holding tank, 0i, is the angle of the input valve, eout is the angle of the output valve, u is the total volume of fluid to have entered the holding 136 AUTOMATED REASONING tank, and v is the total volume of fluid to have left the holding tank. Initially, we have h(0) = u(0) = v(0) = 0, du = Kindin, and &J = KoUteouth, where 0in and dOZLt are determined by the plan being evaluated. As long as h < H, we have ah = ( KinOin - K,,te,,th)/A. If trans( 1, h, H), then we have ah = 0, and, if trans(l, r, H) where T = Kin8in/KoUt8,,t, we are back to ah = ( Ki,&, - Kouteout h)/A. To determine the total amount of fluid spilled, we have to set up rules to han- dle the various possibilities for h < H and v < 17. The complete Prolog representation is shown in Figure 2. During projection, every time that h rises to height, r falls to height, or v rises to volume, the conditions for certain projection rules shown in Figure 2 are met, and these rules are used to generate tokens specifying new models for various parameters. For many planning problems, it is convenient to de- fine a special function of time for evaluating alternative plans. In our simple example, this evaluation function is sp( t ) which is the sum of the fluid spilled from ei- ther tank during the evaluation interval. If the plan consists of the five discrete events shown in Figure 2 and the evaluation interval is (0,12), then we can eval- uate the plan using the query holds( 12, sp=S) which returns with S bound to 1.37. The response time is neg- ligible for this query. The algorithm is guaranteed to terminate if the projection interval is finite. The com- plexity of projection is largely determined by the set of causal rules. For the sorts of rules we have encoun- tered in our planning problems, projection is at worst a small polynomial in the size of the set of rules and initial conditions. Conclusion The current implementation of our hybrid calculus is convenient to use and remarkably fast for a prototype system. It still lacks much of functionality of our pre- vious temporal database systems [Dean, 19891. The current system has only limited ability to reason about uncertainty in either the time of occurrence of events or the initial values of parameters. However, uncer- tainty is difficult to handle even with discretely chang- ing parameters and boolean variables [Dean and Boddy, 19881, and it appears that many of the techniques we have developed for handling uncertainty involving dis- crete change also apply in the continuous case. The primary advantage of the hybrid system de- scribed in this paper over most temporal reasoning sys- tems is its increased expressiveness and precision. It is clearly possible to model continuous processes using discrete approximations, but such approximations are often clumsy to formulate and sacrifice precision in or- der to achieve a reasonable level of performance. In our hybrid system, physical phenomena that are naturally modeled as continuous processes can be done so in a mathematical language designed for that purpose, and discrete processes can be modeled using first-order tem- poral logic which is well suited for that purpose. The use of numerical methods for solving systems of ordi- nary differential equations gives the modeler a great deal of flexibility, and provides more than ample pre- cision for the modeling tasks we have encountered so far. In addition, for projection problems of the sort en- countered in many planning applications, our system subscribes to Sandewall’s semantics up to the precision of the underlying numerical methods. Finally, and per- haps most importantly, we are now able to easily rea- son about planning problems that were impossible or at least prohibitively complicated to do so previously. References [Allen, 19841 J ames Allen. Towards a general theory of action and time. Artifkial Intelligence, 23: 123-154, 1984. [Brachman et al., 19891 Ronald J. Brachman, Hec- tor J. Levesque, and Raymond Reiter, editors. Pro- ceedings of the First International Conference on Principles of Knowledge Representation and Reason- ing. Morgan-Kaufman, Los Altos, California, 1989. [Dean and Boddy, 19881 Thomas Dean and Mark Boddy. Reasoning about partially ordered events. Artificial Intelligence, 36( 3):375-399, 1988. [Dean and McDermott, 19871 Thomas Dean and Drew V. McDermott. Temporal database manage- ment. Artificial Intelligence, 32( l):l-55, 1987. [Dean, 19891 Thomas Dean. Using temporal hierar- chies to efficiently maintain large temporal databases. Journal of the ACM, 36(4):687-718, 1989. [Hendrix, 19731 Gary Hendrix. Modeling simultaneous actions and continuous processes. Artificial Intebbi- gence, 4:145-180, 1973. [McDermott, 19821 Drew V. McDermott. A temporal logic for reasoning about processes and plans. Cog- nitive Science, 6:101-155, 1982. [Ralston and Rabinowitz, 19781 A. Ralston and P. Ra- binowitz. A First Course in Numerical Analysis. McGraw-Hill, New York, 1978. [Rayner, 19891 Manny Rayner. Did newton solve the “extended prediction problem?“. In Brachman et al. [1989], pages 381-385. [Sandewall, 19891 Erik Sandewall. Combining logic and differential equations for describing real-world sys- tems. In Brachman et al. [1989], pages 412-420. [Shampine and Gordon, 19751 L. F. Shampine and M. K. Gordon. Computer Solution of Ordinary Dif- ferential Equations. W. H. Freeman and Company, 1975. [Shoham, 19881 Yoav Shoham. Rea.soning About Change: Time and Causation from the Standpoint of Artificial Intelligence. MIT Press, Cambridge, Mas- sachusetts, 1988. DEAN AND SIEGLE 137
|
1990
|
30
|
946
|
Anytime Synthetic Projection: Maximizing the Probability of Goal Satisfaction Mark Drummond* and John Bresinai Sterling Federal Systems AI Research Branch, NASA Ames Research Center Mail Stop: 244-17, Moffett Field, CA 94035 Abstract This paper presents a projection algorithm for in- cremental control rule synthesis. The algorithm synthesizes an initial set of goal-achieving control rules using a combination of situation probability and estimated remaining work as a search heuris- tic. This set of control rules has a certain probabil- ity of satisfying the given goal. The probability is incrementally increased by synthesizing additional control rules to handle “error” situations the exe- cution system is likely to encounter when following the initial control rules. By using situation prob- abilities the algorithm achieves a computationally effective balance between the limited robustness of triangle tables and the absolute robustness of universal plans. Introduction We are interested in a continuum of plan-guided sys- tems, from those that can operate entirely off-line, where complete plans are produced in advance and later used by independently competent execution sys- tems, to those systems that are embedded in the situ- ations for which their plans are generated. These em- bedded systems are especially interesting since they must close the loop between plan formation and plan execution in their environment. For an embedded sys- tem, simply generating a plan is not enough; such a system must instead incrementally coerce its environ- ment to conform with its goals. The key tasks for an embedded system are resource-bounded incremental plan synthesis and reactive behavior using appropriate plans in a closed-loop fashion. The work presented in this paper extends existing theory in the areas of temporal projection, anytime al- gorithms, and plan synthesis for embedded systems. The goals of this paper are to: 1) define the syntax *This work has been partially supported by the Artificial Intelligence Research Program of the Air Force Office of Scientific Research. ‘Also affiliated with the Computer Science Department at Rutgers University. and semantics of behavioral constraints and provide a search heuristic for their satisfaction; 2) define the probability of behavioral constraint satisfaction; 3) de- scribe a synthetic temporal projection algorithm with anytime properties which heuristically maximizes the probability of behavioral constraint satisfaction. The next section provides relevant background infor- mation. The synthetic temporal projection algorithm is then presented by way of a simple example. The paper concludes with a discussion of connections to re- lated research. Background Realistic planning and control problems suggest the need for temporally extended goals of maintenance and prevention, in addition to the traditional plan- ning goals of achievement. Our approach employs a language of behavioral constraints which is based on a branching temporal logic (cf Drummond, 1989). As an example, consider the following behavioral constraint, or BC. (and (prevent (and (drunk driver) (has-car-keys driver)) 7 12) (achieve (or (at-home me) (have-companion me) ) ?tl>> This BC represents a conjunction of two temporally extended goals: the first goal must be false from time 7 through time 12 and the second goal must be true at some arbitrary time in the future. Behavioral con- straint semantics are defined in terms of possible be- haviors that are synthesized by our temporal projec- tion algorithm. Intuitively, we say that a given projec- tion path w satisfies a behavioral constraint p if and only if all of the formulas in p are true in w over the re- quired time intervals. See appendix A for more details on BC syntax and semantics. We define a behavioral constraint strategy (or BC strategy) to be a partial order over a set of behav- ioral constraints. The partial order, denoted by “_<“, 138 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. indicates both execution and problem solving prece- dence. Behavioral constraint strategies for a given be- havioral constraint are produced using domain- and problem-specific planning expertise. The BC strategy constructed for a given BC indicates a set of subprob- lems for the projector to satisfy and an order in which to satisfy them. This process is beyond the scope of this paper; please refer to Bresina and Drummond (1990) for more information. The way in which BC strategies are used by the projector is made clear in the next section. In order to project future possible courses of action our projector needs a causal theory for each domain of application. A causal theory is a set of operators which defines both the actions that the system can take and the exogenous events that can occur in the applica- tion environment. The difference between actions and events is simply this: actions can be chosen for exe- cution by the control system under construction (e.g., move in a direction) while the occurrence of events is determined by the system’s environment (e.g., a gust of wind). From the perspective of the projector how- ever, actions and events are similar, and both can be characterized as a situation to situation transition. The projector explores various possible futures by re- peatedly finding enabled operators and applying them to produce new hypothetical situations. The projector creates a directed acyclic graph, where each node de- notes a domain situation and each arc is labelled with a domain operator. Projection associates a duration with each operator application and uses this to calcu- late a time stamp for the resulting situation. A path in a projection graph denotes a future pos- sible behavior. Projection paths which satisfy a given behavioral constraint are compiled into a set of Situ- ated Control Rules (SCRS) similar to the way that a STRIPS plan is transformed into a triangle table (Fikes et al., 1972). The SCRs indicate to the reaction com- ponent those actions which will “lead to” the eventual satisfaction of its current behavioral constraint. SCRs are used by the reaction component as a set of local instructions constituting a control program. See Bresina and Drummond (1990) and Drummond (1989) for more details about our overall architecture. The algorithm described in this paper does not crit- ically depend on the architecture, so many irrelevant details have been suppressed. Our temporal projec- tion algorithm can be used by a variety of systems, in a range of architectures. The Projection Algorithm This section presents our anytime synthetic projection algorithm. We start with a description of the algo- rithm in operation and then present ways to control the search that is inherent in this approach. The project algorithm accepts a behavioral con- straint and domain causal theory; it attempts to max- imize the probability that the reaction component will satisfy the behavioral constraint. Our algorithm is based on the heuristic search paradigm which makes it hard to guarantee that the actual maximum proba- bility will be found. Instead, as is typically done with heuristic search algorithms, we claim only that our al- gorithm attempts to maximize the probability of goal satisfaction, which we refer to ES heuristic maximizu- tion. To simplify the presentation we characterize the pro- jector’s causal theory as a single function called trun- sition. The function transition (s) maps a situation description s to a set of triples < si, pi, oi > such that P (Si 1 s, Oi) = pi, where the conditional probability ex- pression has the following interpretation. If oi denotes an action, then pi is the probability that si will be the resulting situation if oi is executed in situation s. If oi denotes an event, then pi is the probability that si will be the resulting situation if oi occurs in situation s. For a given s, we assume that the possible transi- tions are mutually exclusive. Notice that this defini- tion of trunsition(s) makes the Markov assumption by ignoring the particular sequence of operators used to produce s. It is difficult to achieve a complete specifi- cation of all possible situation transitions in a realistic domain, and the automatic incremental improvement of the transition function specification is part of our future research agenda. See figure 1 for an abstract projection graph exam- ple. The behavioral constraint strategy PI 4 /32 has been selected as an appropriate way to satisfy p. This BC strategy indicates that a path which satisfies /?I composed with a path which satisfies & will consti- tute a path which satisfies /3. Project first calls traverse to find a single path that satisfies pr -i /32 from its %urrent? situation, sr. Tra- verse uses the function transition to create situations reachable under the application of a single operator from si. Not all possible transitions are considered: a filter is used to select a subset of the most probable transitions, and only these are used to produce new successors to sr. In our example only sz survives the probability filter. The number of survivors under this winnowing operation is determined by a filter-width parameter, corresponding to the filter selection func- tion in Ow and Morton’s (1986) filtered beam search. A heuristic value is calculated for each successor sit- uation based on the situation’s probability and an esti- mate of the remaining work required to satisfy Pr from that situation. (This estimation function is explained in more detail below.) Another winnowing process is used to select a subset of these situations that have the highest heuristic value. For our example, this set contains only ~2. In general, however, this set will con- tain a subset of all possible frontier search nodes in the developing projection graph. The number of elements in this set is limited by a beam-width parameter, cor- responding to Qw and Morton’s (1986) beam selection function. This set of frontier nodes is passed on to a DRUMMONDANDBRESINA 139 01 04 8; - &j - 87 05 06 . Figure 1: A Simple Projection Graph Example recursive call of traverse. Traverse continues to extend projection paths by se- lecting possible transitions until it finds a path which satisfies /?I. In the figure, the first satisfactory path discovered iS slols2o2s30364. Situated control Rules are now compiled for each situation in this path. The reaction component will thus be given a set of rules of the form: IF si AND pl THEN oi, for i = 1,2,3. At this point, traverse focuses its search for a solution path to fl2 in the subspace anchored at s4. This is accom- plished by collapsing the set of frontier nodes to the singleton set (~4). Such a collapse has the effect of re- quiring any solution path for /32 to start in the situation terminating the satisfactory path for PI. Winnowing the set of possibilities in this way helps to control the projector’s search by reducing the number of alterna- tive situations in the expanding search frontier. We call this strategy cut-and-commit, and it is one aspect of the algorithm’s anytime operation. The con- ditions under which this approach is advisable are dis- cussed below. Traverse continues its search to satisfy p by find- ing a projection path which satisfies ,82 from s4. In our figure, the eventual satisfactory path for p2 is s@&o5s6o6sr. This path is passed to the SCR com- piler producing another set of SCRs for the satisfaction of ,82. The probability for the path si through s7 can be calculated from p(si+llsi, oi), i = 1,. . . ,6 (as de- fined below). This number gives us a lower bound on the probability that the reaction component will satisfy /?. Assuming that there is still time before the reac- tion component must take action, we can increase this probability by finding additional paths which also sat- isfy p. Each additional path will serve to increase the lower bound on the reaction component’s probability of satisfying p. Robustify is our algorithm for finding additional pro- jection paths. The algorithm finds high-probability de- viations from the single existing solution path and calls 140 AUTOMATED REASONING traverse to find alternative paths which recover from each deviation. A deviation is a transition in a situa- tion which produces a new situation from which there does not yet exist a satisfactory path. For example, when robustify is applied to the path slols2o2s3o364, it finds that the transition to ss via operator 07 has a high probability of occurring in s2. Traverse is used to recover from this deviation by synthesizing an alter- nate path, s1ois2orssosss@s4, which also satisfies pi. Similarily, robust& finds that the transition from 95 to sic via 016 has high probability and calls traverse to synthesize the path ~~~~~~~~~~~~~~~~~~~~~~ Each ad- ditional path serves to increase the probability that p will be satisfied by increasing the probability that each of its component constraints, /?I and p2, will be satisfied. Situated Control Rules are compiled for each new subpath synthesized by traverse; in our example, new SCRs are created for 52, ss, ss, s5, and sre. This incre- mental deviate-and-recover strategy is another aspect of the algorithm’s anytime operation. As each new path is found, SCRs are given to the reaction com- ponent to help it deal with ever more of the possible domain situations in which it might find itself. Controlling the Search Situation probability and estimated remaining work were used in traverse to define a heuristic evalua- tion function. The heuristic value for a situation s, with respect to a BC p, is computed as: h (s,p) = clip + K2.rwt(s,P), where p(s) is the probability of situation s and nut (s, p) is the estimated remaining work required to satisfy p from s. The user-provided weights, Kl and K2, determine the relative importance of low-cost and high-probability in the computation of hand, hence, affect the type of solutions synthesized by traverse. These parameters must be tuned as required for each domain of application. This section gives def- rur(s, (maintain $ rs 7,)) m$Ll Tzu(S,pi) = mu(s, (prevent II) 5 7,)) KW l min-true (4, s) . (7, - 7,) + min-false ($, s) . (cw + Kw l (7, - r6)) = rw(s, (maintain II) ys cp)) KW . ??Iin-tTUt? (+, S) . (TV - TV) + min-fah? ($, S) l (CW + KW . (7, - T#)) = rzu(s, (prevent 4 cp $4) KW . min-true (?j, 5) + CW = man-false ($, s) = KW l min-true (?j, s) + CW l min-false ($, s) Table 1: Definition of no(s,p) initions for estimated remaining work and path proba- bility, and more clearly explains the role of behavioral constraint strategies in controlling search. Estimated remaining work For planners concerned only with conjunctive goals of achievement, a heuristic based on situation difference gives reasonable results (Nilsson, 1980); to handle be- havioral constraints we have generalized the notion of situation difference to that of remaining work per time. Our heuristic uses two global parameters, KW (kep work) and cw (change work), which relate predicate truth value to work. The parameter KW denotes the minimum work per unit time to keep the truth value of a predicate constant. The parameter cw denotes the minimum number of work units required to change the truth value of a predicate. We assume that facts change instantaneously and cw estimates the mini- mum work required to change the truth value of a randomly selected predicate. A user must set these parameters as required for each application domain. be We define the remaining work per time rwt (s,p) to rw(s,p)/rt (s,/?); where rw(s,@ is the remaining work necessary to satisfy p from s and rt (s,p) is the remaining time in which to do the work. The remain- ing time can be easily estimated from /3 and s. Let s be a situation, and let rn be the time stamp of s. The numerator of our equation, TW (s,p), can then be defined as shown in table 1. The function min-true($, s) gives the minimum number of predicates in the formula $ that are true in situation s. Similarly, min-faZse(+, s) gives the mini- mum number of false predicates. These terms, together with cw and KW, produce an optimistic estimate of the amount of remaining work. For example, consider the evaluation of rw(s, (maintain $ rs 7,)). The formula ?c) must be main- tained from time point rs through time point r,, from situation s with time stamp 7,. The appropriate defi- nition in table 1 has two terms: the first term describes the work required to keep the minimum number of true predicates in $ true from r, through 7,; the second term deals with the work required to change the min- imum number of false predicates in 1c, to be true, and the work required to keep these predicates true from r6 through 7,. The classical situation difference heuris- tic is a degenerate form of these measures, where work is measured in the number of predicates that must be made true and where there is no cost for keeping pred- icates true over time. Goal Sat isfact ion Probability Our description of traverse depended on the ability to combine individual transition probabilities into aggre- gate projection path probabilities; this section explains how this is accomplished. Let G = (S,T) b e a projection graph, where S is a set of possible situations and T is a set of situation- to-situation transitions; let s E S be a particular sit- uation, and let 20 = s1ors202.. .o,-IS, be a path in G. The path probability of w is defined to be the product of the transition probabilities in w: p (w) = P (31) ’ nr;fP (%+l 1 Si7 Oi)- For a situation s, the situation probability is defined as the sum of the path probabilities of all paths from the unique starting situation of G, ss, to s: p (s) = C p (w) summed over {w : w = ~101. . .on-rs,, is a path in G, s1 = ss, and s, = s}. Finally, we can define the probability that a behav- ioral constraint, p, is satisfied by a projection graph, 6, as the sum of the probabilities of all paths in G anchored at the unique starting situation ss which rtisfy /3: p (p 1 6) = C p (w) summed over ard ‘w ~a%~?~ j: o,-rs, is a path in G, sr = 83, The probability that the reaction component will satisfy a BC p under the guidance of the SCR,s com- piled from a projection graph G is bounded below by p (p 1 G). The probability p (p 1 G) is a lower bound because the reaction component might have access to other SCRS relevant to p which cover situations that are not in G. Behavioral Constraint Strategies As mentioned above, a behavioral constraint strategy is a partial order over a set of behavioral constraints. A given BC strategy controls search by giving the pro- jector a set of behavioral constraints to satisfy and an order in which to satisfy them. A BC strategy is satis- fied when each of its component constraints is satisfied in an order consistent with the given partial order. To make this idea more precise, let (I’, 4) be a BC strategy, where I’ contains n behavioral constraints; let 0 be the set of all total orders over I’ compatible with DRUMMOND AND BRESINA 141 4. Th; obj?tive for traverse is to synthesize a path W =w 020 o*--0w n, such that there exists a total order 6 E 0 where for each wi, wi+l in w, there exists p + /3’ E 8 such that wi satisfies /3 and wi+l satisfies /?I. Furthermore, each p E I’ must be satisfied by one wi in 20. The “0” operator represents path composition defined as follows: w o W’ = ~101~202. . . sie{s&e& . . . 54, where w = sro152oz . . . si and w’ = sieis&ei . . . si, if the union of si and si is consistent, else w o 20’ is un- defined. Consider the simple example used above where the BC strategy is /?I 4 &. In the ideal case, for each path w1 that satisfies &, there exists a path w2 that satisfies /32 such that w1 o w2. In this case, our cut- and-commit strategy will never be forced to backtrack over the first solution found for & , and the policy of immediate SCR compilation is risk-free. However, it is not always possible to construct such ideal BC strate- gies. More typically only a subset of the paths which satisfy /3r can be extended to also satisfy &. In this case, the projector might have to backtrack to find an- other solution to &. If such backtracking occurs, then (at least some of) the SCRs that were compiled from a rejected solution to pr are not appropriate in the con- text of /3r + pz. However, they may be appropriate in the context of another BC strategy and hence could still prove useful. In this paper, we do not address what the reactor does when more than one SCR is applicable. This issue is part of our current research effort; we are de- veloping a SCR conflict resolution strategy based on the BC strategy context for which an SCR is appro- priate in combination with the transition probability and the remaining work estimates associated with an SCR. In our ongoing research on the interaction be- tween the projector and the automatic production of behavioral constraint strategies, one future topic will be techniques for assessing and reducing the risk of backtracking over the inter-behavioral constraint “cut” points. Discussion A. triangle table (Fikes et al., 1972) is analogous to what you get after running traverse only once, a uni- versal plan (Schoppers, 1987) is analogous to what you get by doing exhaustive search of the space of possible domain situations. A triangle table is like a set of SCRs designed to deal with each situation in a sequence of situations, and a universal plan is like a set of SCRs which has 100% coverage of the space of situations. Ginsberg (1989) h as argued against the practicality of universal plans. He has suggested that for “cognitive tasks”, a system should be able to enhance its perfor- mance by expending additional mental resources. Our projection algorithm does exactly this. Under our ap- proach, additional computation time serves to increase the probability of goal satisfaction. There are various architectures addressing the real- time embedded control problem. Representative ap- proaches include Brooks’ (1985) subsumption architec- ture, Nilsson’s action nets (Nilsson, et al., 1990), Maes’ (1990) spreading activation approach, and the situ- ated automata of Rosenschein and Kaelbling (Rosen- schein, 1989; Rosenschein & Kaelbling 1986; Kaelbling, 1987a,b, 1988). Each of these approaches gives a de- signer a language and methodology for specifying a control system. Brooks’ (1985) b su sumption architecture provides an elegant way of organizing the functional components of an embedded control system. The subsumption archi- tecture “model” of embedded execution is richer than our simple IF-THEN Situated Control Rule view. How- ever, we are able to synthesize SCRs automatically from a given behavioral constraint and causal theory describing a particular application domain. To our knowledge, Brooks has not yet addressed the auto- matic synthesis of subsumption architecture instances. Nilsson’s action nets (Nilsson, et aL, 1990) provide another methodology and language for the description of embedded systems. Nilsson’s view of closed-loop homeostatic servo mechanisms is appealing, and early results are promising. Our work differs in providing a more expressive language of behavioral constraints and by using information about situation probability to control search. Maes’ (1990) system employs a spreading activa- tion approach for dynamic action selection and can be viewed as a form of on-line action synthesis. The behavior of Maes’ algorithm depends on a number of global parameters which are set by the user based on (among other factors) characteristics of the environ- ment and the specific goal to be achieved. Hence, if the nature of the environment changes or if the desired goal changes, the user will need to re-tune the param- eters. Our work differs by explicitly searching through the space of possible futures. A behavioral constraint is one of the algorithm’s inputs; hence, changes in the system’s goals are taken into account automatically. Changes in the nature of the environment would be re- flected in the transition probabilities; hence, updated probabilities would appropriately influence the projec- tion search.l The most closely related work is that of Rosen- schein and Kaelbling (Rosenschein, 1989; Rosenschein & Kaelbling 1986; Kaelbling, 1987a,b, 1988). Kael- bling’s GAPPS system is a compiler which translates goal reduction expressions into directly executable cir- cuits. However, a person writing GAPPS goal reduc- tions must essentially do their own temporal projec- tion; that is, it is the person’s responsibility to guar- antee that the rules, once sequenced, will “lead to” goal satisfaction. In contrast, our approach defines a tem- poral projection mechanism which sorts out the effects ‘We have not yet implemented transition probabilities. the automatic update of 142 AUTOMATEDREASONING of various action sequences automatically. Of course, we potentially pay a greater computational cost by car- rying out this search. Additionally, the GAPPS sys- tem, and the REX language on which it is based, have a great deal to say about bounded reaction tim,e in terms of the circuits synthesized from higher-level ex- pressions. We are not currently addressing this issue. We stress the synthetic nature of our projector to distinguish it from analytic projection (Dean & Mc- Dermott, 1987; Hanks, 1990). An analytic projector is used by a planner to validate plans while a synthetic projector combines operator selection and validation in the same algorithm. The analytic/synthetic distinc- tion is largely one of perspective, since it is possible to view a planner-analytic projector pair as a complete system which performs synthetic projection. Hanks (1990) g reatly extended the capabilities of temporal projection systems by adding information re- garding probability. Dean and Kanazawa (1988) also use similar information. The techniques of Hanks, Dean and Kanazawa can be used to judge the prob- ability that a given fact will be true at an arbitrary point in the future. We can imagine providing such an inferential facility, but for now, we permit only cal- culations of individual situation probability. The al- gorithms of Hanks, Dean and Kanazawa can perform more powerful inferences. Dean and Boddy (1988) have characterized an any- time algorithm as one which can be asked for an answer at any point, where the algorithm’s answers are ex- pected to improve the longer it is allowed to run. Our use of traverse and robustify satisfy this characteriza- tion, in the sense that a set of SCRs is available for the reactor at any point in time, and in the sense that the set of SCRs “improves” over time by incremen- tally increasing goal satisfaction probability. We have identified two ways in which a synthetic temporal pro- jection algorithm can be considered “anytime”: first, by using our cut-and-commit search strategy based on behavioral constraint strategies; and second, by recur- sively employing our deviate-and-recover strategy to manage probable errors. Our cut-and-commit approach ameliorates the com- plexity of the projection search. To see this, suppose that the average branching factor in the projection is b, and suppose that an eventual solution path is of length n. This means that breadth-first search would have to project, in the worst case, b”+l - 2 many situations to find a successful path. Suppose that the projector’s BC strategy is totally ordered and is of length c. In the worst case, the number of situations that traverse must project is cm b(“/“)+’ - 2~. As c approaches n, the number of situations we must consider falls off dramat- ically. This assumes, of course, that no backtracking occurs. As c increases, the projection takes on the shape of a series of small trees connected end-to-end, rather than one large tree running from start to finish. The larger c is, the smaller the computation’s anytime “grain size” becomes. We have designed and implemented a simulator for an experimental domain called the Reactive Tile World. The Reactive Tile World exhibits exogenous events and temporally extended goals of maintenance and prevention. We are in the process of empirically validating our projection algorithm on a suite of Reac- tive Tile World test problems. Acknowledgements Other members of the ERE group, namely, Rich Levin- son, Andy Philips, Nancy Sliwa, and Keith Swanson have helped us develop these ideas; discussions with Mark Boddy, Leslie Kaelbling, Stan Rosenschein, and Steve Hanks have been useful. Thanks to John Allen, Hamid Berenji, Guy Boy, Peter Cheeseman, Smadar Kedar, Phil Laird, and Amy Lansky for useful com- ments on a previous draft. Final responsibility for all errors and omissions rests, of course, with the authors. Thanks also to Peter Friedland for providing an excel- lent research environment at NASA Ames. Appendix A: Behavioral Constraint Syntax and Semantics A behavioral constraint (BC) is an expression con- structed according to the following grammar. We use the symbol p to stand for an arbitrary BC and the symbol 1 to indicate alternatives. ; -+ (and PI P2 --a A) I (or PIP2 -*a A) + (maintain $ 71 72) I (prevent $ q 72) z + (maintain $ cp ‘p) I (prevent $ cp cp) -+ (and +I he.. tin) I (or $1 qb... A) 4 + predicate We use T/J to denote a formula, r to denote a time point constant, and cp to denote a time point vari- able. Time points are natural numbers. A vari- able is indicated by a question-mark, for instance: ?t. All variables are implicitly existentially quanti- fied. We currently use time point variables only to express those goals of “achievement” or “destruction” which are not required to occur at a predetermined point in time; these goals are given the following syn- tactic forms: (maintain ~+4 cp cp) z (achieve $J cp) and (prevent II) cp cp) G (destroy $ cp). Behavioral constraint semantics are defined in terms of projection graph paths. Let w = sro15202.. .on-rsn be a projection graph path; let ts (s) denote the time stamp of situation s; and let p be a behavioral con- straint. Then w satisfies p under the following condi- tions. DRUMMONDANDBRESINA 143 PI PI PI VI PI PI PI w I= . WE . WE iff w I= iff w I= iff w I= iff s I= iff s I= . s E iff (and PI . . . A) ViE{l...n): W +/3i (or Pl l - * A) %E{l...n}: W +pi (maintain $ 71 72) 3si E w : ts (si) 5 71 and si k + andVsiEw,j>i: sj j=$or ts(sj) >72 (prevent II) ~1 72) 3Si E w : ts (si) 5 71 and si k + andVsj ~w,j>i: Sj k $Or tS(Sj)>T2 (maintain $ cp rp) 3Si E W : Si b ?.fb (Prevent ti cp P) 3Si E W : Si k II, (and $1 . . . h) Vi E {l...n}: S b$i (or 41 l ** 3 48) 3iE{l...n): Sk& predicate predicate E s References Bresina, J., and Drummond, M. 1990. Integrating Planning and Reaction: A Preliminary Report. Proceedings of the 1990 AAAI Spring Symposium Series (session on Planning in Uncertain, Unpre- dictable, or Changing Environments). Bresina, J., Marsella, S., and Schmidt, C. 1986. REAPPR - Improving Planning Efficiency via Ex- pertise and Reformulation. Rept. LCSR-TR-82, LCSR, Rutgers University, June. Brooks, R. 1985. A Robust Layered Control Sys- tern for a Mobile Robot. Technical Report 864, Ar- tificial Intelligence Laboratory, Massachusetts In- stitute of Technology, Cambridge, Massachusetts. Dean, T., and Boddy, M. 1988. An Analysis of Time-Dependent Planning. AAAI-88. pp. 49-54. Dean, T., and Kanazawa, K. 1989. A Model for Projection and Action. Proceedings of IJCAI-89. pp. 985-990. Dean, T., and McDermott, D. 1987. Temporal Database Management. AI Journal. Vol. 32(l). pp. l-55. Drummond, M. 1989. Situated Con- trol Rules. Proceedings of Conference on Prin- ciples of Knowledge Representation & Reasoning. Toronto, Canada. PI PI PO1 WI PI WI WI PI WI WI P81 P91 PO1 Ginsberg, M. 1989. Universal Planning: An (Al- most) Universally Bad Idea. AI Magazine, Vol. 10, No. 4. pp. 40-44. Hanks, S. 1990. Projecting Plans for Uncer- tain Worlds. Yale University, CS Department, YALE/CSD/RR#756. Fikes, R., Hart, P., and Nilsson, N. 1972. Learn- ing and Executing Generalized Robot Plans. AI Journal, Vol 3, pp. 251-288. Fikes, R. and Nilsson. N. 1971. STRIPS: A New Approach to the Application of Theorem Proving to Problem Solving. AI Journal, Vol. 2, pp. 189- 208. Kaelbling, L. 1987a. An Architecture for Intelli- gent Reactive Systems. Reasoning About Actions and Plans. M. Georgeff and A. Lansky, Eds., Mor- gan Kauffman. Kaelbling, L. 1988. Goals as Parallel Program Specifications. Proceedings of the Seventh Na- tional Conference on Artificial Intelligence. St. Paul, Minnesota. Maes, P. 1990. How To Do the Right Thing. Con- nection Science Journal. (Special Issue on Hybrid Systems. J. Hendler, editor). Nilsson, N., Moore, R., and Torrance, M., ACT- NET: An Action Network Language and its Inter- preter. Draft paper, Stanford Computer Science Department, February 1990. Nilsson, N. 1980. Principles of Artificial Intelli- gence. Tioga Publishing Company, CA. Ow, P. and Morton, T. 1986. Filtered Beam Search in Scheduling. Working paper, Graduate School of Industrial Administration, Carnegie- Melon University. Rosenschein, S. 1989. Synthesizing Information- Tracking Automata from Environment Descrip- tions. Proceedings of Conference on Principles of Knowledge Representation & Reasoning. Toronto, Canada. Rosenschein, S. and Kaelbling, L. 1986. The Syn- thesis of Digital Machines with Provable Epis- temic Properties. Proceedings of Workshop on Theoretical Aspects of Knowledge. Monterey, CA (March 13-14). Schoppers, M. 1987. Universal Plans for Reactive Robots in Unpredictable Environments. Proceed- ings of the Tenth International Conference on Ar- tificial Intelligence. pp. 1039-1046, Milan, Italy. 144 AUTOMATEDREASONING
|
1990
|
31
|
947
|
Search Lessons Learned fro Crossword Puzzles Matthew L. Ginsberg* Michael Frank Michael P. Halpin Mark C. Torrance Computer Science Department Stanford University Stanford, California 94305 ginsberg@cs.stanford.edu Abstract The construction of a program that generates cross- word puzzles is discussed. As in a recent paper by Dechter and Meiri, we make an experimental compar- ison of various search techniques. The conclusions to which we come differ from theirs in some areas - al- though we agree that directional arc consistency is bet- ter than path-consistency or other forms of lookahead, and that backjumping is to be preferred to backtrack- ing, we disagree in that we believe dynamic ordering of the constraints to be necessary in the solution of more difficult problems. 1 Introduction Appearances notwithstanding, this is not a paper about crossword puzzles. It is a paper about search. More specifically, it is a paper about constraint satis- faction in large databases. What we have done is to write a program that gen- erates crossword puzzles by filling words into an empty frame. For frame sizes greater than 4 x 4, the associ- ated search space is large enough to make brute force depth-first search impractical; heuristics must be used. The large branching factor is a consequence of the fact that any particular word can be chosen in many possi- ble fashions - the dictionary used in this research con- tained some 24,000 entries. Crossword puzzle genera- tion can therefore be used to compare the general tech- niques that have been proposed for solving constraint- satisfaction problems in large databases. Crossword puzzles are fairly typical constraint- satisfaction problems; we share, for example, the constraint-satisfaction community’s interest in finding a single solution to a given problem, as opposed to finding all such solutions. But crossword puzzles also tend to be far more difficult than most of the problems that have been discussed in the literature thus far. The *This work has been supported by the Rockwell Palo Alto Laboratory. recent work of Dechter and Meiri, for example, consid- ers randomly-generated problems with lo-15 variables and 5 values [Dechter and Meiri, 19891; our crosswords involved perhaps 60 variables and 7000 values. In the next section, we discuss the general framework in which our experiments were performed. We also dis- cuss some simple improvements to existing techniques that we developed in order to allow our program to solve more difficult crosswords. Section 3 contains our experimental data. For each combination of the heuristics discussed in Section 2, we attempted to complete a variety of crossword frames; the average times needed to complete the search are shown, and the computational merits of the various techniques are discussed. Concluding remarks are con- tained in Section 4. 2 Existing work There is very little existing work on the automatic gen- eration of crossword puzzles; an old paper of Mazlack’s [Mazlack, 19761 is the only one of which we are aware.’ More relevant to our purposes is the work on constraint satisfaction. As noted in [Dechter and Pearl, 19881, there are four choices to be made when solving a constraint- sat isfact ion problem: which variable to instantiate next, what value to use as the instantiation, how to handle backtracking, and what sort of preprocessing to do. By a “variable,” we will mean a particular word slot in the puzzle being generated; the constraints corre- spond to the fact that if two words intersect in a square s, they must use the same letter in that square.2 ‘We will have little to say about Mazlack’s work here. His techniques are very different from ours, and the per- formance of his program - even correcting for hardware advances since it was written - appears to be at least one or two orders of magnitude worse than ours. 2Constraint-satisfaction problems have duals, where the roles of the constraints and the variables are swapped. 210 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Choice of variable When choosing which variable to instantiate next (i.e., which word to fill in), one must decide whether the choice should be made when the puzzle is first exam- ined (at “compile time” ) or whether it should be made dynamically as the other variables are assigned values (at “run time”). A variety of compile time heuristics have been dis- cussed elsewhere in the literature. The so-called “cheapest-first heuristic” suggests constructing a sta- tistical estimate of the number of choices remaining for each variable, and to then instantiate the variable that is the most constrained.3 The “connectivity heuristic” suggests instantiating a variable that is constrained by the last variable instantiated, in order to ensure that one backtracks effectively when a dead end is reached.* The best-known run time heuristic is known as “dy- namic search rearrangement” and suggests that at any particular point in the search one should pick the vari- able that actually is the most constrained (by counting the number of possible solutions for each uninstanti- ated variable), instead of simply the one that is statis- tically expected to be the most sharply restricted as in the cheapest-first heuristic. The two techniques that we chose to consider were the cheapest-first heuristic and its run time analog, dynamic search rearrangement. Connectivity was not considered because, as noted by Dechter and Meiri in [Dechter and Meiri, 19891, many of its advantages can be obtained by using backjumping [Gaschnig, 19791 in- stead of simple backtracking. Choice of instant iat ion Suppose, then, that we have selected a variable (i.e., word) to be filled next. How do we select among the possible values for it ? In doing so, it is important to select one that restricts the possible choices for subse- quent variables as little as possible. Why use a word with a Q when one with an S could be used inste’ad? In crossword puzzles, it is impractical to use this idea exactly; there are simply too many possible choices for each variable. Instead, we did the following: Suppose that we have decided to instantiate some particular As Rich Korf has pointed out, the dual problem in the crossword-puzzle domain is also a natural one - the vari- ables are the letters in the puzzle, and the constraints come from the fact that each letter sequence must be a legal En- glish word. 3For example, if there are 2139 4-letter words in the dictionary, it is assumed that 2139/26 choices remain after the second letter is filled in. This is independent of whether the choice is E (in which case 281 completions remain) or Q (in which case there is in fact only 1). 4Thus having filled in one word, we would next fill a word that intersects it. By not jumping from one section of the puzzle to another, we ensure that chronological back- track always considers a difficulty related to the one that actually caused the backup. variable by filling a particular word in the puzzle. The program considers the first k words that can legally fill this slot; suppose that we denote them by wl,. . . , wk. For each wi , the number of possibilities for each unfilled crossing word is computed, and the product of all of these values is calculated. The word actually chosen is that wi that maximizes this product. Of course, the behavior of this heuristic will be sen- sitive to the choice made for Ic. If k = 1, the first available word will be used at all times. But making k too large is also a mistake - all we really need to do is to make it large enough that one of the first k words is a fairly good choice. The time spent examining the rest of the possible words is unlikely to be justified by the small impact on the size of the subsequent search space. Some experimentation indicated that Ic = 10 was a reasonable value, and this is the value used in Section 3, where it is compared with the choice k = 1. The parameter k was called min-look in the imple- mentation and this is how we will refer to it in Section 3. Backtracking When a dead end is reached (i.e., some slot is found for which there is no legal word), the program needs to backtrack and try something else. Simple chronological backtracking (backtrack to the last choice point, as in PROLOG) suffers from the problem that it may fail to address the source of the difficulty. If the program is having trouble filling the upper-left-hand corner of the puzzle, it is a mistake to make changes in a portion of the puzzle that have no effect on this problematic region. This difficulty can be ovnrcome using a technique known as backjumping [Gaschnig, 19791, which actu- ally backs up to the source of the difficulty. It has been shown both theoretically [Dechter, 19901 and experi- mentally [Dechter and Meiri, 19891 that backjumping outperforms its chronological counterpart. If no lookahead is done, backjumping can be imple- mented simply by always backtracking to a word that intersects a word that cannot be filled satisfactorily; the connection with the connectivity heuristic is clear in this case. If lookahead information is used as well (see the next section), then backjumping requires us to maintain, for each instantiated variable, a list of those subsequent variables that it affects in some way. This idea is obviously closely related to dependency-directed backtracking [Stallman and Sussman, 19771, although it is not quite the same because the expense of main- taining complete dependency information is avoided. We also considered a small further improvement. Suppose that we have reached a dead end, and have de- cided to backjump to a particular word, wi, that is the source of the difficulty. It is not too hard to determine what letter or letters in wi are causing the problem, and to then ensure that the new choice for wi avoids it. In conventional constraint-propagation terms, we GINSBERGETAL. 211 Figure 1: Is multiple lookahead worthwhile? realize that the variable wr is causing trouble because of the constraints it places on a subsequent variable w2 (or perhaps a collection of subsequent variables). Having done so, we make sure that the new choice for wr allows us to change our selection for 202. In Section 3, we will refer to the possible choices as “bt” (simple backtrack), “bj” (backjump to the relevant problem, but make no effort to ensure that the difficulty has been addressed) and “sbj” (smart backjump, ensuring that some relevant letter changes value). Preprocessing Finally, there is the possibility of preprocessing the data in some way that will reduce the need to back- track in the first place. In [Dechter and Meiri, 19891, Dechter and Meiri suggest that the most effective way to do this is to.preprocess the information at each node of the constraint graph in a way that ensures that when a particular variable w is instantiated, there will always be an instantiation for every other variable that shares a constraint with w. In terms of crossword puzzles, we make sure that the choice made for one word is con- sistent with the choices that will need to be made for the words that intersect it. This is called directional arc-consistency [Dechter and Pearl, 19881. There are other possibilities as well. If we think of directional arc-consistency as a simple lookahead to depth 1, directional path-consistency is lookahead to depth 2, so that for the word being instantiated and every choice for a word w’ that meets it, there will be a choice for every word that meets w or w’. In a crossword puzzle, it is impractical to store all of this consistency information; there are simply too many possibilities. Indeed, this was already observed by Dechter and Meiri on the simple problems they in- vestigate in [Dechter and Meiri, 19891. It is possible, however, to repeat the analysis at run time, essentially doing a lookahead to a depth of greater than one when each variable is instantiated. It seems at first that this should be a good idea. Consider the puzzle in Figure 1, for example. It might be the case that there are no two five letter words wr and w2 such that wr ends in Y, w2 has T as its fourth letter, and the last letter of w2 is the same as the first letter of wi. A two-level lookahead would notice this, 04 Figure 2: Test puzzles and one of the two words in Figure 1 would be with- drawn immediately. In practice, this does not work so well. The reason is that the computation involved is a fairly difficult one - we need to look at the possible choices for wi, check to see which letters are still possible in which spaces (this is the expensive part, since it involves examining each of the choices for wi ) , and then to use this in- formation to prune the set of possibilities for ~2. The analysis is expensive enough that the cost incurred is not in general recovered by the associated pruning of the search space. More conventionally put, the for- ward branching factor for the problem is high enough that additional levels of lookahead draw conclusions no more effectively than their backward counterparts. 3 Experimental results Frames used and raw data In order to evaluate the usefulness of the ideas in the last section, the four puzzles appearing in Figures 2 and 3 were solved by the program. The program al- ways used one level of lookahead (i.e., arc-consistency) 212 AUTOMATEDREASONING (4 Figure 3: Test puzzles (ctd.) and some form of the cheapest-first heuristic, since it was quickly discovered that without these, all but the simplest puzzles were intractable. The other parame- ters were set as follows: cheapest-first could be either stat, indicating that a compile-time statistical approximation was used, or exact, indicating that the exact (run-time) value was used. If the run-time ordering were used, min-look could be either 1 (always use the first acceptable word) or 10 (use the best choice among the first ten acceptable words). This calculation was not performed when the statistical ordering was used, since only dynamic information about variable orderings can be used to distinguish among words in this fashion. connected-backtrack could be either bt, bj or sbj, as described in the previous section. For each allowable selection of parameters, each of the above puzzles was solved 10 times; the dictionary was shuffled between each solution attempt to ensure that the performance of the program was not affected by a particularly fortunate or unfortunate choice of word at any point. The results are as reported in Figure 4; the times reported are in seconds for a Symbolics 3620 with 2 megawords of memory. We feel that time of solution is a more valuable gauge of performance than the num- ber of nodes examined or the number of backtracks (as used in [Dechter and Meiri, 19891) because it is of- ten possible to prune the search space but only at a prohibitive cost in terms of the time spent expanding a single node. This is the argument we made when considering lookahead to multiple depths. For the harder puzzles, many of the choices of pa- rameters did not lead to solutions being found within 20 minutes of CPU time, and no timing information is reported for these parameter choices. The most diffi- cult puzzle ((d) in Figure 3) was solved in only 8 of 10 cases with min-look set to 1. Analysis As already mentioned, arc-consistency and cheapest- first were needed to solve any of the puzzles. With regard to the other choices, we observed the following: Choice of variable Unlike the results reported by Dechter and Meiri in [Dechter and Meiri, 19891, it is apparent even for the 5 x 5 puzzle that runtime infor- mation plays an important role in the choice of word to be filled next. The difference in performance be- tween the programs that used an exact version of the cheapest-first heuristic and those that used the statis- tical approximation available at compile time is signif- icant in all cases; the two most difficult puzzles could not be solved at all within the twenty minute time limit unless runtime information was used. GINSBERG ET AL. 213 Choice of instantiation The overhead involved in finding a word that minimally restricts the subsequent search is worthwhile only on puzzles of size 9 x 9 and larger, and it is not until the most difficult of the four puzzles is considered that this heuristic begins to play a significant role. This suggests that the choice of min-look (the number of words considered to fill a par- ticular slot) should be closely coupled to the apparent difficulty of the puzzle being constructed. Backtrack Backjumping (as opposed to simple backtracking) is another heuristic the value of which is only apparent on the larger puzzles; on smaller ones, the cheapest-first heuristic tends to order the words in a way that results in a particular word intersecting the word being filled next and the two techniques co- incide. “Smart” backjumping is needed for puzzle (d) only - but here, it turned out to be absolutely cru- cial. The reason is that many of the 13-letter words have endings like “tion” and if this choice made the upper-right hand corner of the puzzle impossible to fill, it was important not to try another word with the same ending. Of course, it is not clear to what extent other constraint-satisfaction problems will share these features, but it is not unreasonable to think that they will. Things that didn’t work It is also probably worthwhile to report on search heuristics that we tried, but that didn’t reduce the time needed to find a solution to the puzzle. Tree reordering while backtracking Suppose that backjurnping has caused us to backtrack over a word w because it was not relevant to the problem that caused the backtrack in the first place. Is it rea- sonable to put w back into the puzzle before resuming the search, thereby modifying the order in which the search is conducted so that we can reuse the informa- tion that would otherwise be lost? Unfortunately not. Just because removing w doesn’t directly alleviate a particular difficulty is no reason to believe that keeping w won’t commit us to the same problem. As an example, suppose that we put in a word 201, then a crossword ~2, then discover that an- other crossword ws to wr cannot be filled satisfactorily. Provided that the choices for ws are not constrained by the selection of wz, we will backtrack directly to wi, and the above suggestion would therefore cause us to replace w2 in the puzzle. Unfortunately, this replace- ment might well commit us to wi once again. It may be possible to identify a limited set of situ- ations where words that are passed over during back- tracking can be safely replaced, but these situations appear to be fairly rare in practice and the cost of searching for them seems not to be justified. 214 AUTOMATEDREASONING Compile-time dictionary ordering We also con- sidered the possibility of ordering the dictionary not randomly, but in a way that would prefer the use of words containing common letters. For small puzzles, this led to significant performance improvements; the preference of common letters virtu- ally eliminated the need to backtrack on puzzles (a) and (b). On puzzle (c), however, the performance gain was much more modest (perhaps 20%), while on puz- zle (d), the performance appeared to actually worsen - the program was no longer able to solve the puzzle within the twenty minute time limit if min-look was set to 10. (For min-look set to 1, however, only 15 seconds were required.) It is difficult to know what to make of such conflict- ing data; since the ordered dictionary can no longer be shuffled to eliminate statistical fluctuations in solution time, it is possible that the observed behavior is not re- flecting the fundamental nature of the algorithm. The best explanation we can offer is the following one: On large puzzles, where backtracking is inevitable, the ordered dictionary is likely to result in the first ten choices for any particular word being fairly simi- lar. As a result, the program might just as well select the first word as any of the first ten; in fact, the time spent considering the others is unlikely to be repaid in practice. This is consistent with the observed behav- ior - the performance for an ordered dictionary with min-look set to 1 was uniformly better than if this pa- rameter were set to 10. We feel this to be undesirable for the following reasons: The performance of the program becomes quite brit- tle. If lucky, it will solve a puzzle very quickly; if un- lucky, it may not solve it at all. This is the behavior that was observed on puzzle (d). The program cannot improve its performance on very difficult puzzles by increasing the value of min-look, since this technique has been essentially invalidated by the diet ionary ordering. In addition, further experimentation showed that it was not possible to avoid this problem by segmenting the dictionary or ordering it in any other way (such as maximizing the letter differences between words ap- pearing near each other). We wish that we could make more definitive remarks about this technique, but cannot. 4 Conclusion Summarizing, the conclusions that we have drawn from the experimental data. in Figure 4 are the following: 1. 2. Arc-consistency is needed if difficult constraint- satisfaction problems are to be solved effectively. It is far more efficient to order variables at run time than to use the statistical information available at compile time. 3. 4. It is important to select the instantiation for each variable carefully, although not so important that every choice should be considered in large domains. Backjumping is to be preferred to simple backtrack- ing. In addition, it is important to ensure that subse- quent labels for a particular variable actually address a difficulty that was found previously in the search; this can be done without incurring the prohibitive costs involved in maintaining complete dependency information when the tree is expanded. Acknowledgement The first author is indebted to Greg Arnold, David Smith, Phil Stubblefield, Rich Washington and the stu- dents of his introductory artificial intelligence class for many enlightening discussions. The comments of Rich Korf and one other anonymous referee were also help- ful. References [Dechter, 19901 R ina Dechter. Enhancement schemes for constraint processing: backjumping, learning, and cutset decomposition. Artificial Intelligence, 1990. To appear. [Dechter and Meiri, 19891 Rina Dechter and Itay Meiri. Experimental evaluation of preprocessing techniques in constraint satisfac- tion problems. In Proceedings of the Eleventh In- ternational Joint Conference on Artificial InteZZi- gence, pages 271-277, 1989. [Dechter and Pearl, 19881 Rina Dechter and Judea Pearl. Network-based heuristics for constraint- sat isfact ion problems. Artificial Intelligence, 34:1-38, 1988. [Gas&rig, 19791 John Gaschnig. Performance Mea- surement and Analysis of Certain Search AZ- gorithms. Technical Report CMU-CS-79-124, Carnegie-Mellon University, 1979. [Mazlack, 19761 L awrence J. Mazlack. Computer con- struction of crossword puzzles using precedence relationships. Artificial Intelligence, 7:1--19, 1976. [Stallman and Sussman, 19771 R. M. Stallman and G. J. Sussman. Forward reasoning and dependency-directed backtracking in a system for computer-aided circuit analysis. Artificial InteZZi- gence, 9(2):135-196, 1977. I/ Cheapest I Time Puzzle first min-look Backtrack (set) (4 (b) (4 (4 exact exact exact exact exact stat exact stat stat exact exact exact exact exact exact stat stat stat exact exact exact exact 1 bt 0.505 1 bj 0.533 1 sbj 0.605 10 sbj 0.607 10 bt 0.612 _ sbj 0.693 10 b j 0.719 bj 1.015 bt 1.041 10 bt 2.363 10 sbj 2.453 10 b j 2.497 sbj 4.967 1 bt 6.327 1 bj 6.587 - sbj 17.022 _ b j 17.170 _ bt 31.526 10 sbj 11.904 10 b j 15.539 1 sbj 17.668 b j 17.798 exact 10 sbj 71.693 exact 1 sbj 4oEA555* * Completed on only 8 of 10 attempts Figure 4: Test results; techniques not listed were not able to solve the puzzles in question GINSBERGETAL. 215
|
1990
|
32
|
948
|
Iterative Broadening Matthew L. Ginsberg* and William D. Harvey Computer Science Department Stanford University Stanford, California 94305 ginsberg@cs.stanford.edu Abstract Conventional blind search techniques generally assume that the goal nodes for a given problem are distributed randomly along the fringe of the search tree. We ar- gue that this is often invalid in practice, suggest that a more reasonable assumption is that decisions made at each point in the search carry equal weight, and show that a new search technique that we call iter- ative broadening leads to orders-of-magnitude savings in the time needed to search a space satisfying this as- sumption. Both theoretical and experimental results are presented . 1 Introduction Imagine that we are searching a tree of uniform depth d using conventional depth-first search. We work our way to the fringe of the tree and check to see if we are at a goal node. Assuming that we are not, we back up a minimal amount, generate a new node at depth d, and check to see if that is a goal node. This process continues until we finally succeed in solving the problem at hand. The process of depth-first search generates the fringe nodes (the nodes at depth d) in a particular order - from left to right, if we were to draw the tree in its entirety. Assuming that the goal nodes (of which there may be more than one) are randomly placed along the fringe of the search tree, this left-to-right order is a reasonable way to search the tree. Now imagine that we are trying to solve some hard problem, say buying a birthday present for a friend. We decide to buy her a book on Tennessee walking horses, and visit a few book and tack stores looking for one but without success. At this point, rat her than continue looking for this particular gift, we may well decide to try something else. Even if we have good reason to believe that a book of the kind we want exists, we view our continued failure as an indication that we would be better off looking for a different gift, and end up buying her a saddle pad. *This work has been supported by General Dynamics and by NSF under grant number DCR-8620059. Figure 1: Search with a breadth cutoff If all of the inference steps we might take while solv- ing the problem were equally likely to lead to a so- lution, this would make no sense. But in practice, we view the fact that we have been unable to solve the problem of finding the Tennessee-walker book as evidence that the whole idea of getting the book is misguided. Does this idea have an analog in search generally? It does. The reason is that it is possible to make a mistake. Going back to our tree of depth d, it is quite possible that one of the nodes at depth 1 (for example) has committed us to a course from which there is no recovery, in that this particular node has no goal nodes at all underneath it. The way we deal with this in practice is by impos- ing an artificial breadth limit on our search. Thus we may try three different book stores before giving up and getting our friend something else for her birth- day. What we are proposing in this paper is that blind search techniques do the same thing. Specifically, we will suggest that depth-first search be augmented with an artificial breadth cutoff c. What this means is that when we have had to backtrack to a particular node n in the tree c times, we continue to backtrack to the previous choice point, even if there are still unexplored children of the node n. An example is depicted in Figure 1, where we have shown a tree with breadth 4 but a breadth cutoff of 3; the dashed lines indicate paths that have been pruned as a result. Of course, the search with an artificial breadth cut- off will never search the entire tree; we need some way to recover if we fail to find an answer in our search to 216 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. depth d. We will suggest that the most practical way to deal with this problem is to gradually increase the breadth cutoff. So we first start by searching the tree with an artificial breadth cutoff of 2, then try with a breadth cutoff of 3, and so on, until an answer is found. We will refer to this technique as “iterative broaden- ing,” borrowing terminology from Korf’s notion of it- erative deepening [Korf, 19851. We will show in this paper that given reasonable assumptions about the distribution of the goal nodes along the fringe, this technique leads to tremendous expected savings in the amount of time needed to search the tree. The reason, roughly speaking, is that the searches with limited breadth retain a reasonable chance of finding a goal node while pruning large frac- tions of the complete space and enabling us to back- track past early mistakes more effectively. Even if the preliminary searches fail to find a goal node, the time spent on them is often sufficiently small that overall performance is not much affected. The outline of this paper is as follows: In the next section, we present a mathematical analysis of the tech- nique, computing the utility of a search with breadth cutoff c in a space of branching factor b. In Section 3, we discuss the ratio of the time needed by our ap- proach to that needed by the conventional one for var- ious choices of b and d, and for various densities of goal nodes at the fringe of the tree. We present both theo- ret ical values (which incorporate some approximations made in Section 2) and experimental results. In Section 4, we show that the inclusion of heuris- tic information makes our met hod still more powerful, and also that it remains viable when used in com- binat ion with other search techniques (dependency- directed backtracking, etc.). Related work is discussed in Section 5. 2 Formal analysis Suppose that our tree, of uniform branching factor b and depth d, has g successful goal nodes distributed along the fringe. What we will do is assume that de- cisions made at each point in the search are equally important - in other words, that there is some con- stant s such that if n is a node under which there is at least one goal node, then n has exactly s successful children. (We are calling a node successful if it has at least one goal node somewhere under it.) The fact that s is independent of the depth of n is the formal analog of our claim that decisions made at different depths are equally important. We assume that the s successful children are randomly distributed among the b children of n. Since the root node is successful, it is not hard to see that there are sd goal nodes in the tree as a whole, so that we must have s = g ‘id. In what follows, we will generally assume that s is an integer (so that we can evaluate the expressions that follow), and that s > 1 (so that there is more than a single goal node on the fringe). Now suppose that we fix b, s and a breadth cutoff c. For a given depth d, we will denote the probability that the restricted-breadth search finds at least one goal node by p(d), and the number of nodes examined by this search by t(d). We begin by computing p(d) = 1 - p(d). What is the probability that the search fails to find a goal node at depth d? For d = 0 (the root node), we clearly have ;is( 0) = 0. For larger d, suppose that we denote by pr(i) the probability that of the s successful children of a node n, exactly i of them are included in the restricted search of breadth c. Now the probability that the search to depth d + 1 fails is given by f$d + 1) = x pr(i)p(d)i (1) since in order for the search to fail, the depth d search under each of the i successful children of the root node must also fail. We sum over the various i and weight the contributions by the probability that the i success- ful nodes at depth 1 all actually fail. We can evaluate pr( i) by noting that in order for there to be exactly i successful nodes in the restricted search, we much choose i successful nodes from the s that are available, and also c - i unsuccessful nodes from the b-s available. Since the total number of to choose the c nodes in the restricte b present in the entire tree is given hard to see that d search from the by (,“) , it is not This expression, together with (l), allows us to com- pute p(d) for various d. What about t(d), the number of nodes examined by the restricted search to depth d? We begin by defining t,(d) to be the number of nodes examined on average by the restricted search to depth d provided that the restricted search is successful. We immediately have t(d) = [l - F(d)]&(d) + p(d) (cd;:; ‘> (2) since the complete tree of breadth c and depth d must be searched if the restricted search fails. We also need pr, (i), the probability that exactly i of the depth 1 nodes are successful given that the re- stricted search succeeds. Bayes’ rule gives us prs(i) = pr(ils) = pr(sli)pr(i) = El - p(d - l>ilPr(i> PI+) 1 - WI To complete the calculation, we need to know that if we have c nodes at depth 1, of which i are successful, then the average number of these c nodes we need to examine before finding j of the successful ones is given bY dc + 1) i+l GINSBERG AND HARVEY 2 17 Given that the restricted search is successful, how many of the nodes do we need to examine before find- ing one that is successful with the breadth cutoff c? If i nodes are successful, and each successful node has a probability of failure given by p, then the number of the c nodes we can expect to examine is given by i-l ,. NC + 1) $0 -a I-\ The rationale for this expression is as follows: Each term represents the number of nodes examined assum- ing that the first j successful nodes fail (which happens with probability j? for each) and the j + 1st succeeds. The terms are weighted by l/(1 - 8) because j? is the probability that none of the i nodes succeeds, and this is eliminated by our assumption that the restricted search is successful. Given this result, the number of failing nodes exam- ined at depth 1 is f (i, jj) - 1 and t, (d + 1) is therefore: 1+ ~Pr,(~)fGJ$d)) - 1 &+l - 1 I( ) + km (4) i C-l The first term corresponds to the fact that the root node is always examined; the final term t,(d) is the number of nodes examined below the depth 1 node that eventually succeeds. The summation is, as usual, over the number of successful children at depth 1; for each value of i, we compute the expected number of failing nodes examined at depth 1 and realize that each of these failing nodes leads to a complete search of breadth c and depth d. Using (1) and the expression for t, (d + 1) in (4)) we can easily compute the probability of success and ex- pected time taken for the first pass through the search tree, with breadth cutoff c = 2. Unfortunately, we cannot use these expressions to evaluate the probabilities and time taken for subse- quent searches with c = 3 and higher. The reason is that when we do the search with c = 3, we know that the search with c = 2 has already failed. Assum- ing that we do not reorder the children of the various nodes when we iterate and search the tree again, we need to take the fact that the c = 2 search has failed into account when analyzing c = 3. For f < c, let us denote by $c, f) the probability that the search with cutoff c fails given that the search with cutofl f is known to fail. Now it is obvious that s4 = F(c7 f E(f) so that we immediately have jj(c , f) = FCC) P(f) (5) We also need to do something similar for t. We will assume (wrongly) that the expected number of nodes branching depth factor 4 7 11 15 4 1.9 5.9 19.8 59.9 6 1.7 5.8 20.2 55.2 9 1.4 4.9 17.4 46.7 12 1.2 4.1 14.6 38.7 15 1.0 3.5 12.4 32.6 Figure 2: Performance improvement for s = 2 branching depth factor 4 7 11 15 4 2.9 26.2 451.3 7276.6 6 3.9 30.7 292.3 1990.3 9 3.4 24.3 186.0 928.1 12 2.9 19.0 129.0 559.9 15 2.4 15.5 97.3 390.2 Figure 3: Performance improvement for s = 3 examined during a successful search to depth d is un- changed by the fact that the search with breadth cut- off f has failed. In practice, it is possible to reorder the nodes so that the expected number is less than this. However, this may not be desirable because it will abandon heuristic information present in the orig- inal order; it is because of these competing reasons that we are taking the number to be unchanged. As in (2), this leads to t(c, f) = [l - F(c, f )IW) + Pk, f) rd+l-lJ c-l * The hard work is now done. The expected time taken to solve the problem using iterative broadening is given by xB(i - l)t(i, i - 1) (6) where the term being summed corresponds to the time taken by the search of breadth i, given that the previ- ous search has failed to solve the problem. 3 Results Theoretical Given the results of the previous section, it is straight- forward to compute the expected time taken by an iterative-broadening search and compare it to the ex- pected time taken by a simple depth-first search (i.e., c = b) . The tables in Figures 2 and 3 do this for s = 2 and s = 3 respectively and for various choices of b (branching factor) and d (depth of tree). The numbers appearing in the table are the ratios of these two times and indicate the factor saved by the new approach. (Thus the 15.5 appearing in Figure 3 for b = 15 and d = 7 indicates that iterative broadening will typically 218 AUTOMATEDREASONING solve the problem 15.5 times faster than depth-first search.) It can be seen from these figures that iterative broad- ening outperforms conventional search for s 2 2 and d >_ 4. (For shallower searches, this was not always the case. The worst case examined was s = 2, b = 15, d = 2, when iterative broadening was 0.4 times as fast as depth-first search.) Furthermore, as the depth of search increases, so does the time saved. For large depths and branching factors, it appears that the iterative broadening technique reduces the time needed to solve the problem by an overall factor ap- proximately linear in b and additionally reduces the effective branching factor by s - 1. Note that if s were known in advance, the reduction in effective branching factor could also be achieved by working with a breadth cutoff of b - s + 1, since this breadth cutoff will never prune all of the goal nodes from the search space. Iterative broadening achieves this savings without advance information about the size of s. Additional savings are also obtained because of the possible success of the searches with narrower breadth cutoffs. The large depth limit In the large d limit, it is possible to use these results to determine general con- ditions under which iterative broadening leads to com- putational speedups. As a preliminary, we can use (4) to find the expected time needed by conventional depth-first search, obtain- ing for large d bd+l(b - s) tdf(d) = (b - 1)2(s + 1) The time needed by iterative broadening is bounded by the time needed for complete searches with breadth cutoffs up to b + s - 1. We set E = s - 1 to get Setting t(d) = tdf(d) and solving for E gives us E = b/2d so that s = 1 + E = 1 + b/2d and the number of goal nodes is d = eb/2 Proposition 3.1 In the large depth limit, iterative broadening will lead to computational speedup when- ever the eb/2 . total number of goal nodes at the fringe exceeds Experimental In order to ensure that the approximations made in Section 2 not invalidate our theoretical results, we com- pared the iterative-broadening approach to conven- tional depth-first search on randomly generated prob- lems. The experimental results appear in Figure 4 and depth 1 1.5 ; 2.5 3 3 0.5 0.7 0.8 1.3 1.5 4 0.4 0.8 1.8 2.2 3.3 5 0.5 1.1 2.1 3.4 5.1 6 7 I 0.4 0.9 2.3 3.0 15.2 0.5 1.3 4.7 6.5 19.5 Figure 4: Performance improvement observed for branching factor 6 and small s (100 samples) depth 3 4 5 6 m 1 1.5 ; 2.5 3 0.6 0.8 1.7 1.6 2.3 0.7 1.1 2.7 6.6 5.4 0.9 1.7 4.6 8.7 11.3 0.9 1.5 8.8 18.5 37.9 1.1 2.3 12.1 17.8 45.0 Figure 5: Performance improvement observed for branching factor 6 with heuristic information (100 sam- ples) are in overall agreement with our theoretical expecta- tions. The experimental data also includes values for s other than 2 and 3, since in practical applications a successful node may not have-a fixed number of suc- cessful children. Data is shown for s = 1.5 and s = 2.5, and s = 1 as well. The case s = 1 is exceptional because it leads to ex- actly one goal node. Since this goal node is randomly located on the fringe of the search tree, the fastest search is the one that examines the fringe most rapidly, and we can therefore expect depth-first search to out- perform iterative broadening in this case. At worst, it- erative broadening might be a factor of b slower (since there are b possible iterations); in practice, we observed only a factor of 2. This was roughly independent of the breadth and depth of the search. 4 Heurist ii informat ion The experiment al work described in Section 3 was also extended to consider cases in which heuristic in- formation is used to order the children of any particular node so that subnodes that are likely to lead to solu- tions are examined first. We simulated a fairly weak heuristic that scaled by a factor of 2(b + 1 - i)/(b + 1) the probability that the ith child of a successful node was itself successful. Thus the probability of the first child’s success is approximately doubled and the prob- abilities for subsequent children are scaled by a linearly decreasing amount. The results are reported in Figure 5 and indicate that heuristic informat ion improves the relative performance of iterative broadening with re- spect to standard search techniques. (In fact, for b >5 GINSBERG AND HARVEY 219 and d > 6, iterative broadening is the technique of choice even if s = 1.) These results can be understood by realizing that at any node, both search techniques examine the most likely children first. The consequences of making a mistake are different, however - if depth-first search examines an unsuccessful node near the top of the tree, it will go on to examine the entire subtree of that node at potentially devastating cost. Iterative broadening limits the fruitless search to a subtree of breadth c; the better the heuristic, the more likely it is that a goal will be encountered for small c. Even for the relatively weak heuristic used in our experiments, large relative performance improvements were obtained. Combination with other techniques Finally, we tested the iterative-broadening technique by includ- ing it in a program designed to create crossword puz- zles by filling words into an empty frame [Ginsberg et al., 19901. This program uses a variety of tech- niques, including a heuristic ranking of the children of the node being examined, directional arc-consistency [Dechter and Pearl, 19881, backjumping (a simple form of dependency-directed backtracking) [Gaschnig, 19791 and dynamic search rearrangement. The results were as expected. Performance improved in almost all cases; the single exception was for a 5 x 5 puzzle containing 5 5-letter words in each direction (i.e., no black squares at all). The depth of this puzzle was shallower than for most of the others (there are only 10 words to fill in), the branching factor is very large (due to the large number of 5-letter words in the dictionary) and the solutions are quite sparse in the search space (leading to a very small value of s). As can be seen from Figures 1 and 2, all of these factors combine to reduce the effectiveness of the technique we are proposing. 5 Related work Iterative deepening An attractive feature of iterative broadening is that it can easily be combined with iterative deepening, the most effective known technique for searching trees where the depth of the solution nodes is unknown [Korf, 19851. Iterative deepening works by searching the tree to progressively larger fixed depths; any of these fixed-depth searches can obviously be performed using iterative broadening instead of the simple depth- first search proposed in [Korf, 19851. Parallel search Kumar and Rao have recently suggested that the most effective way to search a tree of the sort we have been examining is to interleave n parallel searches for the first n children of the root node, and have shown that this technique reduces expected search time if the dis- tribution of the goal nodes is nonuniform along the fringe of the tree. This approach works for exactly the same reason as iterative broadening - the cost of making a mistake is minimized. Iterative broadening can be expected to lead to still further improvements, since parallel search cannot address difficulties arising from mistakes made below the first level of the search tree or from damage done if the first n children are all failing nodes. 6 Conclusion Iterative broadening leads to computational speedups on search problems containing in excess of 40,000 nodes if either s > 1.5 (so that a successful node has, on aver- age, at least 1.5 successful children) or there is heuris- tic informat ion available indicating conditions under which a node is likely to lead to a solution. In the large depth limit, speedups can be expected whenever there are at least ebj2 solutions to the problem in ques- tion. Since the size of the fringe grows ex P onentially with the difficulty of the problem (and eb 2 doesn’t), we can expect this condition to be satisfied for almost all problems that admit multiple solutions. The speedups gained by our approach are often sev- eral orders of magnitude; this easily outweighs the cost, which appears to be at most a factor of 2. These the- oretical results are confirmed by experimentation on both randomly generated small problems and the large toy problem of crossword puzzle generation. Acknowledgement We would like to thank Bob Floyd and Rich Korf for various helpful suggestions. References [Dechter and Pearl, 19881 Rina Dechter and Judea Pearl. Network-based heuristics for constraint- satisfaction problems. Artificial Intelligence, 34:1-38, 1988. [Gaschnig, 19791 John Gaschnig. Performance Mea- surement and Analysis of Certain Search Al- gorithms. Technical Report CMU-CS-79-124, Carnegie-Mellon University, 1979. [Ginsberg et al., 19901 Matthew L. Ginsberg, Michael Frank, Michael P. Halpin, and Mark C. Torrance. Search lessons learned from crossword puzzles. In Proceedings of the Eighth National Conference on Artificial Intelligence, 1990. [Korf, 19851 Richard E. Korf. Depth-first iterative deepening: An optimal admissible tree search. Artificial Intelligence, 27:97-109, 1985. 220 AUTOMATEDREASONING
|
1990
|
33
|
949
|
Path-Focused Duplication: rocedure for Sunil Issar Carnegie Mellon University Pittsburgh, Pennsylvania 15213-3890 si@cs.cmu.edu Abstract The mating paradigm for automated theorem provers was proposed by Andrews to avoid some of the short- comings in resolution. It facilitates automated deduc- tion in higher-order and non-classical logics. More- over, there are procedures which translate back and forth between refutations by the mating method and proofs in a natural deduction system. We describe a search procedure, called path-focused duplication, for finding refutations by the mating method. This procedure, which is a complete strategy for the mating method, addresses two crucial issues (inadequately handled in current implementations) that arise in the search for refutations: when and how to expand the search space. It focuses on a particular path that seems to cause an impasse in the search and ex- pands the search space relative to this path in a way that allows the search to immediately resolve the impasse. The search space grows and shrinks dynamically to re- spond to the requirements that have arisen or have been met in the search process, thus avoiding an explosion in the size of the search space. We have implemented a prototype of this procedure and have been able to easily solve many problems that an earlier program found difficult. Introduction Much research in theorem proving has focused on im- proving the efficiency of procedures based on Robin- son’s resolution principle [Robinson, 19651. The mating paradigm for automated theorem provers was proposed by Andrews 1198 11 (and a similar approach called the connec- tion method was suggested by Bibel D9821) to avoid con- verting a well-formed formula (wff) to clause form, which introduces redundancy and impedes analysis of the logical structure of the wff. As remarked by Stickel [19861, so- lutions to really hard problems will always require human assistance in specifying strategies and determining where to search for a solution; the mating method provides an at- tractive framework for this interaction because it retains the logical structure of the wff, and thus it is easier to see what This work was supported by NSF grant CCR-8702699. the search is trying to achieve. According to Bibelll9881, the connection method has another advantage: it is compu- tationally as adequate as resolution and has the potential to do significantly better than resolution. The mating paradigm facilitates automated deductions in higher-order logic [Andrews, 19891 and non-classical logics [Wallen, 19901. Refutations generated by the mat- ing method are the underlying component of the proof presentation procedures in [Andrews, 1980; Miller, 1987; Rfenning, 1987; Pfenning and Nesmith, 19901. These pro- cedures translate back and forth between refutations by the mating method and proofs in a natural deduction system; the two systems can thus serve as cooperating processes, possibly in a semi-interactive environment, with each one of them trying to exploit the advantages of the other. In this paper we focus on two crucial issues that arise in the search for refutations by the mating method: when and how to expand the search space. The procedure path- focused duplication, which is described later, addresses these issues. It focuses on a particular path that seems to cause an impasse in the search and expands the search space relative to this path; this transforms a global problem-how to expand the search space so that the search can succeed in finding a refutation -to a more specific local problem- which quantifier should we duplicate so that a particular impasse can be resolved. As discussed in [Andrews, 19811, we cannot specify a bound on the size of the search space without sac- rificing completeness, and each expansion increases the complexity of the search. (Bibel and his colleagues [Bibel et al., 19831 do provide bounds for some spe- cial cases, but they also note that such bounds do not exist in general, since first-order logic is undecidable.) Search procedures for the mating method [Andrews, 1981; Bibel, 19821 have been based on the level-saturation ap- proach Khang and Lee, 19731: exhaustively search for a refutation in a given wff before generating the expanded wff at the next level. These levels introduce artificial constraints in the search. The search procedures thus suffer from prob- lems similar to the ones that arise in the depth-first approach, for example, the Horizon Effect [Berliner, 19731. Since these problems are caused by the level-saturation approach, we rectify them by incorporating the expansion of the wff WAR 221 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. intrinsically into the search process. Path-focused dupli- cation achieves this objective by eagerly duplicating an expansion node whenever the search seems to have reached an impasse. This could result in extremely large wffs, but we avoid this explosion in the search space by localizing the duplication to the impasse that caused it. Localization is achieved by a dynamically growing and shrinking wff which responds to the requirements that have arisen or have been met in the search process. Just as model elimination [Loveland, 19781 and set of support [Was et al., 19651 are complete strategies for reso- lution, path-focused duplication is a complete strategy for the mating method. Path-focused duplication facilitates the introduction of many features (such as not looking for refutations in which wffs occur more than once without sacrificing completeness) which are mentioned in [Stickel, 19821 into the mating method. The Mating Method We start with a brief review of the mating method [Andrews, 1981; Bibel, 19821. As is customary in theorem proving, we will remove existential quantifiers by Skolemization. The wff can contain any connectives, but we will transform them to disjunctions and conjunctions during translation to jforms (defined below). Since the same literal (an atomic wff or the negation of an atomic wff) can occur at several places in the wff, we will assign a unique label to each occurrence of a literal in the jform. A wff W is rectified iff no variable occurs both bound and free in W and distinct quantifier-occurrences of W bind distinct variables. In this paper we will deal only with the wffs that are rectified. This restriction is not a drawback of our procedures; we consider the problem of how to implicitly rectify a wff to be an important implementation detail, which is adequately addressed in [Issar, 19901. l@l&$ . . . @l, is the result of concatenating the lists 11 , 12 , . . . ,I,. [n] denotes the set {i 11 5 i < n} of positive integers. A ,$ori(junctive form) is a representation as an and/or tree for a wff of first-order logic and is defined by the following BNF expression: n #arm = Literal 1 Qifonn, 1 AgOfWli 1 <Vxlx;? . . .x,> germ i=l i=l We will refer to jforms of the form <Vxlx2 . . . x,> jform as expansion nodes and refer to x1 , x2, . . . ,x,, as the expansion variables at this node. The expansion variables in any jform J are the expansion variables that occur at expansion nodes in J. The terminology expansion nodes and expansion variables was introduced by Miller [1987]. We will refer to expansion nodes by the expansion variables at that node. For example, Vuv refers to the expansion node < Vuv > -Quv V Quu in Figure 1. Jforms are displayed as two- dimensional diagrams called vpforms (vertical path forms). In a vpform the disjunctions are displayed horizontally and the conjunctions are displayed vertically. If x is an expansion variable in a jform J, then Jb Ix] is the result of replacing all occurrences of x by y in J. Let M be an expansion node in J, {Xi 1 i E [n]} be the set of expansion 222 AUTOMATED REASONING variables in the subtree with root node M, {yi 1 i E [n]} be a set of new variables that do not occur in J, and M’ be the result of replacing xi by yi in M for each i E [n]; then M’ is a copy of M. Consider the jform J’ that is obtained from J by replacing M with the jform A MM’. We say that J’ is obtained by a duplication from J; this duplication is almost the same as quantifier duplication in [Andrews, 19811. We also say that we duplicated M in J and denote J’ by J + M’. J* is an amplijication of a jform J iff there exists a sequence J = J1, J2 , . . . , Jm-1, J,,, = s* of jforms such that Ji+l is obtained by a duplication from Ji for each i E [m - 11. We next illustrate these definitions with a few examples: Example 1 l[ [ Rab A VxVy[Rxy > [Ryx A Q~]] A VuVv[Quv > Quu]] r> [Qaa A Qbbll The jform J1 , which is displayed as a vpform, in Fig- ure 1 represents this wff. The labels in this jform refer to the literals that are under them. Vx’y’ is a copy of the expansion node by. J2 is an amplification of J1. Example 2 -[[Pa V Pb V PC] > ElxPx] The jform J3 in Figure 2 represents this wff. J4 is an amplification of J3. The set Paths(J) of paths through a jform J is defined inductively as follows: 1. 2. 3. 4. J = Literal. Then Paths(J) def ( <J > }. J = ~~zI#ormi. Then Paths(J) def uzl Paths(iformi). J = all ~OmZi. Then Paths(J) def {P1@P2@ . . . @Pn IPi E Paths(Ji)). J =<Vxl . . .x,> #arm. Then Paths(J) def (Cr> @P I P E Pathsworm)}. A path through a jform J is an element of the set Paths(J). We will sometimes consider a path to be an ordered set. A partialpath through a jform Jis a subset of a path through J. Our paths differ slightly from the paths in [Andrews, 19811 in that we add expansion nodes to the paths. We could as in [Pfenning, 19871 consider a path to be an element of the set of solution graphs [Nilsson, 19801 in J, but we are mainly interested in literals and expansion nodes, and thus restrict the paths to contain only these elements. To continue with our examples: 1. <Lo,v~,Ll,vuv,L5,L6>isapaththroughJ1. 2. For i E {8,9, lo}, let Pi =<Li,VX, Lll>. Then Paths(J3) = {p8,p9,plo). 3. Paths(J4) = {P@ 4x1, L :1, Vx2, Lf,> 1 P E Paths(J3)). A substitution p is more general or less specijed than a substitution +, denoted by p 5 $, iff there is a substitu- tion 4 such that 4p = $. The relation 5 is transitive. A substitution p is a uni$er of a set 24 of pairs of literals iff (tl , t2) E 24 a ptl = pt2. We will say that 22 is unifiable iff it has a unifier. p is the (essentially unique) most general unifier of 24 iff p is a unifier of 24 and p 5 Q for any unifier cuofU. A connection in a jform J is any unordered pair (L,M) of literals in J which are both on some path in J and have the property that the set ((1L,M)} is unifiable. For ex- J1 = \ vxl vx'y' = Lo Rab Jxy [ Ll +w v 1 Li #q ” RY'X' -Rx’ y’ [ II G Qx’Y’ J2 = Lo Rab hv L4 h 1Quv ’ Quu I vu23 Li L$ -Qu2$ ’ Qu2u2 L6 v L7 VQaa y&b6 1 vx’ Lb [ I 1Px’ if2 G [ I YPx? Figure 1: Vpforms for Example 1 Figure 2: Vpforms for Example 2 ample, (Ls, L7) is a connection in J1 . For any connection C = (L,M), a~ denotes the most general unifier of the set ((lL,M)). A connection (L,M) in a jform J spans a path P through J iff both L and M are on P. Foraset M ofconnect.ions,&I def ((lL,M) I (L,M) E M). A mating M for a jform J is a set of connections in J such that the set UM is unifiable. For example, Ml = {(LO,L1),(L3,Lq),(L5,L6)} is a mating for J1 and {(Lll , Lg)} is a mating for J3. For any mating M, CM is the most gene& unifier of the set UM. A mating M for a jform J spans a path P through J iff there is a connection in M which spans P. A mat- ing M for a jform J is an extension of a mating L for J iff L 2 M. A mating M for a jform J is p-acceptable (path-acceptable) iff M spans all the paths through J. For exw?le9 (&I I, L8h (L: 1, ~591, (Lfl, ho)} is a p-accep~ble mating for J4. A refutation for a jform J is an ordered pair (p , M) such that M is a p-acceptable mating for the amplification J* of J. The mating method for automated theorem provers is a method for finding refutations for a jform J. Andrews [19811 shows that the mating method is sound and complete: Theorem I Completeness and Soundness of the Mating Method Agorm J is unsatisfiable iff there is a p-acceptable mating for some amplification 9* of J. Path-Focused Duplication The task of finding a refutation in the mating method can on the basis of the definition of a refutation be naturally split in two separate subtasks: J3 = J4 = Ls L9 LlO Pa ’ Pb ’ PC 1 vx Lll [ I TPX L8 v Ls v LlO Pa Pb PC I vx 1. Search for a p-acceptable mating for J: enumerate all possible matings for J until either a p-acceptable mating is found or all possible matings have been considered. 2. Replace J by some amplification of J: duplicate some expansion node(s) in J. We consider this duplication to be a global duplication because it affects the entire search as described below. This separation is the basis for the search procedures in [Andrews, 1981; Bibel, 19821 and leads to deficiencies, some of which are outlined by Stickel [19821. Such a search process also violates a basic principle that should be followed by the search strategies; according to Palay [ 19801: If an action needs to be taken sometime in the search then do it immediately. If that action were postponed, unnecessary work may be performed. By taking the action immediately, certain information may be ob- tained that alters the current assumptions of the search, making explorations of other nodes unnecessary. Path-focused duplication is an abstract procedure for finding refutations by the mating method, which incorpo- rates amplifications (step 2 above) within the search process (step 1 above) itself. The above mentioned principle is the basis for this procedure: if a mating cannot be extended to span a path P in the existing search space (we say that the search seems to have reached an impasse), but some progress can be made by duplicating an expansion node, ‘then duplicate immediately instead of postponing this ac- tion. We consider the path P to be the cause for this du- plication. The search space grows and shrinks dynamically to respond to the changing requirements in the search: it ISSAR 223 grows to allow an impasse to be resolved and shrinks so that the amplification does not affect the entire search. Let us look at the drawbacks of global duplication. The objective of the mating procedures is to span all the paths in the tree (jform). This can be done by independent processes-one for each path-which must maintain the compatibility of the substitutions for the shared variables. Each duplication increases the number of elements on some paths and in most cases the number of paths in the tree. For example, duplicating either of the expansion nodes Vxy or VW in Ji doubles the number of paths in the resulting jform and each path has more literals. The global duplica- tions thus seem to require greater overall effort, especially if there is a refutation in a smaller tree, which we did not find because we have not exhaustively searched all smaller trees. We address the resulting dilemma-should we or should we not go for global duplication- by localizing the duplication to the path that caused this duplication: it is as if each independent process amplifies its own copy of the tree, and the other processes are intentionally oblivious to these changes. We illustrate localization with an example: Example 3 Consider the jform J1 in Example 1. The mating M 1 cannot be extended to span the path Q =< LO, Vxy, L2, L3, VW, Ls , L7 >. We will then duplicate one of the expansion nodes, say Vxy. The node Vx’y’ which is a copy of Vxy is displayed in the lower left corner of Figure 1. Because we localize the duplication to Q, we will proceed as if the path Q has been replaced by the following two paths: ~0,v~,L2,L3,vx1y1,L~,vuv,L5,L7> ~0,~~,L2,L3,~~1y1,L;:,L~,~~v,L5,L7> There are 7 other paths in Ji that could also be extended like Q, but we will not extend them. There are 16 paths in Jr + Vx’ y’ ; the effect of localization is that the search space will have only 9 paths after duplicating the expansion node Vxy. The behavior of the search is partially determined by the number and size of the paths in the search space. Dupli- cation causes an explosion in their number. Path-focused duplication attempts to directly control the number and size of the paths in the search space without restricting quantifier duplication; this is where the strength of the procedure lies. We next describe path-focused duplication, which is a procedure for finding refutations in a jform J. We use the state-space representation for this description. A state is a pair (Open, M) where Open is the set of partial paths not spanned by the mating and M is the mating that is being generated. The objective of the search is to find a sequence of operations that starts from the initial state and leads to the goal state. 1. Initial State: (a) Open = Paths(J). (b) M=0. 2. Goal State: Open = 8. 3. Operations. There are two operations which trans- form the states: (a) Extension. Select a connection C on Open such that &/MU {cl is unifiable. some PE i. M c- M U {C} ii. Open t- Open - (P) (b) Duplication. Select an expansion node E on some P E Open. Let Et be a copy of E. This can be a new copy or a copy that was used earlier. Open t- Open- {P)U{P@Q 1 Q E Paths(E We illustrate path-focused duplication with an example: Example 4 Consider the jform J1 in Example 1 (dis- played in Figure 1). We specify a partial control strat- egy: use first-in-first-out (FIFO) to select elements from Open, and always make a new copy of the expan- sion node that is selected in the duplication operation. Figure 3 shows how path-focused duplication found a refutation for Jl. Each row in Figure 3 shows the elements in Open after the operation had been applied and also lists either the connection that was added to M or the copy of the expansion node that was used. If the path selected in a row was already spanned by a connection added in an earlier row, then no opera- tion is shown. We would get the jform J2 (displayed in Figure 1) if the duplications implicit in step 8 and step 10 were explicitly generated. The mating M con- sists of the connections listed in the column marked Connection. (J2, M) is a refutation for the jform J1. Thereare8pathsinJt: <LO,v&&vuv,L4,L6>, ~O,~~,Ll,~~~,L4,L7>r<Lg,~~,Ll,~~v,L5,L6~, ~o,&Y,h,~wkL7>r <Lg,v~,L2,L3,vuv,Lq,L6>, 40, vq,L2,L3, v~v,L4,L7>, <LO,v~,L2,L3,vuV,L5,L6>, 40, vv,L2&3, vuv,‘% ,L7>- For i E [8], let Pi be the ith element in this sequence. Further, let Psi = P& <v+‘,L;>, P82 = P&$ < vdy’,L;,L:>, p821 = Ps2 @ <vU2~, L;> and Ps22 = Ps2 @ <Vu2$, Lz >. All the Pi’s are partial paths in J2. Operation Node Connection Open 0. (Pi 11 5 i < 8) 1. Extension Cl 9 Lo) {Pij2<is8} 2. {Pi13<iL8} 3. {Pi14si<8} 4. (Pi15siz8) 5. Extension (L4, L3) {Pij6<i<8} 6. {Pil7<i<8} 7. Extension (L6,LS) {pd 8. Duplication Vx’ y’ {PSl > p82) 9. Extension (L: 9 L2) {pd 10. Duplication Vu23 (p821, p822) 11. Extension (q, L:) (p822) 12. Extension 0% L7) 0 Figure 3: A Refutation for the Jform J1 in Example 1 224 AUTOMATED REASONING It is proved in [Issar, 19901 that path-focused duplication is a complete and sound procedure for finding refutations: Theorem 2 Consider anytiorm J. Soundness Theorem: If there is a sequence of operations that starts from the initial state and leads to the goal state, then M is a p-acceptable mating for some amplijcation of J. Completeness Theorem: If J is unsatisBable, then there is a sequence of operations that starts from the initial state and leads to the goal state. Let us look at some advantages of path-focused duplica- tion: 1. The number of paths considered by path-focused duplica- tion is in most cases significantly smaller than the number of paths in the search space. For example, there are 32 paths in J2, but path-focused duplication found a refuta- tion by considering only 12 paths. Moreover, 10 of the 12 paths (all except Ps21 and Ps22) were proper subsets of paths in J2. 2. Since the effect of any duplication is local to a path, path-focused duplication can afford to be adventurous and separately try all possible duplications that might solve an impasse. 3. We can easily incorporate the set of support strategy [Was et al., 19651 into path-focused duplication: we assume that the jform is of the form l\Li Ci, we can identify one of the Ci’S to be the goal, and the remaining Ci’S to be the axioms; initialize Open to be the set of paths through the goal, and extend the duplication operation so that it can select the elements in the set of axioms also, in addition to selecting the expansion nodes. The details are provided in [Issar, 19901. 4. Path-focused duplication does not lose any advantages that might be associated with the procedures based on the level-saturation approach, since it can simulate the level-saturation procedures. The level-saturation ap- proach specifies the copies of the expansion nodes that can be used before the search begins. If we restrict the duphcation operation to select only these copies, then the two procedures are almost identical. Status and Future Work We have implemented a first-order theorem prover (without equality) based on path-focused duplication. Some of the key features in the control structure are as follows: e Use the depth-first iterative deepening strategy to control the number of copies of an expansion node. e Always try the extension operation before the duplication operation. e Always make a new copy of the expansion node that is selected in the duplication operation. e If a mating cannot be extended to a p-acceptable mating within the assigned depth, then backtrack to the last state where an alternate connection can be added. We have tested our prover on some problems that are available in the theorem-proving literature. This program is written in CMU Common Lisp, and all experiments were Figure 4: Path-Focused Duplication Figure 5: Path-Focused Duplication vs Level-Saturation performed on an IBM-RT with 12 megabytes memory. Al- though an earlier program for the mating method that was based on the level-saturation approach could not solve most of the benchmark problems from [Chang and Lee, 19731, our program found all of them easy. We could also easily solve the Iirst 46 problems-most of the remaining prob- lems are based on equality-in D?elletier, 19861. The table in Figure 4 presents the results for some problems: the first two problems were taken from [Andrews, 19861, the next three problems were taken from [Andrews, 19811, the sixth problem was taken from [Pelletier, 19861, and the last two problems were taken from [S tickel, 19861. The table in Figure 5 compares the performance of our implementation with that of an earlier program’ which was based on the level-saturation approach. (X2 11 Sa is obtained by minimizing the scope of the quantifiers in X21 15.) We use two measures for this comparison: e Time. Run time for finding a refutation. e Space. Number of bytes that were consed by the program as reported by Lisp. We can get a higher-order theorem prover as in [Andrews, 1981; Pfenning, 19871, which is capable of handling equal- ity also, by replacing the &t-order unification algorithm that is used in this implementation with Huet’s higher-order unification algorithm [Huet, 19751. The implementation mentioned in this section is a prototype whose only ob- jective is to demonstrate the effectiveness of path-focused duplication. There are many strategies described in [Issar, 19901 which can improve the performance of this program, ‘A P rocedure based on the level-saturation approach is im- plemented in TPS [Andrews et al., 19881. We use this pro- gram for gathering data about the performance of level-saturation procedures. 158~~ 225 but which have not been implemented yet. Some strate- gies, which are independent of the control structure, are as follows: o A connection graph [Kowalski, 1975; Andrews, 19811 can be used to aid the extension operation in finding a connection on a path and the duplication operation in selecting an expansion node. o We allow the duplication operation to select any expan- sion node on a path. Some of these nodes may be in- appropriate because they do not have any role in the impasse that necessitated the duplication; we can restrict the duplication operation to disregard such nodes. o The same combination of duplications may arise several times on a path. We illustrate this with an example: sup- pose there are three expansion nodes 1,2, and 3 on a path; the duplication operation may try various permutations of these nodes, for example, (1,2, 3), (1,3,2), and (3, 1,2). We can restrict the duplication operation to avoid this redundancy. We have to be careful, though, because the duplication operation is not commutative, and such a restriction can affect the efficiency of the search. There are other strategies that affect the control structure. An example of such a strategy is to use heuristic information as suggested by Stickel [19861 to perform early cutoffs within a depth and to increment the depth. Some of the strategies in IIssar, 19901 have been imple- mented in a propositional theorem prover; the performance of this prover compares favorably with the performance of the resolution provers. We thus have reason to believe that these strategies will improve the performance of our first-order prover too. Acknowledgements First and foremost I acknowledge Professor Peter Andrews, my thesis advisor. His comments on many earlier drafts and suggestions regarding terminology helped to improve the clarity of this paper. I would also like to thank Frank Pr’enning and Dan Nesmith for many discussions and for their enthusiasm about my work. References Andrews, Peter B.; Issar, Sunil; Nesmith, Daniel; and ‘Pfenning, Frank 1988. The TPS theorem proving system. In 9th International Conference on Automated Deduction, Lecture Notes in Computer Science 3 10. Springer-Verlag. 760-761. Andrews, Peter B. 1980. Transforming matings into natu- ral deduction proofs. In 5th Conference on Automated De- duction, Lecture Notes in Computer Science 87. Springer- Verlag. 28 l-292. Andrews, Peter B. 1981. Theorem proving via general matings. Journal of ACM 28: 193-214. Andrews, Peter B. 1986. An Introduction to Mathematical Logic and Type Theory: To Truth Through Proof. Aca- demic Press. Andrews, Peter B. 1989. On connections and higher-order logic. Journal of Automated Reasoning 5:257-29 1. Berliner, Hans 1973. Some necessary conditions for a mas- ter chess program. In Third International Joint Conference on Artificial Intelligence. 77-85. Bibel, Wolfgang; Eder, Elmar; and Fronhoefer, Bertram 1983. Towards an advanced implementation of the con- nection method. In Eighth International Joint Conference on Artificial Intelligence. 920-922. Bibel, Wolfgang 1982. Automated Theorem Proving. Vieweg, Braunschweig. Bibel, W. 1988. On the comparative complexity of resolu- tion and the connection method. Technical Report BRC- 88-6, University of British Columbia, Vancouver. Chang, C. and Lee, R.C. 1973. Symbolic Logic and Me- chanical Theorem Proving. Academic Press. Huet, Gerard P. 1975. A unification algorithm for typed X-calculus. Theoretical Computer Science 1127-57. Issar, Sunil 1990. Search strategies for general matings. Technical Report Forthcoming, Carnegie Mellon Univer- sity, Pittsburgh. Kowalski, Robert 1975. A proof procedure using connec- tion graphs. Journal of ACM 22:572-595. Loveland, Donald W. 1978. Automated Theorem Proving: A Logical Basis. North Holland. Miller, Dale A. 1987. A compact representation of proofs. Studia Logica 46(4):347-370. Nilsson, Nils J. 1980. Principles of Arti@ial Intelligence. Tioga Publishing Company. Palay, Andrew J. 1980. An experimental analysis of the B* tree searching algorithm. Technical Report CMU-CS- 80-106, Carnegie Mellon University, Pittsburgh. Pelletier, Francis Jeffry 1986. Seventy five problems for testing automatic theorem provers. Journal of Automated Reasoning 2: 191-216. Pfenning, Frank and Nesmith, Dan 1990. Presenting in- tuitive deductions via symmetric simplification. In 10th International Conference on Automated Deduction. To ap- pear. Pfenning, Frank 1987. Proof Transformations in Higher- Order Logic. Ph.D. Dissertation, Carnegie Mellon Uni- versity. Robinson, J. A. 1965. A machine-oriented logic based on the resolution principle. Journal of ACM 12:234 1. Stickel, Mark E. 1982. A nonclausal connection-graph resolution theorem-provingprogram. In AAAI-82 National Conference on ArtiJicial Intelligence. 229-233. Stickel, Mark E. 1986. A PROLOG technology theo- rem prover: implementation by an extended PROLOG compiler. In 8th International Conference on Auto- matedDeduction, Lecture Notes in Computer Science 230. Springer-Verlag. 573-587. Wallen, Lincoln A. 1990. Automated Proof Search in Non-Classical Logics: EfBcient Matrix Proof Methodsfor Modal and In tuitionistic Logics. The MIT Press. Wos, Lawrence; Robinson, George A.; and Carson, Daniel F. 1965. Efficiency and completeness of the set of support strategy in theorem proving. Journal of ACM 12:536-541. 226 AUTOMATEDREASONING
|
1990
|
34
|
950
|
Consistent Linear S eedups to a First Solution in Parallel State-Space Search* Vikram A. Saletore and L. V. Kal6 Department of Computer Science, 1304 West Springfield Avenue, University Of Illinois at Urbana-Champaign, Urbana, Illinois 61801, USA email: saletore@cs.uiuc.edu and kale@cs.uiuc.edu Abstract Consider the problem of exploring a large state- space for a goal state. Although many such states may exist, G.nding any one state satisfy- ing the requirements is sufficient. All methods known until now for conducting such search in parallel fail to provide consistent linear speedups over sequential execution. The speedups vary between sublinear to superlinear and from run to run. Further, adding processors may some- times lead to a slow-down rather than speedup, giving rise to speedup anomalies. We present prioritizing strategies which yield consistent lin- ear speedups and requires substantially smaller memory over other methods. The performance of these strategies is demonstrated on a multi- processor. 1 Introduction Consider the problem of searching for a solution in a large state space, starting from a given initial state. The state space is usually structured as a tree, with op- erators that can transform one state ‘node’ to another forming arcs between different states’. In a large class of such problems, the computations tend to be unpre- dictably structured and have multiple solutions. The desired solution is usually specified by certain prop- erties, and any state satisfying these properties is an acceptable solution. Sometimes one is interested in op- timal solution(s) based on certain cost criteria. How- “This research has been supported in part by the National Science Foundation under grant number CCR-89-00988. ‘When it is possible to go from one state to another via two distinct sequences of operators, the state-space is a graph rather than tree. However, we will confine ourselves to state-space trees in this paper. ever, many times, one is interested in just any solu- tion. We focus on parallel exploration of search spaces in the latter context. This is an important problem: search is a major computational paradigm in Arti- ficial Intelligence. For AI to achieve its long term, ambitious ‘objectives, it seems clear that it must use parallel processing techniques [Halstead 19861. Sec- ondly, many ‘real-life’ applications such as Planning (plan construction), Symbolic Integration, VLSI Test Generation, Theorem Proving, etc. require finding an adequate solution rather than an optimal one. A parallel scheme must be able to consistently gen- erate a solution faster than the best sequential scheme, and preferably close to P times faster, where P is the number of processors used. Also, speedups must in- crease monotonically with the addition of processors. Another important performance criteria is the amount of memory required to conduct a search, which may vary from a linear to an exponential function of the depth of the tree. With parallel processing, it may also increase proportionately to P. 2 Search Techniques A sequential depth-first search begins by expanding the root of a pure OR tree and can be efficiently im- plemented using a last-in-first-out (1;IFO) stack of ac- tive nodes. The advantage of the sequential stack based depth-first search over other search techniques is its linear storage requirement O(BD) whereas for best-first and breadth-first searches, it is exponential O(BD) [Pearl 19851 f or a tree with branching factor B and depth fi. A parallel stack based search algorithm is an extension of the serial algorithm that uses either a shared global stack or multiple stacks. In the shared stuck model, all processors share a global stack. Processors pick up nodes from the shared stack and expand them and push the descendents SALETOREANDKALB 227 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. back onto the stack. In Kumar and Rao’s multiple stack model [Kumar & Rao 19871, a processor is ini- tially given the root node. A stack splitting scheme is used to distribute work. Processors search dis- joint parts of the search space using their local stack in a depth-first manner. They report speedups in [Kumar & Rao 19871 that range from 3.46 to 16.27 us- ing 9 processors for the first optimal solution to a 15- Puzzle problem using Iterative Deepening A* (IDA*) [Korf 19881 algorithm ’ on a shared memory multi- processor. The inconsistency in the speedups is due to the anomalies that exist in parallel stack based search. The reason for speedup anomalies is that the parallel search may expand fewer or more nodes than a serial search. In a multiple stack model, since processors search disjoint parts of the search space asynchronously, anomalies are possible because a processor may find a solution by searching a smaller or larger search space than the space searched with a sequential search. In a shared stack model as all processors run asyn- chronously, the set of nodes that are picked up for execution and put back on the stack may be very different from run to run as well as from the one processor case. This randomness in the selection of nodes is exactly the reason for anomalies reported in [Lai & Sahni 19841. Therefore, both uccelerution anomalies (speedup greater than number of processors P) and deceleration unomuZies (decrease in speedup with increase in P) are possible. Also, there is no guarantee that the work performed by the addition of a processor will contribute in finding the first solution and such work may generate more futile work for other processors. To determine the worst case memory required for the multiple stack model, consider a search tree of uniform branching factor B and depth D. The mem- ory needed for the search will be proportionate to the worst case sum of the individual stack lengths of all the P processors in the system. Initially a processor picks up the root node and expands into its B descen- dents that are put on its local stack. Idle processors will try to get untried nodes from this processor. A breadth-first search will ensue until each processor is assigned to one active node which occurs at a depth of pogB Pl when there are P active nodes in the system. Each processor now conducts a depth-first search of subtree of depth (D - pogB PI). The maximum stack length for the system is given by: Stuck Length,,,t Ease = P * D * (B - 1) 2Each iteration of the IDA* algorithm is essentially a depth- first search of the cost bounded search space such that the first solution found is also one of the optimal solutions. ~pooolo pooooo p00001 Figure 1: Or Tree with Bit Vector Priorities. Assuming a constant node size, the memory needed for parallel search is roughly proportional to the prod- uct of P, B, and D. For a shared stack model, a breadth-first search may continue until a depth of /logB P] is reached. From this point onwards P processors may pick P nodes at level i from the stack and put P * B newly created nodes at level i + 1 back on the stack, an increase of P * (B - 1) nodes at each successive iteration. The worst case stack length for a shared stack model is given by an expression identical to the one above. A Priority Based Search We associate priorities with work in a parallel search and show how this would eliminate the anomalies and achieve linear speedups to a first solution. In a pure search, any of the alternatives at a choice point may lead to a solution. The alternatives may be ordered left to right, either using any local (value ordering) heuris- tic if available or using the default order. In a sequen- tial depth-first search, a subtree under a node on the left is explored completely before expanding a node on the right. Thus, it gives higher priority to nodes (al- ternatives) on the left than the nodes on the right. In the context of first solution, the work to the right of the solution path does not contribute to the solution and therefore constitutes wasted work. To obtain con- sistent speedups with parallel search, we try to focus the search effort towards first solution by giving pri- orities to the alternatives at a choice point, with left- most alternative having the highest priority (Work on other alternatives or speculative work can only speed up the solution to the problem if work under left sub- trees fails to find a solution; otherwise, it constitutes wasted work.). Also, to mimic sequential order of node expansions, we must assign priorities such that every descendent of a leftward node has higher priority than all the descendents of rightward nodes. A priority bit vector (also referred to as priority vec- tor) is a sequence of bits of any arbitrary length. Prior- ities are dynamically assigned to the nodes when they are created. A node with a priority vector PI is de- 228 AUTOMATEDREASONING 0 First Alternative 0 Remaining Alterna. Figure 2: Binary Decomposition of a Search Tree. Work Done to reach First Solution Figure 3: ‘Broom Stick’ sweep of a search tree. fined to be at a higher priority than another node with priority Pz if PI is lexicographically smaller than P2. Consider the OR tree in Figure 1. Let the root of this subtree R, have a priority p represented as a bit vector. The root node of the entire search space is as- signed a null (priority bit vector of length 0) priority at the start of the search process. The m (m=4) chil- dren of the node R representing the m alternatives are assigned priority bit vectors by extending the parent’s priority based on their rank. The rank of an nth child among its m siblings is represented as an encoding of n as a pogml bit binary number. The priority vec- tor of a child node is obtained by appending its rank to its parent’s priority. Priorities assigned this way have the prefix property: no two children of a node have priority such that one is a prefix of the other (The idea of associating a similar sequence using path numbers with nodes of an OR trees has appeared in [Li & Wah 19861). Assigning bit vector priorities this way achieves two goals. (a) The relative priority (rank) of the sibling nodes preserves the left to right order of the sibling nodes. (b) Appending the priority of the child to the priority inherited from its parent ensures every descen- dent of a high priority node gets higher priority than all the descendents of low priority nodes. This reflects the policy that until there is no prospect of a solu- tion from the left subtree beneath a node, the system should not spend its resources on the right subtrees, unless there are idle processors. I.e. if for a time pe- riod, if the work available in the left subtree is not sufficient to keep all the processors busy, the idle pro- cessors may expand the right subtrees. But as soon as high priority nodes become available in the left sub- tree, the processors must focus their efforts in that left subtree. For example, if two processors search the tree in Figure 1 then nodes A and B are picked up for ex- ecution once node R is expanded. When nodes A and B are expanded the processors explore nodes E and F (of higher priority) in the next cycle. With priorities some acceleration anomalies are pre- served because it is possible that when there is not enough work in the left subtree, processors that are exploring the right subtrees may find a solution faster. Also, since processing effort is always focussed left- ward, the parallel search behaviour is similar to that of sequential search. This results in a decrease in wasted work and elimination of deceleration anomalies. As the wasted work is decreased to an insignificant pro- portion (see Section 3.2) this prioritizing strategy pro- duces monotonic, almost linear, speedups. The use of priorities to nodes requires the need for an efficient priority queue management, which can other- wise become a bottleneck if a large number of pro- cessors are used. We use grain size control to de- crease the number of accesses to a shared queue and to spread the overhead of parallelisation. In terms of processing time the avera e Total Sequential Execution 4 grain size is defined ime as Total Number of Messages Procerred’ The ideal grain size for a shared memory system depends on the actual overhead involved in fetching nodes from the queue, creating parallel tasks and depositing new nodes back into the queue. Granularity control is used to de- termine when to stop breaking down a computation into parallel computations at a frontier node, treat- ing it as a leaf node and executing it sequentially. A simple technique to control grain size, in state-space search, is to decide a cut-off depth beneath which the region is explored sequentially. Other techniques that attempt to gauge the size (granularity) of subtrees be- neath a node are also possible. We found that such simple techniques were sufficient to prevent the prior- ity queue from being a sequential bottleneck (see Sec- tion 4). With a large number of processors one may increase the grain size to maintain the frequency of access to the shared queue. To retain similar speedup properties the grain size and the number of granules must both increase propor- tionally with the number of processors P, therefore, the overall problem size will have to increase with P2. This can be alleviated somewhat by using concurrent heap access techniques. More important, as absolute adherence to priorities is not essential, techniques such as multiple heaps are also possible. 3.1 Binary Decomposition The worst case stack length for prioritized search with a shared queue is given by the same expression as that SALETOREANDKAL~ 229 for a parallel stack based search -namely P * D * (B - 1). This is because there cannot be more than P * B available nodes at any level in the tree, and like the single-stack, this upper bound can be realised by having the P processors pick up the leftmost P nodes at each level, in lock-step. A depth-first sequential algorithm selects the cur- rent left most unexplored node at each level of the search space, backtracking to the choice point for re- maining alternatives if no solution is found from the current alternative. In a parallel processing context, one can mimic this behaviour by generating the first descendent node say A in the usual manner, and lumping the work for generating remaining descendent nodes (2,3, .., b) ’ t in o a single lumped-node B (see Fig- ure 2). When this lumped-node is picked up for ex- pansion, it generates the next sibling node E and a lumped-node F that lumps work for generating the rest of the sibling nodes (3,4, .., b). Thus, the lumped- node represents the remaining available parallelism in the subproblem in a form that is extractable when- ever needed. This binary decomposition technique re- duces an arbitrarily large branching factor to 2. (We have increased the depth of the tree towards right by this, but if the solution is much closer to the left in the search tree, as is frequently the case, this ef- fect is small. Other techniques can be used to limit the depth with binary decomposition). Another ad- vantage is that since the descendents of a node are not produced until needed, the wasted work is fur- ther reduced. (The lumped nodes are analogous to the choice-points used in OR-parallel Prolog systems e.g. [Hausman et al. 19871.). Although we have reduced the parallelism in the ini- tial stages of the search but once the number of nodes become greater than the number of processors, the available parallelism is more than sufficient to keep all processors busy. 3.2 Delayed Release Although associating priorities eliminates anomalies, the memory requirement is still proportionate to P as given by the expression earlier. In both, stack and pri- ority based models the increase in the memory usage with number of processors occurs because of the avail- ability of large number untried alternatives at each level of the search. This immediate availability of par- allelism at shallower levels in the search space is the major cause for increased memory usage. Notice that in the worst case all P processors pick nodes at level I, produce B *P (or 2 *P for binary decomposition) chil- dren at level I+ 1, and proceed to pick P nodes at level I + 1. To avoid the worst case, processors must skip intermediate levels. To achieve this, the parallelism in the problem available at shallower levels of the search space should be delayed and nodes at deeper levels of the search space should be made available to pro- cessors first. This bottom-first strategy gives rise to a search behaviour shown in Figure 3 termed the Broom Stick sweep. The set of searched nodes is represented in figure by a long narrow stick and the parallelism (ac- tive nodes) exploited at the bottom of the tree gives rise to the broom effect. We achieve this broom stick behaviour by a tech- nique called Delayed Release. The search begins at the root in the usual manner. When a node is ex- panded, all its children except the leftmost child are put in a list accessible only from the leftmost child. This list is local to the leftmost node and the nodes in the list are not available to other processors at the time they are generated. Also, the local list inherited by a node (parent node) is appended to the local list of its leftmost child. Therefore, each processor effec- tively creates only one child when a node is expanded, which is inserted into the shared priority queue. The search continues this way until a leaf node is encoun- tered when all the nodes kept in the list are released as active nodes and made available to be picked up by other processors, subject to priorities, as before. This has the effect of delaying the availability of shal- lower nodes and making available the higher prior- ity nodes to other processors from the bottom of the search space. Figure 4 shows the state of a search tree using de- layed release technique. When node R is expanded, only one super-node consisting of the linked list [Ll, RI] is produced. When this super-node is picked up, only the first node on the list, Lr, is expanded, and one super-node [L2, R2, RI] is released. Eventu- ally, when the super-node [A, B, Rg, R+ Rs, R2, Rx] is picked up for expansion, it is discovered that node A is a leaf, and so all the nodes in the list are released as individual nodes. Processors in the system now pick the highest priority nodes and explore the search space in a similar fashion. (Note that this delayed the ex- pansion of the shallower, low priority node RI .) With the current state of the search tree depicted, nodes A, B, C, D, E, R2, and RI form the set of frontier nodes. The bit vector priorities ensure that the leftmost P nodes are picked up for execution. The delayed release technique achieves the following three objectives. (a) Most significantly, since processors are forced to skip node expansions at intermediate levels and focus on the nodes deeper in the tree, the wasted work is elimi- nated almost completely thus yielding linear speedups. (b) The memory required by the search algorithm is reduced considerably, as supported by empirical data. 230 AUTOMATEDREASONING poooooo p000001 Figure 4: Tree expansion using delayed release technique and bit vector priorities. 20 0 0 16 e ; 12 e : E 8 4 9 Binary Decomp. (BD) (Priorithed) BD Delay. Release (Prioritiee BD Delay. Partial Rel. (Pri / Seq. Exe. Time 201 Sets. J Sequent Symmetry 0 I I I I 0 4 8 12 16 20 Number of Processors Figure 5: 126-Queens: First Solution Speedups. (c) Since the number of active nodes in the priority queue at any time is reduced the overhead of managing the queue is reduced. In the above strategy when a processor picks up a leaf node it releases all the nodes created and stored thus far in the local list of the leaf node. If the number of nodes released is larger than P, then the nodes in excess of P released constitute excess parallelism that can not be exploited at the time of release. In the delayed partial release technique, when a leaf node is encountered, the processor releases a maximum of P highest priority nodes and a single node that comprises the remaining nodes. If an idle processor cannot find other high priority nodes it expands the node compris- ing the excess nodes and proceeds in the usual manner. This technique does not result in a reduction in mem- ory space, since memory space is still needed to store the m-released excess nodes in a list. However, since now there are even fewer entries in the queue than the delayed release strategy, the overhead of managing and restoring the priority queue is further reduced. 4 Multiprocessor Perfor We implemented the above search techniques for par- allel search on Sequent Symmetry shared memory mul- tiprocessor with up to 20 processors and studied their performance. The parallel search strategies were im- plemented using the Chare-Kernel [Kale 19901, a ma- chine independent parallel programming system that currently runs on several multiprocessors. We present performance data on a few state-space search prob- lems. Speedup performance is obtained by comparing to the best sequential program for the problem. Nodes Expanded on Sequent Symmetry PEs 1 (seq) 4 8 16 18 BD 35248 35574 36164 36795 36944 BD-DR 35248 35306 35601 36229 36507 BD-DPR 35248 35357 35644 36219 36448 BD: Binary Decomposition (BD) BD-DR: BD Delayed Release BD-DPR: BD Delayed Partial Release Table I: 126-Queens: Number of Nodes Expanded. In the N-Queens problem the goal is to place N non-attacking Queens on a NXN chess-board. This problem has a large number of solutions where any one solution may be acceptable. We obtained performance data for the 126-Queens (N=126) problem. N was chosen to be large to show that such a large problem can be solved within a reasonable amount of memory usage and time. Binary decomposition technique of Section 3.1 was used since a complete decomposition at every level resulted in memory overflow. The speedup plots in Figure 5 show that with bit vector priorities the wasted work is reduced result- ing in linear, clearly monotonic speedups. The perfor- SALETOREANDKALI? 23 1 2400 M a X 2000 2 1600 e U e 1200 L ii g 800 il 400 equent Symmetry 0 4 8 12 16 20 Number of Processors Figure 6: 126-Queens: Maximum Queue Lengths. mance data is obtained from a single run of the 126- Queens problem and is highly consistent over different runs. The multiple stack strategy yields speedups that varies from run to run, as documented by Kumar et al. in [Kumar & Rao 19871. The speedups with the shared stack also varied wildly between highly super- linear (few seconds) to extreme sublinear (aborted af- ter few hours) and so are not reported here. Table I shows the total number of nodes expanded for the three schemes using bit vector priorities. It shows that (a) with priorities, the work with P processors is not significantly more than with 1 processor (e.g. an in- crease of 3.57% node expansions over sequential search with P = 18 using delayed release technique.) and (b) the wasted work is reduced with delayed release tech- niques. The plots in Figure 6 show that for a LIFO stack the maximum queue length (thus, the memory usage) increase proportionately to the number of pro- cessors P. This dependence on P is eliminated with the delayed release technique. With delayed partial release technique, the queue length decreases further (the memory usage remains unchanged for reasons ex- plained in Section 3). In a Knights-Tour problem, the knight must visit each position on a NXN chess board once and return to its starting position. Many solutions exist for the knights-tour problem. Speedups obtained were highly consistent from run to run, and increase linearly, as shown in Figure 7. In the Magic Square problem the goal is to place integers from 1 to N2 on a NXN square board such that the sum of the integers along any row, column or diagonal is identical. Figure 8 gives the speedups to first solution to the problem with N = 6. The speedups improve with delayed release strategies. Again, the data reflects performance from a single run and is very consistent over different runs. 20 16 4 a Full Decompositio o Binary Decomp. ( o BD Delay. Release D BD Delay. Partial Seq. Exe. Time 108 Sets. Sequent Symmetry -I 0 4 8 12 16 20 Number of Processors Figure 7: 8X8 Knights-Tour: 1st Solution Speedups 5 iscussion We demonstrated the effectiveness of priority based parallel search techniques to eliminate anomalies and obtain consistent linear speedups to first solution in state-space searches. To the best of our knowledge, no other method proposed to date consistently achieves monotonically increasing speedups for a first solution. Our techniques also reduce the memory usage and it does not increase with the number of processors. It may be argued that this is unimportant as the amount of memory available grows linearly with the number of processors. However, this argument misses the point: on a P processor system our scheme requires a small fraction of the memory required by a stack based scheme. With 18 processors, l.Z&Queens required 0.4 MBytes of memory compared to 1.8 MBytes with a shared stack. With a large number of processors and large problems, our scheme will be able to solve prob- lems that the stack based scheme cannot solve due to a memory overflow. An advantage of our scheme is that it adheres to local value-ordering heuristic, which are very impor- tant for first solution searches. Nowever, even when good ordering heuristic is not available, our scheme is still valuable, because of its consistent and monotonic speedups. Recently, Rao and Kumar have derived an inter- esting result in [Rao & Kumar 1988] concerning the multiple-stack model for parallel search, where the so- lution density are highly non-uniform across the search space. Although the speedups are anomalous, they show that on the overage (i.e. averaged over several runs), the speedups tend to be larger than P, com- pared with the standard backtracking search, where P is the number of processors. In such types of search spaces our result is still valuable for the following rea- 232 AUTOMATEDREASONING 16 e 4 12 Number of Processors Figure 8: 6X6 Magic Squares: 1st Solution Speedups. sons. First, the prioritizing scheme we presented en- sures speedups close to P in all runs, and for varying values of P (assuming, of course, that there is enough work available in the part of the search tree to the left of the solution). Second, their results also show that the ‘superlinearity’ of speedup is not further enhanced beyond a few processors. Therefore, in a system with many processors we can exploit the non-linear solution densities better by setting the priorities of the top few nodes in the search tree to be null (i.e. empty bit vec- tors). This retains the advantage of exploring different regions of the search-space, hoping to exploit the non- uniform solution densities (probabilities) while still fo- cusing the processors within these regions for more consistent speedups. The use of priorities effectively decouple the par- allel search algorithm from the scheduling strategy [Kale & Saletore 19891. (In contrast, schemes such as [Lusk et al. 19881 for OR-parallel execution of Pro- log use an explicit tree representation shared by all processors). This decoupling has several advantages. Scheduling strategies can be chosen independently of the search algorithm itself and synchronisation is much simpler. Most important, the prioritisation strategies can be extended to distributed memory machines such as the Intel iPSC/2 and BBN Butterfly, by provid- ing a priority-balancing strategy in conjunction with the load balancing scheme. We are developing such a strategy. We have extended these techniques for for Parallel IDA* in [Kale & Saletore 19891. The extensions were needed because IDA* involves a series of increasing depth-first searches. Problem reduction based prob- lem solving and Logic Programming are related areas in which, frequently, one is looking for one solution while many solutions may exist. However, this is sub- stantially more complex situation than the pure state- space (OR-tree) search, if AND-parallelism is also to be exploited. The techniques developed in this paper can be incorporated beneficially in such schemes with appropriate modifications. Acknowledgements We would like to thank anonymous referees for im- proving the quality of the paper. We also thank Ross Overbeek at Argonne National Lab. for providing ac- cess to the Sequent Symmetry multiprocessor. [Halstead 19861 Walstead R. 1986. Parallel Symbolic Computing, IEEE Computer. [Hausman et al. 19871 Hausman B., Ciepielewski A. and Haridi S. 1987. OR-Parallel Prolog Made Effi- cient on Shared Memory Multiprocessors, Proceed- ings of the Symposium on Logic Programming. [Kale 19901 Kale L.V. 1990. The Chare-Kernel Paral- lel Programming Language and System, Proceed- ings of the International Conference on Parallel Processing. Forthcoming. [Kale & Saletore 19891 Kale L.V. and Saletore V. A. 1989. Parallel State-Space Search for a First So- lution with Consistent Linear Speedups, Technical Report UIUCDCS-R-89-1549, Dept. of Comp. SC., Univ. of Illinois at Urbana-Champaign. [Korf 19881 Korf R. E. 1988. Optimal Path-Finding Algorithms, Search in Artificial Intelligence, 223- 276. Kanal L.K., Kumar V. eds. [Kumar & Rao 19871 Kumar V. and Rao V. N. 1987. Parallel Depth First Search, International Journal of Parallel Programming. 479-519. [Lai & Sahni 19841 L ai T.H. and Sahni S. 1984. Anomalies in Parallel Branch-and-Bound Algo- rithms, Communications of the ACM. 594-602. [Li & Wah 19861 Li G.J. and Wah B.W. 1986. How Good are Parallel and Ordered Depth-First Searches, Proceedings of the International Confer- ence on Parallel Processing. [Lusk et al. 19881 Lusk E., Warren D.H.D, Haridi S. et. al 1988. The Aurora OR-parallel Prolog System, Fifth Generation Computer Systems. 819-830. [Pearl 19851 Pearl J. 1985. Heuristics: Intelligent Search Strategies for Computer Problem Solving, Addison- Wesley, Inc. [Rao & Kumar 19881 Rao V.N. and Kumar V. 1988. Superlinear Speedup in State-Space Search, Pro- ceedings of the Foundation of Software Technology and Theoretical Computer Science. SALETORE ANDKALI? 233
|
1990
|
35
|
951
|
Inductive Synt quat ional Nachum Dershowitz Eli Pinchover Department of Computer Science Department of Mathematics University of Illinois and Computer Science Urbana, IL 61801, U.S.A. Bar-Ilan University nachum@cs.uiuc.edu Ramat-Gan 52100, Israel Abstract An equational approach to the synthesis of functional and logic programs is taken. Typically, a target pro- gram contains equations that are only true in the stan- dard model of the given domain rules. To synthesize such programs, induction is necessary. We propose heuristics for generalizing from a sequence of deductive consequences. These are combined with rewrite-based methods of inductive proof to derive provably correct programs. a survey of rewriting, see (Dershowitz & Jouannaud 1990); for completion and its applications, see (Der- showitz 1989). Consider the following toy system S for addition and doubling (d) of natural numbers in unary notation: x+0 + x x + S(Y) + s(x+y) d(x) + x+x Introduction Various approaches to the automated synthesis of com- puter programs have been taken; see (Barr & Feigen- baum 1981-1982, Chap. X). In particular, deductive methods have been used to derive executable pro- grams from formal specifications; early examples of such an approach include (Burst all & Darlington 1977; Manna & Waldinger 1979). Inductive, example-based methods have also been applied to this task; a survey of this approach is (Smith 1980); more recent work in- cludes (Shapiro 1983). In this paper, we employ both deductive and inductive methods of inferring provably correct programs. This work differs from most others in combining syllogistic and heuristic approaches and in using mathematical induction to formally verify hy- potheses drawn by inductive inference. It is similar in spirit to some methods used in automated deduction, notably (Boyer & Moore 1977). Such a pattern-directed program is used to compute by replacing instances of a left-hand side pattern (the x and y are variables) with the corresponding instance of the right-hand side. The term d(s(0)) + s(O), repre- senting the expression 2* l+ 1, may be rewritten by one application of one rule to (s(0) + s(0)) + s(O), since the third rule matches the subterm d(s(O)), with x = s(0). It could alternatively be reduced to s(d(s(0)) + 0), ap- plying the second rule to the whole term, with x = d(s(0)) and y = 0. C on t inuing in any manner (we treat rewrite systems as nondeterministic programs), eventu- ally results in the irreducible term s(s(s(O))), standing for the numeral 3. We say that s(s(s(0))) is a normal form of the input term d(s(0)) + s(0). Consider now the following recursive program R, which does not use addition for doubling: In (Dershowitz 1982; Dershowitz 1985a), it was pro- posed that equations be used both as specification lan- guage and as target programming language within a synthesis system. In the equational paradigm, pro- grams are expressed as sets of directed equations, called rewrite systems, and are executed using two mecha- nisms: rewriting (reduction) for the functional aspect and narrowing (a restricted form of paramodulation) for the “logic” aspect. As inference engine, these pa- pers suggested using the completion procedure (Knuth & Bendix 1970). This completion-based approach to synthesis has since been pursued in (Kodratoff & Pi- card 1983; Perdix 1986; Reddy 1989) and has been compared to the fold/unfold method of (Burstall & Darlington 1977) in (Fronhofer & Furbach 1986). For x+0 --j 2 x + S(Y) + s(x +d d(0) --j. 0 d(sW ---) +wm System R enjoys four important properties, two intrin- sic and. two vis-a-vis its specification S: (1) R is ter- minating, i.e. for no input term is an infinite sequence of rewrites possible; (2) R is ground confluent, i.e. any variable-free term has at most one normal form; (3) R is correct with respect to S, in the sense that terms are only rewritten to terms that are “equal” according to 5’; (4) R is complete with respect to S, in the sense that any two variable-free terms that are equal according to S are also equal according to R. In general, we demand that all synthesized programs meet these requirements. Section 2 describes the synthesis of deductive con- sequences of a specification like S. As we will see, deduction alone may produce an infinite program for ' 234 AUTOMATED RJZASON~VG From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. S. This leads, in Section 3, to the use of rewriting- based induction techniques to derive the finite program R from a finite subset of the deductive consequences of S. Rewriting-based inductive proofs, called “proofs by consistency” or “inductionless induction”, were pi- oneered by (Musser 1980). It is the use of heuristics for generalizing from a sequence of deductive conse- quences and then establishing the correctness of the conjectured program by formal inductive techniques that distinguishes this work from previous deductive approaches to program synthesis. A similar approach has independently been taken in (Jantke 1989b). Deductive Synthesis The programs we consider in this paper are all in the form of systems of rewrite rules. Rewrite rules are given to the Prolog system as assertions, like rule(add(X,O),X) for the rule x + 0 + 2. A simple Prolog interpreter of rewrite programs finds normal forms of input terms. (For things to work right, we take it for granted that “occur-checks” are performed whenever necessary, as can be done in PTTP (Stickel 1986).) With asserted rules cor- responding to the program S given earlier, Pro- log solves goals like rewrite(add(d(s(0)) ,s(O)) ,Z>, meaning, “What are the terms Z to which the in- put term add(d(s(0)) ,s(O)) rewrites?” The fi- nal answer in this case is the normal form Z = s (s (s (0) ) > . Moreover, Prolog can solve goals like rewrite(add(d(Y) ,s(O)) ,s(s(s(O))>), in which a free (“logic”) variable occurs in the term being rewrit- ten, to obtain a solution s(s(0)) as a value of Y that makes add(d(Y) ,s(O)) rewrite to s(s(s(0))). The same program S may be used for subtraction or halving, much like Horn-clause programs may be used to solve for free variables. Instead of using just pattern-matching to locate a potential rewrite, unifi- cation is used to make the rewrite possible. To solve the goal equation d(z) + s(0) = s(s(s(0))) for z, one looks for a (nonvariable) subterm of the goal that uni- fies with a left-hand side of S. (Variables in goals and rules are always treated as disjoint.) After applying the most general unifying substitution to the goal, the enabled step is made. This two-step (unify-rewrite) process is called narrowing. The use of narrowing as operational semantics for programming with equations was first suggested in (Dershowitz 1984) and is com- pared with other approaches in (Reddy 1986). In our case, the subterm d(z) is an instance of the left-hand side of the third rule, and the goal is rewrit- ten to (z + z) + s(0). (Rewriting is a special case of narrowing in which unification is “one-way” and no substitutions need be made in the goal.) Rewrit- ing twice more, with the second rule followed by the first, gives s(z + z) = s(s(s(0))). Letting z = 0 al- lows the first rule to fire, narrowing the goal to the irreducible, un-narrowable, and unsatisfiable subgoal s(0) = s(s(s(0))). H ence, alternative narrowings must be explored. In this case, we can let z = s(u), instead, yielding the subgoal s(s(s(u) + u)) = s(s(s(0))). Let- ting u = 0, now, gives s(s(s(0))) = s(s(s(O))), the two sides of which are identical. Thus, the solution discov- ered by narrowing is z = s(u) = s(0). The basic deductive mechanism we employ in syn- thesis is completion (Knuth & Bendix 1970). Critical pairs are equations that are deductive consequences of pairs of rules, formed by unifying one (renamed) left- hand side with a nonvariable subterm of the same or another left-hand-side. The idea in completion is to make new rules out of critical pairs that do not sim- plify to identity. To generate critical pairs, we use a Prolog predicate subst (S ,L, R,T) which holds if T is the result of applying rule (L s R) once at a nonvariable subterm of S. The goal solving capabilities of PROLOG allow us to solve for a minimal,instance of S that makes the rule applicable, yielding-after unification-a crit- ical pair eq(S , T) . A terminating system is confluent (a stronger property than ground confluence) if for each critical pair s = t, both s and t reduce to the same term 21. Some other methods for establishing ground confluence (an undecidable property even of terminat- ing systems) are available; see, for example, (Kiichlin 1989). Completion was programmed as a predicate kb(Ei , EO) that applies the basic inference rules de- scribed in (Bachmair et al. 1986) to EO to generate a sequence of sets of equations EO, El, etc. One infer- ence rule generates new critical pairs; another reduces them to normal form; a third deletes trivial ones; two inference rules orient critical pairs into uni-directional rewrite rules. Rules are oriented according to a given well-founded ordering on terms, so that applying the rule to any term reduces the term in the ordering, en- suring thereby that the system of generated rules is al- ways terminating (an undecidable property). Comple- tion typically includes additional mechanisms for sim- plifying rules that have already been generated. (Our implementation does not, and therefore leads to vari- ants of the rules that might be obtained with a full- fledged system like REVE (Lescanne 1983) .) For our purposes, the most useful ordering is the dexicogruphic path ordering (Kamin & Levy 1980); see (Dershowitz 1987). This ordering >lpO is based on a given partial ordering, called a precedence, + between function symbols. In the induced ordering >lpO, a term is always greater than each of its subterms, terms with the same leading function symbol are compared lexico- graphically (from left-to-right, say), and a term with more significant leading symbol needs only be greater than the immediate subterms of a term with less sig- nificant leading symbol. Consider the following specification S: x+0 + x x + S(Y) - 4x + Y) s(x) + Y - 4x+ Y) x+x - 44 DERSHOWITZ AND PINCHOVER 235 in handy. Furthermore, we need not be concerned with the potential completion has of generating an infinite number of irrelevant equations, since-for the purposes of synthesis-completion may be arrested as soon as enough rules R have been generated for completeness. We choose a precedence that ensures that specification symbols (+) are greater than the synthesized functions (d), which in turn are greater than the primitive op- erations (s,O). The query kb( Cl , Cl ) produces the fol- lowing equations and rules R: d(0) - 0 TlxN = s(s(x) + x) GN = s(s(x + x)) - 444x))) The first rule, for instance, is the result of orienting the two normal forms of 0 + 0 (in the only direction possible). The latter term is obtained by unifying the left-hand sides of the specification and first rule for ad- dition. For more details of completion-based synthesis, see (Dershowitz 1985b). We need to show that the two generated rules form a correct and complete system for doubling. To de- fine correctness, we need to make precise what was meant earlier by “equal according to S.” There are two notions of equality that are relevant: (a) deductive equality, meaning provable by substitution of equals for equals; and (b) inductive equality, meaning that all variable-free instances of the equation are deductively equal. To symbolize that every equation in R is a de- ductive equality with respect to S, we write S I- R; to symbolize that they are inductive equalities, we write Znd(S) + R. For example, S I- x+y = y+x is not true, though for every variable-free instance it is; for exam- ple, S I- s(s(0)) + s(0) = s(0) + s(s(0)). The weaker notion, inductive equality, suffices in programming con- texts, so we will say that R is correct with respect to specification S if Znd(S) + R. When completion is used, correctness is guaranteed in the stronger, deduc- tive sense. Completeness is similar to correctness, but with the roles of R and S reversed. Actually, we split S into A U D, where A contains domain information and D expresses properties of the defined functions in terms of domain entities. Then, we require only that Znd(AU R) b D. In the doubling example, A would consist of the three rules for addition and D would be the equation x + x = d(x). The two generated rules for d are com- plete, since both sides of any ground instance of D (happen to) reduce (under A U R) to domain values constructed from s and 0. Since R is correct (that is, it follows from A U D), and D is a conservative exten- sion of A (hence does not equate unequal constructor terms), the two reduced sides of D must be equal in A. So, we have A U R I- t + t = d(t) for all ground terms t. For a discussion of correctness of synthesized rewrite programs, see (Reddy 1989). In (Reddy 1989) it is pointed out that full comple- For the second step, we generate most specific gener- tion is unnecessary and a weaker inference engine suf- alizations of pairs of equations, by replacing conflicting fices; in other words, only a subset of the critical pairs subterms by a new variable; see (Plotkin 1970). We need to be generated for synthesis of ground confluent implemented a predicate msg(S ,T,U, M) that gives the programs. On the other hand, the additional equa- least general term U (i.e. the glb of S and T in the sub- tions generated by full completion occasionally come sumption lattice) such that S and T are both instances Ordinary completion will fail if it reaches a point where all critical pairs have been generated, and all equations are nontrivial, in normal form, and un- orientable. Unfailing extensions of completion have been designed and perform better; see, for example, (Bachmair et al. 1989). Regardless of which version of completion is em- ployed, it may generate an infinite number of relevant program rules. What to do in such a case, is the subject of the next section. Inductive Synthesis In (Dershowitz 1985b) and (Reddy 1989), it was argued that-with an appropriate ordering-completion will always generate a program from a given specification. The catch is that the “guaranteed” program may be of infinite length. Indeed, running completion without the third addition rule, s(x) + y + s(x + y), instead of the desired program, generates an infinite set of rules: There is, of course, little one can do with the resultant infinite table lookup: (d(s”(0)) --+ ~~~(0) : i > 0). What is needed is some way of guessing the more gen- eral rule d(s(x)) + s(s(d(x))). We use two processes to generate hypotheses. The first involves generating critical pairs between right- hand sides of rules; the second is a syntactic form of generalization, a la (Boyer & Moore 1977). The intu- ition is that once we are dissatisfied with the rules, we look for equations between terms containing the defined function symbol, in the hope of discovering a pattern. For the first step, we generate critical pairs between inverted rules of the current partial program. That is, we use a precedence + + s, 0 > d, so that patterns involving d are brought to the fore. Given the above rules for d, we get the following equations d(s(O)) = s(s(d(O))) d(s(s(O))) = s(s(d(s(O)))) 236 AUTOMATEDREASONING of U; M is the list of conflicts between S and T used to construct U, which is needed to ensure that the same conflicts result in the same new variable. (This process is called “anti-unification” nowadays.) From the above two equations, msg generates the hy- pothesis d(s(as)) = s(s(d(x))). G iven a hypothesized rule (such as this equation oriented from left to right), we must apply the inductive proof method to prove that it is consistent with the domain rules and specifi- cation. Once proved, it can be used to reduce (away) special cases already generated. To prove correctness in the inductive sense, we make use of the following fact: Znd(S) k R if and only if Z&(S) b dp(R), where dp(R) is the set of all equa- tions obtained by using S to narrow the left side of a rule in R. In proving dp(R), the hypothesis R may be taken for granted. This process may be repeated for each of the equations in dp(R) until only deduc- tive consequences of S remain. In a manner similar to generation of critical pairs, we implemented a predi- cate dp(D,E) that generates equations E obtained by narrowing D. Thus, to prove an equation eq(S,T) we first reduce its two sides to normal form, then con- sider it proved if it has been shown already, if the two sides are identical, or if it can be oriented into a rule and each equation E such that dp( eq(S , T) , E) is itself provable. This is the essence of the improved proof-by- consistency method in (F’ribourg 1989). Refinements of this method include (Bachmair 1988) and (Reddy 1990). Returning to our example, the hypothesis d(s(z)) -+ s(s( d(z))) is narrowed by d(x) --) x + 2, giving S(X) + S(X) = s(s(Ca(z))). Note that the rule for d is used for verification in the opposite direction of its use for synthesis. This is so that the specification it- self is (ground) confluent. The above equation sim- plifies to s(s(z) + Z) = s( s(a: + x)), using the rule 2 + s(y) + s(z + y), but no further (in the absence of s(z) + y + s(z + y)). Were this equation provable by deductive means, we would be finished; it isn’t, so the inductive proof method continues in the same manner, generating an infinite sequence of oriented hypotheses: SMX) + 4 + s(s(x + x)) SMSMY)) + YN + S(S(S(S(Y) + Y)N Clearly, we need to substitute the (missing) lemma s(z) + y + S(Z + y) for these instances. We employ the same generalization methods as for synthesis (cf. (Jan- tke 1989a; Lange 1989)). An additional helpful tech- nique is cancellation, as used in deduction, for example, by (Stickel 1984). In particular (Huet & Hullot 1982), we can take advantage of “constructors,” replacing hy- potheses of the from c(sr , . . . , sn) = c(tl, . . . , tn) with n hypotheses si = ti, when there are no rules for c in S. In the above case, we are free to strip off matching outer s’s from the generated hypotheses: s(z) +x + s(z+z) SMYN + Y + MY) + Y) Using the same msg procedure as before leads to the more general hypothesis S(X) + y = s(z: + y), exactly what we were looking for. With this added as a rule to S, the recursive program d(0) + 0 dW > + ww)> for d is finally proved correct. The first rule is a de- ductive consequence of S; the second is an inductive consequence. (Actually, the synthesis procedure would already have suggested the missing equation from the :zluly)ce of rules d( sz (0)) -+ Sag, leading to the same . Having succeeded in producing a program for dou- bling, a recursive program for halving can be generated from the implicit definition The following sequence of rules is produced: These rules suggest at least two hypotheses, namely: The former generalizes the equations NO) = ww wsm = w+(0)))) but is disproved, since (taking x = s(0)) it implies that s(O) = 0. The second hypothesis is obtained by looking at different pairs of rules (first and third, second and fourth, etc.) and generalizes the equations It is proved immediately by rect and complete program induction, yielding the cor- h(O) + 0 woN + 0 w+m + s(G9) When a program R contains symbols not appear- ing in its specification S, such as symbols for auxiliary functions, we need to replace inductive truth with the DERSHOWITZ AND PINCHOVER 237 notion of “conservative extension.” That is, we require that there exist no terms s and t in the vocabulary of S such that S y s = t, but R U S I- s = t. One heuris- tic for introducing auxiliary functions is simply to look for nontrivial subterms that appear (some number of times) in program rules. For example, suppose we have all three rules for ad- dition, and wish to manufacture a program q(x) for squaring from the following rules for multiplication: x*0 * 0 x * S(Y) + (x *y) +x 44 *Y + (x * Y) +Y x*x + q(x) Suppose, further, that we do not wish to allow addi- tion in the synthesized program, so we order the sym- bols * > + t Q > s, 0. Completion will generate the following rules (among others) : a(O) + 0 em + 4 + 4 + aW>) 4s(4(aMYN + Y) + Y)>) + d+(Y))) Noting the repeating left-hand side pattern (y + 2) suggests the introduction of an ancillary function: is an indirect program for k, requiring narrowing to first solve the goal y = d(x) (or y = s(d(x))) for a given number y before rewriting k(y) to f(y) (or g(y)). Thus, the first rule applies to even y and the second in the odd case. An alternative rewriting would be program, requiring only d@(Y)) = Y I k(Y) + f(Y) 4WY)N = Y I k(Y) + g(Y) where the first part is a conditional “guard,” which when satisfied for a particular number y allows k(Y) to be rewritten. In general, conditional rewrite sys- tems and conditional narrowing provide a better com- bination of functional and logic programming; see, for instance, (Dershowitz & Plaisted 1988). Condi- tional synthesis, however, would necessitate more pow- erful deductive and inductive methods for handling conditional equations, such as have been investigated in (Ganzinger 1987; Kounalis & Rusinowitch 1990). More elaborate generalization methods would also be required, perhaps along the lines of (Kirchner 1989; Lange 1989). This is an area for further research. @++)+z ---f P(V) Synthesizing p in the same manner as we synthesized d, gives P(O) + 32 P(X, S(Y)) + 44P(X, YN Interpolating p in the precedence after 4 (since it is alright for q to be defined in terms of p) turns all the above rules for q into just: q(O) + 0 a(+4 ---) s(P(q(4 4) Together, program. the rules for p and q constitute the desired Discussion We have shown how-in the equational framework- both deductive and inductive methods may be applied to the task of program synthesis. We have witnessed the need for heuristics that suggest inductive theorems for incorporation in a developing program, as well as for forming the lemmas needed in the inductive proofs. We have been pleasantly surprised by the success of just these few, simple heuristics. Not all target programs fall under the purview of the automated techniques we have discussed. For example, suppose the specification is W(x)) + f@(x)) kW(xN) + 9W(4N where f and g are primitive operations, and we are given all the facts we have derived about d and h. This +a: References Bachmair, L. Proof by consistency in equational theories. In Proceedings of the Third Symposium on Logic in Com- puter Science, pp. 228-233, Edinburgh, Scotland, July 1988. Bachmair, L., Dershowitz, N., and Hsiang, J. Orderings for equational proofs. In Proceedings of the Symposium on Logic in Computer Science, pp. 346-357, Cambridge, MA, June 1986. Bachmair, L., Dershowitz, N., and PI&ted, D. A. Com- pletion without failure. In Ait-Kaci, H. and Nivat, M., eds., Resoirution of Equations in Algebraic Structures, vol. 2: Rewriting Techniques, chap. 1, pp. l-30, Academic Press, New York, 1989. Barr, A. and Feigenbaum, E. A., eds. The Handbook of Ar- tificial Intelligence. William Kaufmann, 1981-1982. Three volumes. Boyer, R. S. and Moore, J. S. A lemma driven automatic theorem prover for recursive function theory. In Proceedings of the Fifth International Joint Conference on Artificial In- telligence, pp. 511-519, Cambridge, MA, 1977. BurstaIl, R. M. and Darlington, J. A transformation system for developing recursive programs. J. of the Association for Computing Machinery, 24( 1):44-67, January 1977. Dershowitz, N. Applications of the Knuth-Bendix com- pletion procedure. In Proceedings of the Seminaire d ‘Informatique Theorique, pp. 95-l 11, Paris, France, De- cember 1982. Dershowitz, N. Equations as programming language. In Proceedings of the Fourth Jerusalem Conference on Infor- mation Technology, pp. 114-124, IEEE Computer Society, Jerusalem, Israel, May 1984. Dershowitz, N. Computing with rewrite systems. Informa- tion and Control, 64(2/3):1 22-157, May/June 1985. Dershowitz, N. Synthesis by completion. In Proceedings of the Ninth International Joint Conference on Artificial Intelligence, pp. 208-214, Los Angeles, CA, August 1985. 238 AUTOMATEDREASONING Dershowitz, N. Termination of rewriting. J. of Symbolic Computation, 3(1&2):69-115, February/April 1987. Corri- gendum: 4, 3 (December 1987), 409-410. Dershowitz, N. Completion and its applications. In Ait- Kaci, H. and Nivat, M., eds., Resolution of Equations in AZgebraic Structures, vol. 2: Rewriting Techniques, chap. 2, pp. 31-86, Academic Press, New York, 1989. Dershowitz, N. and Jouannaud, J. Rewrite systems. In van Leeuwen, J., ed., Handbook of Theoretical Computer Science B: Formal Methods and Semantics, chap. 6, North- Holland, Amsterdam, 1990. In press; available as Rapport 478, LRI, Univ. Paris-Sud, France. Dershowitz, N. and Plaisted, D. A. Equational program- ming. In Hayes, J. E., Michie, D., and Richards, J., eds., Machine IntelIigence 11: The logic and acquisition of knowledge, chap. 2, pp. 21-56, Oxford Press, Oxford, 1988. Fribourg, L. A strong restriction of the inductive comple- tion procedure. J. Symbolic Computation, 8(3):253-276, 1989. Fronhijfer, B. and Furbach, U. Knuth-Bendix completion versus fold/unfold: A comparative study in program syn- thesis. In Rollinger, C. and Horn, W., eds., Proceedings of the Tenth German Workshop on Artificial Intelligence, pp. 289-300, 1986. Ganzinger, H. A completion procedure for conditional equations. In Kaplan, S. and Jouannaud, J., eds., Pro- ceedings of the First International Workshop on Condi- tional Term Rewriting Systems, pp. 62-83, Orsay, France, July 1987. Vol. 308 of Lecture Notes in Computer Science, Springer, Berlin (1988). Huet, G. and Hullot, J. Proofs by induction in equational theories with constructors. J. of Computer and System Sci- ences, 25:239-266, 1982. Jantke, K. P. Algorithmic learning from incomplete in- formation: Principles and problems. In Dassow, J. and Kelemen, J., eds., Machines, Languages, and Complexity (Selected C on rz u ions t ‘b t of the 5th International Meeting of Young Computer Scientists, Smolenice, Czechoslovakia, November 1988), pp. 188-207, 1989. Vol. 381 of Lecture Notes in Computer Science, Springer, Berlin. Jantke, K. P. Inductive program synthesis by problem prov- ing and term rewriting. Technical Report, Humbolt Univ. Berlin, Berlin, 1989. Kamin, S. and Levy, J. J. Two generalizations of the recur- sive path ordering. Unpublished note, Department of Com- puter Science, University of Illinois, Urbana, IL, February 1980. Kirchner, H. Schematization of infinite sets of rewrite rules generated by divergent completion processes. Theoretical Computer Science, 67(2,3):303-332, October 1989. Knuth, D. E. and Bendix, P. B. Simple word problems in universal algebras. In Leech, J., ed., Computational Prob- lems in Abstract Algebra, pp. 263-297, Pergamon Press, Ox- ford, U. K., 1970. Reprinted in Automation of Reasoning 2, Springer, Berlin, pp. 342-376 (1983). Kodratoff, Y. and Picard, M. Completion de systemes de rekcriture et synthese de programmes B partir deleurs specifications. Bigre, 35, October 1983. Kounalis, E. and Rusinowitch, M. Inductive reasoning in conditional theories. In Okada, M., ed., Proceedings of the Second InternationaI Workshop on Conditional and Typed Rewriting Systems, Montreal, Canada, June 1990. Lecture Notes in Computer Science, Springer, Berlin; to appear. Kiichlin, W. Inductive completion by ground proof trans- formation. In Ait-Kaci, H. and Nivat, M., eds., Resolu- tion of Equations in Algebraic Structures, vol. 2: Rewriting Techniques, pp. 211-244, Academic Press, New York, 1989. Lange, S. Towards a set of inference rules for solving di- vergence in Knuth-Bendix completion. In Jantke, K. P., ed., Proceedings of the International Workshop on Analog- ical and Inductive Inference, pp. 304-316, October 1989. Vol. 397 of Lecture Notes in Computer Science, Springer, Berlin. Lescanne, P. Computer experiments with the reve term rewriting system generator. In Proceedings of the Tenth ACM Symposium on Principles of Programming Languages, pp. 99-108, Austin, TX, January 1983. Manna, Z. and Waldinger, R. J. Synthesis: Dreams + pro- grams. IEEE Transactions on Software Engineering, SE- 5(4):294-328, July 1979. Musser, D. R. On proving inductive properties of abstract data types. In Proceedings of the Seventh ACM Symposium on Principles of Programming Languages, pp. 154-162, Las Vegas, NV, 1980. Perdix, H. Program synthesis from specifications. In Jor- rand, P. and Sgurev, V., eds., AIMSA, pp. 13-21, North- Holland, 1986. Plotkin, G. Lattice theoretic properties of subsumption. Technical Report MIP-R-77, University of Edinburgh, Ed- inburgh, Scotland, 1970. Reddy, U. S. On the relationship between logic and func- tional languages. In DeGroot, D. and Lindstrom, G., eds., Logic Programming: Functions, Relations, and Equations, pp. 3-36, Prentice-Hall, Englewood Cliffs, NJ, 1986. Reddy, U. S. Rewriting techniques for program synthe- sis. In Dershowitz, N., ed., Proceedings of the Third Inter- national Conference on Rewriting Techniques and Applica- tions, pp. 388-403, Chapel Hill, NC, April 1989. Vol. 355 of Lecture Notes in Computer Science, Springer, Berlin. Reddy, U. S. Term rewriting induction. In Stickel, M., ed., Proceedings of the Ninth International Conference on Automated Deduction, Kaiserslautern, West Germany, July 1990. Lecture Notes in Computer Science, Springer, Berlin; to appear. Shapiro, E. Y. Algorithmic Program Debugging. MIT Press, Cambridge, MA, 1983. Smith, D. R. A survey of synthesis of Lisp programs from examples. In International Workshop on Program Con- struction, Bonas, France, September 1980. Stickel, M. E. A case study of theorem proving by the Knuth Bendix method discovering that z3 = x implies ring commutativity. In Shostak, R. E., ed., Proceedings of the Seventh International Conference on Automated Deduction, pp. 248-259, Napa, CA, May 1984. Vol. 170 of Lecture Notes in Computer Science, Springer, Berlin. Stickel, M. E. A Prolog technology theorem prover: Imple- mentation by an extended Prolog compiler. In Siekmann, J. H., ed., Proceedings of the Eighth International Confer- ence on Automated Deduction, pp. 573-587, Oxford, Eng- land, July 1986. Vol. 230 of Lecture Notes in Computer Science, Springer, Berlin. DERSHOWITZ AND PINCHOVER 239
|
1990
|
36
|
952
|
Mechanizing inductive reasoning Emmanuel Kounalis and Michael Rusinowitch CRIN, 54506 Vandoeuvre lcs Nancy, BP239 (France) e-mail: { kounalis,rusi}@loria.fr Abstract Automating proofs by induction is important in many computer science and artificial intelligence applications, in particular in program verification and specification systems. We present a new method to prove (and dis- prove) automatically inductive properties. Given a set of axioms, a well-suited induction scheme is constructed automatically. We call such a scheme a test-set. Then, for proving a property, we just instantiate it with terms from the test-set and apply pure algebraic simplifica- tion to the result. This method avoids completion and explicit induction. However it retains their positive fea- tures, namely the completeness of the former and t,he robustness of the latter. 1 Introduction Inductive reasoning consists in performing inferences in domains where there exists a natural well-founded relation on the objects. It is fundamental when prov- ing properties of numbers, data-structures or programs axiomatized by a set of conditional axioms. As op- posed to deductive theorems, inductive theorems are usually valid only in some particular models of the ax- ioms, for instance Herbrand models or the initial model, which fits nicely the semantics of data-type specifica- tions, logic and functional programming. As everybody knows from his experience, it might be difficult, not only to find an appropriate well-founded relation to support inductive inferences, but also to guess suitable induction hypothesis. Two main ap- proaches have been proposed to overcome these diffi- culties. The first applies explicit induction arguments on the structure of terms [1,3,2,4,14]. The second one involves a proof by consistency: this is the induction- less induction method [10,5,6]. However, both meth- ods have many limitations either on the theorems to be proved or on the underlying theory. For instance, explicit induction techniques is unable to provide us automatically with induction schemes, and cannot help to disprove false conjectures. On the other hand, the inductionless induction technique often fails where ex- plicit induction succeeds. Moreover, there does not ex- ist any realistic inductionless induction procedure for 240 AUTOMATED REASONING conditional theories. In this paper, we present an alternative proof system for automatizing inductive reasoning in theories defined by condiCona1 axioms. We show how to prove (and disprove) equations and more generally clauses in the initial model and Herbrand models respectively. Our method combines the full power of explicit induction and inductionless induction. It is refutationally com- plete in the following sense : any positive clause which is not valid in the initial model will be disproved in finite time, provided that no negative literals are in- troduced by the procedure. This method relies on the notion of test-set (which, in essence, is a finite descrip- tion of the initial model) and applies only pure algebraic simplification. The key-idea of the simplification strat- egy is to use axioms, previously proved conjectures, and instances of the conjecture itself as soon as they are smaller than the currently examined proposition with respect to a well-founded relation. This last point cap- tures the notion of Induction Hypothesis in the proof by induction paradigm. The refut’ational aspect of our procedure requires a convergence property of the ax- iomatization and, also, suit,able test-sets. The conver- gence can be obtained either by a Knuth-Bendix like procedure [9] or semantic techniques specific to hierar- chical axiomat,izations(see [12] and section 5.2 of this paper). On the other side, building a test-set requires itself some theorem proving. Whereas the computation of test-sets is generally undecidable, in the last section. we propose a method to obtain test-sets in conditional theories over a free set of constructors. Our met.hod can also be viewed as a real automatization of explicit induction: indeed the test-set computation yields auto- matically induction schemes which are well-adapted to the axioms. In addition, we show how the method ap- plies to proofs of propertirc of some recursive programs and element(ary arithmetic. 2 Overview of our approach: an example Before discussing the technical details of the method we propose for mechanizing proofs of inductive theorems, we first describe our inference system on a simple exam- From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. ple, namely positive integers with cut-off and gcd func- tions and the less predicate. The arrow 4 just indicates how to apply a (conditional) equation for simplification: (1) x- 0-a: (2) o-x -+ 0 (3) s(2) - s(y) + 5 - y (4) (0 < s(x)) ---) tt (5) (2 < 0) + ff (6) x < y = tt j s(x) < s(y) 4 tt (7) x < Y = ff *44 < S(Y) + ff (8) x < y = tt * gcd(x, y) --+ gcd(y - 5, y> (9) 5 < Y = ff * SCd(X, Y) + wd(x - Y, 4 (10) gcd(x,O) -+ x (11) gcd(O,x) -+ x Consider the conjectures: (12) x - x = 0 (13) x < x = ff (14) x < S(Z) = tt (15)zcy=ttvx<y=ff (16)x<y=ffVy<z=ff V x<z=tt (17) gcd(s, z) = x (18) gcd(c Y) = Wd(Y, 4 (19) x < s(x) = ff (20) 2 < y = ff v y < x = tt Except the two last ones all these propositions are valid in the standard arithmetic:note that 13,15 and 16 state that < is a total ordering on integers, and 18 is the com- mutativity of gtd. This suggests to prove them by in- duction. With our method the first step consists in com- puting a test-set (see def. 4.1). By using techniques of section 6,we get the test-set (0, S(X), tt, ff). The next step consists in replacing variables of the conjecture by the elements of the test-set and checking these instances by using pure simplification. The simplification strut- egy may use axioms, previously proved conjectures, and instances of the conjecture itself as soon as they are sm.aller (w.r.t. a noetherian relation which contains th,e rewriting relation) than the currently examined propo- sition. This last point captures the notion of Induction Hypothesis in the proof by induction paradigm (see th. 4.1~. 2). For the equation 12, two instances need to be checked: 0 - 0 = 0 and s(z) - s(z) = 0. The first one reduces immediately to a trivial identity. For the sec- ond one consider the reduction (notice the use of 12 as an induction hypothesis): s(z) -s(x) -Q x - x -+x2 0 For 13, the only non-trivial instance is s(z) < s(z) = ff. However, s(z) < s(z) -‘Is,7 f f. For the last deriva- tion, we have used an induction hypothesis to satisfy the condition of 7 (cf th. 4.1). For 14, the same argu- ment can be employed. For 15, there are four instances by terms from the test-set. The only non-trivial case is ~(3) < s(y) = tt v s(z) < s(y) = ff . By using case rewriting (cf def. 3.3), we can split this formula into the conjunction: (21) 1x < y = tt v tt = tt v s(x) < s(y) = f f (22) x < .(I = tt v s(x) < s(y) = f f Kow, 21 is trivial and 22 is split again in: (23)x<y=ttVlx<y=ffVff=ff (24) x < y = tt V x < y = ff VSW < S(Y) = ff 23 is trivial again and 24 is subsumed by the initial conjecture: this is the induction step (cf th. 4.2). The 16,17,18 are proved exactly in the same way. Consider now 19. To disprove it, we are going to use the con- vergence properties of the initial system. Note that the saturation technique (see section 5) can prove the con- vergence property for l-7 and th. 5.1 for the whole axiomatizxtion. The instances to be considered are : 0 < s(0) = f f, s(z) < s(s(x)) = f f The first one reduces tott = ff h w ose members are irreducible and different. By th. 4.3 the conject.ure is false. For 20, consider the following instance 0 < s(x) = f f V s(x) < 0 = tt. It can be reduced t,o tt = ff V ff = tt and therefore ‘20 is not valid. 3 Preliminaries 3.1 Definitions and notations Let F be a signature of function symbols, and X a set of variables. We shall denote by T(F, X) the set of terms built from F and X. We write s[tln to mean that the term t is a subterm of s at position n. The set of ground terms is denoted by T(F). A conditional equa- tion is an equation or an expression of one of t.he types: elA.. .Ae, =S eorelA.. .Ae, +or+wheree?el,...e, are equations, el 7”’ e, are conditions, a positive literal e in a conditional equation is a conclusion and + is the empty clause. In this paper, axiomatizations are built from conditional equations and goals to be proved are clauses (i.e. disjunction of equational literals, since = is the only predicate, here ‘). Given a binary relation 4, --b* denotes its reflexive transitive closure. Given two binary relations, R, S, RoS denotes their composi- tion. A relation R is noetherian if there is 110 infinite sequence fl R t2 R . . . . In the following. we suppose given a reduction ordering + OIL the set of terms, that is, a transitive irreflexivc relation which is noetherian, monotonic (s + t implies U.J[S] + ~[t]) and st,able (s + t implies SLT + ta). A reduction ordering can be extended to literals by comparing the multiset of their members with the multiset extension of >-. Formula are compared by using the mult,iset extension of this last ordering to the multiset of their atomic subformulas. Since there is no ambiguity, all these extensions will also be denoted by +. An equation s = t will be written s --$ f if for all ground substitution so + TV; in tShatt case we say that the equation is orientable. 1 we shall identify a conditional equat iou and its corresponding representation as a clause KOUNALIS AND RUSINOWITCH 241 3.2 Inductive theorems Given a set of conditional equations Ax on the signature F, we recall that a Herbrand model of Ax is a model of Ax whose domain is T(F) (axioms for equality are implicitly assumed to be valid, too). A formula F is a deductive theorem of Ax if it is valid in any model of Ax. This will be denoted by Ax /= F. The notion of in- ductive theory can be related to several kinds of models: Herbrand models or initial models (i.e least Herbrand models). These relations are discussed in [ll]. We have chosen to study the initial and Herbrand model approaches: Definition 3.1 Let H be a set of conditional equations on the signature F. A clause e is an inductive theorem of H ifl for any ground substitution o, H k eo. For clauses, validity in all Herbrand models differs, in general, from validity in the initial model. However these two notions of validity coincide for unconditional equations as it is proved in- [ll]. 3.3 Conditional rewriting The idea of rewriting is to impose a direction when us- ing equations in proofs. This direction is indicated by an arrow when it is independent from the instantiation: I + r means that, we can replace 2 by r in some context. When an instance of a conditional equation is orientable and has a valid conditional part, it can be applied as a rule. The conditions are checked by a recursive call to the theorem-prover. Termination of such calls is en- conditions to be smaller (w.r.t. sured by requiring the the reduction ordering +) than the conclusion: Definition 3.2 Let H be a set of clauses. Let A be a term or a clause, and n an occurrence of A. Then A[s& +H A[ta], if o is a substitution and there is a conditional equation c + s = t, in H such that SO + ta and H j= co and (s = t)o + cu.. A term A is reducible w.r.t. -)H, if there is a term B such that A -)H B. Otherwise we say that A is H-irreducible. The system H will be qualified as convergent if for all ground terms a,b such that H+a = b there exists a ground term c such that o+H*c and b+H*c. One can easily see that it is also equivalent to the property that every ground term pos- sesses a unique irreducible form. Note that the con- ditional rewriting relation may be undecidable. The relation +H will be extended to sets of clauses in a natural way: by definition, S U {c} -‘H S U {d} whcn- ever c -)H d. 3.4 Case rewriting Case reasoning is a very powerful technique which is the basis of many theorem proving strategies. It is a most important rule in the context of inductive theo- rem proving where case splitting arises naturally from induction hypothesis. We propose here a notion of case rewriting which is well-suited to inductive reasoning. Definition 3.3 Let H be a set of conditional equations and c =+ s = t a conditional equation in H. Let A[su]~ be a clause (where o is a substitution) and let S be a set of clauses. The case rewriting rule can be stated as follows S U {A[sa],} -H S U {(CO V A[sa],). (1~ V A[t&)} if co is not a subclause of A[sa],, n occurs in a maximal literal of A, so F to and (s = t)o + co Let us denote “H U -‘H by L)H. The follow- ing propositions is the base for proving (or disproving) clausal theorems. Proposition 3.1 The case rewriting rule is sound (the derived set of clauses is logically equivalent to the initial set). The relation CI’H is noetherian. 4 How to prove and disprove in- ductive theorems In this section, we propose general methods to prove (or disprove) automatically that clauses are inductive consequences of theories axiomatized by a set of con- ditional equations. These techniques allow us to re- place inductive reasoning by pure simplification. Such a mechanization of inductive proofs is based on the no- tion of test-set, which, in essence, provides us with a finite description of the initial model. 4.1 Test sets First, let us define the height of a term as the height of the tree representation of this term. The height of a set of conditional equations will be the maximal height of the terms occurring in this set. The height of an object x will be denoted by lx]. Definition 4.1 A test-set for a set of conditional equations H is a fin.ite subset S(H) of T(F, X) such that the following properties hold: completeness: for any H-irreducible ground term s, there exists a term t in S(H) and a substitution o such that ta = s. soundness: for any term t in S(H) th.ere exists an H- irreducible grou,J term s and a substitution o such that to = s. transnormality: every n,on-ground term in S(H) has infinitely many ground instances which are H- irreducible. coveredness: any non-ground term t in S(H), It] > 1 where I = I HI - 1 if every variable in the left-hand side of the positive literals in H occurs once and 242 AUTOMATEDREASONING 1 = ]H] if H contains a rule whose left-hand side has multiple occurrences of the same variable. Definition 4.2 A test-substitution w.r.t. S(H) is a substitution which applies every variable to an element of the test-set S(H) Example 4.1 Let us come back to the introductory ex- ample. Let H be the set of axioms 1,2,. . . , 10. As we pointed out, S(H) = (0, s(x), tt, ff} may be considered as a test-set. Note that the four properties of the defy- nition are verified. The construction of test-sets for equational theories is decidable and may be performed in relatively efficient way. The algorithm is based on pumping lemmas in tree languages and is detailed in [8]. Such an algorithm does not exist for conditional theories. However, in the last section, we shall give a method to derive test-sets in theories defined over a free set of constructors. 4.2 Inductive proofs by simplification Our notion of induction refers to a noetherian order- ing on ground terms, which contains the conditional rewriting relation. We can use as an inductive hy- pothesis any instance of the theorem we want to prove, as soon as this instance is smaller (w.r.t. +)t han the one that is currently considered. In Theorem 4.1 we propose two rewriting relations which are sound, with regard to the use of induction hypothe- sis. Both of them allow to utilize the conjecture after a first normal simplification step has been applied. How- ever, if the first step is conditional, we can also use the conjecture when attempting to satisfy the conditions of the rule (case a). The following notations will be useful: Definition 4.3 Let u = v be an equation, then ?L=9 denotes the symmetric closure of +{U=21) and +H/U=V denotes the relation (a )*o(+H)o(x)*. Let H be a set of conditional equations, let A be a term and n an occurrence of A. Then we write A[sa], +H[~=~] A[ta], if o is a substitution and there is a conditional equation al = bl A a . s A a, = b, =+ s = t in H, such that: 1. su + to and (s = t)a t (al = bl A .a. A a, = b,)a 2. Vi, 3c aio+HU{U=v) *c and b~o+~~U~U=U)*c The following theorem shows how to prove equations in the initial model of conditional theories. Theorem 4.1 (see [9]) Let H be a set of conditional equations, S(H) a test-set, and u = v an equation. We suppose that one of the following hypothesis is verified: a. +HU{U=V) is noetherian. In this case we define w as the reflexive closure of the relation: (-‘H[u=~~)O(~Hu(u=~~)~ b. +H/u=v is noetherian. In this case we de- fine w as the reflexive closure of the relation: If, for all test-substitution v there is a term 0 such that uv C\A Q and uv * Q then ‘u = v is an inductive theorem for H (and therefore is valid in the initial model of H by proposition 3.2). Example 4.2 Consider the following conditional ax- ioms for integers with +, odd and even,. (24) x+0-x (25) X+S(Y) - S(X +Y) (26) even(O)+ tt (27) evenw>> --) ff (28) even(s(s(s))) - even(x) (29) euen( 2) = tt a odd(s(x)) --f tt (30) even(x) = ff * odd(W) - ff Here the test-set is (0, s(O),s(s(z)), tt, f f}. Let us prove first the commutativity of +. We apply case b. of th. 4.1. We just consider the non-trivial case, which is an instantiation by the last scheme: s(s(x)) + s(s(y)) = SMYN + s(W). Aft er simplification, we have to con- sider the goal: s(s(s(s(x)) + y)) = s(s(s(s(y)) + x)). Commutativity can be applied strictly inside the equa- tion, since it is supposed to be true for smaller instances (induction hypoth,esis). We get: s(s(y + s(s(x)))) = SW + SMY>>>> and then, simplification finishes the job. By assuming now the commutativity of +, we can prove in the same way : odd(x + s(x)) = tt. First, odd(s(s(x))+s(s(s(x)))) - odd(s(s(s(s(s(x+.~)))))) - tt. To justify the last rewriting step we need to prove as a lemma even(s(s(s(s(x + 2))))) = tt or its simplified form even.(x + .r) = tt. This is achieved by the same technique. It is straightforward to generalize the previous method to proving that clauses are inductive theorems. How- ever, in this general situation, case analysis is crucial: Theorem 4.2 Let H be a set of conditional equations, S(H) a test-set? and C a clause. If, for all test- substitution u, (CY) wH* (pl,pz *a * ,p,), and every clause pj is either a tautology (con!ains two complemen- tary literals or an instance of x=x) or is subsumed by an axiom or contains an instance of C which is strictly smaller w.r.t. >- than Cu, then C is an inductive theo- rem of H Example 4.3 Let us prove now the transitivity of < (see axioms in the introductory example): x < y = ffVY< z=ffVx< t = tt. The only non-trivial instance by a test-substitution among the eight of them is: s(x) < a(y) = ff V s(y) < a(z) = ff V s(r) < t?(z) = tt. After three steps of case-rewriting, we get only one clause which is not a tautology, namely: x<y=ffVy<z=ffVx<z=ttVs(x)<s(y)=ff vs(y) < s(z) = ff v s(x) < s(z) = tt KOUNALIS AND RUSINOWITCH 243 This clause contains a subclause which is a strictly smaller instance of the one to be proved. Hence by th. 4.2, the proof is achieved. In the same way we could prove in the example 4.2 that even(x) = ttvodd(x) = tt. 4.3 Disproving inductive theorems The notion of test-set is particularly useful for refuting inductive properties. The next definition provides us with criteria t.o reject such conjectures. Definition 4.4 We suppose that we are given a set of conditional equations H, and a test-set S(H). Let H’ be the set of positive literals of H. Then, a clause Tel V . . .vle,Vgl = dl v.. .vg, = d, is quasi-inconsistent with respect to H if there is a test-substitution CT such that, for all i 5 m, eio is an inductive theorem and for all j 5 n at least one of the following is verified: l gjo f djo and gjo and djo are irreducible by H’. l gjo + djo and gjo is irreducible by H’. a gjo 4 djo and djo is irreducible by H’. The next result shows that, when the set of axioms is convergent, a quasi-inconsistent clause cannot be induc- tively valid. This is proved by building a well-chosen ground instance of the clause, which is false in some Herbrand model of the axioms. In particular, if the clause is an equation then it is not valid in the initial model. Theorem 4.3 Let H be a convergent set of conditional equations and S(H) a test set for H. If C is quasi- inconsistent w.r.t. H then C is not an inductive theo- rem of H. Example 4.4 The axioms are as in example 4.2. (note that they satisfy the convergenw property). Consider the conjecture even(x) = tt V odd(x) = f f. It is quasi- inconsistent as shown by the following instance: even(s(0)) = tt V odd(s(0)) = ff The theorems 4.1,4.2 and 4.3 can be combined into an inductive theorem-proving procedure which is complete for positive clauses, in the sense that it will disprove every positive clause which is not an inductive theorem, provided that no negative literals are introduced by the procedure. However, in the general case, the procedure allows to disprove many false conjectures. 5 How to get convergence Convergent systems of equations have the property that two terms are equal if and only if they simplify to iden- tical ones. In this section, we recall several methods to obtain the convergence property which is crucial for disproving conjectures. 5.1 The saturation technique The saturation technique generalizes Knuth and Bendix procedure [7] to conditional theories. It is based on a refutationally complete set of inference rules. These rules have been discussed in [13]. 5.2 Hierarchical techniques Hierarchical axiomatizations are natural tools for build- ing structured specifications. They are obtained by in- cremental extensions of a base theory with new func- tion definitions. For hierarchical axiomatizations [12] , ground confluence can be obtained by semantic meth- ods. The next theorem underlies Plaisted’s work [12]: Theorem 5.1 Let H be a convergent set of conditional equations on the signature F - ( f ), and let H’ be an ex- tension of H with conditional equations where the sym- bol f occurs. Assume that H’ has the same initial model than H. If for every ground term f (tl, . . . , tn) there ex- ists t’ E T(F - {f}) such that f(tl,...,tn) (-‘it)* t’ then H’ is convergent. Verification of inductive properties often involves the proof of some lemmas. Adding these lemmas to the initial axiomatization does not destroy the convergence property as stated in the following result: Theorem 5.2 If H is convergent and C is a condi- tional equation which is an inductive theorem of H. Then --+Hu{c} is convergent. For instance, in the introductory example l-11 and 12,13,14,17,18 is convergent. 6 How to get test-sets In this section, we propose a method of constructing test-sets for conditional theories whose signature F can be partitionned into a set C of constructors and a set D of defined functions. Therefore, we assume that every left-hand side of an orientable instance of a conclusion has a symbol from D. This corresponds to the well- known principle of definition of [5]. In order to simplify our presentation WC shall suppose that D = {f). Definition 6.1 Let CS be the set {g(al.. . . , rn); g E C}, a pattern tree T off (x1.. . . ,E,). where f E D is a tree whose nodes are terms. The root is f (xl?. . . ,x,). Every successor of a node :. is obtained by replacing a variable of s by ((II element of S whose variables h,a.ve been renamed. Example 6.1 Let C.9 be {&S(T)} . Here is a pattern tree of x < y: X<Y \ T < 0 0 < S(Y) *p .$bv) 4x1 < S(Y) In the following, we describe a procedure for deriv- ing a pattern-tree such that a test-set can be extracted 244 AUTOMATEDREASONING from its leaves arguments. Hence, we suppose given a set of conditional equations defining a function f. To construct a suitable pattern tree of f(zr, . . . ,zn), the next definition tells us how to identify the nodes to be expanded and the variables to be replaced. Definition 6.2 A term t &I extensible at position u w.r.t. H if t/u is a variable and there is a rule c =+ I + r E H such th.at l/u is a function symbol or a variable occurrkg more than once in 1. A term t is extensible w.r.t. H if it is extensible at some position u. Definition 6.3 Given a set H of conditional equa- tions, we say that t is pseudo-reducible by H if there is a set of rules {cl * 11 -+ r-1, . . . ,c, =$ I, -+ rn} in S such that t/u1 = lIoI,. . . , t jun = Ino, and ClUl v . . . V &a, is an inductive theorem of H. Note immediately that if a term is pseudo-reducible, all its ground instances are reducible. Also, proving that a node is pseudo-reducible amounts to prove some induc- tive theorems. To avoid any vicious circle, either we can use a different method to prove these particular proper- ties or we can use our method itself with a less refined test-set than the one we are trying to build. Let H be a set of conditional equations and let T be a pattern tree for f (xl,. . . , zn). If each leaf of 2’ is either pseudo- reducible or not-extensible then we say T is complete for H. The tree in example 6.1 is complete for the ax- ioms of the preliminary example. The previous defini- tions provides us with a procedure to derive complete pattern-trees. Starting from the tree 2’ = f (x1, . . . . x,), we iterate the following operations: o Select non-deterministically a leaf t which is extensible at some position u and not pseudo-reducible o For any c in CS, rename c in c’ with new variables and add t[c’] u as a son of t. When the previous procedure halts with success (as it did on all the examples we have tested), it provides immediately a test-set: Theorem 6.1 Given a set of conditional equations H, if there is a finite complete pattern-tree for f (xl, . . . , x,) whose all leaves are pseudo-reducible then a test-set for H can be computed. Given a finite complete prl.ttern-tree, let G’ be the set of its leaves arguments. We define G to be a subset of G’ such that every element of G’ has an instance in G and no element of G is an instance of another element, of G. In the example 6.1, G’ = {O,s(z), s(y)} and G = {O,s(x)}. 7 Conclusion are convergent, test-sets give an efficient strategy to dis- prove theorems. We also feel that this method should generalize easily to the case of conditional equations with negative lit,erals in the conditions. References PI PI PI PI 151 PI PI PI PI PO1 WI WI PI PI R. Aubin. Mechanizing structural induction. In Theo- retical Computer Science 9, pp. 329-362, 1979. R.S. Boyer and J.S. Moore. A Computational Logic. Academic Press, New York, 1979. R-M. Burstall. Proving properties of programs by structural induction. In Computer Journal 12, pp. 41- 48, 1969. S.J. Garland and J.V. Guttag. An overview of LP, the Larch Prover. In N. Dershowitz, ed., Proc. of the 3rd RTA Conf., USA, pp. 137-151, LNCS 355, 1989. G. Huet and J-M. Hullot. Proofs by induction in equa- tional theories with constructors. J. of Computer and System Sciences, 25(2):239-266, 1982. J.P. Jouannaud and E. Kounalis. Proof by induction in equational theories without constructors. In Proc. of 1st Symp. on Logic In Computer Science, pp. 358-366, Boston (USA), 1986. D.E. Knuth and P.B. Bendix. Simple word problems in universal algebras. In J. Leech, ed., Computational Problems in Abstract Algebra, pp. 263-297, Pergamon Press, Oxford, 1970. E. Kounalis. Pumping lemmas in tree languages. in Mathematical Foundations of Computer Science, 1990. E. Kounalis and M. Rusinowitch. A mechanization of conditional reasoning. In First International Symp. on Artificial Intelligence and Mathematics, Fort Laud- erdale, Florida, 1990. D.L. Musser. On proving inductive properties of ab- stract. data types. In Proc. 7th ACM POPL, pp. 154- 162, 1080 P. Padawitz. Computing in Horn Clause Theories. Springer-Verlag, 1988. D. Plaisted. Semantic confluence tests and comple- tion methods. In Journal Information and Control 65, pp. 182-215, 198.7. M. Rusinowitch. Theorem-proving with resolution and superposition. In Proc. of the International Conference on Fifth, Gen,eration Computer Sy.stems, 1988. H. Zhang, D. Kapur, and M.S. Krishnamoorthy. A mechanizable induction principle for equational speci- fications. In E. Lusk and R. Overbeek, ed.: Proc. 9th CADE, pp. 162-181, LNCS 310, 1988. We have presented new methods for inductive reason- ing. These methods try to capture as much as possible the power of simplification. Moreover, when the axioms KOUNALIS AND RUSINOWITCH 245
|
1990
|
37
|
953
|
Skolem Functions and Equality in Automated Deduction * William McCune Mathematics and Computer Science Division Argonne National Laboratory Argonne, Illinois 60439-4801 mccune@mcs.anl.gov Abstract We present a strategy for restricting the application of the inference rule paramodulation. The strategy ap- plies to problems in first-order logic with equality and is designed to prevent paramodulation into subterms of Skolem expressions. A weak completeness result is pre- sented (the functional reflexive axioms are assumed). Experimental results on problems in set theory, com- binatory logic, Tarski geometry, and algebra show that the strategy can be useful when searching for refuta- tions and when applying Knuth-Bendix completion. The emphasis of the paper is on the effectiveness of the strategy rather than on its completeness. 1 Introduction Most inference rules and strategies for guiding or re- stricting searches in automated deduction are syntac- tic in spirit. Examples are inference rules that gen- erate positive clauses only, unrestricted back-chaining searches, restriction strategies that consider orderings on terms, and guidance strategies that focus on clauses with few symbols. Notable exceptions, which use inter- pretations or the intended meaning of the symbols, are semantic inference rules, inference rules with built-in knowledge of the intended domain, the set of support strategy for starting the search with specific clauses, and ad hoc weighting methods for controlling searches. We present a paramodulation strategy which has a semantic motivation in that a distinction is made be- tween Skolem functions and ordinary functions. The strategy is to prevent paramodulation (equality substi- *This work was supported by the Applied Mathematical Sci- ences subprogram of the Office of Energy Research, U.S. De- partment of Energy, under Contract W-31-109-Eng-38. tution) into proper subterms of Skolem terms. Human reasoners tend to treat the objects corresponding to Skolem terms as atomic, and it appears that programs can benefit by making a related distinction. One can easily show the completeness of the strat- egy for otherwise-unrestricted paramodulation in the presence of the functional reflexive axioms. The proof rests on the (not well-known) fact [BKS85, Ben891 that equality axioms are not required for Skolem functions. The focus of this work is to try to determine the prac- tical effectiveness of the strategy. The restriction strategy was added to the deduc- tion system OTTER [McCSO], and experiments were conducted on problems in set theory, combinatory logic, Tarski geometry, and Knuth-Bendix completion. The completeness result does not yet apply to Knuth- Bendix completion problems, but our experiments in- dicate that the strategy can be valuable for those prob- lems anyway. Preliminary work on this topic appeared in [McC89]. 2 Preliminaries We assume a resolution/paramodulation refutation system for first-order logic with equality. If the for- mula representing the problem in question involves ex- istentially quantified variables or is not in conjunctive normal form, it is preprocessed. A standard way to preprocess consists of three steps: conversion to nega- tion normal form, Skolemization, then conversion to conjunctive normal form. The Skolemization proce- dure is the interesting step. Existentially quantified variables are replaced with new Slcolem functions and Skolem constants. Arguments of the Skolem functions are the universally quantified variables in whose scope the existential quantifier occurs. A term is a Skolem 246 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. expression if its leading function symbol is a Skolem function symbol, and Sk(F) is any Skolemization of a formula F. The result of preprocessing is a conjunction of clauses, whose variables are implicitly universally quantified. (Variables in clauses start with ‘U’--(Z).) The key property of Skolemization is that unsatisfiabil- ity is preserved: Sk(F) unsatisfiable (E-unsatisfiable) if and only if F is unsatisfiable (Eunsatisfiable). If the problem in question involves equality, one can either apply resolution inference rules with the equal- ity axioms, or apply specialized inference rules that operate on equalities. The equality axioms for a set of function and relation symbols are reflexivity, sym- metry, transitivity, and a substitution axiom for each argument position of each function symbol and rela- tion symbol. X=X x#y v y=x x#y v y#z v x=z X#Y v f-(.-,x ). . .) = f(. . ., y,. . .) x # y v lP(. . . ,x, . . .) v P(. . . , y, . . .) EqAx(F) is the set of equality axioms for the function and relation symbols of a formula F. Although equal- ity substitution axioms for Skolem functions have tra- ditionally been included, it is known [BKS85, Ben891 that they are not necessary. The most widely used inference rule for equality is parumodulation [WOLB84], which generalizes equality substitution to include unification and extra literals in the spirit of resolution. Let N and L be disjunctions of literals, and let M be a literal containing a term t2. Paramodulation applies from clause tl = T V L into clause M[t2] V N if tl and t2 have most a general unifier CT. The paramodulant is (M[r] V N V L)a. The functional reflexive axioms for a set of func- tion symbols consists of an equality f (xl, . . . , x,) = f(Xl,... , x,) for each n-ary function symbol f. Let S be a set of clauses involving equality. The following are basic results in logic and orem proving. automated the- o S is E-unsatisfiable if and only if S&EqAx(S) is unsatisfiable. o Paramodulation is a complete inference rule for equality. In particular, if S is an E- unsatisfiable set of clauses, there is a paramodula- tion/resolution/factoring refutation of S & (x = x). (Some useful restrictions of paramodulation, such as the set of support strategy, require the presence of the functional reflexive axioms for completeness. Even when required for complete- ness, they are rarely used in practice.) 3 The Restriction Strategy Although the following result is basic in logic, it ap- pears in just one [Lov’?~] (as far as we can tell) of the standard texts on resolution-based automated theorem proving, and it is not widely used by the automated theorem proving community. A first-order formula F is Eunsatisfiable if and only if F&EqAx(F) is unsat- isfiable. (Note that F is not necessarily Skolemized.) An immediate consequence of that result is that the equality substitution axioms can be fixed before Skolemization occurs; in particular, equality substitu- tion axioms are not required for the Skolem functions. In fact, the following five statements are equivalent. (1) F is E-unsatisfiable. (2) F&EqAx( F) is unsatisfiable. (3) Sk(F) is Eunsatisfiable. (4) Sk(F&EqAx(F)) is unsatisfiable. (5) Sk(F)&EqAx(Sk(F)) is unsatisfiable. Research in automated theorem proving with equal- ity has focused on the equivalence (3) iff (5)) because clause sets rather than the first-order formulas are usu- ally taken as given. For example, the widely used and cited problem set [MOW761 presents clauses, including equality axioms for Skolem functions. The fact that equality axioms are not needed for Skolem functions can be turned into a strategy for restricting paramodulation, because paramodulation into a term corresponds to a sequence of resolution steps with equality axioms. For example, let f be a 3- place function symbol, and consider a term f (t 1, t2, ts). Paramodulation into t2 or one of its subterms corre- sponds to a sequence of resolution steps with equal- ity axioms. One of the equality axioms is x # y V f (x1, x, x3) = f (xi, y, xs), because paramodulation is into the second argument of f. If f is a Skolem func- tion, that equality axiom need not be present, indi- cating that the paramodulation inference need not be made. The Strategy. Never paramodulate subterm of a Skolem expression. into a proper MCCUNE 247 An Outline of the Completeness Proof. If one assumes unrestricted paramodulation as a starting point, it is not difficult to show the completeness of the restriction. Let S be an E-unsatisfiable set of clauses; let F be the set of function and relation symbols, excluding Skolem function symbols, of S; let EqAx be the equality axioms for F; and let FRA be the functional reflexive axioms for F. Let R be a hy- perresolution/factoring refutation of S&EqAx. Such a refutation exists because S&EqAx is unsatisfiable and hyperresolution/factoring is complete. R can be transformed-as in [CL73, pp. 171-172]-into a hy- perresolution/factoring/paramodulation refutation of S& (2 = 2) &F RA. Each hyperresolution inference with an equality axiom can be directly transformed into a paramodulation inference that satisfies the re- striction. Motivation. The restriction strategy has intuitive appeal as well. The arguments of Skolem functions should serve as place holders for the objects on which the “existing” object depends-equality substitution should not be applied to them. For an example in set theory, if A e B is assumed, one can conclude that there is an object c in A that is not in B. In clauses, c is a Skolem function applied to A and B. If A and B are complicated expressions, one might wish to reason about them by applying equality sub- stitutions, but not to the occurrences in the Skolem expression representing c-those should be fixed when c is “chosen”. If A and B are not ground when c is chosen, further inferences should be free to instantiate the Skolem expression. With this view, the arguments of Skolem functions serve as constraints on unification and constraints on inference. 4 Applications Experiments and OTTER [McC90] is a resolution/paramodulation the- orem prover for first-order logic with equality. The paramodulation restriction strategy was installed in OTTER, and a number of experiments were conducted to try to determine the value of the strategy. Four application areas were chosen for study: sev- eral versions of a problem in set theory, two problems in combinatory logic, a problem in Tarski geometry, and a benchmark algebra problem in complete sets of reductions. The set theory and geometry prob- lems are non-Horn and require a mixture of resolution and paramodulation; in addition, the set theory prob- lems use defined concepts. The combinatory logic and algebra problems require no resolution because they are presented as equality units; the algebra problem requires demodulation (term rewriting) and is not a search for a refutation. 4.1 Set Theory The problem, to show that the composition of two functions is also a function, is the naive version of one of the lemmas in [BLM+86]. It is an easy problem, but OTTER has difficulty with defined concepts, non-Horn clauses, and mixtures of equality and other relations, all of which occur in this kind of set theory problem. Definitions of relation, single-valued set, function, and composition. VR(relation(R) t-, V’u(u E R ---+ 3x3y(u = (x, y)))) VS ( singval(S) * VxVyVz CL (5, Y) E S& (x,z)ES ] -y=z)) VF(function(F) w relation(F) & sing&(F)) VuVFVG u E F o G c--) 3x3y3z Property of ordered pair. vxvyv%vw((x,y) = (z, w) + 2 = % & y = 20) Theorem. VFVG(function(F)&function(G) --+ function(F o G)) Four versions of the theorem were considered. Ver- sions ST-l and ST-2 use the clauses shown below. Ver- sion ST-3 does not use the defined relations relation, sing&, or function (the theorem is stated in terms of the composition, ordered pair, and equality). Version ST-4 is entirely in terms of ordered pair and equality. Table 1 contains a summary of the results. Clause form of the denial of the theorem. (Function symbols starting with the letter f are Skolem function symbols .) 248 AUTOMATEDREASONING 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. 17. 18. 19. 20. X=X -relation(z) V u # z V u = (f7(2, u), f8(2, u)) relation(z) V f9(z) E 2 relation(z) V f9(2) # (z, y) ~singvf.zz(x) v (u,v) fi! x v (21,l.u) fz x v 2, = w singvuZ(x) v (fl(EE),f2(a;)) E z singvuZ(x) v (fl(x),f3(x)) E x singvuZ(x) v f2(z) # f3(2) -~function(x) V relation(z) -function(x) v singvuZ( x) function(x) V ~reZution(s) V 3G2gvuZ(x) 2 e Y 0 x v z = (f4(z, 2, Y), f6(z, 2, Y)) 2 $!YOX v (f4(z,2,y),fS(z,r:,y)) E x 2 tz Y 0 x v (f5(& $9 Yh f6(& 2, ?I)> E Y aEyox v ~#(wJ> v ( u, v) 4 x v (VJ) e Y (w) # (us v) v x = u (xc, Y) # (u, 4 v Y = ?J funchon( F) function(G) -function(F o G) Table 1: Set Theory 4.2 Combinatory Logic and Fragments Combinatory Logic (CL) is closely related to the un- typed X-calculus. There are two constants S and I<, and one binary operator apply. Terms are nor- mally written without the operator, and when paren- theses are omitted, association to the left is assumed. For example, the term appby(appby(a, b), appZy(c, d)) is normally written ub(cd). Many interesting first-order equational theorems in CL can be found in [Smu85]. Problem W, versions W-l and W-2. In combinatory logic, find a combinator W with the property Wxy = zyy. Version W-l uses a finely tuned search strategy for problems of this type, and W-2 uses a more naive search strategy. vxvyv%(sxy% = xz(yz)) VxVy(Kxy = 2) Theorem. %VVxVy(Wxy = xyy) Denial of the theorem in clauses, with explicit function symbol for apply (f and g are Skolem functions, and Ans(z) is an answer literal). 1. ++@, 4, Y), 2) = 445 4, U(Y) 4) 2. u(u(K, x), y) = x 3. +4? f (4, g(4) # 44f (4 9(4), g(4) v A44 If axioms different from those for S and I< are used, the system is in general weaker than CL and is called a fragment of CL. Problem FP, versions FP-1 and FP-2. Find a fixed point combinator in the fragment {Q, M}, with QXYX = y(x:z) and Mx = 2~. Version FP-1 uses a finely tuned search strategy for problems of this type, and FP-2 uses a more naive search strategy. Theorem. 3OVx(Ox = x(0x)) Denial of the theorem in clauses, with explicit function symbol for apply. (f is a Skolem function). 1. u(+(Q> 4, Y), 2) = a(~, +, 4) 2. u(M, 2) = u(x, 2) 3. +, f(4) # a(f@), 46 f(4)) v A44 Table 2: Combinatory Logic Time ] Time with-restriction ] 9 seconds 9 seconds (no proof) 12 seconds 1 second 1 second 50 seconds 3 seconds 4.3 Complete Sets of Reductions By setting the appropriate options, OTTER can be made to search for a complete set of reductions with the Knuth-Bendix procedure. The completeness ar- gument as presented does not directly apply in this context, because the goal is a canonical term-rewriting system rather than a refutation. However, the restric- tion strategy can be directly applied, because the com- putation of critical pairs is itself a restricted form of paramodulaion. A benchmark completion problem [Chr89]. Given an associative system with 24 left identities and 24 right inverses, find a complete set of reductions. The 24 in- verses can be clearly interpreted as Skolem functions. Paramodulation into proper subterms of inverse ex- pressions was prevented, but simplification of those subterms was allowed. MCCUNE 249 f (f (6 Id7 4 = fh f (YY 4) 5 Remarks f(el,x) = 2 f(e2,x) = x . . f( e24, x) = x f(x, 91(x:)) = el f (x,92(x)) = e2 . . f(x, 924(x)) = e24 The time required to find a complete set of reduc- tions was 474 seconds without the restriction and 56 seconds with it. The same set was found. 4.4 Tarski Geometry Tarski developed and studied several first-order axiom- atizations of elementary geometry-we used the ver- sion reproduced in [Wos88]. The domain is points in the plane, and the primitives are a S-place relation “be- tween” and a 4-place relation “equidistance of 2 pairs of points”. We experimented with test problem 10 in [WosSS], the five point theorem. Even though equal- ity relation and several Skolem functions are present, the restriction strategy had little or no effect in any of the comparisons we made. Part of the reason is that there are few occurrences of equality in the axioms and equality plays a small role in the proof of the theorem. Researchers in automated deduction usually start with or are presented with clauses rather than the fully quantified formulas from which they came (for exam- ple [MOW76]). In th e algebra completion problem, it is clear that the 24 inverses can be interpreted as Skolem functions, but it is not always obvious whether a function symbol is a Skolem function symbol. A par- tial solution is presented in [McC88], which contains a procedure that attempts to “un-Skolemize” a set of clauses-that is, eliminate function symbols by intro- ducing existentially quantified variables, while main- taining unsatisfiability. Such function symbols can be interpreted as Skolem functions, and the strategy can be applied to them. We conclude with several points on enhancements and e related work. We believe that the strategy can be shown to be complete without the presence of the func- tional reflexive axioms. One attack, suggested by Dan Benanav [BenSO], is to define paramod- ulation so that all occurrences of the instantiated “into” term are replaced and use a version of the lifting lemma that does not require the functional reflexive axioms. 4.5 Summary of Experimental Results It is difficult to evaluate the effectiveness and general- ity of new ideas in automated theorem proving. The fact that a new strategy performs well on a particu- lar problem is little indication of its performance on semantically or syntactically similar problems. The Skolem function restriction strategy had a positive ef- fect in three of the four areas that were considered. In none of the experiments did the strategy have a negative effect. In particular, we have not found any cases in which the strategy blocks a refutation or inter- feres in any other way with the search for a refutation (even though the functional reflexive axioms are never included and other restrictions are sometimes applied). A refinement of the strategy was suggested, also by Benanav [BenSO], in which the relevant func- tions are the ones with just variables as arguments in the input clauses, rather than Skolem functions. This is analogous to the unnecessary equality ax- ioms studied in [Ben89]. Should demodulation (term rewriting, simplifica- tion) be prohibited inside of Skolem expressions when searching for a refutation? Is the strategy compatible with the Knuth-Bendix completion procedure ? In particular, can critical pair computation and/or simplification be pre- vented inside of Skolem expression? If not, is there a related restriction that is compatible? The consequences and completeness of the restric- tion strategy have not yet been analyzed for Knuth- Bendix completion. However, the algebra completion experiment shows that the restriction can be useful in practice even if it is not complete. When the re- stricted procedure terminates, we do not in general know whether the resulting set is canonical. However, the unrestricted procedure can then be applied to the resulting set to check whether it is canonical; the cost of such a check is very small. Can the restriction shed any light on the prob- lem of searching for models/counterexamples of clauses containing Skolem functions? References [Ben891 Dan Benanav. Recognizing Unnecessary Inference. PhD thesis, Rensselaer Poly- technic Institute, 1989. 250 AUTOMATEDREASONING [BenSO] [BKS85] [BLM+ 861 [Chr89] [CL731 [Lov78] [McC88] [McC89] [McCSO] [MOW761 [Smu85] Dan Benanav, January 1990. communica- tion. [WOLB84] Larry Wos, Ross Overbeek, Ewing Lusk, and James Boyle. Automated Reasoning: Introduction and Applications. Prentice- W. Bledsoe, K. Kunen, and R. Shostak. Completeness results for inequality provers. Artificial Intelligence, 27~255-288, 1985. Hall, Englewood Cliffs, N.J., 1984. [Wos88] Larry Wos. Automated Reasoning: 33 Ba- sic Research Problems. Prentice-Hall, En- glewood Cliffs, N.J., 1988. Robert Boyer, Ewing Lusk, William Mc- Cune, Ross Overbeek, Mark Stickel, and Larry Wos. Set theory in first-order logic: Clauses for Gijdel’s axioms. Journal of Au- tomated Reasoning, 2(3):287-327, 1986. Jim Christian. Fast Knuth-Bendix com- pletion: A summary. In N. Dershowwitz, editor, Proceedings of the 3rd Interna- tional Conference on Rewriting Tech- niques and Applications, Springer- Verlag Lecture Notes in Computer Science, Vol. 355, pages 551-555, New York, 1989. Springer-Verlag. C.-L. Chang and R. C.-T. Lee. Symbolic Logic and Mechanical Theorem Proving. Academic Press, New York, 1973. Donald Loveland. Automated Theorem Proving: A Logical Basis. North-Holland, Amsterdam, 1978. William McCune. Un-skolemizing clause sets. Information Processing Letters, 29:257-263, November 1988. An early ver- sion appears as Argonne National Lab- oratory Tech. Memo ANL/MCS-TM-93, 1987. William McCune. Skolem functions and equality. Association for Automated Rea- soning Newsletter no. 12, Argonne Na- tional Laboratory, May 1989. William McCune. OTTER 2.0 users guide. Tech. Report ANL-90/9, Argonne Na- tional Laboratory, Argonne, Ill., March 1990. John McCharen, Ross Overbeek, and Larry Wos. Problems and experiments for and with automated theorem-proving pro- grams. IEEE Transactions on Computers, C-25(8):773-782, August 1976. Raymond Smullyan. To Mock a Mocking- bird. Knopf, New York, 1985. MCCUNE 251
|
1990
|
38
|
954
|
Automatically Generating Universal ttachments Through Compilation Karen L. Myers Department of Computer Science St anford University Stanford, California 94305 myers@neon.stanford.edu Abstract Universal attachment is a general-purpose mechanism for integrating diverse representation structures and their associated inference programs into a framework built on logical representations and theorem proving. The integration is achieved by links, referred to as uni- versal attachments, that connect logical expressions to these structures and programs. In this paper, we de- scribe a compilation-based method for automatically generating new programs and new universal attach- ments to those programs given a base set of existing programs and universal attachments. The generation method provides the means to obtain large collections of attachments and attached programs without the tra- ditional specification overhead. As well, the method simplifies the task of validating that a collection of at- tachments is correct. 1 Introduction Universal attachment [Myers, 19901 is a mechanism for integrating diverse representation and reasoning tech- niques into a framework based on logic and theorem proving. The motivations for using universal attach- ment are increased inferential efficiency and expanded representational capabilities. Following in the tradi- tion of previous attachment methods [Green, 19691 [Weyhrauch, 19801, universal attachment centers on the notion of ‘attaching’ procedures and data struc- tures to logical expressions. When expressions having attachments are encountered during theorem proving, the attached procedures are executed on the attached data to directly evaluate the logical expressions rather than relying on further deduction. Universal attach- ment is a more expressive mechanism for merging pro- cedures and data structures into a theorem prover than previously defined attachment techniques, and as such supports a much broader class of attachments. This paper describes a method for automatically generating both new programs and new universal at- tachments to those programs. The general problem of automatically producing attachments and attached programs is extremely difficult. We present a method that relies on the existence of a base set of attach- 252 AUTOMATEDREASONING ments and attached programs. The method exploits the idea that concepts are often hierarchically defined. In particular, if a given logical expression 4 is defined in terms of subexpressions 41,. . . , 4, all having at- tachments, then compilation techniques can be used to generate an attached program for 4 that calls the attached programs for the (bd’s. Attachments to these newly generated programs are obtained by appropri- ately combining the attachments defined for the c$~‘s. An automated generation mechanism is important for several reasons. Such a mechanism can be used to create a large collection of attachments and attached programs, thus providing the computational advan- tages associated with such a collection but without the specification overhead. Another benefit relates to the correctness of attachments, where correctness means that the attached programs and the data upon which the programs operate embody the appropriate seman- tics for the expressions to which they are attached. Provided that the generation process is sound, the task of validating the correctness of a collection of automat- ically generated attachments reduces to that of validat- ing the smaller initial set of attachments. We begin in Section 2 by describing universal attach- ment. Section 3 outlines the generation process and conditions for its applicability, while Section 4 evalu- ates the approach taken. The automatic generation method has been implemented as part of a universal attachment system built on top of the KADS theorem prover [Stickel, 19881. 2 Universal Attachment Before presenting the compilation-based generation method, we first summarize universal attachment and describe the condition of factorability required for the method to succeed. 2 .l A Definition of Universal Attachment Definition 1 (Universal Attachment) A univer- sal attachment is a five-tuple represented as (4h>-,4,F) - (PAD) From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. where q.S[xl,..., x,J is the attachment pattern, F is the filter set, p is the attached program, A is the attachment map and D is the detachment map. The attachment pattern +[zr, . . . , x~] is a logical ex- pression (a relational, functional, quantified or boolean expression in some logical language L) defined over the distinguished variables xl, . . . , x~. Distinguished variables are schema variables ranging over the terms in the logical language being employed. As a matter of convenience, we will assume that the distinguished variables for an attachment pattern are simply the vari- ables appearing in the pattern (i.e. the distinguished variables for the term pZus(x,y) are x and y). The fidter set F is a collection of constraints or filters on bindings to the distinguished variables in 4, rep- resented as f [q, . . . , x,.,]. The language for expressing filters can be defined independently of the universal attachment framework, thus a different filter language can be utilized according to the nature of the appli- cations being considered. We present a sample filter language and its corresponding definition of filter sat- isfaction later in this section. The domain of the universal attachment, namely the set of logical expressions for which the univer- sal attachment is defined, is determined jointly by the attachment pattern and the filter set. For F = {fl[xl, . . . , xla], . . . ,fm[xl,. . . ,x,J), the domain of is the set of logical expressions $$~t.t.Y,~~~tL2re fl[tl, . . . ,&I,. . . ,fm[tl, . . . , tn] are satisfied. The attached program p is the name of the program to be used in the attachment process. The attachment map A takes the list of bindings to the distinguished variables as input and generates the appropriate set of parameters for p (the attached data). The detach- ment map translates the result of evaluating p on the attached data to the appropriate expression in the log- ical language (the value of the universal attachment). The attachment and detachment maps provide a very important service in that they translate between logi- cal terms and structures used to represent those terms outside of the theorem prover. For this reason, we refer to them as the transdation maps. The interpretation of the attachment (1) is that a logical expression o in its domain will be evaluated by first executing p on the parameters obtained by apply- ing the attachment map to the bindings of the distin- guished variables, then translating the result according to the detachment map, and finally substituting that value back in for (Y. 2.2 The Filter Language FL Before considering an example of universal attachment, we first describe a sample filter language, FL, defined for a logical language L. More information on both alternative filter languages and the advantages of using filter languages can be found in [Myers, 19901. The metalevel filter language -TL: is built on the assumption that filters can be specified for a dis- tinguished variable independently of all other distin- guished variables, i.e. filters can be written in the form f[xi]. The language consists of the predicates atomic(x), sort(x,s), and standard-name(x,s), with their satisfaction defined as follows:’ Definition 2 (Filter Satisfaction in FL) A term t satisfies a filter f in FL ifl 1. f is atomic(t) and t is a logical constant symbol in L 2. f is sort(t,s) and t has sort s. 3. f is std-name(t,s) and t is a standard name for sort S. The filter atomic requires t to be a constant symbol in L. The filter sort dictates that t be of sort s; the corresponding sort information is included as part of L. Standard name filters are used to make syntactic distinctions within sorts. The user can associate a set of standard names with a sort by making the appropri- ate specifications in L. For example, we might specify that all numeric representations of integers within our logical language are standard names for the sort int of integers. The filter std-name(t,s) dictates that t must be a member of the set of standard names for sort s. To appreciate the need for standard names filtering, con- sider the logical constant the-pope’s-fuvourite-integer. Although this constant is of sort int, we would not want to attach to expressions in which this constant is bound to a distinguished variable since we don’t know the specific number that this constant denotes. We can eliminate such attachments by excluding this constant from the standard names for int. 2.3 A Graph Example The following example illustrates how universal attach- ments can be applied. Example 1 (Path Connectivity) Consider a directed graph whose edges are described by the axiom edge(a, b) A edge(a, c) A edge(b, c) A edge(c, d) A edge(d, b) Here, the constants a, b, c and d denote particular nodes in the graph. Now suppose we define a logical relation path(x, y) in terms of the relation edge such that path(x, y) holds exactly when there is a sequence of edges connecting x to y. To answer queries about paths in the graph we can create a universal attachment. First, we define the LISP structure gr to be the following edge-based representation of the graph described by edge: ‘Throughout this document, sans-serif font is used for expressions in 3’~, italica’aed text indicates expressions in the logical language C, and typewriter-style font indi- cates an attached program or data. MYERS 253 (def var gr ‘((a (b cl> (b (c)) (c (d)) (d (b)))) . We also need a LISP function connp that takes two nodes and an edge-based representation of a graph as parameters; the function call (connp ni n2 g) re- turns t if nl and n2 are connected by a path in g, and nil otherwise. Finally, we require a metalevel func- tion h that maps logical representations of nodes onto the LISP representation of those nodes (i.e. h(a) = a, h(b) = b, etc). Using these components, we can create the universal attachment: (@h(c, y), F@“) + (connp,AP”ih, D”f) (2) Path = { st -name(x, node), std-name(y, node)} d Apath@, Y)) = (h(X)> h(Y), IF) - The domain of this universal attachment is the set of instances of path(x,y) where x and y are bound to stan- dard names of sort node. The attachment map Apath maps a pair of logical terms denoting nodes into the triple consisting of the LISP representation of those nodes and the LISP representation of our graph, gr. The detachment map D tf translates the LISP atoms t to the logical truth value true and nil to false. The at- tachment (2) states that instances of path(x,y) where x and y are bound to standard names for sort node should be evaluated by applying connp to the argu- ments h(x), h(y) and gr. 2.4 Factorable Attachment Maps The general definition of an attachment map A pre- sented above, whereby A translates the list of bindings to distinguished variables into the list of parameters for the attached program, is very broad. In order to facilitate the automatic generation process, we impose the restriction of factorability on attachment maps. Definition 3 (Factorability) An attachment map is factorable i$ it can be represented us a collection of unay and zeroury functions on bindings to distin- guished variu bles. The attachment map Apath in Example 1 is fac- torable, being composed of the unary function h ap- plied to bindings to x, h applied to bindings to y, and the constant function gr with value gr. We will refer to the individual unary and zeroary functions as the com- ponent translations of the attachment map. Factorabil- ity guarantees that attachment maps are definable in terms of bindings to individual distinguished variables, independent of all other bindings. As will be seen in Section 2, this independence is important for the com- pilation process. The factorability requirement is not burdensome; virtually all standard applications of uni- versal attachments use factorable attachment maps. For this document, we assume a standardized repre- sentation of attachment maps. Each map consists of a list of ordered pairs, where the first entry of the pair is a component translation function and the second entry is the distiniguished variable for which the component translation is defined. If the component translation is zeroary, than the second entry is simply 0. Using this notation, we would represent the attachment map in Example 1 = ((b) (hy) (gd)). 3 The Generation Method In this section we describe both the generation method and the compilation criteria that a logical expression must satisfy for the method to apply. For simplicity, we assume that all attached programs are written in LISP. The generation method derives from the observation that concepts are often hierarchically defined. Given a logical expression 4 defined in terms of subexpressions having attachments, the method employs compilation techniques to produce an attached program for 4 that calls the programs attached to 4’s subexpressions. A universal attachment from 4 to the generated pro- gram is obtained by merging the subexpressions’ at- tachments in a manner that depends on the logical structure of f$. We begin by stating a concise definition of the com- pilation criteria. This definition will serve as a refer- ence for the remainder of the section. Following the definition, we provide a thorough explanation of its parts (in particular the concepts of weak satisfaction, nesting constraints, preserving truth values and enu- merubility used in the criteria are defined) as well as a full description of the generation process. Definition 4 (Compilation Criteria) A logical ex- pression C$ satisfies the compilation criteria i$ one of conditions Cl, C2, or C3 is met: Cl There is un attachment (a[~~,. . . , xk], Fa) + (p”, A”, Da) such that: Cl.1 Q[Xl, . . . , xk] unifies with 4, producing bind- ingsxl :tl, . . . . xk :tk. Cl.2 For each filter f[xJ E Fey, f[tJ is weakly satis- fied. Cl.3 Each non-atomic ti satisfies the compilation criteria. Cl.4 The detachment maps in the attachments de- fined by Cl.3 satisfy the nesting constraints. C2 q5 is a boodean expression, either A,“,,P$“, , * . . , ti,], or lPb Vy=,ai[tj, . . . , th,], where: C2.1 Each ,& satisfies the compilation criteria. 2This form of compilation is stronger than that associ- ated with logic programming [Warren, 19771. First of all, logic programming compilation is limited to Horn clauses. Furthermore, the compilation of a logic program produces an encoding in terms of pre-defined primitives (such as uni- fications and stack manipulations) of the search process fol- lowed by the interpreter, while the compilation we propose builds code from arbitrary attached programs. 254 AUTOMATEDREASONING C2.2 The attachments defined by C2.1 for each pi have detachment maps that preserve truth values. C3 4 is a quantified expression of the form 32. Q or V.Z. a such that: C3.1 a satisfies the compilation criteriu. C3.2 z is bound to a distinguished variable in the attachment pattern of the attachment defined by c3.1. C3.3 The terms satisfying the filters specified for z in the attachment defined by 63.1 are enumer- able. 63.4 The attachment defined by C3.1 has a detach- ment map that preserves truth values. Cl: Base Case Cl constitutes the base case of the definition. For a logical expression 4 to be compilable in the base case, condition Cl.1 requires the existence of an attachment (+a, * * . , xk], Fa) - (p”, A”, DCY) (3) where 4 unifies with CV[X~, . . . , Xk]. Condition Cl.2 further requires that if f[xi] is in F” and xi is bound to ti in the unification for C1.l, then f[ti] must be weakly satisfied. In contrast to the notion of satisfaction from Definition 2, weak satisfaction only requires that the nonvariable components of a term satisfy a given filter. This relaxation of the satisfaction criteria accounts for variables in the expression being compiled. For the filter language FL, a term t weakly satisfies atomic(t) iff t is a variable or logical constant name, and t weakly satisfies std-name(t,s) iff t unifies with a standard name for sort s. Weak satisfaction is identical to standard satisfaction for the filter sort(t,s). The condition Cl.3 accounts for the binding of dis- tinguished variables to non-atomic functional expres- sions in 4. In general, an expression 4 that satisfies Cl.1 will have the form (Ylol[t:,...,t~,],...~k[t~ ,..., t;,31 where each ,&[ti, . . . , tki] is either a variable, a con- stant, or a non-atomic functional expression. A pro- gram that evaluates 4 must necessarily include code to evaluate every non-atomic Pk[i$, . . . , t&l. Thus the nesting of functional expressions in 4 invalidates the compilability of 4 unless an attached program exists to evaluate these expressions, or an appropriate pro- gram can be created through compilation. In either case, the nested expressions must satisfy the compil- ability criteria, prompting condition C1.3.3 If we let the set Z index the non-atomic &[ti;,.. . , tii], condition Cl.3 guarantees the existence 3Note that Cl.3 makes the base case of the definition it- self recursive. The well-definedness of the criteria is ensured since the base case recursion parallels the logical structure of q5 and hence must be finite. of the attachments:4 (Ph, * * - , x nail, Fpi) - (pp’, Api, D”l) , i E z. (5) Cl.4 requires that these attachments satisfy certain nesting constraints. The nesting constraints ensure the soundness of consolidating programs attached to nested functional terms with p” from (3) into a single attached program for the entire expression 4. We can express the nesting constraints as follows: Definition 5 (Nesting Constraints) For every i E Z: NC1 The range of DPi must satisfy the filters in F” defined for xi. NC2 If (m, xi) E A” and i E Z, then m( Dpa(c)) = c for every c in the range of the function pp,. Condition NC1 states that if ,&[tf , . . . , tii] is a non- atomic expression bound to the distinguished variable xi then the range of the detachment map DPi must sat- isfy the filters defined for xi. This constraint ensures that substituting the values produced by the attach- ments in (5) for the corresponding nested expressions in c@l[t:, . . . , t&l,. . . pk[tt, . . . , ti,]] yields an expres- sion in the domain of the attachment (3). Condition NC2 requires that the composition of the component attachment map m defined for a distinguished vari- able xi and the detachment map Dpa for the nested expression oj[ti, . . . , ti,] is the identity map. This con- straint ensures that the attachments in (5) and (3) have the same interpretation for attached symbols that they both utilize. The program generated for 4 is simply an ap- plication of p” with nested function applications of the ppS for i E Z used to evaluate the non-atomic Pip”,, * * . , thi]. Defining the parameter list for the new program is somewhat complex. In particular, a param- eter must be defined for each distinct component trans- lation map applied to a distinguished variable bind- ing. The factorability of the attachment maps makes it possible both to identify these translations and to build the required new attachment map that accounts for all such translations; details are in [Myers, 19901. The detachment map is simply Da from (3) while the new filter set is obtained by ‘merging’ the filter sets for the nested expressions and F”. The merging process is an enhanced union operation that eliminates filters subsumed by other filters in the union. For example, sort(t,sl) subsumes sort(t,s2) if sort s2 contains sort sl. Example 2 Let int and rat be functions that map log- ical representations of integers and rationals onto ap- propriate LISP representations of those numbers. Using 4These attachments may be in the set of predefined at- tachments or may be generated recursively by the com- pilation process. The guaranteed attachments for subex- pressions in the recursive cases C2 and C3 also have this characteristic. MYERS 255 int and rat we can specify attachments for the expres- sions add(z, y) and div(x, y), which have the intended in- terpretations of integer addition and rational division. Let add and div be LISP programs of two inputs that compute integer addition and rational division, and int and rat be the sorts of integer and rational numbers. By defining Aint along with Arat = ((int, cc), (int, y)) and Dint = int-‘, = ((rat, x), (rat, y)) and Drat = rat-‘, we can create the attachments: Wd(x, Y>, w- name(z, iinn?, sfd-name(y, int)}) --f (add,A , Dint) (div(x, y), {std-name(z, rat), std-name(y, rat)}) + (div, Arat, Drat) . Now consider the logical definition Vxy. avg(x, y) = div(add(x, y), 2) . The expression div(add(x,y)) satisfies the base case of the compilation criteria. Using the generation method, we obtain the following program and attachment: (defun avg-lisp (nl n2) (div (add nl n2) 2))) (avg(x, y), {std-name(x, int), std-name(y, int)}) --) (avg-lisp, Aint , Drat) . C2: Boolean Expressions If 4 is a boolean expression that doesn’t satisfy C1, 4 is still compilable provided that condition 62 is satis- fied. All boolean expressions share the same compila- tion criteria and generation method; here we restrict attention to conjunctive expressions, where 4 has the form Ar=,ai[ti, . . . ,ti.]. Compilation condiiion (22.1 guarantees the exis- tence of attachments (Qi[W - * , xki], F”‘) + (p”*, A”‘, Dai), i = 1,. . . , n. These attachments provide the programs used to con- struct the new attached program for 4. To motivate C2.2, we consider the nature of the pro- gram to be generated for 4. The form of this program will mirror the logical structure of 4: the program con- sists of an application of the LISP function and to the results obtained by evaluating the attached programs P cyi. This strategy is sound only if the values produced by the pai ‘ match’ the notion of truth values utilized in LISP. In particular, when an attached program pQ’ returns t (or nil), then the truth (or falsity) of the cor- responding conjunct should be established. The need for this semantic correspondence motivates the follow- ing definition. Definition 6 (Truth Value Preservation) A function g from a representation language 151 to a representation language ,& preserves truth values i$ g maps truth and falsity in Cl onto truth and falsity, respectively, in CAL. Example 3 The detachment map Dtf defined in Ex- ample 1 preserves truth values from LISP to our logical language: it maps t to true and nil to false. Although there may be many functions that preserve truth values from one language to another, we will des- ignate Dtf as the canonical truth preserving function from LISP to our logical language. Verifying that a de- tachment map D preserves truth values thus reduces to checking that D = Dtf . As noted above, the new attached program for /$,a$;, . . . , t”,,] consists of an application of the LISP function and to the values obtained by evaluating the P cri. In analogy with programs generated for the base case Cl., a parameter is required for each unique trans- lation applied to a distinguished variable binding and the new attachment map is the collection of these translations. The new filter set is the union of the filter sets for the individual conjuncts where subsumed filters are once again removed. The detachment map is the canonical truth value preserving function, Dtf . C3: Quantified Expressions Condition C3 constitutes the compilation criteria for a quantified expression Vz. cv or 3%. cy that fails to satisfy Cl. C3.1 requires the existence of an attachment (+a,...,x~],Fa) ---) (p*,Aa,D”) (6) for the matrix of the quantified expression. The un- derlying idea for compiling quantified expressions is to apply the program p” from the attachment (6) to the attached LISP representations of all possible bindings to the quantified variable z. To make this approach feasible, the quantified vari- able must be bound to a distinguished variable xi in (Y[Xl,... ,4 (C3-2), and the set of terms satisfying the filters in F” defined for za must be enumerable (C3.3). With standard names filters, enumerability is obtained by using the list of standard names defined for the sort of the quantified variable. More complex mechanisms for achieving enumerability are described in [Myers, 19901; these mechanisms use attached struc- tures directly to determine the domain of quantifica- tion. For example, with quantified expressions defined relative to a graph, the domain of iteration can be lim- ited to the set of standard names for nodes in that graph rather than the set of standard names for all nodes appearing in any graph. The new attached program consists of an iteration whose domain is the set of LISP objects obtained by applying the component translation map m defined for zd (i.e. (m, xi) E A”) to the enumeration of terms sat- isfying the filters for xi in F”. At each step, p” is called. For existential quantifiers, the program returns t only if pa evaluates to t for some value in the domain. For universal quantifiers, the program returns nil if a 256 AUTOMATEDREASONING value is found for which pa evaluates to nil and re- turns t otherwise. As with the compilation of boolean expressions, we require that the detachment map D” preserve truth values (C3.4) to ensure that the seman- tics of the iteration process match the semantics of the logical quantifier. The parameters for the new program are identical to those of p” except that the parameter corresponding to the variable of quantification is replaced by a param- eter representing the domain of the iteration. Corre- spondingly, the new attachment map is obtained from A” by replacing the pair (m, xi) by a function that returns the domain of the iteration. The new filter set is obtained from F” by removing filters defined on xi. The new detachment map is Dtf . Example 4 Consider the logical expression Vz. incycle G 3Y. Paw? Y> A PqY, z) * Given the attachment (2) defined in Example 1, the expression 3y. path(z, y) A path(y, Z) satisfies the com- pilation conditions in C3. The compilation process produces the program incycle-lisp defined by (defun incycle-lisp (u v domain) (some #‘(lambda (item) (and (connp u item v) (connp item u v))) domain) ) . The formal parameters u and v to incycle-lisp cor- respond to a node and a graph, respectively. The pa- rameter domain is the list of values over which the iteration is defined. During each step of the itera- tion, the current iterated value item is tested to see if the code fragment (and (connp u item v) (connp it em u v) ) > evaluates to t. This code fragment is produced by recursively compiling the logical expres- sion path(z, y) A path(y, z). The following attachment for incycle is also cre- ated, according to the principles described above: (incycle( {std-name(x, node))) + (incycle-lisp, Aincycle, D”f ) A in”yc’e((~)) = (h(z),gr, ) (a b c d)) . 4 Closing Remarks This paper has presented a compilation-based method for generating new programs and universal attach- ments to those programs from a base set of existing programs and universal attachments. We have tested an implementation of the method in the domain of graph theory. The class of new attached programs and attachments produced by the implementation method has proven to be quite rich. In addition, the generated attachments appear to provide significant gains in the run-time efficiency of the theorem prover. For non-quantified expressions, the compilation pro- cess consolidates all relevant attachments into a sin- gle program. This consolidation eliminates repeated transitions between the theorem prover and the at- tached computational mechanism, thus reducing the total overhead for translations. The programs con- structed for quantified expressions can provide effi- ciency gains for a different reason: by limiting the do- main of iteration for these programs to the relevant terms, the attached programs can be much faster than theorem proving. The only previous attempt at automating the gen- eration of attachments was Aiello’s work on produc- ing new semantic attachments through compilation [Aiello, 198Oa] [Aiello, 1980b]. Because universal attachments subsume semantic attachments, Aiello’s work is necessarily less ambitious than that reported here. In particular, the compilation of quantified ex- pressions is not addressed. Her work also fails to de- limit sufficient restrictions on the class of expressions that are compilable, leading to situations where her method generates programs that are incorrect for the expressions they are designed to evaluate. Acknowledgements I would like to thank Jens Christensen, Nils Nilsson, Eunok Paek and Carolyn Talcott for many useful dis- cussions related to this work. The author is supported by an IBM Graduate Fellowship. References [Aiello, 198Oa] Luigia Aiello. Automatic generation of semantic attachments in FOL. In Proceedings of the First National Conference on Artificial Intelligence, 1980. [Aiello, 1980b] Luigia Aiello. Evaluating functions de- fined in first order logic. In Proceedings of the Logic Programming Workshop, De brecen, Hungary, 1980. [Green, 19691 Cordell Green. Application of theorem proving to problem solving. In Proceedings of the First International Joint Conference on Artificial Intelligence, pages 219-239, 1969. [Myers, 19901 Karen L. Myers. Universal attachment. Forthcoming Ph.D. dissertation, Stanford Univer- sity. [Stickel, 19881 Mark E. Stickel. The KLAUS auto- mated deduction system. In Proceedings of the Ninth International Conference on Automated Deduction, pages 750-751, 1988. [Warren, 19771 David Warren. Implementing PRO- LOG - Compiling predicate logic programs. Tech- nical Report 39, University of Edinburgh, 1977. [Weyhrauch, 19801 Richard W. Weyhrauch. Prole- gomena to a theory of mechanized formal reasoning. Artificial Intelligence, 13:133-170, 1980. MYERS 257
|
1990
|
39
|
955
|
Negotiation and Conflict Resolution in Non-Cooperative Domains Gilad Zlotkin* Jeffrey S. Rosenschein Computer Science Department, Hebrew University Givat Ram, Jerusalem, Israel gilad@humus.huji.ac.il, jeffQhumus.huji.ac.il Abstract In previous work [Zlotkin and Rosenschein, 1989a], we have developed a negotiation protocol and offered some negotiation strategies that are in equilibrium. This negotiation process can be used only when the “negotiation set” (NS) is not empty. Domains in which the negotiation sets are never empty are called cooperative domains; in general non-cooperative domains, the negotiation set is sometimes empty. In this paper, we present a theoretical negoti- ation model for rational agents in general non- cooper at ive domains. Necessary and sufficient conditions for cooperation are outlined. By re- defining the concept of utility, we are able to en- large the number of situations that have a cooper- ative solution. An approach is offered for conflict resolution, and it is shown that even in a conflict situation, partial cooperative steps can be taken by interacting agents (that is, agents in fundamen- tal conflict might still agree to cooperate up to a certain point). A Unified Negotiation Protocol is developed that can be used in all cases. It is shown that in certain borderline cooperative situations, a partial coop- erative agreement (i.e., one that does not achieve all agents’ goals) might be preferred by all agents, even though there exists a rational agreement that would achieve all their goals. Introduction Definition 2 Plans The subject of negotiation has been of continuing in- terest in the distributed artificial intelligence (DAI) community [Smith, 1978; Rosenschein and Genesereth, 1985; Durfee, 1988; Malone et al., 1988; Sycara, 1988; Sycara, 1989; Kuwabara and Lesser, 1989; Conry et al., 19881. The operation of cooperating, intelligent autonomous agents would be greatly enhanced if they were able to communicate their respective desires and A one-agent plan to move the world from. state s to state f in ST is a list [ol, 02,. . . , on] of operations from OP such that f = o,(o,-I(. . .01(s) . . .)). A joint plan to move the world from state s to state f in ST is a pair of one-agent plans (PA, PB) and a schedule. A schedule is a partial order over the union of ac- tions in the two one-agent plans. It specifies that some actions cannot be taken until other actions are com- pleted; because it is a partial order, it of course allows *Supported in part by the Leibniz Center for Research in Computer Science. compromise to reach mutually beneficial agreements. The work described in this paper follows the gen- eral direction of [Rosenschein and Genesereth, 1985; Zlotkin and Rosenschein, 1989a] in treating negotia- tion in the spirit of game theory, while altering game theory assumptions that are irrelevant to DAI. Previous work [Zlotkin and Rosenschein, 1989a] dis- cussed inter-agent negotiation protocols and negotia- tion strategies that were in equilibrium, but could only be used if the s-called “negotiation set” [Harsanyi, 19771 was not empty. Cooperative domains are those in which NS is never empty; in this paper, we present a theoretical negotiation model for general non-cooperative domains (where NS might be empty). General Definitions Two autonomous a.gents A and B share the same world; this world is in some initial state s. Each agent wants the world to satisfy a set of goal conditions. Definition 1 Goals o The goal of agent i E {A, B}, gi, is a set of predi- cates that agent i wants the world to satisfy. 0 Gd stands for the set of world states that satisfy all the predicates in gi. Both agents have the same set of operations OP that they can perform. An operation o in OP moves the world from one state to another; it is a function o: ST + ST where ST is the set of all possible world states. 100 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. simultaneous actions by different agents. If the initial state of the world is s and each agent i executes plan Pi according to the schedule, then the final state of the world will be f. We will sometimes write J to stand for a joint plan (pA, pB). Definition 3 Costs There exists a cost function, Cost: OP --) IN. For each one-agent plan P = [ol, 02,. . ., o,], Cost(P) is defined to be Cizl Cost(ok). For each joint plan J = (PA, PB), Costi( J) is de- fined to be Cost(e). Note that cost is a function over an operation-it independent of the state in which the operation is carried out. This definition, however, is not critical to the subsequent discussion. Our theory is insensitive to the precise definition of any single operation’s cost. What is important is the ability of an agent to measure the cost of a one-agent plan, and the cost of one agent’s part of a joint multi-agent plan. Definition 4 Best Plans e s + f is the minimal Cost one-agent plan that moves the world from state s to state f. If a plan like this does not exist, then s ----f f is undefined. 0 s + F (where s is a world state und F is a set of world states) is the minimal Cost one-agent plan that moves the world from state s to one of the states 2n F: Cost(s ---) F) = min f ~F:s+f is defined Cost(s ---) f) Example: The Blocks World Domain There is a table and a set of blocks. A block can be on the table or on some other block, and there is no limit to the height of a stack of blocks. However, on the table there are only a bounded number of slots into which blocks can be placed. There are two operations in this world: PickUp( i) - Pick up the top block in slot i (can be executed whenever slot i is not empty), and PutDown - Put down the block which is currently being held into slot i. An agent can hold no more than one block at a time. Each operation costs 1.l Underlying Assumptions In [Zlotkin and Rosenschein, 1989a], we introduced several assumptions that are in force for our discussion here as well (the final two assumptions were implicit in previous work):2 1. 2. 3. 4. 5. Utility Maximizer: Each agent wants to maximize his expected utility. Complete Knowledge: Each agent Knows all rel- evant information. No History: There is no consideration given by the agents to the past or future; each negotiation stands alone. Fixed Goals: Though the agents negotiate with one another over operations, their goals remain fixed. Bilateral Negotiation: In a multi-agent en- counter, negotiation is done between a pair of agents at a time. Deals and the Negotiation Set The agents negotiate on a joint plan that brings world to a s tate that satisfies both agents’ goals. the Definition 5 Deals o A Pure Deal is a joint plan (PA, PB) that moves the world from state s to a state in GA n Gg. e A Deal is a mixed joint plan (PA, PB): p; 0 5 p 5 1 EIR. The semantics of a Deal is that the agents will per- form the joint plan (PA, PB) with probability p, or the symmetric joint plan (PB, PA) with probability 1 - p. 0 Ifs = (J:p) is a Deal, then Costi is defined to be pCosti( J)+( l-p)Costj (J) (where j is i’s opponent). e If 6 is a Deal, then Utilityi is defined to be Cost(s + Gi) - Cost&). The utility for an agent from a deal is simply the diflerence between the cost of achieving his goal alone and his expected part of the deal. A Deal S is individual rational ii for all i, Utilityi 2 0. A Deal 6 is pareto optimal if there does not exist un- other Deal which dominates it-there does not exist another Deal which is better for one of the agents and not worse for the other. The negotiation set NS is the set of all the deals that are both individual rational and pureto optimal. These definitions of an individual rational deal, a pareto optimal deal, and the negotiation set NS are standard definitions from game theory and bargaining theory (see, for example, [Lute and Raiffa, 1957; Nash, 1950; Harsanyi, 19771). 1989a]. Future work will further examine the consequences of removing one or more of these assumptions, such as the No History assumption and the Bilateral Negotiation assumption. ZLOTKINANDROSENSCHEIN 101 Conditions for Cooperation A necessary condition for NS to be non-empty is that there is no contradiction between the two agents’ goals, i.e., GA n Gg # 0.3 Th is condition is not sufficient, however, because even when there is no contradiction between agents’ goals, there may still be a conflict be- tween them. In such a conflict situation, any joint plan that satisfies the union of goals will cost one agent (or both) more than he would have spent achieving his own goal in isolation (that is, no deal is individual rational). Example: The initial state can be seen at the left in Figure 1. gA is “The Black block is at slot 2 but not on the table” and gB is “The White block is at slot 1 but not on the table”. Proof. For the proof of this theorem and subsequent theorems, see [Zlotkin and Rosenschein, 1990a]. q When the conditions of Theorem 1 are true, we will say that the situations are cooperative. Redefinition of Utility In non-conflict situations, if neither the min nor the sum conditions are true, then in order for the agents to cooperatively bring the world to a state in GA nGB, at least one of them will have do more than if he were alone in the world and achieved only his own goals. Will either one of them agree to do extra work? It depends on how important each gi is to agent i, i.e., how much i is willing to pa.y in order to bring the world to a state in Gi. In order to achieve his goal alone, each agent has to execute one Pickup and then one PutDown; Cost(s -+ Gi ) = 2. The two goals do not contradict each other, because there exists a state in the world which satisfies them both, as can be seen on the right side of Figure 1. There does not exist a joint plan that moves the world from the initial state to a state that satisfies the twogoals with total cost less than 8--that is, no deal is individual rational. Figure 1: Conflict exists even though union of goals is achievable The existence of a joint plan that moves the world from its initial state s to a state in GA n Gg is a nec- essary condition for NS to be non-empty. When this condition is not true, we will call it a conflict situa- tion. Ways in which this conflict can be resolved will be discussed in the Conflict Resolution section below. The Worth of a Goal Definition 7 Let Wi be the maximum expected cost that agent i is willing to pay in order to achieve his goal gi. We assume that such an upper bound exists. There may be situations and domains in which there is no limit to the cost that an agent is willing to pay in order to achieve his goal-he would be willing to pay any cost (see [Zlotkin and Rosenschein, 1989b]). That situation, however, is beyond the scope of this paper. The declaration of Utility can be usefully altered as follows : Definition 8 IfS is a deal, then Utility,(b) is defined to be Wi - Cost@). The utility for an agent of a deal is the difference between Wi and the cost of his part of the deal. If an agent achieves his goal alone, his utility is the difference between the worth of the goal and the cost that he pays to achieve the goal. Definition 6 Sum and Min Conditions l A joint plan J will be said to satisfy the sum condi- tion if Theorem 2 If in Definition 6 we change every occur- rence of Cost(s -+ Gi) to Wi, then Theorem 1 is still true. C Cost(s * Gi) 2 C Costs. iE(A,B} %(A,B} a A joint plan J will be said to satisfy the min condi- tion if min Cost(s ----) Gi) > min Costi( ~E(A,B} - iE{A,B) Theorem 1 There exists a joint plan that moves the world from its initial state s to a state in GA nGB and also satisfies the sum and the min conditions, if and only if NS # 8. 3All the states that exist in the intersection of the agents’ goal sets might, of course, not be reachable given the domain of actions that the agents have at their disposal. See [Zlotkin and Rosenschein, 1989b] for an example of a domain in which such a situation can occur. Types of Interactions Before the redefinition of utility, we had two possible situations for agent interaction: conflict and coopera- tive. A conflict situation implied a contradiction be- tween the agents’ goals, or a cost to achieving the union of their goals that was so high, no deal was individual rational. Now that utility has been redefined, we have three possible situations for agent interaction: conflict, com- promise, and cooperative. e A conflict situation is one in which (as before) the negotiation set is empty-no individual rational deals exist. o A compromise situation is one where there are indi- vidual rational deals. However, agents would prefer to be alone in the world, and to accomplish their 102 AUTOMATEDREASONING goals alone. Since they are forced to cope with the presence of other agents, they will agree on a deal. All of the deals in NS are better for both agents than leaving the world in its initial state s. o A cooperative situation is one in which there exists a deal in the negotiation set that is preferred by both agents over achieving their goals alone. Here, every agent welcomes the existence of the other agents. When the negotiation set is not empty, we can dis- tinguish between compromise and cooperative situa- tions using the following criterion. If for all i, Wi 5 Cost(s ---) Gi) and NS # 0, then it is a cooperative situation; otherwise, it is a compromise situation.4 Conflict Resolution What can be done when the agents are in a conflict situation? If we dropped Assumption 3 (“No History”), then we could offer some mechanism in which agents can “buy their freedom” by making a promise to their op- ponent regarding future actions. In this case, they will negotiate over the price of freedom. A discussion of altering utilities through promises, however, is beyond the scope of this paper. A simpler solution would be for the agents to flip a coin in order to decide who is going to achieve his goal and who is going to be disappointed. In this case they will negotiate on the probabilities (weightings) of the coin toss. If they run into a conflict during the negotiation (fail to agree on the coin toss weighting), the world will stay in its initial state s.~ Utility for agent i in general is the difference between the worth for i of the final state of the world and the cost that i spends in order to bring the world to its final state. If agent i wins the coin toss, then he can reach his goal. In this case, his utility is Wi (the worth of his goal) minus the cost he has to spend in order to bring the word to a state that satisfies his goal. If agent i loses the coin toss, his opponent is going to bring the world to a state that satisfies his opponent’s goal. This state will not satisfy gd (otherwise it would not be a conflict situation). The final state of the world in this case is worth 0 to agent i, but he is not going to spend anything to bring the world to this state, so his total utility in the case where he loses the coin toss is 0. If the agents agree to flip a coin with weighting q, then the utility for agent i of such a deal is qi(Wi - 4An example of a compromise situation can be found in Figure 1 when Wi is greater than 4. 5There is a sp ecial case where the initial state s already satisfies one of the agent’s goals, let’s say agent A (S cannot satisfy both goals since then we would not have a conflict situation). In this case, the only agreement that can be reached is to leave the world in state s. Agent A will not agree to any other deal and will cause the negotiation to fail. COst(s + Gi)), where qA = q; qB = 1 - q. Example: There is one block at slot 1. gA is “The block is at slot 2” and gB is “The block is at slot 3”; WA = 12 , and WB = 22. The agents will agree here on the deal that will give them the same utility-to flip a coin with weighting 3. This deal will give them each a utility of &j.” Cooperation in Conflict Resolution The agen .ts may find that, instead of simply a coin in a conflict si tuation, it is better for flipping them to cooperatively reach a new world state (not satisfying either of their goals) and then to flip the coin in o;deF to decide whose goal will ultimately be satisfied. Example: One agent wants the block currently in slot 1 to be in slot 2; the other agent wants it to be in slot 3. In addition, both agents share the goal of swapping the two blocks currently in slot 4 (i.e., reverse the stack’s order). See the left side of Figure 2. Assume that WA = WB = 12. The cost for an agent of achieving his goal alone is 10. If the agents decide to flip a coin in the initial state, they will agree on a weighting of 4, which brings them a utility of 1 (i.e., 3(12 - 10)). If, on the other hand, they decide to do the swap cooperatively (at cost of 2 each), bringing the world to the state shown on the right of Figure 2, and then flip a coin, they will still agree on a weighting of 3, which brings them an overall utility of 4 (i.e., +(12 - 2 - 2)). B 11 R Iii B 1234 -m l!!l 123 4 Figure 2: Cooperation up to a certain point Definition 9 A Semi-Cooperative Deal is a tuple (t, J,q) where t is a world state, J is a mixed joint plan that moves the world from the initial state s to state t, and 0 5 q 5 1 E R is the weighting of the coin toss-the probability that agent A will achieve his goal. The semantics of such a deal is that the two agents will perform the mixed joint plan J, and will bring the world to state t; then, in state t, they will flip a coin with weighting q in order to decide who continues the plan towards their own goal. Definition 10 UtilitYi(t, J,c~) = qi(Wi - Costi - Cost(t 4 G;)) -(l - qi)Costi(J) = qi(W - Costi(t + Gi)) - Costa(J) 6We have $(l2 - 2) = +(22 - 2) = $L. ZLOTKINANDROSENSCHEIN 103 Unified Negotiation Protocol (UNP) In cooperative and compromise situations, the agents negotiate on deals that are mixed joint plans, J:p (co- operative deals). In a conflict situation, the agents ne- ;$i$e on deals of the form (t, J, q) (semi-cooperative . We would like to find a Unified Negotiation Proto- col (UNP) that the agents can use in any situation. The main benefit would be that the agents would not have to know (or even to agree), prior to the negoti- ation process, on the type of situation that they are in. Determining whether the situation is cooperative or not may be difficult. An agent may not have full information at the beginning of a negotiation; he may gain more information during the negotiation, for ex- ample, from the deals that his opponents are offering, a.nd from computations he himself is doing in order to generate the next offered deal. Agents may only know near the end of a negotiation just what kind of situa- tion they are in. The semi-cooperative deals (t , J, Q) are general enough so that, with some minor changes in the defini- tion of utility, they may be used in the Unified Nego- tiation Protocol. A cooperative deal which is a mixed joint plan J:p can also be represented as (J(s), J:p, 0) where J(s) is the final world state resulting from the joint plan J when the initial state is s. J(s) is in GA n GB, so the result of the coin flip at state J(s) does not really matter (since none of the agents would want to change the state of the world anyway). What we advocate is for agents to negotiate always using semi-cooperative deals. A cooperative agreement can still be reached (when the situation is cooperative) because the cooperative I cooperative deals are a subset of the semi- deals. Definition 11 o If (t, J, q) is a semi-cooperative deal, then fi will be defined as the final state of the world when agent i wins the coin toss in state t. fi = (t + Gi)(t) E Gi. e W(fj) = Wi when fj E Gi, otherwise it is 0. o Utilityi(t, J,q) = qi(Wi - Costi(t -+ Gi)) + (1 - qa)W(fj) - Costi( J) e Two deals dl, d2 (cooperative or semi-cooperative) will be said to be equivalent if Vi Utilityi = Utilityi( The calculation of the utility of each deal is done according to the type of the deal (coop- erative or semi-cooperative). . - Theorem 3 If Vi Wa 2 Cost(s - Gi), then NS # 0. If wi < Cost(s - Gd) then agent i cannot even achieve his goal alone. This does not necessarily mean that NS is empty-Theorem 3 stated in the opposite direction is not true. Theorem 4 For a semi-cooperative deal (t, J, q) E NS, if there exists an i such that fi E GA n Gg, then this semi-cooperative deal is equivalent to some coop- erative deal. It is easy to see that whenever fA, fB $ GA fl Gg, then the definition of utility in Definition 10 is the same as that in Definition 11. UNP in a Cooperative Situation In a cooperative situation, there is always an individ- ual rational cooperative deal, where both agents’ goals are satisfied. One might expect that in such a situ- ation, even if the agents use the Unified Negotiation Protocol, they will agree on a semi-cooperative deal that is equivalent to the cooperative deal, i.e., both goals would be achieved. Surprisingly, this is not the case: there might exist a semi-cooperative deal that dominates all cooperative deals and does 7102 achieve both agents’ goals. See the example below. It turns out that this is a borderline situation, brought about because Wi is low. As long as Wi is high enough, any semi-cooperative deal that agents agree on in a cooperative situation will be equivalent to a coop- erat ive deal. Example: T h e initial situation in Figure 3 consists of 5 duplications of the example from Figure 1, in slots 1 to 15. In addition, two slots (16 and 17) each contain a stack of 2 blocks. gA is “Black blocks are in slots 2,5,8,11 and 14 but not on the table; the blocks in slots 16 and 17 are swapped” (i.e., each tower is reversed). $Q is “White blocks are in slots 1,4,7,10 and 13 but not on the table; the blocks in slots 16 and 17 are swapped”. Jludl...rnHRH~ 1 2 3 13 14 15 16 17 Figure 3: Semi-Cooperative Agreement in a Coopera- tive Situation For all i, Cost(s --f Gi) = 26 = (2 x 5) + (8 x 2). Let J be the minimal cost joint plan that achieves both goals. The cooperative deal J: 4 satisfies the min and the sum conditions, because for all i, Costi(J: 3) = 24 = i((8 x 5) + (4 x 2)). This situation is cooperative. For all i, Utility,(J: 4) = 26 - 24 = 2. Let t be the state where the blocks in slots 16 and 17 are swapped, and the other slots are unchanged. Let T be the minimal cost joint plan that moves the world to state t. For all i, Utilityi(t, T: $,+ ) = +(26 - (2 x 5)) - (2 x 2) = 4. The semi-cooperative deal (t,T:$, 3) thus dominates the cooperative situation. deal J:$ even though ;t is a cooperative Conclusions We have presented a theoretical negotiation model that encompasses both cooperative and conflict situ- ations. Necessary and sufficient conditions for coop- eration were outlined. By redefining the concept of 104 AUTOMATEDREASONING utility, a new boundary type of interaction, a com- promise situation, was demarcated. A solution was offered for conflict resolution, and it was shown that even in a conflict situation, partial cooperative steps can be taken by interacting agents. A Unified Negoti- ation Protocol was developed that can be used in all ca.ses, whether cooperative, compromise, or conflict. It was shown that in certain borderline cooperative situ- a.tions, a partial cooperative agreement (i.e., one that does not achieve all agents’ goals) might be preferred by all agents. References [Conry et al., 19883 S usan E. Conry, Robert A. Meyer, and Victor R. Lesser. Multistage negotiation in dis- tributed planning. In Alan H. Bond and Les Gasser, editors, Readings in Distributed Artificial Intelli- gence, pages 367-384. Morgan Kaufmann Publish- ers, Inc., San Mateo, California, 1988. [Durfee, 19883 Edmund H. Durfee. Coordination of Distributed Problem Solvers. Kluwer Academic Pub- lishers, Boston, 1988. [Harsanyi, 197’71 John C. Harsanyi. Rational Behav- ior and Bargaining Equilibrium in Games and So- cial Situations. Cambridge University Press, Cam- bridge, 1977. [Kuwabara and Lesser, 19891 Kazuhiro Kuwabara and Victor R. Lesser. Extended protocol for multistage negotiation. In Proceedings of the Ninth Workshop on Distributed Artificial Intelligence, pages 129-161, Rosario, Washington, September 1989. [Lute and Raiffa, 19571 R. Duncan Lute and Howard Raiffa. Games and Decisions. John Wiley & Sons, Inc., New York, 1957. [Malone et al., 19883 Thomas W. Malone, Richard E. Fikes, and M. T. Howard. Enterprise: A market- like task scheduler for distributed computing envi- ronments. In B. A. Huberman, editor, The Ecol- ogy of Computation, pages 177-205. North-Holland Publishing Company, Amsterdam, 1988. [Nash, 19501 John F. Nash. The bargaining problem. Econometrica, 28:155-162, 1950. [Rosenschein and Genesereth, 19853 Jeffrey S. Rosen- schein and Michael R. Genesereth. Deals among rational agents. In Proceedings of the Ninth Inter- national Joint Conference on Artificial Intelligence, pages 91-99, Los Angeles, California, August 1985. [Smith, 19781 Reid G. Smith. A Framework for Prob- lem Solving in a Distributed Processing Environ- ment. PhD thesis, Stanford University, 1978. [Sycara, 19881 Katia P. Sycara. Resolving goal con- flicts via negotiation. In Proceedings of the Seventh National Conference on Artificial Intelligence, pages 245-250, St. Paul, Minnesota, August 1988. [Sycara, 19891 Katia P. Sycara. Argumentation: Plan- ning other agents’ plans. In Proceedings of the The Eleventh International Joint Conference on Art& cial Intelligence, pages 517-523, Detroit, Michigan, August 1989. [Zlotkin and Rosenschein, 1989a] Gilad Zlotkin and Jeffrey S. Rosenschein. Negotiation and task shar- ing among autonomous agents in cooperative do- mains. In Proceedings of the The Eleventh Inter- national Joint Conference on Artificial Intelligence, pages 912-917, Detroit, Michigan, August 1989. The International Joint Conference on Artificial Intelli- gence. [Zlotkin and Rosenschein, 198981 Gilad Zlotkin and Jeffrey S. Rosenschein. Negotiation and t’ask shar- ing in a non-cooperative domain. In Proceedings of the Ninth Workshop on Distributed Artificial Intelligence, pages 307-327, Rosario, Washington, September 1989. [Zlotkin and Rosenschein, 1990a] Gilad Zlotkin and Jeffrey S. Rosenschein. Negotiation and conflict res- olution in non-cooperative domains. Technical Re- port 90-6, Computer Science Department, Hebrew University, Jerusalem, Israel, 1990. [Zlotkin and Rosenschein, 1990b] Gilad Zlotkin and Jeffrey S. Rosenschein. Negotiation and goal relax- ation. Technical report, Computer Science Depart- ment, Hebrew University, Jerusalem, Isra.el, 1990. In preparation. ZLOTKIN AND ROSENSCHEIN 105
|
1990
|
4
|
956
|
Solving Term Inequalities Gerald E Peterson? 225/105/2/206 mailcode 106 5165 McDonnell Douglas Corporation P. 0. Box 516, St. Louis, MO 63166 peterson@mdc.com Abstract This work pertains to the Knuth-Bendix (KB) algorithm which tries to find a complete set of reductions from a given set of equations. In the KB algorithm a term ordering is employed and it is required that every equa- tion be orientable in the sense that the left-hand side be greater than the right. The KB algorithm halts if a non- orientable equation is produced. A generalization of the KB algorithm has recently been developed in which ev- ery equation is orientable and which halts only when a complete set is generated. In the generalization a con- straint is added to each equation. The constraint governs when the equation can be used as a reduction. The con- straint is obtained from the equation by “solving” the term inequality left-hand side > right-hand side. To under- stand what it means to solve a term inequality, consider the analogy with algebra in which solving term equal- ities, i.e. unijicafion, is analogous to solving algebraic equalities. Then solving term inequalities is analogous to solving algebraic inequalities. Thus, the solution of term inequalities relates to unification as the solution of algebraic inequalities relates to the solution of algebraic equalities. We show how to solve term inequalities when using the lexicographic path ordering. Introduction In a landmark paper, Knuth and Bendix (Knuth & Bendix 1970) described a technique for attempting to generate a complete set of reductions from the axioms of an equa- tional theory. If a complete set of reductions could be found, then it embodied a decision procedure for equa- tions provable from the axioms. In particular they gen- erated a complete set of reductions for groups. In their theory a term ordering was introduced and it was necessary for every equation to be orientable in the sense that one side be larger than the other in the ordering. Equations such as commutativity which could t This work was supported by the McDonnell pendent Research and Development Program. Douglas Inde- not be oriented would cause the process to fail. Knuth and Bendix were well aware of this limitation of their method. In fact, they proposed using an approach in which a non-orientable equation would be made into two reductions, one which rewrites the left-hand side to the right-hand side and another which rewrites the right- hand side to the left-hand side and in which a method is available to “make sure that no infinite looping occurs when reducing words to a new kind of irreducible form.” This proposed approach has been effected (in (Peterson 1990) and forthcoming publications) by adding a con- straint to each reduction. For example, commutativity is represented as x . y -+ y . x if x > y. By using constraints such as these we are able to gen- eralize the entire Knuth-Bendix process. In fact, com- plete sets of constrained reductions are now known for common equational theories including Abelian groups, rings, and Boolean algebras, and there is an analogue of the Knuth-Bendix procedure which begins with the axioms of an equational theory and attempts to generate a complete set of reductions. This constrained version of the Knuth-Bendix process will never fail because a non-orientable equation shows up-every equation can be oriented. It may, of course, fail because it runs for- ever trying to find a complete set. The process reduces to that of Knuth and Bendix when presented with equa- tions which are orientable without the use of constraints. As an example, the following three reductions taken collectively is a complete set equivalent to associativity and commutativi ty. 1. (x * y) - 2 --) x - (y - 2) 2. x-y+y-xifx>y 3. x - (y - 2) + y - (2 - 2) if x > y. In reduction 1 there is no constraint. This means that the left-hand side is always greater than the right. In each of the other two reductions there is a con&mint which is a necessary and sufficient condition that the left-hand side be greater than the right. In order to find the constraint we must solve the inequality left-hand side > right-hand side. Looking back at the example, we see 258 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. that x > y is the solution to x . y > y. x and x > y is also the solution to x . (y -2) > y. (X -2). The manner in which these kinds of solutions are obtained is the subject of the present work. It will be helpful to consider how the solution of term inequalities relates to unification. In unification, a term equality, such as (X s y) . (X . u) = (W . Z) . y is given and it is required to find a most general substitution for the variables which makes the equality true. In this case, the substitution is (x t w, y + w . a, z + w .a). This process could be named solving term equalities but uniJi- cation has been chosen instead. The problem of solving term inequalities is similar. Given a term inequality, such as x . (y . z) > z s y, find the region in term space where the inequality is true. In this case it turns out to be where x > z or x = z or y > z or y = z. Consider an analogy to algebra. The solution in real numbers of a polynomial equation is a finite (possibly empty) set analogous to the single most general unifier of a term equation. The solution of a polynomial inequality, how- ever, consists of a region, possibly with several disjoint intervals, such that the inequality is true if and only if the variable is in the region. For example, x2 - 5x + 4 > 0 if and only if x > 4 or x < 1. Thus we may expect the solution of a term inequality to be a similar type of region in term space. So far we have been implicitly assuming that an un- derlying term ordering existed. Throughout this paper we use the lexicographic path ordering. Knuth and Bendix used an ordering which has since become known as the Knuth-Bendix ordering (Dershowitz 1987). How- ever, it has a more complex definition than the lexico- graphic path ordering and is, therefore, presumed more difficult to work with. A possible research problem is to figure out how to solve term inequalities when using the Knuth-Bendix ordering. Related Work In (Kirchner & Kirchner 1989) a theoretical overview of constrained equational reasoning is presented. They work modulo an equational theory such as associativ- ity and commutativity. However, they assume that con- straints are based on term equalities, wheras we assume constraints are based on term inequalities. In (Comon 1990) it is shown than the question of the existence of solutions to term inequalities based on the lexicographic path ordering, such as those herein, is decidable, but NP-hard. The automatic solution of algebraic inequalities has a similar goal (i.e. the isolation of variables) to that of solving term inequalities, but is accomplished by com- pletely different methods. A good beginning reference to the solution of algebraic inequalities is (Sacks 1987). An Example In order to provide further motivation for the introduc- tion of a technique for solving term inequalities, we present an example of the operation of the constrained Knuth-Bendix algorithm. We emphasize those places in which term inequalities are solved. Details of how the constrained Knuth-Bendix algorithm works in gen- eral will be described elsewhere. The reader is as- sumed familiar with the ordinary Knuth-Bendix algo- rithm throughout this section. The following problem is from page 91 of (Monthly 1968). Suppose S is a semigroup in which x2 = x3 and x2y = yx2 for all x, y in S. Then (xY)~ = x2y2. We will describe how a solution can be mechanically obtained using the constrained Knuth-Bendix algorithm. We present only the part that directly leads to the desired equation. Other equations will be generated in an actual implementation. A semigroup has one associative operation. Thus, the first reduction is 1. (x - y) * 2 + 2 * (y - 2). The equation x2 = x3 is orientable because X. (x . x) > x . x for every x. So the second reduction is 2. x * (x * x) + x - 5. The equation x2 y = yx2, i.e., xe(x.y) = y.(asx), is not orientable, so the ordinary KB algorithm does not apply to this problem. However, the inequality x . (x - y) > y - (x e x) may be solved and the solution is x > y. Thus the equation x2y = yx2 may be represented as the two reductions 3. 2 - (x-y) --) y - (x -x) if x > y, 4. y - (x - x) -+ 2 - (x - y) if y > 5. If we unify the left-hand side of 2 with the x-y subterm of 1 and proceed as in the ordinary KB process, we obtain the new reduction 5. x * (x - (x - y)) ---) x - (x * y). Unifying the left-hand side of 3 with the subterm x - (x . y) of 5 and applying 3 and 5 once each to the result gives the equality x * (y * (x * x)) = x * (x - y) which is produced only if the constraint of 3, i.e. x > y, holds. Now we try to reduce this equality under the assumption x > y. Since x > y implies the constraint of reduction 3, the right-hand side can be reduced by 3 giving x * (y - (x - x)) = y - (x * x). No further reductions are possible. At this point, the inequality x > y which came from one of the parents PETERSON 259 is discarded and the new equality is oriented on its own merits. In this case the equality is orientable and we add 6. x - (y - (x - x)) ---* y - (x - x) as a new reduction. Similarly, if we unify the left-hand side of 4 with the x.y subterm of 1, we obtain the equation x.(x.(y.z)) = y . (x . (x s 2)). We now find x > y as the solution of the term inequality x . (x . (y . 2)) > y . (x + (x -2)) and add the reductions 7. x - (x - (y - 2)) + y. (x f (x - 2)) if x > y, 8. y - (x - (x - z)) ---) x - (1: - (y - 2)) if y > 2. Finally, unifying the left-hand side of 7 with the left- hand side of 2 and reducing once with 7 and 2, respec- tively, yields the equation under the always valid constraint y . z > y. We now reduce this equality to normal form using 1, 6 and 5, and obtain which is the equality we are trying to prove. Note that if this were now added as a reduction, the solution of a term inequality would again be required. The Lexicographic Path Ordering Recall that terms are formed from function symbols (in- cluding constants) and variables. The definition of the lexicographic path ordering depends on a given linear ordering on the function symbols. Therefore, we as- sume there are only a finite number of function symbols and they are put into a linear order. This ordering of function symbols and the lexicographic path ordering on terms will both be denoted by > because either it is possible to figure out from the context whether > is the term ordering or the function symbol ordering, or they are both true simultaneously. Ground terms contain no variables. Two ground terms are equal if and only if they are identical. The lexicographic path ordering (lpo) is defined only for ground terms. It is defined recursively as follows (Dershowitz 1987): Definition. Suppose s = f(sl, - - -, sm) and t = g(tl, - - - , tn) are ground terms. (We may have m = 0 andlor n = 0 for a constant.) Then s > t if and only if Ll sj 2 t for some i, 1 5 i 5 m, or L2 f >gands>tiforevery j,I< j<n,or L3 f = g and for some k, 1 5 k 5 n, we have s; = t; whenever 1 5 i < k, Sk > tk, and s > ti whenever k<isn. Note that the first inequality in L2 is from the func- tion symbol ordering, and in the last part of L3 we do mean s > tj, not sj > tj. The two examples given next should help clear up any confusion related to this definition. First, however, we note that it is possible to prove (Dershowitz 1987) that the Ipo is a well-ordering of the set of ground tezms and it satisfies the subterm property, i.e., if s is a strict subterm of t, then t > s. For the first example, suppose the function symbol order is . > a > b and it is required to show that a a b > b -a. According to Ll and L3 of the definition, this will be so if and only if azb-aor (1) b 2 b - a or (2) a > b and a. b > a or (3) a = b and b > a. (4 In line (3) the first predicate is true by the given function symbol order and the second predicate is true by the subterm property. Thus we have shown what is required. Incidently, lines (l), (2) and (4) are all false. As the second example let’s determine the larger of a. (b + c) and a + (b . c) when the function symbol order is + > . > a > b > c. Since these two terms are not equal, one must be larger than the other. We can use the definition above to test Q . (b + C) > u + (b - c). Since + > -, L2 and L3 do not apply. By Ll, we have a - (6 + c) > a + (b - c) if and only if a 2 a + (b - c) or (5) b + c 2 a + (b - c). (6) But (5) is false by the subterm property. By Ll and L3, (6) is true if and only if b 2 a + (b - c) or c 2 a + (b - c) or b>aandb+c>b.cor b= aandc>b-c. But all of these are clearly false. Thus we do not have a. (b + c) > a + (b . c). So we must have a + (b - C) > us(b+c). Solving Term Inequalities Using the definition of the lexicographic path ordering, we can determine the larger of any two ground terms. Suppose, however, that a given inequality contains vari- ables, and the question is to determine where it is sat- isfied. This can be done by recursively applying the 260 AUTOMATEDREASONING definition of the lpo and gathering all the bottom-level expressions which cannot be simplified. To clarify the meaning of this, let’s do a couple of examples. Example 1. Solve x - y > y - x. By Ll and L3 of the definition, x . y > y . x if and only if x>y*xor (1) yly-xor (2) x>yandx.y>xor (3) x=yandy>x. (4 But (1) and (2) are false by the subterm property and the fact that no term equals a subterm of itself. Also (4) is false since it consists of two incompatible statements. In (3), the second predicate is true by the subterm property. This leaves only the first predicate of (3). Thus the answer is 2 > y. In order to simplify the presentation we will from now on omit the or from the end of each line and we will replace each and with a comma. Example 2. Solve x . y > y - a given that a > . in the function symbol ordering. This example will begin to show the complexity that can arise. By Ll and L3, x + y > y - a if and only if x>y-a (5) x=y.a (6) Y>Y-a (7) y=y-a (8) x>y, x.y>a (9) x = y, y > a. (10) By the subterm property, (7) is false. Since y and y . a are not unifiable, (8) is false. Replacing the equalities by equivalent unifiers and expanding the second predicate in (9) using Ll gives the following form for the solution x>y.a (11) Ix - Y * 4 (12) x>y, x>a (13) x>y, x=a (14 X>Y, Y>a 05) x>y, y=a (16) {x + ~1, Y > a. (17) However, note that (1 l), (12), (15) and (16) each implies ‘(13) by the subterm and transitive properties of >. Thus (1 l), (12), (15) and (16) can be eliminated from the above leaving x>y, x>a {x - a), a > Y lx + ~1, Y > a. as tne solution. We now present an algorithm which can be used to solve any given term inequality. It is presented as a person would use it with pencil and paper. From a ma- chine standpoint it is not very efficient as presented. It can be made more efficient at the expense of greater complexity and less understandability. Because of lim- ited space, efficiency considerations will be deferred to a later paper. Begin with the given inequality on a line by itself. As we proceed, each intermediate stage will consist of a table of one or more lines of the form where 6 is a substitution (possibly empty) and each el- ement ei is either an equality or an inequality. An in- equality is fully reduced if it has one of the forms v > t or t > V, where v is a variable and t is a term which does not contain v. A line is a component if it consists of a substitution 8 followed by 0 or more fully reduced inequalities which do not contain the variables that are replaced in 8. Algorithm. Repeat steps 1 to 3 below until each line is 1: 2. 3. component. Move down the table to the first line which is not a component and across this line from left to right to the first element which is not a fully reduced inequality. Call this element e and its line t. If e is an equality, unify the two sides. If unification is impossible, delete line L If the table is now empty, stop; the answer is false. If unification is possible, let o be the mgu. Delete e in line !Z, replace the substitution 0 at the beginning of e with 8 composed with 0, and apply v to the rest of L If e is an inequality, then i. ii. . . . 111. if e has the-form- v > t where v is a variable which occurs in term t, delete line e; if the table is now empty, stop; the answer is false; if e has the form t > v where v is a variable which occurs in t, delete e from e; tf e is now empty, stop; the answer is true; otherwise, the lpo definition will apply to e; delete line e; add to the end of the table several lines corresponding to the results of applying the lpo dejktition to e; each of these lines will be identical to 4 except that the position formerly occupied by e will be replaced by one possible way in which e might be true. Now do the following. 4. Delete each line which is inconsistent. 5. For each line !Z, if e implies another line, delete .C 6. Delete the redundant elements in each line. An ele- ment e is redundant in e if e - (e) =+ e. PETERSON 26 1 Steps 4 to 6 may be interleaved with 1 to 3 in order to keep the table as simple as possible. Steps 4-6 will be automated in the next section. Example 2 above was performed using essentially these steps. The answers to three other examples are now presented. The reader may go through the above steps to verify these. Example 3. Solve x + (y - z) > x - ( y + z) given that + > . in the function symbol ordering. The solution is X’Y tx + Yb Example 4. Solve x. ( y . z) > y. (2. x) . The solution is x>y, x>z 1% + 4, 2 > Y ix + Yh Y ’ 2. Example 5. Solve (y + z) + ( y + w) > x + (z + tu) . The solution is y+z>x {x-y+z}, y>z. Reasoning with Components In the previous section we have seen that every term inequality can be solved and the solution has the form Cl v c, v ’ * . V C,, where each Ci is a component. In order to complete the automation of the solution pro- cess we need to have algorithms for determining when a component is inconsistent, when one component im- plies another, and when an element in a component is redundant. The purpose of this section is to describe these algo- rithms. Note first that even without steps 4-6, the algorithm of the previous section would generate a solution of the given inequality. The purpose of steps 4-6 is to render the solution in a simple form. This simplification is a practical necessity because without it solutions to even simple inequalities would be unwieldy. However, valid- ity is not compromised if we do not find every possible way in which steps 4-6 can be performed. Thus, we do not attempt to find every possible way in which simpli- fication can be effected by steps 4-6. We will find the common ones, however. We first show how to decide if a conjunction of fully reduced inequalities implies another fully reduced in- equality. Let el , e2, . . a , en and e be fully reduced in- equalities. Let ei = (4 > ri) for each i and let e = (A?! > r). To decide whether or not el, e2, - - - , en =+ e we consider all possible inequality sequences of the form where each f$ > rj is one of the ei. In the above display, each 2 is shown by the subterm property; each > is present in the ei. If we can find such a sequence, then we have proved e; otherwise we assume a proof is not possible. E;or example, suppose we wish to show that (x > y, y > z) =+ x > Z. We have x=x>y=y>z=z as an expression of form (1). Thus it is proved. Now suppose C and D are components and it is re- quired to determine whether C 3 D. Let where 4 = {VI + tl,***,vn - tn}. Then C + D is equivalent to where &9 = (~6 = tl6, .. . , v,O = tne} because sub- stitution of equals for equals is logically valid, and af- ter 6 is used in this way it can no longer contribute to the required implication. Normally inequalities can- not prove equalities, so if the implication is to be true, we must have 40 true. That is, we must have vlB G tl@,-,v,e z tn0. We are left with the problem of determining the validity of To do this, consider the proof of each fi0 separately and conjoin the results. Thus, we must be able to solve the problem el,--- jen * fe where f is fully reduced. If f 8 is fully reduced, use the procedure of the previous paragraph. Otherwise, solve the inequality f0 using the procedure of Section 4 and obtain Ci v - . -V C,, where each C; is a component. We will determine the validity of el , . a . , en + Ci separately for each i and disjoin the results. For el, . . . , e, to imply the component { 4, ei , - - - , ek}, 4 must be empty and w-h e, must imply each ei separately as detailed in the previous paragraph. For example, in Section 4 it was required to show that (x > y - a} a {x > y, x > a}. To do this, we show 262 AUTOMATED REASONING x>y~a=+x>ya.ndx>y~a=+x>aseparately. The first follows from x=x>>-a>y and the second from x=x>y-a>a, each of which has the form (1). In order to show that a component (6, el, . . . , e,) is inconsistent, we let i run from 1 to n, ei = (6 > r-i) and test el,.-+ ,ei-l,ei+l,-3 n e *t-i>&. If this is so for some i, then the component is incon- sistent. Otherwise it is presumed consistent. For exam- ple, suppose {X > y, y > X} is the component. Try x > y =r) x > y. This is easily proved by the above method. Thus this component is inconsistent. Similarly, in order to test an element e of a component C for redundancy, check C - (e} =+ e. References Comon, H. 1990. Solving Inequations in Term Algebras. In Proceedings of the Fifth Annual IEEE Symposium on Logic in Computer Science. Dershowitz, N. 1987. Termination of rewriting. Journal of Symbolic Computation 3:69- 116. Kirchner, C., and Kirchner, H. 1989. Constrained Equa- tional Reasoning, Technical Report, CRIN 89-R-220, Centre de Recherche en Informatique de Nancy. Knuth, D., and Bendix, P. 1970. Simple word problems in universal algebras. Computational Problems in Ab- stract Algebras. J. Leech, ed. Oxford, England: Perga- mon Press, 263-297. Monthly 1968. The American Mathematical Monthly 75. Peterson, G. 1990. Complete Sets of Reductions with Constraints. In Proceedings of the Tenth International Conference on Automated Deduction. Sacks, E. 1987. Hierarchical Reasoning about Inequali- ties. In Proceedings of the Sixth National Conference on Artificial Intelligence, 649-654. American Association for Artificial Intelligence. PETERSON 263
|
1990
|
40
|
957
|
Computing Stable Models By Using the ATMS Kave Eshghi Hewlett Packard Laboratories, Filton Road, Stoke Gifford, Bristol BS12 6&Z, England. Email:ke@hplb.hpl.hp.com Abstract An algorithm is described which computes stable mod- els of propositional logic programs with negation as fail- ure using the Assumption Based Truth Maintenance mechanism. Since stable models of logic programs are closely connected to stable expansions of a class of auto- epistemic theories, this algorithm points to a link be- tween stable expansions of a class of autoepistemic the- ories and ATMS structures Introduction In this paper an algorithm is described which com- putes stable models of propositional logic programs with negation as failure [l], using the Assumption Based Truth Maintenance mechanism [2]. Since stable models of logic programs are closely connected to stable expan- sions of a class of auto-epistemic theories, this algorithm points to a link between stable expansions of a class of auto-epistemic theories and ATMS structures. Stable Models of Logic Programs Stable models of logic programs with negation as failure were introduced in [l] as a means of specifying the se- mantics of logic programs. They are defined as follows: A logic program is a set of clauses of the type P + Pl,PZ,**. - q1,- q2.. where N indicates negation as failure. In this paper we only consider propositional logic programs, where Pl,P2,*41,Q2** are propositions. We do not place any other restriction on the structure of the clasues. Definition 1 The answer set of a propositional Horn Clause program is the set of all propositions provable from it. We use Answer(n) to denote the answer set of the program II Definition 2 Let P be a propositional logic program with negation as failure, and I a set of propositions. The negation-free program PI is derived from P by a Deleting all the clauses in P which conditions such as N q where q E I have a negative m Deleting all the negative conditions in all the remain- ing clauses of P. I is a stable model of P ifl I = Answer(PI) Example: let P be the program Then Pjb} = {b +), and therefore {b} is a stable model of P. In general, a logic program may have any number of stable models. The algorithm described here computes all of them. Stable models of logic programs are closely connected to stable expansions of auto-epistemic theories. In fact, as observed in [l], if we replace every negative condition N p in the program P with the condition 4?(p), where B is the belief operator of auto-epistemic logic, the sta- ble expansion of the resulting auto-epistemic theory is the same as the stable model of P. As such, the algo- rithm described in this paper can be considered to be a theorem prover for a restricted class of auto-epistemic theories. The ATMS We are only concerned with a subset of the capabilities of the ATMS, which we define below. Let N be a set of propositions, called nodes, and S a distinguished subset of N, called assumptions. Let J be a set of propositional Horn Clauses, called justifications, in which all propositional symbols are from N. When we transmit S and J to the ATMS, it computes the following structures: o All the minimal sets of assumptions E such tht J U E is inconsistent. These sets are called nogoods. e for every node n, all the minimal sets of assumptions e such that JUe I- n. e is called an environment of 12, and the set of all environments of a node n is called the label of n. 272 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. For example, let J be a t b* + b, b* b c c* * c,c* and S = {b*, c*}. Then the ATMS will compute the only nogood to be (b*, c*}, and the following labels for each node: a : w*H b : i{c*H c:o (Note: +- c, c* is an alternative syntax for i(c A c*), where -) signifies classical negation) Notation: we will use nogoodJpS(e) to indicate that E is a nogood given the justifications J and assumptions S. We will use enwJjS (n, e) to indicate that e is an en- vironment of n given justifications J and assumptions S. For example, let P be at-b b--c Then P* is a + b* The Algorithm To compute the stable models of a logic program P, we proceed as follows: 1. From the program P derive the set of Horn clauses P* and the set of assumptions S; 2. Add the elements of S to the ATMS as assumptions, and add the clauses in P* to the ATMS as justifica- tions; 3. From the data structures computed by the ATMS (environments and nogoods) compute the stable model of P. Each one of these steps is described below. Deriving P* and S Given a propositional logic program P, P* and S are derived as follows: for every clause such as PcPl,P2,..“Q1,“42...-Qn in P, add the assumptions qT,q$, . ..a. to S, where qT , qz . ..qE are propositional symbols not occuring in P, and add the Horn clauses P + P2, P2.., !I;, 4;...!lcT. + Ql, 4; + 42, !l; . . . . to P*. (We call q and q* the complements of each other. In the rest of this paper, an assumption indicated as q* will always be the complement of the propositional symbol q). + b,b* b +-- c* + c,c* and S = {b*,c*}. The relationship between P and P* As mentioned before, the stable models of P are re- lated to the environments and nogoods returned by the ATMS when it is presented with the assumptions in S and the justifications in P*. To explore this relation- ship, first we define the notion of stable generator. Definition 3 A set of assumptions o is a stable gen- erator of P i$ P* U u is consistent Vn* E S, (n* e d + P* U u I- n) (Note: n is the complement of n*) The following two theorems establish the link be- tween stable generators and stable models: Theorem 1 Let o be a stable generator of P. Then the set I = Answer(P* U (I) \ cr is a stable model of P. Theorem 2 Let I be a stable model of P. Then the set u = (q* : q* E s A q $z I) is a stable generator of P. From these theorems it follows that for every stable model of P, there is a unique stable generator. Further- more, given a stable generator, it is straightforward to compute the corresponding stable model. The algo- rithm described in this paper computes stable genera- tors of a progam P from the environments and nogoods computed by the ATMS when it is given the assump- tions S and justifications P*. To do this, we need the following lemma. Lemma 1 A set of assumptions o is a stable generator of P ifl VE, nogoodP*js(e) -+ E (t o Vn* E S, (n* @ u + 3e, (envP’>S(n, e) A e C a)) (Note: n is the complement of n*) ESHGHI 273 T&s lemma directly follows from the definiton of stable generators and the properties of ATMS nogoods and environments. Example: When the S and P* computed in example 1 are transmitted to the ATMS as assumptions and jus- tifications, {b*, c*} will be the only nogood. The nodes in the ATMS, with their labels, will be: a : Iv*33 b : +*33 c : 0 In this situation, {c*) is the only set of assumptions satisfying the definition of a stable generator, i.e. it is the generator of the only stable model of P. (b*) is not a stable generator because it does not safisfy the second requirement of the definition of stable generators, for c* ${b*) but P*u(b*)yc. Computing Stable Generators In this section, an algorithm is described which, given the environments and nogoods returned by the ATMS, computes all stable generators of P. The algorithm computes a stable generator by finding a set of assump- tions, 7, such that S \ T is a stable generator. (We call r an acceptable culprit set if S \ r is a stable generator) The intuition behind the algorithm is as follows: find a set of assumptions r such that by removing them from S, the remaining set of assumptions u satisfies the re- quirements of lemma 1. The first requirement, that no nogood set should be a subset of u, can be satisfied by choosing one assumption from each nogood and includ- ing them in r. (This is similar to computing diagnoses from a set of conflict sets [9] [3]). However, if we re- move an assumption q* from S where q does not have any environment which is a subset of the remaining set of assumptions we violate the second requirement of lemma 1. For example, consider the only nogood set for the example program above, {b*, c*}. If we choose b* as the culprit, we will satisfy the requirements of lemma 1, because b has an environment, {c*), which is a subset of the remaining set of assumptions, {c* 3. But if we choose c* as the culprit, we violate the second requirement of lemma 1, because c does not have any environment which is a subset of the remaining set of assumptions {b* 3 .(In fact, c does not have any environ- ments at all). We call the environment e a complement environ- ment of the assumption q* if it is an environment of q. We call the set of all complement environments of q* the complement label of q*. In order to make sure that the second requirement of lemma 1 is satified, the algorithm keeps with each chosen culprit q* the set of all its complement environments which do not include any of the other culprits. We call this set of comple- ment environments the companion of assumption q*. Every time a new culprit is chosen, the companions of all the other culprits are updated to remove the envi- ronments which include the chosen culprit. If we can choose a culprit from each nogood without making the companion of any other culprit empty, this will be an acceptable culprit set, because the remaining set of as- sumptions will satisfy lemma 1, and will therefore be a stable generator. The details of this process are given below. Data Structures and Procedures The data structure used to keep assumptions together with their companions is the augmented assumption. An augmented assumption is a tuple (q*, E) where q* is an assumption, and E is a list of complement en- vironments of q*. We call q* the main assumption of (a*> Jq- The list of augmented assumptions bh%),(n& &z)..(n;, Eb)] is an augmented nogood when its main assumption set, i.e. (n;, r-4; . . . . n;), is a nogood (as returned by the ATMS) and for all i, Ei is the complement label of nr (i.e. the list of all complement environments of nz). The augmented nogood list relating to example 1 is u*, ck*lI)Y cc*, iI)1 At the heart of the algorithm is the procedure sta- blecomp. If A is the list of all augmented nogoods of P*, stablecomp(A, Tau) succeeds iff Tau is a set of ac- ceptable culprits (i.e. S \ Tau is a stable generator of PI* We have presented the algorithm in Prolog because it is a non-deterministic algorithm. Prolog handles the non-determinism by its built-in backtracking. Below is the top level definition of stablecomp. stablecomp(A,Tau):- s~comp(A[l.Comp), main-assumptions(Comp,Tau). stablecomp is defined in terms of stcomp, which re- cursively chooses one assumption from each nogood as the next culprit, maintaining the list of culprits cho- sen so far with their companions in the argument Cul- prits-sofar. stcomp([,X,X). stcomp([NogoodINogoods].Culpritssofar,Comp):- choose(Nogood,(Node*,Label)), filterl(Culpritssofar,Label,Labell), filter2(Node*,Culpritssofar,Culpritsl), filter3(Node*,Nogoods,Nogoodsl), stcomp(Nogoodsl,[(Node*,Labell~Culpritsl],Comp). To explain the behaviour of stcomp, first we describe the data structures in its argument places, then we de- scribe the recursion invariant of the above clauses, and 274 AUTOMATEDREASONING then the constituent predicats choose, filterl,filter2 and filter3. o The first argument of stcomp is a list of augmented nogoods. o Its second argument is a list of augmented assump- tions [(a!, El), (u%,,?&)...], where a; are the chosen assumptions sofar, and Ei are their companions. o The third argument of stcomp is the variable that is used to return the result of the computation The following is the recursion invariant for the defini- tion of stcomp. It holds when stcomp is initially called by stablecomp, and whenever it is subsequently called in the recursion. Invariant 1 Let r be the main assumptions set (a:, aa, ..) of Cul- prits-sofar. Then the following will always hold when- ever stcomp(Augmented-nogoods,Culprits-sofar,Comp) is called. I. 2. For every augmented assumption (nt, Ea) in Cul- pritssofar, Ea is not empty, and it is the list of all complement environments of na whose intersection with r is empty, Augmented,Nogoods is a list of all augmented nogoods of P* the intersection of whose main assumption set with r is empty. These conditions are clearly satisfied when stcomp is initially invoked. Let r be the set of main assump- tions of Culprits-so-far when the base case of recursion is reached. Then it will be the case that a Every assumption a* in r will have at least one com- plement environment whose intersection with r is empty, o Every nogood will have at least one element from tau Thus r will be an acceptable culprit set, and S \ r will be a stable generator. The constituent procedures of stcomp Below we discuss the function of the and the three filter procedures. choice procedure choose The call choose(Nogood,(Node*,Label)) non- deterministically chooses an augmented assumption (Node*, Label) from the augmented nogood Nogood. filter1 Let r be the main assumption set of Cul- pritssofar. The function of the filter1 procedure is to remove from the complement-label of the chosen assumption all the environments which include an as- sumption which occurs on r. Thus, if filterl(Culpritssofar,Label,Labell) is successful, Label1 will be the list of all the environ- ments in Label whose intersection with r is empty. If all the environments in Label include an assumption from r, then filterl(Culpritssofar,Label,Labell) fails. filter2 The function of this procedure is to remove from the companions of all assumptions on Cul- pritssofar those environments which include the chosen assumption. Let Culprits-sofar be the list [(n;, El), (nt, Ez)..]. Then if filter2(Node*,Culpritssofar,Culpritsl) . rst [( successful, Culprits1 will be the nT, Ei), (na, Ei)...] where Ei is the subset of Ei with all the environments in Ea which include Node* removed. If there is an Ei which would be empty af- ter removing all environments which contain Node*, filter2 fails. filter3 Let Nogoods be a list of augmented nogoods. Then the procedure call filter3( Node*,Nogoods,Nogoodsl) removes from Nogoods all the augmented nogoods whose main assumption set includes Node*, returning the result in Nogoodsl. Generating all stable generators The procedure stablecomp described above returns one acceptable culprit set when invoked, from which the corresponding stable generator can be computed by the set complement operation. To find all stable generators, the Prolog findall procedure can be used to find all the acceptable culprit sets. Related work The relationship between truth maintenance and non- monotonic reasoning formalisms is close, and there is an extensive literature on it. Of direct relevance to us is the work reported in [7], where an algorithm (different from the one presented here) is presented for computing stable models of propositional logic programs. The ma- jor difference between our work and the one reported in [7] is that they compute stable models directly, and ad- vocate their use as an alternative to the ATMS, whereas the work presented here derives the stable models from ATMS structures, and sheds some light on the relation- ship between stable expansions of auto-epistemic theo- ries and ATMS structures. In [6] and [s] th e semantics of Doyle’s TMS [4] are re- lated to auto-epistemic expansions. Their work can be considered complimentary to ours, because they start from a given truth maintenance system (Doyle’s TMS) and give its semantics in terms of auto-epistemic expan- sions, whereas we start from a class of autoepistemic theories and relate their expansions to ATMS struc- tures. The two theorems stated above are a special case of a more general theorem proved in [5], in which a link was established between stable models of logic programs and abductive hypotheses generation. ESHGHI 275 PI Gelfond,M. & Lifschitz,V: “The stable model se- mantics for logic programming”, Proceeding Fifth International Conference on Logic Programming, MIT Press 1988 PI DeKleer, J: “An assumption based truth mainte- nance system”, Artificial Intelligence Journal 28, 1986 PI PI PI DeKleer, J. & Williams, B.C.: “Diagnosing multiple faults”, Artificial Intelligence Journal 32, 1987 Doyle, J: “A truth maintenance system”, Artificial Intelligence Journal 12, 1979 Eshghi,K & Kowalski, R.A. “Abduction compared with negation as failure”, Proceedings of the Sixth International Conference on Logic Programming, MIT Press 1989 PI PI PI PI Fujiwara, Y & Honiden, S: “Relating the TMS to auto-epistemic logic”, Proceedings IJCAI 89, Mor- gan Kaufman inc., 1989 Pimental, S.G. & Cuadraro, J.L.: “A truth mainte- nance system based on stable models”, Proceedings of the North American Conference on Logic Pro- gramming, MIT Press 1989 Reinfrank,M. et .al.: “On the relation between truth maintenance and auto-epistemic logic”, Proceedings IJCAI 89, Morgan Kaufman inc., 1989 Reiter,R: “A theory of diagnosis from first princi- ple”, Artificial Intelligence Journal 32, 1987 Appendix In this appendix the two theorems are proved. First, a References few preliminaries. Definition 4 Let P be a propositional logic program. Let P* and S be derived as described in the paper. Let CT be a subset of S. Then PJ’ is the horn clause program derived from P* by: 1. Removing every clause which has a condition q* whereq* ES\C 2. From the remaining clauses in P*, removing eve y condition q* where q* E o Lemma 2 For a program P,* defined as above, Answer(P,*) = Answer(P* U a) \ 0 Proof Easily follows from the definition of P* and Pz Proof of Theorem 1 From the definiton of I in theorem 1, the definition of P,* and lemma2 it follows that I = Answer(P,*) Below we prove that PG = PI, thus proving that I = Answer(PI) which proves that I is a stable model of P. Proof of PI = Pb* 1 Let c = p + pl,pz, . . . be a clause in PI. If c occurs in P, since it does not have any negative conditions it will be in Pz as well. Otherwise, there is a clause P + Pl, Pa, “‘3 - Ql, - q2... in P where ql, qz... 4 I. Let qn be any of q1 , qz.... Since - qn occurs as a condition of a clause in P, qz E S*. Since c is a stable generator of P, qg E CT t P* U CT y qn. But since qn $! 1, by definition of I P* U 0 y qn which shows that qi E IY. Now, since p + pl, ~2, . . . . - ql, - qz... is in P, by definition of P* there is a clause p t pl, ~2, . ..qT. a{.. in P*. Since, as proved above, qT, qa, . . E CT, from the definition of P,* it follows that p c ~1, p2 . . . is in Pz, i.e. c is in Pz 2. Let c=p+pl,p2.. beaclausein P,*. Ifcoccursin P, since it does not have any negative conditions it will be in PI as well. Otherwise, there is a clause p + pl,p2, . ..qT. qz.. in P* where q; , qz . . E u. Now, let qi be any of qT, a;... Since cr is a stable generator of P, P* Ua is consistent. Furthermore, by definition P* contains a clause +- * Qn9 Qn* Thus P* U u y qn, for otherwise P* U u would be inconsistent. Thus, by definiton of I, qn @ I. Now, since there is a clause p t pl , ~2, . . .qT , qz . . in P* , there is a clause pl, ~2, . . . - q1 , q2 . . in P, where as shown above, ql, 42, . . . 4 I. Thus p + Pl,P2, *** belongs to PI, i.e. c E PI. Proof of Theorem 2 First, we prove that Pa = PI 1. Let c = p +-pl,p2.. be a clause in PO. If c occurs in P, since it does not have any negative conditions it will be in PI as well. Otherwise, there is a clause P + Pl,P2, -.d,!&. in P* where q;,q$, . . E u. Let qi be any of qT, qz.... Since q;T E CT, by definiton of u, qn @ I. Since P c P1,P2,4T,42*.. is in P*, there is a clause P+Pl,P:!,~~-Qll”qz.* in P where ql, qz... 6 I. Thus p + p1 ,p2.. is in PI, i.e. c E PI. 2. Let c = p + pl,p2.. be a clause in PI. Then there is a clause P c Pl,P2, *a - Ql,” q2.. in P, where ql, 4.2, . . 4 I. Let qn be any of ql, q2 . . . . Since - qn occurs as a condition in P, qi E S. Thus, since qn 4 I, by definiton of a, q; E u. 276 AUTOMATED REASONING Since P + Pl,P2, ** - 41,” 42.. is in P, there is a clause P+-Pl,P2,.4T,42*.. in P* where q:, qz... E CT. Thus p + ~1, ~2.. is in P,,, i.e. cE PO. Now we show u is a stable generator by showing that it satisfies the two requirements of stable generators. 1. We prove that P* U u is consistent by contradiction. Suppose P* U u is inconsistent. Then, the proof of inconsistency would involve a denial of the form c P>PY whereP*Uut-pandP*Uukp*. But since, due to the definiton of P*, assumptions do not occur at the head of clauses, the only way p* can be provable from P* U u is for it to be a member of u. But, due to the definiton of u, this means that p 4 I, which means that PI If p, i.e, since PI = P,*, Pz lj p. Thus, by definiton of P,*, P* U u y p, leading to a contradiction. 2. To prove that Vn* E S, (n* 4 u + P* U u I- n), assume that n* E S and n* 4 u. Then by definition of u, n E I, which, since I is a stable model of P, means that PI I- n. Since PI = Pz, this means that P; I- n, i.e. that P* U u I- n ESHGHI 277
|
1990
|
41
|
958
|
Computing the Extensions of Autoepistemic and Default Logics with a Truth Maintenance System Ulrich Junker GMD, F3-HIS Postfa,ch 1240 5205 St. Augustin 1, F.R..G. unido!gmdzi!junkerGhunet .uu.net Abstract In this pa.per we develop a proof procedure for au- toepistemic (AEL) and defalrlt logics (DL), based on translating them into a. Truth Maintenance Sys- tem (TMS). The translation is decidable if t,he theory consists of a finite number of defaults a.nd premises and classical derivability for the base lan- guage is decida.ble. To determine all extensions of a network, we develop variants of Doyle’s labelling algorithms. ‘Introduction We seek proof methods for autoepistemic logic (AEL) [ll] and default logic (DL) [14]. Most existing tech- niques are too restrictive in terms of the language al- lowed. Reiter’s original proof procedure is restricted to closed normal defaults [14]. Etherington handles only ordered network theories, a special class of general de- faults which are suitable for inheritance [4]. Ka.utz and Selman are mainly interested in complexity results and restrict their attention to disjunct8ion-free default the- ories [7]. Brewka’s prover handles modal implications having no preconditions of the form Lq [I]. Moore’s procedure for AEL is restricted to a propositional lan- guage [12], just as Niemela’s work [lo]. Closer to our approach is the work of Levesque on quantified AEL [9], which has a proof procedure under the same con- ditions as ours; however Levesque’s proof theory is a Hilbert-style axiomatization, without an efficient im- plementation. We want to develop a more general proof procedure for AEL and DL which profits from efficient truth main- tenance (TMS) techniques. To this end, we translate an AEL or DL theory into a TMS network, and relate the admissible labeling of the network to extensions of the original theory. It is already known from the work of Reinfrank, Dressler, and Brewka [13] that the TMS can be given a semantics by mapping to a restricted form of AEL or DL; here we give the inverse transforma- tion. Our approach has only two limits: 1) We do not handle infinite sets of defaults and premises. 2) Deriv- ability has to be decidable for the base language. If 278 AUTOMATED REASONING Kurt Konolige Artificial Intelligence Center SRI International 333 Ravenswood Ave. Menlo Park, California 94025/USA konolige@ai.sri.corn both requirements are satisfied our procedure is able to determine all extensions and to detect incoherence, i.e., non-existence of an extension. To achieve this goal we ta.ckle three problems: Extensions of autoepistemic and default theories are defined as infinite fixed points of monotonic opera- tors, while the TMS is finite. Are there computa.ble, finite conditions for extensions? Doyle’s TMS lacks complete first-order derivability. What first-order derivations must be encoded by jus- tifications to get all needed conclusions? TMS labeling algorithms (cf. [2], [5]) are incomplete because they compute only one extension and can stop without a definite result if there are odd loops. How can we get all extensions? In outline the strategy of the paper is as follows. We concentrate initially on DL because its fixed-point con- dition is close to that of the TMS. First we identify all formulas which are relevant for the fixed point con- ditions, and develop alternative operators whose fixed points consist of relevant formulas. This set of formulas is finite for a finite number of defaults and allows re- construction of every extension. The a.ppropria.te TMS can then be constructed by considering only the rele- vant formulas as nodes, with justifications coming from the defaults and from appropriate first-order proofs re- lating the relevant formulas. Admissible labelings of the TMS provably correspond to extensions of the DL theory. For AEL the story is slightly more complicated. Be- cause of the relation between DL and strongly-grounded extensions of AEL, the above method can be transferred directly. However, in the case of weakly-grounded ex- tensions, the definition of admissible labeling must be changed to allow circular support in the TMS. Finally, we sketch a complete version of Doyle’s la.- beling algorithm. As in [6], it introduces choice points for loops and performs backtracking if it runs into an odd loop. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Closures of operators In this pa.per, we use extensively operators that apply defaults or justifications. Here we give notation and for these operators. Let u-be a domain and I- 2’ be a monoton ic and compact operator: if X E Y then apply(X) 5 apply(Y) if (I E apply(Y) then 3X 2 Y : S is finite a.nd Q E apply(X) (1) Repea:ted a.pplica.tion of apply lea.ds to an operator apply’ which is also monotonic and compact. If we apply. it to the empty set it sa.tisfies applyi 5 apply”+“(s). N ow we define the transitive and reflexive closure of apply: Definition 1 Let apply : 2” t-+ 2” be a monotonic an.d com.pact operaior. The closure apply*(X) is the minimal set that contains X and is closed 1u.r.t. apply, i.e. app1JT(app1Jr*(X)) 5 apply*(X). We mention some alternative characterizations of apply* in Lemma 1. Minimality of apply* can be en- sured by iterating apply or by finite derivation chains. Lemma 1 Let apply’ : 2” H 2” be a monotonic, and compact operator. The follo,wing conditions are equiva- lent: 1. T = app!y*(0). 2. apply(T) = T 5 apply*(0). 3. T = U;“=., applyi(0) / t* apply(T) C T alzdQqET3ql,...,ql,:q=qk and qi E apply({ql,. . .,qi_l}) for i = l,~+~,k. Very often, we consider sets being closed w.r.t. two opera.tors apply, and appl_yz. For this purpose, we write (apply1 U zpply,)(X) for applyI U apply2(X). Consider (appl~r~ U applya)* (0). Here, both operakors are applied in parallel. Sometimes, a sequentia.1 view yields more insights: We first use apply2 and then de- termine the closure w.r.t. applyI. Thus, we get a con- catenaked operator apply; o applyz. Lemma 2 Let apply,, apply2 : 2” - 2” be two monotonic and compact operators, app&)*(@) = (aPPl,v; 0 aPPk)* (0). Then (apply1 U A reduced fixed point condition for DL In this section we reduce the infinite fixed-point exten- sions of DL to finite ones, which are called the exten- sion bases. Let ,& be a first-order language containing a contradiction formula _I_. A default theory A is a pair (D, W) consisting of a set D of defaults and a set of first-order premises W C ,&. Each default has the form (a : bl , - . - , bk/c) where a, bl, - - - , bk,, c are ordinary formulas. Informally, we say that the default is applied if its prerequisite a is provable and bl, - . -, bk are con- sistent, i.e. a.11 lbi are not provable. We abbreviate the set of prerequisites, the set of negated consistency as- sumptions (i.e. exceptions), and the set of conclusions by Pn = {u 1 (CI : bl,. . . , b&z) E D} ED = {lb; 1 (u : bl;-., b&z) E D,i E (1, . . . . h}} C’D = {c 1 (<I : bl,. -‘! bk/c) E D} (2) Let Th(S) be tl le set of first-order conclusions of X. We also introduce a. special operator that applies de- faults. We use different sets X, Y to check both kinds of preconditions. Our operator applies a default (a : 61,. . . ,6k/c) if CI. E S and 16; 6 Y: applyD,lr(X) := {c 1 (a : bl,. . -, bk/c) E D, a E X, a.ndlbi$-Y fori=l,e..,k} (3) To be more precise, we have defined a unary opera- tor for every Y. These operators have nice proper- ties: they are monot.onic and compact and we can apply the results of t,lie previous section in reformu- lating Reiter’s operat’or r. I’(T) is the smallest set tl1a.t contains IV and is closed w.r.t. the first-order clo- sure Th and our operator applyD,T. Hence, I’(T) = (Th u applyD ‘7’)* (TV). A 11 extension is defined using I’: Definition 2’ (Reiter): Let A = (D, W) be a closed default theory. A first-order set T is an extension of A ifl r(T) = T. We now discuss two problems: 1. What a.re the relevant formulas to establish the fixed point condition? 2. How can we reduce the azgument of I? to a finite domain? Every extension is an infinite set a.nd it is difficult to find a. set T satisfying the fixed point condition. What part of T is really needed for determining extensions? The operator applj’D,7 checks lb; $ T for every default (a : bl,-.. , bk/c) and ignores the rest of T. In addition to these nega.ted consistency assumptions, the prereq- uisites of clefa.ults are relevant because derived prereq- uisites are needed to apply further defaults. Thus our test doma.in is defined by CD := PD U ED. The relevant part of a set T is B = TfI,& and satisfies following properties: appfyD,T = appjyDIB and J?(T) = r(B). If T is an extension then B = T fl LD = I’(T) fl ,& = I?(B)nL D . Thus, we have obtained a fixed point condition for a test domain LD which is finite if there are a finite number of defaults. We can IIOW define a reduced extension, called the extension base, as follows. Definition 3 Let A = (D, T/v) be a closed default the- ory. B is an extension base of n ifl B = r(B) II Lo. Hence, if T is am extension then Tn,& is an extension ba.se. Conversely, if B is an extension base then I’(B) = r(r(q rl Lo) = r(r(q) and l?(B) is an extension, giving the following theorem. JUNKER AND KONOLIGE 279 Theorem 3 Let A = (D, W) be a closed dejuult the- ory. There exists a bijective mopping of the set of ex- tensions of A to Ihe set of extension bases of A. There is at most one inconsistent extension of A. If B is the estension base of an inconsistent extension then _LE I’(B) and B = ,!Z D since 811 inconsistency implies every formula. We can check _l_E r(LD) to detect an inconsistent extension base. Now, we simplify I’(B) fl LD which is needed in Def- inition 3. We want to reduce the necessary first-order derivations as much as possible. First, we introduce a new operator that inserts W and then derives first- order consequences. We write it down using a. la.mbda.- expression, namely X(X).Th(X U TV). Then I’(B) is the minimal set that is closed w.r.t. X(X).Th(X U TV) and applyD,B. By Lemma 2, we get: r(B) = ((X(X)*Th(X u w)) o apPbD,B>*(@> c4) Since applyI, B expects only prerequisites which are in & and qxj.m(x u TV) is only supplied with conse- quents which are in CD we can show r(B) nLD = ((x(x).(x u (Th((x n CD) u r/v) n &)))O ~PP~Y~$?)* (0) I-7 LD (5) consistency assumptions from consequents and premises. Equation 5 allows a simple translation to TMS. Compact fixed point conditions for the TMS Doyle’s TMS maintains a network v := (N, J) consist- ing of a set N of nodes and a set J of justifications. A justification (in(I), out(O) --+ c) for a node c consists of a finite in-list I C N, a finite out-list 0 C N, and a consequent c. A justification is applied if all members of its in-list are believed, but no member of its out-list. As for default logic, we introduce an operator ap~Iy~,~ which is monotonic and compact: aPPlY_r,y (X) := G I k-0), out(O) + 4 E J> IGXandOnY=0} (6) Another property of applyJ,Y puting extensions, namely: is important for com- if X C Y then apply.7,~ (T) 2 apply~,~ (T) (7) T is an extension of a justification network if T is the minimal set closed w .r. t . applyJ,T : Definition 4 Let v = (N, J) be a justification network. T is an extension of v ifl T = apply;,, (0). Using the results of the section on operators, we find alternatives to definition 4. We split the set J of all justifications into a set iV of monotonic justifi- cations and a set NM of non-monotonic justifications. Monotonic justifications have an empty out-list and we wri tc apply,,, (_Y) for applynl @(X) which is equal to applynr *(X) for all T. Then we obtain app;4’J,T (X ) = apply ,%V,T(X) u aPP1Y,\f(X)* (8) Len~mcl 4 Let II = (AT, J) be a justificcltion n.etwork, A4 C .I be a set of monotonic justifications and NM := J - M. The f II 0 ouring sentences are equivalent: 1. 7’ is tin extemion of v, i.e. T = appl~;,~(@). 2. appl~~,~(T) C T and Vq E T 3q1,. . . , qk : q = qk, und qi E appl~,,~( {ql! . . . , qi-1)) for i = 1, - - -, k. 3. T = (aPPk!;,l O aPPlq’Aw,T)*(rn)- Property (2) a.grees with usual definitions of extensions as closed and grounded sets (cf. [3], [13]). The third alternative allows a clear translation of AEL and DL to TMS. We map first-order deriva.tions to monotonic justifications and defaults or modal formulas to non- monotonic justifications. First-order derivations We need to derive TMS justifications for the first-order operator X(X).Th(X U TW). To limit the generated jus- tifications, we use subsets of X which are in a domain U and we are interested in theorems contained in a range IC For default logic, we choose U := CD and R:=iCo =PDuED. To realize Th((X fl U) U W) n R, ive try to find all minimal proofs for elements of the range R. More pre- cisely, we determine all minimal subsets Q of U inferring a Q E R in conjunction with T/v (i.e. Q U TV b (I and Q’ U T;f/ p q for every proper subset Q’ of Q) .l For this purpose, we a.pply a proof method that returns a goal q as well as the premises Q used to prove Q; LR-resolution would work here. The proof is translated into a mono- tonic justification (in(Q) --+ (1). Let 114w(U, R) be the set of all justifications obtained by this method: Nile (U, R) := {(in(Q) --+ q) 1 Q is a minimal subset of U s.t. Q U W b q for Q E R} (9) in question and we get: aPPlyM,(u,n)(X) = Th((X n U) u W) n R (10) w.r.t. applyM,(u,R). Hence we obtain the closure of a~dh&&J,R) if we add the input: a~d&w(U,R)(x> = X u (Th((X fi U) u T/V) n R) (11) Here, we translated complete proofs into justifications. Other encodings of first-order derivations including in- termediate steps are conceivable. Finding all minimal proofs is not computable in gen- eral. Therefore, our approach works only when W is a decidable subset of Cc (e.g., clauses with a finite her- brand universe). However, the source of the non-semi- decidability of DL is the non-decidability of classical logic, not the infinite fixed points. lIn fact, it is not necessary to determine minimal subsets: we can use any subset that infers q. But the minimal subsets give the minimal sufficient set of justification rules. 280 AUTOMATEDREASONING Translating default theories to a TMS We are now in a position to translate both the de- faults and first-order part of a default theory into a TMS network. We translat,e each default (CL : bl,-** , bk/c) of D into a non-monotonic justification (;??(u), UZ+& . . . ,41;) + c). This justifica.tion is ap- plied if and only if the default is a.pplied. We put all these justifica.tions into a set iSl\l and get aPPl?%%&, (X) = aPP~Y~,&V (12) Furthermore, we supply enough monotonic justifica- tions for first-order deriva.tions. As pointed out in the previous section, we ta.ke 1\/1 := n/lr,l (Co, CD). Definition 5 Let A = (D, T/r/) be II default theory. Its TMS-trunslu.tion is VA := (lo U CD, NM U 11/r) where J/1 := Mw(CD, lo) and NM := {(z’?z(a),o,~rt(lb~,...,~bk) -+ c) 1 (a : bl,.“,bk/C) E Dl. Now we them to concatena.te applY:t I? using equa.tion 5: and ap~kY~~~,~ T and rela.te 1 (wPh;r O aPP~YlvM,T)* (0) = (X(X).(X u (Th.((S n Co) u W) n &)))o (13) aPPJYD,T)*(Q)) (a&d& o a~w$‘~n,r,~)*(~) n LD = r(T) n LD (14) If T is an extension of VA then T n Lo = I’(T) n ,CD = r(TnLD) nC D and T fl LD is a.n extension base of A. Conversely, if B is an extension base of A consider T := (aPP~Y;vroaPP~YNVf B )*(0). ThenTfXD = r(B)n,&) = B and aPPIYNhd,T ’ “PPIY1~,~,~& = aPPIYNjta,B, and T is an extension of A. Theorem 5 Let A = (0, T/v) be a default theory and VA its TMS-tran.slation. There exists (I bijective map- ping of the set of extewion bases of A to the set of extensions of VA. This is the main result. We discuss some exa.mples. 1) If D = {(a : /a)} and TV = 0 then the test do- main LD = { } a consists of a single element. There are no interesting first-order derivations, and the network consists simply of a single justifica.tion, (in(u) + a). Its single extension is empty. 2) If D = { (: u/b)} and TV = {B > la} then the test domain LD = (1~) a.gain consists of a single element. There is one minima.1 first-order derivation from the domain CD = {b} to the range lo, namely buW i= la.. The network consists of a two justifica- tions ((out(72) + b) and (in(b) + la)), and has no extensions because of the odd loop. 3) D = {(:. la/b), (: d/u)}, W = {a > b} is a more complex theory. Here, ,cD = {a, b}. There is one min- imal first-order derivation, a U W b b. The resulting justification network ((out(u) ---f b), (out(b) + a), and (in(u) + b)) has a single extension, {b). Thus, we have translated default theories into finite justification networks. Using this translation, we get a proper criterion for incoherence: if a t,lieory has no es- tension then its TRIS-translation contains a.11 odd loop. Our translation makes no special use of a contra- diction node. Therefore, st,andard labeling rolltines a.re also sufficient to determine inconsistent est,ensions. However, a high price is paid because a lot of justifica.- tions a.re needed for this purpose. If a sllbset Q of the domain U is inconsistent then (in(Q) - q) is included for every element Q of our range R. If we handle incon- sistent extensions separately we can reduce this effort a.nd replace the set {(‘i?? ((2) - q) 1 q E It> by a sin- gle justifica.tion (in(Q) -_L). Consistent extensions of this modified network correspond to consistent esten- sion bases of the theory. Autoepistemic logic We now turn to AEL. The results of the previous section carry over to strongly-grounded extensions of AEL t,he- ories, by first translating t,o DL, and then to a. ThflS. In this section we treat weakly-grounded extensions. The development is similar to that of the previous t\vo sec- tions. The only real difference is in the definition of extension for TMS networks: we must allow circu1a.r justifications for some nodes. We discuss autoepistemic logic using the terminol- ogy and concepts in [S]. Hence, we have a first,-order la,nguage &, containing a contradiction formula 1. Es- tending ,Co by a 1noda.l operator L leads t,o a modal lan- guage ,!Zael. If q is a closed formula. of iCael the modal literal LQ is also in ,Cnel. We use some abbreviations from [S]. Two opera.tors apply L and 1 L to each ele- ment of a set; To contains the ordinary formulas of T; and T is the complement of ‘7: LT={LqIqcT} ‘LT={~L~I~ET} TO = T&LO 2? = (,& - T) We must be careful in using these terms: To means (L ael - T) 17 ,CO, but not ,Cnel - To. There is a normal form for sentences of &l, in which there a.re no nested modal operators. From now on we assume that every sentence is in this form. From [S], the extensions of a premise set P c Gael are given by: Theorem 6 (Konolige): A subset T of ,!Zne. is an es tension of P iflT = {q E ,Cael 1 P U LTo U lLT0 j=~cds ql. I<45 is the modal logic of weak S5. By this theorem, the original fixed point condition is reduced to ordinary sets. From this, we can show that a set U C_ ,& is the kernel of an extension of P if and only if it satisfies U = {Q E ,CO I P U LU U 1Lu b q}, so the fixed-point condition is over first-order implica.tion. We now concentrate on the problem of reducing U in this fixed-point equation to a finite set. Define as a test domain: LP := {a I Lq occurs in a formula of P} (15) JUNKER AND KONOLIGE 28 I Since P is in normal form every Lq in P refers only to ordinary formulas 9. Hence, ,Cp is a subset of ,Cu. Furthermore, if P is finite ,Cp is also finite. We define I’p for a set l7 as Pp := ‘r n Lp. For subsets of the test domain we can derive a reduced fix-point form, the extension base: Definition G Le2 P be in normal form. A subset B of .Cp is an exiension base of P i.8 B = {q E .Cp 1 PuLBpulLBp/=q} If ‘7’ is an extension then Tp is an extension base. We also regain an extension from each extension base B: Consider U = {cl E & 1 P U LBp U 1LBp b y} which is fo-closed and satisfies Up = Bp. Then U = {q E ,& [ P U LUo U ~Loo ~KQS q} and U is the kernel of the extension {cl E ,Cael 1 P U LU0 U lLU0 b1~45 q}. Theorem 7 Let P be in normal form. Then there is a bijective mapping of the set of extensions of P to the set of extension bases of P. As an example, consider P = {FLU > b, 1Lb > a}. Our test domain ,Cp = {CL, b} has four subsets two of which are extension bases: ifB=0 then {(I E ,Cp 1 P U {‘L a, lLb1 I= ql = h-6 bl # 1 if B = (a) then {y E ,Cp 1 P U {L a,~Lb}~q}={a}=B if B = {b} then ((1 E ,Cp 1 P U {FLU, Lb} i= q) = {b} = B if B = (CL, b) then {Q E .Cp 1 P U {La, Lb) b q) = 0 # B Finally, we briefly discuss inconsistent extension bases. Suppose a subset B of ,Cp satisfies P U LBp U 1LBp /==I. Shce a.n inconsistency implies all formulas, B is an extension base if and only if B = ,Cp. Hence, it is easy to find out whether P has an inconsistent ex- tension: just check whether P U L,Cp is inconsistent. In the sequel we consider just the consistent extensions of P. The transla.tion to a TMS is similar to that of DL the- ories. For every modal sentence LaAlLbl - - - , lLb, > c of P, we supply a set of nonmonotonic justifications (in(a), out(bl, . . . , b,,) --+ c) . We also give a set of mono- tonic justifications over .Lp taking consequents of modal sentences as input. Definition 7 Let P be a subset of ,Cael in normal form. The Th?S-translation of P is up = (,Cp U Cp, M U NM) where M := Mpn~&Cp,Cp), NM := {(;n(~),out(bl,...,b~) -+ c) 1 La A lLbl...,lLb, > c E P-&} and Cp := {c I LaAlLb, ... > c E P-,&}. Unlike in the strongly-grounded case, the translated TMS network does not behave in the same way as the extensions of P, because P may have expressions like La > a that generate circular arguments. However, we must still avoid circular first-order proofs. So we modify the definition of extensions of the TMS. Let ,Cs E ,C:p be the set of ordinary sentences {a 1 La A -Lb1 - - - > c E P}, i.e., only the arguments of negalive occurrences of modal atoms. Define a new nronotonic, conlpact op- erator: (16) All the results for apply hold as well for appl_v+. We call consistent network labelings (those where _I_ is not believed) defined by t,he new operator +-extensions. Tlreorem 8 Let P be a. sf1bse-t of ,Cae, in normal form and l/p its TAGS-ircln.slniion. Then there exists a bijec- iive mapping of ihe sel of consis1en.t extension bases of P lo the se1 of +-exiensions of up. We discuss some examples for autoepistemic logic: 1) If P = {La} (tha.t is, ~LCL 3-l in normal form) our test domain ,Ccp = {a.} consists of a single element, and ,Cs is empty. There are no interesting first-order proofs. The network contains one justification, (out(u) +_I_), which leads to an inconsistency. It has no +-extension. 2) The premise set P = {~LcL} (ill normal form, La 3-L) is similar. However, we get ,Cz = {a}. There is one justification, (jn(cl) --+I), and one +-extension, {4. 3) P = {FLU > b, TLb > a} is a more complex the- ory. Here, ,Cp = {a, b}, ,lZz = 0. The resulting justifica- tion network ((owt(ct) + b) and (out(b) -+ a)) contains an even loop and has two extensions {a}, {b}. We get the same TMS network for weakly and strongly grounded extensions. The major difference be- tween them is the inclusion of circular justifications in the definition of apply+. Moderately-grounded exten- sions have so far resisted analysis in terms of the applJ7 operators, although we are still working on the problem. Computing TMS-extensions After translating autoepistemic and default theories into justification networks a single algorithm, with slight variations, is sufficient t,o compute both exten- sions and +-extensions. We use a complete variant of Doyle’s TMS to compute all extensions of a justifica- tion network. It additionally introduces choice points and considers an OUT-label, as well as an IN-label for a node of every loop. This algorithm is also able to detect incoherence, i.e. non-existence of an extension. The algorithm is NP-complete, and we have alterna- tively been experimenting with stochastic constraint- satisfaction methods to achieve good average time com- plexity. We use two disjoint sets, I and 0, to denote-all nodes that are la.beled IN, or OUT, respectively. Above, we mentioned that nodes in a loop may have a chosen la- bel which is unconfirmed and may fail in presence of odd loops. For this purpose, we introduce a third set U containing all unlabeled and unconfirmed nodes. For strongly grounded derivations, we may only use ele- ments of I - 17. Similar to TMS, our algorithm uses two rules to de- termine a.n IN-label and an OUT-la.bel of a node. The 282 AUTOMATEDREASONING first rule looks for a justification whose in-list members have confirmed IN-labels and whose out-list menlbers are la.beled with OUT, i.e. are not contained in any so- lution. If there is such a justifica.tion its consequent gets a confirmed IN-label. The second rule checks whether there is still a justification which may be applied if fur- ther unlabeled nodes get an IN-label. If there is none _the consequent gets a confirmed OUT-la.bel. If the al- gorithm cannot proceed with propagation it chooses a.n arbitrary node contained in a loop and tries a.n IN-label, a.s well as an OUT-label. However, these la.bels may fail and therefore are unconfirmed. A failure occurs if a node is added to 1 and 0. Finally, there is a termina- tion rule. If the algorithm cannot find any justification whose in-list members have a confirmed IN-label then it stops and adds all remaining nodes to 0. The precise algorithm is listed below: Algorithm 1 Ezt~(I,0, U) E 1. if I I-IO # 8 then {} else 2. if U = 0 then {I} 3. if U # 0 then (uj if U Cl apply,,,(l - U) = 0 then ExtJ(I, 0 U U, 0) @J if 3q E U I7 applyJN_O(I - U) then ExtJ(I U -kW,~- {!a ’ (c) if 3q E U - applyJ1(N - 0) then ExtJ(I,O U ’ -au - b>> (cl) if 3q E U - (I U 0) then ExtJ(I, 0 U {q}, U) U The algorithm terminates if it is supplied with a. f- nite set of nodes. Calling Ezt~(0,0, N) results in the set of all extensions of v = (N, J). A slight va.ria.tion of the algorithm is sufficient to get +-extensions, too. Justification in NiVf may be applied to nodes in I even if their label is not confirmed. This change affects lines 3a and 3b. Conclusion We have developed a translation of AEL and DL to the finite constraint networks of the TMS. The advantage of doing so is that efficient constraint-sat‘isfaction methods can be exploited in the TMS to produce the extensions of the logics. There are two areas in which we wish to develop further results. The first is in the transla.tion process, which unfortunately is correct only for finite sets of defaults and a decidable base language. The ex- tension to infinite sets of defaults seems atta.inable, but the base language complexity must remain a problem, because the TMS labelling is always decidable. Rather, we can view the TMS as an approximation to the orig- inal (undecidable) AEL or DL theory. The question then becomes, under what conditions are we certain to have added enough justifications to the TMS so that its extensions are extensions of the original theory? The second area is the development of constraint- satisfaction methods for the TMS that allow the effi- cient computation of whether a node is in all extensions of the network or not. As mentioned above, we are cur- rently interested in stochastic methods, in which the answer is approximate, but improves with time. Acknowledgements Ulrich Junker was supported by the West German Ministry for Research and Technology within project TASS0 (Grant No. ITW8900A7); Kurt Konolige was supported by the Office of Naval Resea.rch Contract NO. PI PI PI 141 PI [61 PI PI PI PO1 WI P21 WI WI N00014-89-C-0095. References Brewka., G., Nonmonotonic Reasoning: From The- oretical Foundation Towards Efficient Computa- tion. Dissertation, University of Hamburg (19S9) Doyle, J., A Truth Maintenance System. Artificial Intelligence 12 (1979) Doyle, J., The Ins and Outs of Reason Mainte- nance. Proc. IJCAI 83 Etherington, D.W., Formalizing Nonmonotonic Reasoning Systems. Artificial Intelligence 3 1 (1987) Goodwin, J-W., A Theory and System for Non- Monotonic Reasoning. PhD Dissertation, Univer- sity of Linkijping 1987 Junker, U., A Correct Non-Monotonic ATMS. Proc. IJCAI 89 Iiautz, I-I., Selman, B., Ha,rd Problems for Simple Default Logics. Proc. KR’89 Konolige, I<., On the Relation between Default and Autoepistemic Logic. Artificial Intelligence 35 (1988) Levesque, H. J., All I Know: an Abridged Report. Proc. AAAI87. Niemela, I., Decision Procedure for Autoepistemic Logic. Conference on Automated Deduction (1988) Moore, R.C., Semantical Considerations on Non- monotonic Logic. Artificial Intelligence 25 (1985) Moore, R.C., Autoepistemic Logic, in: Smets, P.,Ma.mdani, E.H., Dubois, D., Prade, H. (eds), Non-Standard Logics for Automated Reasoning, Academic Press (1988) Reinfrank, M., Dressler, O., Brewka, G., On the Relation between Truth Maintenance and Au- toepistemic Logic. Proc. IJCAI 89 Reiter, R., A Logic for Default Reasoning. Artifi- cial Intelligence 13 (1980) JUNKERANDKONOLIGE 283
|
1990
|
42
|
959
|
Maintaining Consistency in a Stratified System Program Louiqa Raschid Department of Information Systems and Institute for Advanced Computer Studies University of Maryland College Park, MD 20742 louiqa@secd.cs.umd.edu Abstract We present our research on defining a correct semantics for forward chaining production systems (PS) programs. A correct semantics ensures that the execution of the program will not produce incorrect answers and execu- tion will terminate; it also ensures that the answers are consistent. We define a class of stratified PS programs, and propose an operational semantics for these pro- grams. We define an operator TPs, which computes the operational fixpoint for the productions of the stratified PS program; the fixpoint captures the meaning of the PS program. The theory that can be derived from the productions of the PS program may be inconsistent with the constraints that are also derived from the PS program. We can then view the constraints as modify- - ing the theory so that the modified theory PS is con- sistent with the constraints. However, the same answers are obtained in the operational semantics of the stratified PS program or from the modified theory E. 1. Introduction In recent years, much AI research and development has focused on forward chaining rule-based sys- tems which follow the production sytem (PS) para- digm (Hayes-Roth 1985). Large production rule- based expert systems have been successfully developed in diverse domains such as engineering design databases, trouble-shooting in telephone networks, and configuring VAX computer systems. This research was sponsored partially by the National Science Foundation under Grant DMC8814989 and by the University of Maryland Institute for Advanced Computer Studies. The author would Arcot Rajasekar. like to thank Timos Sellis, Anne Litcher and Production In these domains, the expert system programs often have to reason with large quantities of data. As the production rule base and the database grow larger, these programs have to access information stored on disk. Thus, for performance reasons, it is important that PS programs be implemented using database technology. Research in this area is reported in Delcambre and Etheredge 1988, Main- dreville and Simon 1988, Raschid, Sellis and Lin 1988, Simon and Mandreville 1988, Sellis, Lin and Raschid 1988 and Widom and Finkelstein 1989. If large production systems (PS) are to be implemented successfully to interface with large (relational) databases, then it is critical that the semantics of PS be well understood. Unfor- tunately, most PS have an incomplete operational semantics defined for them. This can result in non-terminating execution of productions and inconsistent answers. In this paper, we describe our research on defining a correct semantics for PS programs. This paper is organized as follows: In section 2, we introduce the operational semantics of OPS5, an example of a PS (Forgy 1981 and Forgy 1982) and motivate this research using some example OPS5 programs. We also define how a logical theory can be derived from the productions of the PS pro- gram. In section 3, we define a class of stratified PS programs and define an operational semantics for stratified PS programs. A stratified PS pro- gram is a stratified program, and comprises an extensional database (EDB) of facts, a stratified intensional database (IDB) of rules, and a stratified set of integrity constraints (IC). Both rules and integrity constraints correspond to productions in the PS program. We show that processing is guaranteed to terminate upon reaching the opera- tional fixpoint of a defined operator TPs. The fixpoint captures the meaning of the PS program and is correct and consistent. 284 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. The theory of the PS program, comprising the EDB facts and the IDB rules that are derived from the productions, may be inconsistent with the integrity constraints (IC) that are also derived from the productions. We can view the IC as modifying-the theory so that the modified stratified theory PS will be consistent with IC. This is described in section 4. We also show the equivalence between the answers obtained in the operational fixpoint and the minimal model for the theory E. 2. The OPS5 Production System In this section we introduce the operational seman- tics defined for the OPS5 production system language and highlight some of its problems. We chose the OPS5 production system language (Forgy 1981 and Forgy 1982) as an example. Operational Semantics of OPS5 An OPS5 knowledge base comprises a set of pro- ductions and an extensional database (EDB) of ground positive unit clauses which may be stored in relations. There will be one relation correspond- ing to each predicate. An OPS5 production consists of (1) the symbol p, (2) the name of the production, (3) the antecedent or the left hand side (LHS), (4) the symbol +, and (5) the consequent actions or the right hand side (RHS), enclosed within parentheses. The an tecedent is a coniunction of first order positive literals of the form: v Xl, x2,+- x, P(al~ a2,-*am, xl7 or negative literals of the form: v Xl, x2,- xn lQ(alr a2,--am, x Q are (n+m)-ary predicates c( EDB relations, al, a2,...a, a x1j x2,..xn are variables. Assum --- __ - ._ - _ .--1.‘.1.3 : --~~- x2,**xn) 17 x2, * eXn)- P and lrresponding to the re constants and e that all variables - 11 11 1 al-e in a TWLtJC-TCSLTZC literal must tea, i.e., appear any variance tnat occurs in a positive literal. The advantages of this restriction have been discussed in Sadri and Kowalski 1988 and correspond to the safety of evaluating queries. The antecedent of each production is inter- preted as a query against the EDB relations. For example, for each of the positive literals, P(al, a2,. .am, x1, x2,. .xn), relation P is queried, and a set of instantiated tuples of P satisfying each positive literal in the antecedent is retrieved. For each of the negative literals, Q, the query corresponding to the first order formula, -I ( 3 Xl, 3, **xn Q(al, a27**7am, ~17 ~2 **>Xn) ), is verified against the relation Q. Note that since the variables are range-restricted, the queries corresponding to the negative literals can always be verified. The antecedent of a production is satisfied if the relations contain instantiated tuples corresponding to each of the positive literals and the relations do not contain tuples corresponding to the negative literals. The consequent actions are of the form: (make R(a 1, a2,-,a,,x1, xz7-,x,) ) or (remove P(a 1, a2 ,.., a,,xi, x2 ,.., xn) ), where P and R are relations. Again, we assume that all vari- ables xi, x2, . . . , x, are range restricted. The interpretation of the make action is to insert the corresponding tuple into the R relation. Similarly, the remove action deletes the existing tuple from the P relation. This requires that the expression P(a,, a2,.*,a,,x1, x z,..,x,) that is referred to by the remove action must occur as a positive literal in the antecedent of that production. We note that the OPS5 language has many additional features that are not described here; we have not considered the effect of such features in our research. The operational semantics of an OPS5 program has been defined as follows: The initial state of the PS corresponds to an initial EDB, corresponding to all the tuples of the EDB relations, and a set of productions. Processing in a production system repeatedly cycles through the following sequence: Match For each production, the antecedent, inter- preted as above, is queried against the tuples of the corresponding relations. Each production whose antecedent is satisfied, together with its instantiated tuples is placed in a conflict set. Select Select one satisfied production from the conflict set. If there is no such production, halt execu- tion. Act For this selected production, execute the make or remove action, interpreted as above. As a result of the Act phase, the EDB relations are updated. Consequently, the next Match phase may produce a new conflict set. There is no concept of a query that retrieves information, in a PS program. Processing will con- tinue as long as productions are executed and the EDB relations are updated. Processing terminates when an operational fixpoint is reached, i.e., when there are no longer any productions that can update the EDB relations. This operational RASCHID 285 fixpoint (or the updated relations) corresponds to the meaning of the PS program. Shortcomings of the Operational Semantics The operational semantics for OPS5 are incom- pletely defined. Consequently, an initial EDB of relations and a set of productions can produce dif- ferent answers. In some cases, an operational fixpoint is never reached. Example 1 Consider a PS whose initial EDB has two tuples, {Employee(Mike). GoodWorker(Mike).), and the following set of productions: (p p1 (Employee(X), GoodWorker( + ( make Manager(X) ) ) (p ps (Manager(X)) + ( make HasOffice ) ) (p p, (Employee(X), HasOffice( + ( make PoorWorker ) ) (p p4 (Manager(X), PoorWorker( -+ ( remove Manager(X) ) ) Given this initial EDB and corresponding set of productions, p,, p, and p, will execute in that sequence and the tuples Manager(Mike), HasOffice(Mike) and PoorWorker(Mike) will be added to the corresponding EDB relations. Next, p, executes and the tuple Manager(Mike) will be deleted from the Manager relation. Subsequently, p, and p, will execute, first inserting the tuple Manager(Mike) and then deleting this tuple from the Manager relation. Processing of p, and p4 will continue but an operational fixpoint is not reached. Example 2 The initial EDB = {Employee(Mike).) and the productions are as follows: (P P, (EmPloYeem + ( make GoodWorker ) ) (p p, (Employee(X), GoodWorker( + ( make Manager(X) ) ) (p ps (Employee(X), 1 GoodWorker( + ( make PoorWorker ) ) If productions execute in the sequence pi fol- lowed by p,, then the final EDB will contain the set of tuples (Employee(Mike). GoodWorker(Mike). Manager(Mike).). If the execution sequence were p, followed by p, and pz, then, the final EDB would include the tuples, (Employee(Mike). GoodWorker(Mike). Manager(Mike). PoorWorker(Mike).). Thus, in this case there are two fixpoints. A Corresponding Logical Theory In order to understand the shortcomings of the operational semantics, and to define a correct semantics, we define how a logical theory can be obtained from the productions in the PS program. Definition Every production that has a make action in its consequent corresponds to a rule of an inten- sional database (IDB). For example, the following production: h&P;lJy, -l Q(4) + (make R(x)) ) CorresPonds to P(x), 1 Q(x) + R(x). Every production that has a remove action in its consequent corresponds to an integrity con- straint (IC). G eneral forms of integrity constraints and their treatment are discussed in Kowalski and Sadri 1989; we delay a detailed discussion of con- straints to a later section 4. Definition Every production that has (remove P(x) ) in the consequent is a constraint. The literal P(x) is retracted literal to restore consistency. Thus, the following production: (P ~2 O=(x), 1 Q(x)) + (remove P(x)) ) corresponds to the following IC: P(x), 1 Q(x) + . P(x) is retracted to maintain consistency and the database must not prove Vx P(x) ~lQ(x). The meaning of treating some productions as integrity constraints will be discussed in section 4. The following logical theory will be obtained, corresponding to the productions of Example 1: EDB = { Employee(Mike). GoodWorker(Mike). 3 IDB = {Employee(X), GoodWorker + Manager(X). Manager(X) + HasOffice . Employee(X), HasOffice +PoorWorker(X).) IC = {Manager(X), PoorWorker + . 3 We can see that the logical theory of the PS is inconsistent with the constraints. Thus, there can be no model for the theory which is also a model for the constraints (Lloyd 1987). In the case of Example 2, there is a negative literal in the antecedent of a rule. With Horn theories (includ- ing stratified theories), the modus ponens rule of inference is insufficient to prove negative informa- tion. To do so one uses the closed world rule of inference or the closed world assumption (CWA). The correct interpretation, based on the CWA, is 286 AUTOMATED REASONING that a tuple, <ai, aa,... a,> is not true if and only if the IDB U EDB viewed as a logical theory can- not prove P(a,, a2,. . . a,). In our example, it is clear that the theory can prove GoodWorker(Mike), and 1 GoodWorker(Mike) can- not be proved. Thus, the interpretation of nega- tive literals in the operational semantics of OPS5 is incorrect. 3. Stratified Production Systems We identify a class of stratified PS programs, and we define an operational semantics for these pro- grams. Stratification is an extension of Horn pro- grams to more general Horn programs that allow negative literals in the antecedent of a rule; recall that productions in OPS5 have the same feature. Our research draws upon existing research in stratified databases (Apt, Blair and Walker 1988). The Operational Semantics A stratified production system program is viewed as a stratified program, and comprises an exten- sional database (EDB) of facts, a stratified inten- sional database (IDB) of rules, and a stratified set of integrity constraints (IC). Both rules and integrity constraints correspond to productions in PS. The initial PS program comprises the following: (1) an intensional database of rules (IDB), where each rule corresponds to a production that has a make action as its consequent, (2) a set of integrity constraints (IC), where each integrity constraint corresponds to a production that has a remove action as its consequent, and (3) an initial extensional database of facts (EDBe). In the operational semantics, there must exist a partition so that PS is a stratified database. Thus, PS = PS, u PS, . . . u PS,. Each of the partitions PS, comprises a set of rules IDBi, and a set of integrity constraints .TCd, each of which may be possibly empty. Partition PS, comprises the initial extensional database EDB,; IDB, and IC, are null. The following con- ditions hold for the stratification: (1) IDB = IDB, (J . . . . u ID& (2) IC = IC, 6 . . . l-J ICn (3) (4 (5) (6) , a literal is all productions in which the literal occurs in the make action. For every positive literal in the body of a rule in IDB,, or in the body of an integrity con- straint in ICi, all other integrity constraints where the literal occurs in the remove action must be contained within U ICi. j<i For every negative literal in a rule in IDB,, or in an integrity constraint in lCi, the definition of that literal must be contained within U IDBi. j<S For every negative literal in a rule in IDBi, or in an integrity constraint in ICi, all integrity constraints where the literal occurs in the remove action must be contained within U ICi. jr i The Operator Tps Once such a partition has been obtained for the stratified PS program, then, for each partition PS,, we define an operator Tps as follows: t Definition Ups is a Herbrand universe for the stratified PS comprising predicates (make P), (remove P), where P ranges over all propositional variables in the PS. If we consider a PS program where the proposi- tional variables are the set (A, B, C3, then Ups is the set of predicates {(make A), (remove A), (make B), (remove B),(make C), (remove C)>. In the case of predicate variables, we will use relations to represent Ups, two for each predicate symbol. Thus, for predicate P, relation makeP will contain all tuples P( .,.,. . .) which are added by some action (make P( .,. ,. . .)) and relation removeP will contain all tuples P( .,.,...) which are removed by some action (remove P( .,.,... )). Definition For each proposition P (or ground positive literal P( .,.,...) ), in EDB,, we replace it with (make P), (or we add the tuple P( .,.,...) to the RASCHID 287 For every positive literal in the body of a rule in IDB,, or in the body of an integrity con- straint in ICi, the definition of that literal must be contained within U IDB,. The definition of j<i relation makeP). Definition The interpretation of the predicates of Ups (for the propositional variable P), is defined as fol- lows: PI h-l= PI A 1 (remove P) I= P (2) (make P) A (remove P) L 7 P (3) 1 (make P) A 1 (remove P) b 1 P (4) 1 (make P) A (remove P) is not allowed in the operational semantics and represents an inconsistency. Definition T ps is a mapping from a subset of Ups to Ups, such that for any rule in IDBi or any integrity constraint in rCi, if there exists an interpreta- tion of EDBi-, , as described above, such that the literals in the antecedent of the correspond- ing production are true, then, the operator adds the action in the head of the production to EDBi . Each EDBi is computed as follows: EDB, = ED& u Tps, t w (EWJ ‘EDB, = ED4 u TPS, t w (ED4) EDB, = EDB,-, u TPSa t w (EW-1) Obtaining an Operational Fixpoint for Tps Processing for each partition Psi should terminate when an operational fixpoint is reached, i.e., when there are no longer any satisfied productions that can update EDBi. Processing for PS terminates when the operational fixpoint for PS, is reached and EDB, is computed. Theorem Tps f w (EDBi-~) is a fixpoint for PS, = IDLE U ICi. We refer the reader to (Rasc89) for the proof. Example 3 Consider a PS whose initial EDB has two tuples, (Employee(Mike). GoodWorker(Mike).), and the following set of productions: (p p1 (Employee(X), GoodWorker( + ( make Manager(X) ) ) (p p2 (Employee(X)) + ( make HasOffice ) ) (p p3 (PoorWorker( HasOffice( + ( remove HasOffice ) ) (p p4 (Employee(X), HasOffice( -+ ( make Manager(X) ) ) The stratification conditions will place produc- tions p, in a higher stratum, say PS,, while the other three productions are placed in PS,. The operational fixpoint EDB, is as follows: CmakeEmployee(Mike). makePoorWorker(Mike). makeHasOffice(Mike). removeHasOffice(Mike).) EDB, is interpreted to prove I HasOffice(Mike) and Manager(Mike) will not be an answer. 4. Maintaining Consistency with Integrity Constraints We now try to understand the meaning of main- taining consistency with respect to integrity con- straints in a stratified PS program. Informally, a database must satisfy its integrity constraints as it changes over time. Usually, an update to the data- base (more precisely an update to facts in the EDB) may cause the violation of an integrity con- straint; such updates are rejected or modified. Sometimes, the database itself, i.e., the facts and the rules may be inconsistent with the constraints and must be modified, to maintain consistency. In Kowalski and Sadri 1989, such a method is presented for transforming a theory which is incon- sistent with respect to a set of integrity constraints into a transformed theory which is consistent with the constraints. The transformation is syntactic. Although the transformation works for more gen- eral constraints, we restrict the discussion to denial constraints of the form A(t), Conj+. where Conj is a conjunction of positive or negative literals (and may be empty). The denial, or the body of the constraint, should not be true in the database. The atom A is the retractable atom that restores consistency, if the constraint is violated. Thus, if we consider the theory CC. C + A3 and the constraint A, 1B +, where the retractable atom is A, then, the theory is inconsistent with the con- straint. However, the transformed theory (C. C, B +A3 is consistent with the constraint. If we apply a similar transformation to the theory obtained from the productions of Example 3, we obtain the following consistent theory: EDB = (Employee(Mike). GoodWorker(Mike). 3 IDB=(Employee(X), GoodWorker(X)+Manager(X). Employee(X) lPoorWorker(X)+ HasOffice( Employee(X), HasOffice + Manager(X). 3 We see that this theory will not prove Manager(Mike), just as in the operational seman- tics. In general, we can prove that if the PS 288 AUTOMATEDREASONING program is stratifiable as defined, then the follow- ing hold: (1) the logical theory derived from the stratified PS program, modified to be consistent with the constraints (also derived from the pro- gram), is a stratified theory. (2) the operational fixpoint of the stratified PS program is identical to the model for the modified consistent theory that is derived from the program. 5. Summary A class of stratified PS programs and an opera- tional semantics for these programs have been defined. The theory derived from the productions is modified so that it forms a consistent theory, I%, with the integrity constraints that are also derived from the productions. The operational fixpoint of PS is identical to the model for I%. A formal presentation of this research is in Raschid 1989. Future research includes extending the semantics of PS programs to include PS programs that exhibit non-deterministic behaviour when executing pro- ductions. 6. References Apt, K-R., Blair, H.A. and Walker, A. 1988. Towards a Theory of Declarative Knowledge. In (Minker 1988). Delcambre, L.M.L. and Etheredge, J.N. 1988. A Self-Controlling Interpreter for the Relational Pro- duction Language. In Proceedings of the ACM Sig- mod International Conference on the Management of Data. Forgy, C.L. 1981. OPS5 User’s Manual, Technical Report CMU-CS-81-135, Carnegie-Mellon Univer- sity. Forgy, C.L. 1982. Rete: A Fast Algorithm for the Many Pattern/Many Object Pattern Match Prob- lem. Artificial Intelligence (19). Hayes-Roth, F. 1985. Rule Based Systems. Com- munications of the ACM(28) 9. Kowalski, R. and Sadri, F. 1989. Knowledge Representation without Integrity Constraints. Technical Report, Imperial College, London, Eng- land. Lloyd, J.W. 1987. Foundations of Logic Program- ming, Second, Extended Edition. Springer Verlag. Maindreville, C. de and Simon, E. 1988. A Pro- duction Rule Based Approach to Deductive Data- bases. In Proceedings of the Fourth International Conference on Data Engineering. Minker. J., ed. 1988. Foundations of Deductive Databases and Logic Programming. Morgan Kauf- mann Publishers, Inc. Raschid, L. 1989. Defining a Semantics for Pro- duction Systems based on Stratified Databases and Integrity Constraints, Technical Report 89-103, University of Maryland. Raschid, L., Sellis, T. and Lin, C-C. 1988. Exploiting Concurrency in a DBMS Implementa- tion for Production Systems. In Proceedings of the International Symposium on Databases in Parallel and Distributed Systems. Sadri, F. and Kowalski, R. 1988. A Theorem- Proving Approach to Database Integrity. In (Minker 1988). Sellis, T., Lin, C-C. and Raschid, L. 1988. Imple- menting Large Production Systems in a DBMS Environment: Concepts and Algorithms. In Proceedings of the ACM Sigmod International Conference on the Management of Data. Simon, E. and Maindreville, C. de, 1988. Deciding Whether a Production Rule is Relational Comput- able. In IProceedings of the International Confer- ence on Database Theory. Widom, J. and Finkelstein, S.J. 1989. A Syntax and Semantics for Set-Oriented Production Rules in Relational Database Systems, IBM Research Report, IBM Almaden Research Center. RASCHID 289
|
1990
|
43
|
960
|
Exploiting locality in a TMS Johan de Kleer Xerox Palo Alto Research Center 3333 Coyote Hill Road, Palo Alto CA 94304 USA Email: deKleer@xerox.com Abstract This paper presents a new approach for exploiting Truth Maintenance Systems(TMSs) which makes them simpler to use without necessarily incurring a substantial performance penalty. The basic intu- ition behind this approach is to convey the local- ity of the knowledge representation of the problem solver to the TMS. The TMS then uses this local- ity information to control and restrict its inferences. The new TMSs accept arbitrary propositional for- mulae as input and use general Boolean Constraint Propagation(BCP) t o answer queries about whether a particular literal follows from the formulae. Our TMS exploits the observation that if the set of propositional formulae are converted to their prime implicates, then BCP is both efficient and logi- cally complete. This observation allows the prob- lem solver to influence the degree of completeness of the TMS by controlling how many implicates are constructed. This control is exerted by using the locality in the original task to guide which com- binations of formulae should be reduced to their prime implicates. This approach has been imple- mented and tested both within Assumption-Based Truth Maintenance Systems and Logic-Based Truth Maintenance Systems. 1 Introduction This paper presents a new practical approach for ex- ploiting Truth Maintenance Systems which makes them simpler to use without necessarily incurring a substan- tial performance penalty. The basic intuition behind this new approach is to convey the locality of the knowl- edge representation of the problem solver to the TMS. Many AI problem solvers, particularly those which rea- son about the physical world, are inherently local - each constituent of the problem (e.g., a process such as flowing, a component such as a pipe, etc.) has a fixed behavioral model. Much of the reasoning can be viewed as propagation: whenever some new signal is inferred to be present the models of the components on which it impinges are consulted to see whether further infer- ences are possible from it. Many of these AI problem solvers either exploit TMSs to do much of this propa- gation, or use TMSs to represent the results of propa- gations. Although widely used, anyone who has used these strategies can attest that current TMSs manifest some surprising logical incompleteness when used in this 264 AUTOMATED REASONING way. These blind spots result from the fact that local- ity present in the original model is often completely lost within the TMS. The TMS framework we present is fully expressive ac- cepting arbitrary propositional formulae as input. Pro- vided with advice from the overall problem solver it is, if needed, logically complete. Propositional satisfiability is NP-complete, but nevertheless often much of the cost of logical completeness can be avoided by exploiting local- ity. For example, conjunctions of formulae in the model library can be precompiled into their prime implicates to reduce run-time cost. Also, the TMS uses locality in- formation at run-time to determine which combinations of formulae are worth analyzing. We have implemented our framework and used it with both Assumption-Based Truth Maintanence Sys- tems (ATMSs) [2; 71 and Logic-Based Truth Mainte- nance Systems (LTMSS) [2; 19; 20; 211. We have used it to compile models from constraints, confluences, order- of-magnitude reasoning axioms and processes. A longer paper [lo] explores the role of this framework in quali- tative physics in more detail. 1.1 Encoding models as formulae Most problem solvers wish to represent arbitrary propo- sitional formulae many of which derive from local con- stituents of the problem (e.g., component or process models). However, most TMSs lack the expressive power to represent arbitrary formulae. Therefore, one is typ- ically forced to encode the propositional formulae in terms the TMS accepts. For example, [4] provides a variety of ways of encoding propositional formulae for the Assumption-Based Truth Maintenance Systems (ATMSs). T ec ni h q ues like these are widely used in QPE [13; 141. u f t n or unately, these encodings tend to be ex- tremely cumbersome. The TMSs which accept arbitrary clauses (such as LTMSs) seem to be more powerful be- cause any propositional formula can easily be converted into an equivalent set of clauses by putting it into con- junctive normal form CNF[l]. Unfortunately, complete LTMSs based on clauses are rarely used because they are too inefficient. Instead, all common LTMS implementations use Boolean Constraint Propagation(BCP)[2; 19; 20; 211 on clauses. BCP is a sound, incomplete, but efficient inference procedure. BCP is inherently local considering only one proposi- tional formula (i.e., boolean constraint) at a time. This locality is the source of both its incompleteness and effi- ciency. Unfortunately, converting a formula to its CNF From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. clauses loses the locality sider the formula: of the original formula. Con- (x * (Y v 4) A (x v Y v 4 (1) If y were false, then considering this formula alone, in isolation, we can infer z must be true (this can be seen by the fact that if z were false, the first conjunct x j (yVz) requires x to be false, and the second conjunct (XV yVz) requires x to be true). However, this information is lost in converting the formula to its two CNF clauses: 1xvyvz, xvyvz. Neither of these two clauses can, individually, be used to infer z from ly. Taken together, of course, they can. Consider QPE as an example [13; 141. QPE encodes every qualitative process model as a set of formulae which are eventually encoded as a set of ATMS horn clauses. Within QPE, this set of horn clauses represents a fixed local module, but within the ATMS each clause is treated independently. As some of the formulae cannot be converted to purely horn clauses, the basic ATMS algorithms are incomplete with respect to the original formulae, and the ATMS is therefore incapable of mak- ing some simple local inferences which follow from the model alone. QPE deals with this difficulty by adding more clauses (than conversion to CNF would indicate) so that the basic ATMS algorithms can make more infer- ences than they otherwise would. Part of our proposal is that the set of formulae representing a model be con- veyed to the TMS as a single module and the TMS use a complete inference procedure locally on modules. As a result we achieve the kind of functionality that is desired, without incurring substantial performance degradation and without burdening QPE with needless encoding de- tails. This process can be made efficient by recognizing that each model type instantiates the same set of for- mulae and therefore most of the work can be done at compile time once per model type. Conceptually, the new TMSs are supplied a set of ar- bitrary propositional formulae and use general BCP to answer queries whether a particular literal follows from the formulae. BCP is usually applied to clauses but can be applied to arbitrary formulae as well. As input the TMS can accept new propositional formulae to define a module, conjoin two existing modules, or accept a new formula to be conjoined with an existing module. Lo- cally, within each module, the TMS is logically complete. As a consequence, the problem solver can dynamically control the trade-off between efficiency and completeness - if completeness is required, all the modules are con- joined, if efficiency is is required, each formula is treated as an individual module. Later in this paper we present a number of techniques to guide the order in which mod- ules should be conjoined in order to minimize computa- tional cost. Consider the example of two pipes in series (Fig. 1). Each pipe is modeled by the qualitative equation (or con- fluence, see [3] for precise definitions) [dPl]-[dP,.] = [cZQ] where Pi is the pressure on the left, P, is the pressure on the right and Q is the flow from left to right. ([dx] is the qualitative (+, 0, -) value of 5’. Th us, the attached pipes can be completely modele by three confluences: [@AI - [d&11 = [~QABI, (2) [~PB] - WC] = [~QBc], (3) [~QAB] = [~QBc]. (4) Suppose we know that the pressure is rising at A (i.e, [dPA] = [+I) and the pressure is fixed at C (i.e., [dPc] = [O]). Considering each component or confluence individ- ually we cannot infer anything about the flows. We only know one of the three variables in confluences (2) and (3), and none of the variables in confluence (4). There- fore, none of the confluences, individually, can be used to infer a new variable value. The only way to determine the behavior is to somehow solve the confluences - but that requires global reasoning over the confluences. If the individual qualitative equations are converted to their propositional equivalents for a TMS (as many qualitative physics systems do), then [~PB], [~&AB] and [QQBc] remain unknown due to the incompleteness of most TMS’s. However, in our TMS if the formulae rep- resenting the individual components are merged then [QQAB] = [~QBc] = [+I is inferred. As such component combinations reoccur in many systems, this combining can be done once in the model library. To compile this combination, our TMS merges the propositional encod- ing of the confluences but without the specific inputs ([dPA] = [+] and [dPc] = [O]). The result is identical to the propositional encoding of the confluence: W’AI - [df’c] = [~&AB] = [~QBc]. After compiling this combination, and applying the in- puts our TMS infers that [QQAB] = [$QBc] = [+] far more efficiently than before (i.e., in one step). A device can always be analyzed by first compiling it without knowledge of any input or outputs. However, compiling a full device model is expensive - it is only useful if we expect to put it in the model library or need to consider many input value combinations. When analyzing a device our TMS does not force the problem- solver to decide whether or not to compile the device beforehand. Our TMS lazily compiles the propositional formulae it is supplied - it only compiles enough to answer queries for the givens it is supplied. When the givens are changed the TMS, if necessary, incrementally compiles more pieces of the device to answer the query. If all possible givens and queries are applied, then the compiled result will be the same as having compiled the full device beforehand. After developing our approach Section 8 expands on these observations and analyzes its relationship with the qualitative resolution rule [al; 121. 2 BCP on formulae and clauses As our approach draws on the intuitions underlying BCP, we give a synopsis of it here. (Note that BCP DE KLEER 265 A B c Figure 1: Assembling the qualitative models of the two joined pipes is equivalent to merging the formulae mod- eling the two pipes. achieves similar results to unit resolution.) BCP oper- ates on a set of propositional formulae (not just clauses) F in terms of propositional symbols S. A formula is de- fined in the usual way with the connectives 7, j, E, V, A and oneof. (oneof is a useful connective requiring that exactly one of its arguments be true.) For the purposes of this paper a clause is a disjunction of literals with no literal repeated and not containing complementary literals. BCP labels every symbol T (i.e., true), F (i.e., false) or U (i.e., unknown). BCP is provided an initial set of assumption literals d; if z E d, then x is labeled T, and if lx E d, then x is labeled F. A may not contain complementary literals. All remaining symbols are initially labeled U. The reason for distinguishing A from F is that F is guaranteed to grow monotonically while assumptions may be added and removed from A at any time. BCP operates by relabeling symbols from U to T or F as it discovers that these symbols logically follow from F U A. A labeling which does not label any symbol U is complete. Conversely a labeling which labels some symbols U is partial. A completion of a partial labeling is one which relabels all the U symbols T or F. Given any labeling each BCP constraint (in the BCP literature propositional formulae are called constraints) is in one of 4 possible states. The labeling satisfies the constraint: for every com- pletion of the current labeling the constraint is true. For example, labeling x T satisfies the constraint XV y. The labeling violates the constraint: there is no com- pletion of the current labeling which satisfies the con- straint. Consider two examples: (1) if the constraint is x V y and both x and y are labeled F, then the constraint is violated, and (2) if the constraint is (x v Y) A (1: v 1Y) and x is labeled I?, then there is no way to satisfy the constraint. A constraint forces a symbol’s label if in every com- pletion of the current labeling which makes the con- straint true that symbol is always labeled T or always F. There may be multiple such symbols. For exam- ple, if x is labeled T, then the constraint x - (y A z) forces y and z to be labeled T. Consider the example from the introduction: (x j (y V z)) A (z V y V z). If y is labeled F, then the label of z is forced to be T. l Otherwise a constraint is open. BCP processes the constraints one at a time mono- tonically expanding the current labeling. The behavior of BCP depends on the condition the constraint is in: If the current labeling satisfies the constraint, then the constraint is marked as satisfied and is no longer considered. If the current labeling violates the constraint, then a global contradiction is signaled. If the current labeling forces the label of some other symbol, then that symbol is labeled and all unsatis- fied and unviolated constraints mentioning that sym- bol are scheduled for reconsideration. If the current constraint is now satisfied it is so marked. Otherwise the constraint remains open and BCP re- considers it when some (other) symbol it references is labeled T or F. If this BCP is applied purely to clauses, then the result- ing behavior is identical to the clausal BCP dicussed in the LTMS literature. If the constraints are arbitrary formulae, then deter- mining whether a constraint forces a symbol label is complex to implement and computational expensive ex- ecute. However, if the constraints are clauses, then BCP can be implemented simply and efficiently. In particular, we store a count with each clause indicating the number of symbols which are labeled U or whose label satisfies the clause. For example, given the clause x V -y where x is labeled U and y is labeled T, the count for the clause is 1. Whenever this counter is reduced to 1, then the clause forces the label of a single remaining symbol (i.e., in this case 1: is forced to 3”). If the count is reduced to 0, then the clause is violated and a contradiction is signaled. As a consequence of this encoding, BCP on clauses can be implemented simply by following point- ers and decrementing counters. Conversely, the process of removing an assumption from A can be efficiently im- plemented by following pointers and incrementing coun- ters. (See [7] for details.) BCP on clauses is equivalent to the circuit value problem and therefore is P-complete (see also [15]). Its worse case complexity is the number of literals in the clauses. BCP is logically incomplete in that it sometimes fails to label a symbol T or F when it should. For example, consider the two clauses from the introduction: 7xvyvz, xvyvz. If y is labeled F, then BCP on the clauses does not label z T. (Note that BCP is also logically incomplete in that it sometimes fails to detect contradictions.) 3 Compiling into prime implicates The previous example (the encoding of formula (1)) shows that running BCP on the original formulae is usu- 266 AUTOMATEDREASONING ally not the same as running BCP on the clauses pro- duced by converting the formulae to CNF. (BCP on the original formulae is usually much stronger or, at worst, equivalent.) Hence, we cannot directly use the efficient BCP algorithms that have been developed for clauses for arbitrary formulae and no correspondingly efficient BCP algorithm is known. This section shows that if each in- dividual formula is encoded by its prime implicates[16; 17; 221, then BCP on the resulting clauses is equivalent to running BCP on the original formulae. We use the following definitions. Clause A is sub- sumed by clause B if all the literals of B appear in A. Therefore if A subsumes B, then B is true wherever A is. An implicate of a set of propositional formulae 3 is a clause entailed by 3 not containing complementary literals. A prime implicate of a set of formulae 3 is an implicate of 3 no proper subclause of which is an impli- cate of 3. Consider the simple example of the introduction. Us- ing the conventional conversion to CNF the formula, (x * (Y V %)) A (x V Y V z), (5) is equivalent to the conjunction of the clauses, 1xv yvz, xvyvz. However, there is only one prime implicate, yv %. This example illustrates that there may be fewer prime implicates of a formula than the conjuncts in the CNF of a formula. Unfortunately, the reverse is usually the case. Consider the clause set: YaVb, wvd, -eve, lbvldvle. In this case, these 4 are all prime implicates, but there are 3 more (for a total of 7): There are a variety of different algorithms for comput- ing prime implicates (see [6; 7; 9; 16; 22; 231). Stripped of all the efficiency refinements discussed in the next section, our basic approach is to use a variation of the consensus method to compute prime implicates. First, the formula is converted into CNF to produce an initial set of clauses. Then we repeatedly take two clauses with exactly one pair of complementary literals and construct a resulting clause with both those literals removed. All clauses subsumed by others are removed. This process continues until no new unsubsumed clause is producible. Using the preceeding definitions, the following theo- rems are key to an efficient implementation of BCP on constraints: Theorem 1 Given a set of clauses Z which are the set of prime implicates of some set of propositional formulae and a set of assumptions d, then if Iud is inconsistent, then BCP will detect a violation. Proof. If Z U A is inconsistent, then there must be a clause, -Al v . . . v -A,, entailed by Z where Ai E A. This clause is an implicate of Z and thus subsumed by some clause S of 2. As all the 1Ai are labeled F, BCP will detect that clause S is violated. 0 Theorem 2 Given a set of clauses Z which are the set of prime implicates of some set of propositional formulae and a set of assumptions A such that AM is consistent, then BCP computes the correct label for every node. Proofs for the remaining theorems can be found in [lo]. Theorem 3 Let A be a set of literuls, 3 a set of propo- sitional formulae and Z is the union of the prime impli- cates of euch of the formulae of 3 individually. If BCP on A U 3 does not detect any violations, then BCP on Au3 produces the same symbol labels us BCP on duz. Theorem 4 Let A be a set of literuls, 3 a set of propo- sitional formulae, and Z is the union of the prime im- plicates of each of the formulae of 3 individually. BCP on A U3 detects a violation exactly when BCP on ZU3 detects a violation. The first two theorems tell us that we can make BCP complete if we need to. The second two theorems tell us that running BCP on the prime implicates of the in- dividual formulae is the same as running BCP on the formulae. Thus, we can exploit the efficient implemen- tations of clausal BCP. Note that the prime implicates, by themselves, do not solve the task - they represent a family of solutions each characterized by a distinct assumption set A. Com- puting the prime implicates is analogous to compiling a propositional formula (or set of them) so that it is easy to compute the resulting solution once some input, i.e., A is provided. Fig. 2 illustrates some of the options engendered by the theorems. Although replacing the entire set of for- mulae with their equivalent set of prime implicates al- lows BCP to be logically complete, the required set of prime implicates can be extremely large. This large set is both difficult to construct and, its very size makes it hard for BCP to work on. Therefore it is usually im- practical to exploit this strategy directly. 4 Basic LAMS transactions Our basic formula LTMS permits the following transac- tions: (add-formula formula): This adds an individual formula to the TMS. Section 2 outlines the allowed con- nectives. (add-assumption symbol label): This labels the symbol T or F. This retracts any previous add-assumption for this symbol. (retract-assumption symbol): This removes the initial label for the symbol. Note that the symbol will retain a non-U if it follows from A U 3. DEKLEER 267 Figure 2: This figure illustrates the different ways BCP can be used. BCP on arbitrary formulae (expensive) produces labeling A. If the formulae encoded as their CNF clauses, then an efficient clausal BCP produces an (unfortunately weaker) labeling B. If formulae are in- dividually converted into their prime implicates, then the efficient clausal BCP finds the same labeling A as the inefficient formula BCP on the original constraints. Finally, if the prime implicates of all the formulae are constructed, then clausal BCP is logically complete. (label? symbol): This returns the label for the sym- bol. (inconsistent?): Tests whether A U 3 is inconsis- tent. 5 Lazy compilation Using the results of the section 3 a complete formula LTMS algorithm can be implemented as follows. The algorithm always maintains the set of prime implicates 3’ of 3. Whenever a new formula f is added to 3, 3’ is updated by computing the prime implicates of the old 3’ and the new formula f thus avoiding recomput- ing the same prime implicates from scratch each time. Whenever A is changed, we execute the usual clausal BCP algorithm on 3’. Therefore, the major cost is paid up front when a formula is added to 3 and not when A is changed. The algorithm just sketched out is needlessly expen- sive. In the next few sections we present techniques which substantially improve its performance in most cir- cumstances. The basic intuition behind these techniques to to delay the construction of additional implicates un- til absolutely necessary because constructing and storing implicates is the most expensive aspect of our frame- work. In all these techniques 3’ is no longer a set of prime implicates of 3, but simply a set of implicates of 3 none of which is subsumed by another. Experience has shown that problem solvers often supply a sequence of formulae without making any intervening queries. Thus, calls to add-formula, add-assumption and retract-assumption are not be acted upon until an actual query is made. When the problem solver requests a label of a symbol the follow- ing steps are performed: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. Update A. Perform clausal BCP. If BCP supplies a label for the symbol, we are done. Take the first queued formula f. If there isn’t one, then go to step 7. Add each of its prime implicates to the LTMS clause set 3’ and mark each such clause as unprocessed. Go to step 2 Consider all unprocessed clauses u. Remove all other clauses subsumed by u from 3’. Mark u as processed. For two clauses u and v in 3’ which contain exactly one complementary pair of literals, which have not been resolved before, compute the consensus of u and v, add it to 3’, and remove the clauses it subsumes from 3’. If no new clause was added in the previous step and no formulae additions are queued, the the label is U. Go to 2. Although in the naive algorithm which initially com- putes all prime implicates, retracting an assumption is very simple, in this algorithm retracting an assumption can later provoke further implicate construction because some symbol might lose its T/F label. Checking for in- consistency is nearly identical. If at any point clausal BCP reports an inconsistency, then no further process- ing is necessary. The basic intuition behind this algorithm is to run the efficient clausal BCP before constructing new impli- cates. This is analogous to the familiar unit-preference strategy except that the initial unit clauses (i.e, -4) can be retracted. The preceeding algorithm still computes far too many implicates than is necessary for a particular A. We can exploit BCP labels to further delay the construction of new implicates. In particular, computing the consen- sus of two clauses where the complementary literals are labeled T/F cannot provide new information (for the current d). Therefore, we can add this restriction to the algorithm. This yields substantial performance im- provements if not all possible A are explored. Many efficiency improvements are possible on this ba- sic scheme. An important one results from distinguish- ing between the two different reasons a symbol can be labeled T/F: (1) a symbol can be labeled because it follows via BCP from 3 alone (we call this a fixed la- bel), or (2) a symbol can be labeled because it follows via BCP from 3 U A but not from 3 alone (we call this a variable label). The important difference is that the 268 AUTOMATEDREASONING fixed labels cannot change as A changes. If a fixed lit- eral label satisfies a clause, then that clause is removed from 7. If a variable literal label satisfies a clause, then the clause is temporarily set aside. If a fixed literal label violates a clause, then the literal is removed from the clause. These results happen anyway as a consequence of constructing implicates. However, BCP achieves them earlier and more efficiently. Note that as variable labels change, clauses which were previously set aside need to be reanalyzed to compute further implicates. 6 Pre-compiling formulae Many AI problem solvers operate with a knowledge base or component library. Given a particular task, pieces of this knowledge base are instantiated as needed. For ex- ample, in Qualitative Process Theory most processes are instantiated with the same fixed set of formulae (but with different symbols). Hence, the schemas for the prime implicates for each model in the library can be constructed a priori, and many implicate constructions can be thus avoided run time. A single propositional formula may yield a very large number of prime implicates. If some of the symbols of a formula are internal (i.e., appear only in the formula, are guaranteed never to be referenced by any new in- put formula and are of no further interest to the prob- lem solver), then all the clauses mentioning that symbol can be discarded without affecting the functionality of the TMS. As a result BCP need not stumble over these needless clauses. The basic formula LTMS transactions which support this insight are: (compile-formula schema internal-symbols): Used at compile time. This converts the formula schema into a set of prime implicate schemas. This is designed to be used when constructing the knowledge base or the model library. internal-symbols is a set of inter- nal symbols which are guaranteed not to appear again. Therefore, after computing prime implicates, all clauses mentioning internal symbols are discarded. (load-formula schema): This takes the prime im- plicate schemas and communicates them to the TMS. 7 Exercising problem solver control In many cases, even lazily constructing sufficient impli- cates of Y=’ to ensure completeness for the given A is too costly. In this circumstance the problem solver pro- vides external guidance to control which prime impli- cates should be constructed and to choose when to give up completeness. One way to limit the computational cost of the algo- rithm is instead of running the algorithm on the entire set of formulae, only apply the algorithm to subsets of the formulae. This locality is captured by the notion of module. A module is a set of formulae and the LTMS data base consists of a set of modules. The algorithm is restricted to perform subsumption tests and consen- sus constructions only within modules. But the clausal BCP is run across all clauses of all modules. The prob- lem solver is provided an additional interface to control when to modules are to be merged. This requires the following additional transactions: load-formula* and add-formula*: These create modules initially containing only their formula argu- ment. (merge-modules module1 modulea): This tells the TMS to conjoin the two modules, by computing the nec- essary implicates of the combination. (internal symbol) : Used at run time. This informs the TMS that the symbol is internal. If all occurrences of this symbol appear in the same module, than all clauses mentioning this symbol can be discarded. This greatly reduces the number of clauses the TMS needs to con- sider . At the one extreme every formula is an individual module and the problem solver never merges modules. In this case the result is equivalent to running BCP on formulae. As all the formulae may be pre-compilable, this may require no implicate construction at run time. If the problem solver is exercising control to achieve completeness, we must examine more carefully when completeness is achieved for a particular A. Just be- cause some symbol is labeled U is no indication of in- completeness - no one guarantees that every literal or its negation should follow from Fud. However, if every clause is individually satisfied, then we know that the clause set is consistent and we can complete the labeling by arbitrarily changing every U to T or I?. (Of course, this observation is implicit in the lazy algorithm which stops resolving clauses when they are satisfied.) This last observation provides two fundamental tech- niques for coping with incompleteness. First, the prob- lem solver can introduce additional assumptions to at- tempt to satisfy open constraints, in effect, performing a backtrack search. (This has the disadvantage of extend- ing A which may not be desired.) Second, the problem solver controls which modules should be merged and in which order. Merging has two important effects: (a) merging can enable the construction of new implicates which yield relabelings, and (b) if each of the modules are either satisfied (we define a module to be satisfied if every one of its clauses is satisfied) or merged into one common unsatisfied module, then we know that BCP is complete. This tradeoff of whether to use backtracking or merging to construct a solution is analogous to the one faced by CSP [8; 181 solvers. Both approaches to coping with incompleteness can be improved with various tactics. We focus here on tactics to improve the performance of merging. If an internal symbol is labeled U, then the modules which mention it are candidates for early merging. Whether or not this relabels the internal symbol, after the merge all clauses mentioning an internal symbol can be dis- carded. Modules sharing no symbols can be trivially merged as the implicates of the conjunction is the union of the antecedent implicates. If all modules are merged and BCP has not detected a violated clause, then by a DEKLEER 269 slight extension of theorem 1 FUA is satisfiable. When used in this way our TMS is yet another way to test for propositional satisfiability. Our implementation also includes an automatic fa- cility which systematically merges those two modules which would produce a module with the fewest number of symbols (determined directly by counting the non- internal symbols). This exploitation of locality often avoids intermediate implicate bloat. 8 Modeling The user of this style of TMS must make a fundamental tradeoff whether all the formulae should be in one mod- ule (and hence be logically complete), or whether the formulae should all be in individual modules (more effi- cient but incomplete). Suppose all the formulae are in one module. For those symbols which were not provided any initial labels, the same set of implicates will now suf- fice for any labeling for them. This ideally matches the requirements of problem solving tasks which require the inputs to be changed while the input formulae remain constant. In other words, by computing the implicates we have made it easy to solve exponentially many prob- lems via BCP on these implicates. One clearcut example of this occurs in qualitative sim- ulation. Typically qualitative analysis uses propagation to determine the qualitative behavior of a system, how- ever, it is well known that simple propagation is incom- plete and therefore that additional techniques are needed (feedback heuristics, feedback analysis, etc.) One such technique is the qualitative resolution rule [ll] which assembles individual component models into larger as- semblages so that (a) the entire device can be repeat- edly simulated on different inputs by simple propagation alone and (b) larger devices can be analyzed by building it out of known assemblages. Our TMS framework achieves the analogous effect. The qualitative resolution rule (sometimes called the qualitative Gauss rule) is implemented using our TMS. [ll] presents an example where two pipes (Fig. 1) con- nected together produce a model for a single pipe. Con- sider the following instance of the qualitative resolution rule. Let 2, y and z be qualitative quantities such that (we drop [...I when unambiguous), a:+y=o, -x+z=o From these two confluences we can infer the confluence, y+z=o. (6) (To those unfamiliar with qualitative physics this may not seem that surprising, but it is important to remem- ber that qualitative arithmetic does not obey the usual field axioms and thus the equations cannot be manip- ulated as in conventional arithmetic.) The qualitative resolution rule is analogous to binary resolution. Two confluences can be usefully combined only if they share at most one symbol in common, otherwise the result is meaningless. Our TMS achieves the effect of the qualitative resolu- tion rule by conjoining the formulae of the two individ- ual pipes. One way to expand x + y = 0 into clauses is to encode all the value combinations disallowed by the confluence: 1(x=+) v 1(y=+), 1(x = +) v 1(y = O), 1(x = 0) v 1(y = +), 1(x = 0) v 1(y = -), -lx= ( 4 v ‘(Y = 01, 1x= ( -) v 1(y = -)* Expanding -x + z = 0 into clauses includes: 1x= ( -) v -(z = +), 1x= ( -) v l(% = O), 1(x = 0) v l(% = +), 1(x = 0) v l(% = -), 1(x = +) v l(% = O), 1(x = +) v l(% = -). If we add the clause, (x = +) v (x = 0) v (2 = -), compute prime implicates and consider {x = +, x = 0,x = -} internal symbols, then the result is exactly the prime implicates of the result of the qualitative res- olution rule (i.e., of y + z = 0). This encoding might appear cumbersome, but the clauses are easily analyzed with BCP. As we have argued earlier, propagation on clauses (i.e., BCP) is efficiently implemented by follow- ing pointers and manipulating counters. Thus, by ‘As- sembling’ the device, we obtain a set of prime implicates with which it is easy to determine a system’s outputs from its inputs. Dormoy [12] p oints out that applying the qualitative resolution rule sometimes produces a combinatorial ex- plosion. This is analogous to the explosion that can occur in expanding a formula to its prime implicates. In his paper Dormoy proposes a joining rule for controlling this explosion. The joining rule applies the qualitative resolution only to components which share an internal variable - it is equivalent to our TMS heuristic of com- bining modules which share internal symbols. Consider the two pipe problem of the introduction again. Suppose we know that [#A] = [+] and [d&l = [O]. We have, in effect, two choices how to solve the problem. We could first inform the TMS of these values and then ask it to merge the modules of the two pipes; or we could first merge the two modules and then add these values. Although the answer [d&l = [+] remains the same, the resulting TMS data base is quite different. If we start with [&‘A] = [+] and [UC] = [0], then most of the prime implicate constructions can be avoided be- cause these initial values provide initial BCP labels to 6 symbols (i.e., the symbolsrepresenting the possible qual- itative values for #A and ~PB). On the other hand, if 270 AUTOMATEDREASONING the modules are merged first without initial values, then all prime implicates are constructed, and although only a few of them are necessary to solve for the given inputs it is now much easier to solve problems when the inputs are changed. Although computing all the prime implicates for a full device may be expensive, it often may be very useful to incur this cost. Once the prime implicates of a device are constructed, the input-output behavior is completely characterized. From the resulting data base of prime im- plicates one can construct the inputs from the outputs just as easily as outputs from the inputs without con- structing any additional prime implicates. So the same data base can be efficiently utilized for a variety of dis- tinct tasks. 9 Conclusion We have shown a simple example of using our frame- work for simple qualitative physics analysis tasks. The applicability of these techniques extends to any problem- solving paradigm for which finite propositional encod- ings exist and there is some notion of locality in the original task which can be conveyed to the TMS. Many tasks for which TMS’s are normally used are candidates for this approach. One obvious one which we are cur- rently exploring is model-based diagnosis [5]. 10 Acknowledgments Daniel G. Bobrow, John Lamping, Olivier Raiman and Vijay Saraswat provided extensive insights on early drafts. References PI PI PI t-4 PI Chang, C. and Lee R.C., Symbolic Logic and Me- chanical Theorem Proving, (Academic Press, New York, 1973). de Kleer, J., An assumption-based truth mainte- nance system, Artificial Intelligence 28 (1986) 127- 162. Also in Readings in NonMonotonic Reasoning, edited by Matthew L. Ginsberg, (Morgan Kaufman, 1987) 280-297. de Kleer, J. and Brown, J.S., A qualitative physics based on confluences, Artificial Intelligence 24 (1984) 7-83; also in: D.G. Bobrow (Ed.), Reuson- ing About Physical Systems (MIT Press and North Holland, 1985) 7-83; also in: J.R. Hobbs and R.C. Moore (Eds.), Formal Models of the Common-Sense World (Ablex, Norwood, NJ, 1985) 109-183. de Kleer, J., Extending the ATMS, Artificial Intel- ligence 28 (1986) 163-196. de Kleer, J. and Williams, B.C., Diagnosing mul- tiple faults, Artificial Intelligence 32 (1987) 97- 130. Also in Readings in NonMonotonic Reasoning, edited by Matthew L. Ginsberg, (Morgan Kaufman, 1987), 372-388. PI PI PI PI WI WI WI P31 WI WI WI PA Dl P91 PO1 WI PI WI de Kleer, J., A practical clause management system, SSL Paper P88-00140, Xerox PARC. de Kleer, J., Forbus, K., and McAllester D., Tuto- rial notes on truth maintenance systems, IJCAI-89, Detroit, MI, 1989. de Kleer, J., A comparison of ATMS and CSP tech- niques , Proceedings of the Eleventh International Joint Conference on Artificial Intelligence, Detroit, MI (August 1989). de Kleer, J., A Clause Management System based on Boolean Constraint Propagation and clause syn- thesis, 1990. de Kleer , J . , Compiling Devices, submit ted for pub- lication, 1990. Dormoy, J. and Raiman, O., Assembling a device, in: Proceedings AAAI-88, Saint Paul, Minn (1988) 330-336. Dormoy, J-L., Controlling qualitative resolution, in: Proceedings AAAI-88, Saint Paul, Minn (1988) 319-323. Forbus, K.D., Qualitative process theory, Artificial Intelligence 24 (1984) 85-168. Forbus, K.D., The qualitative process engine, Uni- versity of Illinois Technical Report UIUCDCS-R- 86-1288, 1986. Dowling and Gallier, Linear time algorithms for testing the satisfiability of propositional horn for- mulae, Journal of Logic Programming 3 267-284 (1984). Kean, A. and Tsiknis, G., An incremental method for generating prime implicants/implicates, Univer- sity of British Columbia Technical Report TR-88- 16, 1988. Kohavi, Z., Switching and Finite Automata Theory (McGraw-Hill, 1978). Mackworth, A.K., Constraint satisfaction, Ency- clopedia of Artificial Intelligence, edited by S.C. Shapiro, (John Wiley and Son, 1987) 205-211. McAllester, D., A three-valued truth maintenance system, S.B. Thesis, Department of Electrical En- gineering, Cambridge: M.I.T., 1978. McAllester, D., An outlook on truth maintenance, Artificial Intelligence Laboratory, AIM-551, Cam- bridge: M.I.T., 1980. McAllester, D., A widely used truth maintenance system, unpublished, 1985. Reiter, R. and de Kleer, J., Foundations of Assumption-Based Truth Maintenance Systems: Preliminary Report, in: Proceedings AAAI-87, Seattle, WA (July, 1987), 183-188. Tison, P., Generalized consensus theory and ap- plication to the minimization of boolean functions, IEEE transactions on electronic computers 4 (Au- gust 1967) 446-456. DEKLEER 271
|
1990
|
44
|
961
|
Constraints for the iscontinuity fro Mot ion Michael J. Black and P. Anandan Department of Computer Science Yale University New Haven, CT 06520-2158 Abstract Surface discontinuities are detected in a sequence of images by exploiting physical constraints at early stages in the processing of visual motion. To achieve accurate early discontinuity detection we exploit five physical constraints on the presence of discontinuities: i) the shape of the sum of squared differences (SSD) error surface in the presence of surface discontinuities; G) the change in the shape of the SSD surface due to relative surface motion; G) distribution of optic flow in a neighborhood of a discontinuity; iv) spatial consistency of disconti- nuities; V) temporal consistency of discontinuities. The constraints are described, and experimental results on sequences of real and synthetic images are presented. The work has applications in the recovery of environmental structure from motion and in the generation of dense optic flow fields. Introduction The relative motion of surfaces can provide information about the presence of surface discontinuities. We de- tect these discontinuities over time by exploiting phys- ical constraints at early levels in the processing of vi- sual motion. As noted by Marr (Marr 1982), the hu- man visual system efficiently detects object boundaries using only relative surface motion as a cue. For ex- ample, figure 1 shows one image in a random dot se- quence, in which a square patch is translating with respect to a stationary background. Human observers easily detecting the boundary of the square when pre- sented with these images in sequence even when noise is added. Thus lines of discontinuity can provide evi- dence about the presence of surface discontinuities and the structure of the environment. In this paper five physical constraints on the pres- ence of discontinuities will be explored. We will de- scribe how these constraints can be exploited to detect lines of discontinuity from a sequence of densely sam- pled images. The first constraint is derived from the observation that multiple surfaces in relative motion will have dif- ferent best displacements between a pair of images. We use the standard sum of squared digerences (SSD) correlation measure for computing displacements. In the presence of surface discontinuities, the shape of the SSD surface provides information about the number, and relative motion of, the surfaces present (Anandan 1987). In the simplest case, the surface is multi-modal with local minima corresponding to the motion of the surfaces at the discontinuity. While a multi-modal error surface indicates the pres- ence of a discontinuity, the aperture problem means that the absence of a multi-modal surface does not guarantee that no discontinuity is present. A second constraint uses information about how the intensity structure in an area of the image changes with mo- tion. This change is measured by comparing the SSD surface obtained under motion with a translation in- variant auto-correlation surface which would result if no motion were present. If a discontinuity is present, the shape of the surface will change with motion, while uniform motion will result in a surface with similar shape. A third constraint (neighborhood flow modality) ex- ploits the fact that if multiple surfaces are moving rel- ative to each other, then the optic flow will be differ- ent for each surface. This, in turn, will be reflected in a histogram of flow vectors within a neighborhood; the histogram will be multi-modal (Spoerri & Ullman 1987). Naively applied, this approach has serious lim- itations but by using confidence measures (Anandan 1989) associated with the flow field we can effectively exploit this constraint. The fourth constraint exploits the continuity of dis- continuities (Marr 1982). Discontinuities correspond to surface boundaries in the world, and hence it is rea- sonable to assume that such boundaries have spatial extent. A spatial consistency constraint is developed using controlled continuity splines (Kass, Witkin, & Terzopoulos 1987). Finally, assuming a fairly stable environment, dis- continuities tend to persist over time and move contin- uously across the image plane. A temporal consistency constraint is developed using active contour models in 1060 VISION From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Figure 1: Random Dot Image. One image from a motion pair in which a foreground patch is undergo- ing a 2 pixel displacement with respect to a stationary background. Zero mean gaussian noise with a standard deviation equal to 10 percent of the standard deviation of the image has been added to the second image. field using region growing (Potter 1980) or edge detec- tion techniques (Thompson, Mutch, & Berzins 1982). A variation on this approach (Mutch & Thompson 1988) computes accretion/deletion regions using cor- relation techniques. Another approach, which we will also exploit, uses information about the distribution of flow vectors in a neighborhood about a point to decide if a discontinuity is present (Spoerri & Ullman 1987). These previous approaches suffer from two prob- lems. First, they all ignore valuable information that is present in the correlation surface from which the flow is derived. Secondly, many occur too late in the flow computation; to work they must be applied to a smoothed flow field. When these techniques are ap- plied to the raw, unsmoothed, flow field, the results are poor. There is a Catch-22: you need the information about discontinuities to derive an accurate smoothed flow field, and you need the smoothed flow field to de- tect the discontinuities. Our approach is novel in that we develop constraints on the location of lines of discontinuity using infor- mation present in the SSD surface as well as physical properties of discontinuities to achieve robust early de- tection. While the constraints have intuitive appeal, and the experimental results are promising, we cur- rently have no probabilistic justification for the confi- den& measures- associated with these constraints and no probabilistic interpretation is implied. This is an area of ongoing research. which an energy term constrains the motion of the con- tour to be consistent with image flow. Motivation and Previous Work This work has two main motivations. First, one of the primary goals of computer vision is to recover the structure of the environment; surface discontinuities provide a great deal of structural information. Tra- ditional edge detection techniques have well known limitations for boundary detection. They may fail to detect boundaries between textured surfaces, and de- tect many edges which do not correspond to struc- tural properties of the environment but are artifacts of surface marking. Motion based discontinuity detec- tion, may be able to be combined with edge detection schemes to produce more accurate and complete de- scriptions of the environment. Secondly, we would like to incorporate information about discontinuities into the computation of dense optic flow fields over time (Schunk 1989) (Spoerri & Ullman 1987). One of the key observations underly- ing work in optic flow computation is the notion that surface discontinuities are not dense. Or phrased an- other way, that flow changes gradually across the field of view. This allows smoothness constraints to be in- troduced into the flow field computation which cor- rect for noise in image correlation. This assumption of a smoothly changing flow field is violated at ob- ject boundaries, and hence the smoothness constraint In the following sections each of the five constraints is developed in detail and illustrated with experimental. results on synthetic data. We then present experimen- tal results with a real motion pair. Before concluding, we discuss our current research directions. Shape of the Error Surface Correlation-based matching is a common technique used in the computation of optic flow (Anandan 1989). The approach is appealing for a variety of reasons; it is simple, it captures the intuitive notion of similarity between two image regions, and is inherently parallel. The sum of squared differences (SSD) is a common correlation measure which is computationally simple and performs well in empirical tests when applied to band-pass filtered images (Burt, Yen, & Xu 1982). Given a point in an image and a set of points G in a neighborhood of size n x m around the point, we define the data error term for a displacement (u, V) of that point as: E(u, v) = E (I&j) - &(i + u, j + v))~, is not appropriate across these boundaries. By explic- i,jEG itly computing surface discontinuities at early stages of motion processing, discontinuity information can be in- where 11 and 12 denote the intensity functions of two successive images. The SSD surface, S, is defined corporated into the smoothness constraint to produce more accurate flow fields. over the space of possible displacements (u, V) with the height of the surface corresponding to the data error, Most previous attempts at detecting discontinuities E(u, v), of that displacement (figure 2 shows an exam- from motion have focused on an analysis of this flow ple SSD surface at a corner point). BLACKANDANANDAN 1061 \ u Figure 2: Example SSD Surface at a Corner (inverted for display). The shape of the SSD surface is typically quite com- plex and contains information about the motion of the surfaces that gave rise to it (Anandan 1984). In partic- ular, in certain well defined cases, if there are multiple surfaces undergoing relative motion in a neighborhood, then they will each have different best displacements. This gives rise to a multi-modalerror surface with min- ima corresponding to the displacements of each surface. In an ideal situation, minima are easily detected by examining the first and second partial derivatives of the surface. Of course, when dealing with real im- agery, detecting minima may not be so easy. In the presence of noise, true minima may be obscured and spurious minima may be introduced. Additionally, if the relative motion of the surfaces is small, then due to discretization, the peaks may merge together and be indistinct. In practice then, we must settle for a heuristic measure of peakness. One heuristic, $, takes into account the steepness of the peak, by measuring the distance of a point from its neighbors: $(u, v) = e k S(u, v) - S(u + i, v + j). i=-1 j=-1 The more negative $, the more likely a steep peak ex- ists. Other measures of peak shape and steepness exist. For example, the scalar confidence measures of (Anan- dan 1984), which are based on normalized directio%al second derivatives of the surface, provide a measure of peakness based on curvature. We desire an estimated confidence, Cs, that a par- ticular image location corresponds to a discontinuity given the shape of the SSD surface at that location. Such a confidence measure should take into account the number of peaks present in the surface and some notion of how good these peaks are. We also take into account that, for some distance on either side of a dis- continuity, the SSD surface may contain evidence of multiple motion. Our confidence measure should be highest at the actual boundary. Figure 3: Confidence, Cs, based on shape of the SSD surface. Experimental results with many confidence mea- sures and heuristics indicate that simple measures, like the ratio of the depths of the two best peaks, per- form nearly as well as more complex measures. If the first and second best peaks, as defined by $J, have displacements (ue, vc) and (ui , vi) respectively, and PO = S(UO, VO) and PI = S(ui, vi) are the depths of the peaks, then we define Cs as: cs = POIPl. This function will have a global maximum approach- ing 1.0 at the actual boundary and will fall off as dis- tance from the boundary increases. Figure 3 shows the values of CS obtained from the SSD surface gener- ated between the images described in figure 1. Bright values correspond to locations where there is a high confidence of a discontinuity. An empirical study of the behavior of the SSD sur- face indicates that in areas of sufficient texture the surface contains enough information for discontinuity detection. However, if one or both of the surfaces present are homogeneous, the aperture problem pre- vents us from deriving meaningful information from the surface. Weakening the Continuity Assumption The SSD surface provides only approximate informa- tion about the displacement of multiple surfaces. It embodies the assumption that the intensity structure of a surface patch remains constant over time. This assumption generally holds for surfaces which are con- tinuous but is violated at surface discontinuities. When using the quadratic SSD measure, the pres- ence of a poorly correlated surface introduces noise which influences the overall correlation. As the data er- ror increases without bound so does the SSD measure. Instead, we desire a function which weights highly dif- ferences which fall within the expected range of er- ror and remains uncommitted about data outside this range. 1062 VISION Figure 4: The 4 function embodying the weak conti- nuity constraint. Figure 5: Confidence, Cs, using the weak continuity assumption. This weakening of the SSD assumption corresponds to Blake and Zisserman’s weak continuity constraint (Blake & Zisserman 1987). The following function, 4, has the desired properties: 40 { 2 = X2x2 if 1x1 < G/X, C-Y otherwise where X and cy are constants chosen with respect to the expected noise. The resulting data error term is a quadratic function of t’he difference in intensity values as long as the magnitude of the difference is below a threshold fi/X, and stabilizes to a fixed value cy beyond the threshold (see figure 4). This function weights well correlated points highly and diminishes the importance of poorly correlated points. If there are multiple surfaces in relative mo- tion, there will be multiple displacements where a high number of points correlated well, and hence the corre- lation surface will contain multiple peaks. The data error is now: E(u, v) = ): 4(h(i, j) - I2(i + u, j + v)). i,jEG The error surface is generated as before and peaks are detected. Using the same confidence measure, C’s, as before we see that the area of possible discontinuity is more precisely located (figure 5). Change in Surface Shape As indicated in the previous section, the SSD surface may not have multiple peaks even when there are mul- tiple surfaces in relative motion. In certain cases repet- itive structures can cause multiple peaks in the SSD surface when only a single motion is present. Hence, we need a different approach to detect the absence of discontinuities. The key observation is that if an area is undergoing a uniform motion then the cross- correlation surface, S, between successive frames will have the same shape same as the auto-correlation sur- face, A, generated by correlating the the first image with itself (Anandan 1984). Figure 6: Confidence, CS,A, based on the change be- tween the auto and cross correlation surfaces. to Intuitively, if the cross-correlation surface is similar the auto-correlation surface, given an appropriate translation, then the likelihood iof a discontinuity is low. We define a confidence measure, CS,A, based on this intuition. We translate the auto-correlation sur- face so that it is centered at the point of best match, (u, v), and compute the difference between the auto and cross-correlation surfaces: na n CS,A = x >: (s(u, v) - A(u, v))~. u=-rn v=-n This measure will be large at discontinuities and small in areas of consistent motion. Multiple peaks in the cross-correlation surface which are the result of repet- itive structure will also appear in the auto-correlation surface and hence CS,A will be low. This measure is illustrated in figure 6 where CS,A is displayed for the sample random dot pair. Neighborhood Flow By taking the displacement of minimum error in the SSD surface, we arrive at a raw, unsmoothed, flow field, F. Each point in the field contains the best displace- ment of that point. Looking in a neighborhood around BLACKANDANANDAN 1063 Neighborhood Flow a b c Figure 7: Detecting discontinuities using neighborhood flow. a) Confidence, CF, on neighborhood of raw flow vectors. b) Confidence, Cfiaas, in raw flow vectors flow confidence. c) Confidence, ‘CF,~,,,,, , combined neighborhood flow and a given point in F, if there are multiple surfaces mov- ing relative to each other, then there will be clusters of points with different flow vectors. A histogram of displacement vectors in a neighborhood will contain multiple peaks if a discontinuity is present (Spoerri & Ullman 1987). Peaks are detected in the histogram and a confidence measure, CF, can be created by com- paring the relative heights of the two highest peaks. At a boundary this measure has a global maximum approaching 1 .O. Since the traditional smoothness process blurs the distinction between neighboring flow vectors, the neighborhood flow constraint must be applied prior to smoothing. However, the unsmoothed flow field is usually noisy and error-prone, hence, the resulting his- togram will itself be unreliable. This is illustrated by the example shown in Figure 7a, which is computed from the random dot test pair. The measure is max- imum near the actual boundary but, due to noise in the unsmoothed flow field, it produces only a rough approximation to the boundary. The solution our dilemma is contained in the use of confidence measures such as those described in (Anan- dan 1989). These provide a measure of confidence in a flow estimate based on the curvature of the SSD sur- face. Figure 7b shows the confidence in the optic flow estimates for the sample image pair. Areas where con- fidence in the flow estimate is low appear dark in the figure. During the computation of the histogram, we simply weight the contribution of each vector accord- ing to its associated confidence and find peaks in the histogram as before. Flow vectors near the disconti- nuity that are unreliable will contribute less than in the unweighted scheme. This approach cannot find a discontinuity if the information is not present in the flow field. Its usefulness is in reducing the confidence of spurious discontinuities which are the result of flow errors. The resulting confidence, CF,~,,,, for the test images is shown in figure 7c.; confidence in the erro- neously located discontinuity at the occluding corner has been reduced. Note that our simple scheme for detecting multi- ple peaks may fail due to the discretization of the histogram. For instance, two adjacent peaks in the histogram may simply be a broad single peak. More sophisticated clustering techniques may be needed to deal with such problems, and will be considered in the future. Spatial Consistency Until now we have only discussed the assignment of a confidence to a point in the optic array which has some likelihood of corresponding to a discontinuity in the environment. Since discontinuities result from objects and their boundaries, and hence have spatial extent, our goal is not to detect points, but to detect lines of discontinuity which provide the best interpretation of the evidence supplied by the other constraints. The approach taken here is to construct a confidence field based on the previous constraints and use controlled continuity splines, or snakes, (Kass, Witkin, & Ter- zopoulos 1987) to detect local minima in the field. We view the task of detecting lines of discontinu- ity as an energy minimization task where the internal spline forces E int impose a smoothness constraint and the pointwise discontinuity confidence imposes exter- nal forces Edise on the shape of the curve: Es, = J o1 &-at(s) + &iisc(S)dS. Local minima of the energy function correspond to possible lines of discontinuity and temporal, or higher level, processes may then be able to choose the global minima corresponding to actual discontinuities. Our spatial consistency assumption gives us a model of discontinuities as continuous curves in the environ- ment. The shape of these curves can be described by an internal spline energy function: E bat = (4s>Iv&>12 + P(41~ss(s)~2)/2 1064 VISION Figure 8: Discontinuity confidence and spatial consistency. Line of discontinuity detected using spa- tial consistency constraint superimposed on the confi- dence field, generated using Cs, CS,A, CF,~,,, where v(s) = (Z(S), y(s)) represents the position of the snake parametrically, v, and v,, are the first and sec- ond derivatives of the spline, and o(s) and ,0(s) control to what extent the snake acts like a membrane and a thin plate respectively. We can combine the pointwise information about discontinuity to form a confidence field 4 where wells in the field correspond to areas where there is high confidence that a discontinuity is present: q = l/(wlcS + W2CS,A + w3cF,C,,,), where the wi are scalar weights. Other formulations of the field are possible. The external energy force on the discontinuity spline is then just where Edisc = wdisc$!. Figure 8 shows the confidence field for the random dot sequence with noise. A closed snake was initial- ized manually with an initial starting position roughly near the discontinuity. The figure shows one local min- imum found by the snake as bright against the darker confidence field. The deep well about the discontinu- ity means initial placement of the snake can be fairly inaccurate. In our current work we are exploring ways of automating this instantiation process. Temporal Consistency Lines of discontinuity correspond to boundaries of sur- faces in the environment. Under the reasonable as- sumption that surfaces tend to persist in time, we can expect that the discontinuities will also persist. This temporal consistency of discontinuities provides a pow- erful constraint which can be used to disambiguate be- tween possible lines of discontinuity. Temporal consistency implies that lines of disconti- nuity will move steadily across the optic array. This can be formulated as a constraint on the location and the motion of the snakes. In particular, the snake- velocity c(s) should be consistent with the flow field of the frontal surface which gives rise to the discontinuity. Similarly, we may require that the snake acceleration G(s) be small. The experiments reported in this paper have been based on two frames, and hence do not exploit tempo- ral consistency. It appears, however, that the inclusion of this constraint for multiple-frame analysis will pro- vide significant improvements. Experimental Results The constraints and associated confidence measures provide accurate discontinuity detection in random dot images, even in the presence of noise. These images, however, contain more texture than is common in im- ages of natural scenes. A sequence of 64 x 64 pixel images of a cluttered office scene was used to test the constraints on real data. The densely sampled se- quence contains two relatively homogeneous bars in the foreground moving across a stationary background containing areas of varying amounts of texture. The closest bar is undergoing approximately a 2 pixel dis- placement while the more distant bar is displaced by approximately 1 pixel. Noise, multiple discontinuities, and nearly homogeneous surfaces make this a challeng- ing sequence for discontinuity detection. The images were first band-pass filtered. The SSD computation for the auto and cross correlation surfaces used a 7 x 7 search area and a 7 x 7 neighborhood with a uniform distribution. A 7 x 7 neighborhood was used for computing neighborhood flow. Figure 9a shows a thresholded image of the potential field generated us- ing C’s, CS,A , and CF,~,,, . Dark areas correspond to locations where there is high confidence that a discon- tinuity exists. Snakes were initialized manually (figure 9b) in the general area of the discontinuity. This initialization process could be automated by using curves gener- ated from intensity-based edge detection and percep- tual grouping. Figure 9c shows the snakes resting at local minima in the field. Conclusion This paper has presented physical constraints which can be exploited to perform early detection of motion discontinuities over time. We have also presented a way of combining the various constraints in the form of an optimization problem, along the lines of the ac- tive contour models developed by (Kass, Witkin, & Terzopoulos 1987). Our approach is suitable for early stages in the processing of visual motion, and produces useful results even using our current formulation of the constraints, which is admittedly somewhat simple. We are currently working on a Bayesian interpreta- tion for our constraints. A conditional probability for a discontinuity can be obtained from each constraint and these can then be combined. The Bayesian model of the uncertainty developed in (Szeliski 1988) for flow- field computation provides hope that such a rigorous treatment is possible. BLACKANDANANDAN 1065 a Figure 9: Experiments. a) Threshold c c)-final positions. b If potential field using Cs, CS,A and %Gna, - b) initial snake positions. There is also work to be done extending the con- straints themselves; in particular, temporal constraints need to be incorporated. The possibility that discon- tinuities may appear, merge, split, grow, and shrink presents a number. of interesting challenges in the use of snakes. The shape of the SSD surface and the use of weak continuity constraints deserve additional study, as do the possibilities for additional constraints. For example, it may be possible to combine dynamic dis- continuity analysis with static image analysis. There are also possibilities for feeding these disconti- nuities back into the correlation process. By explicitly accounting for discontinuities when computing the cor- relation it may be possible to achieve better estimates of flow. This idea relates to work in Markov Random Fields in which line processes are introduced to account for discontinuities (Geman & Geman 1984). Finally, the value of this work will be demonstrated when it is applied to the problems of motion under- standing. In particular, the incorporation of discon- tinuities into the smoothness constraint in flow field computation needs to be examined. The test will be whether early discontinuity detection can indeed be used to produce more accurate dense flow fields. References [l] P. Anandan. Computing dense displacement fields with confidence measures in scenes containing oc- clusion. In SPIE Int. Conf. Robots and Computer Vision, 521, pages 184-194, 1984. [2] P. Anandan. Measuring Visual Motion from Im- age Sequences. PhD thesis, University of Mas- sachusetts, Amherst, 1987. COINS TR 87-21. [3] P. Anandan. A computational framework and an algorithm for the measurement of visual motion. Int. Journal of Computer Vision, 2:283-310,1989. [4] A. Blake and A. Zisserman. Visual Reconstruc- tion. The MIT Press, Cambridge, Massachusetts, 1987. 151 PI VI PI PI PO1 WI Cl21 WI M P. J. Burt, C. Yen, and X. Xu. Local correlation measures for motion analysis a comparative study. Technical Report IPL-TR-024, Image Processing Lab., Rensselaer Polytechnic Institute, 1982. S. Geman and D. Geman. Stochastic relaxation, gibbs distributions, and bayesian restoration of images. IEEE Transactions on Pattern Analysis and Machine Intelligence, PAMI-6(6), November 1984. M. Kass, A. Witkin, and D. Terzopoulos. Snakes: Active contour models. In Proc. 1st ICCV, pages 259-268, June 1987. London, UK. D. Marr. Vision. W. H. Freeman and Company, New York, 1982. M. Mutch, K. and B. Thompson, W. Analysis of accretion and deletion at boundaries in dynamic scenes. In W. Richards, editor, Natural Computa- tion, pages 44-54. MIT Press, Cambridge, Mass., 1988. L. Potter, J. Scene segmentation using motion information. IEEE Trans. on Systems, Man, and Cybernetics, 5:390-394, 1980. B. 6. Schunk. Image flow segmentation and esti- mation by constraint line clustering. IEEE PAMI, 11(10):1010-1027, Oct. 1989. A. Spoerri and S. Ullman. The early detection of motion boundaries. In Proc. 1st ICCV, pages 209-218. London, UK, June 1987. R. S. Szeliski. Bayesian Modeling of Uncertainty in Low-Level Vision. PhD thesis, Carnegie Mellon University, 1988. W. B. Thompson, K. M. Mutch, and V. Berzins. Edge detection in optical flow fields. In Proc. of the Second National Conference on Artificial In- telligence, August 1982. 1066 VISION
|
1990
|
45
|
962
|
c uting Exact A ets: Par Jean Ponce Beckman Institute University of Illinois Urbana, IL 61801 Abstract This paper introduces a new approach for com- puting the exact aspect graph of curved objects observed under orthographic projection. Curves corresponding to various visual events partition the Gaussian sphere into regions where the image structure is stable. A catalogue of these events for piecewise-smooth objects is available from sin- gularity theory. For a solid bounded by rational parametric patches and their intersection curves, it is shown that each visual event is characterized by a system of n polynomials in n + 1 variables whose solutions can be found by numerical curve tracing methods. Combining these methods with ray tracing, it is possible to characterize the stable image structure within each region. Results from a preliminary implementation are presented. Introduction Recognizing a polyhedron from its monocular im- age using an object-centered representation is a non- trivial, but feasible task [14, 211, because most observ- able image features are the projections of object fea- tures: The image contours are the projections of edges, while their junctions are the projections of vertices, plus the occasional t-junctions that occur when a face partially occludes an edge. In contrast, most features observable in the image of a curved object are viewpoint-dependent and can- not be traced back to particular object features: The image contours of a smooth object are the projections of limb points, i.e., regular surface points where the viewing direction is tangent to the surface; they join at t-junctions, and may also terminate at cusp points having the additional property that the viewing direc- tion is an asymptotic direction of the tangent plane WI l *Part of this research was conducted while the authors were with the Robotics Laboratory of Stanford University, where support was provided in part by the Air Force Of- fice of Scientific Research under contract F33615-85-C-5106 and by the Advanced Research Projects Agency of the De- partment of Defense under Knowledge Based Vision ADS subcontract S1093 S-l. 1074 VISION David J. Kriegman Center for Systems Science Yale University New Haven, CT 06520-1968 These simple remarks suggest investigating viewer- centered representations for recognizing curved objects from their monocular image contours. This paper is a first step in this direction, and it addresses the problem of constructing the aspect graph representation [19] of complex curved objects. Combining this qualitative, viewer-centered representation with more quantitative, object-centered representations [25] to obtain efficient control structures of the recognition process is the long- term goal of our research, and we will return to these issues in the conclusion. Informally, the aspect graph of an object enumer- ates all possible configurations of its image features as a function of viewpoint. Formally, it is known from singularity theory [l, 171 that image structure is in general stable with respect to viewpoint: perturbing the camera position in a small ball around the orig- inal viewpoint will not change the contour topology. However, from some viewpoints, almost any infinites- imal change will alter this topology. It follows that the range of all possible viewpoints can be partitioned into maximal regions where the structure of the con- tours, or aspect, is stable. The change in the aspect at the boundary between the regions is named a vi- sual event. The maximal regions and their boundaries can be organized into an aspect graph, whose nodes represent the regions with their associated aspects and whose arcs correspond to the visual event boundaries between adjacent regions. Since their introduction by Koenderink and Van Doorn [19] more than ten years ago, aspect graphs have been the object of very active research. We be- lieve that viewer-centered representations like aspect graphs are crucial for curved objects, but, ironically, most of the past research in this field has focussed on polyhedra, maybe because the contour generators of these objects, being viewpoint-independent, are rela- tively simple. Indeed, approximate aspect graphs of polyhedra have been successfully used in recognition tasks [lo, 13, 151, while several algorithms have re- cently been proposed for computing the exact aspect graph of these objects (see, for example, [9, 23, 31, 331). That the necessary theoretical tools for building ex- act aspect graphs of curved objects were firmly estab- lished results from singularity and catastrophe theories [l, 171 was already recognized by Koenderink and Van From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Doorn [19], and has, since then, been reaffirmed by others [4,27]. However, algorithms implementing these tools have, until very recently, remained elusive. This paper is the second in a series on the construction of exact aspect graphs of piecewise-smooth objects, based on the catalogue of possible visual events established by Rieger [27]. P reviously, we had considered solids of revolution whose generating curve is algebraic [20] (see also [6] for a different approach to the same problem). Here, we present an algorithm for computing the as- pect graph of solids bounded by rational parametric patches and their intersection curves, observed under orthographic projection. To the best of our knowledge, this is the first algorithm ever proposed for computing the exact aspect graph of a piecewise-smooth, curved object which is not a solid of revolution. Mathematicals details, omitted here for the sake of conciseness, can be found in [26]. a. b. C. . Figure 1: Local singularities of the visual map: (a) swallowtail; (b) beak-to-beak; (c) lip. Approach A rational parametric patch has ratios as coordinates, i.e., it is defined by: of polynomials x(u, v) = 1 . . c dij ui vj c U’dX$j, (u, v) E I x J, ki i,j (1) where the dij’s are scalar coefficients, the -j’s are vec- tors of coefficients, and I, J are intervals of !I& This representation includes nearly all geometric models used in computer aided geometric design and com- puter vision, such as polyhedra, CSG models, bicubic patches, generalized cylinders, and superquadrics [25]. In addition, Sederberg and his colleagues [ll, 281 have shown that elimination theory can be used to compute the polynomial implicit equation of a rational patch and construct an exact representation for the intersec- tion curve of two patches in the form of a polynomial implicit equation I(u, v) = 0 in the parameter space of one of the patches. So, the edges of a solid bounded by rational paramet- ric patches and their intersection curves can be charac- terized by a polynomial equation. As remarked earlier, the limbs are characterized by the fact that the viewing direction v is tangent to the surface, i.e., n(u, v).v = 0, where n is the surface normal. Once again, this can be rewritten as a polynomial equation in u and v, and it follows that all image contours can be characterized by implicit polynomial equations. More generally, it will be shown in the next sections that visual events can be represented by systems of polynomial equations, and this will allow us to use global numerical techniques such as continuation [22] g characterize these events. The proposed procedure for constructing an aspect graph is: o Characterize the curves on the unit sphere which correspond to the visual events of the transparent ob- ject. o Build a graph of the regions delineated by these curves and characterize within each region the corre- sponding aspect of the transparent object. e Remove hidden curve branches of the opaque ob- ject from the aspects and merge adjacent regions with identical opaque aspects. As will be shown in a moment, each step of this algorithm corresponds de facto to characterizing the topology of curves defined in high dimension spaces by systems of polynomial equations. This is the key to the success of our algorithm, because it gives us access to the arsenal of computational tools available for characterizing algebraic curves. In principle, this can be done by using symbolic methods such as cylin- drical algebraic decomposition [5]. However, it is well known that these algorithms suffer from “intermedi- ate expression swell,” i.e., the time and space required for the computation of intermediate expressions may become so large as to make the desired-computations impossible [2].-Instead, we propose using the numerical method of continuation [22] and combining it with a new numerical curve tracing algorithm and ray tracing techniques [16, 351. A catalogue of visual events From singularity and catastrophe theories [l], it is known that, from most viewpoints, image contours are piecewise-smooth curves whose only singularities are cusps and t-junctions. They are stable with respect to the viewing direction: perturbing the camera position in a small ball around the original viewpoint will not change their topology. From some viewpoints, how- ever, almost any perturbation of the viewing direction will alter the contour topology. A catalogue of these “visual events” , or “singulari- ties”, has been established by Kergosien [17] for trans- parent generic smooth surfaces observed under ortho- graphic projection. It has been extended by Rieger to piecewise-smooth [27] surfaces, so it applies to both edge and limb projections. As shown in [l], each visual event in this catalogue occurs when the viewing direc- tion has a high order contact with the observed surface along certain characteristic curves.l When contact oc- curs at a single point on the surface, the singularity is ‘Recently, Rieger’s catalogue has been extended to PONCE AND KRIEGMAN 1075 a* x x x 3 Figure 2: Multilocal singularities of the visual map: triple point ; (b) tangent crossing; (c) cusp crossing. (4 said to be local; when it occurs at different points, it is said to be multilocal. In the next two sections, we study the characteris- tic curves associated with local and-multilocal events in more detail. For rational parametric patches, it is shown that both types of events are characterized by systems of n polyno-nial equations in n + 1 unknowns. Local singularities Let us first consider edge projections. Their local vi- sual events are cusps [27, 321, where the viewing direc- tion is tangent to the edge. In this case, the character- istic curve is the edge itself, and the viewing direction corresponding to each edge point is its tangent [26]. From catastrophe theory, it is known that occluding contours may exhibit three types of local singularities: swallowtails, beak-to-beak, and lip transitions [17], as shown in figures 1,5,6,7. During a swallowtail transi- tion, a smooth image contour forms a singularity and then breaks off into two cusps and a t-junction. In a beak-to-beak transition, two distinct portions of the occluding contour meet at a point in the image; after meeting, the contour splits and forms two cusps; the interconnectivity of the limbs changes. Finally, a lip transition occurs when, out of nowhere, a closed curve is formed with the introduction of two cusps. As shown by Am .ol’d [l], swallowtails occur on flec- nodal curves, while both beak-to-beak and lip transi- tions occur on parabolic curves; in all cases,-the cor- responding viewing directions are given by asymptotic directions along these curves. Flecnodal points are in- flections of asymptotic curves, while parabolic points are zeros of the Gaussian curvature [34]. Implicit equa- tions for both types of curves are given in [26]; the cor- responding viewing directions are computed by solving the asymptotic direction equation [34]. some non-generic surfaces, namely developable surfaces, by Sripradisvarakul and Jain [30]. Further research is needed to ascertain if new characteristic curves are necessary to characterize the additional visual events of these surfaces. Multilocal singularities We have just seen that local singularities can be char- acterized by one equation in two unknowns which is the implicit equation of a surface curve. Let us now turn to multilocal singularities, which occur when two or more surface points project onto the same contour point. As shown by Kergosien [17] and Rieger [27], there are three types of multilocal visual events (figure 2). Three contour segments can intersect at a triple point. For an opaque object, only two branches are seen on one side of the transition while three branches are visible on the other side. Secondly, a tangent crossing occurs when two contours meet at a point and share a com- mon tangent. Finally, a cusp crossing occurs when the projection of an occluding contour cusp meets another contour. Multilocal events are not characterized by a single surface curve, but instead by curves in high dimension spaces, or equivalently by families of surface curves. For example, a triple point is formed when three sur- face points are aligned and, in addition, the surface normals at the three points are all orthogonal to the common line supporting these points. By sweeping this line while maintaining three-point contact, a family of three curves is drawn on the surface. The equations for the multilocal singularities are de- rived in [26]. The most complex singularity is the triple point, defined by five equations in six unknowns. Tan- gent crossings and cusp crossings are each character- ized by three equations in four unknowns. The viewing direction corresponding to a multilocal event is given by x2 - x1, where x1 and x2 are two of the points forming the singularity. Tracing the visual events We saw in the previous section that any visual event of a solid bounded by smooth surface patches and their intersection curves is a curve I’ defined in !P1 by a system of n equations in n + 1 variables: qzo, Zl, “‘, Zn) = 0 . . . (2) pn( x0, a, l -*1 xn) =o As shown in [26], these equations are polynomials in the partial derivatives of the considered patches. By clearing if necessary the appropriate denominators, it is obvious in the case of rational parametric patches that each of the Pi’s is a polynomial in the patches’ parametric coordinates. The curve I’ can therefore be defined implicitly by a system of algebraic equations. To characterize its topology, it is possible, in principle, to use the sym- bolic method of cylindrical algebraic decomposition [5]. This may, however, prove impossible in practice [2]. Alternatively, the curve can be traced numerically, us- ing a prediction-correction scheme [7]. The main diffi- culties are finding a sample point on each real compo- nent of the curve to initiate the marching and dealing with the curve singularities where the tangent is not defined [3]. We propose a new algorithm to overcome these diffi- culties. It is divided into four steps: (1) first compute 1076 VISION Figure 3: The parabolic and flecnodal curves on the surface of an SHGC. all extremal points in some direction, sav 00; this in- cludes all singular points; (2) compute all-intersections of the curve with the hyperplanes orthogonal to the zo axis at the extremal points; (3) for each interval of the ~0 axis delimited by these hyperplanes, intersect the curve and the hyperplane passing through the mid- point of the interval; (4) march numerically from these intersections to the adjacent hyperplanes. As shown in [26], steps (1) to (3) involve solving sys- tems of polynomial equations. This is done by using the global numerical method of continuation [22] for solving systems of n polynomial equations in n vari- ables. Continuation is itself a form of curve tracing, and it can find all solutions (counting their multiplic- ities) of systems having up to a few thousand roots [aal. ’ Step (4) is similar to the marching step in [3, 71, and it only involves the inversion of a linear system: Since the mid-point of each interval corresponds to branches of the curve where the tangent’s component along the ~0 axis is never zero, a Tailor expansion of the curve in the ~0 direction can be used to guide the march- ing. This step ends when the bounds of the interval are reached. At this time, the current branch is con- nected to the extremal points found earlier, producing a graph representation of the curve in terms of smooth branihes joined at singularities (an s-graph in Arnon’s terminology [2]). Note that, for each interval, a sample noint is ob- tained for each branch of the curve within this interval. In addition, marching through singularities is trivially avoided by marching only within intervals where the curve is extrema-free and therefore not singular. The algorithm is detailed in [26]. The remaining steps of the algorithm We have shown how to trace the curves which corre- spond to the visual events on the object’s surface. At each point, it is possible to compute the correspond- ing viewing direction and therefore to trace the corre- sponding visual event on the viewing sphere. We now sketch the remaining steps of the aspect graph con- struction: building a-graph of stable view regions, con- structing the correspondin .g transparent aspects, and merging adjacent identical opaque aspects. Figure 4: The curves on the unit sphere that correspond to the local events of an SHGC. Three sample directions (marked ‘S’, ‘B’, and ‘L’) are used to characterize the local events in the next three figures. To compute the graph of regions, we need to find all intersections of the visual event curves on the unit sphere. This can be done, once again, by solving a set of polynomial equations. Then, the intersections and - - extremal points can be sorted, as before, along some direction-and sample points for each smooth branch can be constructed: A sample point for the region de- limited bv two consecutive branches on one interval is simply obtained as the mid-point of the branches’ sam- ple points. The output of this step is a set of regions, curves, and intersection points, plus their connectivity information. In addition, the sample point associated with each region is a representative viewing direction for this re- nion. The contours associated with this view can once again be computed by curve tracing since they are the projections of edges, defined by I(u, V) = 0, and limbs, defined bv n*v = 0. It follows that each aspect can be represented by an s-graph of smooth curve branches separated by the contour singularities, i.e., cusps and t-junctions. It is known that, for a stable view, the visibility of contours only changes at cusps and t-junctions follows that the visibility . of contours does not [Is]. It change along a given branch ofthe s-graph, and it can be d<- termined by ray tracing [35] at the sample point of each branch. As shown in [16], ray tracing rational paramet- ric patches amounts to solving a system of polynomi- &,-which can be done by using continuation.- Once the visibility of the contour branches has been deter- mined, it is-a simple matter to eliminate the invisible branches and merge identical adjacent aspects. Implementation and results The curve tracing algorithm has been implemented and used, among other things, to compute the intersection curves and the silhouette of algebraic surfaces. As a first step in the implementation of the aspect graph algorithm, local visual events of a straight homoge- neous generalized cylinder (SHGC, see [24, 291) have been computed. SHGC’s are obtained by scaling a (not necessarily circular) reference cross-section along PONCEANDKRIEGMAN 1077 a straight axis. They are a convenient choice for exper- imentation since they can be represented by rational parametric patches [25], and proven methods are avail- able for computing and drawing their contours [24]. In the examples presented in this section, we have used an SHGC whose scaling function is a cubic curve and whose reference cross-section is a complex non-convex curve. Figure 3 shows a line-drawing of this object and the corresponding parabolic lines and flecnodal curves. This line-drawing has been computed by the methods described in [24]. The flecnodal and parabolic curves have been computed by the curve tracing algorithm described earlier. Figure 4 shows the corresponding curves on the unit sphere. Note that some of these curves are not closed, and therefore do not delimit re- gions on the unit sphere. This should be expected since the SHGC’s surface has a finite extent and the multilocal events have not been traced. Finally, figures 5,6, and 7 show examples of swallow- tail, beak-to-beak, and lip transitions in the neighbor- hood of sample directions lying on visual event curves of the unit sphere. These directions and the adjacent stable views are shown as arrows and dots, and marked ‘S’, ‘B’, and ‘L’ in figure 4. In order to show the con- tour structure (e.g., cusps and t-junctions), the hidden lines have not been removed in these three figures. Discussion and future research We have presented a new algorithm for computing the exact aspect graph of curved objects and demonstrated a preliminary implementation. This algorithm is quite general since, as noted before, rational patches and their intersection curves subsume most representations used in computer aided geometric design and computer vision. Unlike possible alternative approaches based on cylindrical algebraic decomposition [2, 51, our al- gorithm is also practical, combining well-established numerical techniques such as continuation [22] and ray tracing [16, 351 with a new curve tracing technique which respects curve singularities. Our immediate goal is to complete the implementa- tion of the aspect graph algorithm. As noted in the introduction, future research will be dedicated to ac- tually using the aspect graph representation in recog- nition tasks. In [25], we have demonstrated the re- covery of the position and orientation of curved three- dimensional objects from monocular contours by us- ing a purely quantitative process that fits an object- centered representation to image contours. What is missing is a control structure for guiding this process. We believe that the qualitative, viewer-centered aspect graph representation can be used to guide the search for matching image and model features and yield effi- cient control structures analogous to the interpretation trees used in the polyhedral world [8, 12, 141. Acknowledgements: We thank Kevin Bowyer, John F. Canny, Martial HCbert, Seth Hutchinson, and Brigitte Ponce for useful discussions and comments. b. Figure 5: A swallowtail transition: A smooth contour (a) acquires a discontinuity (b) which splits into one t- junction and two cusps (c). This local event corresponds to the viewing direction marked ‘S’ in figure 4. Figure 6: A beak-to-beak transition: Two disjoint pieces of contour (a) join at the transition (b), then split again in the other direction (c). This local event corresponds to the viewing direction marked ‘B’ in figure 4. Figure 7: A lip transition: A contour appears out of nowhere. This local event corresponds to the viewing di- rection marked ‘L’ in figure 4. 1078 VISION References [l] V.I. Arnol’d. Singul an les of systems of rays. Russian ‘t’ Math. Surveys, 38(2):87-176, 1983. [2] D.S. Arnon. Topologically reliable display of algebraic curves. Computer Graphics, 17(3):219-227, July 1983. [3] C.L. Bajaj, C.M. HofIinann, R.E. Lynch, and J.E.H. Hopcroft. Tracing surface intersections. Computer Aided Geometric Design, 5:285-307, 1988. [4] J. Callahan and R. Weiss. A model for describing surface shape. In Proc. IEEE Conf. on Comp. Vision and Putt. Recog., pages 240-245, 1985. [5] G.E. Collins. Quantifier Elimination for Real Closed Fields by Cylindrical Algebraic Decomposition, vol- ume 33 of Lecture Notes in Computer Science. Springer-Verlag, New York, 1975. [6] D. Eggert and K. Bowyer. Computing the ortho- graphic projection aspect graph of solids of revolution. In IEEE workshop on interpretation of SD scenes, pages 102-108, Austin, TX, November 1989. [7] R.T. Farouki. Trimmed-surface algorithms for eval- uation and interrogation of solid boundary repre- sentations. IBM Journal of Research Development, 31(3):314-332, may 1987. [8] O.D. Faugeras and M. Hibert. The representation, recognition, and locating of 3-D objects. International Journal of Robotics Research, 5(3):27-52, Fall 1986. [9] Z. Gigus and J. Malik. Computing the aspect graph for line drawings of polyhedral objects. IEEE Trans. Pattern Anal. Machine Intell., 12(2):113-122, Febru- ary 1990. [lo] C. Goad. Sp ecial purpose automatic programming for 3D model-based vision. In Proc. Image Understanding Workshop, pages 94-104, June 1983. [ll] R.N. Goldman and T.W. Sederberg. Some applica- tions of resultants to problems in computational ge- ometry. The Visual Computer, l:lOl-107, 1985. [12] W.E.L. Grimson and T. Lozano-PCrez. Localizing overlapping parts by searching the interpretation tree. IEEE Trans. Pattern Anal. Mtachine Intell., 9(4):469- 482, 1987. [13] M. HCbert and T. Kanade. The 3D profile method for object recognition. In Proc. IEEE Conf. on Comp. Vi- sion and Putt. Recog., San Francisco, CA., June 1985. [14] D.P. Huttenlocher and S. Ullman. Object recogni- tion using alignment. In International Conference on Computer Vision, pages 102-111, London, U.K., June 1987. [15] K. Ikeuchi and T. K anade. Automatic generation of object recognition programs. Proceddings of the IEEE, 76(8):1016-35, August 1988. [IS] J.T. Kajiya. Ray tracing parametric patches. In Proc. of SIGGRAPH 82, pages 245-254, July 1982. [17] Y.L. Kergosien. La famille des projections orthogo- nales d’une surface et ses singularit&. C.R. Acad. SC. Paris, 292:929-932, 1981. [18] J.J. Koenderink. What does the occluding contour tell us about solid shape ? Perception, 13, 1984. [19] J.J. Koenderinlc and A.J. Van Doom. The internal representation of solid shape with respect to vision. Biological Cybernetics, 32:211-216, 1979. [20] D.J. Kriegman and J. Ponce. Computing exact aspect graphs of curved objects: solids of revolution. I[n IEEE workshop on interpretation of 3D scenes, pages 116- 122, Austin, TX, November 1989. [21] D. Lowe. The viewpoint consistency constraint. In- ternational Journal of Computer Vision, 1(1):57-72, 1987. [22] A.P. Morgan. Solving Polynomial Systems using Con- tinuation for Engineering and Scientific Problems. Prentice Hall, Englewood Cliflk, 1987. [23] H. PI an m t’ g a and C. Dyer. Visibility, occlusion, and the aspect graph. CS Tech. Report 736, University of Wisconsin, 1987. [24] J. Ponce and D. Chelberg. Finding the limbs and cusps of generalized cylinders. International Journal of Computer Vision, l(3), October 1987. [25] J. Ponce and D.J. Kriegman. On recognizing and po- sitioning curved 3D objects from image contours. In IEEE Workshop on the Interpretation of 3D scenes, pages 61-67, Austin, TX, November 1989. [26] J. Ponce and D.J. Kriegman. Computing exact aspect graphs of curved objects: parametric patches. Techni- cal Report UIUCDCS-R-90-1579, University of Illinois at Urbana-Champaign, March 1990. [27] J.H. Rieger. On the classification of views of piecewise smooth objects. Image and Vision Computing, 1:91- 97, 1987. [28] T.W. Sederberg, D.C Anderson, and R.N. Goldman. Implicit representation of parametric curves and sur- faces. Comp. Vision, Graphics, and Image Proc., 28~72-84, 1984. [29] S.A. Shafer. Shadows and Silhouettes in Computer Vision. Kluwer Academic Publishers, 1985. [30] T. Sripradisvarakul and R. Jain. Generating aspect graphs of curved objects. In IEEE Workshop on In- terpretation of 30 Scenes, pages 109-15, Austin, TX., December 1989. [31] J. Stewman and K.W. Bowyer. Creating the perspec- tive projection aspect graph of polyhedral objects. In International Conference on Computer Vision, 1988. [32] C.T.C. Wall. G eometric properties of generic differ- entiable manifolds. In A. Dold and B. Eckmann, ed- itors, Geometry and Topology, pages 707-774, Rio de Janeiro, 1976. Springer-Verlag. [33] N. Watts. Calculating the principal views of a poly- hedron. Technical Report CS Tech. Report 234, Rochester University, 1987. [34] C.E. W ea er urn. th b Diflerential geometry. Cambridge University Press, 1927. [35] T. Whitted. An improved illumination model for shaded display. Communications of the ACM, 23(6):343-349, June 1980. PONCE AND KRIEGMAN 1079
|
1990
|
46
|
963
|
Generalized Shape Autocorrelation Andrea Califano and Rakesh Mohan IBM, Thomas J. Watson Center Exploratory Computer Vision Group P.O. Box 704, Yorktown Heights, NY 10598 Abstract This paper presents an efficient and homogeneous paradigm for automatic acquisition and recognition of nonparametric shapes. Acquisition time varies from linear to cubic in the number of object features. Recognition time is linear to cubic in the number of features in the image and grows slowly with the number of stored models. Nonparametric shape repre- sentation is achieved by spatial autocorrelation transforms. Both acquisition and recognition are two-step processes. In the first phase, spatialautocorrelationoperators are applied to the image data to perform local shape analysis. Then, spatial autocorrelation operators are applied to the local shape descriptors to either create entries (acquisition) or index (recognition) into a table containing the distributed shape information. The output of the table is used to generate a density function on the space of possible shapes with peaks corresponding to high confidence in the presence of a par- ticular shape instance. The behavior of the system on a set of complex shapes is shown with respect to occlusion, geometric transformation, and cluttered scenes. Introduction This paper focuses on the issue of a scalable and homogeneous approach to the acquisition and extraction of generalized, nonparametric shapes from images. By scal- able, we mean a technique which is tractable, and possibly computationally efficient, with respect to increasing sizes of images, increasing number of shape models stored and an increasing complexity of the models themselves. General surveys on model-based object recognition can be found in [BJ85, CH86]. Most recognition paradigms, lack a corresponding framework for automatically acquiring ob- ject shapes [BCK89, BHH83, Br83, Go83, HH87, IK88]. The object models used, rather than being acquired from raw data, are either handcrafted, or generated assuming that precise geometric information is available. A few approaches, e.g., geometric hashing [KS86, LW88] have been successfully used for both perceptual tasks, how- ever they do not easily generalize to complex shapes and 3D objects. Often, this is a consequence of using recognition clues which are not invariant with respect to scale, and thus requires analysis at multiple level of resolution [Bu88]. As a consequence, a homogeneous shape storage-recall mechanism which is capable of dealing with increasing levels of complexity, both of the shape and of the scene, is still an open issue. The approach presented here addresses these concerns and offers the basis for a homogeneous, scale invariant, and tractable approach to the problem of acquiring and recogniz- ing shapes from imagery. The generality of the formulation allows to extend this approach to a variety of domains. The method exploits long distance correlation informa- tion in shapes to extend the concept of parameter transforms, used for the extraction of simple parametric features, such as lines or circles [Ho62, DH72], to a much more powerful and general paradigm for the extraction of arbitrary non- parametric features. This is achieved much in the spirit of the original generalized parameter transform [Ba8lb], but without any of the limitations which make that approach impractical. A two stage process is proposed, see Fig 1. First, short range autocorrelation operators are used to map from the image into a small set of simple local shape descriptors. A global autocorrelation operator is devised to map these local descriptors, distributed across the image, into index vectors. These are used as indices into a look-up table which contains the shape model representations. During acquisition, entries are added to the table based on the index vectors generated by the transforms. For recogni- tion, the same vectors are used to index into the table. The table output, in turn, generates a density function in the final shape space, where vectors correspond to specific instances of the stored shape models. Position, orientation and scale, as well as the symbolic label of the identified shape, are extracted simultaneously. After each of the two symbolic parameter transforms, constraint satisfaction techniques [FB81, CBT89, MO901 are used to select the best among incompatible local and global shape hypotheses. Only those with the best match to the input data survive, thus effectively segmenting the image with respect to the extracted feature set. Spatial Autoccwrdatio We introduce spatial autocorrelation operators and describe how they can be successfully used in a generalized parameter transform framework. Some notions are recalled from previous work [Ca88, CBT89]. e Generalized Neighborhood Framework The Generalized Hough Transform, proposed by Ballard in [Ba8lb], has shown how stochastic evidence integration techniques can be applied to the recognition of arbitrary CALIFANOANDMOHAN 1067 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. shapes in 2-space. However, due to the locality of the parameter estimation technique typical of the Hough paradigm, the complexity of the model search space ex- plodes exponentially once arbitrary rotation and scale trans- formation are allowed in the input. For this and other reasons the Generalized Hough Transforms has failed to gain wide acceptance as a standard technique for shape extraction. Recent work [Ca88, CBT89] has shown how it is possible to further generalize the notion of parameter transform to include a mechanism for fusing evidence embedded in dis- tant portions of the image. This is achieved by extending the neighborhood concept to include compact nonconnected data set (Generalized Neighborhoods) and by devising trans- form operators for this new sparse data structure. Parameter transforms based on Generalized Neighborhoods typically achieve one to two orders of magnitude better accuracy in the parameter estimates of simple parametric features [Ca88]. They have been used to reliably extract up to 8- dimensional parametric features, such as conic sections in 3-space from range data [CBT89]. In the usual parameter transform formulation, a local mapping operator, f (P, X, y), is devised to estimate the likelihood of the presence of a specific feature MPp P2, ‘0 l 9 p,>‘, in a small local neighborhood P(x, y) in the image space, centered around the point (x, y) . Here, the para.=ters PI, ~2 9 . . . j ps uniquely identify the feature of interest. Evidence integration is performed by integrating the estimator over the entire image W’) =sf P, ~9 Y> h @ Image The resulting value is a confidence measure on the presence of the corresponding feature in the input. By repeating the operation for each possible feature, a density function over the parameter space of the features is generated. Peaks in the density function indicate high values of confidence with respect to the corresponding feature. Clustering technique are used to isolate the peaks from the background noise. The mapping operator, in the case of Generalized Neigh- borhoods, is structured as a spatial autocorrelation function of the form: where k determines the order of the correlation, function. A({(Xi,yJ]) is a neighborhood for partial evidence integration which can depend on the value of the different (X$yJ. Such Image Data neighborhood, usually, can be the entire image or a portion of the image centered around (x, y). Specific advantages of autocorrelation mapping operators are discussed in [CBT89]. Here we would&e to mention increased accuracy of the transform (up to two orders of magnitude), the ability to use partial forms of the mapping operator to link features to image regions using a prob- abilistic measure, and the increased hyper-volume under the density function in parameter space. This final feature allows for the successful implementation of high dimensional parameter transforms. Non Parametric Feature Extraction Although the term “parameter transform” might seem to indicate otherwise, it is possible to use this technique for nonparametric feature extraction. By nonparametric fea- tures, we simply mean features that can not conveniently be described by a small set of parameters. It is known from basic analysis that any piece-wise invertible 2D-curve can be approximated with arbitrary precision by its Taylor series. So, given the usual finite precision requirement, many cur- ves can be locally approximated with sufficient accuracy in terms of the first few terms of the series. Even closed or disconnected curves can have relatively simple polynomial representation [Ta88]. However, retrieving the curve parameters from an image can be an extremely hard task which almost invariably requires optimal segmentation of the input. Besides, the existence of a parametric representation does not guarantee its stability. In other words, small variations in some of the parameters, given the nonlinearity of Taylor series, can produce arbitrary large variations in the form of the associated 2D-curve and vice-versa. Thus matching the extracted representations to the stored ones becomes almost impossible. In these cases, parametric representations are not viable candidates for either the acquisition or the extraction process. Autocorrelation Shape Transforms We provide a different approach to the issue of shape representation. Initially we restrict the analysis to the context of 2D-curves. Later, we generalize the framework to more complex domains. Let us suppose that given a few nonparametric 2D curves we can uniquelyhidentifs a set of points on each curve and estimate their 0 and 1 order properties. We introduce a discrete spatial autocorrelation operator which will map Look-up tablo Local Shape DescrIptora / I Look-up tablr Shape Spats Fig. 1: System Architecture 1068 VISION input data, we use the generated discrete index to select an entry in a look-up table, and we add the tupie < L , (xT , yT) , p , aT, Count > to it. Here Count is original- ly set to one. Every time a tuple produced for a given index exactly matches one already present in the table on the five initial parameters, Count is incremented by one. The sig- nificance of an entry is proportional to its Count. Fig. 2: Correlation of geometric information these sets into a density function on a feature parameter space. Vectors in such a space uniquely identify position, rotation, and scale of the feature, as well as the feature itself with respect to others. Each possible point in the image, drawn from the pre- viously described sets, can be associated with all possible combinations of two other points, thus forming a set of triangles, see Fig. 2. For each such structure we generate a four dimensional index. This is built using the two ratios s&5’ and s2/s, whereS = s1 +s2+s3, which determine the geometry of the triangle, and the two angles al and a2 which describe -_ lsl order properties of the curve with respect to the given 3-point set. This index is scale and rotation invariant, if the position and properties of the points on the curves can also be deter- mined independently of such transforms. In fact, if other local properties of the points are also invariant, they can be used -ti form longer indices, as we show later. Different quantization criteria are applied to each of the index parameters to form a set of discrete variables with a finite number of values. During the acquisition phase, we consider a single, unoc- eluded 2D shape in the image so that the position ofits center of mass (x0, yO), its scale (e.g., perimeter) k, its orientation vector d, and a symbolic label L are known. In the case of 3D shapes, different views corresponding to different aspects of the object [.KD79,CF82] are acquired. Alterna- tively, given the high computational cost of finding different aspects of an object [GM90], and the ability of our system to recognize shapes from partial instances and with some amount of projective invariance, the Gaussian viewing sphere can be sampled at small regular intervals. For each given-triangle we compute a tuple containing four elements: the label of the object, the position (xT, yr) of the center of mass in the new right hand coordinate system defined by the normalized vector t23 and its corresponding orthonormal one, the ratio p - !XY, and the angle aT between the two vectors t,? and d. AI1 these parameters are also scale and rotation invariant, and are used to recover position, orientation and scale of a feature from the corresponding 3 point sets. For each possible combination of three points over the During recognition, in a similar fashion, all possible com- binations of 3 points from the image are used to generate similar sets of indices. For each tuple contained in the table at any given index, a feature-space parameter vector is generated which uniquely determines a possible shape. Based on the value of Count, the evidence density on the parameter space is updated. Triplets located on the same feature or shape correctly estimate the parameter vector and thus accumulate evidence in the density function. Other triplets produce pseudo-random results which will be scat- tered over the entire parameter space and result in negligible accumulation. For each parameter vector in the feature-space, we record the points used to generate its value, and the number of times they voted for it. This information is then used to prob- abilistically associate regions in the image with feature vec- tors in parameter space as discussed in [CBT89]. Constraint satisfaction techniques [Ba8la,CBT89,Mo90] are used to filter the result of the transforms based on this knowledge. Different vectors generated by overlapping data-point sub- sets compete in a “winner-take-all topology” [FB81], so that only the one with highest evidence support from the image is selected. Since the selected features do not share data support, they segment the original input image. By modifying the number of points, properties, and relationships considered, the same framework of evidence integration for nonparametric shapes can be extended to many different domains. In three-space, for instance, one could use the relative position sf any three points from a range data image, with their 1 order properties (surface normals) represented with respect to the plane defined by the three points. Local Shape Descriptors Stable and robust behavior of the transform depends on the correct selection of the set of points on the 2D-shape. No known data-driven techniques guarantee consistence in the selection of points, for a given shape, across different scales and in presence of quantization noise typical of digitized images. One solution is to exhaustively use all possible edge points. This corresponds to the previous formulation in terms of spatial autocorrelation transforms, see previous 2 equa- tions. The mapping operator, in this case, has the discrete structure of table look-up, and the integral is replaced by a summation over subsets of the image discrete locations. If the image used for shape acquisition contains enough data points, this would ensure the overlap of an extensive data subset even in presence of noise and input transformation on scale, rotation and tran lation. However, the s O(n ) computational complexity with respect to the number of considered points makes the ap- CALIFANOANDMOHAN 1069 C 2 A Fig. 3: Sampling on a curve preach unappealing when large data sets are explored. To overcome this difficulty, the shape transform is split into two distinct phases. In the first one, we encode the local 2D shape information into a small set of localized and symmetric shape descriptors. Next, we use this intermediate repre- sentation as the data set for the transform that recovers global shape information. We now have some other invariant parameters, namely those describing the local structure of a curve around each point in a given triplet. These are used to produce a higher dimensional vector for indexing in the look-up table, endow- ing the transform with even more selectivity. The framework for the acquisition and extraction of local shape descriptors is analogous to the one described in the previous subsection. While global shapes are not associated with any specific point on the shape and are positioned through their centers of mass, local shapes are associated with a specific point on the shape. For instance, elliptical arcs are associated with points where curvature reaches local extrema. Local shape descriptors considered are lines, circular arcs, and elliptic arcs (minima and maxima of curvature). Larger sets of local shape descriptors can also be considered [AB86]. First edges are extracted from images using standard techniques such as a Canny edge-detector [Ca86]. Edges are then linked into contours using simple eight neighbors con- nectivity. Given a point (x0, yO) on a contour, we symmetri- cally sample around that position alon the curve (see Fig. 3), generating a set (( Xi , yi ), -N zzz i z&. The sampling step ‘T is proportional to the length of the longest symmetrical interval around the point for which the tangent behavior is monotonic on a coarse scale, and the total tangent variation is less than 2%. It is also inversely proportional to the total variation in tangent angle on the symmetric interval if less then 2%. We assume that faster variation in tangent cor- respond to smaller features which accordingly require finer sampling for detection. In this way, a quasi scale invariant sampling of the contours is achieved. Next we form all possible combinations of the point (x0, yO) with two others from the set {(Xi ,yJ}. The vector (sl/S, QS, al, o@, described in section 2.3, is computed from each triplet and it is used to index into the local-shape look-up table. During acquisition, the computation is performed with (x0 9 yO) located at the center of symmetry for the considered shape. For each triplet, the tuple < h, P,S,Count > is inserted in the table. Here, h is the symbolic label for the local shape. 8 is the angle between the vector t and the normal to the contour n required to recover the shape orientation from the triplet. S = sI +~2+~3 is used for scale normalization. The role of parameter Count is identical to that explained in the previous subsection . During recognition, given (x0, yO) and the sample set {(xi 9 yJ}, triplets are formed and indices computed in an analogous fashion. For each entry in the table, a vector in a local shape parameter space is computed which uniquely identifies the shape, rotation and scale. The density function on the parameter space is updated with the value of Count. After all the triplets have been considered, the feature vector with the highest data support describes the shape around (x0 , yO). By considering the subset of {(Xi> yJ} that successfully voted for a given vector, it is also possible to recover the section of the contour associated with the corresponding shape descriptor. The process is repeated for the next point on the contour at the determined sampling rate, until the entire contour has been considered, and then for all other contours. Since sampling rates are recomputed for each point, sample density varies dynamically along the curve. After the extraction phase, local descriptors supported by overlapping portions of the contours compete, leaving only the ones with the highest confidence. In this way, contours are naturally segmented into a small set of nonoverlapping localized shapes which allow us to recover most of the original information, see Fig 4,5 and 6. The local descriptors are positioned at coarsely sampled contour locations. To increase stability, a finer localization is obtained by extract- ing new descriptors on a pixel by pixel basis, in a small neighborhood of the original local descriptors, and selecting again from among the results, the one with highest support. Through extensive experimental testing, this approach has shown a high degree of stability with respect to scale, rota- tion, translation, and limited projective transformations of the input data. The final set of descriptors is used for the global shape extraction. The index, in this case, becomes (y-s 9 y-s Y al, 9, h,, &, h,), where hi is the symbolic label for the shape at point (xi , yi). Scale information about the shapes could also be used since the nomalization factor S is known for each triplet, but this has not currently been implemented. Computational Complexity An important result is that recognition time is not ex- ponential in the number of image features and grows slowly with the number of models stored in the database. This property is required in machine vision to deal with the large number of shapes necessary for the analysis of real scenes. A direct implication of the use of third order autocorrela- tion functions, during acquisition and recognition, is O(nz) time complexity, where n, is the number of edge elements in the image. The use of local shape descriptors changes the complexity function into O(nz) where n, is the number of local shapes, n,en,. The following sections introduce techniques to reduce the time requirement to O(n,). 1070 VISION Acquisition Local shape descriptors are assigned a weight, wr, propor- tional to their visual relevance. This measure uses the length of their support normalized with respect to the size of the model (this favors large features) and/or the tangent angle variation per unit length that they describe (this favors corners). Larger features have a higher chance of being correctly identified from the input. Rapid variations in tan- gent correspond to curvature maxima which are well local- ized on contours. For each model, it is possible to isolate a small constant number, c, of such highly relevant descriptors Dr= Di:isc I I from the others D= Dj:jsns},D,ED. I We then generate all possible triplets with the first element from the set D and the other two from the set D, The total number of triplets formed, ns i 0 , is a linear function of ns Thus, the time required to acqurre a shape model, or one view for a 3D object, is O(n,). This representation is still highly redundant as each feature is present in at least ’ 0 2 triplets. Recognition Since real world objects have in general a compact struc- ture, it is possible to exploit this property to reduce the search space. For each identified descriptor we generate a circle of coherence centered at its location. The radius of this circle is proportional to the size of the local shape. Other descrip- tors from the same shape are more likely to be found within such circle.This technique has been demonstrated to reduce the cubic explosion in the number of triplets to a linear one [CBT89] with respect to the image size. For a given local descriptor, not all the visually relevant features used with it to acquire the model may be present in its radius of coherence. However, due to the highly redun- dant shape representation, this is usually sufficient to iden- tify the correct match. To make recognition robust with respect to noise in cluttered environments, we extend the radius of coherence until a required constant number of descriptors with desired visual significance w,, normalized with respect to the one of the considered descriptor, are found and we create triplets only with these. This search can be made efficient using multiresolution analysis techniques, or maintainingthe features in a heap structure. In either case, maximum search time is within O(n log n). For each triplet, all the entries of the indexed slot in the shape table have to be processe#. The average number of entries processed is cQ, c = 10 - , assuming a table size of 106, Q approximately 103, and an average of lo3 triplets generated. Thus recognition time is O(n log n Q). Shape Database The shape database is akin to associative memories [HA811 which usually employ distributed representations, in that each of the shape descriptions is not localized to a particular location but distributed over the memory. Such holographic representation engenders fault tolerance to loss of parts of the memory. Shapes are represented as a collec- tion of entries in the table and parameter vectors are used to index into it. Tables are implemented either as arrays, or as hash tables, depending on their size and sparseness. New shapes are learned by performing spatial autocorrela- tion on presented instances from images. Generality and robustness, to allow for the correct recognition behavior in the presence of noise and small projective transforms of the input, are achieved by storing different instances of the shape, by quantizing the parameter vectors (indices), and by stochastic index perturbation mechanism during acquisition. That is, a small randomness (order of the index parameter quantization) is added to the index for the look-up table along each of its dimensions. For each image and object, the acquisition is repeated until the indices no longer hit empty cells in the look-up table with a significant rate. Our model acquisition paradigm is basically a visual shape learning mechanism. As experimentally shown in the next section, this technique is stable to changes in orienta- tion, translations, scale and even small variations in shape, such as those caused by different limited projective trans- forms. This capability to handle small shape variations not only makes it robust to noise but also allows for generaliza- tion of the learned models. Thus when new, unlearned shapes are analyzed, they are matched by the closest stored representation. If the presented shape is significantly dif- ferent with respect to any of the stored ones, it is not clas- sified. However, once the new shape has been acquired, different instances of this shape are correctly recognized. Thus, this learning system not only exhibits generalization capabilities but also separability. Experiments We report some experiments illustrating the different capabilities of our model acquisition and recognition system. We selected the domain of leaf shapes to demonstrate the acquisition and recognition of complex nonparametric shapes. Two of the leaves from this set are shown in Fig. 4 and 7. In this and following figures we show the contours obtained by linking the edges. The contours have been smoothed with a Gaussian filter. The local shape descriptors detected on the first leaf are shown in Fig. 5 and 6. Robustness to noise and small variations in shape: 7% Gaussian noise was added to 20% of the points on the contours. The local shapes detected on this noisy image are shown in Fig . 8. Recognition and location were successful although the number of supporting features dropped to about 50% of those found in the original image. Sealing : An image of the leaf is taken at a shorter distance leading to projected shape of the leaf being 1.8 times larger than the model, Fig. 9. The recognition phase returns the correct label for the leaf and the correct scale factor. Fig. 10 shows the recognized model, scaled by the computed scale factor, and projected onto the image. Rotation and translation in the image plane: An image of leaf # 1 which has undergone rotation and translation in the image plane is considered. The system correctly iden- CALIFANOANDMOHAN 1071 Fig. 4: Shape of leaf #l Fig. 9: Scaled instance. Local shape descriptors Fig. 5: Local shape Fig. 6: Selected Fig. 7: Shape of leaf #2 Fig. 8: 7% Gaussian noise. descriptors descriptors Local shape descriptors / 2 2. Fig, 10: Recognition and Fig. 11: Rotated and Fig. 12: Projective transform Fig. 13: Recognition and location for Fig. 8 translated, recognition location for Fig. 12 tifies the shape and the parameters for rotation and transia- tion and scale. The original leaf #l model, translated and rotated with the recovered amounts is overlaid (Fig. 11). The difference in registration is due to the coarsely quantized computation of the geometrical transform parameters, e.g., the position of the center of mass. If needed, a more precise registration of the model to the image can be obtained by reducing the size of the quantization, rematching only the selected local shapes, and accumulating evidence only for the matched model. Viewpoint: Slant and/or tilt of the object corresponds to viewing the object from different viewpoints. A leaf is viewed with the image plane slanted and titled about % from a plane parallel to the leaf (i.e. projective transform, Fig. 12). There is also some magnification due to differences in the viewing distances. Even given the relatively large change in viewing direction, the correct model is recognized. This model with the scale and translation accounted for, is over- laid on the image in Fig. 13. Currently, recovery of viewing directions is not incorporated as the objects are 2D shapes. To show that these parameters can be recovered by learning the projected representations of the model at different view- ing angles, we acquired the skewed leaf shape as a separate leaf model. In subsequent recognition of the skewed shape, the correct instance is recognized. This not only indicates the system can be incremented to handle 3D shapes, but the factors of generalization and separability, i.e.shapes are categorized as the most similar object in the shape memory but after learning of the shape, the system is able to distin- guish between that similar shape and the newly learned one. Complex scenes: We analyze an image, shown in Fig. 14, containing multiple, with some occluded instances of ob- jects. The scene is cluttered with objects that have not been acquired. Ail the instances of leaf #1 are correctly recog- nized. Due to the presence of multiple objects, other models 1072 VISION in the memory also receive some votes. These models are suppressed by the constraint satisfaction mechanism. Again, the differences in the registration of the object model with the image (Fig. 14) reflect the quantized values used for computing the transforms. Conclusions and Future Directions We have successfully demonstrated a system for the auto- matic acquisition and recognition of complex visual shapes which are not easily modeled by conventional parametric techniques. We have additionally demonstrated the use of spatial autocorrelation as a viable mechanism for describing such shapes. The associative memory structure used for learning and recalling these shapes exhibits the properties of robustness, generalization and recall from partial descrip- tions, that have usually been considered to be limited to neural mechanisms. Additionally, this holographic memory is efficiently implemented on conventional computers, both in terms of time and space requirements. The learning is accomplished in time complexity of 0 (n) td O(n3), where the model is described by n local shape descriptors. The size requirement for the memory is O(mn) to O(mn3) where M is the number of distinct object shapes (or distinct object shapes times their different aspects for 3D shapes) and n the average number of local shapes per model. Recognition time is O(n, Q) to O(n, log nz Q), where nz is the number of local shape features in the image, and Q the number of models in the database. Future work will explore interesting properties exhibited by this mechanism for supervised/unsupervised learning of perceptual concepts such as symmetry and hierarchical or- ganization of models into subparts. A different line of re- search being pursued, includes stochastic techniques for applying autocorrelation operators in real-time tasks, such as in robotics, where concepts must be learned and recalled within short time frames. Acknowledgements We would like to thank Ruud Belle and Rick Kjeldsen for their reviews and comments and Norm Haas for help with the images. References [ABs6] H. Asada and M. Brady 1986. The curvature primal sketch. IEEE Transactions on Pattern Analysis and Machine Intelligence, PAMI-8(l). DSla] D.H. Ballard 1981a. Parameter nets: A theory of low level vision. In Proc. 7th Int. Joint Conf. On Artificial Intell., 10681078. [Ba8lb] D.H. Ballard 1981b. Generalizing the Hough transform to detect arbitrary shapes. Pattern Recognition, Vol. 13, No. 2: 111-122. [BCKSS)] R.M. Bolle, ACalifano, RKjeldsen and R.W. Taylor 1989. Visual recognition using concurrent and layered parameter networks. In Proc. IEEE Conf. on Comp. Vision and Patt. Recognition. [Blss] P.J. Besl and R.C. Jain 1985. Three-dimensional object recognition.Com.utingSurveys, Vol. 17, No. 1: 75- 145. [BHH83] R.C. Bolles, P. Horaud, and M.J. Hannah 1983. 3DPO: A three-dimensional part orientation system. In Proc. 8th Int. Joint Conf. on Artificial Intell., 1116-1120. [B&3] R.A. Brooks 1983. Model-based three-dimensional interpretations of two-dimensional images. IEEE Trans. on Pattern Analysis andMachine Intell., Vol. 5, No. 2: 140- 150. [Bu88] P.J. Burt 1988, “Smart sensing within a pyramid vision machine,” Proc. of the IEEE, Vol. 76, No. 8: 1006- 1015. Fig. 14: Object recognition on complex scenes [Cam J.F. Canny 1986, “A computational approach to edge detection”. IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol. 8, No. 6: 679-698,. [CasS] A. Califano 1988, “Feature recognition using cor- related information contained in multiple neighborhoods,” in Proc. 7th Nat. Conf. on Artificial Intell., pp. 831-836. [CBTS9] A. Califano, R.M. Belle, and R.W. Taylor 1989. Generalized neighborhoods: A new approach to complex feature extraction. In Proc. of IEEE Conf. on Comp. Vision and Pattern Recognition. [CF’82] I. Chakravarty and H. Freeman 1982. Charac- teristic view as a basis for three-dimensional object recog- nition. In Proc. SPIE Conf. on Robot Vision, 37-45. [Ch86] R.T. Chen and C.R. Dyer 1986. Model-based recognition in robot vision. ACM Computing Surveys, Vol. 18, No. 1: 66-108. [DH72] R.O. Duda and P.E. Hart 1972. Use of the Hough transform to detect lines and curves in images. Comm. ACM, 15(l): 11-15. ml] J.A. Feldman and D-H. Ballard 1981. Connec- tionist models and their properties. Cognitive Science, Vol. 6: 205-254. [GM901 2. Gigus and J.Malik 1990. Computing the aspect graph for line drawings of polyhedral objects. IEEE Transactions on Pattern Analysis and Machine Intel- ligence, Vol. 12, No. 2. [Go831 C. Goad 1983. Special purpose automatic programming for 3D model-based vision. In Proc. DARPA Image Understanding Workshop, 94-104. IHHS’I] C. Hansen and T. Henderson 1987. CAGD-Based computer vision. In Proc. Workshop on Comp. Vision, 100-105. ml] G.Hinton and J. Andreson 1981. Parallel models ofassociative memory. Lawrence Erlbaum Ass. [Ho621 P.V.C. Hough 1962. Methods and Means for Recognizing Complex Patterns, U.S. Patent 3069654. [IKSS] K. Ikeuchi and T. Kanade 1988. Automatic genera- tion of object recognition programs. IEEE Proceedings, Vol. 76, No. 8: 1016-1035. m6’J A. Kalvin, E. Schonberg, J.T Schwartz, M. Sharir 1986. Two-dimensional, model-based, boundary matching using footprints. The International Journal of Robotics Re- search, Vol. 6, No. 4. [KD79] J. Koenderink and A. van Doorn 1979. The inter- nal representation of solid shape with respect to vision. Biological Cybernetics, Vol. 32: 211-216. [LWSS] Y. Lamdan and H.J. Wolfson 1988. Geometric hashing: a general and efficient model-based recognition scheme. In Proc. 2nd Intnl. Conf. on Comp. Vision. ~090] R. Mohan 1990. Constraints satisfaction networks for computer vision. Progress in Neural Networks, 0. Omidvar ed., Ablex. [Tat481 G. Taubin 1988. Nonplanar curve and surface es- timation in 3-space. In Proc. of IEEE Conf. on Robotics and Automation. CALIFANOANDMOHAN 1073
|
1990
|
47
|
964
|
Coping with Uncertainty in a Control System for Navigation and Explosat ion Thomas Dean* Kenneth Basye Robert Chekaluk Seungseok Hyun Moises Lejter Margaret Randazza Department of Computer Science Brown University, Box 1910, Providence, RI 02912 Abstract A significant problem in designing mobile robot control systems involves coping with the uncertainty that arises in moving about in an unknown or partially unknown environment and relying on noisy or ambiguous sensor data to acquire knowledge about that environment. We describe a control system that chooses what activity to engage in next on the basis of expectations about how the information returned as a result of a given activ- ity will improve its knowledge about the spatial layout of its environment. Certain of the higher-level compo- nents of the control system are specified in terms of probabilistic decision models whose output is used to mediate the behavior of lower-level control components responsible for movement and sensing. The control sys- tem is capable of directing the behavior of the robot in the exploration and mapping of its environment, while attending to the real-time requirements of navigation and obstacle avoidance. Exploration and Navigation We are interested in building systems that construct and maintain representations of their environment for tasks involving navigation. Such systems should ex- pend effort on the construction and maintenance of these representations commensurate with expectations about their value for immediate and anticipated tasks. Such systems should employ expectations about the in- formation returned from sensors to assist in choosing activities that are most likely to improve the accuracy of its representations. Finally, in addition to reasoning about the future consequences of acting, such systems must attend to the immediate consequences of acting in a changing environment: consequences that generally cannot be anticipated and hence require some amount *This work was supported in part by a National Sci- ence Foundation Presidential Young Investigator Award IRI-8957601 with matching funds from IBM, and by the Advanced Research Projects Agency of the Department of Defense and was monitored by the Air Force Office of Sci- entific Research under Contract No. F49620-88-C-0132. of continuous attention and commitment in terms of computational resources. We start with the premise that having a map of your environment is generally a good thing if you need to move between specific places whose locations are clearly indicated on that map. The more frequent your need to move between locations, the more useful you will prob- ably find a good map. If you are not supplied with a map and you find yourself spending an inordinate amount of time blundering about, it might occur to you to build one, but the amount of time you spend in building a map will probably depend upon how much you anticipate using it. Once you have decided to build a map, you will have to decide when and exactly how to go about building it. Suppose that you are on an er- rand to deliver a package and you know of two possible routes, one of which is guaranteed to take you to your destination and a second which is not. By trying the second route, you may learn something new about your environment that may turn out to be useful la.ter, but you may also delay the completion of your errand. Huey, the robot used in our experiments, is built al- most entirely from off-the-shelf components: a 1%inch diameter synchro-drive base from Real World Interface (Dublin, New Hampshire), a sonar ring subsystem from Denning Mobile Robotics (Wilmington, Massachusetts) equipped with 8 Polaroid ultrasonic sensors, and an 80286-based IBM/AT compatible computer with 2M of memory, a 3-inch floppy, and a serial interface card, run- ning the QNX operating system from Quantum Soft- ware (Kanata, Ontario). The various microprocessors on Huey communicate through serial lines. Huey can operate autonomously using on-board power and com- puting, or tethered to a Unix workstation. Huey’s ultrasonic sensors provide it with information about the distance to nearby objects. With a little care, Huey can detect the presence of a variety of geometric features using these sensors. In gathering information about the office environment, Huey will drive up to a surface to be investigated, align one of the sensors to the right or to the left of its direction of travel along the surface, and then move parallel to that surface looking 1010 ROBOTICS From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. for abrupt changes in the information returned by the aligned sensor that would indicate some geometric fea- ture such as a 90° corner. In doing this, Huey keeps track of the accumulated error in its movement and the variation in its sensor data to assign a probability to whether or not a feature is present. Huey has strategies for checking out many simple ge- ometric features found in typical office environments; we refer to these strategies as feature detectors. The complete set of feature detectors used by Huey and the details concerning their implementation are described in [Randazza, 19891. Each feature detector is realized as a control process that directs the robot’s movement and sensing. On the basis of the data gathered during the execution of a given feature detector, a probability distribution is determined for the random va.ria.ble cor- responding to the proposition that the feature is present at a specific location. Huey is designed to explore its environment in order to build up a. representation of that environment suit- able for route planning. In the course of exploration, Huey induces a graph that captures certain qualitative features of its environment [Kuipers and Byun, 1988, Levitt et al., 1987, Basye et al., 19891. In addition to de- tecting geometric features like corners and door jambs, Huey is able to classify locations. In particular, Huey is able to distinguish between corridors and places where corridors meet or are punctuated by doors leading to offices, labs, and storerooms. A corridor is defined as a piece of rectangular space bounded on two sides by uninterrupted parallel surfaces 1.5 to 2 meters apart and bounded on the other two sides by ports indicated by abrupt changes in one of the two parallel surfaces. The ports signal locally distinctive places (LDPs) (after [Kuipers and Byun, 19881) which generally correspond to hallway junctions. Uninterrupted corridors are rep- resented as arcs in the induced graph while junctions are represented as vertices. Junctions are further parti- tioned into classes of junctions (e.g., L-shaped junctions where two corridors meet at right angles, or T-shaped junctions where one corridor is interrupted by a second perpendicular corridor). Huey is given a set of junction classes that it uses to classify and the label the locations encountered during exploration. In the following sections, we consider two of the main decision processes that comprise Huey’s control system, but first we consider briefly the overall architecture in which these decision processes are embedded. Planning and Control Huey’s control system is composed of a set of decision processes running concurrently under a multi-tasking prioritized operating system. There is no shared state information; all communication is handled by inter- process message passing. Run-time process arbitration is handled by dynamically altering the process priori- ties. Coordination among processes is achieved through a I Sonar Conlroller I I Motor Controller I Figure 1: Huey’s Control Processes a set of message-passing protocols. The different processes that make up Huey’s con- troller are partitioned into levels (see Figure 1). For each level, there is a corresponding arbitrator designed to coordinate the different processes located at that level. At Level 0, we find the processes responsible for control of the different sensor/effecter systems on board the mobile base. Each Level 0 process is completely in- dependent of the other processes, so no arbitration is needed. At Level 1, we find the processes responsible for the low-level control of Huey. Level 1 processes are co- ordinated using a simple priority scheme: the obstacle avoidance process always takes priority over the other Level 1 processes. The activities of the feature recog- nition and corridor following processes are coordinated by higher-level processes. Currently, Huey has only one Level 2 process, the LDP classifier, but, as we increase Huey’s capabilities, we anticipate several additional processes on this level. At Level 3, we find the two processes responsible for Huey’s higher-level behaviors: the task manager in charge of running user-specified errands, and the geographer in charge of exploration and map building. The geogra- pher (roughly) implements the algorithms in [Basye et al., 19891. The task manager is a very simple route planner. The activities of these two processes are co- ordinated by a Level 4 decision process that takes into account the possible costs and benefits to be derived from different strategies for mixing exploration and er- rand running. To get a better idea of how Huey han- dles some of its higher-level decision making, we now describe the decision processes at Levels 2 and 4. Classifying Locally Distinctive Places Upon exiting a corridor through a port, Huey will want to determine what sort of LDP it has entered. If Huey is in a well-explored portion of its environment, this DEAN ET AL. 1011 variables, a decision node corresponding to actions that the robot might take, and a vabu~ node representing the expected utility of invoking the different feature detec- tors in various circumstanc&. The chance nodes include a hypothesis variable, H, that can take on values from C, and a set of boolean variables of the form, Xf,y, used to represent whether or not the feature f is present at location w. Each Xj,w is conditioned on the hypothe- sis H according to the distribution Pr(Xj,w ]Ci) deter- mined by whether or not the class requires the feature at the specified location. . . The decision node, Pt, mdr- Figure 2: LDP-classification module’s influence diagram determination should match Huey’s expectations as in- dicated in its map. If, on the other hand, Huey is in some unknown or only partially-explored area, this de- termination will be used to extend the map, possibly adding new vertices or identifying the current LDP with existing vertices. In this section, we describe how Huey classifies the LDPs encountered during exploration. Let L be the set of all locally distinctive places in the robot’s environment, C = (Cl, C’s,. . . , Cn) be a set of equivalence classes that partitions L, and F be a set of primitive geometric features (e.g., convex and concave corners, flat walls). Each class in C can be character- ized as a set of features in F that stand in some spatial relationship to one another. As Huey exits a port, a local coordinate system is set up with its origin on the imaginary line defined by the exit port and centered in the corridor. The space about the origin enclosing the LDP is divided into a set of equi-angular wedges W. For each feature/wedge pair (f, w) in F x W, we define a specialiaed feature detector df,, that is used to deter- mine if the current LDP satisfies the feature f at location w in the coordinate system established upon entering the LDP. Let D be the set of all such feature detectors plus no-op, a pseudo-detector that results in no new information and takes no time or effort to execute. Huey’s LDP-classification module maintains a a prob- a.bilistic assessment of the hypotheses concerning the class of the current LDP given the evidence acquired thus far. At any given time, Huey will have tried some number of feature detectors. Let Pt be the pool of de- tectors available for use at time t; Pt is just D less the set of detectors executed up until t in classifying the current LDP. The LDP-classification module is respon- sible for choosing the next feature detector to invoke from the set Pt. It does so using a decision model cast in terms of an influence diagram [Howard and Math- eson, 19841. The details are described in [Chekaluk, 19891; in the following, we highlight the main points. The LDP-classification module’s influence diagram in- cludes a set of chance nodes corresponding to random cates the feature detectors available for use at time t, and the ing each value node, V, represents the utility of invok- feature detector. V is dependent only upon the hypothesis and decision nodes. The predecessors of Pt are just the feature detectors invoked so far, thereby indicating temporal precedence and informational de- pendence. A graphical representation of the influence diagram is shown in Figure 2. The utility of invoking each detector is based on (i) the ability of the detector to discriminate among the hy- potheses, (ii) the cost of deploying the detector, (iii) the probability that the current best hypothesis is correct, and (iv) the cost of misidentifying the LDP. The first two are used to select from among D - (no-op) and the last two are used to choose between the best detector from D - {no-op) and no-op. The LDP-classification module selects from D - (no-op), using the function, p : Pt x H + !J?, defined by ~(dj,~, h) = nlDiscrim(dj,,,,) - nzCost(dj,, , h), where nl and ~2 are constants used for scaling, Co~t(djp, h) is a function of the expected time spent in executing dj,, for an LDP of a given Class, and Discrim(dj,, ) is the discrimination function of [Cameron and Durrant-Whyte, 19881 adapted for our application, and defined by 2 Pr(C;) c 1 Pr(dj+, = vIG) - Pr(dj,W = v)I, i=l uao,11 where dj+ = 11 is meant to represent the proposition that the detector dj,, returns the value ‘u. The terms in the above formula are easily obtained. Pr(dj,, = v]C;) is the distribution associated with the corresponding Xj,W node, and Pr(dj,w = V) can be calculated using Pr(dj,, = V) = 2 Pr(df,, = 71lCi) Pr(Ci) i=l The LDP-classification module evaluates the influence diagram using Agogino and Rama.murthi’s [1988] algo- rithm to obtain a decision policy and an expected value function for choosing from among D - (no-op). The LDP-classification module can also choose to do nothing by selecting no-op, thereby committing to the class Ci with the highest posterior probability given the infor- mation returned by the feature detectors invoked thus 1012 ROBOTICS far. The actual decision model used by Huey is some- what more complicated than the one described here; in particular, Huey has an additional set of chance nodes corresponding to micro features, the set of feature de- tectors is more extensive than indicated here, and the current system allows for a feature detector to be in- voked multiple times. Expected Value of Exploration We have experimented with several decision models for reasoning about the expected value of exploration. In the simple model presented in this section, we assume that the system of junctions and corridors that make up Huey’s environment can be registered on a grid so that every corridor is aligned with a grid line and ev- ery junction is coincident with the intersection of two grid lines. In the following, the set of junction types, J, corresponds to all possible configurations of corridors incident on the intersection of two grid lines. Intersec- tions with at least one incident corridor correspond to LDPs. Since we also assume that Huey knows the di- mensions of the grid (i.e., the number of z and y grid lines), Huey can enumerate the set of possible maps M = (MI, M2, . . .t M,), where a map corresponds to an assignment of a junction type to each intersection of grid lines. For most purposes, we can think of a map as a labeled graph. We restrict M by making a number of assumptions about office buildings of the sort that Huey will find it- self in (e.g., all LDPs are connected). To further restrict M; Huey engages in an initial phase of task-driven ex- ploration. Each task specifies a destination location in a, y grid coordinates. Huey computes the shortest path assuming that all intersections have as many coincident corridors as is consistent with what is known about the intersection and its adjacent intersections. Huey then follows this path, acquiring additional information as it moves through unknown intersections until it either finds its path blocked, in which case it recomputes the shortest path to the goal taking into account its new knowledge, or it reaches the goal. Huey continues in this task-driven exploration phase until it is likely-based on the spatial distribution of known locations-that all locations have been visited at least once. From this point on, given a task to move to specific location, it is likely that Huey will be able to compute a path through known territory. Huey now faces the decision whether to take the known path or to try an alternative path through unknown territory. In the model considered here, Huey has to choose between taking the shortest path through known territory, and trying the shortest path consistent with what is known. In the latter case, Huey will learn something new, but it may end up taking longer to complete its task. Let H be a random variable corresponding to the actual configuration of the environment; H takes on values from M. Let Js,v be a random variable corre- Figure 3: The probabilistic model for map building sponding to the junction type of the intersection at the coordinates, (2, y), in the grid; Jz,y can take on values from the set C defined previously. Let Xj,w be as pre- viously defined, a boolean variable corresponding the presence of a feature at a particular position. Let S& be a random variable corresponding to a possible sens- ing action taken at the coordinates, (z, y), in the grid. Let I correspond to the set of sensing actions taken thus far. The complete probabilistic model is shown in Figure 3. In our simple model, Huey has to decide between the two alternatives, PK and Pu, corresponding to paths through known and unknown territory. To compute P+flq, J+(H) is assumed to be uniform, Pr( Ja,y I H) and J+(.& I Jlo,y) are determined by the geometry, and Pr(S,,, IXjtw) is determined experimentally. Let T = (Tl,Ta,..., T,.) denote the set of all tasks corre- sponding to point-to-point traversals, and E( ITi 1) de- note the expected number of tasks of type Ti. Let Cost(Ti, Mj, Mk) be the time required for the task Ti using the map Mj, given that the actual configuration of the environment is Mk; if Mj is a subgraph of Mk, then Cost(T;, Mj, Mk) is just the length of the shortest path in Mjs Let T* denote Huey’s current task. For evaluation purposes, we assume that Huey will take at most one addition al exploratory step. To complete the decision model, we a means of computing the expected value of PK and Pu. In general, the value of a given action is the sum of the immediate costs related to T* and the costs for expected future tasks. Let Futures(M;,l) = xE(ITjI)Cost(q, M;, M;), j=l where Mf = Margmax,~r M,II)- If classification is i per ect, Huey correctly classifies any location it passes through, and ME is the minimal DEAN ET AL. 1013 assignment consistent with what it has classified so far. In this case, the expected value of PK is Cost(T*, M*, -) + Futures( -, I). If classification is imperfect, the expected value of PK is 5 Pr(Mj ]r) [Cost(T*, M*, Mj) + Futures(Mj, E)] . j=l Handling Pv is just a bit more complicated. Suppose that Huey is contemplating exactly one sensing action that will result in one of several possible observations 01, - - - t 0,, then the expected value of Pu is 2 Pr(Mj ]E) Cost(T*‘, M*, Mj) + j=l 73 731 probability tables l/a where s is the number of junc- tion types. If Huey ever detects that ME = I, then it assumes that it has excluded the real map, and dy- namically adjusts its decision model by computing a new sample space for H guided by the results of the exploratory actions taken thus far. Designing Robot Control Systems C Pr(Oi) >: Pr(Mj ]Oi, &)Futures(lClj, [Oi, r]) i=l j=l where T*’ is a modification of T* that accounts for the proposed exploratory sensing action. We use Jensen’s [1989] variation on Lauritxen and Spiegelhalter’s [1988] algorithm to evaluate the network shown in Figure 3. The time required for evaluation is determined by the size of the sample spaces for the individual random variables and the connectivity of the network used to specify the decision model. In the case of a singly-connected’ network, the cost of computation is polynomial in the number of nodes and the size of the largest sample space-generally the space of possible maps. The network shown in Figure 3 would be singly- connected if each feature, Xf,w, had at most one parent corresponding to a junction, Jm,y; a network of this form with 100 possible maps can be evaluated in about 10 seconds, assuming an 8 x 8 grid. Our approach to designing Huey’s control system is outlined as follows. We begin by considering Huey’s overall decision problem, determining an optimal deci- sion procedure according to a precisely stated decision- theoretic criteria, neglecting computational costs. We use an influence diagram to represent the underlying de- cision model and define the optimal procedure in terms of evaluating this model. Huey’s overall decision problem involves several com- ponent problems associated with specific classes of events occurring in the environment. These component decision problems include what action to take when ap- proached by an unexpected object in a corridor, what sensor action to take next when classifying a junction, and what path to take in combining exploration and task execution. Each of these problems is recurrent. In the case of a multiply-connected network, the cost of computation is a function of the product of the sixes of the sample spaces for the nodes in the largest clique of the graph formed by triangulating the DAG correspond- ing to the original network. By making use of the infor- mation gathered in the initial exploratory phase, Huey is able to reduce the connectivity of the network used to encode the decision model. The multiply-connected networks that Huey currently uses have around 50 pos- sible maps, and require on the order of a few minutes to evaluate. The space of possible maps chosen may not include the map correspo&mg to the actual configuration of the environment. To handle such possible omissions. we add a special value, I, to the sample space for H, and make all of the Pr( Jz,ar ]I) entries in the conditional ‘A network is said to be singly-connected if there is at most one directed path between any two nodes; otherwise, it is said to be multiply connected [Pearl, 19881. Problems involving what sensor action to take in classification or what path to take in navigation are predictably recurrent. For instance, during classifica- tion each sensor action takes about thirty seconds to a minute, so the robot has that amount of time to decide what the next action should be if it wishes to avoid standing idle lost in computation. The frequency with which choices concerning what path to take occur is dependent on how long Huey takes to traverse the corridor on route to the next LDP. With the current mobile platform operating in the halls of the computer science department, moving between two consecutive LDPs takes about four minutes. The problem of decid- ing what to do when approached by an unexpected ob- ject occurs unpredictably, and the time between when the approaching object is detected and when the robot must react to avoid a collision is on the order of a few seconds. By making various (in)dependence assumptions and eliminating noncritical variables from the overall com- plex decision problem, we are able to decompose the globally optimal decision problem into sets of simpler component decision problems. Each of the sets of com- ponent problems are solved by a separate module. The computations carried out by these modules are op- timized using a variety of techniques to take advan- tage of the expected time available for decision making [Kanazawa and Dean, 19891. The different decision pro- cedures communicate by passing probability distribu- tions back and forth. For instance, the module respon- sible for making decisions regarding exploration and the module responsible for classifying LDPs pass back and forth distributions regarding the junction types of LDPs. 1014 ROBOTICS Conclusions and Related Work The original designs for Huey’s control system were in- fluenced by the design of the Hilare robot [Chatila and Laumond, 19851. The lower-levels of the control system rely little upon the existence of a global clock and ad- here for the most part to the specifications of Brooks’ subsumption architecture [Brooks, 19861. Our use of in- fluence diagrams and Bayesian decision theory was in- spired by recent work on decision-theoretic control for visual interpretation and sensor placement [Cameron and Durrant-Whyte, 1988, Hager, 1988, Levitt et al., 19881. The design of the geographer module was based on the work of Kuipers [Kuipers and Byun, 19881 and Levitt [Levitt et al., 19871 on learning maps of large- scale space, and our own extensions to handle uncer- tainty [Basye et al., 19891. The design of the module re- sponsible for coordinating exploration and errand run- ning was based on an application of information value theory [Howard, 19661. Huey’s control system combines high-level decision masking with low-level control and sensor interpreta- tion to provide for navigation, real-time obstacle avoid- ance, and exploration in an unfamiliar environment. The basic controller handles multiple asynchronous pro- cesses communicating via simple message-passing pro- tocols. The architecture supports a variety of arbitra- tion schemes from fixed-priority processor scheduling to decision-theoretic control. This paper emphasizes two decision processes: one responsible for reasoning about the uncertainty inherent in dealing with noisy and ambiguous sensor data, and a second responsible for assessing the expected value of various exploratory actions. Our basic approach to designing robot control systems involves constructing a decision model for the overall problem and then decomposing it into compo- nent models guided by the time criticality of the asso- ciated decision problems. References [Agogino and Ramamurthi, 19881 A. M. Agogino and K. Ramamurthi. Real-time influence diagrams for monitoring and controlling mechanical systems. Technical Report Technical Report, Department of Mechanical Engineering, University of California, Berkeley, 1988. [Basye et al., 19891 K enneth Basye, Thomas Dean, and Jeffrey Scott Vitter. Coping with uncertainty in map learning. In Proceedings IJCAI 11, pages 663-668. IJCAI, 1989. [Brooks, 19861 Rodney A. Brooks. A robust layered control system for a mobile robot. IEEE Journal of Robotics and Automation, 2~14-23, 1986. [Cameron and Durrant-Whyte, 19881 Alec Cameron and Hugh F. Durrant-Whyte. A bayesian approach to optimal sensor placement. Technical report, Ox- ford University Robotics Research Group, 1988. [Chatila and Laumond, 19851 R. Chatila and J.-P. Laumond. Position referencing and consistent world modeling on mobile robots. In IEEE International Conference on Robotics and Automation, pages 138- 145, March 1985. [Chekaluk, 19891 Robert A. Chekaluk. Using influence diagrams in recognizing locally-distinctive places. M.Sc. Thesis, Brown University, 1989. [Hager, 19881 Gregory D. Hager. Active reduction of uncertainty in multi-sensor systems. Ph.D. Thesis, University of Pennsylvania, Department of Computer and Information Science, 1988. [Howard and Matheson, 19841 Ronald A. Howard and James E. Matheson. Influence diagrams. In Ronald A. Howard and James E. Matheson, editors, The Principles and Appbications of Decision Anal- ysis. Strategic Decisions Group, Menlo Park, CA 94025, 1984. [Howard, 19661 Ronald A. Howard. Information value theory. IEEE Transactions on Systems Science and Cybernetics, 2( 1):22-26, 1966. [Jensen, 19891 Finn V. Jensen. Bayesian updating in recursive graphical models by local computations. Technical Report R-89-15, Institute for Electronic Systems, Department of Mathematics and Computer Science, University of Aalborg, 1989. [Kanazawa and Dean, 19891 Keiji Kanazawa and Thomas Dean. A model for projection and action. In Proceedings IJCAI 11, pages 985-990. IJCAI, 1989. [Kuipers and Byun, 19881 Benjamin J. Kuipers and Yung-Tai Byun. A robust, qualitative method for robot spatial reasoning. In Proceedings AAAI-88, pages 774-779. AAAI, 1988. [Lauritzen and Spiegelhalter, 19881 Stephen L. Lau- ritzen and David J. Spiegelhalter. Local computa- tions with probabilities on graphical structures and their application to expert systems. Journal of the Royal Statistical Society, 50(2):157-194, 1988. [Levitt et al., 19871 Tod S. Levitt, Daryl T. Lawton, David M. Chelberg, and Philip C. Nelson. Qualita- tive landmark-based path planning and following. In Proceedings AAAI-87, pages 689-694. AAAI, 1987. [Levitt et al., 19881 Tod Levitt, Thomas Binford, Gil Ettinger, and Patrice Gelband. Utility-based con- trol for computer vision. In Proceedings of the 1988 Worhshop on Uncertainty in Artificial Intelligence, 1988. [Pearl, 19881 Judea Pearl. Probabilistic Reasoning in Intelligent Systems: Networhs of Plausible Inference. Morgan-Kaufman, Los Altos, California, 1988. [Randazza, 19891 Margaret J. Randazza. The feature recognition module of the ldp system for the robot huey. M.Sc. Thesis, Brown University, 1989. DEAN ET AL. 1015
|
1990
|
48
|
965
|
Learning General Completable Reactive Pla Melinda T. Gervasio* Beckman Institute for Advanced Science and Technology University of Illinois at Urbana-Champaign 405 N. Mathews Ave., Urbana, Illinois 61801 gervasio@cs.uiuc.edu Abstract This paper presents an e’xplanation-based learning strategy for learning general plans for use in an integrated approach to planning. The integrated approach augments a classical plan- ner with the ability to defer achievable goals, thus preserving the construction of provably-correct plans while gaining the ability to utilize runtime information in planning. Proving achievability is shown to be possible without having to deter- mine the actions to achieve the associated goals. A learning strategy called contingent explanation-based learning uses conjectured variables to represent the eventual values of plan parameters with unknown values a priori, and completers to determine these values during execution. An implemented system demonstrates the use of contingent EBL in learning a general completable reactive plan for spaceship acceleration. Introduction The planning problem may be characterized as the problem of determining an ordered sequence of actions which when executed from a given initial state will achieve a given goal. In classical planning [Chapman87, Fikes7 1, Stefik8 11, plans are determined completely prior to execution by using infer- ence to predict the effects of actions and essentially construct proofs of goal achievement. Provided a classical planner has perfect a priori knowledge, its plans are guaranteed to achieve the given goals. Unfortunately, real world domains can rarely be characterized perfectly. Reactive planning [Agre87, Firby87, Schoppers87;Suchman87] is an alterna- tive approach which makes no predictions about the future andinsteadrepeats a cycle of evaluating the environment and determining an appropriate action. Reactive planning thus solves the extended prediction problem faced by classical planning [Shoham86] simply by eliminating it. Because reactive planning is essentially a hill-climbing approach, however, one wrong reaction may delay or prevent a reactive planner from achieving its goals. Furthermore, reactive plan- ners must also be hand-tailored to achieve the desired behav- ior. Thus, while machine learning strategies have been suc- cessfully applied to classical planners in various domains [Chien89, Fikes72, Hammond86, Minton851, only prelimi- nary work has been done in learning reactive rules [Blythe89, Schoppers871. * This research was supported by the Office of Naval Research under grant N-0001 4-M-0309. The planning approach presented in this paper integrates classical planning and reactive planning to solve some of their limitations while retaining their merits. In this integra- tion, a classical planner is augmented with the ability to defer goals guaranteed to be achievable, thus enabling the use of runtime information without sacrificing the provably-cor- rect nature of plans. The integrated approach also retains the learning abilities of classical planning through contingent explanation-based learning, a strategy which enables learn- ing general plans for use in the integrated approach. An Integrated Approach To Planning Given an initial state description I and a goal state description G, the planning problem involves the determination of a plan P consisting of a sequence of actions which when executed from the initial state will achieve a goal state. 1 Here we con- sider the case wherein a planner has access only to partial state descriptions and thus needs to reason about sets of states rather than individual states. Determining a plan in the integrated approach takes place in two stages. Prior to execution, a compktable partial plan is constructed. That is, the plan may be incomplete, but it is guaranteed that the missing components can be determined during execution. The plan is then completed during execu- tion, possibly with the use of information which becomes available then. Since the plan is completable, any deferred goals are guaranteed to be satisfied during execution. Let states(S) be the set of states satisfying the partial state description S, and PR(p) and EF(p) the precondition and ef- fect state descriptions of an action or action sequence p. Giv- en initial and goal state descriptions I and G, the first stage consists of determining a sequence of subplans Q = {qm,...,qd such that: states(I) c states(ql) AND states(q,) c states(G) AND achievablc(EF(qi),PR(qi+l),) for all qiE {ql,...,qn-1) where achievability is defined as follows: achievable(Sl&) iff V SE states(S1) 3 a plan p which when executed from s will result in a state in states(S2). Note that proving achievability does not require determining a precise plan but rather proving only the existence of a plan. 1. To simplify the presentation, the planning problem is charac- terized as determining completely-ordered action sequences. 1016 ROBOTICS From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Q may thus be provably correct even while being only par- tially-determined. The second stage consists of determining a set of subplans R = {rl, r2, . . . . r-1 > to complete Q, that is: - V qiE {ql,...&-1 } executing ri in the effect state Of Cl; E- suits in a precondition state for the subplan qi+l. Because achievability proofs for R were constructed in the first stage, it is guaranteed that subplans will be found for achieving the deferred goals. The final plan P is thus {91,rl,q2rr2r...,qrr-l,rn-l,q,}.2 Proving Achievability The integrated approach is naturally limited by the achievab- ility constraint on deferred goals. However, it provides a so- lution to an interesting group of planning problems. There are many problems in relatively well-behaved domains where enough a priori information is available to enable the construction of almost complete plans. There are also certain kinds of information which are difficult to predict a priori but can trivially be gathe=d during execution. In these cases, a planner which constructs plans completely a priori faces an extremely difficult task, while a planner which leaves every- thing to be dynamically determined by reacting to the execu- tion environment loses the goal-directed behavior provided by a priori planning. A planner in the integrated approach faces neither problem, with its ability to defer achievable goals and utilize runtime information in its planning. An important criterion for the success of the integrated ap- proach is proving achievability without having to determine actions to achieve the associated deferred goal. Isolating the issue of proving achievability provides two important advan- tages: 1) the option of deferring planning decisions simpli- fies a priori planning, and 2) the use of execution-time infor- mation lessens a planner’s reliance on perfect knowledge prior to execution. Consider the problem of whipping cream An a priori computation of the precise time interval over which to whip the cream in order to achieve soft peaks would have to account for a whole host of factors, such as the chang- ing temperature of the cream, the speed of the beaters, and the humidity in the kitchen. In contrast, monitoring for the de- sired consistency at execution time, as would be done in the integrated approach, is a fairly simple task. Three classes of problems have been identified wherein achievability proofs can be constructed without determining the actions to achieve the associated goals. Repeated Actions and Terminal Goal Values. The first class of problems involves repeated actions towards a terminal goal value, such as hammering a nail all the way into a piece of wood or completely unloading a clothes-dryer. The ach- ievability proof for this class of problems lies in the notion of incremental progress, with every execution of an action re- sulting in a state nearer to the goal state until the goal is reached, in which case the action has no effect. For example, every action of pulling clothes out of the dryer will result in less clothes being in the dryer until the goal of the dryer being 2. Cases with (ro,q,,.. . } or { . . ..qn.rn+l } can be treated similarly. completely empty is reached. Instead of being precomputed, the precise number of repetitions needed can thus be deter- mined at execution time by repeatedly performing the un- loading action until the dryer is empty. Continuously-Changing Ouantities and Intermediate Goal Values The second class of problems involves continuously- changing quantities and intermediate goal values, such as whipping cream until soft peaks form or accelerating to some higher velocity. Proving achievability for this class of prob- lems involves reasoning about the achievability of the limits on the value of a continuously-changing quantity, which guarantees the achievability of all the values within those limits. For example, whipping cream until stiff peaks form can be achieved by running the whipping process over some time interval, thus the intermediate soft-peaks stage is achievable by running the whipping process over some smaller time interval. During execution, this smaller interval can be dynamically determined by monitoring the cream for the desired consistency. Multivle Ovvortunities The third class of problems involves multiple opportunities, such as choosing a paper cup for cof- fee or deciding which gas station to stop at on a long trip. The achievability proof for these problems depends upon the ex- istence of several objects of some type needed to achieve the goal. For example, the state of having a clean, graspable cup at the time of getting coffee is achievable if there is a stack of cups in the cabinet from which one may be chosen. Thus, complicated reasoning about particular cups can be avoided by deferring the cup choice until the cups are in sight and one can be chosen trivially. Achievability proofs are implemented as rule schemata, which are second-order predicate calculus rules which serve as templates from which to derive first-order predicate cal- culus rules for use in theorem-proving. Figure 1 shows an example of such a rule schema for the class of problems in- volving continuously-changing quantities and intermediate goal values, as well as a rule derived from that schema for in- creasing quantities. The reasoning embodied by this schema, also known as the Intermediate Value Theorem in calculus, is as follows. Let q be a continuous quantity having a value vg at some time t(-~ Also let it be the case that certain condi- tions 8 being true over some interval (to t2) will result in q having some other value v2 at time t2. Then for all values v1 between vg and v2 there exists some time tl within the inter- val (to t2) such that if 8 holds over the interval (to tl), q will have the value v1 at tl. This reasoning as applied to an in- creasing quantity is depicted graphically in Figure 2 . Learning Reactive Plans In the integrated approach, a plan is partially constructed prior to execution and completed during execution. We call such a plan a reactiveplan. The integrated approach requires that all deferred goals be achievable, hence the plans are com- pletable reactive plans. The learning objective is to learn general completable reactive plans from observation. Explanation-based learning (EBL) is a knowledge-inten- sive procedure by which general concepts may be learned GERVASIO 1017 Intermediate Value Rule Schema [‘d 6 [VqvOv2tOt2 ((value q v0 to) AND (continuous q) AND ((0 [to t2]) + (value q v2 t2)) ) + [Vvl (between vl v0 v2) + [3 tl (within tl (to t2)) AND ((0 00 W> --+ (value 9 vl W I I I I Intermediate Value Rule for An Increasing Quantity [vqvov2tot2vl ( (value q v0 to) AND (continuous q) AND ( (qualitative-behavior q increasing (to t2)) -+ (value q v2 t2)) (between vl v0 v2) ) [3 tl (within tl [to t2]) AND ( (qualitative-behavior q increasing (to tl)) + (value q vl tl) ) ] ] Figure 1. Sample Rule Schema and Derived Rule. to fi t2 time Figure 2. Reasoning about intermediate values for an increasing quantity. from an example of the concept [DeJong86, Mitchell861. EBL involves constructing an explanation for why a particu- lar training example is an example of the goal concept, and then generalizing the explanation into a general functional definition of that concept or more general subconcepts. In planning, explanation and generalization may be carried out over situations and actions to yield macro-operators or gen- eral control rules. Here, we are interested in learning macro- operators or general plans. Reactive plans present a problem for standard explana- tion-based learning [Mooney86]. Imagine the problem of learning how to cross. After the presentation of an example, an explanation for how the crosser got to the other side of the street may be that the crossing took place through some sui- tably-sized gap between two cars. Unfortunately, the gener- alization of this explanation would then include the precon- dition that there be such a suitably-sized gap between some two cars-a precondition which for some future street-cros- sing can only be satisfied by reasoning about the path of po- tentially every car in the world over the time interval of the expected crossing! The basic problem is that standard expla- nation-based learning does not distinguish between planning decisions made prior to execution and those made during ex- ecution. After execution, an explanation may thus be con- structed using information which became available only dur- ing execution, yielding a generalization unlikely to be useful in future instances. Contingent explanation-based learning &es two main modifications to standard explanation-based learning. The first is the introduction of conjectured variabEes into the knowledge representation to enable reasoning about def- erred achievable goals. The second is the addition of a com- pletion step which incorporates completers into the general plan for the execution-time completion of the partial plans derived from the general plan. Conjectured Variables. Reactive plans involve deferred goals and hence plan parameters whose values are deter- mined during execution. For example, in a reactive plan for hammering a nail all the way into a wooden plank, the precise number of pounding actions needed is unknown prior to ex- ecution. However, an achievability proof can be constructed, as discussed in the section on proving achievability, which guarantees that there exists some number of pounding ac- tions which will achieve the goal. A planner must be able to recognize such plan parameters which have undetermined values prior to execution and whose values must be deter- mined during execution. Contingent EBL uses conjectured variables for this purpose. A conjectured variable is a plan- ner-posed existential used in place of a precise parameter value prior to execution, thus acting as a placeholder for the eventual value of a plan parameter. The integrity of an expla- nation containing conjectured variables hinges upon whether or not values can be found for the conjectured variables- hence the term contingent explanation-based learning. In the integrated approach, a planner is restricted to intro- ducing conjectured variables only if achievability proofs can be constructed for the associated deferred goals. In the class of problems involving continuously-changing processes and intermediate goal values, for example, the achievability proof warrants the introduction of a conjectured variable re- garding the end of the time interval at which the goal value for a particular continuously-changing quantity will be reached. Such a conjectured variable, supported by an ach- ievability proof, is called a valid conjectured variable. Only valid conjectured variables are allowed into the domain knowledge of a system in the integrated approach. Thus, a system may reason with conjectured variables only by rea- soning about their achievability as well. For example, in at- tempting to find a binding for the cup in a get-coffee problem during explanation, a system may explain the achievability of determining a precise cup during execution by reasoning about multiple opportunities. It may thus unify the cup with a valid conjectured variable which would have no a priori value but whose achievability is guaranteed by information available to the system before execution. By disallowing a system from unrestrainedly using conjectured variables to fi- nesse the problem of requiring an explanation grounded in 1018 ROBOTICS initial data, the provably-comt nature of explanations and their generalizations is preserved. Comoletors. The second modification made by contingent explanation-basedlearning involves the incorporation of ad- ditional operators called completers into the general plan. Completors are responsible for determining a completion to a reactive plan by finding appropriate values for conjectured variables during execution. Since only valid conjectured variables are allowed in the integrated approach, every con- jectured variable in a general plan will have an accompany- ing achievability proof in the generalized explanation. This proof provides the conditions supporting the introduction of the conjectured variable, which are used in constructing an appropriate completer. There are currently three types of completers, one for each of the three types of achievability proofs discussed earlier. It- erators perform a particular action repeatedly until some goal is achieved. Monitors observe a continuously-changing quantity to determine when a particular goal value for that quantity has been reached. Filters look for an object of a par- ticular type. The contingent explanation-based learning al- gorithm is summarized in Figure 3. Input training example and goal concept Construct an explanation for why the example is an example of the goal concept If an explanation is successfully constructed Then Generalize and construct a general plan using: the goal (root) the preconditions (leaves) determining applicability the sequence of operators achieving the goal Identify the conjectured variables in the generalized explanation. If there are conjectured variables Then For every conjectured variable Identify the conditions supporting the introduction of the variable in the generalized explanation. Construct an appropriate completer using these conditions and including the plan components with this variable. Add completer to the operators of the general plan. Output general completable reactive plan. Else Output general non-reactive plan. Else Signal FAILURE. Figure 3. Contingent EBL Algorithm. Example A system written in Common LISP and running on an IBM RT Model 125 implements the integrated approach to plan- ning and learning reactive operators. The system uses a sim- ple interval-based representation and borrows simple quali- tative reasoning concepts from Qualitative Process Theory [Forbus84]. The system is thus able to reason about quantity values at time points as well as quantity behaviors over time intervals. For example, (value (velocity spaceship) 65 10) represents the fact that the spaceship is traveling at 65 m/s at time lo), and (behavior (velocity spaceship) increasing (10 17)) represents the fact that the spaceship’s velocity was in- creasing fromtime 10 to 17). The system also uses amodified EGGS algorithm mooney86] in constructing and generaliz- ing contingent explanations. The system is given the task of learning how to achieve a particular goal velocity higher than some initial velocity- i.e. acceleration. The example presented to the system in- volves the acceleration of a spaceship froman initial velocity of 65 m/s at time 10 to the goal velocity of 100 m/s at time 17.1576, with a fue-rockets action executed at time 10 and a stop-fxe-rockets action executed at time 17.1576. In ex- plaining the example, the system uses an intermediate value rules for an increasing quantity (see Figure 1) to prove the achievability of the goal velocity. It determines that the fol- lowing conditions hold: 1) velocity increases continuously while the rockets are on, 2) if the rockets are on long enough, the maximum velocity of 500 m/s will be reached, and 3) the goal velocity of 100 m/s is between the initial velocity of 65 m/s and 500 m/s. There is thus some time interval over which the spaceship can be accelerated so as to achieve the goal. In this particular example, that time interval was (10 17.1576). The part of the explanation the system constructs regard- ing the achievement of the goal velocity at time 17.1576 is shown in Figure 4, together with its corresponding part in the generalized explanation. The general explanation yields a (value (vel ss 100.0 17.1576) -7&iZZZn 100.0 65.0 500.0) (value (vel ss) 65.0 10.0) (continuous (vel ss)) 1 \ (qual-beh (vel ss) incr (10.0 17.576)) (-> (qual-beh (vel ss) incr (10.0 T+INF) (value (vel ss) 500.0 T+INF)) I SPECIFIC (max-val (vel ss) 500.0) (moving ?ss ?v 1 (?st ?et)) . ,oit=sO ?vmax) (value (vel 33s) ?vO ?tl) (qual-beh (vel ?ss) incr (?tl !t)) \ (-> (qual-beh (vel ?ss) incr (?tl T+INF)) (value (vel ?ss) ?vmax T+INF)) I GENERAL (max-val (vel ?ss) ?vmax) Figure 4. Portions of reactive explanations. two-operator -fire-rockets and stop-fire-rockets-gener- al reactive plan. This plan contains the conjectured variable !t, which is the time the goal velocity is reached and the stop- fire-rockets action is performed. Using the conditions pro- vided by the achievability proof, a monitor operator is created for observing the increasing velocity during the ac- celeration process and indicating when the goal velocity is reached to trigger the stop-fire-rockets operator. GERVASIO 1019 The system is also run in a non-reactive (classical plan- ning) mode on the same example. Here, the system uses equations derived from the principle of the conservation of linear momentum in order to explain the achievement of the goal velocity. This involves reasoning about various quanti- ties, including the combustion rate of fuel and the velocity of the exhaust from the spaceship, in order to determine the ac- celeration rate. Corresponding portions regarding the achievement of the goal velocity at time 17.1576 in the spe- cific and general explanations are shown in Figure 5. The (spec-val (vel (exh ss)) (value (vel ?veh) ?vf &t2) GENERAL Figure 5. Portions of non-reactive explanations. general explanation yields a general non-reactive plan also involving a fire-rockets operator and a stop-fire rockets op- erator. However in this plan, the time at which the stop-fire- rockets action is performed is precomputed using some set of equations rather than determined during execution. Reactive vs. Non-Reactive Acceleration Plan Consider the performance of the system using the general reactive plan vs. using the general non-reactive plan. Given the problem of achieving a goal velocity of vffrom the initial velocity of vi at titne ti, the system may construct either a reactive plan fromthe general reactive plan or a non-reactive plan from the general non-reactive plan (Figure 6). In computing the time at which to stop the rocket-firing, the non-reactive plan assumes a constant exhaust velocity I Reactive Plan [ fire-rockets at time ti I monitor increasing velocity for the goal value of vf, binding !t to the time this value is reached stop-fire-rockets at time .ft ] Non-Reactive Plan [ fire-rockets at time ti vf-vi wait for time t = e VemeM-M given vi = velocity at time ti vf = goal velocity ve = relative exhaust velocity me= burn rate M = initial mass of spaceship stop-fire-rockets at time tf= ti + t ] Figure 6. Reactive vs. Non-Reactive Acceleration Plans. and burn rate. Provided the expected values are accurate, it will achieve the goal velocity. However, if the actual values differ, the spaceship may not reach or may surpass the goal velocity. Even small deviations from the expected values could have devastating effects if a plan involved many such a priori computations, through which errors could get propa- gated and amplified. In contrast, the reactive plan makes no assumptions regarding the exhaust velocity and bum rate, and instead uses execution-time information to determine when to stop firing the rockets. It is thus more likely to achieve the goal velocity regardless of such variations. For a classical planner to correctly compute when to stop the rockets, it would have to completely model the rocket- firing process-including the fuel-to-oxygen ratio, com- bustion chamber dimensions, nozzle geometry, material characteristics, and so on. This intractability is avoided in the integrated approach through the deferment of planning deci- sions and the utilization of execution-time information in ad- dressing deferred decisions. The integrated approach does have its own limitations. A planner in this approach incurs the additional cost of proving achievability as well as completing plans during execution. There may thus be cases in which this cost will be higher than the cost incurred by a classical planner, in which case com- plete a priori planning may provide the better solution. How- ever, there are many planning problems which involve par- ticular goals difficult to plan for prior to execution but easy to address during execution. Furthermore, these problems have simple achievability proofs which do not require the kind of real-world modeling likely to lead to intractability. Iu these problems, the integrated approach provides an at- tractive alternative to complete a priori reasoning. Discussion And Conclusions The integrated approach to planning presented in this paper is an attempt to solve the individual limitations of classical planning and reactive planning through an integration which augments a classical planner with the option of deferring achievable goals. Achievability proofs, which preserve the provably-correct nature of plans, are currently required to be 1020 ROBOTICS absolute. However, the real world is rarely certain, and an im- portant area for future research is that of probabilistic achiev- ability proofs. The completers incorporated into learned gen- eral plans are responsible for gathering information for plan completion during execution. The system currently has sim- ple completers with minimal mntime responsibilities. How- ever, the identification of other classes of problems and the consideration of probabilistic achievability proofs will prob- ably require more complicated completers with greater plan- ning responsibilities. Another area for future work is in the addition of some quantitative knowledge to the system’s rea- soning abilitites. This is expected to extend the applicability of the system to more complicated problems and allow for a more thorough study of learning general reactive plans. This work relates in different ways to other work in vari- ous research areas. The problems arising from imperfect a priori knowledge in classical planning was recognized as early as the STRIPS system, whose PLANEX component employed an execution algorithm which adapted predeter- mined plans to the execution environment Fikes72]. Later work such as [Wilkins881 further addresses the problem of execution monitoring and failure recovery. The integrated approach to planning presented in this paper currently moni- tors execution only to complete the partial plans constructed prior to execution. However any monitoring and failure re- covery capabilities applicable to a classical planner can also be incorporated into this approach. The idea of integrating a priori planning and reactivity has also been investigated in other work [Cohen89, Tumey89J. The work presented in this paper differs primarily in that it focuses on the integration of planning and execution within a single plan rather than the integration of the planning and execution of multiple plans. The contingent explanation-based learning algorithm pres- ented in this paper was developed to allow for the learning of general reactive plans for use in the integrated approach. Other work on learning to be reactive [Blythe89] has been on learning stimulus-response rules such as that used in reactive planning. The planning approach described in this paper presents an integration of classical planning and reactive planning which provides for the construction of completable reactive plans. By constraining the deferred goals to only those which can be proven achievable, the integrated approach preserves the provably-correct nature of plans. Also, by utilizing informa- tion gathered during execution in addressing the deferred planning decisions, the integrated approach provides for sen- sitivity to the runtime environment. Contingent explanation- based learning extends standard explanation-based learning to enable general reactive plans to be learned from observa- tion, by allowing a distinction to be made between planning decisions made prior to execution and those made during ex- ecution. The use of completable reactive plans simplifies a priori planning as well as reduces the reliance on perfect a priori information, and euables the construction of plans guaranteed to have successful completions. Acknowledgments. This work has benefited greatly from the comments and direction provided by my advisor, Gerald DeJong, and also fromthe many enlightening (and entertain- ing) discussions with Steve Chien, Scott Bennett, Jon Gratch, and Michael Barbehenn. References kk3=871 P Agre and D. Chapman, “Pengi: An Implementa- tion of a Theory of Activity,” Proceedings of the National Confer- ence on Artijkial Intelligence, Seattle, WA, July 1987. [Blythe89] J. Blythe and T. M. Mitchell, “On Becoming Reac- tive,” Proceedings of The Sixth International Workshop on Machine Learning, June 1989. [Chapman871 D. Chapman, “Planning for Conjunctive Goals,” Artificial Intelligence 32,3 ( 1987). [Chien89] S. A. Chien, “Using and Refining Simplifications: Explanation-based Learning of Plans in Intractable Domains,” Proceedings of The Eleventh International Joint Conference on Ar- tificial Intelligence, Detroit, MI, August 1989. [Cohen891 P R. Cohen, M. L. Greenberg, D. M. Hart and A. E. Howe, “Trial by Fire: Understanding the Design Requirements for Agents in Complex Environments,” Artificial Intelligence Maga- zine IO,3 (1989). [DeJong86] G. F. DeJong and R. J. Mooney, “Explanation- Based Learning: An Alternative View,” Machine Learning I, 2 (April 1986). [Fikes7 l] R. E. Fikes and N. J. Nilsson, “STRIPS: A New Ap- proach to the Application of Theorem Proving to ProblemSolving,” Artificial Intelligence 2,314 (197 1). [Fikes72] R. E. Fikes, P. E. Hart and N. J. Nilsson, “Learning and Executing Generalized Robot Plans,“Artifzcial Intelligence 3, 4 (1972). [Firby87] R. J. Firby, “An Investigation into Reactive Plan- ning in Complex Domains,” Proceedings of the National Confer- ence on Artificial Intelligence, Seattle, WA, July 1987. [Forbus84] K. D. Forbus, “Qualitative Process Theory,“Artifi- cial Intelligence 24, (1984). [Hammond861 K. Hammond, “Learning to Anticipate and Avoid Planning Failures through the Explanation of Failures,” Proceed- ings of the National Conference on Artijcial Intelligence, Philadel- phia, PA, August 1986. [Minton85] S. Minton, “Selectively Generalizing Plans for Pro- blem-Solving,” Proceedings of the Ninth International Joint Con- ference on Artificial Intelligence, Los Angeles, August 1985. [Mitchell861 T. M. Mitchell, R. Keller and S. Kedar-Cabelli, “Explanation-Based Generalization: A Unifying View,” Machine Learning I, 1 (January 1986). [Mooney861 R. J. Mooney and S. W. Bennett, “A Domain Inde- pendent Explanation-Based Generalizer,” Proceedings of the Na- tional Conference on Artificial Intelligence, Philadelphia, PA, Au- gust 1986. [Schoppers87] M. J. Schoppers, “Universal Plans for Reactive Ro- bots in Unpredictable Environments,” Proceedings of the Tenth In- ternationalJoint Conference on Artificial Intelligence, Milan, Italy, August 1987. [Shoham86] Y. Shoham, “Reasoning about Change: Time and Causation from the Standpoint of Artificial Intelligence,” PhD. Thesis, Yale University, Dept. of Computer Science, New Haven, CT, 1986. [StefikSl] M. Stefik, “Planning and Metaplanning (MOL- GEN: Part 2),“Artijkial Intelligence 16,2 (1981). [Suchman87] L. A. Suchman, Plans and Situated Actions, Cam- bridge University Press, Cambridge, 1987. [Turney89] J. Tumey and A. Segre, “SEPIA: An Experiment in 1ntegt;ated Planning and Improvisation,“Proceedings of TheAmer- ican Association for Artificial Intelligence Spring Symposium on Planning and Search, March 1989. [Wilkins881 D. E. Wilkins, Practical Planning: Extending the Classical Artificial Intelligence Planning Paradigm, Morgan Kaufman, San Mateo, CA, 1988. GERVASIO 102 1
|
1990
|
49
|
966
|
From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. System Architecture In a loosely coupled distributed system, an agent spends most of its cpu time in computation as op- posed to communication. Since theorem proving by nature is computationally intensive, we have chosen a loosely coupled implementation for our distributed the- orem prover. Each theorem prover agent spends most of its time performing binary resolution ‘, with the balance spent on problem assessment and communica- tion. Problem assessment helps determine what course of action to take next to further the proof locally. Com- munication between agents generally falls into one of the following categories: (i) a request is sent to one or more agents for information; (ii) an agent returns information in response to a request. The architecture for our theorem proving agent has been tailored to suit the characteristics of the prob- lem solving environment mentioned above (i.e. loosely coupled, multiple concurrent tasks). The architecture of a single theorem proving agent is composed of sev- eral processes attached to a communications network. The problem solving system is then comprised of sev- eral nodes, each having this agent architecture. In each agent there is one mail process, and the remaining pro- cesses are each associated with a distinct problem solv- ing activity. Each process in an agent has equal pri- ority and active processes compete for cpu time in a round robin fashion. Under normal circumstances, ev- ery theorem prover process is active. The mail process is typically in a wait state and becomes active when new mail is received via the communications channel. Each theorem prover process in an agent has its own environment and is associated with one automated rea- soning task identified by a unique tag. Theorem prover processes working on the same reasoning task in dif- ferent agents throughout the network bear the same tag. In addition, no two theorem prover processes for a given agent may work on the same theorem. It need not be the case that every agent works on every theo- rem. Distributed Theorem Proving Strategies As is the case with single agent theorem provers, dis- tributed theorem proving exhibits exponential behav- ior. It turns out, however, that some of the strate- gies used in classical theorem proving to help mini- mize the number of resolvents generated can also be used in the distributed case to reduce the content of in- formation exchanged between agents. Development of ‘The binary resolution performed by each agent in DARES uses a tautology and subsumption reduction strat- egy to minimize the number of resolvents generated, and it uses the set of support strategy to limit its search space. Furthermore, the set of resolvents generated by each level of resolution is sorted by length, so that shorter clauses are resolved first during the next level. these of strategies is essential, since the performance of distributed theorem proving can be greatly enhanced by them. If the computational effort in replying to a request is significant, it may have not been worth making the request in the first place. Similarly, in information-intensive domains requests that receive a bombardment of replies can be counterproductive. Figure 1 is a flow diagram which depicts a high level view of our approach to distributed theorem proving. DARES is based on a traditional saturation level type theorem prover. It uncertain I Terminate Figure I: Distributed automated reasoning flow di+ gram. We have previously noted that in our distributed en- vironment no one agent can achieve the task at hand by itself. Therefore, we do not terminate the resolu- tion process simply because the current resolution level has failed to generate new resolvents. In fact, reaching this point triggers a theorem prover agent to attempt to import relevant information from other agents as shown in Figure 1. If an agent is successful in im- porting new knowledge, the resolution process contin- ues. Otherwise the distributed theorem proving pro- CONRYETAL. 79 cess terminates with no conclusion being drawn about the current theorem. It is not sufficient just to wait for local resolution to halt prior to importing new knowledge, since me- chanical theorem proving in general may not termi- nate when dealing with incomplete knowledge. There- fore, as shown in Figure 1, our system must evaluate whether or not progress is being made locally towards a solution. The Forward Progress test is made at the conclusion of each resolution level to heuristically de- termine whether the proof has advanced towards a NIL resolvent. This test cannot give a definitive answer. It can only say ‘Yes, progress has been made,” or that it “does not know.” On this basis, local resolution moves to the next level only if the Forward Progress test con- cludes that progress has been made. Otherwise, non- local knowledge is imported just as if the current level had failed to produce new resolvents. Forward Progress Heuristic Given a negated theorem and a set of axioms that is adequate for establishing that theorem, a single agent with complete knowledge will, given enough time, eventually determine that the theorem is valid by producing a NIL resolvent . However, when the same axiom set and theorem are distributed over several agents, it is possible that no agent will have sufficient local knowledge to establish the result. It is therefore possible for each agent under this circumstance, with- out a Forward Progress heuristic, to perform resolution forever and not prove a theorem that conventional sys- tems have no difficulty in proving. The purpose of our Forward Progress heuristic is to guarantee that no agent in our system will enter a mode in which it can perform resolution forever, with- out eventually attempting to import nonlocal knowl- edge that may lead to an inconsistency. This safeguard gives DARES the ability to prove any theorem that conventional systems can prove given the same set of global system knowledge. What the Forward Progress heuristic does not do is to give DARES any advantage over the single agent case when the single agent is faced with nontermination. When it is apparent that an agent is not progress- ing, the Forward Progress heuristic triggers the impor- tation of nonlocal information in order to increase the agent’s knowledge relative to the task at hand. Experi- mental data indicate that this heuristic does indeed en- hance system performance, even when a DARES agent is not faced with nontermination. In defining the Forward Progress heuristic, we make use of two related heuristics: the Proof Advancing heuristic and the Monotonic Search heuristic. The Proof Advancing heuristic is the component of the For- ward Progress heuristic which is used to detect local advancement. This heuristic either detects advance- ment, or is uncertain whether or not the proof is ad- vancing. The Monotonic Search heuristic is the mech- anism that the Forward Progress heuristic relies upon if uncertainty about proof advancement persists. The Proof Advancing heutistic is determined at each level of resolution by examination of the newly gener- ated resolvents. A resolvent R is said to be advancing the proof if (a) given two clauses C and D with lit- eral length c and d respectively, the clause length P of R is less than (c + d) - 2, Or (b) R is a single literal, Or (c) R was generated from a single literal clause. If any resolvent generated at saturation level i advances the proof, then we say the Proof Advancing heuristic is satisfied at level i. In general, when two clauses are resolved using bi- nary resolution, the resolvents will always have length no greater than the sum of the lengths of the two par- ent clauses, minus the two literals which are consumed by the resolution process. Condition (a) in the Proof Advancing heuristic considers a proof to be advancing whenever a resolvent is generated with length less than this upper bound. Conditions (b) and (c) in the Proof Advancing heuristic definition recognize that some re- solvents are desirable even though their length equals the upper bound. For example, when a single literal clause C is resolved with clause D of length n, the re- solventhaslengthc+d-2=1+n-2=n-1. The importance of these resolvents are recognized by the Unit Preference [ll] strategy. Whenever condition (a), (b), and/or (c) occurs dur- ing resolution, the proof is considered to be advancing. If none of these occur, we do not know if the proof is making progress. If it is not clear whether or not a proof is advancing, and this uncertainty persists, some mechanism for forcing a knowledge request is required. This is where the Monotonic Search heuristic comes into play. The Monotonic Search heuristic is defined as follows: Let CY,, be the total number of distinct predicate sym- bols found in the set of newly generated resolvents at saturation level n. The search for a proof is said to be monotonic at level i if for i > 1, cyi-1 > cyi. The Forward Progress heuristic is used to detect an apparent lack of forward progress in the proof. This lack of progress is defined in terms of the Proof Ad- vancing and Monotonic Search heuristics. A proof is said to exhibit an apparent lack of forward progress at saturation level i if (1) the Proof Ad vancing heuristic is not sat- isfied at saturation level i - 1, -a (2) the Proof Ad vancing heuristic is not sat- isfied at saturation level i, ana (3) th e search is not monotonic at level i. 80 AUTOMATED REASONING The Forward Progress heuristic guarantees that if proof advancement is uncertain and the number of predicate symbols is nondecreasing in successive levels of resolution, a knowledge request is made. (When- ever the number of predicate symbols is a decreasing function in successive levels of resolution, the number of predicate symbols must eventually shrink to zero. If this situation occurs, it will be detected by the Neut Resolvents test (refer to Figure l), since a scenario in- volving zero predicate symbols can only occur if the current level of resolution fails to generate new resol- vents.) Priority Set In our environment, when an agent has reached a point where it is evident that new information must be ac- quired in order to continue problem solving, it formu- lates a Priority Set P. Definition A Priority Set P has the form P = (Cl, .“, Cn} where each Ci for 0 < i s n is a clause heuristically determined to have a high likelihood of furthering the proof towards a NIL resolvent. P is said to have length n, where n is the number of clauses in P. The heuristic we use to determine the likelihood of a clause extracts some ideas found in two conventional resolution strategies: Set of Support [12] and Unit Pref- erence [ll]. However, our heuristic is more than just a combination of these two strategies. Our importation heuristic determines a likelihood that a clause will be relevant in furthering a proof towards a NIL resolvent. This heuristic is based on clause length and clause an- cestry. Clauses whose ancestry do not lead back to the negated theorem have no likelihood and are assigned the value of 0. Clauses having an ancestry link to the negated theorem have a likelihood whose value is the reciprocal of the clause length. Single literal clauses with a negated theorem ancestry have the maximum likelihood of 1. As a first cut in distributed theorem proving, one could simply form the Priority Set P using all clauses possessing maximum likelihood. Then P could be sent to all agents, with each agent being requested to return any clause that can resolve with one or more members in P. Unfortunately, P could potentially be large, re- quiring significant processing on behalf of each agent receiving the request. A better strategy would be to first remove any clause in P which is subsumed by an- other clause in P, as any reduction in the size of P reduces the overhead other agents incur while process- ing the request. Though use of subsumption in this way reduces the size of P, it still has the potential of being relatively large. An alternative approach makes use of a Mini- mal Literal Set &in derived from P that is defined as follows: Definition Let each clause Ci in a Priority Set P of length n be of the form Ci = (&I, . . . . &,} where Lij is a literal, and: 1. 15 i< n; 2. m > 0 and is the number of literals in clause 2. 3. ;‘~jpni. Then the Priority Litercrl Set L is defined to be the union of literals found in clauses Cl, . . . . Cn and has the formL=ClU...UC,. Definition Given L, the Priority Literal Set for P = {Cl, . . . . C,), we define Lnrin, the Minimum Ptiority Literal Set for P as follows: L min = L - L’, where L’ = {Ljk E L 1 there is a literal Lpq in L, such that Ljk is subsumed by L,,}. After computing the Minimal Priority Literal Set L min from the Priority Set P, the agent could trans lllit Lmin to other agents and request knowledge about clauses they may have that resolve with one or more literals in L&n. If this were done, an agent respond- ing to this request would then systematically attempt to perform resolution with each literal in Lmin against its local clause set, complementing each Lmin literal and attempting to unify it with a literal in each of its local clauses. Recognizing this fact, in an attempt to minimize the effort of an agent replying to a request, the requesting agent complements each literal in Lmin prior to making the request. We call the resulting set the Minimum Priority Negated Literal Set and define it as follows: Definition Given a Minimum Priority Literal Set Lmin = {Qi, . . ..&..,I of length n, where each Qi is a literal for 0 < i 5 n, then the Minimum Prior- ity Negated Literal Set NLmin has the form NLmin = (RI, . . . . &}, where each & = l&i for 0 < i 5 n. After computing the Minimal Priority Negated Lit- eral Set NLmin from the Priority Set P, the agent transmits NLmin to other agents and requests knowl- edge about clauses they may have that unify with one or more literals in NLmin. Up to now we have concentrated on explaining how an agent determines when a request needs to be made, and how it formulates the content of the request. We have said nothing about what happens if the first at- tempt to import knowledge fails, nor have we given much insight into the procedure followed by an agent replying to the request. The first thing the requesting agent does is to deter- mine the range of likelihoods possible for its clause set. Beginning with the clauses having highest likelihood, the agent computes its Minimum Literal Priority Set and broadcasts a request based on this set. This set is a function of likelihood (NLmin(Z)). If the request based on maximum likelihood fails to import nonlo- cal knowledge, the likelihood constraint is relaxed to its next possible value and the agent makes another request. This process continues until the requesting agent is successful in importing knowledge, or the agent has exhausted its clause set. CONRYETAL. 81 We have found that it is beneficial for agents reply- ing to knowledge requests to also incorporate a like- lihood dependency. When an agent makes a request with a high likelihood, the knowledge requested is spe- cific in nature and it should receive information back which is also relatively specific. As requests are made based upon lower likelihoods, we have observed that the requested information encompasses a wider spec- trum and is more general in nature. In DARES, we have incorporated a simple strategy into request processing which links the likelihood of a request to the scope of the search space that an agent considers when making its reply. We require that the likelihood I, used to formulate M&in(Z), be used to determine which clauses in a theorem prover’s envi- ronment are to be considered when evaluating the re- quest. In order for a clause to be deemed a candidate for consideration, it must have length no greater than the maximum length of any clause found in the Priority Set used to generate NL,i,(l). When a clause satisfies the requirements of the re- quest, it is tagged to be considered later as part of the reply. The significance of tagging potential clauses during the unification process is twofold: once a clause is tagged, it is never again considered when subsequent requests are made by the same agent with respect to the current theorem under investigation. Secondly, subsumption is used among the tagged clauses to min- imize what is returned to the requesting agent. This tagging mechanism helps avoid redundancy in what is returned in response to subsequent requests. In addi- tion, tagging can be viewed as an aggregation of knowl- edge about other agents’ activities (not unlike the be- havior evident in the scientific community metaphor [3, 4, 5, 9]), although DARES makes no specific use of this information at this time. Experimental Results There are three key issues which have been addressed in our experiments using DARES. They are: 1. 2. 3. How is DARES’ problem solving behavior affected as the number of active agents is varied? How are anomalies in system behavior which result from particular knowledge distributions minimized, so that DARES’ automated reasoning behavior is not misconstrued? What affect does the amount of shared knowledge throughout the network have on system perfor- mance? In order to measure the amount of shared knowl- edge among agents in a distributed reasoning network, we introduce the notion of a relevant csziom and the Redundancy Factor. Very simply, an axiom is considered relevant if it can be used in some proof of the current reasoning task. If S is a clause set and P a logical consequence of S, then in general there may be more than one subset of S from which P can be deduced. We do not address this issue here. Instead, we presume that each and every clause in S is required in order to derive P. The Redundancy Factor (R) of a network is a global measure of the amount of relevant knowledge shared among the agents. When no relevant knowledge is shared between agents, the Redundancy Factor is 0. When every agent has complete relevant knowledge the network Redundancy Factor is 1. For distributions falling within these boundaries, we define the Redun- dancy Factor to be: where k = number of active agents N = number of relevant-axioms for the reasoning task C = f n&i = number of local axioms known to agent i R = is the Redundancy Factor Each of our experiments corresponds to one dis- tributed reasoning task. For every experiment, data is collected over a wide range of values for each sys- tem parameter. As these parameters are varied, each new run begins with a different random distribution of knowledge for the same task. For each distribu- tion, there are three constraints that must be met. First, each active agent must initially be given at least one axiom. Secondly, multiple copies of an ax- iom are not permitted in an agent’s local environment. (But n copies of an axiom may exist across several agents.) Lastly, the total number of axioms distributed throughout the system must equal the number speci- fied by the current Redundancy Factor. There are two data collection txsrameters in each ex- periment: k and r. Parameter-k corresponds to the number of agents actively engaged in the reasoning task, and r is the Redundancy Factor. Given a the- orem to prove which is comprised of M axioms and N negated theorem clauses, the experiment is done utiliz- ing k agents, where k is -varied between 1 and M. For each value of k, the knowledge distribution is varied between 0 and 100% Redundancy. We minimize the effects that a particular knowledge distribution has on general behavior, by performing many passes at a given data point (k, r), with each pass having a different distribution. Likewise, the be- havioral characteristics of DARES can be determined by performing many different experiments, where each experiment is based on a unique automated reasoning task. In fact, this has been done. The results pre- sented here are based upon analysis of many different experiments. The figures incorporated in this paper reflect the results from one experiment as a vehicle for demonstrating DARES’ distributed automated reason- ing behavior. 82 AUTOMATEDREASONING The performance characteristics for a typical exper- iment are given in Figure 2. These characteristics are normalized to the nondistributed case, in which a sin- gle agent performs the complete reasoning task alone. The two system parameters for DARES:’ data col- lection experiment, k and r, correspond to the UNum- ber of Agents” and “Redundancy Factor” axes in Fig- ure 2, respectively. Since DARES performs distributed automated reasoning approximately one order of mag- nitude faster than its nondistributed counterpart, we have taken the natural log of the elapsed time data for the experiment. Furthermore, we have normalized this data so that the single agent case has a value of unity. The Redundancy Factor axis has been scaled by a factor of 10 for legibility. In general, when there is a very high level of re- dundancy among the agent’s local knowledge, DARES’ runtime rapidly begins to approach that of the single agent. This behavior can be attributed to a very low interaction rate among agents, since each agent has sufficient local knowledge to advance the proof to near completion. The Forward Progress heuristic detects this advancement and does not initiate any knowledge importation requests. Instead, local advancement con- tinues until resolution fails to generate any new resol- vents. It is at this point that a knowledge request is made to import nonlocal information. We observe that requests made in high redundancy environments tend to be very specific in nature, since an agent has advanced the proof nearly to completion prior to making the request. We have also observed that when a request of this sort is made, the knowl- edge sought is readily available in the network. This is a direct consequence of the other agents having near complete knowledge, and of the fact that they have had ample time to advance their local efforts. In general, we find that as the number of agents in a network increases, replies to knowledge requests tend to have better informational content. This relation- ship between network size and reply content is a di- rect consequence of simply having more agents in the network to query, each agent having a different local perspective derived from its differing initial knowledge distribution. In Figure 2 the effect of this relationship is evident in the high redundancy areas. Note that as the number of agents increases, the slope associ- ated with the rapid approach towards the single agent case becomes steeper and the width of these peaks de- creases. Figure 2 also suggests that performing distributed theorem proving is best done by many agents possess- ing little redundancy. In this situation, each agent can be viewed as a specialist. At the start of the distributed theorem proving process, each agent advances its part of the proof as far as it can before making a knowl- edge request. At the time such a request is made, the agent has begun to concentrate its efforts on its local advancement and imports knowledge relative to this acquired focus. Since redundancy is low, we see the agents becoming specialized in different areas, which reduces search space overlap between agents and leads to enhanced system performance. Although system performance is best with many agents in a low redundancy environment, there is only a small increase in system performance as the num- ber of agents is increased. What we see happening as network size becomes larger, is that initial knowl- edge importation requests occur earlier. These re- quests are based on less local effort and are more gen- eral in nature, thus leading to the initial importation of larger volumes of knowledge. Therefore, agents in smaller networks acquire a focus sooner than agents in larger networks. However, as the distributed effort nears completion, we see larger networks outperform- ing smaller ones, since requested information near the end of the proof is more readily available in larger net- works due to network size and the local efforts of more agents. It appears that the performance of larger net- works near the end of the proof is sufficient to offset the advantage smaller networks have at the start, thus we see a slight improvement in system performance as network size increases. The behavioral characteristics displayed in Figure 2 reflect DARES’ general runtime characteristics. This surface plot was generated from data recorded by DARES and represents the average value of all passes made for each data point. The validity of our conclu- sions is supported by a comparison of the characteris- tics of both the lower and upper bound surfaces. These surfaces are shown in Figures 3 and 4 respectively. The lower bound characteristic surface is a plot of the minimum runtime over all passes made for a given data point. Note that there are no major discrepancies in the plateau regions between the general and mini- mum surfaces. In fact, the smoothness of the plateau in the average value surface suggests that we have in- deed minimized dependencies associated with particu- lar distributions. The upper bound characteristic surface shown in Figure 4 is a plot of the maximum of all runtimes recorded by DARES for a given data point. This plot also has (to a limited degree) the same general shape as the average time characteristic surface in Figure 2. Rowever, the most notable feature of this surface is that it is very spiked. This is a demonstration of how sensitive distributed automated reasoning is to its knowledge distribution. Each one of the peaks (spikes) represents reduced system performance directly related to the knowledge distribution used. There are two important observations to be made with respect to the upper bound surface: First, since its overall shape is basically that of the average time surface, we have further evidence supporting the hy- pothesis that the average time characteristics do rep resent those of general behavior; Secondly, the noise in this plot indicates how a relatively poor distribution CONRYETAL. 83 can affect system performance. But more importantly, it demonstrates that DARES in its worst case environ- ment performs automated reasoning at a reasonable rate relative to the that of the nondistributed case. Concluding Remarks In this paper, we have described DARES, our dis- tributed automated reasoning system. Experiments with DARES have provided us with enhanced insight into the role of knowledge in distributed problem solv- ing. We have seen cases in which performance can be very sensitive to initial knowledge distribution, but the average case statistics indicate that one must be un- lucky to encounter such a distribution when knowledge is randomly distributed. More importantly, the experimental results we have presented demonstrate that agents in a loosely cou- pled network of problem solvers can work semi- inflq=enrlentlv vd. f&i~s their at.t.fmt.inn wjt;h_ the &d a&A-Y YYYYAAY’J, J VY -“~~-“~-I of relatively simple heuristics when cooperation is ap- propriate. These results suggest that we have devel- oped an effective cooperation strategy which is iargeiy independent of initial knowledge distribution. DARES has been implemented in a distributed testbed facility, SIMULACT [6], that runs on a net- work of Lisp machines. SIMULACT has provided a --13 1-- -A------ ---A - _I well mwrumentea environment in which appiications of this kind are easily developed and maintained. A number of additional experiments have been performed using DARES [7], but discussion of these experiments is beyond the scope of this paper. References [l] P. E. Allen, S. Bose, E. M. Clarke, and S. Michaylov. PARTHENON: A parallel theorem prover for non-horn clauses. In 9th International Conference on Automated Deduction, pages 764- 765. Springer-Verlag, May 1988. [2] M. P. Cline. A Fast Parallel Algorithm for N-ary Unification with AI. Applications. PhD thesis, Clarkson University, Potsdam, NY 13676, April 1989. [3] M. S. Fox. An organizational view of distributed systems. IEEE Transactions on Systems, Man, and Cybernetics, SMC-1 l( 1):70-80, January 1981. [4] W. A. Kornfeld and C. E. Hewitt. The scientific communitv metanhnr. IEEl? 7hnrnctinnc on SW- -----------J ----1- r---- - -.-v-L-------L -_- -*L terns, Man, and Cybernetics, SMC-ll( 1):24-33, January 1981. [5] V. R. Lesser and D. D. Corkill. Functionally ac- curate, cooperative distributed systems. IEEE %“a aA ,J:s.l. s. A” @..!..,4,, a RI” , 1m J /T.a,L- ar.‘,, A 1 ulcocb~o~uILa VW ilyJocllc3, A.4 c&w, Ul‘U vyvcr WC&6CO) SMC-11(1):81-96, January 1981. [G] De J. Ma.rTnt.nsh ad C. F. Cnnrv. SIMT_TT,-A-C!‘I’: -A_ -- -.--------L-- --- L. 2. d’-‘d. generic tool for simulating distributed systems. In Proceedinos of the Eastern Simulation Conference. 1’71 PI 191 WI Pll WI pages 18-23, Orlando, Florida, April 1987. The Society for Computer Simulation. (also available as NA,IC Technical Report TR-8713). D. J. Macintosh. Distributed Automated Reason- ing: The Role of Knowledge in Distributed Prob- lem Solving. PhD thesis, Clarkson University, Potsdam, NY 13699, December 1989. J. A. Robinson. A machine-oriented logic based on the resolution principle. Journal of the As- sociation for Computing Machineq, 12(1):23-41, January 1965. R. G. Smith and R. Davis. Frameworks for co- operation in distributed problem solving. IEEE Transactions on Systems, Man, and Cybernetics, SMC-11(1):61-70, January 1981. L. Wos. Automated Reasoning: .93 Basic Research Problems. Prentice-Hall, Engelwood Cliffs, NJ., 1 QQQ A”““. L. Wos, R. Overbeek, E. Lusk, and J. Boyle. Auto- mated Reasoning: Introduction and Applications. Prentice-Hall, Engelwood Cliffs, NJ ., 1984. L. Wos and G. A. Robinson. Paramodulation and set of support. In Proceedings of the IRIA Sym- posium on Automatic Demonstration, pages 267- $10 cnr;rrrr*r-Vcrrlar 1 Q&Q . "yIIIIBN.a- . bArrug, A""". CONRYETAL. 85
|
1990
|
5
|
967
|
Integrating Execution, Planning, and Learning in Soar for External Environments* John E. Laird Artificial Intelligence Laboratory The University of Michigan 1101 Beal Ave. Ann Arbor, MI 48109-2110 laird@caen.engin.umich.edu Abstract Three key components of an autonomous intelli- gent system are planning, execution, and learning. This paper describes how the Soar architecture supports planning, execution, and learning in un- predictable and dynamic environments. The tight integration of these components provides reactive execution, hierarchical execution, interruption, on demand planning, and the conversion of deliber- ate planning to reaction. These capabilities are demonstrated on two robotic systems controlled by Soar, one using a Puma robot arm and an overhead camera, the second using a small mobile robot with an arm. Introduction The architecture of an intelligent agent that interacts with an external environment has often been decom- posed into a set of cooperating processes including planning, execution and learning. Few AI systems since STRIPS [Fikes e2 al., 19721 have included all of these processes. Instead, the emphasis has often been on individual components, or pairs of compo- nents, such as planning and execution, or planning and learning. Recently, a few systems have been im- plemented that incorporate planning, execution, and learning [Blythe & Mitchell, 1989; Hammond, 1989; Langley et al., 19891. Soar [Laird et al., 19871 is one such system. It tightly couples problem solving and learning in every task it attempts to execute. Problem solving is used to find a solution path, which the learning mechanism gener- alizes and stores as a plan in long-term memory. The generalized plan can then be retrieved and used during execution of the task (or on later problems). This ba- sic approach has been demonstrated in Soar on a large number of tasks [Rosenbloom et ai., 19901; however, all of these demonstrations are essentially internal - both planning and execution occur completely within *This research was sponsored by grant NCC2-517 from NASA Ames and ONR grant N00014-88-K-0554. 1022 ROBOTICS Paul S. Rosenbloom Information Sciences Institute University of Southern California 4676 Admiralty Way Marina de1 Rey, CA 90292 rosenbloom@isi.edu the scope of the system. Thus they do not involve di- rect execution in a real external environment and they safely ignore many of the issues inherent to such envi- ronments. Recently, Soar has been extended so that it can in- teract with external environments [Laird et al., 1990b]. What may be surprising is that Soar’s basic structure already supports many of the capabilities necessary to interact with external environments - reactive execu- tion, hierarchical execution, interruption, on demand planning, and the conversion of deliberate planning to reaction. In this paper, we present the integrated approach to planning, execution, and learning embodied by the Soar architecture. We focus on the aspects of Soar that support effective performance in unpredictable en- vironments in which perception can be uncertain and incomplete. Soar’s approach to interaction with ex- ternal environments is distinguished by the following three characteristics: Planning and execution share the same architecture and knowledge bases. This provides strong con- straints on the design of the architecture - the reac- tive capabilities required by execution must also be adequate for planning - and eliminates the need to explicitly transfer knowledge between planning and execution. External actions can be controlled at three levels, from high-speed reflexes, to deliberate selection, to unrestricted planning and problem solving. Learning automatically converts planning activity into control knowledge and reflexes for reactive exe- cution. Throughout this presentation we demonstrate these capabilities using two systems. The first is called Robo- Sour [Laird et al., 1989; Laird et al., 199Oa]. Robo-Soar controls a Puma robot arm using a camera vision sys- tem as shown in Figure 1. The vision system provides the position and orientation of blocks in the robot’s work area, as well as the status of a trouble light. Robo-Soar’s task is to align blocks in its work area, unless the light goes on, in which case it must immedi- From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. SOAR I Figure 1: Robo-Soar system architecture. ately push a button. The environment for Rob&oar is unpredictable becaqse the light can go on at any time, and an outside agent may intervene at any time by moving blocks in the work area, either helping or hindering Robo-Soar’s efforts to align the blocks. In addition, Robo-Soar’s perception of the environment is incomplete because the robot arm occludes the vi- sion system while a block is being grasped. There is no feedback as to whether a block has been picked up until the arm is moved out of the work area. The second system, called Hero-Soar, controls a Hero 2000 robot. The Hero 2000 is a mobile robot with an arm for picking up objects and sonar sensors for detecting objects in the environment. Hero-Soar’s task is to pick up cups and deposit them in a waste basket. Our initial demonstrations of Soar will use Robo-Soar. At the end of the paper we will return to Hero-Soar and describe it more fully. Execution In Soar, all deliberate activity takes place within the context of goals or subgoals. A goal (or subgoal) is at- tempted by selecting and applying operators to trans- form an initial state into intermediate states until a desired state of the goal is reached. For Robo-Soar, one goal that arises is to align the blocks in the work area. A subgoal is to align a pair of blocks. Within a goal, the first decision is the selection of a problem space. The problem space determines the set of oper- ators that are available in a goal. In Robo-Soar, the problem space for manipulating the arm consists of op- erators such as open-gripper and move-gripper. The second decision selects the initial state of the problem space. For goals requiring interaction with an external environment, the states include data from the system sensors, as well as internally computed elabora- tions of this data. In Robo-Soar, the states include the position and orientation of all visible blocks and the gripper, their relative positions, and hypotheses about the positions of occluded blocks. Once the initial state is selected, decisions are made to select operators, one after another, until the goal is achieved. Every decision made by Soar, be it to select a prob- lem space, initial state, or operator for a goal, is based on preferences retrieved from Soar’s long-term produc- tion memory. A preference is an absolute or relative statement of the worth of a specific object for a spe- cific decision. The simplest preference, called uccept- able, means that an object should be considered for a decision. Other preferences help distinguish between the acceptable objects. For example, a preference in Robo-Soar might be that it is better to select operator move-gripper than operator close-gripper. A preference is only considered for a decision if it has been retrieved from the long-term production memory. Productions are continually matched against a work- ing memory - which contains the active goals and their associated problem spaces, states, and operators - and when matched, create preferences for specific decisions. For example, a production in Robo-Soar that proposes the close-gripper operator might be: If the problem space is robot-arm and the gripper is open and surrounds a block then create an acceptable preference for the close gripper operator. Once an operator is proposed with an acceptable preference, it becomes a candidate for selection. The selection of operators is controlled by productions that create preferences for candidate operators. For exam- ple, the following production prefers opening the grip- per over moving a block that is in place. If the goal is to move block A next to block B and the problem space is robot-arm and block A is next to block B and the gripper is closed and surrounds block A then create a preference that opening the gripper is better than withdrawing the gripper. Arbitrary control knowledge can be encoding as pro- ductions so that Soar is not constrained to any fixed method. The exact method is a result of a synthesis of all available control knowledge [Laird et al., 19861. Soar’s production memory is unusual in that it fires all matched production instantiations in parallel, and it retracts the actions of production instantiations that no longer match, as in a JTMS [Doyle, 19791.’ Thus, ‘Retraction in Soar was introduced in version 5. Earlier versions ofSoar did not, retract the actions of productions. LAIRD ANDROSENBLOOM 1023 Problem space: Puma Arm Problem space: Selection Problem space: Puma Arm Problem space: Selection Figure 2: Example of planning in Robo-Soar to move a block. Squares represent states, while horizontal arcs represent operator applications. Downward pointing arcs are used to represent the creation of subgoals, and upward pointing arcs represent the termination of subgoals and the creation of results. sufficient preferences have been created to allow the decision procedure to make a single choice, the sub- goal is automatically terminated and the appropriate selection is made. If there is more than a single point of indecision on the path to the goal, then it is necessary to create a longer term plan. If other decisions are underdeter- mined, then they will also lead to impasses and as- sociated subgoals during the look-ahead search. The result is a recursive application of the planning strat- egy to each decision in the search where the current knowledge is insufficient. Figure 2 shows a trace of the problem solving for Robo-Soar as it does look-ahead for moving a single block. At the left of the figure, the system is faced with an indecision as to which Puma command should used first. In the ensuing impasse, it performs a look- ahead search to find a sequence of Puma commands that pickup and move the block. Because of the size of the search space, Robo-Soar uses guidance from a human to determine which operators it should evalu- ate first [Laird et al., 19891. When a solution is found, preferences are created to make each of the decisions that required a subgoal, such as best(approach) and best (move-above) in the figure. Unfortunately, these preferences cannot directly serve as a plan because they are associated with specific planning subgoals that were created for the look-ahead search. These prefer- ences are removed from working memory when their associated subgoals are terminated. At this point, Soar’s learning mechanism, called chunkring, comes into play to preserve the control knowledge that was produced in the subgoals. Chunk- 1024 ROBOTICS ing is based on the observation that: (1) an impasse arises because of a lack of directly available knowledge, and (2) problem solving in the associated subgoal pro- duces new information that is available to resolve the impasse. Chunking caches the processing of the sub- goal by creating a production whose actions recreate the results of the subgoal. The conditions of the pro- duction are based on those working-memory elements in parent goals that were tested by productions in the subgoal and found necessary to produce the results. This is a process very similar to explanation-based learning [Rosenbloom & Laird, 19861. When chunking is used in conjunction with the planning scheme described above, Rob&oar learns new productions that create preferences for operators. Since the preferences were created by a search for a solution to the task, the new productions include all of the relevant tests of the current situation that are necessary to achieve the task. Chunking creates new productions not only for the original operator decision, but also for each decision that had an impasse in a sub- goal. As a result, productions are learned that create sufficient preferences for making each decision along the path to the goal. Once the original impasse is re- solved, the productions learned during planning will apply, creating sufficient preferences to select each op- erator on the path to the goal. This is shown in Figure 2 as the straight line of operator applications across the top of figure after the planning is complete. In Robo-Soar, the productions learned for aligning blocks are very general. They ignore all of the details of the specific blocks because the planning was done using a abstract problem space. Similarly, the productions preferences and working memory elements exist only when they are relevant to the current situation as dic- tated by the conditions of the productions that created them. For example, there may be many productions that create preferences under different situations for a given operator. Once the relevant preferences have been created by productions, a fixed decision procedure uses the pref- erences created by productions to select the current problem space, the initial state, and operators. The decision procedure is invoked when Soar’s production memory reaches quiescence, that is, when there are no new changes to working memory. Once an operator is selected, productions sensitive to that operator can fire to implement the operator’s actions. Operator implementation productions do not retract their actions when they no longer match. By nature they make changes to the state that must per- sist until explicitly changed by other operators. For an internal operator, the productions modify the cur- rent state. For an operator involving interaction with an external environment, the productions augment the current state with appropriate motor commands. The Soar architecture detects these augmentations and sends them directly to the robot controller. For both internal and external operators, there is an additional production that tests that the operator was success- fully applied and signals that the operator has termi- nated so that a new operator can be selected. The exact nature of the test is dependent on the operator and may involve testing both internal data structures and feedback from sensors. At this point, the basic execution level of Soar has been defined. This differs from the execution level of most systems in that each control decision is made through the run-time integration of long-term knowl- edge. Most planning systems build a plan, and follow it step by step, never opening up the individual decisions to global long-term knowled ‘i e. Other “reactive” learn- ing systems, such as Theo Blythe & Mitchell, 1989; Mitchell et al., 19901 and Schoppers’ Universal plans [Schoppers, 1986] create stimulus-response rules that do not allow the integration at run-time of control knowledge. Soar extends this notion of run-time com- bination to its operator implementations as well, so that an operator is not defined declaratively as in STRIPS. This will be expanded later to include both more reflexive and more deliberate execution. Planning In Soar, operator selection is the basic control act for which planning can provide additional knowledge. For situations in which Soar has sufficient knowledge, the preferences created for each operator decision will lead to the selection of a single operator. Once the oper- ator is selected, productions will apply it by making appropriate changes to the state. However, for many situations, the knowledge encoded as productions will be incomplete or inconsistent. We call such an un- derdetermined decision an impasse. For example, an impasse will arise when the preferences for selecting operators do not suggest a unique best choice. The Soar architecture detects impasses and automatically creates subgoals to determine the best choice. Within a subgoal, Soar once again casts the problem within a problem space, but this time the goal is to deter- mine which operator to select. Within the subgoal, additional impasses may arise, leading to a goal stack. The impasse is resolved, and the subgoal terminated, when sufficient preferences have been added to working memory so that a decision can be made. To determine the best operator, any number of methods can be used in the subgoal, such as draw- ing analogies to previous problems, asking an outside agent, or various planning strategies. In Soar, the selection of a problem space for the goal determines which approach will be taken, so that depending on the available knowledge, many different approaches are possible. This distinguishes Soar from many other sys- tems that use only a single planning technique to gen- erate control knowledge. Robo-Soar uses an abstract look-ahead planning strategy. Look-ahead planning requires additional do- main knowledge, specifically, the ability to simulate the actions of external operators on the internal model of the world. As expected, this knowledge is encoded as productions that directly modify the internal state when an operator is selected to apply to it. The internal simulations of operators do not repli- cate the behavior of the environment exactly, but are abstractions. In Rob&oar, these abstractions are pre- determined by the productions that implement the op- erators, although in other work in Soar abstractions have been generated automatically based on ignoring impasses that arise during the look-ahead search [Un- ruh & Rosenbloom, 19891. For Robo-Soar, an abstract plan is created to align a set of blocks by moving one block at a time. This level completely ignores moving the gripper and grasping blocks. This plan is later re- fined to movements of the gripper by further planning once the first block movement has been determined. Even this level is abstract in that it does not simu- late exact sensor values (such as block A is at location 3.4, 5.5) but only relative positions of blocks and the gripper (block A is to the right of block B). Planning in Robo-Soar is performed by creating an internal model of the environment and then evaluat- ing the result of applying alternative operators using available domain knowledge. The exact nature of the search is dependent on the available knowledge. For some tasks, it may be possible to evaluate the re- sult of a single operator, but for other tasks, such as Robo-Soar, evaluation may be possible only after ap- plying many operators until a desired (of failed) state is achieved. Planning knowledge converts the evalua- tions computed in the search into preferences. When LAIRD AND ROSENBLOOM 1025 2. 3. 4 . 5. rect execution. The plan consists of the preferences stored in these control rules, and the rule conditions which determine when the preferences are applica- ble. Expressive planning language. The expressibility of Soar’s plan language is a func- tion of: (1) the fine-grained conditionality provided by embedding the control knowledge in a set of rules; and (2) the preference language. The first factor makes it easy to encode such control structures as conditionals, loops, and recursion. The second fac- tor makes it easy to not only directly suggest the appropriate operator to select, but also to suggest that an operator be avoided, or that a partial order holds among a set of operators. This differs from sys- tems that use stimulus-response rules in which the actions are commands to the motor system [Mitchell et al., 1990; Schoppers, 19861. In Soar, the actions of the productions are preferences that contribute to the decision as to which operator to select. Thus Soar has a wider vocabulary for expressing control knowledge than these other systems. On-demand planning. Soar invokes planning whenever knowledge is insuf- ficient for making a decision and it terminates plan- ning as soon as sufficient knowledge is found. Be- cause of this, planning is always in service of execu- tion. Also because of this, planning and replanning are indistinguishable activities. Both are initiated because of indecision, and both provide knowledge that resolves the indecision. Learning improves future execution and plan- ning. Once a control production is learned, it can be used for future problems that match its conditions. These productions improve both execution and planning by eliminating indecision in both external and internal problem solving. The effect is not unlike the utiliza- tion of previous cases in case-based reasoning [Ham- mond, 19891. This is in contrast to other planning systems that build “situated control rules” for pro- viding reactive execution of the current plan, but do not generalize or store them for future goals [Drum- mond, 19891. Run- time combination of multiple plans. When a new situation is encountered, all relevant learned for moving the gripper ignore the exact names and positions of the blocks, but are sensitive to the final relative positions of the blocks. The ramifications of this approach to planning are as follows: 1. Planning without monolithic plans. In classical planning, the plan is a monolithic data structure that provides communication between the planner and the execution module. In Soar, a mono- lithic declarative plan is not created, but instead a set of control productions are learned that jointly di- productions will fire. It makes no difference in which previous problem the productions were learned. For a novel problem, it is possible to have productions from many different plans contribute to the selec- tion of operators on the solution path (unlike case- based reasoning). For those aspects of the problem not covered by what has been learned from previous problems, on-demand planning is available to fill in the gaps. It is this last observation that is probably most im- portant for planning in uncertain and unpredictable environment. By not committing to a single plan, but instead allowing all cached planning knowledge to be combined at run-time, Soar can respond to unexpected changes in the environment, as long as it has previously encountered a similar situation. If it does not have suf- ficient knowledge for the current situation, it will plan, learn the appropriate knowledge, and in the future be able to respond directly without planning. Interruption The emphasis in our prior description of planning was on acquiring knowledge that could be responsive to changes in the environment during execution. This ig- nores the issue of how the system responds to changes in its environment during planning. Consider two sce- narios from Robo-Soar . In the first scenario, one of the blocks is removed from the table while Robe-Soar is planning how to align the blocks. In the second, a trouble light goes on while Robo-Soar is planning how to align the blocks. This light signals that Robo- Soar must push a button as soon as possible. The key to both of these scenarios is that Soar’s productions are continually matched against all of working mem- ory, including incoming sensor data, and all goals and subgoals. When a change is detected, planning can be revised or abandoned if necessary. In the first example, the removal of the block does not eliminate the necessity to plan, it just changes the current state, the desired state (fewer blocks need to be aligned) and the set of available operators (fewer blocks can be moved). The change in the set of available op- erators modifies the impasse but does not eliminate it, Within the subgoal, operators and data that were specific to the removed block will be automatically re- tracted from working memory. The exact effect will depend on the state of the planning and its dependence on the eliminated block. In the case where an outside agent suddenly aligned all but one of the blocks, and Robo-Soar had sufficient knowledge for that specific case, the impasse would be eliminated and the appro- priate operator selected. In the second example, we assume that there ex- ists a production that will direct Robo-Soar to push a button when a light is turned on. This production will test for the light and create a preference that the push-button operator must be selected. When the next operator decision is made, there is no longer a 1026 ROBOTICS tie, and the push-button operator is selected. Inter- form approach is that all the decision making and plan- ruption of planning can be predicated on a variety of stimuli. For example, productions can keep track of ning methods also apply to these “goals” (abstract operators like search-for-object). For example, if the time spent planning and abort the planning if it is taking too much time. Planning would be aborted by creating a preference for the best action given the currently available information. One disadvantage of this scheme is that any partial planning that hi not been captured in chunks will be lost. Hierarchical Planning and Execution there is an abstract internal simulation of an operator such as pickup-cup, it can be used in planning for the top goal in the same way planning would be performed at more primitive levels. a A second advantage of treating incomplete operator applications as goals is that even seemingly primitive acts, such as move-arm can become goals, providing hierarchical execution. This is especially important when there is uncertainty as to whether a primitive ac- tion will complete successfully. Hero-Soar has exactly these characteristics because its sensors are imperfect and because it sometimes loses motor commands and sensor data when communicating with the Hero robot. Hero-Soar handles this uncertainty by selecting an op- erator, such as move-arm, and then waiting for feed- back that the arm is in the correct position before ter- minating the operator. While the command is execut- ing on the Hero hardware, a subgoal is created. In this subgoal, the wait operator is repeatedly applied, con- tinually counting how long it is waiting. If appropriate feedback is received from the Hero, the move-arm op- erator terminates, a new operator is selected, and the subgoal is removed. However, if the motor command or feedback was lost, or there is some other problem, such as an obstruction preventing completion of the opera- tor, the waiting continues. Productions sensitive to the selected operator and the current count detect when the operator has taken longer than expected. These productions propose operators that directly query the feedback sensors, retry the operator, or attempt some other recovery strategy. Because of the relative compu- tational speed differences between the Hero and Soar on an Explorer II+, Hero-Soar spends approximately 30% of its time waiting for its external actions to com- plete. In our previous Robo-Soar examples, the set of op- erators corresponded quite closely to the motor com- mands of the robot controller. However, Soar has no restriction that problem space operators must directly correspond to individual actions of the motor system. For many problems, planning is greatly simplified if it is performed with abstract operators far removed from the primitive actions of the hardware. For execution, the hierarchical decomposition provided by multiple levels of operators can provide important context for dealing with execution errors and unexpected changes in the environment. Soar provides hierarchical decomposition by creat- ing subgoals whenever there is insufficient knowledge encoded as productions to implement an operator di- rectly. In the subgoal, the implementation of the ab- stract operator is carried out by selecting and applying less abstract operators, until the abstract operator is terminated. To demonstrate Soar’s capabilities in hierarchical planning and execution we will use our second system, Hero-Soar. Hero-Soar searches for cups using sonar sensors. The basic motor commands include position- ing the various parts of the arm, opening and clos- ing the gripper, orienting sonar sensors, and moving and turning the robot. A more useful set includes op- erators such as search-for-object, center-object, pickup-cup, and drop-cup. The execution of each of these operators involves a combination of more primi- tive operators that can only be determined at run-time. For example, search-for-an-object involves an ex- ploration of the room until the sonar sensors detect an object. In Hero-Soar, the problem space for the top-most goal consists of just these operators. Control knowl- edge selects the operators when they are appropri- ate. However, once one of these operators is se- lected, an impasse arises because there are no relevant implementation productions. For example, once the search-for-object operator is selected, a subgoal is generated and a problem space is selected that contains operators for moving the robot and analyzing sonar readings. , Operators such as search-for-object would be considered goals in most other systems. In contrast, goals in Soar arise only when knowledge is insufficient to make progress. One advantage of Soar’s more uni- Hierarchical execution is not unique to Soar. Georgeff and Lansky have used a similar approach in PRS for controlling a mobile robot [Georgeff & Lansky, 19871. In PRS, declarative procedures, called Knowl- edge Areas (KAs) loosely correspond to abstract op- erators in Soar. Each KA has a body consisting of the steps of the procedure represented as a graphic network. Just as Soar can use additional abstract op- erators in the implementation of an operator, a KA can have goals as part of its procedure which lead to additional KAs being invoked. PRS maintains reactiv- ity by continually comparing the conditions of its KAs against the current situation and goals, just as Soar is continually matching it productions. A significant dif- ference between PRS and Soar is in the representation of control knowledge and operators. Within a KA, the control is a fixed declarative procedure. Soar’s control knowledge is represented as preferences in productions that can be used for any relevant decision. Thus the knowledge is not constrained to a specific procedure, LAIRDANDROSENBLOOM 1027 and will be used when the conditions of the produc- tion that generates the preference match the current situation. In addition, new productions can be added to Soar through learning, and the actions of these pro- ductions will be integrated with existing knowledge at run-time. Reactive Execution Hierarchical execution provides important context for complex activities. Unfortunately it also exacts a cost in terms of run-time efficiency. In order to perform a primitive act, impasses must be detected, goals cre- ated, problem spaces selected, and so on, until the motor command is generated. Execution can be per- formed more efficiently by directly selecting and apply- ing primitive operators. However, operator application has its own overheads. The actions of an operator will only be executed after the operator has been selected following quiescence, thus forcing a delay. The advan- t age of these two approaches is that they allow knowl- edge to be integrated at run-time, so that a decision is not based on an isolated production. Soar also supports direct reflex actions where a pro- duction creates motor commands without testing the current operator. These productions act as reflexes for low level responses, such as stopping the wheel motors when an object is directly in front of the robot. Along with the increase responsiveness comes a loss of con- trol; no other knowledge will contribute to the decision to stop the robot. The ultimate limits on reactivity rest with Soar’s ability to match productions and process prefer- ences. Unfortunately, there are currently no fixed time bounds on Soar’s responsiveness. Given Soar’s learn- ing, an even greater concern is that extended plan- ning and learning will actually reduce responsiveness as more and more productions must be matched [Tambe & Newell, 19881. R ecent results suggest that these problems can be avoided by restricting the expressive- ness of the production conditions [Tambe & Rosen- bloom, 19891. Although there are no time bounds, Soar is well matched for both Hero-Soar and Robo-Soar. In nei- ther case does Soar’s processing provide the main bot- tleneck. However, as we move into domains with more limited time constraints, further research on bounding Soar’s execution time will be necessary. Discussion Perhaps the key reason that Soar is able to exhibit effective execution, planning (extended, hierarchical, and reactive), and interruption, is that it has three dis- tinct levels at which external actions can be controlled. These levels differ both in the speed with which they occur and the scope of knowledge that they can take into consideration in making a decision. At the low- est level, an external action can be selected directly by a production. This is the fastest level - Soar can fire 40 productions per second on a TI Explorer II+ while controlling the Hero using 300 productions - but the knowledge utilized is limited to what is ex- pressed locally in a single production.2 This level is appropriately described as reflexive behavior - it is fast, uncontrollable by other knowledge, and difficult to change. At the middle level, an external action can be se- lected through selecting an operator. This is some- what slower - in the comparable situation as above, only 10 decisions can be made per second - but it can take into account any knowledge about the cur- rent problem solving context that can be retrieved directly by firing productions (without changing the context). It allows for the consideration and compar- isons of actions before a selection is made. This level is appropriately described as a dynamic mixture of top- down (plan-driven) and bottom-up (data-driven) be- havior. It is based on previously-stored plan fragments (learned control rules) and the current situation, and can dynamically, at run-time, adjudicate among their various demands. This level can be changed simply by learning new plan fragments. At the highest level, an external action can be se- lected as a result of extended problem solving in sub- goals. This can be arbitrarily slow, but potentially allows any knowledge in the system - or outside of it, if external interaction is allowed - to be taken into consideration. This level is appropriately described as global planning behavior. Soar’s learning is closely tied into these three lev- els. Learning is invoked automatically whenever the knowledge available in the bottom two levels is in- sufficient. Learning moves knowledge from planning to the middle level of deliberate action and, also to the bottom level of reflexes. Without learning, one could attempt to combine the bottom and mid- dle layers by precompiling their knowledge into a fixed decision network as in REX [Kaelbling, 1986; Rosenschein, 19851. However, for an autonomous sys- tem that is continually learning new control knowledge and operators [Laird et al., 199Oa], the only chance to bring together all of the relevant knowledge for a deci- sion is when the decision is to be made. The integration of planning, execution, and learning in Soar is quite similar to that in Theo because of the mutual dependence upon impasse-driven planning and the caching of plans as productions or rules. Schop- pers’ Universal Plans also caches the results of plan- ning; however, Schoppers’ system plans during an ini- tial design stage and exhaustively generates all possible plans through back-chaining. In contrast, Theo and Soar plan only when necessary, and do not generate all 2Hero-Soar is limited in absolute response time by de- lays in the communication link between the Hero and the Explorer, and the speed of the Hero central processor. The actual response time of Hero-Soar to a change in its envi- ronment is around .5 seconds. 1028 ROBOTICS possible plans; however, Theo as yet does not support interruption, nor can it maintain any history. All de- cisions must be based on its current sensors readings. Soar is further distinguished from Theo in that Soar supports not only reactive behavior and planning, but also deliberative execution in which multiple sources of knowledge are integrated at run-time. This middle level of deliberate execution is especially important in learning systems when planning knowledge is combined dynamically at run-time. Acknowledgments The authors would like to thank Michael Hucka, Eric Yager, Chris Tuck, Arie Covrigaru and Clare Congdon for help in developing Robo-Soar and Hero-Soar. References [Blythe & Mitchell, 19891 J. Blythe & T. M. Mitchell. On becoming reactive. In Proceedings of the Sixth International Machine Learning Workshop, pages 255-259, Cornell, NY, June 1989. Morgan Kauf- mann. [Doyle, 19791 J. Doyle. A truth maintenance system. Artificial Intelligence, 12~231-272, 1979. [Drummond, 19891 M. Drummond. Situated control rules. In Proceedings of the First International Con- ference on Principles of Knowledge Representation and Reasoning, Toronto, May 1989. Morgan Kauf- Mann. [Fikes et al., 19721 R. E. Fikes, P. E. Hart, & N. J. Nilsson. Learning and executing generalized robot plans. Artificial Intelligence, 3:251-288, 1972. [Georgeff & Lansky, 19871 M. P. Georgeff & A. L. Lan- sky. Reactive reasoning and planning. Proceedings of AAAI-87, 1987. [Hammond, 19891 K. J. Hammond. Case-Based Plan- ning: Viewing Planning as a Memo y Task. Aca- demic Press, Inc., Boston, 1989. [Kaelbling, 19861 L. P. Kaelbling. An architecture for intelligent reactive systems. In M. P. Georgeff & A. L. Lansky, editors, Reasoning about Actions and Plans: Proceedings of the 1986 Workshop, 95 First Street, 1986. Morgan Kaufomann. [Laird et al., 19861 J. E. Laird, P. S. Rosenbloom, & A. Newell. Universal Subgoaling and Chunking: The Automatic Generation and Learning of Goal Hierar- chies. Kluwer Academic Publishers, Hingham, MA, 1986. [Laird et al., 19871 J. E. Laird, A. Newell, & P. S. Rosenbloom. Soar: An architecture for general in- telligence. Artificial Intelligence, 33(3), 1987. [Laird et al., 19891 J. E. Laird, E. S. Yager, C. M. Tuck, & M. Hucka. Learning in tele-autonomous sys- tems using Soar. In Proceedings of the 1989 NASA Conference on Space Telerobotics, 1989. [Laird et al., 199Oa] J. E. Laird, M. Hucka, E. S. Yager, & C. M. Tuck. Correcting and extending domain knowledge using outside guidance. In Pro- ceedings of the Seventh International Conference on Machine Learning, June 1990. [Laird et al., 1990b] J. E. Laird, K. Swedlow, E. Alt- mann, & C. B. Congdon. Soar 5 User’s Manual. University of Michigan, 1990. In preparation. [Langley et al., 19891 P. Langley, K. Thompson, W. Iba, J. H. Gennari, & J. A. Allen. An integrated cognitive architecture for autonomous agents. Tech- nical Report 89-28, Department of Information & Computer Science, University of California, Irvine, September 1989. [Mitchell et al., 19901 T. M. Mitchell, J. Allen, P. Cha- lasani, J. Cheng, 0. Etzionoi, M. Ringuette, & J. Schlimmer. Theo: A framework for self-improving systems. In K. VanLehn, editor, Architectures for Intelligence. Erlbaum, Hillsdale, NJ, 1990. In press. [Rosenbloom & Laird, 19861 P. S. Rosenbloom & J. E. Laird. Mapping explanation-based generalization onto Soar. In Proceedings of AAAI-86, Philadelphia, PA, 1986. American Association for Artificial Intel- ligence. [Rosenbloom et al., 19901 P. S. Rosenbloom, J. E. Laird, A. Newell, & R. McCarl. A preliminary anal- ysis of the foundations of the Soar architecture as a basis for general intelligence. In Foundations of Artificial Intelligence. MIT Press, Cambridge, MA, 1990. In press. [Rosenschein, 19851 S. Rosenschein. Formal theories of knowledge in AI and robotics. New Generation Computing, 31345-357, 1985. [Schoppers, 19861 M. J. Schoppers. Universal plans for reactive robots in unpredictable environments. In M. P. Georgeff & A. L. Lansky, editors, Reasoning about Actions and Plans: Proceedings of the 1986 Workshop. Morgan Kaufmann, 1986. [Tambe & Newell, 19881 M. Tambe & A. Newell. Some chunks are expensive. In Proceedings of the Fifth In- ternational Conference on Machine Learning, 1988. [Tambe & Rosenbloom, 19891 M. Tambe & P. S. Rosenbloom. Eliminating expensive chunks by re- stricting expressiveness. In Proceedings of IJCAI-89, 1989. [Unruh & Rosenbloom, ‘19891 A. Unruh & P. S. Rosen- bloom. Abstraction in problem solving and learning. In Proceedings of IJCAI-89, 1989. LAIRDANDROSENBLOOM 1029
|
1990
|
50
|
968
|
Symmetry Constraint Inference in Assembly Planning - Automatic Assembly Configuration Specification* Yanxi Liu and Robin J. Popplestone Laboratory for Perceptual Robotics Department of Computer and Information Science University of Massachusetts at Amherst, 01003 USA liu@cs.umass.edu, pop@cs.umass.edu Abstract In this paper we shall discuss how to treat the auto- matic generation of assembly task specifications as a constraint satisfaction problem (CSP) over finite and infinite domains. Conceptually it is straightforward to formulate assembly planning in terms of CSP, how- ever the choice of constraint representation and of the order in which the constraints are applied is non- trivial if a computationally tractable system design is to be achieved. This work investigates a subtle in- teraction between a pair of interleaving constraints, namely the kinematic and the spatial occupancy con- straints. While finding one consistent solution to a general CSP is NP-complete, our work shows how to reduce the combinatorics in problems arising in assembly using the symmetries of assembly compo- nents. Group theory, being the standard mathematical theory of symmetry, is used extensively in this work since both robots and assembly components are three- dimensional rigid bodies whose features have certain symmetries. This forms part of our high-level robot assembly task planner in which geometric solid mod- elling, group theory and CSP are combined into one computationally effective framework. Introduction A robot task level assembly planner requires, as part of the input, the final assembly configuration to be described (Fu 1987, Hutchinson & Kak 1990, Lozano- Perez 1982). Even at the abstract level, planning the sequence of assembly also requires the relationships among assembly components to be specified (Homem De Mello 1989, De Fazio & Whitney et al 1989). How- ever from a mechanical design it is not always trivial to derive an assembly configuration specification that is complete and unambiguous. One-element of this problem arises from the symmetries of assembly com- ponents. For a component of cubic shape, for example, *Preparation of this paper was supported in part by NSF grant number IRI-8709949, in part by ONR grant num- ber N00014-84-K-0564, and University Research Initiative Grant N00014-86-K-0764. there are six equivalent single surfaces, eight equiva- lent vertices and twelve equivalent edges; without a proper representation of symmetry a complete specifi- cation of any type of contact with such a component will be tedious. There is an essential relationship be- tween symmetry and function in mechanical engineer- ing, which needs to be addressed in any system that ‘reasons’ about mechanically engineered entities. In this paper we consider the process of determining a specification for assembly configurations from a de- sign in a way that exploits the symmetries present in a 3-d body, that is computationally tractable, and that places a minimal load on the human user. Our goal is to incorporate this planning work into a integrated robotic assembly system such as Handey (Lozano- Perez et al 1987), but one that has an intimate com- prehension of symmetries not restricted to polyhedral bodies. A constraint satisfaction problem (CSP) is defined over finite discrete domains in (Mackworth 1985) as: Given a set of n variables each with an asso- ciated domain and a set of constraining relations each involving a subset of the variables, find all possible n-tuples such that each n-tuple is an in- stantiation of the n variables satisfying the rela- tions. Each of such n-tuples is a solution. Assembly planning is a problem of the assignment of values to variables subject to a set of constraints (Dechter & Pearl 1987), therefore can be formulated as a CSP. Such constraints may include: Kinematic constraints: A kinematic constraint specifies the contact between a pair of bodies, albeit one that may not pertain to every situation occurring during a particular assembly. Contacts between sur- faces of simple shape can be treated as kinematic pairs (Angeles 1982, Herve 1978). Spatial constraints: no two bodies occupy the same volume of Euclidean space at the same time; such spatial constraints are bounded (in C-space (Lozano- Perez 1983) ) by kinematic constraints. Static and dynamic constraints: These relate to the forces acting on bodies during assembly. Sub- assemblies must be stable under gravity, friction must 1038 ROBOTICS From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. be overcome when necessary, and material must not be overstressed. Temporal constraints: These constrain the order in which actions may occur. They depend primarily on the previous constraints. One of the difficulties in robotics research is the in- terleaving of the application of different constraints. It is standard practice in the analysis of mechanical sys- tems to treat the kinematics before the dynamics of the system - indeed the conceptual dependencies and the possibility that the assembly may be performed either in space or on earth demand this. The work described here is concerned with establishing this kinematic ba- sis. The problem we are facing is this: Given : a set of 3-d rigid bodies and a set of relation- ship requirements upon bodies (implicit kinematic con- straints), such as body A fits body B or body C meshes body D; Find: all the possible assembly configurations in terms of mating features between bodies and relative positions of bodies, thus making kinematic constraints explicit such as surface 1 of A fits surface 3 of B; Satisfy: the kinematic and spatial constraints. We shall call this the assembly constraint satisfac- tion problem (ACSP) to distinguish it from the gen- eral CSP. Each given relationship on bodies in ACSP is a non-instantiated kinematic constraint that corre- sponds to a variable of CSP. The domain associated with each variable is composed of those candidate mat- ing feature pairs that satisfy the necessary mating fea- ture conditions described in (Liu & Popplestone 1989). In (Liu & Popplestone 1989) we reported in detail how to find candidate mating features from a set of geo- metric boundary models of bodies by matching against a prominent-feature library. In this paper we assume that such mating feature pairs have been found, as have the relationships between each pair of mating features. These relationships are described in terms of symme- try groups and are called the symmetry constraints. The possible mating features form domains of finite sizes, thus ACSP appears to be a CSP over finite sets. However each solution of ACSP, a set of mating fea- ture pairs defining an assembly configuration, also has to satisfy the spatial constraint, whereby we have to know the relative positions of bodies subject to the symmetry constraints, and this is an embedded CSP over possibly infinite domains. Besides the interleaving of different constraints, our work differs from that of the SPAR system (Hutchin- son & Kak 1990) in that a constraint between bodies is expressed as the relative location of the bodies belong- ing to a (possibly infinite) generalized coset of feature symmetry groups. Our work differs from that of RAPT (Ambler & Popplestone 1975, Popplestone, Ambler & Bellos 1980) in two ways, one is the incomplete kine- matic constraint input and the other is that instead of mapping symbolic representation for spatial relation- ships to a set of algebraic equations, symmetry groups of the mating feature pairs are generated first (Liu & Popplestone 1990,Popplestone, Liu & Weiss 1990, Pop- plestone 1984). This provides greater computational tractability and a more uniform treatment of spatial re- lationships, plus the ability to treat multiple feature re- lationships through symmetry group intersections (Liu 1990, Popplestone, Weiss and Liu 1988). Group theory, being the standard mathematical the- ory of symmetry, is used extensively in this work, since both robots and assembly components are three- dimensional rigid bodies whose features have certain symmetries. Some group theory related concepts and how to express relative positions of bodies using sym- metry groups of features are discussed in the next sec- tion. It is known that in a general CSP finding one con- sistent solution is an NP-complete problem. In ACSP clues deduced from the symmetries of the assembly are used to minimize the variable domain, thus mitigating the combinatorics, as described in Section “Symmetry constraint and constraint satisfaction graph”. In the final section we present two examples and discuss the pros and cons of this work. Symmetry groups and Relative positions A group G can be regarded simply as a set of mappings that are closed under an associative composition oper- ation, where 1 E G is an identity element such that for all g E G, lg = gl = g, and where each element g has an inverse 9-l such that 99-l = g-lg = 1. A subgroup H of a group G is a subset of G such that H is itself a group under the composition operation of G. If H is a subgroup of G and g E G then a left coset of H is the set gH = (ghJh E H). If gi,g2 E G, a two-sided coset of H is the set 91 Hg2 = (g,hg,lh E H}. For more de- tails on groups and their applications refer to (Miller 1972, Popplestone, Liu & Weiss 1990). One important group to which researchers in robotics can easily relate is the proper Euclidean group E+, which is composed of all 3-d rotations, translations and their combinations. Every element of E+ can act on a subset of the Eu- clidean space ?R3, thereby relocating the subset. For each point x in R3 an orbit of x under a subgroup G of E+ is defined to be the set G(z) = (g(z)19 E G}. This is an important and useful concept. Bodies in an assembly mate through their features. A primitive feature F of a solid is a surface which is a subset of ZR3 associated with a boundary model of the solid. Examples are infinite planes, cylinders and spheres. A compound feature is a set of primitive fea- tures. A feature, primitive or compound, may have symmetries. A symmetry of a feature is an element of ES that leaves the feature set-wise invariant. The set of all the symmetries of a feature has a group structure and is called the symmetry group of the feature. When two features from different bodies mate the relation- ship of the two bodies can be expressed in terms of the symmetry groups of the mating features. In the case LIU ANDPOPPLESTONE 1039 Table 1: Continuous Group and Degree of Freedom 1 Dimension 1 Symmetry Group / Associated 1 (d.o.f.) (constraint) Lower pair 1 Tl Prismatic 1 SO2 RevoEute 1 G screw Screw 2 Scylinder Cylindrical 3 Gplane Planar 3 SO3 Svhericab when they have an area1 contact, i.e. a fitting relation- ship, the symmetry groups of contacting features are identical. In this paper such fitting relationships are our primary concern. We call such a symmetry group a symmetry constraint of the mating feature pair. By associating with each feature its symmetry group, it is possible for the planner to represent and reason about symmetry in an efficient way. This is of essential im- portance in understanding how features mate and what the final assembly configurations can be. Symmetry groups can be either finite or infinite’. An example of a finite group is the symmetry group of a hexagonal bolt-head, which is called the cyclic group of order 6. Some examples of infinite groups are listed in Table 1. Each of these symmetry groups corresponds to a lower pair, which is a kinematic coupling with area1 contact (fitting). Our work treats both infinite and finite cases in a uniform way. Consider what we can infer about the relative loca- tion of two bodies that have two features in contact. Such a contacting relationship must correspond to a set of displacements which specify the relative loca- tion of the two bodies. Note that a displacement as a mapping over !R3 is a member of E+. Now let 231 and Bz be two bodies, with primitive features Fi and 5’2 which are in contact and have symmetry groups sym(Fl), sym( Fz) respectively. Suppose II, 12 specify the locations of bodies B1, Bz in the world coordinate system and fi and fi specify the locations of features Fl, 3’2 in their respective body coordinates. By the def- inition of symmetry group, it is clear that if we move B1 or Bs by a member of the symmetry group sym(Fl ) or sym(.Fz) respectively, the relationship between the features is preserved. The fits relation is particularly constraining. If 3’1 fits 3’2 then their surfaces coincide and thus have the same symmetry group. The relative location of body B1 to body Bz can be expressed as: We can summarize this by saying that if a primitive feature of one body fits a primitive feature of another ‘For a list of imp ortant symmetry group definitions re- fer to (Popplestone, Liu & Weiss 1990, Liu & Popplestone 1990) body then the relative location of the two bodies is a two-sided coset of the common symmetry group of the features. This coset is an infinite set when the symme- try group is of infinite order. In the case where sym(Fi) is the identity group {l}, from formula (l), we know that the relative position of bodies B1 and Bz is uniquely determined: This shows that the most asymmetrical case appears in the simplest form under this formulation. Two bod- ies in an assembly are typically related to each other through multiple primitive features. If the above two bodies are related by fitting two pairs of features, i.e. Fl1 fits 3’21 and Fl2 fits Fzz with feature locations in their body coordinate systems fil, f21, fi2, f22, then the relative location of body B1 to body B2 should be constrained by both relations expressed in the form (1) simultaneously. Equivalently, it should be in the intersection of the two sets: p2 E flpY~(~u)f~l (-)f12sY~(~12)fG1- (3) This illustrates the use of kinematic constraints on mating features to find possible relative body locations, and provides a framework for determining relative po- sitions when two bodies are mated through multiple features. Constraint Satisfaction Process In this section we describe in principle how ACSP is treated and in the next section we shall reinforce this principle through examples. As pointed out in the in- troduction, the given requirements among bodies of an assembly are treated as variables in A CSP and the possible mating features form the domain for each vari- able. If the number of variables is N, the domain size is D (average), and the number of constraints is C, then the search space would be on the order of O(CDN). This shows the importance of reducing the domain size D. Methods employing local arc/path-consistency and heuristics are used in searching for a solution to miti- gate the combinatorics. Input: n relationships among bodies (variables in CSP), each of which is associated with a set of candi- date mating features (the domain of the variable). Output: All the assembly configurations that the relative positions of bodies can be determined and that satisfy the kinematic and the spatial constraints. In the following we describe a three-step-algorithm for finding a solution in ACSP: Step one is setting up the constraint satisfaction graph. Given the non-instantiated kinematic con- straints (input) and all the possible mating features, the system establishes a two-layered graph. The top layer has bodies as nodes and required relationships among bodies as arcs (this is a dual graph of the ac- tual constraint satisfaction graph). The bottom layer 1040 ROBOTICS has candidate mating features as nodes and. the com- mon symmetry groups between mating features as arcs. Whenever the domain size of one of the variables is zero the process terminates. Some primitive fea- tures such as cylindrical surface, surfaces with texture threads, or gears have higher priority to be matched first. Because such surfaces with given parameters are relatively rare, so the probability of being correctly matched is higher. Whenever two candidate mating features have the identity group as their common sym- metry group, or the common symmetry group is the same as the symmetry group of one of the bodies to which the features reside, the relative position of the two related bodies can be uniquely determined and the intersect predicate of PADL22 (Brown 1982) can then be called for spatial occupancy checking. In this case, node-consistency is achieved locally. Step two is reducing the domain size of each variable. The following set of rules are applied in turn: Mandatory request law: if there is only one corre- spondence at the bottom level to a upper layer input constraint this mating feature pair has the highest priority. Therefore if one of the features is a non- sharable feature3, then any other arcs pointing to this feature should be deleted. The precondition of this rule corresponds to the case in CSP where the domain size of a variable is one. The effect of apply- ing this rule can be propagated until the network is quiescent. / Equivalent feature law. A pair of features of a body is said to be equivalent if they have the same symmetry group and same dimensions and belong to the same orbit. A set of features Fi, 3’2, . ..F. of body B belong to the same orbit if and only if there exists g E G (the symmetry group of the body) such that g(Fi) = Fi+l,g(F,) = Fl. Since g(B) = B, the features per- mute among themselves under g while the body sits still set-wise. Being able to represent and reason about these characteristics the system will choose only one out of a set of equivalent features. The rea- soning for the chosen one can be applied to the rest of the features in its orbit. For example, consider a finite cylinder which has two identical ends: all the reasoning about one end of the cylinder applies to the other end of the cylinder. This rule shall be ap- plied unless it causes the termination of the process. Arc/Path consistency checking (Mohr & Hen- derson 1986, Mackworth 1985) is a local consistency 2A solid geometric modeller PADL2 has been interfaced with our planning system. Its intersect predicate returns true if no interference of two specified bodies is found, false otherwise. 3A predicate called sharable is applicable to a pair of features from distinct bodies. It returns tme if a third feature can also be mated simultaneously, J&e otherwise. checking method for CSPs which can be used to elim- inate those arcs which will not lead to a conclusion. Step three is checking the spatial constraint globally. Firstly, we need to find all the subgraphs in the bottom level (relating mating features) which are isomorphic to the top level graph (relating bodies). Each of these subgraphs is an instantiation of the input requirements on bodies. Secondly, the no-pairwise-interference con- straint is applied. When the relative position of a pair of related bodies cannot be determined locally in step one, this is the time to evaluate the situation globally i.e. to see whether constraint from other bodies can be used to decide the position. we have experimented with a simple and quick algorithm due to (Kramer 1990) that solves certain algebraic equations geometrically. This will be explained further in the examples. Complexity analysis of the above algorithm: Step one takes O(nd) time where n is the number of relationships among bodies and d is the domain size. Step two uses the arc/path consistency checking algorithms described in [2l] which has complexity O(nd2) where d is the bound for domain sizes. Step three needs to check s1 x sz... x s, combinations where n is still the number of kinematic constraints and si is the reduced domain size. In summary, the planner starts by establishing the two layered constraint satisfaction graph. Whenever possible, node consistency checking is carried out. The feature-level graph is pruned by applying heuristics, arc/path consistency checks. Finally, isomorphic sub- groups are mapped from the feature-level to the body- level where the spatial occupancy constraint is applied to each. The original network is thus transformed into smaller and smaller networks such that the final iso- morphic graph matching can be performed on a much slimmer graph. Examples and Discussion In this section we describe and compare three examples where different approaches are taken to determine rela- tive positions so that the spatial occupancy constraint can be applied. Example one Each component of this assembly is shown in Figure 1. The input goals are: [goal 1 Cf it bl b411 [goal 2 Cf it b2 b411 [goal 3 [fit b3 b411 The associated compound features for each body: bl : compl = Cl 3 41, . . . b2 : compl = Cl 3 41, . . . b3 : compl = Cl 3 23, . . . b4 : compl = 17 8 91, . . . compl2 = c7 10 133 compl3 = 17 11 123 LIUANDPOPPLESTONE 1041 b6: Figure 1: First assembly example All of the mating feature pairs found from these sets are non-sharable. At step one, the symmetry group computed for each of these compound features by the system is the identity group, thus the relative position of the two bod- ies on which the mating features reside can be determined uniquely. The planner applies the spatial occupancy con- straint on all pairs of mating bodies by using the PADL2 intersect predicate. Then a node consistent network is achieved. At step two, intersection is found by arc con- sistency checking (Figure 2). The process terminated since at least one domain is empty. After replacing to another set of assembly components, two solutions are found at the end of step three i.e. the spatial constraint is satisfied globally. ** [Or fAnd [iit Cbl compll Cb4 compl311 [fit Lb2 compll [b4 compl]] [fit [b3 compll Lb4 compl2111 [And [fit Cbl cornpi] Cb4 complll [fit Cb2 compll Cb4 comp131J [fit Lb3 compll Lb4 compl21]1] . See Figure 2. Since bl and b2 each has two compound features belonging to the same feature orbit, there are ac- tually eight different assembly configurations found. Example two The assembly components of this assembly are shown in Figure 3. The input goals are: [goal 1 [fit b3 bl]] [goal 2 [fit b3 b211 [goal 3 [fit bl b2]] The compound features of each body are composed of these primitive features: bl : compl = [7 83 comp2 = f9 103 b2 : compl = [7 83 comp2 = [9 101 b3 : compl = [7 91 comp2 = [7 83 All the potential mating feature pairs are non-sharable. All the common symmetry groups of mating features are sO(2), which corresponds to a revolute joint. Since SO( 2) is an infinite group, node/arc consistency checking in step ttoo cannot be applied immediately. Although CCWZ~~ and comp2 of b3 are equivalent features but dismissing one Figure 2: A rejected solution and a confirmed solution of Example one Figure 3: Second assembly example would cause the process to terminate so they are preserved. At the step three, the following configurations are proposed after subgraph mapping: ** [Or [And [fit Cb3 compll Cbl comp211 [fit Cb3 comp21 Cb2 comp213 [fit [bl compll I32 compl13~ [And [fit Cb3 comp21 Cbl comp211 [fit Cb3 compll Cb2 comp211 [fit [bl compll Cb2 compl] 111 Although the exact relative position of b3 to bl is un- known from their mating features, the symmetry constraint SO(2) restricts bl to having only one degree of freedom when it is fitted to b3: the rotation about the central axis of their mating features. As a matter of fact, every body in this assembly is constrained by two such revolute joints. Any pair of points coinciding on the mating feature sur- faces should have the same orbit under the action of the common symmetry group of the feature pair. We picked the center point at the bottom of a cylinder, concave or convex, as the representative point for a cylindrical mat- ing feature. This is a good choice for cylinders since its orbit under the symmetry group of the feature is itself (it 1042 ROBOTICS Top View of hod)’ b? with TWO cylinders comlrq out of the paper I ltat ive t I iOC1 mtersectlon locus forned t,:; the at the tangent rcraser.r3:lre p2rr.t .plnt of’ ccntrl of tz Figure 4: When b2 is fitted to b3, the representative points of the fitted features coincide, the orbit of the other representative point forms a locus under this rev- olute motion is invariant under actions by any member of the symmetry group). Therefore the two representative points of a pair of mating features should be coincident all the time when the bodies fit (Figure 4). Figure 5 shows that the orbit of the representative point on feature compl of b2 forms a locus under the symmetry group of feature comp2 of the same body, and same is illustrated for the representative point of feature compl on body bl. The intersection of these two loci is the only possible position for the representative points of compl of bl and compl of b2 to be coincident. Thus it uniquely determines the relative positions of bod- ies bl and b2 such that both mating relationships can be satisfied simultaneously. Finally, the spatial constraint is applied and both sets of possible mating feature pairs are confirmed to be solutions. Example Three Figure 6 shows an assembly containing a mating feature pair of triangle shape. This is the case where the symmetry group of the mating feature is the same symmetry group as the symmetry group of the body thus the relative position can be uniquely determined. Due to length limit, we omit the detail here. Discussion In conclusion, this paper describes the use of constraint sat- isfaction networks to reify assembly configurations which are composed of possible mating feature pairs related by symmetry constraints, i.e. the symmetry groups shared by the mating feature pairs. This work has been imple- mented in POPLOG on the SUN workstation under OS 4.0. Through this work one can see that the performance of a special CSP depends strongly on how well the domain dependent subproblems have been solved. The domain dependent constraint application: finding possible mating Figure 5: Intersecting loci from compl of bl and compl of b2 Figure 6: An example containing non-revolute joint features, finding positions, finding intersections etc., dom- inates the implementation as well. This seems to suggest that an effective combination of artificial intelligence and robotics must be woven together at each problem solving step. The bottleneck of ACSP is the determination of the rela- tive position of bodies so that the spatial constraint can be applied. The usefulness of symmetry constraints is reflected in the fact that when the identity group is present, the rela- tive position can be computed uniquely. When no identity groups are present, we can apply the representative-point- intersection method to find possible locations or to claim that no solution exists. Things become more complicated when a symmetry constraint network is underconstrained, i.e. relative motions are allowed in an assembly for cer- tain functional purposes, such as a pair of scissors. One plausible way to deal with this is simply to sweep the body concerned under the symmetry group of its constantly con- tacting features, then intersect this swept volume with the rest of the assembly. If no intersection is detected, the kine- matic constraint is correctly instantiated, otherwise the in- tersected volumes set up boundaries (or intervals, label set [5]) on the kinematic constraint. PADLZ does not have the LIU ANDPOPPLESTONE 1043 ability to sweep a body therefore we have not yet experi- mented with these. Our method cannot be complete even for assemblies with no residual degrees of freedom since it is possible to define assemblies that require the solution of a polynomial equa- tion of arbitrarily high degree (Hopcroft, Joseph & White- sides 198?), and the geometric methods we use cannot gen- erate solutions of such equations. However in any practical assembly, only a small portion of the assembly planning problem will require the solution of such equations; the ma- jority of the relationships should be amenable to analysis by our methods. Our system could well be complemented by harnessing it to a system capable of treating a full range of polynomial equations as envisaged by Canny [4]. Acknowledgment Thanks Gordon Dakin for implementing the POPLOG to PADLB interface. Thanks King Shaw and Seth Malitz for some helpful discussions. PI PI PI PI 151 PI PI PI PI PO1 El13 Cl21 References Ambler, A.P. and Popplestone, R.J. 1975. Inferring the positions of Bodies from specified Spatial Rela.- tionships. Artificial Intelligence 6(1975): 157-174. Angeles, J. 1982. Spatial Kinematic Chains: Analysis- Synthesis-Optimization. Springer-Verlag, New York. Brown, C.M. 1982 PADLZ: A Technical summary. IEEE Computer Graphics Appl. 2( 2):69-84. Canny, J. 1987. The complexity of Robot Motion Plan- ning. Ph.D. diss. Dept. of Electrical Engineering and Computer Science. MIT. Davis, E. 1987. Constraint Propagation with Interval Labels. Artificial Intelligence 32(3):281-331. De Faeio, R.L. and Whitney, D.E. 1987. Simpli- fied Generation of All Mechanical Assembly Se- quences. IEEE Journal of Robotics and Automation RA-3(6):640-658. Dechter R. and Pearl J 1987. Network-based heuristics for constraint-satisfaction problems. Artificial Intelli- gence 34(l): l-38. Fu,K.S.; Gonzalez,R.C. and Lee, C.S.G. 1987. R 0 B 0 TICS: Control, Sensing, Vision, and Intel li- gence, McGraw-Hill Book Company. Hervd,J.M. 1978. Analyse Structurelle des Mecanismes par Groupe des Ddplacements. Mechanism and Ma- chine Theory 13(4):437-450. Homem de Mello, L.S. 1989. Task Sequence Planning for Robotic Assembly. Ph.D. diss., Dept. of Electrical and Computer Engineering, Carnegie Mellon Univer- sity. Hopcroft J., Joseph, D. and Whitesides, S. 1987. Movement Problems for 2-Dimensional Linkages (chapter 12). S c h wartz J.T., Sharir, M. and Hopcroft, J. (Eds.). Planning, geometry and complixity of robot motions. Norwood, N.J.: Ablex Pub. Corp. Hutchinson, S.A. and Kak, A.C. 1990. SPAR: A Plan- ner That Satisfies Operational and Geometric Goals in Uncertain Environments. Artificial Intelligence Maga- zine 11(1):30-61. PI WI WI P-Y WI WI El91 WI Pll WI PI WI E251 P-V Kramer, G.A. 1990. Solving geometric constraint sys- tems. In Proceedings of AAAI-90. Boston, MA. Liu, Y. 1990. A Justification for the Characteristic In- variant Representation of TR Subgroups of the Proper Euclidean Group. to be presented at the fifth SIAM Conference on Discrete Mathematics, June 11 -14, At- lanta, Georgia. Liu, Y. and Popplestone, R.J. 1989. Assembly Plan- ning from Solid Models. In Proceedings of IEEE In- ternational Conference on Robotics and Automation, 222-227. Washington, D.C.: IEEE Computer Society Press. Also: Assembly Planning from Solid Models us- ing Symmetry Groups. Progress in Robotics and Intel- ligent Systems. Ho, C.Y. and Zobrist, G. (Eds.), Ablex Publishing Corporation, New Jersey. Forthcoming. Lozano-Perez, T. 1983. Spatial planning: a configura- tion space approach. IEEE Transactions on Comput- ers C-32(2):108-120. Lozano-Perez, T., Jones, J.L., Mazer, E., O’Donnell, P.A., Grimson, W.E.L., Tournassoud, P. and Lanusse, A. 1987. Handey: A Robot System that Recognizes, Plans, and Manipulates. In Proceedings of IEEE In- ternational Conference on Robotics and +Automation, 843 - 849. Washington, D.C.: IEEE Computer Soci- ety Press. Lozano-Perez, T. 1982. Task Planning. Robot Motion: Planning and Control, Ed. Michael Brady, et al. The MIT Press Series in Artificial Intelligence. Mackworth, A.K. and Freuder, E.C. 1985. The Com- plexity of Some Polynomial Network Consistency Al- gorithms for Constraint Satisfaction Problems. Artiji- cial Intelligence 25( 1985): 65-74. Miller,W. Jr. 1972. Symmetry Groups and Their Ap- plications. Academic Press. New York. Mohr, R. and Henderson, T.C. 1986. Arc and Path Consistency Revisited. Artificial Intelligence 28(2):225-233. Popplestone, R.J., Liu, Y. and Weiss, R. 1990. A Group Theoretic Approach to Assembly Planning. AT- tificial Intelligence Magazine ll( 1):82-97. Popplestone R.J. , Weiss R., and Liu Y. Using Chay- acteristic Invariants to InfeT New Spatial Telationships from Old. In Proceedings of the 1988 IEEE Interna- tional Conference on Robotics and Auto.mation. Wash- ington, D.C.: IEEE Computer Society Press. Popplestone, R.J. 1984. Group theory and Robotics. Robotics Research, The First lat. Symp.:55-64. M. Brady and R. Paul(Eds.). Cambridge, Mass.: MIT Press. Popplestone,R.J.; Ambler A.P., and Bellos I. 1980. An Interpreter for a Language for Describing Assemblies. Artificial Intelligence 14( 1): 79-107. Whitney D. E. et al 1989. Tools for Strategic prod- uct Design. In Preprints of NSF Engineering Design Research Conference. 1044 ROBOTICS
|
1990
|
51
|
969
|
Becoming Increasingly Reactive Tom M. Mitchell School of Computer Science Carnegie Mellon University Pittsburgh, PA 15213 Tom.Mitchell@cs.cmu.edu Abstract We describe a robot control architecture which combines a stimulus-response subsystem for rapid reaction, with a search-based planner for handling unanticipated situations. The robot agent continually chooses which action it is to perform, using the stimulus- response subsystem when possible, and falling back on the planning subsystem when necessary. Whenever it is forced to plan, it applies an explanation-based learning mechanism to formulate a new stimulus-response rule to cover this new situation and others similar to it. With experience, the agent becomes increasingly reactive as its learning component acquires new stimulus-response rules that eliminate the need for planning in similar subsequent situations. This Theo-Agent architecture is described, and results are presented demonstrating its ability to reduce routine reaction time for a simple mobile robot from minutes to under a second. 1. Introduction and Motivation Much attention has focused recently on reactive architectures for robotic agents that continually sense their environment and compute appropriate reactions to their sense stimuli within bounded time (e.g., (Brooks, 1986, Agre and Chapman, 1987, Rosenschein, 1985)). Such architectures offer advantages over more traditional open- loop search-based planning systems because they can react more quickly to changes to their environment, and because they can operate more robustly in worlds that are difficult to model in advance. Search-based planning architectures, on the other hand, offer the advantage of more general- purpose (if slower) problem solving mechanisms which provide the flexibility to deal with a more diverse set of unanticipated goals and situations. This paper considers the question of how to combine the benefits of reactive and search-based architectures for controlling autonomous agents. We describe the Theo- Agent architecture, which incorporates both a reactive component and a search-based planning component. The fundamental design principle of the Theo-Agent is that it reacts when it can, plans when it must, and learns by augmenting its reactive component whenever it is forced to plan. When used to control a laboratory mobile robot, the Theo-Agent in simple cases learns to reduce its reaction time for new tasks from several minutes to less than a second. The research reported here is part of our larger effort toward developing a general-purpose learning robot architecture, and builds on earlier work described in (Blythe and Mitchell, 1989). We believe that in order to become increasingly successful, a learning robot will have to incorporate several types of learning: 0 It must become increasingly correct at predicting the effects of its actions in the world. 0 It must become increasingly reactive, by reducing the time required for it to make rational choices; that is, the time required to choose actions consistent with the above predictions and its goals. Q It must become increasingly perceptive at distinguishing those features of its world that impact its success. This paper focuses on the second of these types of learning. We describe how the Theo-Agent increases the scope of situations for which it can quickly make rational decisions, by adding new stimulus-response rules whenever it is forced to plan for a situation outside the current scope of its reactive component. Its explanation- based learning mechanism produces rules that recommend precisely the same action as recommended by the slower planner, in exactly those situations in which the same plan rationale would apply. However, the learned rules infer the desired action immediately from the input sense data in a single inference step--without considering explicitly the robot’s goals, available actions, or their predicted consequences. 1.1. Related Work There has been a great deal of recent work on architectures for robot control which continually sense the environment and operate in bounded time (e.g., (Brooks, 1986, Schoppers, 1987, Agre and Chapman, 1987)), though this type of work has not directly addressed issues of learning. Segre’s ARMS system (Segre, 1988) applies explanation-based learning to acquire planning tactics for a simulated hand-eye system, and Laird’s RoboSoar (Laird and Rosenbloom, 1990) has been applied to simple problems in a real hand-eye robot system. While these researchers share our goal of developing systems that are MITCHELL 1051 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. increasingly reactive, the underlying architectures vary significantly in the form of the knowledge being learned, underlying representations, and real response time. Sutton has proposed an inductive approach to acquiring robot control strategies, in his DYNA system (Sutton, 1990), and Pommerleau has developed a connectionist system which learns to control an outdoor road-following vehicle (Pommerleau, 1989). In addition to work on learning such robot control strategies, there has been much recent interest in robot learning more generally, including work on learning increasingly correct models of actions (Christiansen, et al., 1990, Zrimic and Mowforth, 1988), and work on becoming increasingly perceptive (Tan, 1990). The work reported here is also somewhat related to recent ideas for compiling low-level reactive systems from high-level specifications (e.g., (Rosenschein, 1985)). In particular, such compilation transforms input descriptions of actions and goals into effective control strategies, using transformations similar to those achieved by explanation- based learning in the Theo-Agent. The main difference between such design-time compilation and the explanation-based learning used in the Theo-Agent, is that for the Theo-Agent learning occurs incrementally and spread across the lifetime of the agent, so that the compilation transformation is incrementally focused by the worlds actually encountered by the agent, and may be interleaved with other learning mechanisms which improve the agent’s models of its actions. The next section of this paper describes the Theo-Agent architecture in greater detail. The subsequent section presents an example of its use in controlling a simple mobile robot, the learning mechanism for acquiring new stimulus-response rules, and timing data showing the effect of caching and rule learning on system reaction time. The final section summarizes some of the lessons of this work, including features and bugs in the current design of the architecture. perform. The agent runs in a tight loop in which it repeatedly updates its sensor inputs, chooses a control action, begins executing it, then repeats this loop. e It reacts when it can, and plans when it must. Whenever it must choose an action, the system consults a set of stimulus-response rules which constitute its reactive component. If one of these rules applies to the current sensed inputs, then the corresponding action is taken. If no rules apply, then the planner is invoked to determine an appropriate action. l Whenever forced to plan, it acquires a new stimulus-response rule. The new rule recommends the action which the planner has recommended, in the same situations (i.e., those world states for which the same plan justification would apply), but can be invoked much more efficiently. Learning is accomplished by an explanation-based learning algorithm (BBC (Mitchell, et al, 1986)), and provides a demand-driven incremental compilation of the planner’s knowledge into an equivalent reactive strategy, guided by the agent’s experiences. l Every belief that depends on sensory input is maintained as long as its explanation remains valid. Many beliefs in the Theo-Agent, including its belief of which action to perform next, depend directly or indirectly on observed sense data. The architecture maintains a network of explanations for every belief of the agent, and deletes beliefs only when their support ceases. This caching of beliefs significantly improves the response time of the agent by eliminating recomputation of beliefs in the face of unchanging or irrelevant sensor inputs. e It determines which goal to attend to, based on the perceived world state, a predefined set of goal activation and satisfaction conditions, and given priorities among goals. 2. The Theo-Agent Architecture The design of the Theo-Agent architecture is primarily driven by the goal of combining the complementary advantages of reactive and search-based systems. Reactive systems offer the advantage of quick response. Search- based planners offer the advantage of broad scope for handling a more diverse range of unanticipated worlds. The Theo-Agent architecture employs both, and uses explanation-based learning to incrementally augment its reactive component whenever forced to plan. In addition, the architecture makes widespread use of caching and dependency maintenance in order to avoid needless recomputation of repeatedly accessed beliefs. The primary characteristics of the Theo-Agent are: e It continually reassesses what action it should I I I I I 1 OBSERVED.WORLD .-P'CHOSEN. I 4 +- - - - - - - - k --------------------------- ----es+ 4 1 4 SENSORS EFFECTORS Figure 2-l: Data Plow in a Theo-Agent 1052 ROBOTICS Internal structure of agent: A Theo-Agent is defined by a frame structure whose slots, subslots, subsubslots, etc. define the agent’s beliefs, or internal statel. The two most significant slots of the agent are Chosen.Action, which describes the action the agent presently chooses to perform; and Observed.World, which describes the agent’s current perception of its world. As indicated in Figure 2-l the agent may infer its Chosen.Action either directly from its Observed.World, or alternatively from its current Plan. Its Plan is in turn derived from its Observed.World and Attended.To.Goal. The Attended.To.Goal defines the goal the agent is currently attempting to achieve, and is computed as the highest priority of its Active.Goals, which are themselves inferred from the Observed.World. Agent goals: Goals are specified to the agent by defining conditions under which they are active, satisfied, and attended to. For example, an agent may be given a goal Recharge.Battery which is defined to become active when it perceives its battery level to be less than 75%, becomes satisfied when the battery charge is lOO%, and which is attended to whenever it is active and the (higher priority) goal Avoid.Oncoming.Obstacle is inactive. Caching policy: The basic operation of the Theo-Agent is to repeatedly infer a value for its Chosen.Action slot. Each slot of the agent typically has one or more attached procedures for obtaining a value upon demand. These procedures typically access other slots, backchaining eventually to queries to slots of the Observed.World. Whenever some slot value is successfully inferred, this value is cached (stored) in the corresponding slot, along with an explanation justifying its value in terms of other slot values, which are in turn justified in terms of others, leading eventually to values of individual features in the Observed.World, which are themselves inferred by directly accessing the robot sensors. Values remain cached for as long as their explanations remain valid. Thus, the agent’s Active.Goals and Chosen.Action may remain cached for many cycles, despite irrelevant changes in sensor inputs. This policy of always caching values, deleting them immediately when explanations become invalid, and lazily recomputing upon demand, assures that the agent’s beliefs adapt quickly to changes in its input senses, without needless recomputation. Control policy: The Theo-Agent is controlled by executing the following loop: Do Forever: 1. Sense and update readings for all eagerly sensed features of Observed.World, and delete any cached values for ZaziZy sensed features. 2. Decide upon the current Chosen.Action 3. Execute the Chosen.Action When the Chosen.Action slot is accessed (during the decision portion of the above cycle), the following steps are attempted in sequence until one succeeds: 1. Retrieve the cached value of this slot (if available) 2. Infer a value based on the available stimulus- response rules 3. Select the first step of the agent’s Plan (inferring a plan if necessary) 4. Select the default action (e.g., WAIT) Sensing policy: Each primitive sensed input (e.g., an array of input sonar data) is stored in some slot of the agent’s Observed.World. Higher level features such as edges in the sonar array, regions, region width, etc., are represented by values of other slots of the Observed.World, and are inferred upon demand from the lower-level features. The decision-making portions of the agent draw upon the entire range of low to high level sensory features as needed. In order to deal with a variety of sensing procedures of varying cost, the Theo-Agent distinguishes between two types of primitive sensed features: those-which it eagerly senses, and those which it lazily senses. Eagerly sensed features are refreshed automatically during each cycle through the agent’s main loop, so that dependent cached beliefs of the agent are retained when possible. In contrast, lazily sensed features are simply deleted during each cycle. They are recomputed only if the agent queries the corresponding slot during some subsequent cycle. This division between eagerly and lazily refreshed features provides a simple focus of attention which allows keeping the overhead of collecting new sense data during each cycle to a minimum. Learning policy: Whenever the agent is forced to plan in order to obtain a value for its ChosenAction, it invokes its explanation-based generalization routine to acquire a new stimulus-response rule to cover this situation. The details of this routine are described in greater detail in the next section. The effect of this learning policy is to incrementally extend the scope of the set of stimulus- response rules to fit the types of problem instances encountered by the system in its world. 3. Example and Results This section describes the use of the Theo-Agent architecture to develop a simple program to control a Hero 2000 mobile robot to search the laboratory to locate garbage cans*. In particular, we illustrate how goals and actions are provided to the robot with no initial stimulus- response rules, how it initially selects actions by constructing plans, and how it incrementally accumulates stimulus-response rules that cover its routine actions. The robot sensors used in this example include an ultrasonic sonar mounted on its hand, a rotating sonar on ‘The Theo-Agen t is implemented on top of a generic frame-based problem solving and learning system called Theo (Mitchell, et al., 1990), which provides the inference, representation, dependency maintenance, and learning mechanisms. 2A detailed description of the m.odified Hero 2000 robot used here is available in (Lin, et al., 1989). MITCHELL 1053 its head, and a battery voltage sensor. By rotating its hand and head sonars it is able to obtain arrays of sonar readings that measure echo distance versus rotation angle. These raw sonar readings are interpreted (on demand) to locate edges in the sonar array, as well as regions, and properties of regions such as region width, distance, direction, and identity. The primitive sensing operations used in the present example include Battery, which indicates the battery voltage level, Sonarw, which measures sonar range with the wrist sonar pointed directly forward, and Sweep.Wrist.Roll, which obtains an array of sonar readings by rotating the wrist from left to right. Of these sensed features, Sonarw is eagerly sensed, and the others are lazily sensed. The robot actions here include Forward.10 (move forward 10 inches), Backward.10 (move backward 10 inches), Face.The.Object (turn toward the closest sonar region in front of the robot), and Measure.The.Object (obtain several additional sonar sweeps to determine whether the closest sonar region in front of the robot is a garbage can). The.Object refers to the closest sonar region in front of the robot, as detected by the sense procedure Sweep.Wrist.Roll. This Theo-Agent has been tested by giving it different sets of initial goals, leading it to compile out different sets of stimulus-response rules exhibiting different behaviors. In the simple example presented here, the agent is given three goals: 0 Goal.Closer: approach distant objects. This goal is activated when the Sonarw sense reading is between 25 and 100 inches, indicating an object at that distance. It is satisfied when Sonarw is less that 25 inches, and attended to whenever it is active. 0 Goal.Further: back off from close objects. This is activated when Sonarw is between 3 and 15 inches, satisfied when Sonarw is greater than 15 inches, and attended to whenever it is active. * Goal.Identify.The.Object: determine whether the nearest sonar region corresponds to a garbage can. This is activated when there is an object in front of the robot whose identity is unknown, satisfied when the object identity is known, and attended to whenever it is active and GoaLCloser and Goal.Further are inactive. In order to illustrate the’ operation of the Theo-Agent, consider the sequence of events that results from setting the robot loose in the lab with the above goals, actions, and sensing routines: During the first iteration through its sense-decide-execute loop, it (eagerly) senses a reading of 41.5 from Sonarw, reflecting an object at 41.5 inches. In the decide phase of this cycle it then queries its Chosen.Action slot, which has no cached value, and no associated stimulus-response rules. Thus, it is forced to plan in order to determine a value for Chosen.Action. When queried, the planner determines which goal the agent is attending to, then searches for a sequence of actions which it projects will satisfy this goal. Thus, the planner queries the Attending.To.Goal slot, which queries the Active.Goals slots, which query the ObservedWorld, leading eventually to determining that the Attending.To.Goal is GoaLCloser. The planner, after some search, then derives a two-step plan to execute Forward.10 two times in a row (this plan leads to a projected sonar reading of 21.5 inches, which would satisfy GoaLCloser). The inferred value for the Chosen.Action slot is thus Forward.10 (the first step of the inferred plan). The agent caches the result of each of the above slot queries, along with an explanation that justifies each slot value in terms of the values from which it was derived. This network of explanations relates each belief (slot value) of the agent eventually to sensed features of its Observed.World. In the above scenario the agent had to construct a plan in order to infer its Chosen.Action. Therefore, it formulates a new stimulus-response rule which will recommend this chosen action in future situations, without planning. The agent then executes the action and begins a new cycle by eagerly refreshing the Sonarw feature and deleting any other sensed features (in this case the observed Battery level, which was queried by the planner as it checked the preconditions for various actions). During this second cycle, the stimulus-response rule learned during the first cycle applies, and the agent quickly decides that the appropriate Chosen.Action in the new situation is to execute Forward.10. As it gains experience, the agent acquires additional rules and an increasing proportion of its decisions are made by invoking these stimulus-response rules rather than planning. 3.1. Rule Learning The rule acquisition procedure used by the Theo-Agent is an explanation-based learning algorithm called EBG (Mitchell, et al, 1986). This procedure explains why the Chosen.Action of the Theo-Agent is justified, finds the weakest conditions under which this explanation holds, and then produces a rule that recommends the Chosen.Action under just these conditions. More precisely, given some Chosen.Action, ?Action, the Theo- Agent explains why ?Action satisfies the following property: Justified.Action(?Agent, ?Action) t (1) The Attending.To.Goal of the ?Agent is ?G (2) ?G is Satisfied by result of ?Agent’s plan (3) The tail of ?Agent’s plan will not succeed without first executing ?Action (4) ?Action is the first step of the ?Agent’s plan EBG constructs an explanation of why the Chosen.Action is a Justified.Action as defined above, then determines the weakest conditions on the Observed.World 1054 ROBOTICS ct t (w0 measure.the.object prec.sat?) = nil <--expected.value-- (world159 previous.state) = w0 (w0 battery) = 100 <--observed.value-- (w0 battery observed-value) = 100 (world159 the.object distance) = 22 <--expected.value-- (world159 previous.state) = w0 (w0 face.the.object prec.sat?) = t <--prolog-- (w0 battery) = 100 <--observed.value-- (w0 battery observed.value) = 100 (w0 the-object direction known?) = t (w0 the.object distance) = 22 <--observed.value-- (w0 the.object distance observed.value) = 22 (world159 the.object direction) = 0 <--expected.value-- (world159 previous.state) = w0 (w0 face.the.object prec.sat?) = t <--prolog-- (w0 battery) = 100 <--observed.value-- (w0 battery observed.value) = 100 (w0 the.object direction known?) = t under which this explanation will hold3. Consider, for example, a scenario in which the Hero agent is attending to the goal Goal.Identify.The.Object, and has constructed a two-step plan: Face.The.Object, followed by Measure.The.Object. Figure 3-l shows the explanation generated by the system for why Face.The.Object is its Justified.Action. In this figure, each line corresponds to some belief of the agent, and level of indentation reflects dependency. Each belief is written in the form (frame slot subslot subsubslot . ..)=value. and arrows such as “c-- observed.value--” indicate how the belief above and left of the arrow was inferred from the beliefs below and to its right. For example, the leftmost belief that the Hero’s Justified.Action is Face.The.Object, is supported by the three next leftmost beliefs that (1) the (Hero Attending.To.Goals)=Goal.Identify.Object, (2) the (World376 Goal.Identify.Object Satisfied?)=t, and (3) (WO Measure.The.Object Prec.Sat?)=nil. WO is the current Observed.World, World376 is the world state which is predicted to result from the agent’s plan, and Prec.Sat? is the predicate indicating whether the preconditions of an action are satisfied in a given world state. These three supporting beliefs correspond to the first three clauses in the above definition of Justified.Action4. Notice the third clause indicates that in this case the tail of the agent’s plan cannot succeed since the preconditions of the second step of the plan are not satisfied in the initial observed world. IF (1) Identity of The.Object in Observed.World is not Known (1) Sonarw in Observed.World = ?s (1) Not [3 < ?s < 151 (1) Not [25 < ?s < 1001 (2) Battery in Observed.World > 70 (2) Distance to The.Object in Observed.World = ?dist (2) 15 <= ?dist <= 25 (2,3) Direction to The-Object in Observed.Wor = ?dir (3) Not t-5 <= ?dir <= 51 THEN Chosen.Action of Hero = Face-The-Object Figure 3-2: Rule for Explanation from Figure 3-l *Id produced by the Theo-Agent from the explanation of Figure 3-2 shows the english description of the rule <--prolog-- (w0 the-object direction) = 10 Figure 3- l.- The number to the left of each rule <--observed.value-- (w0 the-object direction observed-value) = 10 Figure 3-1: Explanation for (Hero Justified.Action) = Face.The.Object 3Noticethatthethird clause inthedefinition ofJustified.Action requires that the first step of the plan be essential to the plan’s success. Without this requirement, the definition is too weak, and can produce rules that recommend non-essential actions such as WAIT, provided they can be followedbyotheractions thateventuallyachieverhegoal. 4The fourth clause is not even made explicit, since this is satisfied by defining the rule postcondition to recommend the current action. MITCHELL 1055 precondition indicates the corresponding clause of Justified.Action which is supported by this precondition. For example, the first four lines in the rule assure that the robot is in a world state for which it should attend to the goal Goal.Identify.Object (i.e., they assure that this goal will be active, and that all higher priority goals will be inactive). Of course this rule need not explicitly mention this goal or any other, since it instead mentions the observed sense features which imply the activation of the relevant goals. Similarly, the rule need not mention the plan, since it instead mentions those conditions, labeled (2) and (3), which assure that the first step of the plan will lead eventually to achieving the desired goal. In all, the agent typically learns from five to fifteen stimulus-response rules for this set of goals and actions, depending on its specific experiences and the sequence in which they are encountered. By adding and removing other goals and actions, other agents can be specified that will “compile out” into sets of stimulus-response rules that produce different behaviors. 3.2. Impact of Experience on Agent Reaction Time With experience, the typical reaction time of the Theo- Agent in the above scenario drops from a few minutes to under a second, due to its acquisition of stimulus-response rules and its caching of beliefs. Let us define reaction time as the time required for a single iteration of the sense- decide-execute loop of the agent. Similarly, define sensing time, decision time, and execution time as the time required for the corresponding portions of this cycle. Decision time is reduced by two factors: l Acquisition of stimulus-response rules. Matching a stimulus-response rule requires on the order of ten milliseconds, whereas planning typically requires several minutes. l Caching of beliefs about future world states. The time required by planning is reduced as a result of caching all agent beliefs. In particular, the descriptions of future world states considered by the planner (e.g., “the wrist sonar reading in the world that will result from applying the action Forward.10 to the current Observed.World”) are cached, and remain as beliefs of the agent even after its sensed world is updated. Some cached features of this imagined future world may become uncached each cycle as old sensed values are replaced by newer ones, but others tend to remain. The improvement in agent reaction time is summarized in the timing data from a typical scenario, shown in table 3-l. The first line shows decision time and total reaction time for a sense-decide-execute cycle in which a plan must be created. Notice that here decision time constitutes the bulk of reaction time. The second line of this table shows the cost of producing a very similar plan on the next cycle. The speedup over the first line is due to the use of slot values which were cached during the first planning 1. Construct simple plan: 2. Construct similar plan: 3. Apply learned rules: Decision Time 34.3 set 5.5 set 0.2 set Reaction Time 36.8 set 6.4 set 0.9 set Table 3-I: Effect of Learning on Agent Response Time (Timings are in CommonLisp on a Sun3 workstation) episode, and whose explanations remain valid through the second cycle. The third line shows the timing for a third cycle in which the agent applied a set of learned stimulus- response rules to determine the same action. Here, decision time (200 msec.) is comparable to sensing time (500 msec) and the time to initiate execution of the robot action (200 msec.), so that decision time no longer constitutes the bulk of overall reaction time. The decision time is found empirically to re uire 80 + 14r msec. to test a 9 set of r stimulus-response rules . Of course the specific timing figures above are dependent on the particular agent goals, sensors, training experience, actions, etc. Scaling to more complex agents that require hundreds or thousands of stimulus-response rules, rather than ten, is likely to require more sophisticated methods for encoding and indexing the learned stimulus-response pairings. Approaches such as Rete matching, or encoding stimulus-response pairings in some type of network (Rosenschein, 1985, Brooks, 1986) may be important for scaling to larger systems. At present, the significant result reported here is simply the existence proof that the learning mechanisms employed in the Theo-Agent are sufficient to reduce decision time by two orders of magnitude for a real robot with fairly simple goals, so that decision time ceases to dominate overall reaction time of the agent. 4. Summary, Limitations and Future Work The key design features of the Theo-Agent are: e A stimulus-response system combined with a planning component of broader scope but slower response time. This combination allows quick response for routine situations, plus flexibility to plan when novel situations are encountered. e Explanation-based learning mechanism for incrementally augmenting the stimulus-response component of the system. When forced to plan, the agent formulates new stimulus-response rules that SRules are simply tested in sequence with no sophisticated indexing or parallel match algorithms. 1056 ROBOTICS produce precisely the same decision as the current plan, in precisely the same situations. 0 The agent chooses its own goals based on the sensed world state, goal activation conditions and relative goal priorities. Goals are explicitly considered by the agent only when it must construct plans. As the number of learned stimulus-response rules grows, the frequency with which the agent explicitly considers its goals decreases. 0 Caching and dependency maintenance for all beliefs of the agent. Every belief of the agent is . cached along with an explanation that indicates those beliefs on which it depends. Whenever the agent sense inputs change, dependent beliefs which are affected are deleted, to be recomputed if and when they are subsequently queried. 0 Distinction between eagerly and lazily refreshed sense features. In order to minimize the lower bound on reaction time, selected sense features are eagerly updated during each agent cycle. Other features are lazily updated by deleting them and recomputing them if and when they are required. This provides a simple focus of attention mechanism that helps minimize response time. In the future, we hope to allow the agent to dynamically control the assignment of eagerly and lazily sensed features. There are several reasonable criticisms of the current TheoAgent architecture, which indicate its current limitations. Among these are: 0 The kind of planning the TheoAgent performs may be unrealistically difficult in many situations, due to lack of knowledge about the world, the likely effects of the agent’s actions, or other changes in the world. One possible response to this limitation is to add new decision-making mechanisms beyond the current planner and stimulus-response system. For example, one could imagine a decision-maker with an evaluation function over world states, which evaluates actions based on one-step lookahead (similar to that proposed in Sutton’s DYNA (Sutton, 1990).). As suggested in (Kaelbling, 1986), a spectrum of multiple-decision makers could trade off response speed for correctness. However, learning mechanisms such as those used here might still compile stimulus- response rules from the decisions produced by this spectrum of decision-makers. l Although the TheoAgent learns to become increasingly reactive, its decisions do not become increasingly correct. The acquired stimulus- response rules are only as good as the planner and action models from which they are compiled. We are interested in extending the system to allow it to inductively learn better models of the effects of its actions, as a result of its experience. Preliminary results with this kind of learning using a hand-eye robot are described in (Christiansen, et al., 1990, Zrimic and Mowforth, 1988). * The current planner considers the correctness of its plans, but not the cost of sensing or effector commands. Therefore, the plans and the stimulus- response rules derived from them may refer to sense features which are quite expensive to obtain, and which contribute in only minor ways to successful behavior. For instance, in order to guarantee correctness of a plan to pick up a cup, it might be necessary to verify that the cup is not glued to the floor. The current system would include such a test in the stimulus-response rule that recommends the grasp operation, provided this feature was considered by the planner. We must find a way to allow the agent to choose which tests are necessary and which can be ignored in order to construct plausible plans that it can then attempt, and recover from as needed. t3 Scaling issues. As noted in the previous section, the current robot system requires only a small set of stimulus-response rules to govern its behavior. We must consider how the approach can be scaled to more complex situations. Some avenues are to (1) explore other strategies for indexing learned knowledge (e.g., index rules by goal, so that many subsets of rules are stored rather than a single set), (2) develop a more selective strategy for invoking learning only when the benefits outweigh the costs, and (3) consider representations of the control function that sacrifice expressive precision for fixed computational cost (e.g., fixed topology neural networks with constant response time). We believe the notion of incrementally compiling reactive systems from more general but slower search- based systems is an important approach toward extending the flexibility of robotic systems while still achieving respectable (asymptotic) response times. The specific design of the Theo-Agent illustrates one way to organize such a system. Our intent is to extend the current architecture by adding new learning mechanisms that will allow it to improve the correctness of its action models and its abilities to usefully perceive its world. These additional learning capabilities are intended to complement the type of learning presented here. Acknowledgements. This work is based on extensions to earlier joint work with Jim Blythe, reported in (Blythe and Mitchell, 1989). I am most grateful for Jim’s significant contributions to the design of the Theo-Agent. Thanks also to the entire Theo group, which produced the Theo system on which Theo-Agent is built. Theo provides the underlying inference, representation, and learning MITCHELL 1057 mechanisms used by the Theo-Agent. Finally, thanks to Long-Ji Lin who developed a number of the routines for interfacing from workstations to the robot. This research is supported by DARPA under research contract NOOO14-85-K-0116 and by NASA under research contract NAGW- 1175. References IN I21 [31 [41 151 @I [71 181 Agre, P. and Chapman, D. Pengi: An Implementation of a Theory of Activity. In Proceedings of the National Conference on Artificial Intelligence, pages 268-272. Morgan Kaufmann, July, 1987. Blythe, J., and Mitchell, T. On Becoming Reactive. In Proceedings of the Sixth International Machine Learning Workshop, pages 255-259. Morgan Kaufmann, June, 1989. Brooks, R.A. A Robust Layered Control System for a Mobile Robot. IEEE Journal of Robotics and Automation 2(1), March, 1986. Christiansen, A., Mason, M., and Mitchell, T. Learning Reliable Manipulation Strategies without Initial Physical Models. In Proceedings of the IEEE International Conference on Robotics and Automation. IEEE Press, May, 1990. Kaelbling, L.P. An Architecture for Intelligent Reactive Systems. In M.P. Georgeff and A.L. Lansky (editor), Reasoning about Actions and Plans: Proceedings of the 1986 Workshop. Morgan Kaufmann , 1986. Laird, J.E. and Rosenbloom, P.S. Integrating Planning, Execution, and Learning in Soar for External Environments. In Proceedings of AAAI ‘90. AAAI, 1990. Lin, L., Philips, A., Mitchell, T., and Simmons, R. A Case Study in Robot Exploration. Robotics Institute Technical Report CMU- RI-89-00 1, Carnegie Mellon University, Robotics Institute, January, 1989. Mitchell, T.M., Keller, R.K., and Kedar-Cabelli, S. Explanation-Based Generalization: A Unifying View. Machine Learning 1(1), 1986. PI WI l3u In1 r131 iI41 1151 IX51 Mitchell, T. M., J. Allen, P. Chalasani, J. Cheng, 0. Etzioni, M. Ringuette, and J. Schlimmer. Theo: A Framework for Self-improving Systems. In VanLehn, K. (editor), Architectures for Intelligence. Erlbaum, 1990. Pommerleau, D.A. ALVINN: An Autonomous Land Vehicle In a Neural Network. In Touretzky, D. (editor), Advances in Nerual Information Processing Systems, Vol. 1. Morgan Kaufmann, 1989. Rosenschein, S. Formal Theories of Knowledge in AI and Robotics. New Generation Computing 3:345-357,1985. Schoppers, M.J. Universal Plans for Reactive Robots in Unpredictable Environments. In Proceedings of the Tenth International Joint Conference on Artificial Intelligence, pages 1039-1046. AAAI, August, 1987. Segre, A.M. Machine Learning ofRobot Assembly Plans. Kluwer Academic Press, 1988. Sutton, R. First Results with DYNA, an Integrated Architecture for Learning, Planning, and Reacting. In Proceedings of AAAI Spring Symposium on Planning in Uncertain, Unpredictable, or Changing Environments, pages 136-140. AAAI, March, 1990. Tan, M. CSL: A Cost-Sensitive Learning System for Sensing and Grasping Objects. In Proceedings of the 1990 IEEE International Conference on Robotics and Automation. IEEE, May, 1990. Zrimic, T., and Mowforth, P. An Experiment in Generating Deep Knowledge for Robots. In Proceedings of the Conference on Representation and Reasoning in an Autonomous Agent. 1988. 1058 ROBOTICS
|
1990
|
52
|
970
|
A Hierarchical Planner that Generates its Own Hierarchies Jens Christensen* Computer Science Department Stanford University Stanford, CA 94305 jens@cs.stanford.edu Abstract PABLO’ is a nonlinear planner that reasons hi- erarchically by generating abstract predicates. PABLO’s abstract search spaces are generated au- tomatically using predicate relaxation, a new tech- nique for defining hierarchies of abstract predi- cates. For some domains, this mechanism gener- ates hierarchies that are more useful than those created by previous techniques. Using abstrac- tions can lead to substantial savings in compu- tation time. Furthermore, PABLO can achieve a limited form of reactivity when reasoning with relaxed predicates. These abstractions can be viewed as small reactive plans, and our method as an approach to dynamically combining these into useful nonlinear plans. Introduction It has long been known that abstractions can greatly reduce search complexity [Sacerdoti, 1974, Korf, 19871. Wilkins [Wilkins, 19881 has noted that there has been much confusion in the planning literature about what constitutes an abstraction level. Abstraction usually suggests ignoring details and concentrating on impor- tant aspects of a problem. Most planners, beginning with NOAH [Sacerdoti, 1977, Wilkins, 19881, employ a technique we will label operator abstraction. The idea is that more abstract operators are defined in terms of less ab- stract ones. In a planner that allows operator abstrac- tion, each abstraction level consists of a set of opera- tors (possibly decomposable) and remaining subgoals. A level consisting only of primitive operators with no outstanding subgoals is a complete, executable plan. In NOAH, these levels were explicitly stored in a procedural net. However, in NOAH and other planners that employ procedural nets, these levels may or may *This work was partially supported by NASA Grant NCCZ-494 and by Texas Instruments Contract No. 7554900. ‘PABLO stands for Predicate ABstraction Logic, and is also the first name of a certain, famous, abstract painter. 1004 ROBOTICS not form a proper abstraction hierarchy. For the levels in a procedural net to be meaningful abstract levels, it is necessary that the operators in the system truly be defined in terms of other, less abstract, operators. Furthermore, operator abstraction in these planners is not automatic, but rather is left to the encoder of the domain, who must decide on how the operators should be abstracted. There is another abstraction technique encountered in the planning literature wherein abstraction is based not on the operators but rather on the states of the domain. We will label this type of abstraction state abstraction. State abstr action was introduced to nlannine: bv ABSTRIPS [Sacerdoti, 19741. Although - ABSTRIPS proved state abstraction to be an effective abstrac- tion mechanism, few planners employ this technique. In this paper, we introduce a new technique for au- tomatically performing state abstraction - predicate rehxtion. The technique has been implemented in PABLO, an abstract nonlinear planner. Predicate Relaxation Predicate relaxation is a method for weakening a pred- icate so that it holds in more states than it otherwise would. Specifically, we would like to consider a predi- cate P true, not only in those world states in which it is, in fact, true, but also in those states from which P can be made true by one or more operator applications. In a domain with m operators, given a predicate P, we define P,Fel as follows: eel = P P” rel = P,“,,lv Reg(*pi, P,“,Tl) where Reg(Qpi , P) is the regression of predicate P through operator Opi. Obviously, Pre, (n+l’ holds in a superset of the world states where Pp”,l holds. Furthermore, if PFel holds in state s, there exists a plan which can achieve P in n steps or less, from state s. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. If PEl holds, but &;e’er does not, one can say that PFe, is more of a “detail” than &Fe,, since P can be achieved more easily that Q. Predicate relaxation provides a gradual widening of the states in which a predicate holds. In ABSTRIPS, a predicate can either hold in those states in which it was intended to hold, or, when its criticality value is less than the current threshold, hold in all states of the domain. This change in the semantics of a predicate can be quite sharp. Predicates abstracted with predicate relaxation, however, avoid this semantic cliff, since the set of states in which they hold is gradually enlarged at each relaxation level. PABLO PABLO is a nonlinear planner that operates in a hier- archy of abstraction spaces. PABLO employs STRIPS- style operators [Fikes and Nilsson, 19711. A plan con- sists of a strict partial order of instantiated oper- ators. During planning, PABLO makes use of a modified version of TWEAK’s modal truth criterion [Chapman, 19871, extended to handle abstract predi- cates. In an initial relaxation phase, PABLO creates the relaxed definitions for the predicates appearing in the goals and in the preconditions of operators. This need only be done once for each domain. The general idea during planning is that PABLO first consider the most important predicates, and then consider successively less important predicates. This is accomplished by associating each planning level with a relaxation level, and planning with relaxed predicates of that level; when planning at level Ic, every predi- cate P in the preconditions of operators and goals is replaced with P,k,,. When moving down abstraction levels, if newly cre- ated subgoals appear in different sections of the plan, PABLO attempts to achieve them independently. The rationale for this being that these predicates were con- sidered “details” at the higher level and presumably do not have global consequences. In cases where this assumption fails, the consequences can, of course, be costly, in terms of computation time. However, in our experience the increased efficiency outweighs this risk. Example Figure 1: Towers of Hanoi A well known problem with many inherent abstractions is the Towers of Hanoi problem. The operator given to PABLO is the following: Move(x,y,z) P:{Smaller(x,z),Movable(x),On(x,y), Clear(x),Clear(z)} D:{On(x,y),Clear(z)} A:{On(x,z),Clear(y)} See figure 2 for a trace of PABLO solving the 3 disk Towers of Hanoi problem. The plan at the highest level of abstraction consists of Move(C,x,PS), where x is a variable. At this level, all its preconditions are satisfied P%I 2 (C) is satisfied since it can be achieved in two steps). Abstraction Level 2 Abstraction Level 1 Base Level Figure 2: Towers of Hanoi Trace When we move down to the next abstraction level Clear$,l (C) b ecomes Cleariel(C) which is not satisfied in our initial state, since we cannot clear C in one step. PABLO therefore plans to achieve Clea&(C) by adding the action Move(B,C,y) to the plan. In doing so, it undoes On&,,(B,C), which PABLO then plans to reachieve, using the action Move(B,y,C). At this point, the plan at the first level of abstraction is complete since all the first level relaxations of the goals and pre- conditions are satisfied. Planning is then completed at the base level using the original predicates of the domain. In this case, PABLO has discovered and made use of the inherent abstractions in the domain. Empirical ev- idence, presented in [Christensen, 19901 shows a reduc- tion of planning time from exponential in the number of operators, to linear. This conforms to the theoretical analyses in [Korf, 1987, Knoblock, 19901, on the poten- tial computational advantages of using abstraction in planning. Comparison with ABSTRIPS ABSTRIPS would assign the following criticality values to the predicates in the domain: Move(x,Y,z) P:{[3]Smaller(x,z),[3]Movable(x),[2]0n(x,y), [2]Clear(x),[2]Clear(z)} D:{On(x,y),Clear(z)} A:{On(x,z),Clear(y)) CHRISTENSEN 1005 ABSTRIPS creates only one level of abstraction in this domain. When solving the problem, after finish- ing the abstract level, the plan consists of one action Move(C,x,PS). Although this is of some aid in devel- oping the plan at the base level, it is not as useful as PABLO’s hierarchy. ABSTRIPS’s hierarchies are domain-dependent but problem-independent. The number of different criti- cality values, and therefore the number of abstraction levels, of ABSTRIPS is constrained by the number of different predicates of the domain. For the 4 disk Tow- ers of Hanoi, ABSTRIPS still has only one abstraction level, whereas PABLO generates 3 abstraction levels. In general, for the n disk Towers of Hanoi problem, PABLO generates n- 1 abstraction levels, whereas AB- STRIPS still creates only one abstraction level. For other recent approaches to abstraction see [Benjamin, 19901. Limited Reactivity There is currently great interest in the designing of sys- tems which provide timely responses in time-stressed situations [Nilsson, 1990, Schoppers, 19871. Many re- searches have distanced themselves from traditional planning methods on the grounds that these are often slow and impractical. For example, suppose a planner is given the problem in figure 3 to solve. A B II C D Initial State Goal Figure 3: Planning Problem We are given the following two operators: PUTON(x,y) TABLEOPR(x) P:{FCl;(xClear(y), P:{Clear(x),On(x,y)) D:(Cleai(y),On(x,z)) D:{On(x,y)} A:{Clear(z),On(x,y)) A:{Clear(y),On(x,TABLE)) Using the classic nonlinear planning method a trace of the plan at various stages of development might look as in figure 4. One notable feature of this trace is that until the fi- nal plan is produced, the classical planner is not aware of any executable actions to perform in the initial state. The actions Puton(B,C) and Puton(C,D) are not directly executable in our initial state. Should the planner be interrupted at any time during planning it would not have a reasonable action to perform. This is Pnton(C,D) Pnton(B,C) Figure 4: Classic Planning Trace one reason traditional planning methods have generally been regarded as unsuitable for real-time tasks. The new proposed systems have generally involved compiling large sections of the search space into effi- cient caches which compute appropriate responses to situations that might be encountered. We will take the liberty of referring to the types of structures pro- duced by these approaches as reactive plans. As has been pointed out by various researchers, most notably Ginsberg [Ginsberg, 19891, reactive plans have several drawbacks. Principally, a reactive plan grows exponen- tially with the size of a domain, which can make them unwieldy for practical purposes. Besides these reactive planning methods, several other alternatives to classical planning have been sug- gested. Some favor abandoning backward chaining plan-space search in favor of a forward search of the state space [Washington, 19891. The advantage of this approach is that an executable action is available as soon as an action has been found to be applica- ble in the initial state. Unfortunately, until we en- counter the final solution during the forward search, we have no guarantee that our current sequence of ac- tions will eventually lead to the goal. Further, we can- not take advantage of the least-commitment implicit in the nonlinear representation of plans. Finally, a for- ward search, so as not to be completely blind, needs a domain-specific heuristic, thereby reducing domain- independence. An extension of the above is proposed by Drum- mond [Drummond, 19891, where situated control rules are used to advise an executor on appropriate actions to take. This is a promising idea, but because it too is not goal-directed, its usefulness might be somewhat limited. Another approach one can take, within the classi- cal planning context, is that of planning down a left- recursive wedge of the partial plan in case of an in- terruption. The idea is to repeatedly expand the left- most-outstanding preconditions until an action is en- - - countered with all its preconditions satisfied. In some 1006 ROBOTICS circumstances, this approach might be successful. Un- fortunately, the time to plan in this manner is possibly unbounded, since interactions might be encountered, necessitating backtracking. The method we propose retains the power of par- tially ordered plan representations, but also allows the planner to identify plausible executable actions early in the planning process. Reactive Reasoning with PABLO The problem we are addressing is that of providing a plausible executable action should PABLO be inter- rupted before it has formed a complete plan. Ideally, we would like to provide as long a sequence of exe- cutable actions as possible. Towards this end, we can store, along with each re- laxed predicate, the operators through which the predi- cate was regressed during the relaxation process. Then, during planning, when a relaxed predicate is deter- mined to hold in a situation, the operator through which the predicate was last regressed is automatically identified. For example, this is the first level relaxation of On(x,y). Odd (x, Y) On x,Y (y 1 TkBLE) A Clear(x) A 3 z On(x,z) (y # TABLE) A Clear(x) A Clear(y) A 1 2 z. On(x,z) ’ . ’ .- ’ I Puton( The logical expressions are conditions under which the predicate should be determined to hold. The op- erators through which the predicate was regressed to arrive at the expression are shown in the right side of the table. In this case, since it is a first level relaxation, only one operator is included. During planning, the relaxation table is examined from top to bottom. When an expression is found that is satisfied in the current state, the relaxed predicate is said to be asserted in that state. We also say the relaxed predicate is grounded in this state. Once PABLO has completed a plan at one level of abstraction, and is working at the next lower level, it can utilize the extra information stored along with the relaxed predicates that hold at the higher level, should it be interrupted. PABLO chooses a plausible action by examining the preconditions of the earliest action(s) of the plan. If one of these actions has all its precondi- tions satisfied at the base level, the action is obviously executable. If no such action exists, PABLO can choose from among the leftmost operators associated with the sat- isfied predicate relaxations that are grounded in the initial situation. All relaxed predicates must be satis- fied since the plan was completed at the higher level. Any of the actions collected in this manner are exe- cutable. See figure 5 for a trace of PABLO solving the pre- vious example. It should be noted that PABLO solves the example in 6.6 seconds with the relaxation hierar- chy versus 68.5 seconds without it. [aI Abstraction Level 2 Abstraction Level 1 Figure 5: Pablo’s Planning Trace After completing planning at the second level of abstraction the plan consists of one operator: Pu- ton(B,C). This is because all preconditions of Pu- ton(B,C) are satisfied at this level of abstraction, and because the remaining goals, O&(A, B) and Onzel(C, D) are also satisfied. As PABLO moves down to the first abstraction level, the goal Oniel(C, D) is no longer satisfied since it re- quires two steps to accomplish. PABLO grows the plan by adding the operator Puton(C,D) to achieve this goal. Notice that at the first level of abstraction all preconditions to Puton(C,D) hold, since D is clear and block C can be cleared in one step. PABLO then completes the plan at the base level. Now, suppose PABLO is interrupted after it has completed planning at abstraction level 2. At this level, there are three predicates that hold abstractly, i.e., the components of their relaxed definitions that are satis- fied have non-null operator lists associated with them. These are Clea& (B), Cl ea&(C), and Onfel(C, D). To see this, examine the second level predicate relaxation of Clear(x). ~1 The above table has been simplified by removing subsumed expressions. For instance, the result of re- gressing Clear(x) through Puton(y,z) is 3y, 2 On(y, x) A Clear(y) A Clear(z) This expression is not included in the table since it is subsumed by the regression of Clear(x) through Tableopr( y ) . CHRISTENSEN 1007 When ClearFel(x) is instantiated in our plan, with variable x bound to C, Clear&.,(C) becomes: Clea& (C) Clear C On(D,C) A Clear(D) ITableopr (D)] 3 y,z Cn(y,z) A Clear(y) A . On(z,C) [Tableopr(y),Tableopr(z)] As can be seen from the predicate relaxation defini- tion, Clea&,(C) holds because On(D,C) /\ Clear(D), and the leftmost regressed operator associated with this expression is Tableopr(D). In brief, the three re- laxed predicates hold in the initial state for the follow- ing reasons: Clear&l(C) On(D,C) A Clear(D) [Tableopr(D)] Clea&(B) On(A,B) A Clear(A) [Tableopr(A)] O&(C, D) Clear(D) A On(D,C) [Tableopr(D), Puton(C,D)] The above relaxed predicates are grounded in the ini- tial state. If PABLO is interrupted after having com- pleted planning at abstraction level 2, it can choose from among the identified action sequences that are ex- ecutable in the initial state. In this case, it can propose executing Tableopr(D), Tableopr(A), or Tableopr(D) - Puton(C,D). Th is can be determined as soon as the first level of abstraction has been completed, early in the planning process. In this example, it is done after only 15% of the total planning time. If necessary, PABLO can construct a substantial por- tion of the plan, even at this early stage. First, the lists of operators associated with the abstractly sat- isfied predicates are collected. A plan is built by re- peatedly appending applicable sequences of operators. When no more applicable sequences exist, if there is some action in the original plan that is applicable in the last state of this provisional plan, the action is ap- pended to it. We continue appending to the provisional plan in this manner until we have no more sequences of operators or actions in the plan from which to choose. See figure 6 for the incomplete plan constructed us- ing this technique. The full algorithm can be found in [Christensen, 19901. Tableopr(D) Puton(C,D) Tabieopr (A) Puton(B,C) Figure 6: Provisional Plan The plan is almost complete, the only remaining ac- tion is Puton(A,B). Once PABLO commits to the first portion of the plan, developing the remaining portion can be considerably easier. Here, there is little interaction among the executable alternatives. However, there are obviously cases where such interactions exist. Of course, the only way to discover and resolve conflicts based on such interac- tions is to continue planning. Until a complete plan is produced, we cannot guarantee that the optimal ac- tion will be chosen by PABLO (or any other planner), should it be interrupted. This technique, as opposed to the traditional planning algorithm, produces viable alternatives early on in the planning process. Given more time, PABLO will complete plans at succeedingly lower levels, thereby resolving conflicts not discovered at higher levels, and so producing more reliable an- swers. Our method, in effect, provides a primitive any- time algorithm for planning [Dean and Boddy, 19881. Unlike a forward search of the state space, PABLO can take advantage of the least-commitment implicit in nonlinear plans. Furthermore, when it is inter- rupted, its choice for a plausible executable action is derived from a complete abstract plan, which provides a global constraint on this action. An interrupted for- ward state-space search on the other hand, can only provide local constraints on its choice of executable ac- tions. Unlike the technique of continuing planning down the leftmost wedge of the plan after an interruption, our approach requires only a bounded computation time to produce an executable action after an inter- ruption. To see this, note that the executable actions are automatically identified after planning at the high- est level of abstraction has been completed. Reactive Plans The trace of the relaxation of a predicate is in effect a reactive plan for achieving that predicate. See figure 7 for an illustration of the definition of the Or&,(x, y) predicate as a reactive plan. Notice that some pred- icates in the reactive plan are not further regressed. This is because these are preconditions to the operator that we do not wish to plan to achieve, but rather just check that they hold. These predicates are specified in the operator definitions given to PABLO. During planning, when a relaxed predicate is determined to hold, the path through the reactive plan that will lead to the establishment of the predicate is automatically identified. Our technique is a method for handling these small reactive plans. We believe that this is a more promis- ing approach to reactivity than constructing large, un- wieldy reactive plans which risk succumbing to space restrictions very quickly. Each individual plan is re- stricted in size and can be used by the planner on dif- ferent instantiations of the same predicate. Each reactive plan in our system has a clear purpose, namely to achieve a particular predicate. Unlike other reactive planning techniques which must construct a new reactive plan for each combination of goals encoun- tered (modulo some parameters to the reactive plan), PABLO can reutilize the reactive plan definitions for any goals specified in the domain. 1008 ROBOTICS Figure 7: Reactive plan for Or&(x, y) If our domain is large enough we risk creating ab- straction definitions that are too large, although they will always be considerably smaller than reactive plans created for entire domains, since we are only consider- ing reactive plans for individual predicates. With PABLO, we can extend the planning method to restricted reactive plans, e.g., allow only commonly encountered conditions in the relaxed definitions. Al- though this reduces the number of abstractions iden- tified at the higher levels, each predicate can be more quickly identified to hold abstractly. PABLO is robust in the sense that if a predicate is not deemed to hold abstractly, it can plan to achieve it. This is something systems which rely solely on reactive plans cannot do. Conclusion We have presented PABLO, a nonlinear hierarchi- cal planner that automatically generates abstraction spaces using predicate relaxation. PABLO is able to solve some problems, e.g., Towers of Hanoi, making full use of the abstractions inherent in the domain. Fur- thermore, PABLO achieves a limited form of reactivity in that it can produce a sequence of executable actions should it be interrupted before the final plan has been completed. Acknowledgements I wish to thank my adviser Nils Nilsson for many help- ful discussions related to this work. Matt Ginsberg, Craig Knoblock, Andrew Kosoresow, Alon Levy, Karen Myers, Eunok Paek, Yoav Shoham, Rich Washington, David Wilkins, and the Principia group at Stanford have also made many helpful suggestions. References [Benjamin, 19901 Benjamin, D.P., (Ed.), Change of Representation and Inductive Bias, Boston, MA: Kluwer, 1990. [Chapman, 19871 Chapman, D., “Planning for Con- junctive Goals,” Artificial Intelligence, v 32: 333- 378, July 1987. [Christensen, 19901 Christensen, J., “Abstraction in Planning,” forthcoming PhD Dissertation, Stanford University, 1990. [Dean and Boddy, 19881 Dean, T. and Boddy M., “An Analysis of Time-dependent Planning,” in Proceed- ings AAAI-88, pages 49-54, 1988. [Drummond, 19891 Drummond, M., “Situated Control Rules,” Proceedings of the First International Con- ference on Principles of Knowledge Representation and Reasoning,” Toronto, Canada, 1989. [Fikes and Nilsson, 19711 Fikes, R. E. and Nilsson, N. J “STRIPS: A new Approach to the Application 0; Theorem Proving to Problem Solving,” Artificial Intelligence, 2(3-4): 189-208, 1971. [Ginsberg, 19891 Ginsberg, M., “Universal Planning: an (Almost) Universally Bad Idea,” in AI Magazine, vol. 10, no. 4, winter 1989. [Knoblock, 19901 Knoblock, C., “A Theory of Abstrac- tion for Hierarchical Planning,” in D.P. Benjamin (Ed.), Change of Representation and Inductive Bias, Boston, MA: Kluwer, 1990. [Korf, 19871 Korf, R. E., “Planning as Search: A Quantitative Approach,” Artificial Intelligence, 33(l): 65-88, 1987. [Nilsson, 19901 Nilsson, N. J., Moore, R., Torrance, M. C., “ACTNET: An Action-Network Language and its Interpreter (A Preliminary Report),” forthcom- ing. [Sacerdoti, 19741 Sacerdoti, E., “Planning in a Hierar- chy of Abstraction Spaces,” Artificial Intelligence, v 5: 115-135, 1974. [Sacerdoti, 19771 Sacerdoti, E., A Structure for Plans and Behavior, Elsevier, North-Holland, New York, 1977. [Schoppers, 19871 Schoppers, M. J., “Universal Plans for Reactive Robots in Unpredictable Environ- ments ,” in Proceedings AAAI-87, 1987. [Washington, 19891 Washington, R., “Abstraction Planning in Real Time,” Ph.D. Thesis Proposal, un- published, 1989. [Wilkins, 19881 Wilkins, D. E., Practical Planning, Morgan Kaufman, San Mateo, California, 1988. CHRISTENSEN 1009
|
1990
|
53
|
971
|
Indexical Knowledge in Robot Plans* Yves Lesphance and Hector J. Levesquet Dept. of Computer Science University of Toronto Toronto, Ont. M5S lA4 Canada lesperan@ai.toronto.edu and hector@ai.toronto.edu Abstract Robots act upon and perceive the world from a particu- lar perspective. It is important to recognize this relativ- ity to perspective if one is not to be overly demanding in specifying what they need to know in order to be able to achieve goals through action. In this paper, we show how a formal theory of knowledge and action pro- posed in (Lesperance 1989) can be used to formalize several kinds of situations drawn from a robotics do- main, where indexical knowledge is involved. Several examples treated deal with the fact that ability to act upon an object does not require de re knowledge of the object or its absolute position; knowledge of its rela- tive position is sufficient. It is shown how the fact that perception yields indexical knowledge can be captured. We also point out the value of being able to relate in- dexical knowledge and objective knowledge within the same formalism through an example involving the use of a map for navigation. Finally, we discuss a problem raised by some higher-level parametrized actions and propose a solution. Introduction Robots act upon their world from a particular perspec- tive, a particular place and moment in time. The same action done at different places and times has different effects; this is what we call the indexicality or context- sensitivity of action. Not surprisingly then, the knowl- edge that is directly required for action is often index- ical, that is, relative to the agent’s perspective. Simi- larly, the knowledge supplied by perception is indexical knowledge. Previous formal accounts of the ability of robots to achieve goals by doing actions, such as that of Moore (1980; 1985) and Morgenstern (1987), have ignored this, and thus end up imposing unnecessar- ily strong knowledge requirements upon agents before sanctioning their ability; they fail to properly specify the knowledge prerequisites and effects of actions. The *This research was made possible in part by support from the Natural Science and Engineering Research Council of Canada. + Fellow of the Canadian Institute for Advanced Research 1030 ROBOTICS deficiency is discussed by Haas (1986) within the con- text of a syntactic account of belief, but he does not formalize his proposals. In a previous paper (Lespdrance 1989), we proposed a theory of knowledge, action, and ability that captures the distinction between indexical knowledge and objec- tive knowledge and permits a proper specification of the knowledge prerequisites and effects of actions. The functioning of the theory was then illustrated through the example of an agent making a phone call that may be long distance. In this paper, we examine applications of the theory in the robotics domain, where indexical- ity plays a particularly important role. We show how actions can be formalized, given that perception yields indexical knowledge, and that ability to act upon an object does not require de re knowledge of the object or its absolute position. We also show how indexical knowledge and objective knowledge can be related in our framework to deal with the use of maps for naviga- tion. We discuss the representational issues that arise, which have general relevance to the formalization of ac- tions with indexical knowledge prerequisites or effects. Our ability to handle these kinds of situation provides further evidence for the adequacy of our theory. Fi- nally, we discuss problems that arise in handling some higher-level actions with object parameters. Before we can present these applications and discuss these issues, we must first introduce our framework; this is done in the next section. The Formalism Overview Our theory of knowledge, action and ability is embod- ied in a first-order modal logic. The version described here involves several revisions from that presented in (Lesperance 1989); additional motivation is given there. A detailed exposition of the logic and its properties will be available in (Lesperance 1990). The primary concern of our theory is the formaliza- tion of indexical knowledge, so let’s start there. When one has indexical knowledge, for example when one knows that one is currently hungry, what is known is a “proposition” that is relative. It may be rela- From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. tive to the knower, or to the time of the knowing, or perhaps to other aspects of the context. One typi- The formula Know(p) is used to represent the fact that self (i.e., the agent of the context) knows at time tally expresses such relative propositions with sentences containing context-sensitive elements such as ‘I’, ‘now’, ‘here’, ‘this person’, etc. Our logic reflects this: its for- mulas contain elements whose interpretation depends on the context as well as the circumstances. The logical symbols self and now are indexical terms that refer re- spectively to the agent component and time component of the context .l Non-logical symbols will also typically depend on the time of the context for their evaluation; for example, HUNGRY(U) might represent the fact that the agent assigned to variable a is hungry at the time of the context. They can also depend on the agent compo- nent of the context; for example, THIRSTY might mean that the agent of the context is thirsty at the time of the context. We model a context simply as a pair consisting of an agent and a time. This provides adequate semantics for many indexicals expressions. For instance, the indexical here can be taken to stand for the term Pos(seIf), that is, ‘the position of the agent of the context’. In other cases, one may be forced to be more specific than would be required in a natural language; for instance, one may have to say something like ‘the person at such and such relative position from self at time now’ rather than ‘this person’. Informally, our logic only captures index- ical expressions that are functions of self and now.2 Thus, our semantics evaluates formulas with respect to indices, which consist of a possible-world, modeling the objective circumstances, and an agent and time, modeling the context. We talk about a formula being satisfied by a model, index, and variable assignment. Our semantics for knowledge is a simple general- ization of the standard possible-world scheme (Kripke 1963): the knowledge accessibility relation K is taken to hold over indices. ((w, a, t), (w’, a’, t’)) E K if as far as agent a at time t in world w knows, it may be the case that w’ is the way the world actually is and he is a’ and the current time is t’. Thus, we model the knowl- edge state of an agent at a time in a world by a set of indices, which characterizes not only which worlds are compatible with what the agent knows but also which points of views upon these worlds are compatible with what he knows. ‘self and now are not intended to be formal counter- parts of particular natural language words and often behave quite differently from any such counterparts. 2We view the question of whether the semantics of in- dexicals like ‘you’ and demonstratives like ‘this person’ can be captured by treating them as functions of self and now as open. Such a reduction would undoubtedly be complex, but it is not clear how such indexical expressions could play a causal role in cognition without there being such a reduc- tion. But since we are primarily concerned with modeling action and its relationship to knowledge rather with provid- ing a formal semantics for natural language, we can afford to remain uncommitted on this issue. now (i.e.,‘the time %f the context) that cp. If ‘p con- tains indexical elements, Know(v) should be taken as attributing indexical knowledge, that is, knowledge the agent has about himself and the current time. For ex- ample, Know(HOLDING(x)) could mean that the agent knows that he himself is currently holding the object denoted by CC. An important advantage of our approach is that one can still model properties of knowledge by imposing constraints upon the accessibility relation K. We re- quire K to be reflexive and transitive, which means that the principles of modal system S4 hold for knowledge. The approach can be adapted for modeling belief by changing the constraints. This treatment of indexical knowledge was inspired by informal proposals by Perry (1979) and especially Lewis (1979). The operator By is used to say that an indexi- cal “proposition” holds for an agent other than that of the context currently in effect. For example, BY@, Know(cp)) would say that agent a knows that cp. The argument formula is evaluated at an index whose agent component is the denotation of a. We want to be able to make both eternal and index- ical temporal assertions, express relations between in- dexically specified and objectively specified times, talk about agents knowing what time it is, etc. Due to this, time is reified in our logic, that is, terms that denote time points are included. Ordinary predicates, for in- stance HOLDING in the example above, are taken to represent static relations. As we have seen, atomic formulas involving such predicates are taken to assert that the associated relation holds at time now. One asserts that an agent does an action using the logical symbol Does, which functions as a predicate. For ex- ample, Does(GRASP,t) can be used to represent the fact that self does the action of grasping, from now to time t. The operator At is used to say that a state of affairs holds at a time other now. For example, At@, HOLDING(Z)) could mean that self is holding 2 at time t. The argument formula is evaluated at an index whose time is the denotation of t. The temporal aspects of the formalism were influenced by the work of Shoham (1987), Allen (1984), and McDermott (1982), as well as by the first-order temporal logic R described by Rescher and Urquhart (1971). It is possible to express the occurrence of many types of complex actions using the constructs intro- duced above. We have developed a set of definitions that make it easy to state the occurrence of sequen- tially composed or conditional actions.3 Any account of the ability of agents to achieve goals 3Note that the expressive power of our temporal logic is not limited to this class of actions; actions involving non- determinism, concurrency, multiple agents, definite times, etc. can be represented. But our formalization of ability is limited to actions belonging to this class. LESP&ANCE AND LEVESQUE 103 1 by doing actions must be based on consideration of what actions are physically possible for agents and of what effects necessarily hold at the conclusion of these actions. In our framework, these notions are captured through modal operators for ‘historical’ ne- cessity and possibility, whose semantics involves a re- lation over a set of possible courses of events (linear time frames). The operator •I corresponds to histor- ical necessity, that is, what is necessary given every- thing that has happened up to and at time now. For example, 0 (Does(PICKUP, t) > At(t, HOLDING(X))) says (rightly or wrongly) that if the agent does action PICKUP from now to time t, then he will necessarily be holding x at time t . Historical possibility (0) is de- fined in the usual way. This aspect of the framework is modeled on a system reviewed by Thomason (1984). The approach is more compatible with our account of knowledge, and the resulting system is more expressive than standard dynamic logic. To facilitate reasoning about action, we define the following notions: P hyPoss( S) def 03vt Does(S, d), where vUt is a tem- poral variable that does not occur free in S AfterNec(S, p) def q Vvt(Does(6, v”) > At(d, cp)), where vt is a temporal variable that does not occur free in 6 and ‘p Res(S, ‘p) def PhyPoss(S) A AfterNec(S, p) P hyPoss( S) means that it is physically possible for self to do action S next. AfterNec(S, cp) means that if self does 6 next, it will necessarily be the case that cp holds afterwards. We say that S results in cp, formally Res(S, cp), if 6 is physically possible and after doing it, cp must hold. Finally, our theory includes a formalization of abil- ity which is a revised version of that of Moore (1980). First note that one may well know that cooking beef bourguignon would impress the party’s guests with- out knowing how to do it, that is, without knowing what primitive actions “cooking beef bourguignon” re- ally stands for. This also applies to actions that are instances of general procedures: if one ignores the com- bination of a safe, then one ignores what dialing the safe’s combination amounts to (even though one knows the procedure for dialing any given combination). One can view this distinction as an instance of de ditto as opposed to de re knowledge. Moore exploits this in his formalization of ability. For simple actions, his account goes as follows: an agent a is able to achieve a goal by doing the action iff he knows what the given action is, knows that it is physically possible for a to do the action next, and knows that a’s doing the action next neces- sarily results in the goal being achieved. By requiring that the agent know what the action is, Moore elimi- nates the need for explicit specification of the knowledge prerequisites of actions: if an action is an instance of a general procedure and the procedure is known (for- mally, an epistemically rigid function), then the action is known iff the agent knows what its arguments stand for. Complex actions are handled recursively. Note that it is not required that the agent initially know all the actions that make up a successful plan as long as he knows that he will know what to do next at each step of his plan. The main deficiency we find in this formalization is that it requires the agent to know who he is (in an ob- jective way). As we will argue below, this is neither necessary nor sufficient for ability. We will describe a revised version of the formalization which requires in- dexical knowledge instead of de re knowledge. Further- more, the fact that our version is based upon a logic that includes an adequate treatment of indexical knowledge, allows actions with indexical knowledge prerequisites or effects to be properly formalized. We use the formula Can(S, ‘p) to express the fact that self is able to achieve the goal cp by doing action 6. Semantics A semantic structure M is a tuple (A 0, V’, W, 4, K, -, @, A) The first four components are non-empty domains for the appropriate sorts: d is the domain of agents, 0 is the domain of objects, 7 is the domain of times, and ZJ is the domain of primitive actions. The domain of individuals Z is defined as d U 0. W is a set of tem- porally extended possible worlds. E = W x d x 7 is the set of indices. We take a, o, i, t, d, w, and e (possibly subscripted, primed, etc.), as ranging over arbitrary el- ements of A, O,Z, 7, ZJ, W, and E respectively. + is a strict total order on 7 whose intended interpretation is the relation “is earlier than”. K E E2 is the knowledge accessibility relation. The rationale behind this formu- lation was explained in the previous section. K must be reflexive and transitive. The denotation of terms and satisfaction of formu- las are defined relative to indices. Qp gives the exten- sion of predicate and function symbols at an index. A C 2) x E x 7 determines which actions are done by wh;h agents in which worlds over which time intervals: (d, (w, a, tS), te) E A if action d is done by agent a from time tS to time te in world w. M is a family of accessibility relations - one for each time point - that is used to interpret the historical ne- cessity operator •I . Intuitively, w at w* if w and w* dif- fer only in what happens after t. We ensure that our se- mantics respects this intended interpretation by impos- ing various constraints on R. Firstly, for all t E 7, =t must be an equivalence relation - this implies that at any given time point, •I and 0 obey the principles of the modal system S5. Secondly, if w Bta w* and ti 4 t2, then w Xtl w*, i.e. possibilities do not increase as time passes. And finally, to ensure that historical al- ternatives up to a given time are identical in what facts hold, what is done, and what is known up to that time, we require that if w =t, w* and ti 3 t2, then 1032 ROBOTICS 1. 2. 3. 4. for any predicate R, W% (w*, a, h)) = @(R, (w, a, b)), for any function symbol f , @(A (w*, a, Q>)(il, . . . , in> = @(P, (w, a, h))(il, . . . , L), A(4 (w*, a, tl), b) iff A(4 (w, a, h), b), ((w*,a,h),e) E Kifi((w,a,h),e) E K. To simplify reasoning about agents’ ability to achieve goals by doing multi-step actions, we will assume that knowledge is persistent, that is, that agents keep on knowing what they knew previously, and that agents know what actions they have done. The following as- sumption enforces this: if ((w, a, ts), (w’, a’, t.5)) E K and tl 5 f2, then there exists a time i1, where t1 5 fi, such that ((w, a, tl), (w’, a’, El)) E K and if A(d, (w, a, tl), f2) then A(d, (w’, a’, fl), t$). Note this formulation does not require agents to know at what time they start or finish acting, or how much time the action takes. An assignment is a function that maps variables into elements of the domain appropriate to them. The de- notation of a term 0 in a structure M at n index %I e = (w, a, t) under an assignment g, written [O]e,g is de- fined in the standard way for variables and compound terms; for indexicals, we have that [seae,g = a and lbOwDe,g = t (when the structure under consideration is clear from context, we omit it). We can now de- fine what it means for a formula cp to be satisjed by a structure M, an index e = (w, a, t), and an assign- ment g , which we write M , e, g b cp. For conciseness, we omit the standard part of the definition that deals with with first-order logic with equality; for the rest of the language, we have: % g I= Do44 t) iff A(Flle,gt % lMle,g) e, g I= tl < ta iff [h]e,g -( [b]e,g e, g I= At@, 54 iff (w, a, lPlle,g),g I= cp e, 43 I= BY@, 99 ifl (w, bBe,g, 4, g I= cp e, g k Know(p) iff for all e’, such that (e, e’) E K, e’,g I= P e, g j= q cp iff for all w* such that w Bt w*, A formula p is satisfiable iff there exists a structure M, index e, and assignment g, such that M, e, g /= cp. A formula cp is vaZid (written b ‘p) iff it is satisfied by all structures, indices, and assignments. Ability Our current formalization of ability is based on that of Moore (1980). It is simpler than his because we do not attempt to handle indefinite iteration (while-loop actions). Moore’s formalization of this case is actually defective because it does not require the agent to know that the action will eventually terminate. We leave this case for future research. Since we are not treating indefinite iteration, we can simply define ability in terms of the other constructs of the logic as follows: Can(Bd, p) def 3vd Know(vd = ed ARes(Bd, cp)) where Bd is an action term and action variable vd does not occur free in ‘p and Bd Can(skip, ‘p) def Know(v) C=((&; f52), 97) def Cwjl, c4s2, $4) C=(if( cp? , Sl,S2), (Pg > def (Know( cp? ) A C=( 61, (pg>) V (Kno-+w) A Cm(62, ~3~)) The definition works by recursion on the structure of the action expressions involved. The first case handles simple actions (action terms): self is able to achieve a goal cp by doing a simple action 6Jd iff he knows what that action is and knows that his doing it results in the goal holding afterwards. Note that the definition involves quantifying-in only over the class of primitive actions, which are agent-relative entities (e.g. “send grasping signal to hand”), quite unlike people or blocks. The second case states that self can achieve a goal by doing the empty action skip iff he knows that the goal currently holds. The third case says that self is able to achieve a goal cp by doing a sequentially composed action (61; 62) iff by doing 61, he is able to achieve the goal that consists in himself being able to achieve the original goal cp by doing 62. The final case takes care of conditional actions: self can achieve a goal by doing if((p?, Sl,S2) iff he either knows that the condition cp? holds and is able to achieve the goal by doing 61, or knows that it does not hold and is able to achieve the goal by doing 62. Our formalization improves over Moore’s in several ways. Firstly, the simple action case requires the agent to know that if he himself does the action, the goal will necessarily hold afterwards; requiring the agent to know of himself ((ae re) that if he does the action the goal will necessarily hold afterwards, as Moore does, is neither necessary nor sufficient for the agent to be able to achieve the goal. We illustrate this through an exam- ple in the next section. Secondly, it is based on a very expressive temporal logic and thus could be more easily extended to handle actions that refer to times in more general ways than are considered here (e.g. the action of “running until noon”). Finally, the underlying logic includes an adequate treatment of indexical knowledge in general, which permits a more accurate specification of the knowledge prerequisites and effects of actions; the examples in the next section are evidence for this. Formalizing a simple robotics domain We will now use the theory to formalize aspects of a simple robotics domain and show how the resulting for- malization can be used to prove various statements con- cerning the ability of agents to achieve goals by doing actions. We will argue that our framework allows a much more accurate modeling of these situations than frameworks that ignore indexicality. Our domain in- volves a robot, call him ROB, that moves about on a LESP~RANCE AND LEVESQUE 1033 two-dimensional grid. Since our purpose is not to model The indexicality of action manifests itself in many complex patterns of interactions, but to present and justify our account of indexical knowledge and action, ways in this domain. One key way is that a robot can our formalization will be based on the assumption that the robot is the only source of activity in the domain. act upon (manipulate) an object as long as he knows We take our robot to have the following repertory of basic actions (primitives of his architecture): he may where that object is relative to himself; he need not move forward by one square, he may turn right or left 90°, he may sense whether an object is on the square know either the object’s absolute position or his own. where he is currently positioned and if there is one, what shape it has, and he may pick up an object from First consider a simple instance of this where the robot the current square or put down the object he is holding on the current square. It should be clear that in spite wants to pick up an object and is actually positioned of the simplicity of this domain, it contains analogues to a large number of problems encountered in planning where that object is. Relevant aspects of the domain actual robot navigation, manipulation, and perception. For instance, one can view objects of particular shapes are formalized by making various assumptions, most of as landmarks and the robot can then navigate by rec- ognizing such landmarks. We assume that there are no which have to do with the types of action involved. The physical obstacles to the robot’s movements; in partic- ular, an object being on a square does not prevent the following assumption specifies the effects of the action robot from being on it too (one can imagine the robot as standing over the object). PICKUP: know how to do basic actions, that is, know what prim- itive actions they denote. This is formalized as follows: Assumption 2 (Basic actions are rigid) + 3dKnow(d = e), where 8 is any basic action constant We omit the frame “axioms” for PICKUP, which say that it does not affect the position or orientation of anything and that unheld objects that are not where the agent is remain unheld. In a discussion of the robot action of “putting a block on another block”, Moore (1985) recognizes this and suggests that it be defined in terms of lower-level ac- tions involving arm motions to -the objects’ positions, Now clearly, just having de re knowledge of some ob- ject (i.e., 3x Know(OBJECT(x))) is insufficient for be- ing able to pick it up; something must be known about grasping, and ungrasping. But, knowledge of an ob- the object’s position. If we only wanted to model the agent at a high level of abstraction, we might be willing ject’s absolute position is not sufficient for being able to assume that as soon as an agent knows which object is involved, he would know how to get to it (or how to to act upon it. One may not know what one’s absolute find out). But there clearly are circumstances where such assumptions are invalid and modeling at such an position and orientation is and therefore may not be abstract level would leave out a great deal about how action is actually produced. We want an account that able to deduce where the object is relative to oneself. addresses the issue of what information the agent must exploit in order to be able to get at the object. Our formalization reflects this fact: one can prove the following proposition with respect to the simple situa- tion discussed earlier: Assumption 1 (Effects of PICKUP) Proposition 1 b V~(OBJECT(~)APOS(~) = hereA13yH0~~1~~(y) 3 Res(PICKuP, HOLDING(~))) It says that if some object z is positioned where the agent currently is and he is not currently holding any- thing, then his doing the action PICKUP next will re- sult in his holding x. 4 This means that under these conditions, it is both physically possible for him to do PICKUP, and his doing so necessarily results in his holding the object. In fact we assume that all ba- sic actions are always possible. The view adopted is that such actions characterize essentially internal events which may have various external effects depending on the circumstances.” We also assume that agents always 4We assume that this holds for all agents rather than specifically about our robot because we want to avoid as- suming that he knows who he is when we later prove state- ments about his abilities. 5Note tha t a ssumption 1 only specifies what happens when PICKUP is done under the conditions stated. What its effects are in other circumstances is not addressed. pjp’(here = fl’r\ K~~~(~x(~BJEcT(x) A POS(X)=$) A ~$HOLDING(Y))) > C~~(PICKUP,~XHOLDING(X)) This says that even if the agent is currently at some position p’and knows that the absolute position of some object is p’and that he is not holding anything, he still might not be able to achieve the goal of holding some object by doing the action PICKUP. The reason for this is simply that the agent may not know that he is at 6 On the other hand, we can also prove that if the agent knows that some object is where he currentdy is and that he is not holding anything, then he must be able to achieve the goal of holding some object by doing PICKUP: Proposition 2 ~K~OW(~X(~BJECT(X) A POS(X)= here) A ~~HOLDING(Y)) > Can(PICKUP,3x HOLDING(X)) 1034 ROBOTICS The agent can be totally ignorant of what his (and the object’s) absolute position is and still be able to achieve the goal. Note that proposition 2 makes no requirement that the object that the agent ends up holding be the same as the one that was at his position before the action. This may appear too weak and an easy fix would in- volve assuming that the agent knows which object is involved. But is possible to strengthen the above propo- sition without requiring such de re knowledge. For ex- ample, the following proposition captures the fact that the agent knows that after the action, he would be hold- ing some object that was where he was before doing the action. Proposition 3 b Know(3scp A+~HoLDING(~))> Can(PICKUP, 3x(3t(t = now A Past(Does(pICKUP, t) A cp)) A HOLDING(X))) where cp def OBJECT(Z)APOS(Z)= here Specifically, it says that if the agent knows that some object is currently at his position and that he is not currently holding anything, then he can by doing ac- tion PICKUP achieve the goal of holding some object that was at his own position before the PICKUP he has just done (Past(p) means that (o holds at some time earlier than now). This can be strengthened further to require uniqueness. But it should be clear that identify- ing the objects involved in the initial and goal situation, without requiring that it be known what objects they are, is not a trivial matter. Before moving on, let’s examine another variant of this situation. First, imagine that an agent Q knows that there is an object where he himself is and that he is not holding anything. Then a is able to achieve the goal of holding something by doing PICKUP. For- mally, if we let cp be the formula of proposition 2, then b By(qcp). However, if we imagine that a instead knows that there is an object where a is, it no longer follows that he is able to achieve the goal. That is, if (p’ is the result of replacing here by POS(~) in 'p, we have that k By(a,cp’). The reason why this is not valid is simply that Q may not know that he is a. This shows that knowing of oneself ( de re) that if one does the-action, the goal will necessarily hold afterwards, as Moore’s formalization of ability requires, is not suffi- cient for ability. One can similarly show that such de re knowledge is not necessary either (in some models of proposition 2, the agent does not have such knowledge). More generally, knowing the relative position of an object is sufficient for being able to act upon it. For instance, if the robot knows that there is an object at position (1,O) relative to himself, that is, on the square directly in front of him, and knows that he is not holding anything, then he is able to achieve the goal of holding some object by doing first FORWARD and then PICKUP. This can be proven given the assumption already stated and action FORWARD: the following formalization of the Assumption 3 (Effects of FORWARD) /= V$io(here = $A OR1 = o > Res(FORWARD, here=p’+ (1,0) x ROT(O))) Definition 1 ROT(O) def cos 0 sin 0 -sin0 coso > Assumption 4 ~VZ(HOLDING(Z) > POS(Z)= here) Assumption 3 says that as a result of doing FORWARD, the agent moves one square further along the direc- tion he is facing; OR1 represents the orientation of the agent with respect to the absolute frame of reference and ROT(O) is the rotation matrix associated with an- gle o. Assumption 4 says that objects held by the agent are where he is. We also need the following three frame “&om” : firstly, after doing FORWARD, the agent's ori- entation must remain unchanged; secondly, after the agent does FORWARD, the position of objects that are not held by the agent must remain the same as before; and finally, objects that are not held by the agent must remain unheld after he does FORWARD. Given this, we can prove proposition 4, that is, that if the agent knows that there is an object at position (1,0) relative to himself and that he is not holding anything, then he can achieve the goal of holding some object by doing FORWARD and then PICKUP: Proposition 4 +K~OW(~Z(~BJECT(Z) A RPOS(Z) = (1,O)) A -3y HOLDING(Y)) > C~((FORWARD;PICKUP),% HOLDING(X)) Definition 2 RPOS(~)~~((P~S(Z)- here) x ROT(-ORI)) RPOS(z) represents the position of x relative to self. It is possible to prove the- -more general result that if the agent knows the relative object and is not holding anything, he position of an can go to that object’s position and pick it up (since there are no obstacles, a trivial algorithm will achieve this). We will come back to this issue of what one must know in order to be able to go and manipulate an ob- ject, but now let’s have a look at perception. As ob- served earlier, it too yields indexical knowledge. In our domain, the action SENSE constitutes a limited form of perception. We formalize the effects of SENSE as follows: Assumption 5 /= Res(SENSE, Kwhether(3x(oBmcT(x) A POS(X) = here))) Assumption 6 ~VS((P A 13yHOLDING(y) 3 Res(SENSE, Know(p))) where cp d~f3z(GBJECT(~) A POS(x) = here A OFSHAPE( LESP~RANCE AND LEVESQUE 1035 Assumption 5 says that doing SENSE, results in the agent knowing whether6 an object is present at his cur- rent position. Assumption 6 says that if some object is present at the agent’s position and the agent is not holding anything, then his doing SENSE results in him knowing which shape(s) the object has. From this and the fact that basic actions are assumed to be known, it follows trivially that by doing SENSE, the agent can find out if there is an object where he is and, if there is one, what it’s shape(s) is (are). We exploit our formalization of SENSE in the follow- ing example drawn from another interesting area of robotics: that of navigation with the help of a map. In order to fully take advantage of the information con- tained in a map, say to find out how to get to a desti- nation, an agent must first orient himself with respect to it, that is, find out where he is on the map, what his absolute position is. If he does not already-know this, he must try to match the landmarks represented on the map with features of his current environment. Our sim- ple-domain provides inst antes of this if we treat objects of various shapes as landmarks. For example, one can prove the following proposition, which says that if an agent happens to be at absolute position p’ and knows that the unique object having shape s is at position p’, then he can find out that his absolute position is @by doing the action SENSE: Proposition 5 b VjjVs(here = p’/\ K~OW(~X(~BJECT(X) A POS(Z) = p’l\ USH(Z, s A 13~ HOLDING(Y)) 3 can(SENSE, Know(here = ~7)) where USH(X, s) def Vy( OFSHAPE (y, s) G y = 2) We can also show that an agent can find out what his absolute orientation is by recognizing objects that have a known orientation with respect to each other. And we can show that once an agent knows his absolute po- sition, he can use the map to navigate to some object represented on it (see (Lespkrance 1990) for details). These map navigation examples exploit a key feature of our framework, which is that it allows both indexical and absolute knowledge to be represented, and rela- tions between the two to be expressed (this feature of the map navigation problem was pointed out by Israel (1987)). This distinguishes it from the indexical version of the situation calculus proposed by Subramanian and Woodfill (1989) h w ere one simply introduces indexical entities in the ontology. Let’s now go back to the issue of what one must know in order to be able to go and act upon an object. We said that knowing the relative position of the object was sufficient for this. But in real life, agents rarely know exactly what the relative locations of objects are. More typically, they know roughly where objects are and scan the general area until they find the object. 6 Kwhether( p) is defined as Know(q) v Know(-cp). For instance, if our robot knows that an object is either on the square where he is or on the one directly in front of him, then he can achieve holding some object by first doing SENSE, and then either PICKUP, or FORWARD followed by PICKUP, according to whether the object turned out to be where he was or not. Another more complex instance goes as follows: if our robot knows that there is an object that is positioned at most k squares along the row he is facing (and that he is not holding anything), then he can get to it by repetitively moving forward and sensing (up to k times) until he senses that an object is present (Lespdrance 1990). So it is quite clear that ability to act upon an object does not require knowing its relative position. But then what is required? It seems that the best we can say is that the agent must know of some procedure that will take him to where the object is. But this creates problems in the formalization of abil- ity to do certain high-level parametrized actions, for ex- ample, the action of “going to the position of an object 0” GOWHERE( It would be inappropriate to treat this action as a primitive because we want we want to model how knowledge enables action at a more de- tailed level. The other way to way to deal with such an action within our (and Moore’s) framework would involve defining it in terms of lower-level actions that are parametrized with the information that must ac- tually be known in order to be able to do the high- level action (recall Moore’s proposal for the action of “putting a block on another”). This allows knowledge prerequisites to be enforced by the requirement that one know which primitive action to do next and removes the need to formalize them explicitly. But for actions like GOWHERE( it is not clear how this could be put into practice. However, notice that GOWHERE is a strange kind of action in that it appears to refer to anything that would achieve the goal that the agent be where 8 is; it is as much like a goal as like an action. Perhaps we should rule out the introduction of such actions, but instead provide an action-less version of the Can operator: CanAch(cp) would mean that self is able to achieve ‘p in one way or another. Then, we may use CanAch(ms(B) = here A cp) instead of some- thing like C+GOWHERE(~), cp).’ A coarse “syntac- tic” way of formalizing CanAch goes as follows: e, g /= CanAch(cp) iff there exists an action expression S such that e, g b Can(S, cp). A more general and robust ap- proach is being developed by Nunes (1990). Conclusion act upon and perceive the world from a perspective. It is important to recognize Robots titular par- this 7This assumes that it is known that 6 refers to the same entity before and after the action is done; the assumption can be dispensed with by referring to the denotation of 8 prior to the action as illustrated earlier. 1036 ROBOTICS relativity to perspective if one is not to be overly de- manding in specifying what they need to know in order to be able to achieve goals through action. In a previous paper (Lesperance 1989), we proposed a formal theory of knowledge and action that accommodates the neces- sary indexical knowledge, and showed how it could be used to analyze an agent’s ability to make a phone call that might be long-distance. Here, we have shown how the same framework can be used to formalize several kinds of situations involving indexicality drawn from a robotics domain. Several examples treated dealt with the fact that ability to act upon an object does not require & re knowledge of the object or its absolute position; knowledge of its relative position is sufficient. It was shown how the fact that perception yields index- ical knowledge can be captured. We also pointed out the value of being able to relate indexical knowledge and objective knowledge within the same formalism through an example involving the use of a map for navigation. Finally, we discussed problems that arise in handling certain higher-level parametrized actions and proposed a solution. We are examining further the role played by de re knowledge in action, with a view towards clarifying the notion and ensuring that our formalization of this role is adequate. Also under investigation are extensions to the theory to handle actions involving indefinite iter- ation. We are also applying the theory to a domain involving search through a* data structure, to show that indexicality is not restricted to domains involving phys- ical space. Applications to problems in models of lin- guistic communication are also under development. Acknowledgements Graeme Hirst, Joe Nunes, Adam Grove, Joe Halpern, Bart Selman, Gerhard Lakemeyer, and others have pro- vided much useful advice and discussion. References Allen, J. F. 1984. Towards a general theory of action and time. Artificial Intelligence, 23(2):123-154. Haas, A. R. 1986. A syntactic theory of belief and ac- tion. Artificial Intelligence, 28:245-292. Israel, D. J. 1987. The role of propositional objects of belief in action. Technical Report CSLI-87-72, CSLI, Stanford University, Stanford, CA. Kripke, S. A. 1963. Semantical considerations on modal logic. Acta Philosophica Fennica, 16:83-94. Lesperance, Y. 1989. A formal account of self- knowledge and action. In Proceedings of the Eleventh International Joint Conference on Artificial Intebli- gence, pages 868-874, Detroit. Morgan Kaufman Pub- lishing. Lesperance, Y. 1990. A Formal Theory of Indexical Knowledge and Action. PhD thesis, Department of Computer Science, University of Toronto. To appear. Lewis, D. 1979. Attitudes de ditto and de se. The Philosophical Review, 88(4):513-543. McDermott, D. V. 1982. A temporal logic for reasoning about processes and plans. Cognitive Science, 6:101- 155. Moore, R. C. 1980. Reasoning about knowledge and action. Technical Report 191, AI Center, SRI Interna- tional, Menlo Park, CA. Moore, R. C. 1985. A formal theory of knowledge and action. In Hobbs, J. R. and Moore, R. C., editors, Formal Theories of the Common-sense World. Ablex Publishing, Norwood, NJ. Morgenstern, L. 1987. Knowledge preconditions for ac- tions and plans. In Proceedings of the Tenth Interna- tional Joint Conference on Artificial Intelligence, pages 867-874, Milan. Morgan Kaufman Publishing. Nunes, J. H. T. 1990. Ability and commitment. Unpub- lished manuscript, Department of Computer Science, University of Toronto. Perry, J. 1979. The problem of the essential indexical. Noiis, 13:3-21. Rescher, N. and Urquhart, A. 1971. Temporal Logic. Springer-Verlag, Vienna. Shoham, Y. 1987. Temporal logics in AI: Semantical and ontological considerations. Artificial Intelligence, 33( 1):89-104. Subramanian, D. and Woodfill, J. 1989. Making the situation calculus indexical. In Proceedings of the First International Conference on Principles of Knowledge Representation and Reasoning, pages 467-474, Toronto, Canada. Morgan Kaufman Publishing. Thomason, R. C. 1984. Combinations of tense and modality. In Gabbay, D. and Guenthner, F., editors, Handbook of Philosophical Logic, volume 2, pages 135- 165. D. Reidel Publishing, Dordrecht, Holland. LESPI~RANCE AND LEVESQUE 1037
|
1990
|
54
|
972
|
LOGnets: A Hybrid Graph Spatial Representation for Robot Navigation Peter K. Malkin and Sanjaya Addanki IBM T.J.Watson Research Center p.0. Box 704 Yorktown Heights, NY 10598 Abstract In this article we present a novel, hybrid graph spatial representation for robot navigation. This representation enables our mobile robot to build a model of its surroundings which it can then use for navigation. The models or maps that use this representation are hybrid graphs, the nodes being analogical local maps of landmark locations in the robot’s environment, the arcs being the actions the robot executes to travel between the locations. This representation yields a reliable navigation tool, one which ensures that the robot can re-orient itself to recover from errors in path execution and encounters with unexpected obstacles. The LOGnet approach also meshes with human’s natural approach of mapping with landmarks, instead of using angular and translational data. 1 Introduction Real-time mapping and navigation in unknown environments are fundamental skills for an autonomous robot, skills for which many different approaches have been investigated. Given the lab shown in Figure 6, consider how a robot could map this area. With Kuipers’s Qualitative Topological Mapping scheme [4] the robot builds a topological map or graph. The nodes of this graph are “distinctive locations” where sensor values are maximized, and the arcs are the movement strategies used to travel between the locations. Although Kuipers’s work was similar to our’s, his simulations are simple, lacking error analysis and sensor-error modeling. Real-world performance of both mapping and navigation with this approach is unclear. With a standard Cartesian grid-based navigation approach (e.g., [l]) the robot records all the angular and distance information it measures into a grid. There are two drawbacks to this approach. One is that the robot maps everywhere its sensors can see, forcing the robot to manage data it will never actually use. Further, such grid-maps include the cumulative errors of the robot’s sensors and movement mechanisms. Navigation with standard grid-maps also suffers from complex, error-prone path planning and poor failure- recovery. The Occupancy Grid approach [5,6] overcomes the stan- dard grid-map’s cumulative error drawback, since Occupancy Grid cell values specify the probability that the corresponding real-world locations are occupied - sensor and locomotion errors included. Occupancy Grids still contain more data than is necessary for navigation. Davis’s [3] Relational Topological Representations reduce the amount of unnecessary data retained by mapping the lab in terms of the angular and translational relationship between distinctive topological features; error bounds are included in these relations. Here, although the robot does not map everything it can see, it still uses error-prone distance and dead-reckoning measurements to define the spatial relation- ships between objects. Path planning and re-orientation remain complicated with this mapping scheme. Besides these purely practical problems, metric-world spa- tial representations go against our natural intuition. To map a room, such as that shown, one does not record the size, shape and relative position of everything one can see; the map we make is much simpler. We would remember the landmarks of the room, and what we did to travel between these locations. Complete information about all of the intermediate areas is unnecessary until exceptions arise. 2 A Hybrid Graph Approach We propose that the robot map its surroundings using snap- shots of landmark locations and navigate using navigation scripts: sequences of actions that carry the robot from one landmark location to another. The framework we have developed is a hybrid graph: o The nodes of the graph being analogical local maps of distinctive locations - voting scheme versions of Occupancy Grids [S]; 0 The arcs being the sequences of actions forms to travel between the locations. the robot per- We call these graphs LOGnets. Thus, our mapping scheme uses no absolute distances and no dead reckoning. Further, this approach meshes with our MALKINANDADDANKI 1045 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Figure 1: The LNNS System Robot natural approach to navigation. For example, we don use a detailed map to plan how to get to our office from the front door each morning; we just execute the set of actions that we learned gets us to our office (e.g., “Go through the door, follow the hallway to the end and then make a right into the office”). Similarly, when we give directions, we just give a series of landmarks and the actions required to get between the landmarks. of LOGnets The LGGnet hybrid graph representation described above is implemented in our LOGnets Navigation System, LNNS. The system ’ robot is a TRC Labmate Mobile Base carrying a TRC Proximity System with six infrared sensors for obstacle detection and two sonar depth sensors (Fig. 1). The robot is controlled autonomously by a Symbolics 3650 computer connected to the robot by an umbilical cord consisting of two RS-232 interface lines: one to communicate with the robot base, and one to communicate with the proximity system. The base accepts commands which set its forward and turning speeds (the forward speed for our testing = 20 cm/set), and will return measures of how far it has turned. The proximity system accepts commands to make and return measurements, both sonar and IR. 3.1 LOG Maps The area around the robot is represented by 36,10 degree sec- tors, each sector broken into 6 depth divisions corresponding to 0.75, 1.0, 1.5, 2.0, 3.0, and 4.0 meters respectively (Fig. 2). To make a LOG, the robot takes 4 readings with the forward and rear sonar sensors for each 10 degree sector. We do not account for sensor error, unlike [6] and [3]. A given cell value 1046 ROBOTICS (a depth division of a sector) is incremented if the returned sonar reading is within the cell depth limit. Hence, a cell value indicates the confidence that the corresponding depth is accessible. Figure 3 shows an example from our experiments (the square in LOG center indicating the area covered by the TRC robot base). Note that a LOG is simply a 36 by 6 integer array, no actual measurement date is retained. We experimented with LGGs of fewer cells and fewer sonar readings, but found these maps were insufficiently reliable for navigation. 3.2 LOG Map Comparison To determine if it is in a previously visited location, the robot makes a LOG of its surroundings and compares the LOG to all other LOGS in its current graph. LOG comparisons consist of three calculations, each examining a distinct type of LOG map difference. The three types of differences calculated are: 1. The total binary difference, i.e., the total number of cells which disagree as to designation: unoccupied (cell value = 0), or occupied (otherwise); 2. The average root mean squared difference between the values of the LOGS corresponding cells; 3. The average absolute difference between values of the LOGS corresponding cells. ?tvo LGGs match if all three of these comparisons fall within empirically determined thresholds. Since the robot may be in the same location, but oriented differently than it was when it took the original LGG, all possible orientations of the new LOG are checked (i.e.., all 36 possible 10 degree offsets). Thus, if a LOG fails to match any previous LOG, the LOG does not match any previous LOG at any orientation. : * ; I .5rndd;; : ; ; ; 1 : .75mk,+i t : : : ; : : : Irn&--J : : : : : : : 1.5m; ---- 2 ; : ; 2m; _______ -3: i i 3mi , I(----- ------- -pl : , * 4m’ (---------------- 9’ Figure 2: Local Occupancy Grid, LOG 3.3 LOGnets The robot constructs a LOGnet by exploring its environment and measuring a LOG whenever it encounters an obstacle, an obstacle makes a location “distinctive.” This may be thought of as a simplified version of Kuipers’s “distinctive place,” [4]. 33.1 Subsumption Architecture-Based Rule System The exploration the robot performs is accomplished with a subsumption architecture-based, rule system, SABRS (ref. [2]). This system consists of set a of implication rules whose antecedent conditions are triggered by the robot’s sensors, and whose consequents are action symbols corresponding to the possible actions the robot’s mechanisms can perform. This wandering system operates by continually executing the following sequence of actions henceforth referred to as a step: 1. 2. 3. The robot’s sensors are queried and the data from them is passed to the production rules. Every rule whose antecedents are satisfied asserts its consequents. All asserted consequents are sorted by the subsumption architecture which determines which of the asserted robot actions to actually implement (Fig. 4). The robot’s wandering is just the repeated execution of this rule-king sequence. The cost of an arc is simply the number of steps in it. Current LOG World 24 Figure 3: Layout 8 LOG 24 Since these sensor readings are used without additional calculation and since the actions the robots performs are simple, these steps are performed very quickly (less than 1 Hz, 5 Hz. of which is spent waiting for the proximity system to respond). Thus, the robot is able to react to its environment in real time. Further, since the SABRS assertions are made in form of primitive symbols (e.g. stop and turn-left) the SABR system acts as a real-time signal/symbol bridge. Lastly, new SABRS rules can easily be added to get the robot to perform more complex behaviors. 3.3.2 LOGnet Construction When an obstacle is detected, the robot measures a LOG. If this is the first location visited, the new LOG is simply added to the LOGnet. Otherwise, the robot compares the new LOG with all other LOGS in its LOGnet. If the new LOG does not match any other LOG, a new node is added to the LOGnet with an arc connecting the LOG representing the location the robot last visited to the new LOG, the new arc containing MALKINANDADDANKI 1047 pf=ll : : : r--------’ --* : ;-m. .------m-J Figure 4: Subsumption Architecture-Based Rule System the actions (represented by action symbols) that the robot executed in traveling between the two locations. One such arc might be: stop, turn-left, stop, turn-left, go-forward, no-turn, go-forward, no-turn, go-forward, no-turn Suppose, the robot travels from the location represented by LOG 1 to a new location where it measures LOG 5, and that the sequence of actions the robot executes in getting between the two locations is called Arc A (Fig. 5). If LOG 5 does not match any other LOGS in the current LOGnet, LOG 5 is connected into the LOGnet with Arc A from LOG 1. \ \ \ \ \ 0 Figure 5: Linked LOGS If the new LOG does match a LOG in the robot’s LOGnet, it means this is a location visited previously. If the current LOGnet lacks an arc connecting the current LOG to the LOG of the previous location, the new arc is added to the LOGnet to indicate that this path exists. If an arc already exists, then the costs of the new arc and the existing arc are compared, the cheaper arc stored in the LOGnet. Note that the LOGnets the robot produces are not neces- sarily complete mappings of its surroundings - there may be places the robot does not map simply because its rule-based wandering never gets it there. The topic of complete mapping is beyond the scope of this paper. 3.4 LOGnet Navigation To navigate, the robot first orients itself by wandering until it finds a location it recognizes (through LOG comparisons). The robot then asks the outside observer for a goal location. Given this goal location, the robot calculates the lowest cost path to the requested location by referring to its LOGnet, this path calculation requiring only simple graph tracing. To execute the calculated path, the robot carries out exactly the actions the path’s arcs dictate. Note that the subsumption architecture wandering system is still in effect to the extent that the robot will avoid any unanticipated obstacles. The robot checks it is on course by verifying that it reaches the locations indicated by its path. If the LOGS measured match the path’s LOGS, the robot continues. If a LOG fails to match the path’s LOG, matching another LOG instead, the robot recovers by planning the least expensive path to the goal from its current location. If the current LOG fails to match any LOG in the LOGnet, the robot wanders until it finds a LOG it recognizes, calculating a least-cost path to the goal-location when it does. Thus, using LOGnets, the robot can recover from unex- pected obstacles, the subsumption rules ensuring it avoids collisions. The robot can also recover from path execution errors by determining paths to its goal from wherever it finds itself. In one of our tests of the LNNS LOGnet Navigation sys- tem, we constructed eight different environments in our lab, changing the room layout by moving real-life obstacles (e.g., chairs, trash cans and equipment carts)(Fig. 1). In each of these environments we had the robot build a LOGnet of the room, and then use this LOGnet to reach positions we specified. 4.1 LOGnet Construction We had the robot map several of the room layouts multiple times. In each given environment the robot chose approxi- mately the same landmark locations, demonstrating that these positions are stable. Further, since the robot was started in different locations, the position of the landmark locations is independent of where the robot begins - the position of the landmark positions dependent solely on the robot’s wandering system and the sensitivity of its sensors. Figure 6 shows one of our test environments with the path the robot followed in constructing its LOGnet. It took the robot approximately 2 hours to perform this exploration. Gnet Utilization Figure 7 shows the path the robot took to get from location#26 to #28 using the LOGnet described above. The robot first wandered until it encountered an obstacle. It measured a LOG and correctly determined its location to be location #26. It then asked where it should go and we specified location #28. 1048 ROBOTICS 35’ 8” Figure 6: Layout 8, Mapping 2 Figure 7: Test #2, Layout 8,Mapping 2 Given its starting location, LNNS calculated that to get to location #28 from #26, the robot should go from location #26 to #27 to #28. Although the robot successfully navigated to location #27, it failed to get to #28, arriving instead at location #30. Recovering from this path execution error, LNNS determined that it should go from #30 to #27 to #28. The robot again failed to reach the desired goal (location #27), traveling instead to location #26. LNNS then calculated the best path to goal location #28 being from #26 to #27 to #28. This time the robot successfully traveled from #26 to #27 and then from #27 to #28. 4.3 Discussion of Results There are several things to note about the way the robot constructed is LOGnet. The first is that the robot always recognized locations it had visited previously despite trans- lational offsets (up to 2 feet) and rotational offsets (0 - 360 degrees), locations #4 and #3 for example. One can also see that the robot traveled between landmark location along particular routes (e.g., between locations 2 and 3). It is these paths that the robot’s Lffinet arcs roughly specify. Certain areas in the room required more LOGS than others (e.g., the area around locations 13,14 and 17 compared to that around location 3). This is due to the robot’s sonar sensors. Because of their low bandwidth, if the robot is positioned near the comer of a box, the sonar may not sense the box because the sonar signal is deflected away. Hence, if the robot is near any form of comer, the LOGS are more sensitive to translational offsets. As demonstrated in the navigation test described above, MALKINANDADDANKI 1049 INNS was able to recover from errors in path execution. This recovery was quick since the graph-tracing method of determining the best solution path from wherever the robot finds itself is as simple and quick as the method for planning the initial path. In the test above the robot correctly identified all of the locations it visited. There were occasions during our testing when the robot incorrectly identified its location, but this happened less than 5% of the time. Such errors were overcome because when the robot attempted to follow its calculated path to the goal location, it would correctly identify the next world it encountered, thereby re-orienting itself. Through experimentation we learned that a LOG sector angle of 10 degrees yielded reliable landmark location iden- tification and path tracing. When we tried using greater LOG sector angles (e.g, 20 degrees) we discovered that although the robot was able to correctly identify its location, it was not able to orient itself accurately enough to trace its paths. In cases where the robot encountered unexpected obstacle (e.g., human co-workers), the robot easily recovered by stopping and measuring a LOG. This LOG would not match any in the robot’s LOGnet (since the robot was never forced to stop in this position before), and so the robot would wander until it encountered a location whose LOG it did recognize. 5 Future War Higher level actions would allow the robot to track its sur- roundings while executing a path. Hallway following, for example, could be accomplished simply by steering the robot so as maintain the same distance measurements from side- facing sonars. Thus, the robot could adjust its path mid-course to coincide more closely with the path being followed, greatly increasing the reliability of the robot’s path following. Higher level actions would also compress path specifica- tions. With the concept of hallway-following, a path could specify that the robot go down a hallway until the first intersection, the robot executing this path by using its hall- way following rules until the hallway ends (i.e., at the first intersection. The LQGnet itself could be used to disambiguate two matching LOGS. To verify that it is really in the corresponding previous location, the robot could perform the actions of an arc from the supposed current location and verify that it reaches the location represented by the connected LOG. A similar technique is proposed in [4]. Our implementation’s reliability could also be increased if LOGS contained information about the identity of the obstacles surrounding the robot (e.g., the robot is facing an elevator). By checking for the existence of particular objects, similar locations could be distinguished from others that look identical as seen by the sonars. 6 Co n LNNS, the LOGnet Navigation System demonstrates that the hybrid-graph spatial representation described above pro- vides a compact and robust spatial representation for naviga- tion. LOGS, analogical, local depth maps, allow the robot to reliably identify its location, and the SABRS Subsump- tion Architecture-Based Rule System provides the real-time, signal-symbol interface that links the landmark locations to- gether procedurally. The LOGnet representation avoids the cumulative errors associated with non-incremental metric spatial representa- tions and enables the robot to recover from path execution errors quickly and effectively. The hybrid-graph spatial rep- resentation also fits human’s natural approaches to navigation, relying on landmarks and procedural information rather than on absolute distances and dead-reckoning. Acknowledgments We would like to thank Norman Haas, Albert0 Elfes and Paul Viola for their contributions to this work. References I31 [21 [31 i41 151 WI Nilsson, N. A Mobile Automaton: An Application of Artificial Intelligence Techniques. In Proceedings of the International Joint Conference of Artificial Intelligence, 1969,509-520. Brooks, R. A. A Hardware Retargetable Distributed Layered Architecture for Mobile Robot Control. In Proceedings of the IEEE International Conference on Robotics and Automation, 1987,106-I 10. Davis, E. Representing and Acquiring Geographic Knowledge. Los Altos, California: Morgan Kauffman Publishers, Inc., 1986. Kuipers, B. J. and Y. Byun. A Robust Qualitative Method for Spatial Learning. In Proceedings of the AAAI-88 Seventh National Conference on Artificial Intelligence, August, 1988, pp. 774-779. A. Elfes. Sonar-Based Real-World Mapping and Navi- gation. In IEEE Journal of Robotics and Automation, v. RA-3, n. 3, June 1987. A. Elfes. A Tesselated Probabilistic Representation for Spatial Robot Perception and Navigation. In Proceed- ings of the 1989 JPL/NASA Conference on Space Teler- obotics, January 31- February 2,1989, JPL, Pasadena, CA. 1050 ROBOTICS
|
1990
|
55
|
973
|
Towards a System Architecture Sup Gerhasd Fischer,l Andreas C. Lemke,l and Raymond McCall2 Dept. of Computer Science,’ College of Environmental Design,2 and Inst. of Cognitive Science1*2 Engineering Center ECOT 7-7, University of Colorado, Boulder, CO 80309-0430 (gerhard, andreas)@boulder.colorado.edu, mccall~r@cubldr.colorado.edu Abstract We have developed a conceptual framework and a demonstration system that contextualize (or situate) learning in the context of real-world work situations. The conceptual framework is based on the following requirements: the choice of tasks and goals must be under the control of the user, not the system. The environment must be able to situate learning, allow situations to “talk back,” support reflection-in-action, identify the instructional information relevant for tasks at hand, and turn breakdowns from disasters into opportunities for learning. Learning must not disrupt or interfere with solving a problem, and new information to be learned must help to accomplish the task at hand. Our demonstration system JANUS (developed for the domain of architectural design) is built on an integrated architecture: a knowledge-based construction component, a hypermedia-based argumentation component, a set of critics, and a catalog of prece- dent solutions. Contextualized learning is supported by the critics that link construction and argumentation, and precedent solutions from the catalog that situate argumentation. Evaluation of JANUS and the underlying conceptual framework have shown that this approach combines some of the best features of open-ended learning environments and tutoring systems.’ Introduction We have developed a prototype and an architecture for knowledge-based design environments that contextualize learning. Our system uses knowledge-based construction kits and hypermedia to contextualize learning, i.e., to en- able users to learn within the context of their work on real-world problems. With such systems, learning does not take place in a separate phase and in a separate place but is integrated into the work process. The system lets users construct solutions to their own problems, advises them when they are getting into trouble, and provides directly relevant information. By letting users see for themselves the usefulness of new knowledge for actual problem situa- tions, the system improves the motivation to learn. In this paper, we discuss the necessity and rationale to support contextualized learning, develop a conceptual framework for the problem and describe JANUS as a demonstration system illustrating the approach. From the specific system we derive a generalized architecture for such systems. Our evaluations of our effort identified the limitations of our current work and suggested a number of lThis research w as partially supported by grants No. DCR-8420944 and No. IRI-8722792 from the National Science Foundation, grant No. MDA903-86-CO143 from the Army Research Institute, and grants from the Intelligent Interfaces Group at NYNEX and from Software Research Associates (SRA), Tokyo. 420 EDUCATION AND ARTIFICIAL INTELLIGENCE extensions for future research. The Need to Contextualize Learning Doing problem solving and design well has always been difficult, but the explosive growth of technology is greatly magnifying this difficulty. In technologically oriented design fields, the knowledge base needed for design is growing and changing at an alarming rate (Draper, 1984; Fischer, 1988). Learning everything in advance is impos- sible because there are too many things to learn. Humans cannot keep up with developments in their own fields, much less in other fields of potential relevance. The large and growing discrepancy between the amount of poten- tially relevant knowledge and the amount an individual can know and remember puts a limit on progress in design. Overcoming this limit is a central challenge for developers of support systems. Designers can no longer depend on learning everything they need to know before they enter the world of work. They must be able to learn on demand and learning must be contextualized. At least two things are required of a system that allows learning to take place within the context real problem-solving situations. First of all, instruction must relate to and serve the actual task situation at hand where the choice of tasks is primarily under the control of the problem solver, not the system. Secondly, learning must not disrupt or otherwise interfere with solving the problem. The system must avoid the “production paradox,” (Carroll, Rosson, 1987) where learning is in- hibited by lack of time and working is inhibited by lack of knowledge. The designer must regard the time and effort invested in learning to be immediately worthwhile for the task at hand - not merely for some putative long-term gain. Contextualizing learning shares goals with the concept of “cognitive apprenticeship” of (Collins, Brown, New- man, 1989). They characterize their approach as follows: Perhaps as a byproduct of the relegation of learning to schools, skills and knowledge have become abstracted from their uses in the world. In apprenticeship learning, on the other hand, target skills are not only continually in use by skilled practitioners, but are instrumental to the accomplishment of meaningful tasks. Contextualizing learning requires more support than tutoring systems or open learning environments can provide. The strength of tutoring systems (Anderson, Reiser, 1985; Psotka, Massey, Mutter, 1988; Polson, Richardson, 1988; Wenger, 1987) lies in their ability to teach basic concepts and skills of a problem domain. However, they cannot be designed to closely match the concrete problem solving situations of users. Problems From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. presented by tutoring systems are often well-defined and prespecified by the system rather than ill-structured and arising out of real-world contingencies. With tutoring sys- tems, learners are left to acquire task application knowledge on the job, after the completion of formal train- ing. It is left to the learner to relate such training to real- world problem situations. Open learning environments (e.g., LOGO (Papert, 1980)) do not suffer from the problem that presentation of instruc- tional material is system-controlled without regard to the learner’s situation, but these systems provide limited sup- port in helping learners detect mistakes or overcome break- downs. Misconceptions may accumulate into chains in which each later misconception is based on a previous one. Learners get trapped on suboptimal plateaus because they fail to discover the knowledge needed for better design. Contextualized learning has the potential to overcome these shortcomings. Since the learning context is triggered by the actual working context, applicability of the knowledge is clear. Elaboration of new knowledge and inferential recall is facilitated by the familiarity of the working situation. Learning in work situations fosters ef- ficient impasse-driven learning (VanLehn, 1988). Computer-based contextualized learning environments could tailor instruction to the special learning needs of dif- ferent users and could monitor users’ success in applying knowledge. A Conceptual Framework for Contextualized Learning Our understanding of contextualized learning is based on an analysis of learning as situated and of seeing reflection- in-action as a crucial process in design. Situated Learning. Situating learning requires in- tegrating learning into situations for which that learning is useful. Instructional information needs to be related to the specific tasks which it serves and doing so while those tasks are being undertaken. General concepts and prin- ciples have to be mapped onto specific instances. A growing number of researchers (Lave, 1988; Schoen, 1983; Schoen, 1987; Suchman, 1987; Winograd, Flores, 1986) argue that no amount of knowledge of principles suffices to account for successful action in real-world problem situations. An additional skill is needed: contextual elaboration, i.e., the ability to go beyond general procedural prescriptions to devise specific courses of action and to make intelligent exceptions to principles. Learning is not truly situated unless the learner can per- form such contextual elaboration. Reflection-in-Action. Underlying the reflection-in-action approach (Schoen, 1983) is an “action-breakdown-repair model” of the relationship be- tween action and rational thought. Design is seen as repeated alternation between situated action and reflection. The former is governed by a non-reflective thought process and proceeds until it breaks down. A breakdown occurs when the designer realizes that non-reflective action has resulted in unanticipated consequences - either good or bad. Schoen describes this feedback as “the situation talk- ing back.” Reflection is used to repair the breakdown, and then (non-reflective) situated action continues. Reflection- in-action is different from pre-planning and post-mortem analysis because it takes place within the action present, i.e., the time period during which the decision to act has been made but the final decision about how to act has not. This is the period during which reflection can still make a difference to what action is taken. Schoen gives extensive arguments and examples that it is during reflection-in- action that instructional information can best be presented. Integrating Construction and Argumentation. The concepts of situated learning and reflection-in-action need to be further operationalized and augmented if they are to provide a basis for a system architecture. We have done this conceptual elaboration in conjunction with the build- ing and testing of a prototype which provided an “object- to-think-with.” These efforts led us to interpret action as construction and reflection as argumentation. Construction is the process of shaping the solution - e.g., manipulating the form of a building. Argumentation is the reasoning about the problem and its solution. The problem of contextualizing design learning thus be- comes one of integrating construction and argumentation. In particular, the system must help designers to do the following: e to see where their construction knowledge is inadequate (to perceive breakdowns, to “let the situation talk back’ ‘); 0 to find the argumentative knowledge they need for such situations (ideally, all the knowledge and only the knowledge needed for the tasks at hand); e to understand how generalized principles of design re- late to their particular construction situations; e to understand how to perform the contextual elaboration needed to go beyond principles - i.e., to make intel- ligent exceptions and perform detailed situated construc- tion. A Demonstration System: JANUS JANUS (Fischer, McCall, March, 1989) is a integrated design environment comprising two subsystems: JANUS-CRACK (see Figure l), a knowledge-based construc- tion component and JANUS-VIEWPOINTS (see Figure 2), a hypermedia argumentation component. The former con- sists of a domain-oriented construction kit, a set of rule- based critics that “judge” the object under construction, and a catalog of completed designs. The domain of JANUS is architectural design, specifically kitchen design. The critics (Fischer et al., 1990) in JANUS-CRACK evaluate design decisions and provide feedback when design prin- ciples are violated. JANUS supports the construction of an artifact either “from scratch” by combining the primitives from the palette or by modifying an already constructed artifact from its catalog of previously designed kitchens. The designer can browse through this catalog until an inter- esting design is found. This can then be brought into the FISCHER ET AL. 421 Janus-CRACK ette Context: Appliances doors Qll7 windows - sinks loollol York Area I Clear Critique All Praise All New Class New Rule New Relation right-hinged-door-l Learning-Example-3 double-bowl-sink-1 single-door-refrigerator-l base-cabinet-l base-cabinet-2 right-hinged-door-2 h of the work triangle is greater than 23 feet. (FOUR-ELEME corner-cabinet-l base-cabinet-3 *four-clement-stove-1 dishwasher-l Figure 1: JANUS-CRACK This screen image shows JANUS-CRACK, the construction component of JANUS. Building blocks (design units) are selected from the Puktte and moved to desired locations inside the Work Area. Designers can reuse and redesign complete floor plans from the Catalog. The Messages pane displays critic messages automatically after each design change that triggers a critic. Clicking with the mouse on a message activates JANUS-VIEWPOINTS and displays the argumentation related to that message. work area and modified to the designer’s liking. JANUS-VIEWPOINTS (see Figure 2) is an issue-based hy- permedia system (McCall, 1987) containing answers, ar- guments and subissues. Its arguments use design knowledge ranging from building codes describing safety rules to work flow rules such as the work triangle rule. The system allows designers to learn about what issues have to be resolved, about possible answers to these issues, and why and when these answers are appropriate. The knowledge-based critiquing mechanism is the main means for bridging the gap between construction and ar- gumentation. This means that JANUS-CRACK and JANUS-VIEWPOINTS are coupled by using JANUS’S critics to provide the designer with immediate entry into the exact place in the hypermedia network where the argumentation relevant to the current construction task lies. This solves two problems: It greatly enriches the argumentative infor- mation for construction, it allows hypermedia-based ar- gumentation to be used during construction and it contex- tualizes learning by exposing designers to directly relevant knowledge. The catalog contains both positive and negative “learn- ing examples” (see Figure 1). The positive examples in the catalog can be used to learn design principles and ex- plore their argumentative background by bringing them into the work area and applying the Praise AZZ command to them. This results in the critics pointing out design prin- ciples that are not violated. The negative examples violate design principles embedded in JANUS. After such an ex- ample is brought into the work area, critics will fire provid- ing the learner a list of the violated design principles. Both praise and criticism provide the users with entry points into the hypermedia system, where the argumentative back- ground of the principles can be explored by navigation. The integrated system supports contextualized learning by providing argumentative information for construction effectively, efficiently and without designers’ having to (1) realize they need information, (2) suspect that needed in- 422 EDUCATION AND ARTIFICIAL INTELLIGENCE Answer (Stove, Door) The stove should be away from a door. Figure 5: stove-door Argument (Fire Hazard) By placing the stove too close to a door it will be a fire and burn hazard to unsuspected passers by (such as small children)1 Argument (Dining Room) If the door leads into a dining room, it will be easy to bring hot food from the stove into the dining area! the stow Is away from a door VIsIted Nodes Answer (Refrigerator, Windou) Section Description (Work Triangle) Section Rnsuer (Refrigerator, Stove) Section Ansuer (Stoue, Sink) Section IB Answer (Stove, Door) Sect1 on Show Outline Done Show Exanpl e: “Finsuer (Stove Door)” Figure 2: JANUS-VIEWPOINTS This screen image of JANUS-VIEWPOINTS shows an answer to the issue of where to locate the kitchen stove with respect to doors and graphically indicates the desirable relative positions of the two design units. Below this is a list of arguments for and against the answer. The example in the upper right comer (activated by the “Show Example” command in the “Commands” pane) contextualizes an argumentative principle in the context of a specific design (retrieved by the system from the catalog). formation is in the system or (3) know how to retrieve it. The system also contextualizes the general principles con- tained in the hypermedia system by dynamically showing examples illustrating these principles in the context of specific designs. A System Architecture to Contextualize Learning The system building effort around JANUS served as a start- ing point for a generalized architecture for design environ- ments in support of contextualized learning. The major components of such an architecture are (see Figure 3): a construction kit, argumentative hypermedia, critics, and a catalog. Construction Kit. The construction kit provides a palette of domain abstractions for construction of artifacts. The domain abstractions preserve the situatedness of work in the problem domain. Designers can think about problem situations without the distraction of having to Figure 3: A System Architecture Supporting Contextualized Learning think about communicating with the computer. Critics. Successful design requires that the situation taZks back (Schoen, 1983). However, for designers who do not have extensive experience in the domain, the situation is often mute unless the learning environment has a com- ponent that speaks up and points out issues that the desig- ner may otherwise not consider. Critics can fulfill this role. Critics point out suboptimal aspects of the artifact and retrieve relevant issues in the issue base. Critics thus FISCHERETAL. 423 contextualize learning in two ways: by identifying learn- ing needs through real-time analysis of actual construction situations and by presenting just the argumentative infor- mation useful for those needs. Argumentative Hypermedia. Contextualized learning can only be effective if the flow of work is not disrupted. This requires rapid and timely access to relevant infor- mation in the issue base, a collection of argumentation on recurring issues in the problem domain. Issue-based hy- permedia (McCall, 1987) make designers aware of issues, possible answers, and argumentation, and allows them to incremental1 y specify personal design constraints at various levels. The PHI (Procedural Hierarchy of Issues) approach to issue-based hypermedia structures information according to its relevance to design tasks (issues). It contains prin- ciples of design together with the argumentative back- ground necessary for contextual elaboration. The rich con- nectivity of hypermedia allows immediate access to ex- planatory, elaborative and other types of information. Hy- permedia also accommodates individual differences in prior knowledge and learning styles - crucial contextual factors. Users with little knowledge can explore the hyper- media network in depth, while knowledgeable users can ignore links to known information. Catalog. The catalog is an evolving collection of ar- tifacts accumulated by the actual use of the system. It il- lustrates the space of possible designs in the domain. For instructional purposes, the catalog can be enriched with positive and negative learning examples (see Figure 1). The catalog examples are contextualized that the system dynamically selects and presents those examples that not only illustrate the concept but most closely correspond to the construction situation at hand (see Figure 2). Catalog examples provide a link back from argumentation to con- struction by making abstract principles concrete and ready to be integrated into the artifact under construction. Catalog examples support case-based reasoning (Ries- beck, Schank, 1989; Rissland, Skalak, 1989) to comple- ment the generalized argumentative reasoning in the issue base. To this end, catalog examples are annotated with design rationale that allows designers to assess the relevance of the example to the situation at hand. This allows them to provide examples for how to make intel- ligent exceptions to design principles and to do other types of contextual elaboration - which by definition go beyond what can be stated in principles. The user can indepen- dently analyze catalog examples with the critics to dis- cover design principles in the context of specific construc- tion situations. Evaluation, Limitations, and Future Work Evaluation. Our evaluation using professional and amateur designers showed that contextualized learning can be supported by JANUS. Users extend their knowledge in a demand-driven way and breakdowns in the systems were perceived as learning opportunities. Users were able to un- derstand the purposes and uses of the new knowledge en- countered. The different components of the architecture enabled users to learn new knowledge in multiple contexts: tied to the contexts of its uses and independent of any particular context. Limitations. Our evaluation also showed several shortcomings of the current system. One is that JANUS allows views of the artifact only at the individual room level and not at a higher or lower level of aggregation. A second is that it does not support functional simulation. This is a technique frequently used by designers to under- stand the consequences of design decisions - increasing the possibilities of letting the situation talk back - by simulating use of the design. A third is that JANUS does not allow designers to volunteer their goals, preferences, and specifications (Fischer, Stevens, 1987) and therefore fails to realize the full potential of critics and the argumen- tation component to give advice tailored to the actual problem situation. Extended Architecture. In order to overcome these limitations we are in the process of developing an extended architecture containing the following components: 0 Specification component. Design is a process of trading off competing goals such as minimizing cost or max- imizing reliability or extensibility, and the final artifact depends on which tradeoffs are acceptable. Without knowing and adapting to such characteristics of the specific problem situation, the system’s appearance will remain abstract. A specification component would al- low the designer to input these characteristics, and the system can use them to better situate its information structures by filtering out argumentation, critics, and catalog examples that are not relevant to the specified problem situation. * Simulation component. Evaluations of the JANUS system by expert designers have demonstrated a need for simulating usage scenarios with the artifact being designed. Such functional simulations can take the form of deterministic mathematical models as well as infor- mal what-if games. Functional simulation enhances fur- ther the capability of the construction situation to talk back to the designer. e Dynamic Recomputation of Hypermedia Networks. To situate the issue and argumentation structure, the issue base must be active, that is, it must filter out information that is irrelevant to the current construction situation, even if that information is relevant for other hypothetical situations. The situated information structure then is much more manageable. Concretely, an issue base can be better situated by suppressing issues that are made irrelevant by answers to other issues, and, secondly, by inferring answers from information the designer has previously specified and from design decisions that have already been made. New Application Domains. In order to test the generality of our architecture, we will test this approach with other application domains. Our previous work has concentrated on the domain of kitchen design. A first test of the generality was conducted by designing and im- 424 EDUCATIONANDARTIFICIALINTELLIGENCE plementing with the same basic architecture a system for user interface design (Len&e, 1989). We are currently in the planning stage-to apply the approach to more general architectural design issues (e.g., design of buildings) in combination with a technical domain (e.g., the design of high-speed digital communication networks within these buildings). Future Issues for Investigation. With these new fea- tures added to our design environments, we will be able to investigate issues such as the following: (1) Will there be substantial differences in performance if the system is used with and without critics, catalog, and simulation com- ponent? (2) What are the most important components in our architecture that enable situated learning? How should these components be structured? (3) What intervention strategies should the system use for displaying enough in- formation at the right time without disrupting the work process? (4) When are designers willing to suspend the construction process to access relevant information? (5) When will designers challenge or extend the knowledge represented in the system? and (6) When are subjects will- ing to enhance the knowledge structures (Fischer, Girgen- sohn, 1990)? Conclusions In order for designers to cope with the deluge of knowledge for design they must integrate learning into their everyday work. With the described research, we have created an initial conceptual framework for such contex- tualized learning. This framework was illustrated with a prototype system utilizing argumentative hypermedia and knowledge-based critics. From this a preliminary architec- ture for integrated knowledge-based design environments was developed. Evaluation has shown the benefits and limitations of this approach and, in particular, showed that additional components are needed to contextualize learning more fully. In our future research we will develop and test these new components. Our goal is to develop systems which become means for lifelong learning. Ultimately, such environments for contextualized learning might allow learning to become a more personal, less alienating process not separate from the rest of our life. Acknowledgements. The authors would like to thank Andreas Girgensohn, Anders March, Kumiyo Nakakoji, and Jonathan Ostwald who have made major contributions to the JANUS system. References J.R. Anderson, B.J. Reiser (1985). The LISP Tutor. BYTE, 10(4), 159-175. J.M. Carroll, M.B. Rosson (1987). Paradox of the Active User: In J.M. Carroll (Ed.), Interfacing Thought: Cognitive Aspects of Human-Computer Interaction (pp. 80-l 11). Cambridge, MA: The MIT Press. A.M. Collins, J.S. Brown, S.E. Newman (1989). Cognitive Apprenticeship: Teaching the Crafts of Reading, Writing, and Mathematics: In L.B. Resnick (Ed.), Knowing, Learning, and Instruction (pp. 453-494). Hillsdale, NJ: Lawrence Erlbaum Associates. S.W. Draper (1984). The Nature of Expertise in UNIX. Proceedings of INTERACT’84, IFIP Conference on Human-Computer Interaction, 182- 186. Amsterdam: Elsevier Science Publishers. 6. Fischer (1988). Enhancing Incremental Learning Processes with Knowledge-Based Systems: In H. Mandl, A. Lesgold (Ms.), Learning Issues for Intelligent Tutoring Systems (pp. 138-163). New York: Springer-Verlag. G. Fischer, A.C. Len&e, T. Mastaglio, A. March (1990). Using Critics to Empower Users. Human Factors in Computing Systems, CHI’90 Cor#erence Proceedings (Seattle, WA), 337-347. New York: ACM. G. Fischer, A. Girgensohn (1990). End-User Modifiability in Design Environments. Human Factors in Computing Systems, CHp90 Conference Proceedings (Seattle, WA), 183-191. New York: ACM. G. Fischer, R. McCall, A. March (1989). JANUS: Integrating Hypertext with a Knowledge-Based Design Environment. Proceedings of Hypertext’89,105-117. New York: ACM. 6. Fischer, C. Stevens (1987). Volunteering Information -- Enhancing the Communication Capabilities of Knowledge-Based Systems. Proceedings of IlVTERACT’87,2nd IFIP Conference on Human-Computer Interaction (Stuttgart, FRG), 965-971. Amsterdam: North-Holland. J. Lave (1988). Cognition in Practice. Cambridge, MA: Cambridge University Press. A.C. Lemke (1989). Design Environments for High-Functionality Computer Systems. Unpublished doctoral dissertation, Boulder, CO: Department of Computer Science, University of Colorado. R. McCall (1987). PHIBIS: Procedurally Hierarchical Issue-B ased Information Systems . Proceedings of the Conference on Architecture at the International Congress on Planning and Design Theory. New York: American Society of Mechanical Engineers. S. Papert (1980). Mindstorms: Children, Computers and Powerful Ideas. New York: Basic Books. M.C. Poison, J.J. Richardson (Eds.). (1988). Foundations of Intelligent Tutoring Systems. Hillsdale, NJ: Lawrence Erlbaum Associates. J. Psotka, L.D. Massey, S.A. Mutter (Eds.). (1988). Intelligent Tutoring Systems: Lessons Learned. Hillsdale, NJ: Lawrence Erlbaum Associates. C. Riesbeck, R.C. Schank (1989). Inside Case-Based Reasoning. Hillsdale, NJ: Lawrence Erlbaum Associates. E.L. Rissland, D.B. Skalak (1989). Combining Case-Based and Rule-Based Reasoning: A Heuristic Approach. Proceedings of the Eleventh International Joint Conference on Artificial Intelligence, 524-530. D.A. Schoen (1983). The Reflective Practitioner: /tow Professionals Think in Action. New York: Basic Books. D.A. Schoen (1987). Educating the Reflective Practitioner. San Francisco, CA: Jossey-Bass Publishers. L.A. Suchman (1987). Plans and Situated Actions. New York: Cambridge University Press. K. VanLehn (1988). Toward a Theory of Impasse-Driven Learning: In H. Mandl, A. Lesgold (Eds.), Learning Issues for Intelligent Tutoring Systems (pp. 19-41). New York: Springer-Verlag. E. Wenger (1987). Artificial Intelligence and Tutoring Systems. Los Altos, CA: Morgan Kaufmann Publishers. T. Winograd, F. Flores (1986). Understanding Computers and Cognition: A New Foundation for Design. Norwood, NJ: Ablex Publishing Corporation. FISCHERETAL. 425
|
1990
|
56
|
974
|
Backward Model Tracing: An Explanation-Based Approach for Reconstructing Student Reasoning Danilo Fum (*), Paolo Giangrandi(“), Carlo Tasso (“) (*) Dipartimento di Psicologia, Universit5 di Trieste Via dell’Universit.5 7, I-34123 Tries& Italy - fum@uts882.units.infn.it.bitnet (“) Laboratorio di Intelligenza Artificiale, Universita di Udine Via Zanon 6, I-33100 Udine, Italy - tasso@uduniv.infn.it.bitnet Abstract An original methodology, called backward model tracing to model student performance which features a profitable integration of the bug collection and bug construction techniques is presented. This methodology has been used for building the modelling module of a new version of ET (English Tutor), an ITS aimed at supporting the learning of the English verb system. Backward model tracing is based on the idea of analyzing the reasoning process of the student by reconstructing, step by step and in reverse order, the chain of reasoning (s)he has followed in giving his/her answer. In order to do this, both correct domain specific knowledge and a catalogue of stereotyped errors (mahules) are utilized. When the system is unable to explain the student behavior by exploiting its previous knowledge, new malrules are generated dynamically, by utilizing explanation-based learning techniques. The overall process is based on a deep modelling of the student problem solving and the discrimination among possible explicative hypotheses about the reasons underlying the student behavior is carried on non- monotonically through a truth maintenance system. The proposed approach has been fully implemented in a student modelling module developed in PROLOG. I. Introduction One of the most important features an intelligent tutoring system (ITS for short) should provide, is the capability to adapt its behavior to the specific traits of the student. To this purpose, a fundamental contribution is given by the component aimed at building and maintaining the student model. The student model describes the knowledge and beliefs of the student in the specific subject domain and is used for designing and taking appropriate tutorial and remedial actions, tailored to the peculiarities of the student. Building an ITS with a student modelling component is hindered by several problems concerning both theoretical and practical issues. There is a sufficiently general agreement on the fact that the modelling activity cannot be based only on the knowledge provided by an expert in the domain but it is better performed by relying on an explicit description of possible student (mis)behaviors. 426 EDUCATION AND ARTIFICIAL INTELLIGENCE Unfortunately, no agreed-upon solution exists on this topic and the three main approaches adopted for building student modelers (i.e., overlay, bug collection and bug construction: Wenger 1987) directly reflect this situation. In fact, each technique has been generally used alone and no clear ways have been proposed to combine these techniques in order to exploit their respective advantages. Considered by itself, each technique has known drawbacks and falls short of constituting an ideal tool for building cognitively adequate and computationally sufficient student models: overlay is generally considered as not sufficiently powerful to perform sophisticated modelling, collecting catalogues of bugs is notoriously a dull and labor- intensive endeavor, while bug construction has not yet proved to be a reliable and sufficiently comprehensive approach. In this paper we present an original methodology, called backward model tracing to model student performance which features a profitable integration of the bug collection and bug construction techniques. This methodology has been used for building the modelling module of a new version of ET (English Tutor), an ITS aimed at supporting the learning of the English verb system. Backward model tracing is based on the idea of analyzing the reasoning process of the student by reconstructing, step by step and in reverse order, the chain of reasoning (s)he has followed in giving his/her answer. In order to do this, both correct domain specific knowledge and a catalogue of stereotyped errors (malrules) is utilized. When the system is unable to explain the student behavior by exploiting its previous knowledge, new malrules are generated dynamically, by utilizing explanation-based learning techniques. The overall process is based on a deep modelling of the student problem solving and the discrimination among possible explicative hypotheses about the reasons underlying the student behavior is carried on non- monotonically through a truth maintenance system. Backward model tracing seems a promising approach to tackle the hard problem of student modelling (Self 1988) for the following reasons: - it shares the benefits of the model tracing methodology (Anderson 1987); - it exploits the respective advantages of bug collection and bug construction without the limitation of the exclusive usage of a single technique; From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Figure 1. The tense generation process. - it exploits a sophisticated technique such explanation- based learning to push the limits of the bug construction methodology. The paper is organized as follows: The following section briefly presents the ET system where backward model tracing has been applied. Section 3 illustrates the general criteria upon which the methodology is grounded. Section 4 and 5 describe the technical details of the modelling process focusing on the generation of explanatory hypotheses about the causes of the student erroneous behavior and on the discrimination among the formed hypotheses, respectively. Section 6 presents the conclusions of the work. 2. Second Language Tutoring in ET The backward model tracing methodology has been utilized in the new version of the ET system (Fum, Giangrandi, & Tasso 1988), an ITS aimed at supporting Italian students in the learning of the English verb system. ET comprises an articulated knowledge-based domain expert (Fum, Giangrandi, & Tasso 1989), devoted to tense generation, capable to solve fill-in exercises constituted by one or more sentences in which some verbs have to be conjugated into the appropriate tenses. The operation of the domain expert is organized around a sequence of five phases (illustrated in figure l), each devoted to a specific (sub)process, namely: - parsing the exercise sentence(s); - recognizing the temporal relations among the events described in the sentence(s); - identifying the reference time for every clause in the , sentence(s); - selecting the correct tense to be used for each verb; - conjugating the verb(s) into the appropriate tense. Each process is carried out by a dedicated processor, which is supported by a knowledge base encoding the knowledge usually exploited by humans for that subtask. The main representation paradigm utilized in the knowledge bases is constituted by production rules. The generation expert produces also a precise track of the reasoning performed and of the knowledge utilized for solving the exercises. The second fundamental module of ET is the tutor which is devoted to define the modalities of the teaching activity. More particularly, the tutor assigns the exercises according to a given syllabus, cooperates with the modeler in order to discriminate among alternative hypotheses about the student erroneous behavior, and manages the dialogue with the student. The student modeler is the module which implements the backward model tracing methodology. The general goal of this module is to discover the domain specific knowledge the student has utilized in order to derive her/his answer(s). The modelling process aims at constructing a model of the students beliefs in which both correct knowledge and misconceptions are explicitly represented. The student model, which is partitioned into different parts, one for each computational phase, contains therefore a collection of facts and rules that have been utilized in order to interpret the student behavior and that are supposed to mirror what the student knows/beliefs about the subject domain. The student model supplies the basis for remedial activity which is aimed at correcting the student misconceptions. The structure and the functioning of this module constitutes the subject of this paper. FUMETAL. 427 3. Modelling Student Performance Backward model tracing relies on two basic assumptions: (i) in achieving the solution, the student follows a process akin to that used by the expert module i.e., it goes through the same phases and performs essentially the same kind of computations, and (ii) the student mistakes can be modelled by appropriately perturbing the knowledge utilized by the expert module. Some words are needed in order to justify these assumptions. It could be claimed that assumption (i) is unrealistic: in fact it is easy to find evidence that novices solve problems by using strategies that are different from those utilized by experts (e.g., diSessa 1982; Reif 1987). While this cannot be denied, it is also true that, in order to be able to model possible student misbehaviors, a model of the correct performance is required. The student behavior needs thus to be compared with that of an ‘expert’, being this a’real domain expert, a teacher or an ‘ideal student’ (Anderson 1987). The general philosophy followed in ITS development is to locate the domain specific knowledge in the expert module which plays therefore a twofold role: it acts as the source for the knowledge to be presented and, at the same time, it serves as the standard for evaluating the student’s performance” (Wenger 1987). In our context we assume that a student, trying to figure out the correct answer for an exercise, follows the same reasoning steps of the expert module, i.e. after interpreting the meaning of the exercise sentences (s)he computes the temporal relations between the states/events described in the sentence, calculates the reference times for every clause of the sentence, chooses the tense for the verb and, finally, conjugates the verb in that tense. Assumption (i) implies that the errors the student makes could derive only from the fact that some of the rules (s)he applies are ‘bugged’, not from the fact that (s)he can follow computational paths different from those of the expert. Assumption (ii), (shared by other authors: Brown & Burton 1980; Sleeman 1983; Bonar & Soloway 1985) states that it is possible to model these bugs by assuming more or less severe deviations from the knowledge base actually utilized by the expert module. Backward model tracing is grounded on the idea of trying to reconstruct, step by step and in reverse order, the chain of reasoning the student has followed in building the answer. Backward model tracing is triggered by the discovery of a mismatch between the answer given by the student and that provided by the expert module. The goal of the modelling process is to identify the phase(s) where the reasoning process of the student and of the expert differ, and the specific erroneous rules (malrules) applied by the student. Backward model tracing analyzes the reasoning process performed by the student starting from the last phase and going back toward the first ones. For each phase, the modeler tries to determine the input to the phase and the knowledge the student has utilized in order to produce the corresponding output. If a mismatch between the student and the expert output is discovered, it could mean that: (a) some of the rules contained in the knowledge base utilized by the student in that phase, or (b) some of the data utilized as input for that phase or, (c) both some of the rules and the data differ from those utilized by the expert. The goal of the diagnostic process performed by the modeler is to realize which of the above alternatives holds. Case (a) is true when both the expert and the student work with the same input data but their output is different because some of the rules contained in the student knowledge base are actually bugged. In this case a remedial activity could be planned in order to clarify the student misconceptions. As an example of case (a) let us consider the case when both the student and the expert have to form the present perfect of ‘to study’ and the student produces as an answer ‘has studyied’. If (b) is true, then at least one of the previous phases should be blamed for producing the erroneous data and the diagnostic process is repeated focusing on the phase immediately preceding the current one. As an example of (b) let consider the case of the student answering ‘has studied when in fact the correct verb tense is the past perfect. If (c) is true, then both the above mentioned activities occur, i.e., the malrules responsible for the mistake made in that phase are identified and the diagnostic process continues with the preceding phases. An example of case (c) is the answer ‘has studyed’ given when the past perfect is required. Backward model tracing shares all the features of the model tracing methodology (Anderson 1987), i.e. it tries to simulate dynamically a student’s problem solving and uses that simulation to interpret the student behavior. Differently from Anderson’s approach: - it does not rely only on a-priori established catalogue of correct and incorrect productions but it is able to dynamically generate the malrules necessary to explain the student performance; - the tracing occurs after the student has produced his/her performance and it is not used to monitor the student during the solution process just to assure that the correct path will be followed. As a result, backward model tracing possibly represents a less intrusive modelling methodology and a more general diagnostic procedure. Having established the general features of our approach to student modelling, we concentrate now on the technical details of the diagnostic process as it is performed within a single phase. 4. Explaining the Student Answer The diagnostic process aimed at reconstructing the student reasoning for each single phase can be divided in two activities: the first is aimed at generating all the possible lines of reasoning which constitute putative explanations of how the student determined his solution in that phase; the second is aimed at discriminating among the different candidate explanations trying to discover the one(s) that best account(s) for the actual student reasoning. The present section explains how the first activity is performed; section 5 deals with the hypotheses discrimination activity. 428 EDUCATIONANDARTFICIALINTELLIGENCE In order to formulate possible explanations for the student behavior, the modeler operates in backward chaining and generates a derivation tree containing the rules and facts used to produce the output of the phase. More precisely, the output is considered as explained if it is possible to prove it by exploiting the production rules contained in the knowledge base the student utilizes for that phase. As a result of the diagnostic process, the modeler will be able to identify the input data for that phase and the possible malrules utilized by the student. In order to give a more comcrete idea of the diagnostic process, let us follow the system operation through a worked out example, restricted for simplicity only to the last verb conjugation phase. The student, requested to conjugate into the appropriate tense the verb ‘to study’, gives as an answer ‘is studyed’ while the output given by the expert module is ‘has studied’. As a first step, the modeler transforms the student answer into the following clause verb(Verb, Tense, Person, Number, [is, studyed]l[]) which represents the goal to be proven and whose first four arguments will be instantiated at the end of the diagnostic process with the input data for the phase. The modeler then tries to construct one or more derivation trees for that goal. To this purpose, the system tries to find, among the rules contained in the student knowledge base, that whose right hand side matches the current goal (if several rules match the goal, the modeler constructs several derivation trees in parallel) and it tries to prove each antecedent clause in the left hand side of the rule. If a clause constitutes a primitive goal (for example a fact contained in the dictionary) it is considered as proven and the modeler goes on to analyze a new clause, otherwise the modeler proceeds recursively by trying to build a derivation (sub)tree for that clause. The main improvement of our algorithm in comparison with similar approaches (e.g. classic backward chaining, the resolution plus oracle method reported in (Costa, Duchenoy, & Kodratoff 1988), and the technique utilized in (Sleeman 1983)), concerns the treatment of the failing situations. In fact, when the modeler finds a subgoal which is unprovable (i.e. which is neither a primitive goal nor can be demonstrated by applying the rules contained in the student knowledge base) it tries to recover from this situation by exploiting two different modelling strategies. First, it can resort to the bug collection technique by selecting in a catalogue of malrules, representing instances of stereotyped errors students generally make, an appropriate malrule which could be used to prove the current goal. This malrule is then imported as a hypothetical misconception into a/the derivation tree for the student answer. Second, if none of the available malrules is suitable to prove the current goal, the modeler tries to generate a new malrule by perturbing an expert rule; in other words a rule representing certain domain knowledge is purposely modified and made incorrect in order to use it to prove the original goal. This malrule is also imported into the derivation tree. While the first strategy simply utilizes the classic bug collection approach, the second strategy (bug construction) exploits machine learning techniques in order to generate new malrules. Among the possible machine learning techniques usable for generating new malrules, we have adopted an explanation-based approach (Mitchell, Keller, & Kedar-Kabelli 1986; DeJong & Mooney 1986). This approach, which has been already exploited in the field of ITS (Bar-On & Or-Bach 1988), seems particularly promising to be utilized for student modelling for the following reasons: - differently from other machine learning techniques, it requires only a few training instances (possibly only one) to be applied and it seems therefore particularly suitable for modelling when only a few student answers are available; - it is an intensive knowledge-based technique and it seems therefore suitable in a field where a lot of domain- dependent knowledge is available in terms of both the expert knowledge base and of diagnostic knowledge (i.e. knowledge about possible student errors). Bug construction thus constitutes the major tool when no a- priori information about a specific student (mis)behavior is available, i.e. when a student makes an error not contained in the bug library. The generative capability of the bug construction methodology, however, can be improved by taking into account other useful kinds of diagnostic knowledge. For this reason, we have generalized the bug catalogue approach in order to be able to represent any kind of misconception a student could possibly have about expert knowledge. The solution adopted is to allow the bug library to specify not only the malrules but also to describe possible perturbations of them (Hirsh 1985). To perturb a rule, the modeler uses the knowledge contained in the so- called meta-bug library of rules which specifies the kinds of perturbations that could be applied to a rule. This knowledge, which forms a theory of the possible errors students can make, is represented with general diagnostic rules whose condition part specifies a failing situation (a general pattern for a goal that cannot be proved) and whose conclusion part specifies a clause that could be used to replace the failing condition. Coming back to our example, the spelling error contained in the student answer can be explained by the following stereotyped malrule (MR 1): IF add-string(V,ed,V-ed) THEN form-ed(V,[V-ed IX]lX). which says that to form the ed-form of a verb it is sufficient to add the suffix ‘ed’ to the root form of the verb. Two rules of the meta-bug library (MB1 and MB2) utilized by the system are the following: IF verb(have,T,P,N,VlIV2) % Failure THEN verb(be,T,P,N,VlIV2). % Repair IF regular(Verb, Tense) % Failure THEN true. % Repair FUMETAL. 429 1 verb(study,present_perfect,3,singular,[is,studyed]/[]) the present perfect of ‘to study’, 3rd person singular, is ‘is studyed’ by rule Rl verb(have,simplegresent,3,singular.[is]/[]) verb(study,past-participle.[studyed]/[]) verb(be,simple_present,3,singular,[is]/[]) a word(be,form(simple_present,3,singular,[islX]/X) the simple present of ‘to be’. 3rd person singu/ar, is ‘is’ 02 in DICTIONARY Figure 2. A derivation tree. The first rule takes care of the case in which a student could use the auxiliary ‘to be’ instead of ‘to have’ (auxiliary inversion represents a typical error made by Italian students) by saying that, in order to prove a failing clause containing the verb ‘to have’, it is possible to replace it with a clause containing ‘to be’. The second rule takes care of the case in which the student may forget the constraint that, in order to use a given conjugation rule, a regular verb is required, by relaxing that constraint and considering the clause to be proven as true. In our example, the first me&rule allows to explain the incorrect use of the auxiliary. In fact, when the modeler tries to prove the original goal verb(Verb, Tense, Person, Number, [is, stu.dyed]l[]) it finds a match with the consequent of the following conjugation rule (Rl): IF verb(have,simplegresent,Person,Number,VIlV2), verb(V,pastgarticipl,V2tV3) THEN verb(V, presentgerfect,Person,Number, VI lV3). (the present perfect of a verb is formed by joining the simple present of ‘have’ and the past participle of the verb). To prove this goal it tries to prove the two antecedent clauses. It fails with the first one since nowhere it can find a rule that enables it to deduce that 430 EDUCATIONANDARTIFICIALINTELLIGENCE verb(have, simplegresent, Person, Number, [isll[l) (i.e. that the simple present of have is ‘is’). But now the meta-bug MB 1 can be applied to this clause thus obtaining verb(be,simplegresent,Person, Number, [is]l[]) which can be proven by looking at another rule (R2). By introducing this new clause it is possible to positively conclude the building of the derivation tree. Figure 2 illustrates a complete example of a derivation tree for the above discussed goal while figure 3 shows both a PROLOG and a natural language version of the knowledge utilized. Each node of the derivation tree (with the exception of the root) specifies a (partial) conclusion produced during the hypothesized reasoning process of the student, while the root represents the final output. In the specific case, the student built incorrectly the present perfect as a combination of the simple present of the verb ‘to be’ (rule Rl) and the ed- form of the verb ‘to study’. His wrong answer has been caused by the mistakes made in producing the present perfect and the ed-form of ‘to study’ (this mistake is represented in the bug catalogue by the malrule MRl). Since each derivation tree describes the reasoning of the student applied to a very specific situation, in order to be able to extract more general malrules it is necessary to generalize the derivation tree containing the mistake. CONJUGATION RULES %% Rl: The present perfect is formed with the simple present of the verb 9% 00 'to have' and the past participle of the verb. IF verb(have,simple_present,l?erson,Number,Vl/V2), verb(Vb,pastparticiple,V2/V3), THEN verb(Vb,present_perfect,Person,Number,Vl/V3). %% R2: The simple present of an irregular verb is contained in the dictionary. IF irregular(Vb,present_tense), word(Vb,form(simple~resent,Person,Number,Vl/V2)), THEN verb(Vb,simple_present,Person,Number,Vl/V2). %% R3: The past participle of a regular verb is formed with the ed-form %% of the verb. IF regular(Vb,pastparticiple), form_ed(Vb,Vl/V2), THEN verb(Vb,pastparticiple,Vl/V2). VERB DICTIONARY %% Dl: The simple present of the verb 'to be' is irregular. irregular(be,present_tense). %% D2: The simple present of the verb 'to be', 3rd singular, is 'is'. word(be,form(simple3resent,3,singular,[islX]/X)). %% D3: The simple present of the verb 'to have' is irregular. irregular(have,present_tense). %% D4: The simple present of the verb 'to have', 3rd singular, is 'has'. word(have,form(simple_present,3,singular,[hasiXl/X)). %% D5: The verb 'to study' is regular. regular(study,past-tense). BUG JJRRBEX %% MRl IF add-string(V,ed,V-ed) THEN form-ed(V,[V-edIX]/X). TA BUG TJRRARY %% MB1 IF verb(have,T,P,N,Vl/V2) THEN verb(be,T,P,N,Vl/V2). %% MB2 IF regular(Verb,Tense) THEN true. Figure 3. Domain and diagnostic knowledge. For this purpose, the modeler considers a more general structure, called explanation structure, which highlights the various rules (domain rules and possible diagnostic rules) applied during the construction of the derivation tree. Figure 4 illustrates the explanation structure originating from the derivation tree of figure 2. Each box contains the pair of rule clauses unified during the construction of the derivation tree. At this point, while the standard explanation-based learning technique works on the whole structure in order to extract a single general concept, our algorithm proceeds instead focussing on the subtrees containing some meta- bugs; more precisely, it considers those rules who have clauses linked to the me&bugs. From a single derivation tree it is thus possible to infer more than one malrule. In our example, illustrated in figure 4, the modeler concentrates upon the subtree constituted by rule Rl and the meta-bug MBl. For each subtree, the modeler unifies the rule clauses to which a meta-bug has been applied with the left hand side of the meta-bug and then it applies the substitution to the right hand side of the meta-bug. In our example, the antecedent clause of Rl verb(have, simplegresent,PI ,Nl ,VlIV2) is unified with the left hand side of meta-bug MB1 verb(have, T2, P2, N2, V4IV5) and the substitution (T2 a simple-present, P2 w Pl, N2 w Nl, V4 C+ Vl, V5 H V2) is then applied to the right hand side of the me&bug. The resulting right hand side of me&bug MB1 is thus: verb(be,simplegresent,PI ,Nl ,VI fV2) Now, the final step consists in substituting this clause to the antecedent of rule Rl. The final resulting malrule is therefore: FUMETAL. 431 verb(Vb,T,P,N,[is,studyed]/[]) verb(Vb1 ,present-perfect,Pl ,Nl ,Vl/V3) verb(Vb3,past_participle,VG/V7) 6 Figure 4. An explanation structure. IF verb(be,simplegresent,Pl ,Nl ,VlIV2), verb(Vb1 ,pastgarticiple,V2lV3) THEN verb(Vb1 qresentgerfect,Pl ,Nl, Vl/V3), - If the student answer is explained by a single derivation tree, the rules and the facts contained in the tree are inserted into the student model. meaning that the present perfect could be erroneously - If a hypothesized malrule appears in all the alternative formed with the simple present of the verb ‘to be’ and the derivation trees, it can be taken for sure and inserted into past participle of the verb. the student model. 5. Discriminating among Explanations In general, the result of the first modelling activity is a collection of derivation trees which represent different possible reasoning processes followed by the student. The second basic activity of the modelling process has the goal to test all the generated hypotheses in order to select the best one(s) which account(s) for the student performance. During this operation the modeler behaves non monotonically discarding contradictory or very unlikely hypotheses, retracting the disconfirmed assumptions and transforming hypotheses into certified facts. - If a derivation tree contains a number of perturbations which is greater than an established threshold, the derivation tree and its hypothesized malrules are discharged. - If a hypothesized malrule, applied to simulate the student behavior in an exercise different from that by which it was originally derived, produces an answer direrent porn that given by the student, then it is considered as unplausible and discharged. More particularly, in order to discriminate among the different candidate explanations the modeler has built, two strategies are followed. On one hand, some heuristic criteria are utilized to eliminate unplausible hypotheses or to derive new assertions about the student. On the other hand, the hypotheses about the reasons of the student behavior are maintained by utilizing a justification-based truth maintenance system (Doyle 1979; McAllester 1982). Some of the heuristic criteria utilized to discriminate among the different hypotheses are the following: The hypotheses the modeler makes about the student are managed through a justification-based truth maintenance system. In particular, the hypotheses are organized into a network (called dependency network ) which describes the dependency relations among different hypotheses. For example, the rules and the dictionary facts Rl, R2, R3, Dl, D2, and DS support the derivation tree of figure 2 and this derivation tree supports both the stereotyped malrule MRl and the newly constructed one. If some node of the network is deleted during the modelling process, then all the nodes that are dependent on it are also cancelled. This operation is achieved by following the edges of the dependency network. On the other hand, when a previously constructed 432 EDUCATIONANDARTIFICLALINTELLIGENCE hypothesis is confirmed, it is introduced into the student model and, furthermore, the consequences of this change are propagated through the dependency network thus influencing the truth of the other hypotheses supported by it. The diagnostic process requires generally also the cooperation of the tutoring module. When the information the system has about the student is insufficient to discriminate among the different alternative hypotheses generated by the modeler, the tutor can (i) assign new exercises in order to gather data to confirm or disconfirm them or (ii) can start an interactive (menu-driven) dialogue with the student. More precisely, the tutor selects from the exercise database the exercises related to the hypothesized misconceptions and, for each of them, the system determines the answers corresponding to these misconceptions. An exercise is considered as discriminating if it gives different answers for every different hypothesized misconception. The tutor then can select the most discriminating exercise. If no discriminating exercises are available, it is necessary to use the dialogue in order to establish which misconception reflects the student knowledge. It must be pointed out that the tutor considers not only the derivation tree(s) related to the last exercise but it also analyzes the derivation trees of the previous exercises in order to examine the remaining hypotheses. The analysis of a student misconception cannot therefore generally be completed in a single exercise but it requires a sequence of exercises. 6. Conclusions A new methodology for modelling student performance has been presented which could be used for making diagnosis in those systems that, like ET are based on processes decomposable into a finite number of subtasks related to each other through producer-consumer dependencies. It is claimed, in other words, that the deep modelling process illustrated in the paper has general significance beyond the domain of second language teaching and can constitute an attempt to deal with the problem of finding the reasons of and giving a satisfactory explanation to the student performance. Some features of the proposed approach that we find particularly original are: (i) the integration of the bug collection and bug construction techniques, (ii) the use of diagnostic knowledge contained in the me&bug library in order to help the process of bug construction, and (iii) the use of explanation based learning techniques in the domain of modelling students’ misconceptions. The proposed approach has been fully implemented in a student modelling module written in QUINTUS PROLOG and running on a SUN 3 workstation. References Bar-On, E.; and Or-Bach, R. 1988. Explanation-Based Learning in Intelligent Tutoring Systems. In P. Ercoli, and R. Lewis eds. Artificial Intelligence Tools in Education. Amsterdam, NL: Elsevier Science Publ. Bonar, J.G.; and Soloway, E.M. 1985. Pre-Programming Knowledge: A Major Source of Misconceptions in Novice Programmers. Human-Computer Interaction l(2): 133- 161. Brown, J.; and Burton, R. 1980. Diagnostic Models for Procedural Bugs in Mathematical Skills. Cognitive Science 4: 379-426. Costa, E.; Duchenoy, S.; and Kodratoff, Y. 1988. A Resolution Based Method for Discovering Students’ Misconceptions. In J.A. Self ed. Artificial Intelligence and Human Learning. London, UK: Chapman and Hall. DeJong, G.F.; and Mooney, R.J. 1986. Explanation-Based Learning: An Alternative View. Machine Learning 1: 145176. disessa, A.A. 1982. Unlearning Aristotelian Physics: A Study of Knowledge-Based Learning. Cognitive Science 6: 37-75. Doyle, J. 1979. A Truth Maintenance System. Artificial Intelligence 12: 23 1-272. Fum, D.; Giangrandi, P.; and Tasso, C. 1988. ET: An Intelligent Tutor for Foreign Language Teaching. In Proceedings of ITS-88,462-468. Montreal, Canada. Fum, D.; Giangrandi, P.; and Tasso, C. 1989. Tense Generation in an Intelligent Tutor for Foreign Language Teaching: Some Issues in the Design of the Verb Expert. In Proceedings of the 4th Conference of the European Chapter of the Association for Computational Linguistics, 124-129. Manchester, UK: Association for Computational Linguistics. Hirsh, H. 1985. Modeling Problem Solving Performance. Master’s thesis, Stanford Univ. McAllester, D.A. 1982. Reasoning utility package user’s manual. Technical Report, AIM-667, Artificial Intelligence Laboratory, M.I.T. Mitchell, T.M.; Keller, R.; and Kedar-Kabelli, S. 1986. Explanation-Based Generalization: A Unifying View. Machine Learning 1: 47-80. Reif, F. 1987. Interpretation of Scientific or Mathematical Concepts: Cognitive Issues and Instructional Implications. Cognitive Science 11: 395-416. Self, J.A. 1988. Bypassing the Intractable Problem of Student Modelling. In Proceedings of ITS-88, 18-24. Montreal, Canada. Sleeman, D. 1983. Inferring (Mal) Rules from Pupils’ Protocols. In Proceedings of the Second International Machine Learning Workshop, 221-227. Chicago, IL. Wenger, E. 1987. Artificial Intelligence and Tutoring Systems. Los Altos, CA: Morgan Kaufman. Anderson, J. 1987. Production Systems, Learning, and Tutoring. In D. Klahr, P. Langley, and R. Neches eds. Production System Models of Learning and Development. Cambridge, MA: The MIT Press. FUMETAL. 433
|
1990
|
57
|
975
|
ic Instructional Planner William R. Murray Artificial Intelligence Department FMC Corporate Technology Center 1205 Coleman Avenue, Box 580 Santa Clara, California 95052 murray@ctc.fmc.com Abstrirct’ The Blackboard Instructional Planner is a blackboard-based dynamic planner for intelligent tutoring systems. It generates a sequence of lesson plans customized to a student’s background, and adaptively replan, to handle student requests and unexpected changes to the student model or time remaining. The planner is designed to be generic to tutors that teach troubleshooting for complex physical devices. It controls the Lower Hoist Tutor, a prototype tutor for the Mark-45 naval gun mount. This tutor teaches troubleshooting of the lower hoist, a complex hydraulic-electronic-mechanical assembly of the Mark-45 The tutor implementation demonstrates the planner’s operation and means of integration. This research contributes to an understanding of dynamic instructional planners, planner-controlled tutors, and ITS control architectures. The planner implementation shows precisely how a blackboard architecture can be used to realize a dynamic instructional planner. Although experimental, the tutor implementation demonstrates how such a planner can be embedded in an intelligent tutoring system and what the respective roles of the different components of a pianner- controlled tutor are. Finally, the analysis of the planner’s use of the blackboard architecture clarifies requirements for control architectures in intelligent tutoring systems and trade-offs made in choosing alternatives. Introduction The Blackboard Instructional Planner (BB-IP) is a blackboard-based dynamic planner for intelligent tutoring systems. Although experimental, the planner demonstrates key plan generation and replanning capabilities required to handle common tutorial situations. It generates a sequence of lesson plans customized to a student model inferred from a pre-instruction questionnaire. The content, sequencing, and length of lessons are determined by the infefied student model, by the time allotted for lessons, by the target skill to be taught, and by the subject domain. These lesson plans are revised during instruction in response to student questions and requests, changes in time remaining for lessons, and modifications to the student model. ‘This project was sponsored jointly by the Manpower, Personnel and Training R&D Committee of the Office of the Chief of Naval Research (under contract NOOO14-86-C-0487); the Air Force Human Resources Laboratory: the Naval Training Systems Center; and the Naval Personnel Research and Development Center. The goal of this research is to increase the flexibility and effectiveness of computer-based tutoring systems by applying dynamic planning techniques to control the tutor’s actions. Traditional CAl systems do not plan at all although they can deliver very well-crafted lesson plans. Typically, however, they have no domain expertise, customize only via branching or problem selection, and cannot use opportunistic teaching methods. They must limit student questions and requests since they cannot reason about the domain or the student’s lesson plan during instruction. On the other hand, most intelligent tutoring systems incorporate domain expertise and student modeling so that they can apply opportunistic teaching approaches in the course of student problem-solving or a dialog about the subject matter. These tutors tend to be used as adjuncts to classroom instruction since they assume primary instruction is delivered elsewhere. Generally, lesson planning is not done although recent systems have focused on sophisticated local discourse planning. The purpose of the Blackboard Instructional Planner is to integrate these two complementary means of instruction - plan-based and opportunistic - for tutors and domains where this is most appropriate. Our approach to this control problem is called dynamic instructional planning. In this approach, an initial instructional plan is generated by the planner. This plan is customized to an inferred student model. It takes into account the resources available to the tutor (e.g., time). The tutor interprets this plan to control its delivery of instruction. The planner is dynamic since it can later revise this plan during instruction as the tutorial situation changes. The tutorial situation changes as the student model changes, the amount of time available changes, and as student-initiated interactions interrupt the tutor’s plan. The planner operates as the control element of an intelligent tutoring system, as shown in Figure 1 (arrows indicate data flow). The planner generates an initial instructional plan customized to the inferred student model. The actions in the instructional plan are procedures that control the text, highlighting, and animation displayed on the student interface. The interface also accepts student input, including student- initiated questions and requests that can interrupt these instructional procedures. The library of possible instructional procedures the planner can draw upon is part of the courseware. The courseware includes curriculum 434 EDUCATIONANDARTIFICLALINTELLIGENCE From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. materials such as test questions and troubleshooting cases. The domain expert evaluates student performance on these cases, demonstrates correct troubleshooting, and provides answers to student questions about the domain. These evaluations update the student model. Changes to the student model cause replanning if student progress is much better or worse than expected. Figure 1: The planner and other ITS components The planner is designed to be generic to tutors that teach troubleshooting for complex physical devices. It has been implemented as the controller for the Lower Hoist Tutor, a prototype tutor for the Mark-45 naval gun mount, to demonstrate the planner’s operation and means of integration. The tutor teaches troubleshooting of the lower hoist assembly, a complex hydraulic-electronic- mechanical assembly of the Mark-45, by first imparting a mental model of the device and its operation. A STEAMER-based (Hollan, Hutchins, & Weitzman 1984) display of the lower hoist schematic has been adapted for use in exposition, assessment, and troubleshooting practice. Overview of Operation Figure 2 provides an overview of the operation of the Blackboard Instructional Planner. The generic skills knowledge base is a graph with nodes representing device-independent troubleshooting skills for complex hydraulic-electronic-mechanical devices. Arcs represent prerequisite relationships among these skills. The planner interprets this graph as a very high level strategy for teaching troubleshooting. 1 Structure and operation of the device must be taught along with possible faults and a troubleshooting strategy. The domain knowledge base is a semantic network that provides the particulars of the structure and operation of the lower hoist assembly of the Mark-45. It includes a parts breakdown and the sequence of events (part state changes) that occur in normal operation. The circled X in Figure 2 means that a Cartesian product of the two knowledge bases is formed to produce the graph of domain-speczpc skills. For example, one skill in the generic skills knowledge base specifies that the student should understand the role of each part in the device. So for the lower hoist’s 42 parts, 42 domain- specific skills result. Each corresponds to understanding the role of one particular part. ‘This strategy is not based on any cognitive theory, rather it was inferred from the subject . matter expert’s approach to classroom instruction. The graph of domain-specific skills acts as a machine- generated curriculum graph for the skill of troubleshooting the particular device. A three-level instructional plan is produced by selecting out skills from this graph to teach the student, selecting abstract methods to teach the skills, and then selecting specific LISP routines consistent with these methods. The plan generation process also involves sequencing the lessons and lesson plan steps, selecting appropriate parameters for the instructional procedures, critiquing the plan as it is developed, and revising it to improve discourse flow. The result is an instructional plan, which is further broken down into a sequence of lesson plans, corresponding to individual tutorial sessions. Student Model I Goals Dozn KGwkTp -I I DomainSpecific Skill8 I Le8aon 1 Lesson 2 Figure 2: Overview of BB-IP Planning The plan is executed by interpreting the instructional procedures. Some of the procedures assess student ability through tests or by monitoring task performance. This assessment updates the student model, which can in turn cause replanning to occur. Replanning occurs when student performance is unexpectedly good or bad. It can also be initiated when much less time or more time is available than expected, or when student questions or requests interrupt the tutor’s plan. During replanning the plan is edited to add plan steps, remove them, or to alter the procedure parameters. Then execution resumes. Examples of Plan Customization Consider two different student backgrounds and the different plans that are generated Suppose the first student is deficient in the background area of electronics and learns more slowly than the average student. The second student has the expected knowledge of hydraulics, electronics, and mechanics and learns rapidly. The tutor labels the first as Electronics-Deficient, Low-Aptitude and the second as Has-Prerequisites, High-Aptitude based on the results of a short pre-instruction questionnaire covering prerequisite material and general student background. The inferred cognitive stereotypes (Rich 1979) are used to initialize an overlay student model (Car-r & Goldstein 1977) that is an overlay of the domain- specific skills. MURRAY 435 The tutor generates quite different plans for these two students although the high-level teaching strategy, derived from the common generic skills knowledge base, is the same. Both plans cover structure and operation of the lower hoist and discuss a general troubleshooting strategy. Then correct troubleshooting is demonstrated and student performance monitored in troubleshooting cases selected by the tutor. But the first plan is much longer than the second since it provides more layered instruction on lower hoist structure and operation, more discussion of how to troubleshoot, and specific remedial instruction covering the operation of electrically-controlled parts. The instructional plan for the Electronics-Deficient, Low-Aptitude student consists of five lessons and 51 steps (instructional procedures). In the first lesson an introduction to lower hoist structure and operation is given, followed by a detailed description of the lower hoist parts, their location, and their role in lower hoist operation. The second lesson explains how solenoids operate and then provides a detailed explanation of all the part state changes that occur in a normal cycle of operation of the lower hoist. This detailed explanation interleaves text explaining part state changes with animation showing the changes discussed. In the third lesson the student must demonstrate his understanding of normal operation by successively pointing to the next part that should change state and indicating what the new state should be. Essentially, the student leads the simulation. In the fourth lesson, the tutor discusses the possible faults that can occur in the lower hoist. It also discusses how to reason from symptoms to possible faults. Then it presents a troubleshooting strategy that takes into account part change cost, malfunction probability, and split-half testing. Finally, troubleshooting is demonstrated for a particular case. The last lesson is devoted to letting the student practice troubleshooting for various cases with the tutor’s assistance. The instructional plan for the Has-Prerequisites, High-Aptitude student is quite different. Instead of five lessons and 51 steps there are only three lessons and 26 steps. This plan omits much of the layered instruction given to the first student. For example, the procedures that introduce the structure and operation of the lower hoist in a layered fashion are omitted. Similarly, procedures that introduce troubleshooting in a layered fashion are omitted along with topics that the tutor judges to be of lower priority, such as part locations and descriptions. Procedure parameters also differ for the procedure that monitors student troubleshooting. In the second instructional plan the parameters are set to provide hints later, tolerate more incorrect actions, and provide less assistance with selecting test codes than in the first instructional plan. Examples of Dynamic Replanning Consider an example where a question is asked that interrupts the tutor’s presentation. Assume the tutor is executing an instructional procedure cahed Explain-Subcycles that explains the detailed sequence of changes that occur during the operation of lower hoist. Midway through the procedure, when a change happens to the UVK4 piston, the student interrupts and asks what the role of that particular part is. The interruption and specification of the question is handled by a menu interface. Question templates are used to restrict questions to those that can be answered by executing one of the tutor’s instructional procedures. The tutor can either defer or directly answer the question. In this case the tutor chooses to answer the question now since the material being asked about will not be covered later. To answer the question the current procedure is suspended and a step to answer the question is inserted. The step Explain-Subcycles is suspended and two steps are spliced in after it: Explain-Subcycles [subcycles hoist] Patch-l :Part-Roles(to-ans-Ques#l) [WKB] Patch-I :Explain-Subcycles(cont) [subcycles hoist cant] The parameters of each procedure are indicated in boldface after the procedure name. They are shown here in a more readable format than the internal representation. The first step after the interrupted Explain-Subcycles procedure answers the question. The second continues Explain-Subcycles where it was interrupted. But this is not all that happens since the student model is affected simply by the student asking the question. When the student asks a question about material that was covered earlier, the tutor’s belief that the student knows that material is diminished. In this case the tutor covered the roles of the lower hoist parts earlier. The tutor detects that its prior goal, that the student knows the roles of these parts, is no longer satisfied and still should be. To reachieve this goal it splices in a review of the roles of the lower hoist parts before resuming Explain-Sub&es. Now the affected portion of the plan, after both plan patches have been added, appears as: Explain-Subcycles [subcycles hoist] Patch-I:Part-Roies(to-ans-Ques#l) [WK4] Patch-2:Part-RoZes(to-review) [all hoist parts] Patch-2:MuZtipZe-Choice-Quiz [role each hoist part] Patch-I:Explain-SubcycZes(cont) [subcycles hoist cant] The multiple choice quiz has been added to check that the tutor’s review is successful. Now plan critics are applied to improve the tutorial discourse. There is an abrupt context shift from the review of the roles of the lower hoist parts back to the detailed discussion of the lower hoist cycle. This shift in discourse is smoothed out by adding a step: Patch-2:Transition [part roles, subcycles hoist]. Another plan critic attempts to remove redundant discussions. It ensures that only the first Part-Roles procedure discusses UVK4 by removing UVK4 from the list of parts discussed by the second Part-RoEes procedure. After all the edits, the affected portion of the lesson plan appears as shown below: Explain-Subcycles [subcycles hoist] Patch-l :Part-Roles(to-am-Ques#I) [ WK4] 436 EDUCATIONANDARTIFICIALINTELLIGENCE Patch-2:Part-Roles(to-review) [all parts except WK4] Patch-2:MuZtipZe-Choice-Quiz [role each hoist part] Patch-2:Transition [part roles, subcycles hoist] Patch-l :Explain-Subcycles (cant) [subcycles hoist cant] Requests are handled similarly. New steps are inserted to handle requests. Furthermore, future lesson plan steps may be omitted. For example, suppose the tutor grants a student request to use the device simulation. The tutor monitors the student’s actions. If it believes the student has learned material it plans to cover then it will omit pending procedures to cover this material. Dynamic replanning can also be initiated by unexpected changes to the student model. For example, as the tutor monitors student troubleshooting performance it updates the student model. Each troubleshooting action the student selects is compared to an expert’s to compute its utility. Repeated inappropriate actions and hint requests cause the tutor to revise its belief that the student can troubleshoot the device downwards. When the belief value falls below a certain threshold, the procedure for monitoring student troubleshooting is suspended and replanning begins. A diagnosis phase is entered where the tutor decides why its instruction has been ineffective. It could be that it assumed too much of the student, or that an earlier method of instruction was inappropriate. Once it has decided the cause of the problem it edits the instructional plan to address the problem and continues. Only a few diagnosis methods have been implemented. One is to collect the prerequisites for the skill not learnt and then to assess the student’s knowledge of the prerequisites, one by one, until a prerequisite is found that the student does not understand. Then a review for that prerequisite is spliced into the plan prior to the suspended procedure for monitoring student troubleshooting. Execution resumes with the review before troubleshooting practice continues. Other kinds of planning functionality have also been implemented, as discussed in detail in (Murray 1990b). If there is insufficient time to finish all the activities of a lesson then some activities may be deferred until the next lesson. All the remaining lesson boundaries may also be affected. If there is extra time a useful activity is added to take advantage of the time remaining. Incremental planning has also been demonstrated. Only abstract activities are specified for lesson plan steps with the choice of procedure deferred until the step is reached. In the implementation of the examples above specific decisions had to be made about how to customize plans, how to handle student questions, and how to diagnose and correct ineffective plans. The claims made in this paper are not about these specific decisions, since at present there is little guidance from the educational psychology literature specific enough to be applied in these situations. Other approaches can be implemented that would customize plans differently and make different decisions about when and exactly how to replan. The claim made is that the planner framework - the plan representation, the use of blackboard architecture, and the kinds of plan editing that can be performed - would support these alternative pedagogical approaches as well. Plan Representation This section presents the hierarchical instructional plan representation. There are three levels: 1. Instructional objectives - goals of the tutor. These arc domain specific skills which the tutor intends for the student to acquire (e.g., can-predict-normal-behavior-hoist). 2. Activities - abstract methods for achieving these goals. The most common activities are to cover a topic (e.g., cover-topic-part-role-uvk4) or to perform assessment for a skill (e.g., assess-understands-structure-hoist). 3. Procedures - instructional routines that implement specific activities. Multiple procedures are available for the same activity. For example, different kinds of tests can be used for student assessment. t%Jl-EXptE?trt robUVK4 Figure 3: A simple instructional plan Figure 3 shows a small instructional plan for teaching the structure of the lower hoist, assuming that it only had two parts. The top level is the instructional objectives level. On it, the top-level instructional objective has been broken down into two subordinate (i.e., prerequisite) objectives. First, that the student can explain the roles of the parts of the lower hoist. Second, that the student understands how the different part types operate. These objectives are broken down still further. First, the student must understand the role of each of the two parts. Then since LHKl is a solenoid assembly the student needs to understand how solenoids operate. Similarly, since UVK4 is a hydraulic valve the student needs to understand how hydraulic valves operate. The reason that the instructional objectives level is important is that it supports rep1anning. BB-IP needs to know why it was doing a procedure to determine what to do if that procedure fails. This representation of plan rationale supports replanning when previously satisfied instructional objectives are no longer maintained, or when pending instructional objectives are discovered to be MURRAY 437 already satisfied. The next level, the activities level, supports incremental planning by allowing methods for carrying out the objectives to be represented, without committing to specific actions to carry out these methods. There is one activity for each terminal skill node plus additional activities to improve discourse flow and monitor plan progress. The activities cover-topic-role- 1 and cover-topic-role-uvk4 simply present text describing the role of the two lower hoist parts. The activity motivate-topic-structure-hoist has been added to improve discourse flow. It explains to the student that it is important to understand lower hoist structure in order to perform effective troubleshooting. The activities cover-topic-solenoid-operation and cover-topic-valve-operation present material explaining the operation of solenoids and valves. The final activity assess-understands-structure-hoist tests the student to determine if the plan has had its intended effect. The final level, representing a sequence of directly executable plan actions, is the procedures level, For each activity a single procedure has been chosen to carry it out. For example, to cover UVK4’s role the tutor can use either Part-Role or Demo-in-Cycle. Part-Role presents a textual description of UVK4’s role. It also highlights and labels it in the device simulation. Demo-in-Cycle demonstrates the part’s operation in the lower hoist cycle by animating the STEAMER device simulation. Similarly, the topic of hydraulic valve operation can be taught either by Student-Exploration or by Demo-Part. The first procedure asks the student to use the device simulation to explore the operation of a particular valve. The second demonstrates different valve states and how they affect connecting parts. Each procedure is broken down into steps called procedure steps. A procedure can be interrupted between procedure steps and then resumed later. Typically, a procedure step displays another paragraph of text, or makes an incremental change to the device simulation shown on the student interface. For assessment procedures, each procedure step asks a question. Procedures are written this way so the student can ask questions or make requests between procedure steps. Another reason is to monitor procedure execution and student progress since the tutor can assess progress or lack of progress between procedure steps. If progress is insufficient then the tutor can interrupt the procedure to adjust its parameters or abandon it altogether. Plan Generation, Execution, ancl Repair Figure 4 shows the resources used in plan generation. The activities library is a set of generic activities (e.g., cover-topic, assess-topic, demo-skill) that can be used to achieve objectives. The procedures library is a set of instructional routines that can be used to achieve activities (e.g., Explain-Subcycles). These libraries are part of the courseware for the domain, although most of the activities and procedures can apply to other similar domains. The student model is a resource since it is used to filter out those objectives, activities, and procedures that are inappropriate for the student. Another resource is the library of discourse critics that are used to critique and revise the plan during plan generation, and immediately after plan editing. Once the plan has been generated, time estimates and a simple hill-climbing procedure are used to place lesson partitions (see (Murray 1990b) for details). Lesson Partitioning Algorithm Figure 4: Plan generation Plan generation and execution occur in phases called control phases. These are states where only certain kinds of planning actions are performed. BB-IP’s control phases are shown in Figure 5. Phases on horizontal lines are next to the planning level they affect. Planning actions that occur in these phases either add to or modify a partially refined instructional plan. The special Meta-Level phase decides what plan phase to jump to next. Consider plan generation first, assuming complete top-down plan elaboration. The basic sequence of phases is: 1. Refine Objectives- The top-level instructional objective is refined by copying prerequisite objectives from the domain specific skills. 2. Assess Objectives - The student is given a pm-instruction questionnaire to initialize the student model. 3. Propose Activities - Activities to achieve the objectives are proposed. 4. Prioritize Activities - Numerical priorities are assigned to each activity to indicate its importance. 5. Filter Activities - Only those activities above a threshold are retained. 6. Sequence Activities - These activities are now sequenced. 7. Critique Activities - Improvements in the discourse flow are made. 8. Propose Actions - Candidate procedures for each activity are proposed. 9. Select Actions - Heuristics are used to select the best procedure for each activity. Parameters are set for the procedures. 10. Sequence Actions - Procedures are 438 EDUCATIONANDARTIFICJAL,INTELLIGENCE Execute eta-level eta-level Meta-level 0 Monitor Meta-level figure 5: Control phases in plan generation and execution sequenced in the same order as their parent activities. 11. Critique Actions - The plan is again critiqued and improved. 12. Partition Lessons - Partitions are laid down, breaking the instructional plan up into lesson plans. The Meta-Level phases at the end of each horizontal line in Figure 5 were not mentioned since they just produce the sequencing above. However, when incremental planning occurs phases 8,9,10, and 11 are skipped. After the Partition Lessons phase execution begins. The Meta-Level phase moves the planner into the execution loop shown at the right of Figure 5, starting with the Execute phase. The planner stays in the Execute phase as long as the instructional plan is executing smoothly. Interruptions occur when the student model or time do not change as expected or if there are student- initiated questions or requests. The planner enters the Monitor phase and the reason for the plan’s interruption is recorded. A question or a request is deferred if it will be handled later in the instructional plan anyway. Otherwise it is granted immediately. In the former case the tutor explains why the request is being deferred and continues with the Execute phase. In the latter case a step performing the procedure that answers the question or grants the request is spliced into the lesson plan in the Edit phase. The Critiqzle phase adds a transition step then execution resumes. The next step to be executed is the step satisfying the student’s request. An unexpected change to time remaining or the student model means that the plan has some flaw. The Diagnose phase attempts to infer what is wrong. This phase ends when a decision has been made about what the problem is. Then the Edit phase either adds or deletes lesson plan steps, or alters procedure parameters, according to the kind of problem diagnosed. The steps added may only be at the activity level, requiring a digression back to the plan generation process to select procedures. Then this new plan patch is critiqued and execution resumes. Planning and execution are interleaved through the use of control phases and in particular the Meta-level control phase. The Meta-level phase alIows suspending the execution cycle to return to any point in the plan generation process. It also determines when execution should resume. This kind of interleaving of control phases occurs in incremental planning, in diagnosing plan execution problems, in generating initial assessment plans, and in elaborating, splicing in, and then executing plan repair patches. lackboard Architecture and its BB-IP is built on the BBl Blackboard Architecture (Hayes-Roth 1984), which allows multiple blackboards, rather than just one. These are the main blackboards used by BB-II’: 9 Instructional PIan - represents the three-level instructional plan. +D Student Model - represents the student model. * Device - represents the structure and operation of the device. 0 Planner Control - represents meta-level decisions such as whether to continue planning or start execution. Problems noted in the plan’s execution and decisions about their cause are also recorded. The Device blackboard is not updated during execution; the others are. The knowledge sources of BB-IP are planning actions. They primarily modify the Instructional Plan blackboard. The kinds of actions performed are: * Plan generation - new objects are added to the instructional plan and linked to the objects they refine. These objects represent objectives, activities, or procedures. 0 PZan execution - a step in a procedure is executed. * Pian monitoring - some problem in plan execution is noted. For example, the time available or student model is not as it should be. 0 Plan diagnosis - a decision is made regarding a plan failure. 0 Plan revision - part of the plan is modified. New activities or procedures may be added or others deleted. The execution cycle of BB-IP is shown in Figure 6. Changes to the blackboards are caused either by the execution of planning actions, or by student interaction. These changes are called events. They trigger knowledge sources creating activation records which are placed on the agenda. These knowledge source activation records or KSARs record the knowledge sources and their variable MURRAY 439 bindings when triggered. The sckeduler selects the next KSAR to run. Then the next KSAR is interpreted. Its execution may cause changes to the student interface, the instructional plan, or both. This cycle continues until the instructional plan has been completed. Schedukr Figure 6: BB-IP Execution Cycle The blackboard architecture facilitates the implementation of dynamic instructional planners by supporting an explicit plan representation, meta-level reasoning, interruptibility, and rapid prototyping. The explicit instructional plan representation supports dynamic planning by representing plan rationale, future unexecuted actions, global resource allocation, and constraints on partially refined plans. The use of plan critics is also supported. These issues are explained in more detail in (Murray 1990b). Other reasons cited (Hayes-Roth 1987a) for using blackboard architectures such as integrating uncertain data, island driving, and providing opportunistic control appear more relevant to interpretation applications (e.g., HEARSAY-II (Erman et al. 1980)) than this planning application. Related Work This section considers related work in control for intelligent tutoring systems. We consider: 1. Reactive systems having no plans at all. 2. Tutors that follow a single fied plan. 3. Tutors that can only select dynamically from stored plans. 4. Tutors that generate and interpret an explicit instructional plan. Reactive systems recognize and act upon opportunities to provide instruction but do not plan any sequence of actions. WEST (Burton & Brown 1979) and SOPHIE-I (Brown, Burton, & Bell 1975) are examples. Reactive systems such as these are limited to coaching or opportunistic tutoring strategies. The student’s actions determine the course of the instructional session, not a stored or generated plan. Simulated microworlds that only allow discovery learning can also be considered reactive systems, but it is arguable whether such systems are intelligent tutoring systems, although they do apply artificial intelligence techniques to education. Traditional CAI tutors rely on a single fixed plan. The instruction produced may be very good but these systems cannot be readily extended to new domains or instructional strategies since they procedurally encode domain knowledge and teaching methods. To make program development practical (i.e., less time consuming), their flexibility is quite limited. The tutor controls the instructional session, rather than the student. Student questions and requests are restricted or disahowed. For example, the student typically cannot pose a problem for the tutor to solve. A considerable increase in flexibility results when tutors can dynamically select discourse plans from a plan library. MENO-TUTOR (Woolf & McDonald 1984) provides these capabilities with pre-stored skeletal plans, encoded as default state transitions in an ATN-like discourse management network. The network is augmented with meta-rules that allow transitions &om the execution of one skeletal plan to the execution of another. Another tutor, WHY (Stevens & Collins 1977), also provides Socratic question and answer dialogs, but it uses rules to generate its dialogs. GUIDON (Clancey 1987) provides more sophisticated capabilities than either WHY or MENO-TUTOR. Its t-rules (tutorial rules) are used both as pre-stored discourse plans and as meta-rules to control the selection and operation of other t-rules. GUIDON’s capabilities are still limited by the lack of an explicit instructional plan even though it provides very sophisticated dialog management. GUIDON’s dialog can be verbose since it does not plan its dialog to determine which topics should be stressed and which should be deemphasized. Although the user can interrupt GUIDON at any time some requests may be disallowed since they would invalidate assumptions underlying the t-rule currently executing. These and other limitations are discussed in more detail in (Murray 1990a). Tutors that generate and revise explicit instructional plans during instruction are intended to overcome these limitations, and support both lesson and discourse planning. This paper has described one approach; others are described briefly below. A planner-based approach to instruction based on applying classical (i.e., STRIPS- based (Fikes & Nilsson 197 1)) planning techniques is presented in (Peachey & McCalla 1986). The focus is on planning lesson content. Unlike the Blackboard Instructional Planner, this planner does not address issues in resource management, incremental planning, handling mixed-initiative instruction, and integrating lesson planning and discourse management. Another tutor, IDE- Interpreter (Russell 1988), also adopts a planner-based approach to instruction to interpret an instructional design developed in IDE (Russell, Moran, & Jordan 1988), the Instructional Design Environment. It does not rely on classical planning techniques but uses a top-down plan elaboration approach similar to that presented here. However, it does not address issues in procedure interruption and the diagnosis of failed plans. The handling of mixed initiative instruction is also more limited. Finally, the work presented here builds on research by MacMillan and Sleeman (MacMillan & Sleeman 1987). Their work focused on implementing general planner and ITS architectures. The subsequent work by the author has focused on the implementation of a dynamic instructional planner for a realistic application, 440 EDUCATIONANDARTJFICIALINTELLIGENCE rather than developing generic ITS architectures. The planner presented here is actually the second version of the Blackboard Instructional Planner. The first version was much simpler and focused more on discourse management and less on lesson planning. Instructional actions were simulated and resource management not addressed. It was implemented using a high-level language describing instructional actions. The implementation was modeled after the PROTEAN (Hayes-Roth et al. 1987b) blackboard application and its ACCORD (Hayes-Roth et al. 1987c) language Wework using Hayes-Roth’s BB* environment as described in (Murray 1989a). esearch Contributions The first major contribution of this research is its analysis of architectural and planning issues in ITS. (Murray 199Ob) presents a more detailed analysis of the role of the blackboard architecture than can be provided here. Alternative approaches to planning for ITS, and trade-offs made between them, are considered in (Murray 1989b). Two particular architectures for intelligent tutoring systems, discourse management networks and blackboard architectures, are analyzed in (Murray 199Oa). That paper concludes that blackboard architectures provide greater support for the implementation of dynamic instructional planners, although discourse management networks are sufficient for sophisticated dialog management where only local planning is required. A second research contribution is the implementation of the Lower Hoist Tutor. This prototype tutor shows how a dynamic instructional planner such as BB-IP can be integrated with other ITS components to form a complete system. A realistic naval training application, teaching troubleshooting of the lower hoist assembly of the Mark-45 naval gun mount, has been selected to test the planner. Although not yet appropriate for classroom use, all instructional actions have been implemented and the tutor can deliver about two hours worth of instruction on the lower hoist. The major research contribution of this work is the implementation of the Blackboard Instructional Planner. This planner shows precisely how a dynamic instructional planner can be implemented in the blackboard architecture. The Blackboard Instructional Planner generates an instructional plan customized to student background and time constraints, then adaptively replans to support mixed-initiative instruction, and to handle changes to the student model and time remaining. Acknowledgements. I would like to thank Kurt Steuck (AFHRL) and Susan Chipman (ONR) for their technical advice and guidance. I am also grateful to Perry Thorndyke, Barbara Hayes-Roth, N. S. Sridharan, Stuart MacMillan, and Lee Brownston for their help on this project. References Brown, J. S.; Burton, R. R.; and Bell, A. G. 1975. SOPHIE: a Step towards a Reactive Learning Environment. IJMMS 7~675 - 696. Burton, R. R.; and Brown, J. S. 1979. An Investigation of Computer Coaching for Informal Learning Activities. IJMMS 1 I:5 - 24. Carr, B; and Goldstein, I. P. 1977. Overlays: a Theory of Modeling for Computer-aided Instruction, Technical Report, AI Lab Memo 406, MIT. Clancey, W. 1987. Knowledge-based Tutoring: The GUIDON Program. The MIT Press. Erman, L. D.; Hayes-Roth, F.: Lesser, V. R.; and Reddy, D. R. 1980. The Hearsay-II Speech-understanding System: Integrating Knowledge to Resolve Uncertainty. Computing Surveys 12213 - 253. Fikes, R. E.; and Nilsson, N. J. 197 I. STRIPS: a New Approach to the Application of Theorem Proving to Problem Solving. Artificial Intelligence 2: 189-208. Hayes-Roth, B. 1984. BBI: An Architecture for Blackboard Systems that Control, Explain, and Learn about their own Behavior, Tech Report HPP 84-16, KSL, Stanford. Hayes-Roth, B. 1987a. Blackboard Systems. In Encyclopedia of Artificial Intelligence, 73 - 80. Wiley-Interscience Publication. Hayes-Roth, B.; Buchanan, B.; Lichtarge, 0.; Hewett, M.; Altman, R.; Brinkley, J.; Cornelius, C.: Duncan, B.; and Jardetzky, 0. 1987b. PROTEAN: Deriving Protein Structure from Constraints. In Blackboard Systems, 417 - 43 1. Addison-Wesley. Hayes-Roth, B.; Garvey, A.; Johnson, M. V.; and Hewett, M. 1987c. A Modular and Layered Environment for Reasoning about Action, Technical Report KSL 86-38, KSL, Stanford. Hollan, J. D.; Hutchins, E. L.; and We&man, L. 1984. STEAMER: an interactive inspectable simulation-based training system. AI Magazine 5(2): 15 - 27. MacMillan, S. A.: and Sleeman, D. H. 1987. An Architecture for a Self-improving Instructional Planner for Intelligent Tutoring Systems. Computational Intelligence 3( I ): 17 - 27. Murray, W. R. 1989a. Dynamic Instructional Planning in the BB 1 Blackboard Architecture. In Blackboard Architectures and Applications, 455 - 480. Academic Press, Inc. Murray, W. R. 1989b. Control for Intelligent Tutoring Systems: a Blackboard-based Dynamic Instructional Planner. Proceedings 4th International Conference on AI and Education, 150 - 168. 10s. Murray, W. R. 1990a. Control for Intelligent Tutoring Systems: A Comparison of Blackboard Architectures and Discourse Management Networks. Machine-Mediated Learning 3(l), 1990. Murray, W. R. 1990b. A Blackboard-based Dynamic Instructional Planner. Tech Report R-6376, FMC Corporation. ONR final report. Peachey, D. R.; and McCalla, G. I. 1986. Using Planning Techniques in Intelligent Tutoring Systems. IJMMS 24:77 - 98. Rich, E. 1979. User Modeling via Stereotypes. Cog. Sci. 3~355 - 366. Russell, D. M. 1988. IDE: The Interpreter. In Intelligent Tutoring Systems: Lessons Learned, 323 - 349. Lawrence Erlbaum Associates. Russell, D. M.; Moran, T. P.: and Jordan, D. S. 1988. The Instructional- Design Environment. In Intelligent Tutoring Systems: Lessons Learned, 203 - 228. Lawrence Erlbaum Associates. Stevens, A. L.; and Collins, A. 1977. The Goal Structure of a Socratic Tutor. Proceedings National ACM Conference, 256 - 263. ACM. Woolf, B. P.; and McDonald, D. D. 1984. Building a Computer Tutor: Design Issues. IEEE Computer 17(9):6 1 - 73. MURRAY 441
|
1990
|
58
|
976
|
What’s in a user? Karen Sparck Jones Computer Laboratory, University of Cambridge New Museums Site, Pembroke Street Cambridge CB2 3QG, UK I take user modelling to imply reasoning, explicitly or quasi-explicitly, about the user. Thus while systems or interfaces usually embed assumptions about their users (eg they know English or find some icon mnemonic), and defacto exploit these assumptions, this is not real user modelling. But we cannot talk about the need for or nature of user modelling, let alone its feasibility, without reference to the critical features of the context. These are (1) the role of the human: agent or patient (2) the status of the user: central or peripheral (3) the orientation of the activity: outward or inward (4) the character of the information: deep or shallow. In one salient class of contexts, illustrated by advice systems like UC, there is one individual who is both agent, the person operating the interface, and patient, the person about whom the system is taking decisions. The user is central rather than peripheral as the system task is to support him. The system-user activity is directed outwards towards the user rather than from the user to other system functions. Finally, the information about the user supplying the substance of the model is deep in the sense of dealing with the user’s beliefs, goals and plans, as opposed to shallow in the way a simple log of mentioned topics would be. Instruction systems may also have some or all of these properties. But users may figure in quite other ways, including those where agent and patient are distinct individuals with their own proper beliefs and goals, as with lawyer and client; those where the user is subordinate or peripheral, as in industrial plant control, so the dialogue manager with its user modeller is a secondary and not the dominant system component; those where the user is the starting rather than the end point for system action, as in document production; and those where the information about the user is extensional and not intensional, as with social security status for example. In many contexts where it seems legitimate to refer 1140 ADDENDUM to user modelling it is nevertheless not obvious that this has to look below the interactive surface for underlying beliefs or goals, or even at surface beliefs and goals rather than at straight behaviour, or indeed at more than ergonomic factors: all of these can imply reasoning about the user. Thus to set more precise bounds on a discussion of the need and nature of user modelling we can ask whether we should model user(s) in cases like designing a system for (a) supporting a psychoanalyst and subject (b) providing holiday advice (c) managing personal bibliographic files. The strong user modelling claim is that for even the third of these we should go beyond not just ergonomics but also recorded behaviour (allowing the system to adapt eg its classification) and even stated user requirements (as in searching) to modelling based on explanatory properties of the user. These may be objective or subjective, but subjective properties - beliefs, goals and plans - are especially important here. It is necessary, further, for the system to recognise and manipulate these properties not only where they relate to the system’s primary decision making and so influence system effectiveness, as in giving appropriate advice, but also where they do not determine primary decisions but can influence system acceptability, as in presenting advice. But it is generally so difficult to get this type of information, especially reliably and particularly for non-decision properties, that it may be safer to be more conservative and not look too deep. This implies that modelling should (1) consider only readily available information, if not supplied by the user then easily derived via the system’s task and domain knowledge; (2) focus on decision rather than non-decision properties unless the latter are explicit and exploitable; (3) treat subjective, intensional properties only insofar as these are primary for the task, (4) take the user as an individual (whether or not taking a stereotype as a starting point) just as so defined by the particular user-system interaction. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. These principles apply whether natural language is the dialogue medium or not, but clearly work out in detail somewhat differently according to means of interaction. In some contexts weak modelling, through behavioural adaptation, via modifiable (though not fixed) stereotypes, or without reference to intensional attitudes, may be sufficient for effective and acceptable system performance. But stronger modelling even if not mandatory appears to be desirable, not only for obvious cases like advice systems but in any complex system context where user and system are both goal directed, but the relation between their goals is not obvious and has to be established quickly. Thus it is hard to see how a financial advisor or literature search system could not be improved by characterising the user’s input in terms of knowledge and purpose, and by establishing relationships between different inputs through connected knowledge or purposes. Even so, I believe that strong modelling can be adequately done, and in the normal absence of extensive and reliable data is best done, with only the system’s task and domain knowledge, plus the general conventions of communicative dialogue, to support the given specific dialogue; and that it is neither necessary nor sensible to go looking too hard for hidden motivations. Too much refining on explanatory hypotheses is no more needed for everyday conversation with computers than it is with people. Thus with a holiday advisor, if the user asks about travelling by train, just accept that he wants to travel by train without hypothesising why (e.g. it is cheap); or with a training system for equipment fitting, if the apprentice asks which bit is the pobjoy just say which, without considering all the bits the apprentice might think is the pobjoy and telling him they are not. Conservative strategies like this allow for some evaluation of goals and preferences in task and domain terms, as in UC; but they stop speculation getting out of hand. JONES 1141
|
1990
|
59
|
977
|
Complexity of K-Tree Structurecl Constraint Satisfaction Problems Eugene C. Freuderl Department of Computer Science University of New Hampshire Durham, New Hampshire 03824 Abstract Trees have played a key role in the study of constraint satisfaction problems because problems with tree structure can be solved efficiently. It is shown here that a family of generalized trees, k-trees, can offer increasing representational complexity for constraint satisfaction problems, while maintaining a bound on computational complexity linear in the number of variables and exponential in k. Additional results are obtained for larger classes of graphs known as partial k-trees. These methods may be helpful even when the original problem does not have k-tree or partial k-tree structure. Specific tradeoffs are suggested between representational power and computational complexity. 1 Introduction A constraint satisfaction problem (CSP) involves finding values for variables subject to constraints on what combinations of values are allowed. Constraint satisfaction problems occur widely in artificial intelligence. Recently they have received particular attention in the domains of scheduling and temporal reasoning. Judea Pearl has observed that a primary advantage of viewing AI problems in CSP terms is our ability to identify certain “islands of tractability” among CSP problems, classes of problems that admit efficient solution. The significance of such classes is increased by techniques for “massaging” problems outside these classes to fit into or utilize these classes. Up until now there has been one major tractable island, the class of tree structured problems. In this paper I identify a “chain” of such islands, generalizations of tree structures, which considerably expand the “tractable topography” of the CSP world. The tractability of these classes varies inversely with the representational complexity of the problems in the class, but the solution effort is always linear in the number of problem variables. We will restrict our attention here to binary constraint satisfaction problems, in which the given constraints involve two variables. (Non-binary CSPs are shown to 1. This material is based in part upon work supported by the National Science Foundation under Grant No. IRI-8601209 and Grant No. IRI-8913040. 4 AUTOMATEDREASONING be “reducible” to binary CSPs in mossi, Dhar, Petrie, 891.) A binary CSP can be represented by a constraint network, in which the nodes represent variables and the links represent constraints. The general constraint satisfaction problem is NP- complete. However, tree structured problems (those with tree structured constraint networks) have a worst case complexity bound that is linear in the number of problem variables [Mackworth and Freuder, 841. If there are n variables, and no variable has more than d values to choose from, a tree structured CSP can be solved in O(nd2) time [Dechter and Pearl, $81. K-trees [Beineke and Pippert, 71; Rose, 741 generalize trees. Trees are l-trees. The central result of this paper is the demonstration that CSPs whose constraint networks are k-trees can be solved in O(ndk+‘) time. Note that we are saying that the complexity of a k-tree structured CSP is bounded by a linear function in the number of variables as long as we maintain the original k-tree structure and d bound when increasing the size of the problem. Further results are described briefly for larger classes of graphs known as k-chordal graphs and partial k-trees. Partial k-trees are characterized in a manner that generalizes the characterization of forests in preuder, 821. Methods have been developed to utilize tree structures in solving general CSPs [Dechter and Pearl, 881. K-trees now provide us with a range of “target” structures of increasing complexity that we can consider utilizing in similar fashion. Jeavons has introduced the issue of the expressive power of constraint networks [Jeavons, 891. I show that the class of partial p-tree structured networks have less expressive power than the class of partial q-tree structured networks for p less than q. Combined with the complexity bounds indicated above, this suggests a tradeoff between computational complexity and expressive power [Levesque and Bra&man, 19851. Another tradeoff arises in utilizing k-trees as target structures in a partial constraint satisfaction process [Freuder, 891. Any CSP can be solved in time exponential in k by removing enough constraints to give the problem a k-tree structure. In the worst case this would necessitate removing a number of constraints equal to the number of edges in a complete graph of n-k vertices. The 2-tree case is of some special interest. “Minimum From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. IFI networks” are 2-trees wald and Coburn, 83). “Regular width-2 constraint graphs” are partial 2-trees; this paper improves on the O(n 33 d ) complexity bound for regular width-2 CSPs reported in pechter and Pearl, 881. “Series- parallel graphs” are partial 2-trees [Arnborg, 851. Many of the basic concepts used here have been rediscovered in diffbrent forms in different fields at different times. This is a testimony to their importance, but makes issues of attribution and terminology difficult. [Dechter and Pearl, 881 provides useful background from an AI CSP perspective; [Arnborg, 851 provides useful background from the perspective of work on combinatorial graph algorithms. The complexity results exploit the connection between CSP theory and combinatorial graph theory. Some background material in these areas is presented in section 2 along with examples of k-trees. The complexity bounds are derived in section 3. Section 4 discusses representational complexity and suggests how k-trees can be utilized even when the original problem does not have k-tree structure. Section 5 summarizes the results. 2 Background 2.1 Constraint Satisfaction Problems A binary constraint satisfaction problem (binary CSP) consists of a set of variables, each with a domain of potential values, and a set of binary constraints, which specify pairs of allowable variable values. In a constraint graph variables are represented as vertices and constraints as edges. The n-queens problem is often used as a CSP example. This problem involves placing n queens on an n by n chessboard such that no two queens attack one another. In the constraint graph for this problem each pair of vertices is connected by an edge. A soEution to a CSP is an assignment of one value to each of the problem variables such that any pair of values satisfies (is allowed by) the constraint between the corresponding variables. A constraint graph for a CSP represents the set of solutions to the CSP. Two constraint graphs are equivaEent if they represent the same set of solutions. An ordered constraint graph [Freuder, 821 is a constraint graph together with an ordering of the vertices, V1...Vn. The width [Freuder, 821 of a vertex in an ordered constraint graph is the number of edges from that vertex back to vertices preceding it in the ordering. The width of an ordered constraint graph is the maximal width of its vertices and the width of a constraint graph is the minimal width of all the ordered constraint graphs obtained by utilizing every ordering of the vertices. The well-known backtrack search process is a standard method for solving CSPs. An ordering of the variables of a CSP is backtrack-$-et! [Freuder, 821 if backtrack search using that variable order can always find a value for a variable consistent with previous choices of values for variables. Dechter and Pearl present an adaptive-consistency procedure [Dechter and Pearl, 881, which transforms an ordered constraint graph, 0, into an equivalent ordered constraint graph, I, with a backtrack-free variable order. I is called the induced graph of 0. The width of I is called the induced width of the ordered constraint graph 0. Define the induced width of a constraint graph G to be the minimal induced width of all the ordered constraint graphs of G. The adaptive-consistency procedure from [Dechter and Pearl, 881 is shown below: Adaptive-consistency(Xl,...J&) 1. begin 2. forr=nto 1 by-l do 3. compute PARENTS 4. perform ConsistencyQ$., PARENTS( 5. connect by arcs all elements in PARENTS&) (if they are not yet connected) 6 end The X, are variables in an ordered constraint graph. 1 PARENTS returns the set of variables preceding Xi in the ordering that are connected to Xi by an edge in the graph, (Notice that the procedure may add edges to the graph.) The procedure Consistency(v,S) records a constraint on all the variables of S (if S has j variables, this will be a j-ary constraint). The constraint permits an assignment of values to the variables of S only if the assignment is consistent with at least one (consistent) value for v. To determine consistency Dechter and Pearl specify that all constraints be used (old or new) that involve v and a subset (possibly empty) of variables from S. The algorithm basically works to enforce a backtrack- free ordering by adding constraints that prevent one from making choices that will lead to inconsistency. Define the adaptive-consistency level achieved by the adaptive-consistency procedure to be one greater than the maximum size of the PARENTS sets encountered during the running of the algorithm. An O(exp(W*(rr)+l)) bound is given in [Dechter and Pearl, 881 for adaptive-consistency, where W*(n) is the induced width of the constraint graph with ordering 7t. The bound on the algorithm can be expressed as O(ndw*(rc)+l). 0 n each of n-l passes through the outer loop the consistency procedure needs to check that there is a value for Xr consistent with any consistent assignment of values to the parents of Xr. There are at most W*(n) parents. There are at most dw*(‘r)+l combinations of values for the parents together with Xr. For each of these there are at most 2W*(n) constraints to check that involve Xr and some (possibly empty) set of parents. FREUDER 5 2.2 Combinatorial Graph Theory A graph, G=(V,E), consists of a set of vertices, V, and a set of edges, E, where each edge is a two-element subset of V. An edge is incident to the two vertices in the edge. Two vertices are adjacent if they belong to the same edge. A complete graph is one that contains all possible edges. The subgraph of a graph G induced by a subset of vertices V’ from G, written G(V), consists of the vertices V’ together with all edges in G incident only to vertices in v. Define the neighborhood of a vertex v as the set of vertices adjacent to v, and the degree of v as the number of vertices in its neighborhood. A graph G is a k-tree [Beineke and Pippert, 71; Rose, 743 if: 1. G has k vertices and is complete or 2.a. there is a vertex, v, of degree k, whose neighborhood induces a complete graph ad b. the graph obtained by removing v and all edges incident to it from G is a k-tree. A simplicial vertex of a k-tree is one that satisfies part 2 of the definition. Call the complete graph of k vertices t& trivial k-tree. K-trees are structures that can be built as follows: start with a complete graph of k vertices; each time you add a new vertex add an edge between it and k previous vertices that already form a complete subgraph (each pair of vertices is joined by an edge). For example, l-trees are just trees, and can be built as follows: start with a single vertex, connect each new vertex to one of the previous vertices. The constraint graph for the n-queens problem is an n- tree; it is also an (n-1)-tree. For example the constraint graph for the $-queens problem (place 4 non-attacking queens on a 4 by 4 board) is a 3-tree: it can be viewed as a complete graph of 3 vertices (a triangle) plus a fourth vertex connected to each of those three. Now consider the following variation on the n-queens problem, which I will call the n/m-queens problem. The n/m-queens problem requires only that a given queen cannot attack (or be attacked by) any queen in the previous m rows. The n/m-queens problem has an m-tree constraint graph. The 4/2-queens problem has a 2-tree constraint graph. A partial graph of G consists of the vertices of G and a subset of the edges of G. A subgraph of G is a partial graph of an induced subgraph of G. A partial k-tree [Arnborg, 861, is a subgraph of a k-tree; the k-tree is termed an embedding of the partial k-tree. Partial l-trees are forests. Any graph is a partial k-tree for sufficiently large k. I define a weak k-tree as the class of graphs that result when “k” is replaced by ‘Xk” and “k-tree” by “weak k-tree” in the k-tree definition. The weak k-trees are the k-chordal graphs [Chandrasekharan and Hedetniemi, $81. 3 Comprdational Complexity Tree structured problems have been solved with backtrack- free search by achieving a consistency level greater than their width. (Partial) k-tree structured problems are solved here with backtrack-free search by achieving an adaptive consistency level greater than their induced width. 3.1 K-Trees Dechter and Pearl point out, citing [Amborg, Comeil and Proskurowski, 87J, that determing the induced width, W*, of a constraint graph is an NP-complete problem. However, we will see that for k-trees W*=k (except for the trivial k-tree with k vertices, for which W*=k-1). If the constraint graph is a k-tree it can be recognized as such, if necessary, and an ordered constraint graph with induced width k can be obtained, in O(n) time (regarding k as a constant). Adaptive-consistency can then obtain an equivalent ordered constraint graph with a backtrack-free variable ordering in O(ndk+‘) time. The backtrack-free search can be completed in O(nd) time. Taken together this provides the promised O(ndk+‘) bound for solving k- tree structured CSPs. Amborg (citing [Rose, 701) states that k-trees “are easily recognized by a procedure which successively deletes vertices with completely connected neighborhoods” [Amborg, $51. I present here an algorithm that performs this recognition for a graph 6, and returns an ordering of G with induced width k (k-l if G is the trivial k-tree) in time linear in the number of vertices, n, for a fixed k. Algorithm w: Input: A constraint graph G and an integer k. Output: If G is a k-tree, the algorithm returns an ordering of G with induced width k (k-l for the trivial k- tree); if G is not a k-tree the algorithm reports failure. 1. Determine the degree of each vertex, store that number with the vertex, and place all the degree k vertices in a queue K. Sum the vertex degrees as you proceed; if and when the sum exceeds 2n-k-k2 (twice the number of edges in a k-tree), report failure. 2. For i = 1 to n-k If PC is empty, report failure. If K is not empty: Take a vertex v from K. If the graph G(N) induced by the neighborhood N of v is not complete, report failure. If G(N) is complete: record v as the (n-i+l)th vertex in the ordering, remove v and its incident edges from G, subtract one from the degree count associated with the vertices in N and place vertices that now have degree k in the K queue. 3. If G is now a complete graph (of k vertices) choose the remaining vertices in any order to complete the vertex ordering. If G is not complete, report failure. Theorem 1. A k-tree constraint graph with n vertices 6 AUTOMATEDREASONING can be recognized as a k-tree, and an ordered constraint graph of induced width k found (k-l for the trivial k-tree), in O(n) time. Proof. Algorithm W does the job. If G is the trivial k- tree, step 3 produces a width k-l ordering. Adaptive- consistency will not change this width (there are no edges to add). If G is a k-tree with more than k vertices, for any vertex v with degree k the graph induced by the neighborhood of v must be complete, because the definition of k-trees implies that every vertex in a k-tree of more than k nodes is connected to at least k others that induce a complete graph. Any k-tree vertex with a neighborhood that induces the complete graph of k vertices is simplicial [Arnborg, 85; Rose, 701. Therefore, by part 2 of the k-tree definition, if G is a k-tree it remains one after each pass through step 2. If G is a k-tree after step 2 it must satisfy part 1 of the definition and be the complete graph of k vertices. The ordering produced is such that the parent set of each vertex will already induce a complete graph, therefore adaptive-consistency does not change the width, which remains k. A k-tree has k(k-1)/2+(n-k)k edges (count the edges as you apply the definition). That and the use of the K queue are the keys to maintaining an O(nk2) complexity bound for the algorithm. 0 Theorem 2. The induced width, W*, of a non-trivial k- tree is k; for the trivial k-tree, W*=k-1. The induced width of a k-tree is equal to its width. Proof. The trivial k-tree is the complete graph with k vertices, for which the width and the induced width are obviously equal to k-l. Now consider the non-trivial case. Theorem 1 demonstrates that W*5k. The width of a graph is obviously I its induced width and thus I k. A k-tree with more than k vertices includes a complete graph of k+l vertices, and regardless of how they are ordered the last one will have k parents. This demonstrates that the width and therefore the induced width are both 2 k. Thus the width equals the induced width equals k. 0 Theorem 3. Given an induced graph I, with induced width k, of an ordered constraint graph of a k-tree structured CSP; the CSP has n variables each with a domain of at most d values. A backtrack-free search using the ordering of I can be conducted with time bound O(nd). Proof. The adaptive consistency procedure ensures that the ordering of the induced graph is backtrack-free [Dechter and Pearl, 881. Thus to instantiate each of the n variables, we need at worst try each of the d possible values. For each value we need check at most 2k constraints that variable and subsets of its parents. 0 involving Theorem 4. A k-tree structured CSP can be solved in time O(ndk+‘) . Proof. Given a constraint graph G for the CSP we can use algorithm W to obtain an ordered constraint graph 0 with induced width k in O(n) time (Theorem 1). We can then apply adaptive-consistency to obtain an equivalent induced graph in O(ndk+’ ) time, as discussed in section 2. FinalIy we can carry out a backtrack-free search in O(nd) time (Theorem 3). 0 If we do not assume k to be a constant, we can derive an Q(n(2d)k+l) bound, taking into account the analysis of adaptive consistency presented in section 2.1. 3.2 Partial K-Trees This section will sketch some extensions of the k-tree results to partial k-trees. It also contains a characterization of partial k-trees in terms of induced width. Theorem 4 holds for weak k-trees. (As we will see below weak k-trees are partial k-trees; see also [Chandrasekharan and Hedetniemi, 19881) The key observation (similar to one made by Arnborg, citing Rose [Arnborg, 85; Rose, 701) is that the basic idea behind Theorem 1 of deleting vertices whose neighborhoods induce a complete graph still works. We can obtain an O(n) bound by modifying Algorithm W to maintain in place of the queue K a queue C of vertices whose adjacent vertices induce a complete graph of Ik vertices. If we have an embedding of a partial k-tree in a k-tree, we can go on to use the above methods on the embedding. Every partial k-tree with at least k vertices can be embedded in a k-tree without adding vertices [Arnborg, 861. Even if we are given an embedding with more vertices than we started with we can simply throw away the extra and still have a weak k-tree (picture an ordering with induced width k, now throw away the extra vertices). There is unfortunately no similar analog of Algorithm W known for easily recognizing partial k-trees and finding an embedding. There is an O(n k+2) algorithm for doing so [Arnborg, 871, and more efficient methods are known for k=2 [Wald and Coburn, 831 and k=3 [Amborg, 861 (and, of course, for k=l). Theorem 2 can be extended to the following characterization of partial k-trees, which generalizes the characterization in [Freuder, 821 of forest-structured constraint graphs (partial 1 -trees) as those with widthll. Forests are l-trees and the width of a l-tree is equal to its induced width. (Compare with Arnborg’s Theorem 3.l(iv) involving the “dimension” concept in [Arnborg, 851.) The following theorem also serves to identify exactly when we can “induce” width I k, namely when we start with a partial k-tree. K-tree embedding in that case provides a method for obtaining au ordered constraint graph with this induced width. Adaptive consistency, obtained with no more than O(ndk+l) effort, then leads to backtrack-Eree search. Theorem 5. A constraint graph has induced width& iff it is a partial k-tree. Proof. If the graph has fewer than k vertices the theorem is trivial: assume there are at least k vertices. Suppose the graph, 6, is a partial k-tree. It can be embedded in a k-tree with the same vertices. The k-tree will have width k. The partial k-tree’s width will be, if anything, less. Suppose G has induced width w5k. Let I be an induced graph of an ordered constraint graph of G with induced FREXJDER 7 width w. G is a partial graph of I. I is a weak k-tree. We will see that it can be extended to a k-tree by adding further edges (if necessary), i.e that weak k-trees are partial graphs of k-trees. First add edges as needed so that the first k vertices in the ordering wilI induce a complete graph. If the graph has only k vertices we are done. If not add edges to connect the next vertex to the first k, if necessary. This k+lst vertex wilI now have a parent set that induces the complete graph of k vertices. I will demonstrate inductively that edges can be added as needed so that any remaining vertices will have such parent sets. The resulting graph will clearly satisfy the k-tree definition. Assume that edges have been added as needed so that the first i vertices in the ordering after the initial k each have a set of parents that induces the complete graph of k vertices. Consider the i+lst vertex, v. Its parent set induces a complete graph (we have a weak k-tree). If its parent set contains k vertices, this step is complete. If its parents all lie within the first k vertices, simply add edges to connect v to all of the first k vertices. Otherwise, consider the parent set of the parent vertex, p, of v that is closest to v in the ordering. The vertex p will have a parent set that induces a complete graph of k vertices, and that parent set will already include the other parents of v. Simply add edges to connect v with as many of the parents of p as needed to bring the total number of parents of v up to k, The resulting set of parents for v will induce a complete graph of k vertices, as they are all in the complete graph of k+l vertices induced by p and its parents. 0 4 Representational Complexity The representational complexity of k-trees can be analyzed in ways that suggest tradeoffs between representational power and computational complexity. Problems that do not have (partial) k-tree structure for a given k may still be viewed, in whole or in part, in (partial) k-tree terms. 4.1 Representational Power It is of course in some sense obvious that 2-trees are more “representationally complex” than trees (l-trees), that representational complexity increases with increasing k. Thus the complexity bounds obtained for (partial) k-trees can be viewed as either a) expanding the range of problems for which we can guarantee a relatively efficient solution or b) expanding the representational complexity we can permit in formulating our problems while still maintaining relatively efficient bounds on the effort required to solve the problems. In temporal reasoning, consideration has been given to restricting the expressive power of the relational language in order to guarantee computational tractability [van Beek, 891. The results in this paper suggest another means of trading expressivity for tractability, namely restricting expressibility to k-tree structures. For example, by analogy with the n/m-queens example, one could ensure a partial k-tree structure in the constraint graph of the temporal relations in a narrative by insisting that no event could be temporally compared with any event more than k events previous in the narrative. Similar restrictions could be imposed to ensure tractability in scheduling problems. A more precise notion of representational power permits a more formal analysis. Jeavons [Jeavons, 891 has raised the issue of the “expressive power” of constraint networks. He develops methods for actually counting the number of different solution sets that certain classes of constraint graphs can represent. The following theorem makes a qualitative rather than quantitative statement about the expressive power of partial k-trees. Theorem 6. Let Sk be the set of solution sets represented by partial k-tree structured constraint graphs. Sp is a proper subset of Sq for pcq. Proof. Since a partial p-tree is a partial q-tree (Theorem 5) clearly Sp is a subset of Sq. I will construct a partial q- tree structured constraint graph that represents a solution set that cannot be represented by a partial p-tree structured constraint graph. Consider the following constraint graph, G, with q+l vertices. G is complete. The complete graph with q+l vertices is a q-tree. Each variable represented has a domain of q+l values, the numbers 1 through q+l. A constraint C(Vi,vj) between variables Vi and Vj specifies that any pair of values is allowed except the pair (i,j). I will show that the complete graph with q+l vertices is the only graph that can be used to represent the solution set, S, of this CSP. Therefore, since the complete graph of q+l vertices cannot be a partial p-tree no partial p-tree can represent S. Suppose we remove an edge, e, from G, between vi and Vj for some i and j. Now the constraint c(i,j) cannot be present to prevent solutions that include i for vi and j for vj. HOW can we make up for that? We cannot. NO pairs can be removed from the other constraints, as all those pairs are allowed in solutions in the solution set. Adding pairs, or removing other constraints (edges), can only, if anything, increase the number of solutions; CSPs are monotonic in that respect. There are no new constraints to add. Thus the complete graph with q+l vertices is the only constraint graph that can represent S. l 4.2 Reduction Various methods have been proposed for expanding the applicability of tree structures in constraint satisfaction problem solving. These methods suggest analogous techniques for utilizing (partial) k-tree structures, even when the original problem does not have such structure. (Of course, the additional complexity permitted by k-tree structure, as opposed to tree structure, should decrease the need for reduction techniques.) For example, Dechter and Pearl have observed that if we remove enough vertices from an arbitrary constraint 8 AUTOMATEDREASONING graph (along with edges incident to the vertices) we will be left with a tree or forest structure [Dechter and Pearl, 881. They have studied how arbitrary CSPs can thus be reduced to CSPs with tree (or forest) structure by removing or instantiating variables that comprise a “cycle-cutset” for the constraint graph. Analogous methods can be used to reduce arbitrary CSPs to k-trees or partial k-trees. In particular, partial 2- trees can be characterized as graphs that do not contrtm a subgraph homeomorphic to Kq, the complete graph of 4 vertices (i.e. no subgraph is K4 or IQ plus additional degree-two vertices) [Amborg, 851. Thus we could utilize “Kq-cutsets” to reduce constraint graphs to partial 2-trees. The cycle-cutset work can be viewed as providing complexity bounds for CSPs in terms of how close their constraint graphs are to having tree or forest structure. In general the complexity of a CSP can be analyzed in terms of the number of variables whose removal would leave a (partial) k-tree structure. For example, the constraint graph for the 4-queens problem can be reduced to a tree by removing two of the four vertices; it can be reduced to a 2-tree by removing a single vertex. Closeness to k-tree structure can also be measured in terms of constraints. Freuder [Freuder, 891 discusses partial constraint satisfaction problems, which involve weakening the original problem in order to solve an overconstrained problem, or solve a properly constrained problem faster. The following theorem provides an upper bound on how many constraints we have to ignore in order to force a problem into a k-tree structure, thus ensuring that we can solve it in time linear in the number of variables and only exponential in k. Theorem 7. Any constraint graph, G, can be made into a k-tree structured constraint graph by removing at most a number of edges (constraints) equal to the number of edges in a complete graph of n-k vertices. Proof. As indicated earlier the number of edges in a k- tree is k(k-1)/2+(n-k)k. Suppose G is a complete graph with n vertices. It then has n(n-1)/2 edges. We can make G into a k-tree by removing (n(n-1)/2)-(k(k-1)/2+(n- k)k)=(n-k)(n-k-1)/2 edges, i.e. the number of edges in a complete graph with n-k vertices. If G is not complete we can first add edges to make it complete (these will correspond to the trivial constraint that allows all pairs, which is normally not included in the constraint graph). We can form a k-tree by removing edges as before (only in the worst case will they all be edges of the original graph ). l For example, the constraint graph for the 4-queens problem can be reduced to a tree by removing three edges. It can be reduced to a 2-tree by removing a single edge. 5 Conclusion 1. The O(nd2) bound on the complexity of tree structured CSPs generalizes to an O(ndk+l) bound for k- trees. 2. CSPs with partial k-tree structure (and every CSP has partial k-tree structure for some k) can be solved in O(ndk+l) time once a k-tree embedding has been found (which may require O(nk+2) time). 3. The identification of graphs with width <l as forests generalizes to the identification of graphs with induced width Sk as partial k-trees. 4. Representational power increases with increasing k for partial k-trees. 5. Reduction methods can be used to broaden the applicability of (partial) k-tree results. Acknowledgments. This work profited from discussion with Pilar de la Terre and Raymond Greenlaw. References [Amborg, 851 Efficient algorithms for combinatorial problems on graphs with bounded decomposability - a survey, BIT 25: 2-23. [Arnborg and Proskurowski, 861 Characterization and recognition of partial 3-trees, Siam J. Alg. Disc. Meth. 7(2). [Arnborg, Corneil and Proskurowski, 871 Complexity of finding embeddings in a k-tree, Siam J. Alg. Disc. Meth. 8(2). [Beineke and Pippert, 711 Properties and characterizations of k-trees, Mathematika I8: 141-151. [Chandrasekharan and Hedetniemi, 881 Fast parallel algorithms for tree decomposing and parsing partial k- trees, Proc. of the 26th Annual Allerton Conference on Comm., Cont. and Comp., Urbana-Champaign, Illinois. [Dechter and Pearl, 883 Network-based heuristics for constraint-satisfaction problems, Art. Int. 34( 1). [Freuder, 821 A sufficient condition for backtrack-free search, JACM 29(l). prouder, 891 Partial constraint satisfaction, IJCAI-89. [Jeavons, 891 The expressive power of constraint networks, Dept. of C.S., Univ. of London, UK. &evesque and Bra&man, 851 A fundamental tradeoff in knowledge representation and reasoning (revised version), in Readings in Knowledge Representation, Bra&man and Levesque, editors, Morgau Kaufmaun, Los Altos, CA. [Ma&worth and Freuder, 841 The complexity of some polynomial network consistency algorithms for constraint satisfaction problems, Art. Int. 25( 1). [Rose, 701 Triangulated graphs and the elimination process, Journal of Mathematical Analysis and Applications 32: 597-609. Rose, 741 On simple characterizations of k-trees, Discrete Math 7: 317-322. [Rossi, Dhar and Petrie, 891 On the equivalence of constraint satisfaction problems, MCC Technical Report ACT-AI-222-89. MCC, Austin, Texas 78759. [van Beek, 891 Approximation algorithms for temporal reasoning, ZJCAI-89. [Wald and Colb oum, 831 Steiner trees, partial 2-trees, and minimum IFI networks, Networks 13: 159-167. FREUDER 9
|
1990
|
6
|
978
|
The Future of Knowledge Re resent at ion Extended Abstract Ronald J. Brachman AT&T Bell Laboratories 600 Mountain Avenue Murray Hill, NJ 07974 Abstract Knowledge representation (KR) has traditionally been thought of as the heart of artificial intelligence. Any- one who has ever built an expert system, a natural language system-almost any AI system at all-has had to tackle the problem of representing its knowl- edge of the world. Despite it ubiquity, for most of AI’s history KR has been a backstage activity. But in the 1980’s it emerged as a field unto itself, with its own burgeoning literature. Along with this growth, the last decade has seen major changes in KR methodol- ogy, important technical contributions, and challenges to the basic assumptions of the field. I survey some of these developments, and then speculate about some of the equally interesting changes that appear on the horizon. I also look at some of the critical problems facing KR research in the near future, both technical and sociological. Introduction There is little doubt that the current level of achieve: ment of artificial intelligence is largely due to the con- cept of a computational system capable of using an explicitly represented store of knowledge to allow it to reason about its goals, its environment, other agents, and itself. From its very beginnings, AI research has proceeded, often implicitly, on the assumption that the knowledge needed to get along in the world could be written down in some form, and then used as needed. The incarnations of this hypothesis have varied over the years, from McCarthy’s “Advice Taker,” to Newell and Simon’s “Physical Symbol System Hypothesis,” to the “Knowledge is Power” epithet of the expert system years, to Brian Smith’s explicit statement of the “Knowledge Representation Hypothesis.” While we have recently seen criticisms leveled at approaches that use explicit formalizations of knowledge, most of AI still rests securely on the foundation of knowledge representation (KR). The last ten years have been remarkably produc- tive for KR. The 1980’s produced a number of criti- cal new ideas and many important technical develop- ments. The first dedicated international KR confer- ence was held recently, and several of the more recent Computers and Thought Award winners have been from the mainstream of KR. Yet a closer look reveals that these are risky times as well. Some of the basic beliefs of the KR world are coming under increased scrutiny and doubt. Much of the work in the area has become technically obscure, accessible only to a few insiders. What “knowledge representation” means to KR insiders seems to be diverging from what it means to the rest of AI, and as a result, there is danger of the most important problems slipping through an ever- widening crack. This article outlines a talk in which I attempt to look ahead and see what might be in store for knowledge representation in the next few years.’ In it, I try to predict some of the trends that will set the pace for the next few years of research, and I will also outline some important issues that need to be addressed. Before we can look ahead, it is important to deter- mine where we have been and where we stand. To that end, I look back at the recent history of ideas in KR. First, I consider some of the general concerns of the field. Then, I touch on the style and state of work prior to 1980. Besides being an even ten years ago, 1980 was the year of the first NCAI; there, I reported on “Recent Developments in Representation Languages.” Between that talk and the 1980 SIGART Newsletter Special Issue on KR (Brachman & Smith, 1980), we have a reasonable picture of the state of the art at that time.2 After giving a quick caricature of the early days, I outline some of the key developments of the last ten years. From these we can identify some broad trends that seem to be governing work as we move into the ‘90’s. I attempt to project the likely course of some of those trends into the next few years. Finally, I look at some issues that may be critically important to the suc- ‘Here I only briefly outline some of the topics to be ad- dressed in the talk; this is not a transcript. The references are also not comprehensive. 2Al~~ in 1980, Newell introduced the “knowledge level,” and a special issue of Artificial Intelligence on “nonmono- tonic reasoningm appeared. These were particularly signif- icant harbingers of things to come in the 1980’s. 1082 INVITED TALKS AND PANELS From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. cess of KR-and AI-over the next decade. I discuss several research problems and make some recommen- dations for movement in the field as a whole. Of course, while it is easy to make predictions, it is quite another thing to be right. Much of this dis- cussion should be taken with a rather large grain of salt. Furthermore, I cannot pretend to be either to- tally fair or complete. I have had a great deal of help, with ideas donated by many of the finest researchers in the field.3 In the end, though, this represents only a personal opinion on a complicated and intertwined set of issues. The Field Interpretations of “knowledge representation” and its role in Artificial Intelligence vary widely, but at heart the idea is a simple and straightforward one: how do we impart knowledge of the world to a robot or other computational system so that, given an appropriate reasoning capacity, that knowledge can be used to al- low the system to adapt to and exploit its environ- ment? There are several basic issues: in what form is the knowledge to be expressed? how can the reasoning mechanism use a limited amount of knowledge to generate as much of the rest (i.e., implicit knowledge) as it needs? how can explicit and derived knowledge be used to influence the behavior of the system? what can the system do in the presence of incomplete or noisy information? how can the system actually reason in the face of potentially overwhelming search and inference com- plexity (e.g., NP-hard or undecidable problems)? Since most AI systems have explicit knowledge bases of one form or another, the key issues of representation and reasoning are pervasive. Indeed, almost anything that involves the above issues can be considered work in “knowledge representation.” KR has always been principally concerned with the design of forms for expressing information, ranging from informal memory models to complex formal lan- guages. Different KR systems may be better suited to different problems, but much of KR has proceeded un- der the banner of “general-purpose” KR languages and 31 am grateful to Phil Agre, Danny Bobrow, Alex Borgida, David Chapman, Ken Church, Robin Cohen, Jim des Rivieres, Jon Doyle, David Etherington, Mike Gene- sereth, Matt Ginsberg, Pat Hayes, Rick Hayes-Roth, David Israel, Henry Kautz, Wendy Lehnert, Hector Levesque, Bob MacGregor, Bill Mark, Drew McDermott, Bob Moore, Pe- ter Patel-Schneider, Ramesh Patil, Ray Reiter, Chuck Rich, Len Schubert, Stu Shapiro, John Sowa, Mark Stefik, Bill Swartout, Peter Szolovits, Robert Wilensky, Yorick Wilks, and Brian Williams. Special thanks to Hector Levesque and Brian Williams for extensive discussions and assistance. systems. In many cases, the interest is in how to rep- resent a fragment of knowledge in a formal structure, without regard for how it will be used. However, it is fairly widely held that it is virtually useless to consider a representation without consider- ing the reasoning that is to be done with it. In much of KR the kind of reasoning that will be done is primary, and the structures used to represent the grist for the reasoning mill are secondary. “KR” now clearly stands for “Knowledge Representation and Reasoning.” As a result, the study of KR is rooted in the study of logics,4 where formal syntaxes of languages are accompanied by rules of inference and interpretations. This pro- vides a standard for the correctness of an implemented “knowledge representation system”; without the logic, the only meaning of the representation language is the implementation itself. Many different types of reason- ing are possible with the same syntax, and much of the concern in the field has been with “extra-logical” manipulations, such as belief revision. In addition to the above, the field has aspects that provide it with a great richness, but also make it dif- ficult to give a simple characterization. The variety of approaches also means that there are sometimes in- comparable or conflicting goals in KR work. Much of it involves the form of knowledge, but increasingly, and appropriately, KR workers are dealing with content is- sues. Among the other research endeavors in KR we see at least the following: foundational mathematics-KR has developed its own repertoire of complex logics, and has used vari- ous theoretical tools to analyze the connections be- tween them as well as the complexity of computing various functions over the representation structures. cognitive science-one part of KR research is primar- ily interested in the structure of human thought and its parameters, either for its own sake or in order to design and understand variations on the theme. representing knowledge-part of KR involves actu- ally producing domain theories. Recent work has been concerned with more general “ontologies,” ax- iomatizations that stretch across domains, the pro- duction of large, reusable knowledge bases, and is- sues of knowledge engineering and acquisition. reasoning----many forms of domain-independent, commonsense reasoning (e.g., nonmonotonic reason- ing) are central to or overlap with KR. technoZogpKR researchers build systems to sup- port a wide variety of AI implementations. KR sys- tems can include knowledge base management fa- cilities, interface tools, query languages, acquisition tools, etc. So, while the basic idea of “knowledge representa- tion” is simple, the field as a whole is complex and var- 4This is not to say simp y 1 classical first-order predicate logic, but logics in general. BRACHMAN 1083 iegated. While the field has consolidated in some ways over the last few years, it has grown tremendously. The Pioneering Days It is hard to characterize an entire field over any length of time, but I will briefly try to give some general sense of the way things were in KR prior to 1980.5 In the early days of AI, KR was largely practiced as a subsidiary activity to more problem-specific tasks like natural language understanding. Prior to 1975 AI con- ferences did not have separate sessions for KR; instead KR papers showed up in sessions like “Computer Un- derstanding” and “Natural Language: Semantics and Parsing.” The roots of KR as we know it can be found in work on problem-solving at MIT and CMU in the late 1960’s, and emerging work on semantic networks. In the 1970’s, as AI grew, KR’s horizons expanded rapidly. The major body of work began in seman- tic nets, although there were occasional connections with formal logic, and numerous ad hoc formalisms. Many new representation languages were invented, al- though their intended scope and semantics were of- ten unaddressed. It was assumed that KR systems were to be general-purpose support tools for virtually all of AI, and arguments about the superiority of one over another were often made with respect to anec- dotal treatment of natural language examples. There were numerous arguments over what role-if any- mathematical logic should play in representing knowl- edge, and great discussion of whether “procedural” ap- proaches were superior to “declarative” ones.6 These were exciting, pioneering days, with a bit of a “land rush” feel: there was plenty of territory to be staked out, and as many ways of representing knowledge as there were people interested in the topic. Representa- tive of the times was a panel on KR held at IJCAI-77, in which eight participants presented and argued the merits of their KR “hobby horses.” An important development was Minsky’s frame pa- per (Minsky, 1975). Minsky’s concern for more re- alistic commonsense reasoning, using prototypes and defaults, complex object descriptions, “differential di- agnoses” of situations, etc., invigorated the KR com- munity and led to the development of numerous frame representation systems (most of which did not really address Minsky’s key insights). In the mid-‘70’s, the lack of semantic accounts of rep- resentational formalisms and misunderstandings of the role of logic were growing concerns (e.g., see (Woods, 1975)). Towards the end of the decade, things began to 5 See (Brachma n & Smith, 1980) for an extensive but non-homogenized catalogue of the field as of the late ‘70’s; see also (Findler, 1979) and (McDermott, 1978). ‘See (Hayes, 1977) for a summary of the arguments. Hayes states that the proceduralists’ arguments were con- clusive, although he goes on to point out serious misunder- standings of the foundations of KR in that debate. sort themselves out, and the calls for treatment of se- mantics were increasingly heeded. In some cases, frame and semantic net systems were defined in terms of stan- dard logics. In others, predicate logic was used directly as a representation medium. Generally, a more formal approach was beginning to take root. By 1980, four representational paradigms seemed to predominate: semantic networks, frames, predicate logic, and production systems. A few people were ex- perimenting with approaches combining two of these. Most approaches were still “general purpose,” although there were several subareas of KR where reasoning of a specialized sort (e.g., qualitative physics) was primary and representation was tailored to the task. There were even some de facto standards emerging in the various frame and network representations, such as compos- ite objects with slots, generalization hierarchies, in- heritance of properties, and procedural attachment. Resource-limited processing and meta-description were popular topics. Qualitative physics and other reason- ing areas had their own growing communities. And the strange new world of nonmonotonic reasoning was beginning to be explored (Bobrow, 1980). Despite the beginnings of more widespread formal- ization and some basic standard apparatus for frame systems, the picture painted by the community-wide survey in (Brachman & Smith, 1980) was still one of ad hoc methodology and heterogeneity. Most KR groups were building their own systems, which were used only by themselves, and there was still significant disagree- ment on many fundamental issues. Important Developments of the 1980% Since 1980 many things have changed. The last decade has been impressively productive, there is widespread agreement on many issues, and the methodology in the field is much more uniform. I will outline what appear to be the most important developments since 1980, although any such catalogue is an oversimplifi- cation along many dimensions. Overall Trends There are some general trends that have character- ized KR research over the last 10 years that are al- most unanimously perceived as significant (although not uniformly as positive). Technical sophistication. Over the last few years, KR papers have become increasingly technical. By and large this is good-it seems to represent a decline in the kind of loose meta-discussion popular in the 1970’s and an increase in interest in getting some real work done. On the other hand, this increase in technical detail has made KR work much harder to comprehend for those not already involved, and has helped draw KR away from the other areas of AI with which it had traditionally been allied (e.g., natural language). 1084 INWTEDTALKSANDPANELS Theory. KR work in the last ten years has also in- creasingly focused on theory. Concomitantly, KR dis- cussions in the literature have been approached with substantially more rigor than they were in the past. Some impetus for this came from several prize-winning papers at AAAI conferences in the mid-1980’s (when interest in AI was at its peak) and a groundswell of ef- fort on formalisms for nonmonotonic reasoning. More theorems and proofs than ever have appeared in recent KR papers and the body of mathematics in support of KR has grown dramatically. A formal semantics is now an obligatory accompaniment of the description of a novel KR system. The tremendous upsurge in KR theory has seem- ingly come at the expense of experimentation in the field, which has been discouraged by the actions of various program committees. This is not to say that the “experimental” side of KR (mainly associated with work on computer programs) could not use an injec- tion of rigor itself. But by most accounts, the amount of empirical work in the area has fallen off, or has gone underground. To the good, the injection of theory and rigor al- lows us to be able to determine if programs really work and has given us KR systems with precise for- mal semantics-a clear improvement over work typi- cal of the pre-1980 era. But the pendulum may have swung too far, inadvertently causing a rift between the formalists and those concerned with applications, and causing less and less of the KR literature to have any impact on the rest of AI and on practice. Declarative representations. The community has moved away from “procedural representations” to a radically declarative worldview. KR work has in- creasingly focused on what our representations say (e.g., about the world) and less on how to control procedures that process them. The ultimate embod- iment of this view is standard first-order logic with Tarskian semantics. A decade ago, debate raged on the utility of logic and declarative semantics, and on whether representations had to be “programmable”; at that time, for example, “procedural attachment” was de rigueur in frame systems. While no doubt there are still those who wish to resurrect the issue, the field as a whole seems to have warmly embraced classical logic with standard model-theoretic seman- tics. This and related issues were discussed at length in a special journal issue (Levesque, 1987) addressing McDermott’s critique of “pure reason,” but even Mc- Dermott, while unsure of the prospects for success of use-independent, purely declarative knowledge bases, could not come up with a very concrete alternative. Major contributions to the declarative view included Levesque’s functional approach to knowledge represen- tation (Levesque, 1981) and Newell’s “knowledge level” proposal (Newell, 1981). Reasoning. Almost paradoxically, there has been increased focus in the KR community on general types of reasoning. Attention has shifted from the preoccu- pation with pure language design of the ‘70’s to the arena of different types of inference (e.g., temporal, “abductive,” “case- based” ) . This is a good sign, in that the older formalisms could rarely be evaluated be- cause it was never clear what they meant or what infer- ences they sanctioned. This however, has led to some difficulty, in that conference calls for papers continue to divide KR from its sine qua non, reasoning (e.g., “Commonsense Reasoning,” “Automated Reasoning,” and KR are considered distinct topics). Ten years ago, this split might have been appropriate, but now such distinctions are artificial and detrimental. It has be- come hard to tell where most papers belong and how to judge them. Concentration. Another trend of note is a terrific concentration-almost an “implosion’‘-of work in a small set of areas, most notably nonmonotonic reason- ing and qualitative reasoning about physical systems. A look at recent conference proceedings reveals how large a number of people have flocked to a very small set of issues. Technical Developments Within the context of the above global trends, there have been numerous notable technical developments in KR over the last decade. Here I briefly gloss over some of the more obvious happenings to give a flavor of what caught the fancy of the KR community. Nonmonotonic reasoning. Easily the most no- ticeable KR area at recent conferences has been that of “nonmonotonic reasoning” (NMR), wherein formal approaches are proposed to handle the fact that a great deal of reasoning must be based on assumptions that may be ultimately shown to be false. Since informa- tion learned at some future time may falsify a default assumption, many commonsense reasoning situations are inherently nonmonotonic The last ten years has seen the introduction of nu- merous formalisms for NMR, including circumscrip- tion, Default Logic, autoepistemic logics, conditional logics, and many variants of inheritance systems. Some of these are semantic, or consistency-based systems (e.g., they depend on a certain default being consis- tent with an entire KB) and some are syntactic (e.g., they depend on paths through a graph). A key insight has been the use of “minimal models” as the seman- tic basis of many nonmonotonic systems. Among the key developments in the ‘80’s was work by Reiter and students showing that some flaws in inheritance mech- anisms could be elucidated by formalizing the networks in terms of Default Logic, and that the commonly used “shortest-path heuristic” was inadequate. The nonmonotonic world has concentrated on a small number of canonical problems, such as deter- 7For a more camp rehensive introduction to this area, see (Etherington, 1988), (Reiter, 1987), and (Ginsberg, 1987). BRACHMAN 1085 mining if a given bird can fly from the statement of a default like “typically, birds fly.” This is harder than it may look, if you want to take seriously the possibility of birds not flying. Once the basic problem is solved, other more convoluted ones arise, such as the multiple- extension, “Nixon Diamond” problem (in this case the typical NMR system will produce two possible answers to a default inheritance problem). Another key devel- opment (although the importance of the problem itself is arguable) was the ‘Yale Shooting Problem” (Hanks & McDermott, 1986), which illustrated how circum- scription could yield counterintuitive results on certain problems involving the projection of events over time. This work caused quite a stir even before it appeared in print, and has provoked work on many solutions. The Yale Shooting Problem and other canonical NMR problems involve a very small number of ax- ioms to describe their entire world. These may not be fair problems because the knowledge involved is so skeletal. It seems unrealistic to expect a reasoner to conclude intuitively plausible answers in the absence of potentially critical information. By and large, NMR techniques have yet to be tested on significant, “real- world”-sized problems. Qualitative physics. As mentioned, in the ‘80’s there was tremendous growth in interest in qualita- tive reasoning, almost exclusively about continuous physical systems (thus it is usually called “qualita- tive physics” (QP)) (Bobrow, 1984; Weld & de Kleer, 1990). The work has its roots in work on engineering problem-solving at MIT in the 1970’s, Hayes’s work on Naive Physics, and in early work on how devices work by Rieger and Grinberg. As with other fields, QP does not have a single coherent view, and people differ on the key goals. But generally, QP is about how things work, including (1) what are appropriate representational primitives for the salient features of devices and their behavior? (2) given a physical ar- tifact and an initial situation, how do we construct a description of how that artifact works? and (3) how do we use this description to perform interesting tasks like diagnosis and design ? Most agree that explana- tions of how things work have qualitative, temporal, and causal components. The first half of the ‘80’s was spent roughing out the representations of these explanations, and propos- ing techniques for generating them. The greatest ad- vances were on the qualitative component, although work proceeded on the others. The main issue is, what are good qualitative representations for the values of quantities and relationships between quantities? Orig- inally, the sign of the derivative of a quantity was pro- posed as an important qualitative representation; this was expanded to include ordinal relations (<, =, >) of “landmark values,” and eventually to have’ a de- vice’s “state space” divided into open regions of inter- est separated by boundaries, where “regions of inter- est” are defined by the task. Representations for rela- tionships between values were explored, among them, “confluences’‘-equations on the signs of quantities. In the mid-‘80’s, work in QP took off, in part spurred by a special issue of Artijicid InteIZigence(Bobrow, 1984). At the center of the more recent work has been representations for relationships between values, including more powerful qualitative algebras, and more direct ties to the standard frameworks of mathematics and physics. There is also, of course, a tremendous amount of work on reasoning with these and other rep- resentations, which we do not have space to cover here. The notion of a truth maintenance system (TMS) (McAllester, 1990) grew up within the community in- terested in reasoning about physical devices, although the ideas have now spread far and wide. The ideas go back to early work at MIT. Interestingly, this work ties directly back into work on nonmonotonic reason- ing. Work on TMS’s grew tremendously in the ‘80’s. While NMR and QP shared the KR limelight in the ‘80’s, they were not the only technical activities. A number of other topics with keen interest emerged: The revival of probabilities. In the 1970’s, it was virtual heresy to talk about numbers, since that was taken to mean that something was being swept under the rug (e.g., causal relationships disappeared in numerical approaches, and even in the medical AI community, many turned away from probabilities). While Bayesian/decision-theoretic approaches were at- tractive, since they allowed one to maximize expected value even in cases that were not statistically signif- icant, they were problematic because they either re- quired you to assume that everything was conditionally independent or that everything was dependent. In the ‘80’s work on Bayes networks (Pearl, 1988) yielded rep- resentations that could express partial dependence and partial independence. This allows one to tackle large- scale decision problems from a formal probabilistic per- spective, and it should have some important practical implications. Other important work integrating prob- abilistic and deductive reasoning is just beginning to unfold, and could have a major effect on KR work on realistic problems in the next few years. Hybrid reasoning systems. By the mid-‘80’s, combining multiple types of representation was pop- ular. In a division of representational labor, special- ized subsystems stitched together might provide the power to handle realistic domains without forcing a single uniform, too-powerful logic. Hybrids of various sorts were developed, including several marrying logic and frames. Sorted logics grew in popularity, and com- mercial expert system shells generally offered several loosely integrated types of representation. One im- portant criterion for separation of hybrid components (Brachman & Levesque, 1982) distinguished between terminology (knowledge about the meanings of terms, independent of the existence of any objects exempli- fying those terms) and assertion (knowledge of contin- 1086 INVITED TALKS AND PANELS gent facts). A large family of terminological and hybrid systems developed inspired by KRYPTON (Brachman et al., 1983) (th ese ultimately attribute their roots to work done on KL-ONE (Brachman & Schmolze, 1985) in the late ‘70’s and early ‘80’s). Novel work was also done on taxonomic syntax and reasoning. Complexity of reasoning. An influential piece of work that grew out of hybrid representation involved proofs of the computational complexity of the term subsumption inference (Brachman & Levesque, 1984). The results were surprising: small syntactic changes in a representation language can lead to dramatic changes in inference complexity (“computational cliff’ was a term used to describe the transition). There soon fol- lowed a large number of analyses of the complexity of reasoning with various related term-subsumption languages. In the latter half of the decade, it be- came common to see complexity results for reasoning in various types of systems, ranging from default in- heritance schemes to abduction. Besides leading to systems whose complexity characteristics were under- stood, this led to better appreciation of how hard it is to avoid potentially intractable inferences. Case-based reasoning. Another important thread in the ‘80’s has been the attempt to reason based on catalogues of past experience, appropriately indexed. By drawing analogies to the current situation, a case- based reasoner may be able to reuse or revise a previ- ously stored solution. This work has looked at memory structures for case-based reasoning in general and in legal argumentation, medical diagnosis, etc. Abductive reasoning. Throughout the decade, in contexts ranging from story understanding to circuit diagnosis, attention was paid to foundations of diag- nostic reasoning, usually called “abductive” inference. Abduction is reasoning to the best explanation-a nonmonotonic inference. Recently, general algorithms for abduction have been studied, and the complex- ity of abductive inferences have been catalogued. In some cases, diagnostic reasoning “from first principles” (sometimes called “model-based diagnosis”) has been achieved-an important advance over shallower expert system diagnostic methods. Interest in abduction has been around since the early ‘70’s, but was dormant until recently. Interest in diagnosis is growing rapidly. Vivid reasoning. In 1985, Levesque (Levesque, 1986) introduced a novel approach to reasoning that attempts to deal with the complexity of reasoning by allowing the relaxation of correctness and completeness in some cases. The basic idea is to use past experience and other default knowledge to reduce general first- order knowledge to roughly database-or “vivid”- form. Reasoning in the vivid KB then reduces to fast retrieval, although some information must be lost and some errors introduced in the translation. This idea has led to several interesting technical innovations. Large KB’s. In the ‘80’s we began to see the rise of projects developing very large knowledge bases. For example, Lenat and colleagues initiated the CYC project (Lenat & Guha, 1990)-a bold attempt to en- code millions of fragments of “consensus reality” in an encyclopedic knowledge base. This project has begun to raise a host of issues previously unaddressed, sim- ply because of its magnitude and its need to concern itself with “ontology.” More generally, with the con- templation of significant investment of time and energy into single KB’s, concern has begun to develop about the reusability of KB’s, knowledge base management issues, general issues of ontology, and standards for representation languages. A recent workshop explored the possibility of developing an interlingua that could be used to share KB’s from one project to another, even if the projects used different KR languages. Other. There were a number of other topics pur- sued rather vigorously by the KR community, among them temporal reasoning, “model-based” reasoning, reasoning about mental systems (including intension- ality, goals and commitments, explicit and implicit be- lief, and combining evidence), and continued and ex- panding work on a few network representation systems (e.g., Conceptual Graphs, SNePS). other Developments Beyond its own technical progress, KR benefited from the commercialization of AI in the 1980’s. It began to have an impact on the “real world” via expert system shells sold to the public and used in commercial ap- plications (even Byte Magazine had a special issue on KR). While the KR technology that supported most commercial expert systems work was somewhat simple and had been developed long before, some of the larger shells included multiple representational components (typically rules, frames, and some logical representa- tion). With rule-based programming becoming an ac- ceptable alternative (not to mention the widespread use of PROLOG, which bears some relationship to KR), KR made its way into the mainstream of technology. Another intriguing development of the 1980’s was the beginning of exploration of connections to other fields, including decision theory, control theory, eco- nomics, etc. (e.g., (Doyle, 1990)). And finally, in 1989, the KR’89 conference (Brach- man et al., 1989) brought together the KR community. Nagging Doubts One of the most important developments for KR has been the recent resurrection of interest in connectionist architectures. There are many brands of connection- ism, some of them quite compatible with the KR view; one key strain advocates non-symbolic computation. The statistical nature of some connectionist systems makes them less fragile than symbolic KR systems in the face of noise, and since ultimately much of the in- formation to be obtained by AI machines will be noisy, this seems to indicate that connectionist systems will BRACHMAN 1087 eventually take over the role now being played by tra- ditional KR systems. Arguments along these lines have been made, but the jury is still out. Connectionist sys- tems have been found useful for low-level, more percep- tual tasks (like handwritten character recognition), but are still a long way from being able to produce a plan or an explanation. Ultimately, we will probably see hybrid systems with both connectionist and symbolic components, but for now, there is widespread debate about what connectionist systems will eventually be able to do, and what kind of threat they are to more traditional approaches. In a somewhat related vein, some researchers have claimed that many types of intelligent-seeming behav- ior can be accomplished without the use of explicit knowledge, but rather with compiled-in structures that allow a system to react directly to its environment (to “lean on the world” for parts of its knowledge, rather than store it explicitly internally). The “reactive” and “situated” (Rosenschein, 1990) (where the fact that the system is embedded in its world is taken as primary) approaches are concerned with real-time performance, and in some cases appear able to overcome compu- tational bottlenecks of approaches that use theorem- proving. Again, there is an issue of how much of intel- ligent behavior is achievable with purely reactive sys- tems, although there are arguments to be made about how such architectures more closely resemble (parts of) natural systems. Even within the hard-core KR community, there were doubts about traditional ways of doing things. The “logicist” approach-strict declarativism, with knowledge represented independent of use-was taken to task by McDermott(McDermott, 1987). This sparked continued debate (Levesque, 1987) over whether it is desirable or productive to build large knowledge bases without direct attention to the in- tended application of the knowledge (not to mention continued argument on the role of logic in KR). All of this provides some healthy skepticism for a field that could easily get set in its ways. It is im- portant to remember that there are situations where symbolic representation is either implausible or inade- quate. In fact, while some KR people might think of connectionism as a radical hypothesis, when one looks at the natural world, it becomes apparent that the symbol-manipulation view of intelligence-the well- spring of KR-is the more radical view. Some “Non-Happenings” It is interesting to reflect on events that might have been predicted for the ‘80’s, but which never took place. These items still hold the promise that they did a while ago, and in most cases interest seems to be returning. But they were surprising by their absence. AH-DB integration. In the mid-‘80’s, the prospect of “expert databases,” and the commonplace integra- tion of KR and DB technology excited great interest. Work on deductive databases held the promise of syn- ergy with mainstream KR. So far, this has not panned out, perhaps because the basic concerns of practical database management and KR are quite different. CcPrototypes.” Minsky’s original frames paper and work on KRL promised that insights from cognitive sci- ence on prototypes and basic categories would have a major influence on AI reasoning systems. Unfortu- nately, this and other aspects of the frames paper seem to have gotten lost along the way. Natural language semantics. Given that KR was principally driven by natural language concerns right up to the beginning of the decade, one would have expected substantial progress to have been made in the ‘80’s on KR support for NL semantics. This seems not to have been the case. Diagrammatic representations. In 1980, Funt (Funt, 1980) p resented an innovative but under- appreciated representation for visual information. Col- lisions of objects could be detected by direct calcula- tion on an analogue representation. “What Computers Can’t DO.” Throughout the history of KR, there has been debate over whether thinking can be achieved by a mechanized process that manipulates symbols. The revised version of Drey- fus’ book and Searle’s account of the “Chinese Room” seemed to portend great difficulty for KR practition- ers. As it turns out, regardless of the ultimate cogency of the arguments against formal AI, work in KR has proceeded without heed. M&a-reasoning. Early in the ‘80’s there was much hope that many hard problems could be solved by “go- ing meta.” So far, met&reasoning has not turned out to be a panacea. The Future of Knowledge epresentation Despite the telegraphic nature of the above comments, it should be clear that in the past ten years KR has seen some significant changes. Work is substantially more formal and rigorous than it was prior to 1980, fewer implemented systems are being discussed, and a small number of issues have absorbed great attention. The field has moved to center stage in AI, owing to several factors, including some “best papers,” journal special issues, Computers and Thought lectures, eye-catching problems and projects, widespread use of expert sys- tem shells, and a dedicated international conference. But there are some lurking worries. Many feel that the emphasis on formal logic has gone too far, and that important experimental work is being squeezed out by purely theoretical concerns. Much of the work being done bears little regard for realistic problems. The pipeline of interesting problems to analyze (usu- ally generated by attempts to build systems) seems to be filling too slowly. As KR focuses more on self- generated technical problems, it seems to move farther 1088 INWl-EDTALKSANDPANELS from the rest of AI that it was originally intended to support. And connectionism and other non-symbolic approaches seem to pose a threat to the very existence of the KR enterprise. What does this portend for the next ten years? Hav- ing given some thought to major developments of the past, it is time for us to get back to the future of knowl- edge representation. Here are some potential high- lights. Some Likely Scenarios Logic and rigor. The emphasis on rigor in KR will probably continue. Despite some disgruntlement in various circles it is also likely that the logicist program will continue to dominate, although we might see a procedural backlash of some sort, and serious discus- sion of the role that intended use plays in the form of knowledge. Some believe that there will be move- ment away from classical model-theoretic semantics, and perhaps more interest in relevance logics and in- tuitionistic logics. There will continue to be some con- cern about computational complexity-this is healthy, although the meaning of such results needs to be clari- fied (see below), and finer-grained analyses are needed. KR in general will show an increasing frustration with seemingly irrelevant mathematics and theorems not clearly motivated by important problems. While the mathematical foundations of the field are critical, the talented community interested in such work may seek a more comfortable home (e.g., a specialized con- ference); movement of this sort is already underway. Nonmonotonic reasoning. Intuitions about the meaning of nonmonotonicity and its different incar- nations will probably become better identified. We will see a wave of formal systems based on argu- ments for and against a given conclusion; ultimately, we should see work relating such systems back to the consistency-based and syntactic systems. In general, if we are lucky, the field will realize that it is the skele- tal, impoverished-knowledge cases on which different views clash, and concern itself with more conserva- tive approaches; that is, if most NM systems agree on the common cases, then there should be less argument about which is superior and which is flawed, and more on how to solve the really fundamental problems. All in all, this could result in fewer new approaches and more utility from the ones we have, and a revived con- cern for solving real problems with realistically com- plex KB’s (this should ultimately make the problem easier, not harder). Again, if we are lucky, we should start seeing analyses of the nonmonotonic aspects of real-world problems, and the proposal of limited and conservative mechanisms that actually solve them. Unified reasoners. In the near future, we can ex- pect to see more theories that unify different types of reasoning. For example, we are beginning to see logics that incorporate both deduction and abduction (di- agnosis and explanation are integrated into a deduc- tive framework). This trend is likely to continue, with, for example, induction added to the arsenal of reason- ing strategies in a unified system. Other efforts (e.g., (Bacchus, 1990; Halpern, 1989)) have begun to unify deductive, nonmonotonic, and probabilistic reasoning in a coherent and smooth way. Ultimately, reasoning about action and time (planning) and the kind of rea- soning underlying learning will also find their way into what might ultimately become a grand unified theory of reasoning. Probability and statistics. We can expect work on statistical and probability-based reasoning to be- come more closely associated with mainstream KR. We will soon see more accounts of probabilistic and fuzzy reasoning that are compatible with standard ap- proaches. These will help meet the challenges to deduc- tive reasoning currently posed by the need to handle noisy data, frequency information (e.g., in learning), and “fuzzy” concepts. In ten years, many approaches will include both a standard deductive/categorical mechanism and one for dealing with limited observa- tions of regularities in the world (in fact, the deductive mechanism may be the minor component, used only in sticky, “puzzle-mode” situations). We are seeing signs of this in NL, wherein statistics about co-occurrence of words can provide valuable disambiguating infor- mation for more traditional categorical approaches to parsing, and it is likely that the influence of probability will have a similar effect on KR and reasoning systems. This kind of approach will be critical in planning, for example, where the view of a plan as a theorem to be proved is too restrictive to be realistic. Natural language. There has been a deep connec- tion between KR and NL as long as those areas have been studied, and the connection is still there, even though KR research has focused less on NL-specific issues (with some recent movement in the NL commu- nity towards statistical text-based analyses, they have drifted even farther apart). Some predict, however, that we will see a strong move back to support NL se- mantics and pragmatics by some parts of the KR com- munity. Some recent work (Schubert & Hwang, 1989) illustrates the potential direction of this work. Older work by Martin (Martin, 1979) will probably be reex- amined and found surprisingly innovative and useful. The issue of indexicality will continue to be addressed, although it is not clear that representations need to be indexical the way that language is. Ontology. Issues of ontology will be among the most important and most talked about in the next few years. How to build the “upper model”-the topmost levels of a large hierarchy of commonsense knowledge, how to integrate parts created by different people, and how to control revisions will be important considera- tions; the automatic generation of ontologies will prob- ably also become a much-discussed topic. Along re- lated lines, “prototypes,” basic categories, and other psychological phenomena having to do with categoriza- BRACHMAN 1089 tion of the world will probably make a comeback. Large KB’s. Very large knowledge-based systems will soon be commonly upon us. With this, issues that have occupied the database world will come to con- cern KR developers, although perhaps complicated in interesting ways by the logical interpretation of KR languages. Among such concerns, we might see shar- ing of KB’s, persistent object stores, dealing with out- dated or suspect information, “drift” of terminology, and infrastructure issues such as ownership and com- mercial value of represented information. Incremental revision will be of paramount importance, since KB’s will exist over longer periods of time. Knowledge ac- quisition will of necessity move closer to mainstream KR-with very large knowledge bases, automatic and semi-automatic acquisition will become the sine qua non of KB’s. Memory organization issues will reap- pear within KR (some of the earlier work of Schank, et al., will possibly be rediscovered or reinvented). Fi- nally, much will be learned from trying to build CYC, although serious obstacles (e.g., difficulty of timely in- ference in a large enough KB, reconciliation of pieces built by different authors, and general skepticism of the utility of a KB built without a particular use in mind) may prevent it from being anything other than an exciting first experiment. KR to the people. It is probable that by the mil- lenium “knowledge systems” will be a common com- mercial concept. This has important implications for the future of KR. Among other things, KR components will increasingly find themselves in the hands of non- experts, raising a novel set of issues (see below). The issue of KR standards will grow somewhat in impor- tance, with immediate emphasis on intertranslatability between various languages; no doubt subcommunities will also work on true standard KR languages for cer- tain classes of problems. I suspect that, because of the diversity of approaches in the field and current lack of incentives for standardizing, the results of this stan- dards work will be less than ideal for the foreseeable future. However, with increasing governmental and commercial investment in knowledge bases, it really does need to be addressed. No HAL. It is hard to ignore the fact that in roughly another decade we will be confronting the year 2001. Sad to say, given the progress to date, we can comfortably predict that there will be no HAL-9000 available (or even anything close). Some Open Research Problems I now briefly cover some issues in need of research, some broad and some technical. Some of these may have work underway already, so the distinction be- tween the above predictions and this wish list is not absolute. Expressiveness vs. tractability. The general issue of computational efficiency needs more work. What is the meaning of the complexity results pro- duced so far? Worst-case results seem too coarse- grained to be of use in designing real systems, although without understanding how often such cases arise, or what a normal case might be, we still need to pay careful attention to such results. Perhaps decision- theoretic methods could be used as a way of dealing with intractable problems. An irony of work on NMR is that, while the easy adoption and retraction of assumptions is most useful for speeding up natural everyday reasoning, most cur- rent NMR proposals drastically compound the already difficult problem of deductive reasoning. We urgently need to determine how NMR can be used to make com- monsense inference faster, not slower. Unless progress can be made on this front, then most of NMR will prob- ably end up as an interesting mathematical dinosaur. We need ways of doing quick, perhaps inaccurate (but reasonable) reasoning, and to understand when and how to fall back on more reliable, but slower methods. Incomplete reasoners. As we build more expres- sive KR systems, we are virtually guaranteed that they will be incomplete. What is the most useful way to build an incomplete reasoner? Are there ways of de- scribing such systems so that users will understand ex- actly what to make of the results returned and how much to trust the system at any point? Can we build systems that yield results any time we need them (i.e., the best guess at the time) and whose results improve as we let them run longer? KR services. It is possible that the idea of a “general-purpose KR system” that has pervaded the field for many years is meaningless. It may not be possible to rationalize the needs of all applications in one system, and simply opting for maximal expres- sive power may not be the best strategy in all situ- ations. When can the needs of a KR service be con- strained? Are there different reasonable and natural levels of service that can be provided? (I would like to see these levels characterized in a “knowledge level” way, rather than simply saying what procedures are invoked at what level.) Can one system provide many different levels at the user’s option? Can we character- ize the cost of various services so that a user can take it into account in deciding whether to invoke an infer- ence mechanism? In general, the roles that KR com- ponents of a knowledge-based system can play need to be articulated, and the services that the KR system is supposed to provide should be clarified. In the past we have emphasized the need for a KR component to have “predictable” behavior. If “predictability” does not mean “completeness,” what exactly does it mean? KB management. With the advent of very large, realistic knowledge bases, we will need to address the problem of inconsistency: how can a knowledge-based system live with globally inconsistent, but locally rea- sonable knowledge? The problem of limiting the scope of an inference procedure will also be important. This is not a new issue (how to find the relevant things to 1090 INVlTED TALKS AND PANELS think about in a vast sea of undifferentiated facts), but it is likely to have practical consequences in the next ten years. Knowledge base management issues will grow in importance (including low-level ones like version control). More attention will need to be paid to a higher level of knowledge organization, “above” the knowledge level: what are good principles for or- ganizing knowledge of various sorts? And, since large KB’s will invariably be built by multiple sources over much time, we will also need practical but well-founded theories of belief revision. Usability of KR systems. As mentioned, KR sys- tems will increasingly find their way into the hands of “non-professionals.” How do we ease this market en- try? What aspects of KR need to be emphasized and which de-emphasized in order to allow real users to deal with the knowledge and not get bogged down in system details or complex KR issues that seem irrele- vant to them? Experience from the commercial world of expert system shells should be heeded here. Issues of presentation of knowledge, browsing, and querying will be critical, as will the need to explain the sys- tem’s reasoning in terms comprehensible to normal hu- mans. KR systems in general are likely to become much more complicated, especially as more types of reasoning become better understood and are routinely incorporated; the inner workings will thus become in- comprehensible even to experts and these same issues will be doubly important. Other. There are numerous other research prob- lems on which work is needed; here are a few practical ones: integration of frame classification systems and respectable theories of defaults and inheritance; pre- cise theories of approximate categorization, ultimately integrated with more deductive classification schemes; extensible representation schemes that allow expert users to add important constructs, without having to rebuild the system from scratch; the efficiency and us- ability of reason maintenance systems (critical as we scale up). Deeper issues. Finally, there are of course deeper and more general issues. For example, there seems to be some strong general sentiment for the need to take into account the use to which knowledge is to be put before designing a representation or making any claims about it. Can we have realistically useful KB’s that are designed in absence of specific intended applications? Why are we so convinced that knowledge actually has to be represented at all? What kinds of activi- ties are infeasible without general reasoning abilities? Are there principles for making something explicit or declarative? Current work on reactive and related sys- tems will hopefully produce vital data on the limits of non-declarative systems (if there are any). In fact, in the long run, we might consider whether the idea of a separable KR component really makes sense at all. How could the mind have such “loose coupling” between its “knowledge base” and the rest of its capabilities? Recent work in databases, as well as situated automata, reactive systems, and neural nets indicate that a tightly integrated reasoning system may be more realistic than one with the typical bipartite knowledge-based architecture. Some General Recommendations One of the imminent dangers of work in KR is the risk of losing touch with the rest of AI, despite the fact that the ruison d’e^tre of KR is to support it. As we delve into more technically sophisticated details, we seem to leave our “customers” farther and farther behind. While we need to address our problems with technical depth and rigor, we also need to avoid the syndrome of “epicycles” and be careful about losing the forest of commonsense reasoning for the trees of default inheritance. It would not hurt at this point to go back and spend time thinking about the relation of KR to natural language, for example-after all, that was in part responsible for the birth of the field in the first place. This is not to say that KR should return to its primordial ooze, but only that we must refocus on real and important problems. This is especially true in areas like NMR and QP: what real-world problems are better off now than they were ten years ago? We also need to re-encourage experimentation, al- though we can be very careful about what constitutes an acceptable experiment. In a way, we need to get back to the “pioneering” spirit of the 1960’s and ‘70’s, but armed with the insight and mathematical arsenal of the ‘80%. Conference program committees in KR should look for more good ideas and fewer mathemat- ical journal-style papers. Our conferences have taken on too much of the flavor of journal-readings and have lost some of the excitement of actually conferring to argue about new and provocative ideas. In order for this to be realistic, systems-oriented peo- ple should give some serious thought to what consti- tutes a result in the experimental side of the field. We need more consideration by this community as a whole as to what its goals are, and what the impor- tant issues of KR system design and implementation are. The development of some metrics for measuring quality, scope, etc., would be especially welcome. We should try to eliminate the insidious split that has developed in calls for papers-since commonsense and other forms of reasoning are the very reason that KR exists, it is problematic to list them as completely separate areas. It is hard under the current scheme to know to which area to send papers. We must remem- ber that KR stands for knowledge representation and reusoning, and structure our topics accordingly. We should also continue developing relationships with mainstream computer science and other disci- plines that are related to our enterprise, including con- trol theory, decision theory, statistics, OR, economics, etc. We must remain open-minded about input from these other disciplines. Recent work has indicated that BRACHMAN 1091 the payoff from merging AI ideas with traditional disciplines could be great. those of more probability. In Proc. IJCAI-89, pages 1375-1381, Detroit, MI. All in all, it is clear that KR has been thriving these past ten years: it has developed a substantial body of technical machinery and has moved into the “real world.” The next decade promises to be as intellectu- ally rich as the last, and if the right attitude is taken and the right problems addressed, it should bring us much closer to having reliable, fast, and reasonable reasoners. References Bacchus, F. 1990. Representing and Reasoning with Prob- abilistic Knowledge. The MIT Press, Cambridge, Mas- sachusetts. Bobrow, D. G., ed. 1980. Special Issue on Non-Monotonic Logic. Artificial Intelligence, 13(1-2). Bobrow, D. G., ed. 1984. Special Volume on Qualitative Reasoning about Physical Systems. Artificial Intelligence, 24( l-3). Brachman, R. J., and Levesque, H. J. 1982. Competence in knowledge representation. In Proc. AAAI-82, pages 189- 192, Pittsburgh, PA. Brachman, R. J., and Levesque, H. J. 1984. The tractability of subsumption in frame-based description languages. In Proc. AAAI-84, pages 34-37, Austin, TX. Brachman, R. J., and Levesque, H. J., eds. 1985. Readings in Knowledge Representation. Morgan Kaufmann, San Ma- teo, California. Brachman, R. J., and Schmolze, J. G. 1985. An overview of the KL-ONE knowledge representation system. Cognitive Science, 9(2):171-216. Brachman, R. J., and Smith, B. C., eds. 1980. Special issue on knowledge representation. SIGART Newsletter, No. 70. Brachman, R. J., Fikes, R. E., and Levesque, H. J. 1983. KRYPTON: A functional approach to knowledge represen- tation. IEEE Computer, 16(10):67-73. Brachman, R. J., Levesque, H. J., and Reiter, R., eds. 1989. Proceedings of the First International Conference on Prin- ciples of Knowledge Representation and Reasoning. Morgan Kaufmann, San Mateo, CA. Doyle, J. 1990. Rationality and its roles in reasoning. In Proc. AAAI-90, Boston, MA. Etherington, D. W. 1988. Reasoning with Incomplete In- formation. Pitman, London. Findler, N. V., ed. 1979. Associative Networks: Representa- tion and Use of Knowledge by Computers. Academic Press, New York. Funt, B. V. 1980. Problem-solving with diagrammatic rep- resentations. Artificial Intelligence, 13(3):201-230. Also in (Brachman & Levesque, 1985). Ginsberg, M. L., ed. 1987. Readings in Nonmonotonic Rea- soning. Morgan Kaufmann, San Mateo, CA. HaIpern, J. Y. 1989. An analysis of first-order logics of Hanks, S., and McDermott, D. 1986. Default reasoning, nonmonotonic logics, and the frame problem. In Proc. AAA I-86, pages 328-333, PhiIadelphia, PA. Hayes, P. J. 1977. In defence of logic. In Proc. IJCAI-77, pages 559-565, Cambridge, MA. Lenat, D. B., and Guha, R. V. 1990. Building Large Knowledge-Based Systems. Addison-Wesley, Reading, MA. Levesque, H. J. 1981. The interaction with incomplete knowledge bases: A formal treatment. In Proc. IJCAI-81, pages 240-245, Vancouver, British Columbia. Levesque, H. J. 1986. Making believers out of computers. Artificial Intelligence, 30(1):81-108. Levesque, H. J., ed. 1987. Taking Issue/Forum: A Critique of Pure Reason. ComputationaZ Intelligence, 3(3). Martin, W. A. 1979. Descriptions and the specialization of concepts. In P. H. Winston and R. H. Brown, eds., Artificial Intelligence: An MIT Perspective, Vol. 1, pages 377-419. MIT Press, Cambridge, MA. McAIIester, D. 1990. Truth maintenance systems. In Proc. AAAI-90, Boston, MA. McDermott, D. V. 1978. The last survey of representation of knowledge. In Proc. AISB/GI 1978, pages 206-221. McDermott, D. V. 1987. A critique of pure reason. In (Levesque, 1987), pages 151-160. Minsky, M. 1975. A framework for representing knowledge. In P. H. Winston, ed., The Psychology of Computer Vision, pages 211-277. McGraw-Hill, New York. Also in (Brach- man & Levesque, 1985). Newell, A. 1981. The knowledge level. AI Magazine, 2(2):1- 20. Pearl, J. 1988. Probabilistic Reasoning in Intelligent Sys- tems: Networks of Plausible Inference. Morgan Kaufmann, San Mateo, CA. Reiter, R. 1987. Nonmonotonic reasoning. In Annual Re- views of Computer Science, Volume 2, pages 147-186. An- nual Reviews Inc., Palo Alto, CA. Rosenschein, S. J. 1990. Reasoning and acting in real time. In Proc. AAAI-90, Boston, MA. Schubert, L. K., and Hwang, C. H. 1989. An episodic knowledge representation for narrative texts. In (Brach- man et al., 1989), pages 444458. Weld, D. S., and de Kleer, J., eds. 1990. Readings in Qual- itative Reasoning about Physical Systems. Morgan Kauf- mann, San Mateo, CA. Woods, W. A. 1975. What’s in a link: Foundations for semantic networks. In D. G. Bobrow and A. M. Collins, eds., Representation and Understanding: Studies in Cogni- tive Science, pages 35-82. Academic Press, New York. Also in (Brachman & Levesque, 1985). 1092 INVITEDTALKSANDPANJZLS
|
1990
|
60
|
979
|
Rationality and its Roles in Reasoning (Extended Abstract) Jon Doyle* Massachusetts Institute of Technology Laboratory for Computer Science 545 Technology Square Cambridge, Massachusetts 02139, USA Abstract The economic theory of rationality promises to equal mathematical logic in its importance for the mechaniz* tion of reasoning. We survey the growing literature on how the basic notions of probability, utility, and ratio- nal choice, coupled with practical limitations on infor- mation and resources, influence the design and analysis of reasoning and representation systems. Introduction People make judgments of rationality all the time, usu- ally in criticizing someone else’s thoughts or deeds as irrational, or in defending their own as rational. Artifi- cial intelligence researchers construct systems and the* ries to perform or describe rational thought and action, criticizing and defending these systems and theories in terms similar to but more formal than those of the man or woman on the street. Two conceptions of rationality dominate these judg- ments: a logical conception used to judge thoughts, and an economic one used to judge actions or choices. For example, when people criticize as irrational someone who asserts both a proposition p and its contrary lp, or who asserts p and p=+q but refuses to accept q, they refer to a logical sense of rationality. Correspondingly, when some people criticize others for irrationally wast- ing their money on state lotteries, in which the pre- dictable result of prolonged gambling aimed at winning money is, in fact, to lose money, the critics have in mind the economic sense of rationa1ity.l In classical terms, logic concerns Truth, while economics concerns Good- ness (though a case can be made that neither says much about either). Traditionally, much work in artificial intelligence has been greatly swayed by the “logicist” view that logic is the theory of the ideal good thinking desired of all intelligent agents-in particular, that beliefs should be *This work was supported by National Institutes of Health Grant No. ROl LM04493 from the National Library of Medicine. ‘Gambling may be rational if the gambler also has non- monetary aims, such as entertainment. consistent and inferences sound-and has paid much less attention to the economic sense of rationality. One may interpret much non-logicist work on heuristics as implicitly concerned with rationality in the economic sense, but little of this work discusses rationality ex- plicitly or employs any of the formal tools offered by the mathematical theory of rational choice. Recently, however, interest in economic rationality and its formal theory has grown as researchers have sought to find methods for reasoning under uncertainty, for control- ling reasoning, and for putting heuristic methods on sound theoretical bases-each one an issue on which logic alone provides little guidance. The purpose of this paper is to introduce the ba sic notions of economic rationality. These constitute a rich set of conceptual and mathematical tools for analyzing information and behaviors, and provide the proper framework for addressing the problem of how one should think, given that thinking requires effort and that success is uncertain and may require the co- operation of others. Though it provides an attractive ideal, however, the level of information and computa- tional ability demanded by the theory render straight- forward applications of the theory impractical, as was pointed out early on by Simon [1955], who introduced the term bounded rationality (also called limited ratio- nality) for the rationality that limited agents may fea sibly exhibit. We first summarize the basic concepts of economic rationality and identify the principal roles economic rationality plays in the theory and practice of artifi- cial intelligence. The highly abbreviated remainder of this extended abstract examines various impediments to achieving rationality, indicates recent developments on techniques for reasoning rationally in the presence of these limitations, and points out some future directions for research. Economic rationality The fundamental issue in the theory of economic ra- tionality is choice among ahernatives. Economic rit tionality simply means making “good” choices, where DOYLE 1093 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. goodness is determined by how well choices accord with the agent’s preferences among the alternatives. We summarize the elements of this theory here: for more complete expositions, see [Debreu, 1959; Savage, 1972; Jeffrey, 19831. Preference The notion of preference is the fundamental concept of economic rationality. We write A + B to mean that the agent prefers B to A, and A N B to mean that the agent is indifferent between the two alternatives, that is, considers them equally desirable or undesirable. We also write A ;5 B (B is weakly preferred to A) to mean that either A N B or A 4 B. The collection of all these comparisons constitutes the agent’s set of preferences. Rational agents choose maximally preferred alterns tives. If A = {Al,... ,&} is the set of alternatives, then Ai is a rational choice from among these alter- natives just in case Aj 5 Ai for every Aj E A. It is not required that the agent explicitly calculate or com- pute the maximality of its choices, only that it chooses alternatives that are in fact maximal according to its preferences. There may be several rational choices, or none at all if the set of preferences is inconsistent or the set of alternatives is infinite. The theory requires, as a minimum basis for ratio- nality, that strict preference is a strict partial order, indifference is an equivalence relation, indifference is consistent with strict preference, and any two alterna- tives are either indifferent or one is preferred to the other. More succinctly, weak preference is a complete preorder, or formally, for all alternatives A, B, and 6: 1. Either A 5 B or B 5 A, (completeness) 2. IfA;;5B, then B#A,and (consistency) 3.IfA~BandB~C,thenA~C. (transitivity) These rationality constraints ensure that there is al- ways at least one rational choice from any finite set of alternatives. Utility The rationality constraints imply that we may repre- sent the set of preferences by means of a numerical util- ity function u which ranks the alternatives according to degrees of desirability, so that u(A) < u(B) when- ever A 4 B and u(A) = u(B) whenever A - B. By working with utility functions instead of sets of prefer- ences, we may speak of rational choice as choosing so as to maximize utility. Any strictly increasing transfor- mation of a utility function will represent the same set of preferences, and will provide the same choices under maximization. The distinction between the (monetary or cornputs tional) costs or values of something and its utility or disutility is one of the great strengths of the theory of economic rationality, as compared with everyday ac- counting. Utility is an aggregate measure of all dimen- sions of worth, relative to the agent and the agent’s situation, and mere costliness is no guarantee of utility. In reasoning, for example, the utility of some conclu- sion usually depends on numerous variables: on what the question was, in what circumstances it was asked, on how it is to be used, on when the answer was ob- tained, and on how reliable the conclusion is. Whether deriving the conclusion is easy or hard does not affect these factors. One cannot define the notions of preference and util- ity purely in terms of beliefs and goals, for these are independent notions. Goals only state what is desired, and do not give any information about the relative mer- its of different desirable alternatives (see [Dean and Wellman, 19891). Decision theory Most work in artificial intelligence that makes use of economic rationality draws on the specific theory of sub- jective Bayesian decision theory [Savage, 19721, here- after simply called decision theory. Compared with the basic theory, decision theory adds probability measures PA which indicate the likelihood of each possible out- come for each alternative A E d. Decision theory also strengthens the notion of utility from it~l ordinal util- ity function u to a cardinal utility function U. Or- dinal utility functions use numerical values simply as ways of ranking the alternatives in a linear order. It does not make sense to say that an ordinal utility of 10 is twice as good as an ordinal utility of 5, any more than it makes sense to say that the tenth smallest per- son in a room is necessarily twice as tall as the fifth smallest. Amounts of cardinal utility, in contrast, can be added and subtracted to produce other amounts of utility. This makes it possible to combine the utili- ties foreseen in different possible outcomes of A into the expected utility o(A), defined to be the utility of all possible outcomes weighted by their probability of occurrence, or formally, ‘tA) de’ cpA(s)u(s), s (1) where the sum (more generally, an integral) ranges over all possible situations or states of nature under discus- sion. For example, if there are exactly two possible states S1 and Ss of respective utilities 5 and 7, and if the respective probabilities of these states obtaining as outcomes of alternative A are .l and .9, then the expected utility of A is just .1(5) + .9(7) = 6.8. The decision-theoretic definition of preference is then A 5 B if and only if o(A) 5 t?(B). Like the theory of preference, the axioms for decision theory involve qualitative orderings $, and ;Iu of out- comes according to relative likelihood and desirability. 1094 hVJTED TALKS AND PANELS These comparisons we also call beliefs and preferences (distinct from overall preferences or judgments). Just as cost is not the same as utility, expected utility is not the same as average cost, even when utility is a function of cost alone. Expected utility necessarily averages over utilities, not over the variables on which utilities depend. For example, bicycles designed to fit the average size rider perfectly serve an evenly mixed population of tall adults and short children only poorly. In the same way, expected computational utility need not be a function of average running time. The need for economic rationality Logical and economic notions of rationality can be used either descriptively, as giving sets of concepts and math- ematical tools with which reasoning and action may be formalized and analyzed, or normatively, as giving stan- dards of correctness to which reasoning and action must conform. Descriptively, for example, logic has been used to formalize beliefs and other representations, to determine what hypotheses are possible given the Ire* soner’s beliefs, and to determine which methods have any possibility of achieving specified goals. Similarly, economic rationality may be used descriptively to iden- tify the conditions under which one inference technique is better than another, or to explain why a technique is good or bad in specific circumstances. In particular, the theory may be applied in AI to provide a formal anal- ysis of informally developed techniques (e.g., [Langlotz et al., 19861). N ormatively construed, however, logical and economic rationality are at odds with one another over how one should think. We begin by examining the normative use of logic, which we will call logicism. Logicism The logic& school of artificial intelligence views rea- soning as a form of logical inference and seeks to con- struct general-purpose deduction systems in which ax- ioms state what is held true and goals state what is desired to be proven true (or to be achieved as the re- sult of actions). Logicism’s standard asks whether the reasoner’s beliefs are consistent and inferences sound (and sometimes whether the beliefs and inferences are complete as well). Logicism is not a complete theory of thinking by it- self, since it views the problem of how reasoning should be conducted as a pragmatic question outside the realm of the theory of thinking proper. In logic, any consis- tent set of beliefs and any sound inference is as good as any other, and the only guidance logicism seems to offer the reasoner is the rule If it’s sound, do it! Logicism ignores issues of the purpose of reasoning (other than to suppose the existence of externally posed goals) and of the value of beliefs and inferences to the reasoner, basing inferences purely on the logical form of the beliefs and goals. It ignores questions of whether the reasoner should or should not draw some inference, and whether one inference is better or more appropri- ate than another. The usual result is that purely logical reasoners make many worthless inferences, since sound worthwhile inferences may be of the same logical form as sound worthless inferences (cf. [McDermott, 19871). Making worthless inferences would not matter if res soners were not expected to arrive at conclusions and take actions within appropriate lengths of time. But most reasoning does have some temporal purpose. To reason intelligently, the reasoner must know something about the value of information and about which meth- ods for achieving goals are more likely to work than others, and must prudently manage the use of its knowl- edge and skills by taking into account its own powers, limitations, and reliability (cf. [Doyle and Patil, 19891). For example, for some questions it may be clear that no answer is possible, or that finding the answer will take too long, in which case the reasoner may conclude “I don’t know” right away. This might save enough time for the reasoner to successfully answer other questions. Alternatively, the exact answer might appear to take too long to determine and the reasoner may choose to look for an adequate approximate answer that can be found quickly. In either case, the reasoner performs better by anticipating limits and reasoning accordingly than by simply suffering limits. Simply deducing new conclusions until reasoning is terminated by reaching an answer or a deadline leads to haphazard performance, in which the reasoner succeeds on one problem but fails on seemingly identical ones that few people would dis- tinguish, with no discernible pattern to help predict success or failure. Heuristic problem solving Many non-logic&, approaches to AI also downplay is- sues of making rational choices. For example, in his characterization of the knowledge level, Newell [1982] formulates what he views as the fundamental principle of rationality as follows: “Ptinciple of rationality. If an agent has knowl- edge that one of its actions will lead to one of its goals, then the agent will select that action.” [Newell, 1982, p. 1021 (Cf. Cherniak’s [1986] principles of “minimal rational- ity.“) Newell calls this principle the “‘behavioral law that governs an agent, and permits prediction of its behavior”. Since this principle ignores comparisons among goals and among the different methods for goals, the activity it prescribes is almost as indifferent as in the logicist rule above. Many AI systems ignore issues of choice in much the way the principle suggests. Newell eventually adds auxiliary principles about how to act given multiple goals and multiple methods, and ac- knowledges that these ultimately lead to the economic DOYLE 1095 theory of rationality, but nevertheless bases his theory of knowledge on this fundamental principle alone. Newell’s principle of rationality notwithstanding, many in artificial intelligence, including Newell, have long recognized the limitations of unguided reasoning and have advanced the notion of heuristics as central to effective problem solving. Heuristics usually amount to holding beliefs or making inferences that are deemed to be useful though sometimes unsound or mistaken. In- deed, the standard guideline in heuristic problem solv- ing is the rule If it seems usefil, do it! But the notion of usefulness motivating the use of heuristics has rarely been made formal, which has brought much work on heuristic methods into disrepute among logicians, mathematicians, and formally-minded AI theorists. To many, lack of any respectable alterns tive has been the main attraction of logicism as a formal theory of thinking. Economic rationality Economic rationality provides an answer both to the problem of controlling reasoning and to the informal- ity of heuristics. In the first place, economic rational- ity is the pro Baron’s [19$5 P er standard for the knowledge level (cf. psychological perspective). It adds for- mal theories of utility and probability to the logicist formulation of belief and inference, and provides a new norm for guiding reasoning and action, namely that the reasoning activities performed should have maximal ex- pected utility among those open to the agent. It sub- sumes portions of the logicist approach, since logic can be viewed as the theory of certain beliefs, that is, beliefs of probability 1, and the axioms of probability require that certain beliefs be consistent just as in logicism.a It also decouples the notion of rationality from the no- tion of intelligence. Intelligence depends on the actual knowledge possessed and used, while rationality merely depends on possession and use of types of knowledge, namely expectations and preferences. Secondly, heuris- tics may be formalized as methods for increasing the ex- pected utility of reasoning. Since different alternatives may be open to the agent at different times in different reasoning processes, the task for artificial intelligence is to examine each of these situations and determine both the possible methods and their relative utilities. Instead of competing as normative theories, logical and economic notions of rationality fill complementary 20f course, the theory of economic rationality itself may be axiomatized as a logical theory, just like any other theory (e.g., meteorology). This does not mean that the notions of logic subsume those of economical rationality (resp. meteo- rology), since then logic supplies only the form of the theory. In contrast, logicism uses logic to supply the content of the theory of thinking. needs. Logic serves to describe the possibilities for reaG soning and action, while economics serves to prescribe choices among these. Logic plays a descriptive role in developing formulations of problems; economics plays a normative role in choosing both the problems to solve and the means of solving them. ationality in limited agents The normative use of decision theory provides a stan- dard for rationality, but one which is often unattain- able due to limitations on the available information or resources. For example, beliefs and preferences may be incomplete in that a reasoner may not know whether one circumstance is more likely than another or which it prefers, or it may not know all the consequences of its beliefs and preferences (that is, it may not be log- ically omniscient). Beliefs and preferences may be in- consistent due to conflicts among authorities or com- monsense theories, or indeterminate if they vary from situation to situation or are derived from information distributed among different frames, perspectives, or subagents (Thomason [1986] calls this “context sensi- tivity”). If beliefs and preferences cannot be revised quickly enough to account for new information, they also may exhibit inertia. Similarly, computational resources, such as the time available for making decisions or the space available for representing information, may be limited. Some non- computational resources, such as the effort or coopera- tion required of human knowledge engineers, expert in- formants, or end users may be even more limited than computational resources. In addition, some limitations stem from the reasoner’s architecture or organization it- self, since the importance of particular time and space limitations depends on the structures and operations provided by the architecture, which determine the costs and reliabilities of reasoning. While informational, resource, and organizational limitations may all be subject to change by progress in science and technology, there may also be physical and metaphysical limitations not subject to human in- fluence. The known physical limitations, for example, include the speed of light, the interference of simultaue- ous measurements, finiteness of the matter and energy available to represent information, and the inertia of matter and energy. The metaphysical limitations concern whether ratio nalit nor 19541, for example, listed a number of intuitively I is well defined or even possible in principle. Mil- desirable properties of rational decisions under uncer- tainty, each of which is satisfied by some extant the- ories, and then proved the set of these properties to be inconsistent. This suggests that there may be sev- eral essentially different intuitions underlyin tion of rationality (cf. [Touretzky et crl., 1987 ). 7 the no- There is also strong psychological evidence that expected util- ity does not capture a realistic notion of preference. 1096 hVITEiD TALKS AND PANELS Preference is not linearly additive in the probabili- ties of events as is required in equation (I), and hu- mans often exhibit preference reversals and so-called framing and anchoring effects (see [Machina, 1987; Mahneman et al., 19821). Finally, it may be that over- all utility functions simply do not exist. The existence of a utility function entails that all values can be com- bined into a single scale of desirability, and this may not always be possible [Van Frassen, 1973; Nagel, 1979; Doyle and Wellman, 19891. All these limitations mean that the rationality exhib- ited by limited agents will be somewhat different from the rationality presumed in the idealizations of decision theory. Rationality in the ideal theory considers only whether the results of choices best satisfy the agent’s preferences, while rationality in limited agents also con- siders whether the agent makes good choices in the pro- cess of deciding how to apply its efforts in reasoning toward a decision. Rationality when the costs of delib- eration are taken into account is called “Type 2” ratio- nality by Good [I9711 and “procedural” rationality by Simon [1976], as opposed to “Type 1” or “substantive” rationality in which the costs of reasoning are ignored. What is rational for one agent may be in direct conflict with what is rational for agents with different (or no) limitations. This is clearest in the play of chess, where increasing search can successively reveal new threats and new benefits, possibly leading the reasoner to vac- illate about whether some move is good or bad as the time available for searching increases. Achieving Type 2 or procedural rationality means op- timizing the overall degree of rationality by making rsb tional choices about what inferences to perform, which methods to apply, and how (or how long) to apply them. Agents that recognize their own limitations and pur- poses and guide their actions and reasoning accordingly exhibit much of what the Greeks called sophrosyne, that is, temperance or self-control. But it does not always make sense to think a lot about how to think. That is, if the point of guiding reasoning is to arrive at desired conclusions more quickly, extensive calculations about which inference to draw at each step may consume more time than they save. Rational guidance of reasoning thus requires striking a balance between control com- putations and reasoning computations. The proper bal- ance is, of course, found by choosing the amount of time to spend on control computations rationally so as to achieve the best performance. Making control decisions rationally raises the prob- lem of infinite regress, since trying to control the cost of making rational control decisions by means of addi- tional rational control decisions creates a tower of de- liberations, each one concerned with the level below (see [Doyle, 1980; Lipman, 19891). In practice, the deliberative information available at higher levels but unavailable at lower ones decreases rapidly as one as- cends the reflective tower, and most systems rely on well-chosen default choices at the first or second levels instead of long episodes of reflection upon reflection. In theory, halting deliberation at one level amounts to making the decisions for all higher levels at once, and rationality in this setting would seem to mean that the halting point can be judged rational after the fact, that is, as rational given all the expectations and preferences that result from making all these decisions at once. Rawls [1971] calls this condition reflective equilibrium. Jeffrey [1983] calls such decisions ratified decisions. Specific roles for rational choice AI has developed many apparently useful techniques for reasoning and representation, such as depth-first and A* search, dependency-directed backtracking, con- straint propagation, explanation-based learning, etc. Considerable insight might be gained by analyzing these theoretically and empirically in economic terms, both to compare alternative methods with each other, and to find the conditions under which individual tech- niques and representations increase (or decrease) ex- pected utility. Most heuristic methods are thought to increase utility, but at present most are used without any real information about their probability of useful- ness. Indeed, users are sometimes warned that one must have substantial experience with some techniques just to be able to tell when using the techniques will help rather than hurt. Can we demonstrate that these ex- pectations of heuristic value are reasonable? More gen- erally, can we make precise the assumptions about prob- abilities and utilities that underlie these judgments? We here enumerate some tasks in which rational choice would seem to play a significant role. (See the full version of this paper for a more complete discus- sion.) Substantial work has already been done on some of these, but others have seen only initial explorations. Rational approximations: Reasoners uncertain about the time available may employ approximation methods in which the expected utility or the probabil- ity of correctness of partial answers increase monoton- ically as further effort is applied. These include flexi- ble comp&ations or anytime algorithms [Horvitz, 1988; Dean and Boddy, 19881, and probably approximately comet (PAC) algorithms [Valiant, 19841. Rational assumptions and belief revision: De- fault rules may be viewed as implicitly rational de- cisions about reasoning [Doyle, 1983; Doyle, 1989; Langlotz and Shortliffe, 1989; Shoham, 19881. More generally, the reason for recording a belief in memory is the expectation that it will be useful in future reasoning and that the effort needed to rederive or replace it out- weighs the utility of the memory resources consumed by recording it. It should be removed from memory only if it is expected to undermine the efficacy of actions enough to justify the effort of removing it. Theories of conservative belief revision typically adopt principles like minimizing the number or set of DOYLE 1097 Changed belie& [Harman, 1986; GZrdenfors, 19881. But these principles do not take into account any of the reab saner’s preferences among diierent possible revisions, which means that revisions may be less rational than necessary. Rational choice would be especially valuable in the special case of backtracking, both in choosing which assumptions to abandon, and more fundamen- tally, in deciding whether analyzing and removing the inconsistency will be worth the effort. Ratio representations of inconsistent i&or- mation: Theories of inheritance and nonmonotonic logics give the appearance of consistency by means of credulous representations, in which maximal consistent subsets are used to represent (in the sense of [Doyle, 1988; Doyle, 19891) inconsistent sets of rules, and skep- tical representations, in which the intersection of all maximal consistent subsets represents the inconsistent information [Touretzky et al., 19871. Neither skepticism nor credulity is rational in all situations, and choosing an appropriate representation may be difficult [Doyle and Wellman, 19891. Rational search and inference: Russell and We- fald 119891 h ave developed explicit formulas and es- timation techniques for decision-theoretic control of A* and other search methods (see also [Etzioni, 1989; Hansson and Mayer, 19891). Horvitz [1988] and Breese and Fehling [1988] have examined control of larger-scale computational methods, while Smith [1986] has devel- oped techniques for estimating the costs of deductive inference methods. See [Dean, 19901 for a detailed sur- vey of this area. Rational learning: Indiscriminate memorization leads to clogging memory with records of dubious value [Minton, 19901. Thus it is important to make rational decisions about what to memorize, what to forget, what information to summarize, and what sum- maries to memorize, as well as how carefully or precisely to classify or categorize new objects in taxonomies and how to most efficiently organize taxonomies is very im- portant. Ratio planning: Wellman [1990] describes a planner which uses dominance relations among plans to guide the search and to isolate the fundamental trade- offi among methods, tradeoffs that remain valid even if the details of the situation change. Expected utility also provides a criterion for deciding whether to plan for contingencies. Other tasks Finding good representations for probabilities and pref- erences (see [Horvitz et al., 1988; Pearl, 1988; Wellman, 19901) would enable more rapid progress on the specific applications of rational choice discussed above. Other tasks include the following (more can be found in the full version). Automate decision formulation and analysis: The field of decision analysis [Howard and Matheson, 1984; Raiia, 19681 bears striking similarities to the more recent efforts in AI on developing expert sys- terns [Horvitz et al., 19881. Initial efforts have been made towards automating the formulation of decisions (see [Breese, 1987; Wellman, 1990]), and at providing automatic tools to assist human analysts [Holtzman, 1989; Wellman et al., 19891. Exploit economic theory: Economics has sub- stantial theories of common ways of organizing human societies or businesses that have received only initial exploration in AI, such as markets [Huberman, 19881 and more general social decision-making frameworks mixing authority relationships with decisions among equals [Minsky, 19861. AI needs to exploit these the- ories, and especially the growing work in economics on applying economic models to modeling the attitudes and mental organization of the individual agent (see, for example, [Schelling, 1980; Thaler and Shefrin, 19811). Design provably rational architectures: Much might be learned by attempting to design general ar- chitectures for rational reasoning and action that are structured so as to permit clean theoretical analyses of their fundamental properties. Reform AI education: The practice of teaching AI without prerequisites beyond elementary computer sci- ence is becoming increasingly untenable. There are now substantial theoretical foundations for portions of arti- ficial intelligence, including both the basics of modern logic and the basics of economics and decision theory. Students intending serious study of AI need exposure to these foundations through courses in elementary logic and basic decision analysis, and possibly the founda- tions of decision theory and microeconomics as well. Simply including a couple lectures in an introductory AI class is probably not adequate. 1 Conclusion Artificial intelligence has traveled far under the power of two ideas: exploiting logical inference as a method of reasoning, and using informal heuristics to direct rea- soning toward useful conclusions. We have some un- derstanding of systems based on logical inference, but making further progress toward flexible and intelligent reasoners requires understanding the capabilities and behaviors of systems guided by heuristics. Obtaining such understanding will be difllcult without ways of an- alyzing, characterizing, and judging heuristics in terms as precise as those of logic. Fortunately, the economic theory of rational choice offers formal tools for under- standing heuristics and other methods of guiding rea- soning. In fact, economic rationality appears to offer a much-needed knowledge-level standard for how one should think, rather than simply enumerating ways in which one might think. In spite of its attractions as a precise standard for reasoning and action, the theory of rational choice can- not be adopted uncritically for two reasons. First of all, 1098 bWl’ED TALKS AND PANELS it places unreasonable demands on the knowledge and inferential abilities of the reasoner. Second, it is, like logic, a purely formal theory, and says nothing specific about what reasoning is actually useful. Applying ratio- nality to reasoning and representation thus requires for- mulating realistic measures of cognitive utility, obtain- ing realistic expectations about the effects of reasoning, and developing cost-effective mechanisms for combining this information. Many fundamental and practical dif- ficulties remain, but there is no alternative to facing them. If AI is to succeed, the issues of expectations, preferences, and utility cannot be ignored, and even using a problematic theory of rationality seems more edifying than using logic and informal heuristics alone. In summary, logic and economic rationality are not competing theories, but instead are two complementary parts of the solution. Logic provides ways of analyzing meaning and possibility, while economics provides ways of analyzing utility and probability. We need to investi- gate how to integrate these theories in useful ways that recognize that meaning, possibility, utility, and probe bility must all be evaluated with respect to changing purposes and circumstances. Acknowledgments I wish to thank Ramesh Patil, Peter Szolovits, and Michael Wellman for reading drafts, Rich Thomason for lending me some of his notes, and Tom Dean, Othar Hansson, Eric Horvitz, Barton Lipman, Andrew Mayer, Stuart Russell, Joseph Schatz, and David Smith for valuable discussions. References [Baron, 19851 J. Baron. Rationality and Intelligence. Cambridge University Press, Cambridge, 1985. [Breese, 19871 J. S. Breese. Knowledge representation and inference in intelligent decision systems. Re- search Report 2, Rockwell International Science Cen- ter, Palo Alto, 1987. [Breese and Fehling, 19881 J. S. Breese and M. R. Fehling. Decision-theoretic control of problem solv- ing: Principles and architecture. Proc. Fourth Work- shop on Uncertainty in AI, pp. 30-37, 1988. [Cherniak, 19861 C. Cherniak. Minimal Rationality. MIT Press, Cambridge, 1986. [Dean, 19901 T. Dean. Decision-theoretic control of in- ference for time-critical applications. Brown Univer- sity, Providence, RI, 1990. [Dean and Boddy, 19881 T. Dean and M. Boddy. An analysis of time-dependent planning. Proc. AAAI- 88, pp. 49-54, 1988. [Dean and Wellman, 19891 T. Dean and M. P. Well- man. On the value of goals. Proc. Rochester Plan- ning Workshop: l+om Formal Systems to Practical Systems, pp. 129-140, 1989. [Debreu, 19591 G. Debreu. Theory of Value: an ax- iomatic analysis of economic equilibrium. Wiley, New York, 1959. [Doyle, 19801 J. Doyle. A model for deliberation, ac- tion, and introspection. Report AI-TR-581, MIT AI Lab, 1980. [Doyle, 19831 J. Doyle. Some theories of reasoned as- sumptions: an essay in rational psychology. TR 83- 125, Department of Computer Science, Carnegie Mel- lon University, 1983. [Doyle, 19881 J. Doyle. Artificial intelligence and ratio- nal self-government. TR CS-88-124, Carnegie-Mellon University Computer Science Department, 1988. [Doyle, 19891 J. Doyle. Constructive belief and rational represent at ion. Computational Intelligence, 5(1):1- 11, February 1989. [Doyle and Patil, 19891 J. Doyle and R. S. Patil. Two dogmas of knowledge representation: language re- strictions, taxonomic classifications, and the utility of representation services. Report TM-387b, MIT Laboratory for Computer Science, 1989. [Doyle and Welhnan, 19891 J. Doyle and M. P. Well- man. Impediments to universal preference-based de- fault theories. Proc. First Int. Conf on Principles of Knowledge Representation and Reasoning, pp. 94- 102, 1989. [Etzioni, 19891 0. Etzioni. Tractable decision-analytic control. Proc. First Int. Conf. on Principles of Knowledge Representation and Reasoning, pp. ll& 125, 1989. [Gkdenfors, 19881 P. GGrdenfors. Knowledge in FZux: Modeling the Dynamics of Epistemic States. MIT Press, Cambridge, MA, 1988. [Good, 19711 I. J. Good. The probabilistic explication of information, evidence, surprise, causality, expls nation, and utility. In V. P. Godambe and D. A. Sprott, eds., Foundations of Statistical Inference, pp. 108-127. Holt, Rinehart and Winston, Toronto, 1971. [Hansson and Mayer, 19891 0. Hansson and A. Mayer. Heuristic search as evidential reasoning. In Prvc. Fifth Workshop on Uncertainty in AI, pp. 152-161, 1989. [Harman, 19861 G. Barman. Change in View: Prin- ciples of Reasoning. MIT Press, Cambridge, MA, 1986. [Holtzman, 19891 S. Holtzman. Intelligent Decision Systems. Addison-Wesley, Reading, MA, 1989. [Horvitz, 19881 E. J. Horvitz. Reasoning under varying and uncertain resource constraints. Proc. AAAI-88, pp. 111-116, 1988. [Horvitz et al., 19881 E. J. Horvitz, J. S. Breese, and M. Henrion. Decision theory in expert systems and DOYLE 1099 artificial intelligence. J. Approximate Reasoning, 1988. [Howard and Matheson, 19841 R. A. Howard and J. E. Matheson, eds. The Principles and Applications of Decision Analysis. Strategic Decisions Group, Menlo Park, CA, 1984. [Huberman, 19881 B. A. Huberman. The Ecology of Computation. North-Holland, Amsterdam, 1988. [Jeffrey, 19831 R. C. Jeffrey. The Logic of Decision. University of Chicago Press, Chicago, 2nd ed., 1983. [Kahneman et al., 19821 D. Kahneman, P. Slavic, and A. Tversky, eds. Judgment Under Uncertainty: Heuristics and Biases. Cambridge University Press, Cambridge, 1982. [Langlotz and Shortliffe, 19891 6. P. Langlotz and E. H. Shortliffe. Logical and decision-theoretic meth- ods for planning under uncertainty. AI Magazine, lO( 1):39-47, 1989. [Langlotz et al., 19861 C. P. Langlotz, E. H. Shortliffe, and L. M. Fagan. Using decision theory to justify heuristics. Proc. AAAI-86, pp. 215-219, 1986. [Lipman, 19891 B. Lipman. How to decide how to de- cide how to . . . : Limited rationality in decisions and games. AAAI Symp. on AI and Limited Rationality, pages 77-80, 1989. [Machina, 19871 M. J. Machina. Choice under uncer- tainty: Problems solved and unsolved. J. Economic Perspectives, 1(1):121-154, Summer 1987. [McDermott, 19871 D. McDermott. A critique of pure reason. Computational Intelligence, 3:151-160, 1987. [Milnor, 19541 J. MiInor. Games against nature. In R. M. ThralI, C. H. Coombs, and R. L. Davis, eds., Decision Processes, pp. 49-59. Wiley, New York, 1954. [Minsky, 19861 M. Minsky. The Society of Mind. Si- mon and Schuster, New York, 1986. [Minton, 19901 S. Minton. Quantitative results con- cerning the utility of explanation-based learning. Ar- tificial InteZZigence, 42(2-3):363-391, 1990. [Nagel, 19791 T. Nagel. The fragmentation of value. In Mortal Questions, chapter 9. Cambridge University Press, Cambridge, 1979. [Newell, 19821 A. Newell. The knowledge level. Art@ cial Intelligence, 18( 1):87-127, 1982. [Pearl, 19881 J. Pearl. Probabilistic Reasoning in In- telligent Systems: Networks of Plausible Inference. Morgan Kaufinann, San Mateo, CA, 1988. [Raiffa, 19681 H. Raiffa. Decision Analysis: Intro- ductory Lectures on Choices Under Uncertainty. Addison-Wesley, Reading, MA, 1968. [RawIs, 19711 J. Rawls. A Theory of Justice. Harvard University Press, Cambridge, MA, 1971. [Russell and Wefald, 19891 S. Russell and E. Wefald. Principles of me&reasoning. Proc. First Int. Conf. on Principles of Knowledge Representation and Rea- soning, pp. 400-411, 1989. [Savage, 19721 L. J. Savage. The Foundations of Statis- tics. Dover Publications, New York, 2nd ed., 1972. [ScheIling, 19801 T. C. Schelling. The intimate contest for self-command. The Public Interest, 60(Summer):94-118, 1980. [Shoham, 19881 Y. Shoham. Reasoning about Change: Time and Causation fi-om the Standpoint of Artificial Intelligence. MIT Press, Cambridge, MA, 1988. [Simon, 19551 H. A. Simon. A behavioral model of rit tional choice. Quarterly J. of Economics, 69:99-118, 1955. [Simon, 19761 H. A. Simon. From substantive to proce- dural rationality. In S. J. Latsis, editor, Method and Appraisal in Economics, pp. 129-148. Cambridge University Press, 1976. [Smith, 19861 D. E. Smith. Controlling inference. Re- port STAN-B-86-1107, Department of Computer Science, Stanford University, 1986. [ThaIer and Shefrin, 19811 R. H. Thaler and H. M. She- frin. An economic theory of self-control. J. Political Economy, 89(2):392-406, 1981. [Thomason, 19861 R. H. Thomason. The context- sensitivity of belief and desire. Reasoning about Ac- tions and Plans: Proc. 1986 Workshop, pp. 341-360, 1986. [Touretzky et al., 19871 D. S. Touretzky, J . F. Horty, and R. H. Thomason. A clash of intuitions: The current state of nonmonotonic multiple inheritance systems. Proc. IJCAI-87, pp. 476482, 1987. [Valiant, 19841 L. G. Valiant. A theory of the learnable. CACM, 18(11):1134-1142, 1984. [Van Frassen, 19731 Bas 6. Van Frassen. Values and the heart’s command. J. Philosophy, LXX(l):519, 1973. [Wellman, 19901 M. P. Wellman. Formulation of T#adeofls in Planning Under Uncertainty. Pitman, London, 1990. [Welhnan et al., 19891 M. P. Wellman, M. H. Eckman, C. Fleming, S. L. Marshall, F. A. Sonnenberg, and S. G. Pauker. Automated critiquing of medical de- cision trees. Medical Decision Making, 91272-284, 1989. 1100 INVITED TALKS AND PANELS
|
1990
|
61
|
980
|
Probably Approximately Correct Learning David Haussler* haussler@sat urn.ucsc.edu Baskin Center for Computer Engineering and Information Sciences University of California, Santa Cruz, CA 95064 1 Abstract This paper surveys some recent theoretical results on the efficiency of machine learning algorithms. The main tool described is the notion of Probably Approximately Correct (PAC) 1 earning, introduced by Valiant. We de- fine this learning model and then look at sorne of the results obtained in it. We then consider some criti- cisms of the PAC model and the extensions proposed to address these criticisms. Finally, we look briefly at other models recently proposed in computational learn- ing theory. 2 Introduction It’s a dangerous thing to try to formalize an enterprise as complex and varied as machine learning so that it can be subjected to rigorous mathematical analysis. To be tractable, a formal model must be simple. Thus, in- evitahly, most people will feel that important aspects of the activity have been left out of the theory. Of course, they will be right. Therefore, it is not advisable to present a theory of machine learning as having reduced the entire field to its bare essentials. All that can be hoped for is that some aspects of the phenomenon are brought more clearly into focus using the tools of math- ematical analysis, and that perhaps a few new insights are gained. It is in this light that we wish to discuss the results obtained in the last few years in what is now called PAC (Probably Approximately Correct) learning theory [3]. Valiant introduced this theory in 1984 [42] to get computer scientists who study the computational efi- ciency of algorithms to look at learning algorithms. By taking some simplified notions from statistical pattern recognition and decision theory, and combining them with approaches from computational complexity the- ory, he came up with a notion of learning problems that are feasible, in the sense that there is a polynomial time algorithm that “solves” them, in analogy with the class P of feasible problems in standard complexity theory. *Supported by ONR grant NOOO14-86-K-0454 Valiant was successful in his efforts. Since 1984 many theoretical computer scientists and AI researchers have either obtained results in this theory, or complained about it and proposed modified theories, or both. The field of research that includes the PAC theory and its many relatives has been called computational learning theory. It is far from being a monolithic mathe- matical edifice that sits at the base of machine learning; it’s unclear whether such a theory is even possible or desirable. We argue, however, that insights have been gained from the varied work in computational learn- ing theory. The purpose of this short monograph is to survey some of this work and reveal those insights. 3 Definition of PAC Learning The intent of the PAC model is that successful learning of an unknown target concept should entail obtaining, with high probability, a hypothesis that is a good ap- proximation of it. Hence the name Probably Approxi- mately Correct. In the basic model, the instance space is assumed to be (0, l}“, the set of all possible assign- ments to n Boolean variables (or a2ltibuies) and con- cepts and hypotheses are subsets of (0, 1)“. The notion of approximation is defined by assuming that there is some probability distribution D defined on the instance space (0, l}“, giving the probability of each instance. We then let the error of a hypothesis h w.r.t. a fixed target concept c, denoted error(h) when c is clear from the context, be defined by error(h) = c D(z), rEhAc where A denotes the symmetric difference. Thus, error(h) is the probability that h and c will disagree on an instance drawn randomly according to D. The hypothesis h is a good approximation of the target con- cept c if error(h) is small. How does one obtain a good hypothesis? In the sim- plest case one does this by looking at independent ran- dom examples of the target concept c, each example consisting of an instance selected randomly according HAUSSLER 110 1 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. to D, and a label that is “+” if that instance is in the target concept c (positive example), otherwise “-” (neg- ative ezample). Thus, training and testing use the same distribution, and there is no “noise” in either phase. A learning algorithm is then a computational procedure that takes a sample of the target concept c, consisting of a sequence of independent random examples of c, and returns a hypothesis. For each n 1 1 let C,, be a set of target concepts over the instance space (0, l)“, and let C = {&),>I. Let H,, for n 2 1, and H be defined similarly. We &n de- fine PAC learnability as follows: The concept class C is PAC learnable by the hypothesis space H if there exists a polynomial time learning algorithm A and a polyno- mialp(.,.,.) sue I ld 1 tl *t f or all n 2 1, all target concepts c E Cn, all probability distributions D on the instance space (0, l)“, and all c and 6, where 0 < c, S < 1, if the algorithm A is given at least p(n, I/E, l/S) independent random examples of c drawn according to D, then with probability at least l-S, A returns a hypothesis h E H,, with error(h) 5 c. The smallest such polynomial p is called the sample complexity of the learning algorithm A. The intent of this definition is that the learning algo- rithm must process the examples in polynomial time, i.e. be computationally efficient, and must be able to produce a good approximation to the target concept with high probability using only a reasonable number of random training examples. The model is worst case in that it requires that the number of training exam- ples needed be bounded by a single fixed polynomial for all target concepts in C and all distributions D in the instance space. It follows that if we fix the number of variables n in the instance space and the confidence parameter 6, and then invert the sample complexity function to plot the error E as a function of training sample size, we do not get what is usually thought of as a learning curve for A (for this fixed confidence), but rather the upper envelope of all learning curves for A (for this fixed confidence), obtained by varying the target concept and distribution on the instance space. Needless to say, this is not a curve that can be observed experimentally. What is usually plotted experimentally is the error versus the training sample size for particular target concepts on instances chosen randomly accord- ing to a single fixed distribution on the instance space. Such a curve will lie below the curve obtained by in- verting the sample complexity. We will return to this point later. Another thing to notice about this definition is that target concepts in a concept class C may be learned by hypotheses in a different class H. This gives us .some flexibility. Two cases are of interest. The first is that C = H, i.e. the target class and hypothesis space are the same. In this case we say that C is properly PAC learnable. Imposing the requirement that the hypoth- esis be from the class C may be necessary, e.g. if it is to be included in a specific knowledge base with a specific inference engine. IIowever, as we will see, it can also make learning more difficult. The other case is when we don’t care at all about the hypothesis space H, so long as the hypotheses in H can be evaluated effi- ciently. This occurs when our only goal is accurate and computationally efficient prediction of future examples. Being able to freely choose the hypothesis space may make learning easier. If C is a concept class and there exists some hypothesis space H such that hypotheses in H can be evaluated on given instances in polynomial time and such that C is PAC learnable by H, then we will say simply that C is P/iC leanuble. There are many variants of the basic definition of PAC learnability. One important variant defines a no- tion of syntactic complexity of target concepts and, for each n > 1, further classifies each concept in C,, by its syntactic complexity. Usually the syntactic complex- ity of a concept c is taken to be the length of (number of symbols in) the shortest description of c in a fixed concept description language. In this variant of PAC learnability, the number of training examples is also allowed to grow polynomially in the syntactic complex- ity of the target concept. This variant is used when- ever the concept class is specified by a concept descrip- tion language that can represent any boolean function, for example, when discussing the learnability of DNF (Disjunctive Normal Form) formulae or decision trees. Other variants of the model let the algorithm request examples, use separate distributions for drawing posi- tive and negative examples, or use randomized (i.e. coin flipping) algorithms [25]. It can be shown that these lat- ter variants are equivalent to the model described here, in that, modulo some minor technicalities, the concept classes that are PAC learnable in one model are also PAC learnable in the other [20]. Finally, the model can easily be extended to non-Boolean attribute-based instance spaces [19] and instance spaces for structural domains such as the blocks world [18]. Instances can also be defined as strings over a finite alphabet so that the learnability of finite automata, context-free gram- mars, etc. can be investigated [34]. 4 Outline of Results for the PAC Model A number of fairly sharp results have been found for the notion of proper PAC learnability. The following sum- marizes some of these results. For precise definitions of the concept classes involved, the reader is referred to the literature cited. The negative results are based on 1102 INVITED TALKS m-i3 PANELS the complexity theoretic assumption that RF # NP “not”), the general class of multilayer perceptrons with [35]. a multiple (but fixed) number of hidden layers, and the 1. Conjunctive concepts are properly PAC learnable class of deterministic finite automata [27]. These results [42], but the class of concepts in the form of the dis- assume certain widely used cryptographic postulates in junction of two conjunctions is not properly PAC place of the (weaker) postulate that RP # NP. learnable [35], and neither is the class of existential conjunctive concepts on structural instance spaces 5 Methods for Proving PAC with two objects [18]. Learnability; Formalization of Bias 2. Linear threshold concepts (perceptrons) are prop- erly PAC learnable on both Boolean and real- valued instance spaces [ll], but the class of con- cepts in the form of the conjunction of two linear threshold concepts is not properly PAC learnable [lo]. The same holds for disjunctions and linear thresholds of linear thresholds (i.e. multilayer per- ceptrons with two hidden units). In addition, if the weights are restricted to 1 and 0 (but the thresh- old is arbitrary), then linear threshold concepts on Boolean instances spaces are not properly PAC learnable [35]. 3. The classes of I2-DNF, k-CNF, and k-decision lists are properly PAC learnable for each fixed k: [41,37], but it is unknown whether the classes of all DNF functions, all CNF functions, or all decision trees are properly PAC learnable. Most of the difficulties in proper PAC learning are due to the computational difficulty of finding a hy- pothesis in the particular form specified by the tar- get class. For example, while Boolean threshold func- tions with O-l weights are not properly PAC learnable on Hoolean instance spaces (unless RP = NIP), they are PAC learnable by general Boolean threshold func- tions. Here we have a concrete case where enlarging the hypothesis space makes the computational problem of finding a good hypothesis easier. The class of all Boolean threshold functions is simply an easier space to search than the class of Boolean threshold functions with O-l weights. Similar extended hypothesis spaces can be found for the two classes mentioned in (1.) above that are not properly PAC learnable. Hence, it turns out that these classes are PAC learnable [35,18]. How- ever, it is not known if any of the classes of DNF func- tions, CNF functions, decision trees, or multilayer per- ceptrons with two hidden units are PAC learnable. It is a much stronger result to show that a concept class is not PAC learnable than it is to show that it is not properly PAC learnable, since the former re- sult implies that the class is not PAC learnable by any reasonable hypothesis space. Nevertheless, such non- learnability results have been obtained for several im- portant concept classes, including the class of Boolean formulae (Boolean expressions using “and” “or” and All of the positive learnability results above are ob- tained by 1. showing that there is an efficient algorithm that finds a hypothesis in a particular hypothesis space that is consistent with a given sample of any con- cept in the target class and 2. that the sample is polynomial. complexity of any such algorithm By consislenl we mean that the hypothesis agrees with every example in the training sample. An algorithm that always finds such a hypothesis (when one exists) is called a consistent algorithm. As the size of the hypothesis space increases, it may become easier to find a consistent hypothesis, but it will require more random training examples to insure that this hypothesis is accurate with high probability. In the limit, when any subset of the instance space is allowed as a hypothesis, it becomes trivial to find a consistent hypothesis, but a sample size proportional to the size of the entire instance space will be required to insure that it is accurate. Hence, there is a fundamental tradeoff between the computational complexity and the sample complexity of learning. Restriction to particular hypothesis spaces of lim- ited size is one form of tkzs that has been explored to facilitate learning [32]. In addition to the cardinal- ity of the hypothesis space, a parameter known as the Vapnik-Chervonenkis (VC) dimension of the hypothe- sis space has been shown to be useful in quantifying the bias inherent in a restricted hypothesis space [19]. The VC dimension of a hypothesis space H, denoted VCdim(H), is defined to be the maximum number d of instances that can be labeled as positive and negative examples in all 2d possible ways, such that each label- ing is consistent with some hypothesis in H 114,431. Let I-I = WrJn~1 be a hypothesis space and C = {C,},>l be a target class, where C,, C_ H, for n 2 1. Then it can be shown [23] that any consistent algorithm for learning C by H will have sample complexity at most PVCdim(H,))lnf + 1,: . > HAUSSLER 1103 This improves on earlier bounds given in [ll], but may for aspecific distribution on the instance space, e.g. the still be a considerable overestimate. In terms of the car- uniform distribution on a Boolean space [8,39]. There dinality of H,, denoted IHnl, it can be shown [43,33,12] are two potential problems with this. The first is finding that the sample complexity is at most distributions that are both analyzable and indicative 5 lniH,l+l+ ( > of the distributions that arise in practice. The second . is that the bounds obtained may be very sensitive to the particular distribution analyzed, and not be very For most hypothesis spaces on Boolean domains, the reliable if the actual distribution is slightly different. second bound gives the better bound. However, linear A more refined, Bayesian extension of the PAC model threshold functions are a notable exception, since the is explored in [13]. Using the Bayesian approach in- VC dimension of this class is linear in n, while the log- volves assuming a prior distribution over possible tar- arithm of its cardinality is quadratic in n [II]. Most get concepts as well as training instances. Given these hypothesis spaces on real-valued attributes are infinite, distributions, the average error of the hypothesis as a so only the first bound is applicable. functidn of training sample size, and even as a function of the particular training sample, can be defined. Also, 6 Criticisms of the PAC Model 1 - 6 confidence intervals like those in the PAC model can be defined as well. Experiments with this model The two criticisms most often leveled at the PAC model on small learning problems are encouraging, but fur- by AI researchers interested in empirical machine learn- ther work needs to be done on sensitivity analysis, and ing are on simplifying the calculations so that larger problems can be analysed. This work, and the other distribution 1. the worst-case emphasis in the model makes it un- specific learning work, provides an increasingly impor- usable in practice [13,39] and tant counterpart to PAC theory. 2. the notions of target concepts and noise-free train- ing data are too restrictive in practice [1,9]. We take these in turn. There are two aspects of the worst case nature of the PAC model that are at issue. One is the use of the worst case model to measure the computational complexity of the learning algorithm, the other is the definition of the sample complexity as the worst case number of random examples needed over all target concepts in the target class and all distributions on the instance space. We address only the latter issue. As pointed out above, the worst case definition of sample complexity means that even if we could calcu- late the sample complexity of a given algorithm exactly, we would still expect it to overestimate the typical error of the hypothesis produced as a function of the training set size on any particular target concept and particular distribution on the instance space. This is compounded by the fact that we usually cannot calculate the sam- ple complexity of a given algorithm exactly even when it is a relatively simple consistent algorithm. Instead we are forced to fall back on the upper bounds on the sample complexity that hold for any consistent algo- rithm, given in the previous section, which themselves may contain overblown constants. The upshot of this is that the basic PAC theory is not good for predicting learning curves. Some variants of the PAC model come closer, however. One simple variant is to make it distribution specific, i.e. define and analyze the sample complexity of a learning algorithm Another variant of the PAC model designed to ad- dress these issues is the “probability of mistake” model explored in 1211. This is a worst case model that was designed specifically to help understand some of the issues in incremental learning. Instead of looking at sample complexity as defined above, the measure of performance here is the probability that the learning algorithm incorrectly guesses the label of the tth train- ing example in a sequence of t random examples. Of course, the algorithm is allowed to update its hypoth- esis after each new training example is processed, so as t grows, we expect the probability of a mistake on example t to decrease. For a fixed target concept and a fixed distribution on the instance space, it is easy to see that the probability of a mistake on example t is the same as the average error of the hypothesis produced by the algorithm from t - 1 random training examples. llence, the probability of mistake on example t is ex- actly what is plotted on empirical learning curves that plot error versus sample size and average several runs of the learning algorithm for each sample size. In [21], some comparisons are made between the worst case probability of mistake on the tth example (over all possible target concepts and distributions on the training examples) and the probability of mistake on the tth example when the target concept is selected at random according to a prior distribution on the tar- get class and the examples are drawn at random from a certain fixed distribution (a Bayesian approach). The former we will call the worst case probability of mistake and the latter we will call the average case probability of 1104 hVITFiD TALKS AND PANELS mistake. The results can be summarized as follows. Let c = {GJn~l be a concept class and dn = VCdim(C,) for all n 2 1. First, for any concept class C and any consistent algorithm for C using hypothesis space C, the worst case probability of mistake on example t is at most O((dJt)ln(t/d,,)), where t > d,,. Furthermore, there are particular consistent algorithms and concept classes where the worst case probability of mistake on example t is at least R((d,,/t)ln(t/d,)), hence this is the best that can be said in general of arbitrary consistent algo- rithms. Second, for any concept class C there exists a learn- ing algorithm for C (not necessarily consistent or com- putationally efficient) with worst case probability of mistake on example t at most d,/(t - 1). (An extra factor of 2 appears in the bound in [21]. This can be re- moved.) In addition, any learning algorithm for C must have worst case probability of mistake on example t at least Q(d,/t). Furthermore, there are particular con- cept classes C, particular prior probability distributions on the concepts in these classes, and particular distribu- tions on the instance spaces of these classes, such that the average case probability of mistake on example t is at least sZ(d,/t) for any learning algorithm. These results show two interesting things. First, cer- tain learning algorithms perform better than arbitrary consistent learning algorithms in the worst case and average case, therefore, even in this restricted setting there is definitely more to learning than just finding any consistent hypothesis in an appropriately biased hypothesis space. Second, the worst case is not always much worse than the average case. Some recent exper- iments in learning perceptrons and multilayer percep- trons have shown that in many cases d,/t is a rather good predictor of actual (i.e. average case) learning curves for backpropagation on synthetic random data [7,40]. lfowever, it is still often an overestimate on natural data [38], and in other domains such as Ikarn- ing conjunctive concepts on a uniform distribution [39]. Here the distribution (and algorithm) specific aspects of the learning situation must also be taken into ac- count. Thus, in general we concur that extensions of the PAC model are required to explain learning curves that occur in practice. However, no amount of experi- mentation or distribution specific theory can replace the security provided by a distribution independent bound. The second criticism of the PAC model is that the assumptions of well-defined target concepts and noise- free training data are unrealistic in practice. This is cer- tainly true. However, it should be pointed out that the computational hardness results for learning described above, having been established for the simple noise-free case, must also hold for the more general case. The PAC model has the advantage of allowing us to state these negative results simply and in their strongest form. Nevertheless, the positive learnability results have to be strengthened before they can be applicable in prac- tice, and some extensions of the PAC model are needed for this purpose. Many have been proposed (see e.g. h241). Since the definitions of target concepts, random ex- amples and hypothesis error in the PAC model are just simplified versions of standard definitions from statisti- cal pattern recognition and decision theory, one reason- able thing to do is to go back to these well-established fields and use the more general definitions that they have developed. First, instead of using the probabil- ity of misclassification as the only measure of error, a general loss /unction can be defined that for every pair consisting of a guessed value and an actual value of the classification, gives a non-negative real number indicat- ing a “cost” charged for that particular guess given that particular actual value. Then the error of a hypothesis can be replaced by the average loss of the hypothesis on a random example. If the loss is 1 if the guess is wrong and 0 if it is right (discrete loss), we get the PAC no- tion of error as a special case. However, using a more general loss function we can also choose to make false positives more expensive than false negatives or vice- versa, which can be useful. The use of a loss function also allows us to handle cases where there are more than two possible values of the classification. This includes the problem of learning real-valued functions, where we might choose to use (guess--actd( or (guess--actual)2 as loss functions. Second, instead of assuming that the examples are generated by selecting a target concept and then gen- erating random instances with labels agreeing with this target concept, we might assume that for each random instance, there is also some randomness in its label. Thus, each instance will have a particular probability of being drawn and, given that instance, each possi- ble classification value will have a particular probabil- ity of occurring. This whole random process can be described as making independent random draws from a single joint probability distribution on the set of all possible labeled instances. Target concepts with at- tribute noise, classification noise, or both kinds of noise can be modeled in this way. The target concept, the noise, and the distribution on the instance space are all bundled into one joint probability measure on la- beled examples. The goal of learning is then to find a hypothesis that minimizes the average loss when the examples are drawn at random according to this joint distribution. The PAC model, disregarding computational com- plexity considerations, can be viewed as a special case HAUSSLER 1105 of this set-up using the discrete loss function, but with the added twist that learning performance is measured with respect to the worst case over all joint distribu- tions in which the entire probability measure is concen- trated on a set of examples that are consistent with a single target concept of a particular type. Hence, in the PAC case it is possible to get arbitrarily close to zero loss by finding closer and closer approximations to this underlying target concept. This is not possible in the general case, but one can still ask how close the hy- pothesis produced by the learning algorithm comes to the performance of the best possible hypothesis in the hypothesis space. For an unbiased hypothesis space, the latter is known as Bayes optimal classifier [15]. Some recent PAC research has used this more general framework. By using the quadratic loss function men- tioned above in place of the discrete loss, Kearns and Shapire investigate the problem of efficiently learning a real-valued regression function that gives the proba- bility of a “+” classification for each instance [26]. In [17] it is shown how the VC dimension and related tools, originally developed by Vapnik, Chervonenkis, and oth- ers for this type of analysis, can be applied to the study of learning in neural networks. Here no restrictions whatsoever are placed on the joint probability distri- bution governing the generation of examples, i.e. the notion of a target concept or target class is eliminated entirely. 7 Other Theoretical Learning Models A number of other theoretical approaches to machine learning are flourishing in recent computational learn- ing theory work. One of these is the total mistake bound model [29]. Here an arbitrary sequence of examples of an unknown target concept is fed to the learning al- gorithm, and after seeing each instance the algorithm must predict the label of that instance. This is an in- cremental learning model like the probability of mistake model described above, however here it is not assumed that the instances are drawn at random, and the mea- sure of learning performance is the total number of mis- takes in prediction in the worst case over all sequences of training examples (arbitrarily long) of all target con- cepts in the target class. We will call this latter quan- tity the (worst case) mistake bound of the learning al- gorithm. Of interest is the case when there exists a polynomial time learning algorithm for a concept class C = {&},,>I with a worst case mistake bound for tar- get concepts in Cn that is polynomial in n. As in the PAC model, mistake bounds can also be allowed to de- pend on the syntactic complexity of the target concept. The perceptron algorithm for learning linear thresh- old functions in the Boolean domain is a good exam- ple of a learning algorithm with a worst case mistake bound. This bound comes directly from the bound on the number of updates given in the perceptron con- vergence theorem (see e.g. [15]). The worst case mis- take bound of the perceptron algorithm is polynomial (and at least linear) in the number n of Boolean at- tributes when the target concepts are conjunctions, dis- junctions, or any concept expressible with O-l weights and an arbitrary threshold [Ifi]. A variant of the per- ceptron learning algorithm with multiplicative instead of additive weight updates was developed that has a sig- nificantly improved mistake bound for target concepts with small syntactic complexity [29]. The performance of this algorithm has also been extensively analysed in the case when some of the examples may be mislabeled [no]. It can be shown that if there is a polynomial time learning algorithm for a target class C with a polyno- mial worst case mistake bound, then C is PAC learn- able. General methods for converting a learning al- gorithm with a good worst case mistake bound into a I’AC learning algorithm with a low sample complexity are given in [28]. IIence, the total mistake bound model is actually not unrelated to the PAC model. Another fascinating transformation of learning algo- rithms is given by the weighted mujorily method [31]. This is a method of combining several incremental learning algorithms into a single incremental learning algorithm that is more powerful and more robust than any of the component algorithms. The idea is simple. All the component learning algorithms are run in paral- lel on the same sequence of training examples. For each example, each algorithm makes a prediction and these predictions are combined by a weighted voting scheme to determine the overall prediction of the “master” al- gorithm. After receiving feedback on its prediction, the master algorithm adjusts the voting weights for each of the component algorithms, increasing the weights of those that made the correct prediction, and decreasing the weights of those that guessed wrong, in each case by a multiplicative factor. It can be shown that this rnethod of combining learning algorithms produces a master algorithm with a worst case mistake bound that approaches the best worst case mistake bound of any of the component learning algorithms, and that the result- ing algorithm is very robust with regard to mislabeled examples [31]. The weighted majority method can also be used in conjunction with the conversion mentioned above to design better PAC learning algorithms. Both the PAC and total mistake bound models can be extended significantly by allowing learning alga rithms to perform experiments or make queries to a teacher during learning [3]. The simplest type of query is a membership query, in which the learning algorithm 1106 INVITEDTALKSANDPANEL~ proposes an instance in the instance space and then is [3] D. Angluin. Queries and concept learning. Ma- told whether or not this instance is a member of the tar- chine Learning, 2:319-342, 1988. get concept. The ability to make membership queries can greatly enhance the ability of an algorithm to ef- [4] D. Angluin, M. Frazier, and L. Pitt. Learning con- ficiently learn the target concept in both the mistake junctions of horn clauses. 1990. manuscript. bound and PAC models. It has been shown that there are polynomial time algorithms that make polynomially many membership queries and have polynomial worst case mistake bounds for learning 1. monotone DNF concepts (Disjunctive Normal Form with no negated variables) [3], 2. /i-formulae (Boolean formulae in which each vari- able appears at most once) 151, 3. deterministic finite automata [2], and [5] D. Angluin, L. Hellerstein, and M. Karpinski. Learning read-once formulas with queries. JACM, 1990. to appear. [S] D. Angluin and P. Laird. Learning from noisy ex- amples. Machine Learning, 2(4):343-370, 1988. [7] E. Baum. When are k-nearest neighbor and [S] G. M. Benedek and A. Itai. Learnability by fixed back propogation accurate for feasible sized sets of examples. distributions. In Proc. 1988 Workshop on Comp. In Snowbird conference on Neu- Learning Theory, pages 80-90, Morgan Kaufmann, ral Networks for Computing, 1990. unpublished manuscript. San Mateo, CA, 1988. bership queries and has a polynomial worst case mis- 4. Horn sentences (propositional PROLOG pro- take bound into a PAC learning algorithm, as long as kF-9 PI- the PAC algorithm is also allowed to make member- ship queries. In addition, there is a general method for convert- Hence, all of the concept classes listed above are PAC learnable when membership queries are allowed. This contrasts with the evidence from crypto- ing an efficient learning algorithm that makes mem- graphic assumptions that classes (2) and (3) above are not PAC learnable from random examples alone [27]. [9] F. Bergadano and L. Saitta. On the error prob- abilty of boolean concept descriptions. In Pro- ceedings of the 1989 European Working Session on Learning, pages 25-35, 1989. [lo] A. Blum and R. L. Rivest. Training a three-neuron neural net is NP-Complete. In Proceedings of the 1988 Workshop on Computational Learning The- ory, pages 9-18, published by Morgan Kaufmann, San Mateo, CA, 1988. 8 Conclusion In this brief survey we were able to cover only a small fraction of the results that have been obtained recently in computational learning theory. For a glimpse at some of these further results we refer the reader to [22,36]. However, we hope that we have at least convinced the reader that the insights provided by this line of inves- tigation, such as those about the difficulty of searching hypothesis spaces, the notion of bias and its effect on re- quired training size, the effectiveness of majority voting methods, and the usefulness of actively making queries during learning, have made this effort worthwhile. [ll] A. Blumer, A. Ehrenfeucht, D. Haussler, and M. K. Warmuth. Learnability and the Vapnik- Chervonenkis dimension. JA CM, 36(4):929-965, 1989. [12] A. Blumer, A. Ehrenfeucht, D. Haussler, and M. K. Warmuth. Occam’s razor. Information Pro- cessing Leiters, 24:377-380, 1987. [13] W. Buntine. A Theory of Learning Classification Rules. PhD thesis, University of Technology, Syd- ney, 1990. Forthcoming. References [14] T. M. Cover. Geometrical and statistical prop- erties of systems of linear inequalities with appli- [l] J. Amsterdam. The Valiant Learning Model: Ez- tensions and AssessmenZ. Master’s thesis, MIT cations in pattern recognition. IEEE Trans. on Electronic Computers, EC-14:326-334, 1965. Department of Electrical Engineering and Com- [15] R. 0. Duda and P. E. Hart. Pattern Classificaiion puter Science, Jan. 1988. and Scene Analysis. Wiley, 1973. [2] D. Angluin. Learning regular sets from queries and [16] S. E. Hampson and D. J. Volper. Linear function counterexamples. Information and Compuiation, neurons: structure and training. Biol. Cybern., 7587-106, Nov. 1987. 53:203-217, 1986. HAUSSLER 1107 [17] D. Haussler. Generalizing the PAC model for neu- [30] N. Littlestone. Mistake Bounds and Logarithmic ral net and other learning applications. Injorma- Linear-threshold Learning Algorithms. PhD thesis, tion and Computation, 1990. to appear. University of Calif., Santa Cruz, 1989. [18] D. Haussler. Learning conjunctive concepts in [31] N. Littlestone and M. K. Warmuth. The weighted structural domains. Machine Learning, 4:7-40, majority algorithm. Iu 30th Annual IEEE Sym- 1989. posium on Foundations of Computer Science, [19] D. Haussler. Quantifying inductive bias: AI learn- - - pages 256-26 1, 1989. ing algorithms and Valiant’s learning framework. [32] T. Mitchell. The need for biases in learning gener- Artificial Intelligence, 36:177-221, 1988. alizations. Technical Report CBM-TR-117, Rut- [20] D. Haussler, M. Kearns, N. Littlestone, and M. K. Warmuth. Equivalence of models for poly- nomial learnability. Information and Computa- tion, 1990. to appear. [21] D. Haussler, N. Littlcstone, and M. War- muth. Predicting 0,1-functions on randomly drawn points. In Proceedings of the 29th Annual Symposium on the Foundations of Computer Sci- ence, pages 100-109, IEEE, 1988. [22] D. Haussler and L. Pitt, editors. Proceedings of the 1988 Workshop on Computational Learning The- ory. Morgan Kaufmann, San Mateo, CA, 1988. [23] M. A. John Sh awe-Taylor and N. Biggs. Dounding Sample Size with the Vapnik-Chervonenkis Dimen- sion. Technical Report CSD-‘I’R-618, University of London, Surrey, England, 1989. [24] M. Kearns and M. Li. Learning in the presence of malicious errors. In 20th ACM Symposium on Theory of Computing, pages 267-279, Chicago, 1988. [25] M. Kearns, M. Li, L. Pitt, and L. Valiant. On the learnability of boolean formulae. In 19th ACM Symposium on Theory of Computing, pages 285- 295, New York, 1987. 1261 M. Kearns and R. Schapire. Efficient distribution- free learning of probabilistic concepts. 1990. manuscript. [27] M. Kearns and L. Valiant. Cryptographic limita tions on learning boolean formulae and finite au- tomata. In 2lst ACM Symposium on Theory of Computing, pages 433-444, Seattle, WA, 1989. gers University, New Brunswick, NJ, 1980. [33] B. K. N t a ara’an. On learning sets and functions. J Machine Learning, 4(l), 1989. [34] L. Pitt. Inductive Inference, DFAs, and Compu- tational Complexity. Technical Report UIUCDCS- R-89-1530, U. Illinois at Urbana-Champaign, 1989. [35] L. Pitt and L. Valiant. Computational limitations on learning from examples. J. ACM, 35(4):965- 984, 1988. [36] R. Rivest, D. Haussler, and M. Warmuth, editors. Proceedirzgs of the 1989 Workshop on Computa- tional Learning Theory. Morgan Kaufmann, San Mateo, CA, 1989. [37] R. L. Rivest. Learning decision lists. Machine Learning, 2:229-246, 1987. [38] D. Rumelhart. 1990. personal communication. [39] W. Sarrett and M. Pazzani. Average case analysis of empirical and explanation-bused learning algo- rithms. Technical Report 89-35, UC Irvine, 1989. [40] 6. Tesauro and D. Cohn. Experimental tests of statistical learning theories. In Snowbird confer- ence 07b Neural Networks for Computing, 1990. un- published manuscript. [41] L. G. Valiant. L earning disjunctions of conjunc- tions. In hoc. 9th IJCAI, pages 560-6, Los Ange- les, August 1985. [42] L. G. Valiant. A theory of the learnable. Comm. ACM, 27(11):1134-42, 1984. [28] N. Littlestone. From on-line to batch learning. In Proceedings of the 2nd Workshop on Computa- tional Learning Theory, pages 269-284, published by Morgan Kaufmann, 1989. [43] V. N. Vapnik. Estimation of Dependences Dased on Empirical Data. Springer-Verlag, New York, 1982. [29] N. Littlestone. Learning quickly when irrelevant attributes abound: a new linear-threshold algo- rithm. Machine Learning, 2:285-318, 1988. 1108 hVITED TALKS AND PANELS
|
1990
|
62
|
981
|
Truth Maintenance David McAllester* Massachusetts Institute of Technology Artificial Intelligence Laboratory 545 Technology Square Cambridge, Massachusetts 02139, USA Abstract General purpose truth maintenance systems have re- ceived considerable attention in the past few years. This paper discusses the functionality of truth maintenance systems and compares various existing algorithms. Ap- plications and directions for future research are also dis- cussed. Introduction In 1978 Jon Doyle wrote a masters thesis at the MIT AI Laboratory entitled “Truth Maintenance Systems for Problem Solving” [Doyle, 19791. In this thesis Doyle described an independent module called a truth main- tenance system, or TMS, which maintained beliefs for general problem solving systems. In the twelve years since the appearance of Doyle’s TMS a large body of literature has accumulated on truth maintenance. The seminal idea appears not to have been any particular technical mechanism but rather the general concept of an independent module for truth (or belief) mainte- nance. All truth maintenance systems manipulate propo- sition symbols and relationships between proposition symbols. I will use the term “Boolean constraint? to mean any Boolean formula built from proposition symbols and standard Boolean connectives such as --+ (implication), A (conjunction), and 1 (negation). A monotonic TMS manipulates proposition symbols and Boolean constraints. A non-monotonic TMS also al- lows for “heuristic” or “non-monotonic” relationships between proposition symbols such as “whenever I? is true $ is likely” or “if P is true then, unless there is evidence to the contrary, assume Q”. While the seman- tics of monotonic truth maintenance systems are quite clear, the semantics of non-monotonic systems has been a focus of considerable research over the past decade *This work was supported in part by National Science Foundation contract 1R.L8819624 and in part by the Ad- vanced Research Projects Agency of the Department of De- fense under Office of Naval Research contract NOOOlP86-k- 0124. and has lead to the development of non-monotonic log- its. Non-monotonic logic is closely related to belief func- tions, certainty factors, and defaults in type hierarchies. A good introduction to the issues surrounding belief and certainty can be found in [Pearl, 19881. A dis- cussion of defaults in type hierarchies can be found in [Touretzky, 19861. Some approaches to the theory of non-monotonic logic can be found in [McCarthy, 19861, [Konolige, 19871, [Gelfond and Lifschitz, 19881, and [Gelfond, 19891. Having briefly mentioned non-monotonic logic, the remainder of this paper is dedicated exclusively to monotonic truth maintenance systems. There are sev- eral reasons for this. First, most of the development in truth maintenance algorithms, and de Kleer’s ATMS al- gorithm in particular [de Kleer, 1986a], concern mono tonic systems. Second, most practical applications of truth maintenance systems involve monotonic systems (e.g., qualitative simulation, fault diagnosis, and ap- plications to search). Furthermore, monotonic truth maintenance systems provide a solid foundation upon which to build other kinds of systems - algorithms for monotonic systems can usually be used in non- monotonic systems but the converse does not hold. This survey begins with a specification of the func- tionality of monotonic truth maintenance systems. This specification is presented as a set of functions that can be used as a generic interface to most existing systems. Each interface function has a clean non-computational specification. After presenting the interface, I present various implementations. This is followed by a discus- sion of applications of truth maintenance systems in solving search problems. Finally, there is a brief dis- cussion of current research in the construction of more powerful algorithms . The Generic TMS Interface A monotonic TMS is a general facility for manipulating Boolean constraints on proposition symbols. For exam- ple, in automobile diagnosis we might want to enforce the constraint that if the spark plug is sparking then MCALLESTER 1109 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. the rotor is turning. This constraint has the form P 3 Q where P and Q are proposition symbols that an outside observer can interpret as representations of the statements “the spark plug is sparking” and “the ro- tor is turning” respectively. Given a set of propositions about automobile engines, a set of constraints on those propositions (such as the above implication), and a set of observations about a particular automobile, a TMS can be used to ask questions about the consequences of the observations. I will describe the functionality of a (monotonic) TMS by specifying four generic interface functions. A TMS stores a set of Boolean constraints (Boolean for- mulas). Intuitively, one is only interested in truth as- signments that satisfy this stored set of constraints. Be- cause these constraints do not appear explicitly as ar- guments in most of the interface functions, I will call them “internal constraints”. The first interface func- tion, add-constraint, adds a constraint to the internal constraint set. Once a constraint has been added it can never be removed. The remaining interface functions manipulate literals - a literal is either a proposition symbol or the negation of a proposition symbol. The second interface function, follows-from?, takes two ar- guments, a literal 0 and a set of literals El called a premise set. An application (follows-Corn? @ E) can return yes, uo, or unknown. If (follows-from? 0 C) returns yes then the TMS guarantees that iD follows from the premise set C and the internal constraints. If (follows-ficom? 0 C) returns no then the TMS guar- antees that @ does not follow, i.e., there exists an inter- pretation satisfying both the internal constraints and C in which Qr is false. If the TMS is unable to determine if 0 follows, then (follows-from? @ C) returns un- known. In an automobile diagnosis system the internal constraints consist of facts true of all automobiles, e.g., “if the spark plug is sparking then the rotor is turning”, and premise sets consist of observations about particu- lar automobiles. The third and fourth interface functions compute jue tifications. If the TMS can determine that iB follows from the internal constraints and a premise set C, then one can ask the TMS to justify this fact, i.e., to pro- duce a “proof” of 0. There are two interface func- tions used to generate such proofs: justifying-liter& and justifjhg-constraints. Both of these functions take two arguments - a literal and a premise set from which that literal can be derived. If QE, is derivable from C and the internal constraints, then (justifyiug- literals 0 EC) returns a set of literals and (justifyiug- constraints 0 C) returns a subset of the internal con- straints satisfying the following two conditions. o Qi follows from the literals in (justifying-literah 0 Xc) and the constraints in (justifjhg-constraints 0 C). 8 (follows-from ? 9 I=) returns yes for each literal \E in (justifying-literals 0 C). Suppose the internal constraint set includes the con- straints P -) Q, (P A + s. Most truth maintenance systems are able to derive S from these constraints and the premise set {P, W}. Most truth maintenance systems also provide the fol- lowing justifications relative to these constraints and premises. derived justifying justi@hg literal literals constraints : jl$bpJ -+ 2) Q &ii For any given set of internal constraints, premise set, and formula S that can be derived from the given con- straints and premises, the justification functions can be used to generate a “justification tree” for S. The root of the tree is the formula S and at each node of the tree the function justifying-literals can be used to get chil- dren nodes until one reaches members of the premise set. The justifications are required to be non-circular, i.e., if Q appears in the justification tree rooted at P, then P must not appear in the justification tree rooted at Q. Note that all of the justifications in the above table are “local” in the sense that, for each justification, there is only a single justifying constraint. In general, we do not require that justifications be local in this sense. However, virtually all TMS implementations are local in that every derived literal can be justified in terms of other literal8 and a single internal constraint. Contradiction Handling The above specification of a generic TMS interface al- lows for contradictory information to be given to the TMS. Most truth maintenance systems have some way of informing the user that a given premise set is in- consistent with the internal constraints. This can be done by adding a special proposition symbol called con- tradiction. If the TMS is able to determine that a given premise set C contradicts the internal constraints, then (bbllows-from? contradiction C) returns yes. Furthermore, if (follows-firom? contradiction C) returns yes then (justifying-literal8 contradiction C) and (justifjliug-constraints contradiction C) re- turn a set of literal8 and a set of constraints respectively that underlie the contradiction. The justification func- tions can be used to construct a justification tree whose leaves are literals in C. This allows the contradiction to be “blamed” on a subset of X3. BCP plementations Suppose that we wish to compute a value for an appli- cation (follows-from ? @ C). This can be done with a conceptually simple procedure known as Boolean con- straint propagation (BCP). Consider a network whose 1110 INVITEZDTALKSANDPANELS nodes are the proposition symbols that appear either in the premise set C or in the internal constraint set. Each Boolean constraint can be viewed as a connec- tion, or “link” between nodes in the network. Each node (proposition symbol) can be labeled with one of three possible labels: true , faIse, or unknown. Ini- tially all nodes are labeled unknown. To compute the consequences of a particular premise set C one assigns the label true or f&e to each proposition symbol in the set of literals C depending on whether that symbol appears positively or negatively in C. New labels are then computed based on local propagation - whenever a new truth label follows from existing labels and some single internal constraint, that new label is added to the network and propagation continues. If a set of derived labels ever violates one of the internal constraints, then the special proposition contradiction is labeled true. During the propagation process each newly derived 1s be1 can be associated with a “justification”, i.e., a data structure that records the labels and constraint used in the derivation. If every constraint is a clause, i.e., a dis- junction of literals, then this propagation process can be run to completion in time linear in the total size of the set of constraints [McAllester, 19801. To answer a query of the form (follows-from ? 0 C) one simply runs the Boolean constraint propagation process starting with the labels in C and determines if a label is derived for the proposition symbol in the literal 0 - if a label has been derived for the proposition symbol, and that la- bel has the same sign as the sign of the literal a, then follows-from? returns yes, otherwise follows-from? returns unknown. Boolean constraint propagation is not logically com- plete. For example, consider the constraints P + Q and -P + Q. The literal Q follows from these con- straints but does not follow from either constraint in- dividually. BCP will not deduce Q even though Q fol- lows from the constraints. The incompleteness of BCP represents a compromise between functionality and ef- ficiency. Boolean constraint propagation runs in linear time in the total size of the constraint set (for clausal constraints). Boolean entailment, however, is coNP- complete and no efficient algorithm can be expected. Incremental Context Switching. Often consecutive queries to a truth maintenance system have very sim- ilar premise sets. For example, a user might first ask for (follows-from 1 i[, C) and then ask for (follows- from? 0 C’) h w ere C and C’ are large premise sets that differ on only a few literals. The propagation used to answer the first query can be used to make answering the second query more efficient. This can be done with “incremental premise retraction” and “in- cremental premise addition” [Doyle, 19791, [McAllester, 19801. Incremental addition and retraction algorithms allow the set of proposition labels to be incrementally switched from the labeling generated by C to the label- ing generated by 2. is An alternative to unrestricted incremental retraction to store the current premise set on a premise stack. When a new premise is-pushed on to the-premise stack incremental Boolean constraint propagation is used to add new truth labels. When a premise is popped, a simple “undo-list” can be used to remove all labels that were added when that premise was pushed. Now consider two consecutive queries of the form (follows- from? 0 C) and (follows-from? 4[, C’). The labeling for the first query is incrementally computed by pushing the elements of C onto the premise stack. To compute the labeling for 2 one first pops back to a premise set that is a subset of C’ and then pushes those premises in C’ that are not already present. The premise-stack implementation and the unre- stricted incremental implementation provide the same generic interface functionality - at the level of the generic interface one can ask about any premise set at any time. Whether the premise-stack implementa tion is more efficient than the unrestricted incremen- tal retraction implementation depends on the statistics of consecutive queries. For individual retractions the premise stack implementation is considerably more effi- cient. However, the premise stack implementation may require more retractions and assertions to make a tran- sition between two labeling states. In any application where a set of truth assignments is being systematically explored, such as most algorithms for solving constraint satisfaction problems, the premise stack implementit tion is more efficient. The premise stack implemen- tation is also more efficient if most premises are static (are always included) and only a few premises are being changed - one can arrange for the changing premises to migrate to the top of the stack so that only small retractions and additions are done when switching be- tween contexts. ATMS-like Implementations I will initially describe de Kleer’s ATMS [de Kleer, 1986a] as an alternative implementation of the generic TMS interface and compare the ATMS implementation with the BCP implementation. For many applications the only difference between the ATMS and BCP im- plementations is there relative efficiency as implemen- tations of the generic interface. However, the ATMS is more than just an alternative implementation of the same interface - there are certain additional interface functions that can be easily implemented on top of the ATMS algorithms but not on top of BCP. The addi- tional functionality of the ATMS is discussed below. Universal Propagation. Like the BCP implemen- tation, the ATMS implementation of the generic in- terface operates by propagating labels on a network whose nodes are propositions connected by Boolean constraints.’ However, in the ATMS implementation ‘The ATMS described here is a recent version [de Kleer, MCALLESTER 1111 the propagation process is independent of any particu- lar premise set - a single “universal propagation pr* cess” precomputes all answers to all possible queries [de Kleer, 19$6a].2 To make the universal propagation pro- cess more efficient, the user can declare an *priori set of “possible premises”. Each possible premise is a lit- eral and every premise set in every query to the ATMS must be a subset of the set of possible premises. In the ATMS algorithm, a label is a set of premise sets. Each proposition in the network has both a true and a false label. If proposition P has a true label con- sisting of premise sets Cl, . . . C,, then for each ES we must have that P logically follows from Ci and the in- ternal constraints. An analogous statement holds for the premise sets in the false label of P. The premise sets can be propagated through the constraints. For example, if Cl is a premise set that is a member of the true label of P, E:a is a premise set in the true label of Q, and (P A Q) + R is an internal constraint, then the premise set Cl U I=2 can be added to the true label for R. The propagation process is initialized by inserting a singleton premise set into the label for each possible premise. For example, if P is a possible premise, then the singleton premise set {P} is inserted into the true label for P. After the universal propagation has been performed one can answer a query of the form (follows- from? P C) by checking to see if there exists a premise set on the true label of P that is a subset of C. An anal- ogous test can be made for queries involving negative literals. The total number of propagations, and the total num- ber of premise sets generated, can be reduced by im- posing two “filters” on the premise sets in labels. First, the premise sets must be %onsister#. Most obviously, no premise set can contain both a proposition and its negation. In addition, however, one can use the special proposition contradiction to make a stronger consis- tency filter. No premise set in any label, other than the true label for contradiction, can contain as a sub- set any premise set that is a member of the label for contradiction. The second filter involves~ the notion of subsumption. If I31 and C2 are two premise sets in the same label, and Cl is a proper subset of C2, then the label C2 can be removed. The ATMS runs the sin- gle universal propagation process to completion using these two filters to prune the premise sets in labels. Universal Propagation and BCP. The notation I’,C I- ncp @ will be used to indicate that 0 can be derived from internal constraint set I’ and premise set C using Boolean constraint propagation. In the fol- lowing discussion the symbol I’ will be used freely to denote a fixed but arbitrary internal constraint set. A support for a given proposition symbol P is a premise set C satisfying the following three conditions: or,c FBCPP 0 r, C YBCp contradiction o There is no proper subset C’ of C such that w bp p. After the universal ATMS propagation procedure has run to completion, the premise sets in the true label of P are precisely the supports for P. This implies that the ATMS implements exactly the same behavior as the BCP-TMS.3 ATMS Complexity. The ATMS and BCP implemen- tations generate exactly the same behavior at the level of the generic interface. Furthermore, the BCP imple- mentation is guaranteed to require at most linear space and linear time per query. On the other hand, because a given label can contain an exponential number of dif- ferent minimal premise sets, the ATMS implement it tion can require both exponential time and exponential space to answer a single query. This worst case behav- ior can be easily realized even in the case where the Boolean constraints are Horn clauses without implies tion cycles. Why would anyone propose an algorithm that is ex- ponential in both time and space as an improvement on an algorithm that is linear in both? The answer seems to be that the exponential ATMS algorithm has better performance in some applications. In cases where the label sets remain small query answering using pre-computed label sets is more efficient than context- switching in the BCP implementation. As problem size grows, however, the exponential cost of the universal ATMS propagation begins to dominate the potential savings at query time. Another reason for preferring the ATMS algorithm involves the additional fimction- ality discussed in the next section. Additional Functionality of the ATM% The ATMS universal propagation algorithm computes the minimal sets of assumptions necessary to derive a given formula. This feature is useful in device diag- nosis where one wants to find the minimal number of P ossible faults that explains a f iven observed behavior de Kleer and Williams, 19871 de Kleer and Williams, 19891. In fault diagnosis, however, one is often inter- ested in premise sets that contain only a single fault. 199Ob]. de Kl eer’s original ATMS only allowed Horn clause constraints and only allowed positive literals iu queries. Ex- cept for these restrictions, the original ATMS is identical to the system described here. ‘A similar universal propagation process for truth main- tenance systems was developed independently by Drew Mc- Dermott [McDermott, 19831. 31t should be n oted that the ATMS described here is dif- ferent from the clause management system described in [de Kleer and Beiter, 19871. The clause management system, or CMS, requires logical completeness. If constraints are re- stricted to Horn clauses and queries are restricted to positive literals, as in the original ATMS, BCP is logically complete and the CMS and BCP specifications are equivalent. 1112 &VITFzD TALKS AND PANELS Under the single-fault assumption the full generality of the ATMS is not needed. values =I,...=~, we introduce the proposition symbols “X=x& . . . “X = z,,” and the constraints “X = xp v “X = x239 v . . l v u⌧ = ⌧nn Applications to Search It has often been said that truth maintenance systems are useful in controlling search [Doyle, 19791, [de Kleer, 19SSa]. Because “search” is a loosely defined term, this claim is difllcult to evaluate in general. Rather than attempt to evaluate the general claim, I will consider a more restricted class of search problems known as constraint satisfaction problems (CSPs). A CSP consists of a set of variables, where each vari- able is associated with a finite set of possible values, plus a set of constraints. Each constraint consists of two of the given variables plus an enumeration of “allowed” pairs of values for those variables. An assignment of values to all the variables of a CSP is said to satisfy a given constraint if the pair of values assigned to the variables of the constraint is one of the allowed pairs of the constraint. A solution to a CSP is an assignment of values to the variables of the CSP that satisfies all of the constraints of the CSP. It is easy to show that determining the existence of a solutions to CSPs is NP- complete. This definition of a CSP can be generalized to allow constraints of more than two variables without changing the essentials of the analysis given below. There is a large literature on algorithms for effi- ciently finding solutions to constraint satisfaction prob- lems. The best introduction to the general theoreti- cal framework is still perhaps Knuth’s paper on meth- ods of evaluating the running time of backtrack search [Knuth, 19751. Knuth introduces the notion of a consis- tency test to be applied at each node of the backtrack search tree. Today there is a wide variety of possi- ble consistency tests, the most effective of which are based on some form of constraint propagation [Mack- worth, 19771, [Pearl and Korf, 19871. In addition to constraint-propagation based consistency tests, there are a variety of heuristics for selecting which variable to instantiate next and which value for that variable to try first [Haralick and Elliot, 19801, [Freuder, 19851, [Dechter and Pearl, 19881, [Zabih, 19901. Furthermore, there is variety of mechanisms for “backjumping”, i.e., jumping back to earlier choice points because a “depen- dency analysis” shows that intervening choices where not involved in the cause of failure [Stallman and Suss- man, 19771, [Gaschnig, 19791, [Bruynooghe and Pereira, 19841. Research on algorithms for solving CSPs contin- ues to be active. Translating CSPs into Boolean Clauses. It is pos- sible to use a TMS as the foundation of a procedure for solving arbitrary CSPs. Truth maintenance techniques operate on Boolean constraints rather than CSPs as defined above. To use a TMS in solving a CSP one can translate the CSP into a set of Boolean constraints. More specifically, for each variable X in C, with possible and Ai<j(l”X = Xin V l”X = Xjn)e These constraints form a set of disjunctive clauses that together are equivalent to the statement that exactly one of the propositions “X = zi” is true. Now there are two simple ways of translating the constraints of the CSP into constraints on these proposition symbols. The first translation I will cdl the negative translation. Consider a constraint on variables X and Y. For each pair <x, g> of possible values for X and Y respectively that is not an allowed pair of the constraint, we add the clause l”X = 2” V 1W = y”. If C is a CSP (as defined above), I will let N(C) be the set of Boolean clauses generated from the variables and constraints of C in this way. Thesecond translation I will call the positive translation. Again consider a constraint on variables X and Y. For each possible value v of Y, let ~1,. . . 21: be the set of all possible values of X such that <xi, y> is an allowed pair of the constraint. For each possible value g of Y we add the constraint l”X = Xl” A . . . A YUX = qn --b 1”Y = f. This implication is equivalent to a clause, i.e., a disjunc- tion of literals. For any constraint satisfaction problem C, I will let P(C) d enote the positive translation of C into a set of disjunctive clauses. It is interesting to note that the size of the translation N(C) is governed by the number of incompatible pairs of values in the constraints while the size of P(C) is governed by the number of allowed pairs of values in the constraints. Using a TMS to solve a CSP. Given a constraint satisfaction problem C it is possible to give either the Boolean constraint set N(C) or the constraint set P(C) to a TMS. A simple backtrack program can then be written to search the assignments of values to CSP vari- ables where a partial assignment is encoded as a TMS premise sets of the form “Xi = 2. sn . . . uX~ = 2) j”. A filter can be imposed on the back&&k search by &king the TMS, at each node in the search tree, if the spe- cial node contradiction is derivable from the current partial assignment. If the positive translation has been used to convert the CSP to Boolean constraints (and the TMS simulates BCP) then this filter is equivalent to classical arc consistency.4 If the negative transla- tion has been used (and the TMS simulates BCP) then this filter is weaker, but more efficient than, classical 4The linear time of the BCP algorithm on clausal con- straints implies that arc consistency can be achieved in time proportional to the number of consistent pairs of values for constrained pairs of variables. Thus BCP provides an alter- native algorithm for achieving the arc-consistency complex- ity bound given in [Mohr and Henderson, 19861. MCALLESTER 1113 arc consistency. The filter that results from BCP ap- plied to the negative translation might be called BCP consistency. In addition to providing powerful search filters, the justification facility of a TMS provides a mechanism for performing a certain form of backjumping known as dependency directed backtracking [Stallman and Suss- man, 19771. When a failure occurs in the search process one can use the justification mechanisms to uncover the subset of the current premise set that was used to derive the special proposition contradiction. This allows a new constraint to be installed called a “nogoodn which states that at least one of these premises must be false. This new derived constraint allows BCP to make more inferences than were possible with the old constraints and the consistency filter on the remaining search be- comes stronger. Dependency directed backtracking, and backjumping in general, are particularly useful when, for some rea- son, a poor choice has been made in selecting the or- der of the variables to be instantiated in the backtrack search process. To my knowledge, no one has estab- lished the pragmatic value of backjumping in a search that already does careful variable ordering and con- straint propagation based consistency testing. Because of the potential for generating an exponential number of additional derived constraints, dependency directed backtracking is a particularly expensive form of back- jumping. The ATMS universal propagation algorithm can also be applied to the Boolean translation of a CSP [de Kleer, 19891. In addition to clauses generated by the translation, one can specify each assumption of the form “X = xn as a possible premise. An additional proposition called all-variables-assigned can be in- troduced such that BCP can derive the proposition ail- variables-assigned if and only if a proposition of the form “X = xn has been derived for each variable X. Af- ter running the ATMS universal propagation procedure the set of all solutions to the CSP is contained in the true label of the proposition all-variables-assigned. Note that all variable assignments that violate the given constraints are automatically removed by the consis- tency filtration of premise sets in the universal ATMS algorithm. In this way, the universal ATMS propags tion procedure yields [de Kleer, 19841. “choices without backtracking” The most efficient and natural justification structure for the proposition all-variables-assigned will cause the ATMS universal propagation procedure to simu- late a backtrack search with a fixed order in which the variables are considered. However, the backtrack search will be done in space-intensive breadth-first man- ner rather than a space-efficient depth-first manner. In general, space-intensive breadth-first searches are con- sidered to be less efficient (in both time and space) than space-efficient depth-first searches [Pearl and Korf, 19871. To my knowledge, the ATMS has never been shown to be more time efficient for enumerating solu- tions to a CSP than classical backtracking approaches. Truth maintenance systems may be useful as a gen- eral method of solving CSPs because they provide a general and efficient mechanism for constraint props gation based consistency testing of partial assignments. The other ways in which TMS technology might be ap- plied to CSPs, i.e., dependency directed backtracking and ATMS universal propagation, appear to be of lim- ited value. The ATMS universal propagation proce- dure is probably more appropriate for finding minimal premise sets satisfying some condition. General Problem Solving Truth maintenance systems have often been viewed as an integral part of “AI languages”, i.e., knowledge rep- resentation and programming languages that are de- signed to allow for the rapid development of expert systems or general problem solvers [de Kleer, 1986c], [de Kleer, 1986b]. A recent, and highly successful, in- corporation of the constraint propagation aspects of truth maintenance into a general purpose language is Van Hentenryck’s version of Prolog called Chip (for constraint handling in Prolog) [Van Hentenryck, 19891. Van Hentenryck’s version of Prolog is only tenuously related to the literature on truth maintenance systems. However, it seems that languages that combine auto- matic backtracking with automatic constraint propaga tion will be a major competitor with TMS-based AI languages in the future. I will use the term ‘Van Hentenryck language” as a general term for any programming language that combines automatic backtracking with automatic con- straint propagation. Rather than describe Van Hen- tenryck’s version of Prolog, I will describe a Van Hen- tenryck dialect of Lisp called Chil (for constraint han- dling in Lisp). Actually, Chil is built on Scheme, a dialect of Lisp that provides call-with-current- continuation. Automatic backtracking can be incor- porated into Scheme by adding two new primitives: either and fail. The special form either takes two arguments and non-deterministically returns the value of one of them .’ The procedure fail causes the com- putation to be restarted from the most recent non- deterministic choice. Given Scheme’s implementation of call-with-current-continuation, the “primitives” either and til can be efficiently implemented in about ten additional lines of code. Other standard Prolog primitives, such as cut and bag-of are implemented with similar ease. The procedures either and fail provide automatic backtracking and allow the concise expression of a large variety of backtrack search programs. Automatic con- ‘either is a version of McCarthy’s amb [McCarthy, 19631. The word either reads more naturally. 1114 INVITED TALKS AND PANELS straint propagation is added with three more proce- dures: make-domain-object, add-constraint, and force-value. The procedure make-domain-object takes one argument which is a list of “possible val- ues” and returns a data structure that represents a CSP variable with the given set of possible values. The procedure add-constraint takes three arguments: two domain objects (objects returned by make-domaiu- object) and an ordinary Scheme predicate of two argu- ments. The procedure add-constraint installs a con- straint stating that the simultaneous values of the two domain objects must satisfy the given predicate. Fi- nally, the procedure force-value takes a domain ob- ject and non-deterministically assigns that domain ob- ject one of its possible values. The procedure force- value automatically invokes constraint propagation. If constraint propagation does not result in a constraint violation then force-value returns the selected value. Otherwise backtracking occurs. Using these primitives, a constraint propagation version of the n-queens prob- lem can be expressed as follows. (define (n-queens n) (let ((queen-variables (map (lambda (ignore) (make-domain (nurbers-between 1 n))) (numbers-between 1 n)))) (do-from-to (i 1 (- n 1)) (do-from-to (j (+ i 1) n) (add-constraint (nth i queen-variables) (nth j queen-variables) (lambda (vi v2) (and (not (= v2 ~1)) (not (- v2 (+ vi (- j i)))) (not (- v2 (- vi (- j i))))))))) (rap force-value queen-variables))) The above program uses numbers-between, do- from-to, and nth which are not Scheme primitives, but which are easily defined. Given the above proce- dure, the expression (bag-of (n-queens 8)) evaluates to a list of all 92 solutions of the &queens problem. Fur- thermore, the search process specified by the above pro cedure uses constraint propagation based consistency testing at each node of the search tree. Van Hentenryck has shown that the addition of automatic constraint propagation to languages with automatic backtracking can drastically improve the performance of a wide VJ+ riety of useful backtrack search programs. Strengthening Constraint Propagation Constraint propagation appears to be of central im- portance in search-based problem solving. One way of attempting to discover more powerful constraint propagation techniques is to study the relationship be- tween constraint propagation and inference. Constraint propagation is a form of inference - values for unas- signed variables are deduced from the values already assigned. The relationship between inference and con- straint propagation can be made explicit by character- izing constraint propagation processes in terms of infer- ence rules. Boolean constraint propagation can be de- fined in terms of a certain (incomplete) set of inference rules for Boolean logic [McAllester, 19891. Van Hen- tenryck also defines the various constraint propagation techniques used in Chip in terms of rules of inference. In fact, virtually any form of constraint propagation can be defined in terms of rules of inference. Constraint propagation inference rules are unusual, as rules of inference, in that it is possible to determine in polynomial time whether a given statement can be derivedfiomgivenpremises. In other words,constraint propagation inference rules generate a polynomial time decidable inference relation - such relations will be called truciable. Although every constraint propagation technique corresponds to a tractable inference relation, there are many tractable inference relations that do not correspond to any standard constraint propagation technique. For example, the inference rules that de- fine BCP can be combined with the standard inference rules for equality, including the substitution of equals for equals, and the resulting rule set is still polynomial time decidable [McAllester, 19891. In [McAllester et al., 19891 it is argued that the power of tractable rule sets for first order inference is sensitive to the syntax in which formulas are expressed - an alternative syn- tax based on taxonomic relationships between classes yields a more powerful tractable rule set. In [McAllester and Givan, 19891 it is argued that the power of the tractable rule set can be further improved if the syntax is based on the specifier structure of natural language noun phrases under Montague semantics. This obser- vation provides a functional justification for some of the syntactic features of natural language. In [McAllester, 19901 a general theory of tractable rule sets is presented and an algorithm is given for automatically recognizing tractability in rule sets. Inference is closely related to constraint propagation and constraint propagation is clearly important in im- proving search efficiency. People seem to use inference to drastically reduce the amount of search required in problem solving. It seems possible that some of the power of human inference is based on generalizations of constraint propagation - powerful yet tractable in- ference relations computed in a fraction of a second. Perhaps there is still hope for the construction of efll- cient general purpose inference mechanisms. References [Bruynooghe and Pereira, 19841 hi. Bruynooghe and L. M. Pereira. Deduction revision by intelligent backtracking. In J. A. Can&II, editor, Implementations of Prolog, pages 196-215. ERis Horwood, 1984. [Dechter and Pearl, 19881 R. Dechter and J. Pearl. Network-based heuristics for constraint-satisfaction prob- lems. Artificial Intelligence, 34:1-38, 1988. [de Kieer and Williams, 19871 J. de Kleer and B. Williams. Diagnosing multiple faults. Artificial Intelligence, 32:97- 130,1987. [de KIeer and Williams, 19891 J. de Kleer and B. Williams. Diagnosis with behavioral modes. In Proceeding8 IJCAI- 89, pages 104-109, 1989. [de Kleer and Reiter, 19871 J. de Kleer and R. Reiter. Foundations of assumption-based truth maintenance sys- tems. In AAA187, pages 183-188, 1987. [de Kleer, 19841 J. de Kleer. Choices without backtracking. In Proceedings of AAAI-84, pages 79-85, 1984. [de Kleer, 1986a] J. de Kleer. An assumption-based tms. Artificial Intelligence, 28~127-162, 1986. [de Kleer, 1986b] J. de Kleer. Extending the atms. Artificial Intelligence, 28:163-196, 1986. [de Kleer, 1986c] J. de Kleer. Problem solving with the atms. Artificial Intelligence, 28:197-224, 1986. [de Kleer, 19891 de Kleer, J., A comparison of ATMS and CSP techniques, Proceedings of the Eleventh Interna- tional Joint Conference on Artificial Intelligence, Detroit, MI (August 1989). [de Kleer, 199Oa] de Kleer, J., Exploiting locality in the ATMS, AAAI-90, Boston, Mass. (August 1990). [de Kleer, 199Ob] J. de Kleer. A practical clause manage- ment system. SSL Paper P88-00140, Xerox PARC, sub- mitted for publication. [Doyle, 19791 J. Doyle. A truth maintenance system. Arti- ficial Intelligence, 12~231-272, 1979. [Freuder, 19851 E. C. Freuder. A Sufficient Condition for Backtrack-Bounded Search. J. A CM, 32(4):755-761,198s. [Gaschnig, 19791 J. Gaschnig. Performance measurement and analysis of certain search algorithms. Report, CMU, 1979. [Gelfond and Lifschitz, 19881 M. Gelfond and V. Lifschitr. The stable model semantics for logic programming. In Logic Progrumming: Proceedings of the Fifth Interna- tional Conference and Symposium, pages 1070-1080, 1988. [Gelfond, 19891 M. Gelfond. Autoepistemic logic and the formalization of common sense reasoning: Preliminary report. In Non-Monotonic Reasoning: 2nd International Workshop (Lecture Notes in Artificial Intelligence 346), pages 176-189. Springer-Verlag, 1989. [Haralick and Elliot, 19801 R. Haralick and G. Elliot. In- creasing tree search efficiency for constraint satisfaction problems. Artificial Intelligence, 14:263-313, 1980. [Van Hentenryck, 19891 P. Van Hentenryck. Constraint Sat- isfaction in Logic Progmmming. MIT Press, 1989. [Knnth, 19751 D. Knnth. Estimating the efficiency of backtrack programs. Mathematics of Computation, 29(129):121-136, January 1975. [Konoige, 19871 K. KonoIige. On the relationship between default theories and non-monotonic logic. Artificial Intel- ligence, 35:343-382, 1987. [Mackworth, 19771 A. M k ac worth. Consistency in networks of relations. Artificial Intelligence, 8(1):99-181, 1977. [McAIIester and Givan, 19891 D. McABester and R. Givan. Natural language syntax and first order inference. Memo 1176, MIT Artificial Intelligence Laboratory, October 1989. [McARester et al., 19891 D. McARester, R. Givan, and T. Fatima. Taxonomic syntax for first order inference. In Proceedings of the First International Conference on Principles of Knowledge Repmsentation and Reasoning, pages 289-300,1989. [McARester, 19801 D. McAIlester. An outlook on truth maintenance. Memo 551, MIT Artificial Intelligence Lab- oratory, August 1980. [McAIlester, 19891 D. McAlIester. Ontic: A Knowledge Representation System for Mathematics. MIT Press, 1989. [McAIlester, 19901 D. McAIlester. Automatic recognition of tractability in inference relations. Memo 1215, MIT Arti- ficial Intelligence Laboratory, February 1990. [McCarthy, 19631 J. McCarthy. A basis for a mathematical theory of computation. In P. Braffort and D. Hirschberg, editors, Computer Progmmming and Formal Systems. North-Holland, 1963. [McCarthy, 19861 J. McCarthy. Applications of circum- scription to formalizing common sense reasoning. Arti- ficial Intelligence, 26:89-118, 1986. [McDermott, 19831 D. McDermott. Contexts and data de- pendencies: a synthesis. IEEE Tmnsaction on Pattern Anally& and Machine Intelligence, 5(3):237-246, 1983. [Mohr and Henderson, 19861 R. Mohr and T. Henderson. Arc and path consistency revisited. Artificial Intelligence, 28(2):225-233, 1986. [Pearl and Korf, 19871 J. Pearl and R. Korf. Search tech- niques. Ann. Rev. Comut. Sci., 2:451467, 1987. [Pearl, 19881 J. Pearl. Probabilistic Rezoning in Intelligent &&ems: Networks of Plausible Inference. Morgan Kauf- mann, 1988. [Stallman and Sussman, 19771 R. StaiIman and G. Suss- man. Forward reasoning and dependency directed back- tracking in a system for computer-aided circuit analysis. Artificial Intelligence, 9:135-196, 1977. [Touretzky, 19861 D. T ouretzky. The Mathematics of Inher- itance &stems. Morgan Kaufmaun, 1986. [Zabih, 19901 R. Zabih, Some applications of graph band- width to constraint satisfaction problems. AAAI-90. 1116 hVITED TALKS AND PANELS
|
1990
|
63
|
982
|
Massively Parallel AI* David L. Waltz Thinking Machines Corporation 245 First Street Cambridge, MA 02142-1214 Abstract Most AI researchers would, I believe, agree that truly intelligent machines (i.e. machines on a par with humans) will require at least four orders of magnitude more power and memory than are available on any machine today [Schwartz 1988, Waltz 19881. There is now widespread agreement in the supercomputing community that by the year 2000 all supercomputers (defined as the most powerful machines available at a given time) will be massively parallel [Fox 19901. Yet relatively little thought has been given in AI as to how to utilize such machines. With few exceptions, AI’s attention has been limited to workstations, minicomputers and PCs. Today’s massively parallel machines present AI with a golden opportunity to make an impact, especially in the world of commercial applications. The most striking near-term opportunity is in the marriage of research on very large databases with case-based and memory-based AI. Moreover, such applications are steps on a path that can lead eventually to a class of truly intelligent systems. Economic Inevitability of Massive Parallelism The performance of serial computers is limited by the “van Neumann bottleneck,” (the serial path used to move instructions and data between memory and the CPU) and by I/G limitations. Over the next ten years the use of fast technologies (ECL, GaAs, etc.) and further miniaturization might gain a performance factor of five, cleverer caching and instruction prefetch a factor of two, and the use of multiple functional units yet another factor of four, bringing the fastest uniprocessors (now at less than one GFlops) to perhaps 40 GFlops. Compiler technologies could allow as many as 16 such processors to be ganged together, yielding perhaps as much as 640 GFlops in total. The price would be high: very dense chips of exotic materials packed close together present daunting cooling and packaging problems. An extrapolation of current trends (supercomputers cost about $1OO,OOO/MFlops in 1977, and about $SOOO/ MFlops in 1990) suggests that such a machine would cost about $500 million in the year 2000 (about $8OO/MFlops). In contrast, massively parallel machines (e.g. the Connection Machine(R) CM-2) use PC/workstation technologies, and boast per-computational-unit costs Brandeis University Computer Science Department Waltham, MA 02254 similar to those of these small machines: on the order of $lOOQ/MFlops in 1990. The largest massively parallel machines already exceed the power of serial super- computers: the 65,536 processor CM-2 is realistically capable of speeds on the order of 5 GFlops (with a 28 GFlops peak). DARPA has targeted a massively parallel TeraOps (one trillion operations/second) machine by 1995, and the cost is expected to be less than $100 million ($lOO/MFlops). By the year 2000 it should be possible to build massively parallel TeraOps machines for $10 million ($lO/MFlops - two orders of magnitude cheaper than could be done with serial technologies). A Brief History of Massively Parallel AI The Connection Machine system was originally designed to handle AI tasks, such as NETL-like marker-passing over semantic networks, and low-level computer vision [Fahlman 1979, Hillis 19851. *Lisp, an extension of CommonLisp, was the first high-level language for the CM and its first front-end computer was a Symbolics 3600. A number of the early CMs were purchased by AI labs following its introduction in 1986, and some early work was done along the lines envisioned by Hillis: for example, CIS, a marker-passing parallel expert system, with one (instantiated) rule per processor [Blelloch 19861, and a system for computing stereo disparity from a pair of images, using the Mar-r-Poggio method [Marr and Poggio 1976, Drumheller 19861. (See waltz & Stanfill 19881 for a summary of several early AI projects.) However, it is clear in retrospect that there was not much of an AI market for $50,000 Lisp machines, let alone for $1 million (and up) Connection Machine systems performing these sorts of applications. There still is not a market for very large expert systems, in part because it is difficult to build a very large expert system (Blelloch’s CIS system contained 100,000 artificially generated rules on a CM-l with about 8 MBytes of memory; a current *This work was supported in part by the Defense Advanced Research Projects Agency, administered by the U.S. Air Force Office of Scientific Research under contract #F49620-88-C-0058 and is also funded in part by the United States Bureau of the Census. WALTZ 1117 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. CM-2 with 8 GBytes of memory could store 100 million rules!). Likewise, there was not (and still is not) a market for high volume low-level image processing (although the new Land&s may eventually create one). Fortunately for Thinking Machines, the CM-2, with its floating point option (using up to 2000 Weitek chips), proved to be an excellent match for a wide range of scientific problems: finite element models, operations on large matrices, fluid flow and aerodynamics models, n- body problems (e.g. galactic collisions), interactive scientific visualization, models using cellular automata, seismic data processing, signal processing, etc. Most of Thinking Machines’ sales growth -- 50% per year over the past four years -- has been fueled by sales for these types of applications. But the AI dream is still valid. Recent research using novel AI paradigms on real customer problems and real customer databases have identified some great opportunities. The Large-Scale Commercial AI Opportunity Data is being generated faster than it can be digested. Very large (>lOO GByte) databases are becoming common. Such databases contain valuable information on customer credit and buying behavior; many forms of text: public text, including books, newspapers and news wires, financial journals, technical industry publications, scientific journals, and annual reports; and private text, such as studies, memos, manuals, proposals, documentation; visually oriented materials, including maps, schematics, plans and blueprints, as well as fast- expanding video archives; and much more. Until recently mainframe computers, with their extensive existing software libraries, have been the only choice for those who own and/or wish to mine such databases. But mainframes are pitifully slow and at the same time very expensive, and the software available for database tasks has been quite primitive because answering even primitive questions takes too long. Massively parallel machines offer large storage capacity1 and high I/O rates, using parallel disk arrays and multiple wide- word I/O channels. The total CM-2 I/O capacity is currently 200 MBytes/second, limited by the disk rates.2 This means that an entire 100 GByte database can be streamed into the CM-2 in 500 seconds. We estimate based on preliminary but realistic tests, that we can achieve a speedups of at least an order of magnitude over identical data selection operations on a mainframe on a CM-2 costing only a fraction of the price. [Stanfill, forthcoming]. This kind of performance opens the possibility for changing the fundamental nature of an organization’s use of a database -- from a weekly to a daily batch run, or from batch to interactive -- and also opens the opportunity for applying dramatically more complex and intelligent processing to each database item than can otherwise be imagined today. In the next several sections, I outline the algorithms and performance for several commercially important applications. Text-based Intelligent Systems For most of its history, AI has been concerned with “toy problems.” Scaling up presents difficulties: At the two extremes of the spectrum, one can hand-code (as in CYC [Lenat et al. 1986]), or one can use methods to automatically build NLP systems. To date there have been very few practical applications of natural language processing, and this fact has dampened the enthusiasm of funding agencies and companies that support research in this area. Fortunately, there are signs that this situation can be improved by strategically merging AI/NLP and Information Retrieval (IR) technologies. This offers novel opportunities both for learning research, and for building systems that have immediate practical value. A series of experiments and discoveries led researchers at Thinking Machines, most notably Craig Stanfill and Brewster Kahle, to devise a document retrieval system that works in parallel on the Connection Machine [Stanfill & Kahle 1986; Stanfill 19881. The resulting system, marketed as DowQuestcR) by Dow Jones has been in commercial use since January 1989. DowQuest provides a high quality search through a clever interface that can be used effectively by a computer-naive person after only about 5 minutes of training. The basic idea is this: A database of documents (e.g. news articles, abstracts, books, etc.) is distributed to each of the 65,536 processors of a CM-2 (if documents are 2K bytes long, each processor equipped with large memory can hold about 256 compressed documents or 16 million total!). The user types a few words (a question, description, or list of terms will do) and a carriage return; the terms are broadcast to all the processors in parallel along with a numerical “weight” indicating the importance of each term? The search portion of this operation is analogous to the following situation: imagine a stadium with 65,536 people, each with one document and a pocket ‘A single current Connection Machine CM-2 can be equipped with up to eight I/O channels, each of which can have 16 drops, allowing 15 DataVault disk arrays of up to 80 GBytes each, for a total storage capacity of 8x15~80 GBytes = 9,600 GBytes! 2The CM-2 itself can handle more than 400 MBytes/second. 3Term weights are assigned automatically by a program that pre-processes the text and updates the database. The number of occurrences of each term is saved, and weights computed proportional to the negative log of the probability of occurrences of each term. 1118 INVITEDTALK~ANDPA~L~ calculator; an announcer reads each search term followed by a number (representing the importance of a term (the rarer a term, the higher its weight) and each person whose document contains the term adds the score to the calculator. After all terms are read, the persons with the highest scored documents present themselves. (This would be hard in the stadium analogy). (To match the real situation, we would actually need either 16 million people, or 256 documents and 256 calculators per person.) The headlines for the documents with the highest total scores are then sent to the user. The user can view the text of each of these documents by clicking a mouse while pointing to the headline. When a user sees a document (or paragraph of a document) that answers his/her request, the user can mark the document “good” by pointing and clicking the mouse. The system collects all the terms from all the documents marked “good” along with all the initial words the user typed, and repeats the search process described above, but now using all these terms. Each search requires less than a second, even on databases up to 10 GBytes. This method, called “relevance feedback” [Salton 19721, generally produces a substantially better search than is possible with Boolean search systems [Blair $ Maron 19861. DowQuest DowQuest uses the method above, with enough memory so that a 1 GByte database is permanently stored. The 16 documents with the best scores are returned to the user, who can look at the full text (stored on a disk on the front end server) and can mark any document (or paragraph of a document) as “relevant”. DowQuest has about six months worth of articles from nearly 300 different sources: Wall Street Journal, Washington Post Barrons, the business sections of about 100 U.S. newspapers, Fortune. Forbes, and other magazines, and a number of trade publications (e.g. Byte). Ninety-nine percent of all searches take under 1.5 seconds, including front end time. CM time for 100 terms is about 170 msec. The system also parses input text, creates a new surrogate database, and updates the database while the system is operating on-line. We have recently outlined algorithms that allow allow interactive access to 1 TeraByte (I,OOO,OOO MBytes) of text [Stanfill, Thau & Waltz 19891. For reference, the Library of Congress probably contains on the order of 40 Terabytes of text. New Text Opportunities This system suggests interesting opportunities for exploiting natural language processing results: Adding NLP It is highly desirable to add natural language pre- and post-processing to the existing system, to improve its performance, and to extend its capabilities. For example, we are building recognizers that can find, label, and store lists of terms that refer to company names, geographic locations, names of persons, etc. Ultimately, this will help users to ask and obtain answers to questions that would be very difficult to phrase as Boolean queries. For example, “Earnings reports for New England utility companies” would expand to “Earnings reports for Maine, New Hampshire, Vermont, Massachusetts, Connecticut, Rhode Island, utilities, power companies, electric companies, power, light...“. In addition, natural language processing systems will allow us to post-process retrieved documents, to filter out irrelevant articles, and thus improve the performance of the system from the user’s point of view. Adaptive Systems More intelligent processing could be applied to the users’ queries; the system could keep track of user patterns and interests, and adapt itself to be easier to use or even to volunteer information it thinks the user is interested in. WAIS (Wide Area Information Server) We are building a version of this system to seamlessly search an organization’s local data as well as remote (e.g. Dow Jones) databasas. This system will allow organizations to locate and reuse proposals, reports and studies, find (by matching biographies) appropriate people for various tasks, and generally allow each person to locate any text - personal, corporate or public -- with a single search. ypertext The same methods that let us locate relevant articles can allow us to automatically build hypertext systems for text distributed on CD-ROMs. These could be generated much more quickly and inexpensively than is possible with hand-building. Automatic Generation OP NL Systems The retrieval system itself can be adapted to extract phrase, sentence and paragraph “templates” or patterns in order to aid the building of recognizers for particular topics or for types of stories. Such processing can provide empirical data on language usage that would be very difficult to find or invent any other way, leading to “dictionaries” of multi-word and multi-sentence language patterns and to FRUMP-like systems [DeJong 19821 with broad subject coverage. Other related research, using dictionaries or thesauruses, has become popular in recent years. Some striking successes have been achieved by Ken Church and coworkers at AT&T Bell Laboratories [Church 1988, Ejerhed 19881 using the augmented “Brown Corpus” [Kucera & Francis 19821. The Brown Corpus consists of one million words of text, chosen to represent a wide range of text types and styles (newspaper and magazine articles, books on history economics, etc.). It was “augmented” by Kucera and Francis by assigning each word in the corpus to one of about 450 classes, covering standard grammatical categories (noun, verb, adjective) but also including substantially finer distinctions (e.g. WALTZ 1119 noun-agent of sentence; verb-complements of particular types). Church collected statistics on the probabilities that various words would follow particular other word (or category) combinations. This system has been used to judge the most likely categories for words in novel text taken from news-wire sources. Success rates for Church’s system are in the range of 98-99%, much higher than for the best syntactic parsers (in the range of 33% [Salton 19881). All these current lines of research emphasize breadth of coverage, rather than depth of coverage, and are thus complimentary to the goals of traditional AI-NL processing research. All present attractive alternatives to hand-coding benat et al. 1986). And all can be used to accelerate the research into deep processing. The most attractive part of this effort is that our systems are immediately useful, and thus can pay for the research on their own augmentation. I believe these general approaches will have great importance in the ultimate story of the achieving of truly intelligent systems. emory-Based easoning Methods broadly analogous to the text-search algorithms can be used to build “memory-based reasoning” systems to aid in decision-making. These systems perform like artificial neural nets [Rumelhart & McClelland 1986; Waltz & Feldman 19881 or ID3-like learning systems [Quinlan 19881. In memory-based reasoning (MBR) a parallel machine is loaded with a database of the sort that can be used as a training set for learning systems: situations together with actions, classifications, or desired outputs for each situation. When a new problem is encountered, the MBR system compares it to all the known prior cases, and uses the most similar case (or majority vote of several similar cases) to classify the new case The key to successful MBR operation is the selection of a good similarity metric for matching new problems with known cases. [Stanfill & Waltz 19861. Advantages of MBR MBR provides expert system- like behavior, but does not require extensive hand-coding. MBR provides “explanations” -- the precedents most similar to the current problem case -- in order to justify its actions. MBR provides high performance --superior to artificial neural nets [wolpert 19891 and superior to expert systems (see below). MBR is robust when noise is added to its database; in one experiment [Stanfill & Waltz 19881 on the NETtalk database [Sejnowski & Rosenberg 19861, performance fell off only about 10% when 90% of the database was replaced with noise. MBR is simple to update: new cases can be added and old, obsolete ones removed, and performance will immediately track the changes. This is in sharp contrast to artificial neural nets, which must be totally retrained if the world changes, and expert systems, which are notoriously difficult to modify. There are some disadvantages: MBR generally requires a data parallel computer, which will probably be more expensive than a system used to deliver an expert system or neural net application (though inexpensive data parallel systems without extensive interprocessor communication might suffice); and MBR systems do not operate as rapidly as a trained neural net, though they would generally be much faster than expert systems. Classifying Census We have recently demonstrated that an system can perform impressively on a task to generate one of about 241 industry codes and one of about 509 occupation codes for individual respondents, by comparing their answers (expressed as free text and multiple choice selections) with 132,000 cases that have already been classified by hand. Early results have indicated that by keeping categories where the system has been proven to be correct at least 90% of the time for industry codes and at least 86% of the time for occupation codes, MBR can correctly process at least 70% of the database for industry codes and about 56% of the database for occupation codes. For comparison, an expert system that required more than two years to develop, achieves only 57% and 37% of the database respectively on these two tasks [Smith, Masand, & Waltz 19901; the R system took less than a month to build. For this application, the similarity metric is generated, using statistical operations, on the fly. tber Applications Similar methods have been used to build MBR systems for optical character recognition, based on a large number of examples of handprinted numerals [Smith & Voorhees 19901; for medical diagnosis [Stanfill & Waltz 19861; for controlling a robot to produce near optimal trajectories [Atkeson 19871; for (two-dimensional) object recognition lTucker et al. 19881; for automatically generating index terms for news articles or routing articles to appropriate recipients [Smith 19901. Recent work [Zhang & Waltz 19901 on protein structure prediction has shown that a system that combines the results of MBR with neural nets and statistical information dramatically outperforms any previous method. This has relevance to the human genome project, another good target area for AI and IR. Many other applications are clearly possible. Genetically-Inspired Methods Market research is a “forest for the trees” problem. One needs to generate insights into the repetitive preference patterns among millions of customers, and distill market segment definitions in order to offer consumers the products they are most likely to want. We have developed genetically-inspired algorithms [Singer forthcoming, Holland 19751 that automatically find trends and categories without being told in advance what the patterns are. 1120 INVITED TALKS AND PANELS One specific problem that has been addressed by these methods is the following: Suppose that we know purchasing behavior, demographic and credit information for several million (or tens of millions of) people, and that we wish to mail catalogs containing items selected from the offerings of hundreds of vendors, such that the greatest possible return (dollar amounts ordered minus the cost of the mailings) is maximized. Clearly, the larger the catalogs, the more the cost for postage, and the greater the chance each will be thrown away; the smaller and more tailored the catalogs, the better the return, but the more expensive it will be to print the catalogs and stuff the appropriate envelopes. In an example run, we started with about 8000 customers on a small CM-2, and first calculated the ideal catalog of five items for each customer. (This step requires a model of consumer behavior.) Each list of five items is analogous to a piece of genetic material. We also computed an expected return (negative) for sending 8000 tailored catalogs. We then used the communications system of the CM-2 to randomly pair up consumers in parallel. For each pair, we then calculated the change in expected return if consumer 1 took consumer 2’s catalog, and vice-versa. Both consumers were grouped into one or the other of the catalogs with a probability based on the change in the expected returns. The scoring scheme also makes it easier to merge a consumer who shares a catalog with a small number of others into a larger group than to pull a customer out of a large group and into a smaller one. Every few steps, random point mutations to the catalog’s customers were probabilistically introduced, on the theory that the best catalogs may not have been present for anv of the original consumers. The process continued until the maximum expected return point was found (in this case, 30 tailored catalogs, and sets of consumers who should receive each). The overall solution to this problem required on the order of two hours on a 4K processor CM-2; the overall potential search space of solutions is on the order of 1O87 ! A Different Route to Truly Intelligent Systems So what does all this have to do with cognition? I want to argue that the basic associative memory operation of selecting relevant precedents in any situation is the essence of what intelligent entities do. (“Precedents” may be actions, options, remindings, etc.) If only a single precedent is found (e.g. when one is operating in a familiar environment on familiar tasks), then there is little involved in acting intelligently. Only when two or more incompatible precedents are found, or when the task space is unfamiliar, is reasoning (in the ordinary sense) required. Combinatorially explosive search can be avoided, since in any given situation only a small number of “operations” (actions) are plausible, making branching factors manageable. Planning can be supported by associative memory retrieval of precedents of the form: [hypothetical situation + goal + operator -> new situation] and/or [hypothetical situation -> goal]. Even creativity or analogical problem solving might be covered (if the best precedents match structurally but are not literal matches). I am not imagining that a monolithic flat database could model memory. First, generalizations over memory and other structures need to be matched in addition to episodic items. (See [Kolodner I989 and Evett et al. 19901 for descriptions of massively parallel frame systems.) Second, there ought to be situation- specific priming that changes the overall searchable space (or relevance judgements) for precedents. Overall, I am persuaded by society of mind [Minsky 19861 arguments and examples, and feel that the structure of memory also contains many agents responsible for recognizing special situations and either priming or censoring memories Summary If AI is to succeed, it is important to find ways to justify ongoing research costs, to substitute profits for promises. Commercial massively parallel applications already offer opportunities for changing the ways business is done, because existing limits on database size and speed of access can be transcended. Moreover, the excess processing capacity of massively parallel systems makes it possible to add greater intelligence to applications. And there are great potential payoffs for this kind of AI: even modest ideas, if they are sufficiently general to apply to an entire large database, can produce results that seem wonderfully magical. Most successes of this sort to date have used data parallel methods, especially memory-based reasoning. MBR applications can often be generated automatically from existing databases. MBR and case- based reasoning may also form the basis of new paradigms for cognition that can scale to human levels as massively parallel machines develop. REFERENCES Blair, D., & Maron, M. (1985). An evaluation of retrieval effectiveness for a full-text document retrieval system. Communications of the ACM, 28, 289-299. Blelloch, G. E. (1986) “AFS-1: A programming language for massively concurrent computers.” Tech. Report 9 18, Cambridge, MA: MIT AI Lab. Church, K. (1988). A stochastic parts program and noun phrase parser for unrestricted text. Unpublished manuscript, AT&T Bell Labs, Murray Hill, NJ. Dejong, G. (1982). An Overview of the FRUMP System. In W. Lehnert & M. Ringle (Eds.), Strategies for natural language processing, Hillsdale, NJ: Lawrence Erlbaum Associates. WALTZ 1121 Drumheller, M. (1986). “Connection Machine stereomatching”. Proceedings of the 5th National Conference on AI, Philadelphia, 748-753. Ejerhed, E. (1988). Finding clauses in unrestricted text by stochastic and finitary methods. Unpublished manuscript, AT&T Bell Labs, Murray Hill, NJ. Evett, M., Hendler, J., & Spector, L. “PARKA: Parallel knowledge representation on the Connection Machine”. Tech Report CS-TR-2409, University of Maryland, February 1990. Fahlman, S. E. (1979). “NETLz A system for representing and using real-world knowledge”. Cambridge, MA: MlT Press. Kolodner, J. dz Thau, R. (1988) “Design and implementation of a case memory“, Research report. GIT-ICS-88/34, School of Information and Computer Science, Georgia Tech, October, 1988. Kucera, H., & Frances, W. (1982). Frequency analysis of EngZish usage, Boston: Houghton Mifflin Company. Lenat, G., P&ash, M., & Shepherd, M. (1986). CYC: Using common sense knowledge to overcome brittleness and the knowledge acquisition bottleneck. AI Magazine, 4,65-85. Marr, D. C. & Poggio, T. (1976) “Cooperative computation of stereo disparity”. Science 194,283-287. Quiian, R. (1983) *Learning efficient classification procedures and their application to chess end games”, in R.S. Michalski, J. Carbonell, and T. Mitchell (eds.), Machine Learning: An Artificial Intelligence Approach, Los Altos, CA: Tioga Publishing, 463482. Rumelhart, D., & McClelland, J., et al. (1986). Pun&l distributed processing. Cambridge, MA: MIT Press. Salton, G. (1971) The Smart Retrieval System -- Experiment in Automatic Document Classifiation. Englewood Cliffs, NJ: Prentice-Hall. Salton, G. (1988). Personal Communication. Schank, R.C. (1982). Dynamic Memory. Cambridge, UK: Cambridge University Press, 1982. Schwartz, J.T. (1988) “The New Connectionism”. DaeduZus 117, I, 123-142, Winter 1988. Sejnowski, T.J. 8z Rosenberg, C.R. (1986) “NETtalk: A Parallel Network that Learns to Read Aloud”. The John Hopkins University Electrical Engineering and Computer Science Technical Report JHU/EECS-86/01. Smith, S. (1990) “Current limits of text-based intelligent systems”, AAAI Spring Symposium on Text-Based Intelligent Systems, Stanford, March 1990,130-133. Stanfill, C., (1988). Parallel computing for information retrieval: recent developments. Thinking Machines Corporation Technical Report #DR88- 1. Stanfill, C., & Kahle, B. (1986). Parallel free text search on the connection machine system. Communications of the ACM, 29,12. Stanfill, C., Thau, R., & Waltz, D. (1989). “A parallel indexed algorithm for information retrieval”. SIGIR ‘89 (Proc. 12th Annual International ACMSIGIR Conference on R&D in Injkmation Retrieval), Cambridge, MA, June 1989,88-97. Stanfill, C. & Waltz, D. (1986) Toward memory-based reasoning. Communications of the ACM 29, 12, 1213-1228. Stanfill, C., dz Waltz, D. (1988). ‘The memory-based reasoning paradigm”, Proc: Case-Based Reasoning Workshop, Clearwater Beach, Fl., May 1988.414424. Tucker, L., Feynman, C., & Fritzsche, D. (1988). “Object recognition using the Connection Machine”, Proc. Computer Vision & Pattern Recognition, Ann Arbor, MI, June 1988, 871- 878. Waltz, D. L. (1988). “The Prospects for Truly Intelligent Machines”, Daedalus 117, 1, 191-212, Winter 1988. Waltz, D., & Feldman, J. (Eds.) (1988). Connectionist models and their implementations. Norwood, NJ: Ablex. Waltz, D. L. & Stanfill, C. (1988). “Artificial Intelligence Related Research on the Connection Machine”. Prolc. International Conference on Fifth Generation Computer Systems, Tokyo, December 1988,1010-1024. Waltz, D. L. (1989). “Is indexing used for retrieval?” ProcCase- Based Reasoning Workshop, Pensacola Beach, FL., May 1989, 41-44. Wolpert, D. (1989) “Generalization Theory, Surface-fitting, and Network Structures,” Ph.D. Thesis, Physics Dept., University of Califomia, Santa Barbara, Winter 1989. Zhang, X., & Waltz, D. (1990) “Developing hierarchical representations for protein structures: an incremental approach”. AAAI Spring Symposium on Molecular Biology, Stanford, March 1990,149-152. Smith, S., Masand, B., & Waltz, D. (1990) In preparation. Smith, S., & Voorhees, H. L. (1990). In preparation. 1122 INVITEDTALKSANDPA~LS
|
1990
|
64
|
983
|
AI and Software Engineering Will the Twain Ever Meet? Moderator: Robert Balzerl USC Iuforination Scieuces Iustitute Panelists: Richard Fikes Price Waterhouse Mark Fox Carnegie Mellon University John McDermott Digital Equipment Corporation Elliot Soloway University of Michigan Abstract This session will explore the reasons for the lack of im- pact in four important areas in which AI has been ex- pected to significantly affect real world Software Engi- neering. The panelists, each representing one of these areas, will respond to the conjecture that these fail- ures rest upon a common cause - reliance on isola- tionist technology and approaches, rather than upon creating additive technology and a.pproaches that can be integrated with other existing capabilities. l?or the purposes of this debate, we’ve divided up the ways that AI could impact Software Engineering into four broad areas, each of which will be represented by one of the panelists: o Development of smart a.pplications (e.g. Expert Systems) e Development of sma.rt application components e Providing intelligence within the system architec- ture (e.g. in expert databases or intelligent user interfaces) o Using AI to develop software The first three are product related and are con- cerned with including AI capabilities within delivered applications. The first two address embedding the AI capabilities within the application itself, while the third addresses embedding them within the run-time facilities used by the application. The fourth area concerns the use of AI in the process of generating software. This generated software may be conven- tional or it may include AI capabilities in one or more of the first three areas. Our expectakions for major impact upon the field of Software Engineering in these four areas, or on the ‘The author’s work is supported by Bhe Defense Ad- vanced Research Projects Agency under NASA-Ames Cooperative Agreement No. NCC Z-520 and contract MDA903-87-C-0641. The views and conclusions are the author’s and should not be interpreted as representing the olficial opinion or policy of DARPA or the U.S. Government. field in genera.1, have been largely unrealized. h/lost obviously, there has been no shift yet in the basic Soft- ware Lifecycle that I, among others, predicted would occur. The old Waterfall Lifecycle is still universally employed. In many ways, software is still being man- aged and produced as it wa.s twenty years ago. Nevertheless, many significant changes have oc- curred within the Software Engineering community, such as: structured programnling; abstraction and encapsulation; distributed processing; object oriented approaches; the adoption of Unix and C; and most recently, formal methods and specifications. It’s just that these changes have been been initiated and driven by others, not AI. Our major effect on software engineering to date has been in defining, supporting, and getting accepted the iterative development style, especially within the context of prototyping. We a.re thereby also partly responsible for the increased role of prototyping in software development. The argument is not that we’ve had no influence, but that the impact we’ve had has been much, much smaller than expected. Some of the blame for this lack of impact from our field undoubtedly lies within the Softwa.re Engineering Communit~y, but we’ve chosen to focus this debate on our own actions, or the lack thereof, that have crippled this coupling between the two communities. Conjecture: Common Cause - Isolationist Technology & Approaches The central conjecture that this panel will debate is that the primary impediment to the impact of AI on Software Engineering is the adoption by the AI field of technologies a.ncl approaches which isolated us from, rather than coupled us to, the Software Engineering community. This isolationism has been manifested in several areas: Idiosyncratic Language Like ot,ller communities, we invented idiosyncratic languages for our own use. \Vha.t differentiated us, was not the existence of such languages, but rather the nature of the differences between them and the BALZER 1123 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Separate Infrastructure standard algebraic languages in use throughout the rest of the community and our interest in symbolic rather than numeric computation. Idiosyncratic Environment What really set us apa.rt was the creation of idiosyn- cratic environments, programmed in our idiosyncratic language, and utilizing its symbolic computation fa- cilities to represent and manipulate the computation structures of the application being executed and of the environment itself. This ability to manipulate those computation structures gave rise to a, wealth of late binding mechanisms to dynamically control and alter their meaning. In contrast, the rest of the community used far sim- pler, less powerful, (intentionally) less flexible, and much less encompassing environments. Idiosyncratic Hardware Having created our own language and support envi- romnents, and not content to merely ride the crest of the emerging hardware revolution, we took the oppor- tunity afforded by this revolution to create our own machines. The specialized architectures of those machines cer- tainly provided us with an immediate benefit of in- . creased power. But it also clearly launched us on a trajectory away from the rest of the computing com- munity. Not only did we do our work in a.n idiosyn- cratic language, but we also now did it in sepa.ra.te machines that didn’t run anything else. Moreover, this meant that the operating system itself had to be written in Lisp. This cut any remaining ties result- ing from a shared reliance on a common operating system as we had 1la.d 011 the previous generation of mainfra.mcs. The primitive state of distributed system support that existed at tl1a.t time virtually completed our isolation. We not only crea.tecl idiosyllcratic, high perfor- mance, development machines, but we also created low-cost compatible delivery machines 011 which to run the applications we expected to be built and widely disseminated. We all know now, with the advanta.ge of hindsight, that this idiosyncratic hardwa.re thrust was not sus- tainable - in part because the expected market did not develop, but also because of the huge development costs of keeping up with the rapidly improving VLSI state-of-the-art. Recently, our isolation has been eased somewhat by the improving state of network support for dis- tributed processing and by the appearance of co- processor plug-in boards for providing our specialized hardware support within conventional workstations and PCs. It is interesting to note that no other language com- munity chose to pursue a similar, specialized hard- ware, route. In the natural progression of our separation trajec- tory, we built our own infrastructure. Our soft- ware development and execution environments are ar- guably the best ever created. But these environments also had a dark side. The better they became, the more we relied upon them. The more we relied up011 them, the more insular we became, and the bigger the gap became between our support facilities and those common and accepted within the Software Engineer- ing community. We also created, in the expectation of major growth, our OWI~ service industry of software and hardware vendors and consultants to support our small, tight-knit community. Large Footprint One major problem resulting from our wealth of en- vironmental infrastructure, was the ease with which it could be incorporated in our applications, and the difficulty of separating the part we depended up011 from the rest of this infrastructure. This resulted in very large footprints (i.e. memory requirements) for a.11 but the simplest applications. Our response ha.s traditionally been to just add more real memory with the knowledge that mem- ory was always getting chea.per. But this hard- ware bail-out exacerbated our isolation by creating widely different hardware support requirements be- tween ourselves and the mainstream computing com- munity that relied on minimally configured worksta- tions, or even PCs. It is only recently, that we’ve taken this problem se- riously enough to develop the necessary delivery tech- nology to sepa.rate out just the portions of the envi- ronment really needed by an application, and thereby reduce the a.pplication’s footprint. Weak Interoperability The a.11 encompa.ssing nature of our environments, the isolation induced by idiosyncratic hardware, and the dynamicism of our language all conspired to lessen our interest in supporting interoperability with other languages and/or machines. We’ve certainly created connections betwee Lisp and other systems, but almost always in a.cl-hoc spe- cial purpose ways rather than building generic inter- operability mechanisms. There don’t seem to be any technical obstacles tha.t a.re greater tl1a.n those facing other communities -- just, less commitment on our past. No Encapsulation While the rest of the Software Engineering community has been engaged for some time in perfecting mech- anisms for structuring applications by dividing them into manageable subunits with well-defined and enfor- cable interfaces betwee.n them, we have continued our 1124 INVITED TALKS AND PANELS pursuit of flexibility. In that pursuit, we have largely ignored, and failed to support, the mechanisms used by others for early bindings and declarations of static structure. We have no interface definition languages, encapsulation mechanisnis2, or type-safe languages. In the absence of such encapsulation mechanisms, we have no reliable means of breaking systems up into well-defined pieces. Hence, the understandability and maintainability of our systems is highly suspect, re- lying instead on conventions, good coding styles, and accurate documentation. Egocentric Mehtality Questions to be Debated e Do you agree that we’ve had little impact on Soft- ware Engineering ? If not, what major impacts do you think we’ve had? - e Do you agree that the main cause of this lack of impact is our isolationist technologies and ap- proaches? If not, what are the main causes? e What impacts should we have had, given the tech- nologic advances we’ve made? e What t8echnical problems should we have been ad- dressing in order to have had more of an impact? 1 t is ii0 coincidence that our major commercial thrust is called “Expert Systcnls” rather than “Expert Subsystems.” We developed a technology for build- ing a whole generation of stand-alone systems cre- ated and run totally within our own technology which solved some complete user problem. Rather than cre- ating subsystems which could ea.sily fit into existing systems, we temporarily avoided the issue by focusing on problems which allowed stand-alone solutions. e Finally, what technical problems should we now be addressing, and what impacts do you foresee from working on those problems? Another real user need we’ve ignored, beyond cre- ating new expert subsystems and components, and potentially even more important, is making existing components smarter - that is, developing the tech- nologic and methodologic base for incrementally inte- grating knowledge or rule-based capabilities into the existing structure of some component. Marketplace Reaction to AI’s Isolation It is also no coincidence that the marketplace has rejected our isolationist and egocentric approach. They’ve demanded that both the generated expert system applications and the shells that produce them run on Unix Workstations a.nd PC!s, be coded in C (to improve performance and simplify interoperability), and be interfa.ced to the rest of the client’s system and the environment in which the generated compo- nent will operate. Likewise, the sponsors of the various software engi- neering consortia., institutes, and industrial research laboratories have rejected technology transfer utiliz- ing Lisp ba.sed systems because they don’t integrate or interoperate well, and because they don’t have Lisp knowledgeable people to maintain and evolve these systems. The commercial marketplace is moving quite rapidly toward adoption of a set of architectural and interoperability standards that support component- wise heterogeneity, and unless we can open up and unbundle our monolithic Lisp environments, we’ll find ourselves even more isolated and rejected. 2 Common Lisp’s packages provide only the most prim- it,ive mechanisms for sepa.rat.ing the public and private parts of an application, but no means of enforcing tl1a.t separation BALZER 1125
|
1990
|
65
|
984
|
Introduction I have been asked in this note to Richard Fikes Price Waterhouse Technology Centre 68 Willow Road Menlo Park, California 94025 U.S.A. comment on the nature and extent to which the technologies and methodologies used to build “smart” application systems have contributed to software engineering. I will interpret the term “software engineering” broadly here as refering to the ability to create software solutions to problems, and will consider “‘smart’ application systems” to be what are generally referred to as “expert systems” or “knowledge-based systems”. First of all, knowledge-based systems have contributed directly to software engineering by providing a technology that expands the range of tasks which computers can effectively perform. Generally speaking, the expansion has been to simple decision tasks that were previously considered to require human intelligence. Much of the first generation rule-based and object-based technology which enabled the expansion is now being integrated into conventional programming environments so that it will be available for use when needed as a standard part of the professional system builder’s repertoire. The AI community at large has been a major contributor to software engineering by playing a pioneering role in the development of symbolic, interactive, and exploratory programming. The building of knowledge-based application systems has typically required all three of these forms of programming and has recently been particularly responsible for motivating the development of techniques for effectively managing exploratory programming activities. (See, for example, (Walters and Nielsen 1988), (Schoen and Sykes 1988), and (Fikes and Jacobstein 1989).) Since exploratory programming can be a useful methodology in a broad range of both AI and non-AI system building projects (Sheil 1983), I consider techniques for managing its use to be a significant contribution to software engineering. It is those techniques that I wish to address briefly in this note. Managing Exploratory Programming As we know from experience, knowledge-based system applications typically require an exploration process in order to determine the functionality, knowledge, and 1126 INVITEDTALKSANDPANELS processing methods that are needed to perform the target task. The initial specifications from the client for such projects are often little more than aspirations (e.g., recognize the tax issues in a business situation, monitor the operation of a plant). Therefore, a major goal of the early part of a knowledge-based systems application project is to determine a realizable detailed set of functional specifications that are satisfactory to the client. The typical means for achieving that goal is to build a sucession of prototype systems, each of which is exposed to users and experts for comment and then refined to produce the next system. The challenge faced by project planners and managers is how to allow such exploration to occur and still maintain an acceptable degree of predictability in the cost, timing, and results of the project. In the last few years, a set of guidelines has emerged from the building of knowledge-based systems for managing exploratory programming activities in the form of additions to and modifications of conventional software engineering management methodology. The following describes some of the principal points in those guidelines. Conventional software engineering methodology holds that central to any software development is the availability of (1) a system requirements specification stating the problem to be solved and criteria for success against which the application can be designed, implemented, tested, and validated; and (2) a project plan containing an activity schedule and a description of the deliverables and costs for each activity (Sommerville 1989). What has been learned is that the use of exploratory programming does not lessen the importance of writing such a specification and plan at the beginning of a project and of maintaining those documents throughout the project, even though they are initially lacking in significant detail and change substantially as the project progresses. The requirements specification and project plan are important because they represent a common agreement among the interested parties in a project, including the sponsor, experts, users, and developers. For exploratory programming projects, they also indicate at any given time what has been learned thus far and what questions remain open to be answered by the exploration. The project manager’s job is then one of From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. managing the evolution of that agreement and assuring that the open questions are being effectively addressed. The first guideline in managing the evolution of the common agreement is to make sure that all interested parties understand from the outset that the agreement is in fact going to evolve. Everyone must understand that the current agreement at any time during the exploratory phase of the project is only a best guess and that the primary purpose of the exploration is to improve those guesses and remove the uncertainties in them. Thus, the changes in the requirements specification and project plan at the end of each exploratory step are the results of that step. If there are no changes and no reduction of uncertainty, then nothing has been accomplished by the exploration. The primary way to gain support for a project in which specifications and plans are expected to change is to establish clear procedures for updating the specification and plan and for informing all interested parties when those changes occur. (The manager can make clear, also, that the updating and informing procedures are not expected to change.) The central element of those procedures is to have frequent project reviews, including prototype demonstrations, that give all interested parties an opportunity to revise and renew their agreements. Such reviews typically produce a list of errors or problems in the prototype to be addressed in the next step such as desired changes in the user interface, missing or inadequate areas of knowledge or functionality, or errors in the knowledge or its representation. At each project review, a detailed specific plan needs to be presented for the period up to and including the next review. An important element of that plan is a list of objectives for the step. Such a list would include the unresolved requirement specification issues to be addressed and errors or problems in the prototype that were found during the review to be fixed. These objectives provide the developers with a basis for deciding what to do next and a set of criteria for evaluating the results of the next step. At any time during a project, the plan for the current prototyping step is not expected to change substantially. Thus, an exploratory programming project can be considered to have a stepwise stable project plan such that at each review point a stable plan exists for the next step. Summary The technologies and methodologies used to build knowledge-based systems have expanded the range of tasks that computers can effectively perform and has contributed to the development of symbolic, interactive, and exploratory programming. In particular, experience in building knowledge-based systems has produced a set of guidelines for managing both AI and non-AI exploratory programming efforts. Those guidelines have contributed substantially to making exploratory programming a viable system development technique for use whenever there is significant uncertainty as to the functional requirements for the desired system. eferences Sommerville, I. 1989. Software Engineering. Reading Mass.: Addison-Wesley. Walters, J.R., and Neilson, N.R. 1988. Crafting Knowledge-Based Systems; Expert Systems Made (Easy) Realistic. New York: Wiley-Interscience Schoen, S., and Sykes, W. 1987. Putting Artificial Intelligence to Work; Evaluating and Implementing Business Applications. New York: John Wiley & Sons, Inc. Fikes, R., and Jacobstein N. 1989. Managing Expert System Projects. Tutorial: MAS. Eleventh International Joint Conference on Artificial Intelligence. Detroit: IJCAI-89. Sheil, B. 1983. Power Tools for Programmers. DATAMATION February, 1983. FIKES 1127
|
1990
|
66
|
985
|
Looking for the AI in Software Engineering An Applications Perspective Mark S. Fox Center for Integrated Manufacturing Decision Systems Carnegie Mellon University Pittsburgh, PA 15213 msf@cs.cmu.edu htiuction I have been asked to address the reasons why Artificial Intelligence has not had a significant affect on real world Software Engineering, from the perspective of the development of smart application components. In the following I will explore twhat it means to be a “smart application component”, then explore why they have not had the impact Robert Balzer thinks they should deserve. t3martApplicationComponents What is a smart application component? The noun “component” implies that it is a software module or procedure that will be attached to or embedded in another, larger piece of software. Consequently, the component plays a supporting role and must conform to the environment in which it is embedded. The adjective “smart” implies that the component is able to perform some decision task, or participate in one such that the final decision is “better”. Lastly, the adjective “application” implies that the component’s functionality is specific to a domain and not general across all domains. The question is “do we have any?” Of course, knowledge engineering software systems abound, such as ARTTM, KEETM, and Knowledge Craft?. They provide a knowledge representation, usually frame-like, a rule language, usually OPS5-like, and a variety of software engineering support functions such as editors, debuggers, and browsers. These systems have built upon the concepts found in interactive LISP environments and have clearly influenced the direction of the software engineering field. But they are at too low level of functionality to satisfy the application criterion mentioned above. Methods for truth maintenance, assumption-based truth maintenance andconstraint satisfaction are now common place and easily accessed, but these too are at too low a level of functionality. A number of commerical packages focusing on solving diagnosis or troubleshooting problems have been developed. The earliest being derivatives of EMYCIN from Stanford, such as, Cimflex Teknowledge’s S.lTM, and M.lTM and Texas Instrument’s Personal ConsultantTM: TestBench TM from Carnegie Group is a more recent example of a troubleshooting shell that uses failure mode analysis to identify sources of malfunctions. In the latter case, the representation and problem solving capabilities are restriected to a narrower domain. A generalization of the above has evolved into the concept of a generic task, proposed by (Chandrasekaran, 1988). The belief is that software can be designed by configuring a set of tasks, such as: * Hierarchical classification * Hypothesis matching * Synthesis by plan selection and refinement * Abductive hypothesis assembly While an interesting conjecture, it is too early to tell what such a library would be composed of, and there exists too little experience in configuring them. Lastly, more specific appl ication components have been created, some of which are available 1128 INVITED TALKS AND PANELS From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. commercially. These include, knowledge based simulation packages such as Simulation Craft from Carnegie Group and Simkit from Intellicorp, factory scheduling packages, process planners, mechanical design systems, etc. that we now have several to choose from. And in some areas, such as factory scheduling and project management an attempt has been made towards crating libraries (Sathi et al., 1985). Only Lenat’s CYC project at MCC has pushed the representational frontier, and more recently, DARPA, NSF and AFOSR convened a workshop It is clear that Artificial Intelligence has begun to to promote the reusability of representations. produce smart application packages, but only Never the less, AI application builders tend to recently. build their representations from scratch. Given that there exist components that could potentially be embedded in another system, what has curtailed their use? The answer is LISP. Historically, LISP could not be run as an embedded module within a larger application. Either its need to be the “master” process, and/or its size has been the problem. While many believe that if this problem is solved, these components will find greater use, the percpetion is false. The real problem is that industry does not want to train their employees to program in LISP, no matter what the AI community perceives its benefits to be. Training programmers in a new language is expensive, and managers loathe spending large amounts on learning what is essentially a fringe language with questionable, in their eyes, benefits. The momemtum that exists in industry today is to standardize on a single operating system, such as UNIX, and a single programming language, such as C/C++. Change is in the air. Neuron Data’s NEXPERTTM is C-based and embedable. The recently announced IMKA consortium, composed of Digital Equipment, Ford Motor, Texas Instruments, USWest, and Carnegie Group has as its goal to create a C-based knowledge representation system and library of application representations that are efficient, embedable and portable. ReusableRepresentations It is clear that there are not many AI-based smart application components available. It follows then that they should have little impact on software engineering. On the other hand, what modules are available tend to be written LISP, crippling their adoption by industry. The only positive statement one could make, is that software engineering has yet to achieve the “holy grail” of resuability either. ferences Chandrasekaran, B., (19SS), “Generic tasks as building blocks for knowledge-based systems: the diagnosis and routine design examples”, The Knowledge Engineering Review, Vol. 3, No. 3, pp. 177-182. Sathi, A., Fox, M.S., and Greenberg, M., (1985), “Representation of Activity Knowledge for Project Management”, IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol. PAMI-7, No. 5, pp. 531-552. One would think that with the central role that knowledge representation plays in Artificial Intelligence, that there would be a greater availability of representation libraries. It is true that the last ten years has witnessed a flurry of work in temporal and spatial representations, so Fox 1129
|
1990
|
67
|
986
|
eveloping ‘Softw re is like Talki John McDermott Digital Equipment Corporation 111 Locke Drive, LMOZl/Kl 1 Marlboro, Massachusetts 01752 Context It’s not clear to me exactly what people in AI do, but one thing that is talked about a lot is how important knowledge is. One of the things knowledge is sup- posed to be good for is solving hard problems. The idea, as I understand it, is that one characteristic of a large set of problems is that their solutions are radi- cally contingent on the peculiarities of the various situations in which the problems are instantiated. To anyone who is ignorant of most, or even many, of the peculiarities, those problems appear hard. It is only to an agent who has knowledge of almost all of the rele- vant peculiarities that the problems appear straightfor- ward So what does this have to do with software develop- ment? Well, Bob Balzer claims to believe at least three things [Balzer, 901: 1. AI was expected to make software development less hard. 2. It hasn’t. 3. The reason AI has failed is its reliance on isola- tionist technology and approaches. AI doesn’t own very many problems. It does own making software development less hard. It is usual to expect disciplines to make progress on the problems they own. So I share Balzer’s first belief. With respect to his second belief, it is clear that AI has not yet done much to make software development less hard. And AI certainly has done some things to make software development harder. So the only diffi- culty I have with Balzer’s second belief is that it un- derstates the case. The Disagreement Would that Balzer had only two beliefs. His third be- lief -- that AI has failed because of its reliance on iso- lationist technology and approaches -- shows a com- plete lack of appreciation for why we have failed. We have failed because we can’t yet think about the soft- 1130 INVITED TALKS AND PANELS ware development problem clearly. The problem is essentially one of mapping from task features, de- scribed at some appropriate level of abstraction, to program features, described at some appropriate level of abstraction. Or in other words, the problem is map- ping from knowledge level objects to symbol level objects [Newell, $01. What we don’t yet know is what the helpful abstrac- tions at the knowledge level and the symbol level are. IIappily, a whole bunch of work in AI is focused on just this question (eg, [Bachant, 891, [Clancey, 891, Lowry, 891, warcus, 881, McDermott, 891, musen, 891, wch, 901, [Yost, 891. Over the past decade or so, the concept of rapid prototyping as au aid to software development has come into vogue. The idea is, of course, a wonderful one -- probably forever, but for sure in these primitive times when we don’t yet know even how to talk about either tasks or programs in a way that doesn’t obscure the mapping from the one to the other. Rapid prototyping is helpful because, given an approximation to a desired program, users can at least point to inadequacies the program has. Soon, hopefully, we will be able to communicate with words -- with words for patterns which at the moment we don’t know we see. An Example I’ve recently come across a piece of work that is mov- ing us exactly toward where I think we have to go moth, 90a; Roth, gob]. I’m going to give an example from this research to try to convey at least the spirit of the enterprise. The focus of the work has been on how to automate the design and graphical presentation of information. The system developed, SAGE, is an in- telligent interface which receives information from an application program and designs a combination of graphics and text that effectively conveys that infor- mation. SAGE embodies a way of thinking about in- formation and about users’ goals, and a way of think- ing about graphical displays, that makes the mapping from one to the other fairly straightforward. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Figure I Information Provided to SAGE Data Activities Activitv Act- 1 Act-2 Act-4 . Start-Date 34 2 30 . . End-Date 38 16 34 . . Duration 4 12 4 . . Departments Department CAD-Dept Structural-Dept Assembly-Dept Resoonsible- for Act-l, Act-2, Act-4, . . . Act-19, Act-20, Act-23, . . . Act-33, Act-34, . . . Objects & Relations Domain Department Activity Activity Activity Relation Responsible-for Start-date, End-date Duration Requires Characterization of Objects Object & Sets Ordering Department Nominal Activity Nominal Resource Nominal Date Quantitative Number-of-weeks Quantitative Characterization of Relations Relation Responsible-for Start-date, End-date, Duration Requires Coverage No Yes Yes Range Activity Date Number-of-weeks Resource Coordinate/Amount -- SW mm Coordinate Amount Cardinality Varied 1 1 Characterization of Relationships Among Relations Relation&h Role Relation Interval Beginning Start-date Size Duration End End-date Characterization of User’s Goals Goal Visualize-correlation Relations Responsible-for Start-date, End-date Duration Requires Resource Sun TI Sun . . Domain -- -- -- Time Time Uniuueness Yes No No MCDERMOTT 113 1 SAGE attends to the following four kinds of task fea- tures: 1. features which distinguish the kiuds of informa- tion each graphical technique can express, 2. features which order graphical tee es based on how effective they are at conveying different information, 3. features which define users’ purposes, 4. features which determine how information should be integrated within a display. SAGE has a language for describing graphical displays and information which it uses to automatically pro- duce many complex, creative pictures through the synthesis of simple techniques. Eigure 2 iilustrates the kind of picture SAGE can compose. l?igure 1 displays Inthiscase, to SAGE come from a query to a project m nt database. ‘Ibe manager who made the query was considering how to allocate com- ents for an upcoming pro- d included the departments the activities they would be startdates, end-dates, du- sources. FQure 1, in addi- tion to showing the information retrieved from the project management database, contains a number of &a characterizations. These data c.bimc~rizations -- information about what fatures of the task have rele- vance -- provide SAGE with precisely the information it needs in order for it to exploit its knowledge of how to compose pictures. The example illustrates what it means to have helpful abstractions at the knowledge level and at the symbol the input that allowed SAGE to compose that picture. level: Figure 2 Orgrnizrtlonal Divfrlono and Activlth CAD-Dept Act-l Act-2 Act-4 Act-5 Act-6 Act-8 Act-9 Act-10 Act-l 2 Structural-Dept Act-19 Act-20 Act-22 Act-23 Act-24 Act-27 Assembly-Dept Act-33 Act-34 Act-35 Act-43 Act-47 Act-50 Act-80 Act-8 1 Act-82 The Picture Produced by SAGE Wnkr into Project 0 4 8 12 16 20 24 26 32 36 40 44 I I a I1 I I I1 a I I I * . . I. 0 * fi I n . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . i&&q; ; i;:.;:i.;R:i:~~::::::::‘.:.‘r.:.:. :.:::::::~::.::i:.:~:i:..::~ .,: i..: .: :. ‘_ ; . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . : . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . U: . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 0 A&~. ..:.;.:.,.: 0 i .;::s:i .:: ; : UiaoVAX Sm lbEaplocor i . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ..~ 1132 INVITED TALKS AND PANELS knowing that resources comprise nominal (unor- dered) sets and that number-of-weeks is quantita- tive enables SAGE to use color for the requires relation, but not for the duration, knowing that dates refer to time enables SAGE to honor the convention that time is visualized hori- zontally, not vertically, knowing that the responsible-for relation maps “uniquely” to activities (ie, each activity is associ- ated with one department) enables the hierarchi- cal representation of the vertical axis, knowing that the goal is to see the correlations among all the relations leads SAGE to encode them using different properties of a single graphi- cal object: the color, vertical and horizontal posi- tion, and length of interval bars; (SAGE also can infer that the bars’ vertical position reflects the department associated with each activity), knowing that start-date, end-date and duration comprise an interval, enables SAGE to integrate them as such in a single bar, The knowledge that SAGE has that allows it to exploit the data characterizations includes constraint knowledge: for example, representing resources using different shapes instead of colors would have prevented display integration, be- cause the interval bars are already constrained in shape; SAGE considers spatial and other graphi- cal constraints when searching for a way to inte- grate a picture, picture organizational knowledge: for example, in the absence of direct goals to the contrary, SAGE used the order in which the relations were re- quested to determine that it should index (organ- ize) the picture by department rather than by a different property (eg, resource), effectiveness knowledge: for example, SAGE knows that color is good for distinguishing among three resources, but not twenty. Conclusion AI almost has it within its grasp to make software de- velopment easier. Though it probably wouldn’t hurt if we were less isolationist, the primary thing we need to do is identify helpful abstractions for knowledge level and symbol level objects so that program pieces can identify and compose themselves on the basis of im- mediately salient characteristics of tasks. If we look at our past just right, it’s clear this is work we’ve been preparing ourselves for for decades. Now it’s time to do something about it. References [Bachant, 891 Bachant, J., and E. Soloway. The Eugi- neering of XCON. Communication of the ACM, 32,3, 1989. palzer, 901 Balzer, R. AI and Software Engineering -- will the Twain Ever Meet? Proceedings of the Eighth Conference of the American Association for Artificial Intelligence, Boston, Massachusetts, 1990 -- or if not there, personal communication [Clancey, 891 Clancey, W. J. The Knowledge Level Reinterpreted: Modeling How Systems Interact. Ma- chine Learning, 4,3/4,1989. [Lowry, 891 Lowry M., and R. Duran. Knowledge- Based Software Engineering. Handbook of Artificial Intelligence, Vol. 4, Addison-Wesley, 1989. [Marcus, 881 Marcus, S. (ed). Automating Knowledge Acquisition for Expert Systems. IUuwer, 1988. NcDermott, 891 McDermott, J. The World Would Be a Better Place if Non-Programmers Could Program. Machine Learning, 4,314, 1989. wusen, 891 Musen, M. Automated Support for Build- ing and Extending Expert Models. Machine Learning, 4,3/4,1989. wewell, 811 Newell, A. ‘Ihe Knowledge Level. Al Magazine, 2,1,1981. [Rich, 901 Rich, C., and R. Waters. The Programmer’s Apprentice. Addison-Wesley, 1990. [Roth, 9Oa] Roth, S. and J. Mattis. Automatic Graphic Presentation for Production and Operations Manage- ment Systems. Proceedings of the Fourth International Conference on Expert Systems, Hilton Head Island, South Carolina, May, 1990. @oth, 9Ob] Roth, S. and J. Mattis. Data Characteriza- tion for Intelligent Graphics Presentation. Proceedings of the Conference on Computer Human Interaction, Seattle, Washington, April, 1990. post, 891 Yost, G. and A. Newell. A Problem Space Approach to Expert System Specification. Proceedings of the Eleventh International Joint Conference on Arti- ficial Intelligence, Detroit, Michigan, 1989. MCDERMOTT 1133
|
1990
|
68
|
987
|
The Techies vs. the Non-techies: Today’s Two Cultures Elliot Soloway Dept. of Electrical Engineering and Computer Science AI Laboratory University of Michigan Ann Arbor, MI 48109 Extended Abstract During the postwar heyday of physics, C.P. Snow, wrote a short article entitled “The Two Cultures” (1954). There he pointed out the growing division between the ‘science culture” and the “non-science (literary) culture.” He observed that scientists basically had no understanding of - - nay, even any concern for -- literary culture, and vice versa. He pointed out the profound loss to society that was resulting from this dichotomy. Namely, creativity often arises in the interchange of ideas. Sadly, the two cultures were so polarized, even then, that Snow felt that little real dialogue took place between members of the two cultures. Here it is, almost 40 years later. And, in what follows I invoke Snow’s argument as my response to the charge given to this panel: Why hasn’t AI had more of an impact on software engineering ? And more particularly, why hasn’t AI had more of an impact facilitating effective human-computer interaction in software engineering environments. My contribution is (1) to instantiate Snow’s argument in updated terms, i.e., Techies vs. Non- techies, where AI folks are, surprise, the Techies, and (2) to, quite simply, draw the community’s attention to a most provocative argument. Briefly, a Snow-like argument goes like this. By and large, AI is driven by its own questions, e.g., what counts as’an effective truth maintenance system? how can we formally characterize various representational schemes? etc. In contrast, interfaces by definition involve issues (e.g., humans and their idiosyncrasies) external to the computing mechanism(s). Sensitivity to user needs is just not a strong suit of AI (or, computer science in general). In fact, it takes individuals that can bring together the two cultures to make significant inroads in the interface problem. And there are precious few of those androgynous types, who feel comfortable with “real” psychology (not the academic brands of cognitive, social, perceptual, etc.), computer science, and AI. In the “Mythical-Man Month,” Fred Brooks Jr. points out that “progr amming is representation.” Since AI is all about representation, one would think that we would have built for ourselves, at least, wonderfully usable software development tools. In the old days we did have Interlisp. 1134 INVITED -~~~ANDPA~L~ But today we are just recovering from Lisp Machine Lisp - -- and, moving with great speed towards a standardized Lisp that is meant to be a common denominator. Actions speak louder than words: we still don’t even have modern interfaces for our own environments. How many still use OPS5 and think “surely there must be a better way.” (Buy one of the rule-based shells available on personal computers.) There is progress: thank goodness we no longer hold up “automatic programming” as the objective of our systems. (Though, if pushed to the wall, my guess is that AI’ers, optimists of the first water, still believe that it’s a reachable goal.) But, AI still has its healthy dose of hubris in using the term “intelligent interfaces.” That epithet will (hopefully sooner than later) go the way of “user-friendly,” a comparable term. What then is the prognosis ? On the one hand, given that we have experienced only increased polarization over the last 40 years, one has little reason to be sanguine for the future. On the other hand, external forces (e.g., funding) are reshaping the field by emphasizing more applied work. In effect, AI will need to educate itself about these “human concerns” in order to survive. The alternative? Technology will move blithely ahead. For example, a recently initiated customized newspaper service uses a 40 year old, weighted, keyword search algorithm to find articles that meet a user’s profile. Forget all that fancy user modelling. In sum, while the future is uncertain, there is a definite movement within the AI community to become more engaged in the design of “effective” human-computer interaction. In stepping into the morass of real live users, AI will benefit at least as much as those users! From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved.
|
1990
|
69
|
988
|
Tree Decomposition with Applications to Constraint Processing Itay Meiri, Rina Dechter ’ and Judea Pearl Cognitive Systems Laboratory Computer Science Department University of California Los Angeles, CA 90024 itay@cs.ucla.edu, dechter@techsel.bitnet, judea@cs.ucla.edu Abstract This paper concerns the task of removing redun- dant information from a given knowledge base, and restructuring it in the form of a tree, so as to admit efficient problem solving routines. We offer a novel approach which guarantees the removal of all redundancies that hide a tree structure. We develop a polynomial time algorithm that, given an arbitrary constraint network, generates a precise tree representation whenever such a tree can be extracted from the input network, otherwise, the fact that no tree representation exists is ack- nowledged, and the tree generated may serve as a good approximation to the original network. I. Introduction This paper concerns the problem of finding computation- ally attractive structures for representing constraint-based knowledge. It has long been recognized that sparse constraint net- works, especially those that form trees, are extremely efficient both in storage space and in query processing. A densely-specified network may hide such a desirable structure, and the challenge is to identify and remove redundant links until the natural structure underlying the knowledge base is recovered. The general issue of remov- ing redundancies has been investigated in the literature of relational databases [Maier 1983, Dechter 19871, as well as in the context of constraint networks [Dechter and Dechter 19871. This paper offers a novel approach which guarantees the removal of all redundancies that hide a tree structure. * This work was supported in part by the National Science Foundation Grant # IRI 8815522 and an Air Force Grant # AFOSR 880177 t Current address: Computer Science Department, Techuion - Israel Institute of Technology, Haifa 32000, Israel. Formally, the problem addressed is as follows. Given a constraint network, find whether it can be transformed into a tree-structured network without loss of information; if the answer is positive find such a tree, if the answer is negative, acknowledge failure. This paper develops a polynomial time algorithm that, given an arbitrary network, generates a tree representation having the following characteristics: 1. The tree represents the network exactly whenever such a tree can be extracted from the input network, and 2. If no tree representation exists, the fact is ack- nowledged, and the tree generated may serve as a good approximation to the original network. The algorithm works as follows. We examine all tri- plets of variables, identify the redundancies that exist in each triplet, and assign weights to the edges in accordance with the redundancies discovered. The algorithm returns a maximum-spanning-tree relative to these weights. An added feature of the algorithm is that when the tree generated is recognized as an approximation, it can be further tightened by adding edges until a precise representation obtains. This technique may be regarded as an alternative redundancy-removal scheme to the one proposed in [Dechter and Dechter 19871, accompanied with polynomial complexity and performance guarantees. 2. Preliminaries and nomenclature We first review the basic concepts of constraint satisfac- tion [Montanari 1974, Mackworth 1977, Dechter and Pearl 19871. 10 AUTOMATEDREASONING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. A network of binary constraints consists of a set of variables (X 1 , . . . ,X,, } and a set of binary constraints on the variables. The domain of variable Xi, denoted by Q, defines the set of values Xi may assume. A binary con- straint, Rij, on variables Xi and Xi, is a subset of the Cartesian product of their domains (i.e., Ri,j c Di x Dj); it specifies the permitted pairs of values for Xi and Xi. A binary constraint R is tighter than R’ (or converse- ly R’ is more relaxed than R), denoted by R c R ‘, if every pair of values allowed by R is also allowed by R’. The most relaxed constraint is the universal constraint which allows all pairs of the Cartesian product. A tuple that satisfies all the constraints is called a solution. The set of all solutions to network R constitutes a relation, denoted by rel(R), whose attributes are the variables names. Two networks with the same variable set are equivalent if they represent the same relation. A binary CSP is associated with a constraint graph, where node i represents variable Xi, and an edge between nodes i and j represents a direct constraint, Rg, between them, which is not the universal constraint. Other con- straints are induced by paths connecting i and j. The con- straint induced on i and j by a path of length m through nodes i. = i, i 1, . . . , i, = j, denoted by Ri,,i, . ,....&7 represents the composition of the constraints along the path. A pair of values XE Di, and YE Dim is allowed by the path constraint, if there exists a sequence of values VIEDi,, . . . ,Vm-IEDi,-, such that Ri,,i, kvl), Ri,,i,(vl rV2)r l - - 9 an dRim+i,(Vm- l ,I) . A network whose direct constraints are tighter than any of its induced path constraints is called path con- sistent. Formally, a path P of length m through nodes i0, il i ,-**, m is consistent, if and only if R io,i, C Rio,il . . Similarly, arc (i,j) is consistent if for ,-*..b$ any value XEDi, there exists a value yEDj such that R&y). A network is arc and path consistent if all its arcs and paths are consistent. Any network can be con- verted into an equivalent arc and path consistent form in time O(n3)(‘) [Mackworth and Freuder 19851. In this pa- per we assume all networks are arc and path consistent. Not every relation can be represented by a binary constraint network. The best network that approximates a given relation is called the minimal network; its con- straints are the projections of the relation on all pairs of (1) Actually, the complexity is 0 (n3&‘), where k is the domain six; however, for simplicity, we assume the domain size is constant. variables, namely, each pair of values allowed by the minimal network participates in at least one solution. Thus, the minimal network displays the tightest con- straints between every pair of variables. Being a projec- tion of the solution set, the minimal network is always arc and path consistent. 3. Problem statement We now define the tree decomposability problem. First, we introduce the notion of tree decomposition. Definition. A network R is tree decomposable if there exists a tree-structured network T, on the same set of vari- ables, such that R and 7’ are equivalent (i.e., represent the same relation). T is said to be a tree decomposition of R, and the relation p represented by R is said to be tree decomposable (by 7). R is tree reducible if there exists a tree 7’ such that R is decomposable by T, and for all (i, j)E T, TG = RG, namely the constraints in T are taken unaltered from R. The tree decomposability problem for networks is defined as follows. Given a network R, decide if R is tree decomposable. If the answer is positive find a tree decom- position of R, else, acknowledge failure. The tree reduci- bility problem is defined in a similar way. A related problem of decomposing a relation was treated in [Dechter 19871, and will be discussed in Section 6. Example 1. Consider a relation p1 shown in Figure 1. The minimal network is given by MA.B =A!f~,c =MB,c = (00, 11) MA,D = &,D = &,D = (00, 10, 11)~ where constraints are encoded as lists of permitted pairs. Any tree containing two edges from (AB, AC, BC) is a tree decomposition of M; for example, T1 = (AB, AC, AD) and T2 = {AB, BC, BD}. M is also tree reducible, since the link constraints in these trees are identical to the corresponding constraints in M. A B C D 0 0 0 0 ~ 1 1 1 0 1 1 1 1 Figure 1. p1 - a tree-decomposable relation. Example 2. Consider a relation p2 shown in Figure 2. T = (AB, AC, AD, AE) is the only tree decomposition of MEIRI,&ARL, AND DECHTER 11 P2- c -i- 1 1 1 0 1 0 1 D 0 0 1 1 1 1 1 1 ii- -ii- 1 0 1 1 1 1 1 Figure 2. p2 - a tree-decomposable relation. The rest of the paper is organized as follows. Sec- tions 4 and 5 describe the tree decomposition scheme, while Section 6 presents extensions and ramifications of this scheme. Proofs of theorems can be found in [Meiri, Dechter and Pearl 19901. 4. Tree decomposition schemes Tree decomposition comprises two subtasks: searching for a skeletal spanning tree, and determining the link con- straints on that tree. If the input network is minimal, the second subtask is superfluous because, clearly, the link constraints must be taken unaltered from the correspond- ing links in the input network, namely, decomposability coincides with reducibility. We shall, therefore, first focus attention on minimal networks, and postpone the treatment of general networks to Section 6. Our problem can now be viewed as searching for a tree skeleton through the space of spanning trees. Since there are nnB2 spanning trees on n vertices (Cayley’s Theorem lEven 1979]), a method more effective than exhaustive enumeration is required. The notion of redundancy plays a central role in our decomposition schemes. Consider a consistent path P =io, il,. . . ,i,. Recall that the direct constraint Ri,,i= is tighter than the path constraint Rio,;,, . . . ,im. If the two constraints are identical we say that edge (ij) is redun- dant with respect to path P; it is also said to be redundant in the cycle C consisting of nodes {io, i 1, . . . , i, ) . If the direct constraint is strictly tighter than the path constraint, we say that (i,j) is nonredundant with respect to P (or nonredundant in C). Another interpretation of redundancy is that any instantiation of the variables (io, i 1, . . . , i, } which satisfies the constraints along P is allowed by the direct constraint Ri,,i=. Conversely, nonredundancy im- plies that there exists at least one instantiation which violates Ri,,im. Definition. Let T be a tree, and let e = (i,j) P T. The unique path in T connecting i and j, denoted by PT(e), is called the supporting path of e (relative to 7’). The cycle CT(e) = PT(e) u {e ) is called the supporting cycle of e (relative to 7). Theorem 1. Let G = (VIE) be a minimal network. G is decomposable by a tree T if and only if every edge in E - T is redundant in its supporting cycle. Theorem 1 gives a method of testing whether a net- work G is decomposable by a given tree T. The test takes 0 (n3) time, as there are 0 (n2) edges in E - T, and each redundancy test is 0 (n). Illustration. Consider Example 1. Tree T1 = (AB, AC, AD} is a tree decomposition, since edges BC, BD and CD are redundant in triangles {A, B, C}, {A, B, D} and {A, C, D), respectively. On the other hand, T2 = (AD, BD, CD) is not a tree decomposition since edge AB is nonredundant in triangle {A, B, D ) (indeed, the tuple (A = 1, B = 0, C = 0, D = 0) is a solu- tion of T2, but is not part of pl). An important observation about redundant edges is that they can be deleted from the network without affecting the set of solutions; the constraint specified by a redundant edge is already induced by other paths in the network. This leads to the following decomposition scheme. Repeatedly select an edge redundant in some cy- cle C, delete it from the network, and continue until there are no cycles in the network. This algorithm, called TD- 1, is depicted in Figure 3. Algorithm TD-1 l.NtE; 2. while there are redundant edges in N do 3. select an edge e which is redundant in some cycle C, and 4. NtN-{e) 5. end; 6. if N forms a tree then G is decomposable by N 7. else G is not tree decomposable; Figure 3. TD-1 - A tree decomposition algorithm. Theorem 2. Let G be a minimal network. Algorithm TD- 1 produces a tree T if and only if G is decomposable by T. 12 AUTOMATEDREASONING To prove Theorem 2, we must show that if the net- work is tree decomposable, any sequence of edge remo- vals will generate a tree. A phenomenon which might prevent the algorithm from reaching a tree structure is that of a stiff cycle, i.e., one in which every edge is non- redundant (e.g. cycle {B, D, C, E} in Example 2). It can be shown, however, that one of the edges in such a cycle must be redundant in another cycle. The proof of Theorem 2 rests on the following three lemmas, which also form the theoretical basis to Section 5. Lemma 1. Let G be a path consistent network and let e = (io,im) be an edge redundant in cycle C = {io, il , . . . ,im). If C’= {io, il,. . . ,ik, &+I,. . . ,im) is an interior cycle created by chord (ik, il), then e is redundant in C’. Lemma 2. Let G be a minimal network decomposable by a tree T, and let eE T be a tree edge redundant in some cy- cle C. Then, there exists an edge e’E C, e’4 T, such that e is redundant in the supporting cycle of e’. Lemma 3. Let G be a minimal network decomposable by a tree T. If there exist eE T and e’$ T such that e is redun- dant in the supporting cycle of e’, then G is decomposable by T’= T - {e} u (e’}. Algorithm TD-1, though conceptually simple, is highly inefficient. The main drawback is that in Step 3 we might need to check redundancy against an exponential number of cycles. In the next section we show a polyno- mial algorithm which overcomes this difficulty. 5. Tree, triangle and redundancy labelings In this section we present a new tree decomposition scheme, which can be regarded as an efficient version of TD-1, whereby the criterion for removing an edge is essentially precomputed. To guide TD-1 in selecting redundant edges, we first impose an ordering on the edges, in such a way that nonredundant edges will always attain higher ranking than redundant ones. Given such ordering, we do not remove edges of low ranking, but ap- ply the dual method instead, and construct a tree contain- ing the preferred edges by finding a maximum weight spanning tree (MWST) relative to the given ordering. This idea is embodied in the following scheme. Definition Let G = (V,E) be a minimal network. A label- ing w of G is an assignment of weights to the edges, where the weight of edge eE E is denoted by w(e). w is said to he a tree labeling if it satisfies the following con- dition. If G is tree decomposable, then G is decomposable by tree T if and only if T is a MWST of G with respect to W. Finding a tree labeling essentially solves the tree decomposability problem, simply following the steps of algorithm TD-2 shown in Figure 4. TD-2 stands for a family of algorithms, each driven by a different labeling. Steps 2-4 can be implemented in 0 (n 3): Step 2 can use any MWST algorithm, such as the one by Prim, which is O(n2) (see Even 19791); Steps 3-4, deciding whether G is decomposable by T, arc 0 (n3) as explained in Section 4. Algorithm TD-2 1. w t- tree labeling of G; 2. T t MWST of G w.r.t. w; 3. test whether G is decomposable by T; 4. if the test fails G is not tree decomposable; Figure 4. TD-2 - A polynomial tree decomposition algorithm. We now turn our attention to Step 1, namely comput- ing a tree labeling. This will be done in two steps. We first introduce a necessary and sufficient condition for a labeling to qualify as a tree labeling, and then synthesize an 0 (n3) algorithm that returns a labeling satisfying this condition. As a result, the total running time of TD-2 is bounded by 0 (n3). Definition. Let G = (V,E) be a minimal network. A label- ing w of G is called a redundancy labeling, if it satisfies the following condition. For any tree T and any two edges, e’ E E - T and eE T, such that e is on the support- ing cycle Cr(e’) of e’, if G is decomposable by T then (i) w(e’) 5 w(e). (1) (ii) e is redundant in CT(e’) whenever w (e’) = w(e). (2) Theorem 3. Let w be any labeling of a minimal network G. w is a tree labeling if and only if w is a redundancy la- beling. The merit of Theorem 3 is that it is often easier to test for redundancy labeling than for the ultimate objective of tree labeling. Having established this equivalence, the next step is to construct a labeling that satisfies conditions MEIRI,PEARL,ANDDECHTER 13 (1) and (2). Definition. A labeling w of network G is a triangle label- ing, if for any triangle t= { e 1 ,e 2 ,e 3) the following condi- tions are satisfied. (i) If e 1 is redundant in t then w(ed 2 de21 , wh) 5 w(e3). (3) (ii) If e 1 is redundant in t and e2 is nonredundant in t then wh) < w(e2). (4) Conditions (3) and (4) will be called triangle constraints. Illustration. Consider the minimal network of Example 2. Analyzing redundancies relative to all triangles leads to the triangle constraints depicted in Figure 5. Each node in the figure represents an edge of the minimal network, and an arc e 1 -+ e2 represents the triangle constraint w (e 1) < w (e2) (for clarity, all arcs from bottom layer to top layer were omitted). It so happens that only strict ine- qualities were imposed in this example. A triangle label- ing w can be easily constructed by assigning the following weights: w(AB)=w(AC)=w(AD)=w(AE)=3 w(BD)=w(BE)= w(CD)=w(CE)=2 w(BC)=w(DE)= 1. Note that the tree T = {AB, AC, AD, AE), which decom- poses the network, is a MWST relative to these weights, a property that we will show to hold in general. Figure 5. Triangle constraints for Example 2. Clearly, conditions (3) and (4) are easier to verify as they involve only test on triangles. In Theorem 5 we will indeed show that they are sufficient to constitute a redun- dancy labeling, hence a tree labeling. Moreover, a label- ing satisfying (3) and (4) is easy to create primarily be- cause, by Theorem 4, such a labeling is guaranteed to ex- ist for any path consistent (hence minimal) network. Note that this is by no means obvious, because there might be two sets of triangles imposing two conflicting constraints on a pair (a,b) of edges; one requiring w(a) I w (b), and the other w(a) > w(b). Theorem 4. Any path consistent network admits a trian- gle labeling. The ic’:a behind triangle labelings is that all redun- dancy information necessary for tree decomposition can be extracted from individual triangles rather than cycles. By Lemma 1, if an edge is redundant in a cycle, it must be redundant in some triangle. Contrapositively, if an edge is nonredundant in all triangles, it cannot be redundant in any cycle, and thus must be included in any tree decom- position. To construct a tree decomposition, we must therefore include all those necessary edges (note that they attain the highest ranking) and then, proceed by preferring edges which are nonredundant relative to others. The correctness of the next theorem rests on these considera- tions. Theorem 5. Let G be a minimal network, and let w be a labeling of G. If w is a triangle labeling then it is also a redundancy labeling. By Theorems 3 and 5, if the network is minimal any triangle labeling is also a tree labeling. What remains to be shown is that, given any minimal network G = (V,E), a triangle labeling can be formed in 0 (n3) time. Algorithm TLA, shown in Figure 6, accomplishes this task. Algorithm TLA 1. create an empty directed graph G 1 = (V 1, E 1 ) with VI = E; 2. for each triangle t = (ei, ej, ek) in G do 3. if edge ei is redundant in t then addarcsei~ejandei~ektoG1; 4. G2 = (V2,E2) t superstructure of G,; 5. compute a topological ordering w for V2; 6. for i := lto IV21 do 7. for each edge e in Ci do 8. W (4 + W (Ci); Figure 6. TLA - an algorithm for constructing a triangle labeling. Let us consider the TLA algorithm in detail. First, it constructs a graph, G1, that displays the triangle con- straints. Each node in G1 represents an edge of G, and arc 14 AUTOMATEDREASONING u + v stands for a triangle constraint w(u) 5 w(v) or w(u) c w(v). The construction of G1 (Steps l-3) takes 0 (n3) time, since there are 0 (n3) triangles in G, and the time spent for each triangle is constant. Consider a pair of nodes, u and v, in G 1. It can be verified that if they belong to the same strongly-connected component (i.e., they lie on a common directed cycle), their weights must satisfy w(u) = w(v). If they belong to two distinct components, but there exists a directed path from u to v, their weights must satisfy w(u) < w(v). These relationships can be effectively encoded in the su- perstructure of G 1 [Even 19791. Informally, the super- structure is formed by collapsing all nodes of the same strongly-connected component into one node, while keep- ing only arcs that go across components. Formally, let G2 = (V2,Ez) be the superstructure of Gl. Node CiE G2 represents a strongly-connected component, and a direct- ed arc Ci + Cj implies that there exists an edge u + v in G 1, where UE Ci and VE Cj. Identifying the strongly con- nected components, and consequently constructing the su- perstructure (Step 4), takes 0 (n3) (a time proportional to the number of edges in G 1 [Even 19791). It is well-known that the superstructure forms a DAG (directed acyclic graph), moreover, the nodes of the DAG can be topologically ordered, namely they can be given distinct weights w, such that if there exists an arc i -+ j then w(i) < w 0). This can be accomplished (Step 5) in time proportional to the number of edges, namely 0 (n3). Finally, recall that each node in G2 stands for a strongly- connected component, Ci, in G 1, which in turn represents a set of edges in 6. If we assign weight w (Ci) to these edges (Steps 6-8), w will comply with the triangle con- straints, and thus will constitute a triangle labeling. Since all steps are 0 (n3), the entire algorithm is 0 (n3). Illustration. Consider Example 1. There are two strongly-connected components in G 1 : Cl = {AD, BD, CD} and C2 = (AB, AC, BC). There are edges going only from C1 to C2. Thus, assign- ing weight 1 to all edges in Cl and weight 2 to all edges in C2 constitutes a triangle labeling. Consider Example 2, for which G 1 is shown in Figure 5. Note that G 2 = G 1, that is, every strongly-connected component consists of a single node. Assigning weights in the ranges l-2,3-6 and 7-10 to the bottom, middle and top layers, respectively, constitutes a triangle labeling. 6. Exterisions and Ramifications 6. I. Decomposing a relation Given a relation p, we wish to determine whether p is tree decomposable. We first describe how TD-2 can be em- ployed to solve this problem, and then compare it with the solution presented in Dechter 19871. We start by generating the minimal network A4 from p. We then apply TD-2 to solve the decomposability problem for M. If A4 is not tree decomposable, p cannot be tree decomposable; because otherwise, there would be a tree T satisfying p = rel (T) c rel (M), violating the minimahty of M [Montanari 19743. If M is decomposable by the generated tree 7’, we still need to test whether reZ(7’) = p (note that A4 may not represent p precisely). This can be done by comparing the sizes of the two rela- tions; p is decomposable by T if and only if Ipl= I reZ(T) I. Generating M takes 0 (n2 I p I) opera- tions, while ITI can be computed in 0 (n) time [Dechter and Pearl 19871; thus, the total time of this method is O(n21pI). An alternative solution to the problem was presented in [Dechter 19871. It computes for each edges a numerical measure, w, based on the frequency that each pair of values appears in the relation. Fit, the following param- eters are computed: n Cxi = xi) = number of tuples in p in which variable Xi at- taiIlS value Xi. n Cxi = Xi,Xj = xi) = number of tuples in p in which both Xi =Xi andXj=xj. Then, each edge e = (ij) is assigned the weight w(e) = C ?Z (Xi,Xj)lOg ny:ATi ) . (5) *iJj E Xi;ui i i It has been shown that this labeling, w, is indeed a tree la- beling, also requiring 0 (n2 I p I) computational steps. Comparing the two schemes, our method has three advantages. First, it does not need the precision required by the log function. Second, it offers a somewhat more effective solution in cases where p is not available in ad- vance but is observed incrementally through a stream of randomly arriving tuples. Finally, it is conceptually more appealing, since the removal of each edge is meaningfully justified in terms of being redundant. 6.2. Reducing a network Given an arc and path consistent network R, we wish to MEIRI,PEARL,ANDDECHTER 15 determine whether R is tree reducible. This problem ad- mits TD-2 directly, since it can be shown that any path consistent network is tree reducible only when it is minimal. Thus, if TD-2 returns failure, we are assured that R is not tree reducible (though it could still be tree decomposable). 6.3. Removing redundancies from a network Given a network R (not necessarily tree decomposable), we wish to to remove as many redundant edges as possi- ble from the network. Our scheme provides an effective heuristics, alternative to that of [Dechter and Dechter 19871. We first apply the TD-2 algorithm and, in case the tree generated does not represent the network precisely, we add nonredundant edges until a precise representation obtains. 6.4. Approximating a Network Given a network R, find a tree network which constitutes a good approximation of R. The tree T generated by TD- 2 provides an upper bound of R, as it enforces only a sub- set of the constraints. The quality of this approximation should therefore be evaluated in terms of the tightness, or specificity, of T. Conjecture: The tree T generated by TD-2 is most specific in the following sense: no other tree T’, extracted form the network, satisfies reZ(T’) c reZ(T). Although we could find no proof yet, the conjecture has managed to endure all attempts to construct a counterex- ample. 7. Conclusions We have addressed the problem of decomposing a con- straint network into a tree. We have developed a tractable decomposition scheme which requires 0 (n3) time, and solves the problem for minimal networks. The technique maintains its soundness when applied to an arbitrary net- work, and is guaranteed to find a tree decomposition if it can be extracted from the input network without altering the link constraints. The main application of our scheme lies in preprocessing knowledge bases and transforming them into a very effective format for query processing. Other applications are in guiding backtrack search by tree relaxation of subproblems. Finally, we envision this tech- nique to be useful in inductive learning; especially, for learning and generalizing concepts where instances are observed sequentially. The tree generated by TD-2 pro- vides one of the simplest descriptions consistent with the observed data, and at the same time it is amenable to answer queries of subsumption and extension. References Dechter A. and Dechter R. 1987. Removing Redundan- cies in Constraint Networks. In Proceeding of AAAI-87, Seattle, WA. Dechter R. 1987. Decomposing a Relation into a Tree of Binary Relations. In Proceedings of 6th Conference on Principles of Database Systems, San Diego, CA, 185-189. To appear in Journal of Computer and System Science, Special Issue on the Theory of Relational Databases. Dechter R. and Pearl J. 1987. Network-Based Heuristics for Constraint Satisfaction Problems. Artificial Intelli- gence 34(l), l-38. Even S. 1979. Graph Algorithms. Computer Science Press, Rockville, Md. Freuder E. C. 1982. A Sufficient Condition of Backtrack- Free Search, JACh4 29(l), 24-32. Mackworth A. K. 1977. Consistency in Networks of Rela- tions. Artificial Intelligence 8(l), 99-l 18. Mackworth A. K. and Freuder E. C. 1985. The Complexi- ty of Some Polynomial Network Consistency Algorithms for Constraint Satisfaction Problems. Artijcial Intelli- gence 25(l), 65-74. Maier D. 1983. The Theory of Relational Databases. Computer Science Press, Rockville, Md. Meiri I., Dechter R. and Pearl J. 1990. Tree Decomposi- tions with Applications to Constraint Processing. Techni- cal Report R-146, Cognitive Systems Lab., University of California, Los Angeles. Montanari U. 1974. Networks of Constraints: Fundamen- tal Properties and Applications to Picture Processing. In- formation Sciences 7,95- 132. 16 AUTOMATEDREASONING
|
1990
|
7
|
989
|
Panel: User Modeling and User Interfaces Susan T. Dumais Bellcore 445 South St. Morristown, NJ 07960 std@bellcore.com The User Knows Best I will consider the problem of helping user’s retrieve information from large diverse collections of textual materials such as bibliographic databases, electronic bulletin boards and online manuals, although I believe that many of my arguments apply to other interactive environments as well. Information retrieval systems like this must handle a heterogeneous population of users, and even a single user will have a range of information needs including very specific requests as well as more general and often ill-defined topical searches. The idea of employing user models to enhance human- computer interaction in IR applications is very appealing. The hope is that some form of encapsulated knowledge about the user will mediate between user input and system responses resulting in more effective, efficient and enjoyable interactions (Rich, 1983; Sleeman, 1985). There are, however, few success stories, especially in the sense of working systems that are demonstrably better than similar systems that don’t have a user model. One reason for this, I believe, is that researchers have underestimated the difficulties involved in discovering what user characteristics are related to performance differences and, more importantly, how the system should respond to different users (i.e. what to do about it). At a more pragmatic level, obtaining information that can be used to reliably characterize different users is difficult except in the simplest cases. A system which responds differently to users who speak different languages (e.g. English vs. French) might be described as having a simple but effective ‘user model’. In this example: it is clear that language differences pose a major barrier to retrieval; detecting what language the query is in is relatively straightforward; and tailoring the system response to be in the appropriate language is easy. Handling expert-novice differences is quite difficult by comparison, but is still a relatively easy user modeling problem. How can a user’s expert or novice status regarding a particular query be detected on the basis of implicit or explicit information? How should the information presented to experts and novices differ - in amount, kind, level of detail, etc.? When does it matter? The general case of information retrieval is especially difficult because of the variety and dynamic nature of users, tasks and materials. Most existing text retrieval systems work by matching words in (or assigned to) objects against words in users’ queries. While these systems are quite useful, they are far from perfect. Many retrieval problems can be traced to the fact that individual words or phrases provide unreliable evidence about the meaning or topic of a text object. There are many places in the retrieval process where improvements could be targeted - indexing or describing text objects and user requests; matching requests and objects; modeling inter-object relationships; and supporting the search process. Proponents of user modeling have argued that better information requests could be generated by exploiting models that understand user’s goals, problem contexts, knowledge, etc. There is little evidence that such models can be successfully constructed or exploited to enhance retrieval. I agree that user’s queries are seriously deficient, but argue that the most effective tools for flexible and customizable query specification are those that give users better ways to speak for themselves. The user knows more about his/her interests, goals, and state of knowledge than could be communicated to a search intermediary, or defined, abstracted and exploited by most modeling mechanisms. Given existing query methods (e.g. generating natural language queries or complicated Boolean expressions), users find it quite difficult to describe their information needs. With appropriate tools for users to iteratively and interactively specify queries, and to view the results of searches, many of these barriers can be removed. These ideas are not new (e.g. Oddy, 1977), but there is now adequate computer power to implement and to evaluate them with large collections. Egan et al. (1989), for example, describe an online text browser, SuperBook, that was designed to enhance user’s abilities to search in and navigate through electronic texts. In behavioral studies, they found that users who searched for information using SuperBook could find answers more DUMAIS 1135 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. quickly and accurately than their counterparts who used a paper version of the same book. The advantages of SuperBook come from: full-text indexing which increases the likelihood that users will find the information they need, the posting of matched query terms against a dynamic hierarchical view of the document which enables user to quickly find the most relevant passages; and automatic page reformatting and highlighting to accentuate the users’ current search interests. The dynamic hierarchical display is a very simple kind of domain model; but it is one that users understand and can exploit. In bibliographic retrieval situations where it is more difficult to capitalize on inter- or intra-document structure other search enhancements are often quite effective. Retrieval performance can be improved by a number of automatic means that encorporate simple statistical information about the collection of objects and terms - e.g. differentially term weighting or post-coordination to rank objects from most to least similar to the query. Larger improvements (averaging about 60%) can be obtained by automatically constructing a new query based on user feedback about which of the objects returned in response to an initial query are relevant (Salton & McGill, 1983). Since user’s initial queries are usually quiet impoverished, the feedback process can be viewed as an easy and reliable method for generating rich, context-appropriate information requests. In the two cases described above, the ability of users to efficiently and effectively retrieve information was greatly enhanced by providing them with flexible methods for crafting queries and understanding the system’s responses. References Egan, D. E. et al. 1989. Formative design evaluation of SuperBook. ACM TOIS, 7(l), 30-57. Oddy, R. N. 1977. Information retrieval through man- machine dialogue. Journal of Documentation, 33, 1-14. Rich, E. 1983. Users are individuals: Individualizing user models. International Journal of Man Machine Studies, 18, 199-214. Salton, G. and McGill, M. J. 1983. Introduction to Modern Information Retrieval, McGraw-Hill, N.Y. Sleeman, D. H. 1985. UMFE: A user modelling front-end sub-system. International Journal of Man Machine Studies, 23,71-88. 1136 INVITED TALKS AND PANELS
|
1990
|
70
|
990
|
User Modeling and User Interfaces Kathleen R. McKeovm Columbia University Department of Computer Science 450 Computer Science Building New York, N.Y. 10027 MCKEOWN@CS.COLUMBIA.EDU In the past several years, it has become increasingly apparent that there is strong disagreement between researchers within and outside of AI on how to build systems for man-machine communication. Within AI, and specifically within natural language, researchers have noted that human speakers and hearers draw on their knowledge about each other when communicating. This knowledge is used both in understanding, and responding to, a speaker’s utterances. User models are a means for representing various types of information about speakers and hearers so that systems are able to reason about their users when interpreting input and producing responses. While there is disagreement in the AI community about the form of user model that should be used, there is an implicit assumption that some form of knowledge about users is essential for successful man-machine communication. In contrast, in the user interface and information retrieval community there has been a reaction against user models. Researchers in this community have argued that with a properly designed interface, users are able to get the information that they need. Modelling a user requires access to and representation of all sorts of ill-defined aspects of human cognition (e.g., how do we know when a user believes that a specific fact is true?). Rather than being so presumptuous as to assume that we can carry out such a task, why not rely on the fact that users, as humans, are smart enough to be able to use interfaces as intended to satisfy their needs? The purpose of the panel is to bring together these disparate opinions in an open forum. Are we really as far apart as we seem ? Are there opinions in the opposing viewpoints that ought be adopted by the other group? Just What Counts as a User Model? This is a good question, since every researcher has a different definition of a user model. In previous heated discussions over the pros and cons of user models, it has become apparent that sometimes what one person thinks is not part of a user model, another counts as part of a user model. There have been at least three different types of user models proposed in the literature: 0 A model that represents specific user beliefs, user goals, and possibly plans that the user has 1138 INVITED TALKS AND PANELS for achieving those goals. Often these beliefs have been inferred from previous dialog with the user. They may or may not have been explicitly stated. In some systems a distinction is made between speaker beliefs, hearer beliefs, and mutual beliefs (those beliefs that both participants recognize both hold). This trend in user modelling was initiated by Allen and Perrault [Allen & Perrault 801 and has been followed up by a variety of researchers [Carberry 83, Litman & Allen 84, Pollack 86, Sidner and Israel 811. 0 A model of different types of users that are likely to use the system. These user classes are often called stereotypes. For example, a common distinction is often made between experts and novices in the domain. The system makes assumptions about the sorts of things that a user is likely to know based on the class that s/he falls into. This class of user modelling was initiated by Rich pith 791 and also has numerous followers [Chin 86, Wallis and Shortliffe 821. 0 A model based on actual observation of the user. This may include actions the system has observed the user carrying out or assertions the user has made. For example, in a help system for software systems, the system may have access to observations about the commands and command sequences that the user has used in the past. Some researchers classify this as a discourse model [Shuster, E. 881, but it has also been used specifically as a user model wolz et al. 88, Finin 831. Questions Posed to the Panellists As moderator, I have asked the panellists to consider several questions in addition to the desirability of user models which, hopefully, will help focus discussion on the central issues. Given that there have been misconceptions in the past regarding what counts as a user model, panelists should be specific about the type of user model they support or oppose. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. While it is impossible to restrict discussion to a particular medium for interaction (e.g., menus, NL dialog) given the diversity of backgrounds, I’ve asked that we avoid discussion on which interaction medium is best for a task. Rather, we need to consider whether user models are desirable regardless of medium. Since different system tasks may all have different requirements for man-machine interaction, we will restrict ourselves to the same system tasks. In order to allow for the possibility that user modelling is more useful in some domains than others, we will use more than one task. Possibilities include information gathering (e.g., a natural language database system or information retrieval) and a tutorial system. ACKNOWLEDGMENTS Research on user modelling and language generation at Columbia is supported by DARPA contract #NOOO39-84- C-0165, ONR grant N00014-89-J-1782 and NSF grant IRT-84-5 1438. REFERENCES [Allen & Perrault 803 Allen, J.F. & Perrault, C.R. Analysing Intentions in Utterances. Artzjkial Intelligence 15(1):pages 143-178, January, 1980. [Carberry 831 Carberry, S. Tracking User Goal in an Information Seeking Environment. In Proceedings of m-83. American Association for Artificial Intelligence, 1983. [Chin 863 Chin, D. User Modelling in UC, The UNIX Consultant. In Proceedings of Computer Human Interaction, pages 24-28. Boston, Mass., 1986. CFinin 831 Finin, T. Providing Help and Advice in Task-Oriented Systems. In 8th International Joint Conference on Artificial Intelligence, pages 176-8. Karlsruhe, Germany, August, 1983. [Litman & Allen 841 Litman, D.J. and Allen, J.F. A Plan Recognition Model for Clarification Subdialogues. In Coling84, pages pages 302-3 11. COLING, Stanford, California, July, 1984. pollack 863 Pollack, M.E. A Model of Plan Inference that Distinguishes between the Beliefs of Actors and Observers. In 24th Annual Meeting of the Association for Computational Linguistics, pages pages 207-214. ACL, Columbia University, June, 1986. [Rich 791 Rich, E. User modeling via stereotypes. Cognitive Science 3(4):pages 329-354,1979. [Shuster, E. 883 Shuster, E. Establishing the Relationship between Discourse Models and User Models. Computational Linguistics 14(3):82-85, 1988. [Sidner and Israel 811 Sidner, C. and Israel D. Recognizing Intended Meaning and Speakers’ Plans. In Proceedings of the IJCAZ. International Conferences on Artificial Intelligence, August, 198 1. [wallis and Shortliffe 821 Wallis, J. and Shortliffe, E. Explanation Power for Medical Expert Systems: S&dies in the Represenatation of Causal Relationships for Clinical Consultation. Technical Report STAN-CS-82-923, Stanford Univ. Heurist. Program Proj. Dept. Med. Comput. Sci., 1982. [wolz et al. 881 Wolz, U. Tutoring that responds to users’ questions and provides enrichment. Technical Report CUCS-410-88, Department of Computer Science, Columbia University, New York, NY, 1988. Also appeared in the conference proceedings of the 4th International Conference on Artificial Intelligence and Education, May 1989, Amsterdam, The Netherlands. MCKEOWN 1139
|
1990
|
71
|
991
|
User Models and User Interfaces: A Case for Domain Models, Task Models, and Tailorability James D. Hollan Bell Communications Research 445 South Street Morristown, New Jersey 07960 hollan@bellcore.com My thesis is that the case for user models has little empirical support, necessarily must confront currently intractable problems, and is motivated by aspects of a metaphor that does not provide, at least presently, an effective base for the design of user interfaces. More positively, I argue that some of what is sought in the name of user modeling can be accomplished by basing interface design on models of application domains, user tasks, and by providing tailorable systems. I am led to this position primarily from experiences with the design of ICAI systems and construction of mul- timodal interfaces to complex systems. In the limited space of these proceedings I am confined to sketching a portion of my case against user modeling. I focus on the metaphor that I think motivates most user modeling efforts and some of its pernicious consequences. The design of user interfaces is shaped explicitly and implicitly by metaphors. My colleagues and I [Hutchins, Hollan, & Norman, 19851 have argued that there are two fundamentally different metaphors underlying interface design. We labeled them the Conversation Metaphor and the Model World Metaphor. The conversation metaphor derives its metaphorical significance from our knowledge about language. Users think of the interface as an intermediary to a world that is not explicitly represented and interact by providing the intermediary with linguistic descriptions of actions to be accomplished. The model world metaphor derives its significance from our knowledge about the world. The world is explicitly depicted, the represented objects be- have as if they were the things they refer to, and users have no experience of communicating with an intermedi- ary. Instead of providing descriptions of action, the user does them. Metaphors provide a language within the design com- munity that designers use to communicate their designs to each other. They shape the whole design process. Unfortunately, they can lead to uncritical acceptance of presuppositions. This is particularly likely when the metaphor involves aspects of cognition with which we are facile. Much of the motivation for user models comes from adopting a human to human conversation metaphor. But computers are not humans. I contend that an uncrit- ical adoption of the human to human communications metaphor has brought with it a set of unquestioned pre- suppositions that fuel the many unsuccessful attempts at user modeling and deflect effort away from more pro- ductive aspects of the conversation metaphor. Because of our familiarity with human to human communication it is easy to view human computer interfaces via the same metaphor. I think this hides an important set of presuppositions and very difficult problems that must be addressed. A number of empirical studies of advising [Hill, 19881 support these conclusions. They demonstrate that the user models people use are often flawed and even where successful are of an improvised nature that requires a di- alectic with an apparently unbounded array of common sense knowledge. These studies lead one to conclude that user modeling in even simple domains must confront the most intractable AI questions. User modeling efforts not only need to model users when they perform correctly but must contend with the virtually infinite ways users might get things wrong. In addition, they are also required to deal with all of the problems associated with the consequences of getting the model of the user wrong, or wrong in a particular con- text, as well as with the complex issues of agency that arise as soon as the system starts to dynamically modify its behavior as a function of its model of the user. Perhaps more insidiously the attempts at user mod- eling involve a dual of a questionable approach to un- derstanding cognition. Today many are questioning the wisdom of positing models in our heads of everything with which we interact and beginning to recognizing the fact that virtually every thinking task is accomplished via interactions with others and with the artifacts of our culture. The developing zeitgeist is that much is repre- sented not in our heads but in the world. This includes other individuals, the social context of activities, the in- stitutions within which activities are embedded, and the artifacts we employ in thinking and acting. References [Hill, 19881 Will’ lam Hill. Advice Seeking, Giving, and Following. Ph.D. Thesis, Northwestern University, 1988. [Hutchins, Hollan, and Norman, 19851 Edwin L. Hutchins, James D. Hollan, and Donald A. Norman. Direct Manipulation Interfaces. Human- Computer Interaction, 1~311-338, 1985. HOLLAN 1137 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved.
|
1990
|
72
|
992
|
Integrating Planning and Acting in a Case-Based Framework.* Kristian Hammond Timothy Converse Charles Martin The University of Chicago Department of Computer Science Artificial Intelligence Laboratory 1100 East 58th Street Chicago, IL 60637 ai@tartarus.uchicago.edu Abstract This paper presents an outline of a theory of agency that seeks to integrate ongoing understanding, plan- . ning and activity into a single model of representa- tion and processing. Our model of agency rises out of three basic pieces of work: Schank’s structural model of memory organization (Schank, 1982), Hammond’s work in case-based planning and dependency directed repair (Hammond, 1989d), and Martin’s work in Direct Memory Access Parsing (Martin 1990). We see this pa per as a first step in the production of a memory-based theory of agency: the active pursuit of goals in the face of a changing environment, that can exist within the computational constraints of a computer model. Planning as Understanding Research in planning has recently made a dramatic change in course. Planning researchers have begun to acknowledge that the world is too complex and uncer- tain to allow a planner to plan exhaustively for a set of goals prior to execution (Chapman, 1985). More and more, the study of planning is being cast as the broader study of planning, action and understanding (Agre and Chapman, 1987, and Alterman, 1986). The particular cast of this relationship that we have been studying is a view of planning as embedded within an understanding system connected to the environ- ment. The power of this approach lies in the fact that it allows us to view the planner’s environment, plan selections, decisions, conflicts and actions through the single eye of situation assessment and response. Be- cause of our further commitment to the use of episodic memory as the vehicle for understanding, it also pro- vides us with a powerful lever on the problem of learn- ing from both planning and execution. In this paper, we draw an outline of agency, our model of the rela- tionship between planning and action. *This work was supported in part by the Defense Ad- vanced Research Projects Agency, monitored by the Air Force Office of Scientific Research under contract F49620- 88-C-0058, and the Office of Naval Research under contract N0014-85-K-010. 292 COGNITIVE MODELING Memory and Agency Our model of planning and understanding rises out of three pieces of work: Schank’s structural model of memory organization (Schank, 1982), our own work in case-based planning and dependency directed re- pair (Hammond, 1986)) and the work of Martin and Riesbeck in Direct Memory Access Parsing (Martin 1989). Our model has been articulated in two pro- grams, TRUCKER and RUNNER (Hammond, Con- verse, and Marks, 1988 and Hammond, 1989). The model was first developed to deal with the prob- lem of recognizing execution-time opportunities in the context of a resource-bound agent that is forced to sus- pend planning in order to attend to execution (Ham- mond, 1989). The goal of this model was to capture the ability of an agent to suspend goals, yet still rec- ognize execution-time opportunities to satisfy them. To accomplish this goal, we use a single set of mem- ory structures both to store suspended goals and to understand the agent’s circumstances in the world. In response to a blocked goal, an agent’s first step is to do a planning-time analysis of the conditions that would favor the satisfaction of the goal. The agent then sus- pends the goal in memory, indexed by a description of those conditions. For example, a goal to buy eggs that was blocked during planning would be placed in mem- ory associated with the condition of the agent being at a grocery store. During execution, the agent performs an ongoing “parse” of the world in order to recognize conditions for action execution. Following DMAP (Martin, 1989), this parse takes the form of passing markers through an existing episodic memory. Because suspended goals are indexed in the memory used for understanding the world, the goals are activated when the conditions fa- voring their execution are recognized. Once active, the goals are then reevaluated in terms of the new condi- tions. Either they fit into the current flow of execution or they are again suspended. We called the initial model opportunistic memory because the agent’s recognition of opportunities de- pends on the nature of its episodic memory struc- tures. Having turned to the broader issues of inte- grating planning and action, we now refer to our work From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. as the study of agency. Direct Memory Access Processing Init ial Results Our initial implementation of opportunistic mem- ory, TRUCKER, exhibited exactly the behavior we wanted. A combined scheduling planner and execu- tive, TRUCKER was able to suspend blocked goals and then recognize later opportunities to satisfy them. It also learned plans for goal combinations that it de- termined would occur again. The recognition of oppor- tunity and the resulting learning of specific optimiza- tions rose naturally out of the agent’s ongoing under- standing of its environment. Our model of planning is case-based. Both of our planners, TRUCKER and RUNNER, plan by recall- ing existing plans that are indexed by a set of cur- rently active goals. Our initial model of this index- ing (Hammond, 1986) was based on the notion that a planner could amortize its planning efforts by caching plans in memory under descriptions of the goals that they satisfied and the problems (in the sense of inter- actions between steps of a plan) that they avoided. In TRUCKER, we worked on the idea that this method of indexing could itself be cast as a problem of char- acterizing the situations in the world under which a plan could be run. Retrieval then became a process of recognition, similar to that used in the understand- ing of the world. The result of this was that plans were cached in the same memory organization used to suspend blocked goals and to understand the changing states of the world. In TRUCKER, and later in RUNNER, we tried to address the specific problem of recognizing execution- time opportunities. In the process, however, we actu- ally built a general mechanism to control planning and action. That is, to achieve the desired execution-time opportunism, we had to build a general model of plan- ning and action based on embedding the knowledge of plans and goals, as well as the control of action itself, in a memory-based understanding system. A Model of Agency We use the term agency to comprise the spawning of goals, selection of plans, and execution of actions. Our process model of agency is based on Martin’s DMAP understander as well as its antecedent, Schank’s Dy- namic Memory. DMAP uses a memory organization defined by part/whole and abstraction relationships. Activations from environmentally supplied features are passed up through abstraction links and predictions are passed down through the parts of partially active concepts. Subject to some constraints, when a concept has only some of its parts active, it sends predictions down its other parts. When activations meet existing predictions, the node on which they meet becomes ac- tive. Finally, when all of the parts of a concept are activated, the concept itself is activated. The DMAP architecture provides a computational mechanism for specifying and applying domain- dependent information to a general memory search process. Concepts are represented in the abstraction and packaging hierarchies familiar to artificial intelli- gence researchers. This hierarchy is not only a store of content, but also provides the structure for the index- ing and application of process knowledge. Operational features In general terms, we can associate operational fea- tures of the world with the memory structures to which they refer. In language understanding, such features may include words or phrases; for planning, they may comprise detectable states of the world. We call these features operational because they can be derived from the input with little reliance on the use of memory. In general, an operational feature cannot be a necessary or sufficient condition for recognizing any particular memory structure. For example, the RUNNER project (Hammond, 1989) associates “being near the coffee pot” and “the coffee pot is empty” with the FILL-POT action of the MAKE-COFFEE plan. These two conditions are pre- sumed to be easily detectable features of the environ- ment, relying on the planner’s location and a capacity for object identification. These features are in no sense equivalent to the FILL-POT action but they are opera- tional in that they serve to recognize the applicability of that action to the achievement of the MAKE-COFFEE plan. Memory search strategies Operational features are the primitive elements out of which memory search strategies are composed. A search strategy is the specification relative to a mem- ory structure of how concepts in memory may become active. In general, a search strategy specifies other memory structures and features along with some order- ing information to direct the search. Because memory search involves recognizing a sequence of concepts, we call these search strategies concept sequences. For example, in language analysis, the original do- main of the DMAP work, two simple concept sequences associated with the memory structure for the commu- nication event MTRANS are the following. { (actor) “says” (info) }, representing that an MTRANS concept can be recognized as a result of recognizing, in sequence, a concept filling actor role of the MTRANS, the lexical item “says” (an operation feature for a language analyzer), and a concept filling the info role of the MTRANS. HAMMONDETAL. 293 The organization of memory Because DMAP associates search strategies with specific concepts in memory, those concepts serve as the points of organization for expectations generated by the system. For example, RUNNER places expecta- tions for the FILL-POT action on the memory structures for ‘being near the coffee pot” and “the coffee pot is empty”. Because these memory structures already ecist in the system and serve as the organizing point for these ex- pectations, the memory itself provides the medium for disambiguating which expectations are relevant in any situation. Expectations from existing memory struc- tures prime other existing memory structures. Acti- vation of an existing memory structure allows the sys- tem to focus on those and only those expectations that primed that particular memory structure. Accomodating action To accommodate action, we have added the notion of PERMISSIONS. PERMISSIONS are handed down the parts of plans to their actions. The only actions that can be executed are those that are PERMITTED by the activation of existing plans. Following McDer- mott (McDermott, 1978), we have also added POLI- CIES. POLICIES are statements of ongoing goals of the agent. Sometimes these take the form of maintenance goals, such as “Glasses should be in the cupboard.” or “Always have money on hand.” The only goals that are actively pursued are those generated out of the interaction between POLICIES and environmental fea- tures. We would argue that this is, in fact, the only way in which goals can be generated. Most of the processing takes the form of recogniz- ing circumstances in the external world as well as the policies, goals and plans of the agent. The recognition is then translated into action through the mediation of PERMISSIONS that are passed to physical as well as mental actions. Goals, plans, and actions interact as follows: l Features in the environment interact with POLI- CIES to spawn goals. For example, in RUNNER, the specific goal to HAVE COFFEE is generated when the system rec- ognizes that it is morning. The goal itself rises out of the recognition of this state of affairs in combi- nation with the fact that there is a policy in place to have coffee at certain times of the day. l Goals and environmental features combine to ac- tivate plans already in memory. Any new MAKE-COFFEE plan is simply the active tion of the sequence of actions associated with the existing MAKE-COFFEE plan in memory. It is re- called by RUNNER when the HAVE-COFFEE goal is active and the system recognizes that it is at home. l Actions are permitted by plans and are asso- ciated with the descriptions of the world states 294 COGNITIVE MODELING Actions are specialized by features in the environ- ment and by internal states of the system. As with Firby’s RAPS (Firby, 1989), particular states of the world determine particular methods for each general action. For example, the specifics of a GRASP would be determined by information taken from the world about the size, shape and location of the object being grasped. e Action level conflicts are recognized and mediated using the same mechanism that recognizes infor- mation about the current state of the world. For example, when two actions are active (such as filling the pot and filling the filter), a media tion action selects one of them. During the initial phases of learning a plan, this can in turn be trans- lated into a specialized recognition rule which, in the face of a conflict, will always determine the ordering of the specific actions. Finally, suspended goals are associated with the descriptions of the states of the world that are amenable to their satisfaction. For example, the goal HAVE-ORANGE-JUICE, if blocked, can be placed in memory, associated with the conjunct of features that will allow its satisfac- tion, such as being at a store, having money and so forth. Once put into memory, this conjunct of features becomes one of the set that can now be recognized by the agent. The Study of Agency We do not see this model as a solution to the prob- appropriate to their performance. Once a set of features has an action associated with it, that set of features (in conjunct rather than as individual elements) is now predicted and can be recognized. Filling the coffee pot is permitted when the MAKE-COFFEE plan is active; it is associated with the features of the pot being in view and empty. This means not only that the features are now pre- dicted but also that their recognition will trigger the action. lems of planning and action. Instead, we see this as a framework in which to discuss exactly what an agent needs to know in a changing world. Advantages of this framework include: 1. A unified representation of goals, plans, actions and conflict resolution strategies. 2. Ability to learn through specialization of general techniques. 3. A fully declarative representation that allows for meta-reasoning about the planner’s own knowl- edge base. 4. A simple marker-passing scheme for recognition that is domain - and task - neutral. 5. Provision for the flexible execution of plans in the face of a changing environment. The basic metaphors of action as permission and recognition, and planning as the construction of de- scriptions that an agent must recognize prior to ac- tion, these fit our intuitions about agency. Under this metaphor, we can view research into agency as the ex- ploration of the situations in the world that are valu- able for an agent to recognize and respond to. In par- ticular, we have examined and continue to explore con- tent theories of: The conflicts between actions that rise out of re- source and time restrictions as well as direct state conflicts and the strategies for resolving them. The types of physical failures that block execution and their repairs. The types of knowledge-state problems that block planning and their repairs. The circumstances that actually give rise to goals in the presence of existing policies. The possible ways in which existing plans can be merged into single sequences and the circum- stances under which they can be applied. The types of reasoning errors that an agent can make and their repairs. The trade-offs that an agent has to make in deal- ing with its own limits. The different ways in which a goal can be blocked and the resulting locations in memory where it should be placed. Our goal is a content theory of agency. The archi- tecture we suggest is simply the vessel for that content. RUNNER Most of our activity in studying this architecture has been within the context of the RUNNER system. The RUNNER project is aimed at modeling the full spec- trum of activity associated with an agent-goal gener- ation, plan activation and modification, action execu- tion, and resolution of plan and goal conflict-not just the more traditional aspect of plan generation alone. RUNNER’s world The agent in RUNNER currently resides in a simulated kitchen, and is concerned with the pursuit of such goals as simulated breakfast and coffee. Such commonplace goals and tasks interest us in part because they are repetitive and have many mutual interactions, both negative and positive. We are interested in how plans for recurring conjuncts of goals may be learned and re- fined, as part of view of domain expertise as knowledge of highly specific and well-tuned plans for the particu- lar goal conjuncts that tend to co-occur in the domain (Hammond, Converse, and Marks, 1988). We are also interested in the issue of exactly how these plans can be used in the guidance of action. RUNNER’s Representation The knowledge and memory of the agent is captured in the conjunction of three types of semantic nets, rep- resenting knowledge of goals, plans and states. Nodes in these networks are linked by abstraction and pack- aging links, as in DMAP. In addition, we propose an additional SUSPEND link, which connects suspended goals to state descriptions that may indicate opportu- nities for their satisfaction. For example, the goal to have eggs would be suspended in association with the description of the agent being at a grocery store. In addition to being passed to abstractions of activated concepts, activation markers are always passed along SUSPEND links. In general, the only other way in which these nets are interconnected is via concept sequences. A node may be activated if all of the nodes in one of its con- cept sequences is activated - a concept sequence for a given node can contain nodes from any of the parts of memory. The following is a partial taxonomy of the types of concept sequences we currently allow: e Activation of a goal node can activate a node rep- resenting a default plan. Ed Activation of a plan node and some set of state nodes can activate a further specialization of the plan. a Activation of a goal node and some set of state nodes can activate a further specialization of the goal. e Activation of any state node that has a SUSPEND link will activate the associated goal. An Example: Making Coffee The above discussion of representation may make more sense in the context of an example, currently imple- mented in RUNNER, of how a particular action is sug- gested due to conjunction of plan activation and envi- ronmental input. One of the objects in RUNNER’S simulated kitchen is a coffeemaker, and one of the plans it has available is that of making coffee with this machine. This plan involves a number of subsidiary steps, some of which need not be ordered with respect to each other. Among the steps that are explicitly represented in the plan are: fetching unground beans from the refrigerator, putting the beans in the grinder, grinding the beans, moving a filter from a box of filters to the coffeemaker, filling the coffeemaker with water from the faucet, moving the ground beans from the grinder to the coffeemaker, and turning the coffeemaker on. The subplans of the coffee plan are associated with that plan via packaging links. In this implemented example, the agent starts out with a node activated which represents knowledge that it is morning. This HAMMONDETAL. 295 in turn is sufficient to activate the goalto have coffee (this is as close as the program comes to a theory of addiction). This goal in turn activates a generic plan to have coffee. This turns out to be nothing but an abstraction of several plans to acquire coffee, only one ofwhich is the plan relevant to our kitchen: Sending initial activations to memory sending activation marker to [morning3 Activating concept: [morning] concept sequence ([morningI) for node [GOAL: drink-coffee] is completed. sending activation marker to [GOAL: drink-coffee] Activating concept: [GOAL: drink-coffee] Asserting new goal: [GOAL: drink-coffee] sending activation marker to [PLAN: coffee-plan] Node [PLAN: coffee-plan] has both permission and activation: ((MARKER [GOAL: drink-coffee])) (TOP-LEVEL-PLAN) Activating concept: [PLAN: coffee-plan] Asserting new plan: [PLAN: coffee-plan] Plan has no steps -- insufficiently specific “Visual” input, in terms of atomic descriptions of recognizable objects and their proximities, is passed to memory. For example, the agent “sees” the following visual types: countertop, white wall, box of filters Among sets of possible visually recognized objects are concept sequences sufficient for recognition that the agent is in the kitchen. The recognition of the white wall and the countertop completes one of these sequences. The “kitchen” node in turn passes activa- tion markers to its abstractions, activating the node corresponding to the agent being at home: Straight ahead I see: a countertop, up close; a countertop, fairly close; a green square filter-box, up close; a countertop, fairly close; a countertop, far away; a white wall, far away; a countertop, fairly close; a countertop, far away; a white wall, far away To the left is a countertop, up close To the right, there's a countertop, up close Straight ahead, there's a countertop, up close ------------------------------------------------ MEMORY : Active plans: coffee-plan sending activation marker to [wall] Activating concept: [wall] sending activation marker to [filter-box] Activating concept: [filter-box] sending activation marker to [counter-t opl Activating concept: [countertop] concept sequence ([wall] Ccountertopl) for node [in-kitchen] is completed. sending activation marker to [in-kitchen] Activating concept: [in-kitchen] 296 COGNITIVEMODELING sending activation Activating concept : marker to [at-home] [at-home] The activation of this node in conjunction with the activation of the generic coffee goal completes the con- cept sequence necessary for the goal for making coffee at home, which in turn activates the default plan for that goal. In this way a specialized plan is chosen in response to a conjunction of a recognized state and a more generic goal: MEMORY : concept sequence ([GOAL: drink-coffee] [at-home]) for node [GOAL: drink-coffee-at-home] is completed. sending activation marker to [GOAL: drink-coffee-at-home] Activating concept: [GOAL: drink-coffee-at-home] Asserting new goal: [GOAL: drink-coffee-at-home] sending activation marker to [PLAN: make-coffee-at-home] Node [PLAN: make-coffee-at-home] has both permission and activation: ((MARKER [GOAL: drink-coffee-at-home])) (TOP-LEVEL-PLAN) Activating concept: [PLAN: make-coffee-at-home] The activation of the coffee-plan causes permission markers to be sent down packaging links to the nodes representing the parts of the plan. The activation of the other object concepts from the “visual” input in turn have sent activation markers to the actions that containthemintheir concept sequences. Among these is the plan step for taking a filter from the box and installing it in the coffeemaker, which is activated by seeing box of filters itself. In this way a sub-plan is sug- gested by the intersection of permissionfromits parent plan and cues from the environment that indicate that it is easily satisfiable: Asserting new plan: [PLAN: make-coffee-at-home] Sending permissions to steps of plan Sending permission markers from [PLAN: make-coffee-at-home] to steps FILL-CARAFE PDT-BEANS-IN-GRINDER MOVE-GROUNDS-TO-COFFEE-MAKER TURN-ON-COFFEE-MAKER GRIND-BEANS PUT-IN-FILTER GET-COFFEE-BEANS concept sequence ([filter-box] [PLAN: make-coffee-at-home]) for node [PLAN: put-in-filter] is completed. sending activation marker to [PLAN: put-in-filter] Node [PLAN: put-in-filter] has both permission and activation: ((MARKER ([filter-box] [PLAN: make-coffee-at-home]))) ((MARKER [PLAN: make-coffee-at-home])) Activating concept: [PLAN: put-in-filter] Asserting new plan: [PLAN: put-in-filter] Sending permissions to steps of plan Sending permission markers from [PLAN: put-in-filter] to steps PUT-FILTER-IN-COFFEEMAKER GET-FILTER concept sequence ([filter-box] [PLAN: put-in-filter]) for node [PLAN: get-filter] is completed. sending activation marker to [PLAN: get-filter] Node [PLAN: get-filter] has both permission and activation: ((MARKER ([filter-box] [PLAN: put-in-filter]))) ((MARKER [PLAN: put-in-filter])) Activating concept: [PLAN: get-filter] After another level of passing permission markers to sub-plans, the process “bottoms out” in the sugges- tion of the primitive action of picking up the box of filters. With no suggestions to the contrary, the action is taken: Asserting new plan: [PLAN: get-filter] Sending permissions to steps of plan Sending permission markers from [PLAN: get-filter] to steps TAKE-OUT-FILTER PICK-BP-BOX LOOK-FOR-FILTER-BOX concept sequence ([filter-box] [PLAN: get-filter]) for node [PLAN: pick-up-box] is completed. sending activation marker to [PLAN: pick-up-box] Node [PLAN: pick-up-box] has both permission and activation: ((MARKER ([filter-box] [PLAN: get-filter]))) ((MARKER [PLAN: get-filter])) Activating concept: [PLAN: pick-up-box] Suggesting action: (GRASP 'FILTER-BOX) ------------------------------------------------ ACTION: Performing action: (GRASP 'FILTER-BOX) ------------------------------------------------ To the left is a countertop, up close To the right, there's a countertop, up close Straight ahead, there's a countertop, up close Result of action: I'm holding on to a filter-box The final action is chosen both on the basis of ac- tive plans and goals, and in response to the immediate circumstances in which the agent finds itself. Given a change in either the top-down- -guidance or the bottom- up recognition, the selection of plan and action will change in response. Conclusion We’ve presented a sketch of an architecture for mem- ory that we believe will be of use in exploring various issues of opportunism and flexible plan use. We do not view the architecture as a solution to the problems of interest, but instead as a framework that may be use- ful in exploring content theories of plan types, action suggestion and arbitration. As we said before, our goal is a content theory of agency. The architecture we sug- gest is simply the vessel for that content. Acknowledgements This work is the first stage of a collaborative effect at the University of Chicago. As such this paper owes much to Christopher Owens and Phil Agre as well as to Mitchell Marks and the others students at the Uni- versity of Chicago’s Artificial Intelligence Laboratory. References Phil Agre and David Chapman. Pengi: An imple- mentation of a theory of activity. In Proceedings of the Sixth Annual Conference on Artificial Intelligence, pages 268-72. AAAI, 1987. L. Birnbaum and G. Collins. Opportunistic planning and freudian slips. In Proceedings of the Sixth Annual Conference of the Cognitive Science Society, Boulder, co, 1984. David Chapman. Nonlinear planning: A rigorous reconstruction. In Proceedings of the Ninth Inter- national Joint Conference on Artificial Intelligence, pages 1022-24. IJCAI, 1985. R. J. Firby. Adaptive execution in complex dynamic worlds. Research Report 672, Yale University Com- puter Science Department, 1989. Kristian J. Hammond. Case-Based Planning: View- ing Planning as a Memo y Task, volume 1 of Perspec- tives in Artificial Intelligence. Academic Press, 1989. Kristian J. Hammond. Opportunistic memory. In Proceedings of the Eleventh International Joint Con- ference on Artificial Intelligence. IJCAI, 1989. Kristian J. Hammond. Explaining and repairing plans that fail. Artifical Intelligence Journal, In Press. Kristian J. Hammond, Tim Converse, and Mitchell Marks. Learning from opportunities: Storing and reusing execution-time optimizations. In AAAI 1988, pages 53640. AAAI, 1988. Charles E. Martin. Direct Memory Access Parsing. PhD thesis, Yale University Department of Computer Science, 1989. D. McDermott. Planning and acting. Cognitive Sci- ence, 2, 1978. Roger C. Schank. Dynamic Memory: A Theory of Re- minding and Learning in Computers and People. Cam- bridge University Press, 1982. HAMMONDETAL. 297
|
1990
|
73
|
993
|
A Method of Calculating the Measure of Salience in Understanding Metaphors IWAYAMA Makoto and TOKUNAGA Takenobu and TANAKA Hozumi Tokyo Institute of Technology 0-OKAYAMA, 2-12-1 MEGURO-KU, TOKYO, 152, JAPAN iwa@cs.titech.ac. jp Abstract This paper presents a computaional method of cal- culating the measure of salience in understand- ing metaphors. We mainly treat metaphors in the form of “A is (like) B ,” in which “A” is called tar- get concept, and “B” is called source concept. In understanding a metaphor, some properties of the source concept are transferred to the target con- cept. In the transfer process, we first have to select the properties of the source concept that can be more preferably transferred to the target concept. The measure of salience represents how typical or prominent the property is and is used to measure the transferability of the property. By introducing the measure of salience, we have to consider only the high salient properties after the selection. The measure of salience was calculated from Smith & Medin’s probabilistic concept[l2, 131 according to Tversky’s two factors[l4]. One is intensity which refers to signal-to-noise ratio; this is calculated from the entropy of properties. The other is di- agnostic factor which refers to the classificatory significance of properties; this is calculated from the distribution of the property’s intensity among similar concepts. Finally we briefly outline the whole process of understanding metaphors using the measure of salience. Introduction Natural language is a rich source of metaphors, and metaphors have strong relationship with the concep- tual structure that has been acquired through our ev- eryday life[7]. For this reason, we should consider metaphors to develop a better natural language un- derstanding system. In this paper, we mainly treat metaphors in the form of “A is (like) B,” in which “A” is called target concept, and “B” is called source concept. We consider the un- derstanding metaphor as a transfer process of proper- ties from the source concept to the target concept. For example, in the case of “A man is a wolf,” some prop- erties of “wolf” - “being vicious, dangerous, fierce, etc.” are transferred to “man.” As a consequence of 298 COGNITIVE MODELING the transfer, “man’s” properties “being vicious, dan- gerous, fierce, etc.” are highlighted. This transfer process consists of the following three steps. First, we have to select properties of the source concept tl1a.t can be transferred to the target concept. We call this step selection step. Secondly, we have to find the properties of the target concepts which corre- spond to the properties selected in the selection step. We call this step mapping step. Finally, we have to highlight or downplay the properties of the target con- cept according to the corresponding properties of the source concept. We call this step variance step. These steps are very similar to that of analogical reasoning[4]. In this paper, we focus on the selection step and show how this step is achieved. In the selection step, we have to select the proper- ties of the source concept that can be more preferably transferred to the target concept. We introduce the measure ofsalience that measures the transferability of the property. Generally, the measure of salience repre- sents how typical or prominent the property is. By in- troducing the measure of salience, we have to consider only the high salient properties after the selection step. There are many properties that play little importance during the whole process of understanding metaphors. With respect to the above example, “wolf’s” proper- ties “being vicious,” “being fierce,” “being dangerous” are high salient properties and are more likely to be transferred to “man.” On the other hand, “having two eyes, ” “having four legs,” etc. are low salient proper- ties and cut off at the selection step. Many researchers have used salience in the process of understanding metaphors[lO, 9, 151, but they have not described precisely how salience is calculated. It is nec- essary to show the foundation which salience was based on and the method of calculating salience based on the foundation. In this paper, we propose a method to cal- culate the measure of salience from Smith & Medin’s probabilistic concept[l2, 133 which has a grounding in probability theory. According to Tversky[l4], we cal- culate the measure of salience in terms of two factors. One is intensity which refers to the signal-to-noise ra- tio; this is calculated from the entropy of properties. The other is diagnostic factor which refers to the clas- From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. sificatory significance of properties; this is calculated from the distribution of the property’s intensity among similar concepts. Finally we briefly outline the whole process of understanding metaphors using the measure of salience. Probabilistic concept and the Measure of Salience In this section, we describe our method of calculat- ing the measure of salience. First, we briefly re- view probabilistic concept that Smith & Medin have proposed[l2, 131. 0 ur measure of salience is calculated based on the probabilistic concept. Probabilistic Concept Probabilistic concept is composed of a set of proper- ties, each of which has an attribute with a set of pos- sible values. Probability is attached to each value. We use probabilistic concept as our concept representation form, because: o Probabilistic concept is not “all or none” concept, and this feature is necessary to calculate the measure of salience as ranging from 0 to 1. o Once probabilities are attached to attribute’s values, they can be treated formally based on probability theory. We give a definition of concept, which is slight different from Smith & Medin’s original definition. D efiuition 1 Concept A Concept denoted by *(C) is a set of properties Si. *(C)= {Sl,S2,...,SrJ A property Si is a pair of an attribute ai and its possible value set Vi. Si = CLi Z V;: The possible value set Vi is a set whose element is a pair of ai’s possible value vi,j and its probability wi,j among the Vi. K = (Vi,l#Wi,l, - - * Y Vi,j#W,j3 - - - 9 Vi,m #wi,ml That is, m IE Wi,j = 1 j=l Most Likelihood Vulue(MLV) vi,naat is the value with the highest probability among a possible value set Vi, and Most Likelihood Property(MLP) Si,mac is the pair of attribute ui and its MLV v~,,~~~~ and is denoted by ai : Vi,max- Following is an example of *(Apple). Example 1 Definition of *(Apple) red#O.8 color : green#0.15 brown#0.05 round#0.95 *(Apple) = shape : cyIindricaI#0.05 > texture : i smooth#0.9 rough#O.l > . . . “color : {red#O.S, green#0.15, brown#0.05)” is a property, and “{red#O.S, green#0.15, brown#0.05)” is its possible value set, where each real number is the probability of the value. “red” is the MLV and “cobor : red” is the MLP. The probability attached to the each value can be understood as the rate of the concept’s instances which was observed to have the value. For example, one who has the above representation observed 80% of the “ap- ples” as “red apples.” The Measure of Salience Each property has a measure of salience which is a real number ranging from 0 to 1. 0 and 1 represents the lowest and the h ighest salience respectively. The measure of salience represents the typicality of a prop- erty and is used in understanding metaphors to decide which properties of a source concept might be more preferably transferred to a target concept. Many re- searchers have used the measure of salience in the same way a.s mentioned above[lO, 9, 151, but they have not shown the precise method to calculate the measure of salience. In the field of cognitive psychology, Tversky have pointed out the qualitative nature of salience[l4]. Tversky says that salience is determined by two types of factors; intensitive and d iagnostic. The former refers to the sihnal-to-noise ratio and the later refers to the classificatory significance of properties. In the follow- ing sections, we show the method of calculating the measure of salience according to Tversky’s two factors. Intensitive factor is calculated based on the entropy in information theory, and we call this measure the Amount of Infomaution of Property(AIP). Another di- agnostic factor is calculated based on the distribution of a property’s AIP among similar concepts, and we call this measure the Difference of Property(DP). The Amouut of Iuformation of l?roperty(AIP) The first factor in calculating the measure of salience is the amount of information which a property has. This is calculated by the entropy of a possible value set 14. Because the entropy is a measure of randomness, the lower the entropy is, the less random a possible value set Vi is, that means Vi has more redundant in- formation. Intuitively, more redundant Vi means that its MLV v+,,, occurs more frequent comparing with other values of I/;:. It follows that the property Si with more redunda.nt Vi is the more typical and salient prop- er ty. IWAYAMAETAL. 299 For example, compare the following two properties, Sl = color : VI and S2 = color : Vz. V2=(red#O.G,green#O.4} In these two possible value sets, probability of each MLV “red” are the same 0.6. But if we take account of the distribution of all elements in each possible value set, MLV of VI occurs more redundantly than that of V2 because, the degree of concentration of VI is higher than that of Vz. In fact entropy (relative entropy) of VI (i.e. 0.7627 according to the definition below) is lower than that of Vz (i.e. 0.9705), and it shows that VI is more redundant and has more information than v,. Definition 2 The amount of information of prop- erty (AIP) Given a property Si = ai : vi, in which vi = {%,l#W,l, %,2#W,2, . * f 7 ‘ui,rn#Wi,rn) the AIP of Si is denoted by r(E) and calculated by the following expression: r(K) = 1- h(K) where h(Vi) is 0 ifm=l h(V;:) = H(Vi) log2 m otherwise. H(V;:) is H(Q) = 2 w~,~ log, 1 j=l Wi,j r(K), h(K) and H(K) are called “redundancy,” “rela- tive entropy,” and “entropy” respectively in the infor- mation theory[8]. The AIP ranges from 0 to 1 depending on the di- versity of a possible value set. If the diversity of a possible val ue set concentrates on only one value - for example 2 : {a#l, b#O, c#O, d#O), the prop- erty has the highest AIP 1, because all instances has the value a: To the contrary, if the diversity of a possible value set is averaged - for example x : { a#O.25, b#O.25, c#O.25, d#O.25}, the property has the lowest AIP 0, because one can not successfully predict which value a instance has. Example 2 Calculation of AIP Consider the following three possible value sets which are the value of attribute “color” of some fruits. V Color-of Strawberry- -{red#0.9,purple#O.l} V~o~or-,,f,~rape={violet#0.7,green#0.2,red#0.1) Each AIP becomes, ~(VCoZormof -Apple 1 =l- 0.8xlog2 $8+0.15x1og2 7&-+o.05xlog2 hzo 4431 'O&23 . L r(VColor&f Strawberry) =l- 0.9x log2 &+0.1x log2 $r log22 . =0.5310 f(VCoIor2f -Grape > =l- The Difference of Property(DP) The second fac- tor in calculating the measure of salience is the differ- ence of a property among similar concepts. It is the dis- tribution of a property’s AIP among similar concepts. Intuitively, the more distinguished property from other similar concepts has the higher value of DP and this property becomes higher salient. Definition 3 The Difference of Property(DP) Given a concept *(C)‘s property Si = CL~ : K and a set of similar concepts Sim(*(C)) including *(C), the DP of the Si is denoted by d(Si) and calculated by the following expression: . ’ d(Si) = $4) c *(cj)Esirra(*(c>) c SkE*(Cj) rl(Sk, Si) where r’(Sk , Sa) is calculated by the following expres- sion: if Sk,naaa: = Si,maz otherwise. In this paper, we define the similar concepts as the concepts that has the same parent node in the IS-A hierarchy. For example, the DP of “color of apple” becomes The AIP of “color of apple” c The AIP of “color of fruit” whose MLP is “color:red” ’ because similar concepts of “apple” are “fruits,” and the MLP of “color of apple” is “color:red,” Example 3 Calculation of DP In this example we calculate the DPs of *(Apple)‘s properties, SAlor-of-apple and Sshape-of-applk- B&h property’s MLPs are “color : red” and “shape : round” respectively. Figure 1 shows the similar con- cepts of *(Apple) - these are the child concepts of *(Fruit) - and the AIPs of “color of fruit” whose MLP is “color:red” and the AIPs of “shape of fruit” whose MLP is “shape:round.” Blank spaces represent that the concepts do not have the property whose MLP is “color : red” or “shape : round?‘. For example the MLP of Seolor,of~enaon is “color : yellow” and so the place corresponding to this property is blank space. This is because such a property pla.ys no role in calcu- lation of the DP of Seolor,of~pple. The DPs Ofseolor,of-apple and Sshape-of-apple are Cal- culated as follows. d(Sshape-of -apple)= a.7 0.7136 136+0.65&6+l+0.7577+0.7577+0.1161=0~16g7 Note that because there are less “red fruits” than “round fruits,” the DP of “color of apple” has higher score than that of “shape of apple.” 300 COGNITIVEMODELING *(Fruit) shape:round color: red @wle) 0.7136 0.4421 (Strawberry) 0.5310 (Watermelon) 0.8586 (Lemon) (Melon) 1 (Orange) 0.7577 (Banana) (Grape) (Pear) 0.7577 (Peach) 0.1181 Figure 1: *(Apple)‘s similar concepts The DP ranges from nearly equal to 0 to 1. If a MLP of a property is the unique MLP among simi- lar concepts, this property is the most distinguished property and the DP of this property becomes 1. For example the MLP of penguin “can-fly : no” is in this case, because all other birds have the different MLP “can-fly : yes.” To the contrary, if every similar con- cepts has the same MLP, the DP of the property which has the MLP become nearly equal to 0. For example, because all fruits have the MLP “have-seed : yes,” the DP of this property of apple becomes nearly equal to 0. The measure of salience of properties The mea- sure of salience of a property is calculated by the fol- lowing definition. Definition 4 The measure of salience of a property The measure of salience of a property Sa is calculated by the following expression: sudience(Sa) = r(Vi) x d(Si) Because d( Si) is the rate of r(K) occupying among similar concepts, sulience( Si) represent the apparent AIP in similar concepts. For example, if d(Si) is 1, Sd is the most distinguished property and the apparent AIP is the same as the net AIP (i.e. r(q)) itself. If d(Si) is much lower, there are many similar concept that have the same MLP of Si and the apparent AIP becomes lower than the net AIP. Example 4 Calculation of the measure of salience Using the results obtained by example 2 and 3, we can calculate the measure of salience of properties S color-of-apple and Stezture,of-apple- S~~ienCe(Sco~or,~,pp~e) = 0.4421 X 0.4543 = 0.2008 Sulience(Sshape~f-apple) = 0.7136 X 0.1697 = 0.1211 While the net AIP of Sshapedj,apple (i.e. 0.7136) is higher than that of Scolor,of~apple (i.e. 0.4421), the apparent AIP - that is the measure of salience - of Sshape~~,apple becomes lower. This is because the effect of the lower DP of S~~ape,of,apple. The process of understanding metaphors is very simi- lar to analogical reasoning[4]. There are four steps in understanding metaphors. In these four steps, the last three steps correspond to the property transfer process. 1) 2) 3) 4 Extraction step: Extracts a Source concept and a Target concept from surface sentence. Selection step: Selects the properties of the source concept that are transferable to the target concept. (Calculating salience of source concept’s properties) Mapping step: Finds the properties of the target concept that correspond to the selected properties in the selection step. Variance step: Highlight and downplays the prop- erties of the target concept that are found in the mapping step. Using the Measure of Salience in Understanding Metaphors In this section we describe the overview of our metaphor understanding system AMUSE and explain how the measure of salience is used in AMUSE. The Overview of AMUSE As to analogical reasoning, step l), step 2), step 3) 4) are corresponding to Retrieval step, Elaboration step, Mapping and justification step respectively[5]. We have focused on the step 2) and shown the method of calculating the measure of salience. We think that the higher salient the property is, the more preferably the property can be transferred. Now, we show the other steps briefly in understand- ing the following metaphor. (1) Mary’s cheeks are like apples. Form this sentence, AMUSE first extract a view- point expression. This process corresponds to step 1). The viewpoint expression is denoted by *(Target) \ *(Source) and means the *(Target) viewed from ii(Scy;e). In this case *(Cheek) \ *(Apple) is ex- . In the selection step, AMUSE calculates the mea- sure of salience of the properties of *(Apple). For the limitation of space we consider only the following five properties. S~lienc~(Sco~or~o~~app~e) = 0.2008 SUdie?ZCe(Sshape,of,apple) = 0.1211 SUlie?ZCe(S~aste~of~appre> = 0.1153 Sulience(Ste~ture,of,pple) = O-1062 sulience(Sh asseed-of-apple) = O-06244 These five properties are rated according to the mea- sure of salience, and AMUSE send the properties to the mapping step in this order. AMUSE has the parameter of threshold which cut off the lower salient properties. In this example if we set the value of threshold to 0.1, Iww~~AETAL. 301 then only the first four properties are sent to the map- ping step. The mapping step finds the property of *(Cheek) which corresponds to the property of *(Apple) selected in the previous step. If both property have the same attribute name and the same value which is equal to the MLV of a property of *(Source), AMUSE finds there is a correspondence between both properties. For example, Scolor,of,apple and Scolor,of,cheek are S color-of Apple = {red#O& green#0.15, brown#0.05} S color-of -cheek = {yellow#O.S,pale#O.l, red#O.l} Since these two possible value sets have the same value “red” which is the MLV in S’color,ofapple, there is a correspondence between Scolor,of~heek: and Scolor-of Apple - Among selected four proper- ties Scolor,ofapple, Sshapedf -apple, Stemture,of-apple and S taste-of -apple, the Staste,ofapple is dropped at the mapping step because there is no corresponding prop- erty in *(Cheek). In this case *(Cheek) does not have the attribute “taste.” In the variance step, AMUSE changes the diversity of the properties of *(Cheek) found in the mapping step. For example, in the most simplest version of AMUSE, Scolor,of -cheek shown above is changed to S color-of -cheek = { yellow#O, pade#O, red#l} The value of ScolOr,of Lheek - “red” which correspond- ing to the MLV of Seolor,of~pple is highlighted and the other values - “yeblow” and “pale” are downplayed. Finally, we get the following representation of *(Cheek) \ *(Apple) as the result of understanding the metaphor (1). *(Cheek) \ *(Apple) = color : In the representation, underlined value is highlighted and others are downplayed according to the high salient properties of *(Apple). The role of salience in understanding metaphors There are two advantages to use the measure of salience in understanding metaphors. One is as the measure of preference used in the selection step, which has been described in this paper. The other is as the measure to discern three types of sentences - literal _- sentences, metaphors and anomalies. AMUSE is a system which can understand not only metaphors but also literal sentences and anomalies based on the same framework. Many systems have a special device for understanding metaphors, and it is necessary to determine whether an input sentence is a metaphor or not before processing[l, 21. But there does not exist the clear boundary between metaphors and literal sentences, anomalies. AhlUSE does not dis- cern the three types of sentences before processing and all of these are processed in terms of the same transfer process. For example in the case of a literal sentence (2) I saw the girl with a telescope., two viewpoint expressions *(Telescope) \ *(Tool) and *(Telescope) \ *(Thing) are extracted. In the case of a anomaly (3) Mary’s cheeks are like bananas., the viewpoint expression *(Cheek) \ *(Banana) is ex- tracted. In the case of the metaphor (l), the viewpoint expression *(Cheek) \ “(Apple) is extracted. In pro cessing these viewpoint expressions, high salient prop- erties of the source concept can be transferred to the target concept as described in the previous section. Considering the percentage of the actually transferred properties among the selected properties in the se- lection step, almost all properties are transferred in processing *(Telescope) \ *(Tool) and *(Telescope) \ *(Thing). To the contrary, almost all properties are not transferred in processing *(Cheek) \ *(Banana). We define the Comprehensibility of Viewpoint expres- sion(CV) as representing this percentage. Following is the definition of the CV. Definition 5 The Comprehensibility of Viewpoint expression The CV of the *(A) \ *(B) is calculated by the fol- lowing expression. c The AIP of the property of *(B) which is actually transferred to *(A) c The AIP of the selected property of *(B) in the selection step The CV is the flowing rate of information of the properties in the transfer process. Some properties se- lected at the selection step are cut off at the map- ping step. In literal sentences, the CV of its viewpoint expression is almost 1. In anomalies, the CV of its viewpoint expression is almost 0, because almost all selected properties in the source concept have not cor- responding properties in the target concept. So the higher the value of CV a viewpoint expression has, the more literal the viewpoint expression is. There needs another measure that distinguish metaphors from other types of sentences. The CV mea- sures only the degree of literal or anomalous of view- point expressions. From the Ortony’s view[lO, 91: in the case of metaphors, transferred properties are high salient in the source concept and low salient in the tar- get concept. In literal sentences, both are high salient. In anomalies, both are low salient. There is an experi- mental evidence about the Ortony’s view[6]. While the CV only considers the properties in the source concept, Ortony’s measure considers the properties in both the source concept and the target concept. To formulate 302 COGNITIVE MODELING the Ortony’s measure in AMUSE, we have to make both the mapping step and the variance step more pre- cise. This is out of the scope of this paper. Conclusion In this paper, we have proposed a method of calculat- ing the measure of salience. The measure of salience represents typicality of a property and can be used in various inferences as a measure of preference. This is an aspect of the utility of salience, and the understanding metaphors is one of them. Our metaphor understanding system AMUSE uses the measure of salience to guide which properties can preferably be transferred from a source concept to a target concept. It is also significant to show the foundation which salience is based on and the method of calculating salience based on the foundation. This is the aspect of how the salience is calculated. To compare with the aspect of the utility, this aspect has not been so enlighten. But both *aspects are necessary to accom- plish the theory of salience. The measure of salience proposed in this paper is based on the probability at- tached to attribute’s values, and we have shown the precise method how the measure of salience is calcu- lated from the probability. Our measure of salience is based on the entropy in information theory and more formal than other system’s score of salience. But there remains some questions. We have not shown the effect of the context to the measure of salience. There are two relations between contextual information and two factors of the measure of salience. The first one is the diversity change of a possible value set, which causes the change of the first factor - the amount of information of properties. The second one is the variety of selecting similar concepts, which causes the change of the second factor - the difference of properties. Precise analysis of these relations is left as our future work. Finally, there is a question how the probabilistic concept is constructed. We think Fisher’s incremen- tal concept clustering system COBWEB[S] gives us one answer, because COBWEB also uses probabilis- tic concept as its representation form and constructs probabilistic concepts and their hierarchy incremen- tally. Fisher proposed the measure of Category util- ity to control the construction of concept hierarchy. Category utility is the measure calculated by two fac- tors - intra-class similarity and inter-class similarity. Roughly speaking, COB WEB incrementally construct concept hierarchy so as to increase intra-class simi- larity and decrease inter-class similarity. This strat- egy reflects basic-level eflect and typicality eflect[ll] observed in human’s categorization. Our measure of salience and Fisher’s measure of Category utility are similar, that is intra-class similarity and inter-class dis- similarity corresponding to the amount of information and the difference of properties respectively. There- fore we think COBWEB can be incorporated into our metaphor understanding system AMUSE as construct- ing probabilistic concepts. PI PI PI PI PI PI VI PI PI WI PI WI WI WI 1151 References J. G. Carbonell. Metaphor: An inescapable phe- nomenon in natural-language comprehension. In W. G. Lehnert and M. H. Ringle, editors, Strate- gies for natural language processing, pages 415- 434. Erlbaum, 1982. D. Fass. Metonymy and metaphor: What’s the difference? In COLING ‘88, pages 177-181, 1988. D. Fisher. Knowledge acquisition via incremental conceptual clustering. Machine Learning, 2:139- 172, 1987. R. P. Hall. Computational approaches to analig- ical reasoning: A comparative analysis. Artificial Intelligence, 39( 1):39-120, 1989. S. T. Kedar-Cabelli. Analogy - from a unified perspective. In D. H. Helman, editor, Analogical Reasoning, pages 65-103. Kluwer Academic Pub- lishers, 1988. T. Kusumi. Effects of categorical dissimilarity and affective similarity between constituent words on metaphor appreciation. Journal of Psycolinguistic Research, 16(6):577-595, 1987. G. Lakoff and M. Johnson. Metaphors we dive by. Chicago University Press, 1980. II. M iyagawa. Information Theory. CORONA Publishing CO., LTD., Tokyo, Japan, 1979. (in Japanese). A. Ortony. Beyond literal similarity. Psychological Review, 86(3):161-180, 1979. A. Ortony. The role of similarity in similes and meta.phors. In A. Ortony, editor, Metaphor and Thought. Cambridge University Press, 1979. E. Rosch and C. B. Mervis. Family resemblances : Studies in the internal structure of categories. Cognitive Psychology, 7:573-605, 1975. E. E. Smith and D. Medin. Categories and Con- cepts. Harvard University Press, Cambridge, MA, 1981. E. E. Smith, D. N. Osherson, L. Rips, and M. Keane. Combining prototypes : A selective modification model. Cognitive Science, 12(4):485- 527, 1988. A. Tversky. Features of similarity. Psycodogicul Review, 84(4):327-352, 1977. E. J. Weiner. A knowledge representation ap- proach to understanding metaphors. Computu- tionul Linguistics, lO( l):l-14, 1984. IWAYAMA ET AL. 303
|
1990
|
74
|
994
|
Distributed Cases for Case-Based Reasoning; Facilitating Use of Multiple Cases Michael Redmond* School of Information and Computer Science Georgia Institute of Technology Atlanta, Georgia 30332-0280 (404) 853-9382 E-mail: redmond@pravda.gatech.edu Abstract A case-based reasoner can frequently benefit from us- ing pieces of multiple previous cases in the course of solving a single problem. In our model, case pieces, called snippets, are organized around the pursuit of a goal, and there are links between the pieces that pre- serve the structure of reasoning. The advantages of our representational approach include: 1) The steps taken in a previous case can be followed as long as they are relevant, since the connections between steps are preserved. 2) There is easy access to all parts of previous cases, so they can be directly accessed when appropriate. Introduction Case-based Reasoning (CBR) (Kolodner and Simpson 1984) is a method of using previous episodes to sug- gest solutions to new problems. CBR allows a rea saner to solve problems efficiently when previous sim- ilar experiences are available. Problem solving using case-based reasoning usually involves retrieving rele- vant previous cases, adapting the solution(s) from the previous case(s), if necessary, to solve the new prob- lem, and storing the current episode as a new case to be used in the future. A case-based reasoner can frequently benefit from using pieces of multiple previous cases in the course of solving a single problem. For example, in protocols taken by Lancaster (Lancaster and Kolodner 1988), mechanics doing a troubleshooting task used pieces of different cases to suggest different hypotheses to con- sider and tests to perform. An annotated example from our program CELIA (Cases and Explanations in Learning; an Integrated Approach) (Redmond 1989b), which solves problems in the domain of automobile troubleshooting, illus- *This research has been supported by the Army Re- search Institute for the Behavioral and Social Sciences un- der Contract No. MDA-903-86-C-173, and by DARPA contract F49620-88-C-0058 monitored by AFOSR. The au- thor wishes to thank Janet Kolodner for her guidance, Ray Bareiss, and Ashwin Ram for helpful discussions, and Tom Hinrichs, Steve Robinson, Louise Penberthy, and Joel Mar- tin for helpful comments on earlier versions of the paper. trates the successful use of multiple cases. In this ex- ample, the car is stalling. In forming an initial hypoth- esis, the reasoner retrieves part of a previous case with the same symptoms that suggests that the idle speed is low and that the mechanic should test whether the en- gine stalls when it is cold. After carrying out the test the mechanic finds that the engine stalls when warm. Since the results of this test are different than in the previous case, the rest of that case is not useful for further diagnosis. ***** Relevant Case Snippet Retrieved **** The HYPOTHESIS that Case 101, Snippet Case-Generate- Hypothesis-316 suggests is: (LOW IDLESPEED) **** Continue with Linked Case Snippet **** The TEST that Case 101, Snippet CaseTest-Hypothesis-318 suggests is: (TEMPERATURE ENGINE-SYSTEM (WHEN (STALLS ENGINE-SYSTEM)) COLD) The TEST-RESULT predicted is: (TEMPERATURE ENGINE-SYSTEM (COLD)) Result: (TEMPERATURE ENGINE-SYSTEM (WARM)) ***** Abandoning Case 101 ***** CELIA recognizes that the first case must be aban- doned, and retrieves another case to help it interpret the test result. The new case shares hypotheses and test results with the current situation, rather than just symptoms. It suggests that the problem is a low idle mixture. ***** Continuing with Case 105, Snippet Case-Interpret-Test-505 The RULE-IN-that Case 105, Snippet Case-Interpret-Test-505 suggests is: (LOW IDLE-MIXTURE) The RULE-OUT that Case 105, Snippet Case-Interpret-Test-505 suggests is: (LOW IDLE-SPEED) *** Continuing with Case 102, Snip. Case-Generate-Hypothesis-289 The hypothesis that Case 102, Snippet Case-Generate- Hypothesis-289 suggests is: (SMALL (DISTANCE THROTTLE-DASHPOT-STEM THROTTLE-LEVER)) The TEST that Case 102, Snippet CaseTest-Hypothesis-287 suggests is: (DISTANCE THROTTLE-DASHPOT-STEM THROTTLELEVER) The TEST-RESULT predicted is: (NOT(SMALL (DISTAIWETHFL~TTLEDASHP~T-STEM THROTTLELEVER))) It further suggests actions to take to fix the problem (not shown), but after carrying out those actions, the car still stalls. This case, too, is abandoned. Another 304 C~GNI~VEMODELING From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. case is retrieved that suggests a new hypothesis: the throttle dashpot is out of place. It suggests checking if the distance between the throttle dashpot and the throttle lever is too short. This hypothesis proves to be correct, the fix it suggests is carried out and the problem is fixed. The process we are describing is one of using pieces of several cases to solve a problem. We have ob- served this happening in automobile troubleshooting (Lancaster and Kolodner 1988)) medical diagnosis, and meal planning (Hinrichs 1988). We suspect that it is common to any problem solving task that is solved by addressing subgoals individually. It is especl’ally evident when planning and execution are interleaved, where the results of execution are not always as pre- dicted. In order for several cases to be used efficiently in combination with each other, several issues must be addressed. l How to retrieve a case when some part of it could prove useful. e How to find and isolate the parts of the previous case that will be useful in the current context. o How to form generalizations to reflect commonalities in parts of the problem solving experiences. In this paper we discuss a case representation that enables effective combination of multiple cases by mak- ing each part of a case directly accessible, while retain- ing the links between the parts. Case Representation When more than one case is used to solve a problem, frequently only parts of each case will be useful in the synthesis. These parts might be buried within an ex- tended sequence of actions serving many goals. For example, when a reasoner is trying to find a test for a particular hypothesis, the relevant test part of a case is all he needs to focus on. The actions taken and the other hypotheses are not important at that time. Cases must therefore be represented such that their parts can be efficiently accessed. Traditionally, cases used by case-based reasoners have been treated as monolithic entities l. That is, an episode is stored as a single instantiation of a single knowledge structure. Aspects of a case are specified as slots in the representation. Although many of these representations have structured representation within slots and reasoning can be applied to parts of a case, indexing, in general, retrieves the case as a whole. Treating a situation as a monolithic case and embed- ding everything in it creates problems for using parts of multiple cases to solve one problem: e Retrieval of the parts of the case that can be help- ful in a given situation has to be a two step pro- cess. First, the appropriate case must be accessed, then the currently useful parts hidden inside the case must be found. It can take a lot of effort to find them within the case, even given the right indices to the ‘See Related Work section for some exceptions. e situation. A one step process allowing direct access to the useful parts of cases would be more efficient. Monolithic cases contain too much information for a system to be able to do useful generalization. Since cases have many parts, some of which should be generalized with parts of other cases, but others of which are unique, generalization of commonalities may be delayed. In order for the appropriate part of a case to be ac- cessed when it can be useful, in the middle of problem solving, it is advantageous to divide cases into pieces. In our model, Cases are stored in pieces, or snippets (Kolodner 1988). This allows the reasoner to use small frag- ments of cases in its reasoning rather than having to wade through large monolithic cases. Each snippet is organized around one particular goal, and contains information pertaining to the pur- suit of that goal. Each snippet contains the current problem solving context at the time the goal was initiated, including the initial problem description and results of actions taken so far. There are links between the snippets that preserve the structure of the diagnosis. Each snippet is linked to the snippet for the goal that suggested it and to the snippets for the goals it suggests. Content of Snippets Each snippet can be thought of as a scene of the larger episode. A snippet has three main types of informa- tion. First, is the problem solving context at the time of the snippet’s occurrence. Second is information re- lated to the goal that the snippet is centered around. Last is information linking the snippet to other re- lated snippets. Figures 1, 2, and 3 together comprise an example of the internal representation of a snippet representing the goal of testing the hypothesis that the carburetor float bowl had too high a fuel level. Context. Problem solving context includes actions and results of actions taken earlier in the problem solv- ing, as well as features of the problem. Global context is the features given for the overall problem situation, in- ternal context is the circumstances, state or knowledge established by the actions already taken as part of the problem solving. In the automobile troubleshooting domain, internal context includes tests that have been done and their results; information or hypotheses that have been ruled out or ruled in during problem solving; fixes that have been made during problem solving; and the current hypothesis. The global context includes the chief complaint; other symptoms; how frequently the symptoms occur; how long the problem has been going on; any particular ambient temperature range when failure occurs; any particular weather conditions when failure occurs; the car model; the customer; the mechanics involved; and where and when the problem solving occurred. Global context remains the same across snippets of a case, but internal context changes. REDMOND 305 Figure 1 shows an example of the problem solving con- text part of a snippet. CASE-TEST-HYPOTHESIS-130 CONTEXT Internal Ruled-In (Lean (Position (Idle-Mixture-Screw))) Ruled-Out (Low (Position (Idle-Speed-Screw))) (Lean (Position (Idle-Mixture-Screw))) Tests-Done $ Results ncorrect (Position (ThrottleDashpot))) - - (Temperature Engine-System (When (Stalls Engine-System)) Cold) (Hot (Temperature Engine-System)) (Stalls Engine-System) (Stalls EngineSystem) (Small (Distance ThrottlsDashpot-Stem Throttle-Lever)) (Not (Small (Distance Throttle-Dashpot-Stem Throttle-Lever)) Fixes-Done Solution: NIL (I ncrease (Position (Idle-Mixture-Screw))) Current-Hypoth (High (Contains Carburetor-Float-Bowl Fuel)) Global Complaint Other-Sympt Frequency How-Long Amb-Temp-Q-Fail Weath-Q-Fail Car-Type Car-Owner Participants Location When (Stalls Engine-System) (Rough (Run Engine-System)) Weekly 2months Any Rainy (1981 Ford Granada) Davis Cable Mark Graves, David Wood Mikes-Repair-Shop 2843569149 Figure 1: Example Case Snippet Context. The problem solving context of a snippet is used for matching during retrieval. As Barletta and Mark (1988) have suggested, both internal and global prob- lem solving context are necessary to maintain coher- ence and consistency of actions. Since snippets include both internal and global problem solving context, re- trieval results in usefully similar case pieces. This form of context creates advantages for combin- ing multiple cases to find a solution. When there is a need to access part of another case, having the in- ternal context available allows matching on results of previous problem solving. Thus a snippet which fol- lowed from similar steps and results can be favored. In this way both access issues are addressed: access- ing a case that is relevantly similar, and accessing the part of the previous case that will be useful in the cur- rent context. An appropriately relevant snippet can be directly accessed. With monolithic cases the inter- nal context at each point in the problem solving would not be available to make accessing parts easy. By sav- ing the context with each piece we are trading space for flexibility. Any method, in order to be as flexible, would have to either represent the internal context at each point, or be able to recompute it at retrieval time, an expensive proposition. In addition, though not currently implemented, rep- resenting the internal context enables analytical rea soning that could determine that the current context is incompatible with something already done prior to the snippet in the previous situation, thus averting failure. Pursuit of Goal. Each snippet is centered around the pursuit of one goal. It is here that the actions taken in pursuit of a goal and the results of those ac- tions are recorded. When a snippet is retrieved during problem solving, these slots suggest the actions to take and the results to expect if the situation is the same as in the previous case. We have identified 7 types of goals involved in troubleshooting, Table 1 lists those goal types and their associated slots. Figure 2 shows the slots for a test: the test that was done, the method of carrying it out, the tools used, and the result. In general, the goal-related part of a snippet needs to in- clude the actions carried out to achieve the goal and the effects of the actions. CASE-TEST-HYPOTHESIS-130 PURSUIT OF GOAL Goal G-TEST-HYPOTHESIS Test Test Me(fJIh (Contains Carburetor-Float-Bowl Fuel)) (Turn-Off Engine-System) (Remove Carburetor-Air-Horn-Screw) (Remove Carburetor-Air-Horn) (Ask (Level Fuel Carburetor-Float-Bowl) Scale-On-Carburetor-Float-Bowl) Test-Tools Screw-Driver Test-Result (High (Level Fuel Carburetor-Float-Bowl)) Figure 2: Example Case Snippet Pursuit of Goal. Goal Type I Slots for Goal Type I Verifying a complaint I actions taken I tools used, result Testing a fix or replacement I test that was done, method of carrying it out, tools used, result Table 1: Goal Types and Their Slots. Linkage. While it is important to divide cases into snippets so that parts of cases can be easily and di- rectly accessible, it is also important to be able to re- construct the case. Sometimes a number of steps in the same case can provide useful guidance. A hypothesis suggests a test, the result suggests an interpretation, the interpretation suggests a fix, and the fix is associ- ated with a test of the fix. As long as the expectations from a previous case are upheld in the new situation, the reasoner can benefit by following the sequence of reasoning steps from the recalled case. In order to en- 306 COGNITIVEMODELING able such reconstruction, snippets include links to the snippets for the goals they follow from and the goals that follow from them. Briefly, the idea is, first, retain the links so that in the future use of the snippet, the step that it suggested will be suggested. Second, save the value of the main slot of the preceding snippet to facilitate making generalizations involving the previ- ous step taken. Note that the portion of the snippet shown in Figure 3 has a slot for the previous hypoth- esis because it was preceded by a generate hypothesis snippet, whose main slot was a hypothesis. CASETEST-HYPOTHESIS-130 LINKAGE Link-Down CASEINTERPRET-TEST-140 Link-Up CASE-GENERATE-HYPOTHESIS-125 Prev-Hypothesis (High (Contains Carburetor-Float-Bowl Fuel)) Figure 3: Example Case Snippet Linkage. Links Between Snippets As mentioned above, snippets are linked together in a manner that preserves the underlying structure of the goals pursued in the case. Figure 4 shows the linkages between snippets for a case of a stalling car. This case illustrates the differences that can occur between temporal order and the underlying structure of which snippets follow from which. Each node represents a case snippet for a particular goal pursued in the case. Each link represents a relationship between goals in the case. Arrows point from a snippet to the snippets that it suggests. Preserving these intra-case links is important for fu- ture use of the case. For example, in diagnosis, the case structure preserves which hypothesis suggested a test, and what test result suggested a hypothesis, even if they were not contiguous in the processing. To demon- strate this, in Figure 4, step 6 follows from step 3, since it is a refinement of the previous hypothesis. Step 7 follows from step 4, since it is a test of the hypothe- sis. Step 11 does not follow from any of the previous hypotheses or tests, it is the start of a new direction after a dead end was reached. This means that the im- portant structure in a case is not the temporal order of the actions taken. Rather, it is which goals follow from which other goals. For example, in automobile troubleshooting, a hy- pothesis that the alternator belt is loose could follow from a hypothesis that the battery is not charging since it is a potential root cause. Or a hypothesis that the radiator hose is leaking could follow from a hypothesis that there is a leak in the cooling system, since it is a narrowing of a hypothesis. Preserving this linkage enables a case to provide guidance as to what to pursue next as long as the re- sults continue to be the same as in the previous case. In troubleshooting, this allows retrieval of a case frag- ment with a particular hypothesis to yield a connection to the test to do next. The guidance is not affected by any idiosyncratic temporal ordering that does not re- flect the underlying structure of the previous case. Case Header - Car Stalls Diagnosis Actions (in order presented) 1. Hyp - Loose Connected Spark Plug 2. Test - Loose Connected Spark Plug (Neg.) 3. Hyp - Malfunction Carburetor 4. HYD - Lean Idle Mixture 5. Hyp - Low Idle Speed 6. Hyp - High Float Level 7. Test - Lean Idle Mixture (Neg.) 8. Test - Low Idle Speed (Neg.) 9. Hyp - High Float Level (restate) 10. Test - High Float Level (Neg.) 11. Hyp - Malfunction Control System Figure 4: Case Structure. Snippet Access Snippets can be accessed two ways: o Directly, through retrieval, matching the current sit- uation to the snippet’s goal and context. e Sequentially, by following links between snippets. In CELIA, retrieval via direct access is first restricted to snippets that are centered around the goal type be- ing considered. Then a weighted similarity metric is used, with matching occurring for all features within both the internal and global context. An empirical adjustment of the weight on a feature’s importance is made based on the success or failure of prediction dur- ing learning (Redmond 198913). As would be hoped, the similarity metric quickly comes to favor many of the features in the internal context, and give less im- portance to .features in the global context that seem spurious, such as the car owner, the participants, and the location. These, however, are not eliminated, so they can play a part in some unusual situation in which they are important. Further work will investigate us- ing some form of explanation based indexing (Barletta and Mark 1988) in conjunction with this. Retrieval by sequential access is easy given our case represent at ion. Snippets have links to other snippets that follow from them. When a snippet has been used to suggest an action, if the result is the same as in the snippet’s execution, the reasoner can follow the link to the next goal and its actions. Retrieval by sequential access is favored over direct access when it is appro- priate. This retains coherence and avoids unnecessary processing. Advantages of the Approach Our system, CELIA, learns from observing an expert’s actions (Redmond 1989b, 1989a). It uses parts of mul- tiple cases for two tasks REDMOND 307 o To predict and explain the instructor’s actions as it is learning. The experience is then saved in the distributed form we have described here. Redmond (1989c) explains how this distributed case represen- tation can be constructed from observing raw input. e To provide guidance during problem solving. The distributed case representation has advantages for both processes. Here we discuss the advantages for problem solving. o There is easy access to all parts of previous cases, so they can be directly accessed when a snippet’s goal is to be pursued. o The structure of the case is retained so it can be reconstructed as a whole or in part when necessary. The actions taken in the previous case can continue to provide guidance as long as the situation remains usefully similar to that of the previous case. Opera- tionally, in the current system this means as long as the same results are obtained in the step as in the corresponding step in the previous case. o Generalizations of case snippets can be formed for r the pursuit of a particular goal, but not hindered by the pursuit of other goals in the cases. While empirical measures of the learning part of the system have been made, our evaluation of the represen- tational approach is based on the fact that it enables, without much cost, flexible problem solving that would otherwise be difficult. With monolithic cases, not only might the reasoner not have the right indices for the case, finding the right part of a case to use for the current task situation is effortful. Even if the case is indexed so that it will be accessed when any of its parts are relevant (e.g. by important features of the internal context at each and every point during the case - the tests done and their results, the fixes done . . . ), once that case is accessed it is necessary to find the point in the case’s problem solving where its con- text best matches the current context. Making this process as simple as CELIA’s process would require including all the same information that CELIA’s cases have - the context at each point during the case (for indices), directly associated with the step in the case. This case representation content would not be distin- guishable from our theory except that our representa- tion preserves the underlying order of the steps. The ideas discussed raise some issues. First, as s’nip- pets become smaller, the distinction between cases and situation/action rules may seem to blur. If problem solving does not benefit from the overall context pro- vided by a whole case, then the case representation might be equivalent to individual decision rules. A re- I lated question one might ask is whether problem solv- ing behavior constructed from relatively local decisions can be globally consistent, or will unforeseen interac- tions between goals creep in. An advantage of tradi- tional case-based reasoning techniques is that a whole case has a coherency that holds together the problem solving behavior. We do not want to lose coherency 308 COGNITIVEMODELING when we break cases into pieces. We have discussed a number of important ways in which our snippet rep- resentation differs from decision rules. First, the links between actions are retained, so a case can be followed as long as the results of actions are as predicted by the previous case. Sequential access of snippets leads to a goal-directed coherence that is not inherent in a set of individual decision rules. Second, snippets include in their context both the initial problem description and the results of actions taken up to that point. This means that when direct access is used the choice of ac- tions to take is directly influenced by the problem solv- ing that has already occurred. Third, the case snippet can provide useful suggestions even when there is only a partial match to the current situation (i.e. when a rule may not apply). Another issue we must address is what size snippet is most useful for problem solving. There is a trade-off between the efficiency of being able to match and use a single case as the solution to the problem, and the generality of matching to the parts that are applicable in the current situation. We have suggested that the appropriate division is for each snippet to concern a single goal. We should clarify that this means that they are concerned with a leafgoal. A high level goal such as exphain anomaly would be broken down into subgoals using knowledge of goals and subgoals. The lowest level goals are the ones that the reasoner would look for guidance in achieving. It is this level of goals that the case snippets are organized around. Applying this to the advantages suggested above, the approach has these advantages: Direct access is to the parts of previous cases in- volved in the pursuit of the types of goals that the problem solver seeks guidance in achieving. When generalization of case snippets is added, it can be done for the pursuit of a particular low-level goal for which the reasoner might later want guidance. might be argued that the number of indices nec- essary increases as the cases are divided into smaller chunks and each chunk requires indices. However, if parts of the larger chunks are to be accessible, then equivalent numbers of indices are necessary in order to be able to get an indication that some part of the larger chunk would be of value in the current circum- stances. Thus, snippet size and number of indices are independent of each other. This division of cases into multiple snippets based on goals pursued is important when multiple cases are used to solve different parts of a problem. When changes lead to the need to access a different case to get help pursuing a goal, the part of the case that should be accessed is available such that it can be found in a timely manner. Such division would not be important in a domains in which cases can only be considered as a whole (as in e.g. HYPO (Ashley & Rissland 1987)). Related Work and Conclusions Most CBR approaches have represented cases as single units and reasoned based on one case. MEDIATOR (Simpson 1985) made use of parts of multiple cases in coming to a solution. However, MEDIATOR had to first choose a case, then access the relevant part. More recently, several CBR approaches have separated cases into pieces. JULIA’s (Kolodner 1989; Hinrichs 1988) case pieces represent scenes that are related partonomically and taxonomically. Its snippets, like CELIA’s, facilitate synthesizing parts of multiple cases to form a solution, and effective generalization. JULIA does not need The use of parts of multiple cases, and the division of cases into linked, goal-centered fragments provides flexibility to recover from changes or unexpected re- suits, while retaining goal-driven processing. The case representation enables direct access to usefully similar parts of previous cases, while retaining the opportu- nity to follow significant portions of a previous case. When generating a multi-step solution and the solu- tion can be synthesized from multiple cases, our dis- tributed case representation provides significant flexi- bility advantages. This is important in numerous d* mains, including automobile troubleshooting, medical diagnosis, many design problems, and we suspect any problem solving task that is solved by addressing sub- the type of links used in our representation, however, Barletta and Mark (1988) group their cases into because of the relatively low amount of difference in structure of cases, and a relatively static set of goals across problems, with limited need to pursue them in any particular order. Derivational Analogy (Carbonell 1986) is somewhat similar to our approach in that it saves the problem trace, including generation of subgoal structures and generation of alternatives. A key difference is that our approach provides both direct and sequential access to parts of the problem solving. Derivational Analogy only accesses a trace at the beginning of a problem. If a case can no longer provide guidance a different case must be accessed from the top and the reasoning fol- lowed from there. The start bf the problem trace is accessed when it shares a subgoal chain with the cur- rent situation. Therefore, derivational analogy cannot retrieve a case or part of a case with a similar current subgoal but a different way of getting to it. goals individudly. References K. Ashley and E. Rissland 1987. Compare and contrast, a test of expertise. In Proceedings of the National Conference on Artifi- cial Intelligence (AAA I-87), San Mateo, CA. Morgan Kaufmann. R. Barletta and W. Mark 1988. Breaking cases into pieces. In Proceedings of Case-Based Reasoning Workshop, St. Paul, MN. J. Carbonell 1986. Derivational analogy: A theory of reconstruc- tive problem solving and expertise acquisition. In R. Michalski, J. Carbonell, and T. Mitchell, editors, Machine Learning: An Artificial Intelligence Approach, Volutne II. Morgan Kaufmann, Los Altos, CA. T. R. Hinrichs 1988. Towards an architecture for open world problem solving. In Proceedings of a Workshop on Case-Based Reasoning, San Mateo, CA. Morgan Kaufmann. J. Kolodner and R. Simpson Jr. 1984. A case for case-based rea soning. In Proceedings-of the Sixth Annual Conference of the Cognitive Science Society, Hillsdale, NJ. Lawrence Erlbaum As- sociates. J. Kolodner 1988. Retrieving events from Based Reasoning, San Mateo, CA. Mor&n Kaufman;. a case memory: a par- allel implementation. In Proceedinos of a Workshop on Case- pieces such that the aciions’that are used to recover from each of the hypothesized faults are in the same piece. This serves part of the purpose of dividing the cases into pieces, direct access to relevant actions. It appears to be specific to the particular goal of fixing a known fault, however. It is not as flexible as organize tion by goals, in that it serves a particular goal type, fixing a problem, but does not allow easy direct access to ali the goals pursued in the previous-case. J. Kolodner 1989. Judging which is the “best” case for a case based reasoner. In Proceedings of the Second Workshop on Case- Based Reasoning, San Mateo, CA. Morgan Kaufmann. L. Kopeikina, R. Bandau, and A. Lemmon 1988a. Case-based reasoning for continuous control. In Proceedings of a Workshop on Case-Based Reasoning, San Mateo, CA. Morgan Kaufmann. L. Kopeikina, R. Bandau, and A. Lemmon 198813. Extending cases through time. In Proceedings of Case-Based Reasoning Workshop, St. Paul, MN. J. Lancaster and J. Kolodner 1988. Varieties of learning from problem solving experience. In Proceedings of the Tenth An- nual Conference of the Cognitiwe Science Society, Hillsdale, NJ. Kopeik&a, Bandau, and Li-on (1988a, 1988b) suggested the need for cases that represent how a situ- at& develops over time. Their approach wils to divide a case into problem description; action plan; descrip- tion of effect of implemented action; description of the ‘no need for treatment state’; remove controls; and de- scription of a ‘no problem state’. Such a case is always accessed at the beginning, and all of the main actions Lawrence Erlbaum Associates. M. Redmond 1989a. Combining case-based reasoning, explanation-based learning and learning from instruction. In Pro- ceedings of the Sixth Annual International Workshop on Ma- chine Learning, San Mateo, CA. Morgan Kaufmann. M. Redmond 1989b. Combining explanation types for learning by understanding instructional examples. In Proceedings of the Eleventh Annual Conference of the Cognitive Science Society. Hillsdale, NJ. Lawrence Erlbau& Associ&s. -. are within the second piece. If the results are not as expected, another case can be used to recover from that new problem, however, it is accessed from the be- ginning as a whole case. They argue against dividing cases up into unconnected individual cases, but do not consider an approach such as ours. Our use of snip- pets which retain both the internal context, and the internal structure of the case addresses this need. M. Redmond 1989c. Learning from others’ experience: creating cases from examples. In Proceedings of the Second Workshop on Case-Based Reasoning, San Mateo, CA. Morgan Kaufmann. R. L. Jr. Simpson 1985. A Computer Model of Case-Based Rea- soning in Problena Solving. PhD thesis, Georgia Institute of Technology, Atlanta, GA. REDMOND 309
|
1990
|
75
|
995
|
Validated Retrieval in Case-Based Reasoning Evangelos Simoudis Computer Science Department Brandeis University Waltham, MA 02254 and Digital Equipment Corporation Abstract We combine simple retrieval with domain-specific vali- dation of retrieved cases to produce a useful practical tool for case-based reasoning. Based on 200 real-world cases, we retrieve between three and six cases over a wide range of new problems. This represents a selectiv- ity ranging from 1.5% to 3%, compared to an average selectivity of only 11% from simple retrieval alone. Introduction We have combined simple retrieval (based on the sim- ilarity of surface features) with domain-specific valida- tion of retrieved cases to produce a useful practical tool for case-based reasoning. Starting with a case base of 200 real-world cases, we have narrowed our considera- tion to between three and six cases over a wide range of new problems. This represents a selectivity ranging from 1.5% to 3%, compared to an average selectivity of only 11% from this same case base using retrieval with- out validation. We are applying the same technology to a larger case base in a different domain, and have deployed a related tool with a much larger case base for actual use in the field. Our work begins with a real-world problem: a com- puter manufacturer’s diagnosis of system software fail- ures. In this domain, diagnostic knowledge exists in several forms: manuals, courses, production rule sys- tems, and knowledge bases. But the predominant start- ing point in current use is a set of data bases created by recording successfully diagnosed error conditions. In order to diagnose a new failure, non-expert specialists retrieve from a data base previously solved cases that appear superficially similar to the new problem. They then attempt to verify the similarity by performing tests on the new problem and comparing the results with those of each retrieved case. When they become con- vinced that a previous case is substantially the same as the new problem, they examine the resolution of the old case and report it (possibly amended or edited to more closely fit the new problem) to the customer. Only in rare cases are experts requested to examine problems - most are resolved from the existing data base - and the solutions are then added to the data base. 3 10 COGNITIVE MODELING James Miller Computer Science Department Brandeis University Waltham, MA 02254 and Digital Equipment Corporation This existing human system is a conscious use of case- based reasoning (CBR) techniques; we have improved the system by adding to it an automated tool using re- sults from AI case-based reasoning systems. In order to produce a tool of practical value we were forced to examine more closely the task of retrieval in case-based reasoning. Based on our experience we propose an ex- tension to current systems, validated retrieval, that dra- matically reduces the number of cases presented to the reasoning component (human or automated) of a case- based system. Validated retrieval relies on domain- specific knowledge about tests used to compare cases retrieved from the case base with newly presented prob- lem cases. Knowledge about the relationships among the various tests is captured in a validation model which we implement as a semantic network[Quillian, 19681. In order to build our validation model we are faced with a classic knowledge acquisition task. By perusing exist- ing data bases used by specialists we are able to acquire this knowledge with a reasonable amount of effort - and with only a small investment of specialists’ time. Retrieval in CBR CBR systems first retrieve a set of cases from a case base and then reason from them to find a solution to a newly posed problem. Existing systems ([Bareiss et al., 19881, [Hammond, 1986], [Kolodner, 19831, [Kolodner et al., 19851, [Rissland and Ashley, 1986] and [Stanfill and Waltz, 19861) make two assumptions about the initial retrieval of cases from the case base: 1. Very few cases will be retrieved from the case library. 2. The retrieved solved. cases are relevant to the problem being In many practical applications, retrieval alone is suffi- cient to solve the difficult part of a task. For example, in our domain of diagnosis of computer software failures, specialists can easily respond to customer problems if they can quickly locate a few similar cases from their collective past experience. For this reason, we have con- centrated on the retrieval aspect of case-based reason- ing. In MBRTALK[Stanfill and Waltz, 19861, also, the essential task is retrieval; the “reasoning” component From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. consists of merely passing the retrieved information di- a justification model to relate the various applicability rectly to an output unit. checks to one another. Related Work Closest to our own work is the work of Koton on CAsEY[Koton, 1988], a CBR system which has been ap- plied in the domain of medical diagnosis. CASEY has a justification component whose goal is to determine whether the causal explanation of a retrieved case ap- plies to a new problem. This frequently allows CASEY to avoid invoking its causal model when creating an ex- planation for a new case. CASEY'S justification phase is similar to our validation phase. But there is an impor- tant difference between these two systems arising from different assumptions about tests. CASEY relies on pre- cisely two tests (EKG and X-rays), both of which are inexpensive and non-invasive. Both of these tests are performed prior to the retrieval phase and the results are used to provide surface features for the retrieval algorithm. By contrast, there are literally hundreds of tests to be performed in our domains and it is far too ex- pensive to perform all of them in advance of initial case retrieval. As a result, our systems devote attention to minimizing the number of tests that are performed. We not only perform tests incrementally and cache the re- sults, but also employ knowledge about the tests them- selves to reduce the number of tests performed. The CBR system CHEF[Bammond, 19861, whose do- main is Chinese cooking, also uses retrieval followed by justification to identify the most appropriate plans (recipes) to solve a new problem. In order to identify a relevant recipe it performs simple tests, similar to our surface feature comparisons, during the retrieval phase. Once retrieved, a recipe may fail to completely satisfy the requirements of the new problem. In this case, CHEF consults a causal model of the domain in order to de- termine the cause of the mismatch and effect repairs. Finally, in the more recent case-based reason- ing systems PHIAR[Kambhampati, 19891, KRITIK[Goel and Chandrasekaran, 19891, and cYcLops[Sycara and Navinchandra, 19891 also use both surface features and deeper knowledge, although in these systems the deeper knowledge is in the form of causal explanations. PRIAR and KRITIK use the causal explanations during case rea- soning to adapt existing solutions to fit new problems - an important area, but one that our work does not explore. CYCLOPS concentrates on the reverse of our problem: we are concerned with retrieving too many cases for careful scrutiny, while in CYCLOPS the con- cern is that no relevant cases may be retrieved. CY- CLOPS uses deep knowledge to modify the indices used during the retrieval phase, an approach that meshes nicely with ours to produce an automated method for improving the performance of surface feature retrieval. We have found that we can efficiently achieve our goal (retrieval of relevant cases) without recourse to a causal model by using a validation model that is significantly easier to construct. Our contribution is largely one of scale: if CHEF had a larger set of basic recipes from which to choose, our approach would almost certainly improve the performance of CHEF by limiting the num- ber of recipes that must be repaired before a successful solution is found. The SWALE[Leake, 19881 system concentrates primar- ily on modifying the explanation (contained in an expla- nation packet or XP) of a retrieved case to match a new problem. Nonetheless, it has a subcomponent, XP AC- CEPTER, that justifies the application of a retrieved XP to a current situation. The ACCEPTER verifies an XP by determining if it can believe the applicability checks that are packaged with each XP. Each such test is similar to the tests associated with our validation model. Because of the small number of cases (eight, by our count) XP ACCEPTER never addressed the issues of scale which are our major concern. Thus, SWALE never developed Two Phases: Retrieval and Validation Our goal is to take a sizable pre-existing case base along with a new problem and produce a small number of relevant cases. Like our human specialists, our systems perform diagnosis in two phases: Retrieval: it poses a query to the case base using a subset of the features that describe the new problem. Validation: it follows the validation procedure from each retrieved case to determine if it applies to the problem at hand. The goal of the retrieval phase is to extract from the case base those cases that appear to be relevant to the new case. Since the case base is large, and we have been interested primarily in sequential implementations, it is important that the case-base be organized in a way that permits efficient search based on surface similari- ties. For this reason, we organize the cases into a gen- eralization hierarchy (using UNIMEM[Lebowitz, 19871). The retrieval phase consists of traversing the generaliza- tion hierarchy to find a close match to the new problem. The result of this traversal is either an individual case (a leaf node) or a set of cases (an internal node in the hi- erarchy, returned as all of the cases indexed under that node). Unlike those systems that rely exclusively on UNIMEM for case retrieval, we don’t fine tune UNIMEM to reduce the number of cases retrieved. The validation phase then considers each of the re- trieved cases and attempts to show that the case is rele- vant to the problem at hand. Associated with each case in the case base is a set of tests and their result values that must be met for the stored case to be valid. We call the set of tests and values a validation procedure, and each element of this set (i.e. a single test/value pair) is called a validation step. The tests are applied to the actual problem and the results are compared with the results in the case. Based on this comparison both the current case and other retrieved cases can be removed SIMOUDIS ANDMILLER 311 from further consideration. Only when all of the tests for a given case are successfully matched against the current problem is the case reported as a candidate for a reasoning component’s consideration. (In other do- mains, it may be possible to assign weights to individ- ual test results and use a threshold or averaging scheme for deciding whether or not to reject the case.) The Validation Model The validation phase of our method is straightforward if the individual validation tests are simple and self- contained. Unfortunately, in our domains, and prob- ably in most real-world domains, this is not the case. In each domain we have studied, we have found that the tests are interrelated in a way that is not evident in advance, and we have been forced to face the knowl- edge acquisition task head-on. In Section we describe a methodology for acquiring this knowledge about tests. We have successfully used this methodology to develop validation models: structures that capture much of an expert’s knowledge in a way that makes it easy for the validation phase to process the tests it requires. What is a validation model? The test space, which we represent with a validation model, is rich and complex. Not only are there the individual tests themselves, but the tests can often be grouped together to represent methods for testing larger components. Furthermore, performing one test may ei- ther require information gathered from earlier tests or generate information that modifies the meaning or need to perform subsequent tests. Thus, there are prece- dence constraints among the tests, conceptual group- ings of tests, and a body of inferential knowledge in- volving the various tests. For example, if we want to know why a house is hot (the problem), we may first want to see if the air condi- tioner is working. But before performing these actions we need to find out if the house has an air conditioner. In this example, the desired test (is the air conditioner working?) uses the output of another test (is there an air conditioner?). It is this knowledge, as well as knowl- edge about the important outcomes and implications of a test, that is captured by the validation model. We have chosen to represent this knowledge in the form of a semantic network whose nodes correspond to sets of tests and whose arcs indicate relationships between these sets. This richness is reminiscent of causal models and nat- urally leads us to ask about the relation between causal and validation models. The two forms of models en- capsulate different kinds of knowledge, serve to answer different questions, and facilitate different forms of rea- soning. Causal models, like declarative programming languages, provide a base for detailed reasoning, theo- rem proving, and logical deduction - they try to effi- ciently answer “why?” questions. Validation models, like functional or imperative programming languages, 3 12 COGNITIVE MODELING provide control structures and efficient directed search mechanisms - they try to efficiently answer “how to?” questions. [Davis, 19841 argues that causal models can be used to answer the “how to?” questions of diagnosis. We agree, but the argument is similar to an argument from the programming language community: a logic program that clearly declares the meaning of square roots cm be used to calculate their values, but a func- tional or imperative program is likely to do so far more efficiently. Similarly, we believe that a validation model is both easier to construct and more efficient to use than a causal model for, at least, diagnostic tasks. Creating a Validation Model We build our validation models by first examining ex- isting data bases that are used by human specialists. These data bases may be either formalized (as in the case of our WPS-PLUS1 system) or merely informal notes prepared by the specialists for their own perusal (as in the case of our VAX/VMS system). In our two case-based systems, the existing data contains a tex- tual description of the steps that the specialists used to verify a hypothetical explanation of the problem. In constructing the validation model, it is our goal to cap- ture the interrelationships between the validation tests. As a result, we have built validation models that corre- spond to a particular case base by: Reading the validation procedures of each case and building a list of all the validation steps used in the entire data base. In the process of reading the data base and preparing this list, the implementor devel- ops a sense of the underlying (but unstated) relation- ships between tests that are mentioned in the data base. Examining the resulting list, looking for groups of tests that appear to form related sets. Organizing the list provides a basis for discussion with domain experts, who help “debug” the proposed organiza- tion. Refining the structure of the list through knowledge acquisition sessions with domain experts. During these sessions, significant ranges of test results are identified, as are inferences from these results that eliminate the need to perform other tests. That is, a dependency graph based on test results is developed. Iterating the above two steps after consulting addi- tional information such as manuals and code doc- umentation. The structure of the domain becomes clearer at each iteration. (We have found that three iterations are sufficient to produce a useful structur- ing.) The final validation model consists primarily of entries corresponding directly to information that appears in the original data base. ‘DEC, VAX, VMS and WPS-PLUS are registered trade- marks of Digital Equipment Corporation. 5. Integrating the test sets into the structure derived in the previous step. This integration makes explicit the prerequisites of each test, as well as providing alternative ways of obtaining information ordinarily provided by a particular critical test in cases where that test cannot be performed. An Extended Example In order to understand the validated retrieval process, consider the following example from the domain of au- tomobile diagnosis and repair We have chosen a simple example from this domain because it allows the reader to understand the details of our approach. An example from either of our practical domains would require the reader to acquire a detailed understanding of a compli- cated software system. For our example we assume an existing case base with its associated validation model. We are given the following new problem: NEW CASE make: MAZDA model: 626 engine: 2.OL EFI miles: 50,000 year: 1985 Droblem: engine does not start. The retrieval phase uses the make, model, problem, and approximate year of manufacture to search through a case base of previous automobile problems. Based on these surface features, we retrieve three cases to be val- idated before presentation to a reasoning component: CASE 1 make: MAZDA model: 626 engine: 2.OL EFI miles: 10,000 year: 1988 problem: engine does not start. validat ion: The fuel injector was clogged. Fuel was not delivered to the combustion chamber for the en- gine to ignite. For this reason the engine could not start. solution: cleaned the fuel injector. CASE 2 make: MAZDA model: 626 engine: 2.OL miles: 60,000 year: 1984 problem: engine does not start. validation: The car had a faulty gas pump. Fuel could not be delivered to the combustion chamber. For this reason the engine could not start. solution: Replaced the gas pump. make: MAZDA model: 626 engine: 1.8L miles: 20,000 year: 1987 problem: engine does not start. validat ion: A leak existed in the gas line. Fuel could not be delivered through the fuel line. For this reason the engine could not start. solution: Fixed the leak. The validation model contains (at least) the three tests that are referenced by these cases: “check if a fuel injector is clogged”, “check if the gas pump is working”, and “check if there is a leak in the fuel line”. The first of these is actually composed of two simpler tests: a test for fuel present in the reservoir of the injector and a test for fuel exiting the injector’s nozzle. If there is no fuel in the injector then we can deduce that the injector is not at fault. Rather, the problem lies earlier in the fuel system - either in the pump or the fuel line. The system first attempts to validate Case 1 by re- peating the validation steps from that case. That is, we wish to test if the fuel injector is clogged. In the pro- cess of performing this two-step test we actually acquire knowledge that is relevant to Cases 2 and 3: if the fuel reservoir is not empty we can eliminate both cases; if it is empty, we can eliminate Case 1. This relationship is encoded in the semantic network that represents our validation model and is used in the validation phase. In the best case, this validation model allows us to re- duce the work required to validate cases from four tests to two tests and simultaneously reduces the number of cases to be considered by the reasoner from three to one (selectivity of 33.3%). The first test is for an empty fuel reservoir; if the reservoir is full then Cases 2 and 3 are eliminated. We then test the nozzle for fuel exiting. If no fuel leaves the nozzle, then Case 1 is presented to the reasoner; but if fuel is leaving the nozzle we, unfortunately, eliminate Case 1 as well and leave the reasoning component to its own resources. The worst case requires all four tests and provides either zero or one case to the reasoner. Recent Results An Operating System: VMS The first system we developed is used for the diagnosis of device driver induced crashes of Digital’s VMS op- erating system. The knowledge about surface features was obtained primarily from DEC internal publications and was complemented by an expert from the VMS sup- port team during three knowledge acquisition sessions. It took a total of 84 hours to acquire the domain spe- cific knowledge about surface features. Based on this information, the domain knowledge used by UNIMEM in order to organize the cases into a generalization hierar- chy was implemented in five days. SIMOUDIS AND MILLER 3 13 It took an additional four days of reading valida- tion procedures in the data base to develop a validation model for device drivers. In addition, four more knowl- edge acquisition sessions, lasting 40 hours, were needed to refine and improve the validation model. Encoding the actual validation model took about 80 additional days. We estimate that it took roughly 20 person- days to acquire the necessary knowledge and about 85 person-days to do the full system development. Since this was our first attempt to build a case base and validation model, these numbers are much larger than we expect for subsequent systems. Our work to date on the system described in Section appears to confirm this expectation. The system was evaluated using a case base of 200 cases that were obtained from notes written by special- ists. The surface feature retrieval phase of the system was evaluated by presenting each of the 200 cases to the retriever (as new problems) and preparing a histogram of the number of cases retrieved. UNIMEM provides a mechanism, known as retrieval weights, for tuning its retrieval capabilities. After some experimentation, we discovered that the use of larger retrieval weights (i.e. more stringent matching criteria) caused the re- triever to miss many relevant cases and, in many occa- sions, to fail to retrieve any cases at all. With less strin- gent criteria this problem was rectified. However, many of the retrieved cases were not relevant to the problem. With the optimal weighting, we were able to retrieve on average 22 cases per retrieval (11%). The validation phase, however, was able to reduce this number of cases to an average of 4.5 cases out of 200 (2.25%). In addition, we presented three new cases to the sys- tem. Based on surface features alone, we retrieved 20, 25, and 16 cases (10, 12.5, and 8% selectivity). The validation phase reduced this to 3, 5 and 3 cases, re- spectively (1.5, 2.5, and 1.5% selectivity). Our experts confirm that these validated cases are the only ones rel- evant to the problems presented. A Word Processing System: WPS-PLUS The second system performs diagnosis of customer problems with the word processing component of an office automation product. During 15 hours of knowl- edge acquisition sessions, the knowledge about surface features was obtained from a support engineer for the product. It then took an additional five days to encode the domain knowledge for use by UNIMEM. The validation model was obtained from the valida- tion procedures of the cases in the data base, an internal publication, and 10 hours of knowledge acquisition with the same enginer. While the work is not yet complete (only 50 out of 340 cases have been encoded), it has taken only 10 days to implement the validation model. This system was evaluated using a case base of 340 cases. Repeating the same experiment performed with the VMS case base led to an average of 26 cases per retrieval, or 7.6% selectivity. The validation phase re- 3 14 COGNITIVE MODELING duced this to two cases, or 0.58% selectivity. Since the validation model for this case base is not yet fully en- coded, we have not presented new problems to the sys- tem. Our validated retrieval method can be applied in many types of tasks. The basic requirements are: an existing data base of previous practical experience; a set of quick tests that serve to reduce the search space at low cost; a set of more expensive tests that can further reduce the search space; and an understanding of the relationships between the expensive tests. We have identified four areas of potential interest, but we have limited our implementation work to the first of these: Diagnostic tasks. As shown in the example, we use the symptoms of a problem as the surface features for the retrieval phase. The validation procedure de- scribes which tests to perform in order to determine if the case is relevant to the new problem. Design tasks. The surface features are specifica- tions that a design must satisfy. The validation pro- cedure for a stored design describes how to verify that its key parts meet the requirements specification. Sales tasks. The technique can be used to help iden- tify sales prospects for a new product. The surface features are the characteristics of a customer such as: size of business, type of business, location of business. Each validation procedure describes the customer’s requirements that were satisfied in a previous sale. The validation model includes tests that determine whether or not a customer needs a particular type of product. Management tasks. These tasks include account- ing, credit analysis, investment decisions, and insur- ance underwriting. In each of these areas, specialists can identify easily recognized features in their prob- lem domain (type of company, size, etc.) that allow rapid retrieval of similar situations encountered in the past. They then have more detailed tests that can be applied (debt/equity ratio, payment history, type of client, balance sheets, etc.). Conclusions Our work has concentrated exclusively on the issue of case retrieval. A careful study of two applications in which people consciously use case retrieval has shown that retrieval based solely on surface features is not suf- ficiently discriminating for use with large case bases. It results in large numbers of cases returned to the reasoner, each of which must then be further exam- ined at great expense. Adding a validation phase that uses knowledge of domain-specific tests to prune the re- trieved cases dramatically reduces the number of cases that must be examined by the reasoner. We have found that acquiring knowledge about domain-specific tests is aided by an initial perusal of the existing data base used by specialists. With a reason- able amount of effort, and with only a small investment of specialists’ time, this information can be captured in a validation model represented as a semantic net- work. We have used this methodology to produce two systems. One of these systems has been successful in practice, and the other (incomplete) system is likely to be equally useful. While the burden of knowledge acquisition in our methodology is small compared with other methods, it is not negligible. Automating this work by combin- ing a natural language system to analyze existing data bases with AI-assisted statistical comparison of surface features provides a fertile area for further investigation. Furthermore, we suspect that a careful study of such a system in practice will reveal validation tests that are sufficiently common that it may be reasonable to promote them to surface features, leading to a system with better retrieval capabilities. This analysis, which must first be performed manually to validate our as- sumption, is itself an excellent area for the application AI methods. In fact, the work on CYCLOPS appears to be directly applicable to this problem. Finally, we feel that the kind of knowledge embod- ied in a validation model has received little serious at- tention. Yet this is the critical component of many knowledge-based tasks in the real world. The relation- ship between the “practical how-to” knowledge of our validation models and the more thoroughly explored “conceptually why” knowledge of causal models will bring important insights into the nature of knowledge itself. A reasonable first step in this direction would be to either make this distinction more precise or carefully argue that it is unnecessary. Acknowledgements The authors wish to thank David Waltz for his help with this research. In addition, we have received help- ful comments from Candy Sidner, Andrew Black, Mark Adler, and Rose Horner. References [Bareiss et al., 19881 Ray Bareiss, Karl Branting, and Bruce Porter. The role of explanation in exemplar- based classification and learning. In Proceedings of Case-Based Reasoning Workshop, 1988. [Davis, 19841 Randall Davis. Didagnostic reasoning based on structure and behavior. Artificial Intelli- gence, 24, 1984. [Goel and Chandrasekaran, 19891 A. Goel and B. Chandrasekaran. Use of device models in adaptation of design cases. In DARPA Workshop on Case-Based Reasoning, pages 100-109, 1989. [Hammond, 19861 Kristian Hammond. Case- Based Planning: An Integrated Theory of Planning, Learn- ing, and Memory. PhD thesis, Yale University, 1986. [Kambhampati, 19891 S. Kambhampati. Representa- tional requirements for plan reuse. In DARPA Work- shop on Case-Based Reasoning, pages 20-23, 1989. [Kolodner et al., 19851 J anet L. Kolodner, Jr. Robert L. Simpson, and Katia Sycara-Cyranski. A process model of case-based reasoning in problem solving. In Proceedings of the International Joint Conference on Artificial Intelligence, 1985. [Kolodner, 19831 Janet L. Kolodner. Reconstructive memory: A computer model. Cognitive Science Jour- nal, 7:281-328, 1983. [Koton, 19881 Phyllis Koton. Using experience in learn- ing and problem solving. PhD thesis, Massachussetts Institute of Technology, 1988. [Leake, 19881 David Leake. Evaluating explanations. In Proceedings of the Seventh National Conference on Artificial Intelligence, 1988. [Lebowitz, 19871 Michael Lebowitz. Experiments with incremental concept formation: Unimem. Machine Learning, 2:103-138, 1987. [Quillian, 19681 M.R. Quillian. Semantic memory. In Marvin Minsky, editor, Semantic Information Pro- cessing, pages 227-270. MIT Press, 1968. [Rissland and Ashley, 19861 Edwina Rissland and Ken- neth Ashley. Hypotheticals as heuristic device. In Proceedings of the Fifth National Conference on Ar- tificial Intelligence, 1986. [Stanfill and Waltz, 19861 Craig Stanfill and David Waltz. Toward memory-based reasoning. CACM, 29:1213-1228, 1986. [Sycara and Navinchandra, 19891 Katia P. Sycara and D. Navinchandra. Index transformation and gener- ation for case retrieval. In DARPA Workshop on Case-Based Reasoning, pages 324-328, 1989. SIMOUDIS ANDMILLER 315
|
1990
|
76
|
996
|
0 IA SOF AI Lawrence Birnbaum, Gregg Collins, Michael Freed, and Bruce Krulwich Northwestern University The Institute for the Learning Sciences and Department of Electrical Engineering and Computer Science Evanston, Illinois Abstract We propose that a planner should be provided with an explicit model of its own planning mechanism, and show that linking a planner’s expectations about the performance of its plans to such a model, by means of explicit justification structures, enables the planner to determine which aspects of its planning are responsible for observed performance failures. We have implemented the ideas presented in this paper in a computer model. Applied to the game of chess, the model is capable of diagnosing planning failures due to incomplete knowledge of the rules, improper or overly optimistic focus of attention, faulty projection, and insufficient lead time for warning about threats, and is therefore able to learn such concepts as discovered attack and the fork. 1 Introduction Learning by debugging, or fiilure-driven learning, has historically been the most prominent approach to learning how to plan in AI (see, e.g., Sussman, 1975; Schank, 1982; Hayes-Roth, 1983; Kolodner, 1987; Chien, 1989; Hammond, 1989). In much of this work, particularly in its early stages, no real distinction was made between the diagnosis methods used to uncover planning errors, and the repair strategies used to correct them. The hope was that relatively superficial descriptions of planning errors could be used to index directly to repair strategies that were likely to be useful in eliminating those errors. More recently, efforts have been made to tease these apart so that relatively general model-based methods for diagnosis can be applied to the task of finding bugs in faulty plans (see, e.g., Simmons, 1988). Such methods, derived originally from work in circuit debugging (see, e.g., Stallman and Sussman, 1977; Davis, 1984; DeKleer and Williams, 1987), depend upon having an explicit representation of how a plan is intended to function given certain 3 18 COMMONSENSE REASONING assumptions. The task of the diagnosis component is then to determine which of these assumptions are faulty when a plan fails to operate as expected. We have been developing such an approach within the context of learning to plan in competitive situations (see, e.g., Birnbaum and Collins, 1988; Collins, Birnbaum, and Krulwich, 1989). Many assumptions made during planning, obviously, concern the state of the world in which the plan will be executed. In addition, however, plans often depend upon assumptions about the capacities or properties of the agent executing them. Because this agent is often the planner itself, a planner needs some degree of self-knowledge in order to plan correctly. For example, if a robot planner were unaware of its lifting power, it might build plans requiring it to lift objects that were too heavy; if it were unaware of its width, it might build plans requiring it to squeeze through openings that were too narrow; and so on. Perhaps less obviously, plans do not draw only on the physical capabilities of a planner: They also depend on its cognitive capabilities. Thus, a planner will require some knowledge of its mental and perceptual processes in addition to knowledge about its physical properties (Collins and Birnbaum, 1990). For example, chemists often put a stopper in a test tube in which they are boiling something, so that the “Pop!” that occurs when rising pressure forces the stopper out will alert them to the fact that it is time to remove the test tube from the heat .I This is a simple instance of a powerful and general strategy often employed by human planners, namely, setting an external alarm to alert the planner when some task needs his attention, thus freeing him to attend to other lThanks to Ken Forbus for this example. From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. matters in the interim. The success of such a plan depends upon two things: First, the planner must actually notice the alarm, and second, he must recall the task which is supposed to be resumed when the alarm goes off. In order for a robot planner to successfully apply this strategy, therefore, it will need to know something about the kinds of events that attract its attention-and which can therefore function as an alarm-and something about the reasoning processes that occur when its attention is drawn to such an event. The planner’s theory of its cognitive machinery might, for example, specify that flashing lights, loud noises, and quick movements attract its attention; that once its attention is so attracted, the planner will attempt to explain the cause of the event; and that if the cause is due to the planner itself, the planner will recall its purpose in setting up the event. Armed with this theory, the planner can decide whether to attribute to itself the ability to be alerted by a particular type of event, for instance the “Pop!” of a stopper being disgorged from a test tube. When faulty assumptions in a planner’s model of itself cause planning errors, failure-driven learning can be invoked to enable the planner to identify and alter these assumptions, and thus improve its model of itself just as it would its model of anything else. However, in dealing with assumptions about its own capabilities as a planner there is another possibility: For in many cases, these assumptions about the planner are represented in terms of parameters that are under the planner’s own control. Thus, rather than changing the model to reflect the way the planner functions, the planner may be able to change the way it functions to conform with the model. 2 Modelling the planner Developing a model-directed approach to the diagnosis of planning failures, as discussed above, requires developing explicit models of the planning and plan-execution mechanisms employed, and of how the agent’s plans depend upon those mechanisms. In this section, we describe models of two portions of a simple planner, dealing with threat detection and with execution scheduling. 2.1 A model of threat detection Every planning domain presents variety of threats against its goals. a planner with a In coping with any particular class of threats in some domain, the planner has a choice of either attempting to permanently insulate itself from all instances in that class-i.e., of removing some necessary precondition for all instances of that sort of threat-or of attempting to deal with threats individually as they arise. We refer to these two approaches as the “Great Wall of China” paradigm, and the “Firefighting” paradigm, respectively. It is in the second of these two general strategies that the necessity for threat detection arises. We model threat detection as a simple rule-based process: For each known type of threat, there is a rule that is able to detect instances of that threat if it is evaluated at some point in time prior to the realization of the threat. The planner must take account of a variety of constraints in formulating and deploying such rules. For example, in order to fulfill the function of threat detection within the Firefighting paradigm, each rule must be capable of detecting its threat in time to permit the planner to carry out an effective counterplan. Moreover, the planner must formulate a control regimen for checking its threat detection rules that ensures that whenever a threat arises, the appropriate threat detection rule will in fact be checked in time. We have previously argued (Collins, Birnbaum and Krulwich, 1989) that, all else being equal, the planner’s task is simplified by attempting to detect threats as late as possible. In chess, that point is one move before the threat is carried out. A novice chess planner, then, starts out with a model in which it checks its threat rules at each turn, looking for threats that may be executed on the next turn. Having decided upon this control regimen, the planner is faced with another choice: It can recompute the set of outstanding threats each time it checks its rules, or it can incrementally compute this set by looking only for changes that have occurred since the previous check. The latter approach is generally more efficient when the number of new threats arising per detection cycle is small compared to the total number of threats outstanding, provided that an effective method for focussing on threats that result from changes can be devised. In turn-taking games such as chess, incremental detection of threats means computing the threats added and removed by each move. Given the rule-based framework for threat- detection described above, focussing on threats BIRBAUMETAL. 319 resulting from changes can be implemented as a set of restrictions on the domain of application of the threat detection rules. In our model these restrictions are themselves implemented as a set of focus rules that specify the domain over which the threat detection rules will be applied. A portion of the model is shown in Figure 1. V x 3 t t s ert(x) & detect(x, t) ---, added-to(x, T, t) V x, tl, t2 added-to(x, T, tl) & t2 s ert(x) & -3 tr (tl s tr s t2 & removed-from(x, T, tr)) + member-of(x, T, t2) V x 3 r, f, 0, t t s ert(x) & detects(r, x) & active(x, t) & (evaluate-rule(r, 8, t) + detect(x, t)) & 8 E focus-results(f, t) plan on the queue. A portion of the model appears in Figure 2. V p, t, g execute(p, t) & t zs deadline(p) & plan-for(p, g) + achieve(g) V p, t execute(p, t) - member-of(p, Q, t) & -3 pa (member-of(pa, Q, t) & priority(p) < priority (pa)) V p, ts, te added-to(p, Q, ts) 8~ ts 5 te & -3 tr (ts s tr s te & removed-from(p, Q, tr)) + member-of(p, Q, te) V & t goal@ t) & call-planner& t) 8~ planner& t) = p * added-to(p, Q, t) Fieure 2: Partial model of execution scheduline V r, f, t, 8 8 E focus-results(f, t) -c evaluate-rule(r, 8, t) 3 Case study: The fork V x, t remove-from(x, T, t) - member-of(x, T, t) & -active(x, t) Figure 1: Partial model of threat-detection;! 2.2 A model of execution scheduling Since a planner has limited resources, the formulation of a viable plan in service of an active goal is not, by itself, enough to guarantee that the plan will be carried out. Thus, another important aspect of any planner is a priority-based scheduling mechanism for determining which plans should be executed when. While such a mechanism could, in principle, be arbitrarily complex, we have chosen to model execution scheduling using a simple priority queue, assuming discrete time (which is sufficient for the turn-taking games we are currently investigating). Given such an approach, the basic model of execution scheduling is as follows: Once a goal is formed, a plan is chosen for that goal, assigned a deadline and a priority, and placed on the priority queue. At each time increment, the queue is checked, and the highest priority plan on the queue is chosen for execution. Thus a plan will be successfully executed if and only if there is a time before its deadline when it is the highest priority 2The predicate “ert” stands for earliest realization time, i.e., the earliest time at which the threatened action can be expected to occur. The models described above were developed as part of an account of learning in competitive situations-in particular, chess. We will now consider their application to the acquisition of a classic chess tactic, the fork. In our account, the novice chess player initially notices the fork when it fails to block a threat against one of its pieces. Such a failure leads the planner to search for a fault in the planning and execution mechanisms involved in its ability to block threats-either, that is, in its mechanisms for detecting the threat, for formulating counterplans to the threat, or for executing such counterplans. This search employs the models described in the last section, along with certain other assumptions that specify how the mechanisms they describe are being deployed in order to block threats in chess. For example, one of these assumptions states that for each threat against materiel that is detected, a goal to block that threat will be formulated. In general, these assumptions can be derived by regressing (see, e.g., Manna and Waldinger, 1979) a specification of the desired behavior of the planner through the rules that specify its planning mechanisms. Consider a situation in which white’s rook and knight are under attack from a black pawn. Though it is white’s turn to play, there is no move that would protect both pieces. Rooks are more valuable than knights, so white will save the rook, and black will capture the knight. If our planner is 320 COMMONSENSE REASONING placed in this situation, the capture of the knight will cause a failure of its expectation that all threats to its pieces will be blocked. We now give an informal account of how fault diagnosis must proceed in this case. (A more detailed description of the process is contained in the next two sections.) By the first two axioms of execution scheduling (see Figure 2), the planner’s ability to block a threat depends upon there being a time such that a counterplan for the threat is on the queue, it is before the deadline, and there is no higher priority plan on the queue. Thus, for blocking to have failed, it must have been the case that there was no such time, i.e., some necessary condition for execution must have been missing at each time when the plan might, in principle, have been executed. Thus we can group all of the times into equivalence classes depending upon which necessary condition failed to hold. The diagnostic process has now reached a point at which the planner is presented with a choice of ways to fix the problem, since it can choose the time for which it wants to reinstate the missing condition. For example, execution could occur at an earlier time if the planner could find a way to schedule the plan earlier; execution could occur at a later timt! if the planner could find a way to postpone the carrying out of the threat, say, by putting the opponent in check; and execution could occur at a time in between if the planner could make the plan for saving the knight a higher priority than the plan for saving the rook. In the particular instance that we are considering, the only possible approach is to try to execute the blocking plan earlier. However, by the axioms describing the execution scheduling and threat detection mechanisms, this requires adding the blocking plan to the priority queue earlier, which in turn requires formulating a goal to block the threat earlier, which in turn requires detecting the threat earlier. Our approach, then, makes it possible for a planner to determine for itself that the way to cope with forks is to detect them sooner, rather than needing this piece of advice to be built in. 4 Diagnosing faults in plan justification structures The goal of fault diagnosis is to explain the failure of an expectation as a consequence of the failure of some set of underlying assumptions. In our model the connections between underlying beliefs and consequent expectations are represented in terms of explicit justification structures (see, e.g., DeKleer et al., 1977; Doyle, 1979). These justification structures, as alluded to above, record how the planner’s expectations about the performance of its plans are inferred from the policiesit has adopted, in conjunction with the axioms that constitute its model of the planning and execution mechanisms it employs. For instance, the justification structure underlying the expectation that the planner will block the threat to its knight in the fork example above is a conjunction of three antecedent expectations: That moving the knight will block the threat, that the move will be executed, and that such execution will take place before the opponent takes the knight. The expectation that the knight move will be executed is in turn justified by the conjunction of two prior expectations that the move appears on the plan queue and that it is the highest priority item on the queue; and so on. Diagnosing the fault thus involves “backing up” through these justification structures, recursively explaining the failure of an expectation as the result of a failure of one or more of its immediately antecedent expectations. This approach is similar to that proposed by Smith, Winston, Mitchell, and Buchanan (1986) and Simmons (1988). More generally, a justification structure links an expectation with a set of supporting beliefs. The justification may be either conjunctive, meaning all the supporters must be true to justify the expectation, or disjunctive, meaning at least one of the supporters must be true to justify the expectation. When an expectation fails, the diagnosis algorithm attempts to determine which of its supporters should be faulted. If the support set is conjunctive, then at least one supporter must be faulted. If the support set is disjunctive, then all of the supporters must be faulted. The basic algorithm nondeterministically expands the set of faulted expectations according to these simple rules until a stopping criterion is met. However, when faulting conjunctive supports, the degree of arbitrary choice required can be reduced by checking whether a proposition in the support set was observed to be true during the execution of the plan, and if so removing it from consideration. Since the goal of the diagnosis process is to provide enough information to allow a repair to be effected, the process should, in principle, continue until a repair is actually generated. Because of this, the diagnostic module in our system calls the repair module at each step, checking to see if the BIRBAUMETAL. 321 current set of faulted expectations provides enough information for a repair to be generated. This is particularly important for reducing the effort entailed in propagating a fault through a disjunctive justification. Although, in principle, every proposition in such a support set must be faulted when the supported proposition is faulted, it does not necessarily follow that the diagnostic procedure must explain the failure of each disjunct. Since the overarching goal of the process is to fix the problem, and since the repair of a single disjunct will suffice to restore the supported expectation, it may be enough to explain the failure of one disjunct. In other words, the attempt to fault a disjunctive justification results in the goal to unfault one of the disjuncts. One additional point deserves special mention. There will be many instances in which the planner expects that the execution of a plan will involve some entity that meets a particular set of constraints, but does not know in advance the exact identity of this entity. This may be true, for example, of objects that will be found in the planning environment, including tools, raw materials, obstacles, and other agents. In our model, it is also true of execution times for plans, since the planner leaves the execution scheduler some latitude in determining when the plan should actually be carried out. The upshot is that some of the assumptions underlying the expectation that a plan will succeed are existentially quantified: They assert that a time, tool, or material meeting certain constraints will actually exist. Faulting such expectations causes special problems, stemming from the fact that the faulting of an existentially quantified proposition implies the faulting of an infinite set of disjuncts, one for each object over which the existential ranges. Of course, even in principle, the diagnostic engine cannot consider why the assertion failed for each instance of the variable. One solution is to partition the set of instances into classes in such a way that the elements of each class have all failed to meet exactly the same constraint or constraints, while meeting all others. This organizes the set of faulted instances in such a way that the unfaulter need only consider one instance of each type of failure, rather than repeatedly trying to unfault instances that have failed for the same reason about which it can do nothing. In the case of the fork, for example, the planner’s expectation that there will be a time at which it will be able to carry out the plan to save the knight depends on there being a time before the deadline when the plan is on the schedule queue, and is of higher priority than anything else on the queue. Each of these three constraints defines a class of times, namely, those at which the expectation failed because that particular constraint was not met.3 5 Conclusions We have proposed that a planner should be provided with an explicit model of its own planning mechanism, and have shown that linking a planner’s expectations about the performance of its plans to such a model, by means of explicit justification structures, enables the planner to determine which aspects of its planning are responsible for observed performance failures. We have implemented the models of threat detection and execution scheduling described above in our test-bed system for failure-driven learning in planning domains (Collins, Birnbaum, and Krulwich, 1989). Applied to the game of chess, the model is capable of diagnosing planning failures due to incomplete knowledge of the rules, improper or overly optimistic focus of attention, faulty projection, and insufficient lead time for warning about threats, and is therefore able to learn such concepts as discovered attack and the fork. In other work (see, e.g., Collins, Birnbaum, and Krulwich, 1989), we have addressed the issue of how to use such diagnoses as a basis for repairing the planner’s procedures in order to avoid such failures in the future. We are currently developing explicit models of other aspects of planning, including plan formulation and optimization. In addition, we have identified a number of common sense planning concepts that could be acquired given richer models of threat detection and execution scheduling. For example, one possible reason for a planning system’s failure to detect a threat in time might be that it does not evaluate its threat-detection rules often enough. In general, the frequency with which these rules should be evaluated must be a function of the 31n fact, there are several other equivalence classes, since multiple constraints may fail for a given time. However, since the goal of fault diagnosis given disjunctive justifications is to find something to unfault, we start with those classes corresponding to a single failed constraint on the grounds that these are likely to prove easier to fix. 322 COMMONSENSE REASONING speed with which threats develop in a particular environment. It is therefore possible that a planner could learn the need to alter this frequency in different domains by applying failure-driven methods. Thus, extending the model of threat detection presented in this paper will allow us to provide a computational account of the acquisition of the common-sense planning heuristic that when things are happening quickly, a planner should pay closer attention. Acknowledgments: We thank Matt Brand, Kris Hammond, and Dick Osgood for many useful discussions. This work was supported in part by the Office of Naval Research under contract N00014- 89-J-3217, and by the Defense Advanced Research Projects Agency, monitored by the Air Force Office of Scientific Research under contract F49620-88-C- 0058. The Institute for the Learning Sciences was established in 1989 with the support of Andersen Consulting, part of The Arthur Andersen Worldwide Organization. References Birnl aum, L., and Collins, G. 1988. The transfer of experience across planning domains through the acquisition of abstract strategies. Proceedings of the 1988 Workshop on Case-Bused Reasoning, Clearwater Beach, FL, pp. 61-79. Birnbaum, L., Collins, G., and Krulwich, B. 1989. Issues in the justification-based diagnosis of planning failures. Proceedings of the Sixth International Workshop on Machine Learning, Ithaca, NY, pp. 194-196. Chien, S. 1989. Using and refining simplifications: Explanation-based learning of plans in intractable domains. Proceedings of the Eleventh ZJCAZ, Detroit, MI, pp. 590-595. Collins, G., and Birnbaum, L. 1990. Problem-solver state descriptions as abstract indices for case retrieval. Working Notes of the 2990 AAAZ Spring Symposium on Case-Based Reasoning, Palo Alto, CA, pp. 32-35. Collins, G., Birnbaum, L., and Krulwich, B. 1989. An adaptive model of decision-making in planning. Proceedings of the Eleventh IJCAI, Detroit, MI, pp. 511- 516. Davis, R. 1984. Diagnostic reasoning based on structure and behavior. Arti@%zZ InteQence, vol. 24, pp. 347-410. DeKleer, J., Doyle, J., Steele, G., and Sussman, G. 1977. AMORD: Exnlicit control of reasonine. Proceedinm of the ACM Symposium on Artificial intelligence and Programming Languages, Rochester, NY, pp. 116-125. DeKleer, J., and Williams, B. 1987. Diagnosing multiple faults. Artificial Intelligence, vol. 32, pp. 97-130. Doyle, J. 1979. A truth maintenance system. Artificial Intelligence, vol. 12, pp. 231-272. Hammond, K. 1989. Case-Bused Planning: Viewing Planning as a Memory Task. Academic Press, San Diego. Hayes-Roth, F. 1983. Using proofs and refutations to learn from experience. In R. Michalski, J. Carbonell, and T. Mitchell, eds., Machine Learning An Artificial Zntelligence Approach, Vol. I, Tioga, Palo Alto, CA, pp. 221-240. Kolodner, J. 1987. Capitalizing on failure through case- based inference. Proceedings of the Ninth Cognitive Science Conference, Seattle, WA, pp. 715-726. Manna, Z., and Waldinger, R. 1979. A deductive approach to program synthesis. Proceedings of the Sixth ZJCAI, Tokyo, pp. 542-551. Schank, R. 1982. Dynamic Memory: A Theory of Reminding and Learning in Computers and People. Cambridge University Press, Cambridge, England. Simmons, R. 1988. A theory of debugging plans and interpretations. Proceedings of the 1988 AAAI Conference, St. Paul, MN, pp. 94-99. Smith, R., Winston, H., Mitchell, T., and Buchanan, B. 1985. Representation and use of explicit justifications for knowledge base refinement. Proceedings of the Ninth ZJCAZ, Los Angeles, CA, pp. 673-680. Stallman, R., and Sussman, G. 1977. Forward reasoning and dependency-directed backtracking in a system for computer-aided circuit analysis. Artificial Intelligence, vol. 9, pp. 135-196. Sussman, G. 1975. A Computer Model of Skill Acquisition. American Elsevier, New York BIRBAUMETAL. 323
|
1990
|
77
|
997
|
Physical Impossibility Instead of Fault Models Gerhard Friedrich, Georg Gottlob, Wolfgang Nejdl Christian Doppler Laboratory for Expert Systems Technical University of Vienna, Paniglgasse 16, A-1040 Vienna, Austria - friedrich@vexpert .at Abstract In this paper we describe the concept of physical im- possibility as an alternative to the specification of fault models. These axioms can be used to exclude impos- sible diagnoses similar to fault models. We show for Horn clause theories while the complexity of finding a first diagnosis is worst-case exponential for fault mod- els, it is polynomial for physical impossibility axioms. Even for the case of finding all diagnoses using physical impossibility axioms instead of fault models is more ef- ficient, although both are exponential in the worst case. These results are used for a polynomial diagnosis and measurement strategy which finds a final sufficient di- agnosis. 1 Introduction Model-based diagnosis has traditionally been based on the use of a correct behavior model. Faulty components were assumed to show arbitrary behavior modeled by an unknown fault mode. An interesting extension to this approach is the in- clusion of specific fault models, which have been intro- duced in [3] and [S]. [3] retains an unknown fault mode and uses fault models to assign different probabilities to different behavior modes. [6] shows how to exclude im- possible diagnoses (“the light of a bulb is on although no voltage is present”) by deleting the unknown fault mode. However, in this case the fault models have to be complete to find the correct diagnoses. While the cor- rect model behavior can often be expressed as a Horn clause theory (with polynomial consistency checking’) the introduction of fault models leads to a non Horn clause theory in any case and thus to a computationally more complex algorithm for finding diagnoses. ‘In this paper we assume a system model guaranteeing a re- stricted term depth of all arguments and a restricted number of argument positions. Otherwise the problem would of course be undecidable or exponential. In this paper we investigate a third approach, which excludes impossible diagnoses by specifying physical impossibility axioms in the form of negative clauses. This approach does not enlarge the diagnosis complex- ity compared to a correct behavior based system, but usually excludes the same diagnoses as fault models. Starting from a Horn clause description of the correct behavior, the introduction of physical impossibility ax- ioms retains the Horn property. On the other hand the introduction of fault models leads to a non Horn theory resulting in an exponential algorithm for finding even a first diagnosis. Our approach is therefore advanta- geous in cases where the additional information which can be expressed by specific fault models (like proba- bilities of different behavior modes) is not needed or not available. In Section 2 we describe the concept of physical im- possibility and discuss the relationship between phys- ical impossibility and fault models. Section 3 shows the computational advantages of our approach and dis- cusses the worst-case complexity of finding diagnoses. A polynomial algorithm for finding a final sufficient di- agnosis is given which is not possible if we use fault models. Because of the space limitations formal definitions and complete proofs are given in a longer version of this paper. 2 hysical Impossibility To describe the notion of physical impossibility, let us first analyze the possible behavior of the components of a device. This behavior can be represented by speci- fying constraints between the state variables describing the component. We assume a finite domain for these variables. Each state variable can have only one value. The domain of a component can be specified by a fi- nite set of value tuples denoting all possible value com- binations which can be assigned to the state variables of the component. The arity of a tuple is equal to the number of variables describing a component. FRIEDRICH ET AL. 331 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. Figure 1: Tuple domain of a component including cor- rect behavior and fault model tuples. To diagnose a system various subsets of this domain may be specified. The relations of these sets are de- picted in Figure 1. We will discuss the following sets (using Sl \ S2 to denote S1 minus Sz): l correct behavior set denoted by ok o fault model set -ok o physical impossibility set (Domain \ (lok U ok)) In the following paragraphs we will describe how to represent correct, faulty, and impossible behavior. For each definition we show the appropriate rules used for the bulb example which has been introduced in [6]. Note, that the specific formalism used for describing a system model depends on the inference mechanism used. The general concepts defined here do not depend on it. In Figure 2 a simple circuit is shown, consisting of a power supply and three bulbs. Wires connect these components in parallel. The domain theory specifies the correct behavior of the circuit as usual, as described below. The literal ok(X) denotes that the component X works correctly. 202 w4 w6 Figure 2: Three bulbs and one voltage supply in par- allel The following axioms describe the correct behavior of our components. Variables are stated by capital letters and are universally quantified. In order to achieve a clear and simple presentation, we assume without los- ing generality that wires always behave correctly. (1) bulb(X) A ok(X) A vad(port(X), +) -+ val(light(X),on). (2) bulb(X) A ok(X) A val(port(X),O) --+ val(light(X), ofl). bulb(X) A ok(X) A val(light(X),ofl) -+ val(port(X), 0). bulb(X) A ok(X) A vad(light(X),on) + val(port(X), +). SUPPlY A ok(X) --+ val(port(X), +). Values are propagated along connections, each state variable can have only one value. val(Port1, Vaa) A conn(Portl,Port2) + val(Port2, Vaa). va/(Portl, Var) A conn(Port2, Portl) + val(Port2, Val). vad(Port, Vaal) A val(Port, Vu&?) + Vail = Va12. supply(s). conn(po~(s),port(bl)). bulb(bl). conn(port(s),port(b2)). bulb(ba). conn(port(s),port(b3)). bulb(b3). Additionally the following observations are made: val(dight(bl), 08). vad(light(bs), on). vaZ(light(ba), o#). The construction of conflict sets leads to four min- imal conflict sets (s,bl), (s, bz), (bl, b3) and (bz, b3) which determine two diagnoses [s, bs] and [b,, bz]. Now usually one would not consider bl and b2 to be correct while b3 and s are faulty producing light when there is no power supply. The additional information a diagnosis expert uses in this case is the knowledge about what is physically possible. If this knowledge is omitted (because only the correct behavior is modeled), “miracles” are possible. Using the principle of physical impossibility, we sim- ply exclude all tuples which are impossible. This can alwa.ys be done by completely negative clauses and thus without adding a non Horn clause to the description of the correct behavior. In our case: 7 (bulb(X) A val(!ight(X), on) A vaI(port(X),O)). Using domain closure axioms stating that a light can be on or ofl and that the volta.ge can be 0 or +, we get the following rules, which subsume rule 2 and 4 of our correct behavior rules. They can be used instead of the physical impossibility axiom. bulb(X) A val(/ight(X),on) + val(port(X), +). bulb(X) A vaI(port(X), 0) + val(iight(X), 08). On the other hand, a f&t m,oded consists of the following axiom to eliminate the undesirable diagnosis [s, b31: 332 COMMONSENSE REASONING bulb(X) A 7 ok(X) -+ (val(port(X),O) A val(light(X),off)) V (val(port(X), +) A val(light(X),o$)). This axiom can be simplified to bulb(X) A 7 ok(X) -+ val(light(X),o$). The introduction of fault models into a Horn the- ory describing the correct behavior always leads to a non Horn theory. (If we use the literal ah(X) denoting abnormal behavior, we have to include the additional axiom ah(X) H lok(X)). Both approaches reduce the conflict sets (s, bl), (+a) to (h) and (b2). This results in the elimina- tion of diagnosis [s, b3]. The reason for the conflict set reduction using the fault model approach is that ok(bg) can be deduced without assuming it, since the light is on. Therefore each single assumption ok(bl) and ok(b2) is inconsistent with the system description and the ob- servations. By using physical impossibility, we simply exclude the possibility, that a light is on with no volt- age present. Transforming the physical impossibility axiom using the domain axioms even lets us directly deduce the presence of voltage. (Note, that we use the domain axioms only during transformation, not for the final generation of the model.) This example suggests an equivalence between fault models and physical impossibility axioms. This equiv- alence can be formally described by the following the- orem: Theorem 1 If the domain and the model of correct behavior is represented and -ok(X) only appears in the clauses representing the correct behavior (e.g., ok(ci) + . . .) then the additional specification of a fault model is equivalent to the additional specification of the physical impossibility axioms for the task of diagnosis. We use the usual component oriented description and the assumption that faults are independent from each other. Rules like lok(ca) --) -ok(cj) are excluded. Proof (informal): Using domain axioms and the ax- ioms describing correct and faulty behavior we can de- duce the physical impossibility axioms. No additional conflict will result if we add the physical impossibility axioms to the system model. On the other hand using domain axioms, correct be- havior and physical impossibility axioms (which are specified by negative clauses), we can deduce the pos- sible behavior. Additionally for each component ca in a diagnosis we can deduce -ok(ci) otherwise the diag- nosis would not be minimal. This can be deduced only by using the correct behavior clauses, as -ok(c;) does not appear in any other clauses. Therefore every cor- rect behavior tuple leads to a contradiction. Using the possible behavior, we can now derive at least a subset of the faulty behavior subsuming the fault model. Let us denote the correct behavior axioms as &, the faulty behavior axioms as BF, the physical impossibil- ity axioms as al and the domain axioms as 2). Then we can write the equivalence of fault models and physical impossibility axioms for the purpose of finding all diagnoses somewhat informally as In most systems (especially those based on value propagation) only Horn clauses are used for describing correct and faulty behavior modes. Explicit domain ax- ioms are not included in the system model. Notwith- standing the potential incompleteness caused by this omission, we usually use such a simplified theory to avoid combinatorial explosion. Its incompleteness with respect to diagnosis decreases with an increasing set of measurements. What we would therefore like to prove is the fol- lowing equivalence of physical impossibility and fault models (without domain axioms) : Although this is indeed valid in many cases it is pos- sible to construct situations where the addition of Horn clause fault models yields a more complete theory than the addition of physical impossibility. If domain axioms are omitted physical impossibility axioms can there- fore only be a reasonable approximation. However, al- though Horn clause fault models yield better results in some cases, they are themselves an approximation (except if completely unrestricted clauses are used). In Section 3 we will show that physical impossibil- ity axioms do not degrade the efficiency of the diag- nosis algorithm. We can still construct a polynomial algorithm finding a final sufficient diagnosis for such a theory. On the other hand we show that fault models are intractable, something we wanted to avoid when we excluded the domain axioms initially. So we are faced once again with the well-known completeness/efficiency tradeoff often encountered in AI. 3 Efficiency and Complexity 3.1 Efficiency Considerations To allow efficient consistency checking and diagnosis generation, we use Horn clauses for our system model as much as possible. This corresponds to the use of value propagation as inference engine. Usually only the FRIEDRICH ETAL. 333 subset of the correct behavior which can be expressed o fault models (all 6 modes): 22.9 by functional dependencies is used in the system model. In this example we achieved a runtime improvement It is clear that by extending such a Horn clause the- factor of 22.9 by using physical impossibility axioms in- ory by physical impossibility axioms (which are nega- stead of fault models. Note, that this does not depend tive or definite clauses) we do not increase the complex- on our algorithm, but simply mirrors the combinato- ity of the diagnosis process, while even the inclusion of rial explosion caused by the non Horn theory (see also Horn clause fault models automatically makes the the- [4]). Each fault model introduces alternative rules used ory non Horn, leading to the well-known combinatorial explosion. for value propagation and we have exponentially many combinations of fault models. Example 1 We use the standard d74 circuit depicted in Figure 3.1 with six different behavior modes (as used in [4], see Figure 3.1). a 3 X ml b f 2 al - 2 C m2 - Y 2 d a2 g 3 8 e m3 3 1. output is correct 2. output is zero 3. output is left input 4. output is right input 5. output is one 6. output is shifted left one bit Figure 3: D74-circuit On the other hand physical impossibility is barely affected by the introduction of additional fault models, as only the checks to exclude impossible diagnoses get slightly more complicated. No new values are deduced because of the physical impossibility axioms. Consis- tency has to be checked only for a Horn clause theory. 3.2 Complexity In the following we will concentrate on Horn clause the- ories for the correct and faulty behavior and the phys- ical impossibility axioms. This is sufficient for most cases and usually used by value propagation systems. It also allows us to capture all functional dependencies. For consistency based model-based diagnosis we can state the following complexity theorems. They are in- dependent of the inference strategy used. Theorem 2 Assume a description of the correct be- havior by a (propositional) Horn clause theory, a set of observations and a set of (already found) diagnoses Z?. The complexity of deciding whether a next diagnosis exists which is not in 2, is n/p-complete. We do not use an unknown fault mode, as such a mode would allow any possible behavior. Such a fault mode is therefore only interesting if we rely on proba- bility ranking. Proof (informal): The problem is obviously in NP. By reduction to SAT we can show that it is also NP- complete. out the additional fault mode information. Initial measurements are a = d = e = 3, b = c = 2, f = 2 and g = 8. The two double fault diagnoses for these measurements are [(ul, right), (m2,left)] and [(ml, zero), (m2, left)]. Using physical impossibility we get the same diagnoses as using fault models, with- However, if we just want to change the faulty components, the exact fault mode is irrelevant. (In this example, the physical impossibility axioms define that any behavior not covered by the behavior modes is inconsistent.) Using the MOM0 system described in [5] we got the following normalized model generation times (for find- ing all diagnoses) : Let C be a set of propositional clauses in SAT form. Let U be the set of variables used in C. Assume fur- ther for each x (lx) that there exists at least one clause c E C such that x (lx) does not occur in c. We use the following instance of the next diagnosis problem ND = (COMP, SD, OBS, D) consisting of a set of compo- nents, a system description, a set of observations and of diagnoses. COMP = {x,zlxaJ} SD = G,uG2uG3uG, OBS = {TZ} D = {{x,~}~x”:U} G = { [AzEe okz A /j+cok~] - f 1 c E C} G2 = {ok,-+f,okz~~~x~U) G3 = (A XcEU k - u > G4 = (uAf+z) o physical impossibility (4 or 6 modes): 1 e fault models (first 4 modes): 7.6 334 COMMONSENSEREASONING For a diagnosis A 4 D the following truth value as- signment satisfies C: Using this assignment we can show C satisfiable _ 3A $! D for ND This complexity theorem is valid if the system de- scription includes just a model of correct behavior con- sisting of propositional Horn clauses. Extending the model by fault models or physical impossibility axioms can not decrease the complexity. Sometimes it is sufficient to find just one initial di- agnosis, especially if we take various repair or measure- ment strategies into account. Let us therefore compare the complexity of this problem for physical impossibil- ity and fault models. While both physical impossibility and fault models exclude impossible diagnoses, the difference between them is, that the use of a fault model also influences the candidate space and the use of physical impossibility does not. This is expressed by the following theorem: Theorem 3 If we add physical impossibility axioms to the correct behavior model, each superset of a diagnosis is consistent. Proof (informaZ): No clause from the description of the correct behavior and the physical impossibility ax- ioms contains the positive literal ok(c). Only negative literals lo/z(c) appear in the clauses describing the cor- rect behavior. Therefore adding loL(c) for some com- ponent c to a diagnosis can not lead to a contradiction as we cannot derive ok(c) from the given theory. We can define a polynomial algorithm for a system description consisting of correct behavior and physical impossibility axioms to find a diagnosis: Algorithm 1 (Finding the First Diagnosis) 1. Take the candidate which assumes all components to be faulty. This candidate has to be correct oth- erwise the system description itself is inconsistent. 2. Now remove an arbitrary component from the can- didate, i.e. assume the component to be correct. The component has to be chosen in such a way that the remaining candidate is consistent. Com- ponents need only be checked once. In a value propagation system new values may be deduced for each component which is assumed to be cor- rect. If the theory proves to be inconsistent, these values have to be retracted. 3. Do this until no more components can be removed from the candidate (i.e. all components have been tried). The (minimal) candidate found can be out- put as first diagnosis. Proof (informa/): As the candidate space is contigu- ous, algorithm 1 always finds a minimal candidate. The inclusion of ok(C) is monotonous so the algorithm per- forms exactly n consistency checks. Note, that checking consistency of all single faults by a simple algorithm exhibits also a worst-case complex- ity of n and a average case complexity of n/2, if we set the cost for a consistency check to 1. If we use conflict sets to compute the single faults the complexity is ex- ponential in the worst case. (Consider the case, where we have exponential many conflict sets.) Finding the first diagnosis using a system description with several incompatible behavior modes is exponen- tial in general. For fault models which do not exclude any diagnosis compared to the correct behavior model alone (e.g. if the unknown fault mode is included), we can find the first diagnosis in polynomial time simply by deleting all fault model axioms. Theorem 4 Let us assume, that we extend the de- scription of the correct behavior by clauses describing the faulty behavior and that these clauses include the positive literal oL(ca) for the described components ci, which appears in negative form in the correct behavior clauses. Then deciding whether a first diagnosis exists is NF-complete. Proof (informal): The proof is very similar to the next diagnosis problem. We transform sets of assump- tions which are inconsistent (like {ok(q), -ok(q)}) into already found diagnoses. (By the way, even deciding whether there exists an arbitrary consistent candidate is n/P-complete.) Similar results to theorem 2 and 4 have been shown in an interesting paper of Bylander et al ([l]) in the context of abductive reasoning. However, the trans- formation from a consistency-based diagnosis problem into an abductive one sketched in their paper using conflict sets is not preferable, as the number of conflict sets can grow exponentially resulting in an exponential algorithm for the transformed problem. 3.3 Polynomial Diagnosis Strategies The results described in the previous section indicate the complexity of the consistency based diagnosis prob- lem. However, it is still possible to define a polynomial diagnosis algorithm for finding a sufficient2 diagnosis as 2By sufficient we mean a correct diagnosis we want to accept the final one depending on some termination criterion. FRIEDRICH ET AL. 335 by using our first diagnosis algorithm for correct be- havior and physical impossibility axioms. Unfortunately, a measurement selection function de- rived from entropy (e.g. [2], [3]) tries only to minimize the number of measurements (and therefore measure- ment costs). What is not included in the minimization process are the inference costs which, however, can get exponential. We have to use measurement selection heuristics, which need to compute only one diagnosis. Algorithm 2 Polynomial algorithm for finding a suf- ficient diagnosis (if correct behavior and physical im- possibility rules are given): 1. Find the first diagnosis using all available obser- vations (algorithm 1). 2. If the diagnosis found fulfills the termination cri- terion, then exit. This could be the case if we can prove the components included in the diagno- sis to be faulty without assuming the correctness of other components. In other cases, an immedi- ate repair may be more cost efficient than further testing. 3. Take additional actions to get new information such as o Take one or more additional measurements. o Try to prove a component to be correct or faulty. l Replace a component by a good one, etc. Which strategy we take and which measurements we choose may depend on the conflicts found so far, the failure probability of the components, cost of testing etc. Trying to prove or disprove the cur- rent diagnosis is also a good heuristic. If we can prove a component ci to be correct for the given exogenous variables (i.e. by measuring its direct inputs and outputs), it can be excluded from a diagnosis. We can assume ok(~) for such a com- ponent. This might also be done by using an in- ternal test. Replacing a component by a good one has usually the same effect. 4. got0 1 The difference to the algorithm used in [2] and sim- ilar algorithms is that only one diagnosis is computed at each iteration. As only polynomially many measure- ment points exist and the number of consistency checks is polynomial, the algorithm halts in polynomial time. 4 Conclusion We have described the concept of physical impossibility as an alternative to fault models. Compared to fault models physical impossibility axioms result in a more efficient computation of diagnoses. We also described a polynomial algorithm for finding the first diagnosis using physical impossibility axioms. The inclusion of fault models even into a Horn clause system model was shown to lead to a n/P-complete decision procedure to check for a first diagnosis. For both finding the next diagnosis is exponential in general. By relaxing the op- timality criterion for measurement selection as defined in [2] we are able to define a simple algorithm for find- ing a final sufficient diagnosis in polynomial time using correct behavior and physical impossibility axioms. Acknowledgements We thank Peter Struss, Oskar Dressler, Hartmut Freitag, Olivier Raiman, and Johan de Kleer for their comments to a previous version of this paper. eferences PI PI PI PI PI PI Tom Bylander, Dean Allemang, Michael C. Tan- ner, and John R. Josephson. Some results con- cerning the computational complexity of abduction. In Proceedings of the International Conference on Principles of Knowledge Representation and Rea- soning, pages 44-54, Toronto, May 1989. Morgan Kaufmann Publishers, Inc. Johan de Kleer and Brian C. Williams. Diagnosing multiple faults. Artificial Intelligence, 32197-130, 1987. Johan de Kleer and Brian C. Williams. Diagno- sis with behavioral modes. In Proceedings of the International Joint Conference on Artificial Intelli- gence, pages 1324-1330, Detroit, August 1989. Mor- gan Kaufmann Publishers, Inc. Oskar Dressler and Adam Farquhar. Problem solver control over the ATMS. In Proceedings of the German Workshop on Artificial Intelli- gence, pages 17-26, Eringerfeld, September 1989. Springer-Verlag. Gerhard Friedrich and Wolfgang Nejdl. MOM0 - Model-based diagnosis for everybody. In Proceed- ings of the IEEE Conference on Artificial Intelli- gence Applications, Santa Barbara, March 1990. Peter Struss and Oskar Dressler. Physical negation - Integrating fault models into the general diag- nostic engine. In Proceedings of the International Joint Conference on Artificial Intelligence, pages 1318-1323, Detroit, August 1989. Morgan Kauf- mann Publishers, Inc. 336 COMMONSENSE REASONING
|
1990
|
78
|
998
|
de of Coherence lanation* Hwee Tou Ng Raymond J. Mooney Department of Computer Sciences University of Texas at Austin Austin, Texas 78712 htng&s.utexas.edu, mooney@cs.utexas.edu Abstract Abduction is an important inference process un- derlying much of human intelligent activities, in- cluding text understanding, plan recognition, dis- ease diagnosis, and physical device diagnosis. In this paper, we describe some problems encoun- tered using abduction to understand text, and present some solutions to overcome these prob- lems. The solutions we propose center around the use of a different criterion, called explana- tory coherence, as the primary measure to eval- uate the quality of an explanation. In addition, explanatory coherence plays an important role in the construction of explanations, both in deter- mining the appropriate level of specificity of a preferred explanation, and in guiding the heuris- tic search to efficiently compute explanations of sufficiently high quality. 1 Introduction Finding explanations for properties and events is an important aspect of text understanding and of intelli- gent behavior in general. The philosopher C.S. Peirce defined abduction as the process of finding the best explanation for a set of observations; i.e. inferring cause from effect. The standard formalization of ab- ductive reasoning in artificial intelligence defines an explanation as a set of assumptions which, together with background knowledge, logically entails a set of observations [Charniak and McDermott, 19851. Natural language understanding has recently been studied in terms of abduction [Charniak, 1986, Hobbs et al., 19881. Specifically, abduction has been used to solve problems ranging from resolv- ing anaphoric references and syntactic ambiguity [Hobbs et al., 19881 t o recognizing characters’ plans in a narrative [Charniak, 19861. *This research is supported by the NASA Ames Re- search Center under grant NCC-2-429. The first author was also partially supported by a University of Texas MCD fellowship. We have built an understanding system called AC- CEL (Abductive Construction of Causal Explanations for Language) that is capable of constructing deep, causal explanations for natural language text (both narrative and expository text) through the use of ab- duction. In this paper, we focus on several problems that arise when applying abduction to text under- standing. These problems include: (1) the inadequacy of the frequently used simplicity criterion, i.e. “Oc- cam’s Razor”, in selecting the preferred abductive ex- planation; (2) the determination of an abductive proof of the appropriate level of specificity; and (3) the com- putational intractability of abduction. The solutions we propose to these problems center around the use of a different criterion, called explanatory coherence, to construct and evaluate abductive explanations. 2 The Basic Abductive Mechanism A generic abductive inference procedure operates as follows. The background knowledge is encoded in Horn clause axioms. Given a conjunction of positive literals which encodes the input sentences, the abduc- tive inference procedure computes all possible abduc- tive proofs by backward-chaining on the input literals using the Horn clause axioms in the knowledge base, much like Prolog. However, when there is no fact or consequent of a rule in the knowledge base that uni- fies with a subgoal in the current partial proof, instead of the proof failing, the abductive procedure has the choice of making that subgoal an assumption, if it is consistent to do so. Inconsistency is detected by call- ing a theorem prover to try to deduce a contradiction. Since consistency checking is undecidable in general, we impose a depth bound in the theorem prover such that it only tries to search for a proof of inconsistency within the depth bound. Hence, an abductive proof is a proof of the conjunc- tion of the input literals using Horn clause rules and facts in the knowledge base, together with a set of assumptions. An abductive proof is considered an ex- planation, or an interpretation of the input sentences. NC AND MOONEY 337 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. 3 Problems and Solutions “John was happy. The exam was easy.” The basic abductive mechanism has several problems. These problems and their solutions are described be- low. (name j jolm) (haps j) 4 (succeed j e) 3.1 Occam’s Razor Isn’t Sharp Enough Most previous research on abduction, whether applied to plan recognition, language understanding, disease diagnosis, or physical device diagnosis, only uses “Oc- cam’s Razor”, i.e. the simplicity criterion, as the ba- sis for selecting the best explanation. For instance, in (exam e) (easy e) Wdy j 6 We j e) Interpretation 1 E= l,A=2 Simplicity metric = E/A = l/2 Coherence metric = (1+1)/(7*(4*3/2)) = 0.048 [Charniak, 19861, the best interpretation is one that la maximizes E - .- i A, where E - - incorporates the assumption of minimizing the num- = the number of ex- plained observations, and A = the number of assump- tions made. ber of top level events in deducing the plan that an The work of [Hobbs et al., 19881 also adopts a similar simplicity criterion. In [Reiter, 19871, he proposed a simplicity criterion based on subset- containment minimality. Other related work, though not explicitly utilizing abduction, also relies on some kind of simplicity criterion to select the best explana- tion. For example, IKautz and Allen, 19861 explicitly (name j john) (happy j) (exam e) (easy e) + (optimist j) Interpretation 2 E=l,A= 1 Simplicity metric = E/A= l/l Coherence metric = 0 lb agent is pursuing. Though an important factor, the simplicity criterion is not sufficient by itself to select the best explanation. We believe that some notion of explanatory-coherence is more important in deciding which explanation is the best. This is especially true in the area of language un- derstanding and plan recognition. Consider the sen- tences: “John was happy. The exam was easy.” The sentences translate into the conjunction of the follow- ing 1iterals:l b=e j john), (happy j>, (exam e), (easy e). A knowledge base of axioms relevant to these input literals are: (happy ?x) <- (optimist ?x) (happy ?x) <- (succeed ?x ?y> (succeed ?x ?y) <- (exam ?y> (easy ?y) (study ?x ?y> (take ?x ?y) Based on these axioms, there are two possible in- terpretations of these sentences, as shown in Figure la and lb. Relying on the simplicity metric results in selecting the interpretation that John was happy because he is an optimist, someone who always feels good about life in general (Figure lb). This is in con- trast with our preferred interpretation of the sentence - John was happy because he did well on the easy exam (Figure la).2 Intuitively, it seems that the first interpretation (Figure la) is better because the input observations Figure 1: The importance of explanatory coherence are connected more “coherently” than in the second interpretation (Figure lb). We manage to connect “John was happy” with the “easy exam” in the first interpretation, whereas in the second interpretation, they are totally unrelated. This is the intuitive no- tion of what we mean by explanatory coherence. It is clear that “Occam’s Razor”, i.e. making the minimum number of assumptions, is not the dominant deciding factor here at all. Rather, we select an explanation based on its coherence, i.e. how well the various ob- servations are “tied together” in the explanation.3 That sentences in a natural language text are con- nected in a coherent way is reflected in the well known “Grice’s conversational maxims” [Grice, 19751, which are principles governing the production of natural lan- guage utterances, such as “be relevant”, “be informa- tive”, etc. Although the notion that natural language text is coherently structured has long been recognized by researchers in natural language processing (see for example [Allen, 1987]), p revious work on abduction applying to the tasks of text understanding and plan recognition has not included this criterion in its eval- uation of explanations. The use of explanatory coher- ence here attempts to remedy this problem. ’ Since we do not focus on the parsing aspect of language understanding, we assume the existence of some appropri- ate parser that translates the given set of input sentences into a logical representation consisting of a set of literals. 2Note that the simplicity criterion of [Reiter, 19871 based on subset minimality also does not work well for this example - it is indifferent towards both interpretations, instead of choosing the preferred one. 3[Thagard, 19891 h as independently proposed a com- putational theory of explanatory coherence that applies to the evaluation of scientific theories. However, his theory of explanatory coherence consists of seven principles - sym- metry, explanation, analogy, data priority, contradiction, acceptability, and system coherence. Independent criteria like simplicity and connectedness have been collapsed into one measure which he termed “explanatory coherence”. 338 COMMONSENSE REASONING We would like to formulate our coherence metric so as to possess several desirable properties. In particu- lar, explanations with more connections between any pair of observations, as well as those with fewer dis- joint partitions are more coherent. Also, a coherence metric with values lying in a unit range O-l will facil- itate the comparison of explanations. We have developed a formal characterization of what we mean by explanatory coherence in the form of a coherence metric that satisfies the above mentioned properties. The metric is defined as follows : where ): Ni,j C= l<i<j<l N ii ( > d = the total number of observations; N = the total number of nodes in the proof graph; z ( > 2 = Z(Z - 1)/2; Ni,j = the number of distinct nodes nk in the proof graph such that there is a (possibly empty) sequence of directed edges from nk to ni and a (possibly empty) sequence of directed edges from nk to nj , where ni and nj are observations. The numerator of this metric is a measure of the total number of nodes in the explanation connecting pairs of observations. This measure is constructed so that it increases with the number of nodes in the expla nation which simultaneously lend support to a given connection. The denominator of the metric simply scales the result according to the size of the explana- tion so that the final value falls between 0 and 1. To illustrate the computation of the coherence met- ric, consider the explanation in Figure la. Let n1 = (name j john), n2 = (happy j), n3 = (exam e), n4 = (easy e), 725 = (succeed j e), n6 = (study j e), and n7 = (take j e). In th is explanation, the total number of nodes N = 7, and the total number of observations I = 4. N2,3 = 1, since there is exactly one node (namely n3) such that there is a directed path from n3 to n2 and also a directed path from n3 to n3 (the trivial empty path). Similarly, N2,4 = 1. All other Ni,j = 0. This results in the coherence metric C = 0.048, as shown in Figure la. The coherence metric as defined above can be effi- ciently computed. Using a standard depth-first search graph algorithm4, it can be readily shown that C can be computed in time 0(a . N + e), where I = the total number of observations, N = the total number of nodes in the proof graph, and e = the total number of directed edges in the proof graph [Ng and Mooney, 19891. Based on the coherence met- ric, ACCEL has successfully selected the best in- *We assume he re that the proof graph contains no cy- cles, since circular justification is not considered a good trait of an explanation. terpretation for a half dozen examples of exposi- tory and narrative text that we have tested. (See [Ng and Mooney, 19891 for the list of examples suc- cessfully processed by ACCEL.) We note here some additional advantages of our co- herence metric. One observation is that coherent ex- planations also tend to be simple explanations. This is because in a coherent explanation, propositions tend to be more tightly connected. This increases the like- lihood of assumptions being unified, and leads to a re- duction in the number of assumptions made and thus a simpler explanation. In addition, compared to the simplicity metric, the coherence metric is less vulnerable to changes in the underlying representation of the knowledge base. It is relatively easy to encode the axioms in a knowl- edge base in a slightly different way so as to change the number of assumptions made in an explanation. However, connections between propositions are less dependent (relatively speaking) on such changes. For example, suppose we change the axioms in the given example slightly so that as long as one takes an easy exam, one will succeed in the exam without having to study for it. Also, suppose one has to be wealthy as well as an optimist to be happy. Given this mod- ified set of axioms, the first interpretation now only requires one assumption, while the second interpreta- tion requires two. So all of a sudden, the first inter- pretation becomes the simpler explanation of the two. However, the coherence metric of the first interpreta- tion (= (1+1)/(6*(4*3/2)) = 0.056) is still higher than that of the second (which remains at zero). 3.2 Deciding on the Appropriate Level of Specificity of Explanations Another problem in constructing a good explanation is determining the appropriate level of specificity of an abductive proof. Previous approaches fall into one of three categories : most specific abduction, least spe- cific abduction, and weighted abduction.5 In most specific abduction, the assumptions made must be basic, i.e. they cannot be “intermediate” assumptions that are themselves provable by assum- ing some other (more basic) assumptions. This is the approach used in the diagnosis work of [Cox and Pietrzykowski, 19871. In least specific ab- duction, the only allowable assumptions are literals in the input observations. [Stickel, 19881 claims that least specific abduction is best suited for natural lan- guage interpretation. He argues that what one learns from reading a piece of text is often close to its sur- face form, and that assuming deeper causes is unwar- ranted. In weighted abduction [Hobbs et al., 19881, weights (or costs) are assigned to the antecedents of 5[Stickel, 19881 d escribes yet another form of abduction known as predicate specific abduction, which has been used primarily in planning and design-synthesis tasks. In pred- icate specific abduction, the predicate of any assumption made must be one of a pre-specified set of predicates. NG AND MOONEY 339 (worker ?w johnl) (place-of-work ?w sml) @St go1 going) (goer go1 johnl) (dest go1 sml) johnl) (thing-worn ?w ul) (thing-put-on put-on1 ul) (iist ul uniform) “John went to the supermarket. He put on the uniform.” Coherence metric (without backchainmg on (ii sml smarket)) = 0.0537 Coherence metric (with backchainmg on (it sml smarket)) = 0.0474 Figure 2: The level of specificity of explanation backward-chaining rules in order to influence the de- cision on whether to backchain on a rule. In this case, the best interpretation is the one with assumptions that have the lowest combined total cost. However, none of these approaches is completely satisfactory. Consider the sentences “John went to the supermarket. He put on the uniform.” Both least specific and most specific abduction fail to generate the preferred interpretation in this case, which is that John is working at the supermarket. Figure 2 shows the proof graph of the preferred interpretation of this example (excluding the dashed lines and boxes). (See [Ng and Mooney, 19891 for the details of the relevant axiomatization.) Note that nowhere in the input sentences is the con- cept of “working” mentioned at all. It has to be in- ferred by the reader. Since this preferred interpreta- tion includes making the assumptions that there is a working event, that John is the worker of this working event, etc, it is evident that least specific abduction, in which the only allowable assumptions are input lit- erals, is incapable of arriving at this explanation. On the other hand, most specific abduction will not do the job either. Recall that most specific abduction always-prefers backchaining on rules to prove a sub- goal if possible rather than making that subgoal an assumption. Thus, applying most specific abduction to this example results in backchaining on the input literal (inst sml smarket) to the assumptions (inst ?s smarket-shopping) and (store-of ?s sml), since in the present knowledge base, this is the only backchain- ing rule with a consequent that unifies with (inst sml smarket).6 That is, we explain the going action, its agent and its destination by assuming that John is working there, and we are also forced to assume, by the requirement of most specific abduction, that there is some supermarket shopping event to explain the supermarket instance. 1 This is because most specific abduction requires that we have an explanation for why John went to the supermarket as opposed to some other workplace. This is clearly undesirable. However, determining the level of specificity of an explanation based on coherence produces the desired interpretation. That is, we backchain on rules to prove the subgoals in an explanation only if doing so in- creases its overall coherence, and thus we make as- sumptions just specific enough to connect the obser- vations. In the current example, backchaining on (inst sml smarket) results in a decrease in the coherence metric value, since the total number of nodes in the proof graph increases by two but there is no increase in the number of connections among the input obser- vat ions. Intuitively, explaining the supermarket in- stance by assuming a supermarket shopping event is completely unrelated to the rest of the explanation that John is working there. The coherence metric has been successfully used in ACCEL to determine the ap- propriate level of specificity of explanations, where the desired specificity is one which maximizes coherence. The weighted abduction of [Hobbs et al., 19881 would presumably arrive at the correct interpretation given the “appropriate” set of weights. However, it is unclear how to characterize the “semantic contri- bution” of each antecedent in a rule in order to assign the appropriate weights. In contrast, our method does not rely on tweaking such weights, and it produces the preferred interpretation with the desired level of speci- ficity in all of our examples. We believe that allowing arbitrary weights on rules is too much of a burden on the knowledge engineer. It also provides too many degrees of freedom, which can lead to the knowledge engineer “hacking up” arbitrary weights in order to get the system to produce the desired explanation. 3.3 Taming the Intractability Problem Finding a simplest abductive explanation has been shown to be NP-hard [Reggia et al., 1985, Bylander et al., 19891. H owever, an optimal explana- tion in our system is one with the highest coherence, as opposed to the simplest explanation, and so none of the proofs in the above research applies directly. Nonetheless, we have a proof that finding a maximally coherent explanation that satisfies simple contradic- tion restrictions in a two-level, propositional abduc- ‘(inst sml smarket) denotes “sml is an instance of a supermarket” ; (inst ?s smarket-shopping) denotes “?s is an instance of a supermarket shopping event; and (store- of ?s sml) denotes “the store of the shopping event ?s is sml” . 340 COMMONSENSE REASONING tion model is NP-hard. As such, the use of heuristic search to explore the vast space of possible solutions seems to be a good strategy to adopt. In fact, we have implemented a form of beam search that has success- fully computed the preferred interpretation of all of our examples very efficiently. We use a beam search algorithm with two beam widths, called inter-observation beam width (@inter) and in-&u-observation beam width (&tra), in order to reduce the explored search space. A queue of best explanations is kept by the beam search procedure, forming the “beam” of the beam search. At all times, explanations in the queue are sorted by coherence, where the best explanation is the one with the highest coherence.7 Only at most Pinter number of the best ex- planations are kept in the queue after completing the processing of each input observation. Within the pro- cessing of an input observation, at most /?intra number of best explanations are kept in the queue. We have adopted two beam widths instead of one as in a typical beam search algorithm since we have found out em- pirically that optimal solutions can be computed most efficiently using two beam widths of different sizes. Figure 3 shows how the quality of the best explana- tion varies with run time for the supermarket working example with different values of flinter and @intra. We use the ratio of the coherence metric value of an ex- planation over that of the optimal explanation to rep- resent the quality of an explanation. All the run times reported in this paper are the actual execution times on a Texas Instruments Explorer II Lisp machine. Each data point in the Figure represents a quality- time pair obtained by using some specific values of P inter and ,&tra. Each curve connects all the data points with the same @inter but different ,Dintra. With- out using any heuristic search (i.e., if a complete search is made), it takes more than 3 hours to compute the optimal solution, while setting @inter = 3 and Pintra = 8 yields the optimal solution in 0.89 min, which represents a speed up of over 200 times! Also, fixing P. anter = 4 and /3intra = 13, the optimal explanations are computed in about one minute on average for the half dozen examples of expository and narrative text that we have tested. 4 Related Work Several research efforts have focused on abduc- tion as an important inference process in plan recognition [Charniak, 19861, natural language un- derstanding [Hobbs et al., 19881, disease diagno- sis [Pople, 19731, and physical device diagnosis [Cox and Pietrzykowski, 19871. In the area of natu- ral language understanding, [Hobbs et al., 19881 de- scribes the use of abduction in solving the four lo- cal pragmatics problems of text understanding. This 7Ties are broken based on the simplicity metric of E/A, where E is the number of observations explained and A is the number of assumptions made. Explanation Quality versus Run Time Q W I I I 100.00 - 95.00 - 90.00 - 85.00 - 80.00 - 75.00 - 70.00 - 65.00 - r= 60.00 - / 55.00 - .i/ 50.00 - g..-.- I’ 45.00 - 40.00 - 35.00 - 30.00 - 2.m - ml0 - 15.00 - 10.00 - i 5.00 - I 0.20 I 0.40 I 0.60 - - - - I 0.80 I I .oo I 1.20 I - 1.40 Figure 3: Explanation Quality versus Run Time work differs from ours in that unlike their empha- sis on mostly linguistics issues like reference resolu- tion and syntactic ambiguity resolution, ACCEL is concerned with constructing deep, causal explana- tions of the input text. The work of [Charniak, 19861 and [Charniak and Goldman, 19891 are most similar to ours. However, they are primarily concerned with recognizing characters’ plans and goals in narrative stor’ies, whereas ACCEL is also capable of construct- ing causal explanations for expository text. For exam- ple, a complete understanding of an encyclopedia text describing animals requires understanding the purpose or reason for the various features of the animals. (See [Ng and Mooney, 19891 for a list of expository text sentences that can be processed by ACCEL.) Also, explanations are evaluated based on their explanatory coherence in our work, as opposed to the simplicity criterion of [Charniak, 19861 and the probability crite- rion of [Charniak and Goldman, 19891. Furthermore, the work of [Charniak, 19861 used marker passing to restrict the search for explanations, whereas we used a form of beam search for the efficient construction of explanations. The Bayesian probabilistic approach to plan recog- nition and text understanding has been proposed by [Charniak and Goldman, 19891. Besides the problem of engineering the numerous prior and posterior prob- abilities of the nodes in a Bayesian network, this ap- proach does not take into account the importance of text coherence. For instance, in the sentences “John got a gun. He entered the grocery store.“, one can set NG AND MOONEY 341 up reasonable probability estimates such that the con- ditional probability that John was both hunting and shopping is higher than that of John robbing the store (given the propositions stated in the text). However, selecting an interpretation based solely on the prob- ability of propositions about the situation being de- scribed is ignoring the fact that these propositions are adjacent sentences in a natural language text, not just random facts observed in the world. As illustrated by this example, text coherence dominates and results in the reader selecting the more coherent interpretation that John was robbing the store. 5 Future Research We plan to investigate the efficiency gain which may be brought about by incorporating an ATMS (Assumption-based Truth Maintenance System) into the abductive inference procedure, so as to efficiently keep track of the dependency among the assumptions and propositions of various competing explanations. Since uncertainty and likelihood information is needed in order to achieve a complete understanding of natural language text, and because a straightfor- ward application of Bayesian probability theory does not give a completely satisfactory solution (as we have illustrated here), an approach that will integrate both the importance of text coherence and likelihood infor- mation is an important issue in future research. 6 Conclusion In summary, we have described some problems en- countered using abduction to understand text, and have presented some solutions to overcome these prob- lems. The solutions we propose center around the use of explanatory coherence to evaluate the quality of ex- planations, to determine the appropriate level of speci- ficity of explanations, and to guide the heuristic search to efficiently compute explanations of sufficiently high quality. These solutions have proven to be very effec- tive on a range of examples in text understanding. References [Allen, 19871 James F. Allen. Natural Language Un- derstanding. Benjamin/Cummings, Menlo Park, CA, 1987. [Bylander et al., 19891 Tom Bylander, Dean Alle- mang, Michael C. Tanner, and John R. Josephson. Some results concerning the computational com- plexity of abduction. In Proceedings of the First International Conference on Principles of Knowl- edge Representation and Reasoning, pages 44-54, Toronto, Ontario, Canada, 1989. [Charniak and Goldman, 19891 Eugene Charniak and Robert P. Goldman. A semantics for probabilistic quantifier-free first-order languages, with particular application to story understanding. In Proceedings of the Eleventh International Joint Conference on Artificial Intelligence, 1989. 342 COMMONSENSE REASONING [Charniak and McDermott, 19851 Eugene Char- niak and Drew McDermott. Introduction to Arti- ficial Intelligence. Addison Wesley, Reading, MA, 1985. [Charniak, 19861 Eugene Charniak. A neat theory of marker passing. In Proceedings of the National Con- ference on Artificial Intelligence, pages 584-588, Philadelphia, PA, 1986. [Cox and Pietrzykowski, 19871 P. T. cox and T. Pietrzykowski. General diagnosis by abductive inference. In Proceedings of the 1987 Symposium on Logic Programming, pages 183-189, 1987. [Grice, 19751 H. P. Grice. Logic and conversation. In P. Cole and J. Morgan, editors, Syntax and Semun- tics 3 : Speech Acts, pages 41-58. Academic Press, New York, 1975. [Hobbs et al., 19881 Jerry R. Hobbs, Mark E. Stickel, Paul Martin, and Douglas Edwards. Interpretation as abduction. In Proceedings of the 26th Annual Meeting of the Association for Computational Lin- guistics, pages 95-103, Buffalo, New York, 1988. [Kautz and Allen, 19861 Henry A. Kautz and James F. Allen. Generalized plan recognition. In Proceedings of the National Conference on Artificial Intelligence, pages 32-37, Philadelphia, PA, 1986. [Ng and Mooney, 19891 Hwee Tou Ng and Ray- mond J. Mooney. Abductive explanation in text un- derst anding : Some problems and solutions. Tech- nical Report AI89-116, Artificial Intelligence Labo- ratory, Department of Computer Sciences, The Uni- versity of Texas at Austin, October 1989. Pople, 19731 Harry E. Pople, Jr. On the mechaniza- tion of abductive logic. In Proceedings of the Third International Joint Conference on Artificial Intelli- gence, pages 147-152, 1973. Reggia et al., 19851 James A. Reggia, Dana S. Nau, and Pearl Y. Wang. A formal model of diagnostic in- ference. I. problem formulation and decomposition. Information Sciences, 37~227-256, 1985. [Reiter, 19871 R y a mond Reiter. A theory of diagnosis from first principles. Artificial Intelligence, 32:57- 95, 1987. [Stickel, 19881 Mark E. Stickel. A Prolog-like inference system for computing minimum-cost abductive ex- planations in natural-language interpretation. Tech- nical Note 451, SRI International, September 1988. [Thagard, 19891 Paul Thagard. Explanatory coher- ence. Behavioral and Bruin Sciences, 12(3):435-467, September 1989.
|
1990
|
79
|
999
|
Stolving Large-Scale Constraint Satisfaction an Scheduling Problems Using a epair Metho Steven Mintonl Mark D. Johnston2 Andrew B. Philips1 Philip Laird3 lsterling Federal Systems 2Spac~7ede~~~~~~~~~c~~~~~titute 3AI Research Branch NASA Ames Research Center . NASA Ames Research Center Mail Stop: 244-17 Baltimore, MD 21218 Mail Stop: 244-17 MofFett Field, CA 94035 Abstract This paper describes a simple heuristic method for solving large-scale constraint satisfaction and scheduling problems. Given an initial assignment for the variables in a problem, the method oper- ates by searching though the space of possible re- pairs. The search is guided by an ordering heuris- tic, the min-conflicts heuristic, that attempts to minimize the number of constraint violations af- ter each step. We demonstrate empirically that the method performs orders of magnitude better than traditional backtracking techniques on cer- tain standard problems. For example, the one mil- lion queens problem can be solved rapidly using our approach. We also describe practical schedul- ing applications where the method has been suc- . cessfully applied. A theoretical analysis is pre- sented to explain why the method works so well on certain types of problems and to predict when it is likely to be most effective. Introduction One of the most promising general approaches for solv- ing combinatorial search problems is to generate an initial, suboptimal solution and then to apply local repair heuristics. Techniques based on this approach have met with empirical success on many problems, in- cluding the traveling salesman and graph partitioning problems[ll]. Such techniques also have a long tradi- tion in AI, most notably in problem-solving systems that operate by debugging initial solutions [20,22]. This idea can be extended to constraint satisfication problems in a straightforward manner. Our method takes an initial, inconsistent assignment for the vari- ables in a constraint satisfaction problem (CSP) and incrementally repairs constraint violations until a con- sistent assignment is achieved. The method is guided by a simple ordering heuristic for repairing constraint violations: select a variable that is currently participat- ing in a constraint violation, and choose a new value Moffett Field, CA 94035 that minimizes the number of outstanding constraint violat ions. The work described in this paper was inspired by a surprisingly effective neural network developed by Adorf and Johnston for scheduling the use of the Hub- ble Space Telescope[2,13]. Our heuristic CSP method was distilled from an analysis of the network, and has the virtue of being extremely simple. It can be implemented very efficiently within a symbolic CSP framework, and combined with various search strate- gies. This paper includes empirical studies showing that the method performs extremely well on some stan- dard problems, such as the n-queens problem, to the extent that the method can quickly find solutions to the one million queens problem. We also describe ini- tial work on large-scale scheduling applications which suggests that the method has important practical im- plications as well. The final contribution of this pa- per is a theoretical analysis that describes how various problem characteristics affect the performance of the method. Previous Work: The GDS Network By almost any measure, the Hubble Space Telescope scheduling problem is a complex task [24,19,12]. Be- tween ten thousand and thirty thousand astronomical observations per year must be scheduled, subject to a vast variety of constraints involving time-dependent orbital characteristics, power restrictions, priorities, movement of astronomical bodies, stray light sources, etc. Because the telescope is an extremely valuable resource with a limited lifetime, efficient scheduling is a critical concern. An initial scheduling system, de- veloped in FORTRAN using traditional programming methods, highlighted the difficulty of the problem; it was estimated that it would take over three weeks for the system to schedule one week of observations. A more successful constraint-based system was then de- veloped to augment the original system. At its heart is a neural network developed by Johnston and Adorf, the Guarded Discrete Stochastic (GDS) network, which MINTON ET AL. 17 From: AAAI-90 Proceedings. Copyright ©1990, AAAI (www.aaai.org). All rights reserved. searches for a schedule [2,13]. From a computational point of view, the network is interesting because Johnston and Adorf found that it performs well on a variety of tasks, in addition to the space telescope scheduling problem. For exam- ple, the network performs significantly better on the n- queens problem than previous heuristic methods. The n-queens problem requires placing n queens on an n x n chessboard so that no two queens share a row, col- umn or diagonal. The network has been used to solve problems of up to 1024 queens, whereas previous meth- ods discussed in the literature[21] encounter difficulties with problems that are ten times smaller. Later in this paper we describe how our analysis of the GDS network enabled us to build a simple heuristic algorithm that performs even better. The GDS network is a modified Hopfield network[9]. The most significant modification is that the main net- work is coupled asymmetrically to an auxiliary network of guard neuTons which restricts the configurations that the network can assume. This modification enables the network to rapidly find a solution for many prob- lems, even when the network is simulated on a serial machine. The disadvantage is that convergence to a stable configuration is no longer guaranteed. Thus, the network can fall into a local minimum involving a group of unstable states among which it will oscillate. In practice, however, if the network fails to converge after some number of neuron state transitions, it can simply be stopped and started over. ’ To illustrate the network architecture and updat- ing scheme, let us consider how the network is used to solve binary constraint satisfaction problems. A problem consists of n variables, Xr . . . Xn, with do- mains Dr . . . D,, and a set of binary constraints. Each constraint Ca(Xj, Xk) is a subset of Dj x Dk speci- fying incompatible values for a pair of variables.2 To solve a CSP using the network, each variable is rep- resented by a separate set of neurons, one neuron for each of the variable’s possible values. Each neuron is either “on” or “off”, and in a solution state, every vari- able will have exactly one of its corresponding neurons “on” , representing the value of that variable. Con- straints are represented by inhibitory (i.e., negatively weighted) connections between the neurons. To insure that every variable is assigned a value, there is a guard neuron for each set of neurons representing a variable; if no neuron in the set is on, the guard neuron will pro- vide an excitatory input that is large enough to turn ‘The emphasis in Johnston and Adorf’s work is to pro- duce a computational architecture that can efficiently solve CSP problems, as opposed to modeling cognitive or neural behavior. Our discussion necessarily ignores many aspects of Johnston and Adorf’s work, which is described in detail elsewhere[l3,2]. 2This paper on y 1 considers the task of finding a single solution, that is, finding an assignment for each of the vari- ables which satisfies the constraints. one on. (Due to the way the connection weights are set up, it is unlikely that the guard neuron will turn on more than one neuron.) The network is updated on each cycle by randomly picking a set of neurons that represents a variable, and flipping the state of the neu- ron in that set whose input is most inconsistent with its current output (if any). When all neurons’ states are consistent with their input, a solution is achieved. The Min-Conflicts Heuristic Why does the GDS network perform so much better than traditional backtracking methods on tasks such as the n-queens ? In addressing this question, we be- gan with a number of competing hypotheses (some of which were suggested by Adorf and Johnston[2]). For instance, one hypothesis was that the systematic na- ture of the search carried out by backtracking is the source of its problems, as compared to the stochastic nature of the search carried out by the network. Specif- ically, if solutions in the backtracking space are clus- tered together (with correspondingly high inter-cluster distances), then a completely randomized search of the space can be more effective than systematic backtrack- ing. However, although tasks such as n-queens are in fact solved more efficiently using randomized algo- rithms (such as Las Vegas algorithms [4]), our studies indicate that the performance of the GDS network is far too good to be explained by this hypothesis. As it turns out, the key to the network’s performance appears to be that when it chooses a neuron to update, it chooses the neuron whose state is most inconsistent with its input. Thus, from a constraint satisfaction perspective, the network will “deassign” a variable’s current value only if it is inconsistent with other vari- ables. Furthermore, when a new value is later assigned, the network will choose the value that minimizes the number of other variables that it is inconsistent with. This idea is captured by the following heuristic: Min-Conflicts heuristic: Given: A set of variables, a set of binary constraints, and an assignment specifying a value for each vari- able. Two variables co@ict if their values violate a constraint. Procedure; Select a variable that is in conflict, and as- sign it a value that minimizes the number of conflicts.3 (Break ties randomly.) We have found that the network’s behavior can be approximated by a symbolic system that uses the min- 31n general, the heuristic attempts to minimize the num- ber of other variables that will need to be repaired. For binary CSPs, this corresponds to minimizing the number of conflicting variables. For general CSPs, where a single constraint may involve several variables, the exact method of counting the number of variables that will need to be re- paired depends on the particular constraint. The space telescope scheduling problem is a general CSP, whereas most of the other tasks described in this paper are binary CSPS. 18 AUTOMATEDREASONING conflicts heuristic for hill-climbing. The hill-climbing system starts with an initial assignment generated in a preprocessing phase. At each choice point, the heuris- tic chooses a variable that is currently in conflict and reassigns its value, until a solution is found. The sys- tem thus searches the space of possible assignments, favoring assignments with fewer total conflicts. Of course, the hill-climbing system can become “stuck” in a local maximum, in the same way that the network may become “stuck” in a local minimum. In the next section we present empirical evidence to support our claim that the min-conflicts heuristic is responsible for the network’s effectiveness. One of the virtues of extracting the heuristic from the network is that the heuristic can be used with a variety of different search strategies in addition to hill- climbing. For example, we have found that informed backtracking can be an effective strategy when used in the following manner. Given an initial assignment gen- erated in a preprocessing phase (as described above), an informed backtracking program employs the min- conflicts heuristic to order the choice of variables and values to consider, as described in figure 1. Initially the variables are all on a list of VARS-LEFT, and as they are repaired, they are pushed onto a list of VARS- DONE. The program attempts to find a sequence of repairs, such that no variable is repaired more than once. If there is no way to repair a variable in VARS- LEFT without violating a previously repaired variable (a variable in VARS-DONE), the program backtracks. It should be clear that the informed backtracking al- gorithm is simply a basic backtracking algorithm aug- mented with the min-conflicts heuristic to order its choice of which variable and value to attend to. This il- lustrates an important point. The informed backtrack- ing program incrementally extends a consistent partial assignment (i.e., VARS-DONE), in the same manner as a basic backtracking program, but in addition, uses in- formation from the initial assignment (i.e., VARS-LEFT) to bias its search. The next section documents the de- gree to which this information is useful. Experimental Results This section has two purposes. First, we evaluate the performance of the min-conflicts heuristic on some standard tasks using a variety of search strategies. Sec- ond, we show that the heuristic, when used with a hill- climbing strategy, approximates the behavior of the GDS network. We have employed the following search strategies with the min-conflicts heuristic: 1. Hill-climbing: This strategy most closely replicates the behavior of the GDS network. The disadvantage is that a hill-climbing program can get caught in local maxima, in which case it will not terminate. 2. Informed backtracking: As described earlier, this strategy is a basic backtracking strategy, augmented Procedure INFORMED-BACKTRACK WARS-LEFT VARS-DONE) If all variables are consistent, then solution found, STOP. Let VAR = a variable in VARS-LEFT that is in conflict. Remove VAR from VARS-LEFT. Push VAR onto VARS-DONE. Let VALUES = list of possible values for VAR ordered in ascending order according to number of conflicts with variables in VARS-LEFT. For each VALUE in VALUES, until solution found: If VALUE does not conflict with any variable that is in VARS-DONE, then Assign VALUE to VAR. Call INFORMED-BACKTRACKCVARS-LEFT VARS-DONE) end if end for end procedure Begin program Let VARS-LEFT = list of all variables, each assigned an initial value. Let VARS-DONE = nil Call INFORMED-BACKTRACKWARS-LEFT VARS-DONE) End program Figure 1: Informed Backtracking Using the Min- Conflicts Heuristic 3. with the min-conflicts heuristic for ordering the as- signment of variables and values. Because the min- conflicts heuristic repairs the initial assignment, it can also be viewed as backtracking in the space of possible repairs. One advantage of this strategy is that it is complete-if there is a solution, it will even- tually be found; if not, failure will be reported. Un- fortunately, this is of limited significance for large- scale problems because terminating in a failure can take a very long time. A second advantage is that the strategy can be augmented with pruning heuris- tics which cut off unpromising branches. This can be very useful, as documented in the next section. Best-first search: This strategy keeps track of multi- ple assignments (each corresponding to a leaf in the search tree). On each cycle it picks the assignment with the fewest constraint violations and considers the set of repairs that can be applied to that as- signment. We have found that best-first search (of which A* is one variation) is generally expensive to employ on large-scale problems due to the cost of maintaining multiple assignments. The N-Queens Problem The n-queens problem, originally posed in the 19th century, has become a standard benchmark for test- ing backtracking and CSP algorithms. In a sense, the problem of finding a single solution was “solved” in the 1950’s by the discovery of a pair of patterns that can MINTON ET AL. 19 Strategy n=lO1 n = lo2 n=103 n=104 n=105 n= lo6 Basic Backtracki 53.8 4473 (70%) 88650(13%) * * * Most Constrained Backtrackt 17.4 687 (96%) 22150 (81%) * * * MinConflicts Hi-Climbingx 57.0 55.6 48.8 48.5 52.8 48.3 MinConflicts Backtrack t: 46.8 25.0 30.7 27.5 27.8 26.4 i = number of backtracks, $ = number of repairs * = exceeded computational resources (100 runs required > 12 hours on a SPARCstationl) Table 1: Number of Backtracks/Repairs for N-Queens Algorithms be instantiated in linear time to yield a solution[l]. Nevertheless, the problem has remained relatively “hard” for heuristic search methods. Several stud- ies of the n-queens problem [21,8,14] have compared heuristic backtracking methods such as search rear- rangement backtracking (e.g., most-constrained first), forward checking, dependency-directed backtracking, etc. However, no previously identified heuristic search method has been able to consistently solve problems involving hundreds of queens within a reasonable time limit. On the n-queens ,problem, Adorf and Johnston [2] reported that the probability of the GDS network con- verging increases with the size of the problem. For large problems, e.g., n > 100 (where n is the num- ber of queens), the network almost certainly converges. Moreover, the median number of cycles required for convergence is only about 1.167~. Since it takes O(n) time to execute a transition (i.e., picking a neuron and updating its connections), the expected time to solve a problem is (empirically) approximately O(n2). The network has been used to solve problems with as many as 1024 queens, which takes approximately 11 minutes in Lisp on a TI Explorer II. For larger problems, mem- ory becomes a limiting factor because the the network requires approximately O(n2) space. (Although the number of non-zero connections is O(n3), some connec- tions are computed dynamically rather than stored). To compare the network with our min-conflicts ap- proach, we constructed a hill-climbing program that operates as follows. An initial assignment is created in a preprocessing phase using a greedy algorithm that iterates through the rows, placing each queen on the column where it conflicts with the fewest previously placed queens (breaking ties randomly). In the sub- sequent repair phase, the program keeps repairing the assignment until a solution is found. To make a re- pair, the program selects a queen that is in conflict and moves it to a different column in the same row where it conflicts with the fewest other queens (breaking ties randomly). Interestingly, we found that this program performs significantly better than the network. For n 2 100 the program has never failed to find a solution. Moreover, the required number of repairs appears to remain constant as n increases. After further analysis, however, we found the hill-climbing program performs 20 AUTOMATED REASONING better than the network because the hill-climbing pro- gram’s preprocessing phase invariably produces an ini- tial assignment that is “close” to a solution, in that the number of conflicting queens in the initial assign- ment grows extremely slowly (from a mean of 3.1 for n = 10 to a mean of 12.8 for n = 10”). Once this dif- ference was eliminated, by starting the network in an initial state produced by our preprocessing algorithm, the network and the hill-climbing program performed quite similarly. We note, however, that the network requires O(n2) space, as compared to the O(n) space required by the hill-climbing program, which prevented us from running very large problems on the network. Table 1 compares the efficiency of our hill-climbing program and several backtracking programs. Each pro- gram was run 100 times for n increasing from 10 to one million. Each entry in the table shows the mean number of queens moved, where each move is either a backtrack or a repair, depending on the program. A bound of n x 100 queen movements was employed so that the experiments could be conducted in a rea- sonable amount of time; If the program did not find a solution after moving n x 100 queens, it was terminated and credited with n x 100 queen movements. For the cases when this occurred, the corresponding table en- try indicates in parentheses the percentage of times the program completed successfully. The first row shows the results for a basic backtracking program. For n 2 1000, the program was completely swamped. The second row in the table shows the results for informed backtracking using the “most-constrained first” heuris- tic. This program is a basic backtracking program that selects the row that is most constrained when choosing the next row on which to place a queen. In an empirical study of the n-queens problem, Stone and Stone [21] found that this was by far the most powerful heuris- tic for the n-queens problem out of several described earlier by Bitner and Reingold[3]. The program ex- hibited highly variable behavior. At n = 1000, the program found a solution on only 81% of the runs, but three-quarters of these successful runs required fewer than 100 backtracks. Unfortunately, for n > 1000, one hundred runs of the program required considerably more than 12 hours on a SPARCstationl, both because the mean number of backtracks grows rapidly and be- cause the “most-constrained first” heuristic takes O(n) Problem Size Figure 2: Mean Solution Time for Hill-Climbing Pro gram on N-Queens Problem time to select the next row after each backtrack. Thus we were prevented from generating sufficient data for n > 1000. The next row in the table shows the re- sults for hill-climbing using the min-conflicts heuris- tic. As discussed above, this algorithm performed ex- tremely well, requiring only about 50 repairs regardless of problem size. The final row shows the results for an informed backtracking program that used the min- conflicts heuristic as described in the previous section. We augmented this program with a pruning heuristic that would initiate backtracking when the number of constraint violations along a path began to increase sig- nificantly. However, for n > 100, this program never backtracked (i.e., no queen had to be repaired more than once). The results are better than those for the hill-climbing program (although there is little room for improvement) primarily because the hill-climbing pro- gram tends to repair the same queen again and again. We note that for the two programs using the min- conflicts heuristic, each repair requires O(n) time in the worst case. However, this is a relatively minor price to pay. Since the number of repairs remains ap- proximately constant as n grows, the average runtime of the program is approximately linear. This is illus- trated by figure 2, which shows the average runtime for the hill-climbing program. In terms of realtime perfor- mance, this program solves the million queens problem in less than four minutes on a SPARCstationl. (The algorithm can also be optimized for large problems, in which case the solution time is less than a minute and a half.) source constraints, preferences, etc. The space tele- scope scheduling problem, as discussed earlier, is a complex problem on which traditional backtracking and operations research techniques perform poorly. The problem can be considered a constraint optimiza- tion problem where we must maximize both the num- ber and the importance of the constraints that are sat- isfied. In practice, the GDS network has performed quite well using a relatively simple approach. The network, in effect, attempts to satisfy as many “im- portant” constraints as possible; less “important” con- straints, or preferences, are used to break ties during the update procedure. Naturally, a similar approach can be used with the min-conflicts heuristic. As usual, we minimize the number of conflicts, but rather than breaking ties randomly, the preference constraints are used to break ties. (Due to space limitations, we only report our main results here. See [18] for a more in- depth discussion of this application.) The min-conflicts heuristic under hill-climbing has been shown to be at least as effective as the GDS network on representative data sets provided by the Space Telescope Sciences Institute. Moreover, because the min-conflicts heuristic is so simple, the scheduling program was easy to code and is extremely efficient.4 While this may be regarded as just an implementation issue, we believe that the clear and simple formulation of the method was a significant enabling factor. We are currently experimenting with a variety of differ- ent search strategies that can be combined with the min-conflicts heuristic. Although this study is not yet complete, we expect that the improvements in speed we have observed will eventually translate into better schedules, since the search process can explore a larger number of acceptable schedules. The min-conflicts method has also been tested on data on the Space Shuttle Payload Scheduling prob- lem, another complex, real-world scheduling problem. Preliminary results show that the method performs far better than a backtracking CSP program that was pre- viously built for this task[26]. Additional corrobora- tion comes from a parallel study by Zweben[25], who has investigated a related method for repairing sched- ules using simulated annealing. In general, it appears that repair-based methods fare quite well on this prob- lem. An additional bonus, as Zweben has pointed out, is that repair-based methods can also be used for dy- namic rescheduling. In many domains this capability is important because unexpected events may require frequent schedule revision. Other Applications The min-conflicts and/or GDS network have also been tried on a variety of other problems with good (but Scheduling Applications A scheduling problem involves placing a set of tasks on a time line, subject to temporal constraints, re- 4The scheduling program runs at least an order of mag- nitude faster than the network, although some of the im- provement is due to factors such as programming language differences. This makes a precise comparison difficult. MINTONETAL. 21 preliminary) results, including the randomly generated problems described by Dechter and Pearl [6,2] and con- junctive precondition matching problems[l7]. We are currently cataloging the types of applications for which our method works well. We have also compared the performance of the GDS network and the mm-conflicts heuristic on graph 3- colorability, a well-studied NP-complete problem. In this problem, we are given an undirected graph‘with n vertices. Each vertex must be assigned one of three col- ors subject to the constraint that no neighboring ver- tices be assigned the same color. Adorf and Johnston found that the performance of the network depended greatly on the connectivity of the graph. On sparsely connected graphs (with average vertex degree 4) the network performed poorly, becoming caught in local minima with high probability. On densely connected graphs the network converged rapidly to a solution. We have repeated Adorf and Johnston’s experiments with our hill-climbing program, and found similar re- sults. We have also experimented with variations of informed backtracking using the min-conflicts heuris- tic. Our most effective program is an informed back- tracking program that records the assignment with the least conflicts found so far. When the number of back- tracks exceeds a (dynamically adjusted) threshold, the search process is restarted using this best assignment. We have found that performance is further improved by adding heuristics for selecting which vertex to re- pair, and that, as in the n-queens problem, it helps to have a good initial assignment, which can also be pro- duced using additional heuristics. This illustrates the well-known principle that combining multiple heuris- tics can improve performance significantly. In this domain, certain heuristic methods are known to produce excellent results. For instance, Brelaz’s k- colorability algorithm [5] employs two strong heuristics (forms of “most-constrained first”) and it outperforms our informed backtracking algorithm. Turner [23] has shown that this algorithm will optimally color “almost all” random k-colorable graphs without backtracking, so its dominance is not surprising. Summary of Experimental Results For all of the tasks discussed in the previous section, we have found that the behavior of the GDS network can be approximated by hill-climbing with the min- conflicts heuristic. To this extent, we have a theory that explains the network’s behavior. Obviously, there are certain practical advantages to having “extracted” the heuristic from the network. First, the heuristic is very simple, and so can be programmed extremely ef- ficiently, especially if done in a task-specific manner. Second, the heuristic can then be used in combina tion with different search strategies and task-specific heuristics. This is a significant factor for most practi- cal applications. Insofar as the power of the heuristic is concerned, our experimental results are encouraging. On the n-queens problem the min-conflicts heuristic clearly outperforms heuristics that have previously been investigated. Fur- thermore, the heuristic has already been applied suc- cessfully to real-world scheduling problems. We have also considered variations of the min- conflicts heuristic, such as repairing the variable that participates in the most conflicts first. In general, we have found that minor variations of the heuristic do not affect performance significantly, as long as the heuris- tic tends to decrease the number of variables that are inconsistent. Analysis The previous section showed that the min-conflicts heuristic is extremely effective on some tasks, such as placing queens on a chessboard, and less effective on other tasks, such as coloring sparsely connected graphs. In this section, we analyze how the parameters of a task influence the effectiveness of the heuristic. Con- sider a CSP with n variables, where each variable has Ic possible values. We restrict our consideration to a sim- plified model where every variable is subject to exactly c binary constraints, and we assume that there is only a single solution to the problem, that is, exactly one satisfying assignment. We address the following ques- tion: What is the probability that the mm-conflicts heuristic will make a mistake when it assigns a value to a variable that is in conflict? We define a mistake as choosing a value that will have to be changed again before the solution is found. We note that for our in- formed backtracking program, a mistake of this sort early in the problem-solving process may prove fatal, as it may require an exponential amount of search to recover from its mistake. For any assignment of values to the variables, there will be a set of d variables whose values will have to be changed to convert the assignment into the solu- tion. We can regard d as a measure of distance to the solution. The key to our analysis is the following ob- servation. Given a variable V to be repaired, only one of its I% possible values will be good5 and the other Ic - 1 values will be bad (i.e., mistakes). Whereas the good value may conflict with at most d other variables in the assignment, a bad value may conflict with as many as c other variables. Thus, as d shrinks, the min-conflicts heuristic should be less likely to make a mistake when it repairs V. In fact, if each of the k - 1 bad values has more than d conflicts, then the min-conflicts heuristic cannot make a mistake - it will select the good value when it repairs this variable, since the good value will have fewer conflicts than any bad value. 22 AUTOMATEDREASONING We can use this idea to bound the probability of making a mistake when variable V is repaired. Let V’ be a variable related to V by a constraint. We assume that a bad value for V conflicts with V’ with probability p, independent of the variables V and V’. Let Nb be a random variable representing the number of conflicts for an arbitrary one of the lo - 1 bad values for V. Thus, the expected value for Nb is pc. Since we are interested in the behavior of the min-conflicts heuristic as d shrinks, let us suppose that d is less than pc. Then, to bound the probability that A$, is less than d, we can use Hoeffding’s inequality, which states that after c trials, the probability that a random variable is SC less than the mean is bounded by e-2szc. With s = (pc - d)/c, th e relative distance between pc and d, we obtain: PT(A$, < d) 5 e-2(~c--d)2~c To account for the fact that a mistake can occur if any of the L - 1 bad values has d or fewer conflicts, we bound the probability of making a mistake on any of them by multiplying by k: - 1: Pr(mistake) 5 (k - l)e-2(pc-d)zlc Note that as c (the number of constraints per vari- able) becomes large, the probability of a mistake ap- proaches zero, if all other parameters remain fixed. This analysis thus offers an explanation as to why 3- coloring densely connected graphs is relatively easy. We also see that as d becomes small, a mistake is also less likely, explaining our empirical observation that having a “good” initial assignment is important. Ad- ditionally, we note that as p increases or k: decreases, the probability of a mistake also shrinks. The analysis makes several simplifying assumptions, including the assumption that only a single solution ex- ists. In the n-queens problem, it appears that the num- ber of possible solutions grows rapidly with n [21]. To explain the excellent performance of the min-conflicts heuristic on the n-queens problem, it seems necessary to take this additional fact into account; we note that for n-queens the bounds derived above are relatively weak. (In n-queens, each row is represented by a vari- able, so that c = n, and p x 2.5/n, since any two rows constrain each other along a column and either one or two diagonals. Therefore, pc remains approximately constant as n grows.) iscussion The heuristic method described in this paper can be characterized as a lo& search method[ll], in that each repair minimizes the number of conflicts for an indi- vidual variable. Local search methods have been ap- plied to a variety of important problems, often with impressive results. For example, the Kernighan-Lin method, perhaps the most successful algorithm for solving graph-partitioning problems, repeatedly im- proves a partitioning by swapping the two vertices that yield the greatest cost differential. The much- publicized simulated annealing method can also be characterized as a form of local search[lO]. However, it is well-known that the effectiveness of local search methods depends greatly on the particular task. We are currently comparing the algorithm’s performance with alternative techniques on a variety of tasks. There is also a long history of AI programs that use repair or debugging strategies to solve problems, primarily in the areas of planning and design[22,20]. These programs have generally been quite successful, although the repair strategies they employ may be do- main specific. In comparison, the m&conflicts heuris- tic is a completely general, domain-independent ap- proach. Of course, any domain-independent heuristic is likely to fail in certain cases, precisely because of its lack of domain-specific expertise. In fact, it is easy to imagine problems on which the min-conflicts heuristic will fail. The heuristic is poorly suited to problems with a few highly critical constraints and a large number of less important constraints. For example, consider the problem of constructing a four- year course schedule for a university student. We may have an initial schedule which satisfies almost all of the constraints, except that a course scheduled for the first year is not actually offered that year. If this course is a prerequisite for subsequent courses, then many sig- nificant changes to the schedule may be required be- fore it is fixed. In general, if repairing a constraint violation requires completely revising the current as- signment, then the min-conflicts heuristic will offer lit- tle guidance. This intuition is partially captured by the analysis presented in the previous section, which shows how the effectiveness of the heuristic is inversely related to the distance to a solution. The problems investigated in this paper, especially the n-queens problem, tend to be relatively uniform, in that the likelihood of such critical constraints exist- ing is low. In the space telescope scheduling problem, constraint preprocessing techniques[l6] are applied to reduce the likelihood that any particular constraint will be highly critical. For example, by taking the transi- tive closure of temporal constraints (e.g. the “after” relation) and representing each inferred constraint ex- plicitly, critical constraints can be transformed into sets of constraints. This works well because the min-conflicts heuristic will be less likely to violate a set of constraints than a single constraint. In some cases, we expect that more sophisticated techniques will be necessary to identify critical constraints[7]. To this end, we are currently evaluating abstraction and explanation-based learning techniques that have worked well for planning systems[l5,17]. Conclusions This paper has two primary contributions. First, we have analyzed a very successful neural network algo- rithm and shown that an extremely simple heuristic MINTONETAL. 23 is responsible for its effectiveness. Second, we have demonstrated that this heuristic can be incorporated into symbolic CSP programs with excellent results. Acknowledgements The authors wish to thank Hans-Martin Adorf, Richard Franier, and Don Rosenthal for their assis- tance on this research project, and Peter Cheese- man, Monte Zweben, John Bresina, Megan Eskey, Mark Drummond, Eric Raymond, Oren Etzioni, Craig Knoblock and Bernadette Kowalski for their comments and advice, and for their company during late-night dinners. The Space Telescope Science Institute is op- erated by the Association of Universities for Research in Astronomy for NASA. PI PI PI PI El PI PI PI PI PO1 PI References B. Abramson and M. Yung. Divide and con- quer under global constraints: a solution to the n-queens problem. Journal of Parallel and Dis- tributed Computing, 61:649-662, 1989. H.M. Adorf and M.D. Johnston. A discrete stochastic neural network algorithm for constraint satisfaction problems. In Proceedings of the In- ternational Joint Conference on Neural Networks, San Diego, CA, 1990. J. Bitner and E.M. Reingold. Backtrack program- ming techniques. Communications of the ACM, l&651-655, 1975. G. Brassard and P. Bratley. Algorithmics - Theory and Practice. Prentice Hall, Englewood Cliffs, NJ, 1988. D. Brelaz. Almost all k-colorable graphs are easy to color. Journal of Algorithms, 9:63-82, 1988. R. Dechter and J. Pearl. Network-based heuristics for constraint satisfaction problems. Artificiak In- telligence, 34:1-38, 1988. M.S. Fox, N. Sadeh, and C. Baykan. Constrained heuristic search. In Proceedings IJCAI-89, De- troit, MI, 1989. R.M. Haralick and G.L. Elliot. Increasing tree search efficiency for constraint satisfaction prob- lems. Artificial Intelligence, 14:263-313, 1980. J.J. Hopfield. Neural networks and physical sys- tems with emergent collective computational abil- ities. In Proceedings of the National Academy of Sciences, 1982. D.S. Johnson, C.R. Aragon, L.A. McGeoch, and C. Schevon. Optimization by simulated annealing: an experimental evaluation, Part II. To appear in Journal of Operations Research, 1990. D.S. Johnson, C.H. Papadimitrou, and M. Yan- nakakis. How easy is local search? Journ& of Computer and System Sciences, 37:79-100, 1988. WI WI [14 [151 WI El71 WI WI PO1 Pll P21 WI PI P51 P61 M.D. Johnston. Automated telescope scheduling. In Proceedings of the Symposium on Coordination of Observational Projects, Cambridge University Press, 1987. M.D. Johnston and H.M. Adorf. Learning in stochastic neural networks for constraint satisfac- tion problems. In Proceedings of NASA Confer- ence on Space Telerobotics, Pasadena, CA, Jan- uary 1989. N. Keng and D.Y.Y. Yun. A planning/scheduling methodology for the constrained resource prob- lem. In Proceedings IJCAI-89, Detroit, MI, 1989. C.A. Knoblock. Learning hierarchies of abstrac- tion spaces. In Proceedings of the Sixth Interna- tional Conference on Machine Learning, Ithica, N.Y., 1989. A.K. Mackworth. Consistency in networks of re- lations. Artificial Intelligence, 8:98-118, 1977. S. Minton. Empirical results concerning the util- ity of explanation-based learning. In Proceedings AAAI-88, Minneapolis, MN, 1988. S. Minton, A.B. Philips, M. Johnston, and P. Laird. The Min- Conflicts Heuristic: Experimental and Theoretical Results. Technical Report forth- coming, NASA Ames Artificial Intelligence Re- search Branch, 1990. N. Muscettola, S.F. Smith, G. Amiri, and D. Pathak. Generating Space Telescope Observation Schedules. Technical Report CMU-RI-TR-89-28, Carnegie Mellon University, Robotics Institute, 1989. R.G. Simmons. A theory of debugging plans and interpretations. In Proceedings AAAI-88, Min- neapolis, MN, 1988. H.S. Stone and J.M. Stone. Efficient search tech- niques - an empirical study of the n-queens prob- lem. IBM Journal of Research and Development, 31:464474, 1987. G. J. Sussman. A Computer Model of Skill Acqui- sition. American Elsevier, New York, 1975. J.S. Turner. New methods to color the vertices of a graph. Communications of the ACM, 22:251- 256, 1979. M. Waldrop. Will the Hubble space telescope com- pute? Science, 243:1437-1439, 1989. M. Zweben. A Framework for Iterative Improve- ment Search Algorithms Suited for Constraint Sat- isfaction Problems. Technical Report RIA-90-05- 03-1, NASA Ames Research Center, AI Research Branch, 1990. M. Zweben and M. Eskey. Constraint satisfaction with delayed evaluation. In Proceedings IJCAI-89, Detroit, MI, 1989. 24 AUTOMATED REASONING
|
1990
|
8
|
Subsets and Splits
SQL Console for Seed42Lab/AI-paper-crawl
Finds papers discussing interpretability and explainability in machine learning from after 2010, offering insight into emerging areas of research focus.
Interpretability Papers Since 2011
Reveals papers from the AAAI dataset after 2010 that discuss interpretability or explainability, highlighting key research in these areas.
SQL Console for Seed42Lab/AI-paper-crawl
Searches for papers related to interpretability and explainability in NIPS proceedings after 2010, providing a filtered dataset for further analysis of research trends.
AI Papers on Interpretability
Finds papers discussing interpretability or explainability published after 2010, providing insight into recent trends in research focus.
ICML Papers on Interpretability
Retrieves papers from the ICML dataset after 2010 that mention interpretability or explainability, offering insights into trends in model transparency research.
ICLR Papers on Interpretability
Retrieves papers from the ICLR dataset that discuss interpretability or explainability, focusing on those published after 2010, providing insights into evolving research trends in these areas.
ICCV Papers on Interpretability
Finds papers from the ICCV dataset published after 2010 that discuss interpretability or explainability, providing insight into trends in research focus.
EMNLP Papers on Interpretability
Retrieves papers related to interpretability and explainability published after 2010, providing a focused look at research trends in these areas.
ECCV Papers on Interpretability
The query retrieves papers from the ECCV dataset related to interpretability and explainability published after 2010, providing insights into recent trends in these research areas.
CVPR Papers on Interpretability
Retrieves papers from the CVPR dataset published after 2010 that mention 'interpretability' or 'explainability', providing insights into the focus on these topics over time.
AI Papers on Interpretability
Retrieves papers from the ACL dataset that discuss interpretability or explainability, providing insights into research focus in these areas.