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 |
|---|---|---|---|
1,200 | An Improved Incremental Al Prime Implicates Johan de Kleer Xerox Palo Alto Research Center 3333 Coyote Hill Road, Palo Alto CA 94304 USA email: dekleer@parc.xerox.com Abstract Prime implicates have become a widely used tool in AI. The prime implicates of a set of clauses can be computed by repeatedly resolving pairs of clauses, adding the resulting resolvents to the set and removing subsumed clauses. Unfortunately, this brute-force approach performs far more res- olution steps than necessary. Tison provided a method to avoid many of the resolution steps and Kean and Tsiknis developed an optimized incre- ment al version. Unfortunately, both these algo- rithms focus only on reducing the number of reso- lution steps required to compute the prime impli- cates. The actual running time of the algorithms depends critically on the number and expense of the subsumption checks they require. This paper describes a method based on a simplification of Kean and Tsiknis’ algorithm using an entirely dif- ferent data structure to represent the data base of clauses. The new algorithm uses a form of dis- crimination net called tries to represent the clausal data base which produces an improvement in run- ning time on all known examples with a dramatic improvement in running time on larger examples. 1 Introduction Prime implicates have become a widely used tool in AI. They can be used to implement ATMSs [9], to charac- terize diagnoses [2], to compile formulas for TMSs [3], to implement circumscription [5; 81, to give but a few examples. The prime implicates of a set of clauses can be computed by repeatedly resolving pairs of clauses, adding the resulting resolvents to the set and remov- ing subsumed clauses. Unfortunately, this brute-force approach performs far more resolution steps than nec- essary. Tison [lo] provided a method to avoid many of the resolution steps and Kean and Tsiknis [B] give an optimized incremental version. Both algorithms pro- vide a significant advance as they substantially reduce the number of resolution steps required to compute the prime implicates of a set of clauses. Unfortunately, both algorithms focus only on reduc- ing the number of resolution steps required to com- pute the prime implicates. The actual running time of the algorithm also depends critically on the number 780 Representation and Reasoning: Tractability and expense of the subsumption checks they requires. Reducing the number of resolutions certainly reduces the number of subsumption checks required. However, the number of subsumption checks required grows (see analysis in Section 3.2 and data in Section 4) faster than the square of the final number of prime impli- cates. As a result both algorithms are impractical on all but the tiniest examples. Neither algorithm [6; lo] indicates how subsumption is to be performed, and any prime implicate algorithm is incomplete without such a specification. This paper proposes a method based on a simplification of Kean and Tsiknis’ algorithms using an entirely different data structure to represent the data base of clauses in order to facilitate subsumption checking. This data struc- ture is called trie [7] which has been explored exten- sively for representing dictionaries of words. (Tries are also used in ATMS implementations [l] to store the nogood data base.) Using tries to represent the data base dramatically improves the performance of prime implicate algorithms. The data in Section 4 shows that we can now construct the prime implicates for a much larger set of tasks. Admittedly, no amount of algorithmic improvement can avoid the complexity produced by the sheer num- ber of prime implicates. The number of prime impli- cates for many tasks grows relatively quickly so the ap- proach is impractical for many applications. However, we can now conceive of computing prime implicates for applications impossible to before. 2 A brute-force algorithm The key step in computing prime implicates consists of a resolution rule called consensus[6; 9; lo]. Given two clauses: ‘XW, where x is a symbol and ,0 and y are (possibly empty) disjunctions of literals, the consensus of these two clauses with respect to x is the clause, WY, with duplicate literals removed. If the two clauses have more than one pair of complementary literals, then the consensus would contain complementary literals and is From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. discarded (since it is a logical tautology). The prime implicates of a set of clauses can be computed by re- peatedly adding the consensus of any pair of clauses to the set and continually removing all subsumed clauses (until no further consensus and subsumption is possi- ble). The following algorithm finds the prime implicates of a set of clauses &: ALGORITHM BRUTE-FORCE(&) 1. Let P (the result) be {}. 2. Take the first clause q off of &. If none we are done. 3. If q is subsumed by any clause of P, then go back to step 2. 4. 5. 6. 7. 3 Remove all clauses of P which are subsumed by q. Try to compute the consensus of q and every clause in P. Whenever the consensus exists, add it to &. Add q to P. Go to step 2. Improving efficiency The algorithm presented in Section 2 is intuitively ap- pealing but quite inefficient in practice. Construct- ing prime implicates is known to be NP-complete and therefore it is unlikely any really good algorithm ex- ists. Nevertheless we can do dramatically better than the algorithm of Section 2. Through logical analysis we can eliminate a large number of the redundant consen- sus calculations. We can redesign the data structures to support addition and deletion of clauses relatively efficiently. 3.1 A more efficient eon~en~u~ algorithm When one observes the behavior of BRUTE- FORCE, almost all the clauses produced by the con- sensus calculation are subsumed by others. One reason for this is somewhat obvious: the consensus operation is commutative and associative when the consensi all exist (usually the case). For example, if we have three clauses a, /3 and y, consensus(a,consensus(p,Y)) = consensus(consensus(cr , p>, y)). For 3 clauses BRUTE-FORCE finds the same result in 3 distinct ways. Unfortunately, the number of ways to derive a result grows exponentially in the number of clauses used to produce the final result. Tison [6; 101 introduced the following key intuition which suppresses the majority of the consensus calcu- lations. To compute the prime implicates of a set of clauses, place an ordering on the symbols, then iterate over these symbols in order, doing all consensus calcu- lations with respect to that symbol only. Once all the consensus calculations for a symbol have been made it is never necessary to do another consensus calcula- tion with respect to that symbol even for all the new AvB Figure 1: Tison’s Method 1 BVC 1 CVD AVD AvD dtmsxison consensus results which are produced later (of course, when the user incrementally supplies the next clause the symbols must be reconsidered). Figure 1 provides a simple example. Suppose we are given clauses A V B, 43 V C and +Z’ V D. The symbols are ordered: A, B and C. There are no consensus calculations available for A. There is only one (at 1 in the figure) consen- sus calculation available for B (on the first and second clauses). Finally, when processing C there are two (at 2 and 3 in the figure) consensus calculations available. One of those consensus calculations produces 1B V D. Although this resolves with the first original clause, Tison’s method tells us the result will be irrelevant be- cause all the useful consensus calculations with respect to B have already been made. The following algorithm incorporates this ideas. The algorithm U?IA (this derives from the incremental Ti- son method presented a current set of prime clauses to add. - and proved correct in [6]) takes implicates N and a set S of new ALGORITHM IPIA(N,S) 1. Delete any D E N U S that is subsumed by another D’ E N u S. 2. Remove a smallest C clause from S. If none, return. 3. For each literal 1 of C, construct l& which contains all clauses of N which resolve successfully with 6. 4. Let C be the set containing C. 5. Perform the following steps for each literal I of C. (a) For each clause in C which is still in N compute the consensus of it and every clause in l& which is still in N. (b) For every new consensus, discard it if it has been subsumed by N U S. Otherwise, remove any clauses in N US subsumed by it. Add the clause to N and C. algorithm to the previous one we see consensus computations are avoided: Comparing this that a great many cle Kleer 781 l Consensus calculations with respect to a literal ear- lier in the order are ignored. o Two clauses produced in the same main step (choice of C) are never resolved with each other. l Consensus calculations with a D in the original N are ignored unless the consensus of D and C exists. 3.2 Implementing subsumption checking efficiently Thus far we have been analyzing the logic of the prime implicate algorithms in order to improve their effi- ciency. However, all the algorithms we know of depend critically on subsumption checking and unless that is properly implemented all the CPU time will be spent checking subsumption. A key observation is that we are maintaining a data base of unsubsumed clauses. We need to implement 3 transactions with this data base. 1. Check whether clause x is subsumed by some clause of the data base. 2. Add clause x to the data base. 3. Remove all clauses from the data base which are subsumed by x. To understand some of the complexities, consider the most obvious implementation: We could implement the subsumption check by a subset test and maintain the data base as a simple list. Using lists makes check- ing for subsumption of order the number of clauses, and thus the complexity of generating k prime impli- cates at least k2 which is unacceptable. Our implementation is based on an integration of two ideas. First, each clause is always represented in a canonical form. Second, the clause data base is repre- sented as a discrimination tree. To achieve a canonical form for clauses we assign a unique integer id to each symbol. We order the literals of every clause in as- cending order of their ids. (Complementary literals have the same id, but they can never appear in the same clause as this would produce a tautology.) This means that two sets of literals refer to the same clause if their ordered lists of literals are identical. For exam- ple, given symbols A, B and C with id’s 1, 2 and 3, the clause, AvBvC is represented by the list, [A, B, Cl. The representation of clauses is sensitive on the choice of id’s. If the id’s were 3, 1, 2 respectively, then the clause would be represented by the list, [B&A]. This also makes it possible to test whether a clause of length n subsumes a clause of length m in at most n + m comparisons. However, our algorithm never Figure 2: Data base with 3 clauses. AVBVC AVD dbl‘lS.lWAd BvD checks whether one clause subsumes another. Instead, our algorithm stores the canonical forms of clauses in a discrimination tree (or trie [7]). By storing canoni- cal forms in a trie and a single clause can be checked against all existing clauses in a single operation. The trie for clauses is relatively simple. Conceptu- ally, it is a tree, all of whose edges are literals and whose leaves are clauses. The edges below each node in the trie are ordered by the id of the literal. Suppose that A, B, C, D and E are a sequence of nodes with ascending id’s and the data base contains the three clauses: AvBvC, B v D, AVD. The resulting tree is illustrated in Figure 2. Because clauses are canonically ordered, our tries have the ad- ditional important property that the id of any edge is less than the id of any edge appearing below it at any depth. This property is heavily exploited in the update algorithms which follow. The most commonly called procedure checks whether a clause is subsumed by one in the data base. Given an ordered set of literals, the recursive function SUBSUMED? checks whether the set of literals L is subsumed by trie N. The ordered literals are repre- sented as an ordered list, and the trie by an ordered list of edges. ALGORITHM SUBSUMED?(L, N) 1. 2. 3. 4. If N is a terminal clause, return success. Remove literals from the front of L until the id of the first edge of N is greater than that of the first literal of L. If no literals remain (L is empty), return failure. For each literal I of L do the following until success or the id of the first edge of N is no longer greater than that of I. 782 Representation and Reasoning: Tractability (a) If the first literal of N is I, recursively invoke SUBSUMED? on the remaining literals and the edges below the first element of N. (b) If the recursive call returns success, return suc- cess. 5. Remove the first element of N. 6. Go to Step 2. Suppose we want to check whether D V E is sub- sumed by the data base of Figure 2. The root of the trie has 2 outgoing edges, A and B. D has a larger id than the top two edges of the trie (A and B), therefore SUBSUMED? immediately reports failure. Suppose we want to check whether A V B V D is subsumed by the trie. The first edge from the root matches the first literal, so the recursive call tries to determine whether the remaining subclause B V D is subsumed by the trie rooted from the edge below A. Again B matches, but D does not match C so the two recursive calls to SUBSUMED? fail. Finally, the top-level invo- cation of SUBSUMED? again recursively calls itself and finds a successful match. Adding a clause to the data base is very simple. Our algorithm exploits the fact that the clause to be added is not itself subsumed by some other clause, and that any clause it subsumes has been removed from the data base. ALGORITHM ADD-TO-TRIE(L, N) 1. 2. 3. Remove edges of the front of N, until the id of the first edge of N is greater or equal to the first literal of L. If the label of the first edge of N is the same as that of L, recursively call ADD-TO-TRIE with the remainder of L, the edges underneath the first edge of N and return. Construct the edges to represent the literals of L and return, and side-effect the trie such that it appears just before the current position N. The potentially most expensive operation and the one which requires the greatest care is the third basic update on the trie. Here we are given a clause, not subsumed by the trie and we must remove from the trie all clauses subsumed by it. ALGORITHM REMOVE-SUBSUMED(L, N) 1. If there are no literals, delete the entire trie repre- sented by N and return. 2. If we are at a leaf of the trie, return. 3. For (a) each edge e of N, do the following. If the label of e is the first literal of L, then re- cursively call REMOVE-SUBSUMED with the rest of the literals and the edges below e. Figure 3: Trie with 2 clauses. AvBvC chsme2 (b) If the label of e is lower than that of the first literal of L, then recursively call SUBSUMED on the same literals but the edges below e. As an extreme case suppose we want to remove all clauses subsumed by D from Figure 2. Because D is last in the ordering, the algorithm simply searches in left-to-right depth-first order removing all clauses containing D. After adding the clause D, the resulting trie is illustrated by Figure 3. 4 esults Table 1 table summarizes the performance improve- ment of IPIA produced using a trie. Each line of the table lists the name of the task, the number of clauses which specify the problem, the number of prime im- plicates of these clauses, the number of subsumption checks the non-trie version of II?IA requires, the run- ning times of the two algorithms, the average fraction of the trie searched during subsumption checks, the fraction of resolvents which are not subsumed by the trie, and the number of non-terminal nodes in the final trie. The timings are obtained on a Symbolics XL1200. The Lisp code is not particularly optimized as it is de- signed for a text book [4]. The non-trie version of IPIA is so slow that it is not possible to actually time its performance on larger ex- amples. We instrumented the trie version to estimate the number of subsumption checks that would have to be made by assuming that, on average, each subsump- tion check would check ha1 f of the current clauses. In all the cases we have tried, this estimate is within 25% of the actual number of subsumption checks so this estimate seems fairly reliable. We estimate the tim- ing of the non-trie version using 10 microseconds per subsumption check which is the fastest we’ve ever seen the non-trie algorithm perform. The implementation is written in basic Common Lisp and runs in Lucid and Franz as well. Both the code and the examples de Kleer 783 Subsumption Fraction Fraction Trie Task Clauses PIS Checks t-list(s) t-TRIE(s) Searched New Size Two-Pipes 54 88 13124 .22 .06 .081 .50 54 Adder 50 8400 3.8 x lOlo* 3.8 x 105* 721 .009 16207 K33 9 73 5166 .12 .03 .123 1 24 K44 16 641 506472 5.5 .46 .031 1 160 K55 25 7801 9.1 x 10”” 900” 8.6 .003 1 1560 K54 20 1316 1730120 22.6 1.1 1 263 K66 36 117685 2.4 x lOlo* 2.4 x 105* 224 1 K67 42 823585 1.3 x lo=* 1.4 x lolo* 2541 1 137264 Regulator 106 2814 3.7 x 1oy* 3.7 x 104* 85 .06 1365 BD 151 1907 1.1 x 109” 1.1 x 104’ 38 .067 2493 Table 1: Comparison of the old and improved algorithms. “*” indicates estimates. are available from the author. Table 1 clearly indicates the dramatic performance achievement produced using a trie data structure to represent the clausal data base. The actual IPIA al- gorithm in [6] includes additional optimizations to the version we have presented in this paper. Those opti- mizations reduce the number of resolutions and sub- sumption checks. However, these optimizations entail additional bookkeeping and are known to produce in- correct results in some cases. Therefore, we restrict our comparison to the basic version of IPIA. The tasks labeled “Two-Pipes” and “Regulator” come from qualitative physics. The tasks labeled “Adder” and “BID” come are diagnosis problems. The tasks labeled “K”nm are taken from [6]. The analysis clearly shows that the trie-based algo- rithm yields substantial improvement in all cases. The final columns in the table provide some insight into why performance improves so dramatically. One hy- pothesis for the good performance is that most new clauses are subsumed by others and therefore imme- diately found in the trie and that the data structure would perform poorly if there were few subsumptions. The data does not substantiate this intuition. The col- umn labeled “Fraction New” indicates the fraction of the new clauses which are not subsumed by the cur- rent trie. We see even in the worst case where the new clause is never subsumed, that the trie-based al- gorithm is far superior. The column labeled “Frac- tion Searched” shows the average fraction of the non- terminal nodes in the trie actually searched. This data suggests that the central advantage of using tries is that subsumption checks need only examine a small fraction of trie. We have attempted to invent tasks which would de- feat the advantage of using tries and have not been able to find any. Tries would perform poorly for a task in which all subsumption checks failed and all the nodes in the trie have to be scanned for each failing sub- sumption check. To achieve this the trie would have to contain a very high density of clauses. It is difficult to 784 Representation and Reasoning: Tractability devise an initial set of clauses whose prime implicates densely populate the space. Moreover, the fact that clauses resolve with each to produce new ones means that if the clause set becomes too dense the clause set is likely to be reduced by subsumptions (a dense clause set is also likely to be inconsistent). The performance of the trie-based IPIA is relatively sensitive to the choice of ids (although performance is always much better than the non-trie version). The choice of ids affects the canonicalized forms of the clauses and hence the size of the trie. To lower the size of the trie, the most common symbols should have lower id. Although it is impossible to tell initially which symbols will occur more commonly in the prime implicates, we use the number of occurences in the ini- tial clause set as a guide. IPIA performs noticably better if less common symbols are processed first (i.e., in steps 2 and 5). References PI PI PI PI PI PI de Kleer, J., An assumption-based truth main- tenance system, Ar-tificial Intelligence 28 (1986) 127-162. Also in Readings in NonMonotonic Rea- soning, edited by Matthew L. Ginsberg, (Morgan Kaufmann, 1987), 280-297. de Kleer, J., Mackworth A., and Reiter R., Char- acterizing Diagnoses, in: Proceedings AAAI-90, Boston, MA (1990) 324-330. Extended version will appear in Artificial InteZligence Journal. de Kleer, J., Exploiting locality in a TMS, AAAI- 90, Boston, MA (1990) 254-271. Forbus, K., and de Kleer, J., Building problem solvers (MIT Press, 1992). Ginsberg, M.L., A Circumscriptive Theorem Prover. Proceedings of the second international workshop on Non-Monotonic Reasoning. Springer, LNCS 346, 100-114, (1988). Kean, A. and Tsiknis, G., An incremental method for generating prime implicants/implicates, Jour- nal of Symbolics Computation 9 (1990) 185-206. [?] Knuth, D.E., The art of computer programming (Addison-Wesley, Reading, MA, 1972). [8] Raiman, O., and de Kleer, J., A Minimality Main- tenance System, submitted for publication, 1992. [9] Reiter, R. and de Kleer, J ., Foundations of assumption-based truth maintenance systems: Preliminary report, Proceedings of the National Conference on Artificial Intelligence, Seattle, WA (July, 1987), 183-188. [lo] Tison, B., Generalized consensus theory and appli- cation to the minimization of boolean functions, IEEE transactions on electronic computers 4 (Au- gust 1967) 446-456. de Kleer 785 | 1992 | 132 |
1,201 | ts for Fast Inference Henry Kautz and Bart Selman AI Principles Research Department AT&T Bell Laboratories Murray Hill, NJ 07974 {kautz, selman}@research.att.com Abstract Knowledge compilation speeds inference by creating tractable approximations of a knowledge base, but this advantage is lost if the approximations are too large. We show how learning concept generalizations can al- low for a more compact representation of the tractable theory. We also give a general induction rule for gen- erating such concept generalizations. Finally, we prove that unless NP E non-uniform P, not all theories have small Horn least upper-bound approximations. Introduction Work in machine learning has traditionally been divided into two main camps: concept learning (e.g. [Kearns, 19901) and speed-up learning (e.g. [Minton, 19881). The work reported in this paper bridges these two areas by showing how concept learning can be used to speed up inference by allowing a more compact and efficient rep- resentation of a knowledge base. We have been studying techniques for boosting the performance of knowledge representation systems by compiling expressive but intractable representations into a computationally efficient form. Because the out- put representation language is, in general, strictly less expressive than the input (source) language, the output is an approximation of the input, rather than an exact translation. We call this process knowledge compilation by theory approximation. For example, it is NP-hard to determine if a clausal query follows from a theory represented by proposi- tional clauses, and thus all foreseeable algorithms for this problem require time exponential in the size of the theory in the worst case. On the other hand, the problem can be solved in linear time for theories expressed by Horn clauses. We have developed algo- rithms for computing two kinds of Horn approximations to general clausal theories [Selman and Kautz, 1991; Kautz and Selman, 19911. The first is a Horn Zower- bound, defined as a set of Horn clauses that entails the source theory. We proved that a best (logically weakest) such bound, called a Horn greatest lower-bound (GLB), can be always be represented by a set of Horn clauses no larger than the source theory. Thus such a GLB can 786 Represent at ion and Reasoning: Tractability be used to quickly determine if a query does not follow from the source theory: If the query does not follow from the GLB ( w ic can be checked in linear time), it h’ h does not follow from the source theory. The second kind of approximation is a Horn upper- bound, defined as a set of Horn clauses that is entailed by the source theory. The best (logically strongest) such set is called the Horn least upper-bound (LUB).l The LUB can be used to quickly determine if a query does follow from the source theory: If the query does follow from the LUB (which can be checked in linear time), it also follows from the source theory. If the query does follow from the GLB but does not follow from the LUB, then the bounds cannot be used to answer it. The system can either return “unknown” or choose to do full theorem proving with the original theory. In either case, the resulting system is sound: use of the bounds speeds inference by allowing some proportion of the queries to be answered quickly, but introduces no erroneous answers. It may take a great deal of time to actually compute the bounds, but this cost is “off-line” : our goal is to have fast “run-time” query answering. In the papers cited above we also show how the bounds can be computed and used in an incremental, anytime fashion. Our original papers on this work left open the ques- tion of the worst-case size of the LUB relative to that of the source theory. Although it is easy to show that the LUB is sometimes equivalent to a set of Horn clauses which is exponential in the size of the source theory, that alone does not rule out the possibility that there always exists an alternative Horn axiomatization of that same LUB which is not significantly larger than the source theory. In this paper we exhibit a clausal theory that shows such an exponential blowup can be inherent: that is, the smallest Horn theory that is equivalent to the LUB is exponentially larger than the source theory. This would appear to be very bad news if one hoped to use the LUB as a way to speed up inference, since the increase in size can offset the decrease in inference ‘Throughout this paper we use LUB to mean Horn least upper-bound, although in the final section we briefly discuss some other kinds of least upper-bounds. From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. time. But in fact this negative result leads to an in- teresting insight about theory approximation: minor changes to the source theory can dramatically reduce the size of the minimum representation of LUB. In par- ticular, adding simple concept definitions to a source theory can sometimes decrease the size of the LUB by an exponential factor. The definitions add no new in- formation about the world; the original and augmented source theories agree on all formulas that do not con- tain the newly-defined concepts. Furthermore, we can present an intuitively plausible rule for automatically generating such definitions. We cannot prove that the techniques described in this paper for creating a compact representation of the LUB are complete; indeed, we believe that are simply useful heuristics. In fact, we will prove that unless a very sur- prising result holds in the complexity of finite functions, compact and tractable representations of the LUB do not always exist. The connection between concept learning and speed- up learning has always been implicit in much of the work in the two fields. For example, work on algorithms for learning decision trees [Pagallo and Haussler, 19901 has the goal of generating trees that are small, and/or are expected to classify objects with a minimum num- ber of tests. In work on speed-up learning for problem- solving, the learned macro-operators can also be consid- ered to be newly defined concepts [Minton, 19851. Our work arose in the context of developing tractable ap- proximations of a knowledge base, and differs from first kind of example in that no new information is given to the system during the learning process, and differs from the second in that the concepts are induced be- fore any problem instances (in our case, queries to the knowledge base) are presented to the system. Work in reformulation [Amarel, 1968; Bresina et al., 1986; Subramanian and Genesereth, 19871 is somewhat simil- iar in that reformulating a problem to make it easier to solve may also involve the introduction of new terms. Most of the work in that area, however, tries to find efficient reformulations of particular problem instances, rather than complete theories, and does not try to trade off-line costs for run-time efficiency. The paper is structured as follows. First we out- line knowledge compilation using Horn approximations. The next section presents an example of a theory with an exponential LUB. Then we show that the same the- ory with an added defined concept has a small LUB (polynomial in the size of the source theory). The fol- lowing section deals with issue of inducing the neces- sary concepts, and introduces a method of compacting a theory (i.e. the LUB) by inducing concepts. Finally we prove that unless the polynomial hierarchy collapses to &, there must always be some theories whose LUB cannot be represented in a form that is both small and tractable. Theory Approximation For a full introduction to knowledge compilation using Horn approximations see [Selman and Kautz, 19911; a generalization to other kinds of approximations and the first-order case appears in [Kautz and Selman, 1991; Greiner, 19921. This section summarizes only the rele- vant definitions and results. We assume a standard propositional language, and use P, Q, r, and s to denote propositional letters. A zit- eral is either a propositional letter, called a positive literal, or its negation, called a negative literal, and is represented by 2U, x, y, or Z. A clause is a disjunction of literals, and can be represented by the set of literals it contains. Clauses are sometimes written using material implication to make their intended meaning clear; for example, the clauses p V 1~ V -rr and Q > (p V lr) are identical. Greek letters LY and ,0 are used to represent clauses or parts of clauses (disjunctions of liter&). A set of clauses is called ‘a clausal theory, and is rep- resented by the Greek letters C or 6. A clause is Horn if and only if it contains at most one positive literal; a set of such clauses is called a Horn theory. (Note that we are not restricting our attention to definite clauses, which contain exactly one positive literal; a Horn clause may be completely negative.) A set of clauses C entails a set of clauses C’, written C b C’, if every model (sat- isfying truth-assignment) of C is a model of I=‘. The general problem of determining if a tailed by clausal theory is NP-hard f iven clause is en- Cook, 19711, and thus almost certainly intractable. However, the prob- lem for Horn theories can be solved in time linear in the combined lengths of the theory and query [Dowl- ing and Gallier, 19841. (Note that the query need not be Horn; in fact, the problem remains linear for even broader clauses of queries, such as arbitrary CNF for- mulas, and DNF formulas, where at most one negative literal.) each disjunct cant ains Following are the definitions of the Horn upper- bound approximations of a clausal theory, as described in the introduction. Definition: Horn Upper-Bound and LUB Let c be a set of clauses. A set Cub of Horn clauses is a Horn upper-bound of c iff c b Cub. A set Club of Horn clauses is a Horn least upper-bound (LUB) of C iff it is a Horn upper-bound, and there is no Horn upper-bound c,b such that Cub /= Cl&, and &b k &-,. For example, let C be {pvq, (pAr) > s, (q/\r) 1 s). Then one Horn upper-bound is { (pAr) 1 s, (q Ar) > s}, and the LUB is (r 1 s}. The LUB of a theory is unique up to logical equiv- alence. That is, there may be distinct sets of Horn clauses Club and Ciub that satisfy the conditions stated above, but if SO, Club + Cl&, and Ciub + Club. It is important to note that such distinct representations of the LUB may vary greatly in size: for example, one may be the size of C, and the other of size 21cl. . Kautz and Selman 787 The LUB of a theory can be used as a quick but in- complete method of testing if the theory entails a query o by the following observations: 0 If&b j=othenCt=o. o If Q is Horn, then Club b o if and only if c b Q. The LUB of a theory can be computed by resolu- tion. The basic method is to generate all resolvants of C (a finite set, since the language is propositional), and then eliminate all non-Horn clauses. The result is a representation of the LUB, but it will usually con- tain many redundant clauses - for example, p > q and q 3 r as well as p > r. The representation can be minimized by repeatedly striking out any clause that is entailed by all the other clauses in the set. This basic algorithm can be optimized so that it generates fewer redundant clauses, but there is little hope for a polyno- mial time algorithm since the problem is NP-hard ([Sel- man and Kautz, 19911). We accept this potential cost, however; the game we are playing is to see how fast we can make run-time question-answering by moving computational effort to a pre-processing stage. In ad- dition, the knowledge compilation algorithms naturally generate a sequence of approximations that converge to the true LUB and GLB. These intermediate approx- imations can be used for question-answering even before the algorithm halts. if Diane is a computer scientist who reads Dennett and Kosslyn, then Diane is a cognitive scientist. In general, for such non-Horn form theories, finding a proof may take time exponential in the length of the entire theory (provided P # NP) . Clause (1) can be resolved with subsets of clauses (2-4) to yield many different Horn clauses, such as (ReadsMcCarthy A Phil A ReadsKosslyn) > CogSci (CompSci A ReadsDennett A Psych) > CogSci In fact, the LUB of this theory is equivalent to the set of 23 Horn clauses: (pAqAr) 3 CogSci 1 p E (CompSci, ReadsMcCarthy] q E {Phil, ReadsDennett} i (5) r E (Psych, ReadsKosslyn} Furthermore, we can prove that there is no smaller set of Horn clauses equivalent to (5). Note that this is a much stronger condition then simply saying that there are no redundant clauses in (5); we are asserting that there is no way to represent the same information in less space by using Horn clauses (or even using non- Horn clauses, for that matter). In general: Theorem 1 There exist clausal theories C of size n such that the smallest clausal representation -of their L UB is of size O(2”). Explosion of the LUB The proofs of this and all other theorems appear in the Knowledge compilation provides the greatest advantage when the representation of the LUB is as small as possi- ble. Is it always possible to find a representation of the LUB which is of comparable size to that of the source theory? The answer is no, as the following example demonstrates. The source theory contains the following clauses, which can be interpreted as rules for deciding if some- one is a cognitive scientist. The clauses are numbered for reference. (CompSci A Phil A Psych) 3 Cog&i (1) ReadsMcCarthy 3 (CompSci V CogSci) (2) ReadsDennett > (Phil V CogSci) (3) ReadsKosslyn > (Psych V CogSci) (4) Clause (1) states a sufficient condition for being a cogni- tive scientist: being a computer scientist, and a philoso- pher, and a psychologist. The remaining clauses let one deduce a person’s profession from his or her reading habits. Clause (2) states that if a person reads pa- pers written by McCarthy, then the person is either a computer scientist or a cognitive scientist (or possi- bly both). Similarly, a reader of Dennett is either a philosopher or cognitive scientist or both, and a reader of Kosslyn is either a psychologist or cognitive scientist or both. Reasoning with this theory can be quite complicated. For example, by reasoning by cases, one can prove that appendix. Thus, although we can tell if any clause follows from the LUB in time linear in the size of the LUB, the ex- plosion in size of the LUB in this example wipes out our savings. Of course, there are also many common- sense theories for which such exponential blowup does not occur. Shrinking the LU There are many ways to modify the syntactic character- istics of a theory without changing its basic meaning. For example, any theory can be represented by a set of clauses each containing no more than three literals (3-CNF form) by introducing new propositional letters. The old and new theories are not equivalent, since the new uses an expanded vocabulary, but they are essen- tially the same: they both entail or both do not entail any formula that does not contain any of the new let- ters. Thus one might wonder if a large LUB could be repre- sented by a small set of Horn clauses that have basically the same meaning, if not actual logical equivalence. As with the case of 3-CNF formulas, the technique we use depends on the introduction of new propositional let- ters. Rather than modify the definition of the LUB, we will add these new letters to the source theory itself. If we take the meaning of a letter to be a concept, we will see that the method reduces to the definition of new concepts that generalize old concepts. 788 Representation and Reasoning: Tractability For example, let us modify the theory given by clauses (l-4) by introducing three new concepts, “computer science buff”, “philosophy buff” , and “psy- chology buff” . The first generalizes the concepts of a computer scientist and of a reader of papers by Mc- Carthy. Similarly, the second generalizes philosopher and reader of Dennett, and the third generalizes psy- chologist and reader of Kosslyn. Each concept defini- tion requires three clauses: one to assert that the more general concept is divided among its subconcepts, and two to assert that the subconcepts are part of the con- cept. The added clauses are: CompSciBuff > (CompSci V ReadsMcCarthy) (6) CompSci > CompSciBuff (7) ReadsMcCarthy 3 CompSciBuff (8) PhilBuff 1 (Phil V ReadsDennett) (9) Phil 3 PhilBuff (10) ReadsDennett > PhilBuff (11) PsychBuff 3 (Psych V ReadsKosslyn) (12) Psych 3 PsychBuff (13) ReadsKosslyn 3 PsychBuff (14) The LUB of the augmented theory containing (l-4) and the clauses above can be represented by just the Horn clauses from the new concept definitions (7,8, 10, 11, 13, 14) together with the single clause (CompSciBuff A PhilBuff A PsychBuff) r> CogSci (15) Returning to our example above where Diane is a computer scientist who reads Dennett and Kosslyn, we can now infer quickly from (7)) (1 l), and (14) that she is a computer science buff, philosophy buff, and psychol- ogy buff, and therefore by (15) a cognitive scientist. Note that this inference can be computed in time linear in the size of the new LUB and therefore linear in the size of the original theory (l-4). So, by teaching the system new concept definitions, the size of the new source theory grows only linearly, and the LUB shrinks to approximately the size of the source theory itself.2 Inducing New Concepts So far we have seen that the goal of speeding infer- ence by creating a compact, tractable approximation of 2The signific ante of this reduction does not lie solely in the fact that some ~lrbit~~yrepresentation equivalent to the LUB can be encoded in a linear number of characters. For instance, the schema in equation (5) is also written using no more characters than there are liter& in the original theory. Or even more to the point, the source theory itself can be taken to “represent” its own LUB, where we interpret it to mean “the set of all Horn clauses that can be derived from this set of formulas.” The reason the reduction given in this example is interesting is that the resulting representation also allows efficient inference - that is, linear in the size of the representation. a knowledge base can motivate learning concepts that are simple generalizations of previous concepts. This presupposes the existence of a helpful teacher and/or a separate concept learning module that will present the knowledge compilation system with useful concept definitions. One might wonder, however, if the process can be inverted: Can such concepts be generated as a by-product of the search for a compact representation of the tractable approximation? This is indeed possi- ble, we will show below. (See [Muggleton and Buntine, lQSS] for a different approach to learning new general- izations, based on inverting resolution proofs.) Suppose you know that two different classes of ob- jects, call them p and Q, share a number of characteris- tics. For example, to represent the fact that all p’s and all q’s are blue or red or orange one could write p z> ( blue V red V orange ) q 3 ( blue V red V orange ) In such a situation it seems quite reasonable to hy- pothesize the existence of a class of objects T that sub- sumes both p and q, and which has the characteristic properties p and q share. That is, you would create a new symbol T, and add the definition T zz (pVq) to your knowledge base. The common properties of p and q can be associated with this new concept P, and the original axioms stating those properties (namely the two clauses above) can be be deleted from your knowledge base, without loss of information. Thus the original axioms are replaced by P 3 ( blue V red V orange ) P=JF Or The new axioms, even without the addition of the ax- iom r I (p V q), have a number of desirable properties. We will state these properties for the general case. Definition: Induced Concept Let 8 be a set of clauses containing one or more pairs of clauses of the form -pVcya, ‘qvcui (16) where p and q are letters and or, e . e, cyn for n 2 1 are disjunctions of literals. An induced concept of 0 is a new letter r together with two kinds of defining clauses: one for the necessary condition r 1 (P v 4) (17) and a pair of clauses for suficient conditions: P 3 r, Or (18) Definition: Compaction Let 19 be a set of clauses, and r an induced concept of 0. Then 8’, the compaction of 8 using r, is defined as follows: et = 8 -{ipVai 1 i E {l,...,n}} -{lQVCYi 1 i E (1,.**,n}} U{lpVr, TqVr} U{lrVcUi 1 i E (l,***,n)} Kautz and Sehnan 789 That is, the compaction is obtained by removing the clauses given in (la), and adding the clauses given in (18), and adding a set of clauses that states that r im- plies each of the oi. Theorem 2 Let 8’ be a compaction of 8 using induced concept r. Then If a is a formula not containing r, then 0 /= cx if and only if 8’ j= CK. In other words, 8’ is a conservative extension of 8. If the total length of the ai’s is 4 or more, then 8 is smaller than 0. Let us see what happens when the large LUB given by equation (5) is repeatedly compacted by inducing new concepts. Arranging the the clauses of the LUB as follows suggests that CompSci and ReadsMcCarthy should be generalized: (CompSci A Phil A Psych) > CogSci (ReadsMcCarthy A Phil A Psych) > CogSci (CompSci A ReadsDennett A Psych) 3 CogSci (ReadsMcCarthy A ReadsDennett A Psych) 3 CogSci (CompSci A Phil A ReadsKosslyn) 3 CogSci (ReadsMcCarthy A Phil A ReadsKosslyn) 3 CogSci (CompSci A ReadsDennett A ReadsKosslyn) 3 CogSci (ReadsMcCarthy A ReadsDennett A ReadsKosslyn) 3 CogSci So the LUB can be compacted by generating a new symbol (let us call it “CompSciBuff”), and rewriting it as (CompSciBuff A Phil A Psych) 3 CogSci (CompSciBuff A ReadsDennett A Psych) 3 CogSci (CompSciBuff A Phil A ReadsKosslyn) 3 CogSci (CompSciBuff A ReadsDennett A ReadsKosslyn) > CogSci CompSci 3 CompSciBuff ReadsMcCarthy ‘I) CompSciBuff The pair of propositions Phil andReadsDennett fit the pattern of the concept induction rule, so we introduce a symbol called PhilBuff and rewrite again: (CompSciBuff A PhilBuff A Psych) > CogSci (CompSciBuff A PhilBuff A ReadsKosslyn) > CogSci CompSci > CompSciBuff ReadsMcCarthy > CompSciBuff Phil > PhilBuff ReadsDennett > PhilBuff Finally, concept induction is applied to the pair Psych and ReadsKosslyn , The result is the small LUB pre- sented at the end of the previous section: (CompSciBuff A PhilBuff A PsychBuff) 3 CogSci CompSci 3 CompSciBuff ReadsMcCarthy 3 CompSciBuff Phil 3 PhilBuff I ReadsDennett 3 PhilBuff Psych 3 PsychBuff ReadsKosslyn > PsychBuff In general: Theorem 3 There exist clausal theories C of size n such that (1) the smallest clausal representation of their LUB is of size 0(2n) and (2) there are compactions of their LUB (using one or more induced concepts) that are of size O(n). Although we have been thinking of induction as a technique for reducing the size of the LUB, it can also be thought of as a method for adding new concepts to the source theory, as illustrated by the following theorem. Theorem 4 Let C be a set of clauses and &b its Horn least upper-bound. Let &, be a compaction of Club us- ing induced concept r. Define I’ to be C together with (both the necessary and suficient conditions of) the def- inition of r: l?=EU{rf(pVq)} Then the Horn least upper-bound rlUb of r entails the compaction Cfub: rlub k qub Furthermore, rlUb is a conservative extension of Club. In other words, compacting the LUB by inducing new concepts can be viewed as a result of regenerating the LUB after adding the definition of a new concept to the source theory. In the example given in this paper, the compacted and regenerated LUB’s are equivalent, but in general the regenerated LUB can be slightly stronger. For example, if the theory C is {p 3 s, q 3 s, t 1 (p V q)} , the reader may verify that Flub entails t > r, but that xi,,, does not. In any case, the regenerated bound I&b still does not entail any formulas not containing the new concept r that are not entailed by the original bound Club. Q Efficient Representations Always Exist? So far we have shown that a naive representation of a theory’s LUB can sometimes require an exponential amount of space, and that in some of those cases a clever representation using new propositional letters re- quires only a polynomial amount of space. The question then becomes how general these results are. Is it always possible to produce a small representation of the LUB by the compaction technique described above? Failing that, one may wonder if it is always possible to pro- duce a small and tractable representation of a theory’s 790 Representation and Reasoning: Tractability LUB using any techniques and data structures, includ- ing methods we have not yet discovered. The following theorem states that the more general question is in fact equivalent to a major open question in complexity theory, whose answer is expected to be negative. Theorem 5 Unless NP C_ non-uniform P, it is not the case that the Horn least upper bound &b of a proposi- tional clausal theory C can always be represented by a data structure that allows queries of the form to be answered in time polynominal in (ICI + IQ!]), where Q is a single Horn clause. Note that this is so despite the fact that we allow an arbitrary amount of work to be performed in computing the data structure used to represent Club. The notion of “non-uniform P” comes from work in circuit complexity [Boppana and Sipser, 19901. A prob- lem is in non-uniform P (also called P/poly) iff for ev- ery integer n there exists a circuit of complexity (size) polynomial in n that solves instances of size n. The adjective “non-uniform” refers to the fact that different circuits may be required for different values of n. Any problem that can by solved by an algorithm that runs in time O(f(n)) h as circuit complexity 0( f (n) log n). We use this fact implicitly in the proof of the theorem, where we talk about polynomial time algorithms rather than polynomial size circuits. The class non-uniform P is, however, considerably larger than P. (For example, non-uniform P contains non-computable functions, such as the function that returns “1” on inputs of length n iff Turing Machine number n halts on all inputs. For any n the circuit is simply fixed to return 1 or 0.) Although it is possible that P # NP and yet NP & non-uniform P, this is con- sidered unlikely. One consequence would be that the polynomial-time hierarchy would collapse to C2 [Karp and Lipton, 19821. As shown in the appendix, the theorem can be strengthened to say that the claim that there always exists an efficient form of the LUB for answering Horn clausal queries is equivalent to the claim that NP C_ non- uniform P. Therefore a proof that such efficient repre- sentations do or do not always exist would be a major result in the complexity of finite functions. An immediate corollary of the theorem is that un- less the polynomial hierarchy collapses in this manner, compaction by defining new propositions is an incom- pletement method for shrinking the LUB. Corollary Unless NP C non-uniform P, it is not the case that there is always a compaction (using any num- ber of new variables) of the Horn least upper bound of a theory C that is of size polynomial in ICI. This follows from the theorem because one can deter- mine if a Horn clause follows from a compaction (which is itself Horn) in time linear in the length of the com- paction plus the length of the query. Conclusions Knowledge compilation speeds inference by creating two tractable approximations of a knowledge base. Part of the potential speed advantage can be lost if one of these bounds, the LUB, grows to exponential size. We have shown that this can sometimes occur, but that learning defined concepts can sometimes rescue the method, by allowing an exponential reduction in the size of the LUB. In addition, compacting the tractable theory by using a rule of induction is one way to gen- erate the concepts. These results provide a useful bridge between the ar- eas of concept learning and speed-up learning. While work in concept learning is normally motivated by the need to classify data, our work suggests that concept learning may also be useful for efficient commonsense reasoning. Finally, we prove that unless a radical reformulation of complexity theory occurs it is likely that any method for efficiently representing the Horn least upper-bound is incomplete. However, the general framework for the- ory approximation described in the beginning of this paper can be adapted to use bounds that are in any tractable lan uage, such as binary clauses [Kautz and Selman, 1991 , or Horn clauses of a fixed maximum 7 length. In some of these languages we can be sure that the LUB is of polynomial size. For example, the binary-clause least upper-bound of a theory of size n is of size O(n2). Currently we are studying the properties of these different kinds of approximations. Appendix: Proofs Proof of Theorem 1 Consider a theory C of the following form, for arbi- trary 12: -pl v 7p2 v - * - v ‘pn v s ‘Ql v Pl v s -q2VP2VS ‘Qn VPn vs We see that C contains 4n + 1 literals; that is, it is of size O(n). The LUB C lub of c is the following set of Horn clauses, of total length 2”: { 1x1 v 7x2 v * ’ * v 1xn v s 1 Xi E {pi,qi} for 1 5 j 5 n > First we prove that the set Club has the following prop- erties: no two clauses resolve, and it is irredundant (no subset of C lub implies all of Club). Then we prove that &b is of minimum size. (Note that being of minimum size is a stronger condition than being irredundant.) Proof that C lub is irredundant: suppose there is a clause cy in Club such that &b - (o} + o. Since no two clauses in Club - {o} resolve, by completeness of resolution there must be an cy’ in Club - {Q} such that Kautz and Selman 791 a’ subsumes cy. But this is impossible, since all clauses in Elub are of the same length. Finally, we can now prove that there is no smaller set of clauses Eiub which is equivalent to Club : Suppose there were an Efub such that El& s Eiub and &,,I < (Club I. Then for all cx in &, , that C k a’, and since cy’ is Horn, Club k cy’ and therefore &b b o. For the general case, note that any Q can be equivalently written as a conjunction of clauses, and Flub thus entails each clause. Thus El&, entails each clause, and therefore entails cy. 0 Proof of Theorem 5 and since no clauses in Club resolve, this means that there exists an (Y’ in Club such that a’ subsumes c11. That is, every clause in E:*,, is subsumed by some clause in Club. Suppose each clause in &b subsumed a different clause in XI,,,; then I&b’1 2 I%ubl, a con- tradiction. Therefore there is a proper subset Club” of Club such that each clause in C&, is subsumed by some clause in Club”. Then Club” b Club’, and therefore &b” + Club. But this is impossible, because we saw that Club is ir- redundant. Therefore there is no smaller set of clauses equivalent to Club which is shorter than Club. 0 Proof of Theorem 2 (First part) Let 0” = 0 U (r = (p V q)}. We see that 0” is a conservative extension of 8, since it extends t9 by adding a defined proposition [Shoenfield, 1967, page 571. Since 0’ + 8 it is an extension of 0, and since t9” b 0’ it must be the case that 8’ is a conservative extension of 8. (Second part) Obvious, by counting. 0 Proof of Theorem 3 The LUB of any theory in the class described in the proof of Theorem -1 has the following compaction of size O(n) using new letters rl, . . . , r,: (-q V 8 l 8 V -v, V s)U iTPi V ri, YQiVri Ilsi<n} Cl Proof of Theorem 4 (First part, that I’ lub /= Club’.) Observe that C U {r E (pV q)] b (r 3 Cvili E (1, . . . . n}}. Together with the fact that C b Club it follows that C U (r G (p V q)} t= Club U (r 3 aili E (1, . . . . n}) and thus Flub b &b’. Now suppose we have been able to compute a repre- sentation of the Horn LUB of C that has the property that one can test Horn queries against it in polynomial time. We noted before that a Horn formula follows from the LUB if and only if it follows from the source theory. Suppose A is an arbitrary 3-CNF formula over n vari- ables that we wish to test for satisfiability. We con- struct a Horn clause cy containing only auxiliary vari- ables by including a negative auxiliary variable c that corresponds to each clause S in A. For example, if A is (PI 'J1~3 VP~)+PI VPZ VTP~) then the corresponding Horn clause is (Second part, that Flub is a conservative extension of &b.) It is plain that Flub is an extension of El&, because adding premises to the source theory can only make the LUB grow monotonically. Next we prove that Flub is conservative. Let cy be a formula not containing r such that Flub t= CY. Let us first consider the case where o! is a clause and not a tautology. Then there is a Horn clause cy’ such that Now we claim that this Horn clause is implied by the LUB if and only if A is not satisfiable. (+) Suppose the query is implied by the LUB. Since the query is Horn, this means that c l= lc! v 1c’ v 72” v . . , where the (c, c’, c”, . . .} are the auxiliary variables in the query that correspond to clauses {S, S’, S”, . . .} in A. Equivalently, E U (~(Tc V 1,~’ V -YZ” V . . .)} is unsatisfiable. That is, Flub k CY’ and ~8’ /= a! C U {c, c’, c”, . . .} is unsatisfiable. and therefore I’ + cy’. Recall that I’ is a conservative extension of C, and cy is in language of C. This means Note that any clause in C containing an auxiliary vari- able other than (c, c’, c”. . .} can be eliminated, since Suppose such a representation of the LUB always ex- isted. We then show that S-SAT over n variables can be determined in O(n3) time. Because the choice of n is arbitrary, and 3-SAT is an NP-complete problem, this would mean that NP 2 non-uniform P. Let the variables be a set of main variables {Pl ,---,Pn} t o e g th er with a set of auxiliary variables bw ]z, y, z E LITS}. where LITS is the set of literals constructed from the main variables (the variables or their negations). Let the source theory C be the conjunction of clauses: II= A { 2 v Y v z v lcx,y,z} x:,~,zGLITS Note that C is of length O(n3). The idea behind the construction is that any S-SAT clause over n variables can be constructed by selecting a subset of the clauses from C and eliminating the auxiliary variables. 792 Representation and Reasoning: Tractability that clause is satisfied in any model in which its auxil- iary variable is assigned false, and no other instance of that variable appears in the formula. Thus it must be the case that (6 v lC, 6’ v ld, 6” v 4, . . .) u {c, c’, cy . * .} is unsatisfiable. Because the auxiliary variables each ap- pear exactly once negatively and once positively above, they can can be resolved away. Therefore (S, S’, S”, . . .} E A is unsatisfiable. (t) Note that each step in the previous section can be reversed, to go from the assumption that A is un- satisfiable to the conclusion that C k c~. We assumed that the test could be peformed in time polynominal in the length of the source theory plus the length of the query. We noted earlier that the source theory is of length 0(n3). The query is also of of length 0(n3), because there are only n3 auxiliary variables. The smallest A containing n variables is of length n, so in in any case both the source theory and query are polynomial in the length of A. Thus satisfiability of A can be determined in time polynomial in the length of A. Since the choice of n was arbitrary, and S-SAT is an NP-complete problem, this means that NP C non- uniform P. 0 Proof of strengthened Theorem 5 We can strengthen the theorem to an equivalence by showing that NP c non-uniform P implies that small and tractable representations of the LUB always exist. Suppose we are given a source theory cant aining n variables. Assuming NP of length m non-uniform P, there exists a circuit that determines satisfiability of formulas of length m + n that has complexity polyno- mial in m-j-n. We use this circuit to construct program to test queries of the form Club + a as follows: given o, first check that is not a tautology, and eliminate any duplicated literals. The resulting query is of length 5 n. Then pad out the query to exactly length n by duplicat- ing any of its literals. Then the negation of the query together with C is a formula of exactly length m + n, so-we can use the circuit to determine if the formula is unsatisfiable, or equivalently, that cy follows from C. Since a is Horn, then the latter condition is equivalent to saying Club i= a. Since the circuit is of size poly- nomial in m + n it must execute in time polynomial in m-l-n - that is, in time polynomial in (ICI + ]a]). • I References [Amarel, 19681 Saul Amarel. On representations of problems of reasoning about actions. In Michie, ed- itor, Machine Intelligence 3, pages 131-171. Edin- burgh University Press, 1968. [Boppana and Sipser, 19901 R. B. Boppana and M. Sipser. The complexity of finite functions. In J. an Leeuwen, editor, Handbook of Theoretical Computer Science, Volume A: A/go- rithms and Compexity, pages 757-804. Elsevier, Am- sterdam (and MIT Press, Cambridge), 1990. [Bresina et al., 19861 J. L. Bresina, S. C. Marsella, and C. F. Schmidt. Reappr - improving plan- ning efficience via local expertise and reformulation. Technical Report LCSR-TR-82, Rutgers U., New Brunswick, June 1986. [Cook, 19711 S. A. Cook. The complexity of theorem- proving procedures. In Proceedings of the 3rd Annual ACM S mposium on the Theory of Computing, pages 151-15{, 1971. [Dowling and Gallier, 19841 William F. Dowling and Jean H. Gallier. Linear time algorithms for testing the satisfiability of propositional Horn formula. Jour- nal of Logic Programming, 3:267-284, 1984. [Greiner, 19921 Russell Greiner. Learning near-optimal Horn approximations. In Preprints of the AAAI Spring Symposium on Knowledge Assimilation. Stan- ford University, Stanford, CA, March 1992. [Karp and Lipton, 19821 R. M. Karp and R. Lipton. Turin machines that take advice. Enseign. Math., 28:19ff-209, 1982. [Kautz and Selman, 19911 Henry Kautz and Bart Sel- man. A general framework for knowledge compila- tion. In Proceedings of the International Workshop on Processing Declarative Knowledge (PDK), Kaiser- slautern, Germany, July 1991. [Kearns, 19901 Michael J. Kearns. The Computational Complexity of Machine Learning. MIT Press, Boston, MA, 1990. [Minton, 19851 Steve Minton. Selectively generalizing I$LI-I;~~; problem solvmg. In Proceedings of IJCAI- > . [Minton, 19881 Steven Minton. Learning Eflective Search Control Knowledge: an Explanation-Based Approach. PhD thesis, Department of Computer S;;;ce, Carnegie-Mellon University, Pittsburgh, PA, . [Muggleton and Buntine, 19881 Stephen Muggleton and Wray Buntine. Machine invention of first-order predicates by inverting resolution. In J. Laird, editor, Proceedings of the Fifth International Conference on Machine Learning, page 339, Los Altos, CA, 1988. Morgan Kaufmann. [Pagallo and Haussler, 19901 Giulia Pagallo and David Haussler . Boolean feature discovery in empirical learning. Machine Learning, 5:77-99, 1990. [Selman and Kautz, 19911 Bart Selman and Henry Kautz. Knowledge compilation using Horn approxi- mations. In Proceedings of AAAI-91, pages 904-909, Anaheim, CA, 1991. [Shoenfield, 19671 Joseph R. Shoenfield. Mathematical Logic. Addison-Wesley, Reading, MA, 1967. [Subramanian and Genesereth, 19871 Devika Subra- manian and Michael R. Genesereth. The relevance of irrelevance. In Proceedings of IJCAI-87, volume 1, page 416, 1987. Kautz and Selman 793 | 1992 | 133 |
1,202 | ropositional its Jonathan Stillman Artificial Intelligence Program General Electric Research and Development Center P.O. Box 8, Schenectady, N.Y. 12301 e-mail: stillman@crd.ge.com Abstract We characterize the complexity of several typical prob- lems in propositional default logics. In particular, we examine the complexity of extension membership, ex- tension existence, and extension entailment problems. We show that the extension existence problem is X; complete, even for semi-normal theories, and that the extension membership and entailment problems are X; complete and II; complete respectively, even when re- stricted to normal default theories. These results con- tribute to our understanding of the computational rela- tionship between propositional default logics and other formalisms for nonmonotonic reasoning, e.g., autoepis- temic logic and McDermott and Doyle’s NML, as well as their relationship to problems outside the realm of nonmonotonic reasoning. Introduction Almost every activity that one undertakes involves rea- soning and acting based on incomplete information. You are reading these words under the assumption that they will say something about the topic described in the abstract above, although you don’t know this. Perhaps the next few pages are blank. There are many ways that your plan to continue reading could be thwarted, yet you probably haven’t thought about them, nor about how you might cope with them. Nor- mally, this incompleteness doesn’t even play a role in one’s conscious reasoning process. Much of artificial intelligence research involves devel- oping useful models of how one might emulate on com- puters this ‘common-sense’ reasoning in the presence of incomplete information that people do as a matter of course. There have been a number of attempts at develop- ing such models, both ad hoc and formal. Researchers argue that traditional predicate logics, developed for reasoning about mathematics, are inadequate as a for- mal framework for such research in that they are inher- ently monotonic: if one can derive a conclusion from a set of formulae then that same conclusion can also be derived from every superset of those formulae. They argue that people simply don’t reason this way: we are constantly making assumptions about the world in light of incomplete information, acting on those as- sumptions, then revising our beliefs as further informa- tion becomes available (see [McCarthy 19771 or [Min- sky 19751, for instance). Many researchers have pro- posed modifications of traditional logic to model the ability to revise conclusions in the presence of addi- tional information (see, for instance, [McCarthy 19861, [Moore 19831, [Poole 19$6]). Such logics are called non- monotonic. Informally, the common idea in all these approaches is that one may want to be able to “jump to conclusions” that might have to be retracted later. A detailed discussion of nonmonotonic logics is out- side the scope of this paper; a good introduction to the topic can be found in [Etherington 19881, and a number of the most important papers in the field have been collected in [Ginsberg 19871, which also provides some good introductory material. One of the most prominent of the formal approaches to nonmonotonic reasoning was proposed by Reiter ([Reiter 19801). R ‘t el er’s approach is based on default rules, which are used to model decisions made in pro- totypical situations when specific or complete infor- mation is lacking. Reiter’s default logic is an extension of first order logic that allows the specification of de- fault rules, which we will summarize shortly. Unfortu- nately, the decision problem for Reiter’s default logic is highly intractable in that it relies heavily on consis- tency checking for processing default rules, and is thus not even semi-decidable (this is not a weakness of Re- iter’s logic alone; it is common to most nonmonotonic logics). This precludes the practical use of Reiter’s full default logic in most situations. In earlier work of this author’s [Stillman 1990a; Stillman 1990b] and Kautz and Selman’s [Kautz and Selman 19891, syntactically restricted propositional de- fault theories were investigated in attempts to identi- fying regions of tractability in default reasoning. The work was motivated by the need to reason about rel- atively large propositional knowledge bases in which the default structures may be quite simple. Recent research involving inheritance networks with excep- tions is particularly relevant, and is explored in depth 794 Representation and Reasoninn: Tractabilitv From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. that if practical default reasoning systems are desired, in [Touretzky 19861 one must either consider extremely restricted expres- and in Chapter 4 of [Ethering- ton 19881, where the close relationship between de- siveness or work to identify subcases of otherwise in- fault logic and inheritance networks with exceptions is explored. A partial order of syntactic restrictions tractable classes that yield feasible complexity. is described in [Kautz and Selman 19891, together with discussion of the complexity of several problems over this partial order when the propositional theory is restricted to consisting of a set of literals. Their results showed that while very simple theories may be intractable, some syntactic restrictions result in polynomial-time tests for determining whether certain properties hold. In particular, they showed that one can decide in polynomial time whether there exists an extension that contains a given literal when the default rules are restricted to a class they called Horn default rules. They suggested that the ability to combine such default theories with non-default propositional Horn theories would be particularly useful, but left open the question of whether the membership problem (i.e., de- termining whether there exists an extension of a given default theory containing a specified literal) for such a combination of theories is tractable. In [Stillman 199Oa], we showed that a restriction of this problem is NP-complete, and presented several related results. Our investigation in [Stillman 1990b) resulted in defin- ing a richer hierarchy of default rules than that con- sidered by Kautz and Selman, most of which result from disallowing any prerequisites in rules. This cor- responds to introducing a “context-free” element to the reasoning, and seems to constitute the most sim- ple type of default rule that is not completely triv- ial. The work described in [Stillman 1990b] consid- ered very tight restrictions on the expressiveness of default rules as well as the underlying propositional theory. Unfortunately, our results showed that even under these restrictions, membership problems almost invariably remain intractable. These results suggested NP (It is import o note, however, that and only if B = the polynomial hiera and only if the polynomial hierarchy collapses to P.), although all of the problems in the polynomial hier- archy can be solved in single exponential time. From a practical standpoint, a more complete understand- ing of just where the important decision problems in propositional default logic lie in the polynomial hierar- chy may help us understand how to develop better de- terministic algorithms for these problems by enabling us to exploit prior results about other problems that lie in the same classes. The remainder of this paper is organized as follows: we begin with a brief description of Reiter’s default logic, followed by a short overview of the polynomial hierarchy. We then present the main results of this paper, characterizing the complexity of several key de- cision problems for propositional default theories. Fi- nally, we summarize and discuss related results and future work. Preliminaries eiter’s Default Logic For a detailed discussion of Reiter’s default logic the interested reader is referred to [Reiter 19801. In this section we will simply review some of the immediately cU:p pertinent ideas. A default theory is a pair (D, W), -T-- where W is a set of closed well-formed formulae (wffs) in a first order language and D is a set of default rules. If the conclusion of a default rule occurs in the ius- A default rule consists of a triple < cy, ,0, y >: cy is a formula called the prerequisite, ,B is a set of formu- lae called the justiJications, and +y is a formula called the conclusion. Informally, a default rule denotes the statement “if the prerequisite is true, and the justifi- cations are consistent with what is believed, then one may infer the ConcZusion.” Default rules are written This paper contains the results of an examination of the general complexity of membership, entailment, and existence problems for arbitrary propositional de- fault logics. Although it is clear that such problems cannot be tractable (since they trivially contain the tautology problem for propositional calculus), it is not obvious exactly how hard they are. The main results we present are that these problems are indeed higher in the polynomial hierarchy than NP or co-NP, placing them at the second level of the hierarchy. While the impact of classifying a problem at the second level of the hierarchy is not yet fully understood (similarly, we don’t know that showing a problem to NP-complete means that it can’t be solved efficiently, just that it’s in the same set as a number of other problems that we don’t know how to solve efficiently), this may indicate that these problems are strictly harder than those in tifications, the default rule is said to be semi-nor&al; if the conclusion is identical to the justifications the rule is said to be normal. A default rule is closed if it does not have any free occurrences of variables, and a default theory is closed if all of its rules are closed. The maximally consistent sets that can follow from a default theory are called extensions. An extension can be thought of informally as one way of “filling in the gaps about the world.” Formally, an extension E of a closed set of wffs T is defined as the fixed-point of an operator F, where I’(T) is the smallest set satisfying: e w 5 WI e I’(T) is deductively closed, o for each default d E D, if the prerequisite is in I’(T), and T does not contain the negations of any of the justifications, then the conclusion is in I’(T). Stillman 795 Since the operator I’ is not necessarily monotonic, a default theory may not have any extensions. Normal default theories do not suffer from this, however (see [Reiter 1980]), and always have at least one extension. In [Reiter 19801 an alternative characterization of the extensions of a default theory is provided and proved equivalent to that given above: Theorem 1 (Reiter) Let E be a closed set of w$s, and let A = (D, W) be a closed default theory. Define l&J = w andfori20 E i+l = Th(E$J ( a :P1,...Prn ED 1 wherz ct E Ea and +1,...7&B,E I Then E is an extension for A ifl E=U Ei a’=0 Properties of Default Theories There are several important properties that may hold for a default theory. Given a default theory (D, W), perhaps together with a literal q, one might want to determine the following about its extensions: Existence Does there exist any extension of (D, W)? Membership Does there exist an extension of (D, W) that contains q? (This is called goal-directed reason- ing by Kautz and Selman.) Entailment Does every extension of (D, W) contain q? (This is closely related to skeptical reasoning, where a literal is believed if and only if it is included in all extensions.) The Polynomial Hierarchy and CE Complete Problems There exist many problems for which it is unknown whether or not they can be solved efficiently (in time polynomial in the length of their input). Structural complexity theory is concerned with categorizing such problems into equivalence classes, and with determin- ing relationships between such classes. The most well known class studied in structural complexity theory is NP; hundreds of commons problems in many areas of study have been identified as being NP-complete or NP-hard (see [Garey and Johnson 19791 for a good introduction to this topic). Much of the research in structural complexity theory is directed toward pro- viding insight into what is perhaps the most famous problem in computer science: ‘What is the effect of nondeterminism on computational complexity?’ This includes the famous P = NP question. There exist decision problems that seem to be harder than NP-complete problems, but which we have been unable to prove to be so. The polynomial hierarchy, formally defined in [Stockmeyer I9761 (see also [Garey and Johnson 19791 for an introduction) is a way of classifying some of these NP-hard decision problems by considering the ramifications of providing time- bounded Turing machines with oracles. Thus the poly- nomial hierarchy is a subrecursive analog of the Kleene arithmetical hierarchy [Rogers 19671, in which deter- ministic polynomial time is substituted for recursive time, and nondeterministic polynomial time is substi- tuted for recursively enumerable time. The classes that comprise the polynomial hierarchy are defined as the set {E”,,II;, A; : k 2 0}, where G = I-I; = A: = P; and for k 1 0, xi+1 = NP(q.), J--G+, = co - NP(Cp,), A:+1 = P(q). (Note in particular that Cy = NP, and that II; = co - NP.) It is helpful to have a canonical complete problem for each of these classes as a starting point in proving completeness of new problems. This role is played be the problem SATISFIABILITY in the theory of NP- completeness. In [Meyer,Stockmeyer 19731, a class of problems BI, is defined for k > 0, and it is shown that & is complete for Ei. An instance of Bk consists of: Input: A Boolean formula F over sets of variables xl&, . . .Xk. Question: Does 3&, vx2, . . .&kXk [f@=l,&, . . .xk)] = l? where &k is 3 if k is odd, V if k is even. Main esults We are now ready to present the main results of this paper: Theorem 2 The Extension Membership Problem for propositional default theories is X:-complete. Proof: (sketch) To show that the Extension Mem- bership Problem (EMP) is X:-hard we reduce B2 to EMP as follows: Let -- m\J(Y)Ef(x > VI be an instance of Ba, where (x) and (Y) each denote a set of boolean variables. The instance of EMP we will construct has as its default theory A = (D, W) with 796 Representation and Reasoning: Tractability W = 4, and the set of default @es D is composed of the following. For each ~i E X we introduce a new variable ei and two default rules: : xi A ei : -xi A ei Xi A ei -Xi A ei Having done this, we introduce a new variable Q and add the default rule -- elAe2A...e,.i;;,Af(X,Y):q Q This completes the construction. Intuitively, the new variables ei act as enablers (the use of these variables is not strictly necessary, but their presence aids in un- derstanding the proof), in that they indicate that some truth valuehas been chosen for the variable xi, and the variable Q is used to indicate that the formula is a tau- tology given the choice of assignment to x. Suppose the instance is in &, i.e., there does exist an assignment to those variables in x such that for -- all assignments to the variables in 7, f(X, Y) = 1. To construct an extension E that contains the literal Q, we choose an arbitrary assignment a to the variables in X such that f(o(y), 7) = 1. For each xi E Z, if cx(Xi) = 1, include in E the consequences of applying the default rule : xi A e; xi A ei Similarly, if if f2(xi) = 0, include in E the consequences of applying the default rule z -Xi A ed 1x3 Aei Once this is done, each of the variables ei is true. Fur- thermore, by hypothesis, f(a(x),Y) = 1. Thus the default rule -- elAe;!A...e,Af(X,Y):q Q is applicable, allowing us to include Q in E. It is easy to see that the result of applying the specified defaults produces an extension that contains 4. Conversely, if there exists an extension E containing 4, we maintain that the instance of B2 is satisfiable. The only way that q can be included in E is if the default rule -- el Ae2 A...e, A$ X,Y) : q Q has been applied. Thus each of the ei variables is also in E, sign+ing that for each xi either xc or lxi is in E, and f(X, Y) is provable in E. Since E can impose no restrictions on Y, this signifies that once the choice of a truth value for each x8: via application of default rules has been madeLit is the case that for all values -- of the variables in Y, f(X, Y) is true. It is now a trivial matter to construct a satisfying assignment for the instance of B2. Next we must prove that EMP is in C:. Infor- mally, given an arbitrary propositional default theory A = (D, IV) we will use the iVP machine to guess the sequence of defaults to be applied in constructing an extension E that contains q, then use the NP oracle to verify that the chosen defaults are applicable, that no other default rules can be applied (E is an extension), and that Q E E. (It should be noted that we do not need to actually create the extension; it suffices to aug- ment W with the consequences of the chosen default rules, and verify that (a) no other default rules can be applied, and (b) th e set of propositional sentences thus created is consistent. The actual size of the ex- tension may be exponential in the size of the original presentation since it contains the logical closure of a set of propositional sentences, and thus we cannot af- ford to express it explicitly.) It is also important to the correctness of the proof that each default rule will be chosen at most once in deriving an extension, thus guaranteeing that the guess provided by the oracle is polynomial in length with respect to the instance. This follows from the lemma below: Lemrraa 3 Let E be any extension of a propositional default theory A = (D, W), with IDi = n. Then, using the description of extensions presented in Theorem 1, E = U;., Ei, i.e., at most n steps are needed to produce the extension. Proof of the lemma is straightforward and omitted. More formally, we can appl from [Meyer,Stockmeyer 1973 . si the following theorem, (The theorem applies to Zi for arbitrary Ic. We have specialized it to the case where k: = 2 for simplicity.) Theorem 4 (Stockmeyer-Meyer) Let 0 be a finite alphabet and A c @+.A E Zt i$ there is a polynomial p(n), an alphabet I’, and a ternary relation R E P such that for all x E O+, x E A iff $Nz R(x, y, z) where y, exceeding x range over all words in I’+ of length not P(lXI)- Applying this theorem is somewhat involved and is omitted. •I Several related theorems and corollaries follow straightforwardly: Theorem 5 The Extension Entailment Problem for propositional default theories is II:-complete. Corollary 6 The Extension Membership Problem for normal propositional default theories is C;-complete. Corollary 7 The Extension Entailment Problem for normal propositional default theories is @-complete. Although it is known [Reiter 1980; Etherington 19881 that the extension existence problem is trivial for nor- mal default theories, the next theorem demonstrates that relaxing this assumption introduces intractability. Specifically, we show that Stillman 797 Theorem 8 The Extension Existence Problem for propositional default theories is C;-complete. Proof: (sketch) The construction is similar to that provided in the proof of Theorem 2 above, with the following default rules added: :qA-a Q ’ :aAyc a > Arguments similar to those given in the proof of The- orem 2 above demonstrate that if the instance of B2 is true then there is a derivation that proceeds as in Theorem 2 that concludes Q by applying the default rule A- el Ae2 A...e,F, Af(X,Y): q Q within that paradigm. An extended version of this pa- per describes our results in this area. Similar results have been derived independently by Georg Gottlob [Gottlob 19921 recently; he has looked at default logics, NML, autoepistemic logic, and the closely related logic N, defined in [Marek and Truszczynski 19901. Ruten- berg [Rutenberg 19911 has derived related results for ATMS [deKleer 19861. Researchers have just begun to classify the structural complexity of these problems. The characterization we have established thus far will serve as an aid in understanding the relationships that exist between various formalizations of nonmonotonic reasoning and in understanding the computational re- lationships that exist between nonmonotonic reasoning and other problems in computer science. This may not be an extension, however, in that one can add a to the extension by applying the second default rule above. One can verify that this is an extension. If the inst ante of B2 is false, however, then the lit- erals in the set {q, a, b} can only be included by apply- ing the default rules above (the key observation here is that there is no other support for Q, nor for la). One can verify that these three rules are circular, thus there does not exist any extension. This shows that the Estension Existence Problem is Cg-hard. Demonstrating inclusion in Cs is quite similar to Theorem 2, and is omitted here for the sake of brevity. cl We have the following: Corollary 9 The Extension Existence Problem for semi-normal propositional default theories is C;- complete. Conclusions In this paper, we have characterized the complex- ity of several fundamental problems in propositional default logics, showing that even restricted versions of the extension existence problem are C; complete, and that such restrictions of the extension member- ship and entailment problems are C: complete and Hg complete respectively, This work, taken to ether with that presented in [Kautz and Selman 1989 !I and [Still- man 1990b], provides an extensive categorization of the complexity of propositional default logics. One of the most interesting areas for further re- search is in understanding the ramifications of these results on known formalisms for nonmonotonic reason- ing. The results described above can be reproduced for the closely related questions of derivability, argua- bility, and fixed-point existence within propositional NML[McDermott and Doyle 19801. This strength- ens results presented in [Niemela 19891, who showed membership, but left open questions of completeness. Furthermore, given the efficient intertranslatability be- tween the extensions of propositional default lo& and strongly grounded extensions in autoepistem‘Ilc logic [Konolige 19881, similar results can be shown to hold Acknowledgements The author is indebted to Dan Rosenkrantz for helpful discussions concerning this work, and to the referees for several insightful comments. References de Kleer, J., 1986. An Assumption-Based Truth- Maintenance System. Artificial Intelligence, 29:241- 288. Etherington, D.W. 1987. Formalizing Non-Monotonic Reasoning Systems. Artificial Intelligence 31:41-85. Etherington, D.W. 1988. Reasoning with Incomplete Information. Pitman, London. Garey, M.R., and Johnson, D.S. 1979. Computers and Intractability. W.H. Freeman, New York. Ginsberg, M.L., editor. 1987. Readings in Nonmono- tonic Reasoning. Morgan Kaufman, Los Altos, CA, 1987. Gottlob, Georg 1992. Complexity Results for Non- monotonic Logics. Presented at the Fourth Interna- tional Workshop on Nonmonotonic Reasoning, May 1992. Kautz, H.A., and Selman, B. 1989. Hard problems for simple default logics. In Proceedings of the First International Conference on Principles of Knowledge Representation and Reasoning, 189-197, Toronto, On- tario, Canada. Konolige, K., 1988. On the Relation between Default and Autoepistemic Logic. Artificial Intelligence, 35. Marek, ‘Mr., and Truszczynski, M., 1990. Modal logic for default reasoning. Annals of Mathematics and Ar- tificial Intelligence, 1~275-302. McCarthy, J. 1977. Epistemological problems of ar- tificial intelligence. In Proceedings of the Fifth Inter- national Joint Conference on Artificial Intelligence, 1038-1044. International Joint Conferences on Artifi- cial Intelligence, Inc. McCarthy, J. 1986. Applications of circumscription to formalizing commonsense knowledge. Artificial In- telligence, 28:89-166. 798 Representation and Reasoning: Tractability McDermott, D., and Doyle, J. 1980. Non-monotonic logic I. Artificial Intelligence, 13:41-72. Minsky, M. 1975. A framework for representing knowledge. In Patrick Winston, editor, The Psy- chology of Computer Vision, pages 211-277. McGraw- Hill, New York. Moore, R.C. 1983. Semantical considerations on nonmonotonic logic. In Proceedings of the Eighth International Joint Conference on Artificial Intelli- gence, 272-279, Karlsruhe, West Germany, Interna- tional Joint Conferences on Artificial Intelligence, Inc. Niemela, I. 1989. On the complexity of the decision problem in propositional nonmonotonic logic. In Pro- ceedings of the 2nd Workshop on Computer Science Logic, Duisburg, FRG, Oct. 1988, Springer-Verlag LNCS Volume 385. Poole, D.L. 1986. Default reasoning and diagnosis as theory formation. Technical Report CS-86-08, Dept. of Computer Science, University of Waterloo. Reiter, R. 1980. A logic for default reasoning. Artifi- cial Intelligence, 13:81-132. Rogers, H. 1967. Theory of Recursive Functions and Eflective Computability. MIT Press, Cambridge. Rutenberg, V., 1991. Complexity Classification in Truth Maintenance Systems. In Proceedings of STACS 91, Springer-Verlag LNCS 240. Stillman, J.P. 1990a. The Complexity of Horn The- ories with Normal Unary Defaults. In Proceedings of the 8th Canadian Artificial Intelligence Confer- ence, (CSCSI/SCEIO-90), Ottawa, Canada, 23-25 May, 1990, published by Morgan-Kaufman Publishers (also available as a General Electric Research and De- velopment Center Technical Report, #89CRD243). Stillman, J.P. 1990b. It’s Not My Default: The Com- plexity of Membership Problems in Restricted Propo- sitional Default Logics. In Proceedings of the 8th National Conference on Artificial Intelligence (AAAI- 90), 29 July - 3 August 1990, AAAI Press/ MIT Press, Menlo Park. Stockmeyer, L. 1976. “The polynomial-time hierar- chy,” Theoretical Computer Science 3, l-22. Stockmeyer, L., and Meyer,A., 1973. Word problems requiring exponential time: preliminary report. In Proceedings of the Sixth IEEE Symposium on Switch- ing and Automata Theory l-9. Touretzky, D.S. 1986. The Mathematics of Inheri- tance Systems. Pitman, London. St illman 799 | 1992 | 134 |
1,203 | National Library of Medicine BuiMing 38A National Institutes of Health Bethesda, MD 20894 harris@ncbi.nlm.nih.gov d application of an procedure for the datastream, given a rnary snmilarity judgments between regions in the stream. Our method is effective on very large databases, and tolerates the presence of noise in the similarity judgements and in the extents of similar regions. We applied this method to the problem of finding the sequence-level building blocks of proteins. After verifying the effectiveuess of the clusterer by testing it on synthetic protein data with known evolutionary history, we applied the method to a large protein sequence database (a datastream of more than IO7 elements) and found about 10,000 protein sequence classes. The motifs defined by these classes are of biological interest, and have the pote to supplement or replace the existing manual otation of protein sequence databases. There are many ch nges ii3 applying machine learning methods to large, re -world problems. IIn this paper, we report on our exploratiou of a dassification problem several orders of magnitude larger than any other application of unsupervised we are aware. Existing m impractical for this problem, prtm ately (Schank, 1991) or because they are g large numbers of irrelevant features (Almuallim 8t Dietterich, 1991). We developed a simple and efficient heuristic classification method, and demonstrated its effectiveness on synthetic data. We also report on the application of the method to a natural dataset containing more than 10’ elements. Our motivating problem involves finding motifs, or repeating patterns, in protein sequences. Proteins are composed of amino acids, bonded together Enearly into a protein sequence. Proteins fold into three IlSiOIMl structures, fully coded for in the protein sequ which determine their biochemical functions. There are 20 different naturally occurring amino acids, and sequences contain more than 6000 amino ace of possible proteins is therefore very or more than 107**** Evolution has to identify the domains that constitute them. Several features of protein building blocks must be lcept ia mind when desi g machine le * g methods for them. First, the building blocks are not of ze. 0f the hundreds of putative domains identified by biologists, see e.g. (Bairoch, 1991), the amino acids long, and the longest contains no acids. Second, domains e deletions and sub acid sequence of each domain occur leading to significant variation in instances of any particular domain. * has an underlying ch , the databases we must search to find these Efforts related to the Human Genome Project and other biological research have large numbers of pr Protein on Resource or PIR, arker, George, Hunt, & Garavelli, 1991), the largest the individual protein arris, Hunter, and States 837 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. sequence databases, includes more than 33,000 protein sequences containing a total of more than 10 million amino acids. These databases are growing exponentially, with a doubling time of just over a year. Our goal is to use as much as possible of this information to identify domains that have been used repeatedly throughout evolution. Given the explosive growth of protein sequence data, automation of as much of the analysis of this data as possible has become an imperative. The amount of existing protein data is already too large to be analyzed by hand: only 10% of the sequences in PIR have their domains annotated, and manual annotation is falling further and further behind. Our approach is a step toward the automatic annotation of massive sequence databases. In a nutshell, the machine learning problem we address is how to efficiently segment and classify a datastream, given the ability to identify variable length regions of similar content. We have developed a method that uses a binary similarity metric to extract objects from large, unsegmented and noisy datastreams and performs automatic unsupervised classification on those objects. This method, although tailored to our specific application, has potential applications in other domains. For example, a language learner faces a similar problem in interpreting a noisy stream of auditory data to identify and classify the different types of sounds. Existing Classificati Finding roaches for Traditional ML classification methods such as conceptual clustering, e.g. (Fisher, 1987); Bayesian classification, e.g. (Cheeseman, et al., 1988); and self-organizing feature maps, e.g. (Kohonen, 1988) are unsuitable for application to this problem for several reasons. First, these methods require the data to be presented in the form of discrete objects with an explicit list of attributes, and demand a real-valued distance function that can measure the degree of “similarity” between any pair of objects. Protein domains are of varying length, and can occur at varying offsets within different proteins. The representational requirements of existing methods cannot be met naturally and in a reasonable amount of space with this kind of data. For example, mappings of sequences to bitstrings or fixed length feature vectors often use a sliding window down the sequences to make fixed length vectors. This method increases the number of objects to nearly the number of amino acids in the data set, which is too large (over 10,000,000 in PIR alone) to be practical for our application. Second, none of these methods are efficient enough to handle a genuinely large dataset. At best, these methods make on the order of one comparison between each pair of objects. These classification methods therefore require at least O(n*) time to classify n objects. Even using an efficient partial matcher to identify similar pairs iu the PIR database generates nearly 2 million objects (hits). If each bit had to be compared against every other hit, and each comparison took only 10 microseconds, the n* comparisons would take at least 4x10’ seconds, or 463 days. Incremental approaches do not ameliorate the difficulty with this megaclassification problem. Our HHS (Hunter, Harris, States) clustering algorithm works in two stages. Starting with fragmented regions provided by a binary comparison tool, it assembles fragments into objects and then groups together similar objects by their extent of overlap. The tool we used for obtaining similarity judgements for protein sequences was BLAST (Altschul, et al, 1990), a program for rapidly finding statistically significant partial matches between pairs of protein sequences. BLAST uses amino acid mutation scores for approximate string- matching. It directly approximates the results that would be obtained by a dynamic programming algorithm, but is more than an order of magnitude faster. Given a pair of protein sequences, BLAST identifies variable length stretches that have greater than chance similarity. These pairs of similar subsequences are called hits.. Each hit consists of a string of amino acids from the “query” protein and the corresponding same-length string from the “subject” protein (Figure 1). The length of a BLAST hit depends on the extent of similarity between the two sequences being compared and on a sensitivity/specificity tradeoff that can be set at runtime. The clustering task involves trying to build the transitive closure of the similarity judgments that BEAST makes. There are several complications that make this task difficult. BLAST searching is probabilistic and therefore noisy. It can miss regions of similarity, and it can fragment a single region of similarity into multiple hits. Also, BLAST handles approximate matches in the content of the sequences, but it requires exact registration for matching, and its matches have fixed extent. We need to be able to build groups that have approximately matching extents, and where the registration between regions of similarity is not perfect. The HHS clustering algorithm does this by first assembling the BLAST hits and then clustering the assembled hits. Protein 1 Protein 2 BLAST Query Subject Figure 1: BLAST is applied to two protein sequences that have homologous regions, resulting in a hit. 838 Scaling Up -- r-x .x---4 ks 'i 1 '. ‘-. I -- A b~~‘-~-~‘-.-~l ASSEMBLE DON’T ASSEMBLE Figure 2: Protein 1 has a gap in its region of homology with Protein 2. Since BLAST can’t handle gaps, it finds two separate hits. BLAST hits separated by a small gap probably come from the same domain and should be assembled. BLAST hits with a large gap between them probably come from different domains, and should not be assembled. Hit Assembly There are well known biological mechanisms that create differences in registration and extent of similar regions. As proteins evolve, their sequences are gradually transformed by biological events. The most common events include point mutations, where one amino acid is substituted with another; insertions, where a new amino acid is inserted into the sequence; and deletions, where an amino acid is deleted from a sequence. (Insertions and deletions are referred to as “indels.“) Substitutions and indels can cause two proteins that derive from a common ancestor to gradually diverge from each other. The best alignment between two homologous (i.e. evolutionarily related, and therefore similar) sequences may contain gaps in one or both sequences. BLAST is unable to insert gaps into its alignments. If it encounters non-mate g portions in the sequences being compared, it generally breaks the hit. A new hit is likely to start after the indel, with a different offset between the query and subject portions. This means that hits do not necessarily represent complete domains; they may include only pieces of a domain. Even strongly homologous regions might show up as many separate BLAST hits. The first stage of the HHS algorithm is to assemble the potentially fragmented raw BLAST hits into continuous (possibly gapped) regions of local similarity, which we call “assembled hits.” Not all hits that involve a single pair of proteins should be assembled. A large gap between two hits indicates a lapse in homology (Figure 2). The probability that BLAST would fail to pick up such a long stretch of homologous sequence is low, so a long gap between two hits provides evidence that the two hits belong to separate domains and should not be assembled The hit assembly procedure works by finding all pairs of BLAST hits that share both query and subject protein and have a sufficiently small gap between both the two queries and the two subjects. This procedure is fast, since the maximum number of hits between any pair of proteins is relatively small. The program that parses the BLAST output sorts the hits by query and subject, so the hits that share both query and subject proteins are adjacent to each other in the list of hits. The longest permissible gap between two BLAST hits that qualify for assembly can be calculated by considering BLAST’s sensitivity. BLAST is very good at detecting long stretches of homology; the shorter a homologous region, the less certain it is to be detected by BLAST. We can calculate the probability that BLAST will pick up a region of similarity of any specified length. To attain a 90% probability of detection, a homologous region must be at least 57 amino acids long. We choose this gap length as our cutoff when assembling hits. Clustering Assembled Assembling the BLAST hits has addressed one of the sources of noise in the similarity judgments: the fragmentation of essentially unitary regions of simihuity. We now want to group these assembled hits into equivalence classes, forming the transitive closure of the pairwise similarity judgements. In the process, we must address the problem of variation in the extents of regions of similarity. When assigning assembled hits to the same group, the extents of the hits a.~ not required to match exactly. There are two reasons for this. First, the endpoints of a region of similarity identified by BLAST are much less certain than the detection of the region as a whole. Second, evolution may change the ends of a particular domain more rapidly than the central portion, both because ends may play a less important functional role, and because they have to adapt portions of the protein that they abut. Hits that should be grouped together may therefore have “ragged ends,” and be of somewhat different lengths. hits establish equality relations across proteins; and subject portions of a hit are nonrandomly However, the ragged ends issue makes it problematic to determine whether two regions from the in are in fact the same, and, therefore, whether include those two regions should be placed in the same group. Building equivalence classes is thus a matter of determining when two hits contain references to the same region. For two hits to share a reference to a particular region, that region must be within a particular protein, and the overlap between hits must be adequate. We only need to Harris, Hunter, and States 839 Subsequence 1 Subsequence 2 (4 Overlap = 50 110 0 130 110-50 60 -=- = 130-O 130 03 Left overhang: Right overhang: L -1 I I I I 50 20 (0 Figure 3: The proportion of overlap between two subsequences from the same protein (A) is the length of the overlap divided by the extended length of the two subsequences (B). The nonoverlapping portions are the overhangs (C). compare hits that share a protein; call such hits “neighbors.” The neighbor list for each pair of proteins is generally quite short, because a given pair of proteins is unlikely to hit each other in many separate places, and even if it does, many of those BLAST hits will have already been assembled. Comparing a hit only to other hits in its neighbor list rather than to all the other hits saves a lot of time. When deciding whether two hits refer to the same region, we must consider both overlap and overhang (see Figure 3). The overlap component is the length of the overlapping portion of two sequences divided by the extended length of the sequences. To be eligible for grouping, two sequences must have a sufficient proportion of overlap. The outcome of the clustering is not highly sensitive to the exact value of this parameter; we set it to 40%. We also require that the unmatched segment at either end (the overhang) must not exceed the maximum allowable length. This overhang is like a gap that f& at the end of a hit, so we can use same analysis of BLAST’s sensitivity we used in determining the maximum gap length to set the maximum overhang to 57 amino acids. Sorting helps us avoid some unnecessary comparisons when checking overlap between pairs of hits, which in the worst case takes O(neighbors*) time per protein. Each neighbor list is ordered by query start position and query end position. If we get to a neighbor whose start position is greater than the end position of the current hit, we know that no neighbor later in the list will have any overlap with the current bit, so we can cut short our comparisons and move on to the next hit on the list (Figure 4). The clusterer initially assigns each assembled hit to a separate group. Whenever two hits that have a protein in common are found to have sufficient overlap, the groups that they belong to are checked to see if they should be merged We have investigated several criteria for deciding when to merge groups. The simplest approach is to merge two groups whenever they are found to share a single sufficiently overlapping region. There is a pitfall in this approach: a single false hit might cause the merging of two groups that don’t belong together. Fortunately, this type of error turns out to be extremely rare; we set the stringency for BLAST high enough to make false positives very unlikely. We also tried requiring groups to share k overlapping hits in order to qualify for merging, where k is a constant that can be set at run time. However, tests on synthetic data showed that the best setting fork is one; higher values decrease the accuracy of the clustering. In conceptual classification, each object is assigned to exactly one group. In Bayesian classification, objects can be assigned to more than one group as a result of uncertainty, but the underlying finite mixture model assumes that each object intrinsically belongs to a single group. Our method for classifying datastreams allows for some segments not to be classified at all, and for others to be assigned to more than one group. Regions that aren’t classified are those that were unique in the database and thus didn’t generate any BLAST hits. Regions that get assigned to multiple classes are those that appear in families of multiple domain proteins. For example, if two related proteins each have an A domain and a B domain, BLAST will find hits between the A portions, the B portions, and the whole A!3 region. Because the hits have very different extents, the subsequence representing the A domain will appear in both the A group and the AB group. In this problem, a correctly assigned region may genuinely belong to more than one class. Current hit Neig,hbors Figure 4: When checking for overlap between the current hit and its neighbors, we need not check any neighbor that starts after the end of the current hit (dotted line). 840 Scaling Up Tess the Clusterer In order to validate our clustering approach, we developed a program to simulate protein evolution and provide us with sets of artificial proteins of known evolutionary history.. The evolver starts with a set of user-selected domains and mutates them for the desired number of generations. These synthetic proteins can then be used to test how effective our clustering method is at recognizing domains and grouping them appropriately. We found that after 50 generations of evolution, the clusterer could still recognize domains with 96% accuracy. For more details on the protein evolutionary simulator, see (Hunter, Harris, and States, 1992). Describing Groups In contrast with many classification tasks, the classes or groups formed by our program do not have obvious definitions: each group is a set of particular protein subsequences that have been found to resemble each other. Such a list can, by itself, be useful to a biologist. However, in order to use the classification for automated database annotation, we must create comprehensible descriptions of each class. Ideally, we would like to find a natural language description of each group. We are attempting to construct such descriptions by summarizing the names of the proteins in the group, and including additional information about the size of the group and whether the hits in the group contain whole proteins or portions of proteins. Large groups containing hits that are portions of proteins are likely to be protein building blocks. Large groups that contain whole proteins are more akin to RJR superfamilies. Our preliminary group-namer selects words or phrases from the protein names in a group that appear significantly more frequently than in the database as a whole. It would also be desirable to be able to describe a group by a consensus sequence or afrequency matrix. showing the frequency of each amino acid at each position along the set of sequences in a group. A consensus sequence can be derived from a frequency matrix by taking the most common amino acid at each position. Unfortunately, calculating the frequency matrix for a group is equivalent to the problem of finding the best multiple alignment among a set of sequences. For n sequences of average length k, finding the best multiple alignment takes time O(lm) (Carillo & Lipman, 1988). Tools exist for finding multiple alignments; these could potentially be used to align the sequences in a group so that the frequency matrix could be determined. Alternatively, it might be possible to use programs that describe groups of related protein sequences, such as (Smith 8t Smith, 1990) and (Hen&off & Henikoff, 1991), to find patterns describing the groups obtained by our clusterer. Representing classes with consensus sequences or frequency matrices would make it easier to incrementally classify new proteins. A new protein could be divided into chunks that fit into the already determined classes. This would enable a biologist to look for domains in a newly sequenced protein. Once the clusterer reached the desired level of performance on the synthetic data, we tried it on several real protein databases, the largest of which is the Non-Redundant Database (NRDB). NRDB is a collection of all of the protein sequences from several large databases (RJR, SwissProt, translated Get&&, and NCBI Backbone) with the duplicates removed. It includes 61,810 proteins comprising over 5 million ammo acids. lnsulln blndlng raglon Proteins with Domain 1: A05274 Ins receptor precursor (version 1) - Human A05275 Insulin receptor pmxxsor (version 2) - Human Proteins with Domain 2: A05274 Insulin receptor precursor (version 1) - Human A05275 Insulin receptor precursor (version 2) - Human GQm Epidermal growth factor receptor - Fruit fly CQHUE Epidermal growth factor receptor precursor TVRTNU Kinase-related transforming protein (neu) Proteins with Domain 3: A05274 Insulin receptor precursor (version 1) - Human A05275 IInsulin receptor precursor (version 2) - Human A25228 Cell division control protein 7 - Yeast A28163 Protein kinase C delta - Rat EC-number 2.7.1. A29597 K&se-related transforming protein - Blowfly A29872 Phosphorylase kinase gamma (catalytic) chain and 140 others.... Figure 5: Two views of the insulin receptor. (A) is the traditional biological view: This protein binds insulin and signals the cell that insulin has been bound by turning on its kinase. (B) shows the view from the induced classification: One domain (1) spans the entire extent of the protein and contains complete insulin receptors. A second domain (2) defines a region which is associated with ligand binding. The third domain (3) defines the kinase domain. Domains (2) and (3) also appear in proteins other than insulin meptors. Harris, Hunter, and States 841 The most time-consuming part of the whole clustering procedure is the BLAST run (which took 800 CPIJ hours on Sun Spare 2 and Silicon Graphics 2D series workstations). On an IBM 3090 supercomputer, our clustering algorithm took 100 minutes to process and sort the 6.6 million BLAST hits generated by NRDB, 10 minutes to assemble the hits, and 46 minutes to cluster the assembled hits. The resulting classification has 12,548 groups- Many of our induced domains correlate well with domains or protein families as traditionally defined by the biological community. For example, all 447 globin proteins in the PIR database are classified into a single induced domain, and no extraneous proteins are placed in this class. The whole insulin receptor appears as a single domain in our classification with two subset domains which define the ligand binding and the kinase domain of the receptor (Figure 5). Manual definitions of patterns or signatures have also been used to define motifs, for example in the Prosite knowledge base (Bairoch, 1991). Our analysis demonstrates several limitations of that approach. Some of the domains that our program found, such as globins and immunoglobulins, cannot be represented by Prosite-like patterns. Second, the manually defined patterns have limited sensitivity and specificity. For example, only 77% of kinases actually match the Prosite kinase signature. Finally, building and maintaining patterns manually is extremely time-consuming. As a result, many recently described domains of considerable biological interest. are not yet available as patterns. Our automatic method solves each of these problems. Our clustering method is applicable, with minimal modification, to nucleic acid databases. Nucleic acid motifs might include gene families (coding regions), signals such as promoters or splice sites, or repeated elements. We have successfully run our program on nucleic acid databases, but the results have not yet been analyzed. The HHS approach could also be applied to other problems that involve classifying objects from noisy unsegmented datastreams, such as the problem of understanding continuous speech. A digitized stream representing time-varying sounds would be equivalent to a sequence of amino acids. The goal of the language learner is to find repeating patterns or regularities. This involves a phase analogous to hit assembly, in which noise is filtered out and phonemes are pieced together, and a clustering phase in which patterns are recognized despite differences in detail and duration. We have demonstrated an efficient method (HHS) for unsupervised classification from a very large, unsegmented datastreams using probabilistic binary similarity judgements. We applied HHS to the problem of discovering protein building blocks from sequence databases. Tests on synthetic protein data showed that our method correctly clusters even relatively distantly related sequences. We then ran our clustering program on the 6.6 million BLAST hits generated by the 5 million amino acid NRDB protein sequence database, which took under three hours of supercomputer time. The induced classes correspond well to those found by biologists. Our program may provide a way of addressing the daunting problem of annotation of rapidly growing protein sequence databases. Moreover, our method is general enough to be applicable to other massive classification tasks. Almuallim, H., & Dietterich, T. 1991. Learning with many irrelevant features. In Ninth National Conference on Artificial Intelligence, 547-552. Anaheim, CA: AAAI Press. Altschul, S. F., Gish, W., Miller, Mr., Myers, E. W., & Lipman, D. J. 1990. A Basic Local Alignment Search Tool. Journal of Molecular Biology 215:403-410. Bairoch, A. 1991. Prosite database 7.10. Geneva, Switzerland. Barker, W. C., George, D. G., Hunt, L. T., & Garavelli, J. S. 1991. The PIR Protein Sequence Database. Nucleic Acids Research 19 (Suppl):2231-36. Berg, J. M. 1990. Zinc finger domains: Hypotheses and current knowledge. Annual Review of Biophysics and Biophysical Chemistry 19:405-42 1. Carillo, H., & Lipman, D. 1988. The multiple sequence alignment problem in biology. SIAM J. Appl. Math 48: 1073. Cheeseman, P., Self, WI., Kelly, J., Taylor, W., Freeman, D., & Stutz, J. 1988. Bayesian classification. In Proceedings of AAAI $8, Saint Paul, Minnesota: Fisher, D. 1987. Knowledge acquisition via incremental conceptual clustering. Machine Learning 2: 139-172. Henikoff, S., & Henikoff, J.G. 1991. Automated assembly of protein blocks for database searching. Nucleic Acids Research 19(23):6565-6572. Hunter, L., Harris, N., & States, D. 1992. Efficient classification of massive, unsegmented datastreams. To appear at Ninth International Machine Learning Conference, July 1992, Aberdeen, Scotland. Kohonen, T. 1988. Self Organization and Associative Memory . Berlin: Springer-Verlag. Schank, R. C. 1991. Where’s the AI? AI Magazine 12(4):38-49. Smith, RF., & Smith, T.F. 1990. Automatic generation of primary sequence patterns from sets of related protein sequences. Proc. Natl. Acad. Sci 87:118-122. 842 Scaling Up | 1992 | 14 |
1,204 | idea Shimazu+ Software Engineering Laboratory* C&C Information Technology Research Laboratories+ NEC Corporation Z- 11-5 Shibaura, Minato, Tokyo, 108 Japan This paper reports a case study on a large-scale and corporate-wide case-based system. Unlike most papers for the AAAI conference, which exclusively focus on algorithms and models ex- ecuted on computer systems, this paper heavily involves organizational activities and structures as a part of algorithms in the system. It is our claim that successful corporate-wide deploy- ment of the case-base system must involve or- ganizational efforts as a part of an algorithmic loop in the system in a broad sense. We have es- tablished a corporate-wide case acquisition al- gorithm, which is performed by persons, and developed the SQUAD Software Quality Con- trol Advisor system, which facilitates sharing and spreading of experiences corporate-wide. The major findings were that the key for the success is not necessary in complex and sophis- ticated AI theories, in fact, we use very simple algorithms, but the integration of mechanisms and algorithms executed by machines and per- sons involved. P ltroduction This paper reports a case study on a large-scale and corporate-wide case-based system. Unlike most papers for the AAAI conference which, exclusively focus on al- gorithms and models executed on computer systems, this paper heavily involves methodologies and organizational constraints, which arise in the course of knowledge-based system development and deployment. The central claims which we wish to deliver are: (1) the successful corporate-wide deployment of the AI sys- tem must involve organizational efforts, as a part of the algorithmic loop in the system in a broad-sense, and (2) the system should be flexible and robust enough to cope with incremental and changing nature of the corporate structure and activities. In essence, this idea dictates the significance of the integration of algorithms for the organizational activities and the machine executable pro- gram. The underlying thrust involved in the proposed ap- proach is the idea that the case-based system should be viewed as a part of a corporate-wide, or department- wide, strategic information system, which enhances shar- ing of experience. Traditionally, CBR systems have been NEC Corporation 4 l- 1 Miyazaki, Miyamae, Kawasaki, 216 Japan developed as a kind of expert system, which provide so- lution to the problem [Riesbeck and Schank, 19891. Of course, this is still a viable approach. However, the or- ganizational and economic impacts would be far greater, when the case-based system was integrated as a part of a corporate-wide information system. It would be used as a new media, which facilitates spreading of knowledge and experiences. The development of the large-scale and corporate-wide case-based system should involve a carefully planned case-acquisition process. Many research efforts have fo- cused on the CBR systems or theories, and none of them have addressed the problem of how to acquire cases. In addition, many CBR systems have been built on domains which have already been carefully investigated - do- main experts already know what features are involved, which features are important, and what values fill each feature. It is our observation that, for many possible CBR application domains, even experts do not have a well-organized idea of what factors are involved. Because of the fact that many real-world application domains are not well knowledge engineered and that the corporate activities changes over time, the CBR system should be able to cope with dynamically changing case structures, cases with missing and inaccurate information, and other constraints which arise from the real-world deployment. As an example of the corporate-wide case-based system development efforts, this paper reports the SQUAD Software Quality Control Advisor system and the corporate-wide case acquisition process for building the case-base for the SQUAD system. The task domain is Sofiware Quality Control (S WQC)[Mizuno, 19901. We are conducting a corporate-wide knowledge acquisition process, which involves an estimated annual labor in- vestment of over 200 person-years, which provides over 3,000 cases per year. Concurrent to the case acquisition efforts, the SQUAD system has been deployed, which meets various constraints which arise from real-world de- velopment and deployment. This is perhaps the first attempt to employ a case- based system as a part of corporate-wide information system with corporate-wide knowledge acquisition pro- cess. Due to the fact that the system was actually de- ployed and the case acquisition process was introduced corporate-wide, we are not able to conduct controlled experiments to verify some of the hypotheses involved, Although we recognize the importance of scientific and controlled data collection, such attempts would costs bil- Kitano, et al. 843 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. lions of dollars, as the proposed process involves around 150,000 employees. Instead, this paper will describe rea- sons for decision we made in this project. Scientific inves- tigation on the efficacy of each approach would be made possible when we taking cognizance of the numbers of such attempts in various domains, with various organi- zational constraints. It is our wish that this report will serve as the basis for discussions on how large-scale and corporate-wide case-based systems should be developed and deployed. 2 SWQC as a Corporate-Wide Knowledge Acquisition Process 2.1 Software Quality Control Quality control is an essential element in modern indus- trial society. tive edge, High quality products provide competi- and assure a higher reliability. Software is by no means an exception. Recent establishment of the ISO-9000-3 standard [ISO, 19901 clearly urges the soft- ware industry to attain a high-level of software qual- ity control. One of the major a proaches to im the product quality is the QC Quality Control Q roving P activ- ity, which assumes voluntary participation of all employ- ees forming small groups in each factory and depart- ment. Particularly, QC activities have been successfully introduced in many Japanese firms. QC activities have been carried out in virtually every stage in manufactur- ing processes. Very comprehensive and voluminous re- ports on improvement in quality and productivity have been filed. In 1981, we established a company-wide or- ganizational structure to enforce the Software Quality Control (SWQC). Traditionally, QC activities have been viewed as an important process involving worker par- ticipation as well as a substantial means of continuous improvement in production systems. Each reported case provides analysis of problems under the status quo, pos- sible causes, counter-measures taken, and effects of the counter-measures. Each case is reported as a two-page length paper and a form in which to fill major issues in the case. 2.2 Establishing the Knowledge Engineering Process We made a radical departure from the traditional view of the QC activity. We consider the QC activity as a company-wide knowledge acquisition process. Thus, we established a knowledge engineering loop for the SWQC domain. Figure 1 illustrates organizations involved and the process flow. Each SWQC activity group in the en- tire NEC group submit their case reports. The review committee reviews each case. The review result classi- fies reported cases into 1% of Best Cases, 10% of Selected Cases, and 90% of Pool Cases. Best cases and selected cases are chosen, based on its quality of analysis, sig- nificance of the effects, and universality of the problem. They are considered to be the norm for the case report. Naturally, these cases are given toppriority in case-base building, and serve as the basis of the domain model and the case format definition. The SWQC activity was started out in 1981 with no substantial case format. The rough case format and the case report category were introduced as the SWQC grew into the corporate-wide activity. Recently, we have be- gun to provide specific feature sets to all participating groups, so that they would help making standard case re- port format and improve analysis quality. This cycle is a stepwise cycle. It starts out from a vague standard and provides only top-level features. As knowledge engineer- ing progresses, more detailed feature sets are provided. This is because we start to understand the domain model and what features should be identified. Due to the turn around cycle, up-grading the case format would require one year at minimum. This work is in the end of the fourth cycle in this loop. It is only after the third cycle that the minimum features could be identified, so that it was possible to build a crude case-base. The feature set will be further sophisticated, as this cycle progresses. Thus, the absolute requirement for the case-based sys- tem on this domain is that the incremental modification to the case-base, particularly the indexing features, can be accomplished with minimum cost, if not cost free. In order to facilitate the stable flow of high quality cases which covers nearly all software domains, several organizational measures have been introduced: Filtering: When the knowledge acquisition was scaled up to a corporate-wide level, some case filtering scheme would be necessary to select high quality cases, from among all cases with varying analysis quality. This is essential in establishing the norm for the high quality case. Incentive System: This is a management issue for the corporate-wide knowledge acquisition. A top-down control has been established regarding the activity framework, awarding, symposium, conventions, and other incentive systems. Also, a bottom-up con- trol of operational procedures and system critique scheme has been introduced, in order to maintain involvement of the participants. Feedback: All the best cases and the selected cases have been compiled in a book form, and distributed to all involved sections. Distributed Control: Each department hosts inter- nal competitions, so that only qualified cases are reported to the company-wide review committee. This avoids overloading the review committee. As a result of these measures, the number of acquired cases has increased significantly, and has reached the sat- uration point. Currently, over 3,000 cases of quality and productivity improvement measures have been reported every year. Over 20,000 cases have already been accu- mulated, as of December 1991 (Figure 2). The main point of this part of the project is that the algorithm for case acquisition is essentially executed by people, not by machine, thus requires organizational sup ports and sustaining efforts for years. 3 The SQUAD System 3.1 System Requirements As is always the case, the real-world deployment im- poses various constraints, some of which require a ma- jor compromise in straightforward implementation of the laboratory-level models. The SWQC domain is not an exception. Some of the major requirements are: 844 Scaling Up Case Acquisition Case Filtering Knowledge Engineering Best Cases /“’ (1% of all cases) \ SQUAD f Case- Base All NEC Group (150,000 employee) Figure 1: SWQC Knowledge Engineering Loop Increase in Acquired Cases 13.00 1200 11.00 1o.w 9.w 8.00 7.00 6.00 5.00 4.00 3.00 2.00 1.00 0.00 Ytpr 82 84 86 88 90 Figure 2: Number of Acquired Cases Response time: The system should provide fastest re- sponse time, to be a part of a corporate informa- tion system. When the central server approach is taken in the deployment, the potential size of the user group is over 150,000. Although the use of massively parallel machines would guarantee quick retrieval (see [Kolodner and Thau, 19881 and [Cook, 1991]), budget constraints precluded this option. Low Development Cost: The development cost should be as low as possible. The bottom line is that the case-base can be built and maintained by one or two full-time employee. Robustness: The system should allow missing infor- mation, inaccurate description, and other erroneous data entries. It is not possible, both from economic and organizational reasons, to force every QC ac- tivity group to report cases with a uniform level of accuracy and specificity. It is also not possible for the case-base builder to frequently inquire about de- tails of the reported case. Flexibility: The system should allow a maximum level of flexibility to the user, in specifying cues for case retrieval. Figure 3: SQUAD System Incremental modification: The system should allow an incremental modification of index features for the case-base. As actual products and systems change, the domain itself changes. It is not economically and logistically feasible to carry out exhaustive knowl- edge engineering, to identify a well-formed index structure over 20,000 cases with 3,000 additions ev- ery year. 3.2 System Architecture The SQUAD system is a case-based software quality con- trol advisor system. In its first development phase, the SQUAD system does not involve an adaptation phase. It only has a case retrieval phase. The main reasons are (1) retrieval of cases alone suffice for most advising tasks, and I 2) the domain is so complicated and ill-formed, that any orm of adaptation scheme would require significant development costs and the system behavior would be un- stable, as ourself do not fully understand the nature of the domain. The screen of the SQUAD system is shown in Figure 3. Coping with Case- ase Modification and Flexi- ble uery The critical issues in the SQUAD system are (1 ability to cope with case-base modification after 7 each knowledge engineering cycle, (2) robustness against missing information, and (3) ability to cope with varying query specification level. The SQUAD system deals with these requirements Kitano, et al. 845 EE 0002 :E 0005 ET 0002 0003 :E 0006 No. Fl Fll F12 1.00 0.50 0.50 1.00 0.50 0.50 0.00 0.00 0.00 1.00 1.00 0.00 1.00 0.00 1.00 Figure 4: Case-base modification after each cycle within a consistent and uniform model. Figure 4 il- lustrates how the case-base, represented in a flat table, can be modified after each knowledge engineering cy- cle. Initially, only feature Fl is defined in the case-base. Cases with this feature (Case 0001 and 0002) are as- signed with 1.0, and a case without this feature (Case 0003) is assigned 0.0. In the second cycle, feature Fl was found to have subcategories: Fll and F12. Due to the lack of specific information for Cases 0001 and 0002, values for these cases on F 11 and F 12 are assigned as 0.5 for each new feature. In case three subcategories were found, the value would be 0.33. Basically, we as- sume equi-probability distribution regarding which sub- category may be correct. When information is available, either 1.00 or 0.00 will be assigned. Assuming that F12 was found to have a further subcategory in the third cycle, e.g. Fl21 and Fi22 in Figure 4, the same equi- probability rule is applied for cases, which do not have this information detail. This is a simple mechanism, but it was proven to be effective in coping with changing case structures. Thus, it enables the SQUAD system to cope with incremental modification of case-base in each cycle, and maintains reasonably accurate retrieval, even with missing informat ion. This mechanism also allows flexible and consistent case retrieval. Each case can be described at any speci- ficity level, and the users can specify a query cue at any level, So far, CBR retrieval methods have been assuming that the query, or the cue case, is speci- fied and represented with the same level of abstraction with cases in the case-base. For example, if a feature Tools-Used is specified at the level of specific name for the tool, the assumption is that the cue case is also specified at this level. Similarity would be com- puted, using the domain heuristics or statistical means. However, the assumption that the user can specify fea- tures at the same level of abstraction with the case-base is too strong to be implemented in the practical sys- tem. For example, users tend to specify kinds of tools (such as Spec-Acquisition-CASE, Programming-CASE, or Version-Control-Tool), rather than specific name for tools (such as ProSpec, SEA/I, or Life-Line). By the same token, cases collected do not necessarily con- tain information at the same abstraction level. This is illustrated in Figure 5. The figure shows an example of user query selection and two cases. Typical Figure 5: Examples of Feature Selections by User query is specific for some of the features, but not for other features. However, for example, the query should return Case-l with highest similarity results, because only difference in between Query and Case-l is the speci- ficity of features selected. Actually, all selected items in Query and Case-l are subsumed in other selected fea- tures, in one way or the other. For example, the query specifies Fl, F222, and other features. Case-l and Case-2 match Fl, because the fea- ture Fi value for Case-l and Case-2 is 1.0 (See Figure 4). On the other hand, F222 would have a low similar- ity score, because only partial information is provides for Case-l and Case-2. Actually, the similarity score between F222 and F22 is 0.5. F222 and F21 have a sim- ilarity score 0.0, because Case-2 has F21 feature which makes the F22 value to 0.0. In this example, assuming equal weight distribution, the similarity score for Case-l and Case-2, for the query, are 0.305 and 0.167, respec- t ively. Retrieving Cases from Sparse and Dynamically Changing Salient atures The case indexing is very sparse and salient features change in each retrieval session. With regards to the sparseness, on an average, only 3.4 out of 75 features (as of the third cycle) are specified for indexing cases. This is due to (1) broad coverage for the SWQC domain, and (2) the use of flat table case-base representation. Since the coverage do- main is so broad, some features, relevant to cases in one of the subdomains, are not relevant to cases in other do- mains. Also, the use of flat table type representation, a constraint imposed from practical consideration’, drasti- cally increased the sparseness, If a conventional similar- ity metric, used in many CBR systems, is applied which assumes a dense indexing of features, retrieval would be inaccurate. At the same time, the goal of retrieval changes in each session. Thus, it is not possible for us to improve quality and speed of retrieval with a sophis- ticated indexing scheme as seen in [Hammond, 19861, [Hunter, 19881, and [Kolodner, 19841. Let X, Y, and A be a feature vector for the query, a feature vector for the case in consideration, and a weight matrix. The conven- tional similarity metric is computed by: ‘To be more sp ecific, we need to develop case-base using the Lotus l-2-3 type spreadsheet interface. The case-base entry should be made by simply specifying items which can be identified from the reported case. 846 Scaling Up Sim(X, Y) = Xtdiag( &)Y II x III1 y II However, this method involves matching many irrele- vant features, thus significantly degrading retrieval accu- racy. Instead of using this similarity equation, an equa- tion is defined which ignores irrelevant features for each retrieval. The proposed alternative formula is: Simx(X, Y) = Sim(Cx(X), Cx(Y)) = ww~~“d~> II cxw IIII WY) II = XTW&)Y II x IIXII y Ilx II y Ilx = d c YI i &t.Xi#O This problem is illustrated using a simple example. Let us assume that a query X, a case-base which con- tains cases Y and Z, and a weight matrix A, as shown below: A=[;] x+] Y=[;] z+] When appling a traditional similarity measure, sim- ilarities between X and Y (Sim(X,Y)), and X and Z (Sim(X,Z)) would be computed as: Sin( x, Y) SiTta( x, Z) = = = $1 [l . 1 z 1 1 01 1 z 0 1 I[ 1 1 4 1 0 1 I[ 1 0 6 1 Similarities for the same example, using the proposed metric would be: Simx(X, Y) = 1 01 0 111 1 1 fi l 1 = a Simx(X, 8) = $1 1 O1 [” * J[n] 1 = a In essence, this method ignores features which are considered to be irrelevant. Cain et. al. [Cain et. Figure 6: Retrieval Performance al:, 19911 also proposed a similarity metric, which ap- plied less weight to irrelevant features. However, their scheme heavily relies upon the domain knowledge used in Explanation-Based Learning (EBL). Their method can- not be applied to the SWQC domain, because such do- main knowledge is extremely difficult to obtain, and rel- evant features dynamically change at each query. One other approach is to keep track of the past solution [Veloso and Carbonell, 19911. However, it was not pos- sible to take this approach because no such traces were available. The proposed method provides faster response time and higher retrieval accuracy. The response times have been measured for various numbers of cue features, and various sizes of case-bases. Figure 6 shows case retrieval time for the traditional method, which checks matching for all features, and the new method. In case of the traditional model, the retrieval time is almost constant, regardless of the number of cue features specified by the user. As our analysis discovered, the average number of cue features for each retrieval was around 3. Thus, the method significantly curtailed the computing cost - l/10 of the traditional method. Also, the retrieval accuracy, with subjective judgement by users, records almost 20% improvement over the traditional method. This coincides with the results reported by [Cain et. al., 19911. Figure 8 illustrate the difference in distance be- tween cases in the case-base (only 30 cases are used in this figure to make it readable . The left hand side is the cluster created by the tra d itional similarity metric and the right hand side is the cluster created by the new method. Clearly, the new method provides fine-grain distance distinction between cases, which has been sig- nified by the improved accuracy. Mitano, et al. 847 Performance Comparison 6.30 - 6.00 - 5.50 - 5.00 - 4.50 - 4.w - 3.50 - 3.w - 250 - 200 - 1.50 - 1.00 - 0.50 - 0.00 i- 103 Figure 7: Scalability 15 2 2 if 20 4 12 26 11 22 29 24 17 23 1 '6" 16 5 7 14 27 "2 : 25 :; 21 Figure 8: Cluster of Cases Figure 9: A Process of Organizational Knowledge Cre- ation 4 Discussions 4.1 Organizational Knowledge Great ion Perhaps one of the most advanced organization theo- ries in the area of business administration is a theory of organizational knowledge creations proposed by Non- aka [Nonaka, 19901 [N onaka, 19911. He assumes the exis- tence of tacit knowledge and articulated knowledge. He observes that organizational knowledge spreads through the process of (1) socialization, (2) articulation, (3) com- bination, and (4) internalization (Figure 9). He argues that the articulation and the internalization are a deci- sive step for improving the organizational knowledge. The SQUAD system and SWQC activity can be a powerful scheme for organizational knowledge creation. First, the SWQC activity encourages a certain level of articulation of knowledge, since all participants are sup- posed to submit reports and forms, which describe their improvement activities. Although not all of such reports are articulation of tacit knowledge, there are some re- ports which articulated their tacit knowledge. Social- ization process takes place, while they are working as We have discovered that the knowledge ac- &r!%& through the group activity is much more effi- cient and effective than individual activity by experts. Although we do not discount the value of well trained experts, it is logistically not feasible to rely on ex- perts on software quality control and productivity in the corporate-wide scale. In addition, we consider that each member in each department is a tacit expert in the field, as they are the most experienced persons in the specific task. Next, the knowledge engineering conducted by the SWQC department further augments the level of artic- ulation, and combination took place,, when the domain ontology and models were built. Finally, the SQUAD system allows efficient access to the SWQC cases, which enhances internalization of articulated knowledge in dif- ferent divisions. It should be noted that our knowledge source is case-bases, not rule-bases. Thus, we are much closer to tacit knowledge than abstract rules. Of course, whether such a knowledge transfer process actually took place has not been made clear. We only knew that the project have made substantial contribu- tion for software quality and productivity, which is esti- mated to worth over a hundred million dollars per year. Since effects of such improvements accumulate as the process continues, the net effects are expected to be over multi-billion dollars. In addition, the proposed approach is consistent with the modern organizational theory. By identifying the proposed scheme in the perspective of the organizational theory, it is possible to logically deduce the direction which should be pursued. 4.2 The Next Move In Nonaka’s model, however, the knowledge was trans- mitted to different divisions only in the form of articu- lated knowledge. We wish to go one step further, past the Nonaka’s model, by providing a multi-media user interface to possibly transmit a part of tacit knowledge. The multi-media SQUAD not only provides user-friendly access to the SWQC case, but also enables us to record discussions and talks by the person involved. Often, the essential part of the experience is hard to formal- ize. By using the multi-media interface, the users can obtain both formal and informal information. 848 Scaling Up One other aspect of improvement is the combination process. We wish to provide not only the domain on- tology and models, but also domain heuristics. Acquisi- tion of useful heuristics is a major subject in data-base mining. This is particularly important for case-based systems, which do not provide explicit rules themselves. Once we start to acquire rules, the process of organi- zational knowledge creation will be carried out with a full spectrum of knowledge - rules, cases, and informal knowledge. 4.3 CASE by Case The idea of sharing of experience applies to other soft- ware development domains. One of the most promis- ing approaches which we propose is the CASE by Case paradigm, in which Computer-Aided Software Engineer- ing (CASE) tools support case retrieval and certain adaptation levels. In essence, this approach uses past cases of software design and programs during the devel- opment of the new software system. There have been several attempts to reuse programs and design results in the past. However, most of such projects have failed, due to inflexibility in the retrieval specification, diffi- culties in defining the design representation, etc. Our experience in SQUAD system demonstrates that a well- designed case retrieval mechanism, togather with orga- nizational efforts, would allow an entire system to grow. Thus, an incomplete representation scheme could be the starting point (although complete representation is obvi- ously preferred), due to the similarity search capability of the CBR paradigm. Introduction of the CBR idea of- fers a new opportunity to establish a practical and cost effective software engineering paradigm. 5 Conclusion This paper has described an approach for building a large-scale and corporate-wide case-based system, as ex- emplified in the SWQC and the SQUAD software qual- ity control advisor system. The main thesis of this pa- per is that the model, or algorithms, for the organi- zational activities and the machine executable program should be integrated in order to establish a large-scale and corporate-wide AI system. Since such an attempt would be fairly substantial for any corporate system, the project should involve a carefully organized knowledge acquisition process and a CBR system which is flexible enough to cope with organizational and other constraints inherent in real-world deployment. It took us almost a decade to establish a corporate- wide process of case acquisition, which provides a stable flow of up-to-date cases of software quality control and productivity improvement. The current statistics indi- cates that this process offers quality and productivity improvement over a hundred million dollars each year. The net effects could easily exceed multi-billion dollars. We believe that this is one of the most substantial knowl- edge engineering projects ever conducted. The proposed model also presents substantial consis- tency with one of the most advanced organization the- ories, called the theory of organizational knowledge cre- ation. This is, by no means coincidence, since we are striving toward a new paradigm of corporate informa- tion system, which enables sharing of experience, which is the central dogma in the proposed paradigm. The most important findings drawn from our experi- ence is that integration of the organizational process and the flexible system design to cope with the changing cor- porate activity and constraints, exhibits maximum util- ity in improving the entire production process, which has significant economic impacts. The algorithm of the SQUAD system is very simpl. However, the point we wish to make is the fact that this is the best approach for the incremental deployment of the corporate-wide system which matches changing corporate structure and task domains. Acknowledgements The authors would like to thank Dr. Mizuno, Dr. Pujino, Mr. Saya, and Mr. Kai for continuous support for this project. More than that, however, we would like to thank all NEC employee who have engaged in this project for a decade, and continue to participate in this endeavor in one way or the other. eferences [Cain et. al., 19911 Cain, T., Pazzani, M., and Silver- stein, G., “Using Domain Knowledge to Influence Sim- ilarity Judgement,” Workshop, 1991. Proc. of Case-Based Reasoning [Cook, 19911 Cook, D., “The Base Selection Task in ana- logical Planning,” Proc. of IJCAI-91, 1991. [Hammond, 19861 Hammond, K., Case-Based Planning: An Integrated Theory of Planning, Learning, and Memory, Ph. D. Thesis, Yale University, 1986. [Hunter, 19881 Hunter, L., The Use and Discovery of Paradigm Cases, Ph. D. Thesis, Yale University, 1988. [ISO, 19901 ISO, Guidelines for the application of IS0 9001 to the development, supply and maintenance of software, DIS 9000-3, ISO, 1990. [Kolodner, 19841 Kolodner, J., Retrieval and Organiza- tional Strategies in Conceptual Memory: A Computer ModeZ, Lawrence Erlbaum Assoc., 1984. [Kolodner and Thau, 19883 Kolodner, J. and Thau, R., Design and Implementation of a Case Memory, GIT- ICS-88/34, Georgia Institute of Technology, 1988. [Mizuno, 19901 Mizuno, Y. (Ed.), Total Quality ControE for Software, Nikka-giren, 1990 (in Japanese). [Nonaka, 19911 Nonaka, I., “The Knowledge-Creating Company,” Harvard Business Review, Nov.-Dec., 1991. [Nonaka, 19901 Nonaka, I., A Theory of Organiza- tional Knowledge Creation, Nikkei, Tokyo, 1990. (in Japanese) [Riesbeck and Schank, 19891 Riesbeck, C. and Schank, R., Inside Case-Based Reasoning, Lawrence Erlbaum Associates, 1989. [Veloso and Carbonell,, 19911 Veloso, M. and Carbonell, J-1 “Variable-Precrslon Case Retrieval in Analogical Problem Solving,” Workshop, 1991. Proc. of Case- Based Reasoning Kitano, et al. 849 | 1992 | 15 |
1,205 | 1. Wafer Scale Integration for Massively Parallel ory-Based Reasoning* Hiroaki Kitano and Moritoshi Yasunagat Center for Machine Translation Carnegie Mellon University Pittsburgh, PA 15213 U.S.A. hiroaki@cs.cmu.edu, myasunagOcs.cmu.edu Abstract In this paper, we describe a desi n of wafer- scale integration for massively para lel memory- P based reasoning ( W SI-MBR) . W SI-MBR at- tains about 2 million parallelism on a single 8 inch wafer using the state-of-the-art fabri- cation technologies. While WSI-MBR is spe- cialized to memory-based reasoning, which is one of the mainstream approachs in massively parallel artificial intelligence research, the level of parallelism attained far surpasses any exist- ing massively parallel hardware. Combination of memory array and analog weight computing circuits enable us to attain super high-density implement ation with nanoseconds order infer- ence time. Simulation results indicates that inherent robustness of the memory-based rea- soning paradigm overcomes the possible preci- sion degradation and fabrication defects in the wafer-scale integration. Also, the WSI-MBR provides a compact (desk-top size) massively parallel computing environment. Introduction The memory-based reasoning (MBR) is one of the main- stay approach in massively parallel artificial intelligence research [Kitano et. al., 19911 [Waltz, 19901. The basic notion of MBR is to place memory as a foundation of in- telligence. Instead of having abstract and piecewise rules to make inferences by chaining them, MBR simply stores large numbers of actual cases to carry out similarity- matching in order to make inferences from the most similar cases in the past. MBR has been succesfully ap plied to English pronounciation task [Stanfill and Waltz, 19861, census data classification[Creecy et. al., 19901, protein structure prediction[Zhang et. al., 19881, ma- chine translation[Kitano and Kiguchi, 1991][Sumita and *This research was carried out as a program of the Inter- national Consortium for Massively Parallel Advanced Com- puting Technologies (IMPACT). ‘This author is on leave from Hitachi Central Research Laboratory. Iida, 1991][S a t o and Nagao, 19901, natural language un- derstanding [Kitano and Higuchi, 19911 and other data- intensive domains. MBR, however, requires massively parallel hardware such as the CM-2 connection machine [Thinking Ma- chines Corporation, 19891. The problems of current mas- sively parallel machines are (1) economically expensive, (2) huge physical size, and (3) parallelism does not suf- fice for some large-scale applications. For example, the CM-2 is a multi-million dollar machine requires install- ment in the machine room and attains only 64K paral- lelism (VPR = 1) with l-bit processing elements. Given the fact that many serious MBR applications (national statistics, crime investigation, tax records, virtual real- ity, etc) require more than a few million parallelism with reasonably low economic expense, current massively par- allel machines do not suffice for further penetration of the MBR and other massively parallel AI approachs for real-world applications. The solution which we will offer in this paper is to develop a wafer-scale integration for memory-based rea- soning (WSI-MBR). The design and performance simu- lation indicates that we can attain about 2 million paral- lelism on a single 8 inch wafer with 0.3 micro fabrication technologies which would be available for commercial production around year 1995. WSI-MBR will provide nearly 200 million parallelism when the wafer stack clus- ter method was established, which is the state-of-the-art VLSI fabrication and assembly technologies[McDonald et. al., 19911. The inference speed is on the order of nanoseconds by the use of a hybrid analog/digital com- puting circuits. The implication of this technology is significant. It means that we will be able to built desk- top or even lap-top massively parallel MBR systems. The WSI-MBR is a run-time component. All data and weight are pre-computed on massively parallel machines such as the Connection Machine. Computed weights and data are loaded onto WSI-MBR to perform inferencing. In the large-scale memory-based reasoning system, the content of the memory-base is expected to be fairly sta- ble so that up-date of weights and data will not be neces- sary for a certain duration of the operation. Separation of the main computing system and delivery (or run-time) system is justified even from a commercial point of view. 850 Scaling Up From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Since massively parallel machines would be quite large and expensive, development of run-time systems with extremely cheap and compact size would substantially push down cost-effectiveness trade-off point. easoning aradigm Memory-Based Reasoning is a reasoning method based on a large set of examples. Stanfill and Waltz wrote that [Stanfill and Waltz, 19861: We consider the phenomenon of reasoning from memories of specific episodes, how- ever, to be the foundation of an intelligent system, rather than an adjunct to some other reasoning method. This approach counters the traditional AI paradigm which places rules as the foundation of intelligence. It is not the scope of this paper to discuss benefits and limita- tions of the MBR itself. However, it should be noted that there are some sucessful reports and some commer- cial systems that have already been deployed using the MBR paradigm (English word pronounciation [Stanfill and Waltz, 19861, Prediction of protein structure [Zhang et. al., 19881, the Census classification [Creecy et. al., 19901, and others.) The MBR method requires a large set of cases. Each case consists of a set of features and a goal. Features represent problems need to be solved, and a goal repre- sents a solution in the case. In the MBRtalk example, each case has seven fields for characters of the word, and goal fields which represents a correct pronounciation and stress (Table 1). Statistical approach is used to determine significance of each feature in making correct reasoning. While rela- tively simple and homogenious operations are performed on each datum, the memory-based reasoning is particu- larly suitable for SIMD-type massively parallel machines such as the Connection Machine. A similarity measure will determine the weight in which each feature affects the result of reasoning. In case of the MBRtalk task, the measure is computed based on the following equations: Since benefits of the MBR over other reasoning paradigms, such as rule-based systems and neural net- works, have been discussed in [Stanfill and Waltz, 19861, we simply point out merits which motivated us for the development of the WSI-MBR. One of the computa- tional advantages of the MBR is that it allows data- parallel computing because the similarity of each record can be computed independently from other records. It is also a very attractive scheme for direct hardware imple- mentation due to its simplicity and potential robustness against noise and faults. 3. Wafer-Scale Integration Wafer-Scale Integration (WSI) is the state-of-the-art VLSI fabrication technology (See Proc. of Interna- tional Conference on Wafer Scale Integration for recent progress in WSI. Also, [Cavil1 et. al., 19911 provides a good overview of the area.), and has been applied to various domains such as neural networks [Yasunaga et. al., 19911. It fabricates one large VLSI-based system on a wafer as opposed to conventional VLSI production which fabricates over 100 chips from one wafer. The advantage of WSI is in its size (high integration level), performance, cost, and reliability: Size: WSI is compact because nearly all circuits neces- sary for the system are fabricated on a single wafer. Performance: WSI has substantial performance ad- vantage because it minimizes wiring length. Cost: WSI is cost effective because it minimize expen- sive assembly line. Reliability: WSI is reliable because it eliminates the ponding process which is the major cause of circuit malfunctions. However, there is one big problem in WSI fabrication: defects. In the conventional VLSI fabrication, one wafer consists of over 100 chips. Generally, we have certain percentages of defective chips. Traditionally, chips with defects have been simply discarded and the chips without defects have been used. To estimate the faults in the chip, we use the Seeds model[Seeds, 19671: - ID[f = PAI = VII)2 ID[f = P-f11 w! is a weight of feature f on the field g. d; is a value difference metric. Such metric differ in each task, but they are similar enough to be hardwired in VLSI chips. Please refer [Stanfill and Waltz, 19861 and other papers for details of the MBR approach. where Y is a yield of the wafer, D is the fault density which is, in the fabrication process we are going to use, about 1 fault per cm2, and A is the chip area. This is a reasonable rate for the current fabrication process. How- ever, even this level of fault would cause fatal problems for such an attempt to build an entire IBM 370 on one wafer. Unless sophisticated defects control mechanisms and robust circuits are used, a single defect collaspes an entire operation. But, redundant circuits diminish the benefits of the WSI. This trade-off has not been solved. In the WSI-MBR, we take a radically different ap preach. We accept a certain rate of defects. Rather Kitano and Yasunaga 851 Fields Input Fields Output (Goal) Rec. No. n-3 n-2 n-l n n+l n+2 n+3 Pron. Stress 00001 - - - f * 1 e f + 00002 - - f i i e - A 1 Table 1: A part of the memory-base for MBRtalk task than trying to control defects, we propose to use WSI for implementing a more robust computing mechanism so that a small amount of defects does not seriously af- fect the overall operation of the chip. We believe that MBR is ideal for this solution because it does not rely upon any single data unit. The essence of the MBR is a bulk data set which gives stable reasoning capability. 4. WSI-MBR WSI-MBR is a digital/analog hybrid WSI specialized for memory-based reasoning. We decide to employ a digi- tal/analog hybrid approach in order to increase paral- lelism and performance. First, in the digital computing circuit, a floating point processor part takes up most of chip area. On the other hand, the analog circuit requires only a fraction of area for implementation of equivalent floating point opera- tion circuits. The digital approach has an advantage in its flexibility since various sequences of floating point operations can be programmed. The analog approach in inflexible since it hardwires a computing sequence. However, in the WSI-MBR, the sequence of computa- tion is already well-defined so that no re-programming is required (See [Mead, 19891 for one other use of analog VLSI for neural networks). Use of a less area-demanding analog approach provides two major advantages over the digital approach: (1) increased parallelism, and (2) speed updue to relaxed-wiring constraints (critical paths and wire width). P.ise %CL IC~Addl (Chip Lmetion Signal) Figure 1: Wafer Floor Layout Chip Selection Circuit Second, the analog circuits provide a drastic speed up over digital circuits. It is well known that analog circuits have a natural advantage in speed of computation. This is also true in our model as we will discuss it later. Figure 1 shows a wafer floor layout of the WSI-MBR. Figure 2 shows a chip selection circuit. One wafer con- tains 56 memory chips, 7 data-bus chips (denoted as B), and a serial/parallel converter chips (denoted as C). This layout is for a five inch wafer. The chip selection circuits consists of signal lines which identifies and selects a chip on the wafer which the data should be send and accessed. In the figure, CL denotes the chip location signal (3 bits column, 3 bits row, 1 bit left/right selection) which iden- tifies a chip on the wafer. L/R, CC, and RC are address of the chip to be selected. Each memory chip consists of 4K MBR memory cells. One MBR memory cell loads one record and goal data, and carries out MBR operations. Figure 3 shows a i/R CL m CL ix CL $ 4 Figure 2: Chip Selection Circuit 852 Scaling Up Figure 3: Schematic of the Memory Cell of WSI-MBR schematic of the MBR memory cell. In this design, the cell has 256 bits of digital memory (24 8-bits fields and a 64bits goal memory), comparator, analog multipliers, a sense amplifier, and an Output Enable control circuits. The input data will be broadcast through the data-bus to all MBR memory cells. In each MBR memory cell, each field value of the input data is compared with the value of the corresponding field. This comparison is done at each comparator CMP in parallel. Figure 4 shows a schematic of memory bit cells and a comparator. When the value is the same, CMP holds a high voltage output which will be multipled by a corresponding weight using one transistor multiplier. Results of each multiplication are added and produces a similarity value of the record (called the score voltage SV) on the MBR memory cell. Now we want to take out the value of the goal mem- ory of similar MBR memory cells. We use a threshold relaxing technique to retrieve the goal value in the order of the similarity rank. Initially a high voltage is given to the threshold voltage line (denoted as TV in Figure 3). This voltage of the TV line is compared with the score voltage using a sense amplifier (denoted as SA in Figure 3). The host computer, or the controller, controls the TV level through a digital-analog converter. The controller decreases the TV level until any of the MBR memory cell has higher score voltage. When the score voltage is higher than the threshold voltage, then a S/R latch is set which indicate that the goal memory of the MBR memory cell should be retrieved. The Output Enable control circuit (OE control circuit) runs serial through- out the single chip to allow asynchrous scanning. This .means that a single fault in any part of the OE con- trol circuit hampers an entire chip function (but, not an entire wafer). In order to improve the reliability, the OE Control circuit is built as triple redundancy circuit. Thus, unless all three OE control circuits in the same memory-cell cause faults (this would be an extremely low probability), the chip function would be maintained. Therefore, the WSI-MBR carries out asynchronous data fetching to attain fast data retrieval, but maintains high reliability. Figure 4: Schematic of Memory Bit Cells and Compara- tor One MBR memory cell uses about 4,000 transistors: 1,024 for memory bit cells, 1,920 for comparators, 16 for analog multipliers, and about 1,000 for the output enable controllers and other circuits such as the bus driver. 5. Performance Simulation We have developed a simulator for WSI-MBR. The sim- ulator is written in C language and run on UNIX-based workstation and on the CM-2 connection machine. The simulator can model factors critical to WSI designing such as (1) noise-levels with various noise distributions, (2) defects, and (3) run-time faults. In this paper, we use Nettalk (MBRtalk in this case) task as an example of the performance data we have ob- tained. Although we have investigated the performance of WSI-MBR with several other tasks, we use MBRtalk for this paper because it is one of the most widely un- derstood tasks. The MBRtalk system was implemented on the WSI-MBR simulator. Experiments were car- ried out for the MBRtalk system with the memory-base size of 908 (6506), 5908 (43166), 10908 (80394), and 19908 (146940) words (records). Also, we used a full set Nettalk data. 5.1. Parallelism WSI-MBR attains a strikingly high level of parallelism. When the WSI-MBR design in the previous section is implemented on the 5-inch wafer using 0.5 p CMOS fab- rication technology, with the standard yield rate, the WSI-MBR provides 240K records each of which carry out completely data-parallel MBR operation. This is at- tained by the high density fabrication technology which can implement 16M transistors in the memory cell area, and by the compact design of the MBR memory cell which requires only 4,000 transistors per a cell. Tech- Kitano and Yasunaga 853 Word accuracy vs. Noise level Letter accuracy vs. Noise level Pacmtcoxeu Percrnl consct lo.w ! I I I I I ’ NohcLcvd 0.w 20.w 40.00 60.00 80.00 100.00 Figure 5: Word accuracy and noise Figure 6: Letter accuracy and noise nologies assumed in this design (5-inch wafer and 0.5 ~1 CMOS fabrication) are already available in selected chip producers. Within 4 to 5 years, the fabrication technolo- gies will provide for us 8 inch wafers and 0.3 pm fabrica- tion technologies[IEDM-91, 19911. The WSI-MBR will be able to offer about 2 million parallelism on a sin- gle wafer. Table 2 shows the number of memory-cells on a single wafer using various fabrication technologies. The 1995 technology is an estimation from current trends of VLSI technologies (See [Gelsinger et. al., 19891 and [Dally, 19911 f or rle es rmations of VLSI technologies b * f t’ in future. [IEDM-91, 1991) is one other good source of information.). 5.2. Precision: Robustness against noise One of the problems of the analog VLSI is the preci- sion in computing. Inherently, some noise undermines computing precision. We have simulated the noise fac- tor of the analog part of our circuit. We have confirmed that the anticipated noise level will not affect the accu- racy of reasoning in the memory-based reasoning system. There are several noise sources such as shot noise, ther- mal noise, l/f noise, burst noise, and avalanche noise. Also, there are some device-level deviation at produc- tion process of the wafer. Empirically, the total level of noise is known to be at the level of f30%. In our ex- periments, we varied noise levels starting from fO% to &loo% which essentially deviates similarity weight ma- trices. The distribution of the noise is uniform within the given range. Results are shown in Figure 5 and in Figure 6. We have discovered that the WSI-MBR is extremely robust against noise. There is only a minor degrada- tion even with the ItlOO% noise with the full-data set MBRtalk. The MBR seems to be fairly practical on 92.00 90.00 88.00 86.00 84.00 82.00 80.00 78.00 16.00 74.00 72.00 N&c I.cvcl 0.00 20.00 40.00 60.00 80.00 1oo.w analog VLSI since expected maximum level of noise is about f30% which does not cause any significant degra- dation in accuracy even with the small memory-base. It should be noted that the WSI-MBR is more robust against noise than NETtalk since NETtalk’s letter accu- racy degrades to under 80% with 100% noise[Sejnowski and Rosenberg, 19871 whereas MBRtalk on WSI-MBR maintains over 80% of letter accuracy with the memory- base larger than 45,000 records. 5.3. Fault Tolerance: Robustness against defects WSI inherently involves faults. As we have discussed previously, there is virtually no means to eliminate or control the defects. While we recognize this problem, we have carried out a set of simulations to identify the robustness of MBR against device level defects. The re- sult is shown in Figure 7. The accuracy degrades almost linearly. Since the expected run-time faults would be far less than l.O%, we see no problem on the accuracy degra- dation of MBR due to the run-time faults. By the same token, the result can be applied to the production de- fects. Since the expected defects density in our fabrica- tion process is about 0.5 defect/cm2, the total expected number of defects on one wafer is about 50 (assuming 100 chips/wafer and 1 cm2 chips). This is only 0.02% of the 240K memory-cells. This implies that we don’t even have to test each memory-cell to ensure the expected level of accuracy. 5.4. Speed: Beyond Tera FLOPS Computing time of the WSI-MBR is mostly a sum of the maximum transmission delay in the wafer, memory bit cell access time, and gate delay for multiplier and other 854 Scaling Up Year for Design rule MBR Memory Chips per Wafer MBR Memory Production (v) Cell per Chip 5 inch 8 inch Cell per Wafer 1989 0.8 1K 60 - 60K 1992 0.5 4K 60 120 240K - 480K 1995 0.3 16K 120 1920K Table 2: Number of MBR Memory Cells on a Single Wafer Accuracy vs. Run-time faults -Y loo.w 95.00 90.00 85.00 80.00 75.00 70.00 65.00 60.00 55.00 SO.00 45.00 40.00 3J.W 30.00 25.w Fmlt Ram 0.00 10.00 20.00 30.00 40.00 Figure 7: Fault rate and accuracy circuits. Table 3 shows an estimated computin time of the WSI-MBR using various fabrication techno ogies. 7 We use a data pipe-line in each data-bus chip to mitigate transmission delay. Using the 1995 technology, we can attain 66 nanosec- onds MBR operation and 2 million parallelism at the record level. Considering that each record contains 24 fields each of which requires weight computing, total arithematic operation for one MBR operation would be equivalent to 70 Tera FLOPS in digital computers. In the worst case, the data fetch may create a bottleneck slowing down the entire cycle to 1 milli-second. How- ever, even in this case, the total computing power on a single WSI-MBR attains 0.48 Tera FLOPS. The knowl- edgable readers may notice that the system clock for the 1995-technology is 15 MHz, far less than 50 MHz which is the expected cycle for the VLSI processors. This is because we do not use intra-chip pipeline and mem- ory banks, which are major methods for attaining higher system clock cycle, because these methods would com- plicate circuits, thus decrease parallelism. In our design simulations, the higher-level of parallelism was preferred over the introduction of pipeline and memory-banks. We can use higher system clock cycle such as 50 MHz, when the design decision was made to do so. 6. Conclusion In this paper, we presented the design of the wafer scale integration for massively parallel memory-based reason- ing. The unique feature of the WSI-MBR is an integra- tion of broad range of the state-of-the-art technologies such as wafer scale integration, high precision analog cir- cuit, massive parallelism, and memory-based reasoning paradigm. Our experiments indicate several significant advantages of the WSI-MBR: WSI-MBR attains an extremely high level of paral- lelism. Due to the compact design attained by the digital/analog hybrid approach, and by the state-of- the-art fabrication technologies, a single wafer WSI- MBR can host 240K MBR memory cells. By year 1995, the WSI-MBR can be fabricated with 0.3 pm technology which enables 2 million MBR memory cells to be hosted on a single 8 inch wafer. Each MBR memory cell has its own processing capabili- ties. WSI-MBR attains TFLOPS-order of aggregated computing power on a single wafer. Our estima- tion results demonstrate that WSI-MBR can attain 70 TFLOPS using the 1995 WSI technology. Even in the w,orst case where the data fetch creates a yb&;;t;al bottleneck, the WSI-MBR attains 0.48 . WSI-MBR overcomes the problem of noise in ana- log VLSI due to robustness of the MBR approach. Our simulator experiments demonstrate that WSI- MBR does not cause significant accuracy degrada- tion with the noise level anticipated in the actual implementation of the analog part of the VLSI. WSI-MBR is highly reliable because (1) it minimizes the ponding process which is the major cause of processing and run-time faults, and (2) it is highly fault-tolerant due to the distributed nature of the MBR approach. While WSI-MBR shows linear degradation as number of records are damaged, the expected run-time faults rate is extremely small, a fraction of a percent. Thus, our experiments indi- cate that the WSI-MBR can overcome the problem of the run-time faults. WSI-MBR can be built as a compact plug-in mod- ule or as an independent desk-top massively parallel system. This is due to the compact circuit design and by the use of WSI technology. In summary, the WSI-MBR offers an extremely high level of parallelism, over TFLOPS of aggregated comput- ing power, and the approach (combination of WSI tech- nology and MBR paradigm) effectively overcomes the Kitano and Yasunaga 855 Year for Design rule Max. Trans. Delay Memory Bit Cell Gate Delay for Total System Clock Production (Pm) on Wafer (Two-way) Access Time Multiplier, etc. Time Cycle (MHP) 1989 0.8 20 60 16 96 10 Table 3: Estimated computing time of WSI-MBR at each technology (nanoseconds) noise problems of the analog VLSI and the faults prob- lem of WSI. In addition, the WSI-MBR is expected to be cheap (few thousand dollars) and compact (TFLOPS MBR machine in the lap-top computer size). Although, the high performance was attained due to the special- ized architecture, the basic paradigm, MBR, is known to be useful for many areas of application. The com- puting power offered by the WSI-MBR would certainly explore new and realistic application areas. The utility of the WSI-MBR would be explored with data-intensive domains such as human genome sequencing, corporate MIS system, etc. We believe the implication of our work is significant. We have shown that a compact and inexpensive mas- sively parallel MBR system can be built even now. As far as the MBR is concerned, we are no longer constrained by the memory-space, the processor power, and the cost of the massively parallel machines. Millions processing elements are there, and TFLOPS are in our hand. The next step is to build applications to make use of the state-of-the-art WSI-MBR technology. References [Cavil1 et. al., 19911 Cavill, I?. J., Stapleton, P. E., and Wilkinson, J. M., “Wafer Scale Integration: A technology whose time has come,” Proc. of International Conference on Wafer Scale Integration, IEEE Computer Society Press, 1991. [Creecy et. al., 19901 C reecy, R., Masand, B, Smith, S., and Waltz, D., Trading MIPS and Memory for Knowledge En- gineering: Automatic Classification of Census Returns on a Massively Parallel Supercomputer, Thinking Machines Corporation, 1990. [Dally, 19911 Dally, W., “Fine-Grain Concurrent Comput- ing,” Research Directions in Computer Science: An MIT Perspective, Meyer, A., (Ed,), MIT Press, 1991. [Gelsinger et. al., 19891 Gelsinger, P., Gargini, P., Parker, G., and Yu, A., “Microprocessors circa 2000,” IEEE Spec- trum, Vol. 26, No. 10, 1989. [IEDM-91, 19911 IEEE P rot. of International Electron De- vice Meeting, 1991. [Kitano and Higuchi, 19911 Kitano, H. and Higuchi, T., “High Performance Memory-Based Translation on IXM2 Massively Parallel Associative Memory Processor,” Proc. of AAAI, 1991. [Kitano and Higuchi, 19911 Kitano, H. and Higuchi, T., “Massively Parallel Memory-Based Parsing,” Proc. of IJCAI-$1, 1991. 856 Scaling Up [Kitano et. al., 19911 Kitano, H., Hendler, J., Higuchi, T., Moldovan, D., and Waltz, D., “Massively Parallel Artificial Intelligence,” Proc. of IJCAI-91, 1991. [McDonald et. al., 19911 McDonald, J. F., Donlan, B. J., Russinovich, M. E., Philhower, R., Nah, K. S. and Greub, H., “A fast router and placement algorithm for wafer scale integration and wafer scale hybrid packing,” Proc. of In- ternational Conference on Wafer Scale Integration, IEEE Computer Society Press, 1991. [Mead, 19891 Mead, C., Analog VLSI and Neural Systems, Addison Wesley, 1989. [Sato and Nagao, 19901 Sato, S. and Nagao, M., “Toward Memory-based Translation,” Proc. of the International Conference on Computational Linguistics (COLING-90), 1990. [Seeds, 19671 Seeds, R.B., “Yield and Cost Analysis of Bipo- lar LSI,” Proc. of IEEE International Electron Devices Meeting, Oct., 1967. [Sejnowski and Rosenberg, 19871 Sejnowski, T. and Rosen- berg, C., “Parallel Netwroks that Learn to Pronounce En- glish Text,” Complex Systems, 1, 145-168, 1987. [Stanfill and Waltz, 19861 Stanfill, C. and Waltz, D., “To- ward Memory-Based Reasoning,” Communications of the ACM, Vol. 29, No. 12, 1986. [Sumita and Iida, 19911 Sumita, E. and Iida, H., “Experi- ments and Prospects of Example-Based Machine Transla- tion,” Proc. of the Annual Meeting of the Association for Computational Linguistics (ACL-91), 1991. [Thinking Machines Corporation, 19891 Thinking Machines Corporation, Model CM-2 Technical Summary, Technical Report TR-89-1, 1989. [Waltz, 19901 Waltz, D., “Massively Parallel AI,” Proc. of AAAI-$0, 1990. [Yasunaga et. al., 19911 Yasunaga, M., et. al. “A Self- Learning Neural Network Composed of 1152 Digital Neu- rons in Wafer-Scale LSIs,” Proc. of the International Joint Conference on Neural Networks at Singapore (IJCNN-91), 1991. [Zhang et. al., 19881 Zhang, X., Waltz, D., and Mesirov, J., Protein Structure Prediction by Memory-Based Reasoning, Thinking Machines Corporation, 1988. | 1992 | 16 |
1,206 | 1. Wafer Scale Integration for Massively Parallel ory-Based Reasoning* Hiroaki Kitano and Moritoshi Yasunagat Center for Machine Translation Carnegie Mellon University Pittsburgh, PA 15213 U.S.A. hiroaki@cs.cmu.edu, myasunagOcs.cmu.edu Abstract In this paper, we describe a desi n of wafer- scale integration for massively para lel memory- P based reasoning ( W SI-MBR) . W SI-MBR at- tains about 2 million parallelism on a single 8 inch wafer using the state-of-the-art fabri- cation technologies. While WSI-MBR is spe- cialized to memory-based reasoning, which is one of the mainstream approachs in massively parallel artificial intelligence research, the level of parallelism attained far surpasses any exist- ing massively parallel hardware. Combination of memory array and analog weight computing circuits enable us to attain super high-density implement ation with nanoseconds order infer- ence time. Simulation results indicates that inherent robustness of the memory-based rea- soning paradigm overcomes the possible preci- sion degradation and fabrication defects in the wafer-scale integration. Also, the WSI-MBR provides a compact (desk-top size) massively parallel computing environment. Introduction The memory-based reasoning (MBR) is one of the main- stay approach in massively parallel artificial intelligence research [Kitano et. al., 19911 [Waltz, 19901. The basic notion of MBR is to place memory as a foundation of in- telligence. Instead of having abstract and piecewise rules to make inferences by chaining them, MBR simply stores large numbers of actual cases to carry out similarity- matching in order to make inferences from the most similar cases in the past. MBR has been succesfully ap plied to English pronounciation task [Stanfill and Waltz, 19861, census data classification[Creecy et. al., 19901, protein structure prediction[Zhang et. al., 19881, ma- chine translation[Kitano and Kiguchi, 1991][Sumita and *This research was carried out as a program of the Inter- national Consortium for Massively Parallel Advanced Com- puting Technologies (IMPACT). ‘This author is on leave from Hitachi Central Research Laboratory. Iida, 1991][S a t o and Nagao, 19901, natural language un- derstanding [Kitano and Higuchi, 19911 and other data- intensive domains. MBR, however, requires massively parallel hardware such as the CM-2 connection machine [Thinking Ma- chines Corporation, 19891. The problems of current mas- sively parallel machines are (1) economically expensive, (2) huge physical size, and (3) parallelism does not suf- fice for some large-scale applications. For example, the CM-2 is a multi-million dollar machine requires install- ment in the machine room and attains only 64K paral- lelism (VPR = 1) with l-bit processing elements. Given the fact that many serious MBR applications (national statistics, crime investigation, tax records, virtual real- ity, etc) require more than a few million parallelism with reasonably low economic expense, current massively par- allel machines do not suffice for further penetration of the MBR and other massively parallel AI approachs for real-world applications. The solution which we will offer in this paper is to develop a wafer-scale integration for memory-based rea- soning (WSI-MBR). The design and performance simu- lation indicates that we can attain about 2 million paral- lelism on a single 8 inch wafer with 0.3 micro fabrication technologies which would be available for commercial production around year 1995. WSI-MBR will provide nearly 200 million parallelism when the wafer stack clus- ter method was established, which is the state-of-the-art VLSI fabrication and assembly technologies[McDonald et. al., 19911. The inference speed is on the order of nanoseconds by the use of a hybrid analog/digital com- puting circuits. The implication of this technology is significant. It means that we will be able to built desk- top or even lap-top massively parallel MBR systems. The WSI-MBR is a run-time component. All data and weight are pre-computed on massively parallel machines such as the Connection Machine. Computed weights and data are loaded onto WSI-MBR to perform inferencing. In the large-scale memory-based reasoning system, the content of the memory-base is expected to be fairly sta- ble so that up-date of weights and data will not be neces- sary for a certain duration of the operation. Separation of the main computing system and delivery (or run-time) system is justified even from a commercial point of view. 850 Scaling Up From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Since massively parallel machines would be quite large and expensive, development of run-time systems with extremely cheap and compact size would substantially push down cost-effectiveness trade-off point. easoning aradigm Memory-Based Reasoning is a reasoning method based on a large set of examples. Stanfill and Waltz wrote that [Stanfill and Waltz, 19861: We consider the phenomenon of reasoning from memories of specific episodes, how- ever, to be the foundation of an intelligent system, rather than an adjunct to some other reasoning method. This approach counters the traditional AI paradigm which places rules as the foundation of intelligence. It is not the scope of this paper to discuss benefits and limita- tions of the MBR itself. However, it should be noted that there are some sucessful reports and some commer- cial systems that have already been deployed using the MBR paradigm (English word pronounciation [Stanfill and Waltz, 19861, Prediction of protein structure [Zhang et. al., 19881, the Census classification [Creecy et. al., 19901, and others.) The MBR method requires a large set of cases. Each case consists of a set of features and a goal. Features represent problems need to be solved, and a goal repre- sents a solution in the case. In the MBRtalk example, each case has seven fields for characters of the word, and goal fields which represents a correct pronounciation and stress (Table 1). Statistical approach is used to determine significance of each feature in making correct reasoning. While rela- tively simple and homogenious operations are performed on each datum, the memory-based reasoning is particu- larly suitable for SIMD-type massively parallel machines such as the Connection Machine. A similarity measure will determine the weight in which each feature affects the result of reasoning. In case of the MBRtalk task, the measure is computed based on the following equations: Since benefits of the MBR over other reasoning paradigms, such as rule-based systems and neural net- works, have been discussed in [Stanfill and Waltz, 19861, we simply point out merits which motivated us for the development of the WSI-MBR. One of the computa- tional advantages of the MBR is that it allows data- parallel computing because the similarity of each record can be computed independently from other records. It is also a very attractive scheme for direct hardware imple- mentation due to its simplicity and potential robustness against noise and faults. 3. Wafer-Scale Integration Wafer-Scale Integration (WSI) is the state-of-the-art VLSI fabrication technology (See Proc. of Interna- tional Conference on Wafer Scale Integration for recent progress in WSI. Also, [Cavil1 et. al., 19911 provides a good overview of the area.), and has been applied to various domains such as neural networks [Yasunaga et. al., 19911. It fabricates one large VLSI-based system on a wafer as opposed to conventional VLSI production which fabricates over 100 chips from one wafer. The advantage of WSI is in its size (high integration level), performance, cost, and reliability: Size: WSI is compact because nearly all circuits neces- sary for the system are fabricated on a single wafer. Performance: WSI has substantial performance ad- vantage because it minimizes wiring length. Cost: WSI is cost effective because it minimize expen- sive assembly line. Reliability: WSI is reliable because it eliminates the ponding process which is the major cause of circuit malfunctions. However, there is one big problem in WSI fabrication: defects. In the conventional VLSI fabrication, one wafer consists of over 100 chips. Generally, we have certain percentages of defective chips. Traditionally, chips with defects have been simply discarded and the chips without defects have been used. To estimate the faults in the chip, we use the Seeds model[Seeds, 19671: - ID[f = PAI = VII)2 ID[f = P-f11 w! is a weight of feature f on the field g. d; is a value difference metric. Such metric differ in each task, but they are similar enough to be hardwired in VLSI chips. Please refer [Stanfill and Waltz, 19861 and other papers for details of the MBR approach. where Y is a yield of the wafer, D is the fault density which is, in the fabrication process we are going to use, about 1 fault per cm2, and A is the chip area. This is a reasonable rate for the current fabrication process. How- ever, even this level of fault would cause fatal problems for such an attempt to build an entire IBM 370 on one wafer. Unless sophisticated defects control mechanisms and robust circuits are used, a single defect collaspes an entire operation. But, redundant circuits diminish the benefits of the WSI. This trade-off has not been solved. In the WSI-MBR, we take a radically different ap preach. We accept a certain rate of defects. Rather Kitano and Yasunaga 851 Fields Input Fields Output (Goal) Rec. No. n-3 n-2 n-l n n+l n+2 n+3 Pron. Stress 00001 - - - f * 1 e f + 00002 - - f i i e - A 1 Table 1: A part of the memory-base for MBRtalk task than trying to control defects, we propose to use WSI for implementing a more robust computing mechanism so that a small amount of defects does not seriously af- fect the overall operation of the chip. We believe that MBR is ideal for this solution because it does not rely upon any single data unit. The essence of the MBR is a bulk data set which gives stable reasoning capability. 4. WSI-MBR WSI-MBR is a digital/analog hybrid WSI specialized for memory-based reasoning. We decide to employ a digi- tal/analog hybrid approach in order to increase paral- lelism and performance. First, in the digital computing circuit, a floating point processor part takes up most of chip area. On the other hand, the analog circuit requires only a fraction of area for implementation of equivalent floating point opera- tion circuits. The digital approach has an advantage in its flexibility since various sequences of floating point operations can be programmed. The analog approach in inflexible since it hardwires a computing sequence. However, in the WSI-MBR, the sequence of computa- tion is already well-defined so that no re-programming is required (See [Mead, 19891 for one other use of analog VLSI for neural networks). Use of a less area-demanding analog approach provides two major advantages over the digital approach: (1) increased parallelism, and (2) speed updue to relaxed-wiring constraints (critical paths and wire width). P.ise %CL IC~Addl (Chip Lmetion Signal) Figure 1: Wafer Floor Layout Chip Selection Circuit Second, the analog circuits provide a drastic speed up over digital circuits. It is well known that analog circuits have a natural advantage in speed of computation. This is also true in our model as we will discuss it later. Figure 1 shows a wafer floor layout of the WSI-MBR. Figure 2 shows a chip selection circuit. One wafer con- tains 56 memory chips, 7 data-bus chips (denoted as B), and a serial/parallel converter chips (denoted as C). This layout is for a five inch wafer. The chip selection circuits consists of signal lines which identifies and selects a chip on the wafer which the data should be send and accessed. In the figure, CL denotes the chip location signal (3 bits column, 3 bits row, 1 bit left/right selection) which iden- tifies a chip on the wafer. L/R, CC, and RC are address of the chip to be selected. Each memory chip consists of 4K MBR memory cells. One MBR memory cell loads one record and goal data, and carries out MBR operations. Figure 3 shows a i/R CL m CL ix CL $ 4 Figure 2: Chip Selection Circuit 852 Scaling Up Figure 3: Schematic of the Memory Cell of WSI-MBR schematic of the MBR memory cell. In this design, the cell has 256 bits of digital memory (24 8-bits fields and a 64bits goal memory), comparator, analog multipliers, a sense amplifier, and an Output Enable control circuits. The input data will be broadcast through the data-bus to all MBR memory cells. In each MBR memory cell, each field value of the input data is compared with the value of the corresponding field. This comparison is done at each comparator CMP in parallel. Figure 4 shows a schematic of memory bit cells and a comparator. When the value is the same, CMP holds a high voltage output which will be multipled by a corresponding weight using one transistor multiplier. Results of each multiplication are added and produces a similarity value of the record (called the score voltage SV) on the MBR memory cell. Now we want to take out the value of the goal mem- ory of similar MBR memory cells. We use a threshold relaxing technique to retrieve the goal value in the order of the similarity rank. Initially a high voltage is given to the threshold voltage line (denoted as TV in Figure 3). This voltage of the TV line is compared with the score voltage using a sense amplifier (denoted as SA in Figure 3). The host computer, or the controller, controls the TV level through a digital-analog converter. The controller decreases the TV level until any of the MBR memory cell has higher score voltage. When the score voltage is higher than the threshold voltage, then a S/R latch is set which indicate that the goal memory of the MBR memory cell should be retrieved. The Output Enable control circuit (OE control circuit) runs serial through- out the single chip to allow asynchrous scanning. This .means that a single fault in any part of the OE con- trol circuit hampers an entire chip function (but, not an entire wafer). In order to improve the reliability, the OE Control circuit is built as triple redundancy circuit. Thus, unless all three OE control circuits in the same memory-cell cause faults (this would be an extremely low probability), the chip function would be maintained. Therefore, the WSI-MBR carries out asynchronous data fetching to attain fast data retrieval, but maintains high reliability. Figure 4: Schematic of Memory Bit Cells and Compara- tor One MBR memory cell uses about 4,000 transistors: 1,024 for memory bit cells, 1,920 for comparators, 16 for analog multipliers, and about 1,000 for the output enable controllers and other circuits such as the bus driver. 5. Performance Simulation We have developed a simulator for WSI-MBR. The sim- ulator is written in C language and run on UNIX-based workstation and on the CM-2 connection machine. The simulator can model factors critical to WSI designing such as (1) noise-levels with various noise distributions, (2) defects, and (3) run-time faults. In this paper, we use Nettalk (MBRtalk in this case) task as an example of the performance data we have ob- tained. Although we have investigated the performance of WSI-MBR with several other tasks, we use MBRtalk for this paper because it is one of the most widely un- derstood tasks. The MBRtalk system was implemented on the WSI-MBR simulator. Experiments were car- ried out for the MBRtalk system with the memory-base size of 908 (6506), 5908 (43166), 10908 (80394), and 19908 (146940) words (records). Also, we used a full set Nettalk data. 5.1. Parallelism WSI-MBR attains a strikingly high level of parallelism. When the WSI-MBR design in the previous section is implemented on the 5-inch wafer using 0.5 p CMOS fab- rication technology, with the standard yield rate, the WSI-MBR provides 240K records each of which carry out completely data-parallel MBR operation. This is at- tained by the high density fabrication technology which can implement 16M transistors in the memory cell area, and by the compact design of the MBR memory cell which requires only 4,000 transistors per a cell. Tech- Kitano and Yasunaga 853 Word accuracy vs. Noise level Letter accuracy vs. Noise level Pacmtcoxeu Percrnl consct lo.w ! I I I I I ’ NohcLcvd 0.w 20.w 40.00 60.00 80.00 100.00 Figure 5: Word accuracy and noise Figure 6: Letter accuracy and noise nologies assumed in this design (5-inch wafer and 0.5 ~1 CMOS fabrication) are already available in selected chip producers. Within 4 to 5 years, the fabrication technolo- gies will provide for us 8 inch wafers and 0.3 pm fabrica- tion technologies[IEDM-91, 19911. The WSI-MBR will be able to offer about 2 million parallelism on a sin- gle wafer. Table 2 shows the number of memory-cells on a single wafer using various fabrication technologies. The 1995 technology is an estimation from current trends of VLSI technologies (See [Gelsinger et. al., 19891 and [Dally, 19911 f or rle es rmations of VLSI technologies b * f t’ in future. [IEDM-91, 1991) is one other good source of information.). 5.2. Precision: Robustness against noise One of the problems of the analog VLSI is the preci- sion in computing. Inherently, some noise undermines computing precision. We have simulated the noise fac- tor of the analog part of our circuit. We have confirmed that the anticipated noise level will not affect the accu- racy of reasoning in the memory-based reasoning system. There are several noise sources such as shot noise, ther- mal noise, l/f noise, burst noise, and avalanche noise. Also, there are some device-level deviation at produc- tion process of the wafer. Empirically, the total level of noise is known to be at the level of f30%. In our ex- periments, we varied noise levels starting from fO% to &loo% which essentially deviates similarity weight ma- trices. The distribution of the noise is uniform within the given range. Results are shown in Figure 5 and in Figure 6. We have discovered that the WSI-MBR is extremely robust against noise. There is only a minor degrada- tion even with the ItlOO% noise with the full-data set MBRtalk. The MBR seems to be fairly practical on 92.00 90.00 88.00 86.00 84.00 82.00 80.00 78.00 16.00 74.00 72.00 N&c I.cvcl 0.00 20.00 40.00 60.00 80.00 1oo.w analog VLSI since expected maximum level of noise is about f30% which does not cause any significant degra- dation in accuracy even with the small memory-base. It should be noted that the WSI-MBR is more robust against noise than NETtalk since NETtalk’s letter accu- racy degrades to under 80% with 100% noise[Sejnowski and Rosenberg, 19871 whereas MBRtalk on WSI-MBR maintains over 80% of letter accuracy with the memory- base larger than 45,000 records. 5.3. Fault Tolerance: Robustness against defects WSI inherently involves faults. As we have discussed previously, there is virtually no means to eliminate or control the defects. While we recognize this problem, we have carried out a set of simulations to identify the robustness of MBR against device level defects. The re- sult is shown in Figure 7. The accuracy degrades almost linearly. Since the expected run-time faults would be far less than l.O%, we see no problem on the accuracy degra- dation of MBR due to the run-time faults. By the same token, the result can be applied to the production de- fects. Since the expected defects density in our fabrica- tion process is about 0.5 defect/cm2, the total expected number of defects on one wafer is about 50 (assuming 100 chips/wafer and 1 cm2 chips). This is only 0.02% of the 240K memory-cells. This implies that we don’t even have to test each memory-cell to ensure the expected level of accuracy. 5.4. Speed: Beyond Tera FLOPS Computing time of the WSI-MBR is mostly a sum of the maximum transmission delay in the wafer, memory bit cell access time, and gate delay for multiplier and other 854 Scaling Up Year for Design rule MBR Memory Chips per Wafer MBR Memory Production (v) Cell per Chip 5 inch 8 inch Cell per Wafer 1989 0.8 1K 60 - 60K 1992 0.5 4K 60 120 240K - 480K 1995 0.3 16K 120 1920K Table 2: Number of MBR Memory Cells on a Single Wafer Accuracy vs. Run-time faults -Y loo.w 95.00 90.00 85.00 80.00 75.00 70.00 65.00 60.00 55.00 SO.00 45.00 40.00 3J.W 30.00 25.w Fmlt Ram 0.00 10.00 20.00 30.00 40.00 Figure 7: Fault rate and accuracy circuits. Table 3 shows an estimated computin time of the WSI-MBR using various fabrication techno ogies. 7 We use a data pipe-line in each data-bus chip to mitigate transmission delay. Using the 1995 technology, we can attain 66 nanosec- onds MBR operation and 2 million parallelism at the record level. Considering that each record contains 24 fields each of which requires weight computing, total arithematic operation for one MBR operation would be equivalent to 70 Tera FLOPS in digital computers. In the worst case, the data fetch may create a bottleneck slowing down the entire cycle to 1 milli-second. How- ever, even in this case, the total computing power on a single WSI-MBR attains 0.48 Tera FLOPS. The knowl- edgable readers may notice that the system clock for the 1995-technology is 15 MHz, far less than 50 MHz which is the expected cycle for the VLSI processors. This is because we do not use intra-chip pipeline and mem- ory banks, which are major methods for attaining higher system clock cycle, because these methods would com- plicate circuits, thus decrease parallelism. In our design simulations, the higher-level of parallelism was preferred over the introduction of pipeline and memory-banks. We can use higher system clock cycle such as 50 MHz, when the design decision was made to do so. 6. Conclusion In this paper, we presented the design of the wafer scale integration for massively parallel memory-based reason- ing. The unique feature of the WSI-MBR is an integra- tion of broad range of the state-of-the-art technologies such as wafer scale integration, high precision analog cir- cuit, massive parallelism, and memory-based reasoning paradigm. Our experiments indicate several significant advantages of the WSI-MBR: WSI-MBR attains an extremely high level of paral- lelism. Due to the compact design attained by the digital/analog hybrid approach, and by the state-of- the-art fabrication technologies, a single wafer WSI- MBR can host 240K MBR memory cells. By year 1995, the WSI-MBR can be fabricated with 0.3 pm technology which enables 2 million MBR memory cells to be hosted on a single 8 inch wafer. Each MBR memory cell has its own processing capabili- ties. WSI-MBR attains TFLOPS-order of aggregated computing power on a single wafer. Our estima- tion results demonstrate that WSI-MBR can attain 70 TFLOPS using the 1995 WSI technology. Even in the w,orst case where the data fetch creates a yb&;;t;al bottleneck, the WSI-MBR attains 0.48 . WSI-MBR overcomes the problem of noise in ana- log VLSI due to robustness of the MBR approach. Our simulator experiments demonstrate that WSI- MBR does not cause significant accuracy degrada- tion with the noise level anticipated in the actual implementation of the analog part of the VLSI. WSI-MBR is highly reliable because (1) it minimizes the ponding process which is the major cause of processing and run-time faults, and (2) it is highly fault-tolerant due to the distributed nature of the MBR approach. While WSI-MBR shows linear degradation as number of records are damaged, the expected run-time faults rate is extremely small, a fraction of a percent. Thus, our experiments indi- cate that the WSI-MBR can overcome the problem of the run-time faults. WSI-MBR can be built as a compact plug-in mod- ule or as an independent desk-top massively parallel system. This is due to the compact circuit design and by the use of WSI technology. In summary, the WSI-MBR offers an extremely high level of parallelism, over TFLOPS of aggregated comput- ing power, and the approach (combination of WSI tech- nology and MBR paradigm) effectively overcomes the Kitano and Yasunaga 855 Year for Design rule Max. Trans. Delay Memory Bit Cell Gate Delay for Total System Clock Production (Pm) on Wafer (Two-way) Access Time Multiplier, etc. Time Cycle (MHP) 1989 0.8 20 60 16 96 10 Table 3: Estimated computing time of WSI-MBR at each technology (nanoseconds) noise problems of the analog VLSI and the faults prob- lem of WSI. In addition, the WSI-MBR is expected to be cheap (few thousand dollars) and compact (TFLOPS MBR machine in the lap-top computer size). Although, the high performance was attained due to the special- ized architecture, the basic paradigm, MBR, is known to be useful for many areas of application. The com- puting power offered by the WSI-MBR would certainly explore new and realistic application areas. The utility of the WSI-MBR would be explored with data-intensive domains such as human genome sequencing, corporate MIS system, etc. We believe the implication of our work is significant. We have shown that a compact and inexpensive mas- sively parallel MBR system can be built even now. As far as the MBR is concerned, we are no longer constrained by the memory-space, the processor power, and the cost of the massively parallel machines. Millions processing elements are there, and TFLOPS are in our hand. The next step is to build applications to make use of the state-of-the-art WSI-MBR technology. References [Cavil1 et. al., 19911 Cavill, I?. J., Stapleton, P. E., and Wilkinson, J. M., “Wafer Scale Integration: A technology whose time has come,” Proc. of International Conference on Wafer Scale Integration, IEEE Computer Society Press, 1991. [Creecy et. al., 19901 C reecy, R., Masand, B, Smith, S., and Waltz, D., Trading MIPS and Memory for Knowledge En- gineering: Automatic Classification of Census Returns on a Massively Parallel Supercomputer, Thinking Machines Corporation, 1990. [Dally, 19911 Dally, W., “Fine-Grain Concurrent Comput- ing,” Research Directions in Computer Science: An MIT Perspective, Meyer, A., (Ed,), MIT Press, 1991. [Gelsinger et. al., 19891 Gelsinger, P., Gargini, P., Parker, G., and Yu, A., “Microprocessors circa 2000,” IEEE Spec- trum, Vol. 26, No. 10, 1989. [IEDM-91, 19911 IEEE P rot. of International Electron De- vice Meeting, 1991. [Kitano and Higuchi, 19911 Kitano, H. and Higuchi, T., “High Performance Memory-Based Translation on IXM2 Massively Parallel Associative Memory Processor,” Proc. of AAAI, 1991. [Kitano and Higuchi, 19911 Kitano, H. and Higuchi, T., “Massively Parallel Memory-Based Parsing,” Proc. of IJCAI-$1, 1991. 856 Scaling Up [Kitano et. al., 19911 Kitano, H., Hendler, J., Higuchi, T., Moldovan, D., and Waltz, D., “Massively Parallel Artificial Intelligence,” Proc. of IJCAI-91, 1991. [McDonald et. al., 19911 McDonald, J. F., Donlan, B. J., Russinovich, M. E., Philhower, R., Nah, K. S. and Greub, H., “A fast router and placement algorithm for wafer scale integration and wafer scale hybrid packing,” Proc. of In- ternational Conference on Wafer Scale Integration, IEEE Computer Society Press, 1991. [Mead, 19891 Mead, C., Analog VLSI and Neural Systems, Addison Wesley, 1989. [Sato and Nagao, 19901 Sato, S. and Nagao, M., “Toward Memory-based Translation,” Proc. of the International Conference on Computational Linguistics (COLING-90), 1990. [Seeds, 19671 Seeds, R.B., “Yield and Cost Analysis of Bipo- lar LSI,” Proc. of IEEE International Electron Devices Meeting, Oct., 1967. [Sejnowski and Rosenberg, 19871 Sejnowski, T. and Rosen- berg, C., “Parallel Netwroks that Learn to Pronounce En- glish Text,” Complex Systems, 1, 145-168, 1987. [Stanfill and Waltz, 19861 Stanfill, C. and Waltz, D., “To- ward Memory-Based Reasoning,” Communications of the ACM, Vol. 29, No. 12, 1986. [Sumita and Iida, 19911 Sumita, E. and Iida, H., “Experi- ments and Prospects of Example-Based Machine Transla- tion,” Proc. of the Annual Meeting of the Association for Computational Linguistics (ACL-91), 1991. [Thinking Machines Corporation, 19891 Thinking Machines Corporation, Model CM-2 Technical Summary, Technical Report TR-89-1, 1989. [Waltz, 19901 Waltz, D., “Massively Parallel AI,” Proc. of AAAI-$0, 1990. [Yasunaga et. al., 19911 Yasunaga, M., et. al. “A Self- Learning Neural Network Composed of 1152 Digital Neu- rons in Wafer-Scale LSIs,” Proc. of the International Joint Conference on Neural Networks at Singapore (IJCNN-91), 1991. [Zhang et. al., 19881 Zhang, X., Waltz, D., and Mesirov, J., Protein Structure Prediction by Memory-Based Reasoning, Thinking Machines Corporation, 1988. | 1992 | 17 |
1,207 | 1. Wafer Scale Integration for Massively Parallel ory-Based Reasoning* Hiroaki Kitano and Moritoshi Yasunagat Center for Machine Translation Carnegie Mellon University Pittsburgh, PA 15213 U.S.A. hiroaki@cs.cmu.edu, myasunagOcs.cmu.edu Abstract In this paper, we describe a desi n of wafer- scale integration for massively para lel memory- P based reasoning ( W SI-MBR) . W SI-MBR at- tains about 2 million parallelism on a single 8 inch wafer using the state-of-the-art fabri- cation technologies. While WSI-MBR is spe- cialized to memory-based reasoning, which is one of the mainstream approachs in massively parallel artificial intelligence research, the level of parallelism attained far surpasses any exist- ing massively parallel hardware. Combination of memory array and analog weight computing circuits enable us to attain super high-density implement ation with nanoseconds order infer- ence time. Simulation results indicates that inherent robustness of the memory-based rea- soning paradigm overcomes the possible preci- sion degradation and fabrication defects in the wafer-scale integration. Also, the WSI-MBR provides a compact (desk-top size) massively parallel computing environment. Introduction The memory-based reasoning (MBR) is one of the main- stay approach in massively parallel artificial intelligence research [Kitano et. al., 19911 [Waltz, 19901. The basic notion of MBR is to place memory as a foundation of in- telligence. Instead of having abstract and piecewise rules to make inferences by chaining them, MBR simply stores large numbers of actual cases to carry out similarity- matching in order to make inferences from the most similar cases in the past. MBR has been succesfully ap plied to English pronounciation task [Stanfill and Waltz, 19861, census data classification[Creecy et. al., 19901, protein structure prediction[Zhang et. al., 19881, ma- chine translation[Kitano and Kiguchi, 1991][Sumita and *This research was carried out as a program of the Inter- national Consortium for Massively Parallel Advanced Com- puting Technologies (IMPACT). ‘This author is on leave from Hitachi Central Research Laboratory. Iida, 1991][S a t o and Nagao, 19901, natural language un- derstanding [Kitano and Higuchi, 19911 and other data- intensive domains. MBR, however, requires massively parallel hardware such as the CM-2 connection machine [Thinking Ma- chines Corporation, 19891. The problems of current mas- sively parallel machines are (1) economically expensive, (2) huge physical size, and (3) parallelism does not suf- fice for some large-scale applications. For example, the CM-2 is a multi-million dollar machine requires install- ment in the machine room and attains only 64K paral- lelism (VPR = 1) with l-bit processing elements. Given the fact that many serious MBR applications (national statistics, crime investigation, tax records, virtual real- ity, etc) require more than a few million parallelism with reasonably low economic expense, current massively par- allel machines do not suffice for further penetration of the MBR and other massively parallel AI approachs for real-world applications. The solution which we will offer in this paper is to develop a wafer-scale integration for memory-based rea- soning (WSI-MBR). The design and performance simu- lation indicates that we can attain about 2 million paral- lelism on a single 8 inch wafer with 0.3 micro fabrication technologies which would be available for commercial production around year 1995. WSI-MBR will provide nearly 200 million parallelism when the wafer stack clus- ter method was established, which is the state-of-the-art VLSI fabrication and assembly technologies[McDonald et. al., 19911. The inference speed is on the order of nanoseconds by the use of a hybrid analog/digital com- puting circuits. The implication of this technology is significant. It means that we will be able to built desk- top or even lap-top massively parallel MBR systems. The WSI-MBR is a run-time component. All data and weight are pre-computed on massively parallel machines such as the Connection Machine. Computed weights and data are loaded onto WSI-MBR to perform inferencing. In the large-scale memory-based reasoning system, the content of the memory-base is expected to be fairly sta- ble so that up-date of weights and data will not be neces- sary for a certain duration of the operation. Separation of the main computing system and delivery (or run-time) system is justified even from a commercial point of view. 850 Scaling Up From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Since massively parallel machines would be quite large and expensive, development of run-time systems with extremely cheap and compact size would substantially push down cost-effectiveness trade-off point. easoning aradigm Memory-Based Reasoning is a reasoning method based on a large set of examples. Stanfill and Waltz wrote that [Stanfill and Waltz, 19861: We consider the phenomenon of reasoning from memories of specific episodes, how- ever, to be the foundation of an intelligent system, rather than an adjunct to some other reasoning method. This approach counters the traditional AI paradigm which places rules as the foundation of intelligence. It is not the scope of this paper to discuss benefits and limita- tions of the MBR itself. However, it should be noted that there are some sucessful reports and some commer- cial systems that have already been deployed using the MBR paradigm (English word pronounciation [Stanfill and Waltz, 19861, Prediction of protein structure [Zhang et. al., 19881, the Census classification [Creecy et. al., 19901, and others.) The MBR method requires a large set of cases. Each case consists of a set of features and a goal. Features represent problems need to be solved, and a goal repre- sents a solution in the case. In the MBRtalk example, each case has seven fields for characters of the word, and goal fields which represents a correct pronounciation and stress (Table 1). Statistical approach is used to determine significance of each feature in making correct reasoning. While rela- tively simple and homogenious operations are performed on each datum, the memory-based reasoning is particu- larly suitable for SIMD-type massively parallel machines such as the Connection Machine. A similarity measure will determine the weight in which each feature affects the result of reasoning. In case of the MBRtalk task, the measure is computed based on the following equations: Since benefits of the MBR over other reasoning paradigms, such as rule-based systems and neural net- works, have been discussed in [Stanfill and Waltz, 19861, we simply point out merits which motivated us for the development of the WSI-MBR. One of the computa- tional advantages of the MBR is that it allows data- parallel computing because the similarity of each record can be computed independently from other records. It is also a very attractive scheme for direct hardware imple- mentation due to its simplicity and potential robustness against noise and faults. 3. Wafer-Scale Integration Wafer-Scale Integration (WSI) is the state-of-the-art VLSI fabrication technology (See Proc. of Interna- tional Conference on Wafer Scale Integration for recent progress in WSI. Also, [Cavil1 et. al., 19911 provides a good overview of the area.), and has been applied to various domains such as neural networks [Yasunaga et. al., 19911. It fabricates one large VLSI-based system on a wafer as opposed to conventional VLSI production which fabricates over 100 chips from one wafer. The advantage of WSI is in its size (high integration level), performance, cost, and reliability: Size: WSI is compact because nearly all circuits neces- sary for the system are fabricated on a single wafer. Performance: WSI has substantial performance ad- vantage because it minimizes wiring length. Cost: WSI is cost effective because it minimize expen- sive assembly line. Reliability: WSI is reliable because it eliminates the ponding process which is the major cause of circuit malfunctions. However, there is one big problem in WSI fabrication: defects. In the conventional VLSI fabrication, one wafer consists of over 100 chips. Generally, we have certain percentages of defective chips. Traditionally, chips with defects have been simply discarded and the chips without defects have been used. To estimate the faults in the chip, we use the Seeds model[Seeds, 19671: - ID[f = PAI = VII)2 ID[f = P-f11 w! is a weight of feature f on the field g. d; is a value difference metric. Such metric differ in each task, but they are similar enough to be hardwired in VLSI chips. Please refer [Stanfill and Waltz, 19861 and other papers for details of the MBR approach. where Y is a yield of the wafer, D is the fault density which is, in the fabrication process we are going to use, about 1 fault per cm2, and A is the chip area. This is a reasonable rate for the current fabrication process. How- ever, even this level of fault would cause fatal problems for such an attempt to build an entire IBM 370 on one wafer. Unless sophisticated defects control mechanisms and robust circuits are used, a single defect collaspes an entire operation. But, redundant circuits diminish the benefits of the WSI. This trade-off has not been solved. In the WSI-MBR, we take a radically different ap preach. We accept a certain rate of defects. Rather Kitano and Yasunaga 851 Fields Input Fields Output (Goal) Rec. No. n-3 n-2 n-l n n+l n+2 n+3 Pron. Stress 00001 - - - f * 1 e f + 00002 - - f i i e - A 1 Table 1: A part of the memory-base for MBRtalk task than trying to control defects, we propose to use WSI for implementing a more robust computing mechanism so that a small amount of defects does not seriously af- fect the overall operation of the chip. We believe that MBR is ideal for this solution because it does not rely upon any single data unit. The essence of the MBR is a bulk data set which gives stable reasoning capability. 4. WSI-MBR WSI-MBR is a digital/analog hybrid WSI specialized for memory-based reasoning. We decide to employ a digi- tal/analog hybrid approach in order to increase paral- lelism and performance. First, in the digital computing circuit, a floating point processor part takes up most of chip area. On the other hand, the analog circuit requires only a fraction of area for implementation of equivalent floating point opera- tion circuits. The digital approach has an advantage in its flexibility since various sequences of floating point operations can be programmed. The analog approach in inflexible since it hardwires a computing sequence. However, in the WSI-MBR, the sequence of computa- tion is already well-defined so that no re-programming is required (See [Mead, 19891 for one other use of analog VLSI for neural networks). Use of a less area-demanding analog approach provides two major advantages over the digital approach: (1) increased parallelism, and (2) speed updue to relaxed-wiring constraints (critical paths and wire width). P.ise %CL IC~Addl (Chip Lmetion Signal) Figure 1: Wafer Floor Layout Chip Selection Circuit Second, the analog circuits provide a drastic speed up over digital circuits. It is well known that analog circuits have a natural advantage in speed of computation. This is also true in our model as we will discuss it later. Figure 1 shows a wafer floor layout of the WSI-MBR. Figure 2 shows a chip selection circuit. One wafer con- tains 56 memory chips, 7 data-bus chips (denoted as B), and a serial/parallel converter chips (denoted as C). This layout is for a five inch wafer. The chip selection circuits consists of signal lines which identifies and selects a chip on the wafer which the data should be send and accessed. In the figure, CL denotes the chip location signal (3 bits column, 3 bits row, 1 bit left/right selection) which iden- tifies a chip on the wafer. L/R, CC, and RC are address of the chip to be selected. Each memory chip consists of 4K MBR memory cells. One MBR memory cell loads one record and goal data, and carries out MBR operations. Figure 3 shows a i/R CL m CL ix CL $ 4 Figure 2: Chip Selection Circuit 852 Scaling Up Figure 3: Schematic of the Memory Cell of WSI-MBR schematic of the MBR memory cell. In this design, the cell has 256 bits of digital memory (24 8-bits fields and a 64bits goal memory), comparator, analog multipliers, a sense amplifier, and an Output Enable control circuits. The input data will be broadcast through the data-bus to all MBR memory cells. In each MBR memory cell, each field value of the input data is compared with the value of the corresponding field. This comparison is done at each comparator CMP in parallel. Figure 4 shows a schematic of memory bit cells and a comparator. When the value is the same, CMP holds a high voltage output which will be multipled by a corresponding weight using one transistor multiplier. Results of each multiplication are added and produces a similarity value of the record (called the score voltage SV) on the MBR memory cell. Now we want to take out the value of the goal mem- ory of similar MBR memory cells. We use a threshold relaxing technique to retrieve the goal value in the order of the similarity rank. Initially a high voltage is given to the threshold voltage line (denoted as TV in Figure 3). This voltage of the TV line is compared with the score voltage using a sense amplifier (denoted as SA in Figure 3). The host computer, or the controller, controls the TV level through a digital-analog converter. The controller decreases the TV level until any of the MBR memory cell has higher score voltage. When the score voltage is higher than the threshold voltage, then a S/R latch is set which indicate that the goal memory of the MBR memory cell should be retrieved. The Output Enable control circuit (OE control circuit) runs serial through- out the single chip to allow asynchrous scanning. This .means that a single fault in any part of the OE con- trol circuit hampers an entire chip function (but, not an entire wafer). In order to improve the reliability, the OE Control circuit is built as triple redundancy circuit. Thus, unless all three OE control circuits in the same memory-cell cause faults (this would be an extremely low probability), the chip function would be maintained. Therefore, the WSI-MBR carries out asynchronous data fetching to attain fast data retrieval, but maintains high reliability. Figure 4: Schematic of Memory Bit Cells and Compara- tor One MBR memory cell uses about 4,000 transistors: 1,024 for memory bit cells, 1,920 for comparators, 16 for analog multipliers, and about 1,000 for the output enable controllers and other circuits such as the bus driver. 5. Performance Simulation We have developed a simulator for WSI-MBR. The sim- ulator is written in C language and run on UNIX-based workstation and on the CM-2 connection machine. The simulator can model factors critical to WSI designing such as (1) noise-levels with various noise distributions, (2) defects, and (3) run-time faults. In this paper, we use Nettalk (MBRtalk in this case) task as an example of the performance data we have ob- tained. Although we have investigated the performance of WSI-MBR with several other tasks, we use MBRtalk for this paper because it is one of the most widely un- derstood tasks. The MBRtalk system was implemented on the WSI-MBR simulator. Experiments were car- ried out for the MBRtalk system with the memory-base size of 908 (6506), 5908 (43166), 10908 (80394), and 19908 (146940) words (records). Also, we used a full set Nettalk data. 5.1. Parallelism WSI-MBR attains a strikingly high level of parallelism. When the WSI-MBR design in the previous section is implemented on the 5-inch wafer using 0.5 p CMOS fab- rication technology, with the standard yield rate, the WSI-MBR provides 240K records each of which carry out completely data-parallel MBR operation. This is at- tained by the high density fabrication technology which can implement 16M transistors in the memory cell area, and by the compact design of the MBR memory cell which requires only 4,000 transistors per a cell. Tech- Kitano and Yasunaga 853 Word accuracy vs. Noise level Letter accuracy vs. Noise level Pacmtcoxeu Percrnl consct lo.w ! I I I I I ’ NohcLcvd 0.w 20.w 40.00 60.00 80.00 100.00 Figure 5: Word accuracy and noise Figure 6: Letter accuracy and noise nologies assumed in this design (5-inch wafer and 0.5 ~1 CMOS fabrication) are already available in selected chip producers. Within 4 to 5 years, the fabrication technolo- gies will provide for us 8 inch wafers and 0.3 pm fabrica- tion technologies[IEDM-91, 19911. The WSI-MBR will be able to offer about 2 million parallelism on a sin- gle wafer. Table 2 shows the number of memory-cells on a single wafer using various fabrication technologies. The 1995 technology is an estimation from current trends of VLSI technologies (See [Gelsinger et. al., 19891 and [Dally, 19911 f or rle es rmations of VLSI technologies b * f t’ in future. [IEDM-91, 1991) is one other good source of information.). 5.2. Precision: Robustness against noise One of the problems of the analog VLSI is the preci- sion in computing. Inherently, some noise undermines computing precision. We have simulated the noise fac- tor of the analog part of our circuit. We have confirmed that the anticipated noise level will not affect the accu- racy of reasoning in the memory-based reasoning system. There are several noise sources such as shot noise, ther- mal noise, l/f noise, burst noise, and avalanche noise. Also, there are some device-level deviation at produc- tion process of the wafer. Empirically, the total level of noise is known to be at the level of f30%. In our ex- periments, we varied noise levels starting from fO% to &loo% which essentially deviates similarity weight ma- trices. The distribution of the noise is uniform within the given range. Results are shown in Figure 5 and in Figure 6. We have discovered that the WSI-MBR is extremely robust against noise. There is only a minor degrada- tion even with the ItlOO% noise with the full-data set MBRtalk. The MBR seems to be fairly practical on 92.00 90.00 88.00 86.00 84.00 82.00 80.00 78.00 16.00 74.00 72.00 N&c I.cvcl 0.00 20.00 40.00 60.00 80.00 1oo.w analog VLSI since expected maximum level of noise is about f30% which does not cause any significant degra- dation in accuracy even with the small memory-base. It should be noted that the WSI-MBR is more robust against noise than NETtalk since NETtalk’s letter accu- racy degrades to under 80% with 100% noise[Sejnowski and Rosenberg, 19871 whereas MBRtalk on WSI-MBR maintains over 80% of letter accuracy with the memory- base larger than 45,000 records. 5.3. Fault Tolerance: Robustness against defects WSI inherently involves faults. As we have discussed previously, there is virtually no means to eliminate or control the defects. While we recognize this problem, we have carried out a set of simulations to identify the robustness of MBR against device level defects. The re- sult is shown in Figure 7. The accuracy degrades almost linearly. Since the expected run-time faults would be far less than l.O%, we see no problem on the accuracy degra- dation of MBR due to the run-time faults. By the same token, the result can be applied to the production de- fects. Since the expected defects density in our fabrica- tion process is about 0.5 defect/cm2, the total expected number of defects on one wafer is about 50 (assuming 100 chips/wafer and 1 cm2 chips). This is only 0.02% of the 240K memory-cells. This implies that we don’t even have to test each memory-cell to ensure the expected level of accuracy. 5.4. Speed: Beyond Tera FLOPS Computing time of the WSI-MBR is mostly a sum of the maximum transmission delay in the wafer, memory bit cell access time, and gate delay for multiplier and other 854 Scaling Up Year for Design rule MBR Memory Chips per Wafer MBR Memory Production (v) Cell per Chip 5 inch 8 inch Cell per Wafer 1989 0.8 1K 60 - 60K 1992 0.5 4K 60 120 240K - 480K 1995 0.3 16K 120 1920K Table 2: Number of MBR Memory Cells on a Single Wafer Accuracy vs. Run-time faults -Y loo.w 95.00 90.00 85.00 80.00 75.00 70.00 65.00 60.00 55.00 SO.00 45.00 40.00 3J.W 30.00 25.w Fmlt Ram 0.00 10.00 20.00 30.00 40.00 Figure 7: Fault rate and accuracy circuits. Table 3 shows an estimated computin time of the WSI-MBR using various fabrication techno ogies. 7 We use a data pipe-line in each data-bus chip to mitigate transmission delay. Using the 1995 technology, we can attain 66 nanosec- onds MBR operation and 2 million parallelism at the record level. Considering that each record contains 24 fields each of which requires weight computing, total arithematic operation for one MBR operation would be equivalent to 70 Tera FLOPS in digital computers. In the worst case, the data fetch may create a bottleneck slowing down the entire cycle to 1 milli-second. How- ever, even in this case, the total computing power on a single WSI-MBR attains 0.48 Tera FLOPS. The knowl- edgable readers may notice that the system clock for the 1995-technology is 15 MHz, far less than 50 MHz which is the expected cycle for the VLSI processors. This is because we do not use intra-chip pipeline and mem- ory banks, which are major methods for attaining higher system clock cycle, because these methods would com- plicate circuits, thus decrease parallelism. In our design simulations, the higher-level of parallelism was preferred over the introduction of pipeline and memory-banks. We can use higher system clock cycle such as 50 MHz, when the design decision was made to do so. 6. Conclusion In this paper, we presented the design of the wafer scale integration for massively parallel memory-based reason- ing. The unique feature of the WSI-MBR is an integra- tion of broad range of the state-of-the-art technologies such as wafer scale integration, high precision analog cir- cuit, massive parallelism, and memory-based reasoning paradigm. Our experiments indicate several significant advantages of the WSI-MBR: WSI-MBR attains an extremely high level of paral- lelism. Due to the compact design attained by the digital/analog hybrid approach, and by the state-of- the-art fabrication technologies, a single wafer WSI- MBR can host 240K MBR memory cells. By year 1995, the WSI-MBR can be fabricated with 0.3 pm technology which enables 2 million MBR memory cells to be hosted on a single 8 inch wafer. Each MBR memory cell has its own processing capabili- ties. WSI-MBR attains TFLOPS-order of aggregated computing power on a single wafer. Our estima- tion results demonstrate that WSI-MBR can attain 70 TFLOPS using the 1995 WSI technology. Even in the w,orst case where the data fetch creates a yb&;;t;al bottleneck, the WSI-MBR attains 0.48 . WSI-MBR overcomes the problem of noise in ana- log VLSI due to robustness of the MBR approach. Our simulator experiments demonstrate that WSI- MBR does not cause significant accuracy degrada- tion with the noise level anticipated in the actual implementation of the analog part of the VLSI. WSI-MBR is highly reliable because (1) it minimizes the ponding process which is the major cause of processing and run-time faults, and (2) it is highly fault-tolerant due to the distributed nature of the MBR approach. While WSI-MBR shows linear degradation as number of records are damaged, the expected run-time faults rate is extremely small, a fraction of a percent. Thus, our experiments indi- cate that the WSI-MBR can overcome the problem of the run-time faults. WSI-MBR can be built as a compact plug-in mod- ule or as an independent desk-top massively parallel system. This is due to the compact circuit design and by the use of WSI technology. In summary, the WSI-MBR offers an extremely high level of parallelism, over TFLOPS of aggregated comput- ing power, and the approach (combination of WSI tech- nology and MBR paradigm) effectively overcomes the Kitano and Yasunaga 855 Year for Design rule Max. Trans. Delay Memory Bit Cell Gate Delay for Total System Clock Production (Pm) on Wafer (Two-way) Access Time Multiplier, etc. Time Cycle (MHP) 1989 0.8 20 60 16 96 10 Table 3: Estimated computing time of WSI-MBR at each technology (nanoseconds) noise problems of the analog VLSI and the faults prob- lem of WSI. In addition, the WSI-MBR is expected to be cheap (few thousand dollars) and compact (TFLOPS MBR machine in the lap-top computer size). Although, the high performance was attained due to the special- ized architecture, the basic paradigm, MBR, is known to be useful for many areas of application. The com- puting power offered by the WSI-MBR would certainly explore new and realistic application areas. The utility of the WSI-MBR would be explored with data-intensive domains such as human genome sequencing, corporate MIS system, etc. We believe the implication of our work is significant. We have shown that a compact and inexpensive mas- sively parallel MBR system can be built even now. As far as the MBR is concerned, we are no longer constrained by the memory-space, the processor power, and the cost of the massively parallel machines. Millions processing elements are there, and TFLOPS are in our hand. The next step is to build applications to make use of the state-of-the-art WSI-MBR technology. References [Cavil1 et. al., 19911 Cavill, I?. J., Stapleton, P. E., and Wilkinson, J. M., “Wafer Scale Integration: A technology whose time has come,” Proc. of International Conference on Wafer Scale Integration, IEEE Computer Society Press, 1991. [Creecy et. al., 19901 C reecy, R., Masand, B, Smith, S., and Waltz, D., Trading MIPS and Memory for Knowledge En- gineering: Automatic Classification of Census Returns on a Massively Parallel Supercomputer, Thinking Machines Corporation, 1990. [Dally, 19911 Dally, W., “Fine-Grain Concurrent Comput- ing,” Research Directions in Computer Science: An MIT Perspective, Meyer, A., (Ed,), MIT Press, 1991. [Gelsinger et. al., 19891 Gelsinger, P., Gargini, P., Parker, G., and Yu, A., “Microprocessors circa 2000,” IEEE Spec- trum, Vol. 26, No. 10, 1989. [IEDM-91, 19911 IEEE P rot. of International Electron De- vice Meeting, 1991. [Kitano and Higuchi, 19911 Kitano, H. and Higuchi, T., “High Performance Memory-Based Translation on IXM2 Massively Parallel Associative Memory Processor,” Proc. of AAAI, 1991. [Kitano and Higuchi, 19911 Kitano, H. and Higuchi, T., “Massively Parallel Memory-Based Parsing,” Proc. of IJCAI-$1, 1991. 856 Scaling Up [Kitano et. al., 19911 Kitano, H., Hendler, J., Higuchi, T., Moldovan, D., and Waltz, D., “Massively Parallel Artificial Intelligence,” Proc. of IJCAI-91, 1991. [McDonald et. al., 19911 McDonald, J. F., Donlan, B. J., Russinovich, M. E., Philhower, R., Nah, K. S. and Greub, H., “A fast router and placement algorithm for wafer scale integration and wafer scale hybrid packing,” Proc. of In- ternational Conference on Wafer Scale Integration, IEEE Computer Society Press, 1991. [Mead, 19891 Mead, C., Analog VLSI and Neural Systems, Addison Wesley, 1989. [Sato and Nagao, 19901 Sato, S. and Nagao, M., “Toward Memory-based Translation,” Proc. of the International Conference on Computational Linguistics (COLING-90), 1990. [Seeds, 19671 Seeds, R.B., “Yield and Cost Analysis of Bipo- lar LSI,” Proc. of IEEE International Electron Devices Meeting, Oct., 1967. [Sejnowski and Rosenberg, 19871 Sejnowski, T. and Rosen- berg, C., “Parallel Netwroks that Learn to Pronounce En- glish Text,” Complex Systems, 1, 145-168, 1987. [Stanfill and Waltz, 19861 Stanfill, C. and Waltz, D., “To- ward Memory-Based Reasoning,” Communications of the ACM, Vol. 29, No. 12, 1986. [Sumita and Iida, 19911 Sumita, E. and Iida, H., “Experi- ments and Prospects of Example-Based Machine Transla- tion,” Proc. of the Annual Meeting of the Association for Computational Linguistics (ACL-91), 1991. [Thinking Machines Corporation, 19891 Thinking Machines Corporation, Model CM-2 Technical Summary, Technical Report TR-89-1, 1989. [Waltz, 19901 Waltz, D., “Massively Parallel AI,” Proc. of AAAI-$0, 1990. [Yasunaga et. al., 19911 Yasunaga, M., et. al. “A Self- Learning Neural Network Composed of 1152 Digital Neu- rons in Wafer-Scale LSIs,” Proc. of the International Joint Conference on Neural Networks at Singapore (IJCNN-91), 1991. [Zhang et. al., 19881 Zhang, X., Waltz, D., and Mesirov, J., Protein Structure Prediction by Memory-Based Reasoning, Thinking Machines Corporation, 1988. | 1992 | 18 |
1,208 | 1. Wafer Scale Integration for Massively Parallel ory-Based Reasoning* Hiroaki Kitano and Moritoshi Yasunagat Center for Machine Translation Carnegie Mellon University Pittsburgh, PA 15213 U.S.A. hiroaki@cs.cmu.edu, myasunagOcs.cmu.edu Abstract In this paper, we describe a desi n of wafer- scale integration for massively para lel memory- P based reasoning ( W SI-MBR) . W SI-MBR at- tains about 2 million parallelism on a single 8 inch wafer using the state-of-the-art fabri- cation technologies. While WSI-MBR is spe- cialized to memory-based reasoning, which is one of the mainstream approachs in massively parallel artificial intelligence research, the level of parallelism attained far surpasses any exist- ing massively parallel hardware. Combination of memory array and analog weight computing circuits enable us to attain super high-density implement ation with nanoseconds order infer- ence time. Simulation results indicates that inherent robustness of the memory-based rea- soning paradigm overcomes the possible preci- sion degradation and fabrication defects in the wafer-scale integration. Also, the WSI-MBR provides a compact (desk-top size) massively parallel computing environment. Introduction The memory-based reasoning (MBR) is one of the main- stay approach in massively parallel artificial intelligence research [Kitano et. al., 19911 [Waltz, 19901. The basic notion of MBR is to place memory as a foundation of in- telligence. Instead of having abstract and piecewise rules to make inferences by chaining them, MBR simply stores large numbers of actual cases to carry out similarity- matching in order to make inferences from the most similar cases in the past. MBR has been succesfully ap plied to English pronounciation task [Stanfill and Waltz, 19861, census data classification[Creecy et. al., 19901, protein structure prediction[Zhang et. al., 19881, ma- chine translation[Kitano and Kiguchi, 1991][Sumita and *This research was carried out as a program of the Inter- national Consortium for Massively Parallel Advanced Com- puting Technologies (IMPACT). ‘This author is on leave from Hitachi Central Research Laboratory. Iida, 1991][S a t o and Nagao, 19901, natural language un- derstanding [Kitano and Higuchi, 19911 and other data- intensive domains. MBR, however, requires massively parallel hardware such as the CM-2 connection machine [Thinking Ma- chines Corporation, 19891. The problems of current mas- sively parallel machines are (1) economically expensive, (2) huge physical size, and (3) parallelism does not suf- fice for some large-scale applications. For example, the CM-2 is a multi-million dollar machine requires install- ment in the machine room and attains only 64K paral- lelism (VPR = 1) with l-bit processing elements. Given the fact that many serious MBR applications (national statistics, crime investigation, tax records, virtual real- ity, etc) require more than a few million parallelism with reasonably low economic expense, current massively par- allel machines do not suffice for further penetration of the MBR and other massively parallel AI approachs for real-world applications. The solution which we will offer in this paper is to develop a wafer-scale integration for memory-based rea- soning (WSI-MBR). The design and performance simu- lation indicates that we can attain about 2 million paral- lelism on a single 8 inch wafer with 0.3 micro fabrication technologies which would be available for commercial production around year 1995. WSI-MBR will provide nearly 200 million parallelism when the wafer stack clus- ter method was established, which is the state-of-the-art VLSI fabrication and assembly technologies[McDonald et. al., 19911. The inference speed is on the order of nanoseconds by the use of a hybrid analog/digital com- puting circuits. The implication of this technology is significant. It means that we will be able to built desk- top or even lap-top massively parallel MBR systems. The WSI-MBR is a run-time component. All data and weight are pre-computed on massively parallel machines such as the Connection Machine. Computed weights and data are loaded onto WSI-MBR to perform inferencing. In the large-scale memory-based reasoning system, the content of the memory-base is expected to be fairly sta- ble so that up-date of weights and data will not be neces- sary for a certain duration of the operation. Separation of the main computing system and delivery (or run-time) system is justified even from a commercial point of view. 850 Scaling Up From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Since massively parallel machines would be quite large and expensive, development of run-time systems with extremely cheap and compact size would substantially push down cost-effectiveness trade-off point. easoning aradigm Memory-Based Reasoning is a reasoning method based on a large set of examples. Stanfill and Waltz wrote that [Stanfill and Waltz, 19861: We consider the phenomenon of reasoning from memories of specific episodes, how- ever, to be the foundation of an intelligent system, rather than an adjunct to some other reasoning method. This approach counters the traditional AI paradigm which places rules as the foundation of intelligence. It is not the scope of this paper to discuss benefits and limita- tions of the MBR itself. However, it should be noted that there are some sucessful reports and some commer- cial systems that have already been deployed using the MBR paradigm (English word pronounciation [Stanfill and Waltz, 19861, Prediction of protein structure [Zhang et. al., 19881, the Census classification [Creecy et. al., 19901, and others.) The MBR method requires a large set of cases. Each case consists of a set of features and a goal. Features represent problems need to be solved, and a goal repre- sents a solution in the case. In the MBRtalk example, each case has seven fields for characters of the word, and goal fields which represents a correct pronounciation and stress (Table 1). Statistical approach is used to determine significance of each feature in making correct reasoning. While rela- tively simple and homogenious operations are performed on each datum, the memory-based reasoning is particu- larly suitable for SIMD-type massively parallel machines such as the Connection Machine. A similarity measure will determine the weight in which each feature affects the result of reasoning. In case of the MBRtalk task, the measure is computed based on the following equations: Since benefits of the MBR over other reasoning paradigms, such as rule-based systems and neural net- works, have been discussed in [Stanfill and Waltz, 19861, we simply point out merits which motivated us for the development of the WSI-MBR. One of the computa- tional advantages of the MBR is that it allows data- parallel computing because the similarity of each record can be computed independently from other records. It is also a very attractive scheme for direct hardware imple- mentation due to its simplicity and potential robustness against noise and faults. 3. Wafer-Scale Integration Wafer-Scale Integration (WSI) is the state-of-the-art VLSI fabrication technology (See Proc. of Interna- tional Conference on Wafer Scale Integration for recent progress in WSI. Also, [Cavil1 et. al., 19911 provides a good overview of the area.), and has been applied to various domains such as neural networks [Yasunaga et. al., 19911. It fabricates one large VLSI-based system on a wafer as opposed to conventional VLSI production which fabricates over 100 chips from one wafer. The advantage of WSI is in its size (high integration level), performance, cost, and reliability: Size: WSI is compact because nearly all circuits neces- sary for the system are fabricated on a single wafer. Performance: WSI has substantial performance ad- vantage because it minimizes wiring length. Cost: WSI is cost effective because it minimize expen- sive assembly line. Reliability: WSI is reliable because it eliminates the ponding process which is the major cause of circuit malfunctions. However, there is one big problem in WSI fabrication: defects. In the conventional VLSI fabrication, one wafer consists of over 100 chips. Generally, we have certain percentages of defective chips. Traditionally, chips with defects have been simply discarded and the chips without defects have been used. To estimate the faults in the chip, we use the Seeds model[Seeds, 19671: - ID[f = PAI = VII)2 ID[f = P-f11 w! is a weight of feature f on the field g. d; is a value difference metric. Such metric differ in each task, but they are similar enough to be hardwired in VLSI chips. Please refer [Stanfill and Waltz, 19861 and other papers for details of the MBR approach. where Y is a yield of the wafer, D is the fault density which is, in the fabrication process we are going to use, about 1 fault per cm2, and A is the chip area. This is a reasonable rate for the current fabrication process. How- ever, even this level of fault would cause fatal problems for such an attempt to build an entire IBM 370 on one wafer. Unless sophisticated defects control mechanisms and robust circuits are used, a single defect collaspes an entire operation. But, redundant circuits diminish the benefits of the WSI. This trade-off has not been solved. In the WSI-MBR, we take a radically different ap preach. We accept a certain rate of defects. Rather Kitano and Yasunaga 851 Fields Input Fields Output (Goal) Rec. No. n-3 n-2 n-l n n+l n+2 n+3 Pron. Stress 00001 - - - f * 1 e f + 00002 - - f i i e - A 1 Table 1: A part of the memory-base for MBRtalk task than trying to control defects, we propose to use WSI for implementing a more robust computing mechanism so that a small amount of defects does not seriously af- fect the overall operation of the chip. We believe that MBR is ideal for this solution because it does not rely upon any single data unit. The essence of the MBR is a bulk data set which gives stable reasoning capability. 4. WSI-MBR WSI-MBR is a digital/analog hybrid WSI specialized for memory-based reasoning. We decide to employ a digi- tal/analog hybrid approach in order to increase paral- lelism and performance. First, in the digital computing circuit, a floating point processor part takes up most of chip area. On the other hand, the analog circuit requires only a fraction of area for implementation of equivalent floating point opera- tion circuits. The digital approach has an advantage in its flexibility since various sequences of floating point operations can be programmed. The analog approach in inflexible since it hardwires a computing sequence. However, in the WSI-MBR, the sequence of computa- tion is already well-defined so that no re-programming is required (See [Mead, 19891 for one other use of analog VLSI for neural networks). Use of a less area-demanding analog approach provides two major advantages over the digital approach: (1) increased parallelism, and (2) speed updue to relaxed-wiring constraints (critical paths and wire width). P.ise %CL IC~Addl (Chip Lmetion Signal) Figure 1: Wafer Floor Layout Chip Selection Circuit Second, the analog circuits provide a drastic speed up over digital circuits. It is well known that analog circuits have a natural advantage in speed of computation. This is also true in our model as we will discuss it later. Figure 1 shows a wafer floor layout of the WSI-MBR. Figure 2 shows a chip selection circuit. One wafer con- tains 56 memory chips, 7 data-bus chips (denoted as B), and a serial/parallel converter chips (denoted as C). This layout is for a five inch wafer. The chip selection circuits consists of signal lines which identifies and selects a chip on the wafer which the data should be send and accessed. In the figure, CL denotes the chip location signal (3 bits column, 3 bits row, 1 bit left/right selection) which iden- tifies a chip on the wafer. L/R, CC, and RC are address of the chip to be selected. Each memory chip consists of 4K MBR memory cells. One MBR memory cell loads one record and goal data, and carries out MBR operations. Figure 3 shows a i/R CL m CL ix CL $ 4 Figure 2: Chip Selection Circuit 852 Scaling Up Figure 3: Schematic of the Memory Cell of WSI-MBR schematic of the MBR memory cell. In this design, the cell has 256 bits of digital memory (24 8-bits fields and a 64bits goal memory), comparator, analog multipliers, a sense amplifier, and an Output Enable control circuits. The input data will be broadcast through the data-bus to all MBR memory cells. In each MBR memory cell, each field value of the input data is compared with the value of the corresponding field. This comparison is done at each comparator CMP in parallel. Figure 4 shows a schematic of memory bit cells and a comparator. When the value is the same, CMP holds a high voltage output which will be multipled by a corresponding weight using one transistor multiplier. Results of each multiplication are added and produces a similarity value of the record (called the score voltage SV) on the MBR memory cell. Now we want to take out the value of the goal mem- ory of similar MBR memory cells. We use a threshold relaxing technique to retrieve the goal value in the order of the similarity rank. Initially a high voltage is given to the threshold voltage line (denoted as TV in Figure 3). This voltage of the TV line is compared with the score voltage using a sense amplifier (denoted as SA in Figure 3). The host computer, or the controller, controls the TV level through a digital-analog converter. The controller decreases the TV level until any of the MBR memory cell has higher score voltage. When the score voltage is higher than the threshold voltage, then a S/R latch is set which indicate that the goal memory of the MBR memory cell should be retrieved. The Output Enable control circuit (OE control circuit) runs serial through- out the single chip to allow asynchrous scanning. This .means that a single fault in any part of the OE con- trol circuit hampers an entire chip function (but, not an entire wafer). In order to improve the reliability, the OE Control circuit is built as triple redundancy circuit. Thus, unless all three OE control circuits in the same memory-cell cause faults (this would be an extremely low probability), the chip function would be maintained. Therefore, the WSI-MBR carries out asynchronous data fetching to attain fast data retrieval, but maintains high reliability. Figure 4: Schematic of Memory Bit Cells and Compara- tor One MBR memory cell uses about 4,000 transistors: 1,024 for memory bit cells, 1,920 for comparators, 16 for analog multipliers, and about 1,000 for the output enable controllers and other circuits such as the bus driver. 5. Performance Simulation We have developed a simulator for WSI-MBR. The sim- ulator is written in C language and run on UNIX-based workstation and on the CM-2 connection machine. The simulator can model factors critical to WSI designing such as (1) noise-levels with various noise distributions, (2) defects, and (3) run-time faults. In this paper, we use Nettalk (MBRtalk in this case) task as an example of the performance data we have ob- tained. Although we have investigated the performance of WSI-MBR with several other tasks, we use MBRtalk for this paper because it is one of the most widely un- derstood tasks. The MBRtalk system was implemented on the WSI-MBR simulator. Experiments were car- ried out for the MBRtalk system with the memory-base size of 908 (6506), 5908 (43166), 10908 (80394), and 19908 (146940) words (records). Also, we used a full set Nettalk data. 5.1. Parallelism WSI-MBR attains a strikingly high level of parallelism. When the WSI-MBR design in the previous section is implemented on the 5-inch wafer using 0.5 p CMOS fab- rication technology, with the standard yield rate, the WSI-MBR provides 240K records each of which carry out completely data-parallel MBR operation. This is at- tained by the high density fabrication technology which can implement 16M transistors in the memory cell area, and by the compact design of the MBR memory cell which requires only 4,000 transistors per a cell. Tech- Kitano and Yasunaga 853 Word accuracy vs. Noise level Letter accuracy vs. Noise level Pacmtcoxeu Percrnl consct lo.w ! I I I I I ’ NohcLcvd 0.w 20.w 40.00 60.00 80.00 100.00 Figure 5: Word accuracy and noise Figure 6: Letter accuracy and noise nologies assumed in this design (5-inch wafer and 0.5 ~1 CMOS fabrication) are already available in selected chip producers. Within 4 to 5 years, the fabrication technolo- gies will provide for us 8 inch wafers and 0.3 pm fabrica- tion technologies[IEDM-91, 19911. The WSI-MBR will be able to offer about 2 million parallelism on a sin- gle wafer. Table 2 shows the number of memory-cells on a single wafer using various fabrication technologies. The 1995 technology is an estimation from current trends of VLSI technologies (See [Gelsinger et. al., 19891 and [Dally, 19911 f or rle es rmations of VLSI technologies b * f t’ in future. [IEDM-91, 1991) is one other good source of information.). 5.2. Precision: Robustness against noise One of the problems of the analog VLSI is the preci- sion in computing. Inherently, some noise undermines computing precision. We have simulated the noise fac- tor of the analog part of our circuit. We have confirmed that the anticipated noise level will not affect the accu- racy of reasoning in the memory-based reasoning system. There are several noise sources such as shot noise, ther- mal noise, l/f noise, burst noise, and avalanche noise. Also, there are some device-level deviation at produc- tion process of the wafer. Empirically, the total level of noise is known to be at the level of f30%. In our ex- periments, we varied noise levels starting from fO% to &loo% which essentially deviates similarity weight ma- trices. The distribution of the noise is uniform within the given range. Results are shown in Figure 5 and in Figure 6. We have discovered that the WSI-MBR is extremely robust against noise. There is only a minor degrada- tion even with the ItlOO% noise with the full-data set MBRtalk. The MBR seems to be fairly practical on 92.00 90.00 88.00 86.00 84.00 82.00 80.00 78.00 16.00 74.00 72.00 N&c I.cvcl 0.00 20.00 40.00 60.00 80.00 1oo.w analog VLSI since expected maximum level of noise is about f30% which does not cause any significant degra- dation in accuracy even with the small memory-base. It should be noted that the WSI-MBR is more robust against noise than NETtalk since NETtalk’s letter accu- racy degrades to under 80% with 100% noise[Sejnowski and Rosenberg, 19871 whereas MBRtalk on WSI-MBR maintains over 80% of letter accuracy with the memory- base larger than 45,000 records. 5.3. Fault Tolerance: Robustness against defects WSI inherently involves faults. As we have discussed previously, there is virtually no means to eliminate or control the defects. While we recognize this problem, we have carried out a set of simulations to identify the robustness of MBR against device level defects. The re- sult is shown in Figure 7. The accuracy degrades almost linearly. Since the expected run-time faults would be far less than l.O%, we see no problem on the accuracy degra- dation of MBR due to the run-time faults. By the same token, the result can be applied to the production de- fects. Since the expected defects density in our fabrica- tion process is about 0.5 defect/cm2, the total expected number of defects on one wafer is about 50 (assuming 100 chips/wafer and 1 cm2 chips). This is only 0.02% of the 240K memory-cells. This implies that we don’t even have to test each memory-cell to ensure the expected level of accuracy. 5.4. Speed: Beyond Tera FLOPS Computing time of the WSI-MBR is mostly a sum of the maximum transmission delay in the wafer, memory bit cell access time, and gate delay for multiplier and other 854 Scaling Up Year for Design rule MBR Memory Chips per Wafer MBR Memory Production (v) Cell per Chip 5 inch 8 inch Cell per Wafer 1989 0.8 1K 60 - 60K 1992 0.5 4K 60 120 240K - 480K 1995 0.3 16K 120 1920K Table 2: Number of MBR Memory Cells on a Single Wafer Accuracy vs. Run-time faults -Y loo.w 95.00 90.00 85.00 80.00 75.00 70.00 65.00 60.00 55.00 SO.00 45.00 40.00 3J.W 30.00 25.w Fmlt Ram 0.00 10.00 20.00 30.00 40.00 Figure 7: Fault rate and accuracy circuits. Table 3 shows an estimated computin time of the WSI-MBR using various fabrication techno ogies. 7 We use a data pipe-line in each data-bus chip to mitigate transmission delay. Using the 1995 technology, we can attain 66 nanosec- onds MBR operation and 2 million parallelism at the record level. Considering that each record contains 24 fields each of which requires weight computing, total arithematic operation for one MBR operation would be equivalent to 70 Tera FLOPS in digital computers. In the worst case, the data fetch may create a bottleneck slowing down the entire cycle to 1 milli-second. How- ever, even in this case, the total computing power on a single WSI-MBR attains 0.48 Tera FLOPS. The knowl- edgable readers may notice that the system clock for the 1995-technology is 15 MHz, far less than 50 MHz which is the expected cycle for the VLSI processors. This is because we do not use intra-chip pipeline and mem- ory banks, which are major methods for attaining higher system clock cycle, because these methods would com- plicate circuits, thus decrease parallelism. In our design simulations, the higher-level of parallelism was preferred over the introduction of pipeline and memory-banks. We can use higher system clock cycle such as 50 MHz, when the design decision was made to do so. 6. Conclusion In this paper, we presented the design of the wafer scale integration for massively parallel memory-based reason- ing. The unique feature of the WSI-MBR is an integra- tion of broad range of the state-of-the-art technologies such as wafer scale integration, high precision analog cir- cuit, massive parallelism, and memory-based reasoning paradigm. Our experiments indicate several significant advantages of the WSI-MBR: WSI-MBR attains an extremely high level of paral- lelism. Due to the compact design attained by the digital/analog hybrid approach, and by the state-of- the-art fabrication technologies, a single wafer WSI- MBR can host 240K MBR memory cells. By year 1995, the WSI-MBR can be fabricated with 0.3 pm technology which enables 2 million MBR memory cells to be hosted on a single 8 inch wafer. Each MBR memory cell has its own processing capabili- ties. WSI-MBR attains TFLOPS-order of aggregated computing power on a single wafer. Our estima- tion results demonstrate that WSI-MBR can attain 70 TFLOPS using the 1995 WSI technology. Even in the w,orst case where the data fetch creates a yb&;;t;al bottleneck, the WSI-MBR attains 0.48 . WSI-MBR overcomes the problem of noise in ana- log VLSI due to robustness of the MBR approach. Our simulator experiments demonstrate that WSI- MBR does not cause significant accuracy degrada- tion with the noise level anticipated in the actual implementation of the analog part of the VLSI. WSI-MBR is highly reliable because (1) it minimizes the ponding process which is the major cause of processing and run-time faults, and (2) it is highly fault-tolerant due to the distributed nature of the MBR approach. While WSI-MBR shows linear degradation as number of records are damaged, the expected run-time faults rate is extremely small, a fraction of a percent. Thus, our experiments indi- cate that the WSI-MBR can overcome the problem of the run-time faults. WSI-MBR can be built as a compact plug-in mod- ule or as an independent desk-top massively parallel system. This is due to the compact circuit design and by the use of WSI technology. In summary, the WSI-MBR offers an extremely high level of parallelism, over TFLOPS of aggregated comput- ing power, and the approach (combination of WSI tech- nology and MBR paradigm) effectively overcomes the Kitano and Yasunaga 855 Year for Design rule Max. Trans. Delay Memory Bit Cell Gate Delay for Total System Clock Production (Pm) on Wafer (Two-way) Access Time Multiplier, etc. Time Cycle (MHP) 1989 0.8 20 60 16 96 10 Table 3: Estimated computing time of WSI-MBR at each technology (nanoseconds) noise problems of the analog VLSI and the faults prob- lem of WSI. In addition, the WSI-MBR is expected to be cheap (few thousand dollars) and compact (TFLOPS MBR machine in the lap-top computer size). Although, the high performance was attained due to the special- ized architecture, the basic paradigm, MBR, is known to be useful for many areas of application. The com- puting power offered by the WSI-MBR would certainly explore new and realistic application areas. The utility of the WSI-MBR would be explored with data-intensive domains such as human genome sequencing, corporate MIS system, etc. We believe the implication of our work is significant. We have shown that a compact and inexpensive mas- sively parallel MBR system can be built even now. As far as the MBR is concerned, we are no longer constrained by the memory-space, the processor power, and the cost of the massively parallel machines. Millions processing elements are there, and TFLOPS are in our hand. The next step is to build applications to make use of the state-of-the-art WSI-MBR technology. References [Cavil1 et. al., 19911 Cavill, I?. J., Stapleton, P. E., and Wilkinson, J. M., “Wafer Scale Integration: A technology whose time has come,” Proc. of International Conference on Wafer Scale Integration, IEEE Computer Society Press, 1991. [Creecy et. al., 19901 C reecy, R., Masand, B, Smith, S., and Waltz, D., Trading MIPS and Memory for Knowledge En- gineering: Automatic Classification of Census Returns on a Massively Parallel Supercomputer, Thinking Machines Corporation, 1990. [Dally, 19911 Dally, W., “Fine-Grain Concurrent Comput- ing,” Research Directions in Computer Science: An MIT Perspective, Meyer, A., (Ed,), MIT Press, 1991. [Gelsinger et. al., 19891 Gelsinger, P., Gargini, P., Parker, G., and Yu, A., “Microprocessors circa 2000,” IEEE Spec- trum, Vol. 26, No. 10, 1989. [IEDM-91, 19911 IEEE P rot. of International Electron De- vice Meeting, 1991. [Kitano and Higuchi, 19911 Kitano, H. and Higuchi, T., “High Performance Memory-Based Translation on IXM2 Massively Parallel Associative Memory Processor,” Proc. of AAAI, 1991. [Kitano and Higuchi, 19911 Kitano, H. and Higuchi, T., “Massively Parallel Memory-Based Parsing,” Proc. of IJCAI-$1, 1991. 856 Scaling Up [Kitano et. al., 19911 Kitano, H., Hendler, J., Higuchi, T., Moldovan, D., and Waltz, D., “Massively Parallel Artificial Intelligence,” Proc. of IJCAI-91, 1991. [McDonald et. al., 19911 McDonald, J. F., Donlan, B. J., Russinovich, M. E., Philhower, R., Nah, K. S. and Greub, H., “A fast router and placement algorithm for wafer scale integration and wafer scale hybrid packing,” Proc. of In- ternational Conference on Wafer Scale Integration, IEEE Computer Society Press, 1991. [Mead, 19891 Mead, C., Analog VLSI and Neural Systems, Addison Wesley, 1989. [Sato and Nagao, 19901 Sato, S. and Nagao, M., “Toward Memory-based Translation,” Proc. of the International Conference on Computational Linguistics (COLING-90), 1990. [Seeds, 19671 Seeds, R.B., “Yield and Cost Analysis of Bipo- lar LSI,” Proc. of IEEE International Electron Devices Meeting, Oct., 1967. [Sejnowski and Rosenberg, 19871 Sejnowski, T. and Rosen- berg, C., “Parallel Netwroks that Learn to Pronounce En- glish Text,” Complex Systems, 1, 145-168, 1987. [Stanfill and Waltz, 19861 Stanfill, C. and Waltz, D., “To- ward Memory-Based Reasoning,” Communications of the ACM, Vol. 29, No. 12, 1986. [Sumita and Iida, 19911 Sumita, E. and Iida, H., “Experi- ments and Prospects of Example-Based Machine Transla- tion,” Proc. of the Annual Meeting of the Association for Computational Linguistics (ACL-91), 1991. [Thinking Machines Corporation, 19891 Thinking Machines Corporation, Model CM-2 Technical Summary, Technical Report TR-89-1, 1989. [Waltz, 19901 Waltz, D., “Massively Parallel AI,” Proc. of AAAI-$0, 1990. [Yasunaga et. al., 19911 Yasunaga, M., et. al. “A Self- Learning Neural Network Composed of 1152 Digital Neu- rons in Wafer-Scale LSIs,” Proc. of the International Joint Conference on Neural Networks at Singapore (IJCNN-91), 1991. [Zhang et. al., 19881 Zhang, X., Waltz, D., and Mesirov, J., Protein Structure Prediction by Memory-Based Reasoning, Thinking Machines Corporation, 1988. | 1992 | 19 |
1,209 | Generating Cross-References for ia Explanation” Kathleen . McKeown Steven K. Feiner Jacques Robin Do&e D. Seligmann Michael Tanenblatt Department of Computer Science Columbia University New York, NY 10027 { McKeown, Feiner, Robin, Doree, Tanenbla} @cs.columbia.edu Abstract When explanations include multiple media, such as text and illustrations, a reference to an object can be made through a combination of media. We call part of a presentation that references material elsewhere a cross-reference. We are concerned here with how textual expressions can refer to parts of accompanying illustrations. The illustration to which a cross-reference refers should also satisfy the specific goal of identifying an object for the user. Thus, producing an effective cross-reference not only involves text generation, but may also entail modifying or replacing an existing illustration and in some cases, generating an illustration where previously none was needed. In this paper, we describe the different types of cross-references that COMET (Coordinated Multimedia Explanation Testbed) generates and show the roles that both its text and graphics generators play in this process. Introduction When explanations include multiple media, such as text and illustrations, a reference to an object can be made through a combination of media. For example, text can refer to an illustration and not just to the physical world. We call part of a presentation that references material else- where a cross-reference. In this paper, we are concerned with how textual expressions can refer to parts of accom- panying illustrations. Cross-references can be useful in identifying clearly an intended referent to the system user when the explanation otherwise generated would not achieve this goal. For example, when providing instruc- tions for repairing a piece of equipment, an explanation can inform the user of the necessary repair action, while * This work was supported in part by the Defense Advanced Research Projects Agency under Contract NOOO39-84-C-0165, the Hewlett- Packard Company under its AI University Grants Program, the National Science Foundation under Grant IRT-84-51438, the New York State Center for Advanced Technology under Contract NYSSTF-CAT(88)-5, and the Office of Naval Research under Contracts NOOO14-82-K-0256, NOOO14-89-J-1782, and NOOO14-91-J-1872. simultaneously defining a term with which the reader is unfamiliar by using a cross-reference. (See [l] for the use of text and physical actions to fulfill multiple goals.) The illustration accompanying a cross-reference should also satisfy the specific goals of identifying and locating an object for the user. Thus, producing an effective cross- reference may entail modifying or replacing an existing illustration and in some cases, generating an illustration where previously none was needed. In this paper, we describe the different types of cross-references that COMET (Coordinated Multimedia Explanation Testbed) generates and show the roles that both its text and graphics generators play in this process. This work extends our previous work on coordinating text and graphics in mul- timedia explanation [5,6,4]. COMET generates cross-references in response to re- quests to locate an object (e.g., “Where is cx>?“), and in situations in which the user model indicates that the user does not know the name commonly used to refer to an object and the explanation would otherwise not identify the referent clearly for the user. We have identified two basic forms of cross-reference, both of which are sup- ported in COMET. Structural cross-references refer to the structure and layout of an illustration, and content cross-references refer to the content of an illustration. COMET’s content cross-references can refer to spatial relations between objects shown in an illustration, to spa- tial relations relative to the illustration itself, and to special graphical features of the illustration (e.g., the use of high- lighting or of a cutaway view). In COMET, cross-referencing is a cooperative task shared by the medium doing the referencing and the medium being referenced. When a cross-reference to an illustration is generated, COMET’s graphics generator may modify the illustration it would otherwise generate to identify clearly the object to which the cross-reference refers. The graphics generator can accomplish this through a variety of techniques, including highlighting, cutaway views, insets, and changes in camera specification [16,7]. In the following sections, we first McKeown, et al. 9 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Figure 1: COMET components used in cross-referencing. provide an overview of how cross-references are generated and then describe a set of examples that illustrate the dif- ferent forms of cross-reference implemented in COMET and the roles played by the text and graphics generators in accomplishing them. Overview Those components of COMET that play a role in cross- reference generation are shown in Figure 1. (A more detailed overview of COMET’s architecture is provided in [6].) On receiving the user’s request for an explanation, COMET’s content planner is invoked first to determine what information to include from COMET’s underlying knowledge bases. Its output, a hierarchy of logical forms (LFs), is passed to the media coordinator, which annotates the LFs with directives indicating which information is to be realized by each of a set of media generators. COMET includes both a graphics generator (IBIS [15]) and a text generator [lo] that produce the explanation’s illustrations and text from the LF segments that are assigned to them. IBIS is a rule-based system that designs illustrations that satisfy a set of input communicative goals [ 161. The text generator comprises two modules, the lexical chooser [ll], which selects the words to be used in the text, and the sentence generator, implemented in FUF [2,3]. User input is obtained through a simple menu interface, which is not shown in this figure. Cross-references are generated by a module of COMET’s media coordinator, the cross-reference generator. The need for a cross-reference is determined by both the content planner (on receiving a “where” ques- tion) and by the lexical chooser (when the user model indicates that the user is unfamiliar with the way an object is commonly describedl). Thus, the cross-reference gener- ator can be invoked either from the content planner or indirectly from the lexical chooser. In constructing a cross-reference, the cross-reference generator communicates with IBIS. IBIS maintains a representation of its illustrations that the cross-reference generator can query to determine for any illustration what objects are directly and indirectly visible in it, what special graphical features it employs, and how IBIS has conveyed its goals. Any of this information may be used in the cross-reference. In addition to answering these queries, IBIS also notifies the cross-reference generator each time the display changes (i.e., each time a new illustration or set of illustra- tions is drawn, or an old one is modified). Thus, com- munication between IBIS and the cross-reference gener- ator is bidirectional. The cross-reference generator also queries the knowledge base to include taxonomic and in- herent locative relations (e.g., that the holding battery is typically found inside the holding battery compartment). When the content of the cross-reference is complete, the cross-reference generator, if necessary, invokes IBIS to modify the existing illustration (or to create a new one satisfying a set of goals); upon successful completion, the text generator is called. This is to ensure that the goal that IBIS has been given has been successfully achieved. The text generator receives a new LF segment from which a clause or full text will be generated. As an example of the overall flow of control, consider the following situation, in which the lexical chooser deter- mines that a cross-reference is needed. COMET receives a request for an explanation through its menu interface. In our current domain, this will be a request for help in troubleshooting a specific problem the user is experiencing with a military communications radio. The content of the explanation is constructed by the content planner and con- sists of a hierarchy of LFs. The hierarchy will ultimately be realized as an explanation with one or more substeps, each of which may consist of one or more illustrations with accompanying text. The LFs are annotated by the media coordinator and passed to both text and graphics generators, which begin processing the LFs. In selecting words for the explanation, the lexical chooser may determine from the model of user vocabulary that the user is not familiar with the way in which the lexical chooser will refer to an object. When this happens, further processing of text is suspended, the lexical chooser reinvokes the content planner (mediated by the media coordinator), the cross-reference generator is called, and cross-reference generation begins. When the content is complete, IBIS and the text generator are requested to real- ize this portion. When the generation of additional text and the modification of the illustration have been completed for the cross-reference, each media generator resumes processing the original LFs where it left off. In the follow- ing sections, flow of control is further illustrated with specific examples from COMET’s domain. ‘This may be either a name (e.g., “the FCTN knob”) or a definite description based on taxonomic knowledge (e.g., “the holding battery cover plate”). 10 Explanation and Tutoring I install the new holding battery. Step 2 of 6 Remove the old holding battery, shown in the cutaway view. Figure 2: Explanation to remove the holding battery. A cross-reference is generated as part of an explanation when COMET determines that the user does not know the way an object is commonly described (either its name or unmodified definite description determined using taxonomic knowledge). For example, when instructing the user to remove the radio holding battery, COMET first generates the overview sentence, “ the old holding battery.” No accompanying illustration is generated since this action involves many substeps. If the user requests more detail on how to remove the old holding battery, however, COMET will generate a sequence of explana- tions, thus allowing the user to avoid this extra detail if it is not needed. In generating the overview sentence, when COMET text generator selects the reference “ battery,” it checks the user model to determine if the cur- rent user knows this term. If not, it calls the media coor- dinator, which in turn calls the content planner to replan the reference. One option for the content planner is to generate a cross reference that will identify the holding battery for the user.2 In this case, generating a cross-reference involves both generating a textual reference to an illustration and generating the illustration since none existed previously. The cross-reference generator invokes IBIS with the com- municative goal of showing the holding battery. Since the holding battery is inside the radio, other objects block it, *In situations where an accompanying illustration already uniquely identifies the object, an additional cross-reference is not generated. If the unknown term is one that cannot be depicted graphically, COMET generates an alternative wording that does not use unfamiliar words [ 111. and IBIS decides to generate a cutaway view, as shown in Figure 2. The cross-reference generator queries IBIS representation of the illustration to determine what, if any, special graphical features are used, what objects are visible, and which ones are either obstructed or not shown. Only one form of cross-reference is selected since it is to be generated as part of a complete sentence and should be concise. Graphical features are typically the easiest to refer to textually and the most salient for the user, and therefore one is used here. The text generator produces the final sentence including the cross-reference, “ the old holding battery, shown in the cutaway view.” If the user model indicates a vocabulary gap in an explana- tion that was designed to use illustrations, the cross- reference generator does not need to invoke IBIS to generate a new illustration. Instead, it directly queries IBIS for information about the existing illustrations. This infor- mation can be especially rich when IBIS generates a composite illustration, which can be a sequence of illustra- tions or a larger illustration with one or more embedded insets. IBIS creates a composite illustration when it can- not satisfy directly all goals it is given by creating a single simple illustration. If the explanation includes a com- posite illustration, COMET must refer to the structure of the layout in order that the user understand which object is being referenced, since the same object may appear in more than one of the illustrations in the composite. The cross-reference generator can query IBIS for the dimen- sions and position of the illustrations (in display coor- dinates), as well as the way in which illustrations relate to one another. This information can be used to generate McKeown, et al. 11 Remove the old holding battery. Step 1 of 2 Step 1: Remove the holding battery cover plate, highlighted in the right picture: Loosen the captive screws and pull the holding battery cover plate off of the radio. Figure 3: Explanation to remove the holding battery cover plate. cross-references that, for example, refer to the part of the display on which the illustration is located or mention that an illustration is an inset of another. Consider, for example, the first step in the explanation of how to remove the old holding battery, shown in Figure 3. If the lexical chooser finds that the user is not familiar with the default description ( battery cover plate”), it reinvokes the content planner (by means of the media coordinator), which in turn calls the cross-reference generator. The cross-reference generator searches for graphical features that uniquely identify the cover plate in one of the illustrations. Finding that the cover plate is the only object highlighted in the right illustration, it replans the reference to the cover plate, which becomes: “ the holding battery cover plate, highlighted in the right picture: “ In this case, a combination of information about both the illustration ’ visual efsects and its layout is ex- plicitly used to disambiguate the textual reference. Generating Spatial Relations in Gross-References In the previous examples, COMET generated a cross- reference when the user model indicated a gap in the user ’ s vocabulary. However, cross-references are also generated when the user asks a follow-up question to an explanation, requesting the location of an object. COMET includes a menu interface that allows a user to ask about the location of objects referred to in the current explana- tion, as well as objects referred to in the immediately preceding explanation. When responding to a “ where ” question, COMET uses more than one type of cross- reference in its response. In particular, it will include spa- tial relations between the object in question and another salient object, and/or spatial relations between the object 12 Explanation and Tutoring and the illustration layout. These spatial relations allow the user to identify the location of the object on the real radio as opposed to just the illustration, by providing a road map from a known, or quite salient object, to the object in question. For example, suppose that the user already knows what a holding battery cover plate is and the text in Figure 3 does not include the cross-reference “ in the right picture”. Following this explanation, the user could ask the follow-up question “Where is the holding battery cover plate? using the menu interface and COMET would generate the following textual response: “ the left il- lustration, the holding battery cover plate is shown at the top left. In the right illustration, the holding battery cover plate is highlighted.” This cross-reference includes references to both illustra- tions, selecting the best feature of the illustration for each reference. For the right illustration, the cross-reference is the same as is generated for a vocabulary failure. For the left illustration, the cross-reference cannot contain any unique graphical feature of the holding battery cover plate since none has been recorded by IBIS. In this case, it selects a spatial relation between the plate and the radio itself (an object the user certainly can find), determining that the plate is in the top left of the radio. To do this it first queries the domain knowledge base, and determines that the holding battery cover plate is located at the bottom right of the radio. Then, as the holding battery cover plate is to be located with reference to the radio in the illustra- tion, the radio orientation relative to the camera is ob- tained from IBIS. The radio is upside down, so the description of the holding battery cover plate is updated to read: “ holding battery cover plate is shown at the top left of the radio.” Load the frequency into channel one. Step b2Of4 igure : Explanation to set the MODE knob to SC. The cross-reference generator next determines the loca- tion of the holding battery cover plate relative to the il- lustration. It finds that the holding battery cover plate is at the top left of the illustration (using a bounding box ap- proach, similar to that of [S]), which results in the follow- ing, somewhat clumsy, text: “ holding battery cover plate is shown at the top left of the radio at the top left of the picture.” Since there are multiple references to the location of the object being at the top left, it is possible to conflate them without the resulting ambiguity causing problems. The final form of the text is, “ holding bat- tery cover plate is shown at the top left.” COMET can also recover when an initial cross-reference fails. Consider the following situation where the user repeatedly does not understand the referent of “ the MODE knob.” The user is being instructed to “ Set the MODE knob to SC ” during the course of a session. Figure 4 shows COMET ’ explanation, which includes an illustra- tion. IBIS opted to highlight the knob and center it, and has generated an arrow indicating how the knob is turned. Showing the location of the knob is a low-priority goal; consequently there is limited contextual information show- ing the location of the knob in this illustration. IBIS chose to indicate the knob ’ location through the use of landmarks (unique neighboring objects), such as the but- tons on the radio ’ keypad. Even though the illustration was designed to identify the MODE knob, the user issues the query “Where is the MODE knob?” using COMET ’ menu interface. The cross-reference generator selects a cross-reference that uniquely refers to the knob based on its appearance in the illustration. It determines that the knob is the only object that has been highlighted in the illustration and sends this information to the text generator. COMET produces the sentence, “ MODE knob is highlighted.” This replaces the text originally displayed below the illustration. Although the user may see the highlighted knob in the illustration, the knob location on the radio may still be unclear. The user asks again, “Where is the MODE knob?” The cross-reference generator determines that the generated textual cross-reference has failed and sends a request to IBIS that the location goal for the MODE knob be assigned a high priority. IBIS handles this request as a new constraint and searches for a method to satisfy it. In this case, IBIS rules cause it to augment the existing illustration with an inset illustration that is designed to satisfy the single goal of showing the MODE knob loca- tion with high priority. This inset illustration is generated with the added con- straint that its visual effects be achieved in the same man- ner as in its parent illustration, maintaining consistency between the two illustrations. One way IBIS shows loca- tion is by selecting a context object and depicting the ob- ject to be located within this context. Here, the radio serves as the context object; and the inset inherits this property. IBIS assigns very high priority to the goals for the radio ’ visibility and recognizability and a lower priority to the MODE knob visibility and recognizability. Consequently, IBIS selects a view that shows the radio in its entirety. To draw attention to the knob, IBIS highlights it, using the same highlighting method as in the parent illustration. IBIS notifies the cross-reference generator that it has added an inset illustration to the display and that this inset is a child of the illustration showing the state of the knob. McKeown, et al. 13 1 Load the frequency into channel one. Step 2 of 4 The highlighted MODE knob is shown in the inset. Figure 5: Explanation of the MODE knob location, generated after a previous cross-reference fails. The cross-reference generator makes two determinations: 1) there is only one inset (it is unique and need not be differentiated from the parent illustration or other insets) and 2) only the MODE knob is highlighted in the inset. COMET outputs the cross-reference: “ highlighted MODE knob is shown in the inset.” The modified illustra- tion and the new text are shown in Figure 5. Related Work Several other projects support cross-references from text to graphics. SAGE [14], a system that explains quantitative models, generates cross-references to call a user ’ atten- tion to a particular picture or to a new graphical encoding technique, or to answer a user ’ questions about what parts of a figure support a textual statement. In SAGE, a description of the content to be communicated is first processed by the text generation component, which an- notates the content description to correspond to an outline of the text to be generated, passing it to the graphics com- ponent. The graphics component designs the pictures and annotates the content description to index them, and passes the content description back to the text generation com- ponent, which then generates text that includes cross- references to the pictures. An important difference in COMET ’ approach is that a illustration may be reused, incrementally redesigned or totally replaced to make a cross-reference possible or better, if the media coordinator deems it necessary. The CUBRICON [ 131 multimedia map system generates several kinds of cross-references in speech to direct a user ’ attention to its maps. One kind refers to which of CUBRICON ’ multiple displays is being used and to the kind of information presented; it is generated to call attention to changes in the material presented on a 14 Explanation and Tutoring display. CUBRICON also uses speech to describe its ap- proach to encoding information, such as the kind of high- lighting used. Another kind of cross-reference is used to refer to specific graphical objects on a map; for example, “ airbase is located here <point>,” where “ is indicated by blinking the airbase icon when speaking “ Unlike COMET, CUBRICON seems to use only this last kind of cross-reference to refer to a specific object in a map, rather than choosing from a set of cross- reference approaches. Recent work on cross-referencing in WIP [ 171 focuses on how to compute textual expressions for referring to complex spatial relations between pairs of objects and be- tween an object and its picture. imitations COMET currently can provide multimedia explanations of any of over 50 complex actions represented in its knowledge base. These actions can refer to more than 200 represented objects. The techniques for cross-referencing described here are general and can be applied to any object referenced in an explanation. COMET can fail in two ways in producing a cross-reference: it can produce an unneeded cross-reference (i.e., one in which the user already knows the identity or location of the referenced object) or it can fail to generate a needed cross-reference. In the first case, the user will receive more information than is needed; if COMET consistently overproduces cross-references, the user is likely to become frustrated with verbose, obvious explanations. In the second case, however, the user can always ask about the location of an object as a follow-up question to the explanation. Since we currently assume that COMET user model is given as input, and the model must explicitly indicate when an object is not known, COMET tends to fail by undergenerating cross-references unless explicitly requested. We think this is the better approach because the user can always receive a cross- reference in response to a follow-up question. Couchsims and Future We have demonstrated a set of cross-reference techniques for referring to graphics from text that can make possible explanations that are more understandable than explana- tions without cross-references. We have emphasized the notion of cross-referencing as a two-part process involving both the generation of text that can refer to a variety of features of an illustration, and the analysis and possible generation, modification, or even replacement of the il- lustration being referenced. When an explanation contain- ing a cross-reference fails (as indicated by user inter- action), COMET can recover by redesigning one or both of the text that makes the cross-reference and the illustra- tion to which the text refers. There are several directions that we are interested in exploring. While we have discussed a variety of cross- references from text to graphics, cross-references from graphics to text are also possible. A true cross-reference requires some act of referring. In contrast to the rich set of textual devices for deixis, there is a relatively small, but powerful, set of graphical mechanisms that may be used for explicit reference. One example is an arrow that points from graphics to text, such as a “danger” icon with an arrow emanating from it that points to a textual warning that explains the danger. Weaker examples, in which the act of referring is implicit, rather than explicit, are the placement of a “danger” icon near a warning or the use of a colored surround to highlight a warning [ 1 S]. There are several ways in which a user’s interaction with the graphics might provide useful information for text generation, and in particular for cross-referencing. While COMET’s user can ask questions about objects through menu picking, the user should also be able to point to both the text and the illustration. Pointing raises a number of interesting issues (e.g., see [9], [12], and [13]), including disambiguating the object to which the user is pointing and the scope of the point. The way in which the system understands the user’s pointing action might be made clear to the user through the use of an appropriate textual cross- reference, accompanied perhaps by graphical highlighting. We have augmented parts of COMET to support picking in both text and graphics to allow us to explore some of these issues. We are particularly interested in developing principled criteria for determining when to use different kinds of cross-references and how to choose among specific in- stances. For example, would it be better to refer to the holding battery compartment as being “below the holding battery cover plate” or “at the top left of the radio”? What factors influence the choice, and how can we evaluate fac- tors such as visual salience? What are the tradeoffs be- tween potentially competing factors such as salience and concision? Finally, while we have catalogued the different kinds of explanations that COMET can produce, we have not evaluated COMET with real users to determine how well its explanations meet their needs. Clearly, evaluation is needed, and how to do this is a research issue in itself that we plan to address in the near future. WV ents COMET is an ongoing group project whose other par- ticipants have included Michael Elhadad, Andrea Danyluk, Yumiko Fukumoto, Jong Lim, Christine Lombardi, Michelle Baker, Cliff Beshers, David Fox, Laura Gabbe, Frank Smadja, and Tony Weida. [II 121 [31 141 [a [61 [71 PI Appelt, D.E. Planning English Sentences. Cambridge University Press, Cambridge, England, 1985. Elhadad, M. Extended Functional UniJCication ProGrammars. Technical Report, Columbia University, New York, NY, 1989. Elhadad, M. Types in Functional Unification Grammars. In Proc. 28th Meeting of the Association for Computa- tional Linguistics. Pittsburgh, PA, June, 1990. Elhadad, M., Seligmann, D., Feiner, S., and McKeown, K. A Common Intention Description Language for Inter- active Multi-Media Systems. In A New Generation of Intelligent Inter$aces: Proc. IJCAI-89 Workshop on Intelligent Inteeaces, pages 46-52. Detroit, MI, August 22, 1989. Feiner, S. and McKeown, K. Coordinating Text and Graphics in Explanation Genera- tion. In Proc. AAAI-90, pages 442-449. Boston, MA, July 29-August 3, 1990. Feiner, S. and McKeown, K. Automating the Generation of Coordinated Multimedia Explanations. IEEE Computer 24( 10):33-4 1, October, 199 1. Feiner, S. and Seligmann, D. Dynamic 3D Illustrations with Visibility Constraints. In Patrikalakis, N. (editor), Scientific Visualization of Physical Phenomena (Proc. Computer Graphics In- ternational ‘91, Cambridge, MA, June 26-28, I991), pages 525-543. Springer-Verlag, Tokyo, 199 1. Friedell, M. Automatic Graphics Environment Synthesis. PhD thesis, Case Western Reserve University, 1983. Computer Corporation of America Technical Report CCA-83-03. McKeown, et al. 15 l-91 UOI El11 [121 iI31 Kobsa, A., Allgayer, J., Reddig, C., Reithinger, N., Schmauks, D., Harbusch, K., and Wahlster, W. Combining Deictic Gestures and Natural Language for Referent Identification. In Proc. 11 th Int. ConJ: on Computational Linguistics, pages 356-361. Bonn, Germany, 1986. McKeown, K.R., Elhadad, M., Fukumoto, Y., Lim, J., Lombardi, C., Robin, J., and Smadja, F. Language Generation in COMET. In Mellish, C., Dale, R., Zock, M. (editors), Current Research in Language Generation. Academic Press, London, 1990. McKeown, K.R., Robin, J., and Tanenblatt, M. Tailoring Lexical Choice to the User’s Vocabulary in Multimedia Explanation Generation. Technical Report, Columbia University Department of Computer Science, 1992. Moore, J. and Swartout, W. Pointing: A Way Toward Explanation Dialogue. In Proc. Eighth National Conference on Artificial Intelligence, pages 457-464. Boston, MA, July 29-August 3, 1990. Neal, J. and Shapiro, S. Intelligent Multi-Media Interface Technology. In Sullivan, J. and Tyler, S. (editors), Intelligent User Znter$aces, pages 1143. Addison-Wesley, Reading, MA, 1991. Roth, S., Mattis, J., and Mesnard, X. Graphics and Natural Language as Components of Automatic Explanation. In Sullivan, J. and Tyler, S. (editors), Intelligent User Inte$aces, pages 207-239. Addison-Wesley, Read- ing, MA, 199 1. Seligmann, D. and Feiner, S. Specifying Composite Illustrations with Communicative Goals. In Proc. LUST ‘89 (ACM SIGGRAPH Symp. on User Inte$ace Sofnyare and Technology), pages l-9. Wil- liamsburg, VA, November 13-15, 1989. Seligmann, D. and Feiner, S. Automated Generation of Intent-Based 3D Illustrations. In Proc. ACM SIGGRAPH ‘91 (Computer Graphics, 25:4, July 1991), pages 123-132. Las Vegas, NV, July 28-August 2, 1991. Wazinski, P. Generating Spatial Descriptions for Cross-Modal References. In Proc. 3rd Co@ on Applied Natural Language Processing. Association for Computational Linguis- tics, Trento, Italy, April, 1992. Young, S.L. Comprehension and Memory of Instruction Manual Warnings: Conspicuous Print and Pictorial Icons. Human Factors 32(6):637-649, December, 1990. 16 Explanation and Tutoring | 1992 | 2 |
1,210 | George Berg Computer Science Department State University of New York at Albany, LI-67A Albany, NY 12222 USA Abstract In order to be taken seriously, connectionist nat- ural language processing systems must be able to parse syntactically complex sentences. Cur- rent connectionist parsers either ignore structure or impose prior restrictions on the structural com- plexity of the sentences they can process - ei- ther number of phrases or the “depth” of the sentence structure. XERIC networks, presented here, are distributed representation connectionist parsers which can analyze and represent syntacti- cally varied sentences, including ones with recur- sive phrase structure constructs. No a priori limits are placed on the depth or length of sentences by the architecture. XERIC networks use recurrent networks to read words one at a time. RAAM- style reduced descriptions and X-Bar grammar are used to make an economical syntactic representa- tion scheme. This is combined with a training technique which allows XERIC to use multiple, virtual copies of its RAAM decoder network to learn to parse and represent sentence structure us- ing gradient-descent methods. XERIC networks also perform number-person disambiguation and lexical disambiguation. Results show that the net- works train to a few percent error for sentences up to a phrase-nesting depth of ten or more and that this performance generalizes well. Introduction One of the biggest challenges facing proponents of connectionist models of natural language processing (NLP) is the rich structure of language. In most lin- guistic theories, a sentence consists (in part) of vari- ous types of phrases which are themselves composed of other phrases and/or words. This structure also helps constrain the semantics or meaning of the sen- tence (e.g. what elements fill the Agent, Patient, In- strument, etc. semantic case roles; to what other el- ement(s) in the sentence may a pronoun legitimately refer). To be taken seriously as models of NLP, connection- 32 Learning: Constructive and Linguistic ist systems must either use structure and structurally- sensitive processing, or demonstrate an alternative explanation of the same phenomena. Recently, re- searchers have addressed some of these issues. How- ever, their systems have a priori limits on the sentence structures they support. In this paper, we introduce the XERIC Parser, a connectionist syntactic analyzer which places no prior limit on the extent of the struc- ture of a sentence. In practice its limitations seemingly reflect the actual structures of the training data and the limitations of the network’s training regimen and finite representation. Structure in Connectionist NLP One of the underlying tenets of the modern cognitive sciences is that human languages have a form and con- straints on their meanings which are well-accounted for by assuming that syntactically and semantically they have a compositional structure and that this struc- ture affects the meaning of the sentences in the lan- guage. And, as put forth most forcefully by Fodor and Pylyshyn (1988), ‘t 1 is difficult to capture this notion of structure and structure-sensitivity in connectionist models of NLP. Despite their use of strawmen to make their case, Fodor and Pylyshyn did indeed have a point - many early connectionist models used representa- tions which were flat - there was no principled way to model the relationships between elements in their representations. And the methods proposed in these models to account for ordering and structured rela- tionships either were ad hoc, lacked systematicity, or were subject to combinatorial explosion if scaled up. Since the time of their paper, however, several gen- eral approaches have emerged for connectionist models to account for structure (cf van Gelder, 1990). And several connectionist NLP systems have used these techniques. Miikkulainen (1990) uses recurrent net- work architectures (discussed below) as the basis for his parsing system. Jain [Jain and Waibel, 19901 uses gating networks to similar effect. In both cases, encod- ings of words are presented to the network one after an- other in sequence, and the recurrence or gating in the network architecture provides a context which allows From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. A (S pecifier)*A X (Complement)* (Head) boy A with a dog Figure 1: The X-bar template and an instantiated NP. the networks to build representations for the sentences. However, both Jain and Miikkulainen constrain the types of structure which their networks accommodate. Jain’s parser has a fixed limit on the number of phrase- like structures which it can represent. To represent a larger number, his network would have to be expanded by adding more of his modular representation units. In Miikkulainen’s parser, the number of structures which can be represented is hard-wired into the network’s ar- chitecture; to change it, the entire network would have to be altered and retrained. In fairness, both of these systems were designed to address other aspects of con- nectionist NLP, not the problem of the representing structure in general. The XERIC In contrast, in the XERIC parser the X-Bar theory of grammar and recurrent connectionist networks are combined to produce a network with no a priori limit on the length of the sentence or the depth of the re- sulting structure. What limits there are are due to limits of the “resolution” of the fixed-length vector of units which encodes the reduced representation of the sentence structure. In addition, the parser does lexical disambiguation and propagates the number/person constraints in the sentence. And, in common with most other connec- tionist parsers, the XERIC parser, because of its re- current, feed-forward architecture, parses in time pro- portional to the length of the sentence. Underlying Concepts In contrast to the phrase-structure rules of traditional theories of sentence structure, X-Har grammar uses a single structure for all phrases - the X-Bar template [Sells, 19851. This template is instantiated to provide all of the structures needed, from simple Noun Phrases (NPs) to entire sentences. The template’s instantiation for a particular phrase is determined by the interaction of what is allowed in the phrase, as given in the lex- ical entry for the head word of the phrase, and what elements are actually provided in the sentence. For ex- ample, in Figure 1 the X-bar template indicates that a phrase may have zero or more specifiers, one head word and zero or more complements. An example instanti- ation for the NP “the boy with a dog” is also shown in the figure. In this phrase, the head noun, “boy” allows the determiner “the” as a specifier and the em- bedded Prepositional Phrase (PP) “with a dog” as a complement. This is in contrast to a NP whose head is a pronoun (e.g. “I”, “them”) which allows neither determiners nor PPs. The ample information in the lexicon and the sim- plicity of the X-bar template provide a “grammar” which constrains the allowed structures for a partic- ular sentence. This is more economical than phrase structure grammars, where information which must be in the lexicon is redundantly introduced in the specific phrase structure rules. And the large number of rules it takes to account for the variety of forms a partic- ular phrase may take (e.g. Verb Phrases) is simply a manifestation of the varying requirements of the head words of the phrases. In order to capture the sequential nature of pars- ing, some mechanism must be provided which allows a connectionist network to capture both the sequen- tial “reading” of the words in the sentence, and to maintain some representation of partially read sen- tences. One technique (used by Miikkulainen) is the sequential or simple recurrent network [Jordan, 1986; Elman, 19901. In a typical recurrent network, the acti- vation levels of the hidden units at time t are presented as part of the input to the network at time t +- 1. This gives the network a “history” or “context”, so that the input at time t + 1 can be processed in light of what in- puts have been presented at earlier times [Cleeremans et al., 19891. Jordan Pollack has used a variation on the recurrent network to build connectionist network models of in- herently structured representations such as stacks and queues. In his RAAM model [Pollack, 19901, he uses Berg 33 INPUT LAYER OUTPUT LAYER Figure 2: The basic structure of the XERIC parser network. a 2m x m x 2m architecture to build representations of binary trees. Terminal symbols are encoded using m units. The network is trained to recreate its input on its output units. The m hidden units encode the information to recreate the activations of the 2m out- put units. The hidden unit values can then be used as new, nonterminal inputs to subsequently encode more complex binary trees. The process can be reversed, by repeatedly feeding an encoding to the latter half of the network (the decoder) until terminals are found at both parts of the output. From an initial vector of m units, this process can retrieve the tree structure that it encodes. XERIC’s Basic Network Structure XERIC combines X-bar syntax, recurrent networks and a RAAM-style reduced encoding. The basic archi- tecture is shown in Figure 2. The input to the network is an encoding of the features of the current word. The hidden layer units’ activation values from the last time step are presented as context input this time step. The activation feeds forward through the three hidden lay- ers to the output layer. The structure of the output layer is based on a simple form of the X-Bar template used in XERIC: a phrase may have one specifier, one head word, and up to two complements.’ The head position is the same size as the word encodings, and is used to represent the head word of a phrase (or null). The complements are either encodings of component phrases or nulls. The specifier may encode either a word (e.g. a determiner such as “the”), a phrase, or null. When parsing, the XERIC parser is started with all of the context units set to a predetermined null value (e.g. 0.5). The lexical encoding of a word is presented and activation feeds forward through the network. For each subsequent word in the sentence, the lexical en- ‘This form of X-bar grammar is admittedly oversimpli- fied (cf Fukui and Speas, 1986). However, it is adequate for XERIC, and can in principle be generalized. 34 Learning: Constructive and Linguistic coding for the word is presented as input, along with the hidden unit activation values from the previous step. After the last word of the sentence has been pre- sented as input, and activation fed forward through the network, the hidden layer units’ activations are an encoding of the representation of the entire sentence. The structure of the sentence can be shown explicitly by using the “back half” of the network (the hidden, decoder and output layers) as a RAAM-style decoder. Feeding the activations of the encoding of a simple declarative sentence to the decoder will yield an en- coding of the sentence’s subject NP in the specifier position, sentence inflection information in the head position, an encoding of the sentence’s VP in comple- ment position 1, and null values in complement po- sition 2 (indicating that there is no element in this position). The encodings of component phrases can be presented to the decoder to give their phrasal com- ponents. To get the structure of the entire sentence, simply continue this process until all of the phrases give null values for their specifier and complements. This is similar to the approach that Hinton (1988) takes in descending through a similarly-represented part/whole hierarchy. It is the relationship between the X-Bar template and the lexical entry for the words in the sentences that makes an X-Bar approach to parsing attractive. The template is simple, and its variations are constrained by the information in the lexicon and what words are actually in the sentence. Since we are using a fixed network, and a fixed length vector of units to encode representations (the hidden layer in Figure 2)) the po- tential economy of this method of representing struc- ture is a critical feature of the model. Our use of a RAAM-style recursive encoding allows us to train our network to attempt to encode potentially arbitrarily- deep structures. Of course, limitations of the training methods used and on the ability of network units to en- code information will put some sort of bound on what XERIC-style networks can successfully parse and rep- resent. We hoped that these bounds would not be too t t t t a dog a fork Figure 3: The “unrolled” network for the sentence “the boy with a dog ate spaghetti with a fork.“. Unlabeled phrases at the output level are empty. tight and that the XERIC networks could parse sen- tences with deep and varied structure. As we indicate below, experiments show that this hope is vindicated. Unrolled training Architecture The basic architecture of a XERIC parsing network must be augmented in order to train it. Since one of the goals of this work is that the training of the network result in it developing an encoding scheme in order to represent the structure of the sentences and component phrases, we do not know a priori the repre- sentation scheme for specifiers and complements, and hence what the target activation values for the non- null phrases should be. In order to get around this problem, the network used in training is actually a number of virtual copies of the decoder portion of the actual XERIC parsing network. As shown in Figure 3, using multiple copies of the network to emulate a net- work which completely matches the structure of each sentence allows the training to have only word encod- ings and nulls at the output layers. The training regi- men is then free to determine phrase encodings at the (replicated) hidden layers. By slaving all of the vir- tual copies of the network to the actual one so that all weight changes due to learning are applied to the one actual XERIC network, we retain the function of the back half of the XERIC network as the general-purpose phrase decoder described above.2 2This technique is similar in form, if not in purpose, to “back-propagation through time” [Rumelhart et al., 1986]. t her Features In many cases, a word in isolation is lexically ambigu- ous. For instance, the word “drive” may either be a noun or a verb. In XERIC networks, such words are presented as input in an ambiguous form. One of the tasks the network performs is to disambiguate such words. Depending on where in the sentence an am- biguous word is read, it is disambiguated to its proper form. In addition, the XERIC network also propagates number and person agreement between the subject noun phrase and the sentence’s main verb. As the head noun and the main verb are read, they constrain each other as to what number and person values they may legitimately have (e.g. “the sheep are” constrains sheep to be third-person plural, whereas “the sheep is” must be third-person singular). The size of phrases is 45 units. Because of the recur- rent mappings this is also the size of the hidden layer and its recurrent mapping at the input layer.3 A lex- ical entry (used at the word part of the input and for phrase heads at the output layer) is encoded using 35 units.4 Most of the units in word encodings represent 3The encoder layer is currently 62 units and the decoder layer 108 units. 4When the element in a specifier is a word (e.g. a deter- miner), the encoding only uses 35 units, the others being set to a null value. XERIC has a “mode bit” unit to indi- cate whether the specifier contains a word, a phrase or is null. Berg 35 linguistic features. Typical features are the syntactic category of the word (e.g. noun, verb, preposition), its number/person (e.g. first-person plural, third-person singular), and various category-specific features. For nouns, these include whether or not a noun is a pro- noun, an anaphor, a proper-noun, etc. For verbs, the features include the tense, whether it takes a direct and/or indirect object, etc. The unit has a value of one if a feature is present, a value of zero if it is ab- sent, and a value of 0.5 if it is either optional or un- clear. An example of an optional feature is a verb that may optionally take a direct object. An example of an unclear feature would be the features “noun” and “verb” in the encoding of a word where its category is initially ambiguous. The lexical encoding for each word also contains a g-unit “ID code” which uniquely distinguishes each word, apart from its syntactic fea- tures. verge best with low learning rate values (typically using 0.01 5 ‘I 2 0.05) and using no momentum term (i.e. a = 0). The simulations for training and running XERIC are written in C and run on SUN SPARCstation 1 work- stations. XERIC networks train at about 1.5 hours per epoch. This relatively slow rate of speed is due to the large size of the corpora, the depth of the virtual networks and the relative complexity of the software necessary to implement the virtual network training. Results and XERIC networks typically converge to l-S% overall error for both training and testing corpora (where an error is a unit which deviates from its target value by a certain amount, e.g. 0.2). It typically takes a network 500-1500 epochs to reach a rough asymptote for error values. XERIC networks train to correctly encode the structure of all but the most atypical or extremely deep sentences it parses. Most of the errors are lexical in nature - incorrect word ID codes or syntactic features. These errors increase as more of the sentence is read. They also increase with the depth of the nesting in a sentence’s structure. Testing on corpora other than the one on which a network was trained shows only minor increases in error percentages for sentences of depth up through ten. Testing and training are done on separate corpora each containing the patterns for 1000 sentences. The average sentence is between 6.5 to 7 words long, re- sulting in corpora containing between 6500 and 7000 patterns. The corpora contain sequential presentations of randomly generated, syntactically legal sentences. There is no restriction on the length or “depth” of the generated sentences, although the random selection is biased slightly against complex phrases. This results in most of the sentences being between 2 and 8 phrases deep, with fewer sentences of greater depths, typically with a maximum between 14 and 20. Since the lexical entries do not contain semantic in- formation to do PP-attachment disambiguation, the generator restricts the sentence forms for verbs which subcategorize for both a direct and an indirect object. In these cases, the direct object NP (in the VP’s compl position) will be simple - it will contain no embedded phrases. This way there is no phrase attachment ambi- guity. The first NP after the verb will be the verb’s di- rect object, and the following PP (and any subsequent phrases) will be part of the verb’s indirect object. This is in contrast to the general case where the direct ob- ject may be a NP with embedded component phrases. Without semantic information it is impossible to tell in general whether following PPs belong to the direct object NP or are the beginning of the verb’s indirect object. Training XERIC Networks In the corpora, the target outputs for each pattern are the “unrolled” network outputs (cf Figure 3) of as much of the information in the sentence as can be de- termined from the words read so far (along with what- ever disambiguation can be inferred from the partial sentence). These results suggest that the reduced description of the sentence, which is the heart of this architecture, is an “information bottleneck”. Intuitively, either the limitations of the learning algorithm, or the inability of a finite floating-point simulation of a fixed-size network to represent more than a certain amount of information causes this to be harder for the network to store and reproduce. We are currently analyzing this. The training method used for the XERIC parser is error backpropagation [Rumelhart et al., 19861. Despite their ability to represent complicated and varied sentence structure, the current generation of Weight updates are done after every pattern presenta- XERIC networks are not general NLP models. They tion. Investigation has shown that the networks con- are very specifically designed to explore the need to For the best XERIC networks, the overall error at the end of a sentence varies between 1% to 9% as the nesting depth of the sentence increases from 2 to 10 in the training corpus. For the same network a typi- cal testing corpus will have error rates of from 1% to 11% in this range. The error rates increase roughly in proportion to the depth in both cases. Beyond a depth of 10, error rates vary greatly from 5% to IS%, possibly reflecting memorization of the small number of exemplars or limits to the ability of the networks to represent these very deep sentences. The 18 units at each phrase output layer which rep- resent the word IDS account for 52.7% of the errors in the training corpus and approximately 50% for testing corpora. Since these units account for only 10.5% of the total number of output units, a disproportionate amount of the error of XERIC networks is due to the network’s inability to correctly reproduce the IDS of the words it reads. 36 Learning: Constructive and Linguistic represent the syntactic structure of sentences. In one sense, these networks are only a prerequisite for con- nectionist NLP systems. We do however plan to use them as the basis for more complex parsers and ana- lyzers. We are currently working on several approaches to improve both the performance and breadth of cover- age of XERIC parsers. Using a more general X-Bar template will allow us to incorporate embedded and passive sentences as well as adjective phrases. Other elements of linguistic theory (cf Government-Binding Theory [Chomsky, 19$1]) can be used by adding more networks to constrain the sentence’s representation [Rager and Berg, 19901. We are also adding semantic analysis to the XERIC parser. This is necessary even if one is only inter- ested in syntactic structure of a sentence, because PP- attachment is, at least in part, semantically motivated. To be part of a useful NEP system, XERIC parsers must have a semantics or at least be compatible with a separate semantic analyzer. By using a sparse method of representing structure and a network architecture which, in principle, can encode arbitrarily complex structures the XERIC parsing net- works provide a model of connectionist NIP which can support the rich and varied structure of sentences in human language. Preliminary experiments show that such networks can encode in a finite network enough information to represent complex sentences with fairly deep recursive phrase structures. In addition a XERIC parser can also do lexical disambiguation and num- ber/person constraints as it parses. If the XERIC model can be augmented to handle additional syntac- tic principles and semantic representation and process- ing, then it will represent an important step forward in connectionist natural language processing. ckmowledgements An early version of this work was presented at the IJ- CAI 1991 Workshop on Natural Language Learning. I would like to thank John Munson, Judith Swota, John Rager, Andy Haas, Carl Edlund, Doug Mokry and Jor- dan Pollack for insights related to this work. The Com- puter Science Department at Rensselaer Polytechnic Institute (and in particular, Chris Welty) provided ad- ditional workstations to help make this research possi- ble. Elman, J. 1990. Finding structure in time. Cognitive Science 14:179-212. Fodor, J. A. and Pylyshyn, Z. 1988. Connectionism and cognitive architecture: A critical analysis. In Pinker, S. and Mehler, J., editors 1988, Connections and Symbols. MIT Press, Cambridge, MA. Fukui, N. and Speas, P. 1986. A theory of cate- gory projection and its applications. In Fukui, N.; Rapoport, T.; and Sagey, E., editors 1986, MIT Working Papers in Linguistics, Vol. 8. MIT Depart- ment of Linguistics and Philosophy. 128-172. Hinton, G. 1988. Representing part-whole hierarchies in connectionist networks. In Proceedings of the Tenth Annual Conference of the Cognitive Science Society, Montreal, Canada. 48-54. Jain, A.. and Waibel, A. 1990. Incremental parsing by modular recurrent connectionist networks. In Touret- zky, D., editor 1990, Advances in Neural Information Processing Systems 2. Morgan Kaufmann, San Mateo, CA. Jordan, M. 1986. Attractor dynamics and parallelism in a connectionist sequential machine. In Proceedings of the Eighth Annual Conference of the Cognitive Sci- ence Society, Amherst, MA. 531-546. Miikkulainen, R. 1990. A PDP architecture for pro- cessing sentences with relative clauses. In Proceed- ings of the 13th International Conference on Compu- tational Linguistics, Helsinki. Pollack, J. 1990. Recursive distributed representa- tions. Artificial Intelligence 46:77-105. Rager, J. and Berg, G. 1990. A connectionist model of motion and government in Chomsky’s government- binding theory. Connection Science 2(1 & 2):35-52. Rumelhart, D.; Hinton, G.; and Williams, R. 1986. Learning internal representations by error propaga- tion. In McClelland, 9.; Rumelhart, D.; and the PDP Research Group, , editors 1986, Parallel Dis- tributed Processing: Volume 1: Foundations. MIT Press, Cambridge, MA. Sells, P. 1985. Lectures on Contemporary Syntactic Theories. Center for the Study of Language and In- formation, Stanford, CA. van Gelder, T. 1990. Compositionality: A connec- tionist variation on a classical theme. Cognitive Sci- ence 14:355-384. References Chomsky, N. 1981. Lectures on Government and Binding. Foris, Dordrecht. Cleeremans, A.; Servan-Schreiber, D.; and McClel- land, J. 1989. Finite state automata and simple re- current networks. Neural Computation 1~372-381. | 1992 | 20 |
1,211 | Learning to iguate Claire Cardie Department of Computer Science University of Massachusetts Amherst, MA 01003 (cardie@cs.umass.edu) Abstract In this paper we show how a natural language system can learn to find the antecedents of relative pronouns. We use a well-known conceptual clustering system to create a case-based memory that predicts the antecedent of a wh-word given a description of the clause that precedes it. Our automated approach duplicates the performance of hand-coded rules. In addition, it requires only minimal syntactic parsing capabilities and a very general semantic feature set for describing nouns. Human intervention is needed only during the training phase. Thus, it is possible to compile relative pronoun disambiguation heuristics tuned to the syntactic and semantic preferences of a new domain with relative ease. Moreover, we believe that the technique provides a general approach for the automated acquisition of additional disambiguation heuristics for natural language systems, especially for problems that require the assimilation of syntactic and semantic knowledge. Introduction Relative clauses consistently create problems for language processing systems. Consider, for example, the sentence in Figure 1. A correct semantic interpretation should include the fact that “the boy” is the actor of “won” even though I F5- Tony saw the boy who won the award. seems a simple enough task, there are many factors that make it difficultl: The head of the antecedent of a relative pronoun does not appear in a consistent position or syntactic constituent. In both Sl and S2 of Figure 2, for example, the antecedent is “the boy.” In Sl, however, “the boy” is the direct object of the preceding clause, while in S2 it appears as the subject of the preceding clause. On the other hand, the head of the antecedent is the phrase that immediately precedes “who” in both cases. S3, however, shows that this is not always the case. In fact, the antecedent head may be very distant from its coreferent wh-word2 (e.g., S4). Sl. Tony saw the boy who won the award. S2. The boy who gave me the book had red hair. S3. Tony ate dinner with the men from Detroit who sold computers. S4. I spoke to the womb with the black shirt and green hat over in the far corner of the room who wanted a second interview. SS. I’d like to thank Jim, Terry, and Shuwn, who provided the desserts. S6. I’d like to thank our sporuors, GE and NSF, who provide financial support. S7. We wondered who stole the watch. SS. We talked with the woman and the man who were/was dancing. S9. We talked with the woman and the man who danced SlO. The woman from Philadelphia who played soccer was my sister. Sll. The awards for the children who pass the test are in the drawer. Figure 1 : Understanding Relative Clauses Figure 2 : Relative Pronoun Antecedents the phrase does not appear in the embedded clause. The interpretation of a relative clause, however, depends on the accurate resolution of two ambiguities, each of which must be performed over a potentially unbounded distance. The system has to 1) find the antecedent of the relative pronoun and 2) determine the antecedent’s implicit position in the embedded clause. The work we describe here focuses on (1): locating the antecedent of the relative pronoun.Indeed, although relative pronoun disambiguation lLocating the gap is a separate, but equally difficult problem because the gap may appear in a variety of positions in the embedded clause: the subject, direct object, indirect object, or object of a preposition. For a simple solution to the gap-finding problem that is consistent with the work presented here, see (Cardie & Lehnert, 199 1). 2Relative pronouns like who, whom, which, that, where, etc. are often referred to as wh-words. 38 Learning: Constructive and Linguistic From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. The antecedent is not always a single noun phrase. In S5, for example, the antecedent of “who” is a conjunction of three phrases and and in S6, either “our sponsors” or its appositive “GE and NSF” is a semantically valid antecedent. Sometimes there is no a arent antecedent. (e.g., 53). ~isa~big~atiQ~ of the relative depend on ~~~~r~atiQ~ in the em In S8, for example, the antecedent of “who” is either “the man” or “the woman and the man,” depending on the number of the embedded clause verb. SoInetim?s, the antecedent is truly ambiguous. For sentences like S9, the real antecedent depends on the surrounding context. Locating the antecedent re ssimilation of syntactic a semantic nowledge. The ac tic strut ture the clause preceding “who” in sentences S 10 and S 1 I, for example, is identical (NP-PP). The antecedent in each case is different, however. In SlO, the antecedent is the subject, “the woman;” in S 11, the antecedent is the prepositional phrase modifier, “the children.” In this paper we show how a natural language system can learn to disambiguate relative pronouns. We describe the use of an existing conceptual clustering system to create a case-based memory that predicts the antecedent of a wh-word given a description of the clause that precedes it. In addition, 0 Our approach duplicates the performance of hand- coded rules. 0 It assumes only minimal syntactic parsing capabilities and the existence of a very general semantic feature set for describing nouns. 0 The technique requires human intervention only to choose the correct antecedent for the training instances . 0 The resulting memory is automatically tuned to respond to the syntactic and semantic preferences of a particular domain. a Acquiring relative pronoun disambiguation heuristics for a new domain requires little effort. Furthermore, we believe that the technique may provide a general approach for the automated acquisition of additional disambiguation heuristics, especially for problems that require the assimilation of syntactic and semantic knowledge. In the next section, we describe current approaches to relative pronoun disambiguation. The remainder of the paper presents our automated approach and compares its performance to that of hand- codedrules. rase Any natural language processing system that hopes to process real world texts requires a reliable mechanism for locating the antecedents of relative pronouns. Systems that use a formal syntactic grammar often directly encode information for relative pronoun disambiguation in the grammar. Other times, the grammar proposes a set of syntactically legal antecedents and this set is passed to a semantic component which determines the antecedent using inference or preference rules. (For examples of this approach, see (Correa, 1988; Hobbs, 1986; Ingria, & Stallard, 1989; Lappin, & McCord, 1990).) Alternatively, semantically-driven systems often employ disambiguation heuristics that rely for the most part on semantic knowledge but also include syntactic constraints (e.g., UMass/MUC-3 (Lehnert et. al., 1991)). Each approach, however, requires the manual encoding of relative pronoun disambiguation rules, either 1) as part of a formal grammar that must be designed to find relative pronoun antecedents for all possible syntactic contexts, or 2) as heuristics that include both syntactic and semantic constraints. Not surprisingly, NLP system builders have found the hand- generation of such rule sets to be both time consuming and error prone. Furthermore, the resulting rule set is often fragile and generalizes poorly to new contexts. For example, the UMass/MUC-33 system began with 19 rules for finding the antecedents of relative pronouns. These rules were based on approximately 50 instances of relative pronouns that occurred in 10 newswire stories from the MIX-3 corpus. As counterexamples were identified, new rules were added (approximately 10) and existing rules changed. Over time, however, we became increasingly reluctant to modify the rule set because global effects of local rule changes were difficult to measure. In addition, most rules were based on a class of sentences that the UMass/MUC-3 system had found to contain important information. As a result, the hand-coded rules tended to work well for relative pronoun disambiguation in sentences of this class (93% correct for one set of 50 texts), but did not generalize to sentences outside of this class (78% correct for the same set of 50 texts). In the next section, we present an automated approach for learning the antecedents of wh-words. This approach avoids the problems associated with the manual encoding of heuristics and grammars, and automatically tailors the disambiguation decisions to the syntactic and semantic profile of the domain. roach Our method for relative pronoun disambiguation consists of three steps: 1. Create a hierarchical memory of relative pronoun disambiguation cases. 3MUC-3 is the Third Message Understanding System Evaluation and Message Understanding Conference (Sundheim,l99 1). UMass/MUC-3 (Lehnert et. al., 199 1) is a version of the CIRCUS parser (Lehnert, I990) developed for the MUC-3 performance evaluation. Cardie 39 2. For each new occurrence of a wh-word, retrieve the most similar case from memory using a representation of the clause preceding the wh-word as the probe. 3. Use the antecedent of the retrieved case to guide selection of the antecedent for the probe. These steps will be discussed in more detail in the sections that follow. uilding the Case Base We create a hierarchical memory of relative pronoun disambiguation cases using a conce tual clustering system called COBWEB (Fisher, 1987). B COBWEB takes as input a set of training instances described as a list of attribute-value pairs and incrementally discovers a classification hierarchy that covers the instances. The system tracks the distribution of individual values and favors the creation of classes that increase the number of values that can be correctly predicted given knowledge of class membership. While the details of COBWEB are not necessary for understanding the rest of the paper, it is useful to know that nodes in the hierarchy represent probabilistic concepts that increase in generality as they approach the root of the tree. Given a new instance to classify after training, COBWEB retrieves the most specific concept that adequately describes the instance. We provide COBWEB with a set of training cases, each of which represents the disambiguation decision for a single occurrence of a relative pronoun.5 We describe the decision in terms of four classes of attribute-value pairs: one or more constituent attribute-value pairs, a cd-form attribute-value pair, a part-of-speech attribute-value pair, and an antecedent attribute-value pair. The paragraphs below briefly describe each attribute type using the cases in Figure 3 as examples. Because the antecedent of a relative pronoun usually appears in the clause just preceding the relative pronoun, we include a constituent attribute-value pair for each phrase in that clause.6 The attribute describes the syntactic class of the phrase as well as its position with respect to the relative pronoun. In S 1, for example, “of the 76th court” is represented with the attribute ppl because it is a prepositional phrase and is in the first position to the left of “who.” In S2, “Rogoberto Matute” and “Juan Bautista” are represented with the attributes npl and np2, respectively, because they are noun phrases one and two positions to the left of “who.” The subject and verb 4 The experiments described here were run using a version of COBWEB developed by Robert Williams, now at Pace University. 5Our initial efforts have concentrated on the resolution of “who” because the hand-coded heuristics for that relative pronoun were the most complicated and difficult to modify. We expect that the resolution of other wh-words will fall out without difficulty. 6Note that we are using the term constituent rather loosely to refer to all noun phrases, prepositional phrases, and verb phrases prior to any attachment decisions. 40 Learning: Constructive and Linguistic Sk [The judge] [of the 76th court] [,] who . . . I I consti#zuuents: ( s human ) ( ppl physical-target ) ( v nil ) cd-form: ( cd-form physical-target ) part-of-speech: (part-of-speech comma ) antecedent: ( antecedent ((s)) ) cd-form: ( cd-form proper-name ) part-of-speech: ( part-of-speech comma ) antecedent: ( antecedent ((np2 cd-form)) ) S3: [Her DAS bodyguard] [,] [Dagoberto Rodriquez] [,] who... I I constituents: ( s human ) ( npl proper-name ) ( v nil ) cd-form: ( cd-form proper-name ) part-of-speech: ( part-of-speech comma ) antecedent: ( antecedent ((cd-form) (s cd-form) (s)) ) Figure 3: Relative Pronoun Disambiguation Cases constituents (e.g., “the judge” in Sl and “detained” in S2) retain their traditional s and v labels, however - no positional information is included for those attributes. The value associated with a constituent attribute is simply the semantic classification that best describes the phrase’s head noun. We use a set of seven general semantic features to categorize each noun in the lexicon: human, proper-name, location, entity, physical-target, organization, and weapon. 7 The subject constituents in Figure 3 receive the value human, for example, because their head nouns are marked with the “human” semantic feature in the lexicon. For verbs, we currently note only the presence or absence of a verb using the values t and nil, respectively. In addition, every case includes a cd-form, part-of- speech, and antecedent attribute-value pair. The cd-form attribute-value pair represents the phrase last recognized by the syntactic analyzer. * Its value is the semantic feature associated with that constituent. In S 1, for example, the constituent recognized just before “who” was “of the 76th court.” Therefore, this phrase becomes part of the case representation as the attribute-value pair (cd-form physical- target) in addition to its participation as the constituent attribute-value pair (ppl physical-target). The part-of- speech attribute-value pair specifies the part of speech or item of punctuation that is active when the relative 7These features are specific to the MUC-3 domain. 8The name cd-form is an artifact of the CIRCUS parser. pronoun is recognized. For all examples in Figure 3, the part of speech was cornmap Finally, the position of the correct antecedent is included in the case representation as the antecedent attribute-value pair.1° For UMass/MUC-3, the antecedent of a wh-word is the head of the relative pronoun coreferent - without any modifying prepositional phrases. Therefore, the value of this attribute is a list of the constituent and/or cd-form attributes that represent the location of the antecedent head or (none) if no antecedent can be found. In Sl, for example, the antecedent of “who” is “the judge.” Because this phrase occurs in the subject position, the value of the antecedent attribute is (s). Sometimes, however, the antecedent is actually a conjunction of constituents. In these cases, we represent the antecedent as a list of the constituent attributes associated with each element of the conjunction. Look, for example, at sentence S2. Because “who” refers to the conjunction “Juan Bautista and Rogoberto Matute,” the antecedent can be described as (np2 cd-form) or (np2 npl). Although the lists represent equivalent surface forms, we choose the more general (np2 cd-form).11 S3 shows yet another variation of the antecedent attribute-value pair. In this example, an appositive creates three semantically equivalent antecedent values, all of which become part of the antecedent feature: 1) “Dagoberto Rodriguez” - (cd- form) , 2) “her DAS bodyguard’- (s), and 3) “her DAS bodyguard, Dagoberto Rodriguez”- (s cd-form). The instance representation described above was based on a desire to use all relevant information provided by the CIRCUS parser as well as a desire to exploit the cognitive biases that affect human information processing (e.g., the tendency to rely on the most recent information). Although space limitations prevent further discussion of these representational issues here, they are discussed at length in (Cardie, 1992b). It should be noted that UMass/MUC-3 automatically creates the training instances as a side effect of syntactic analysis. Only specification of the antecedent attribute- value pair requires human intervention via a menu-driven interface that displays the antecedent options. In addition, the parser need only recognize low-level constituents like noun phrases, prepositional phrases, and verb phrases because the case-based memory, not the syntactic analyzer, directly handles the conjunctions and appositives that comprise a relative pronoun antecedent. For a more detailed 9Again, the fact that the part-of-speech attribute may refer to an item of punctuation is just an artifact of the UMass/MUC-3 system. loCOBWEB is usually used to perform unsupervised learning. However, we use COBWEB for supervised learning (instead of a decision tree algorithm, for example) because we expect to employ the resulting case memory for predictive tasks other than relative pronoun disambiguation. 1 lThis form is more general because it represents both (np2 4) at-d hp2 PPD. discussion of parser vs. learning component tradeoffs, see (Cardie, 1992a). As the training instances become available, they are passed to the clustering system which builds a case base of relative pronoun disambiguation decisions. After training, we use the resulting hierarchy to predict the antecedent of a wh-word in new contexts. For each novel sentence containing a wh-word, UMass/MUC-3 creates a probe case that represents the clause preceding the wh-word. The probe contains constituent, cd-form, and part-of-speech attribute-value pairs, but no antecedent feature. Given the probe, COBWEB retrieves the individual instance or abstract class in the tree that is most similar and the antecedent of the retrieved case guides selection of the antecedent for the novel case. For novel sentence Sl of Figure 4, for example, the retrieved case specifies np2 as the location of the antecedent. Therefore, UMass/MUC-3 chooses the contents of the np2 constituent - “the hardliners” - as the antecedent in S 1. Sometimes, however, the retrieved case lists more than one option as the antecedent. In these cases, we rely on the following case adaptation algorithm to choose an antecedent: 1. Choose the first option whose constituents are all present in the probe case. 2. Otherwise, choose the first option that contains at least one constituent present in the probe and ignore those constituents in the retrieved antecedent that are missing from the probe. 3. &her-wise, replace the np constituents in the Dt] [encourages] [the hardliners] [in ARENA] [,] who... Antecedent of Retrieved Case: ((np2)) Antecedent of Probe: = “the hardliners” S2: [There] [are] [criminals] [like] [Vice President Merino] fs Antecedent of Retrieved Case: ((pp5 np4 pp3 np2 cd-form) Antecedent of Probe: (np2 cd-form) = “Vice President Merino, a man” Antecedent of Retrieved Case: ((pp2)) Figure 4: Case etrieval and Adaptation Cardie 41 Figure 5 : Results (% correct) retrieved antecedent that are missing from the probe with pp constituents (and vice versa) and try 1 and 2 again. In general, the case adaptation algorithm tries to choose an antecedent that is consistent with the context of the probe or to generalize the retrieved antecedent so that it is applicable in the current context. Sl illustrates the first case adaptation filter. In S2, however, the retrieved case specifies an antecedent from five constituents, only two of which are actually represented in the probe. Therefore, we ignore the missing constituents pp5, np#, and pp3 and look to just np2 and cd-form for the antecedent. For S3, filters 1 and 2 fail because the probe contains no pp2 constituent. However, if we replace pp2 with np2 in the retrieved antecedent, then filter 1 applies and “a specialist” is chosen as the antecedent. Note that, in this case, the case adaptation algorithm returns an antecedent that is just one of three valid antecedents (i.e., “Smith,” “a specialist,” and “Smith, a specialist”). Experiments and Results To evaluate our automated approach, we extracted all sentences containing “who” from 3 sets of 50 texts in the MUC-3 corpus. In each of 3 experiments, 2 sets were used for training and the third reserved for testing. The results are shown in Figure 5. For each experiment, we compare our automated approach with the hand-coded heuristics of the UMass/MUC-3 system and a baseline strategy that simply chooses the most recent phrase as the antecedent. For the “adjusted” results, we discount errors in the automated approach that involve antecedent combinations never seen in any of the training cases. In these situations, the semantic and syntactic structure of the novel clause usually differs significantly from those in the hierarchy and we cannot expect accurate retrieval from the case base. In experiment 1, for example, 3 out of 8 errors fall into this category. Based on these initial results, we conclude that our automated approach to relative pronoun disambiguation clearly surpasses the “most recent phrase” baseline heuristic and at least duplicates the performance of hand- coded rules. Furthermore, the kind of errors exhibited by the learned heuristics seem reasonable. In experiment 1, for example, of the 5 errors that did not specify previously 42 Learning: Constructive and Linguistic unseen antecedents, 1 error involved a new syntactic context for “who”- “ who” preceded by a preposition, i.e., “regardless of who.” The remaining 4 errors cited relative pronoun antecedents that are difficult even for people to specify. (In each case, the antecedent chosen by the automated approach is indicated in italics; the correct antecedent is shown in boldface type.) 1. (‘... 9 rebels died at the hands of members of the civilian militia, who resisted the attacks” 2. (‘*.. the government expelled a group of foreign drug traffickers who had established themselves in northern Chile” 3. “ . ..the number of people who died in Bolivia...” 4. (‘ . ..the rest of the contra prisoners, who are not on this list...” Conclusions Developing state-of-the-art NLP systems or extending existing ones for new domains tends to be a long, labor- intensive project. Both the derivation of knowledge-based heuristics and the (re)design of the grammar to handle numerous classes of ambiguities consumes much of the development cycle. Recent work in statistically-based acquisition of syntactic and semantic knowledge (e.g., (Brent, 1991; Church, et. al., 1991; de Marcken, 1990; Hindle, 1990; Hindle, & Rooth, 1991; Magerman & Marcus, 1990)) attempts to ease this knowledge engineering bottleneck. However, statistically-based methods require very large corpora of on-line text. In this paper, we present an approach for the automated acquisition of relative pronoun disambiguation heuristics that duplicates the performance of hand-coded rules, requires minimal syntactic parsing capabilities, and is unique in its reliance on relatively few training examples. We require a small training set because, unlike purely statistical methods, the training examples are not word- based, but are derived from higher level parser output. In addition, we save the entire training case so that it is available for generalization when the novel probe retrieves a poor match. In spite of these features of the approach, the need for a small training set may, in fact, be problem-dependent. Future work will address this issue by employing our case- based approach for a variety of language acquisition tasks. Further research on automating the selection of training instances, extending the approach for use with texts that span multiple dqmains, and deriving optimal case adaptation filters is also clearly needed. However, the success of the approach in our initial experiments, especially for finding antecedents that contain complex combinations of conjunctions and appositives, suggests that the technique may provide a general approach for the automated acquisition of additional disambiguation heuristics, particularly for traditionally difficult problems that require the assimilation of syntactic and semantic knowledge. owledgments I thank Wendy Lehnert for many helpful discussions and for comments on earlier drafts. This research was supported by the Office of Naval Research, under a University Research Initiative Grant, Contract No. N00014-86-K-0764, NSF Presidential Young Investigators Award NSFIST-8351863, and the Advanced Research Projects Agency of the Department of Defense monitored by the Air Force Office of Scientific Research under Contract No. F49620-88-C-0058. eferences Brent, M. (1991). Automatic acquisition of subcategorization frames from untagged text. Proceedings, 29th Annual Meeting of the Association for Computational Linguistics. University of California, Berkeley. Association for Computational Linguistics. Cardie, C. (1992a). Corpus-Based Acquisition of Relative Pronoun Disambiguation Heuristics. To appear in Proceedings, 30th Annual Meeting of the Association for Computational Linguistics. University of Delaware, Newark. Association for Computational Linguistics. Cardie, C. (1992b). Exploiting Cognitive Biases in Instance Representations. Submitted to The Fourteenth Annual Conference of the Cognitive Science Society. University of Indiana, Bloomington. Cardie, C., $ Lehnert, W. (1991). A Cognitively Plausible Approach to Understanding Complex Syntax. Proceedings, Eighth National Conference on Artificial Intelligence. Anaheim, CA. AAAI Press / The MIT Press. Church, K., Gale, W., Hanks, P., & Hindle, D. (1991). Using Statistics in Lexical Analysis. In U. Zernik (Ed.), Lexical Acquisition: Exploiting On-Line Resources to Build a Lexicon (pp. 115-164). Hillsdale, New Jersey: Lawrence Erlbaum Associates. Correa, N. (1988). A Binding Rule for Government- Binding Parsing. Proceedings, COLING ‘88. Budapest. de Marcken, C. 6. (1990). Parsing the LOB Corpus. Proceedings, 28th Annual Meeting of the Association for Computational Linguistics. University of Pittsburgh. Association for Computational Linguistics. Fisher, D. H. (1987). Knowledge Acquisition Via Incremental Conceptual Clustering. Machine Learning, 2, p. 139-172. Hindle, D. (1990). Noun classification from predicate- argument structures. Proceedings, 28th Annual Meeting of the Association for Computational Linguistics. University of Pittsburgh.Association for Computational Linguistics. Hindle, D., & Rooth, M. (1991). Structural ambiguity and lexical relations. Proceedings, 29th Annual Meeting of the Association for Computational Linguistics. University of California, Berkeley. Association for Computational Linguistics. Hobbs, J. (1986). Resolving Pronoun References. In B. J. Grosz, K. Sparck Jones, & B. L. Webber (Eds.), Readings in Natural Language Processing (pp. 339-352). Los Altos, CA: Morgan Kaufmann Publishers, Inc. Ingria, R., & Stallard, D. (1989). A Computational Mechanism for Pronominal Reference. Proceedings, 27th Annual Meeting of the Association for Computational Linguistics. Vancouver. Association for Computational Linguistics. Lappin, S., & McCord, M. (1990). A Syntactic Filter on Pronominal Anaphora for Slot Grammar. Proceedings, 28th Annual Meeting of the Association for Computational Linguistics. University of Pittsburgh.Association for Computational Linguistics. Lehnert, W. (1990). Symbolic/Subsymbolic Sentence Analysis: Exploiting the Best of Two Worlds. In J. Barnden, & J. Pollack (Eds.), Advances in Connectionist and Neural Computation Theory. Norwood, NJ: Ablex Publishers. Lehnert, W., Cardie, C., Fisher, D., Riloff, E., & Williams, R. (1991). University of Massachusetts: Description of the CIRCUS System as Used for MUG-3. Proceedings, Third Message Understanding Conference (MUC-3). San Diego, CA.Morgan Kaufmann Publishers. Magerman, D. M., & Marcus, M., P. (1990). Parsing a Natural Language Using Mutual Information Statistics. Proceedings, Eighth National Conference on Artificial Intelligence. BostonAAAI Press/The MIT Press. Sundheim, B. M. (May,199I).Overview of the Third Message Understanding Evaluation and Conference. Proceedings, Third Message Understanding Conference (MIX-3). San Diego, CA.Morgan Kaufmann Publishers. Cardie 43 | 1992 | 21 |
1,212 | Discrimination- ive io Boonserm Kijsirikul Masayuki Numao Department of Computer Science, Tokyo Institute of Technology 2-12-1 Oh-okayama, Meguro, Tokyo 152, JAPAN Email: {boon, numao, shimura}@cs.titech.ac.jp Abstract This paper presents a new approach to construc- tive induction, Discrimination-Based Construc- tive induction(DBC), which invents useful pred- icates in learning relations. Triggered by failure of selective induction, DBC finds a minimal set of variables forming a new predicate that discrim- inates between positive and negative examples, and induces a definition of the invented predicate. If necessary, it also induces subpredicates for the definition. Experimental results show that DBC learns meaningful predicates without any interac- tive guidance. Introduction Learning systems find a concept based on positive and negative examples by using given terms, such as features and predicates. Most learning systems em- ploy selective induction, and find a concept descrip- tion composed of only predefined terms. However, if such terms are not appropriate, constructive induc- tion [Michalski, 19831 or shift of bias [Utgoff, 19861 are required to invent new terms. Several systems have been developed for term invention. Most systems use a feature-value language for representing exam- ples and a concept description, and invent a new fea- ture by combining the given features [Matheus, 1990; Pagallo, 19891. Due to a lack of expressive power in feature-value languages, there has been increasing interest in sys- tems which induce a first-order logic program from ex- amples [Muggleton and Feng, 1990; Quinlan, 19901. Some of these systems perform constructive induc- tion. FOCL [S iverstein and Pazzani, 19911 invents new terms, i.e., new predicates, by combining exist- ing subpredicates. Based on interaction with its user, CIGOL [Muggleton and Buntine, 19881 invents terms without any given subpredicate. This paper presents Discrimination-Based Con- structive induction (DBC) which invents a new pred- icate without any given subpredicate nor any user interaction. Triggered by failure of selective induc- 44 Learning: Constructive and Linguistic tion, DBC introduces a new predicate into a previ- ously found incomplete clause. This is performed by searching for a minimal relevant variable set forming a new predicate that discriminates between positive and negative examples. If necessary, DBC also recursively invents subpredicates for the definition. Experimental results show that, without interactive guidance, our system CHAMP can construct mean- ingful predicates on predefined ones or from scratch. Our approach is system independent and applicable to other selective learning systems such as FOIL [Quin- lan, 19901. Discriminatiou- ased Constructive Induction As the purpose of learning a program is to discriminate between positive and negative examples, a new predi- cate is likely to be useful if it is based on discrimination between the examples. In this section, we describe our DBC problem and then provide an algorithm to solve the problem. The problem we are interested in is as follows: Given: e an incomplete clause C e positive and negative examples covered by C Determine: e a clause C’ that is the result of adding a new literal R (= P(...)) to the body of C Q a definition of the predicate P The incomplete clause and the examples are obtained by selective induction. To simplify the problem, we assume that (i) C’ completely discriminates between positive and negative examples and (ii) R is composed only of variables and all of them occur in C. In our approach, a new predicate is invented by searching for a minimal set of variables forming a rela- tion R that discriminates between the examples. A set is minimal if it has no proper subset which forms such a relation. We do not look for non-minimal variable sets since they contain superfluous variables. From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Definition 1 A clause C covers an atom e with re- spect to (w.r.t.) logic program K, denoted C&r >K e, or simply C >K e, iff there are substitutions 0,~ such that Chead@ is identical to e and C&+60 E o*(K); where Chea,-J, Cbody and D*(K) are the head of 6, the body of C, and an atomic-derivation-closure ’ [Mug- gleton and Feng, 19901 of K, respectively. The definition extends naturally to a set of atoms E, and is written C >K E. Using the definition, the DBC problem is formalized as: Given: C >K E+, C >K E-. (1) Find: (R, A) such that, (i) (R, A) is complete (covering all positive examples) and is consistent (not covering any negative ex- ample), i.e., (c v lR) >(KAA) J% (cv ‘R) #(K*A) E- (2) (ii) (R, A) is minimal, i.e., there is no other complete and consistent tuple (R’, A’) such that var(R’) C var(R). where K is a set of background clauses and C is an incomplete clause. E+, E- are sets of positive and negative examples covered by C, respectively. R is a new literal. A and var(R) are a set of ground instances of R and a set of variables occurring in R, respectively. We restrict a set of instances A to a set that consists of only bindings in substitutions making C cover E+. Let var( Chead) = { Yl , . . . , Ym) and var(Cbody) = {Yrntl , . - . , Yn} be a set of variables oc- curring in chead and only in Cb&y . Let (OiUj} = (fi/al,;, . . - , Ym/am,ir Ym+l/am+l,j,. . . , Y,/an,j) be a set of substitutions that make C cover the ith positive example et w.r.t. background knowledge K(ceiuj >K et). The initial hypothesis of a solu- tion (Rs, A,) is defined as: (Ro,Ao) = (fpi,..., Yn)9 A A$(al,i, - * * 9 urn,;, am+l,j, * - * 7 Gz,j)), . . where $ is a prldiiate not appearing in K and C. Ro and A0 are composed of all variables in C and all bind- ings of those variables. Theorem 2 Given (l), if every positive example is different from every negative one, (Ro, A,) is complete and consistent. (For proof of the theorems see [Ki- jsirikul et al., 19921.) The initial hypothesis (Re, As) may contain super- fluous variables which must be removed. Definition 3 (R A> -{z, ,...,z, 1 denotes a pair (R’, A’) obtained by removing (21,. . . , Zm} from R and the corresponding terms from A. ‘D*(K) = (Do(K) U D1(K) U . ..). where Do(K) is the set of unit clauses in K and D”(K) = D”-l (K) U {A& . ..& IA-B1 ,..., B, E K and for each B; there ex- ists Bi E D”-‘(K) such that 8i is the mgu of Bi and B: } Given (Rs, As), the search space for solving the DBC problem is: HAll = {(Ro, &)I& E Ao} U {(Ro, hi)-~lA c var(Ro)} Example 1 Let (Ro, Ao) = (p(x, Y, z), (~(2, I, 4), ~(2,1,5))).{(Ro~ &>I& C Ao} = { (p(x, y, z), {p(2,1,4), yg9 19$y (;ovq zh {PC& 194)Ih (P(x,y,zh {P(2,& 5)))I. - (P(Y,Z),{P(l,4),P(l,5)}), (I%&)-:IA c iiY,-W = I(p(y,z),lp(1,4),~(1,5P;~: (p(y, z1, {P(b4H), (P(Y, z), {PO, 5H), (p(x, zA {PC& 417 ~(2,5H), (~(x, z), {~(2,4)H, (~(x, z), {~(2,5))>, (~(x,y), {PC% N), (P(Z), {P(4LP(5)IL (P(z), {P(4)h (P(Z), {P(50), (P(y), {PWL (P(x), {PWI)~- Cl The DBC Algorithm To find a solution, one straightforward algorithm would enumerate (R, A) in HAll from small to big un- til it finds such a pair that is complete. However, this is intractable since its time complexity is exponential in the number of variables in the clause. Fortunately, there is a DBC algorithm that accomplishes the task whose time complexity is a linear function of the num- ber of variables. The following greedy removal algo- rithm has been adopted. Algorithm DBC Input: A clause C, a set of background clauses K and sets of positive and negative examples E+, E-, where {K ,..., yn} is a set of variables in C. begin (RA) + (Ro,Ao) for i := 1 to n do begin (R’, A’) + (R, A)-,,,,; Cl t CvyR’; if there exists A+ such that (A+ E A') A (C' >(K/\A+) E') the) cc' 2((KhA+)E-) (R, A) + (R’, A’) /* yi is irrelevant */ end Let var(R) = (21,. . . , 21); Find a set of possible bindings of (21,. . . , Zr) such that C >K E- and use them as a set of negative instances, A-, of R end Output: (R, A+), A-, C’ = C v YR Figure 1: The DBC Algorithm The basic idea of the algorithm is to remove irrele- vant variables one by one. If a variable is removed and there exists (R’, A+) that enables the clause to still cover all positive examples but no negative examples, then that variable is considered to be irrelevant. Al; though K A A0 derives no negative examples, K A A could derive some of them since Yi is removed. To avoid such derivation, A+ is calculated by removing from A’ all its elements that derive any negative ex- amples. Theorem 4 The DBC algorithm produces a com- plete, consistent and minimal (R, A+). Mijsirikul, Numao, and Shimura 45 Note that a minimal hypothesis (R, A+) produced by the algorithm does not necessarily contain the mini- mum number of variables, i.e., the number of variables in R is a local minimum. Overview of CHAMP The authors have constructed a learning system, CHAMP, to test the DBC algorithm. It consists of a selective induction component, CHAM, and a predi- cate invention component based on the algorithm. Selective Induct ion Component: C CHAM [Kijsirikul et al., 19911 is a logic program learn- ing component that employs refinement operators in MIS [Shapiro, 19831 to specialize a clause by: (i) in- stantiating a head variable to a function, (ii) unify- ing variables, or (iii) adding a background predicate to a body. It employs the Merit heuristic which is a combination of Gain in FOIL and likelihood to avoid exhaustive search [Kijsirikul et al., 19911. Failure Driven Constructive Induction in CHAMP CHAMP constructs a new predicate when the selective induction component fails, i.e.: o There is no specialized clause that covers positive examples, or (I The number of bits encoding the specialized clause exceeds the number of bits encoding positive ex- amples covered by the clause, and the clause does not achieve reasonable accuracy. The second condition follows the argument in [Quinlan, 19901. If a clause is reasonably accurate, the inexact clause is retained as a final clause. This restriction on encoding bits is used to avoid overfitting noisy exam- ples. The number of bits encoding a clause is defined re- cursively as follows: the number of bits required to code the most general term [Kijsirikul et aE., 19911 is 0: bits(MGT) = 0. The number of bits required to code each specialized clause Ci is: e if Ci is specialized by instantiating a head variable in C to a function, bits(Ci) = bits(C) + Zog2(3) + loga( where Ni is the number of specialized clauses ob- tained by instantiation; e if Ci is specialized by unifying variables in C, bits(Ci) = bits(C) + Zog2(3) + loga( where Nu is the number of specialized clauses ob- tained by unification; or o if Ci is specialized by adding a predicate to the body of C, bits(Ci) = bits(C) + Zog2(3) +Zoga (number of predicates + 1) +Zogz (number of possible arguments). An extra 1 in Zog~(number of predicates + 1) is for a new predicate. Logz(3) indicat,es the number of bits to specify one operation out of the above three. On the other hand, the number of bits required to encode positive examples is: bits(p,p + n) = Zoga(p + n) + log2 K Pfn >>) where p and n are the number of positive examples and negative examples, respectively. The number of bits encoding a program P which contains a set of clauses, {Cl,. . . , C,), is: Bits(P) = bits(C$) + SW. + bits(&). Learning Algorithm of C In this section we describe the learning algorithm of CHAMP. The algorithm first tries to learn a clause composed of only given predicates. If no such clause is found, the algorithm then invents a new predicate that is represented in terms of its instances. These instances are then fed into the algorithm so that the algorithm can learn their definition, as shown in Figure 2. When the selective induction component fails to dis- cover a clause, as candidates for introducing new pred- icates the algorithm selects n incomplete clauses that have higher scores in the following heuristic: Score(C) = Merit(C) x (bits( CovPos, Total) - bits(C)), where C, CowPos and Total are a clause, the num- ber of positive examples covered by the clause and the number of all examples, respectively. The algorithm outputs either programs or instances of new predicates which minimize the encoding bits. In other words, the number of bits encoding positive examples covered by a clause added by a predicate should be greater than the number of bits encoding the clause and a definition (P and/or Is) of that predicate. There are two criteria for stopping predicate in- vention: (1) the number of bits encoding all clauses exceeds that, encoding the positive examples of the target concept; and (2) the instances of a new pred- icate (NewPsj, NewNsj) are the same as examples (PosEzs, NegEzs) except for the name of the predi- cate. Learning Sort without Knowledge Below we demonstrate that a sort program is learned without background knowledge by inventing subpred- icates. Training examples are selected from all lists of length up to three, each containing non-repeated atoms drawn from the set {0,1,2}. We use a predicate with symbol $ to indicate that it is created by the system, and name it appropriately for readability. 46 Learning: Constructive and Linguistic Precedure CHAMP( PosExs,NegExs,CZauses,Instances); /* input: P OS E xs, NegExs are sets of positive and negative examples */ /* output: Clauses, Instances are sets of clauses and positive instances */ begin Clauses t (1; Instances t (1; while PosExs # {} do begin Choose a seed example e from PosExs and call CRAM to learn a clause C which covers e; if succeed then add C to CZa?Lses and remove positive examples covered by it from PosExs else begin Select n previously found incomplete clauses(C;) by CHAM that, h ave higher scores in Score( C, ); for i := 1 to n do begin Use DBC algorithm to construct a clause NC;(= C, V ‘R,) whose body is added by a new predi- cate(litera1) Ri; Calculate positive and negative instances of the new predicat,e( NewPs, , N eu]Nsi ); CovPosBitsi + bits(]positive examples covered by NC;I,IPosEx.sj + (NegExs() end; Select the best new clause NC, that has the maximum value of CoVPosBitsj - ( bits(NC,) + bits(INewPsjl,lNewPs,I + INewNs,l) ); Call CHAMP( NewPs,, NewNs,, P, Is) recursively to learn a definition (P and/or Is) of the new predicate; if CovPosBitsj 2 ( bits(NCj) + Bits(P) + bits(lls],]NewPs,] + INewNs,l) ) then begin Add NCj and P to Clauses, Is to Instances; Remove positive examples covered by NCj from PosExs end else begin Add PosExs to Instances; PosExs c {} end end. Figure 2: Learning Algorithm of CHAMP Because useful background predicates such as partition, append, <, >= are not given, the selective induction component fails to discover a clause. At this step, incomplete clauses with high scores are: Cl: sort(CXIYl,Z) :- sort(Y,V) c2: sort([XIYl,Z) :- c3: sort([XIY], [ZIUI) :- sort(Y,W) . . . CHAMP introduces $insert into the first clause as follows: var(C1) = (X,Y,Z,V}, R = $insert(X,Y,Z,V). First, A is calculated: $insert(2, [l,O], [O,l, 21, [0, I]) A Sinsert(2, [0, I], [0, 1,2], [0, I]) A A= $insert(2, [1],[1,2],[1]) A $insert(2, [O], [0,2], [O]) A . . . To remove irrelevant variables, (R’, A’) is computed and tested. lSt loop: (R',A')=(R,A)-{x~ = ($insert(Y,Z,V),{$ insert([l, 01, [O, I, 4, [O, I]). . .}) C’ = sort(CXIYl,Z) :- sort(Y,V), $insert(Y,Z,V) There is no A+ c A’ that makes (R’, A+) complete. (R, A) = ($insert(X, Y, 2, V), A) 2nd loop: (R',A')=(R,A)+) = ($insert(X,Z,V), {$ insert(2, [0,1,2], [0, I]). . .}) C’ = sort( [XIY] ,Z> :- sort(Y,V), $insert(X,Z,V) There exists a A' = A' that makes (R’, A+) complete. (R, A) = ($insert (X, Z, V), A') Removing Z or V is a similar process. The obtained clause is: sort([XIY] ,Z> :- sort(Y,V), $insert(X,Z,V). with instances of $insert listed below: positive instances( A+): &insert (2, Cl ,21, Cl1 > $insert(2, CO,1,21, CO,ll> $insert (2, CO, 21, CO1 > $insert (2, C21 , Cl > $insert(l, Cl,21, C21> $insert(l, CO,l,21, CO,211 . . . negative instances( A-): $insert (0, Cl , Cl > $insert (0, CO1 , Cl1 1 $insert (0, CO1 , C21> $insert (0, CO, 11 , Cl 1 $insert(O, [O,ll, El,23> $insert(O, [O,ll, [23) . . . CHAMP also tries to introduce new predicates into the other clauses but the first clause is selected since it has the maximum value. Positive and negative instances of $insert are passed to the selective induction component to learn a definition of $insert. The component fails again and then CHAMP attempts to introduce a new pred- icate into the clause $insert (X, [Y I Z] , [Y I V] > : - $insert (X, Z ,V>, and finds the first clause of $insert: $insert(X,[YlZ],[YlV]) :- $insert(X,Z,V), $greaterThan(X,Y). with instances of $greaterThan listed below. Positive instances: $greaterThan(l,O). $greaterThan(2,0). $greaterThan(2,1). Negative instances: $greaterThan(O,l). $greaterThan(O,a). Kijsirikul, Numao, and Shimura 47 $greaterThan(l,2). While CHAMP learns a definition of $greaterThan, it needs a new predicate, and constructs $greaterThan(X,Y) :- $p (X ,Y> . Since examples of $p are the same as those of $greaterThan, CHAMP terminates the predicate invention. Finally, CHAMP learns the following program: sort(C1, Cl>. sort(CXlYl,Z) :- sort(Y,V), $insert(X,Z,V). $insert(X,CYlZl,CYlVl) :- $insert(X,Z,V), $greaterThan(X,Y). $insert(X,CX,ZIUl ,CZlUl) :- $greaterThan(Z,X). $insert (X, [Xl , Cl ) . $greaterThan(l,O). $greaterThan(2,0). $greaterThan(2, I). Experimental Results An experiment was made on various learning prob- lems in order to show that CHAMP invents meaningful predicates which lead to increased classification accu- racies. Table 1 shows the results. In all problems, the system was given positive ex- amples and it generated negative examples under the closed-world assumption. In the arch problem, ex- amples are given in a specific form of the arch as in [Muggleton and Buntine, 19881. The test examples for all problems are randomly selected from supersets of training sets. The program for the sort problem is the same as the above except that the given predicate ‘>’ is used in $insert clauses instead of $greaterThan. The rest of the programs for problems in Table 1 are as follows: grandmother: grandmother(X,Y) :- parent(X,Z), parent(Z,Y), $female(X). reverse: reverse([l,CI). reverse([XlYl,Z) :- reverse(Y,V), $concat(X,V,Z). $concat (X, Cl , EXI ) . $concat(X, CYIVI, CYIZI) :- $concat(X,V,Z). union: union([l,X,X). union([XlYl,Z,U) :- union(Y,Z,U), $member(X,U). union(CXlYl,Z,[XlVl) :- union(Y,Z,V), $not-member(X,V). $member(X,[XIYl). $member(X, CYIZI) :- $member(X,Z). $not-member(X,[l). $not-member(X,[YlZ]) :- not-equal(Y,X), $not-member(X,Z). arch: arch(X,Y,X) :- $column-beam(X,Y). $column-beam([XlYl,Z) :- $column-beam(Y,Z), $brick-or-block(X). $column-beam(Cl,X) :- $beam(X). $brick-or-block(brick). $brick-or-block(block). $beam(beam). The results reveal that CHAMP learns meaningful predicates when background knowledge is inappropri- ate or insufficient. There are two reasons for predicate invention. One reason is that CHAMP invents predi- cates for increasing classification accuracies as shown in Table 1. In the grandmother problem, accuracy with predicate invention did not reach 100%~ because $female(X) is defined by its instances and there are some people in the test examples that are not given in the training examples and are female. The other reason is to reduce the size of programs by avoiding overly complex clauses. During an experiment by the authors, FOIL discovered a reverse program without inventing predicates as follows: reverse(A,B) :- components(A,C,D), components(B,E,F), reverse(D,G), components(G,E,H), reverse(H,I), reverse(F,J), components(J,C,I). where “components ( [A I Bl , A, B) ” is given as back- ground knowledge. CHAMP learns a more compact program by inventing $concat. Although we have not tested the effect of noise on predicate invention yet, we believe that, the restriction on encoding bits could avoid overfitting examples with noise, as in FOIL. Related Work The DBC algorithm searches for a minimal rele- vant variable set forming a new predicate based on discrimination between the examples. This dis- tinguishes it from other constructive induction al- gorithms. For instance, the intra-construction op- erator in CIGOL [M uggleton and Buntine, 19881 searches for relevant variables of a new predi- cate by considering the structure of terms shar- ing variables. Given resolvent clauses, for exam- ple, “insert(l,CO1,CO,l3) :- insert(l,Cl,Cll)" and "insert(2,~l,Ol,C1,0,21) :- insert(2,[Ol,EO,21)", intra-construction constructs a clause “insert(A,[BlCI,[~I~l) :- insert(A,C,D),$greater- Than(A,B,C,D)" with instances “$greaterThan(l,O,[l, [I])” and “$great erThan(2,1,[01,[0,21)", where C and D are not really relevant variables.’ On the other hand, CHAMP, as demonstrated in the example, learns $greaterThan(A ,B) consisting of only relevant vari- ables A and B. Another advantage of CHAMP, com- pared to CIGOL, is that, as training examples are given as a batch, invention of predicates needs less user interaction with the system. FOCL [Siverstein and Pazzani, 19911 is a construc- tive induction system extending FOIL. To construct a new predicate, FOCL uses cliche’s to constrain combi- nation patterns of predefined predicates. The cliches help heuristic used in FOCL to search for a useful pred- 21fwe giveexampl esin an appropriate sequence, CIGOL learns the meaningful $greaterThan(A,B) which contains only relevant variables. 48 Learning: Constructive and Linguistic reverse union components 256( 16) not-equal 3400(100) (positive) I I $insert 19.9 64(32) 100 67.2 $female 68.6 16(8) 99.7 98.6 $column-and-beam, $brick-or-block, $beam $concat $member, $not-member 7.9 28(14) 100 50.0 24.2 64(32) 100 50.0 413.4 400(200) 100 62.5 (a): CPU time for SICStus Prolog version 0.7 on SPARC station 2. (b): Classification accuracy with predicate invention. (c): Classification accuracy without predicate invention. Table 1: Predicates invented by CHAMP and classification accuracies with and without, predicate invention. icate, whereas our approach uses DBC to construct a new predicate when the heuristic fails to discover a clause. It may be useful to combine the approaches of DBC and the clichks. SIERES [Wirth and O’Rorke, 19911 is another con- structive induction system. It constrains the search of a clause and a new predicate by using a limited se- quence of argument dependency graphs. Our approach is more general than SIERES in the sense that we have no such constraints. Our work is also related to CW-GOLEM [Bain, 19911. Based on the Closed- World Specialization method, CW-GOLEM introduces a new predicate not(R) into the body of an over-general clause for han- dling exceptions. Our method can handle such excep- tions by including not(R) into the hypotheses HA~I. conchlsion We have described a new approach to constructive induction. The experimental results show that our system CHAMP can successfully construct meaningful predicates on existing ones or from scratch. The pred- icates are invented for increasing classification accura- cies and reducing the size of programs. One reason for the successful results is that a minimal variable set that forms a new predicate simplifies the learning process. Simplification of the learning of a concept by good in- teraction between constructive and selective induction, is achieved by recursively inventing subpredicates. Limitations of DBC are that a new predicate must completely discriminate between positive and negative examples, and a new predicate cannot contain new variables, constants and functions. Our implementation of DBC is combined with a se- lective induction system CHAM. However, since DBC is system independent, it is applicable to other selec- tive learning systems that search clauses in a top-down manner. cknowledgements We would like to thank Seiichirou Sakurai, Surapan Mek- navin and Somkiat Tangkitvanich for helpful discussions, and Niall Mu&a&, who rewrote the paper. eferemces Bain, M. 1991. Experiments in Non-Monotonic Learning. In Proc. 8th Id. WorMop on Machine Learning. 380-384. Kijsirikul, B.; Numao, M.; and Shimura, M. 1991. Efficient Learning of Logic Programs with Non-determinate, Non- discriminating Literals. In Proc. the 8th Intl. Workshop on Machine Learning. 417-421. Kijsirikul, B.; Nmnao, M.; and Shimura, M. 1992. Predi- cate Invention Based on Discrimination. Technical report, Tokyo Institute of Technology. Matheus, C. J. 1990. Adding Domain Knowledge to SBL Through Feature Construction. In AAAISO. 803-808. Michalski, R. S. 1983. A Theory and Methodology of In- ductive Learning. Artificial Intelligence 20:111-161. Muggleton, S. and Buntine, W. 1988. Machine Invention of First Order Predicates by Inverting Resolution. In Proc. the 5th Intl. Workshop on Machine Learning. 339-352. Muggleton, S. and Feng, C. 1990. Efficient Induction of Logic Programs. In Proc. the First Intl. Workshop on Al- gorithmic Learning Th.eory, Tokyo. OHMSHA. 368-381. Pagallo, G. 1989. Learning DNF by Decision Trees. In IJCAI89, Detroit,MI. 639-644. Quinlan, J. R. 1990. Learning Logical Definitions from Relations. Machine Learning 5:239-266. Shapiro, E. Y. 1983. Algorithm.ic Program Debugging. The MIT Press, Cambridge, MA. Siverstein, G. and Pazzani, M. J. 1991. Relational Clichks: Constraining Constructive Induction during Re- lational Learning. In Proc. th,e 8th, Intl. Workshop on Ma- chine Learning. 203-207. Utgoff, P. E. 1986. Shift of Bias for Inductive Concept Learning. In Michalski, R.S.; Carbonell, J.G.; and Mitchell, T.M., editors 1986, Mach&e learning: An artificial intelli- gence approach (Vol. 2). Morgan Kaufmaml. 107-148. Wirth, R. and O’Rorke, P. 1991. Constraints on Predicate Invention. In Proc. the 8th Intl. Worksh.op on Machine Learning. 457-461. Kijsisikul, Numao, and Shimura 49 | 1992 | 22 |
1,213 | Learning Relations by Bathfinding Bradley L. Richards Dept. of Computer Sciences University of Texas at Austin Austin, Texas 787 12 bradley@cs utexas .edu Abstract First-order learning systems (e.g., FOlL, FOCL, FORTE) generally rely on hill-climbing heuristics in order to avoid the combinatorial explosion inherent in learning first-order concepts. However, hill-climbing leaves these systems vulnerable to local maxima and local plateaus. We present a method, called relational pathfinding, which has proven highly effective in escaping local maxima and crossing local plateaus. We present our algorithm and provide learning results in two domains: family relationships and qualitative model building. 1 Introduction Many recent learning systems for first-order Horn clauses, such as FOIL, FOCL, and Forte ([Quinlan, 19901, [ Pazzani, Brunk, and Silverstein, 199 11, and [Richards and Mooney, 19911) employ hill-climbing to learn clauses one literal at a time. One of the problems faced by such hill- climbing systems is what we call the local plateau problem (see Figure 1). This arises when, in order to improve the classification accuracy of a rule, we must add two or more literals simultaneously. There may be many single relations which do not decrease the category accuracy, but which of these will lead to an eventual improvement? This paper presents a new method for dealing with this problem: relational pathfinding. This approach is based on the assumption that, in relational domains, there usually exists a fixed-length path of relations linking the set of terms satisfying the goal concept. For example, in a family domain, there is always a fixed-length path between a grandparent and a grandchild; this path consists of two parent relations. We present a method for finding these paths, and we demonstrate this method in three domains: family relationships, qualitative model building, and logic programming. The remainder of this paper is organized as follows: Section 2 gives a brief background on first-order learning systems. Section 3 describes our algorithm for relational pathfinding, illustrating it in the domain of family relationships. Section 4 presents results for the more complex problem of deriving qualitative models of dynamic systems from observed behaviors. Section 5 gives results in the domain of logic programming. Section 6 compares relational pathfinding to related work in the 50 Learning: Constructive and Linguistic Dept. of Computer Sciences University of Texas, Austin Austin, Texas 78712 mooney @cs . utexas . edu field and gives our recommendations for future work. Section 7 summarizes and concludes the paper. There are several first-order learning systems capable of pure inductive learning. Among these are FOIL [ Quinlan, 19901, FOCL [Pazzani, Brunk, and Silverstein, 19911, GOLEM [Muggleton and Feng, 19901, and Forte [-Richards and Mooney, 199 11. FOIL and GOLEM are designed as pure inductive learners. FOCL is an enhancement of FOIL which, if given an initial theory, Fire 1. The local plateau problem. uses it to provide hints to the learning process. Forte is designed primarily as a theory-revision system but, by revising an empty theory, can perform pure inductive learning. All of these systems learn first-order categorization rules, and all but GOLEM learn “top-down” by specialization, adding a single literal at a time to their rules. The top-down systems are vulnerable to local plateaus and local maxima. Relational pathfinding is designed to aid this type of system. GOLEM works “bottom-up” by generalization, and would not be helped by this technique. Top-down systems work by learning Horn clauses one at a time until all positive examples are covered. Each From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. clause is generated by adding one literal at a time using a simple hill-climbing technique. At each step, instantiations of each predicate in the data are tested for their ability to discriminate the remaining positive and negative examples, and the best discriminator is added to the clause. When all negative examples have been excluded, the clause is complete. Additional clauses are formed to cover any remaining positive examples. Of course, this hill-climbing approach is vulnerable to local plateaus and local maxima. Relational pathfinding is an attempt to avoid these locality problems. The idea of pathfinding in a relational domain is to view the domain as a (possibly infinite) graph of constants linked by the relations which hold between the constants. For example, a portion of the data in Minton’s family domain [Hinton, 19861 is shown in Figure 2. This domain is particularly easy to visualize since all relations are binary. Cl 1 ristopher mm Penelope Colin Charlotte I Figure 2. A portion of a family tree. We can see the local plateau problem by trying to define the grandparent relation using only the instances positive: ~r~~p~ent(~~~stop~e~, Colin) negative: gsandparent(Christop~er, Arthur) There is no single antecedent which will discriminate between these instances. Both Colin and Arthur have parents, neither has children, and neither is married’. Also, determinate literals do not help in this example; The only determinate literal available is ~~~e~(~~st~pher, Penelope), since all parents have two children and all children have two parents. In order to create a correct theory, we must simultaneously add both of the required parent relations, i.e., grandparent(8, y) + parent@, z) A Relational pathfinding is based on the assumption that, in most relational domains, important concepts will be represented by a small number of fixed paths among the constants defining a positive instance. For example, the instantiate rule with a positive instance find isolated sub-graphs for each sub-graph constants become initial end-values end for repeat for each sub-graph expand paths by one relation in all possible ways remove paths with previously seen end-values end for until intersection or resource-bound exceeded if we have intersections for each intersection add path-relations to original rule if the new rule contains new singletons add relations using the singletons if we eliminated all singletons keep the expanded rule else discard the rule end if end if replace constants with variables end for select most accurate rule end if if negatives are still provable use normal specialization to finish the rule end if algorithm 1. Overview of the relational pathfinding algorithm. grandparent relation is defined by a single fixed path consisting of two parent relations. Relational pathfinding can be tried anytime a clause needs to be specialized and does not have relational paths joining all of its variables. If, after pathfinding, the rule is still too general, we do further specialization using a standard FOIL-like technique. This arises, for example, when a rule requires non-relational antecedents. Relational pathfinding finds paths by successive expansion around the nodes associated with the constants in a positive example, in a manner reminiscent of Quillian’s spreading activation [Quillian, 3 968 1. We arbitrarily choose a positive instance and use it to instantiate the initial rule. The constants in the instantiated rule are nodes in the domain graph, possibly connected by antecedents in the rule. We then identify isolated subgraphs among these constants; if the initial rule contains no antecedents, then each constant forms a singular subgraph. We view a sub-graph as a nexus from which we explore the surrounding portion of the domain graph. Each exploration which leads to a new node in the domain graph is a path, and the value of the node it has reached Richards and Mooney 51 is the path’s end-value. Initially, constant in a sub-graph is the end-value of a path of length zero. Taking each subgraph in turn, we find all new constants which can be reached by extending any path with any defined relation. These constants form the new set of path end-values for the subgraph. We check this set against the sets of end-values for all other subgraphs, looking for an intersection. If we do not find an intersection, we expand the next node. This process continues until we either find an intersection or exceed a preset resource bound. When we find an intersection, we add the relations in the intersecting paths to the original instantiated rule. If the new relations have introduced new constants that appear only once, we complete the rule by adding relations which hold between these singletons and other constants in the rule. If we are unable to use all such singletons, the rule is rejected. Finally, we replace all constants with unique variables to produce the final, specialized theory clause. If we simultaneously discover several intersections, we develop clauses for ah of them and choose the one which provides the best accuracy on the training set. While the pathfinding algorithm potentially amounts to exhaustive exponential search, it is generally successful for two reasons. First, by searching from all nodes simultaneously, we greatly reduce the total number of paths explored before we reach an intersection. Second, most meaningful relations arc defined by short paths, which inherently limits the depth of search. However, a practical implementation of this method includes a resource bound. As an example, suppose we want to learn the relationship UPI.&~, given an initially empty rule and the positive instance uncle(Arthur, Charlotte). The process is illustrated in Figure 3. We begin by exploring paths from the node labelled Arthur, which leads us to the new nodes Christopher and Penelope. We then expand from the node labelled Charlotte, leading to the nodes Victoria and James. At this point we still do not have an intersection, so we lengthen all paths originating from node Arthur. We eliminate any end-values which we have already used (and which, therefore, do not give us an intersection). This leaves us with only one path end- value: Victoria. Since Victoria is also an end-value of one of the paths originating from Charlotte, we recognize an intersection. There are two paths leading from Arthur to Victoria, but in this case they are identical (merely leading through different grandparents). If we had found several paths, we would select the one providing the best overall accuracy. The final path is uncle(x, y) +- parent(z, x), parent(z, w), parent@, y) The literal male(x), which is required to complete this rule, is not a relation and is therefore added by ordinary specialization. 52 Learning: Constructive and Linguistic Ckktophet Penelope Arthur James Charlotte Christopher manw Penelope Arthur James w- Charlotte ‘qgare 3. rmamg one or me uncle rerauons. To test the hypothesis that relational pathfinding improves the accuracy of an empirical learning system, we ran Forte (Richards and Mooney, 19911 on the family data used in [Hinton, 19861 and [Quinlan, 19901, both with and without relational pathfinding. Training sets were randomly selected from a set containing all 112 positive instances and 272 “near-miss” negative instances, with the remainder serving as the test set. The data includes Figure 4. Inductive learning performance in Hinton’s family domain, averaged over 20 trials per data point. Inductive Learning I I I I , I I 1 I I 0 60 100 160 200 260 600 Training lnstancae - Norlnal - +- Fblatlon-path twelve family-relation concepts, so a training set of 60 instances includes an average of 5 instances for each concept. The results (see Figure 4) show a significant gain in learning performance for any size of training set. Above 120 instances, learning without relational pathfinding levels out while relational pathfinding leads to a complete and correct theory. By comparison, FOIL [Quinlan, 1990 ] achieved a maximum accuracy of 97.5 % on this data, using the equivalent of 2400 training instances. ive The family domain is ideal for demonstrating our approach since the relations are binary and form a fairly simple graph. However, relational pathfinding works equally well in more complex domains, as long as concepts can be viewed as fixed-length paths joining nodes in a graph. An example of this is the domain of qualitative modelling. Qualitative model building is a complex domain for two reasons. First, not all relations are binary. Second, values associated with new variables are not simple atoms, but full behavioral descriptions which may be only partially instantiated. One limitation of systems which derive qualitative models from behaviors is that there has been no satisfactory method of identifying missing variables. For example, if we seek to model the cascaded tank system shown in Figure 6, a complete model (see Figure 5) must include variables for inflow, outflow, amount, and net- flow for each tank. However, an observer is likely to measure only the externally visible variables, and to thereby omit the net-flow variables. We work with qualitative models as defined by QSIM [Kuipers, 19861. A QSIM model is a set of variables and a conjunction of constraints on those variables. Typical constraints (relations) include derivative (d/dt), add (+), M+, and M-. The constraints describe qualitative relationships among the variables over time. For example, the M+ constraint states that two variables are related by a strictly monotonically increasing function. Relational pathfinding provides a way to introduce missing variables into a model. Qualitative constraints impose restrictions on the values of their arguments; when used by relational pathfinding to generate end-values of paths, they partially instantiate the values to enforce their restrictions. Thus, the values are partial behavioral descriptions of hypothetical system variables. Two paths intersect when the restrictions on their end-values are consistent (i.e., when they can be unified). When the new rule is generalized, the intersection value becomes a new variable in the model. Forte, using relational pathfinding, is able to create correct models when one or more system variables have been omitted from the input behavioral descriptions. Consider a system of two cascaded tanks, A and B, where the inflow to tank A is constant, and the outflow from tank A provides the inflow to tank B. For this system, given Amount-A Out-A AIBOMW43 Inflow A: c3+Qtel-@+c3+ Amount A: ro t+ @+ c3+ @+ Outflow A: to t+ c3+ c3+ ot- Amount B: 00 f+ t+ t+ El+ Outflow B: 00 t+ t+ -r+ Qt- Time: 444444444 Table 1. Single behavior of two cascaded tanks reaching equilibrium. the single behavior shown in Table I3 (which omits any mention of the net-flow variables), Forte automatically produces the model model(Amount-A, Amount-B, Inflow-A, Ou-A, Out-B) mqlus(Amount-B, Out-B), mqlus(Amount-A, Out-A), m-minus(Out-A, Net-A), m minus(Amount-A, Net-A), de>vative(Amount-B, Net-B), derivative(Amount-A, Net-A), add(Net-B , Out-B, Out-A), add(Net-A, Out-A, Inflow-A), constant(Inflow-A). This model is the same as the correct model shown in Figure 5, with the addition of two redundant M- constraints. 5 Any Horn clause theory can be viewed as a logic program. However, in the domains of family relationships and qualitative models, theory are not recursive. If we wish to synthesize predicates for relations like append, reverse, or sort, we must be able to produce recursive clauses. Richards and Mooney 53 The only new issue we must consider is how to evaluate recursive calls. This is a problem because we are in the process of modifying the very predicate we wish to evaluate. Our answer is to use the positive instances in the training set as an extensional definition of the predicate. The means that, when synthesizing logic programs, we expect the training set to contain a complete set of positive examples (e.g., our training set for list reversal contains all instances for lists of length three or less, using up to three distinct atoms). Using the training set to evaluate recursive calls allows relational pathfinding to develop recursive clauses. Consider the predicate merge-sort. Suppose we already have definitions for split and merge, and we have already learned the base case. If relational pathfinding uses the instance it will develop the ground path shown in Figure 6. This path contains two singleton constants: [4,2] and [2,4]. However, we are able to eliminate both singletons by adding the relation merge_sort(]4,2], [2,43). Replacing the constants with variables produces the final, correct rule merge sort(A, B) :- s$it(A, C, D), merge-sort(C, E), merge-sort(l), F), merge(E, F, B). WOI-k Perhaps the earliest work on overcoming locality problems in first-order learning was [Vere, 19773, which introduced the idea of “association chains” composed of determinate binary relations. This idea appeared ahead of its time, since there were no first-order learning systems which could take advantage of it, but it foreshadows both determinate literals (see below) and relational pathfinding. Adding determinate literals to a rule is an idea used by Muggleton and Feng in GOLEM, and later added to FOIL ]Quinlan, 1991 J. Determinate literals are literals which, given the bindings derivable from a positive instance and prior literals, have only one possible ground instantiation. After adding all possible determinate literals (up to a predefined depth limit), learning proceeds normally. If, by adding the determinate literals, we added all but one of the relations necessary to cross any local plateaus or escape any local maxima, we will be able to learn a correct rule. When learning is complete, excess determinate literals are discarded. In theory, any chain of determinate literals can be found by relational pathfinding. However, in domains where relational paths are long, using determinate literals may be more efficient. In other domains, where we cannot find a chain of determinate literals to cross a local plateau or escape a local maximum, relational pathfinding will have the advantage. merge-sort Another method for dealing with locality problems is that of relational clicht?s, presented in [Silverstein and Pazzani, 19911. In this approach, the learning system has a predefined set of templates describing combinations of relations which often appear together. For example, the predicate part-of(x, y) generally appears along with a definition for part y. The learning system can add entire templates rather than single relations, thus avoiding some of the local maxima or plateaus which it might otherwise encounter. The method of relational pathfinding is more general than relational cliches since it does not depend on predefined templates; however, if the predefined templates are adequate for the learning domain, using relational cliches will be more efficient. A domain-specific system for building qualitative models is M&Q, presented in [Richards, Kraan, and Kuipers, 19921. To date, the only general purpose learning system applied to this problem is COLE&I [Bratko, NIuggleton, and Vargek, 19913. GOLElG’s performance in this domain is limited since it requires negative examples and its definitions of qualitative constraints are incomplete (e.g., it ignores corresponding values). Both MISQ and Forte can build qualitative models using only positive information. Relational pathfinding allows new model variables to be introduced in a natural way. In this paper we presented a new method, relational path finding, which helps first-order learning systems escape local maxima and cross local plateaus. It is similar to the approaches of determinate literals and relational cliches in that all of these approaches add multiple 54 Learning: Constructive and Linguistic relations to a rule. Although each of these methods addresses the same problem of escaping local maxima, they are useful in different circumstances. Relational pathfinding is more general than either of these methods, but potentially less efficient. We presented results in three domains in which relational pathfinding has proven useful. When learning family relationships, it provides a substantial performance advantage, requiring many fewer examples to learn accurate definitions. In qualitative modelling, it allows a system to learn an accurate model even if behavioral information on some variables is missing. And in logic programming, it provides an effective way to learn recursive clauses. In all of these domains, relational pathfinding allows the system to overcome the problem of local maxima and local plateaus while still limiting combinatorially explosive search. AC S This research was supported by the Air Force lnstitute of Technology faculty preparation program, by the NASA Ames Research Center under grant NCC 2-629, and by the National Science Foundation under grant IRI-9102926. Also, our thanks to Michael Pazzani for his helpful comments on an earlier draft of this paper. ferenms I. Bratko, S. Muggleton, and A. Vars’ek, “Learning Qualitative Models of Dynamic Systems,” Proceedings of the Eighth lnternational Workshop on Machine Learning, pp. 385-388, 1991. G. E. Hinton, “Learning Distributed Representations of Concepts,” Proceedings of the Eighth Annual Conference of the Cognitive Science Society, 1986. B. Kuipers, “Qualitative Simulation,” Artificial lntelli- gence, 29:289-338, 1986. S. Muggleton and C. Feng, “Efficient induction of logic programs, ” Proceedings of the First Conference on Algorithmic Learning Theory, 1990. M. J. Pazzani, C. A. Brunk, and G. Silverstein, “A knowledge-intensive Approach to Relational Concept Learning, ” Proceedings of the Eighth International Workshop on Machine Learning, pp. 432-436, 1991. M. R. Quillian, “Semantic Memory, ” Semantic Information Processing, MIT Press, pp. 227-270, 1968. J. R. Quinlan, “Learning Logical Definitions from Relations,” Machine Learning, 5:239-266, 1990. B. L. Richards, I. Kraan, and B. J. Kuipers, “Automatic Abduction of Qualitative Models,” Proceedings of the Tenth National Conference on Artificiallntelligence (A.&U 1992), 1992. B. L. Richards and R. J. Mooney, “First-Order Theory Revision, ” Proceedings of the Eighth lnternational Workshop on Machine Learning, pp. 447-451, 1991. 6. Silverstein and M. J . Pazzani, “Relational cliches: Constraining constructive induction during relational learning, ” Proceedings of the Eighth International Workshop on Machine Learning, pp. 203-207, 1991. S. A. Vere, “Induction of Relational Productions in the Presence of Background Information,” Proceedings of the Fifth international Joint Conference on Artificial Intelligence (IJCAI 1977), pp. 349-355, 1977. Notes ‘For this simple example we disregard the possibility of using negation, i.e., grandparent(n. y) t- iparent@, y). “The uncle relationship is completely defined by two paths, one of length 3 and one of length 4. We illustrate here the process of finding the shorter of these two paths. 3For simplicity, we show only the direction-of-change and the sign of each variable at each time point. The complete behavior includes qualitative magnitudes and dimensional information. Direction-of-change can be increasing ( T ), decreasing ( 4 ), or steady ( 8). Sign is plus ( + ), minus (-), or zero (0). J. R. Quinlan, “Determinate Literals in inductive Logic Programming,” Proceedings of the Eighth international Workshop on Machine Learning, pp. 442-446, 1991. Richards and Mooney 55 | 1992 | 23 |
1,214 | ichael . Lowry AI Branch M.S. 269-2 NASA Ames Research Center Moffett Field, CA 94035 lowry@pluto.arc.nasa.gov Abstract This paper describes a rational reconstruction of Einstein’s discovery of special relativity, validated through an implementation: the Erlanger program. Einstein’s discovery of special relativity revolutionized both the content of physics and the research strategy used by theoretical physicists. This research strategy entails a mutual bootstrapping process between a hypothesis space for biases, defined through different postulated symmetries of the universe, and a hypothesis space for physical theories. The invariance principle mutually constrains these two spaces. The invariance principle enables detecting when an evolving physical theory becomes inconsistent with its bias, and also when the biases for theories describing different phenomena are inconsistent. Structural properties of the invariance principle facilitate generating a new bias when an inconsistency is detected. After a new bias is generated, this principle facilitates reformulating the old, inconsistent theory by treating the latter as a limiting approximation. Introduction1 Twentieth century physics has made spectacular progress toward a grand unified theory of the universe. This progress has been characterized by the development of unifying theories which are then subsumed under even more encompassing theories. Paradigm shifts are nearly routine, with the postulated ontology of the universe changing from the three dimensional absolute space of Newtonian physics, to the four dimensional space-time of relativistic physics, and through many other conceptual changes to current string theories embedded in ten dimensions. Theoretical physicists attribute much of the success of their discipline to the research strategy first invented by Einstein for discovering the theory of relativity [Zee 863. ‘This research was supported in part by a sabbatical while the author was a member of the Kestrel Institute, and in part by a subcontract through Recom Technologies to NASA Ames Research Center. At the heart of Einstein’s strategy was the primacy of the principle of invariance: the laws of physics are the same in all frames of reference. This principle applies to reference frames in different orientations, displaced in time and space, and also to reference frames in relative motion. This principle also applies to many other aspects of physics, including symmetries in families of subatomic particles. The application of the invariance principle to “two systems of coordinates, in uniform motion of parallel translation relatively to each other” was Einstein’s first postulate: the principle of special relativity [Einstein 19051. Einstein’s genius lay in his strategy for using the invariance principle as a means of unifying Newtonian mechanics and Maxwell’s electrodynamics. This strategy of unifying different areas of physics through the invariance principle is responsible for many of the advances of theoretical physics. In the parlance of current machine learning theory, Einstein’s strategy was to combine the principle of special relativity with his second postulate, the constancy of the speed of light in a vacuum, in order to derive a new bias. (This second postulate was a consequence of Maxwell’s equations; [Einstein 19051 notes that experimental attempts to attribute it to a light medium were unsuccessful.) This new bias was designed and verified to be consistent with Maxwell’s electrodynamics, but was inconsistent with Newton’s mechanics. Einstein then reformulated Newton’s mechanics to make them consistent with this new bias. He did this by treating Newton’s mechanics as a limiting approximation, from which the relativistic laws were derived through generalization by the new bias. Einstein’s strategy is a model for scientific discovery that addresses a fundamental paradox of machine learning theory: in order to converge on a theory from experimental evidence in non-exponential time, it is necessary to incorporate a strong bias [Valiant 841, but the stronger the bias the more likely the ‘correct’ theory is excluded from consideration. Certainly any conventional analysis of what could be learned in polynomial time would exclude a grand unified theory of physics. The paradox can be avoided by machine learning algorithms that have capabilities for reasoning about and changing their bias. Even if a strong bias is ultimately ‘incorrect’, it is still possible to do a great 56 Learning: Discovery From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. deal of useful theory formation before the inconsistencies between the bias and empirical facts becomes a limiting factor. The success of the Galilean/Newtonian framework is an obvious example. In order to avoid the paradox, a machine learning algorithm needs to detect when a bias is inconsistent with empirical facts, derive a better bias, and then reformulate the results of learning in the incorrect bias space into the new bias space [Dietterich 911. The Erlanger program described in this paper is such an algorithm. Einstein’s strategy is essentially a mutual bootstrapping process between two interrelated hypothesis spaces: a space for biases, and a space for physical theories. The invariance principle defines the space of biases; each bias is a different postulated set of symmetries of the universe, formalized through a group of transformations. The invariance principle also defines a consistency relationship that mutually constrains the bias space and the space for physical theories. The hypothesis space for biases has a rich lattice structure that facilitates generating a new bias when a shift of bias is necessary. The hypothesis space for physical theories has an approximation relation between theories (limit homomorphisms) that, after a shift in bias, facilitates generating a new theory from an old (approximate) theory and the new bias. The entire process converges if learning in the bias space converges. This paper builds upon the considerable body of literature on relativity and the role of symmetry in modern physics. Its contribution includes identifying and formalizing the structural relationships between the space of biases and the old and new theories that enabled Einstein’s strategy to succeed, in other words, made it computationally tractable. The tactics for carrying out the components of this strategy have been implemented in the Erlanger program, written in Mathematics v.l.2. The next section of this paper introduces the invariance principle, which determines the consistency relationship between a bias and a physical theory. It also describes the procedure for detecting inconsistency. The following section presents the tactic for computing a new bias using the invariance principle. It takes the reader through the Erlanger program’s derivation of the Lorentz transformations. The section after defines limit homomorphisms, a formal semantics for approximation. The following section describes BEGAT: BiasEd Generalization of Approximate Theories, an algorithm which uses the invariance principle and the semantics of limit homomorphisms to generate components of the new theory. The paper concludes with a generalization of Einstein’s strategy called primal-dual learning, which could be applied to other types of biases. A longer version of this paper is contained in [Lowry 921. Symmetry is a unifying aesthetic principle that has been a source of bias in physics since ancient times. In modern physics this principle is stated as: ‘the laws of physics are invariant for all observers.’ An invariance claim is a universally quantified statement of the form ‘For all events/histories of type F, for all reference frames of type R, Physical Theory P holds’. An invariance claim implies that a group of transformations mapping measurements between different observers also maps physical theory P onto itself. Such a group of transformations defines the postulated symmetries of the universe, and is the type of bias used by theoretical physicists. The transformations are parameterized by the relation between two different observers, such as their relative orientation or velocity. For example, Galileo defined the following transformation equations relating measurements for observers in constant relative velocity v parallel to the x-axis: Ix’ =x-vt, t’= t) These transformations are consistent . with Newton’s theory of mechanics. The invariance principle defines a consistency relationship between physical theories and groups of transformations. The following definitions are standard and sufficient for our purpose of understanding and implementing Einstein’s strategy for deriving special relativity. However, the reader should be aware that these definitions are a simple starting point for a deep, well developed mathematical theory that has had a profound impact on theoretical physics. (A good mathematical exposition focused on special relativity is [Aharoni 651, a more sophisticated philosophical and foundational treatment is [Friedman 831.) Below, G is a transformation group. An invariant operation is a special case of a covariant operation. Laws are invariant if they define the same relation after they are transformed by the action of the transformation group. A sufficient condition for a theory to be invariant with respect to a transformation group G is if all the operations are covariant and all the laws are invariant. Invariance of an operation or form: Invariant(op,@ e \d(fl E I;,xl...x,) OP(X, 9 x:! ,...J,) = OP(&,X*,...,X,N Covariance of an operation or form: Covariant(op, Cj) H V(g E &xl...x,) OP(~(X,J,,..., x,)) = g(oP(x~,x~,...,x,)) H V(g E gxl...x,) op(x~,+*., -ql) = 8-‘(oP(8(xl,x2,.~.,x.))) Invariance of a physcial law expressed as a universally quantified equation: Invariant(V(...) tl(...) = t2(...), G) H V(J E &Xl...&) w, 9x2 ,..., x,)= t2(xl,x, ,..., x0) ‘tl(fl(xl,xz,..., -qJ) = t2(~tX~.X2,...Jn)) To check an invariant predicate, the Erlanger program back-substitutes transformation equations into a form or law and then compares the result to the original form or law. If the function or relation are the same, then the invariant predicate is true. In essence the Erlanger program assumes the law holds good in the original reference frame and then transforms the law into measurements that would be observed in a new frame of reference. (This can be done Lowry 57 independent of whether the law is invariant.) If these measurements agree with the law stated in the new frame of reference, then the law is invariant. The steps of the algorithm are described below and illustrated with the example of determining whether the Galilean transformations are consistent with the constant speed of light, Einstein’s second postulate. The input is the definition of the law for the constant speed of light, and the transformation equations relating variables in the original frame of reference to the variables in the new (primed) frame of reference: Invariant(x2 = c2t2 9 {x = x’+ vt’, t = t’}) 1. Solve the law in the new frame of reference to derive expressions for dependent variables (This turns a relation between variables into a disjunction of sets of substitutions.): (IX’ = Ct’), IX’ = -ct’)) 2. Use the parameterized transformation equations to substitute expressions in the new frame of reference for variables in the old frame of reference; this yields a new law relating measurements in the new frame of reference: (x’+ vq2 = c2f2 3. The substitutions derived in step 1 are applied to the new law derived in step 2: {(ct’+ vty2 = C2t’2, (-Cf + vq2 = c2t’2} 4. If the law(s) derived in step 3 is a valid equality(ies), then the law(s) is invariant. For this example they are not, so the Erlanger program determines that Einstein’s second postulate is inconsistent with the Galilean transformations. Deriving a New The invariance principle can be used not only to verify that a physical law is consistent with a particular bias, but also to generate a new bias when a physical law is inconsistent with the current bias, as when the constant speed of light is inconsistent with the Galilean transformations. There are important structural aspects of the invariance principle that enabled this aspect of Einstein’s strategy to succeed. In particular, the consistency relationship is contravariant: a weaker physical theory is consistent with a larger set of transformations. (For the purposes of this paper, ‘weaker’ can be thought of as ‘fewer deductive consequences’, though this is not entirely correct.) Thus when an inconsistency is detected between a bias represented by a set of transformations and an evolving physical theory, the physical theory can be relaxed, leading to an enlarged set of transformations. This enlarged set is then filtered to compute the new bias. Assume that a physical theory T (e.g. Newton’s mechanics) is consistent with a transformation group G (e.g. the Galilean group). Further assume that G is the largest transformation group consistent with T. Then a new empirical fact e is observed (e.g. the constant speed of light), such that e is not consistent with G. Then T is relaxed to 7” (e.g. Newton’s first law), thereby enlarging G to G’ (e.g. the set of all linear transformations). The new bias is the subset of G’, i.e. G “(e.g. the Lorentz group), such that T’ with e is consistent with G”. Then the laws in (T - 7”) are transformed so that they are consistent with G ” and have as limiting approximations the original laws. This section describes an implemented algorithm for deriving G “, while the next sections describe transforming the laws in (T - T’). These same algorithms can also be used when trying to unify theories with different biases, such as Newton’s mechanics and Maxwell’s electromagnetism. The Lorentz group is a set of transformations that relate the measurements of observers in constant relative motion The Lorentz group is a sibling to the Galilean group in the space of biases. Einstein’s derivation of the Lorentz transformations implicitly relied upon structural properties of the lattice of transformation groups. In particular, Einstein constrained the form of the transformations with an upper bound, derived from Newton’s first law: a body in constant motion stays in constant motion in the absence of any force. This is his assumption of inertial reference frames, an assumption he relaxed in his theory of general relativity. The largest set of transformations consistent with Newton’s first law are the four dimensional linear transformations. Of these, the spatial rotations and spatial/temporal displacements can be factored out of the derivation, because they are already consistent with Einstein’s second postulate. (The Erlanger program does not currently have procedures implemented to factor out subgroups of transformations - these are under development.) This leaves an upper bound for a subgroup with three unknown parameters (a,df) whose independent parameter is the relative velocity (v): x = u(x’+ vt’) t = dx’+ ft’ This upper bound includes both the Galilean transformations and the Lorentz transformations. The DeriveNewBias algorithm takes the definition of an upper bound, such as the one above, including lists of the unknown and independent parameters, a list of invariants, a list of background assumptions, and information on the group properties of the upper bound. When this algorithm is applied to Einstein’s second postulate of the constant speed of light, the derivation of the Lorentz transformations proceeds along roughly the same lines as that in Appendix 1 of [Einstein 19161. This derivation and others are essentially a gradual accumulation of constraints on the unknown parameters of the transformations in the upper bound, until they can be solved exactly in terms of the independent parameter which defines the relation between two reference frames. The algorithm is described below, illustrated with the example of deriving the Lorentz transformations. . The input in this example to the DeriveNewBias algorithm is the upper bound given above, two invariants for a pulse of light - one going forward in the x direction and one going backwards in the x direction -t x = ct, x = -cl}, the assumptions that the speed of light is not zero and that the relative velocity between reference frames is less than the speed of light, and information for 58 Learning: Discovery computing the inverse of a transformation.The steps of the DeriveNewBias algorithm: 1. Constraints on the unknown parameters for the transformation group are derived separately from each individual invariant. This step is similar to the procedure which checks whether a law is invariant under a transformation group. However, instead of steps 3 and 4 of that procedure, the system of equations from steps 1 and 2 are jointly solved for constraints on the unknown parameters. For the two invariants for a pulse of light, the derived constraints are: a=(-c2d+cf)/(c-v), a=(c2d+cf)/(c+v) 2. The constraints from the separate invariants are combined through Mathematics’s SOLVE function. In the example of the Lorentz derivation, this reduces the unknown parameters to a single unknown v): a= f, d=(fv)lc2 3. In the last step, the group properties are used to further constrain the unknown parameters. Currently the implemented algorithm only uses the inverse property of a group, but the compositionality property is another source of constraints that could be exploited. First, the constraints on the unknown parameters are substituted into the upper bound transformation definition, yielding a more constrained set of transformations. For the Lorentz example this yields: x = f(x’ + vt’) t = ft’+fvx’/c2 Second, the inverse transformations are computed. The information given to the algorithm on the grouti properties of the upper-bound define how the independent parameter for the -transformation is changed- for the inverse transformation. For relative velocity, this relation is simply to negate the relative velocity vector . This then yields the inverse transformations: XI = f(x - vt) t’= ft-(fvx)/c2 The inverse transformations are then applied to the right hand side of the uninverted transformations, thereby deriving expressions for the identity transformation: x= f(f(x-vt)+v(ft-p)) fvx t=f fr-- -I- ( ) fiJf(x - vt) C2 C2 These expressions are then solved for the remaining unknown parameters of the transformation (e.g.8, whose solution is substituted back into the transformations: dc 1 x = (A!+ vt’)- t/T G+c:Y d - The result is the new bias, which in this example is equivalent to the standard definition of the Lorentz transformations (the definitions above are in Mathematics’s preferred normal form). eories. Once a new bias is derived, a learning algorithm needs to transfer the results of learning in the old bias space into the new bias space. This is done by treating the old theory as an approximation to the new, unknown theory. Reasoning with approximate theories, and even generating approximate theories from detailed theories, has become a topic of research in AI in recent years [Bellman 901. Various notions of “approximation” have been developed to support these reasoning methods. The problem of generating a new theory from an approximate theory and a new bias requires a precise definition of approximation with a well defined semantics. This section describes limit homomorphisms, which are homomorphisms that only hold in the limiting value of some parameter. A limit homomorphism is a map h from one domain to another such that for corresponding functions f and g the following equality converges as the limit expression goes to the limiting value: lim expr-bvalue h(f(x,...x,)) = g(h(x,)...h(x,)) Within physics, limit homomorphisms define the relationship between new, unified theories and the older theories they subsume. If the mapping function h is invertible, then a limit homomorphism can be defined in the reverse direction. The limit homomorphisms between Newton’s mechanics and different formulations of relativistic mechanics can all be defined through tupling and projections that are invertible. From an a priori, mathematical viewpoint neither Newtonian mechanics nor relativistic mechanics is intrinsically more general than the other - the mathematical relationship is symmetric; each is a limit homomorphism of the other. These theories agree on their predictions when velocities are low, but diverge as velocities approach the speed of light. Relativistic mechanics is a posteriori more general because its predictions agree with experimental facts for high velocities, hence the theory is more generally applicable. Relativistic mechanics is also extrinsically more general in the sense that its bias is consistent with electrodynamics, and hence relativistic mechanics and electrodynamics can be unified. iasEd Generalization of Approximate Theories) While the intrinsic mathematical relationship between Newtonian and relativistic physics is not one of generalization [Friedman 831, the process of generating relativistic mechanics from Newtonian mechanics is one of generalization. This section describes the mathematics justifying this process, and an implemented algorithm based on these mathematics that derives relativistic kinematics. Extensions are currently under development to Lowry 59 enable it to derive different formulations of relativistic dynamics. It is clear from a reading of [Einstein 19051 that Einstein derived relativistic mechanics from Newtonian mechanics, by treating the latter as a limiting approximation that was valid in low velocity reference frames and applying the Lorentz transformations in order to generalize to the relativistic laws. For example, in section 10, paragraph 2 of Einstein 19051: “If the electron is at rest at a given epoch, the motion of the electron ensues in the next instant of time according to the equations [Newton’s equations of motion] . . . as long as its motion is slow.” Einstein then generalized to the relativistic equation of motion by applying the Lorentz transformations to Newton’s equations of motion. Einstein even constrained the laws of relativistic dynamics to have the same form as Newtonian dynamics. A theory such as Newton’s mechanics that has a high degree of experimental confirmation over a range of phenomena (e.g. particles interacting at low velocities compared to the speed of light), represents a summary of many experimental facts. If a new theory is to account for these same experimental facts, it must agree with the old theory over the same range of phenomena. Hence the old theory must approximate, to within experimental error, the new theory over this range of phenomena (and vice versa). When both the old theory and the new theory comply with the invariance principle, then the difference in the biases will determine the limit point, i.e. the range of phenomena over which they must agree. The following mathematical sketch explains what this limit point must be, when the theories postulate the same number of dimensions. The two biases will share some subgroups in common (e.g. the spatial rotations) and differ in other subgroups (e.g. the subgroup for relative velocity). For the subgroups that differ, the identity transformations will be the same. Hence the value of the parameter (e.g. relative velocity) that yields the identity transformation must be the limit point (e.g. 0 relative velocity). Furthermore, assuming that the transformations in the differing subgroups are a continuous and smooth function of their parameter(s), and that the functions in the respective theories are smooth and continuous, then the bounding epsilon-delta requirements for a limit are satisfied. Thus, given a new bias, the new theory must be derived so that it satisfies two constraints: the theory is invariant under the new bias, and the old theory is a limit homomorphism of the new theory. In simple cases, these two constraints can be solved directly to generate parts of the new theory by applying the transformations in the new bias to ‘rotate away’ from the limit point, as Einstein ‘rotated’ a description of Newton’s equations for an electron initially at rest to reference frames in which it was not at rest. (Here ‘rotate’ means applying the transformations in the subgroups of the new bias not contained in the old bias, e.g. the Lorentz transformations.) For the operations of the new theory. these two constraints can be combined as follows: 1. New, unknown operation is covariant wrt new bias: op(&q,x,,..., x,N = B(oP(++..4)) Equivalently: op(xl ,x2 ,. . . , x, ) = 8-l (op(8(x, ,x2 ,. . . ,x, ))) 2. New, unknown operation has limit homomorphism to old operation op’: x,..r.‘x”-, htopCq,x2,...,x,N= op’(h(x,),h(x2),...,h(x,)) 1imitYpoint Thus: op(-q,-$,...,.q#) = flW1 (op’V~(,& h ht&2 N,. . . r h(&n)))N where~(x,,x,,...,x,) =limit point In words, the new operation is obtained by : 1. Finding a transformation 8 that takes its arguments to a reference frame where the old operation is valid. 2. Applying the inverse transformation to define the value of the new operation in the original reference frame. Applying BEGAT to derive the laws of the new theory is a similar two step process: first, a transformation is determined that takes the variables to a reference frame in which the old laws are valid, and then the inverse transformations are symbolically applied to the equations for the old laws. The algorithm is underconstrained, because of the interaction of the definition of the new (unknown) operation and the definition of the (unknown) homomorphism h. In parts of Einstein 19051, Einstein assumes that h is the identity, for example in his derivation of the relativistic composition of velocities ( described below), and then derives an expression for the new operation. In other parts of [Einstein 19051, he assumes that the old operation and the new operation are identical, for example in his derivation of the relativistic equation of motion. In that derivation he kept the same form as the Newtonian equation (i.e. force = mass * acceleration) and then solved for a relativistic definition of inertial mass, and hence h. To his credit, Einstein recognized that he was making arbitrary choices [Einstein 1905 section 10, after definition of transverse mass]: “With a different definition of force and acceleration we should naturally obtain other values for the masses.” Different assumptions about the ontology of relativistic mechanics leads to different homomorphisms h and different formulations of the equation for relativistic dynamics. In his original paper, Einstein reformulated the Newtonian equation by measuring the force in the reference frame of the moving object and the inertial mass and acceleration in the reference frame of the observer. (In essence, Einstein did not complete step 2, for reasons too complex to explain here.) This leads to a projection of the Newtonian mass into separate transverse and longitudinal relativistic masses. A subsequent formulation of relativistic dynamics consistently measures forces, masses, and accelerations in the reference frame of the observer, resulting in a single relativistic mass that varies with the speed of the object. In this formulation the mass of a system is the sum of the masses of its components, and is conserved in elastic collisions. The modern formulation of relativistic dynamics, based on Minkowski’s space-time 66 Learning: Discovery and Einstein’s tensor calculus, requires that components that transform into each other be tupled together. Thus because time coordinates transform into spatial coordinates, time and space are tupled into a single 4- vector. Consequently energy and momentum are also tupled together. In this case h maps Newtonian inertial mass to rest mass, and maps Newtonian acceleration and forces to their 4-vector counterparts. The following illustrates how the BEGAT algorithm works for a simple operation when h is the identity, refer to [Lowry 921 for details on more complicated cases. Note that when h is the identity: op( x1, x2 ,. . . ,x, ) = 8-1(op’(~~x,),B~x2),~~*,8(~~~) whereg(xl,x2,...,x,) =limrt point BEGAT takes as input the definition of the old operation, the list of transformations for the new bias, and a definition of the limit point. For the composition of velocities, the old operation is simply the addition of velocities: Newton - Compose(v1, v2) = vl + v2 where: vl is the velocity of reference frame R, w.r. t. R0 v2 is the velocity of object A w. r. t. reference frame R, and the output is defined in reference frame R0 The transformations are the Lorentz transformations derived earlier. The limit point is when R, is the same as R,, i.e. vl = 0. The first part of the reasoning for the BEGAT algorithm is at the meta-level, so it is necessary to understand some aspects of the notation used in the Erlanger program. Variables are represented by an uninterpreted function of the form: var[event, component, reference-frame]. This form facilitates pattern matching. Transformations have representations both as lists of substitutions and as a meta- level predicate of the form: Transform[start-frame, end-frame, independent-parameter] The independent parameter for relative velocity has the form: var[end-frame,relvelocity,start-frame]. Thus vl is represented as var[R1,relvelocity,R,] and v2 as var[A,velocity,R,]. 1. BEGAT first solves for 8, the transformation which takes the arguments to the limit point. This transformation maps the reference frame for the output to the reference frame for the limit point. The result is obtained by applying a set of rewrite rules at the meta-level: Transform[RO,R1,var[RO,relvelocity,R,ll This transformauon maps reference frame R, to reference frameR . 2. BEGAT next solves for the value of the variables which are given to the old operation, i.e. a(vl), dv2). For dvl) it symbolically solves at the meta-level for: Apply[Transform[R,,R,,var~,,relvelocity,R,]], var[R ,relvelocity, RJ], obtaining varlJX ,relvelocity,R,], i.e. bolically at vl)=O Fordv2) it sym solves at the meta-level for: Apply[TransformlR,,R,,var[RO,relvelocity,R,ll, var[A,velocity, R obtaining var[A,velocity,R,], i.e. g(v2)=v2 since v d I], is measured in R,. This meta-level reasoning about the application of transformations is necessary when the input variables and the output variables are defined in different reference frames. 3. BEGAT next symbolically applies the old operation to the transformed variables: Newton - compose(g(vl),8(v2)) = 0 + v2 = v2 4. BEGAT finally applies the inverse transformation to this result to obtain the definition for the relativistic operation: Relativistic-compose(v1 ,v2) = Apply [Transform R, ,R,,var[R, ,relvelocity ,R,]], var[A,velocity, R,l1 There is no transformation yet defined for velocrties, so BEGAT calls DeriveCompositeTransformation with the definition for velocity (i.e.v = &A,), and the Lorentz Transformations for the components of the definition of velocity - namely the transformations for the x co-ordinate and the time co-ordinate derived earlier. DeriveCompositeTransformation then symbolically applies these transformations to the components of the definition, and then calls Mathematics’s SOLVE operation to eliminate the Ax, At components from the resulting expression. The result is the same definition as Einstein obtained in section 5 of [Einstein 19051: Relativistic - compose(vl,v2) = (vl + v2) / (1 + (~1~2) / c2) elated Research Within AI, this research is related to scientific discovery and theory formation [Shrager and Langley 901, qualitative physics [Weld and de Kleer 901, change of bias in machine learning [Benjamin 90a], and use of group theory [Benjamin gob]. The research in this paper appears to be the first addressing the scientific revolutions of twentieth century theoretical physics. The notions of approximation within qualitative physics are closely related to limit homomorphisms. Within machine learning, research on declarative representations and reasoning about bias is most important, see the collection of papers in [Benjamin 90a]. Conclusion: Toward A hypothesis of this research is that Einstein’s strategy for mutually bootstrapping between a space of biases and a space of theories has wider applicability than theoretical physics. Below we generalize the structural relationships of the invariance principle which enabled the computational steps of Einstein’s derivation to succeed. We conjecture that there is a class of primal-dual learning algorithms based on this structure that have similar computational properties to primal-dual optimization algorithms that incrementally converge on an optimal value by alternating updates between a primal space and a dual space. More details can be found in [Lowry 921. Let B be a set of biases with ordering relation a that forms a lattice. Let I be a set of theories with ordering relation 4 that forms a lattice. Let cbe a consistency relation on ml such that: Lowry 61 C(b, t) and b’ Q b a C(b’, t) C(b, t) and t’ 4 t --4 C(b, t’) This definition is the essential property for a well- structured bias space: As a bias is strengthened, the set of theories it is consistent with decreases; as a theory is strengthened, the biases it is consistent with decreases. Hence ~defines a contravariant relation between the ordering on biases and the ordering on theories. Let 21 be the max bias function from I + B such that C&Z(t), t)and t’b C(b, t) 3 b a u(t).Let ‘D be a function from ‘B x I + rBsuch that ‘o(b, t) = b A U(t), where A is the lattice meet operation. I, is the DeriveNewBias function, which takes an upper bound on a bias and filters it with a (new) theory or observation to obtain a weaker bias. (For some applications of primal-dual learning, D should take a lower bound on a bias and filter it with a new theory or observation to obtain a stronger bias. ) 2) is well-defined whenever 9, I, and c have the properties described above. However, depending on the type of bias, it might or might not be computable. If it is computable, then it defines the bootstrapping from the theory space to the bias space when an inconsistency is detected. The bootstrapping of BEGAT from a new bias to a new theory that has a limiting approximation to the old theory requires two capabilities. First, given the old bias and the new sibling bias, the restriction of the old theory to those instances compatible with the new bias must be defined and computable. Second, given this restriction, its generalization by the new bias must also be defined and computable. As an example of BEGAT with a different type of bias, consider the problem of learning to predict a person’s native language from attributes available in a data base. A declarative representation for biases that includes functional dependencies was presented in [Davies and Russell 871 and subsequent work. Let the original bias be that the native language is a function of the birth place. This bias would likely be consistent with data from Europe, but would be inconsistent with the data from the U.S. because of its large immigrant population. Assume that a function 13 derives a new bias where the native language is a function of the mother’s place of origin. Then the restriction of the original theory to concepts derived from non-immigrant data is compatible with this new bias. Furthermore, the concepts learned from this restricted set can be transfered directly to the new theory by substituting the value of the birth place attribute into the value for the mother’s place of origin. Future research will explore the theory and application of primal-dual learning to theoretical physics and other domains. Given the spectacular progress of twentieth century physcis, based on the legacy of Einstein’s research strategy, the computational advantages of machine learning algorithms using this strategy might be considerable. Acknowledgements Thanks to Robert Holte, Laura Jones, Hugh Lowry, Thomas Pressburger, Jeffrey Van Baalen and the referees for their many helpful comments for improving this paper. References Aharoni, J. 1965. The Special Theory of Relativity. New York: Dover. Benjamin, P. editor. 1990a. Change of Representation and Inductive Bias. Boston: Kluwer. Benjamin, P. editor. 1990b. Workshop Proceedings for Algebraic Approaches to Problem Solving and Perception. June 1990. Davies, T. R. and Russell, S.J. 1987. A Logical Approach to Reasoning by Analogy. In IJCAI-87. Dietterich, T. 1991. Invited Talk on Machine Learning at AAA191, Los Angeles, CA. Einstein, A. 1905. On the Electrodynamics of Moving Bodies. In The Principle of Relativity, A Collection of Original Memoirs on the Special and General Theory of Relativity, contributors H.A. Lorentz, A. Einstein, H. Minkowski, and H. Weyl. NewYork: Dover (1952). Einstein, A. 1916. Relativity: The Special and General Theory. A clear explanation that anyone can understand. New York: Crown. Ellman, T. editor. 1990. AAAI90 Workshop proceedings on Automatic Generation of Abstractions and Approximations. Boston, MA. Forbus K.D. 1984. Qualitative Process Theory. Artificial bztelligence(24):85-168. French, A. P. 1968. Special Relativity. New York: Norton. Friedman, M. 1983. Foundations of Space-Time Theories: Relativistic Physics and Philosophy of Science. New Jersey: Princeton University Press. Kuhn, T. S. 1962. The Structure of Scientific Revolutions. Chicago: University of Chicago Press. Lowry, M.R. editor. 1992. Proceedings of the Asilomar Workshop on Problem Reformulation and Representation Change. NASA AMES Technical Report FIA-92-06. Shrager, J. and Langley, P. eds. 1990. Computational Models of Scientific Discovery and Theory Formation, editors. San Mateo: Morgan Kaufmann. Skimmer, R. 1982. Relativity for Scientists and Engineers. New York: Dover. Taylor, E.F. and Wheeler, J.A. 1966. Spacetime Physics. San Francisco: Freeman. Valiant, L.G. 1984. A Theory of the Learnable. In CACM (27): 1134-l 142. Weld,D.S. 1989. Automated Model Swithching: Discrepency Driven Selection of Approximation Reformulations. University of Washington Computer Science Department Technical Report 89-08-01. Weld, D.S. and de Kleer, J. eds. 1990. Readings in Qualitative Reasoning about Physical Systems. editors. San Mateo, CA: Morgan Kaufmann. Zee, A. 1986. Fearful Symmetry: The Search for Beauty in Modern Physics. New York: Macmillan. 62 Learning: Discovery | 1992 | 24 |
1,215 | School of Computer Science and Center for Light Microscope Imaging and Biotechnology Carnegie Mellon University Abstract One goal of machine discovery is to automate cre- ative tasks from human scientific practice. This paper describes a project to automate in a gen- eral manner the theory-driven discovery of reac- tion pathways in chemistry and biology. We have designed a system - called MECHEM - that pro- poses credible pathway hypotheses from data or- dinarily available to the chemist. MECHEM has been applied to reactions drawn from the history of biochemistry, from recent industrial chemistry as reported in journals, and from organic chem- istry textbooks. The paper first explains the chemical problem and discusses previous AI treatments. Then are pre- sented the architecture of the system, the key algo- rithmic ideas, and the heuristics used to explore the very large space of chemical pathways. The system’s efficacy is demonstrated on a biochemi- cal reaction studied earlier by Kulkarni and Simon in the KEKADA system, and on another reaction from industrial chemistry. Our project has also resulted in separate novel contributions to chemical knowledge, demonstrat- ing that we have not simplified the task for our convenience, but have addressed its full complex- ity. Introduction The goal of machine discovery is to interpret scientific reasoning in computational terms by automating spe- cific tasks or formulating general conceptions of scien- tific activities (e.g., experiment design, theory choice). The usual focus has been on scientific discovery be- cause of its status in the scientific pantheon, although it has been argued by [Simon, 1966] that the processes of discovery are not distinct from less exalted aspects of scientific reasoning or from more mundane reasoning. This paper describes the current state of a project that attempts to automate the discovery of reac- tion pathways in chemistry and biology and which began as the author’s Ph.D. thesis [Valdes, 1990b, Valdes, 199Oc]. This theory-driven task is of a long tradition in science, and is important today both for its scientific aspect and economic significance , since understanding the pathway underlying a chemical syn- thesis is a first step toward improving its industrial yield. We have designed a system - called MECHEM - that can propose credible pathway hypotheses from data or- dinarily available to the chemist. MECHEM has been applied to reaction data drawn from the history of bio- chemistry, from recent industrial chemistry as reported in journals, and from organic chemistry textbooks. The following section first explains the chemical problem and discuss previous AI treatments of path- way discovery. Then are presented the architecture of the system, the key algorithmic ideas, and the heuris- tics used to explore the very large space of chemical pathways. Then the system’s efficacy is demonstrated on two specific reactions, one of which was studied earlier by [Kulkarni and Simon, 19881 in the KEKADA system. Finally, the issue of generality is taken up. iscovery of reaction pathways The chemical problem of discovering reaction pathways is as follows. Given empirical data on starting materi- als and observed products (not necessarily final prod- ucts) of a specific chemical reaction, 1. infer simple, plausible pathways that explain the em- pirical data and are consistent with existing theory, and 2. seek and apply further evidence to discriminate among the plausible pathways. For example, a reaction that consumes the starting materials ornithine, ammonia, and carbon dioxide and that is observed to form the products urea, arginine, and water can be explained by the following pathway: ornithine -I- NH3 + CO2 - Hz0 + CgH1sN303 NH3 + C6H13N303 - arginine -I- Ha0 arginine + Hz0 - urea -I- ornithine in which the chemical species &HieNsOs has been conjectured, i.e., was not observed and was not part of Valdh-Perez 63 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. the input data. (Ornithine is C’S H12N202, ammonia is NH3, carbon dioxide is C@, arginine is C6HiaN402, and urea is CH*N20. The reader can verify that all steps are balanced.) The celebrated discovery of this pathway by the biochemist Hans Krebs was studied historically by [Holmes, 19801 and was the subject of a cognitive model by [Kulkarni and Simon, 19881. The idealized problem of pathway discovery is to find the exact set of steps that occur in a given chemical reaction. In current practice it is infeasible to deter- mine the pathway with certainty, for several reasons. The most recalcitrant reason is that, given usual exper- imental data and a pathway to explain those data, one can always create a more elaborate pathway that ex- plains the data equally well. Hence, the practical task is to find a set of steps that is consistent with all or most of the experimental data, is consistent with cur- rent knowledge of what types of reaction tend to occur, and is simple, i.e., no more complex than needed. Discovery of reaction pathways is a theory-driven task because most of the heuristics are derived from strong theoretical presuppositions drawn from the do- main science. Pertinent chemistry knowledge This section describes the minimal chemistry knowl- edge needed to understand the task domain of MECHEM. [King, 19631 is a good elementary introduc- tion to the basic concepts. The notation A + B --) X + Y expresses a process, or reaction, by which the chemical substances A and B are transformed into new substances X and Y. The starting materials are the chemicals that are placed in a medium to start a reaction or sequence of reactions. A molecular formula (or just formula) is a list of the type and number of atoms making up a chemical sub- stance, e.g., CH20 for formaldehyde. In this paper, a chemical species corresponds to a unique formula, and vice versa-thway is defined as a set of individual reactions. each-h is a sten. , Ordinary A chemx reactions conserve mass; molecules are transformed into prod- uct molecules only in ways that conserve total num- bers and types of atoms. The concentration of a reac- tion species refers to the number of species molecules per unit volume; concentrations can vary over time as species react or are formed. Role of pathway discovery in chemistry Chemists often undertake to determine a reaction pathway for purely scientific reasons. Other reasons arise in the context of enhancing the yield of a synthe- sis, because even partial knowledge of the pathway can suggest changes to the reaction conditions that may improve the yield. For example, another reagent might be introduced in order to increase the rate of a desir- able step. Studies of the pathways underlying chemical reactions appear frequently in chemical and chemical engineering journals. Even a paper whose main pur- pose is to describe a new chemical synthesis typically includes at least some discussion of the pathway un- derlying the synthesis. The discovery of reaction pathways has not been successfully automated ([Valdes, 199Ob] has details). In particular, the automatic generation of plausible pathways has received little attention; for example, [Carpenter, 19841 in the preface to a textbook on the subject states: “Regrettably (or not, depending on one’s point of view) there are no algorithms for gener- ating scientific hypotheses.” Finally, we note that the space of pathway solutions is well understood in chemistry: the space consists of a set of reaction steps, each step consisting of a small number of reactants giving rise to a small number of products. What was not understood prior to our work was how to formulate a problem space, i.e., to find op- erators or an algorithm that explore the space system- atically. Prior work The only prior work in AI on discovering re- action pathways is that of [Soo ei al., 19871 and [Kulkarni and Simon, 19881. Soo et al. describe a pro- gram that uses known rules to interpret experimental concentrations data represented in a special form (as Lineweaver-Burk plots). Given a catalogue of reaction pathways, the program tested each catalogued entry against constraints inferred by the rules. Hypothesis generation was not otherwise addressed, nor experi- ment design. Also, knowledge of all reaction species and their roles in the reaction (i.e., substrate or prod- uct) was assumed. Kulkarni and Simon developed a cognitive model of the historic discovery of a biochemical reaction path- way by Hans Krebs, but they focussed on the heuristic strategies that Krebs used to design and interpret ex- periments. They did not attempt to automate in a systematic manner the general problem of discovering reaction pathways. The MECHEM System Architecture Figure 1 is the model of pathway discovery underlying MECHEM; the only aspect of the model not currently addressed by our work is deciding whether the current hypotheses and evidence constitute a scientific contri- bution (deciding when to suspend work on a problem is discussed briefly in [Valdes, 1990bl). As depicted, the theory-formation cycle starts with the initial data from a problem instance. These data suggest initial values of the hypothesis complexity parameters, which are the number of steps R and species S to be contained in a pathway hypoth- esis. Then the hypothesis generator (called STOICH) cycles until it finds a non-empty set of pathways, at 64 Learning: Discovery lnorement Compfexity * I I Parameter t Figure 1: A Model for Pathway Discovery which point these are tested against the available ev- idence not already incorporated in the generator. If all pathways are discredited to the point of rejection, then hypothesis generation resumes with incremented complexity parameters. If the current pathways explain the existing evi- dence, then an experimentation cycle is entered. Ini- tially, evidence is sought to discriminate among them. Any evidence found is applied to filter the pathways; if all of the latter are rejected, then hypothesis for- mation resumes after incrementing the complexity. If some pathways survive, then one might decide that a scientific result has been achieved, e.g., a small set of highly credible pathways. If, on the other hand, no evidence can be found with an effort deemed appropriate, then still one might de- cide that a disseminable result has been reached, or perhaps decide to suspend the problem, or decide to incur a greater cost in order to find more evidence. Strategic decisions such as whether to suspend work on a problem, publish one’s results, or incur greater cost to obtain evidence are not yet addressed by our work. Their inclusion in the diagram is intended to convey a picture of the theory-formation cycle that complements MECHEM, which to date primarily addresses detailed tactical reasoning about hypotheses and evidence. Key algorithmic ideas The space of possible reaction pathways has been well understood by chemists for nearly a century. Each ele- ment of the space is a’set of reaction steps, and a step is a small set of reactants giving rise to a small set of products, syntactically separated by an arrow, i.e., re- actants ---) products. Our key discovery has not been one of perceiving this space, but of identifying an algo- rithm to generate the elements of the space in an or- der determined by an unproblematic simplicity metric. That is, we have formulated a problem space where only an unstructured space was known beforehand. The two main operators, which are implicit within the pathway generator, add an extra step to a pathway fragment, and introduce a new lexical item (a new species vari- able). The generation algorithm is more fully described in forthcoming papers. Another key algorithmic idea concerns how unseen species are introduced into pathways. An unseen species is initially designated as a variable (e.g., ‘X’) and later is instantiated by balancing the steps in which it appears. For example, on the one-step path- way fragment C3Hg + 02 --) x + C:!H& X = CH4 is deduced by balancing the step. If instead the one-step fragment were then X, Y would not be constrained to unique values. However, as further extensions to the fragment use X,Y in new steps, enough constraint can be added to result in unique values. In general, solving for the pathway variables is done by solving a matrix equa- tion Ax = b, where A is the matrix of stoichiometric coefficients of the pathway variables, x is the vector of pathway variables, and vector b sums for each step the molecular formulas that are already known. The matrix equation can be solved by adapting a standard Gaussian Elimination algorithm to work on molecular formulas (i.e., vectors) rather than scalars. MECHEM's search for pathways can well be viewed as a sequence of breadth-first searches that start each time with a different theoretical vocabulary; introduc- ing a new unseen species (incrementing the number of species S) in effect augments the vocabulary of enti- ties by a new variable. The breadth-first search cor- responds to systematically searching for all pathways, given a fixed vocabulary, up to a certain depth R of number of steps. When MECHEM fails to find a satis- fying hypothesis in complexity class S,R, it increments R and adds another level in the breadth-first search. How the breadth-first search is pruned by heuristics, and at what point S is incremented while R is reset, is described in [Valdes, 1990b] and in forthcoming pa- pers. It is worth emphasizing that the search is compre- hensive due to its breadth-first nature, that is, all pathway hypotheses of specified complexity that are consistent with the data are found. Further details on the algorithm are found in [Valdes, 1990b] and [Valdes, submitted for publication]. Heurist its Heuristics are the strategies used to guide search over a problem space. MECHEM's heuristics are not ex- Vald&-IPerBz 65 pressed declaratively within the program, but we will state them in such a form here, roughly in perceived order of importance. 1. MECHEM organizes its search in terms of sim- plicity. The space of pathways consistent with usual empirical data is infinite, so a severe selection criterion is needed. Simplicity is determined by the number of pathway steps and of species, with the latter the more important of the two. 2. Any reaction step that is not balanced is ruled out at once. This criterion follows the conservation law according to which the total number and identity of all reactant atoms remain unchanged after a chemical reaction. This conservation law is not an inviolable law of nature, since certainly mass can be converted into energy, but it does describe virtually all reactions studied by chemists. 3. MECHEM only considers reaction steps involving at most two reactants and at most two products. The representation of steps itself enforces this heuris- tic, but there is a way to rescind the restriction when needed, as in the case of the urea reaction below. The restriction is justified by chemical theory. 4. A canonical representation of pathways en- sures that identical pathways will not be generated twice in the search [Valdes, 1991a]. The importance of MECHEM’s canon for search efficiency is reminiscent of the DENDRAL case [Lindsay et al., 19801, although the two canons are very different, since the DENDRAL canon was about molecular structures, not pathways. 5. Chemical species are represented as molec- ular formulas. If instead the species were repre- sented immediately as molecular structures with all atoms and bonds explicit, then severe combinatoric problems would ensue due to the multiple ways that bonds could break and rearrange during a reaction step. This heuristic can be viewed as planning in an abstract space, since a molecular formula typically cor- responds to many structural isomers. The above heuristics are critical to the efficacy of MECHEM as a discoverer of reaction pathways. The next group of heuristics below are not critical, although each adds power in the sense of discriminating among otherwise equally plausible pathways. There are a group of heuristics that MECHEM shares with DENDRAL at a conceptual level, although their justification and detail differ from DENDRAL’s case. First is the concept of superatoms: a group of atoms deemed to be stable through the reactions can be de- fined as a superatom which is conserved intact just as single atoms are. Second is the degree of unsatura- tion of a molecular formula, which serves to rule out as implausible certain formulas proposed by the sys- tem. Third is the use of a badlist, which is a list of implausible components of pathways, e.g., a pair of species that are implausible co-reactants, or a specific step that is implausible. Badlists are currently input by the author in consultation with the reaction expert. 66 Learning: Discovery Another class of heuristics derives from experi- ment. These heuristic methods test whether a given pathway can account for experimental evidence. The methods used so far on actual reactions involve the following types of experimental evidence: precursor relations between two species, i.e., X is on the path to formation of Y. starting material A catalyzes the reaction [Valdes, 19921. concentrations of species measured over time [Valdes, 199Oa]. overall stoichiometry (net consumption/formation of observed species). An important lesson from the DENDRAL project was the efficiency gain from incorporating heuristics as early as possible in a generator of candidate solutions [Lindsay et al., 19801. 0 ur experience with MECHEM has confirmed the value of this lesson, and we have ex- erted much conceptual and programming effort in ap- plying it. For example, species unknowns are instan- tiated as soon as unique values can be inferred from their use in a pathway (this involves solving a matrix equation in the general case of several unknowns and several steps). Finally, [Valdes, 1990b] d iscusses some heuristics for experiment planning. So far MECHEM has been ap- plied only to reactions derived from the chemical liter- ature and books, so we have not had occasion to rec- ommend or carry out experiments. Hence we omit dis- cussion of this important topic, pending future demon- stration of its role in MECHEM. Validation The efficacy of MECHEM can be validated in several ways. Firstly, the output of the system can be correctly seen as a deductive statement of the form: theoretical assumptions + experimental evi- dence + set of simplest pathways. This formulation allows carrying out a systematic, comprehensive search, while providing confidence that no simpler satisfying pathways have been overlooked. Our algorithms for’generating and testing pathways, as described in the chemical literature, are guaranteed to embody correctly the relevant chemical concepts (al- though in at least one case we have argued for an al- gorithmic redefinition of a standard chemical concept [Valdes, 1991bl). MECHEM is guaranteed, short of a mistake in our programming or in our published the- ory, to find the simplest pathways consistent with the assumptions and evidence. Secondly, MECHEM’s pathway generator STOICH has also been implemented very differently in Pro- log III [Jourdan and Valdes-Perez, 19901, and compar- ative tests between the two versions have resulted in exact agreement, thus corroborating MECHEM’s relia- bility. Thirdly, MECHEM has rediscovered in a systematic manner Krebs’s pathway for the urea reaction. Cur- rently we are applying MECHEM to some novel indus- trial chemistry [Smith and Savage, 19911 in consulta- tion with Phillip Savage of the University of Michigan, with promising preliminary results. The rest of the current section describes in detail the results of the urea and industrial-chemistry reactions. Urea synthesis KEKADA, already mentioned above, implemented a historical reconstruction by Holmes of Hans Krebs’s discovery of the cyclical biochemical pathway under- lying the synthesis of urea in v&o. We have applied MECHEM to the problem of inferring pathways for the urea reaction, using a portion of the evidence discov- ered by Krebs and KEKADA. Krebs at one point had concluded that three starting materials were involved in forming three reaction products thus: ornithine, NH3, CO2 - urea, H20, arginine Also, Krebs had inferred from experiment that or- nithine catalyzed the reaction, i.e., ornithine was com- pletely re-generated after initially undergoing reaction. Lastly, Krebs knew from the chemical literature that arginine produces ornithine and urea in other con- texts (see page 149 of [Kulkarni, 19881 or page 221 of [Holmes, 19801)) and considered this fact relevant to the urea pathway under study. We will require that arginine be a precursor of urea, although not necessar- ily in a single step. We will use the above data together with a heuristic that merges two pathway steps into one three-reactant step if the following condition is met: a conjectured species appearing in the original two steps is elimi- nated from the new, merged step. This heuristic is for- malized in a small program MERGE-STEPS. The sole purpose of MERGE-STEPS is to allow three-reactant steps like Krebs did. General reasoning about pathway catalysis in MECHEM is formalized in another program YIELD; this program and its supporting theoretical re- sults have been reported [Valdes, 1991b, Valdes, 19921. Thus STOICH, YIELD, and MERGE-STEPS com- bine to discover 10 simplest pathways consistent with Krebs’s evidence. We show here only three of these, with the pathway proposed by Krebs shown first: ornithine + NH3 + CO2 + Hz0 + C’S H13N303 NH3 + Cc H13 N303 ---f arginine + Hz0 arginine + Hz0 + ornithine + urea NH3 + CO2 + Hz0 +CHNO ornithine + 2 (CHNO) + CO2 + arginine arginine + Hz0 + ornithine + urea ornithine + NH3 u Hz0 -I- Cs H13 N30 NH3 + CO2 -I- CiH13N30 - arginine + Hz0 NH3 + arginine + Cs HIS N30 + urea Each pathway involves seven species, meaning that STOICH needed to conjecture two unseen species to I I evidence #pathways class . . * starting materials & urea -0 4s2R- 0 5S2R 6 6S2R arginine is formed 0 7S2R 71 8S3R water is formed 16 8S3R ornithine effect 98 8S4R arginine precursor of urea 45 8S4R merge step (allow 10 7S3R three-reactant steps) -u Table 1: Pruning Hypotheses on Urea Pathway find a satisfying pathway; in each case one of the conjectured species was eliminated by MERGE-STEPS. The conjectured species CeH13N303 is the formula of citrulline, the intermediate proposed by Krebs (or- nithine is C~H~-JN~O~, arginine is C6H14N402, urea is CHqN20, ammonia is NH3, and carbon dioxide is COa). Table 1 summarizes the evolution of hypotheses on the urea reaction. Starting only with knowledge of starting materials and of urea, STOICH finds six 6S2R pathways. Data on the formation of arginine and then of water changes the current pathways found by STO- ICH as shown. Then the current 16 pathways, together with the fact that ornithine is a catalyst, are input to YIELD, which finds that none of the 16 explains the “ornithine effect .” STOICH then searches for incre- mentally more complex pathways, and the new batch in 8S4R is again tested by YIELD, leaving 98 pathways able to explain the ornithine effect. Of these, only 45 pathways show arginine to be a precursor of urea.’ On each remaining pathway the program MERGE-STEPS is called to merge two steps into one three-reactant step (as was allowed by Krebs) if the merge eliminates a conjectured species; this results in 10 simplest merged pathways, of which 3 were shown above. We have limited MECHEM’s input to the experimen- tal evidence discussed by Holmes; other evidence could be sought for further discrimination. For example, con- sultation of the Merck Index of chemicals reveals the formula CHNO - which is a conjectured intermediate in two of the ten pathways - to be either cyanic or iso- cyanic acid, both of which are toxic and hence rather implausible biological intermediates. Industrial chemistry [Smith and Savage, 19911 have recently studied the novel chemistry of pyrolysis of 1-dodecylpyrene (DDP).l The chemistry of DDP is relevant to the pro- cessing of heavy crude oils in the petroleum indus- try. The authors identified experimentally seven major products of DDP, and measured the product concen- trations at sampled times under various reaction con- ‘Pyrolysis refers to the splitting (-lysis) of bonds due to heat (pyro-). Valdb-Per&z 67 ditions. We have used their data from experiments at 400°C (personal communication). Twelve pathways able to account for observed prod- ucts and concentrations are found by MECHEM, of which three are shown here below. (The superatom 2 refers to a polycyclic pyrene missing a hydrogen atom at the reactive site; its formula is ClsHg. Also, for space reasons, the string ‘pyrene’ is replaced by ‘II’). Each pathway contains two conjectured species that were not input to the system, shown as formulas. DDP - Decane + VinylII DDP --+ Undecene + MethylII MethylII + Vinylll * II + ZC3 H5 Undecene + ZC3 H5 --+ EthylII + Cl2 Hz2 Decane + EthylIS - II + Dodecane DDP - Decane + VinylIll DDP - Undecene + MethylIt DDP + Undecene + EthylII + C21 HJ2 Decane + EthylIl --f II + Dodecane II + Decane - MethylII + C&H20 DDP -, Decane + Vinylll DDP -+ Undecene + MethylrZ DDP + Undecene ---t EthyllI + C2l H42 MethyllIt + VinyZlI + II + ZC3 H5 Decane + EthylII --f II + Dodecane Phillip Savage has evaluated these results in a per- sonal communication thus: “I find your identification of ZCsH5 and C’s H20 as key intermediates to be fasci- nating, because we have seen these products in modest yields.” Discussion Currently, MECHEM is unable, with practicable amounts of computation, to handle cases where the number of conjectured species is greater than four. The execution time of the system increases greatly with this number, and the current practical boundary on a 14 MIPS workstation is four. With respect to theoretical knowledge, MECHEM’s main deficiency is its very limited ability to reason about molecular structure, which provides a strong constraint on plausible reactions. This deficiency is not intrinsic: structural reasoning was not our high- est priority in bringing the system to its current state. Adding such reasoning is the next step in our agenda. Related systems Most work on machine discovery has concerned largely data-driven tasks such as law discovery, partly be- cause such tasks offer the most scope for general- ity. Some recent work on theory-driven discovery in- cludes that of [Karp, 19891, [Hayes-Roth et al., 19861, [Kocabas, 19911, and [Sleeman et al., 19901. A brief comparison with the STAHLp system [Rose and Langley, 19871 and its successor REVOLVER [Rose and Langley, 19881 is of some interest. STAHLp finds componential models of substances that are im- plied by a set of given reactions, which is a step in MECHEM’s search: given a pathway fragment with species variables, infer its component formula. STAHLp’s task also involves finding plausible revisions to the input reactions when an illegal model is inferred. MECHEM, however, simply removes that node from its search. Finally, STAHLp obtains its componential models by a search involving substitution of one vari- able for another, while MECHEM carries out a Gaus- sian elimination algorithm to infer the component for- mulas of species variables. Generality MECHEM is a general system in the sense that it is pre- pared to handle any data from chemical reactions by proposing pathways accounting for the data. All the theory and heuristics incorporated into MECHEM thus far are completely general, i.e., they are not restricted to any type of chemistry, whether organic, biological, or industrial. Although the system can be improved by incorporating more chemical theory, it constitutes currently a theory of pathway discovery of consider- able power, as was demonstrated in the above reaction examples. The abstract mechanisms of MECHEM bear a strong similarity to parallel work carried out by a group headed by Jan Zytkow. Specifically, the Gell-Mann program in particle physics [Fischer and Zytkow, 19901 and the Mendel program in classical genetics (personal communication) are similar in the sense of conjecturing unseen quark and gene entities to account for observa- tional data in a manner controlled by simplicity. This similarity lends credence to claims of MECHEM’s gen- erality at a conceptual level. We add that additional interest is generated in MECHEM’s case by its appli- cation to problems of current importance, and by the link with experimentation. [Langley et ad., 19871 state that “... generality is more likely to reside in data-driven approaches than in theory-driven ones.” A reasonable implication is not that theory-driven science should not be an object of AI study, but that the role of generality in theory- driven science is unclear. One way to elucidate its role is to examine the generality (or lack thereof) of the heuristics used in successful theory-driven approaches to real-life problems, as we have done here. Our sepa- rate contributions to chemical knowledge show that we have not simplified the scientific task for our own con- venience; rather, we have addressed the full complexity of the pathway-discovery task. We intend to investigate further the generic scientific task of pathway elucidation by trying to apply ideas from MECHEM to the elucida- tion of the endocytic pathways of cell biology [Dautry-Varsat and Lodish, 19841. 68 Learning: Discovery Conch&n This paper reports on the current status of the MECHEM project, which attempts to automate in a general manner the theory-driven discovery of reac- tion pathways in chemistry and biology. Significant progress has been made as demonstrated by applica- tion of the system to the rediscovery of a celebrated biochemical pathway and to industrial chemistry of current importance. The key algorithmic ideas un- derlying MECHEM are novel, even if appreciable intel- lectual debt is owed to the DENDRAL project. Our project has also resulted in novel contributions to chemical knowledge, and we expect MECHEM by it- self to make a publishable discovery of a pathway in the medium term. Acknowlledgments This paper is based on the author’s Ph.D. thesis in Com- puter Science at Carnegie Mellon, supervised by Herbert Si- mon (chairman), Bruce Buchanan, Tom Mitchell, and Gary Powers. This research was supported by an Air Force Lab- oratory Graduate Fellowship, administered by the South- eastern Center for Electrical Engineering Education. Sup- port for writing and publication derives from NSF grant DIR-8920118 to the Center for Light Microscope Imaging and Biotechnology. eferences Carpenter, Barry K. 1984. Determination of Organic Re- action Mechanisms, John Wiley & Sons. Dautry-Varsat, Alice and Lodish, Harvey F. 1984. How receptors bring proteins and particles to cells. Scientific American 250:52-58. Fischer, P. and Zytkow, Jan M. 1990. Discovering quarks and hidden structure. In International Symposium on Methodologies for Intelligent Systems. Hayes-Roth, B.; Buchanan, B.; Lichtarge, 0.; Hewett, M.; Altman, R.; Brinkley, J.; Cornelius, C.; Duncan, B.; and Jardetzky, 0. 1986. Protean: Deriving protein structure from constraints. In Proc. of AAAI. 904-909. Holmes, Frederic L. 1980. Hans Krebs and the discovery of the ornithine cycle. In Proc. of 63rd Annual Meeting of the Federation of American Societies for Experimental Biology, volume 39. Symposium on Aspects of the History of Biochemistry. Jourdan, Jean and Valdes-Perez, Raul E. 1990. Constraint logic programming applied to hypothetical reasoning in chemistry. In Logic Programming: Proc. of the 1990 North American Confeence, Cambridge, Mass. MIT Press. 154- 172. Karp, Peter D. 1989. Hypothesis formation as design. In Shrager, J. and Langley, P., editors 1989, Computa- tional Models of Scientific Discovery and Theory Forma- tion. Morgan Kaufmann, San Mateo, CA. 275-317. King, Edward L. 1963. How chemical reactions occur, an introduction to chemical kinetics and reaction mecha- nisms. W.A. Benjamin. Kocabas, Sakir 1991. Conflict resolution as discovery in particle physics. Machine Learning 6(3):277-309. Kulkarni, D. and Simon, H.A. 1988. The processes of sci- entific discovery: The strategy of experimentation. Cog- nitive Science 12:139-175. Kulkarni, D.S. 1988. The Processes of Scientific Research: The Strategy of Experimentation. Ph.D. Dissertation, Carnegie Mellon University. (Computer Science Depart- ment). Langley, P.; Simon, H.A.; Bradshaw, G.L.; and Zytkow, J.M. 1987. Scientific Discovery: Computational Explo- rations of the Creative Processes. MIT Press, Cambridge, Mass. Lindsay, R.K.; Buchanan, B.G.; Feigenbaum, E.A.; and Lederberg, J. 1980. Applications of Artificial Intelligence for Organic Chemistry: The Dendral Project. McGraw HiI& New York. Rose, D. and Langley, P. 1987. Chemical discovery as belief revision. Machine Learning 1:423-451. Rose, Donald and Langley, Pat 1988. A hill-climbing ap- proach to machine discovery. Proceedings of the Machine Learning Confemnce 367-373. Simon, H.A. 1966. Scientific discovery and the psychology of problem solving. In Colodny, R., editor 1966, Mind and Cosmos. University of Pittsburgh Press. 22-40. Sleeman, D.H.; Stacey, M.K.; Edwards, P.; and Gray, N.A.B. 1990. An architecture for theory-driven scientific discovery. In Proceedings of the Fourth European Work- ing Session on Learning, San Mateo, Calif. Morgan Kauf- mann. 1 l-23. Smith, C. Michael and Savage, Phillip E. 1991. Reac- tions of polycyclic alkylaromatics. 1. Pathways, kinetics, and mechanisms for I-dodecylpyrene pyrolysis. Ind. Eng. Chem. Res. 30:331-339. Soo, V.; Kulikowski, C.A.; Garfinkel, D.; and Garfinkel, L. 1987. Theory formation in postulating kinetic mech- anisms: Reasoning with constraints. Technical Report CBM-TR-150, Department of Computer Science, Rutgers. Valdes-Perez, Raul E. An algorithm to generate reaction pathways for computer-assisted elucidation. Submitted to Journal of Computational Chemistry. Valdes-Perez, Raul E. 1990a. Coarse judgment of reaction model plausibility using linear estimation of reaction ex- tent. Presented at Annual Meeting of American Institute of Chemical Engineers. Chicago, 11-16 November. Valdes-Perez, Raul E. 1990b. Machine Discovery of Chemical Reaction Pathways. Ph.D. Dissertation, Carnegie Mellon University. (School of Computer Science, CMU-CS-90-191). Valdes-Perez, Raul E. 199Oc. Symbolic computing on reaction pathways. Tetrahedron Computer Methodology 3(5):277-285. Valdes-Perez, Raul E. 1991a. A canonical representation of multistep reactions. Journal of Chemical Information and Computer Sciences 31(4):554-556. Valdes-Perez, Raul E. 1991b. On the concept of stoichiom- etry of reaction mechanisms. Journal of Physical Chem- istry 95(12):4918-4921. Valdes-Perez, Raul E. 1992. A necessary condition for catalysis in reaction pathways. Journal of Physical Chem- istry. In press. Vald&-Per6z 69 | 1992 | 25 |
1,216 | iscovery of E tion of Convergence * Robert Zembowicz Jan M. iytkow Department of Computer Science, Wichita State University, Wichita, KS 67208 robert@wise.cs.twsu.edu zytkow@wise.cs.twsu.edu Abstract Systems that discover empirical equations from data require large scale testing to become a reliable research tool. In the central part of this paper we discuss two convergence tests for large scale evaluation of equation finders and we demonstrate that our system, which we introduce earlier, has the desired convergence proper- ties. Our system can detect a broad range of equations useful in different sciences, and can be easily expanded by addition of new variable transformations. Previous systems, such as BACON or ABACUS, disregarded or oversimplified the problems of error analysis and error propagation, leading to paradoxical results and imped- ing the true world applications. Our system treats ex- perimental error in a systematic and statistically sound manner. It propagates error to the transformed vari- ables and assigns error to parameters in equations. It uses errors in weighted least squares fitting, in the eval- uation of equations, including their acceptance, rejec- tion and ranking, and uses parameter error to elimi- nate spurious parameters. The system detects equiv- alent terms (variables) and equations, and it removes the repetitions. This is important for convergence tests and system efficiency. Thanks to the modular struc- ture, our system can be easily expanded, modified, and used to simulate other equation finders. Introduction All discovery systems that discover numerical reg- ularities (BACON: Langley, Simon, Bradshaw, & Zytkow 1987; ABACUS: Falkenhainer & Michalski 1986; FAHRENHEIT: iytkow, 1987, iytkow, Zhu, & Hussam 1990; IDS: Nordhausen & Langley 1990; KE- PLER: Wu & Wang 1989; E*: Schaffer 1990) use mod- ules that find mathematical equations in two variables from a sequence of data. In this paper we describe an empirical Equation Finder (called EF) implemented with a particular concern towards a broad scope of equations it can detect, modularity of design, flexibility of control, and sound treatment of error. All these fea- *Work supported by the Office of Naval research under the grants No. N00014-88-K-0226 and N00014-90-J-1603. tures are important for a high quality equation finder useful in modern science. Because empirical equations are discovered for many purposes, and are used to ac- quire more knowledge, a faulty mechanism for equation discovery may have a major detrimental effect on other discoveries. Scientists recognize that a measurement error is as- sociated with each experimental data point, and that all knowledge derived from experimental data carries corresponding errors. EF implements these tenets and systematically applies the theory of error propagation. EF computes the error for each transformed variable and for each parameter in each equation. The parame- ter error is needed to generalize the equations to more than two variables, and FAHRENHEIT uses these val- ues in the generalization process (Zytkow, Zhu & Hus- sam 1990). BACON, ABACUS, and IDS use a con- stant system error but that causes undesired and para- doxical results and impedes their use in practical ap- plications. E* ignores the error altogether. Error plays several other roles in EF. It is used in the weighted least square fit for each type of equa- tion and in statistical tests that evaluate and rank the equations. Parameter error is used in EF to eliminate spurious terms in the equations. In the central part of this paper we analyze the con- vergence properties of EF. When a known equation is used to generate data, the evaluation of EF’s results is unproblematic, because the source equation should be among the results. We describe two convergence tests, based on this idea, which must be satisfied by a scientific quality equation finder. We demonstrate the performance of our system on those tests. Previous equation finders do not perform as well because they fail the errors. EF: model fitting and evaluation Input to EF consists of /v numeric data points (x&y&a& i = l)...) Iv, where xi are values of the independent variable x, yi are values of the dependent variable y, oi represents the uncertainty of yi (scien- tists call it error, for statisticians it is devi&ion, while the term noise is often used in AI). Output is a list of 70 Learning: Discovery From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. X Figure 1. Sample data and 3 equations with similar goodness of fit accept able models. Model Fitting. Model Fitter, a component of EF, uses chi-square fitting, known also as weighted least-squares (Eadie et al. 1971, Press et al. 1989) to fit given numeric data points (xi, yi, oi) to a fi- nite number of models. Model is a function template Y=f(wl,.-, dg) (for example, y = al + uzx + usx2) whose parameters’ values al, . . . , aa are determined by the requirement that the value of x2, N x2 = c( Yi-.ff(Xi~~l~-~-~~q) 2 (1) i= 1 (Ji > is minimal. The value of x2 is the sum of squares of deviations of data points (xi, yi) from the model, weighted by errors Ui, so that measurements which are more precise carry greater weight. At theminimum of x2, its derivatives with respect to the aj all vanish, N c Yi -f(Zi,Ul,...,Uq).af(Xi,dl,...rUj,...,U~) = o 2 dUj t i=l ui (2) for j = l,..., q. In general, the set (2) of equations is non-linear and not easy to solve. For a polynomial model, however, the set (2) can be solved by algebraic or matrix operations, producing efficiently a unique solution. Our Model Fitter can consider polynomials of any degree. In addition to the original variables x and y Model Fitter can work on data expressed in any transformed variables: x’ = x’(x) and y’ = y/(x:, y). Parameter Error. Standard deviations of parame- ters al, . . . . a4 at the values that minimize x2 are cal- culated according to the formula for error propagation (Eadie et al. 1971): Uij = N dUj 2 c( > -&- *a:, j= l,...,q (3) a’=1 (parameter values Uj, j = 1, . . . , q are solutions of equa- tions (2), therefore they are functions of xi, yili, ai). Removing vanishing parameters. If the absolute value of a fitted parameters aj is smaller than the cor- responding error Us,, then zero could be also a good value for aj. EF sets this parameter to zero. The new simplified equation has a similar goodness of fit (Zem- bowicz & Zytkow 1991). Figure 1 demonstrates the need for the removal of vanishing parameters. For the plotted data, EF finds 3 models: y = al +u2x+u3x2, y = bl +b2x+b3x2+b4x3, and y = cl + c2x + +x2 + cd/x; 64 and c4 are “zero- valued” : lb41 << ob4, 1~41 << uC4. Note that (i) there is no visible difference between the first two models; (ii) the data does not prefer any of the models, all have almost the same goodness of fit defined by (l), but y = al + ~22 + usx2 is the simplest. Higher degree polynomials will always be created, it is important to eliminate those which are unnecessary. Fit Evaluation. For the best fit to each model, EF calculates the value of x2 according to Equation (l), and assigns the probability Q = &(x2, N - q) (N - q is the number of degrees of freedom in the data left after the fit) that this x2 value has not been reached by chance. A small value of Q means that the dis- crepancy between the data (xi, yi, ui) and the model Y = f(XA,..., Us) is unlikely to be a chance fluctua- tion. The threshold of acceptance is defined using the probability Q: all models for which Q is smaller than some minimum value Qmira, are rejected. The best models are those with the largest values of Q. EF: the search space The class of polynomial models is too narrow for many applications. To extend the scope of detectable func- tions, EF uses data transformations, combined with application of polynomial model fitters to the trans- formed data (Figure 2). For each pair of variables x’, Zembowicz and Zytkow 71 /- transform model fitters remove repetitions constant linear (e.g. y = a + bx) e e generate equation search- e qth degree polynomial 4-- remove repetitions Y 1% Y l/Y eee linear (e.g I 1 ). 7 = a + b logx ) quadratic e l e l e generate variable search J qth degree polynomial / eee Figure 2. The search space: generation of vari- ables, generation of equations, and model fitting. y’, and the error u’ of y’, Equation Generation Search tries to find acceptable models. Generation of new variables. The variable Gener- ation Search (left hand side of Figure 2) creates new variables by applying a number of transformation rules, initially to the original variables x and y, x ----f 2’ = t1(x), (4) (X,Y,U) + (Y’J) = (Y’(X,Y)? l$g -0) ) (5) and then to the transformed‘variables. Note, that each time when EF uses y in a transformation, it also trans- forms the associated u according to (5). Each new term is simplified and then compared against all the previ- ous terms to ensure its uniqueness. The default set of transformations used by EF in- cludes logarithm, exponent, inverse, square root, mul- tiplication, and division. Adding new transformation rules is simple. Only the transformation formula must be provided; the formula for error transformation is au- tomatically developed by the module that calculates analytical derivatives. For example, the inverse and multiplication transformations are defined by name: INVERSE PRODUCT parameters: (24 (P d formula: (/ 1 PI (* P 4) application condition: P#O - Equation Generation Search. For each possible combination of variables x’ and y’, and for each polyno- mial up to the maximum user-specified degree, the op- erator Generate New Equations proposes a polynomial equation y’ = f(x’, al, . . . , ue), which is then solved for y, if possible. If this seems a new equation, the Model Fitter finds the best values for the parameters al, . . . , u4, and then evaluates the model, as described in the previous section. The search driver coordinates the search in the spaces of variables and equations (Figure 2). The sys- tem applies the Generate New Variable operator to extend the space of variables, and the Generate New Equation operator to generate, fit, and evaluate equa- tions. The search starts from the two original variables: x and y (upper left part of Figure 2). The application of the Generate New Equation operator leads to a con- stant model y = a, linear model y = a + bx, and other polynomials up to the predefined maximum polyno- mial degree (upper right part of Figure 2). If none of the models passes the evaluation, the Generate New Variables operator is applied repeatedly (see lower left part of Figure 2). If we consider only three transfor- mations: logarithm, inverse, and multiplication, then the new variables would be: 1 bw -9 xy, logy, s 2 Now, using the original and new variables, the Gen- erate New Equation search applies to each combina- tion of x-type and y-type variables would form a large number of models (lower right part of Figure 2). For example, if maximum polynomial degree is 1, then the 72 Learning: Discovery select transformations transform terms simplify term term contains y? new term? term defined for all data? select polynomial transform equation & = dY’ 37 simplify simplify equation solve for y new equation? 6 = & + bx2 + cx4)/3p) Figure 3. Generation of new variables and equations: the backtrace of all actions responsible for the generation of equation y = e (a+bx2+cx4)/x following new equations would be generated: Y =a+b/x y=aebZ y=a+blogx y=--l- a+bx Y = uxb 1 y= - y=- a+bx Y = ueb/x y = :iiF:: Y =;++ If still none of the models is acceptable, the Generate New Variable search applies again. This operator, for the same three transformations, would generate the following new variables: 1 log(log 4, - log x logx’ 2 logx, - 2 ’ ~Ylogz,Yl~gx,~, 1% Y 1wd10~Y)&Y~opy. ylxYlogY,xl%Y, ;, log x logy X2Y, XY2, 10&Y), $9 loga: * logy, ----j-Y - X Note that the number of variables grows rapidly. Figure 3 demonstrates the creation of new variables and equations from another perspective. It depicts the backtrace of actions needed to generate the equation e(a+bx2+cx4)/x. th’ is equation can be generated at Keith two in the Generate New Variables search (the original variables x and y are at depth zero). The search terminates when an acceptable model is found or at the predefined maximum search depth. User control over search The user can change the maximum depth of both searches, that is, the maxi- mum polynomial degree and the maximum transfor- mation search depth. The user can also specify which transformation rules are to be considered. Another parameter controls the minimum search depth. It can force EF to continue the search even if an acceptable model was found. This option is particularly useful when the user is not satisfied with any of the mod- els already found and wants EF to deepen the search. The minimum search depth is also needed for the two convergence tests described in the next section. This simple search driver is very useful for testing and for studying the properties of EF, but it can be easily rearranged in various ways. EF: experimental evaluation of convergence Various tests can be applied to equation finders. One important application of EF is in a scientific labora- tory, as a part of a machine discovery system (Zytkow, Zhu, & Hussam 1990). That application, however, does not allow us for an easy systematic testing of EF on a broad range of equations. In addition, it does not provide us with an undisputed “right answer”, against Zembowicz and Zytkow 73 which we can compare the outcome of EF. Even if we collect data about a phenomenon which is described by a particular equation E, it is always possible that an interference of another unexpected phenomenon will result in data that does not satisfy E. Schaffer (1990) employed another schema of testing. He uses the ac- tual equations proposed by scientists as the standard of validity. Although the result proposed by the sci- entist should be among those proposed by EF within the measurement error, this approach is not appropri- ate for testing EF alone, because scientific standards of acceptance combine several criteria, some of which use background knowledge not available to EF, such as interpretation of parameters, and derivability from other equations. In this paper we propose two convergence tests that apply to any empirical equation finding (A-EF) system to verify its performance on all equations it can consid- ered. Both tests use data generated from known equa- tions. For each equation y = j(z), we use f to gener- ate data, adding Gaussian error of controlled size to all data points. The source equation y = f(x) should be among the acceptable solutions found by A-EF. How- ever, one cannot require that the source equation is the unique solution, even if the system removes zero-valued parameters described previously. First, the larger are experimental errors, the more models fit the data with similar goodness of fit. Sec- ond, the number of acceptable models increases also when the range of values of the independent variable ;[: represented in data is narrowed down and does not characterize the overall behavior of f(x). For most real-world data our EF reports more than one accept- able model. Both these multiple solution problems can be solved or alleviated if the user can make additional experi- ments in the expanded range of x and/or improve the accuracy of experiments. If the source function f(x) is in the scope of A-EF’s search, then a gradual reduc- tion of error should eventually leave the source func- tion as the only acceptable model. When the scope of the data is expanded, the situation is not so simple, although many initially accepted models can be ruled out. Consider, for example, the function y = usin( If the experimental errors u are larger than Ial, then Y = 0 is an acceptable model, no matter how far the range of x is extended. Only if the error is reduced, this procedure may lead to a unique solution. The following two tests can verify the convergence of any equation finding system (A-EF) to the source equation. In both tests, we automated the gradual expansion of the scope and reduction of error. Test #l. Given an empirical equation finding system, 1. Take a function y = f(z) recognizable by A-EF. 2. Choose an error level E and a range R, of 2. 3. Generate random data points xi, i = 1, . . . , N, xi E R,, generate yi according to f, and add random 74 Learning: Discovery Gaussian errors to yi according to E. Run the curve fitter to the depth sufficient to dis- cover f. If f is not among acceptable models, then report the failure of A-EF. If there is only one acceptable model, then go to step 1 and take another function, else extend the range R, and go to step 3. A-EF passes test #l for a class F of functions within its closure, if for each function f in F the test #1 con- verges to f, except when the difference between the maximum and minimum values of f is significantly smaller than the error E. Test #2. This test differs from test #l only in step 6. Instead of increasing the range, the error is decreased: 6’. If there is only one acceptable model, then go to step 1 and take another function, else reduce the error level E and go to step 3. A-EF is passes the second test on a class of functions F, if the loop converges to f for each function f in F. We have implemented a convergence tester which uses both tests. It generates data points and calls an equation finding system to be evaluated. We have run both tests on our EF for all types of functions y = f(x, ~1,. . . , up) that can be discovered at the first level of transformations for the maximum polynomial degree of 3. We have used the logarithm, exponent, inverse, square, square root, division, and multiplication as transformations. Under these condi- tions, our EF tries 193 possible models. For each function f, we have run both tests several times, varying the number of generated data points from 20 to 100. All parameter values ui for f were generated randomly for each test run. The tables show ranges of the independent variable x. The error level of 10% means that for each data point the error was drawn from the normal (Gaussian) distribution of the deviation set to 10% of the value of the dependent variable y. The tables show counts of acceptable mod- els (Q 2 0.001) with the zeroing parameters removed (with the exception of Table 1). Tables l-4 present selected results. Table 1 presents combined results of both tests for the function y = a + b&i + cx when vanishing parameters luil < g,, were not removed. The number of acceptable models does not converge to 1. However, if the vanishing pa- rameters are removed, the resulting equations are sim- plified and removed if they were already discovered, then the number of acceptable models goes down to one, (Table 2). This d emonstrates the importance of parameter zeroing. Table 3 shows the result of the first test (for the fixed relative error E = O.l), while table 4 shows the result of the second test (for fixed range R = [l, lo]) respec- tively, for several functions. The number of expected Table 1: The number of acceptable models for y = 1 Error 1 Range of independent variable level [1,5] [1:7.5] [l,iO] [1,12.5] [1,15] 10% 110 77 54 . 38 30 13 9 4 3 2 2 Table 2: The number of acceptable models for y = + b& + cx; zero-valued parameters removed 1 Error I Range of independent variable I level [1,5] [177.5] [l,iO] [1,12.5] [1,15] 10% 76 62 41 29 21 37 23 15 12 8 4 3 2 1 1 1 Table 3: Test #l: number of acceptable models for several equations; relative error is fixed at 10% 1 Range of independent variable Source model [1,5]- [1,7.5] - [l,lO] [1,15] Y =u+b,/Z+cx 9 3 2 1 y = (a + bx + CX~)~ 8 3 2 1 Y = a + be” + ce2x 5 2 2 1 y = log(u + bx + cx2) 10 3 1 1 y = (a + bx2 + CX~)~ 11 2 2 1 y = da + be” + ce2x 9 4 3 1 y = log(u + b& + cx) 7 4 1 1 Table 4: Test#2: number of acceptable models for several eauations: the range is fixed at x in 11. 101 Source model Y =u-+b,/x+cx y = (a + bx + ~2~)~ Y = a + be” + ce2$ y = log(u + bx + cx2) y = (a + bx2 + ~2~)~ y du + be” + ce2x y 1 log(a + b& + cx) Error level 10% 1% 0.1% 0.01% 38 15 2 1 46 12 2 1 28 7 2 1 59 14 1 1 39 10 2 1 39 14 3 1 40 10 1 1 models converges to 1 when the range of x increases or the error level decreases, as expected. Conclusions In contradistinction to its predecessors, EF treats ex- perimental error and evaluation of equations in a sys- tematic and statistically sound manner. We have intro- duced two convergence tests that should be satisfied by any equation finding system. We have run those sim- ulation tests on our EF and we have found that our system has the desired convergence properties. The convergence tests require the elimination of equivalent variables and equations, which is important also for the efficiency of search. Thanks to the modular structure of EF, it can simu- late various equation finding systems, such as different versions of BACONl, or the equation finders of ABA- CUS and IDS. For instance, BACON1 (Langley et al. 1987) can be simulated by selecting transformations xy and x/y (conditional upon monotonicity of data), by applying constant and linear models, and by setting Uy’ - - fly for each transformed variable y’. Our EF has been successfully applied to scientific laboratory data and was incorporated into a larger machine discovery system FAHRENHEIT used in real world applications (iytkow, Zhu, and Hussam 1990) and into Forty-Niner (iytkow and Baker 1991), which mines databases in search for useful regularities. Be- cause equations are seldom a useful description of data in databases, the EF search in databases is triggered by a simple functionality test which uses a general def- inition of a function. References Eadie, W.T., Drijard, D., James, F.E., ROOS, M., Sadoulet, B. 1971. Statistical Methods in Experimental Physics, North-Holland Publ. Falkenhainer, B.C., & Michalski, R.S. 1986. Inte- grating Quantitative and Qualitative Discovery: The ABACUS System, Machine Learning, 1: 367-401. Langley, P., Simon, H.A., Bradshaw, G., & iytkow J.M. 1987. Scientific Discovery; Computational Ex- ploration of the Creative Processes, Boston, MA: MIT Press. Nordhausen, B., & Langley, P. 1990. An Integrated Approach to Empirical Discovery. in: J.Shrager & P. Langley eds. Computational Models of Scientific Dis- covery and Theory Formation, 97-128, San Mateo, CA: Morgan Kaufmann Publ.. Press, W.H., Flannery, B.P., Teukolsky, S.A., Vetter- ling, W.T. 1989. Numerical Recipes in Pascal, Cam- bridge: Cambridge University Press. Schaffer, C. 1990. A Proven Domain-Independent Scientific Function-Finding Algorithm, Proceedings of AAAI-90, 828-833, Menlo Park, CA: AAAI Press. Wu, Y., & Wang, S. 1989. Discovering Knowledge from Observational Data, in: Piatetsky-Shapiro, 6. (ed), Knowledge Discovery in Databases, IJCAI-89 Work- shop Proceedings, Detroit, MI, 369-377 Zembowicz, R., and iytkow, J.M. 1991. Automated Discovery of Empirical Equations from Data, Proceed- ings of ISMIS-91, 429-440, Springer-Verlag. iytkow, 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 Kaufmann Publ.. iytkow, J.M., Zhu, J. & Hussam, A. 1990. Automated Discovery in a Chemistry Laboratory, Proceedings of the AAAI-90, 889-894, Menlo Park, CA: AAAI Press. Zembowicz and Zytkow 75 | 1992 | 26 |
1,217 | Operational definition refinement: a Jan M. iytkow Jieming Zhu obert Zembowicz Department of Computer Science Wichita State University, Wichita, KS 67208 Abstract Operational definitions link scientific attributes to ex- perimental situations, prescribing for the experimenter the actions and measurements needed to measure or control attribute values. While very important in real science, operational procedures have been neglected in machine discovery. We argue that in the preparatory stage of the empirical discovery process each opera- tional definition must be adjusted to the experimental task at hand. This is done in the interest of error re- duction and repeatability of measurements. Both small error and high repeatability are instrumental in theory formation. We demonstrate that operational proce- dure refinement is a discovery process that resembles the discovery of scientific laws. We demonstrate how the discovery task can be reduced to an application of the FAHRENHEIT discovery system. A new type of independent variables, the experiment refinement vari- ables, have been introduced to make the application of FAHRENHEIT theoretically valid. This new extension to FAHRENHEIT uses simple operational procedures, as well as the system’s experimentation and theory for- mation capabilities to collect real data in a science lab- oratory and to build theories of error and repeatability that are used to refine the operational procedures. We present the application of FAHRENHEIT in the con- text of dispensing liquids in a chemistry laboratory. Real world discovery Many tasks must be solved before we create an au- tonomous robot that can compete with an experimen- tal scientist in real world discoveries. In this paper we concentrate on generation of high quality data; that is, on the details of procedures which lead to scientific measurements. Experimentation strategies developed by research on machine discovery (Falkenhainer & Ra- jamoney 1987, Zytkow & Langley 1990, Kulkarni & Simon 1988, Sleeman et al. 1989) do not concentrate on measurement and manipulation details, assuming *The work described in this paper was supported by Office of Naval Research under the grants No. NOOOl4-8% K-0226 and N00014-90-J-1603. 76 Learning: Discovery that high quality data are obtained from a user or a simulation. In true science, however, the requests for data are based on empirical knowledge. For instance, measurements must be made at concrete times. If a measurement is made too early, before a reaction is completed or before a measuring device stabilizes, the results will be systematically wrong or the error may be large. If the measurements are made too late, the interference of a disturbing phenomenon may cause an- other systematic error. The exact timing of “too early and too late” may vary. A reaction may be completed at different times for varying amounts of chemicals. Similarly, the time after which a measuring device will stabilize may depend on the mass added and other cir- cumstances. The knowledge of repeatability condition may take on the form of a complex theory. Another problem is the knowledge of experimental error. Without this, it is difficult to evaluate theo- retical findings such as empirical equations. Although many systems (BACON (Langley et al. 1987), ABA- CUS (Falkenhainer & Michalski 1986), and IDS (Nord- hausen & Langley 1990)) include some error-related parameters, they disregard the true scientist’s prob- lems of error analysis (Zytkow, Zhu, & Hussam 1990, Zembowicz & Zytkow 1991). The error should be known for each data point used in theory generation. This may require a very large number of experiments. A better solution would be to develop a theory of error for a given measurement method. When an error is large and data is not repeatable, the theoretical component of an autonomous discoverer would experience various difficulties and misfortunes trying to build theories from such data. Error and re- peatability conditions are interrelated. Small error can be achieved under restrictive repeatability conditions. We demonstrate how the theory of error can be de- termined and the repeatability conditions derived by the use of the discovery system FAHRENHEIT. None of these skills were available in previous machine dis- covery systems. We show how FAHRENHEIT can be adapted to carry out this task. We will now discuss operational procedures and their refinement topics not addressed in previous pub- From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. lications in machine discovery. Two earlier papers (Zytkow, Zhu, & Hussam 1990, 1990a) reported the applications of FAHRENHEIT to discovery of a the- ory helpful in developing analytical instrumentation in chemistry, but the operational procedures were hard- coded into the experiment control module, and all their elements have been pre-programmed. Interaction with the real world: operational procedures Each independent and dependent variable must be linked to manipulations (actions) and measurements available to the experimenter. They are used to set the values of independent variables and to measure values of dependent variables obtained in response. Scien- tifically meaningful manipulations and measurements can be reconstructed in the form of operational defini- tions (Bridgman 1927, Carnap 1936). Although each scientific concept is typically defined by a coherent set of operational definitions (Zytkow 1984), in this pa- per we will limit our attention to a single definition of one concept. Each operational definition can be viewed as a program, the elementary instructions for which are primitive actions, instrument readings, and calculations. For instance, a procedure that defines mass difference caused by a particular action can be expressed as: Mass-change(by action a) = Mb =: measure mass before action a Ma =: measure mass after action a Ma - Mb This procedure, although defining a theoretically sound concept, requires adjustments to a particular ap- plication: the constraints on the time before and the time after, as well as the error of the procedure for a particular experimental situation, to which it is going to be applied. We claim that each operational definition must be adjusted to the specific details of a given experiment, in preparation for the empirical discovery. The adjust- ment is based on a discovery process, that resembles the discovery of scientific laws. It involves the analy- sis of error and the determination of conditions under which experiments are repeatable. Measurement refinement: a case study Mass transfer experiment As an example, let us consider an experiment illus- trated by Figure I, in which an electronic buret dis- penses water in the amount controlled by FAHREN- HEIT. Water is transferred to a beaker, which has been placed on a balance. Volume dispensed by the buret is the independent variable, while mass at the balance is dependent. Our task is to determine error and re- peatability conditions for the Mass-change procedure provided in previous section. The experiments, even Figure 1. The liquid transfer experiment setup. delivers lOm1 water to the beaker at a time. The buret if identical from the perspective of independent vari- ables used in theory construction, may yield different results. To analyze the differences, in all repeatabil- ity experiments, two additional independent variables can be used: time of measurement, and the ordering number of the experiment. In our example this is the number of the repeated transfer of the same amount of water and the time at which the balance measures the mass. We will concentrate on the error and repeata- bility of mass measurements for a single value of the volume dispensed by the buret. At each time, the beaker is represented by the state, including: substance: mass: values: empty, water, the reading of mass and the like The initial state of the beaker can be also controlled, by draining the beaker or by filling it with a particular amount of liquid. Data collection and analysis FAHRENHEIT began the repeatability and error ex- periment by setting three independent variables at a constant value: substance in the beaker to empty, dis- pensing volume to lOmL, number of dispensing to zero, while varying time from 0 to 120, by sampling the bal- ance at the rate of about 1.25 readings per second. The first sequence of measurements thus consisted of weighing the empty beaker approximately 120 times. As shown in Table 1, this sequence of balance read- ings has been recognized by FAHRENHEIT as a con- stant, and the standard deviation has been found. The error was not available for the first sequence of data. This is a special application of FAHRENHEIT’s Equa- tion Finder (Zembowicz & Zytkow 1991). While the error is assumed to be constant, the value of error is determined as the standard deviation of the best fit within a small set of simple equations. If the set of data is large, while the equations are simple, there is no risk to introduce overfit, which would result in an underestimated error. The initial value of error can be Zytkow, Zhu, and Zembowicz 77 time (second) 0 1 2 . . . . . . 98 99 100 balance reading bv-4 223.827 223.827 223.827 . . . ..e 223.829 223.829 223.829 discovered regularity: constant, m = 223.827, error: 0.002 Table 1. Partial list of the first 120 balance readings (made in 100 seconds), the discovered regularity and error. number of mass transfers 1 2 3 4 5 6 7 8 9 10 r measuremenl fi start time 0 0 0 0 0 0 0 0 0 0 end time 124 124 126 123 124 126 123 123 126 125 - period (in seconds) partition point 10 9 9 9 9 10 9 9 10 11 1 regu!arrty founcL for partition points: t = 9.5, v regularity found for slopes: t = -0.000222, with error = 9.6 x low6 discovered regularity for stable readings m: mass in grams, t: time in seconds in parentheses, the error of the slope m= -0.000213t + 233.685 (5.6 x lo-“) m= -0.000203t -I- 243.517 (5.5 x 10-6) m= -0.000242t + 253.454 (5.5 x 10-6) m = -0.000229t + 263.398 (5.6 x 10B6) m= -0.000240t + 273.339 (5.6 x 10-6) m = -0.000210t + 283.286 (5.5 x 10e6) m= -0.000229t + 293.235 (5.6 x 10-6) m= -0.000212t + 303.182 (5.6 x 10-6) m= -0.000202t + 313.131 (5.5 x 10-6) m= -0.0002365 + 323.082 (5.6 x 10-6) th error = 0.6 Table 2. For each dispensing process, the start point of stable readings is detected (partition point) and the regularity for those readings is found (the error of the slope for each linear regularity in parentheses). changed at a later time, if in similar but better con- trolled circumstances, a smaller value of error is de- tected. In our experiments, the value of error has been determined as 0.002, which is almost the minimum dis- cernible value for our balance and never changed. This value has been used repeatedly as the error, when an- alyzing the future readings. Repeatability conditions are always satisfied by a constant, so FAHRENHEIT finds this experiment completely repeatable, without limiting conditions. The second variable varied by FAHRENHEIT is the ordering number of dispensing. 1OmL of water is dis- pensed each time from the buret to the beaker, roughly every 120 seconds. This dispensing process has been repeated 10 times, while balance readings were sam- pled continuously at the rate of about 1.25 readings per second, leading to that approximate 10 x 120 read- ings have been collected (Table 2 and Figure 2). Each sequence of data, one at a time, is analyzed by the Equation Finder. Because the error is small, no sequence of data, as depicted in Figure 2, fits a single equation. The data partitioning mechanism is there- fore invoked, finding a unique special point in each sequence (see Table 2). The initial steep raising line corresponds to the mass change during the dispensing. Each dispensing lasted about 10 seconds. The second sequence of data corresponds to a far more stable sit- uation following each dispensing. No equation within error is detected for the first partition, while a linear equation is found for each second partition of data (Ta- ble 2), with a small error in the slope. Negative slopes 78 Learning: Discovery indicate the decreasing mass of the beaker, which, as we know, is due to liquid evaporation. Because re- peatability is satisfied only by a constant, now the data are searched incrementally from the partition point, us- ing the initially determined error, to detect the scope of constancy. Because the slope is very small, given the error of mass as O.O02g, for about 20-30 seconds following each liquid transfer, the mass readings fit a constant. The lower bound of the constant is the par- tition point, while the upper bound is approximately 20-30 seconds later. A similar constancy is found for the data immedi- ately preceding the dispensing. Now the operational definition can use these constraints, so that the differ- ence between the mass at the point of the first stabi- lized reading after dispensing and the mass of the last stabilized reading before dispensing is computed (Ta- ble 3). When FAHRENHEIT generalized the location of each partition point, the constant has been detected at 9.5 seconds with an error of 0.6 second. Both the experiments and the theoretical derivations have been fully automated. Theory of repeatability and error Now that we have described details of our experiment, let us summarize the theory of repeatability and error, and the mechanism by which the initial operational definition controls the experiments. dispensing # 1 2 3 4 5 6 7 8 9 10 vol. dispensed 9.857 9.854 9.961 9.969 9.964 9.973 9.975 9.973 9.973 9.971 discovered regularity: constant, m = 9.947, error = 0.03 Table 3. List of ten actual dispensed volumes, their regularity and standard deviation. 323.046 L--**m** ~o~b);ll f (s) (4 . . . . . . . . . . . . . e l ...**... Q d Figure 2. (a): mass of the empty beaker is constant, error is very small; (b) and (c): as water is added, mass increases. The readings stabilize after about 10 seconds; error becomes small. However, a slow long term phenomenon of evaporation (d) can be noticed by comparing the difference in mass: 323.0809 at 1240s; 323.0469 at 14009. Refinements of an operational definition Each operational definition requires specific actions and measurements. The task is to detect limitations on the time and circumstances in which these actions and measurements are performed. Another task is to determine the error of the procedure. In our example, several constraints on time have been found, and differ- ent theories have been found for an empty beaker and a beaker which contains water. Other circumstances, such as the initial mass of the beaker before each dis- pensing, could be examined also, perhaps leading to more complex theories. In our example, two specific measurements required by the definition are: (1) the mass before dispensing, and (2) the mass after dis- pensing. The repeatability and error for both guide the refinement process. The experiment refinement variables In law discovery, following BACON, FAHRENHEIT distinguished between independent and dependent variables, trying to find a theory that would include all independent variables. In real world applications, the potential independent variables are those associated with manipulation procedures, while potential depen- dent variables are those associated with measurement procedures. In repeatability and error analysis, all independent variables can be used to explore the space of circum- stances that decrease error and improve repeatability. Variables, which are not involved in the future theory formation task, can still be very important in control- ling error and repeatability. For each discovery task, therefore, all variables are divided into two categories (Figure 3). The first category includes variables for which FAHRENHEIT is supposed to build a theory and are called theory formation variables. In our ex- (a). Theory forma- tion variables; tradi- tional application of BACON and FAHRENHEIT (b). Experiment refine- ment variables; they are used to determine the repeatability condi- tions and error. Figure 3. Two types of independent variables. The space of independent variables decomposes into two subtypes: (a). for theory formation; (b). for experiment refinement. The- ory of error, which uses experiment refinement variables, must be found before FAHRENHEIT can work on the main theory for the theory formation variables. periment, this first category includes the volumes dis- pensed by the buret. The second category includes control variables that are of no direct interest to the current theory formation task. We call them exper- iment refinement variables. Some of these variables may be irrelevant to the measurements, but some of them may influence their results. If that happens for a variable V, FAHRENHEIT finds a constraint on V that limits its influence on the experiment. In our ex- periment, the second category includes two variables which are always available to the experimenter: the number of times the liquid is added, and the time at which the reading is conducted. If no other variables can be controlled, the last two types of variables can still be varied. The use of special points FAHRENHEIT includes mechanisms to detect “spe- cial points” such as maxima, minima, big changes in slope, and so forth (iytkow, Zhu & Hussam 1990). Zytkow, Zhu, and Zembowicz 79 Special points can be used for data partitioning. When a regularity cannot be detected for all data, FAHREN- HEIT finds special points and partitions data accord- ingly. Then FAHRENHEIT can find regularities on boundaries of regularities, and regularities on all types of special points. Both features have been used during repeatability analysis in our example. Special points have been used as a tool for data partitioning, so that the regularity search may succeed in partitions. For instance, a regularity on a boundary of the constant regularity is used to define a repeatability condition. The use of error For each new variable V generated by FAHRENHEIT, such as the slope of a particular regularity, or in the boundary of a regularity, the system finds the error of each value of V. Detected errors provide important in- formation about data, and are used to find regularities and special points. For instance, the error reported in Table 1 is used to determine all regularities for water evaporation. When a sufficient set of values of two variables (inde- pendent and dependent) has been collected, FAHREN- HEIT calls Equation Finder and then considers the best equation discovered by EF. If the error of the dependent variable is known, EF uses it to evaluate equations and estimate errors of equation parameters. If the error is not known, which is the case at the be- ginning of the process, EF assumes a model of con- stant error and estimates for each in a small class of simple equations, the measurement error from the fit. The equation with the smallest error is considered to be the best. In this way FAHRENHEIT obtains not only the best equation, but also the estimation of data error. The lucky coincidence in our experiment has been that the first sequence of measurements was per- formed on the empty beaker. Since the regularity is a constant for all data, this error is minimal. If the initial sequence of measurements were not so fortuitous, the initial error could be larger. But whenever the system finds a sequence of data that is constant within smaller error, it uses that smaller error in future. This seems intuitively plausible: when we discover that in special circumstances the weighing error is smaller, we change our mind on the error of the device. iscovery of repeatability and error In the repeatability study, FAHRENHEIT varies one variable in the category of experiment refinement vari- ables at a time, while keeping all theory formation variables constant. In the liquid transfer experiments, FAHRENHEIT’s space of experiment refinement vari- ables includes time, the number of the dispensing, and the empty/non-empty condition of the beaker. The initial experiment is conducted with an empty beaker and zero repetition of dispensing. With the water be- ing added to the beaker, focus is shifted to the “water in beaker” subspace, where the remainder of the bal- ance readings take place. After each successive 1OmL of water is added, the readings are collected over a period of time. After each sequence of data has been collected, FAHRENHEIT tries to find regularities in the data. If the regularity is not constant, the FAHRENHEIT reconsiders the same data, looking exclusively for the range of constancy. The system expects that some data fit a constant within acceptable error and that the rest may either follow another regularity or increase the er- ror. FAHRENHEIT’s capability for finding multiple regularities and their boundaries is used on this task. In our approach, only a part of data is repeatable (con- stant) because the error is very small. FAMRENHEIT searches for a constant which is acceptable within er- ror, and if it cannot find a satisfactory constant for the whole data set, it partitions the data and tries to find a satisfactory constant in each data subset separately. In order to determine whether the fit is satisfactory, FAHRENHEIT uses the minimum value of experimen- tal error or error which has been detected in the first sequence of data. The dimension of the dry beaker is important be- cause two classes of regularities were discovered: the constant mass for the dry beaker and, the negative linear slope when water is present in the beaker. FAHRENHEIT cannot generalize these two types of regularities, so they are kept separately, and the prop- erty of the beaker, empty vs. containing water, is used in the refined procedure. It is always desirable to in- crease the range of repeatability and to decrease error, but there is no satisfactory universal method that will determine the tradeoff between error and repeatabil- ity and decide on the optimal combination of both. The simplest algorithm would compute the average and standard deviation for each sequence of data. This way we can maximize the range of repeatability but we also maximize the error. Usually the error computed this way is unacceptable. The selection of a viable tradeoff depends on real world considerations external to FAHRENHEIT. Scientists may prefer the smallest error within acceptable costs, while in applications we may prefer the largest repeatability range within ac- ceptable error. FAHRENHEIT uses the minimum er- ror of mass for all datasets it has analyzed. In our experiment, the smallest error occurred in the first se- quence of data. Then the system finds the range of repeatability within that error. Operational definition refinement In our example, an operational procedure to measure the mass dispensed by the buret has been originally defined as: Mass-change(by action a) = mass(after action a)-mass(before action a) Following the repeatability and error analysis, that def- inition can be refined to: 80 Learning: Discovery Mass-change(by adding x mE of water): Mb =: if beaker empty, get mass at any time before dispensing; if water in beaker, get mass at t seconds (t < y) before the beginning of dispensing, #a =: mass at t seconds (y+z > t > z> after the beginning of dispensing Ma - Mb For x=lOmL the error of mass-change is 0.03 where z is the value of the independent variable for the buret (so far only the dispensing of 10mL has been examined, but, in the BACON style, the sys- tem is ready for a generalization); ?/ is the boundary on repeatability for the beaker which contains water: y 5 20 - 5(error) = 15sec; z is obtained from the mea- surement of dispensing time. It has been determined that t > z(z = 9.5 + O.G(error) = lOsec), the con- straint generated by dispensing, while the evaporation provides the second constraint t < y + z. If the ex- periments continued for different values of z, it would turn out that there is a regularity (proportionality) between z and x. The new operational definition con- tains two dependent variables, y and z. They can be treated in the same way as parameters included in the regularities, maxima, and the like. For instance, they can be generalized. For another value of the dispensed volume, y will remain constant, while z will change. Eventually, it can be discovered that z = a x 2, where x is the dispensed volume. If there is leeway left by the repeatability conditions, then the experiment controller, which assigns tasks to device controllers can make its choice of measurement time for the mass reading, within constraints. This helps in experiment planning. Conclusions As we have shown by studying a very simple chem- istry experiment, FAHRENHEIT can be used to refine an operational procedure by discovering repeatability conditions and experimental error. The refined pro- cedure can be applied within the context of a given experiment. For other experiments, refinements may produce different results. Although the discussion was limited to one particular experiment, the same method can be applied to other laboratory situations. For ex- ample, if an acid is dispensed and the pH value is mea- sured, how long should the pH-meter wait to read the pH value, before reagents are fully mixed by the stirrer, and then, how many readings are repeatable before liq- uid evaporates or another process becomes significant and influences the readings ? Waiting until the reagents are fully mixed in pH reading is analogous to waiting until the balance stabilizes in a weight reading. The presented paradigm for operational definition refinement, is a step towards application of machine discovery systems like FAHRENHEIT to real-world discovery problems. Eventually the results may a truly scientific quality. reach Bridgman, P.W., 1927. The Logic of Modern Physics. New York, NY: Macmillan. Carnap, R. (1936). Testability and Meaning, Philoso- phy of Science, 3. Falkenhainer, B.C., & Michalski, R.S., 1986. Inte- grating Quantitative and Qualitative Discovery: The ABACUS System, Machine Learning, 1: 367-401. Falkenhainer, B.C., & Rajamoney, S., 1987. The Inter- dependencies of Theory Formation, Revision, and Ex- perimentation, Proceedings of the Fifth International Conference on Machine Learning, 353-366. Los Altos, CA: Morgan Kaufmann Publ.. Kulkarni, D., & Simon, H.A., 1988. The Processes of Scientific Discovery: The Strategy of Experimentation, Cognitive Science, 12: 139-175. Langley, P.W., Simon, H.A., Bradshaw, G., 8r; Zytkow J.M., 1987. Scientific Discovery; An Account of the Creative Processes. Boston, MA: MIT Press, Langley, P.W., & Zytkow, J.M., 1989. Data-Driven Approaches to Empirical Discovery. Artificial Intelli- gence, 40: 283-312. Nordhausen, B., & Langley, P., 1990. An Integrated Approach to Empirical Discovery. in: J.Shrager & P. Langley (eds.) Computational Models of Scientific Dis- covery and Theory Formation, 97-128, San Mateo, CA: Morgan Kaufmann Publ.. Sleeman, D.H., Stacey, M.K., Edwards, P., & Gray, N.A.B., 1989. An Architecture for Theory-Driven Sci- entific Discovery, Proceedings of E WSL-89. Zembowicz, R., Zytkow, J.M., 1991. Automated Dis- covery of Empirical Equations from Data, Proceedings of the ISMIS-91 Symposium, 429-440, Springer-Verlag. iytkow, J.M. 1984. Partial Definitions in Science Compared to Meaning Families in Natural Language. Sign, System and Function: papers of the first and second Polish-American semiotics colloquia, 479-492, Mouton Publ.. 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 Kaufmann Publ.. Zytkow, J.M., Zhu, J. & Hussam, A., 1990. Automated Discovery in a Chemistry Laboratory, Proceedings of the AAAI-90, 889-894, Menlo Park, CA: AAAI Press. Zytkow, J.M., Zhu, J. & Hussam, A., 1990a. Determin- ing Repeatability and Error in Experimental Results by a Discovery System. In: Ras Z., Zemankova M., and Emrich M.l., (eds.), Methodologies for Intelligent Systems 5, 483-445, New York, NY: Elsevier Science Publ.. Zytkow, Zhu, and Zembowiez 81 | 1992 | 27 |
1,218 | earni wit sio aces Haym Hirsh Department of Computer Science Rutgers University New Brunswick, NJ 08903 hirsh@cs.rutgers.edu Abstract Although version spaces provide a useful concep- tual tool for inductive concept learning, they often face severe computational difficulties when impls mented. For example, the G set of traditional boundary-set implementations of version spaces can have size exponential in the amount of data for even the most simple conjunctive description languages [Haussler, 19881. This paper presents a new representation for version spaces that is more general than the traditional boundary-set repre- sentation, yet has worst-case time complexity that is polynomial in the amount of data when used for learning from attribute-value data with tree- structured feature hierarchies (which includes lan- guages like Haussler’s). The central idea under- lying this new representation is to maintain the traditional S boundary set as usual, but use a list N of negative data rather than keeping a G set as is typically done. 1. Introduction Concept learning can be viewed as a problem of search [Simon and Lea, 1974; Mitchell, 1982]-to identify some concept definition out of a space of possible def- initions expressible in a given concept description lan- guage. Mitchell [1982] formalized this view of generuL ization as search in his development of version spaces: A version space is the set of all classifiers expressible in the description language that correctly classify a set of data. Mitchell furthermore noted that the relative generality of concepts imposes a partial order that al- lows efficient representation of a version space by the This paper owes a great debt to William Cohen, in front of and with whom much.of this work developed. The ar- rangement of facilities by Paul Rosenbloom at IS1 (under DARPA and ONR contract number N00014-89-K-01555) so I could escape from New Jersey and work in the CaIifor- nia sun is tremendously appreciated. Discussions with and comments from William Cohen, Steve Norton, and an ony- mous reviewer (Oren Etzioni) are also greatly appreciated. boundary sets S and G containing the most specific and most general concept definitions in the space. The S and G sets delimit the set of all concept definitions consistent with the given data. Incremental learning is accomplished with the candidate-elimination algo- rithm, which manipulates only the boundary sets of a version space: as each new example is obtained, S and G are modified so that they represent a new version space containing those concept definitions that cor- rectly classify all the previously processed data plus the new example. Although version spaces have been successful as a conceptual framework for learning, they have had se- rious computational limitations as a way to imple- ment learning systems. This paper addresses the is- sue of the computational complexity of implementing version-space learning algorithms by proposing an al- ternative representation of version spaces that main- tains the S set as usual, but uses a list N of neg- ative data rather than the traditional G set. The benefit of this new representation is that unlike the [S, G] representation of version spaces where the G set can have size exponential in the amount of data even for very simple conjunctive languages [Haussler, 19881, this [S, N] representation requires space and time only polynomial in the amount of data. It furthermore ex- tends the version-space approach to situations where the boundary-set representation cannot be used. The remainder of this paper is structured as fol- lows. Section 2 discusses criteria for evaluating version- space representations, including various operations a representation should tractably support. Section 3 then presents the [S, N] representation in more de- tail, including implementations of various operations using this representation. Descriptions of how these implementations can be instantiated for conjunctive languages over tree-structured attribute hierarchies to yield polynomial-time version-space algorithms follows in Section 4. Section 5 discusses some of the issues raised by this work, including the generality of the [S, N] representation and some open problems, and Section 6 concludes the paper with a summary of the main points of this work. Hirsh 117 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. 2. Representing Version Spaces The key idea in this paper is to develop an alternative representation of version spaces for which computa- tional intractability does not occur. However, before describing the alternative representation, it is useful to elaborate a bit further on what is meant by a repre- sentation of a version space. First some basic terminology. concept learning problems traditionally assume the presence of some concept description language, CDL, in which results must be expressed. Each concept definition in CDL applies to a universe of objects, or instances, Z, some of which it classifies as positive (the concept definition is said to cover the instance) and some of which it classifies as negative. The extension of a concept de- scription c E CDL is the set of all objects it classifies as positive. A learning problem is a triple (CDL, I+, I-), where I+, I- 2 Z. I+ is the set of positive training data, and I- is the set of negative training data. A concept definition c E CDL is consistent with I+ and .I- 7 written cons(c, I+, I-), if it covers every element of I+ and doesn’t cover any element of I-. The version-space approach to concept learning [Mitchell, 19821 is to determine everything in a con- cept description language that is consistent with I+ and I-. The version space of all elements of CDL con- sistent with I+ and I-, VS~~~(I+, I-), is equal to {c E CDL ] cons(c, I+, I-)}. When clear from context, the CDL subscript will be left out. A representation of a version space for a class C of description languages is a finite data structure from which VS&I+, I-) can be defined for all CDL E C. For example, the following are all representations of a version space: The tuple [S = min( VS(I+, I-)), G = max( VS(I+, I-))] is a representation of a version space for the class C of admissible languages,l since for admissible languages VS( I+, I-) = {c E CDL13 E S,3g E Geczid- VS(I+, I-), i.e., listing all elements in the version space, is trivially a representation of a version space for the class C of finite concept description languages. The tuple [I+, 1-I is a representation of a version space for all languages, since VS(I+, I-) = (c E CDL 1 cons(c, I+, I-)). While all of these are version-space representations, the key question that must be asked is how tractably a set of data can be processed for a particular represen- tation. This can be formalized as follows. A version- space representation is tractable for a class of descrip- tion languages if the representation of VS(I+, I-) can be computed for all I+ and I- in time polynomial in a concept space can al., 1991; ]I+], ]1- I, and relevant properties of the description language (such as the number of features for feature- based description languages).2 For example, consider the tractability of the version- space representations discussed above: 1. 2. 3. a The [S, G] representation is not tractable for con- junctive languages of tree-structured features, since Haussler has shown that the G set can have size exponential in 11-l for even the simple subcase of monomial languages. VS(I+, I-) (explicitly listing the entire version space) is only tractable if the description language is small, i.e., it has size polynomial in II+ I, )I- 1, and relevant properties of the description language. The [I+, I-] representation is tractable for conjunc- tive tree-structured languages since the [S, N] repre- sentation of the version space can be computed from it, and as shown later this second representation is tractable. In addition to processing a set of data, there are number of operations that are useful when learning Among the operations that have generally proven useful for version space are the following: l(a) w Collapsed ?( Vs) ----) true or false: If data are inconsistent or if there is no description that can distinguish between all given positive and negative data, the version space will be empty. This operation returns true if version space Vs is emptyiand otherwise it returns false. - Converged ?( VS) ----) true or false: The ideal result of learning will be a version space that contains only a single item. This operation returns true if version space VS contains exactly one concept definition, otherwise it returns false. with version spaces, and a good representation should support as many of them as possible. This can be for- malized as follows. A version-space representation is epistemologically adequate for a set of operations and a class of description languages if all the operations can be implemented using the representation. A represen- tation is heuristically adequate for a set of operations and a class of description languages if each of the oper- ations can be computed in time polynomial in the size of the operation’s inputs and in relevant properties of the description language. 2Tractability should not be confused with the impor- tant question of sample complexity (such as is addressed in the pat-learning literature), namely how much data is necessary to learn well with a particular class of descrip- tion languages. The results in this paper guarantee that if the sample complexity is polynomial in relevant features of the language -such as to E-exhaust a version space with high probability [Haussler, 1988]-processing the data us- ing the [S, N] representation will have polynomial compu- tational complexity; there are no such guarantees for the [S, G] representation. 118 Learning: Inductive 2(a) 04 364 4(a) W (4 Update(I, VS) -F VS’: For each new example learning must remove those elements of the version space that classify the ex- ample incorrectly. This operation updates version space VS to reflect new instance I. CZassify(I, VS) -+ +, -, or ?: If all elements of a version space agree on the clas- sification of an example, the example can be given the unanimous classification accorded by the ver- sion space. This operation returns “+” if every el- ement of VS classifies I as positive, returns a “-n if every element of VS classifies I as negative, and otherwise returns “?” since some elements of VS classify I as positive and some as negative. Member(C, Vs) + true or false: A version space is simply a set of concept defini- tions. This operation checks if concept definition C is in version space VS. VSl r-l vs2 + vs’: Version spaces are sets and thus can be inter- sected. This operation returns the version space VS’ that is the intersection of VSl and VS2. VSl u vs2 ---) vs’: As for intersections, version spaces can also be unioned together. This operation returns the ver- sion space VS’ that is the union of VSl and VS2. VSl C_ VS2, VSl = VS2 ---) true or false: One set can always be a subset of another. Sim- ilarly, two sets can be equal. These operations return true if V& is a subset of VS2 or if VSl is equal to VSz, respectively. The operations in 1, 2, 3, and 4a were described by Mitchell [1978]. The operations in 4 have also proven useful for an alternative form of boundary-set-based version-space learning [Hirsh, 19901. To make this tangible, consider the adequacy of the three representations discussed earlier: 1. The [S, G] p re resentation is epistemologically ade- quate for the set of operations listed above for the class of admissible description languages, and it is heuristically adequate for the operations above for conjunctive languages of tree-structured features. 2. VS(I+, I-) (explicitly listing the entire version space) is epistemologically adequate for finite de- scription languages, and is only heuristically ade- quate for small description languages. 3. The [I+, I-] representation is epistemologically ad- equate for the above operations for admissible de- scription languages, since at worst the [S, N] repre- sentation can be computed from it. It is furthermore heuristically adequate for all operations but 4b by computing the associated [S, N] representation. Since VS(I+ , I-) can be (although in theory need not be) computed by sequentially processing the in- dividual elements of I+ and I- with a series of Up- date operations, one might think that the heuristic ad- equacy of a representation for the Update operation implies tractability for processing a set of data within the representation. This is not the case; for example Haussler has shown that for the boundary-set repre- sentation each Update can potentially double the size of the G set, yielding a result with size exponential in ].I- 1. Tractability can be established if the representa tion is heuristically adequate for Update and if for all 1+ and I- the size of the representation of VS(I*, I-) is guaranteed to be polynomial in ]I+], ]I- I, and rele- vant properties of the description language. This paper is not the first to consider alternative representations of version spaces. Most relevant to this work is the representation used by INBF [Smith and Rosenbloom, 19901. It represents a version space using the standard S set and using a G set that is only up- dated with a subset of the negative data-those that are “near misses”-and instead also maintains a list of “far miss” negative data. They show that for con- junctive tree-structured languages their representation is epistemologically and heuristically adequate for op- erations la, lb, and 2a, and that it is furthermore tractable. Also related is the work of Idestam-Almquist [1989], whose primary focus is not on the tractability of ver- sion spaces7 but rather on retracting data as a way to handle inconsistent data. Idestam-Almquist assumes conjunctive languages over ranges and tree-structured features. However, rather than representing S and G sets he instead maintains where the S and G set would be for each feature after processing each of the train- ing examples in isolation. Idestam-Almquist shows that his representation is epistemologically and heuris- tically adequate for conjunctive languages over ranges and tree-structured hierarchies for the operations in categories 1 and 2 plus his instance retraction opers tion. The representation described in this paper bears many similarities to that of Smith and Rosenbloom, but does away with the G set altogether, extending the approach to non-feature-based languages and further version-space operations. Some of Idestam-Almquist’s implementations of the operations in categories 1 and 2 are special cases of the implementations to be de- scribed in the next section. 3. Version Spaces wit t G Sets The whole point of this paper is that a version space can be represented as a tuple [S, N], where S repre- sents the S boundary set of the traditional candidate- elimination algorithm (i.e., S = min( VS(I+, I-))), and N is a list of the observed negative data (i.e., N = I-). Initially S contains the empty concept that says nothing is positive3 and N is empty. 3Thi~ should not be confused with an empty S set-the S set here has one concept definition whose extension is empty [Hirsh, 19901. Hirsh 119 First, observe that this is indeed a representa- tion of version spaces for admissible description lan- guages, since VS(I+ , I-) = {c E CDL 1 3s E S, s -( c, cons(c, 8, Iv)). The remainder of this section presents epistemolog- ical adequacy conditions for the [S, N] representation. The following shows that the representation is episte- mologically adequate for operations la, 2a&b, 3a, and 4a for admissible languages (including proof sketches for the correctness of the given algorithms): CoZZupsed?( [S, N]): If S is empty return true, oth- erwise return false. (Cf. the algorithm for Up- date.) Proofi If S is empty the version space has no minimal element, which means it must be empty (since the CDL is admissible). 0 Update(I, [S, N]): If I is negative add 1 to N and remove those elements of S that cover I; if I is pos- itive replace S with the minimal generalizations of S that cover I but cover no element n of N. Proofi The proof for the S set parallels that for the candidate-elimination algorithm [Mitchell, 19781; the proof for the N set is obvious. D CZassify(I, [S, N]): If I is below every s in S, re- turn “+” (as in the standard boundary-set imple- mentation of version spaces). Otherwise compute the new version space [S’, N] that would arise if I were positive. If S’ is empty (i.e., the version space collapses), I must be negative so return “-“. Otherwise return “?“. Proof: If I is below every element of S every ele- ment of the version space must classify it positive. If treating I as positive causes the version space to collapse every element of the version space must classify it as negative. Otherwise some classify it as positive and some as negative. 0 Member(C, [S, N]): If C is above some s in S and covers no n in N return true, otherwise return false. Proof: If a definition is above some element of S and doesn’t cover any element of N it is in the version space. 0 [Sr, Nl] n [Sz, Ns]: Compute the minimal pair- wise generalizations of elements from Sr and S2. Throw away those that cover some element of il or Ns . The S set for the new version space con- tains the minimal elements of the result of this computation. The new N set is simply the union of Nr and Ns. Proof: The proof for the S set parallels that for version-space merging [Hirsh, 19901; the proof for the N set is obvious. 0 In addition, the [S, N] representation is epistemolog- ically adequate for converged?’ for the following two languages: If learning uses a conjunctive tree-structured lan- guage, then Smith and Rosenbloom [1990] have shown that convergence requires one “near-miss” for each feature in the S set that has not been gener- alized to be a “don’t care”. Thus it is possible to check convergence for such languages by checking if N contains the necessary near misses. Proof: [Smith and Rosenbloom, 19901. 0 If it is possible to generate all minimal generaliza tions of a concept definition (i.e., for a concept def- inition c it is possible to generate all terms ci for which ci is more general that c and there is no cp between c and ca), then simply compute the set of minimal generalizations of the S set (if it is single- ton) and if each minimal generalization covers some element n in N the version space has converged. Proofi If there is no more general term that ex- cludes all negative data, the singleton element of the S set must be the most general term consistent with the data as well as the most specific, and thus it is the only thing in the version space. 0 These algorithms cover all of Mitchell’s original op- erations, and only leave operations 4b and 4c. Note that the [S, N] re p resentation is not epistemologically adequate for computing unions, since it is not even possible to represent arbitrary unions of version spaces for conjunctive tree-structured languages in the [S, N] representation (generating an example that demon- strates this is left as an exercise due to space limita- tions). On the other hand, the [S, N] representation is epistemologically (and heuristically) adequate for sub- set and equality testing for conjunctive tree-structured languages by exploiting the results of Smith and Rosen- bloom [1990], but space considerations preclude pre- senting details. . olynomial=Time Learning with Version Spaces The previous section demonstrated the correctness of the [S, N] representation of version spaces and showed that it is epistemologically adequate for all the given operations (except 4b) for fairly weakly constrained de- scription languages. However, to be a satisfactory rep- resentation it must be both tractable and heuristically adequate. This section demonstrates the tractability and heuristic adequacy of the [S, N] representation for conjunctive tree-structure languages.4 4Although not discussed here, the algorithms of this sec- tion also apply (with minor changes) more generally, such as for real-valued data where the description language takes the form of conjunctions of ranges over the various vari- ables. However, characterizing the exact linguistic limits of tractability for these algorithms is beyond the scope of this paper. 120 Learning: Inductive The most important criterion for a version-space representation is whether data can be processed in polynomial time, i.e., whether the representation is tractable, and this is the first question considered here. As discussed earlier, tractability can be established by establishing heuristic adequacy for Update plus estab- lishing polynomial bounds on the space requirements for representing VS(I+ 9 I-) for any If and I-. The heuristic adequacy of Up&de is shown below. It is easy to show the necessary space bounds by noting that the [S, N] representation of VS(I+, I-) (for the class of conjunctive tree-structured languages) requires space linear in only 11-l and the number of features, since the S set will always be singleton, and the size of N can never be larger than the amount of negative training data (in contrast to the traditional [S, G] represents tion, which may require exponential space). Thus the [S, N] representation is tractable. The remainder of this section shows the heuristic adequacy of the [S, N] representation for conjunctive tree-structured languages for all the operations in cat- egories 1 through 3 plus operation 4a using the algo- rithms of the previous section. Key to these results is the fact that comparing two concept definitions for relative generality and computing the minimal general- ization of two definitions requires time at worst linear in the number of features and the sizes of the general- ization hierarchies, as does comparing an instance to a concept definition or computing the minimal gener- alization of a definition that covers an instance. The goal here, of course, is to show that each resulting im- plementation requires time at worst polynomial in the 1 of the inputs (e.g., IN]), the number of features, the size of the feature hierarches. GoZlapsed?([S, N]): This simply checks if S is empty, and is thus trivially tractable. Gongerged?([S, N]): For attribute-value data with generalization hierarchies the result of Smith and Rosenbloom [1990] mentioned above can be used. 2(a) 64 This simply requires scanning every element of N and checking if it is a near miss by inspec ting S and the generalization hierarchies for each fea ture. This clearly takes time polynomial in ] N 1, the number of features, and the size of the gener- alization hierarchies. Upd&(I, [S, NJ): F or negative data this requires at worst checking if the single element of S covers I and adding 1 to &, which only requires time linear in the number of features and the hierarchy sizes. For positive data this requires computing the min- imal generalization of S and I, then comparing the result to each element of N, which requires time at worst polynomial in IN I, the number of features, and the generalization-hierarchy sizes. CZussify(1, [S, NJ): At worst this requires compar- ing 1 to S (requiring time linear in the number of features and the hierarchy sizes), then updating 3(a) 4(a) the version space with the example (which as just described requires polynomial time), then finally checking if the resulting S set is empty. This all requires polynomial time. Member(G, [S, N]): Checking whether C is above the singleton S-set element requires time linear in the number of features and the hierarchy sizes, and checking that it covers no element of N re- quires time polynomial in IN 1, the number of fea- tures, and the hierarchy sizes, and thus member- ship takes at most polynomial time. [Sr, Nr] n [&, Nz]: Computing the generalization of the singleton elements from Sr and ,!?a requires time polynomial in the number of features and the hierarchy sizes. Comparing it to all elements of Nr and N2 requires at most (Nr] + I Nz ] comparisons, and thus computing the new S set requires poly- nomial time. Computing the new N set simply requires unioning Nr and N2, which is of course tractable. 5. iseussion This paper has described how the [S, N] representa- tion of a version space is epistemologically adequate for most of the desired version-space operations with few restrictions on description languages beyond ad- missibility. It also showed the tractability and heuris- tic adequacy of the [S, NJ representation when used in learning from attribute-value data with tree-structured feature hierarchies. This is particularly notable be- cause it applies even in cases where the traditional boundary-set implementation of version spaces must store an exponential number of items in the G set, i.e., where the [S, G] representation is not tractable. Since the approach described here does not maintain a G set this exponential complexity never occurs. Eliminating the G set has further benefits beyond avoiding exponential G-set size. These include: o If the G set is infinite. For example, if Z is infi- nite and CDL contains one most general definition whose extension contains all of Z and the remaining elements of CDL include all definitions that cover exactly one or exactly two elements of Z, after a single positive example and a different single neg- ative example the G set would have infinite size. Nonetheless, the [S, N] representation would still ap- ply to this case. A more realistic example of this is in the description logic CLASSIG 19891, where there are an infinite number of max- imally general specializations of THING that would exclude a description containing a cyclic SAME-AS construct; here, too, the G set would be infinite. e If the language is not admissible. Even if there are unbounded ascending chains (which means there may be no maximal term for a version space and hence no G set), the [S, N] representation may ap- ply; all that is necessary is that the S set be repre- Hirsh 121 e sentable. This suggests that the notion of admissi- bility can be separated into two parts: “lower” ad- missibility for S-set representability and “upper9’ ad- missibility for G-set representability. All the earlier proofs only require lower admissibility. If it is intractable or undecidable to compute a single minimal specialization of a concept definition. Since the [S, N] representation only requires generalizing S-set elements, it applies even when G-set special- izations cannot be computed. Thus the [S, N] representation of version spaces makes it possible to implement version-space learning in situ- ations where Mitchell’s original version-space approach would not have even applied. This paper has suggested doing away with G sets since most languages traditionally used with version spaces tend to have singleton S sets and it is the G set that causes difficulties. However, for some languages, such as pure disjunctive languages, the G set remains singleton and the S set can grow exponentially large. While this paper has described representing version spaces by the S and N sets, by symmetry it is possible to represent a version space by its G set and a list P of positive data. In general one would want to represent a version space by whichever of the two boundary sets would remain small plus the data that correspond to the other boundary set. There are a number of questions that remain open. This paper described how it is possible to do away with one boundary set by instead saving a list of train- ing data. The obvious next step would be to replace both boundary sets with the lists of positive and nega tive data that give rise to them and perform all opera tions using these lists. While presented as a strawman representation in Section 2, the general questions of tractability and heuristic adequacy are worth explor- ing. Although the [S, N] representation is heuristically adequate for subset and equality testing for conjunc- tive languages over both tree-structured hierarchies and ranges, the general question of epistemological and heuristic adequacy for these operations for more gen- eral languages remains an open question. Lastly, the tests for convergence presented here only apply in spe- cial cases; while it would be interesting to show epis- temological adequacy for a more general class of lan- guages, the assumption that it is possible to compute all minimal generalizations of a definition is likely to be the most general case possible. Finally, note that the [S, N] representation is not a perfect replacement for the traditional [S, G] boundary-set representation. If unions are important, or if it is necessary to have the G-set explicitly (such as if false negatives are bad and thus very general terms are desired), the [S, G] representation is the only one known to be appropriate. 122 Learning: Inductive 6. Summary This paper has presented a new representation for ver- sion spaces that maintains the S set of traditional boundary-set implementations of version spaces, but replaces the G set with a list N of negative data. This [S, N] representation was shown to support vari- ous desired version-space operations. When applied to attribute-value data with tree-structured feature hier- archies learning has worst-case complexity that is poly- nomial in the amount of data even in situations where the candidate-elimination algorithm takes exponential time and space. The learning algorithms also apply in cases where boundary-set implementations of version spaces cannot be used, such as when it is intractable or impossible to compute G-set elements. References A. Borgida, R. J. Brachman, D. L. McGuiness, and L. Resnick. CLASSIC: A structural data model for objects. In Proceedings of SIGMOD-89, Portland, Oregon, 1989. C. A. Gunter, T.-H. Ngair, P. Panangaden, and D. Subramanian. The common order-theoretic struc- ture of version spaces and ATMS’s (extended ab- stract). In Proceedings of the National Conference on Artificial Intelligence, Anaheim, CA, July 1991. D. Haussler. Quantifying inductive bias: AI learning algorithms and Valiant’s learning framework. Artifi- cial Intelligence, 26(2):177-221, Sept. 1988. H. Hirsh. Incremental version-space merging. In Proceedings of the Seventh International Conference on Machine Learning, pages 330-338, Austin, Texas, June 1990. H. Hirsh. Theoretical underpinnings of version spaces. In Proceedings of the Twelfth Joint International Conference on ArtijkiaZ Intelligence, pages 665-670, Sydney, Australia, August 1991. P. Idestam-Almquist. Demand networks: An alter- native representation of version spaces. SYSLAB Re- port 75, Department of Computer and Systems Sci- ences, The Royal Institue of Technology and Stock- holm University, 1989. T. M. Mitchell. Version Spaces: An Approach to Con- cept Learning. PhD thesis, Stanford University, De- cember 1978. T. M. Mitchell. Generalization as search. Artificial Intelligence, 18(2):203-226, March 1982. H. Simon and G. Lea. Problem solving and rule in- duction. In H. Simon, editor, Models of Thought. Yale University Press, 1974. B. D. Smith and P. S. Rosenbloom. Incremental non- backtracking focusing: A polynomially bounded gen- eralization algorithm for version spaces. In Proceed- ings of the National Conference on Artificial InteZZi- gence, pages 848-853, Boston, MA, August 1990. | 1992 | 28 |
1,219 | andy Merber Lockheed Artificial Intelligence Center O/96-20, B/254?, 3251 Hanover Street Palo Alto, California 94304 kerber@titan.rdd.lmsc.lockheed.com Many classification algorithms require that the training data contain only discrete attributes. To use such an algorithm when there are numeric at- tributes, all numeric values must first be converted into discrete values-a process called discretiza- tion. This paper describes ChiMerge, a general, robust algorithm that uses the x2 statistic to dis- cretize (quantize) numeric attributes. ntroduction Discretization is performed by dividing the values of a numeric (continuous) attribute into a small number of intervals, where each interval is mapped to a discrete (categorical, nominal, symbolic) symbol. For example, if the attribute in question is a person’s age, one pos- sible discretization is: [O. . .ll] -+ child, [12.. .17] -+ adolescent, [18. . .44] + adult, [45. . .69] + middle age, [70. . so] + elderly. Few classification algorithms perform discretization automatically; rather, it is the user’s responsibility to define a discretization and construct a data file con- taining only discrete values. While the extra effort of manual discretization is a hardship, of much greater importance is that the classification algorithm might not be able to overcome the handicap of poorly chosen intervals. For example, consider the discretization of the attribute age, defined above. It is impossible to inductively learn the concept legal to drink alcohol in California (where the drinking age is 21) because all ages between 18 and 45 have been mapped to the same discrete value. In general, unless users are knowledge- able about the problem domain and understand the be- havior of the classification algorithm they won’t know which discretization is best (something they probably expected the classification system to tell them). Although it can significantly influence the effectiveness of a classification algorithm, discretization is usually considered a peripheral issue and virtually ignored in the machine learning literature. Typically, authors of papers describing discrete classification algorithms ei- ther apply their systems to purely discrete problems, discretize manually (using expert advice, intuition, or experimentation), or employ a simple method. The most obvious simple method, called equal-width- intervals, is to divide the number line between the min- imum and maximum values into N intervals of equal size (N being a user-supplied parameter). Thus, if A and B are the low and high values, respectively, then the intervals will have width W = (B - A)/N and the interval boundaries will be at A + W, A + 2W, . . . , A + (N - 1)W. In a similar method, called equal-frequency- intervals, the interval boundaries are chosen so that each interval contains approximately the same number of training examples; thus, if N = 10, each interval would contain approximately 10% of the examples. These algorithms are easy to implement and in most cases produce a reasonable abstraction of the data. However, there are many situations where they per- form poorly. For example, if the attribute salary is di- vided up into 5 equal-width intervals when the highest salary is $500,000, then all people with salary less than $100,000 would wind up in the same interval. On the other hand, if the equal-frequency-intervals method is used the opposite problem can occur: everyone mak- ing over $50,000 per year might be put in the same category as the person with the $500,000 salary (de- pending on the distribution of salaries). With both of these discretizations it would be difficult or impos- sible to learn certain concepts. The primary reason that these methods fail is that they ignore the class of the training examples, making it very unlikely that the interval boundaries will just happen to occur in the places that best facilitate accurate classification. Classification algorithms such as C4 [Quinlan et al., 19871, CART [B reiman et al., 19841, and PVM [Weiss et al., 19901 do consider the class information when constructing intervals, but differ in that discretization is performed not as a pre-processing step, but dynam- ically as the algorithm runs. For example, in C4 (a member of the ID3 [Quinlan, 19861 family of decision tree algorithms) the same measure used to choose the best attribute to branch on at each node of the de- cision tree (usually some variant of information gain) is used to determine the best value for splitting a nu- meric attribute into two intervals. This value, called a cutpoint, is found by exhaustively checking all pos- sible binary splits of the current interval and choosing the splitting value that maximizes the information gain measure. However, it is not obvious how such a technique should be used or adapted to perform static (non- dynamic) discretization when more then two intervals Kerber 123 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. per attribute are desired. [Catlett, 19911 describes one possible extension, called D-2, which applies the above binary method recursively, splitting intervals as long as the information gain of each split exceeds some thresh- old and a limit on the maximum number of intervals has not been exceeded. Some classification algorithms can be easily ex- tended to discretize dynamically, but many cannot. Even for algorithms that could use a dynamic method, it might still be preferable to use static discretization. [Catlett, 19911 reports over a lo-fold speed-up (50-fold in one domain) for ID3/C4 when the data is discretized initially using D-2 rather than the standard dynamic approach, with little or no loss of accuracy (and some- times increased accuracy). The dramatic increase in efficiency is because the dynamic ID3/C4 algorithm must re-discretize all numeric attributes at every node in the decision tree, whereas when D-2 is used each attribute is discretized only once. Objectives The search for an improved discretization algorithm was undertaken in order to extend the OTIS classi- fication system [Kerber, 1988][Kerber, 19911 to han- dle numeric data automatically (OTIS constructs sym- bolic classification rules from relational, noisy, and multi-class training examples). Initially, the equal- width-intervals and equal-frequency-intervaZs methods were implemented and found to be generally effec- tive, but fragile-occasionally producing discretiza- tions with obvious and serious deficiencies, such as with the age and salary examples described earlier. As a result, it was seldom possible to feel confident that a given discretization was reasonable; a classification algorithm cannot distinguish a non-predictive from a poorly discretized attribute and the user cannot do so without examining the raw data. Evaluating the quality of a discretization or a dis- cretization algorithm is difficult because it is seldom possible to know what the correct or optimal discretiza- tion is (it would be necessary to know the true distri- bution of the model from which the data was gener- ated, generally possible only with artificially generated data). Further complicating evaluation is that dis- cretization quality depends on the classification algo- rithm that will use the discretization; for instance, clas- sification algorithms will differ according to whether they prefer many or few intervals. While it is not possible to have an optimal discretiza- tion with which to compare results, some notion of quality is needed in order to design and evaluate a discretization algorithm. The primary purpose of dis- cretization, besides eliminating numeric values from the training data, is to produce a concise summariza- tion of a numeric attribute. An interval is essentially a summary of the relative frequency of classes within that interval (e.g., if an interval contains 28 positive and 12 negative examples, the interval would be de- scribed as 70% positive and 30% negative). There- fore, in an accurate discretization, the relative class frequencies should be fairly consistent within an inter- val-(otherwise the interval should be split to express this difference) but two adjacent intervals should not have similar relative class frequencies (otherwise the intervals should be combined to make the discretiza- tion more concise). Thus, the defining characteristic of a high quality discretization can be summarized as: intra-interval uniformity and inter-interval difference. ChiMerge operationalizes this notion of quality by using the x2 statistic to determine if the relative class frequencies of adjacent intervals are distinctly different or if they are similar enough to justify merging them into a single interval. x2 is a statistical measure used to test the hypothesis that two discrete attributes are statistically independent. Applied to the discretization problem, it tests the hypothesis that the class attribute is independent of which of two adjacent intervals an example belongs. If the conclusion of the x2 test is that the class is independent of the intervals, then the intervals should be merged. On the other hand, if the x2 test concludes that they are not independent, it indicates that the difference in relative class frequencies is statistically significant and therefore the intervals should remain separate. erge Algorithm The ChiMerge algorithm consists of an initialization step and a bottom-up merging process, where inter- vals are continuously merged until a termination con- dition is met. Chimerge is initialized by first sorting the training examples according to their value for the attribute being discretized and then constructing the initial discretization, in which each example is put into its own interval (i.e., place an interval boundary before and after each example). The interval merging process contains two steps, repeated continuously: (1) com- pute the x2 value for each pair of adjacent intervals, (2) merge (combine) the pair of adjacent intervals with the lowest x2 value. Merging continues until all pairs of intervals have x2 values exceeding the parameter x2-threshold (described below); that is, all adjacent in- tervals are considered significantly different by the x2 independence test. The formula for computing the x2 value is: x2 = 22 (Aj;E,jJ2 i=lj=l ij Where: m = 2 (the 2 intervals being compared) k= number of classes Aij = number of examples in ith interval, jth class. Ri = number of examples in ith interval = Et=, Ai, Cj = number of examples in jth class = CL, Ai, N = total number of examples = c:=, C, Eij = expected frequency of Ai, = “iic’ 124 Learning: Inductive The value for x2-threshold is determined by selecting a desired significance level and then using a table or formula to obtain the corresponding x2 value (obtain- ing the x2 value also requires specifying the number of degrees of freedom, which will be 1 less than the number of classes). For example, when there are 3 classes (thus 2 degrees of freedom) the x2 value at the .90 percentile level is 4.6. The meaning of this thresh- old is that among cases where the class and attribute are independent, there is a 90% probability that the computed x2 value will be less than 4.6; thus, x2 val- ues in excess of the threshold imply that the attribute and class are not independent. As a result, choos- ing higher values for x 2-threshold causes the merging process to continue longer, resulting in discretizations with fewer and larger intervals. The user can also override x2-threshold, if desired, through use of two parameters-min-intervab and max-intervals-which specify a lower and upper limit on the number of in- tervals to create (the defaults, 1 and 00, have no ef- fect). The standard recommended procedure for using ChiMerge would be to set the x2-threshold at the .90, .95, or .99 significance level and set the max-intervals parameter to a value of around 10 or 15 to prevent an excessive number of intervals from being created. The behavior of ChiMerge will be demonstrated us- ing the well known iris classification problem [Fisher, 19361. The iris database contains 50 examples each of the classes Iris setosa, Iris versicolor, and Iris vir- ginica (species of iris). Each example is described us- ing four numeric attributes: petal-length, petal-width, sepal-length, and sepal-width. Figure 1 shows the dis- tribution of classes with respect to the sepal-length at- tribute. The numbers on the left are the values of sepaZ-length and the symbols to their right each rep- resent a single instance with that sepal-length value, coded as follows: “4 = setosa, “0” = versicolor, and ((@‘, = virginica. Blanks lines show the location of in- terval boundaries chosen by ChiMerge. Similar plots for the other three iris attributes are included as an appendix. Figure 2 shows both an intermediate and the final discretization when ChiMerge is applied to the sepal- length attribute. Each row of the figure represents one interval of the current discretization. The number on the left is the lower bound of that interval; thus, the extent of an interval is from its lower bound up to (but not including) the lower bound of the next interval. The next three numbers in each row comprise the class frequency vector, which represents how many examples of each class are in that interval (the order is setosa, versicolor, virginica). The numbers on the right are the result of applying the x2 statistic to measure the difference between adjacent intervals; the higher the x2 value the greater the belief that the difference between the two intervals is statistically significant. For exam- ple, in the interval [5.0+5.5) there are 25 instances 5.5 *-M10000 5.6 oooooe 5.7Tkkooooor 8.: g;oeee 610 ooooee t&a CKm~" Figure 1: Class histogram for sepal-length of setosa, 5 instances of versicolor, 0 instances of vir- ginica, and a x2 difference of 8.6 between it and the following interval. The intermediate discretization (on the left) shows the situation after running ChiMerge with the threshold set at 1.4 (the .50 significance per- centile level, which is extremely low). If ChiMerge is now resumed with a higher threshold, on the next it- eration the intervals [6.7+7.0) and [7.0+7.1) will be merged since they are the pair of adjacent intervals with the lowest x2 score. The second discretization in Figure 2 shows the final result produced by ChiMerge at the .90 significance level (x2 = 4.6). The appendix includes the discretizations produced by ChiMerge for the other three iris attributes. Class Int fkequency X 2 4.3 16 lI 0 1. 4.9 5.0 5.5 5.6 5.7 5.8 5.9 6.3 6.6 6.7 7.0 7.1 4 25 2 0 2 1 5 5 5 5 3 12 6 2 5 0 3 7 15 0 10 0 12 4.1 2.4 8.6 2.9 1.7 1.8 2.2 4.6 4.1 3.2 1.5 3.6 Int 4.3 5.5 5.8 6.3 7.1 Class frequency 2 45 ti 1 30.9 4 15 2 1 15 10 6.7 4.9 0 14 25 5g 0 0 12 * Figure 2: ChiMerge discretizations for sepal-length at the .50 and .90 significance levels (x2 = 1.4 and 4.6) Empirical Results Because ChiMerge is not itself a classification algo- rithm it cannot be tested directly for classification ac- Kerber 125 curacy, but must be evaluated indirectly in the context of a classification algorithm. Therefore, ChiMerge, D- 2, and the equal-width-intervals and equal-frequency- intervals algorithms were used to create intervals for the Back Propagation neural network classifier [Rumel- hart and McClelland, 19861. Back Propagation was chosen primarily because it is widely known, thus re- quiring no further description. The results shown were obtained using 5-fold cross validation testing in the glass fragment classification domain and 2-fold cross validation with the numeric attributes of the thyroid domainl. The glass data consists of 214 examples di- vided into 6 classes and described in terms of 9 numeric attributes. The thyroid data contains 3772 exam- ples, 7 classes, and 6 attributes (the discrete attributes were ignored). For the equal-width-intervals, equal- frequency-intervals, and D-2 algorithms, the value of N (the number of intervals) was set to 7. For ChiMerge, the x2-threshold was set at the .90 significance level and constrained to create no more than 7 intervals. The results have a standard deviation of 0.5% for the glass data and 0.2% for the thyroid data; thus, the im- provement of ChiMerge and D-2 over the simple meth- ods is statistically significant. Glass Thyroid Algorithm (u = 0.5%) (u = 0.2%) -ChzMerge 9.8 o D-d 30.2 % 10.2 % Equal-width-intervals 33.3 % 18.3 % Equal-frequency-intervals 35.7 % 16.4 % Figure 3: Error rates Discussion A very important characteristic of ChiMerge is ro- bustness. While it will sometimes do slightly worse than other algorithms, the user can be fairly confident that ChiMerge will seldom miss important intervals or choose an interval boundary when there is obviously a better choice. In contrast, the equal-width-intervals and equal-frequency-intervals methods can produce ex- tremely poor discretizations for certain attributes, as discussed earlier. Another feature is ease of use; while discretization quality is affected by parameter settings, choosing a x2-threshold between the .90 and .99 sig- nificance level and max-intervals to a moderate value (e.g., 5 to 15) will generally produce a good discretiza- tion (some qualifications are discussed later). A major source of robustness is that unlike the simple methods, ChiMerge takes the class of the examples into consider- ation when constructing intervals and adjusts the num- ber of intervals created according to the characteristics of the data. In addition, ChiMerge is applicable to multi-class learning (i.e., domains with more than two ‘Obtained from the University of California-Irvine in- duction database repository: ml-repository@ics.uci.edu. classes-not just positive and negative examples). An- other benefit of ChiMerge is that it provides a concise summarization of numeric attributes, an aid to increas- ing human understanding of the relationship between numeric features and the class attribute. One problem with ChiMerge is a tendency to con- struct too many intervals due to the difficultly in dis- tinguishing between true correlations and coincidence. The role of the x2 statistic is to help determine whether the difference in relative frequencies between adjacent intervals reflects a real relationship between the nu- meric attribute and the class attribute or is the re- sult of chance. The x2-threshold parameter presents a trade-off. Setting higher values reduces the likeli- hood of false intervals; however, if the threshold is set too high, intervals representing real phenomena will also be eliminated. In general, it’s probably not very harmful to have a few unnecessary interval bound- aries; the penalty for excluding an interval is usually worse, because the classification algorithm has no way of making a distinction that is not in the data pre- sented to it (such as occurs in the drinking age ex- ample in the introduction). To illustrate the difficulty of avoiding spurious intervals, a simple test was con- ducted in which randomly generated data was given to ChiMerge. Therefore, ideally, ChiMerge should not produce any interval boundaries, since any found are known to be false. However, the x2-threshold parame- ter generally had to be set to a very high value (above the .99 significance level) to force it to eliminate all intervals. While the x2 statistic is general and should have nearly the same meaning regardless of the number of classes or examples, ChiMerge does tend to produce more intervals when there are more examples. One reason is that when there are more examples there are simply more opportunities for coincidences to occur. Another important factor is that real phenomena will be more likely to pass the significance test as the num- ber of examples increases. For example, if the true dis- tributions of one region is 80% positive instances and that of a neighboring region is 60% positive, this differ- ence is unlikely to be detected when there are only 10 examples per region, put probably would pass the x2 test when there are more than 100 examples per region. This problem is controlled by using the max-intervals parameter to place an upper limit on the number of intervals ChiMerge is allowed to create. One difficulty with using the x2 statistic is that it can be unreliable (misleading) when the expected fre- quency (denoted EQ in the formula) of any of the terms is less than about 1.0. When this occurs, there is a ten- dency for the resultant x2 value to over-estimate the degree of difference. This bias has been partially alle- viated by altering the x2 formula so that the denom- inator of every term of the x2 formula has a value of at least 0.5 (to avoid dividing by a very small number, which produces an artificially large x2 value). This modification, despite its aesthetic shortcomings, seems 126 Learning: Inductive to work quite well. In any case, this is usually not an important problem since intervals containing few examples, where this bias is most prevalent, will still result in x2 values below the threshold; thus they tend to be absorbed early in the merging process anyway. Another shortcoming of ChiMerge is its lack of global evaluation. When deciding which intervals to merge, the algorithm only examines adjacent intervals, ignoring other surrounding intervals. Because of this restricted local analysis, it is possible that the forma- tion of a large, relatively uniform interval could be pre- vented by an unlikely run of examples within it. One possible fix is to apply the x2 test to three or more intervals at a time. The x2 formula is easily extended, by adjusting the value of the parameter m in the x2 calculation. Computational Complexity The version of ChiMerge described here has a compu- tational complexity, in terms of the number of times that the x2 function is called, of 0(n2), where n is the number of examples2. However, implementation of some simple optimizations can reduce the complex- ity to O(n logn). One source of increased speed is to be more aggressive about merging when constructing the initial list of intervals. In addition, several pairs of intervals, not near each other, could be merged on each iteration. The x2 values could also be cached rather than re-computed each iteration for those intervals not affected. However, the lower bound of ChiMerge is O(n logn)-the complexity of sorting the examples in the initial step of the algorithm-unless some means can be devised to eliminate this step. Limitations ChiMerge cannot be used to discretize data for un- supervised learning (clustering) tasks (i.e., where the examples are not divided into classes), and there does not appear to be any reasonable way to extend it to do so. Also, ChiMerge is only attempting to discover first- order (single attribute) correlations, thus might not perform correctly when there is a second-order corre- lation without a corresponding first-order correlation, which might happen if an attribute only correlates in the presence of some other condition. Future Work A variation of ChiMerge that might be interesting to investigate, would be to modify it to create a general- ization hierarchy of intervals rather than a fixed parti- tion of the number line. This hierarchy would be the binary tree corresponding to the evolutionary history of the intervals as constructed by the algorithm: the root of the tree would be the entire number line, and for every non-leaf node in the tree its children would be the two intervals that were merged to create it. Such 2a non-optimized version of ChiMerge was defined for reasons of clarity an interval hierarchy could be used by symbolic induc- tion methods (such as INDUCE[Michalski, 19831 and OTIS[Merber, 19881) that handle hierarchically defined attributes. The induction algorithm could climb or de- scend the generalization tree as needed to obtain an in- terval of the desired specificity. Another advantage is that the x2-threshold, min-intervals, and max-intervals parameters would become irrelevant. Summary ChiMerge is a general, robust discretization algorithm that uses the x2 statistic to determine interval similar- ity/difference as it constructs intervals in a bottom-up merging process. ChiMerge provides a useful, reliable summarization of numeric attributes, determines the number of intervals needed according to the character- istics of the data, and empirical testing indicates sig- nificant improvement over simple methods that do not consider the class information when forming intervals. Breiman, L.; Friedman, J. H.; Olshen, R. A.; and Stone, C. J. 1984. Classification and Regression Trees. Wadsworth, Belmont, CA. Catlett, J. 1991. On changing continuous attributes into ordered discrete attributes. In European Working Session on Learning. Fisher, R. A. 1936. The use of multiple measurements in taxonomic problems. Ann. Eugenics 7(2):1’79-188. Kerber, R. 1988. Using a generalization hierarchy to learn from examples. In Fifth International Conference on Ma- chine Learning, Ann Arbor, MI. Morgan Kaufmann. 1-7. Kerber, R. 1991. Learning classification rules from exam- ples. In Worlcshop Notes of the AAAI-91 Workshop on Knowledge Discovery in Databases. 160-164. Michalski, R. S. 1983. A theory and methodology of in- ductive learning. In Michalski, R. S.; Carbonell, J. G.; and Mitchell, T. M., editors 1983, Machine learning: An arti- ficiaZ intelligence approach. Morgan Kaufmann, Los Altos, CA. Quinlan, J. R.; Compton, P. J.; Horn, K. A.; and Lazarus, L. 1987. Inductive knowledge acquisition: a case study. In Quinlan, J. R., editor 1987, Applications of Expert Sys- terns. Addison- Wesley, Sydney. 157-l 73. Quinlan, J. R. 1986. Induction of decision trees. Machine Learning 1~81-106. Rumelhart, D. E. and McClelland, J. L. 1986. ParaZZeI Distributed Processing, volume 1. MIT Press, Cambridge, MA. Schlimmer, J. 1987. Learning and representation change. In Sixth National Conference on Artificial Intelligence, Los Altos, CA. Morgan Kaufmann. 511-515. Weiss, S. M.; Galen, R. S.; and Tadepalli, P. V. 1990. Maximizing the predictive value of production rules. Ar- tificial Intelligence 45147-71. Kerber 127 Appendix The appendix shows ChiMerge discretizations for the iris classification domain (with x2 threshold = 4.61, the .90 significance level). In the histogram figures, blank lines show where ChiMerge placed interval boundaries. The numbers on the left represent attribute values and the symbols to their right represent single instances with that particular attribute value, coded as follows: “*” = setosa, “0” = uersicolor, and “e” = virginica. The tables summarize the information in the histograms. Each row represents one interval. The Interval column shows the lower bound of each interval. The Class frequencies show how many of each class are in that interval (the order is setosa, versicolor, virginica 2 . The x2 column shows the result of computing the x2 value for each adjacent pair of intervals; the higher the x value the greater the belief that the difference between the two intervals is statistically significant. Sepal width 2.0 lo 2.1 1 2.2 loo. 2.3 boo0 2.4 1000 2.5 looooorro 2.6 looorr 2.7 looooooooo 2.6 (000000oooooooo 2.9 I*ooooooore 3.0 ~000000001*aeo*ee*e~* 3.1 ~ooorerr 3.2 ~oooaeoro 3.3 &korrr 1.0 Petal length Class Interval frequencies 2 1.0 1 Y 1 2.5 1 25 20 5.0 3.0 18 15 24 17.1 3.4 30 1 5 24.2 Petal width 0.1 I- 0.2 k 0.3 I- 0.4 ikhkk4-k 0.5 I* 0.6 I* 0.7 1 0.8 1 0.9 1 1.0 ~0000000 1.1 loo0 1.2 ~00000 1.3 ~0000000000000 1.4 (0000000. 1.5 ~00000000000~ 1.6 loooo 1.7 loo ::: 2.0 2.1 2.2 2.3 2.4 2.5 (0ooooooooooo (0.0.. ~0.00.. I.00000 1.0. IOOOOOOOO 1.0. 1.0. Class Interval frequencies 2 0.1 NJ 0 0 1.0 0 23 0 78.0 1.4 0 21 5 59 - 1.8 0 1 45 48.4 3.1 i 3.2 1 3.3 loo 3.4 i 3.5 loo 3.6 lo 3.7 lo 3.8 lo 3.9 lo00 4.0 [ooooo 4.1 lo00 4.2 loooo 4.3 loo 4.4 loo00 4.5 joooooooo 4.6 1000 4.7 looooo 4.8 looor 4.9 l00.0. 5.0 l0.0. 5.1 loooororr 5.2 (00 5.3 I.0 5.4 i00 5.5 I.00 5.6 joooooo 5.7 IO.0 5.8 IO.0 5.9 I.0 6.0 1.0 6.1 I... 6.2 1 6.3 I. 6.4 ir 6.5 1 6.6 IO 6.7 1.0 6.6 I 6.9 i0 Class Interval frequencies I l.U 5u 0 u 3.0 0 44 1 95.0 4.6 0 6 15 37.3 5.2 0 0 34 10.9 128 Learning: Inductive | 1992 | 29 |
1,220 | {trmurray, bev}@cs.umass.edu We have developed and evaluated a set of tutor construction tools which enabled three computer- naive educators to build, test and modify an in- telligent tutoring system. The tools constitute a knowledge acquisition interface for representing and rapid prototyping both domain and tutoring knowledge. A formative evaluation is described which lasted nearly two years and involved 20 stu- dents. This research aims to understand and sup- port the knowledge acquisition process in educa- tion and to facilitate browsing and modification of knowledge. Results of a person-hour analysis of throughput factors are provided along with knowl- edge representation and engineering issues for de- veloping knowledge acquisition interfaces in edu- cation. This research addresses issues of scaling up and shak- ing down the tutor conseruction process. It asks how educators’ concepts of subject, matter and teaching methods can be transformed into a detailed yet Aexi- ble conceptualization consistent with computer based tutoring. We report on the usability and efficiency of a knowledge acquisition interface in the form of a set of tutor construction tools. 3 Our formative evaluation of the tools includes a user-participatory design pro- cess [Blomberg & Henderson, 19901 and a case study of three educators using the tools to develop a knowl- edge based tutor for statics. In this paper we give data suggesting that educators (with with appropriate tools and the assistance of a knowledge engineer) can build a tutor with an effort comparable to that required to ‘This work was supported by the National Science Foun- dation under grant number MDR 8751362 and by External Research, Apple Computer, Inc., Cupertino, CA. 2Murray is currently working in the Interactive Multi- media Group at ABB Combustion Engineering, Research and Technology, Power Plant Laboratory, Windsor CT. 3 Also called MAFITS, Knowledge Acquisition Frame- work for ITS. build traditional computer aided instructional (CM) systems. We report on one of the first evaPuations of a knowledge acquisition interface for a tutor and the first such interface tailored exclusively for use by prac- ticing educators. We expect that only a few master teachers will participate on tutor design teams, but the tools will allow a wide range of educators to easily customize the resulting systems. Our study is not an evaluation of the effectiveness of either a specific tutor or a particular instructional approach. Since this research area is new and few methodological guidelines or prior results exist, it is an “explorae or y” study. We focus on design and knowl- edge acquisition issues of knowledge based tutors, and, though the statics tutor was tested on 20 students, we did not measure student learning, but rather observed how the teacher collected and analyzed data to update the tutor. Other generic shells for AI-based tutoring systems have been built, including SIP [Macmillan et al., 1988], IDE [R ussell et al., 19881, ID Expert [Merrill, 19891 and Byte-sized Tutor [Bonar et al., 19861. These systems are intended to be used by educators or in- structional experts who are not programmers. How- ever, they are focused more on generality than on us- ability. They do not clearly address the issues encoun- tered when educators actually use these systems. Few researchers (none that we know of) have completed a user-based analysis of a generic tutor shell and the as- sociated knowledge acquisition issues. Though we have focused on teachers, the tools for rapid prototyping of ITS domain content and tutoring strategies should also be valuable to industry trainers, instructional design- ers, and educational researchers. ovw e The knowledge acquisition component of this research is similar to other research which addresses techniques for eliciting domain and heuristic knowledge from ex- perts (e.g., [Bareiss, et. al., 1989; Mullarkey, 19901). However, this work focused on several knowledge ac- quisition issues specific to education, beginning with the difficulty of enlisting domain expert participation From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Figure 1: Topic Net Editor, Showing Part of the 41-node Statics Topic Network in the process of building teaching systems. In fact, understanding, acceptance and use of AI research by educators has been much slower than research progress [Clancey & Joerger, 19881, due in part to the lack of tools for constructing these programs. Increased coor- dination between domain experts and evolving tutors is needed because the insights, principles and rules built into these systems should originate from a rich synthe- sis of the experience of practicing teachers, learning and instructional theories, and on-line experimenta- tion. Yet, complex knowledge bases present a tremen- dous challenge to domain experts and knowledge engi- neers, and often results in causing them to be lost in data space [Carroll et al., 19901 or to make inappro- priate or ineffective changes [Terveen and Wroblewski, 199oJ. In this paper we discuss design principles and give results of a quantitative nature regarding the design of a physics tutor using the development tools, e.g., How much effort is required to build a knowledge based tutoring system?4 Design principles for a visual knowledge editor. The tutor construction tools are an example of a visual 41n [Murray & Woolf, 19921 we describe our tutor design process, and how the development tools were used to assist in this process. The representational framework and stu- dent model are described in [Murray & Woolf, 19901, and in [Murray, 19911 we discuss issues for representing curriculum and tutoring strategy knowledge, and how the conceptual models and cognitive limitations of the practicing teacher affect his/her ability to conceptualize curriculum and the instructional processes. 18 Explanation and Tutoring knowledge editor, here defined as a system which makes knowledge visible and communicable. Such an inter- face is based on the highly asymmetrical abilities of people and computers [Terveen and Wroblewski, 19901 and is designed to reduce cognitive load on human working memory and to reify a person’s underlying do- main knowledge structure. Such an editor in an educa- tional application should visualize domain knowledge and tutoring heuristics and communicate complex con- ceptual relationships instantiating an educator’s men- tal model of a domain. We found a number of design principles which were key to the usability of the tools. The interface for a knowledge based tutor authoring system should: 1. 2. 3. 4. 5. 6. 7. Provide the user with a clear and accurate cognitive model of the underlying framework; Make it hard for the user to inadvertently change the knowledge base; Give feedback on the operation just completed; Help the user “self-locate” and “navigate” within the knowledge base; As much as possible, anticipate the cognitive capa- bilities and limitations of the typical user; Provide features which reduce cognitive load on working memory (by reifying information and struc- ture) and long term memory (by providing re- minders) ; Allow the user to view (static) knowledge base in multiple ways and to view relationships between items; 8. 9. 10. 11. Provide ‘monitors’ which allow the user to view the changes in dynamic processes and data structures; Provide on line assistance and reference information; Facilitate opportunistic (i.e. top down and bottom up) design by not forcing the ‘user to make decisions in a rigid order; Allow quick movement and iteration between test and modification. .esearch Goals and Methodology. Our goals ere to identify effective knowledge acquisition inter- face components and to research the process of working with educators to build domain and tutoring strat- egy knowledge-bases. In order to identify interface components, we maintained a sixteen month user- participatory design methodology along with an iter- ative design/formative evaluation, i.e., design and im- plementation were iterative and concurrent with use by a domain expert and two “knowledge base managers” (see below). This ‘participatory design’ methodology supported considerable teacher involvement in the con- struction of the system and shifted the role of educa- tors from software ‘users’ or research ‘subjects’ to co- researchers or co-developers [Blomberg & Henderson, 1990; Whiteside et al., 1988].5 To research the process by which educators can de- sign, modify and evaluate a tutoring system we used the case study methodology. The work reported here describes the methodology used as well as a portion of the data collection, results and analyses. The partic- ipants were three educators who had little or no pro- gramming experience before the project: one exem- plary high school physics teacher took on the role of domain expert,6 and two education graduate students took on the role of knowledge base managers, re- sponsible for the initial entry of curriculum content, for non-content-specific debugging of the knowledge base, and for the supervision of student test runs. The first author acted as knowledge engineer. The three partic- ipants suggested changes to the system and saw those changes manifest. The experimental data included 93 pages of field notes (in which the knowledge engineer recorded information and impressions from interviews with the domain expert and observations of system use), a daily record of all code changes, data files trac- ing knowledge base editing sessions and student tuto- rial sessions, post-session interviews with students, and a post-study interview with the domain expert. esu1ts of Case situ Brief description of the tutor. The tutor was de- signed to convey a qualitative, intuitive understanding 5 See [Murray, 19911 for a discussion of how user partic- ipation affected the design of the tools. 6Dr. Charles Camp is a physics teacher at the Amherst Regional High School, Amherst, Massachusetts. We will refer to him as the “domain expert” or “teacher.” of relationships among forces in static (non motion) situations [Murray & Woolf, 19901. Its objectives in the area of linear equilibrium, for instance, are for a student to predict the motion or non-motion of ob- jects with forces exerted on them and to isolate the X and Y components of forces in static situations. Fig- ure 1 shows a portion of the curriculum. The tutor is able to diagnose and remediate several common physics misconceptions, including the belief that stationary or solid objects do not exert forces, and confounding the forces acting on an object with the forces exerted by an object. The tutor asks qualitative questions about real-world objects and situations. Additionally, an in- teractive “crane boom simulation” can be presented, allowing the student to manipulate connected objects and to observe resulting force magnitudes and vectors. The student can interrupt the tutorial session at any time, skip or repeat the current presentation, explore and inquire freely, change the teaching style, ask for hints, definitions, explanations, etc., or visit another part of the curriculum. St-, en Develmt Training Total 1. Introd -- - -uction 0 3.5 3.5 n 2. I &~;“eh- 19 G9 I 1129 _ d&I&U ““A &AL .LY “.Y .G”.Y n 3. I Class. Scriot I 9 I 5 II 14 tl 4. Topic Net 9 5 14 5. CAI Script 45 5 50 6. Strategies 7 3 10 7. w nn c 1 Impleme 0 Totals r all 1 414 1 42.1 11 bll u steps l-4, 6) 37 23.7 59.7 nt. (5, 7-10) 438 19 457 -1- I 1”. aam ” w.c) Figure 2: Person-hour Analysis for Building the Statics Tutor Analysis of the curricullum and knowledge base. The driving questions for the quantitative analysis of the data were: How can the size and structure of the knowledge base be measured to allow for comparative analysis of knowledge bases from different knowledge based tutors? How much effort is required by each participant in each step of designing the statics tutor? Approximately how much time did it take (per hour of instruction and per curriculum topic) to design the statics tutor? Instructional units such as ‘topics’ and ‘lessons’ can have different meanings for different knowledge based tutoring systems, and system-independent metrics are Murray and Woolf 19 needed to compare terminology and the size and com- plexity of tutors. We propose three such metrics: stu- dent tasks per instructional unit,? curricukm links per instructional unit, and transactions per instructional unit. Transactions are defined as the smallest func- tional unit of discourse, such as a motivation para- graph, an explanation, a question, a hint, etc. The av- erage number of student tasks per instructional unit is a rough indication of the amount of interaction in a tu- toring system. The ‘curriculum links per instructional nnit’ (links per topic network node in our system) is an indication of curriculum interconnectedness and com- plexity. The average ‘transactions per instructional unit’ (transactions per topic in our system) gives a rough indication of the amount of content represented by an instructional unit. The total number of trans- actions is a relatively system-independent metric for comparing the size of tutor knowledge bases encoded within different representational frameworks. The following metrics were calculated for the statics tutor knowledge base (see [Murray 19911 for a more thorough analysis):8 8 Average presentations (student tasks) per topic (instructional unit): 3. e Average curriculum links per topic (instruc- tional unit): 1.2. e Average transactions per topic (instructional unit): 12. Though we have not yet performed a detailed com- parison of our curriculum knowledge base with those from other systems, we used these characteristics to compare the linear equilibrium part of the statics cur- riculum (the 25% that was tested with students) to the entire curriculum so that we could justify extrapolat- ing some data from the linear equilibrium portion to the entire curriculum. Productivity analysis. Figure 2 shows a person- hour analysis for the various steps in designing the statics tutor. It is organized with project steps in the columns and project activities in the rows. Project steps include design, e.g., brainstorming, classroom script design, topic network design, tutoring strategies design, and implementation, e.g., generating a CAI- like script, completing work sheets, data entry, debug- rA student ‘task’ is an activity (question, request, etc.) that the tutor gives to the student. These are represented by ‘presentations’ in our system. An ‘instructional unit’ is any unit of chunking content, and will differ according to the tutoring system, e.g. topic, lesson, concept, rule, etc. ‘Topics’ are the main instructional unit for our system. ‘Other characteristics were determined. The topic net- work contains 41 nodes (39 topics and 2 misconceptions), each topic representing (very roughly) about 9 minutes of instruction. There were 252 curriculum objects in the knowledge base, including 81 presentations and 48 pictures. 20 Explanation and Tutoring ging the knowledge base, and student trial runs (see [Murray, 19911 f or a description of each design step). Within each step there are two kinds of ‘activities:’ development (including production and guidance) and training. These numbers do not include the following: the effort spent programming the simulation, the ef- fort spent (by an artist) creating graphic illustrations, nor the time to build the development tools. Some of the figures are based on estimates and our numerical analysis is only intended to give order of magnitude figures. We believe the figures can be used to es- timate production time for similar projects using the tutor construction tools. We analyzed the productivity data in several ways (see Figure 3”), including: as a function of design step (design vs. implementation), as a function of design activity (training vs. development), and as a function of participant role (domain expert vs. knowledge en- gineer and knowledge base manager). Following are some summary figures from this analysis: Total design time for the 6-hour curriculum was 596 hours, or about 15 hours per topic. The effort per hour of instruction time was about 100 hours (the entire curriculum represents about six hours of teaching). Factoring out training, it took about 85 hours per hour of instruction. The domain expert’s time was about the same as the knowledge base manager’s time, and the knowledge engineer’s time was about one third of the others. The knowledge engineer’s effort represented about 15% of the total effort. Implementation was about six times the effort of de- sign, i.e. design was about 15% of the total effort. Training took about 15% of the total effort. Most of this training was one-time training that would not have to be repeated for the next tutor built by the same team. The training required for the knowl- edge base managers was small, taking only one sixth as much time as the domain expert’s training (see [Murray, 19911 f or a discussion of training content). We also analyzed such things as the average time to enter curriculum information to create a new object in the knowledge base (25 minutes), and the aver- age time for making knowledge base modifications during test runs (6 minutes). Over the course of the project we saw a two- fold increase in efficiency using the knowledge base Browser. We can not determine, however, how much of this change was due to improvements in the knowl- edge base and how much was due to increased user experience. “The sum of the time for the domain expert and knowl- edge base manager from Figure 3 corresponds to the grand total in Figure 2. Figure 2 does not include the knowledge engineer’s time. Domain Expert KB Managers Knowledge Engineer All Total Tram. Devel. Tram. Devel. Tram. Guidance Tram. Devel. Design 22.7 36.8 0 0 22.7 3.7 46 40.5 86.5 Implem. 14 203 6 234 20 32 40 469 509 Totals 36.7 240 6 234 42.7 35.7 86 510 596 277 240 79 596 Figure 3: Time vs. Participant Role The most interesting figure is the 85 hours of devel- opment effort per hour of instruction. This number must be interpreted cautiously, in part because it is based on a single case, and in part because ‘an hour of instruction’ has questionable meaning as a metric in highly interactive computer based instruction that tailors content according to individual students. How- ever, it seems to be the best metric we have thus far, and as a benchmark, the results are very encouraging, being an order of magnitude better that what had been previously proposed for knowledge based tutor devel- opment time. It compares quite favorably with the es- timated 100 to 300 hours required to build traditional CA1 [Gery, 19871. Additionally, construction time for tutor development beyond the first hours might be sig- nificantly reduced after the initial curriculum is built, since generic rules for representing pedagogy, student knowledge and dialogue can be re-used and existing domain knowledge can be presented from different per- spectives. On the other hand, CA1 is not “generative” and instruction time still requires multiple hours devel- opment time for multiples hours of on-line instruction since each interaction and each new screen must be encoded explicitly by the author. a tor constru@tion Tools This section briefly describes components of the con- struction tools, indicating first the needs of the users and then the functionality of the components. Domain experts require support in locating relevant informa- tion quickly and adding new information effectively, in harmony with existing representation conventions. Ef- fective interfaces must make concepts and structures within the framework visually apparent. Experts also need to notice, modify and save incremental changes to the knowledge base or tutoring strategies. We de- scribe two types of tools: editing tools, used to inspect and modify static component of the knowledge base; and monitoring took, which allow the user to visually trace the current state of the dynamic components of the system during tutorial runs. Several of the tools serve as both editing tools and monitoring tools. Editing tools. The Tutor Strategy Editor allows multiple tutoring strategies to be created and modi- fied as editable graphic procedural networks [Murray & Woolf, 19911. Figure 4 shows the strategy “Give Follow up” being modified. Creating, deleting, repo- sitioning and testing nodes and arcs is done by click- ing on a node or arc and using a menu of operations. The Tutoring Strategy Editor traces the flow of control through the networks during trial runs of the tutor so the educator can observe strategy choices by the tutor and action choices within a single strategy. This facili- tates modification of tutoring strategies and provides a concrete visualization of what can be, at times, a com- plex control structure. We are just beginning to work with experts to modify tutoring strategies and have no results as yet. ml.-cORRLcl WIND RNSW-WRONG) lU.L-CORRECl 9 nNslu-OF, I PU-lURONG cl lELL-CORAECl Figure 4: Tutoring Strategy Editor The Domain Browser supports a domain expert in viewing and editing textual domain information (see Figure 5). All three tables of the figure, Object Type, Instance, and Slot, scroll through an alphabetical list- ing of available elements. The figure shows the teacher examining the Hints slot of a presentation he named LE-Intuition-Easyl. Below the three tables are three pop-up operations menus, one for each table, which allow the user to copy, edit, test, browse, and view components of the knowledge base. The large win- dow at the bottom allows standard operations, such as Murray and Woolf 21 Figure 5: The Domain Knowledge Browser viewing, copying, creating, editing, and deleting. The Topic Network Editor (see Figure 1) is used to define and graphically view domain topics and their re- lationship to each other. It is similar to a curriculum network or concept network. If this editor is active dur- ing a trial tutor session, domain topics are highlighted to monitor the tutor’s traversal of the curriculum. Monitoring Tools. Session monitoring tools are in- valuable in helping educators understand the progress of a tutorial session in terms of curriculum traver- sal, flow of control through tutoring strategies and changes in the student model. The Topic Net Edi- tor and Strategy Editor function as editing tools and monitoring tools. lo Other session monitoring tools in- clude an Event Log, a Topic Level Display and sta- tus/achievement reports on students which can be used by the educator to evaluate presumed areas of strength and weakness or to determine advanced or remedial needs for non-computer parts of the course. Lessons Learned This research focused on understanding and support- ing knowledge acquisition/editing activities for build- ing educational knowledge bases. It addressed issues around tuning a knowledge acquisition interface to the special needs of educators to tease apart knowledge of what they teach and how they teach it. Several lessons were learned and several principles were confirmed: 1. Educators can become an integral part of develop- ment of a knowledge based system and their ex- pert hands-on participation can be made practical through supportive interface tools. ‘“The current topic is highlighted in the Topic Net Editor amd the current action is highlighted in the Strategy Editor. 22 Explanation and Tutoring 2. 3. 4. 5. 6. An intelligent tutor curriculum can be developed with an effort comparable to that required to de- velop a CBT system and additionally the tutor has the benefits of a knowledge-based system. Expert educators’ mental models of curriculum tend to be procedural in nature, and this tendency should be addressed in their training and in the tools used to build the declarative knowledge bases of tutors. An interface using widespread and well designed Macintosh standard pointing and clicking tools is simple enough to reveal the underlying knowledge representation of the tutor and yet expressive enough to enable expert educators with differing back- grounds to tease apart their domain and tutoring knowledge. In this sense the interface representa- tion lies midway on a simplicity-expressiveness con- tinuum [Mullarkey, 19901. Session-tracking and tracing mechanisms reassure computer-naive experts that they can follow the im- pact of system changes without loosing sight of the flow of control through the curriculum or tutoring strategies. They can experiment without “breaking” the system and this enticed experts to become more involved, resulting in a better tutoring system. [Gould, 19881 observes that “developing user- oriented systems requires living in a sea of changes [and therefore] development is full of purprises.” A user-participatory design process is crucial to de- signing an interface that includes what users need and does not include what they find extraneous. Also, seeing domain experts as collaborators and co- experimentors rather than subjects or clients adds depth and richness to the design process and prod- uct. 7. Working on a knowledge based system benefits ed- ucators. Experts we worked with (both within and outside this case study) have commented that they have a better understanding of the structure of the domain and of students reasoning and misconcep- tions as a result of designing a tutoring system. Contributions and Future This research focused on the need for communica- tion and collaboration between educators and soft- ware engineers or scientists evolving large and complex knowledge-based systems for tutoring. Programmers can not act in isolation to construct knowledge-based systems by encoding sequences of operations that per- form certain goals. Rather, computer-naive domain experts will need to be involved for great lengths of time to develop and maintain specialized knowledge bases. This research provided a case study of one such development process. This research has contributed to the important is- sue of facilitating educator collaboration in building tutoring systems by: 1) placing highly usable tools in the hands of practicing educators; 2) drawing educa- tors into the development process as domain experts; 3) documenting a user-participatory iterative design process; and 4) evaluating a qualitative case study of tutor knowledge base development. Time and resource requirements for building a knowledge base were ana- lyzed including construction time per topic, per partic- ipant, per activity (e.g., data entry vs. bug detection) and per construction goal (e.g., design vs. implemen- tation). Several principles of a visual knowledge editor were articulated along with a description of a knowl- edge acquisition interface built based on those princi- ples. Since this work was a case study, the results are sug- gestive and descriptive rather than conclusive. Also, since the study involved a fairly curriculum-based model of instruction (and our tools were tweaked to support this type of model), our results may not be ap- plicable to expert system based tutors such as ‘model tracing’ tutors or coaches. This study represents the “‘exploratory” beginnings of understanding how knowl- edge acquisition tools can be used to involve practic- ing educators in tutor design. Future work includes evaluating the tutoring strategy interface, extending and fleshing out existing tutoring strategies, evaluating the tutor’s ability to choose among alternative strate- gies, and studying their impact on student learning. We also intend to evaluate our approach in a class- room setting, addressing some of the limitations of the construction tool interface by exploring its usability in classroom contexts and with multiple domain experts. In addition, although tutors build with our tools al- low substantial student flexibility and control, we have not yet studied characteristics of the interface that en- courage such control, and nor have we studied whether students will have difficulty utilizing the available op- tions. Finally, we also need to test our approach with diverse instructional domains and pedagogical styles. eferences Bonar, J., Cunnningham, R., & Schultz, J. (1986). An Objcd- Oriented Architecture for Intelligent Tutoring Systems. Proceedinga of OOPSLA-86. Barr&s, R., Porter, B. & Murray, K. (1989). Supporting Start- to-Finish Development of Knowledge Bases. Machine Learning 4: pp. 259-283. Blomberg, .J. L. & Hcndsrson, A. (1990). Rcflectiona on Partic- ipatory Ddgn: Lessons from the Trillium Experience. Proceedinga of The Compute+Human Interface Conference-1990. Carroll, 3. M., Singer, J., Bellamy, R. & Alpert, S. (1990). A View Matcher for Learning Smalltalk. Proceeding8 of the 1990 ACM Conference on Human Factovs in Computing Systems, ACM Presu, pp. 431-437. Clanccy, W. J. & Joerger, K. (1988). A Practical Authoring Shell for Apprenticeship Learning. Intelligent Tutoring Sy#temr-88 Proceedinga, University of Montreal. Gcry, G. (1987). Making CBT Happen. Boston, MA: Wcin- garten Publ. Gould, J. D. (1988). How to Design Usable Systems. In Hr- landrr, M. (Ed.), Handbook of Human-Computer Intrvaction. Am- sterdam: Elsdrr Science North Holland, pp. 272-298. Macmillan, S., Emme, D., & Berkowitz, M. (1988). Instruc- tional Plimnc*rs, Lessons Learncd. In Psotkn, Massey, & Muttcsr (Eds.), Intelligent Tdoring Sgstemr, Lessons Learned, Hillsclalc, NJ: Lawrence Erlbaum Assoc. Merrill, M. D. (1989). An Instructional Design Expert System. Computer-Baaed Inatrxction, 16(3), pp. 95-101. Mullarkey, P. (1990). An Experiment in Direct Knowledge Ac- quisition, Proceedinga Eighth National Conference on Artificial In- telligence, pp. 498-503. Murray, T. (1991). A Knowledge Acquisition Framework Fa- cilitating Multiple Strategies in nn Intelligent Tutor. Ed.D. Diaser- tation, University of Ma.ssachusetts at Amherst, Computer Science Tech. Report 91-95. Murray T. & Woolf, B.P. (1990). A Knowledge Acquisition Framework for Intc,lligfmt Learning Environments. SIGART (Spo- cia.l Interest Group in Artificial Intelligence) Bulletin, 2: 2, pp. 1-13. Murray, T. & Woolf, B.P. (1992). Tools for Teac:her Participa- tion for ITS Dexign. Ppococdings of the ITS-92 confer.ence, Mon- treal. Russrll, D., Moran, T. P., & Jordan, D. S. (1988). The Instruc- tional Design Environment. In Psotka, Massey, & Mutter (Eds.), Intelligent Tutoring Systems: Lessons Learned. Hillsdale, NJ: Lawrence Erlbaum. Suchman, L. (1987). Planr and Situated Action: The Proh- Iem of Human-Machine Communication. Cambridge: Cambridge Press. Terveen, L., and Wroblrwski, D. (1990). A Collaborative Inter- face for Editing Large Knowledge Bases. Proceedingr Eighth Na- tional Conference on Artificial Intelligence, pp. 491-496. Whiteside, J., Brnnett, J., & Holtzblatt, K. (1988). Usability Engineering: Our Experience and Evolution. In M. Helander (Ed.), Handbook of Human- Computer Interaction. Amsterdam: Elseviar Science North-Holland Press. Murray and Woolf 23 | 1992 | 3 |
1,221 | Computer & In Mitsubishi Electric Corporation 5-1-I Ofuna, Kamakura Kanagawa 247, Japan kira@sy.isl.melco.co.jp For real-world concept learning problems, feature selection is important to speed up learning and to improve concept quality. We review and analyze past approaches to feature selection and note their strengths and weaknesses. We then introduce and theoretically examine a new algorithm Relief which selects relevant features using a statistical method. Relief does not depend on heuristics, is accurate even if features interact, and is noise-tolerant. It requires only linear time in the number of given features and the number of training instances, regardless of the target concept complexity. The algorithm also has certain limitations such as non- optimal feature set size. Ways to overcome the limitations are suggested. We also report the test results of comparison between Relief and other feature selection algorithms. The empirical results support the theoretical analysis, suggesting a practical approach to feature selection for real-world problems. The representation of raw data often uses many features, only some of which are relevant to the target concept. Since relevant features are often unknown in real-world problems, we must introduce many candidate features. Unfortunately redundant features degrade the performance of concept learners both in speed (due to high dimensionality) and predictive accuracy (due to irrelevant information). The situation is particularly serious in constructive induction, as many candidate features are generated in order to enhance the power of the representation language. Feature selection is the problem of choosing a small subset of features that ideally is necessary and sufficient to describe the target concept. For many real-world problems, which possibly involve much feature interaction, we need a reliable and practically efficient method to eliminate irrelevant features. Approaches and their problems are discussed in Section 2. 405 N. Mathews Avenue IJrbana, IL 61820, U.S.A. rendell@cs.uiuc.edu Intended to circumvent some of the problems, a new algorithm is described in Section 3. Its detailed theoretical analysis and brief empirical evaluation are given in Sections 4 and 5. Section 4 addresses current limitations and future work. Section 7 concludes. as eir s We assume two-class classification problems. An instance is represented by a vector composed of p feature values. S denotes a set of training instances with size n. P is the given feature set ( fl , f2, . . . 9 fp } . An instance X is denoted by a p-dimensional vector (xl, x2, . x: 9 xp), where xj denotes the value of the feature fj of Typical approaches need a function J evaluates the subset @ of P usi @I is better than @2 if J(3E 1) examine all the training instance O(J), must be at least O(n). es ] or IxSl [Rendell, Cho & Seshu 19891, select relevant features by themselves, using measures such as information gain for J. Hence, one might think that feature selection is not a problem at all. But hard concepts having feature interaction are problematic for induction algorithms [Devijver & Kittler 1982, Pagallo 1989, Wendell $ Seshu 19901. For example, if the target concept is fl @ f2 = 1 and the distribution of the feature values is uniform over { 0, 1) , the probability of an instance’s being positive is 50% when fl = I (f2 = 1). There is little information gain in selecting either of fl or f2 though they are relevant. Since real-world problems may involve feature interaction, it is not always enough to apply concept learners only. 2.2 xhaustive Sear@ One way to select a necessary and sufficient subset is to try exhaustive search over all subsets of F and find the subset that maximizes the value of J. This exhaustive From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. search is optimal - it gives the smallest subset maximizing J. But since the number of subsets of F is 2p, the complexity of the algorithm is O(2p).0(J). This approach is appropriate only if p is small and J is computalionally inexpensive. Almuallim and Dietterich [ 1991 J introduced FOCUS, an exhaustive search algorithm Figure 11. They showed that FOCUS can detect the necessary and sufficient features in quasi-polynomial time, provided (1) the complexity of the target concept is limited and (2) there is no noise. They defined the complexity for a concept c to be the number of bits needed to encode c using their bit- vector representation, and showed that FOCUS will terminate in time O((2p)10g(s - p>,) where s is the complexity of the target concept. But the complexity can be as large as O(2p), for example when all the features are relevant. Since the complexity of the target concept is generally not known a priori , we have to expect as much as 0(2Ppn) time for the worst case when all the subsets of P are to be examined. Moreover, with noisy data, FOCUS would select a larger subset of F, since the optimal subset would not give clear class separation. FoCUS(S, F) For i = 0, 1, 2, .*a ForallEEPofsizei If there exist no two instances in S that agree on all features in @ but do not agree on the class then return E and exit Figure 1 FOCUS 2.3 Heuristic Search Algorithms Devijver and Kittler [1982] review heuristic feature selection methods for reducing the search space. Their SFS(S, F) Is=0 For i=ltod Find a feature fmax E F - E, where J(1E U { fmax), S) = max fE IF-E J(2: u (f), 8) @=@u umax) Return $5 (a) SFS definition of the feature selection problem, “select the best d features from F, given an integer d 5 p” requires the size d to be given explicitly and differs from ours in the sense. This is problematic in real-world domains, because the appropriate size of the target feature subset is generally unknown. The value d may be decided by computational feasibility, but then the selected d features may result in poor concept description even if the number of relevant features exceeds d only by 1. Figure 2 shows Sequential Forward Selection (SFS) and Sequential Backward Selection (SBS) algorithms. These algorithms use a strong heuristic, “the best feature to add (remove) in every stage of the loop is the feature to be selected (discarded).” These algorithm are much more efficient. SFS’s complexity is O( &)-O(J). SBS’s complexity is @($0(J). But the heuristic also causes a problem. These algorithms perform poorly with feature interaction. Interacting features (e.g. in protein folding, parity (Section 5)) may not maximize J individually, even though they maximize it together. 2.4 Feature weight based approaches Research in AI tends not to view feature selection as a distinct problem but rather handles it as an implicit part of induction. The following approaches handle feature selection implicitly. STAGGER [Schlimmer 1987, Schlimmer & Granger 19861 selects source features for constructing a new feature, judging from the feature weights based on their relevance to the concept. However, since the relevance is determined one feature at a time, the method does not work for domains where features interact with one another. SW& 3’) E=P For i = 1 to (p - d) Find a feature fmax E iE, where J(@- (fmax), S) = max J(E - (f}, S) fE E @=IE:- (fmax) Return E (b) SBS Figure 2 Heuristic Search Algorithms 130 Learning: Inductive Callan, Fawcett and Rissland [ 199 l] also introduce an interesting feature weight update algorithm in their case- based system CABOT, which showed significant improvement over pure case-based reasoning in the OTHELLO domain. CABOT updates the weights by asking the domain expert to identify the best case. This dependency on the expert makes the system less autonomous, which is problematic for feature selection. 3 eIief Algorithm Relief is a feature weight based algorithm inspired by instance-based learning [Aha, Kibler & Albert 199 1, Callan, Fawcett dz Rissland 19911. Given training data S, sample size m, and a threshold of relevancy 2, Relief detects those features which are statistically relevant to the target concept. z encodes a relevance threshold (0 I 2 I 1). We assume the scale of every feature is either nominal (including boolean) or numerical (integer or real). Differences of feature values between two instances X and Y are defined by the following function diff. When Xk and yk are nominal, <if Xk and yk are the same> cif xk and yk are different> When Xk and yk are numerical, diff(xk, Yk)=(Xk - yk)/nUk where nUk iS a normalization unit to normalize the values of diff into the interval [0, l] Relief@, m, 7) Separate S into S+ = {positive instances] and S’= (negative instances) w = (O,O, . . . * 0) Fori= 1 tom Pick at random an instance X E S Pick at random one of the positive instances closest to X, Z+ 62 8+ Pick at random one of the negative instances closest to X, Z- E S- if (X is a positive instance) then Near-hit = Z+; Near-miss = Z’ else Near-hit = Z-; Near-miss = Z+ update-weight(W, X, Near-hit, Near-miss) Relevance = .( l/m)W For i = 1 to p if (relevancei 1 t) then fi is a relevant feature else fi is an irrelevant feature update-weight(W, X, Near-hit, Near-miss) Fori= 1 top Wi = Wi - diff(xi, near-hiti)2 + diff(xi, near-missi)2 Figure 3 Relief Algorithm Relief (Figure 3) picks a sample composed of m triplets of an instance X, its Near-hit instance1 and Near- instance. Relief uses the p-dimensional Euclid distance for selecting Near-hit and Near-miss. calls a routine to update the feature weight vecto r every plet and to determine the average weight elevanee (of all the features to the target concept). Finally, Relief selects those features whose average weight (‘relevance level’) is above the given threshold 2. The following theoretical analysis shows that Relief is different from other feature weight based algorithms in that it can handle feature interaction, or that it is more autonomous. esretical nalysis Relief has two critical components: the averaged weight elevance and the threshold 2. ged vector of the value - (xi - (xi- near-missj)2 for e h feature fi over m sample triplets. Each element of levanee corresponding to a feature shows how relevant the feature is to the target concept. z is a relevance threshold for determining whether the feature should be selected. The complexity of Relief is O(pmn). Since m is an arbitrarily chosen constant, the complexity is O(pn). Thus the algorithm can select statistically relevant features in linear time in the number of features and the number of training instances. Relief is valid only when (1) the relevance level is huge for relevant features and small for irrelevant features, and (2) 2 retains relevant features and discards irrelevant features. We will show why (1) and (2) hold in the following sections. ellevance leve Let A be a vector of random ables (Si) such that )2 + (xi - near-missj)2 date-weight function accumulates the value of 6; for each feature over m samples. Vance gives the averaged value of 6i for each feat If fi is a relevant feature, xi and near-hiti are expected to be very close in the neighborhood of contrast, the values of at least one of the relevant features of X and Near -miss are expected to be different. Therefore, near-hiti is expected to be close to xl more often than near-misq to xi, and relevancei= E(6i) >> 0. 1 We call an instance a near-hit of X if it belongs to the close neighborhood of X and also to the same category as X. We call an instance a near-miss when it belongs to the properly close neighborhood of X but not to the same category as X. Mira and Rendell 131 If instead fi is an irrelevant feature, the values of random variables xi, near-hit1 and near-miss1 do not depend on one another. Therefore, (xi - near-hiti) and (Xi - near-missi) are independent. Since near-hiti and near-missi are expected to obey the same distribution,2 E((xi - near-hiti)2) = E((xI - near-missi)2) E(6i) = - E((xI - near-hiti)2) + E((xi - near-missi)2) = 0 relevance; = E(Si) = 0 Therefore, statistically, the relevance level of a relevant feature is expected to be larger than zero and that of an irrelevant one is expected to be zero (or negative)2. 4.2 Threshold z Figure 3 shows that those features whose relevance levels are greater than or equal to 2 are selected and the rest are discarded. Hence the problem to pick a proper value of 2. Relief can be considered to statistically estimate the relevance level 6; for each feature fi, using interval estimation. First we assume all the features are irrelevant (E(&) = 0). z gives the acceptance and critical regions of the hypothesis. acceptance-region = { eil I&-E(&)l<~) = ( 4; I I ei I5 Z } critical-region = ( & I I & - E(6i) I > z ) = { 5; I I ci I > 2 ) If the relevance level of a feature is in the acceptance region of the hypothesis, it is considered to be irrelevant. If the relevance level of a feature is in the critical region of the hypothesis, it is considered to be relevant. One way to determine z is to use Cebysev’s inequality, P(I p - E(p) I I ha(p)) > 1 - l/h2 for any distribution of p where a(p) is the standard deviation of p and h > 0. Since xi, near-hiti, and near-missi are normalized, -1 5 6i I 1. Since fi is assumed to be irrelevant, E(6i) = 0 and therefore O(6i) I 1. Since the relevance level relevancei is the average of 6i over m sample instances, E(relevancei) = 0 and o(relevancei) = o&)/G 5 l/G. Therefore, P(I relevance; I 5 hfi) 2 P(I relevance; I 5 ho(relevance;)) > 1 - l/h2 According to the inequality, if we want the probability of a Type I error (rejecting the hypothesis when it is true) to 2Strictly speaking, the distributions differ slightly. Since Relief does not allow X to be identical with Near-hit, some of their irrelevant feature values are expected to be different. On the other hand, since X and Near-miss are not identical (if there is no noise), all of their irrelevant feature values can be the same at the same time. This asymmetry tends to make E(Si) negative for irrelevant features. be less than a, l/h2 I a is sufficient. Therefore h = 1 / d-- a is good enough. It follows that z = h&=I/lrotm is good enough to make the probability of a Type I error to be less than a. Note that Cebysev’s inequality does not assume any specific distribution of 6i. h can usually be much smaller than 1 / 6 Also, O(6i) can be much smaller than 1 (e.g. for the discrete distribution of (0 : l/2, 1 : l/2), d = 0.707. For the continuous uniform distribution over [0, 11, CT =0.0666). Since we only want z = ha, z can be much smaller than I / 6. While the above formula determines z by a (the value to decide how strict we want to be) and m (the sample size), experiments show that the relevance levels display clear contrast between relevant and irrelevant features [Kira & Rendell’92J. z can also be determined by inspection. 5 Empirical Evaluation In section 2, we discussed three types of past approaches. One is concept learners alone, another is exhaustive search, the third is heuristic search. In this section, we compare Relief with these approaches. ID3 represents concept-learner-alone approach and also heuristic search - a kind of sequential forward search [Devijver $ Kittler 19821, since it incrementally selects the best feature with the most information gain while building a decision tree. Exhaustive search is represented by FOCUS [Almuallim & Dietterich 19911. Figure 4 shows the results of comparing (1) ID3 alone, (2) FOCUS + ID3, and (3) Relief (m = 40,~ = 0.1) + ID3 in terms of predictive accuracy and learning time in a parity domain. The target concept is fI @ f2 = 1. The horizontal axis shows the size of the given feature set P in which only two are relevant features. The results are the averages of 10 runs. The predictive accuracy of ID3 alone was inferior to both FOCUS + ID3 and Relief + ID3. This shows the importance of feature selection algorithms. With noise- free data, both FOCUS -o- ID3 and Relief + ID3 learned the correct concept. FOCUS + ID3 is more effective than Relief + ID3, because FOCUS can select the two relevant features more quickly than Relief. With noisy data, however, the predictive accuracy of ID3 with Relief is higher than with FOCUS. In fact, Relief + ID3 typically learns the correct concept. The learning time of FOCUS + ID3 increases exponentially as the size of P increases, while that of Relief + ID3 increases only linearly. Thus Relief is a useful algorithm even when feature interaction is prevalent and the data is noisy. These results show that Relief is significantly faster than exhaustive search and more accurate than heuristic search. 132 Learning: Inductive z -100 2 E 90 iti 80 u 4 70 60 G ID3 5 ‘O” 5 # Features (a) Tests with noise-free data .?? -- 1 Theoretical Upperbound FOCUS + ID3 5 10 15 # Features (b) Tests with noisy data (10% feature noise) Figure 4 Test Results in Parity Domain Relief requires retention of data in incremental uses. However it can be easily modified for incremental update of relevance levels. Relief does not help with redundant features. If most of the given features are relevant to the concept, it would select most of them even though only a fraction are necessary for concept description. Relief is applicable only to the two-class classification problem. However the algorithm can easily be extended for solving multiple-class classification problems by considering them as a set of two-class classification problems. Relief can also be extended for solving continuous value prediction problems. Insufficient training instances fools Relief. Sparse distribution of training instances increases the probability of picking instances in different peaks or disjuncts [Rendell & Seshu 19901 as Near-hit (Figure 3). It is crucial for Relief to pick real near-hit instances. One way is to give enough near-hit instances for all instances. Another is to apply feature construction [Matheus & Rendell 1989, Rendell & Seshu 1990, Yang, Blix & Rendell 19911. By generating good new features, the number of peaks of the target concept is reduced. Accordingly the same training instances may provide enough near-hit instances to detect relevance of those new features to the concept. These limitations also suggest research directions. Relief is a simple algorithm which relies entirely on a statistical method. The algorithm employs few heuristics, and is less often fooled. It is efficient - its computational complexity is polynomial (O(pn)). Relief is also noise- tolerant and is unaffected by feature interaction. This is especially important for hard real-world domains such as protein folding. Though our approach is suboptimal in the sense that the subset acquired is not always the smallest, this limitation may not be critical for two reasons. One is that the smallest set can be achieved by subsequent exhaustive search over the subsets of all the features selected by Relief. The other mitigating factor is that the concept learners such as ID3 [Quinlan I9831 and PLSI mendell, Cho & Seshu 19891 themselves can select necessary Kira and Rendell 133 features to describe the target concept if the given features are all relevant. More experiments and thorough theoretical analysis are warranted. The experiments should include combining our algorithm and various kinds of concept learners such as similarity-based learners, and connectionist learners. Relief can also be applied to IBL to learn relative weights of features and integrated with constructive induction. Acknowledgements The authors thank David Aha for discussion on IBL algorithms and Bruce Porter for discussion on feature importance. Thanks also to the members of the Inductive Learning Group at UIUC for comments and suggestions. eferences [Aha 19891 Aha, D. W. Incremental Instance-Based Learning of Independent and Graded Concept Descriptions, Proceedings of the Sixth International Workshop on Machine Learning. [Aha 19911 Aha, D. W. Incremental Constructive Induction: An Instance-Based Approach, Proceedings of the Eighth International Workshop on Machine Learning. [Aha, Kibler & Albert 19911 Aha, D. W., Kibler, D. & Albert, M. K. Instance-Based Learning Algorithms. Machine Learning, 6,37-66. [Aha & McNulty 19891 Aha, D. W. & McNulty, D. M. Learning Relative Attribute Weights for Instance-Based Concept Descriptions, Proceedings of the Eleventh Annual Conference of the Cognitive Science Society. [Almuallim & Dietterich 19911 Almuallim, H. & Dietterich, T. G., Learning With Many Irrelevant Features, Proceedings of the Ninth National Conference on Artificial Intelligence, 199 1,547-552. [Bareiss 19891 Bareiss, R., Exemplar-Based Knowledge Acquisition : A Unified Approach to Concept Representation, Classification, and Learning, Academic Press. [Breiman et al. 19841 Breiman, L., Friedman, J. H., Olshen, R. A. & Stone, C. J., Classification and Regression Trees, Wadsworth, 1984. [Callan, Fawcett & Rissland 19911 Callan, J. P., Fawcett, T. E. & Rissland, E. L., CABOT : An Adaptive Approach to Case-Based Search, Proceedings of the Twelfth International Joint Conference on Artificial Intelligence, 199 1,803-808. [Devijver & Kittler 19821 Devijver, P. A. & Kittler, J., Pattern Recognition : A Statistical Approach, Prentice Hall. [Kira & Rendell 19921 Kira, K. & Rendell, L. A., A Practical Approach to Feature Selection, Machine Learning : Proceedings of the Ninth International Conference @IL92), 1992. [Matheus & Rendell 19891 Matheus, C. & Rendell, L. A. Constructive Induction on Decision Trees. Proceedings of the Eleventh International Joint Conference on Artificial Intelligence, 1989,645650. pagallo 19891 Pagallo, G., Learning DNF by Decision Trees, Proceedings of the Eleventh International Joint Conference on Artificial Intelligence, 1989,639-644. [Porter, Bareiss & Holte 19901 Porter, B. W., Bareiss, R. & Holte, R. C. Concept Learning and Heuristic Classification in Weak-Theory Domains, Artificial Intelligence, 45229-263. [Quinlan 19831 Quinlan, J. R. Learning Efficient Classification Procedures and Their Application to Chess End Games. Machine Learning : An Artificial Intelligence Approach, 1983,463-482. [Rendell, Cho & Seshu 19891 Rendell, L. A., Cho, H. H. & Seshu, R. Improving the Design of Similarity- Based Rule-Learning Systems. International Journal of Expert Systems, 2,97-133. [Rendell & Seshu 19901 Rendell, L. A. & Seshu, R. Learning Hard Concepts through Constructive Induction: Framework and Rationale. Computational Intelligence, Nov., 1990. [Schlimmer 19871 Schlimmer, J. C., Learning and Representation Change, Proceedings of the Fifth National Conference on Artificial Intelligence. [Schlimmer & Granger 19861 Schlimmer, J. C. & Granger, R. H. Jr., Incremental Learning from Noisy Data, Machine Learning 1,317-354. [Yang, Blix & Rendell 19911 Yang, D-S., Blix, G. & Rendell, L. A. The Replication Problem: A Constructive Induction Approach, Proceedings of European Working Session on Learning, march, 1991. 134 Learning: Inductive | 1992 | 30 |
1,222 | re its ic s Philip Laird* AI Research Branch NASA Ames Research Center Moffett Field, California 94035 (U.S.A.) laird@pluto.arc.nasa.gov Abstract Learning from experience to predict sequences of discrete symbols is a fundamental problem in machine learning with many applications. We present a simple and practical algorithm (TDAG) for discrete sequence prediction, verify its perfor- mance on data compression tasks, and apply it to problem of dynamically optimizing Prolog pro- grams for good average-case behavior. Discrete Sequence Prediction: A ndamental Problem A few fundamental learning problems occur so often in practice that basic algorithms for solving them are becoming important elements of the machine-learning toolbox. Among these problems are pattern classifi- cation (learning by example to partition input vectors into two or more classes), clustering (grouping a set of input objects into an appropriate number of sets of objects), and delayed-reinforcement learning (learning to associate actions with states so as to maximize the expected long-term reward). Discrete sequence prediction (DSP) is another ba- sic learning problem whose importance, in my view, has been overlooked by researchers outside the data- compression community. In the most basic version the input is an infinite stream of discrete symbols about which we assume very little. The task is to find regu- larities in the input so that our ability to predict the next symbol progresses beyond random guessing. Hu- mans exhibit remarkable skills in such problems, un- consciously learning, for example, that after Mary’s telephone has rung three times, her machine will prob- ably answer it on the fourth ring, or that the word “in- controvertible” will probably be followed by the word “evidence.” The fact that predictions from different in- dividuals are usually quite similar is further evidence that DSP is a fundamental skill in the human learning repertory. *Supported in part by the National Science Foundation (INT-9008726). Consider some applications where DSP plays an im- portant role: Information-theoretic applications rely on a proba- bility distribution to quantify the amount of “sur- prise” (information) in sequential processes. For ex- ample, an adaptive file compression procedure reads through a file generating codes to represent the text using as few bits as possible. Each character is passed to a learning element that forms a probability distribution for the next character(s). As this pre- diction improves, the file is compressed by assigning fewer bits to encode more probable strings. Closely related to file compression are game-playing situa- tions where the ability to anticipate the opponent’s moves can increase a player’s expected score. Dynamic program optimization is the task of refor- matting a program into an equivalent one tuned for the distribution of problems that it actually encoun- ters. As the program solves a representative sample of problems, the learning element examines its de- cisions and search choices in sequence. From the resulting information about program execution se- quences one constructs an optimized version of the program with better average-case performance. Dynamic buflering algorithms go beyond simple heuristics like least-recently-used for swapping items between a small cache and a mass-storage device. By learning patterns in the way items are requested, the algorithm can retain an item in the cache or initi- ate an anticipatory fetch for one that is likely to be requested soon. Adaptive human-machine interfaces reverse the com- mon experience whereby a human quickly learns to predict how a program (or ATM, automobile, etc.) will respond. Years ago, operating systems acquired type-ahead buffering as an efficiency mechanism for humans; if the system can likewise learn to antici- pate the human’s responses, it can work-ahead, offer new options that combine several steps into one step, and so on. Anomaly detection systems are important for iden- tifying illicit or unanticipated use of a system. Such Laid 135 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. tasks are difficult because what is most interesting is precisely what is hardest to recognize and predict. Some AI researchers have approached DSP as a knowledge-based task, taking advantage of avail- able knowledge to predict future outcomes. While a few studies have attacked sequence extrapola- tion/prediction directly, e.g., (Dietterich and Michal- ski, 19SS), more often the problem has been an embed- ded part of a larger research task, e.g., (Lindsay et al., 1980). One can sometimes apply to the DSP problem algorithms not originally intended for this task. For ex- ample, feedforward nets (a concept-learning technique) can be trained to use the past few symbols to predict the next, e.g., (Sejnowski and Rosenberg, 1987). Data compression is probably the simplest appli- cation of sequence prediction, since the text usually fits the model of an input stream of discrete symbols quite closely. Adaptive data compression (Lelewer and Hirschberg, 1987) learns in a single pass over the text: as the program sees more text and its ability to pre- dict the remaining text improves, it achieves greater compression. .The most widely used methods for lin- ear data compression have been dictionary methods, wherein a dictionary of symbol sequences is constantly updated, and the index of the longest entry in the dic- tionary that matches the current text forms part of the code. Less familiar are recent methods that use directed acyclic graphs to construct Markovian models of the source, e.g. (Bell et al., 1990; Blumer, 1990; Williams, 1988). Such models have the clearest vision of the learning aspects of the problem and as such are most readily extended to problems other than data compres- sion. The TDAG algorithm, presented below, is based on the Markov tree approach, of which many variants can be found in the literature. TDAG can, of course, be used for text compression, but our design is intended more for online tasks in which sequence prediction is only part of the problem. One such task, program op- timization, is the original motivation for this research. The TDAG Algorithm TDAG (Transition Directed Acyclic Graph) is a sequence-learning tool. It assumes that the input con- sists of a sequence of discrete, uninterpreted symbols and that the input process can be adequately approxi- mated in a reasonably short time using a small amount of storage. That neither the set of input symbols nor its cardinality need be known in advance is an impor- tant feature of the design. Another is that the time required to receive the next input symbol, learn from it, and return a prediction for the next symbol is tightly controlled, and in most applications, bounded. We develop the TDAG algorithm by successive re- finement, beginning with a very simple but impracti- cal learning/prediction algorithm and subsequently re- pairing its faults. First, however, let us provide some intuition for the algorithm. Assume that we have been inputting symbols for some time and that we want to predict the next one. Suppose the past four symbols were “m th” (the blank is significant). Our statistics show that this four- symbol sequence has not occurred very often, but that the three-symbol sequence ” th” has been quite com- mon and followed by e 60% of the time, i 15% of the time, r and a each lo%, and a few others with smaller likelihoods. This can form the basis for a probabilistic prediction of the next symbol and its likelihood. Al- ternately we could base such a prediction on just the previous two characters “th”, on the preceding char- acter “h”, or on none of the preceding characters by just counting symbol frequencies. Or we could form a weighted combination of all these predictions. If both speed and accuracy matter, however, we will probably do best to base it on the strongest conditioning event ” th” , since by assumption it has occurred enough times for the prediction to be confident. Maintaining a table of suffixes is wasteful of storage since one symbol becomes part of many suffixes. We shall instead use a successor tree, linking each symbol to those that have followed it in context. The Basic Algorithm. TDAG learns by construct- ing a tree that initially consists of only the root node, A. Stored with each node is the following information: 8 symbol is the input symbol associated with the For the root node, this symbol is undefined. node. e children is a list of the nodes that are successors (children) of this node. 0 in-count below. and out-count are counters, explained If v is a node, the notation symbol(v) means the value of the symbol field stored in the node V, and similarly for the other fields. There is one global vari- able, state, which is a FIFO queue of nodes; initially state contains only the node A. For each input sym- bol CC the learning algorithm (Fig. 1) is called. We ob- tain a prediction by calling project-from and passing as an argument the last node u on the state queue for which out-count(v) is “sufficiently” high, in the following sense. Note that the in-count field of a node v counts the number of times that v has been placed on the state queue. This occurs if symbol(v) is input while its par- ent node is on the state queue, and we say that v has been visited from its parent. The out-count field of a node v counts the number of times that v has been re- placed by one of its children on the state queue. If p is a child of V, the ratio in-count(p)locount(v) is the proportion of p visits among all visits from v to its children. It is an empirical estimate of the probability of a transition from the node u to p. The confidence in this probability increases rapidly as out-count(v) increases, so we can use a minimum value for the out-count value to select the node to project from. 136 Learning: Inductive input(x): /* 2 = the next input symbol */ 1. Initialize new-state:= (A). 2. For each node u in state, a Let CL:= make-child(u, x). /* (See below) */ a Enqueue p onto new-stats 3. state:=new-state. make-chiZd(v, x): /* create or update the child of v labeled x */ 1. In the list children(v), find or create the node p with a symbol of z. If creating it, initialize both its count fields to zero. 2. Increment in-count(p) and out-count(v) each by one. project-from(v): /* Return a prob. distrib.*/ 1. Initialize projection:= {}. 2. For each child p in children(v), add to projection the pair [symbol(p), (in-count(fi)/out-count(v))]. 3. Return pro jectioa Figure 1: Basic algorithm. As a simple example (Fig. 2), suppose the string “a b” is input to an empty TDAG. The result is a TDAG with four nodes: A, the root, with two children. The out-count is two. a, the child of A labeled a, created upon arrival of the symbol a. This node has been visited only once, so its in-count is 1. Its only child has been visited once (with the arrival of the b), so its out-count is also 1. b, the child of A labeled b, created upon arrival of the symbol b. Its in-count is 1, but since no character has followed b, it has no children and its out-count is 0. ab, the child of the node a. It was created upon arrival of the symbol b, so its symbol is b. The in-count is 1, and the out-count is 0. The state queue now contains three nodes: A, b, and ab (in that order). These nodes represent the three possible conditional events upon which we can base a prediction for the next symbol: A, the null conditional event; b; the previous symbol b; and ab, the two previous symbols. If we project from A, the resulting distribution is [(a, l/2), (b, l/2)]. We can- not yet project from either of the other two nodes, since both nodes are still leaves. Our confidence in the projection from A is low because it is based on only out-count(A) = 2 events; this field, however, in- creases linearly with the arrival of input symbols, and our confidence in the predictions based on it grows very rapidly. Figure 2: TDAG tree after “a bn input. The num- bers in parentheses are, respectively, the in-count and out-count for the nodes. The basic algorithm is impractical, in part because the number of nodes on the state queue grows linearly as the input algorithm continues to process symbols, and the number of nodes in the TDAG graph may grow quadratically. The trick, then, is to restrict the use of storage without corrupting or discarding the useful information. The time for the procedure input to process each new symbol 2 (known as the turnaround time) is pro- portional to both the size of state and the time to search for the appropriate child of each state node (make-child, step 1). The improvements below will rec- tify the state-size problem; the search-time problem exists because there is no bound on the length of the children list. Therefore, to reduce the search for the appropriate child to virtually constant time, one should implement it using a hash table indexed by the node address Y and the symbol x, returning the address ~1 of the successor of Y labeled by x. The Improved Algorithm. To make the basic al- gorithm practical, we shall make three modifications. Each change is governed by a parameter and requires that some additional information be stored at each node. It is also convenient to maintain a new global value m that increases by one for every input symbol. The changes are: e Bound the node probability. We eliminate nodes in the graph that are rarely visited, since such nodes represent symbol strings that occur infrequently. For this purpose we establish a minimum threshold prob- ability 0 and refuse to extend any node whose prob- ability of occurring is below this threshold. m Bound the height of the TDAG graph. The previ- ous change in itself tends to limit the height of the TDAG graph, since nodes farther from the root oc- cur less often on average. But there remain input streams that cause unbounded growth of the graph (for example, “a a a . . . “). For safety, therefore, we introduce the parameter H and refuse to ex- Laird 137 tend any node v whose height height(v) equals this threshold. Bound the prediction size. The time for project-from to compute a projection is proportional to K, the number of distinct symbols in the input. This is unacceptable for some real-time applications since K is unknown and in general may be quite large. Thus we limit the size of the projection to at most P symbols, P > 1. Doing so means that any symbol whose empirical likelihood is at least l/P will be included in the projection. The first change above is the most difficult to imple- ment since it requires an estimate of Pr(v), the prob- ability that v will be visited on a randomly chosen round. Moreover, we can adopt either an eager strut- egy by extending a node until statistics indicate that Pr(v) < 0 and then deleting its descendents, or a Zaxy strategy by refusing to extend a node until sufficient evidence exists that Pr(v) 2 0. Both strategies re- sult ultimately in the same model. The eager strategy temporarily requires more storage but produces better predictions during the early stages of learning. In this paper we present the lazy strategy. Note that in the basic algorithm the state always contains exactly one node of each height h < m, where m is the number of input symbols so far. Let u be a node of height h; with some reflection it is appar- ent that, if m is 2 h, then the fraction of times that v has been the node of height h on state is Pr(v 1 m) z in-count(v)/(m - h + 1). Moreover, as m ---) 00, Pr(v 1 m) approaches Pr(v) if this limit ex- ists. Since the decision about V’S extendibility must be made in finite time, however, we establish a parameter N and make the algorithm wait for N symbols (tran- sitions from the root) before deciding the extendibility of nodes of height 1. Thereafter, another 2N input symbols are required before nodes of height 2 are de- cided, and so on, with hN symbols needed to decide nodes of height h after deciding those of height h - 1. More symbols are needed for deciding nodes of greater height because the number of TDAG nodes with height h may be exponential in h; a sample size linear in h helps maintain a minimum confidence in our decision about each node, regardless of its height. Note that, with this policy, all nodes of height h become decidable after the arrival of N(l + 2 + . . . + h) = Nh(h + 1)/2 symbols. For the applications described in this paper a node, when marked extendible or unextendible, remains so thereafter, even if later the statistics seem to change. This policy is a deliberate compromise for efficiency. A switch extendible-p is stored with each node. It remains unvalued until a decision is reached as to whether v is extendible, and then is set to true if and only if v is extendible. (See the revised input algorithm in Figure 3.) In the prediction algorithm, we store in each node a list most-likely-children of the I? most likely chil- 138 Learning: Inductive input(z): /* process one input symbol */ 1. rrl :=m + 1. Initialize new-state:= {A}. 2. For each node u in state, 0 Let fl := m&e-chdd(u, r:). e If eatendible?(p), then enqueue p onto new-state. 3. state := new-state. make-child(v, 2): /* find or create a child node */ 1. In the list children(v) find or create the node u with symbol(p) = 2. If creating it, initialize: in-count(p) and out-count(p) := 0, height(p) :=height(v) + 1, and children(p) and most-likely-children(@) := empty. 2. Increment in-count(p) and out-count(v) each by one. 3. Revise the (ordered) list most-likely-children((v) to reflect the increased likelihood of p. E&ePadibte?(p): /*’ ‘Lazy’ ) Version */ 1. If extendible-p(p) is True or False, return its vahre. 2. Else let h = height(@); if m 5 Nh(h+l)/2, then return False. (p is still undecided). 3. If height(p) = H (i.e., p is at the maximum allowed height) or (in-count(p) - 1) < 0. hN (i.e., Pr(p) is below thresh- old), then e extendible-p@) := False. o Return False. 4. Else o extendible-p@) := True. o Return True. Figure 3: Revised input algorithm. dren. Whenever an input symbol causes a node u to be replaced by one of its children p in the state, we adjust the list of u’s most likely children to account for the higher relative likelihood of p. This can be done in time O(P). The algorithm is in Figure 4. Analysis Space permits only the briefest sketch of the analy- sis of the correctness and complexity of the algorithm. The efficiency and space requirements are governed en- tirely by the four user parameters N, 0, N, and P. The turnaround time to process each input symbol is O(H log m). In many practical cases, where the in- put source does not suddenly and radically change its statistical characteristics, the O(logm) factor can be eliminated by “freezing” the graph once the leaf nodes have all been marked unextendible; this occurs after at most 1 + (NH(H + 1)/2) input symbols. The total number of TDAG nodes can be shown to be at most K(1 + H/O), h w ere K is the size of the input alpha- bet. Finally, the turnaround time of the prediction algorithm is O(P logm); again the O(logm) factor is often removable in practice. project-from(u): 1. Initialize projection:= {}. 2. For each child p in most-likely-chilcIren((v), add to projection the pair [symbol(p), in-count(p)/out-count(v)]. 3. Return project ion Figure 4: Revised prediction algorithm Correctness and usefulness are distinct issues. Too many algorithms have been proven correct with respect to an arbitrary set of assumptions and yet turn out to be of little or no practical use. Conversely there are algorithms that appear to perform well without any formal correctness criteria, but the reliability and gen- erality of such algorithms is problematic. Our TDAG design begins with specific performance requirements; hence usefulness has been the primary motivation. But a notion of “correctness” is also needed to ensure that the predictions have a well-defined meaning and to per- mit comparison with other algorithms. Correctness is an extensional property that can- not be discussed without defining the family of input sources. Like many data compression algorithms the TDAG views the input as though it were generated by a stochastic deterministic finite automaton (SDFA) or Markov process. “‘Learning” an SDFA from examples is an intractable problem (Abe and Warmuth, 1990; Laird, 1988), and I am aware of no practical algorithm for learning general SDFA models in an online situa- tion. The TDAG approach is to represent the SDFA as a Markov tree, in which the root node represents the SDFA in its steady state, depth-one nodes represent the possible one-step transitions from steady state, etc. It is not hard to prove that, for any finite, discrete-time SDFA source S, the input algorithm of Figure 1 con- verges with probability one to the Markov probability tree for S. The predictions made by the project-from algorithm of Figure 1, with an input node v of height h, converge to the hth -step transition probabilities from steady state of 5’. The modifications to the basic TDAG version shown in Figures 3 and 4 determine how much of the Markov tree we retain and which nodes of the tree are suitable for prediction. Instead of shearing off all branches uni- formly at a fixed height, the algorithm retains more nodes along branches that are most frequently tra- versed while cutting back the less probable paths. The parameters relate directly to the available computa- tional resources (space and time), rather than to un- observable quantities like the number of states in the source process. Of course, we can never be certain that the input process is really generated by an SDFA or that the parameter choices will guarantee convergence to a close approximation to the input process even when it is an SDFA. Usefulness is a property that can only be demonstrated, not proved. Applications Text compression is an easy, useful check of the qual- ity of a DSP algorithm. The Huffman-code method of file compression (Lelewer and Hirschberg, 1987) uses the predicted probabilities for the next symbol to en- code the symbols; the Huffman code assigns the fewest bits to the most probable characters, reserving longer codes for more improbable characters. The TDAG serves nicely as the learning element in an adaptive compression program: each character is passed to the TDAG input routine and a prediction is returned for the next character. This prediction is used to build or modify a Huffman code, which is kept with each extendible node in the TDAG. To decompress the file one uses the the inverse pro- cedure: a Huffman code based on the prediction for the next character is used to decode the next charac- ter; that character then goes into the TDAG in return for a new Huffman code. For compressing ASCII text, the TDAG parameters were set as follows: H = 15 (though the actual graph never reached this height); P = 120 (since no more than 120 characters actually occur in most ASCII text files); 8 = 0.002; and N = 10. The resulting program, while inefficient, gave compression ratios considerably better than those for the compact program (FGK algo- rithm) and, except for small files, better than those of the Unix compress utility (LZW algorithm). Sample results for files in three languages are shown in Figure 5. Figure 5: Sample File Compression Results. Compres- sion is the compressed length divided by the original length (smaller values are better). Unfortunately, most DSP applications are not so straightforward. Dynamic optimization is the task of tuning a program for average-case efficiency by study- ing its behavior on a distribution of problems typical of its use in production. Sequences of computational steps that occur regularly can be partially evaluated and unfolded into the program, while constructs that entail search can be ordered to minimize the search time. Any program transformations, however, must re- sult in a program that is semantically equivalent to the original. Explanation-based learning is a well-known example of a dynamic optimization method. Adapting a DSP algorithm to perform dynamic op- timization is non-trivial because prediction is only part Laird 139 of the problem. If several choices are possible, we must balance the likelihood of success against its cost. In repairing a car, for example, replacing a spark plug may be less likely to fix the problem than replacing the engine, but still worthwhile if the ratio of cost to probability of success is smaller. I designed and wrote a new kind of dynamic opti- mizer for Prolog programs using a TDAG as the learn- ing element. Details of the implementation are given elsewhere(Laird, 1992), along with a comparison to other methods. Here we summarize only the essen- tial ideas. A Prolog compiler was modified in such a way that the compiled program passes its proof tree to a TDAG learning element along with measurements of the computational cost of refuting each subgoal. After running this program on a sample of several hundred typical problems, I used the resulting TDAG infor- mation to optimize the program. The predictions en- able us to analyze whether any given clause-reordering or unfolding transformation will improve the average performance of the program. Both transformations leave the program semantics unchanged. Next, the newly optimized version of the program was recompiled with the modified compiler, and the TDAG learning process repeated, until no further optimizations could be found. The final program was then benchmarked against the original (unmodified) program. As expected, the results depended on both the pro- gram and the distribution of problems. On the one hand a program for parsing a context-free language ran more than 40% faster as a result of dynamic opti- mization; this was mainly the result of unfolding recur- sive productions that occurred with certainty or near certainty in the sentences of the language. On the other hand a graph-coloring program coding a brute- force backtracking search algorithm was not expected to improve much, and, indeed, no improvement was ob- tained. Significantly, however, no performance degra- dation was observed either. Typical were speedups in the 10% to 20% range-which would be entirely satis- factory in a production application. See Figure 6 for sample results. In general, the TDAG-based method enjoys a num- ber of advantages over other approaches, e.g., the abil- ity to apply multiple program transformations, absence of “generalization-to-N” anomalies, and a robustness due to the fact that the order of the examples has little influence on the final optimized program. Conclusions Discrete Sequence Prediction is a fundamental learning problem. The TDAG algorithm for the DSP problem is embarrassingly easy to implement and reason about, requires little knowledge about the input stream, has very fast turnaround time, uses little storage, is math- ematically sound, and has worked well in practice. Besides exploring new applications, I anticipate that future research directions will go beyond the current Average Improvement (%) Program CPU Time Unifications CF Parser 41.1 34.5 List Membership 18.5 17.2 Logic Circuit Layout 4.8 9.5 Graph 3-Coloring 0.20 -1.40 Figure 6: Sample Dynamic program optimization re- sults. rote learning of high-likelihood sequences by general- izing from strings to patterns. This may help guide induction algorithms to new concepts and to ways to reformulate problems. Acknowledgments Much of this work was done during my stay at the Ma- chine Inference Section of the Electrotechnical Laboratory in Tsukuba, Japan. Thanks to the members of the labora- tory, especially to Dr. Taisuke Sato. Thanks also to Wray Buntine, Peter Cheeseman, Oren Etzioni, Smadar Kedar, Steve Minton, Andy Philips, Ron Saul, Monte Zweben, and two reviewers for helpful suggestions. Peter Norvig gener- ously supplied me with his elegant Prolog for use in the dynamic optimization research. References Abe, N. and Warmuth, M. 1990. On the computational complexity of approximating distributions by probabilis- tic automata. In Proc. 3rd Workshop on Computational Learning Theory. Bell, T. C.; Cleary, J. G.; and Witten, I. H. 1990. Text Compression. Prentice Hall, Englewood Cliffs, N.J. Blumer, A. 1990. Application of DAWGs to data com- pression. In Capocelli, A., editor 1990, Sequences: Com- binatorics, Compression, Security, und Transmission. Springer Verlag, New York. 303 - 311. Dietterich, T. and Michalski, R. 1986. Learning to predict sequences. In al., R. S. Michalskiet, editor 1986, Machine Learning: An AI Approach, Vol. II. Morgan Kaufmann. L&d, P. 1988. Efficient unsupervised learning. In Haus- sler, D. and Pitt, L., editors 1988, Proceedings, 1st Com- put. Learning Theory Workshop. Morgan Kaufmann. Laird, P. 1992. Dynamic optimization. In Proc., 9th In- ternational Machine Leurning Conferwzce. Morgan Kauf- mann. Lelewer, D. and Hirschberg, D. S. 1987. Data compression. ACM Computing Surveys 19:262 - 296. Lindsay, R.; Buchanan, B.; and et al., 1980. DEiVDRAL. McGraw-Hill, New York. Norvig, P. 1991. Paradigms of A.I. Programming: Cuse Studies in Common LISP. Morgan Kaufmann. Sejnowski, T. and Rosenberg, C. 1987. Parallel networks that learn to pronounce English text. Complex Systems 1:145-168. Williams, R. 1988. Dynamic history predictive compres- sion. Information Systems 13(1):129-140. 140 Learning: Inductive | 1992 | 31 |
1,223 | Rutgers University Department of Computer Science New Brunswick, NJ 08903 norton@paul.rutgers.edu, hirsh&s.rutgers.edu Abstract This paper presents an approach to learning from noisy data that views the problem as one of rea- soning under uncertainty, where prior knowledge of the noise process is applied to compute a pos- teriori probabilities over the hypothesis space. In preliminary experiments this maximum a posteri- ori (MAP) approach exhibits a learning rate ad- vantage over the C4.5 algorithm that is statisti- cally significant. Introduction The classifier learning problem is to use a set of labeled training data to induce a classifier that will accurately classify as yet unseen, unclassified testing data. Some approaches assume that the training data is correct [Mitchell, 19821. S ome assume that noise is present and simply tolerate it [Breiman et aE., 1984; Quinlan, 19871. Another approach is to exploit knowledge of the presence and nature of noise [Hirsh, 1990b]. This paper takes the third approach, and views clas- sifier learning from noisy data as a problem of reason- ing under uncertainty, where knowledge of the noise process is applied to compute a posteriori probabilities over the hypothesis space. The new algorithm is com- pared to C4.5 (a descendant of C4 [Quinlan, 1987]), and exhibits a statistically significant learning rate ad- vantage over a range of experimental conditions. Terminology Throughout this paper we use the following terminol- ogy to refer to examples and sequences of examples in a noisy environment. An example consists of a sam- ple and a class label. A true exumple is an example whose attributes are correctly given and whose class label is generated by the correct classifier, often called the target concept. A sequence of true examples consti- tutes a true data sequence. True data are not directly *and Siemens Corporate Research, Inc., 755 College Road East, Princeton, NJ 08540. available for learning because a probabilistic noise pro- cess corrupts the descriptions of true examples. Learn- ing therefore must use the corrupted observed data se- quence in place of the unavailable true data sequence. The approach taken in this paper is to make in- formed speculations about the nature of the true data based on observed data. An example that is hypothe- sized to be an element of the true data sequence is re- ferred to as a supposed example. Sequences of supposed examples are supposed data sequences. A supposed ex- ample is in the neighborhood of an observed example if it is possible for the noise process to transform the supposed example into the observed example. A classifier is consistent with a sequence of exam- ples if the classification it gives every example in the sequence matches the class label provided with the ex- ample. Classifiers must be expressed in some represen- tation, and the entire set of all classifiers expressible in the representation and consistent with a sequence of data is known as a version space [Mitchell, 19781. The relation “more general than or equal to” imposes a par- tial ordering on the space of classifiers. Two subsets of a version space make up its boundary-set represen- tation: an S set of its most specific classifiers, and a G set of its most general classifiers. When no classi- fier is consistent with a sequence of data the version space is empty and is said to have collapsed. Version spaces are just sets, and hence can be intersected. This intersection can be computed in the boundary-set rep- resentation [Hirsh, 199Oa]. Computing A Posteriori Probabilities by Modelling Noisy Data This paper presents a Bayesian maximum a posteriori or MAP approach for selecting a best classifier given observed data. Under MAP reasoning, if the true data sequence S* were known, the preferred classifier would be the one maximizing P(Hi]S*). But since the ob- served data sequence 0 is available instead of S* the best classifier maximizes P(Hi]O) instead. This pa- per explores how this best classifier can be determined under the following assumptions: Norton and Hirsh 141 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. A noise model is known that provides the probability that example s is corrupted to observed example o, i.e., P(ols). All classifiers are equally likely a priori, i.e., P(Hi) = P(Hj) for all i and j. The classifier being learned is deterministic, and therefore consistent with the true data sequence, i.e., P(HIS) = 0 if H is not consistent with S. The approach of this paper is to consider all sup- posed sequences Sj that could have given rise to the observed data sequence 0. The classifier consistent with the most likely supposed sequences will be se- lected as best, where the noise model is used to identify the most likely supposed sequences. More formally, let 0 denote the observed data se- quence, Sj a supposed data sequence, and Hi a clas- sifier of interest. Let VS be a function that computes the set of classifiers consistent with a given data se- quence. The a posteriori probability of Hi is evaluated as follows, and as explained below: P(HilO) = P(OIHi)P(Hi>/P(O) (1) CC C P(OSj IHi) (2) = CP(OISjHi)P(Sj IHi) (3) = ~P(OIsj)P(Sj IHi) (4 oc C p(OI%) (5) HiE GS(Sj) Since the desired result of learning is whichever classi- fier Hi has largest value of P( Hi IO), all that is impor- tant is the relative ordering of this value for the various classifiers Hi. Thus, since the constant term P(0) in Equation 1 does not effect the relative probabilities of different classifiers, it can be factored out. P(Hi) is factored out in the same step under the assumption that all classifiers are equally likely a priori. 0 is inde- pendent of Hi given Sj, and hence Hi can be dropped from the first term of Equation 3. Furthermore, the only non-zero terms for P(Sj I Hi) in Equation 4 are the ones for which the supposed sequence is consistent with the classifier. The derivation is completed with the further assumption that each supposed sample is in an equi-probable neighborhood of the corresponding true sample, making the supposed sequences equally likely. 1 ‘If this last assumption is untrue, it is easily ac- commodated during evidence combination, computing ~(QIWW) in place of P(OjSi) in Equation 5 since P(Sjp3;) = P(Sj). 142 Learning: Inductive Incremental Probabilistic Evidence Combination While the analysis of the previous section has described how to compute P(HilO) in theory, finding the clas- sifier with maximum a posteriori probability by enu- meration will usually be intractable. In fact, the form of Equation 5 suggests a way to more efficiently orga- nize this computation by maintaining current beliefs as a list of version spaces and associated probabili- ties. Each element of this list is the pair of a version space VS(Sj ) for some Sj and the associated proba- bility P(OISj). With this representation, to compute P( Hi IO) for some Hi all that is necessary is to scan the list of version spaces and sum the values of P( 0 I Sj ) for which Hi is in VS(Sj ). M oreover, determining the best classifier(s) can be done by inspecting the intersections of the various version spaces and the cumulative sums of the associated P(OISj) for the various VS(Sj) being intersected. Ideally, if the version spaces are mutually disjoint, all elements of the highest rated version space have greatest maximum a posteriori probability and the entire version space can be returned as a result of learning since all its elements have equal posterior probability. Thus far, however, we have neglected to’ discuss how VS(Sj) and P(OISj) are calculated. Because the clas- sifiers consistent with the supposed sequence are also consistent with each supposed example, the version space for sequence Sj can be computed by intersecting those of its components sjk. VS(Sj) = n VS(sjk) k Because the samples are independent of one another, and because the noise model is independently applied, the probabilities can be similarly computed. P(OISj) = p(okjsjk) k These expressions have a convenient structure that al- low belief update equations to be written as recurrence formulae. Let ST = {sjr , . . . , sjm} denote the first m elements of Sj . Let SJT+l = {Sjl, . . . , sjm, s}. Let 0” and O”+l be similarly defined. It follows from the preceding equations that and vS(Sjm+l) = vS(Sy) n W(S) P(O”+1py+l) = P(Orn~S~)P(o~s) Each new example o can be viewed as evidence in the form of pairs VS(s) and P(ols) for every s in the neigh- borhood of o. The new belief is computed by com- bining elements of the current belief (i.e., the current list of version spaces and their associated probabili- ties) and the new evidence pairwise, intersecting ver- sion spaces and multiplying probabilities as specified above. Initially, a belief of 1 is assigned to the version space that contains all classifiers, VS(0). If any version space collapses as a result of evidence combination, it and its associated probability are dropped. In contrast with other batch learning algorithms, e.g. C4.5, this is an incremental evidence combination approach. Although maintaining version spaces arose as a way to avoid computing P(HilO) for the large number of possible hypotheses Hi, representing version spaces has the potential problem of combinatoric explosion-each incremental intersection could double the number of version spaces that are maintained. The extent of the problem depends on the bias in the classifier repre- sentation language-to what extent incorrect supposed sequences yield consistent classifiers versus quickly col- lapsing version spaces. There are several practical ways to curb the growth. In the experiments described be- low, any version space at least 1000 times less likely than the most likely one is pruned, once new evidence is combined with the old. This pruning parameter keeps the number of version spaces to 1000 or less2 Example The previous sections have described somewhat ab- stractly how a classifier could be selected given a model of the noise process. This section makes this more tan- gible by actually carrying the calculation through for a simple example. For this example, the noise process alters the the class of a true example with probability 0.2, i.e., for example s = (x, +), P(0 = (x:, +)ls) = 0.8 and P(o = (2, -)]s) = 0.2. We also assume that data are described with three binary features, each a 0 or 1. Imagine that the first observed example is (010, +) . The noise model says there are only two supposed ex- amples that could have given rise to the observed ex- ample. The true example is either (010, +) (with prob- ability 0.8) or (010, -) (with probability 0.2). Thus the version space consistent with (010, +) is assigned strength 0.8, and the version space consistent with (010, -> is assigned strength 0.2. The boundary-set representations for these version spaces, and their as- sociated probabilities are shown in the first row of Fig- ure 1. 0 denotes the empty concept, i.e. ‘false’. The second observed example is (011, -) . Two sup- posed examples could give rise to it: (011, -) with probability 0.8, and (011, +) with probability 0.2. The second row of Figure 1 contains the corresponding ev- idence. The probability of all supposed sequences (all pairs of of supposed examples) is given in the third row of the figure, with all pairwise intersections of ver- sion spaces and with the products of the corresponding probabilities. As further examples are obtained, this procedure continues, computing the two version spaces for each 2The sizes of the boundary sets that represent a version space have been shown to be a potential difficulty as well [Haussler, 19881. This is discussed further below. Example Evidence Combination o1 = (010, +) [G= {***}, S= {OlO}] + 0.8 [G={l**,*O*,**l},S={0}] ----f 0.2 02=(011, -) [G={l **, *o*, **O}, s= {0)] + 0.8 [G= {M=++, S= {011)] + 0.2 Figure 1: Evidence Combination with Version Spaces example, intersecting them with the version spaces from past data, and assigning the product of the in- dividual probabilities to each result. If an intersection is ever empty, the corresponding supposed sequence is discarded as inconsistent. Conceptually, the result of learning should be deter- mined by checking in which version spaces each po- tential classifier occurs and summing the probabilities, selecting the classifier with greatest summed probabil- ity as the result of learning. However, note that for this particular noise model the two version spaces gen- erated from each observed example are disjoint, and this means that all maintained version spaces will al- ways be disjoint. Thus each classifier will occur in at most one version space and all learning need do is re- turn the version space with greatest probability, since all its elements have maximum a posterior; probability. Experimentd This section describes the initial experimental evalua- tion of our approach using the label noise model of the previous section. Our implementation is in Common Lisp and handles learning from attribute-value data. Numeric attributes are discretized and generalized as ranges. Symbolic attributes can be generalized as dags with elements of the powerset of basic values.3 A series of experiments was performed to investigate the performance of MAP learning on conjunctive con- cepts. The attributes were either 0, 1, or *. Concepts with 6, 8, and 10 attributes were considered. Attribute noise was not used. Rather, uniform label noise levels of O%, 5%, lo%, 15%, 20%, and 25% were used. The 3While the results described below apply only to learn- ing conjunctive concepts like those of the previous section, the approach has been used to learn to recognize DNA pro- moter sequences in E. Coli as well as to learn DNF con- cepts. Although our early results are promising, they are still somewhat preliminary, and further discussion of these applications are beyond the scope of this paper due to space considerations. Norton and Hirsh 143 number of irrelevant attributes was varied between one and one less than the total number of attributes. Each experiment used a setting of these three parameters and performed at least 50 repeated trials. For compar- ison purposes our results are compared to the results of C4.5 on the same data using the same experimental conditions.4 Samples for the positive and negative classes were generated with equal probability. Within a class, sam- ples were chosen according to a uniform distribution. After a correct example was obtained, the class la- bel was corrupted according to the noise probability. Each trial used 500 noisy samples for training and 3000 noiseless samples for testing. Noiseless samples were used to explore whether learning identified the correct concept, not whether it modeled the noise. Generalization scores and storage requirements were recorded at intervals of five processed examples. The generalization scores presented here ‘are the average scores for all the concepts in the version space with the greatest probability. In cases where two or more version spaces were highest ranked, the first version space was arbitrarily selected. To compute generaliza- tion scores for C4.5, the program was run on the ac- cumulated examples whenever a multiple of five was reached. Pruning was enabled, and windowing dis- abled. Figure 2 illustrates the empirical results for the ex- periment with ten features ‘(five of them irrelevant) and 25% label noise. 50 trials were performed. The upper plot displays the average generalization scores for our MAP approach using dense vertical lines, and the aver- age generalization scores of C4.5 using the curve. The middle plot contains significance levels for the hypoth- esis that the technique with the better sample average is in fact better on the average. It shows that our MAP approach is indeed better, significant at about the 0.01 level before 200 examples are processed, and at about the 0.05 level until 400 examples are processed. The bottom graphic contains two curves. The larger one is the average total size of the S and G sets in all ver- sion spaces. The smaller valued curve is the average number of version spaces still being considered. Some general lessons can be abstracted from the full suite of over 100 experiments that were run. (Space limitations make it impossible to include further in- dividual results.) The MAP approach has better av- erage performance than C4.5 on small sample sizes. Before roughly 100 samples are processed the differ- ence in average generalization scores is almost always statistically significant at the 1% level or better. The only exceptions to this rule in the suite of experiments occur when only one or two attributes are relevant. Both approaches are statistically indistinguishable on large sample sizes. However, in some cases the av- erage generalization score of C4.5 meets or exceeds that 4The executable imag e of C4.5 used in this study was supplied by J. R. Quinlan and runs on Sun4 systems. 144 Learning: Inductive Average over Best ML VS & C4.5 with Pruning Samples Significance Levels for IML - C4.51 > 0 Q 5: 0 Storage Requirements & Hypothesis Count for ML 0 Samples Figure 2: 10 Binary Attributes (5 Irrelevant), 25% La- bel Noise of the MAP approach. This never happened for con- cepts with five or more relevant attributes, happened sometimes for concepts with four, and happened fre- quently for concepts with three or fewer relevant at- tributes. The crossover point, where the average per- formance of C4.5 exceeds that of this MAP approach, occurs earlier as the generality of the true concept in- creases. There may be a secondary effect delaying the crossover as the noise rate increases. As a rule, C4.5 performs better when few attributes are relevant. However, a closer examination of the conjunctive language for representing classifiers and the statistics of the test data help clarify this issue. In this problem there is only one perfect classifier, and when three or fewer attributes are relevant all other possible classi- fiers exhibit at least 7% error. Since the difference in asymptotic difference between the MAP approach and C4.5 is only around 1% (e.g., 96% versus 97% correct), this means the difference is not due to consistent iden- tification of a nearly correct concept definition with only small error, but rather, fairly regular convergence to the correct result combined with occasional iden- tification of a result which while syntactically similar exhibits larger error (since results are averaged over 50 trials). In such occasional cases the desired result is in- correctly pruned earlier in learning due to the setting of the pruning parameter. The storage requirements for this implementation are measured as the total of the sizes of the S and G sets being considered at a given time. The primary effect is due to the noise level and stems from the MAP approach. As the noise level rises, probabilities for the class labels approach one another. The result is that probabilities stay closer together and take longer to reach the cutoff threshold. A secondary effect is due to the concept length and the action of the the version space component. As the concept length rises there is a tendency for the total sizes of the S and G sets to rise.5 Related Work Others have discussed probabilistic approaches to learning from noisy data that bear some similarity to our own approach. Angluin and Laird describe an algorithm for learning from data with uniformly dis- tributed class label noise [Angluin and Laird, 19881. The kernel of the algorithm requires an upper bound on the noise rate, and they have given a procedure for estimating it. .A number of examples is computed based on this estimated noise rate bound and several other learning parameters. They show that any con- cept that minimizes the number of disagreements with 5More recent implementations of this work have used the representations of version spaces presented by Smith and Rosenbloom [1990] and Hirsh [1992]. Each eliminates the problem of potential exponential growth in the size of G sets. that many examples is probably approximately cor- rect. Although their paper deals only with label noise, they indicate that the method can also be extended to handle attribute noise. For uniformly distributed label noise, maximum agreement and maximum a posteriori reasoning yield the same results. For non-uniform la- bel noise and for attribute noise maximum agreement and maximum a posteriori are different. Haussler, Kearns, and Schapire derive a number of bounds on the sample complexity of Bayesian learning from noiseless data [Haussler et al., 19911. The Bayes and Gibbs algorithms form the backbone of their anal- ysis. The Bayes approach is a weighted voting scheme that need not behave like any member of the concept description language. It has the lowest probability of error of any classifier, but its evaluation requires enu- meration of a version space of consistent concepts (in the noiseless case) or the entire set of concepts (in the noisy case). For noiseless data, Gibbs chooses one of the consistent classifiers at random, according to the posterior probability distribution. This classifier can be found by enumerating the version space of consis- tent concepts once. If Gibbs were extended to noisy data, it would choose a classifier at random from all the version spaces (including those consistent with the least likely supposed sequences) according to the poste- rior probability distribution that accounts for the noise process. The MAP learning approach described here returns a single concept from the best version space, and can be viewed as an approximation to the Gibbs method. Selecting one such concept can be made de- terministic and tractable if a bias towards specific con- cepts is acceptable, e.g., by simply selecting a concept in the S set without enumerating the elements of any version space. Buntine describes a complementary Bayesian frame- work for empirical learning [Buntine, 19901. He sug- gests that the properties of the learning protocol that supplies the training data be analyzed probabilistically to provide guidance in constructing the learning algo- rithm. The MAP approach is entirely compatible with this recommendation. The main applied focus of Bun- tine’s work, however, is on learning uncertain classi- fiers from noiseless data. This paper focuses instead on learning deterministic classifiers from noisy data. Since our work uses version spaces, it is reasonable to discuss other version-space approaches to learning from noisy data. Mitchell’s original approach was to maintain version spaces consistent with smaller and smaller subsets of the data [Mitchell, 19781. Essen- tially, for each k: from 0 to a small constant K, a version space is computed that contains every concept consis- tent with any n - lc examples from a pool of n (and the remaining I% are effectively ignored). The first problem with this method is under-utilization of observations. Even when a simple noise model is correct and avail- able, observations are ignored. A second problem is that it pools classifiers consistent with likely subsets 145 of data and classifiers consistent with unlikely subsets of data. Convergence to a small set of classifiers will be difficult, especially for large I<, and for weakly bi- ased hypothesis languages. The MAP method sepa- rates the unlikely supposed sequences from the likely ones, avoiding much of this problem. Hirsh eneralizes Mitchell’s candidate elimination al- gorithm ‘i Mitchell, 19781 to permit the combination of version spaces, creating the incremental version space merging algorithm (IVSM) [Hirsh, 199Oa]. Like can- didate elimination, IVSM operates on version spaces in the boundary set representation. Adopting a gen- eralized view of version spaces as any set of concept definitions representable using boundary sets makes it possible to suggest a new *approach to handling noisy examples subject to bounded inconsistency (IVSM-BI) by including extra classifiers inconsistent with the data but not too far off from the observed data. However, to handle label noise the approach is effectively useless. When data are subject to attribute noise, the problem is less severe, but both likely and unlikely classifiers are included in version spaces with equal footing. Closing Remarks In many domains, probabilistic measurement processes and subjective judgements lead to noisy attribute val- ues and class labels. Three approaches have been taken in this regard: assume there is no noise, tolerate the noise, and exploit knowledge of the noise. The last approach is adopted in this paper. It is shown that learning from noisy data can be viewed as a problem of reasoning under uncertainty by incremental evidence combination. It is also shown that probabilistic reason- ing can be usefully applied in an integrated approach to learning from noisy data. The experiments described earlier are limited to the label noise problem for a conjunctive language with binary attributes, but the reasoning under uncertainty approach applies more widely. Other experiments were performed involving both real and synthetic data de- scribed by non-trivial tree-structured attributes. The technique was also applied to problems with attribute noise, where a different evidence representation is re- quired. In each case the test results bear out the useful- ness of the method. The performance of this technique on the well-known Iris flower database is comparable to that of other symbolic learning methods. An approach to learning DNF concepts based on this method has also been implemented. Preliminary test results on learning DNA promoters in E. Coli are encouraging. The experimental results cited so far summarize studies in which the experimental conditions exactly satisfy the assumptions underlying the algorithm, i.e., the noise model is known exactly. In a real situation exact values might be unavailable. A few early ex- periments using the uniform label noise model suggest that the learning procedure is robust with respect to the true noise level, but a thorough study has not been made. The excellent results during early learning (e.g. Figure 2) also indicate robustness, since apparent noise rates need not closely parallel actual noise rates. Re- sults using plausible noise models for the Iris and DNA promoter problems are encouraging on this point too. One of the important questions still to be addressed is how noise models and their parameters are acquired. References Angluin, D. and Laird, P. 1988. Learning from noisy examples. Machine Learning 2(4):343-370. Breiman, L.; Friedman., J.; Olshen, R.; and Stone, C. 1984. Classification and Regression Trees. Wadsworth and Brooks. Buntine, W. 1990. A Theory of Learning Class$ca- tion Rules. Ph.D. Dissertation, University of Tech- nology, Sydney. Haussler, D.; Kearns, M.; and Schapire, R. 1991. Bounds on the sample complexity of Bayesian learn- ing using information theory and the VC dimension. In Computational Learning Theory: Proceedings of the Fourth Annual Workshop. Morgan Kaufmann. Haussler, D. 1988. Quantifying inductive bias: AI learning algorithms and Valiant’s learning framework. Artificial Intelligence 36(2):177-222. Hirsh, H. 1990a. Incremental Version-Space Merging: A General Framework for Concept Learning. Kluwer, Boston, MA. Hirsh, H. 1990b. Learning from data with bounded inconsistency. In Proceedings of the International Conference on Machine Learning. Morgan Kaufmann Publishers. 32-39. Hirsh, H. 1992. Polynomial-time learning with version spaces. In Proceedings of the Tenth National Con- ference on Artificial Intelligence (AAAI-92). AAAI Press. Mitchell, T. M. 1978. Version Spaces: An Approach to Concept Learning. Ph.D. Dissertation, Stanford University. Mitchell, T. M. 1982. Generalization as search. Arti- ficial Intelligence 18(2):203-226. Quinlan, J. R. 1987. Inductive knowledge acquisi- tion: A case study. In Quinlan, J. R., editor, 1987, Application of Expert Systems. Turing Institute Press. 157-173. Smith, B. and Rosenbloom, P. 1990. Incremental non- backtracking focusing: A polynomially bounded gen- eralization algorithm for version spaces. In Proceed- ings of the Eighth National Conference on Artificial Intelligence (AAAI-90). MIT Press. 848-853. 146 Learning: Inductive | 1992 | 32 |
1,224 | Cullen Schaffer Department of Computer Science CUNY/Hunter College 695 Park Avenue, New York, NY l 10021 212-7’72-4283 l schaffer@marna.hunter.cuny.edu Abstract Overfitting avoidance in induction has often been treated as if it statistically increases expected pre- dictive accuracy. In fact, there is no statistical basis for believing it will have this effect. Over- fitting avoidance is simply a form of bias and, as such, its effect on expected accuracy depends, not on statistics, but on the degree to which this bias is appropriate to a problem-generating domain. This paper identifies one important factor that affects the degree to which the bias of overfitting avoidance is appropriate-the abundance of train- ing data relative to the complexity of the relation- ship to be induced-and shows empirically how it determines whether such methods as pessimistic and cross-validated cost-complexity pruning will increase or decrease predictive accuracy in deci- sion tree induction. The effect of sparse data is illustrated first in an artificial domain and then in more realistic examples drawn from the UCI machine learning database repository. Introduction It is easy to get the impression from the literature on decision tree pruning techniques [Breiman e2 al., 1984; Cestnik and Bratko, 1991; Mingers, 1987; Mingers, 1989; Quinlan, 1987; Quinlan and Rivest, 19891 that these techniques are statistical means for improv- ing predictive accuracy. In fact, overfitting avoid- ance methods in general-and pruning techniques in particular-have an indeterminate effect on expected accuracy. Overfitting avoidance constitutes an a pri- ori prejudice in favor of certain models and, like other forms of bias, it is inherently neither good nor bad. Whether bias will improve or degrade performance de- pends purely on whether it is appropriate to the do- main from which induction problems are drawn. These points, demonstrated empirically and ana- lytically in [Schaffer, 1992a; Schaffer, 1991; Schaffer, 1992b], suggest an important shift in research focus. Attempts to develop “good” pruning techniques or to compare techniques to determine which is “best” [Mingers, 19891 make no sense if the effect of each technique depends on where it is applied. Rather than looking for a single, universally applicable prun- ing method, we need a selection of useful alternatives and-most crucially-an understanding of the factors that determine when each implicit bias is appropriate. This paper takes a first step toward providing in- sight of this kind. The paper is organized in two parts. In the first, a well-known pruning method-cross- validated cost-complexity pruning-is pitted against a no-pruning strategy in an artificial domain. This do- main is designed to show as clearly as possible how the effect of pruning depends on the abundance of training data relative to the complexity of the true structure underlying data generation. In particular, when the training data is relatively sparse in this domain, either because few observations are available for learning or because the underlying structure is complex, the bias inherent in popular pruning methods is inappropriate and they have a negative effect on predictive accuracy. The second part of the paper illustrates the same sparse data effect using examples drawn from the UC1 machine learning data repository [Murphy and Aha, 19921. This part shows that understanding what de- termines the effect of overfitting avoidance strategies is a matter of practical concern. In extreme cases of sparse training data in the UC1 examples pruning de- grades predictive accuracy by three to five percent; in moderate cases the negative effect is smaller, but still comparable to the gains often reported in support of proposed pruning methods. oisson Generator Experiments The Poisson Generator In experiments described in this section, data for in- duction is generated artificially. Instances consist of the value of a continuous attribute x that ranges from 0 to 1 and a class value in (A,B}. How the class de- pends on z is determined by a data generation model; Figure 1 shows a sample model. The class value is A for x values between 0 and the first vertical mark, B be- tween the first and second marks, and so on alternately. To generate data, x values are chosen at random over Schaffer 147 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. A B A B the next, this factor may be critical. As we consider a * 0 1 increasingly complex models or smaller training sets X in such cases, pruning methods will, according to the Figure 1: A sample data generation model hypothesis, perform more and more poorly until, even- tually, they decrease predictive accuracy. For data sufhciently sparse, in this sense, the bias inherent in the interval [O,l] and paired with the associated class values. Then, to simulate the effect of classification noise, class values are complemented with probability techniques like pessimistic and cross-validated cost- complexity pruning is inferior to the bias inherent in a no-pruning strategy and we should expect the latter to perform better. e. The data generator creates a new data generation model each time it is called and then uses this model to produce training and test data. Models vary only in the number and placement of the vertical cutpoints, which are determined according to a Poisson process with parameter X. That is, the number of cutpoints is chosen at random over { 0,1,2,. . . } , the expected num- ber of cutpoints is X, and, once the number is chosen, cutpoints are placed at random in the interval [O,l]. The value of A is a parameter of the data generator set by the user. Experimental Methodology To investigate this hypothesis, the algorithms CV and NP were tested on problems produced by the Poisson generator. Three parameters were varied in the course of these tests: the size of the training set, n, the av- erage model complexity, X, and the classification error rate, e. For each of I68 combinations of n, A and e, the three algorithms were tested on 50 problems produced by the Poisson generator. In each case, a test set of IO0 fresh instances was used to measure predictive ac- curacy. After 50 trials the overall accuracy of CV and NP was compared. Since the number of cutpoints in a model is one less than the number of leaves in the corresponding optimal decision tree, X is a measure of the expected complexity of the underlying model. The Poisson generator just described thus provides a way to generate induction problems at varying levels of complexity. By paring induction down to essentials-one attribute and two classes-the generator helps to focus attention on the effect of sparse data. Complex examples representative of induction in real application domains are discussed in below. Algorithms for Comparison Two tree induction algorithms are compared in these experiments, each implemented by choosing appropri- ate options of the CART program. CV uses the Gini splitting criterion to build trees and cost-complexity optimization through tenfold cross-validation to prune them. It differs from the default version of CART [Breiman et al., 19841 only in that (1) it replaces the one-standard-error rule described in [Breiman et al., 1984, p. 781 with a zero-standard-error rule that has performed better in related experiments [Schaffer, 1992a] and (2) it allows nodes of any size to be split. The default version of CART will not split nodes of less than five training cases. A second algorithm, NP, is identical to CV except that it does not carry out any pruning. Experimental Results The results of these experiments are summarized in Figure 3. Each gridpoint is marked either with “CV,” if that algorithm attained the highest overall predictive accuracy for the associated n-X-e combination, or with a dot (w) if NP is superior. 1 Note that the size of the training set decreases along the vertical axis. As the schematic diagram in Figure 2 indicates, this means that data grows sparser in each grid as we move upward or rightward. These grids very neatly illustrate the sparse data ef- fect: In each, pruned trees prove more predictive at the lower left and unpruned trees more predictive at the upper right. At the top and right, where data is spars- est, avoidance of overfitting through pruning degrades performance, as predicted, rather than improving it. In each grid, a downward sloping boundary sepa- rates a domain region in which the biases of the tested pruning methods are appropriate from one in which they are inappropriate. Note that the increasing levels of noise have the effect of moving this boundary up- ward and to the right. Other things being equal, in this domain, noise increases the value of pruning. Wypot hesis The basic hypothesis underlying this paper is that the effect of overfitting avoidance depends, among other things, on the amount of training data relative to the complexity of the data generation model. Under cer- tain conditions, characteristic both of the artificial ex- amples of this section and the real-data examples of Additional experiments have been carried out by the author for an induction strategy using information gain and pessimistic pruning and by Ross Quinlan [personal communication] for C4.5 with qualitatively similar re- sults. ‘At one gridp oint a dash I-) indicates that these algo- rithms performed identically. 148 Learning: Inductive Figure 2: Schematic guide to the Poisson generator results e = .05 n 20 * . 30 cv * 40 cv * 50 cv cv 60 cv cv 70 cv cv 4 6 n 20 . - 30 cv cv 40 cv cv 50 cv cv 60 cv cv 70 cv cv 4 6 cv cv cv 8 10 12 x e= .2 cv cv f cv cv * cv cv cv 8 10 12 x . . cv * 14 16 . . . . cv * . . cv - * cv 14 16 n e= .l 20 . . . . . . . 30 cv cv * . . . . 40 cv cv * . . . . 50 cv cv * cv cv - * 60 cv cv cv cv . . . 70 cv cv cv cv cv . . 4 6 8 10 12 14 16 A n e= .3 20 cv . cv . - cv . 30 cv cv cv . . cv . 40 . . .cv. . . 50 cv cv cv cv cv . . 60 CV CV CV . . . . 70 cv cv cv . cv * . 4 6 8 10 12 14 16 x Figure 3: Results for the Poisson generator experi- ments Leaves Accuracy 5: CV 3.8 10.2 NP 71.38 CV 70.40 NP -.97 A Signif. .12 Table 1: Results for heart disease data experiments Examples from the UC1 Repository In this section, examples drawn from the UC1 repos- itory of machine learning databases are used to illus- trate the sparse data effect.2 Except where noted, re- sults are averaged over 50 trials in which training data is selected at random and remaining data is used for testing. Cleveland Heart Disease Data Table 1 summarizes the results of experiments with the Cleveland heart disease data.3 With real data of this kind, we have no control over the complexity of the true relationship governing data generation, but we can investigate the effect of sparse data by incre- mentally decreasing the size of the training set. The table shows that, as we do, the predictive accuracy of trees produced by NP climbs from about one percent below those produced by CV to more than three per- cent above. As in the artificial domain, the effect of overfitting avoidance is negative for sufficiently sparse training data. The last column of the table gives the statistical sig- nificance of NP’s superiority, according to a paired t test; in the higher rows, this figure may be subtracted from 1 to get the significance of CV’s superiority in- stead. A figure near .5 in the last column would indi- cate that there is no statistically significant difference between the algorithms. Similar results have been obtained for the Cleveland heart disease data in experiments comparing PS, an IND-based [Buntine and Caruana, 19911 tree induc- tion strategy using information gain to build trees and Quinlan’s pessimistic method [Quinlan, 19871 to prune them, with PS-NP, a strategy that builds trees the same way, but does not prune. 2All data is available by anonymous FTP from the di- rectory pub/machine-learning-databases at ics.uci.edu. 3CART requires training sets to include at least one rep- resentative of each class for each fold of cross-validation. Thus, even if a full training set includes such representa- tives and NP produces a tree as usual, CART may refuse to produce a tree using the options defining CV. Cases of this hind are excluded from the analysis in this section. All statements that one of NP or CV is superior to the other ought, for precision, to be prefaced by the phrase “when both algorithms produce trees.. .” Schaffer 149 I Leaves I Accuracv I CV NP CV NP =A 300: 608.0 659.5 74.34 74.20 -.14 2000 430.5 489.9 70.60 70.58 -.02 1000 258.6 296.8 63.00 63.06 .06 500 142.1 176.3 54.79 55.06 .27 250 77.4 105.2 44.03 44.32 .29 125 45.9 62.6 32.57 33.95 1.38 Signif. <.01 .37 .76 .94 .98 .96 Table 2: Results for letter recognition data ments Letter ecognition Data Leaves Accuracy n CV NP CV NP A Signif. 1600 6.5 7.5 99.86 99.92 .06 >.99 400 3.8 5.4 99.35 99.47 .13 .99 100 2.3 3.2 97.94 98.21 .27 >.99 20 2.0 2.2 90.70 90.73 .03 .55 10 1.9 2.1 76.86 82.28 5.42 >.99 Table 3: Results for mushroom data experiments experi- The Cleveland heart disease data illustrates the fact that NP may be superior when training sets are suf- ficiently small. But training data may be sparse, in the sense of this paper, even for large training sets if the true relationship between attributes and classes is sufficiently complex. Results for the letter recognition data, shown in Table 2, are a case in point. This is a second clear example of the sparse data effect in real data, but, here, NP remains superior for training sets of up to 1,000 cases. The complexity of the true un- derlying relationship is reflected by the enormous, but highly predictive, trees constructed by both algorithms given large amounts of training data. In experiments with PS and PS-NP, the latter proved superior for the letter recognition data for train- ing sets of up to 16,000 cases. This would appear to confirm past suggestions that the pessimistic method may lead to consistent overpruning [Mingers, 19891. igit Recognition Data A third example of the sparse data effect is reported in a study of the digit recognition problem in [Schaffer, 1992a]. In that paper, CV is superior to NP by about one percentage point when the training set contains 200 instances and attribute errors occur with prob- ability .2. When the number of instances is cut to 100, however, NP proves superior by roughly an equal amount, and its advantage rises to about three per- centage points for training sets of size 25. Mushroom Data Results for the mushroom data are more complex. An initial set of experiments, summarized in Table 3, show NP superior to CV at every tested training set size, but with a deep dip in significance near n = 20.4 Given training sets of this size, both CV and NP normally discover the single attribute that accounts for about 90 percent of potential predictive accuracy and neither regularly discovers anything else of use. For smaller 4At this level of n, an additional 150 trials were run to confirm the weak significance. The table shows results for a total of 200 trials. 20; 100 60 30 20 15 10 Leaves cv 98.34 97.56 96.78 93.23 89.85 85.97 75.27 Act NP 97.90 96.91 95.71 92.20 89.55 87.49 80.21 uracy a -.44 -.65 -1.07 -1.03 -.30 1.52 4.95 1 1 Table 4: Results for mushroom data with added noise training sets, NP discovers the single, highly predictive attribute more consistently, and for larger training sets it leads the way in discovering additional predictive structure; in both cases, it proves superior to CV. A salient feature of the mushroom data is the low level of noise evidenced by the extremely high accura- cies achieved by both tested algorithms. Recalling the effect of classification noise in the artificial domain of the previous section, we may hypothesize that this lack of noise is what allows NP to maintain its superiority at every tested level of n. Table 4 confirms this hypoth- esis by showing the results of additional experiments with the mushroom data in which artificial noise com- plements the class variable with probability .Ol. With this modification, we again observe a clear example of the sparse data effect. Results of experiments with PS and PS-NP were qualitatively much like those reported here. For the original mushroom data, PS-NP proved superior for training sets of 10 to 6,400 cases except for a middle range centered about training sets of 40 cases. With added classification noise, a clear sparse data effect was observed, with the crossover near n = 25. Hypothyroid Data Results for the hypothyroid data are the least clear of those reported here. In initial experiments comparing PS and PS-NP, this data seemed to yield another clear example of the sparse data effect, as shown in Table 5. For still larger training sets, however, the superiority of PS’s pessimistic pruning decreased as both algorithms converged to near perfect performance. Moreover, experiments comparing CV and NP show 150 Learning: Inductive Leaves Accuracy n PS PS-NP PS PS-NP A Signif. 375 5.5 10.1 98.4 98.2 -.2 .02 260 5.5 9.0 97.7 97.7 0 .50 180 5.2 7.4 97.3 97.4 .l .91 90 3.4 6.4 95.2 95.6 .4 .98 45 1.8 4.6 93.1 94.1 1.0 >.99 Table 5: Results for hypothyroid data experiments with PS and PS-NP 200: 375 I 260 180 90 45 Leaves Accuracy CV NP CV NP A Signif. 6.3 9.8 99.79 99.77 -.02 .19 4.5 5.8 98.56 98.76 .20 >.99 4.0 5.6 97.57 97.79 .22 .99 2.8 4.9 96.24 96.96 .72 >.99 2.1 3.9 95.41 95.46 .06 .62 1.6 3.2 94.83 94.62 -.21 c.01 Table 6: Results for two-class hypothyroid data exper- iments with CV and NP the former superior for training sets of 45 cases-just where pruning performed worst in experiments with PS and PS-NP. Results for these experiments are shown in Table 6. Note though, that these are not directly comparable with results for PS and PS-NP. First, the PS algorithms use information gain as a splitting cri- terion, while the CV algorithms use Gini. Second, for practical reasons, the three positive classes of the hy- pothyroid data were merged for experiments with CV and NP.5 Note also that 1,000 trials were run for n = 45 instead of the usual 50 in order to produce a clearer result. One fact that may account for the difference between experiments with the hypothyroid data and the others reported in this paper is that the class distribution for the hypothyroid data is highly unequal. Negative cases account for about 95 percent of the data. In a last set of experiments, balanced data sets were constructed for each trial using all of the positive cases and an equal number of randomly selected negative cases. Data sets constructed in this manner were split into training and testing portions at random, as usual. Because the size of the test sets was normally quite small, 100 trials were run at each training set size. The results, given in Table 7, show a uniform pat- tern, with NP superior at every tested training set size. It would be interesting to know if CV is superior for larger training sets, yielding a complete example of the sparse data effect, but the data available is not suffi- 5See footnote 3. Some of the positive classes are so weakly represented that they are almost certain not to ap pear in one of the training sets used for cross-validation and this causes the CART system to refuse to build a tree. Table 7: Results for balanced two-class hypothyroid data experiments with CV and NP cient to run these trials. iscussion The results of the previous section mainly speak for themselves, but two points may be worth adding. First, it was remarkably easy to find examples like the mushroom and letter recognition data for which prun- ing degrades performance even for large training sets. Data sets were selected for testing more or less at ran- dom from the UC1 repository and results for all but one of those data sets have been reported here.6 Thus, there is reason to suspect that the sparse data effect is often of practical importance in the induction problems considered by machine learning researchers. Second, results for the hypothyroid data point up the fact that sparsity of data is only one of several condi- tions which together determine the effect of overfitting avoidance. In particular, if class prevalences are far from equal, any of the well-known pruning methods may increase predictive accuracy even when training data is sparse.7 As argued in the introduction, when we recognize that overfitting avoidance is a form of bias, we nat- urally turn our attention away from pursuing “good” overfitting avoidance methods and toward a determi- nation of where alternative methods are appropriate. This paper contributes by identifying the abundance of training data relative to the complexity of a target relationship as one important factor in this determina- tion. It stops far short, however, of defining sparsity precisely or of telling us just how sparse data must be for particular pruning methods to degrade perfor- mance. This is an important area for future work. One thing that may be stated emphatically even at this early juncture, however, is that it is hopeless to 6Results for the hepatitis data are omitted. In that case, there appears to be very little relationship between attributes and classes. A one-node tree is almost optimally predictive and, as might be expected when the the com- plexity of the target concept is so low, pruned trees are superior even for very small training sets. ‘Ross Quinlan [p ersonal communication] has produced a variant version of the Poisson generator which divides the unit interval as usual, but then assigns classes to the subintervals with unequal probabilities. In this case, prun- ing uniformly increases the performance of (24.5. Schaffer 151 expect the training data itself to tell us whether it is sparse enough to make unpruned trees preferable. As argued at length in [Schaffer, 1992131, training data cannot tell us what bias is appropriate to use in inter- preting it. In particular, the sparsity of data depends on the complexity of the true relationship underlying data generation; and it is not data but domain knowl- edge that can tell us how complex a relationship to expect. Schaffer, Cullen 199213. Machine Learning. Acknowledgements Special thanks to Ross Quinlan for his efforts to repli- cate the results reported here and for pointing out im- portant flaws in a draft version of the paper. Thanks also to Wray Buntine and Robert Holte for supporting the ideas advanced here. eferences Breiman, Leo; Friedman, Jerome; Olshen, Richard; and Stone, Charles 1984. Classification and Regres- sion Trees. Wadsworth & Brooks, Pacific Grove, Cal- ifornia. Buntine, Wray and Caruana, Rich 1991. Introduction to IND and recursive partitioning. Technical Report FIA-91-28, RIACS and NASA Ames Research Center, Moffett Field, CA. Cestnik, Bojan and Bratko, Ivan 1991. On estimating probabilities in tree pruning. In Machine Learning, EWSL-91. Springer-Verlag. Mingers, John 1987. Expert systems - rule induc- tion with statistical data. Journal of the Operationad Research Society 38:39-47. Mingers, John 1989. An empirical comparison of pruning methods for decision tree induction. Machine Learning 4(2):227-243. Murphy, P. M. and Aha, D. W. 1992. UCI repository of machine learning databases [a machine-readable data repository]. Maintained at the Department of Information and Computer Science, University of Cal- ifornia, Irvine, CA. Quinlan, J. Ross and Rivest, Ronald L. 1989. In- ferring decision trees using the minimum descrip- tion length principle. Information and Computation 801227-248. Quinlan, J. Ross 1987. Simplifying decision trees. In- ternational Journal of Man-Machine Studies 27:221- 234. Schaffer, Cullen 1991. When does overfitting decrease prediction accuracy in induced decision trees and rule sets? In Machine Learning, E WSL-91. Springer- Verlag. Schaffer, Cullen 1992a. Deconstructing the digit recognition problem. In Machine Learning: Proceed- ings of the Ninth International Conference (ML92). Morgan Kaufmann. Overfitting avoidance as bias. 152 Learning: Hraductive | 1992 | 33 |
1,225 | Wei-Min Shen Microelectronics and Computer Technology Corporation 3500 West Balcones Center Drive Austin, TX 78759 wshen@mcc.com Abstract This paper describes the integration of a learning mechanism called complementary discrimination learning with a knowledge representation schema called decision lists. There are two main results of such an integration. One is an efficient repre- sentation for complementary concepts that is cru- cial for complementary discrimination style Iearn- ing. The other is the first behaviorally incremental algorithm, called CDLZ, for learning decision lists. Theoretical analysis and experiments in several do- mains have shown that CDL2 is more efficient than many existing symbolic or neural network learning algorithms, and can learn multiple concepts from noisy and inconsistent data. Hntroduction Complementary discrimination learning (CDL) (Shen 1990) is a general learning mechanism inspired by Pi- aget’s child development theories. The key idea is to learn the boundary between a hypothesis concept and its complement incrementally based on the feedback from predictions. The framework is general enough to be applied to many learning tasks (Shen 1989, Shen 1992), including concept learning, adaptive con- trol, learning finite state machines, and discovering new theoretical terms. However, earlier implementations of CDL use standard CNF and DNF Boolean formulas to represent separately the hypothesis concept and its complement. Since hypotheses are revised frequently in the learning process, to keep them complementary in these canonical forms is computationally expensive. A decision list is a representation schema proposed by Rivest (1987) for Boolean formulas. He proves that Ic-DL (decision lists with functions that have at most Ic terms) are more expressive than L-CNF, L-DNF, and Decision Trees. He also gives a polynomial-time algo- rithm for learning decision lists from instances. How- ever, one of the open problems listed in his paper is that there is no known incremental algorithm for learn- ing decision lists. Complementary discrimination learning and decision lists are well suited for each other. On the one hand, decision lists eliminate the burden of maintaining sepa- rate representations for complements. (Since decision lists are closed under complementation, they can be used to represent a concept and its complement in a single format .) On the other hand, complementary dis- crimination provides a way to learn decision lists incre- mentally. The integration of complementary discrimination learning and decision lists gives some surprising re- sults. The most salient one is efficiency. In the ex- periments we conducted, CDL2 is much more efficient than most other behaviorally incremental algorithmsl, such as ID5r, and its performance is even competitive with the nonincremental learning algorithm ID3. Com- pared to nonsymbolic algorithms such as backpropaga- tion neural networks, CDL2 is much faster to train and has comparable results in recognizing hand-written nu- merals that are noisy and inconsistent. CDE2 also ex- tends Rivest’s definition of decision lists from binary concepts to multiple concepts. Such decision lists pro- vide a compact representation for concepts. When ap- plied to Quinlan’s (1983) chess task, CDL2 has learned a decision list of 36 decisions. The rest of the paper is organized as follows. Section 2 gives a general description of complementary discrim- ination and points out the need for decision lists. Sec- tion 3 describes in detail the new learning algorithm CDL2 and how decision lists are used in complemen- tary discrimination style learning. Section 4 reports experimental results of CDL2 in several concept learn- ing tasks and compares the results with other learning algorithms. Section 5 analyzes the complexity of CDL2. Complementary Complementary Discrimination Learning (CDL) is a mechanism for learning concepts from instances. In some sense, instances can be viewed as points defined ‘A learning alg orithm is behaviorally incremental if it is incremental in behavior (i.e., it can process examples one at a time), but not incremental in storage and processing costs (e.g., it may require to remember some or all previous examples.) From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. in a feature space and concepts as regions in such a space. The main idea of CDL is to move a hypoth- esized boundary between a hypothesis concept H and its complement H in the feature space until it converges to the real boundary of the real concept and its com- plement. The boundary between H and H is adjusted based on feedback from predictions. When a new in- stance arrives, CDL predicts that the instance belongs to one of the hypothesized complements, either H or H, depending on which side of the boundary the instance lies on. If the prediction is correct, CDL remembers the new instance as an exumple of the hypothesis. If the prediction is wrong, then the boundary is “shifted” towards the hypothesis in the prediction. This is done by shrinking one hypothesis and expanding the other. How much the hypothesis is shrunk depends on the dif- ference between the new instance and all the previous examples of that hypothesis. Technically, the shrinking is done by conjoining the hypothesis with the difference so found. After the hypothesis is shrunk, the other hypothesis is expanded to be the complement of the shrunken hypothesis. The new instance is remembered as an example of the expanded (complement) hypothe- sis. Efficiency of this CDL scheme depends on its imple- mentation. If both H and H are separately represented, then one must make sure that H and ?? are always complementary each time the boundary is moved. One trick is to keep them in some canonical forms, say one in CNF and the other in DNF (Shen 1990). However, since the differences between a new instance and pre- vious examples are always in DNF, it is computational expensive to keep the concepts in these canonical forms. Moreover, this implementation is awkward for multiple concepts. Since there is only one boundary to keep, the names of multiple concepts must be represented as arti- ficial “features” of the instances so that CDL can learn them as if they were binary concepts. Thus, in order to use the idea of CDL efficiently, a better representation for complementary concepts must be found. Such a representation should make mainte- nance of complementarity between H and H computa- tionally inexpensive. Decision lists seem to be an ideal choice. Following Rivest, a decision list is a list L of pairs where each test function fj is a conjunction of literals, each vj is a value in {O,l}, and the last function f,. is the constant function true. For convenience, a pair (fj, vj) is called the j-th decision, fj the j-th decision test, and vj the j-th decision value. In this paper, we use an extended definition of decision lists in which vj is a value from a finite set of concept names rather than from the binary set {O,l}. A decision list L defines a set of concepts as follows: for any instance x, the decision on x is defined to be . = (f. v.) where j is the least index such that Z(X) = l:‘T;Ii value vj is the concept of X. ----xl---- O/ \l -x3- -x2- o/ \l Cl3 co1 I/ \o Cl3 x4 o/ \l co1 Kll Figure 1: A decision tree To see how decision lists represent concepts, consider the decision tree in Figure 1. The concept defined by this tree is equivalent to a Boolean formula in DNF: TliT3 V X122 V XlT2X4 This can be easily translated into a decision list: (%573,1)(X1X2, I)(XlZ2X4,1)&‘% 0) (1) Since a decision list can have values other than Is, the same concept can also be represented as the following different decision lists: (zlT3, l)(%X3,0)(~2~490)(true, 1) (2) @1X3,0)(X2, I)( xlZ4,O)(true, 1) (3) Decision lists make the movement of concept bound- aries easier. We let 101 denote the domain of a decision D = (f,v), which is a set of instances (iIf = I}. An interesting property of decision lists is that deci- sions with smaller indices “block” decisions with larger indices if their domains overlap. To discriminate a de- cision, one can simply “shrink” or “break” the domain of the decision so that instances that do not belong to this decision can “fall through” to later decisions that have the correct values. Consider, for example, a decision list ((&l)(true, 0)). If evidence has shown that (&,l)‘s domain is too large, i.e., some part of that domain, say those that have ~1, should have concept value 0 instead of I, then one can simply append ~1 to ~3 to “shrink” the decision (~3~1) and get a new decision list: (@rzs,l)(true,O)). This is actually the key concept of the new complemen- tary discrimination learning algorithm CDLS. The CDL2 Algorithm As we indicated in the last section, complementary dis- crimination is a mechanism that learns the boundary between a concept and its complement. The necessary subtasks of general CDL are: to detect which hypothe- sis is overly general; to find out what part of the hypoth- esis is overly general; and to actually move the bound- ary towards that hypothesis. In the case of learning decision lists, the first task is accomplished as follows: when a new instance x (with a concept value vz) arrives, the learner uses the current decision list to make a prediction as to what concept the new instance belongs to. The prediction is the value vj, 154 Learning: Inductive Let G be the new instance and v, be its concept value. Loop: Let DDE = (pi, vi) be the decision on X; If the decision is correct, i.e., v, = Vi, then store x as an example of Dj and return; else Let (~71,. . ’ , ud) = DIFFERENCES(examplesOf( Dj ),x); Rep~ace(.fj,vj) by (fjAal,vj),...,(fjhud, vi); Distribute the examples of Dj to the new decisions; If Dj was the last decision, then append (true,v,) at the end of the list, and return. Figure 2: The basic CDL2 learning algorithm where j is the least index such that fj(x) = 1. If vj is not equal to v,, then the decision (fi , vi) is too general. Since each decision with a list of previous v in the decision examples that ii& is associated belong to the de- cision, to find-out what part of fj is overly-general en- tails finding the difference between the new instance and all of the previous examples that belong to fj. The difference will be a list of terms that are true for previous examples but false for the new instance. For example, if the new instance is 10001 (in the form of xrxzx32425) and the previous examples are 00011, 00010, 00001, 00000, 11000, 11001, 11010, and 11011, then the difference will be (~1, 22), where ~1 distin- guishes (00011, 00010, 00001, 00000) from 10001 and 22 distinguishes (11000, 11001, 11010, 11011) from 10001. For a detailed description of how differences are found, see (Shen 1990). Let the differences so found be a list {al, . . . , ud}. To shrink or break the decision (fj, vj), we replace it with a list of new decisions (fj ~01, vj), * * . , (fj AUK, vj). Clearly, none of the new decisions will capture the new instance again. The previous examples of the old deci- sion are then distributed to these new decisions in the following manner: an example e is distributed to f’ AUK where i is the least index such that [fj A ai] = 1. After the incorrect decision is replaced, the new in- stance continues to look for a decision in the remainder of the old decision list. Suppose the new prediction is from the decision & , where k 2 (j + d). If VI, = vc, then the instance is remembered as an example of &. Otherwise, Dk is shrunken or broken just as Dj was. This process continues until the instance finds-a de- cision-with the correct value. If the instance reaches the end of the list, i.e., Dk = (true,vk), then either vk = v, and x can be added to Dk’s example list, or & is shrunk and a new “default” decision (true, vr) is appended at the end of the list with 2 as its only exam- ple. The pseudocode of the CDL2 algorithm is listed in Figure 2. It is interesting to notice that Rivest’s nonincremen- tal learning algorithm constructs decision lists from the beginning to the end, while CDL2 constructs decision lists from the end to the beginning (roughly). This is because CDL style learning is based on discrimination, and decisions with greater indices are more general than those with smaller indices. The use of discrimination also sets apart CDL2 from “exemplar-based learning” mechanisms, e.g., (Salzberg 1991). The main idea of those algorithms is to “grow” a region around some seed instances, while the idea of CDL2 is to “repartition” re- gions based on surprising instances. Furthermore, the decision tests learned by CDL2 are very similar to the features used at the nodes of decision trees (Pagallo and Haussler 1990). To illustrate the algorithm, let us go through an ex- ample to see how CDL2 learns the concept defined Fig- ure 1: 21Z3 V Xl22 V XlT2X4. We assume that the training instances are from 00000 to 11111 and will be given in that order. Each training instance has a con- cept value. For example, (11000 +) means the instance 11000 is in the concept, while (00111 -) means 00111 is not in the concept. When the first training instance (00000 +) arrives, CDL2 initiates a decision list with a single “default” decision: ((true 9 +)I, The instance is stored as an example of this sole de- cision. Since the next three instances 00001, 00010, and 00011 are all being predicted correctly, they also become examples of the default decision. The fifth instance is (00100 -), and CDL2’s prediction “+” is wrong. The difference between (00000 00001 00010 00011) and 00100 is found to be (&), the decision is shrunk to be (&,+), and a new default (true, -) (with the instance 00100 as its example) is appended at the end. The new decision list is now: ((53, +)(true, -)). With this decision list, the succeeding instances are pre- dicted correctly until 10000. CDL2’s decision is (23, +) but the instance belongs to “-.” Comparing the exam- ples of the decision with the new instance, CDL2 finds the difference to be 21. The decision is then replaced by (‘j~153, +): ((Qz3, +)(true, -)). The troublesome instance then finds (true, -) to be correct and becomes an example of the default deci- sion. For succeeding instances, CDL2’s prediction is correct on 10001, but wrong on 10010. The decision is (true, -) but 10010 is a +. The differences found are (xafi , ~4), so the decision (true, -) is replaced by ((53z1, -)@4, -)(true, +)), yielding: ((5W3, +)(X3%, -)@4, -)(true, +I). With this decision list, CDL2 predicts correctly the next five instances 10011, 10100, 10101, 10110, and 10111 but fails on 11000. The decision is (Z4, -) but the in- stance is a +. The difference between Ed’s examples (10101 10100 10001 10000) and the instance 11000 is found to be (32). The decision (~4, -) is then shrunk into (Z4~2, -) and th e new decision list is now: ((zlF3, +)(x3% 9 ->(~4~2, -)(tr% +)) This decision list is equivalent to the target concept, and it correctly predicts 11001 through 11111. Shen 155 The basic CDL2 algorithm can be improved in sev- eral ways. The first one is to construct decision lists that are shorter in length. CDL2 does not guarantee learning the shortest decision list, and the length of the final decision list depends on the order of the training instances. If the instances that are more representative (i.e., that represent the critical differences between com- plementary concepts) appear earlier, then the length of the decision list will be shorter. Although learning the shortest decision list is a NP-complete problem (Rivest 1987), there are some strategies to aid in maintaining the list as short as possible. Every time a decision is replaced by a list of new deci- sions, we can check to see if any of these new decisions can be merged with any of the decisions with greater indices. A merger of two decisions (fi, v) and (fj , v) is defined to be (fm, II), where fm is the intersection of the literals of fi and fj . Two decisions Di = (fi, vi) and Dj = (fj,Vj) (i < j) can be merged if the follow- ing conditions are met: (1) The two decisions have the same value, i.e., vi = Vj ; (2) None of the examples of Da is captured by any decisions between i and j that have different decision values; (3) The merged decision (fm, vj) does not block any examples of any decisions after j that have different values. To illustrate the idea, consider the following example. Suppose the current decision list is ((553, +)(a -)(true, +)), and examples of these three decisions are (010, 000), (111, lOl), and (Oil), re- spectively. Suppose the current instance is (100 -), for which CDL2 has made the wrong decision (~a,+). Since the difference between (010, 000) (the examples of 01) and 100 is @I), the decision (ES,+) should be replaced by (?&?r ,+), which would result in a new deci- sion list ((53Zl,+)(iq, -)(true, +)). However, the new decision (&~i;l,+) can be merged with (true,+) because it has the same decision value, and none of its examples can be captured by (~1, -), and the merged decision, which is (true,+), does not block any other decisions following it. Thus, the decision list is shortened to: ((XI, -&rue, +)). The second improvement over the basic CDL2 algo- rithm is to deal with inconsistent data. When data are inconsistent, there will be no difference between some instances that have different concepts values. In other words, the same instance may belong to different con- cepts simultaneously. To handle such data, we relax the criterion for a correct decision to be: A decision Dj = (fj, vj ) is correct on an instance x that has concept value vc if either vj = up, or x is already an example of Dj . For example, suppose a decision (x122,+) currently has the example (( 11 +)) and a new instance (11 -) arrives, then the decision (xrxz,+) will be considered to be cor- rect because 11 is already in its example set. With this new criterion, a decision may have duplicate examples. Examples that belong to the same decision may have the same instance with different concept values, and the Table 1: Comparison on classifying chess end games value of the decision may be inconsistent with some of its examples. To deal with this problem, we have to adopt a policy that the value of a decision is always the same as the concept value that is supported by the most examples. If another example (11 -) is by the decision above, then the value of the decision will be changed from “+” to “-” because “-” will be supported by two examples vs. only one example for “+“. Experiments To date, the improved CDL2 has been tested in four domains: 6-bit Multiplexor (Barto 1985, Utgoff 1989), Quinlan’s chess task (Quinlan 1983), the noisy LED display data (Breiman et al. 1984), and a hand-written character recognition task. The first two domains are noise free, and the last two domains are noisy and contain inconsistent instances. In this section, I re- port CDL2’s performance only on the two more diffi- cult tasks: the chess task and the recognition of hand- written numerals. Comparison with other learning al- gorithms will also be given. In Quinlan’s chess task, the instances are configura- tions of end games in chess, each of which is represented as a binary feature vector of length 39. Each instance is labeled either “win” or “lose,” and the task is to learn the concept of “win” (or “lose”) from a given set of 551 end games. I have compared CDL2 with two leading algorithms ID3 and ID5r on this domain. The results are listed in Table 1. The first column in the table is the name of the al- gorithm. ID3 (Q uin an 1986) is a nonincremental algo- 1 rithm that learns decision trees. ID5+ and ID5r (Utgoff 1989) are incremental algorithms that learn decision trees. The difference between ID5i; and ID5r is that when the decision tree is revised, ID5r ensures that all the previous instances are still correctly classified, while ID5i does not. The second column is the number of passes that each algorithm made on the data set. This number is not meaningful for the nonincremental ID3 because it re- quires to see all the instances at once. The rest of the columns are the running times, the percentage of in- stances that are correctly classified after learning, and the smallest size for the learned concept, respectively. All algorithms are implemented in Allegro Common Lisp on Sun4, and the running time is an average for runs in which the instances are presented in different orders. As we can see, with the same accuracy, CDL2 156 Learning: Inductive Table 2: Comparison on the numeral recognition task 1 Prorr. I Epc. CPU Act.% Act.% (n)odes 1 Names - (min) (train) (test) (w)ghts Linked 30 300 96.6 87.8 385n Local 45 450 96.9 NNet 50 500 96.9 TD.3 N.A. 4.4 99.9 87.8 2860~ 88.2 74.2 440dec 1~5~ 1 - _ - - - c-ml,2 I 1 13.1 99.9 77.9 360dec is about 200 times faster than ID5r and is even faster than the nonincremental algorithm ID3. The size of concept learned by CDL2 is also very competitive with others. (The numbers in the last column are just rough indications. A size comparison between decision trees and decision lists involves a very lengthy discussion.) The second set of experiments performed is in the domain of recognizing hand-written numerals. The in- stances are 3301 numerals (from 0 to 9) written by hu- mans, each of which is represented as an 8x8 binary bit map. The data are noisy and have inconsistent instances (i.e., two bit maps that look the same may represent different numerals). The task is to learn to recognize these numerals by training on some numer- als (65% of the data), then testing the recognition on numerals that have not been seen before (35% of the data). Note that a random guess in this domain has only 10% chance of being correct. CDL2 is compared to some existing backpropagation neural networks and ID3. (This task is too complex for ID5i family algorithms.) The results are summarized in Table 2. Compared to ID3, CDL2 is slightly slower but has higher accuracy on the test data. Compared to the NNet, CDL2 learns faster and has higher accuracy on the training data, but it does not perform as well on the test data. One reason behind this is that the concepts in this domain are a set of arbitrary shapes (which can be handled by the neural net), while CDL2’s current generalization is best suited for hyperrectangles in a high-dimension space. Another reason is that CDL2 is overfitting. Yet another reason is that CDL2, unlike these networks, has no knowledge about this domain. If such knowledge were embedded in the algorithm, just as in the choice of architecture for the networks, CDL2 might improve its performance. Complexity Analysis In this section, we analyze the complexity of the basic CDL2 algorithm. Let d be the number of attributes of instances, and let n be the number of training instances. We assume all the attributes are binary and analyze the complexity under the following three cases. In the first case, which is extreme, we assume that every training instance will cause a prediction failure for CDL2, and the length of the decision list is always the longest possible (the number of decisions in the list is equal to the number of instances seen so far). When the i-th instance arrives, the length of the decision list is i- 1 and each decision has only one example. Therefore, finding a decision for the instance takes at most d(i- 1) bit comparisons, finding the difference takes at most d comparisons, and replacing the decision takes 1 deletion and 1 insertion. Since we assume each decision can only capture one instance, the decision must be at the end of the list and the new instance will find a correct decision after one loop. Thus the total number of comparisons to process the i-th instance is Q(d . i). There are n training instances, so the total number of comparisons to process all the training instances is: 2 O(d - i) = O(d . n2). i=l In the second case, which is also extreme, we assume that there is only one decision and it has all the previous (i - 1) examples. In this case, finding a decision takes d comparison, finding the differences takes d(i - 1) com- parisons, replacing the decision takes 1 deletion and at most (i - 1) insertions, distributing examples takes at most (i - 1)2d comparisons. This “explosion” of deci- sions can only happen once and after that the analysis is the same as in the first case. To be conservative, we assume that the explosion happens at the n-th instance, so the total complexity is: i=l In the third case, we assume the number of decisions is & and each of them has 4 examples. Then finding a decision takes d& comparisons, finding the differ- ence takes dd comparisons, replacing decisions takes 1 deletion and at most 4 insertions, and distributing examples takes at most d&d comparisons. We as- sume conservatively that in the worst case all the & decisions are broken (i.e., CDL2 loops fi times for the i-th instance), and the total time for processing all n instances is: kO(d.i;). i=l The above analysis is for the basic CDL2 algorithm. In the improved version, new decisions may be merged with the existing ones. Suppose there are & decisions in the list, a merge may take d&d comparisons (con- dition 1 takes at most fi, conditions 2 and 3 together take at most dfi&). There are at most & new de- cisions, so a revision of decision may require d . id comparisons. We assume conservatively that all the & decisions are broken, and the total time becomes: 2 O(d - i2) = O(d . n(n + 1)(2n + 1)) = O(d . n3). i=l Shen 157 Figure 3: Comparison of CDL2 experiments with de n2 Intuitively, it seems possible to tighten the above analysis considerably because CDL2’s performance in practice is much better. To gain more information about the real complexity, we compared CDL2’s actual running time with the complexity d. n2. The result is in Figure 3. In these experiments, we ran the improved CDL2, whose complexity is Q(d . n3) in theory, on two tasks: learning the d-bit parity concept and learning the d-bit multipleXOR. The first task is known to be the worst case for learning decision trees (Utgoff 1989) and the length of its decision list is n (corresponding to the first case in our analysis above). The second task has concepts that have exceptional instances and the length of its decision list is roughly fi (corresponding to our analysis in the third case). In all these experiments, CDL2 is presented with all 2d instances. As we can see in Figure 3, CDL2’s complexity is less than d . n2 in both tasks. These results suggest that our complexity analysis may indeed be too conserva- tive. Nevertheless, the current complexity of CDL2 is at least comparable with that of ID3 and ID5r. Ac- cording to (Utgoff 1989), ID3 takes O(n . d2) additions and 0(2d) multiplications, and ID5r takes O(n . d. ad) additions and 0(2d) multiplications. CDL2 uses only comparison operations and its complexity has no expo- nential components. Conclusions and Acknowledgment In this paper, I have described a successful inte- gration of complementary discrimination and decision lists. Compared to earlier complementary discrimina- tion learning algorithms, CDL2 has provided a solution to the problem of representing complementary concepts (or the boundaries of concepts) efficiently. It also pro- vides a natural way to represent and to learn multiple concepts simultaneously. Compared to Rivest’s initial results on decision lists, this work extends the defini- tion of decision lists to represent multiple concepts and, more importantly, has provided a behaviorally incre- mental algorithm for learning decision lists. Such an algorithm can learn from data that is potentially noisy and inconsistent. Moreover, experiments have shown that the efficiency of this incremental algorithm is com- parable to some widely used nonincremental concept learning algorithms. There are several future directions to improve CDL2. One is to use statistics to record historical information so that examples need not be stored. This would make CDL2 incremental not only in behavior but also in stor- age and processing costs. Another is to increase the ex- pressiveness of decision tests so that decision lists can represent concepts with arbitrary shapes and concepts with predicates. I thank Paul Utgoff, Jim Talley, Ray Mooney and Jude Shavlik for providing tools and data for the exper- iments, Michael Huhns, Jim Barnett, Jim Talley, Mark Derthick and three anonymous reviewers for their com- ments on the earlier draft. Special thanks to Phil Can- nata who provides both moral and financial support for this work. References (Barto, 1985) A.G. Barto. Learning by statistical co- operation of self-interested neuron-like computing el- ements. Hnman Neurobiology, 4:229-256, 1985. (Breiman et al., 1984) L. Breiman, L.H. Fredman, R.A. Olshen, and C.J. Stone. Classification and Re- gression Trees. Wadsworth International Group, Bel- mont, CA, 1984. (Pagallo and Haussler, 1990) Guilia Pagallo and David Haussler . Boolean feature discovery in empirical learning. Machine Learning, 5(I), 1990. (Quinlan, 1983) R.J. Quinlan. Learning efficient clas- sification procedures and their application to chess end games. In Machine Learning. Morgan Kaufmann, 1983. (Quinlan, 1986) R. J. Quinlan. Induction of decision trees. Machine Learning, l( 1):81-106, 1986. (Rivest, 1987) L. Ronald Rivest. Learning decision lists. Machine Learning, 2, 1987. (Salzberg, 1991) S. Salzberg. A nearest hyperrectangle learning method. Machine Learning, 6(3), 1991. (Shen, 1989) W.M. Shen. Learning from the Environ- ment Bused on Actions and Percepts. PhD thesis, Carnegie Mellon University, 1989. (Shen, 1990) W .M. Shen. Complementary discrimi- nation learning: A duality between generalization and discrimination. In Proceedings of Eighth AAAI, Boston, 1990. (Shen, 1992) W.M. Shen. Autonomous Learning from the Environment. W.H. Freeman, Computer Science Press. Forthcoming. 1992. (Utgoff, 1989) P.E. Utgoff. Incremental induction of decision trees. Machine Learning, 4(2):161-186, 1989. 158 Learning: Inductive | 1992 | 34 |
1,226 | 1 earning in FOL with a Similarity Gilles Bisson Laboratoire de Recherche en Informatique, URA 4 10 du CNRS Equipe Inference et Apprentissage Universite Paris-sud, B%iment 490, Orsay 91405 Cedex, France email : bisson@lri.hi.fr Abstract* There are still very few systems performing a Similarity Based Learning and using a First Order Logic (FOL) representation. This limitation comes from the intrinsic complexity of the learning processes in FOL and from the difficulty to deal with numerical knowledge in this representation. In this paper, we show that major learning processes, namely generalization and clustering, can be solved in a homogeneous way by using a similarity measure. As this measure is defined, the similarity computation comes down to a problem of solving a set of equations in several unknowns. The representation language used to express our examples is a subset of FOL allowing to express both quantitative knowledge and a relevance scale on the predicates. Learning in FQL A learning tool is the result of a trade-off between the capacity of the knowledge representation language used and the efficiency of the learning algorithm dealing with this language (Levesque & Brachman 1985). From this point of view, Valued Propositional Logic (VPL) is an interesting choice: some efficient statistical and/or logical learning methods can deal with this representation and it allows to take into account numerical knowledge. Therefore, this paradigm is currently used in the main families of systems such as ID3 (Quinlan 1983), AQll (Michalski & Larson 1983) in classification, CLUSTER/2 (Michalski & Stepp 1983), COBWEB (Fisher 1987) in Conceptual Clustering, and also in Data Analysis (Diday 1989). However, for a large set of domains, VPL is not sufficient to express the learning set. This problem occurs when the examples contain a variable number of entities (or objects) and when the relational structure between these objects changes from an example to the other. For instance, as shown by (Kodratoff et al. 1991), the representation of a molecule is yet a critical problem. In ethanol (figure l), how to represent the two carbons in the frame of VPL? It could be possible to create two specific attributes CARBl and CARB2 then to learn some rules with these attributes. But if we apply the learned knowledge to another molecule composed of any number of carbons, the system will be unable to recognize * This work is partially supported by CEC through the ESPRIT-2 contract Machine Learning Toolbox (2154) and also by french MRT through PRC-IA. which atoms of this new molecule play the role of CARBl and CARB2. The user will have to label correctly and always in the same way the different atoms. Now, when several objects appear in an example, the most difficult task is indeed to find the correct labeling. H H I Figure 1: Structure of H- c- l Ethanol H FOL-based representations allow to overcome this problem since they can deal with complex domains in which the relational structure of the described objects changes from an example to the other. They have been introduced a long time ago (Winston 1970) and are currently used in several systems such as GOLEM (Muggleton 1990), ITOU (Rouveirol 199 1) or FOIL (Quinlan 1990). However, the number of systems developed on this paradigm stays far less than those using VPL. Two reasons explain this point: first, the use of FOL generally involves a large increase of the computation complexity; second, in its classical definition, FOL does not allow to deal efficiently with numerical values, which is a limit in many real world problems. Various languages derived from FOL allowing to suppress this last flaw have been proposed in learning field such as APC (Michalski 1983) or the “Hordes” (Diday 1989) in Data Analysis. But, very few solutions about the way to process these representation languages have been provided. and clustering From a set of examples, the processes of generalization and clustering used in machine learning involve very similar problems. Generalization consists in pointing out the common parts of the examples, and clustering in gathering together the examples having the most common parts. Due to this resemblance, it is interesting to study if both processes are solvable in a similar way. In VPL representation, the generalization of two formulas (without domain theory) is not a difficult problem because the matching between the attributes is unique. In FOL the problem is intrinsically more complex since there are generally numerous ways to match the literals. The algorithms performing all the possible matching such as LGG (Plotkin 197 1) are unusable in real 82 Learning: Inductive From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. world problems since they lead to very large generalizations. Therefore, some bias are necessary to bind this size. A solution used in the Structural Matching algorithm (Kodratoff, Ganascia 1986), (Vrain 1990), is to compute a distance between each pair of entities occurring in the predicates then to define a matching of the entities which globally optimizes this distance. The literals kept in the generalization formula are only those corresponding to these matching. However, the distances currently defined in the literature stay incomplete. For instance, in the system QGUST (Vrain 1990), the algorithm does not deal with numerical values. In (Esposito 1991), since the matching algorithm does not take into account the overall relational structure between entities, the first matching between entities are done in a somewhat arbitrary order. One classical way to cluster a set of examples is to define a numerical distance (subsequently used by a clustering algorithm) expressing the resemblance degree between the examples. This solution is used in Data Analysis (Diday & al. 1985), (Nicolas et al. 1991), Conceptual Clustering (Gennari et al. 1989), (Decaestecker 1991) and in Case Based Reasoning. However, the distances used are not applicable in FQL-based representation since they do not take into account the relations between arguments. Some works have been done in this direction in pattern recognition and graph clustering (Segen 1990), but the used representation languages are often too specific to be usable in a general knowledge representation framework. In practice, the problem of clustering in FOL comes down to the previous one of generalization: to compute a global distance between two examples, we must know the partial distance between the different entities occurring within these examples. Therefore, both generalization and clustering problem in FOL can be solved in the same way: by computing a distance between the entities which occur in the examples. Once this distance is computed, the problems of generalizing and clustering in FGL come down to those existing in VPL, because the problem of multiple matching is solved. In this paper, first, we provide the representation language used to express the examples. Then, we explain the method used to evaluate this distance (we will use a similarity measure), which takes into account all the knowledge expressed within the examples. The representation language used in our approach is based on a subset of the FOL without negation nor functional symbols. The atom (or positive literal) is the ground structure of our representation. An atom is built with a predicate of arity n (with n20), whose different arguments are typed. We distinguish two categories of arguments: the entities (or objects) and the values. The entities are symbols whose meaning depends on their occurrences inside the predicates. The values have their own semantic and must belong to a data type. We associate to our language the following semantic. The predicates qualify the properties of an entity, or the relations between several entities; the values quantify these properties and relations. An example is a conjunction of instantiated atoms : EX: Size (A, large) & Red (B) & Distance (A, B, small) ‘A is an entity whose property Size is large and B is an entity whose property Color is red; The relation Distance between them has a small value” In addition, to each predicate can be associated a weight expressed as an integer. This number allows to express a relevance scale between the predicates of the application domain. Finally, we assume that for each data type T (integer, nominal, taxonomy, etc), there exists a function V-SIMT : T x T + [O..l] allowing to evaluate the degree of “similarity” between any pair of values of the type T. icates In order to evaluate a similarity between any pair of entities (Xi, Xj) belonging to 2 examples, a simple method, used by (Vrain 1990) and (Bisson 1990), consists in comparing the atoms in which these entities appear. In this aim, we establish for each entity Xi the list of its occurrences in the example (denoted Occ (Xi)). Each item of this list is composed by a pair (predicate-name, position-of-Xi). We must take into account the position of the entities in the predicates since the relations are often oriented : for instance, in the relation FATHER (x, y) the two entities do not have the same meaning. To evaluate the similarity between two entities we compute the ratio between the length of the intersection of their occurrence lists by the longest list brought into play. The result is in the interval [O.. l] and can be a resemblance percentage. SIM(Xi,Xj)= Lgth (Occ (Xi) A Occ (Xj)) MAX (Lgth (Occ (Xi)), (Lgth (Qcc (Xj)))) The examples El and E2 below contain four entities PAUL, YVES, JOHN and ANN. The values “male” and “female” belong to a type SET-OF, and the numbers to a type INTEGER. Let us evaluate the similarities: El : aul, yves) & sex (yves, male) & age (yves, 22) & french (pad) E2 : father Qohn, ann) & sex (arm, female) & age (ann, 12) 8r american Q&n) However, with respect to the representation language previously defined, this approach is too crude since some information is not used. We can point out three kinds of deficiencies in this method of similarity computation. isson 83 The first deficiency of this method is that it does not take into account the weight of the predicates. This point can be easily solved by associating to each item of the list of occurrences a value corresponding to the weight of the predicate. Thus, we no longer work with the number of occurrences but with the sum of the weight of these occurrences (denoted I;-WGT). Practically, the role played by the weight is quite simple: a predicate P with a weight of W is taken into account in the computation as if each of the occurrences of P appears W times in the example. The second deficiency of this method is about the use of the values. In the previous example, when we compare the entities YVES and ANN for the predicate AGE, we would like that the similarity value reflects not only the fact that the predicate AGE appears in both examples, but also reflects the “proximity” between the values 12 and 22. In this way, the similarity between YVES and ANN for AGE should provide a value corresponding to the predicate weight multiplied by the similarity between the values 12 and 22. This similarity is computed with the help of the function V-SIM associated to the type involved (for instance: integer in the interval [O..lOO]). This is coherent with the semantic given to our representation language in which values help to quantify the predicates. The third deficiency of this kind of similarity computation is more fundamental. By limiting the similarity to common predicates only, the comparison between PAUL and JOHN concerns only the following aspect: “Both of them have a child, and the one is French and the other is American”. In this way, we do not use all the information expressed in the examples, namely, the fact that the children have different ages and that PAUL has a son and JOHN a daughter. In other words, in order to be thorough and complete, the similarity computation between PAUL and JOHN must take into account the resemblances existing between the entities YVES and ANN to which PAUL and JOHN are connected by the predicate “father”. Intuitively, the closer YVES and ANN are, the closer PAUL and JOHN are too. More generally, the fact that two entities have been connected by the user with the help of a relational predicate means they are semantically dependent. Therefore, for a given pair of entities (Xi, Xj), the similarity computation for this one should take into account the similarities of the other related pairs. Moreover, this dependence relation must be transitive and its strength must decrease in accordance with the number of predicates present in the connecting path. For instance, if A is connected to B and B is connected to C then A influences C, but this influence must be lower than the one of B on C. 5 Similarities as a system of equations From the previous critics, we define a new measure (denoted T-SIM) computing the similarity between two entities X and Y for a given common occurrence. To each occurrence corresponds a pair of atoms in which X and Y appear at the same position R. First, we compute the mean of the similarities between the values. Then, we compute the mean of the similarities between the entities; for X and Y the similarity is 1 since, from the viewpoint of the studied predicate, they are similar. Finally, the similarity for the occurrence equals the product of the two means by the weight (or relevance) of the predicate involved. If they are no entities and/or no values in the atoms, the corresponding terms in T-SIM are equal to 1. Let the two general atoms Tk and T’k: Tk = P (Al, . . . . Ai, . . . , An, Vl, . . . , Vj, . . . , Vm) T’k = P (Bl, . . . . Bi, . . . , Bn, Ul, . . . , Uj, . . . , Urn) where : P is the predicate symbol of the atoms Ai and Bi express the entities (n20) Vj and Uj express the typed values. (m20) dist (Ai, Bi) = 1 when i=R (corresponds to X and Y) dist (Ai, Bi = SIM (Ai, Bi) when i#R dist (Uj, Vj) = V-SIMT (Uj, Vj) (see section 3). As we can easily notice, this method computes the similarity of a pair of occurrences by using the similarity of connected entities. From this point of view, the similarity computation, as defined above, can be rewritten as the problem of solving a system of equations in several unknowns. Here, we define the function V-SIMT in the following way for the values of AGE and SEX: V-SIMage (Vl ,V2) = [ 99 - I Vl - V2 I ] / 99 V-SIMsex (Vl,V2) = If Vl=V2 Then 1 Else 0 Therefore, here are the values of T-SIM found for the common occurrences of FATHER, AGE and SEX. There is no T-SIM for the pairs (Paul, arm) and (yves, john) since there is no common occurrences between these entities. The final similarity between two any entities X and Y corresponds to the sum of the T-SIM evaluated for each common occurrence divided, as previously (section 4), by the total weights of the predicates brought to play by the entities. Let us call “CO” the total number of common occurrences between two entities. The similarity value belongs to the interval [O . . 11 because the denominator always expresses the greatest possible value of similarity. co T-SIM (Ti, T’i, Ri) SIM(X,Y) = i=O MAX (Z-WGT (&c(X)), I;-WGT @cc(Y))) 84 Learning: Inductive In our example, by defining the variables A=SIM (Paul, john) and B=SIM (yves, arm), the similarity computation is equivalent to the system of equations: A =[(W+B/2)1/2 B = [ (A/2 + l/2) + (g/10) + (0) ] / 3 which corresponds to the matrix : A=38% * B=53% Obviously, the found similarity values reflect the choices performed during the definition of the representation language, the writing of the examples and especially the definition of the algorithm. However, the important point is that the scale of similarity pointed out by the method must be stable and coherent with respect to the semantic of the language and the description of the problem. On the one hand, in this similarity measure, some parts of the computation are defined in the algorithm itself. Namely, the way the relations between entities are handled and the information propagated. On the other hand, both processes of value comparison and weight scaling of the predicates can be set in accordance to the problem to solve. Thanks to this point, we obtain a method in which some domain independent behaviors can be pointed out (this is fundamental for user’s understanding), and nevertheless, which stays adaptable to the studied domain. Bringing the similarity computation to the problem of solving a system of equations is interesting because this topic has been extensively studied and many algorithms exist to compute the solution in an optimal way (Golub & Van Loan 1983). In our problem, the system of equations has always the following aspect: 1 k12 k13 . . . kln k21 1 k23 k31 k32 1 . . . . . . . knl 1 The characteristic matrix M is unsymmetrical and square and its order N is equal to the number of entities that could be matched (at least one common occurrence) in the two studied examples. The variables Xi express the similarity of any pair of entities. The most interesting point is that we can easily demonstrate that the matrix M and MT are diagonally dominant and then strictly positive (the determinants of the matrix are never zero). Thereby, the corresponding system of equations can always be solved. 6 Jaeobis’ method Unfortunately, it is not always possible to use the “direct method” to compute the similarities between entities. If one entity at least has two identical occurrences in one example (it appears in the same predicate at the same position) then it is necessary to introduce in the system of equations some non-linear terms. Here is an example : E3 : father (paul, yves) & father (paul, ericz) & ..* E4 : father Cjohn, arm) 8z sex (arm, female) & . . . If we use the similarity previously defined to compute T-SIM for (Paul, john) in the predicate “Father”, we take into account the average similarity between SIM (yves, arm) and SIM (eric, ann). To be coherent, we must compare ANN with the most similar son of PAUL, namely YVES or ERIC. During the computation of T- SIM for (paul, john) we must perform a matching choice guided by the values of SIM (yves, ann) and SIM (eric, arm). Thus, for the predicate FATHER, we have the following T-SIM similarity between PAUL and JOHN : T-SIM = 1/2(l+Best-Match[SIM(yves,ann),SIM(eric,ann)]) The function Best-Match can be in this case the function MAX-OF. By introducing this function, it becomes impossible to express the characteristic matrix of the system of equations. Therefore, to solve our equations, we are going to use an iterative method inspired from the classical Jacobi’s method (Golub $ Van Loan 1983). Jacobi’s method is divided into two steps. In the first step, we initialize the process by roughly evaluating the values of the unknown variables. In the second step, we refine iteratively the value of each variable of the system, by using the values estimated during the previous phase. This second step is performed until the variation of the successive values falls under a predefmed threshold. In our similarity problem, the method is quite similar. During iteration 0 (denoted SIM-0), we initialize the similarity value of each pair of entities by counting the common occurrences of predicates as defined in section 4. During the nth iteration (denoted SIM-n), we compute the similarity between a given pair of entities, as defined in section 5, by taking into account the similarity computed during the previous iteration for the other pairs. In this way, each step of the process refines the results previously computed by propagating the informations along the connected paths. Given a pair of entities appearing in two examples, let us examine this propagation process. During the initialization step (SIM-0) we just take into account the predicates in which both entities directly occur. During the first iteration (SIM-I), we take into account these predicates again, their typed values, but also the similarities between the connected entities which were computed during SIM-0. During the second iteration (SIM-2), we perform the same operations, but the connected entities have already been taken into account their own connected entities at the previous step. In this way, at each iteration, we gain a level in the analysis of the relations between entities. Therefore, the total number of iterations to perform equals the longest path that exists in the examples between two entities. Bisson 85 Nevertheless, since we do not try to have precise values but just to obtain a scale of similarity between the entities, it is not necessary to perform many iterations. Experimentally, we observe that two or three iterations are generally enough to have a good estimation of the similarity between two entities. That is due to the fact that the further the information comes from, the smaller its role in the similarity computation. We can demonstrate that the decreasing rate follows a geometrical law. However, the convergence of this algorithm is not totally ensured. For each iteration, once the matching choice has been done, the similarity computation can be expressed as previously in the form of a characteristic matrix. But, if we are sure that this matrix can be inverted, we are not sure that the sequence of matrix built in the course of the iterations is converging to a solution because the matching choices performed can be different from one iteration to the next. However, this problem seems more theoretical than practical since an instability in the matching occurs when the entities involved are very close. In this case, the errors done on the similarities are low. We are going to illustrate our iterative algorithm. Two examples El and E2 are described with four predicates: triangle, square, color and left. The values used in the predicate color belong to an ordered type described below. El: triangle(a), color(a,white), squaMO,color(b,grey), left(a,b) E2 : square(c),color(c,dark),triangle(d) color(d,black),left(c,d) @ The predicate Triangle, Square, Color have a weight=l; Left has a weight=3 e The items of Color are: (white, light, grey, dark, black) The similarity between two ordered values Vl and V2 is defined as depending of the position of both values in the declaration of the type and of its cardinal (Card). SIM-ord (Vl,V2) = (Card-l) - hS (Vl) - POS (V2)l w-w During the initialization SIM-0, the system looks for the common predicates between the entities (section 4). Let us detail now the iteration SIM-1 for the pair of entities (a,c). The simikuity is null for the Triangle and Square because “a” and “c” do not verify simultaneously these properties. For Color, the similarity depends on the distance between “white” and “dark” (here 0.25). The predicate Left expresses a relation between two entities; for the pair (a,c) the similarity is by definition equal to 1, and for the pair (b,d) we use the previous computed value (they have Color and Left in common, therefore SIM-0 (b,d) = 0.80). The final similarity for Left corresponds to the mean between these two values multiplied by the weight of Left, we obtain 2.70. The process is the same for SIM-2 and SIM-3. As we can see, the values found are converging. 7 Complexity of the computation In AI, it is often difficult to characterize precisely the real complexity of an algorithm since it depends both on the quantity of the inputs and on their internal structures. Here, the problem is complex since our data have any structure. Therefore, we are going to estimate the complexity of the similarity computation by using “average numbers” which is mathematically incorrect, but has the advantage of providing a rough idea of the real cost. Let E be the number of example to compare. Let ME be the average number of pairs of matchable entities. (Which means pairs of entities having at least one common occurrence). Let P be the average number of common predicates between two entities. Let I be the average number of common occurrences between the entities. Let A be the average arity of the predicates. In Jacobi’s method, each iteration consists in computing the similarity between all pairs of matchable entities for all pairs of examples. Therefore, the computation is quadratic both in terms of examples and entities. Complexity SIM-0 : 0 (E2.ME.P) Complexity SIM-n : 0 (E2.ME.P.Iz.A) This may seem expensive. However, when this method is used in a learning tool, numerous bias depending on the studied domain allow to decrease this complexity. A first bias concerns the computing method itself. As previously seen, when entities belonging to a pair of examples do not have several times the same occurrence (I=l), we can use a direct mathematic method to solve the system of equations. The building cost of the characteristic matrix is about the same as the cost of performing one iteration SIM-n. However, in practice, this cost is strongly related to the quality of the indexing of the data within memory. Once the matrix is built, the precise similarities are computed by using efficient algorithms and without any iteration. The next table shows the complexity of the resolution in accordance to the features of the example structures. 86 Learning: Inductive Some simplifications can be done when the learning system works on pre-classified examples. In this case, it is useless to compute the similarity between examples belonging to two different classes. If we have C uniformly distributed classes, the terms E2 falls down to (E/C)2. Typing the entities or more generally introducing some constraints on the possible matching between the entities is also a very eecient way to decrease the complexity of the terms ?vlE and I. In this way, typing allows sometimes to come down from the Jacobi’s method to the direct method. The weight scale defined on the predicates can also be used to prune the search space. For instance, we could decide that the similarity between two entities will be computed if and only if the total weight of the predicates involved in their occurrences is above a given threshold. Condusion In this paper, we have proposed a general method to compute a distance between the different entities of a pair of examples. The representation language adopted to describe these examples is based on a subset of first order logic: it allows to express both relational and quantitative information and to take into account a relevance scale on the predicates. As defined, the similarity measure could be expressed as a system of equations in several unknowns, which can always be solved by a direct or by an iterative method. Finally, this measure can guide accurately and homogeneously some learning processes such as Generalization, Conceptual Clustering or Case-Based Reasoning. This method is used in the learning system KBG (Bisson 1991, 1992). With this system, we have verified on several domains (Electronic design, Vision, etc) that the behavior of the similarity function is coherent. At present, several improvements of the method seem interesting to study, such as the extension of the representation language in order to deal with negation. Deeper studies about the different kind of bias allowing to decrease the complexity of the similarity computation is also an interesting direction to pursue. Acknowledgements : I thank Y. Kodratoff, my thesis supervisor, for the support he gave to this work and all the members of the Inference and Learning group at LRI. BISSON G. 1990. A Knowledge Based Generalizer. In Proceedings of the Seventh International Conference on Ivlachine Learning, 9-15. Austin (Texas). B ISSON G. 1991. Learning of Rule Systems by Combining Clustering and Generalization. In Proceedings of the International Conference Symbolic-Numeric, Data Analysis and Learning ,399-415. Paris (France). BISSON G. 1992. Conceptual Clustering in a First Order Logic Representation. Proceeding of 10th ECAI. Vienna. DECAESTECKER C. 199 1. Apprentissage en Classification Conceptuelle Incrementale. (in french) These de Docteur en Sciences soutenue le 1991, IJniversite libre de Brnxelles. DIDAY E., LEMAIRE J. 1985. Ele’ments d’analyse des dorm&es. (in french). Ed. Dunod. DIDAY E. 1989. Introduction a 1’Analyse des Donnees Symboliques. (in french) Rapport inteme INRIA no 1074. ESPOSITO F., MALERBA D., SEMERARO G. 1991. Flexible Matching for Noisy Structural Descriptions. In proceeding of 12th IJCAI, 658664. Sydney. FISHER D.I-I 1987. Knowledge Acquisition via Incremental Conceptual Clustering. Machine Learning 2, 139-172. GENNARY J., LANGLEY P., FISHER D. 1989. Model of Incremental Concept Formation. Artificial Intelligence Journal, Volume 40, 1 l-61. GOLUB G., VAN LOAN C. 1983. Matrix Computations. John Hopkins University Press. KODRATOFF Y., ADDIS T., MANTARAS R.L., IvlORIK K., PLAZA E. 1991. Four Stances on Knowledge Acquisition and Machine Learning. In proceeding EWSL 91, Springer- Verlag, Porto, March 91,514-533. KODRATOFF Y., GANASCIA J.G. 1985. Improving the generalization step in Learning. Machine Learning 2 an Artificial Intelligence Approach, Morgan Kaufmann Publishers, 2 15-244. LEVESQUE R., BRACHMAN II. 1985. A Fundamental Tradeoff in Knowledge Representation and Reasoning. Readings in Knowledge Representation. Morgan Kaufmann. 4 l-70. MICHALSKI R.S., STEPP E. 1983. Learning from Observation : Conceptual Clustering. In Machine Learning I an Artificial Intelligence Approach, Tioga, 331-363. MUGGLETON S., FENG C. 1990. Efficient Induction of Logic Program”. In proceeding of First Conference on Algorithmic Learning Theory, Tokyo. NICOLAS J. LEBBE J., VIGNES R. 1991. From Knowledge to Similarity. Proceedings of the International Conference Symbolic-Numeric, Data Analysis and Learning, 585-597. QUINLAN J.R 1990. Learning Logical Definitions from Relations. Machine Learning Journal 5,239-266. ROUVEIROL C. 1991. Semantic Model of Induction of First Order Theories. Proceedings of 12th IJCAI, 685-690. SEGEN J. 1990. Graph Clustering and Model Learning by Data Compression. Proceedings of the 7th ICML, 93-100. VRAlN C. 1990. GGUST : A System Which Learns Using Domain Properties Expressed As Theorems. Machine Learning 3, an Artificial Intelligence Approach. Bisson 87 | 1992 | 35 |
1,227 | Knowledge Systems Lab., Comp. Sci. Dept. Stanford Universitv, Stanford, CA-94304 G, Central Res. Lab., itsubishi Electric Corp. 8-I-1 Tsukaguchi-Honmachi Amagasaki, Hyogo 661 JAPAN vlad@cGtanford.edu {t%jino,nishida}@sys.crl.melco.co.jp Decision trees are widely used in machine learning and knowledge acquisition systems. However, there is no optimal or even unanimously accepted strategy of obtaining “good” such trees, and most of the generated trees suffer from improprieties, i.e. inadequacies in representing knowledge. The final goal of the research reported here is to formulate a theory for the decision trees domain, that is a set of heuristics (on which a majority of experts will agree) which will describe a good decision tree, as well as a set of heuristics specifying how to obtain optimal trees. In order to achieve this goal we have designed a recursive architecture learning system, which monitors an interactive knowledge acquisition system based on decision trees and driven by explanatory reasoning, and incrementally acquires from the experts using it the knowledge used to build the decision trees domain theory. This theory is also represented as a set of decision trees, and may be domain dependent. Our system acquires knowledge to define the notion of good/bad decision trees and to measure their quality, as well as knowledge needed to guide domain experts in constructing good decision trees. The partial theory acquired at each moment is also used by the basic knowledge acquisition system in its tree generation process, thus constantly improving its performance. I cm Inductive systems based on decision trees formation are commonly used in machine learning and knowledge acquisition. Therefore, an important amount of research has been devoted to designing and refining algorithms for learning decision trees. However, when a human expert inspects the results of such an algorithm, he will usually point out some inadequacies (which we will call improprieties) in the structure of the generated trees. By interpreting the global situation in which each of these improprieties arises, the expert can recommend corrective actions, according to his particular domain of expertise. The problem of generalizing both the interpretation of improprieties, and the actions recommended by experts to be taken in order to eliminate these improprieties, is equivalent to formulating a theory of the decision trees domain; and in its turn, acquiring this theory amounts to learning efficient ways to learn “good” decision trees, that is trees which satisfy the expert’s knowledge, experience and aesthetical feelings about his own domain of expertise, criteria which can vary slightly from one domain to another. Although a little surprising, representing this theory itself using decision trees came very natural in our work. This work was inspired by the need to provide an interactive knowledge acquisition tool that stimulates the expert in specifying the appropriate knowledge in the appropriate form. The idea of such a tool is not new at all (one of the first such tools was the TElRESlAS system (Davis 1979) designed to help the implementation of EtvWClN based consultation systems (vanlvlelle 1980)), and following it there have been a number of such systems providing different degrees of help for the expert. However, our approach tries to advance one step further in helping the expert articulate the underlying knowledge of his domain, by integrating knowledge acquisition and machine learning through combining domain knowledge acquisition with the use of examples. lThis work was done while the first author was a visiting researcher at System 4G, Central Research Laboratory, Mitsubishi Electric Corp., Amagasaki, Japan Cur knowledge acquisition system named KAISER - a Knowledge Acquisition Inductive System driven by Explanatory Reasoning - (figure 1) (Tsujino, Takegaki, & Nishida, l990), inductively learns classification knowledge in the form of a decision tree and analyzes it using its domain knowledge to detect improper conditions and mismatches between theory and induction results. These improper conditions are then used to guide the expert in changing and augmenting the knowledge base to eliminate them, and to continue the induction cycle. This process supplies a mental stimulus for the expert to help him to refine and better organize his experience and knowledge of his domain KAISER’s impropriety knowledge 88 Learning: IlradLactive From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. represents both what makes a decision tree to be good of bad, and how to improve such a tree. Similar knowledge is issued by constructive induction atheus 1989, 1991; Pagallo 1990) which deal with equivalent questions like when should new features be built or old ones discarded, and what constructive operators to apply to which features. The main difference, however, is that KAISER aims at interactive knowledge acquisition while constructive induction aims as automatic feature generation. Therefore, KAISER generates explanations to help the expert in understanding the problem, and offers a wide variety of impropriety elimination actions in addition to constructing new features - e.g. by pruning, asking for new examples and domain knowledge, redefining the problem (its classes and attributes), etc. It accepts examples in OAV form (i.e., class, attributes and values) and domain knowledge (e.g., abstract rules that examples must/may satisfy). Decision trees are learned inductively from the current set of examples (using an ID3-like algorithm (Quinlan 91986)) and then evaluated based on domain knowledge to detect ‘improprieties’. The key idea of KAISER is that (i) this evaluation process uses a fair amount of heuristic knowledge about decision trees that constitutes a qualitative measure of the goodness/badness of a decision tree, and therefore (ii) by defining an appropriate set of improprieties, their explanations and elimination actions, we can make an intelligent and apt intemiew to acquire more refined domain knowledge from the expert. Domain knowledge includes (possible incomplete/incorrect) knowledge about (i) the relation between classes and the attribute values (i.e., the value of attribute ‘eyes’ must be ‘oval’ if the class is ‘cat’), (ii) ordinal relationships among attribute values (i.e., the value ‘yellow’ of attribute ‘color-of- warning-lamp’ is between the values of ‘red’ and ‘green’) and (iii) derivation knowledge of an attribute value from other attribute values (i.e., the value of attribute ‘weight’ can be calculated from the values of ‘mass’ and ‘density’ by multiplying them together). By referring this domain knowledge, the impropriety detector discovers improprieties such as noisy or unreliable conditions, similar structure, or mismatches between domain knowledge and the decision tree. The impropriety interpreter combines them together to derive more specialized and adequate improprieties. The impropriety selector chooses the most important one to be treated next. To eliminate the impropriety, KAISER prints the associated explanation and actions, which usually prompt the expert for new examples and domain knowledge. In order to acquire “good” knowledge, several researchers have attempted to integrate induction which guarantees the operationality of this knowledge and deduction which validates its reliability. Munez proposed his EG’L-like algorithm for decision tree induction (Nunez 1991), a hierarchy of attribute values and the measurement of attributes cost as background knowle more understandable trees than ID3, bu handle the abstract relationship between classes and attributes which is necessary to acquir and expert interpretable knowledge. proposed an induction system named FOCL (Pazzani & Kibler 1990), which accepts this knowledge in the form of Horn clauses and evaluates and refines them by induction. Although KAISER is mainly based on induction, it also provides deductive explanation-based optimization of induced knowledge by using domain knowledge. Instead of refining all this knowledge automatically, KAISER tries to conduct an interview with the expert and obtain it based on the heuristic knowledge expressed as improprieties. Pazzani also suggests using such heuristics to achieve interactive knowledge acquisition in the KR-FOCL (Pazzani & Brunk 1991) system. The heuristics of KR-FOCL largely correspond to KAISER’s improprieties and their elimination actions. KAISER Generate: -explanations (set of atomic explanations) Impropriety domain knowledge (Learned by Meta-KAISER) Figure 1. System Structure Dabija, Tsujino, a& P&&&h $9 hand-coded by us through an introspection process. As we have expected, some of the experts using KAISER to specify knowledge in different domains (gas composition analysis of electric transformers, diagnosis of electric motors failures, tap changers for electric transformers), expressed some disagreement with the system’s interpretation of certain combinations of improprieties or with its recommendations in some particular cases. Thus, we realized that the impropriety domain theory specified by us was neither complete, nor totally consistent, and therefore was not well enough suited to its purpose of providing an efficient tool for an easy improvement of the domain knowledge base. It became clear that the process of defining the improprieties and their associated explanations and suggested corrective actions is a complex heuristic process. The improprieties domain is best characterized as common sense knowledge, possible domain dependent. It requires learning heuristics about detecting and using improprieties (which are themselves heuristics about incoherences in decision trees), and thus it is part of Heuretics - the study of heuristics as defined by Polya (Polya 1945). What we actually needed was a theory of the domain of classification trees composed of a set of heuristics which specify: (i) WHAT means to have a good/bad decision tree for a given domain (by identifying possible improprieties), (ii) WHY a decision tree is good/bad (by supplying appropriate explanations to all possible combinations of improprieties), and (iii) HOW to obtain a good decision tree (by suggesting the best corrective actions to eliminate these improprieties). The formation of this theory is the ultimate goal of our research, and the tool to formulate it is described in the next section. The primitives used to formulate the theory for the domain of decision trees are the impropriety, the atomic explanation and the alternative. An impropriety represents anything that the expert believes is not right about a decision tree. It may be something definitely wrong about it (like a node which has examples belonging to conflicting classes), or something that the expert finds strange (like a path which appears to lack some essential condition), or even something that may be fine in general, but in this particular case the expert would prefer it otherwise (like two sibling subtrees which are not identical but consist of similar conditions). Appendix 1 presents the improprieties which actually formalize these informal descriptions and their associated explanations and actions, as they have been acquired by our system. By interpreting the reason why such an impropriety appears, the expert can recommend corrective actions (usually new examples and/or new constraints according to his domain knowledge). Each impropriety is associated with a node of the tree (if the impropriety refers to a subtree, then it will be associated with the root of that subtree). One node of the tree may have, simultaneously, a combination of improprieties, which taken together may have different properties than a simple union of the properties of each of these improprieties. Each impropriety and combination of improprieties has an associated explanation (of why it occurred and what it represents), and an associated action (representing a set of possible corrective measures that can be taken to eliminate the impropriety)2. An atomic explanation is an arbitrary large piece of an explanation. It may, but need not, constitute an explanation by itself. The explanations associated with the improprieties are made up of an ordered list of atomic explanations. An alternative is a piece of action that can be taken to eliminate the impropriety (or combination of improprieties) with which it is associated. Each alternative may constitute an action, and each action associated with improprieties is made up of an ordered list of alternatives. These are ordered according to their efficiency in eliminating the impropriety (i.e. less efficient alternatives will eliminate the current impropriety but may create a new, less “important” one), and are not necessarily ordered according to their frequency of use. Therefore there is no statistical measure to be used in learning or in ordering them. Also, though ideally we would like to obtain an autonomous system which 2The set of improprieties and their combinations can be totally ordered according to their gravity, and this way we can propose a theoretical measure of the quality of a decision tree, by taking into account the combined effects described by the discovered improprieties. Let g(i) be the gravity of the impropriety of each node on a scale of 0 to 1, and N the number of nodes in the tree. This quality may then be defined as: Using this measure, we can analyze and compare different decision trees for the same domain, and can improve them by first eliminating the most damaging improprieties. We have experimented with a number of such expressions, and although this is the closest approximation to the concept of the quality of a decision tree as described here, it is still only of theoretical value, and not suitable for implementation in our system; a single formula seems too rigid to encompass by itself the complexity of the problems that may appear in forming decision trees. Therefore, our system uses a set of qualitative heuristic rules for deciding the next impropriety to reduce. An example of such a rule is: “An impropriety that needs a tree modification takes precedence over one that requires domain knowledge refinement”, and their complete set is listed in [Tsujino et. al., 19901. 90 Learning: Inductive may apply a single alternative for each combination of improprieties detected, this is clearly not possible, and the final result will be a list of the best alternative actions to be taken for each impropriety, ordered by their efficiency in obtaining a “better” tree, and ask the expert to choose one of them. The decision trees domain theory consists of the strategy of finding improprieties and the strategy of asking questions. Their initial specification in KAISER proved itself incomplete and difficult to use, and therefore we decided to try to specify a comprehensive theory of the impropriety domain.There are different possible ways to build such a theory. One way would have been by searching the space of such heuristics, approach similar to (Lenat 1982, 1983). However, an automatic evaluation criteria for the generated heuristics was difficult to define, and we felt that an interactive system would have better chances of success.Thus, our first step was to provide a tool for the analysis of the decision trees domain, as well as for the systematic incremental accumulation of knowledge about this domain, while in the same time using this already acquired knowledge to help other domain experts in already deriving better decision trees for their particular tasks.The most natural way for us to build such a tool was to employ a recursive architecture, by bootstrapping the learning system (Pat Langley, personal communication, March 1991) using KAISER to acquire knowledge in the domain of decision trees improprieties from human experts’ experience and skills, knowledge which is in the same time applied by KAISER to generate its explanations and questions. We gave the name Meta-KAISER to the system used to acquire impropriety domain knowledge, since the kind of knowledge it acquires is meta-knowledge from KAISER’s point of view, being used by it to acquire other specialized domain knowledge. One further difficulty was the absence of any actual expert in this domain, (the domain itself was defined by us). However, each expert in a field can also be used as an impropriety domain expert, since he is usually able to articulate his disagreement or discontent with the current classification tree generated by KAISER. This way, the Meta-KAISER system was born, to run in parallel with the domain acquisition system (KAISER) and to acquire knowledge, whenever the opportunity presents itself, for the decision tree improprieties domain. Meta-KAISER is a learning apprentice system which accumulates this knowledge from every expert that uses KAISER in his own domain, and it is our hope that it will eventually converge towards a unified theory of the decision trees domain (maybe application-domain dependent), which will in turn enable KAISER to more efficiently help experts in generating specific domain dependent knowledge bases. It is already known that the performance of a theory formation system is heavily dependent on representation, on the relationship between form and content (Lenat & Brown 1983). Given the specifications of the KAISER system used for this purpose, we have decided to also use a decision tree representation for the heuristics describing the decision trees domain theory. For the strategy of asking questions, we use a multiple class decision tree for each place in the ordered list of alternatives which represents an action, and another tree for each place in an explanation. The classifying (binary valued) attributes are the detected improprieties. Each such decision tree will indicate, for a detected set of improprieties, the best alternative (resp. atomic explanation), if any, to be given to the expert on the corresponding place in a question (resp. explanation). Appendix 2 presents such a tree for the alternatives on the first position in an action, together with a partial list of improprieties and alternative corrective actions currently known to the system. Any kind of representation would be used, it would introduce some kind of bias on the learning process in the improprieties domain. After experimenting with several kinds of such representations, we concluded that this one is the best suited for both the domain to be learned and the system used towards this goal. Though the representation is clearly inconvenient for human interpretation, a simple procedure translates the domain theory it describes into human readable form, generating a set of heuristics which completely describe Meta-KAISER% knowledge of the impropriety domain at any current stage, in a form easily understandable and interpretable (and therefore modifiable) by the human expert. From the expert’s reaction to the way KAISER treats improprieties in the expert domain’s decision tree, Meta-KAISER generates new positive and negative examples in the decision trees domain to support the expert’s point of view and uses these examples to refine its impropriety domain knowledge.The expert is allowed, at any time during the process of knowledge acquisition and decision tree formation in his own domain of expertise, to add or delete an alternative or explanation for a certain combination of improprieties, or to modify the order in which the system suggests explanations or actions for a combination of improprieties. He may also define a new basic impropriety, or a new alternative or atomic explanation. The system generates all pertinent examples suggested by the current situation by adding to the current set of examples new positive examples for the added Dabija, Tsujino, and Nishida 91 alternatives and negative examples for the deleted ones, and the appropriate type of examples in the case of an order modification. In each case, the system checks for possible example conflicts and manages them in a consistent manner. When the expert defines a new concept (impropriety) by specifying a detection procedure for it, the system also automatically generates a set of plausible examples corresponding to the expert’s definition of the concept, and will refine them during subsequent interaction with the expert. After accepting any changes indicated by the expert in the impropriety domain knowledge, Meta-KAISER uses all the examples and domain knowledge acquired so far regarding decision trees improprieties to rebuild the affected classification trees which represent the heuristics for the impropriety domain theory. If necessary, the original KAISER mechanism conducts a dialogue with the expert to resolve any improprieties in these trees. After this process is concluded, the newly generated trees will immediately constitute KAISER’s new strategy of asking questions. This way, KAISER continuously modifies itself (using Meta-KAISER) to improve its performance in assisting the domain experts in specifying their own domain knowledge. Appendix 1 presents an example of a heuristic modified by one of the experts that have worked with our system. Due to the uncertainty and complexity of the impropriety domain, it is possible that, at some point, the expert contradicts one of his previous requests or recommendations regarding KAISER’s treatment of the improprieties in the decision tree, or that he contradicts the opinion of a previous expert in a similar situation. Therefore, Meta-KAISER remembers the history of changes made to the decision trees domain (for each combination of improprieties) by different experts. If such a case happens, the system points out the contradiction and supplies the expert with all the information about that case, allowing the expert to make an informed decision. For the heuristics used by the strategy of finding improprieties we have also employed a decision tree representation and an identical knowledge acquisition method. There is one decision tree for each impropriety type,using as attributes different kinds of tree characteristics: local to a node (like the number of examples supporting the class of a node) or global to the tree (like the existence of two similar subtrees with the same parent). The expert may again define new improprieties or characteristics to consider, or may require modifications to this strategy, similarly to what he can do for the strategy of asking questions. Meta-KAISER generates new examples to support the expert’s requests, and then creates new decision trees which represent the current set of acquired impropriety detection heuristics. We specified an initial impropriety domain knowledge for Meta-KAISER, again using the basic KAISER system. From previous observations of the system behavior, we have defined a basic domain theory for improprieties and have extracted a set of examples which were used by KAISER to produce and refine the set of decision trees which represent the initial heuristics describing the impropriety domain knowledge. (Dabija, Tsujino, & Nishida 1992) presents this initial domain knowledge and an example of a decision tree generated by KAISER for it.This initial knowledge base is currently refined by each expert using the KAISER system in his own domain of expertise, as Meta-KAISER is designed to always work in parallel with KAISER and to respond to any discontent voiced by the expert with regard to KAISER’s suggested explanations and/or actions. Different criteria for judging the quality of decision trees are applied by experts in different domains, and our mechanism is able to accomodate them by learning domain dependent impropriety theories. This way, when KAISER is used to learn decision trees in a given domain, the impropriety detection and interpretation knowledge to be used will be the one acquired by Meta-KAISER in previous applications for the same domain. Further studies are needed to determine whether we can isolate a basic general theory (perhaps as intersection of all domain dependent ones) and whether we can specify the domain dependent theories as variations from the basic one. sod Decision trees are a powerful knowledge acquisition tool, but the algorithms used to build them usually produce improper trees. While implementing a system that aids experts in improving the decision trees generated for their domains, we have found out that the domain of decision trees is in itself poorly understood and lacks a unified theory. The final objective of this research is to provide a theory of what a good decision tree is, and a practical tool for obtaining them, through a complete understanding of the classification trees domain, their inefficiencies and improprieties. However, we believe that this goal can be achieved only by a prolonged and constant analysis of a considerable number of decision trees, applied in different domains. Since there is no actual expert in this domain, the acquisition of this theory must be done from different examples which appear during the knowledge acquisition processes for other domains. The process of articulating the knowledge for the impropriety domain theory seems almost impossible when it is first presented to any person. However, when such situations are actually 92 Learning: Inductive encountered by experts during their attempts to specify knowledge in their own domains, the process of correcting these particular situations seems very natural to the experts. Thus, our first step was to provide a tool (Meta-KAISER) for the analysis of the decision trees domain, as well as for the systematic incremental accumulation of knowledge about this domain, while in the same time using (through KAISER) this already acquired knowledge to help domain experts in already deriving better decision trees for their domains. We have integrated these systems in a recursive, self- bootstrapping architecture which employs a unitary knowledge representation paradigm using decision trees to represent the decision trees domain heuristics themselves. Meta-KAISER is designed to always run in parallel with KAISER, with two advantages: (i) it can use every expert working with KAISER as its own domain expert and will add the opinions of these experts incrementally, and (ii) the partial theory it has acquired at every moment will be used by KAISER in its own operation, thus continually improving its own performance. Moreover, the decision trees domain theory it acquires and uses may be domain dependent, and therefore can be fine-tuned for each particular application domain. Based on this theory we will be able to design a system that analyzes the improprieties in the trees it generates, and is able to recommend (or whenever possible to take by itself) the best suited actions in order to improve these trees. We expect the process of gathering and stabilizing the knowledge for the decision trees domain to be a long one, requiring the use of the KAISER system in the knowledge acquisition process for many particular domains and the interaction of the respective experts with Meta-KAISER. However, the results obtained so far make us believe that eventually, after a large number of runs, Meta- KAISER will gather generally accepted sets of heuristics to describe the decision tree domain theory. While the first experts using KAISER had more trouble in adjusting this knowledge, Meta- KAISER is less and less frequently invoked as it approaches a generally accepted basic theory for decision trees. Appendix 2 presents part of this theory as generated by Meta-KAISER after a few runs. Preliminary results show a clear improvement in KAISER’s performance as confirmed by the experts using it, but further experiments are needed in order to refine the theory learned by Meta-KAISER and to determine the suitability of domain-dependent vs. general decision trees theory. The initially generated trees, representing the decision trees domain theory, were already complex although the heuristics they represent were defined by us in an introspective way. But these heuristics were clearly incomplete, and we expect the corresponding theory to become much more complex by the consistent use of Meta-KAISER together with every application of the KAISER system. It is possible that eventually, after a large number of Meta-KAISER runs, the decision tree domain theory it develops will converge to a quasi-stable set of heuristics. However, total convergence to a perfectly stable theory is probably not possible and even not necessarily desirable, particularly since this theory may have a component dependent on the particular domain for which the decision trees are used. This view of learning systems which do not converge to a perfectly stable state, but may oscillate among a number of partially satisfactory states, has been encountered in other domains too (Dabija 1990), and is also acknowledged by other researchers (Pat Langley, personal communication, June 1991). Our framework is particularly suited for acquiring and developing specific domain dependent theories of decision trees, sensitive to the particularities of different application domains. The authors want to express their thanks to Pat f_angley for several very helpful comments on an earlier draft of this paper. The following dialogue was conducted by KAISER (and Meta-KAISER) while acquiring diagnosis knowledge for the domain of oil isolated electric transformers. The problem at hand is to classify a faulty transformer into one of three classes of faults (Arc, Over Heat and Partial Discharge) based on the composition of the dissolved gas such as H2, CH4 and C2H6. Underlined strings show the responses of the expert. impropriety detected: Ex leaf: his leaf contains thre classes c and OverHeat) that cannot parated because their attribute values are exactly same. Domain knowledge 2 suggests that the class may be OverHeat. (1) Accept the suggestion, and change it into a leaf of class QverHleat. (2) Change it into a leaf of major class (3) Merge it with its largest siblings of cl (4) Name the class. (5) Try further separation. (6) Modify the alternatives. Choose: 1 It was changed into a leaf of class Over impropriety detected: ear-naiss-expsaPlatlon: Dabija, Tsujino, and Nishida 93 A leaf of class Arc failed in explanation because one and only one condition CH4-C2H6 of domain knowledge Arc-Q1 was not satisfied. (1) Graft the condition CH4-C2H the tree. (2) Give new counter examples that arrives to this leaf but the class is not Arc. (3) Modify the alternatives. Choose: 1 CH4-C2H6 will be grafted and the tree expanded. impropriety detected: Twin-nodes: Two siblings Node23 and Node25 refer to the same attribute (H2-C2H2), and the major class in their examples is the same (Arc). (1) Merge the twins and generate a new subtree from the union of their examples. (2) Merge the twins and ignore the smaller sibling (Node25). (3) Merge the twins and ignore the larger sibling (Node23). (4) Modify the alternatives. Choose: 4 Calling Meta-KAISER... Meta-KAISER: (1) Define new impropriety. (2) Define new alternative. (3) Add alternative to impropriety list. (4) Delete alternative from impropriety list. (5) Modify order of alternatives for impropriety list. (6) Return to previous menu. Choose: 1 New impropriety name: Twins-not-in-order Current known alternatives are: 1 - Name the class of a leaf. 2 - Give new examples that will arrive to the current node. . . List the alteriatives (in proper order) to be used with this impropriety: 9 10 16 Please contact the system developer if you need help during the following session: This new impropriety must be (1) detected or (2) derived? 2 Current known improprieties are: 1- NIL-leaf 2- Noisy-node . . List the improprieties from which this new one should be derived: 14 and not11 Here is an example of a decision tree learned by Meta-KAISER to describe the impropriety domain theory. Each leaf specifies the first alternative in each action suggested by KAISER, when the combination of improprieties in the nodes on the path to this leaf is found in an application domain decision tree. The improprieties tested for in the nodes are (Tsujino, Takegaki, & Nishida, 1990): (STl) Noisy node impropriety: a node has few examples, e.g., less than half of the average leaf size. This is a typical clue for pruning. (ST2) NIL leaf impropriety: the class of a leaf cannot be determined by induction because of the lack of examples. This often arises when we use multiple valued (not binary) attributes. (ST3) Inseparable examples impropriety: some examples can not be separated only with given attributes. This impropriety possesses features of both ST1 and ST2. (ST4) Similar node impropriety: two brother nodes refer the same attribute, their entropies are near, and they consist of similar component classes. This is a structural clue to generalize the attribute of their father by merging the links to them. (ST5) Similar class impropriety: more than one node tries to separate the same set of classes at different places in a decision tree. This is a primitive clue for a new attribute for separating the conflicting classes, which is represented by a subtree induced from the subset of examples that belong to the conflicting classes. 94 Learning: Inductive (SE1 ) Contradictory explanation impropriety: the conditions to a leaf are explicable by the domain knowledge that belongs to a different class. primitive elimination action of this impropriety is to specialize the conditions of the miss-matched domain knowledge, and/or to generalize the conditions of the domain knowledge that should match and get higher support factors. (SE2) Multiple explanation impropriety: more than one explanation is suggested by domain knowledge. This impropriety is a clue to relax a condition to lessen the support factor of a piece of knowledge that is not so important, and/or add some weak conditions to strengthen the factor of a preferable piece of knowledge. (SE3) Near-miss explanation impropriety: one and only one condition is missing to explain a leaf. This impropriety is a strong clue for over-fitting. A primitive elimination action is to add the missing condition and expand the tree. (SE4) Tbvin immediate siblings impropriety: the immediate siblings of a node belong to the same class. This impropriety is a clue for noisy examples. A primitive elimination action is to change the node between the siblings into a leaf of the siblings’ class. (SE5) No explanation impropriety: no explanation is given. It is a clue to generalize the conditions of a piece of knowledge that should match, and/or ask for a new piece of domain knowledge for the leaf. The alternative actions recommended on leaves are (Dabija, Tsujino, & Nishida, 19921: (AOl) Name the class of a leaf. (A02) Give new examples that will arrive to the current node. (A03) Give the domain knowledge that will explain the current node (or one of its predecessors). (A04) Merge current node with one of its siblings. (A05) Change the node into a leaf of its major class. (AO6) Remove the examples of the minor class. (A07) Further separate the class of a node. (A08) Give new attributes to separate the class of a node. (A09) Merge two siblings and generate a subtree from the union of their examples (AlO) Merge two siblings and ignore the examples of one of them. (Al 1) Generate automatically a new attribute to discriminate a pair of classes by generating a separate tree for the examples belonging only to this pair of classes. (Al2) Merge two classes into a single one and rebuild the tree. (Al 3) Refine domain knowledge. (A14) Graft a condition to node and expand the tree. (A15) Accept the suggestion of class for node. (816) No action (cancel the impropriety). Dabija,V.G. 1990. Learning by Experimentation in Uncertain Environments. In Proceedings of the 4th ustralian Joint Conference on Artificial Intelligence, ,K.; and Nishida,S. 1992. Theory Formation in the Decision Trees Domain. Journal of the Japanese Society for Artificial Bn tel/igence, 7(3). of Heuristics. Eurisko Appear Fourth National C 236-240. atheus,C.J., and RendeH,L.A. 1989. Constructive Induction n Decision Trees. In Proceedings of the h international Joint Knowledge in Decision Tree Induction. A&chine heaming, 6(3):23-t -250. Pagallo,G. and Haussler,D. 199 Boolean Feature Discovery in Empirical Learning. chine b earning 5 171-99. Pazzani, .J. and Kibler,D. 1990. The Utility of Knowledge in Inductive Learning, Technical Report, TR-90-18, University of California at Irvine. Pazzani,M.J. and Brunk,C.A. 1991. Detecting and Correcting Errors in Rule-Based Expert Systems: An Integration of Empirical and Explanation-based Learning. Knowledge kquisition 3(2) :I 57-l 73 . Polya, G. 1945. How to solve it. Princeton Univ. Press, Princeton, NJ. Quinlan,J.R. 1986 Induction of Decision Trees. achine Learning I(1 ) : Tsujino,M., Takegaki, ., and Nishida, S. 1990. A isition System that Aims at ive Learning and Explanation- Based Reasoning. In Proceedings of the First Japanese Knowledge Acquisition for Knowledge- s Workshop,1 75-190. 1980. A Domain-Independent Aids in Constructing Consultation Programs. Technical Report, STA Stanford Univ. Dabija, Tsujino, and Nishida 95 | 1992 | 36 |
1,228 | rsonal Learning Apprentice Lisa Dent, Jesus Boticariol, John McDermott2, Tom Mitchell, and David Zabowski School of Computer Science Carnegie Mellon University Pittsburgh, PA 15213 Lisa.Dent@cs.cmu.edu Tom.Mitchell@cs.cmu.edu Personalized knowledge-based systems have not yet become widespread, despite their potential for valuable assistance in many daily tasks. This is due, in part, to the high cost of developing and maintaining customized knowledge bases. The construction of personal assistants as learning apprentices -- interactive assistants that learn continually from their users -- is one approach which could dramatically reduce the cost of knowledge-based advisors. We present one such personal learning apprentice, called CAP, which assists in managing a meeting calendar. CAP has been used since June 1991 by a secretary in our work place to manage a faculty member’s meeting calendar, and is the first instance of a fielded learning apprentice in routine use. This paper describes the organization of CAP, its performance in initial field tests, and more general lessons learned from this effort about learning apprentice systems. knowledge constraints Abstract Keywords: learning apprentice, knowledge-based assistants, office automation 1. Introduction Personal knowledge-based assistants have the potential to assist with many daily tasks. For example, a university faculty member might utilize various software assistants to manage courses, to organize the graduate admissions committee, and to manage a meeting calendar. Consider the example of a knowledge-based agent which provides an interface for editing a meeting calendar and advice such as when and where to schedule specific meetings, how long the meeting should last, whether to move an existing meeting to make room for the new meeting, whether to send electronic mail reminders to the participants, etc. The agent might also represent the faculty member in his or her absence by responding automatically to electronic mail requesting certain types of meetings. In order to be effective, such an agent would need considerable regarding the scheduling preferences and of the individual faculty member (e.g., that meetings with graduate students are typically located in the faculty member’s office, that meetings with undergraduates during office hours are typically allocated 30 minutes), as well as knowledge of various individuals within the environment (e.g., that Jon is an undergraduate majoring in computer science, that I7aj is the Dean of computer science). While such a knowledge-based assistant would be helpful, developing and maintaining such a system is difficult because (1) specifying the appropriate program action at design time is possible only for a very unambitious definition of “appropriate”, (2) even if appropriate specifications could be obtained for one person, they must be redefined for each new user, and (3) even if one could specify the task and implement a program, maintaining the system in the face of an evolving world is costly. For these reasons, we believe that personalized knowledge-based software agents are not practical using standard software technology. Instead, we explore here the feasibility of learning apprentice systems, as defined in (Mitchell et al., 1985): We define learning apprentice systems as the class of interactive knowledge-based consultants that directly assimilate new knowledge by observing and analyzing the problem-solving steps contributed by their users through their rwrmal use of the system. More specifically, the thesis of the research reported here is that learning apprentice systems will enable practical development of a large class of personalized software assistants that are currently impractical due to high development and maintenance costs. The thesis rests on three key questions: I. Can one construct interactive assistants that, even when they are initially uninformed, are both sufficiently useful to entice users and able to capture useful training examples as a byproduct of ‘Jesus Boticario is currently with the UNED, in Madrid, Spain. 2John McDermott is with Digital Equipment Corporation, Marlboro, MA. 96 Learning: Inductive From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. their use? 2. can one develop sufficiently powerful generalization methods to automatically acquire general decision-making strategies from this training data? 3. These generalization methods will require a stable set of attributes for describing training examples. Can this set be identified without incurring the same maintenance and customization costs we are attempting to avoid? In this paper we support the above thesis by presenting and analyzing a particular learning apprentice for calendar management, called CAP. CAP has been in routine use since June 1991 by one secretary in our work environment. During this time it has captured hundreds of training examples and has learned to provide useful advice as the user adds new meetings to the calendar (e.g., suggesting the meeting date, location, and duration). Although there have been a number of other attempts to develop learning apprentice systems (e.g., (Mitchell et al., 1985), (Segre, 1988), (Schlimmer, 1990), (Kodratoff & Tecuci, 1986), (Nakauchi et al., 1991), (Kozierok & Maes, 1992)) no previous system has passed the threshold of successful deployment within a real user community. We present here preliminary results from field tests of the CAP system by its first regular user. The following section briefly introduces the calendar management problem. Subsequent sections describe the program and its learning methods, and summarize the learning experiments performed to date. The final section considers lessons learned from this case study and directions for future research. 2. The Calendar Our long term p a personal calendar agent that provides assistance similar tc that of a secretary who has worked for some time with the calendar user, and thus knows the constraints and preferences of that person and the environment in which they work. Such a secretary makes many decisions. Consider, for example, the questions that George’s secretary might consider when Dan asks for a meeting with George: @ When should the meeting be held? Q How long should the meeting last? 8 At what location should the meeting be held? Q Should an existing meeting be moved to make room for this meeting? 8 Should I delay this meeting until next week, or shorten it to make room for it this week? @ Should I ask George whether he wants to meet with Dan, or schedule this myself? Should I send a reminder message to Dan (and if so, when)? The above questions characterize the range of knowledge needed to assist in calendar management. The current prototype CAP system learns to provide advice regarding only the first three s of questions. The other questions represent our goals for the next generation system. 3. interactive editor for adding, moving, copying and deleting calendar meetings, and for displaying various views of the calendar. CAP is interfaced to the electronic mail system and provides commands for sending automatically generated reminder messages to meeting attendees. It contains a knowledge base that summarizes the current calendar state, information on approximately 250 people and groups known to the calen owner (including their positions, departments, offices, and email addresses), descriptions of past user commands (which serve as training data for learning), and an evolving set of rules and neural networks for providing advice to the user. The CAP user interface is based on a set of editing commands (macros) written in a text editor called Gnu- Emacs. These editing commands communicate with a Common Lisp subprocess running THE0 (Mitchell et al., 1991), a framework for learning and problem solving, on which the core of the system is based. THEO provides the frame-based representation for CAP’s knowledge base, inference methods for generating advice to the user, and CAP’s learning methods. A more detailed descrip somewhat earlier version of CAP is given in (Jo al., 1991). Figure 3-l shows the user interface to CAP, which displays a single calendar week. The user has invoked the Add-Meeting command, and the system is therefore prompting the user for the parameters associated with this command: Event-Type, Attendees, Date, Duration, Start- Time, Location, and Confirmed?. At the bottom of the screen in the figure, the system has parameter Duration and has suggested the value of 60 minutes. The user has overridden this value by entering the value 30. Every such parameter value for eveq command is both an opportunity for CAP to provide advice to the user, and an opportunity to collect a training example for refining the knowledge upon which system advice is based. Table 3-l shows a typical training example captured by CAP as a result of the user adding a meeting to the calendar. The first seven attributes of this training example correspond to the seven basic command parameters which the user must supply (or at least approve). The remaining attributes are inferred upon demand by CAP from the given parameters together with its background knowledge and the curren and time. Note that the possible set of training ex attributes includes in principle many more attributes than those shown in Table 3- 1. For example, the entire calendar state at the time the meeting is added is potentially relevant (including features such as the previous meeting with the same attendees, and other meetings during the same week). Dent, et al. 97 Figure 3-l: A Typical CAP Display. add-meeting-request-217: event-type meeting attendees goodman date (25 11 1991) duration 60 start-time 1100 location weh5309 confirmed Ye= action-time 2899823798 action-date (22 11 1991) day-of-week Monday number-of-attendees 1 single-attendee? Yes lunchtime? no end-time 1200 attendees-known? Ye= position-of-attendees faculty dept-of-attendees gsia group-attendees? no sponsor-of-attendees unknown Table 3-l: A Typical CAP Training Example. Note also that when the user enters a parameter, noise may appear in the resulting training example due to misspellings, synonyms or misunderstanding of the intended semantics of the parameter (e.g. use of both weh5309 and 5309 as synonymous locations). In order to minimize this, CAP enforces an evolving set of legal values during type-in of most parameters, and provides automatic completion where possible. CAP’s learning component makes use of these automatically logged training examples. Each parameter of each command provides a separate learning task (e.g., for the AddMeeting command, learning tasks include learning to predict Duration, Location, and Day-of-Week). The learning component is invoked offline, to avoid delay in user response time. CAP currently utilizes two competing learning methods which are provided by the THEO framework: a decision tree learning method similar to ID3 (Quinlan, 1986, Quinlan, 1987), and a neural network learning method, Backpropagation (Rumelhart et al., 1986). CAP converts each learned decision tree into a set of rules (one rule per path through the tree) which are then further generalized by removing any preconditions that do not increase coverage of negative training examples. In neural network learning, the symbolic training example attributes are automatically encoded as network unit values using a l-of-n encoding (i.e., an attribute with n possible values is encoded using n network units, one of which will have the value 1 and the others the value 0). If The Position-of-attendees of event ?x is grad-student, and The Department-attendees of event ?x is robotics; Then The Location of event ?x is weh5309. If The Seminar-type of event ?x is theo; Then The Location of event ?x is weh4605. If The Seminar-type of event ?x is distinguished-lecturer; Then The Duration of event ?x is 90. If The Department-of-attendees of event ?x is computer-science, and The Position-of-attendees of event ?x is faculty; Then The Duration of event ?x is 60. If The Attendees of event ?x is. Mr. Boticario, and The Single-attendee? of event ?x is yes; Then The Day-of-week of event ?x is friday. If The Seminar-type of event ?x is theo; Then The Day-of-week of event ?x is monday. Table 3-2: Some Rules Learned by CAP. Table 3-2 shows a typical subset of rules learned by CAP for predicting meeting Duration, Location, and Day- of-Week. Each of these rules is fairly simple, and fairly mundane, but captures some important regularity or 98 Learning: Inductive preference within the domain. In the current system, CAP has learned a set of approximately 50 such rules for each of its predicted attributes. Some rules cover only a single training example, whereas others cover several dozen examples. 4, Experimental There are several questions to be asked about learning apprentice systems such as CAP. How long does it take to become a useful assistant? How often does the user accept the apprentice’s advice? How does the quality of learned advice compare with the quality that could be provided by hand crafted rules? How many features (attributes) need to be considered to produce useful advice? Can learning keep pace with changes that occur over time in a dynamic environment? Our initial experimentation has been on the prediction of parameters for the Add-Meeting command, specifically prediction of meeting Location, Duration, and Day-of- Week. Briefly stated, our results suggest the following answers to the above questions: CAP can begin to provide useful advice within a month or two. The user’s acceptance of advice regarding meeting Location and Duration varies from 45% to 70% over time, but can be significantly improved by suggesting advice only in cases where the apprentice has high confidence. The quality of the apprentice’s advice is comparable to the advice we were able to produce with hand-coded rules. The apprentice was able to induce its rules by attending to lo-15 features of meetings and meeting attendees. And the pace of learning is fast enough to capture semester- long regularities in our environment. Figure 4-l compares the performance of hand-coded rules for meeting Location against the learned rules and learned neural networks, as the number of training examples is increased. We developed hand-coded rules for each of the parameters of the Add-Meeting command before any learning experiments were conducted, based on our knowledge of the domain and examination of old calendars, at a cost of several person-weeks of effort. The horizontal axis indicates the number of training examples used (the n most recent examples immediately preceding September 30, 1991). The vertical axis indicates the percent agreement between this learned advice and the user for the 60 Add-Meeting commands immediately following September 30. The results of this experiment are typical of those for other data sets and parameters in that they indicate (1) that automatically learned rules provide advice comparable to more costly manually developed rules in this task, (2) that both ID3 and Backprop are capable of learning such knowledge, and (3) that a minimum of 100 training examples should be provided for this learning task. Figure 4-2 gives more detailed results for predicting Location using 120 training examples. The leftmost bar gives the performance of a simple Default method which always suggests the most common Location value. This Figure d-1: Prediction Accuracy versus Training Set Size for Location shows that 58% of the test meetings for Sept. 30 take place in the default location (the office of the calendar owner). The remaining 42% of meetings are split among 13 additional locations. The bars marked Hand-coded and BP indicate performance of the manually developed rules and the neural network respectively. The method labeled ID3- Default applies the ID3 rules to classify the example, or the Default prediction in the case that no ID3 rule applies3. In order to understand the intrinsic difficulty of prediction on this data, we attempted to find a bound on the maximum prediction accuracy that was possible for this set of training and test examples. The bar marked Upper Bound indicates the level of prediction accuracy that can be achieved by assuming that any test example with a previously unseen value for Location cannot possibly be correctly predicted, that test examples with identical descriptions but different classifications will be classified at best using the most common Location value, and that all other test examples will be correctly classified. Notice that the learned classification methods capture approximately half of the predictable cases beyond those with default values. The lightly shaded bar in Figure 4-2 illustrates the potential to achieve higher classification accuracy by reducing coverage of the data. This ability to trade coverage for accuracy is important to the prospects for learning apprentices such as CAP, because it indicates that even in domains where learned knowledge is not strong 31n this particular data set, the ID3 rules cover all default predictions, so the Default method does not contribute any successful predictions here. Dent, et al. 99 Figure 4-2: Prediction of Meeting Location for meetings following Sept. 30, 1991 enough to support reliable decision making in all cases, the agent might still act autonomously in a predictable subset of its domain. One could imagine, for example, a future version of CAP that responds autonomously to email requests for meetings, but only in those cases where the request is covered by highly reliable rules (leaving other decisions to the user). In the figure, the bar labeled ID3- Reliable uses only a subset of the learned rules that CAP estimates to be most reliable. CAP currently judges a rule to be “reliable” if it covers at least two positive training examples, and no negative training examples (the rules given in Table 3-2 are all reliable rules). Using this subset (only 13 of the 53 learned rules), the coverage drops to 52% of the test cases but accuracy over this subset increases to 90%. The tradeoff of coverage for accuracy for ID3’s prediction of meeting Location is depicted in greater detail in Figure 4-3. After the rules are learned using 120 training examples, they are ranked according to their performance on these same examples. The data is 1 2 E w I n 56 3 12.0 W 9 OS- W- 75- 70. w- 14 16 21 43 33 44 45 “l2 41 0 10 w w 40 w w 70 w w loo Petcent Coveregh Figure 4-3: Accuracy vs. Coverage for Prediction of Meeting Location for meetings following Sept. 30,199l sufficiently noisy that many rules do not achieve 100% accuracy even on the training examples. If two rules are equally accurate, the rules which covers more examples is ranked higher. Subsets of the ordered rules are then tested on the 60 examples following September 30. The top rule is tested alone and its performance is plotted as “1” in Figure 4-3, the first and second rule are tested together and plotted as “2”, the first three rules are tested and plotted as “3”, and so on. In cases where a rule does not apply to any of the test examples, its subset has the same accuracy and coverage as the previous subset (without the inapplicable rule). These subsets are not plotted. For example, no “4” appears on the graph because the fourth rule does not apply to any of the test examples. The subset of rules chosen as “reliable” and reported on Figure 4-2 is marked on Figure 4-3 by a double star. Figure 4-3 shows that CAP has the ability to rank its rules and to increase the accuracy of its predictions of meeting Location by selecting a subset of reliable rules. Similar tradeoffs of coverage for accuracy have been obtained when predicting Duration and Day-of-Week, though the absolute accuracies tend to be lower for these attributes. The same tradeoff could also be used on the Backpropagation predictions (by using the real-valued output activations as measures of confidence), but we have not yet done so. Whereas the above data is based on a single set of training and test data surrounding September 30, 1991, the data illustrated in Figure 4-4 summarizes the evolution of system performance due to learning over the interval from 100 Learning: Inductive varying data. 8” 8 1” 8 g 70 W w 40 --- Up w-Bound - -- - P De auk -. - IDB-Default . . . . . . . . . BP - Handcoded Rules Junl4 Jun30 Jul15 Jd31Aug15 At9331 se&l15 scp30 .OCtlS 0 0 W 100 150 wo 260 Number of Training Ekamptes Coltectsd and Evaluation Dates Figure 4-4: Prediction of Meeting Location with 100% Coverage ; ~~~~ <-* ,.’ -- - . . W ‘\,’ --- Up er43ound - .. - w De ault P -. - IDS-Default . . . . . . . . . Bp - Handcoded Rules 70 Junl4 Jun30 Jull5 Jul31 Atag15 A~31 SeplS SepJO Dul.5 0 0 W 1w 150 200 260 Number of Training Exsmptes Cotlected and Evalustion Dates Figure 4-5: Prediction of Meeting Duration with 100% Coverage June 1991 through October 19914. For each of the dates indicated on the horizontal axis, ID3 and Backpropagation were invoked using a training example window of up to 120 meetings immediately preceding that date. Performance of the learned classifiers was then evaluated using the next 60 Add-Meeting commands following that date. The five lines on the graph indicate the classification accuracy of the first five methods on the bar graph of Figure 4-2. All methods here are evaluated relative to 100% coverage of the test data (the tail of the curve in Figure 4-3). Consider the performance of the learned rules and the neural network. Note that the training window does not reach 1W examples until approximately August 15, so performance of learned knowledge before this date is hindered by insufficient data. Following this date, two trends seem to emerge in this data and the corresponding graph for meeting Duration shown in Figure 4-5. First, notice that the date on which the worst performance of learned knowledge is found relative to the Default and Upper-Bound is approximately August 31. At this point, the window of training examples is completely filled with examples from summer break, whereas the test examples (following August 31) are meetings from the fall semester. Thus the especially poor performance in this case may be due to a training set that exhibits regularities that are misleading relative to the test set. Several trends are apparent from Figure 44. First, consider the overall shape of the curves. In spite of the wide variance in predictive methods depicted, they all follow the same general pattern; a pattern dictated by the data which is being tested. The low points during July and August are likely due to differences in the distribution of calendar meetings between the academic semester (which begins September 1) and the summer break. During the semester there are strong regularities in meetings, whereas during the summer the schedule becomes much less structured, and prediction becomes correspondingly more difficult. Other features of the data are less easily explained, such as the high predictability of June meetings. In the remainder of this discussion, we will concentrate on the relative performance of the different methods over this Second, notice that performance of the learned classifiers (for both Location and Duration) change from somewhat below the hand coded rules to somewhat above the hand coded rules as the semester continues. Two factors may help to explain this trend. First, the window of training examples gradually fills with fall semester meetings rather than summer meetings, so that learned knowledge becomes more correct as the semester wears on. Second, as time goes on, permanent changes in the environment (e.g., new meeting rooms, new committees) gradually cause the hand coded rules (written in April, 1991) to become out of date. Based on the data obtained so far, we predict that in the 4Ahhough learning continues up through the present time, October is the latest date for which 60 subsequent test examples are available to evaluate the quality of learning. Dent, et al. 101 future the performance of the learning methods will remain around 65% correct for prediction of meeting Location and 50% correct for prediction of meeting Duration; lower between semesters and over the summer. We may be able to improve these results by adding new input features to the learning methods. For example, the relative fullness of the day or week of a meeting may influence its duration, but this feature is not currently considered by CAP’s learning methods. It may also help to make more features observable to CAR. For example, if the availability of conference rooms were accessible online, it would be a valuable feature for predicting meeting Location. Another promising direction is to target the prediction of a subset of the meetings by using the coverage for accuracy tradeoff discussed earlier. There are several variations of this technique which we intend to explore. Currently CAR learns a completely new set of rules for each date and selects the most reliable rules from these, as measured over the training examples. We plan to extend this by saving reliable rules between learning episodes, enabling the set of reliable rules to grow. We also intend to experiment with different definitions of “reliable” and different methods of sorting the rules. 5. Summary and Conclusions Our experience with CAP provides preliminary empirical support for our thesis that personal learning apprentices can produce useful knowledge-based assistants with significantly reduced manual development and maintenance of the knowledge base. CAP demonstrates that it is possible to design a learning apprentice which is attractive to users, able to capture useful training data, and capable of generalizing from such data to learn a customized knowledge base competitive with hand coded knowledge. Lessons learned from our experience with CAP thus far include the following: CAP is able to collect useful training data for several reasons. First, it is attractive to users even before it has learned any knowledge, because it provides a convenient set of calendar editing and display commands and an interface to the email system. Second, it is able to collect the training examples it requires without imposing a significant extra burden on the user. Third, the interface is designed to maximize consistency in the data it obtains by providing automatic completion and checking of legal values. Some manual updating is still required, even though learning reduces the problem of maintaining the knowledge base. In particular, CAP depends on knowledge about meeting attendees, and as new attendees are encountered this knowledge must be updated. In the current version of the system, the user is prompted for the institution, department, position, and email address of each new attendee who is not yet described in its knowledge base. The system has now built up a knowledge base of about 250 individuals. We are currently considering interfacing the system to an online personnel database to reduce this load on the user. Selection of predictive attributes for each predicted parameter is a critical part of system develop Predictive attributes must be relevant, observabl efficiently computable. Research on learning mechanisms that could handle larger numbers of attributes could ease the task of manual selection of these attributes. We conjecture that the set of attributes we select for each learning task in the calendar system will be stable enough across different users and across time to produce useful personal assistants. There many features that influence meeting Duration, cation, etc. that are unobservable to CAP. For exam meeting Location is influenced by the availability oiconference rooms at the time of the meeting, and meeting date is influenced by the calendars of other attendees. Note that the observability of the world could be increased if other users in our environment start to use the system to maintain their calendars, or if CAP were able to access online information about conference room schedules. Learned regularities in the environment change over time. For example, meetings tended to be longer and fewer during the summer than during the academic semester, and new committees with new meeting locations appeared. In order to succeed in the face of a drifting environment, the time constant of the learner must be shorter than the time constant of the environment. A window of 120 examples, which corresponds to a few months worth of data from our current user, provides sufficient data for predicting meeting Location and Duration, given the 10 or so features we use to predict each. New learning techniques that reduce the number of required training examples uld be a great help. It iis possible to trade ompleteness for improved accuracy in the system’s advice. For example, by using only its most reliable rules, CAP is able to increase its accuracy for predicting Location to 90% at the cost of reducing its coverage to only 52% of the examples. The ability to make this tradeoff opens the opportunity for highly reliable autonomous operation (e.g., for responding automatically to meeting requests when the user is absent) in which the system responds only to cases for which it believes its response is most reliable. In addition to the research issues raised above, extensions to CAR that we hope to explore in the future include (1) giving copies to multiple users to determine CAP’s ability to customize to each, (2) exploring the opportunities for collaboration and co-learning among several copies of the system, (3) adding the ability to provide pro-active advice (e.g., to suggest that a reminder message should be sent, rather than waiting for the user to initiate the action), and (4) extending CAR to respond automatically to email requests for meetings. 102 Learning: Indu’ctive We wish to thank Jean Jourdan for helping develop the initial version of CAP, and Alan Christiansen, Lonnie Chrisman and Sebastian Thrun for providing helpful comments on this paper. We also thank the entire THEO group at CMU for providing the framework in which CAP is written. This research was sponsored in part by the Avionics Lab, Wright Research and Development Center, Aeronautical Systems Division (AFSC), U. S. Air Force, Wright-Patterson AFB, OH 45433-6543 under Contract F33615-90-C-1465, Arpa Order No. 7597 and by a grant from Digital Equipment Corporation. The views and conclusions contained in this document are those of the authors and should not be interpreted as representing the official policies, either expressed or implied, of the U.S. Government or of Digital Equipment Corporation. References Jourdan, J., Dent, L., McDermott, J., Mitchell, T., and Zabowski, D. (1991). Interfaces that Learn: A Learning Apprentice for Calendar Management (Tech. Rep.) CMU-CS-91-135. Carnegie Mellon University. Kodratoff, Y., and Tecuci, G. (1986). DISCIPLE : An Iterative Approach to Learning Apprentice Systems (Tech. Rep.) UPS-293. Laboratoire de Recherche en Informatique, Universite de PARIS-SUD. Kozierok, R. & Maes, P. (1992). Intelligent Groupware for Scheduling Meetings. Submitted to CSCW-92. . Mitchell, T.M., Mahadevan, S., and L. Steinberg. (August 1985). LEAP: A Learning Apprentice for VLSI Design. Proceedings of the Ninth International Joint Conference on Artificial Intelligence. , Morgan Kaufmann. Mitchell, T. M., J. Allen, P. Chalasani, J. Cheng, 0. Etzioni, M. Ringuette, and J. Schlimmer. (1991). Theo: A Framework for Self-improving Systems. In VanLehn, K. (Ed.), Architectures for Intelligence. Erlbaum . Nakauchi, Y ., Okada, T., and Anzai, Y. (May 1991). Groupware that Learns. Proceedings of the IEEE Pacific Rim Communications, Computers and Signal Processing. , IEEE Press. Quinlan, J.R. (1986). Induction of Decision Trees. Machine Learning, l(1), 81-1U6. Quinlan, J.R. (August 1987). Generating Production Rules from Decision Trees. Proceedings of the International Joint Conference on Artificial Intelligence. , Morgan Kaufmann. Rumelhart,D. E.,G. E. Hinton, & R. J. Williams. (1986). Learning Internal Representations by Error Propagation. In Rumelhart, D. E., 6. L. McClelland, & the PDP Research Group (Ed.), Parallel Distributed Processing.. MIT Press. Schlimmer, J.C. (November 1990). Redstone: A Learning Apprentice of Text Transformations for Cataloging. Unpublished. Segre, A.M. (1988). Machine Learning of Robot Assembly Plans. Kluwer Academic Press. Dent, et al. 103 | 1992 | 37 |
1,229 | asackna, CA 91109 We address the problem of selecting an attribute and some of its values for branching during the top-down generation of decision trees. We study the class of im- purity measures, members of which are typically used in the literature for selecting attributes during deci- sion tree generation (e.g. entropy in ID3, GID3*, and CART Gini Index in CART). We argue that this class of measures is not particularly suitable for use in clas- sitication learning. We define a new class of measures, called C-SEP, that we argue is better suited for the pur- poses of class separation. A new measure from C-SEP is formulated and some of its desirable properties are shown. Finally, we demonstrate empirically that the new algorithm, O-BTree, that uses this measure indeed produces better decision trees than algorithms that use impurity measures. Empirical learning from examples is receiving considerable attention in terms of research and applications. Programs that learn from pre-classified examples aim at circumventing the knowledge acquisition bottleneck in the development of expert systems. The problem is due to the fact that human experts find it difficult to express their (intuitive) knowledge of a domain in terms of concise, correct situation-action rules. Empirical learning algorithms attempt to discover relations between situations expressed in terms of a set of attributes and actions encoded in terms of a fixed set of classes. By examining large sets of pre-classified data, it is hoped that a learning program may discover the proper conditions under which each action (class) is appropriate. Learning algorithms typically use heuristics to guide their search through the large space of possible relations between combinations of attribute values and classes. A powerful and popular such heuristic uses the notion of selecting attributes that minimize the information entropy of the classes in a This heuristic is used in the ID3 algorithm [ 131 and its extensions, e.g. GID3 [2], GID3* [6], and C4 1141, in CART [l], in CN2 [3] and others; see [I I] and [6] for a general discussion of the attribute selection problem. We focus our attention on algorithms that learn classifiers in the form of decision trees. Decision tree based approaches PO4 Learning: Inductive sets. In addition and tberefore not top-down decision tree generator pecially the GID3* algorithm, in real-world industrial ications in semicon- ductor manufacturing [IO] and in other domains such as astronomical data processing at Caltech [7]. In brief, a top-down, non-backtracking decision tree al- gorithm is given a data set of classified examples expressed in terms of a set of attributes. The attributes may be nom- inal (discrete, categorical) or continuous-valued (numeri- cal). The algorithm tirst discretizes the continuous-valued attributes by partitioning the range of each into at least two intervals. For each discrete (or discretized) attribute, the algorithm lirst formulates a logical test involving that at- tribute. The test partitions the data into several subsets. For example, in ID3 [ 131 and C4 1141, the value of the attribute is tested, and a branch is created for each value of the at- tribute. In GID3* [5, 61, only a subset of the values may be branched on, while the remaining values are grouped to- gether in one default branch. A selection criterion is then applied to select the attribute that induces the “best” parti- tion on the data. Once selected, a branch for each outcome of the test involving that attribute is created. This creates at least two child nodes to the parent node, and the algorithm is applied recursively to each child node. The algorithm refrains from further partitioning of a given node when all examples in it belong to one class, or when no more tests for partitioning it can be formulated. Thus a leaf node predicts a class (sometimes probabilistically). We claim that the single most important aspect that deter- mines the behavior of a top-down non-backtracking decision tree generation algorithm is the attribute (test) selection cri- terion used. The most widely used attribute selection criteria appear in the form of average impurity measures. This is a family of measures designed to capture aspects of partitions of examples relevant to good classification. Earlier compar- isons of selection measures compared measures within the class of impurity measures (see below) and concluded that the choice of selection measure from within that class makes little difference [l]. Later in this paper we show that a new From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. class of measures is needed. IA S be a set of training examples with each example e E S belonging to one of the classes in C = (Cl, C2, . . . , Ck). The class vector of S is a h-vector (cl, ~2, . . . , Q), where each @i is the number of examples in S that have class Ci E C: Q = I(e E Slchw(e) = Ci)l. Note that the CRASS vector is a vector from the space Nk, where N denotes the set of natural numbers. The class probability vector of S is the corresponding vector in [0, ilk: A set of examples is said to be pure if all its examples belong to one class. Hence, if the class probability vector of a set of examples has a component with value 1, the set is pure. An extreme case of impurity occurs when all components of the class vector are equal. To quantify the notion of impurity, a family of functions known as impurity measures [l] is defined. We use 4 to denote a function that assigns a merit value to a class probability vector. Definition 1: Let S be a set of training examples having a class probability vector PC. A function 4 : [O,llk ---) 31 such that q5(PC) 2 0 is an impurity measure if it satisfies the following conditions: 1. #(PC) is minimum if 3i s.t. component PCi = 1. 2. #(PC) is maximum if Vi, 1 5 i 5 H, PCi = +. 3. #(PC) is symmetric with respect to components of PC. 4. #(PC) is smooth (differentiable everywhere) in its range. Conditions I and 2 of the definition are intended to fix the well-understood extreme cases. Condition 3 insures that the measure is not biased towards any of the classes. The fourth condition sometimes appears as a requirement that 4 be convex downwards with respect to any of the components of PC. Usually this makes the analysis easier as well as providing desirable computational properties. However, we need to evaluate the impurity of a partition induced by an attribute on a set of examples. Let PC(S) be the class probability vector of S and let A be a discrete (or discretized) attribute defined over the set S. Assuming that A partitions S into the sets Sl , . . . , ST, the impurity of the partition is defined as the weighted average impurity of its component blocks: (P(S,A) = Finally, the merit assigned to attribute A due to its partition of S is proportional to the reduction in impurity after the partition. Hence, A@@‘, A) = #(PC(S)) - ip(S, A). It has been widely accepted that functions within this family are interchangeable for use in selecting attributes to branch on, and that they result in similar trees [I, 121. This Figure 1: Two Possible Binary Partitions (3 classes). is not surprising since they all agree on the minima, maxima and smoothness. For example, if we assign k #(PC(S)) = &t(S) = - PCi lOg( PCi) i=l then @(S, A) would be the entropy of the partition E(A, S) and A@(S, A) would correspond to the information gain Gcrin(A, S) as defined in [ 1, 131. Another impurity mea- sure, used in [l] and claimed to result in trees similar to those resulting from information entropy minimization al- gorithms, is the Gini index. To obtain the Gini index we set 4 to be #(PC(S)) = PCi ’ PCj. i#j In this paper, we shall treat entropy as representative of the class of impurity measures. We shall examine the behaviour of entropy over the space of possible partitions and identify certain regions where entropy prefers partitions that do not conform with our intuitive expectation of how a “good” selection criterion should behave. Consider a set S of 110 examples of three classes ( C 1, C2, C3 ) whose class vector is shown in Figure 1. Assume that the attribute-value pairs (A, CZ~) and (A, a~) induce the two binary partitionson S, ?rl and 7r2, shown in the figure. Note that partition ~2 separates the classes CI and C2 from the class C3. However, the information gain measure prefers partition ‘~1 (gain = Sl) over ?r2 (g&n = .43). Note that if partition ~2 is accepted, the subtree under this node has a lower bound of three leaves. On the other hand, the subtree under the node created for partition ~1 has a lower bound of six leaves. This does not necessarily imply that partition ‘~2 will generate a tree with a smaller number of leaves. IIowever, unlike information entropy, intuitive evaluation of the two partitions clearly prefers ?rz to ~1 (assuming no further lookahead is allowed). If an attribute- value pair manages to isolate some Classes from the rest, then it is clearly relevant to classification. As a matter of fact, if it were possible to obtain the tree with the minimal number of leaves, i.e. exactly one leaf for each of the Ic classes, then each node test will isolate some classes from others. If an attribute-value pair were not really correlated with the classes it isolates, then the probability of it causing a total class separation partition is lower than that for an overlapping classes partition. If the goal is to generate a tree with a smaller number of leaves, then we should expect the selection measure to be especially sensitive to total class Fayyad and Irani 105 separation. The case illustrated in Figure 1 gets worse when the number of classes grows (see [6] for further examples). The primary task of a classification learning algorithm is to separate differing classes from each other as much as possible, while separating as few examples of the same class as possible. If a partition is selected that does not separate differing classes apart, then the learning algorithm must find later partitions that do. Hence, by separating classes, the algorithm avoids postponing an action that sooner or later must be taken. The price for not ng it sooner is the likelihood of increasing the number of leaves in the tree. It is worthwhile noting that if the learning problem has exactly two classes, then the entropy heuristic no longer suffers from this problem, since class purity and class separation become the same. For this reason, in the binary class case, we believe that entropy is a good measure for classification. The above discussion clearly illustrates that the informa- tion entropy heuristic is not sensitive to class separation, if there are more than two classes in the problem. Since a partition is evaluated by averaging the impurity of its com- ponent blocks, the entropy measure can only detect class separation indirectly. We argue that a “proper” selection measure for classification should compare the class vectors of the partition blocks directly. Other evidence for the in- appropriateness of the entropy measure originates in our empirical experience with ID3, ID3-IV, GID3, and GID3*. ID3-IV uses the gain ratio rather than entropy as a selection measure (see [13].) GID3 and GID3* differ from ID3 and ID3-IV in that rather than branching on every value of the se- lected attribute, they branch on a few individual values while grouping the rest in one default branch. All these algorithms perform better than ID3. For example, we have very strong empirical evidence that GID3* consistently produces better trees than ID3 [5,6]. How does this reflect on the merit of the entropy measure as a selection criterion? Our answer to this question takes the form of an argument illustrating that for any node in the tree, ID3 always selects the partition having the minimum entropy among all possible partitions using the selected attribute. In particular, we shall show that the partition selected by GID3* is always one that has an equivalent or higher entropy than the partition selected by ID3. Hence, if following the minimum entropy heuristic is a good idea, then ID3 should in principle generate better decision trees. Yet the empirical evidence points strongly to the contrary. Given a data set at a node during decision tree generation, the partition ?ri selected by ID3 to partition the data at the node is a refinement of the partition selected by GID3* for the same node. This is obvious from the fact that GID3* branches on a subset of the individual values branched on by ID3. In addition, Given a data set at a node during decision tree generation, the partition ?rr selected by ID3 to partition the data at the node has the same or lower class informa- tion entropy than the corresponding partition ~2 selected by GID3* for the same node, as shown by: a 1 If the partition induced on a set S by attribute A is a refinement of the partition induced on S by attribute A’, then the class information entropy of the former is lower than that of the latter: E(A, S> 5 E(A’, S). See Lemma B.O. I in [63. of? cl Although ID3 always selects partitions having lower en- qhopies than those selected by GID3*, empirical experience clearly indicates that this consistently leads to worse deci- sion trees. The interpretation of this proposition is that al- though information entropy captures reasonable properties that make it useful for attribute selection, whatever it cap- tures is not geared towards generating good trees. Whence, a method that consistently does not minimize entropy (GID3*) leads to the discovery of better trees. Other evidence for the correctness of this claim is presented as part of our discus- sion of the binary tree hypothesis (to be stated later). A similar situation occurs with ID3-IV [ 131. Although the IV measure and the gain-ratio were introduced by Quinlan as an ad hoc solution to overcome the problems with very fine partitions (large number of values), ID3-IV seems to outperform ID3. This gives us another instance of an algo- rithm that purposely avoids minimal entropy partitions and yet produces better trees. Another reason to suspect the suitability of information entropy to the task of attribute selection derives from re- sults in communication and information theory. It has been shown that the entropy minimization heuristic tends to yield decision trees with near-minimal average depth [8]. Al- though this may be a desirable property from a communi- cation/vector quantization application perspective, we have strong empirical evidence indicating that trees with low aver- age depth tend to have a large number of leaves and a higher error rate for the data sets encountered in a large variety of domains [4, 61. We therefore claim that, from a machine learning perspective, the information entropy heuristic aims at an inappropriate goal: minimizing the average depth of a tree. A consequence of Lemma 1 and entropy’s preference for finer partitions is that the entropy measure is insensitive to within-class fragmentation: the separation of examples hav- ing the same classes. For example, consider two partitions of a set of examples, one (~2) being a refinement of the other (~1). Further assume that both partitions are pure, i.e. each of their component blocks consists of examples of the same class. Both evaluate equally under entropy-the average entropy of each partition being zero. However, the partition ~2 necessarily fragments examples from some class while partition x1 does not. The extra fragmentation simply results in more leaves. The information entropy measure suffers from two ad- ditional deficiencies. The first occurs in cases where the training set contains a majority of examples from one class, the G&n measure is then necessarily depressed away from its possible maximum for all possible partitions. This is because the entropy of each set, prior to partitioning, is low. In such situations various partitions approach each other in merit when evaluated under entropy. The second defeciency with the entropy measure is what is referred to as the information paradox in [ 151. The basic problem is that a set with a given class probability vector 106 Learning: Inductive evaluates identically to another set whose class vector is a permutation of the tirst. Thus if one of the subsets of a set has a different majority class than the original but the distribution of classes is simply permuted, entropy will not detect the change. owever, a major change in the dominant class is generally considered as evidence that the attribute value is actually relevant to classification. In general, entropy, like all other members of the family impurity measures, is insensitive to permutations in the components of the class probability vector. The reason for this is that it measures the impurity of each set in isolation. So the information paradox le only indirectly when we average the entropies of the two sets in the partition. I we have listedl above seven properties that we ations that the information entropy measure is not particularly well-suited for use as an attribute selection measure. It is QIU' hypothesis that a measure that is better behaved than entropy, will lead to the generation of better decision trees. We shall formulate such a measure. We have shown in [6] that for every decision tree, there exists a binary decision tree that is logically equiva- lent to it. Thus, exploring strictly binary trees does not reduce the space of possible decision trees that one may discover. At this stage we make a further claim: T ypothesis : For a top-down, non- ision tree generation algorithm, if the algorithm applies a proper attribute selection measure, then selecting a single attribute-value pair at each node and thus constructing a binary tree, rather than select- ing an attribute and branching on all its values simul- taneously, is likely to lead to a decision tree with fewer 1MVeS. We have no formal proof of this hypothesis: only infor mal analysis and an empirical evaluation of it. Due to space constraints’ we do not include the analysis. The empirical results supporting this hypothesis are given later in the pa- per as part of our comparison of all the algorithms. The interest reader is referred to the detailed presentation in FL at are the ramifications of this hypothesis on decision tree generation algorithms? We claim that it establishes a reasonable strategy for designing decision tree generation algorithms in general. Rather than branching on all attribute values of a selected attribute, branch on a single one-the “best” value. When we formulated the GID3* algorithm, we were considering the problem of deciding which sub- set of values of an attribute are relevant for classification when the information entropy is used as a measure of merit. The discussion presented above gives a different answer to the attribute-value selection problem: Rather than deciding which subset of values of an attribute is relevant based on whatever measure is being used’ always select one value at a time; however, insure that the measure of attribute-value pair merit is a proper measure for classification. we have decided to generate strictly binary de- cision trees in which each branch test specifies a single bute-value pair, we turn our attention to the design of a proper selection (merit) measure for attribute-value pairs. Rather than following the tradition of impurity measures and defining desirable properties with respect to a single set, we shall specify desirable properties with respect to a partition on a set. Given a test T on an attribute A and a set of training ex- amples S, T induces a binary partition on the set S into: S = ST USy7, where ST = (e E Sle satisfies T), and %, = s - ST. We propose that a selection measure should in principle satisfy the properties: 1. It is maximum when the classes in ST are disjoint with the classes in %, (inter-class separation). 2. It is minimum when the class distribution in ST is identical to the class distribution in ST. 3. It favours partitions which keep examples of the same class in the same block (intra-class cohesiveness). 4. It is sensitive to permutations in the class distribution. 5. It is non-negative, smooth (differentiable), and symmetric with respect to the classes. This defines a family of measures, called C-SEP (for Class SEParation), for evaluating binary partitions. By keeping as many examples of the same class together, we are aiming at leaves with high example support. This leads to better predictors and to a smaller number of leaves. Recall that the number of leaves and the expected error rate are related to each other, as shown in [4,6], and that the training support per leaf serves as a semantic (vs. syntactic), estimate of rule generality [6]. Note that the conditions listed above force members of the family to compare class distributions directly since many of the properties are not detectable if each class vector is eval- uated in isolation (c.f. impurity measures). The heuristic that is instantiated by selection measures that are members of the impurity measures family (including entropy) may be summarized as: Favor the partition for which, on average, the dis- tribution of classes in each block is most uneven. On the other hand, members of the C-SEP family of mea- sures represent the following heuristic: Favor the partition which separates as many dif- ferent classes from each other as possible, and keeps examples of the same class together. re For a h-vector V, l]Vll denotes the magnitude of V: I IWI = 4 c x2* i=l Let VI be the class vector of ST and V2 be the class vector of s-7. In order to measure class overlap/separation directly, Fayyad and Irani 107 what should be done is to examine the “angle” between the two class vectors. In general k-space, what we need is a measure of the degree of orthogonal&y of the two vectors. Two vectors are orthogonal when their non-zero components do not overlap. We implicitly assume that the test r is a meaningful test in that it induces a non-trivial partition on S’ i.e., we implicitly assume that S7 # S,, # 8. Since our vectors are in nf”, the angle is at a maximum when it is 90’ and is minimum when it is 0’. One measure of the angle is to take its cosine. The cosine of the angle between two vectors VI and V2,6(V,, V,) is given by: cos qv,, V2) = Vl OV2 IlYdl l llk2ll where ‘0’ represents the inner (dot) product: k VlOyp c &i&i- i=l It is minimum when the two vectors are orthogonal and is maximum when they are parallel. ‘Iwo vectors are parallel when one is a constant multiple of the other, whence the angle between them is zero. Selection Measure ORT : For a set S of training ex- amples and a test r inducing a binary partition on S into S7 and S,, having class vectors 771 and V2, respectively, the orthogonality measure is defined as ORT(q S) = I - cos B(Vp, V2). I I Note that this measure takes values inthe range [0, I]. A maximum value indicates that the vectors are orthogonal. We now show that the orthogonality measure possesses the desirable properties listed above. Proposition 1 The QRT measure possesses the following properties: 1. If the class probability vectors of the two sets in the par- tition are identical, then QRT is minimum. 2. If ORT(r, S) = 0 then the class probability vectors of the two sets in the partition of S are identical. 3. The QRT measure is maximum iff the classes in S7 are disjointfrom the classes that appear in Sy7. 4. The measure QRT favours partitions which keep like classes in the same subset. Proof: See [6]. cl Note that condition 2 for minimum is equivalent to the condition under which information gain is minimum: Corollary 1 Gc&a(T, S) = 0 e QRT(q S) = 0. hofi See [6]. cl Although the conditions under which Ge&a and ORT are minimum are equivalent, the conditions for maximum are not. This is where ORT possesses desirable properties that information entropy does not. Actually, the conditions under which ORTachieves its maximum value, 1, are more general than those under which entropy is as its minimum, 0: Co~~~lBlaq 2 Given a test 7 that induces a binary partition on a set S of training examples containing more than one class, then E(r, S) =O a QRT(r,S) = 1. See 161. 0 ly that the ORT measure results in better trees. We name the binary tree algorithm that uses the ORT measure 0-BTree. We turn our attention to comparing the performance of with that of ID3, ID3-IV, GID3*,and ID3-BIN. ID3 mply the ID3 algorithm modified to branch on a single attribute-value pair at each node (hence generating strictly binary trees). We have earlier claimed that ID3-BIN should consistently outperform ID3 and ID3-IV. The results of this comparison will also demonstrate this fact as a side effect. The data sets used for empirical evaluation were of two type: synthetic and real-world. The synthetic data was used since we have complete control over it so it can serve as a clean controlled test. A set of rules was constructed manu- ally for diagnosing a well-understood portion of the Reactive Ion Etching (RIE) process in semiconductor manufacturing. The rules were verified physically and semantically by the domain experts. This set of rules was used to generate ran- dom examples. Each rule specifies the values of only a few of the available attributes. Since attributes not ap ing in a rule’s precondition are considered irrelevant to the classification task, random values are generated for those attributes in order to obtain examples. The goal of the learn- ing program is to attempt to rediscover, or approximate, the original set of rules. This establishes a reference point for comparing the performance of the learning algorithms. The learning task contains 8 attributes (all discrete) and 6 classes. The classes are roughly equally likely. Hence the error rate of a “naive” classifier that always guesses the most common class for any example should not be lower than 83%. In order to eliminate random variation, IO independent experiments were conducted on IO independently generated random RlE data sets’. The performance is measured by number of leaves and error rate. The error rates were col- lected by classifying examples in a separate fixed test set of 1886 examples. The results reported will all be in terms of ratios rela- tive to GID3* performance. Figure 2 shows the relative performance for the RIE random experiments. In this do- main, better trees were generated by 0-BTree. One note to make here is that although GID3* and O-BTree managed to discover trees with the minimal number of leaves on many occasions, the trees were actually different. As a matter of fact, 0-BTree was able to discover the original (optimal) tree on some trials. This tree has a zero error rate. The second type of data used consisted of a real-world application data set from semiconductor manufacturing (HARR90), and some publicly available data having only ‘A training set consists of 150 examples on the average. 108 Learning: Inductive for RIE-random Domain Ratios for RSErandom Domain (cxIB*al.Q) (Gm3*rl.O) 8.8 6.8 2.5 6.0 4.2 2.0 3.4 1.6 2.6 1.8 1.0 1.0 0.2 0.5 GHPPS’ ED3 U&3-W H)$-Bm 0.BTREE GIDS’ ID8 HXi-I[v HD!B-BW O--E Algorithm JUgotitb Figure 2: Performance of Various Algorithms (Relative to GID3*) in RIE Domain. discrete attributes. These were the foreign imports auto- mobile insurance data (AU’IG), the soybean disease data sets (SOYBEAN) and the mushroom classification task (MLJSHRM). We avoid using data that have continuous- valued attributes in order to avoid confusing the issue of at- tribute selection and continuous-valued attribute discretiza- tion which is performed prior to selection. We would like to isolate the effect of attribute selection as much as possible. The results for these domains are shown in Figure 3. A data set worth noting here is the SOYBEAN data. This data happens to have attribute-value pairs that induce total class separation at the very root of the tree. Although this did not decrease the number of leaves, the error rate of the tree gen- erated by 0-BTree was a little over haIf the corresponding error rate for ID3-BIN. We may therefore conclude that the ORT measure lead to more appropriate choices than those made by minimizing the information entropy at any stage (ID3-BIN). We have proposed a new use in selecting attributes during decision tree generation. The selection measures that are widely used in the decision tree induction literature typically use a selection mmure from the family of impurity measures. We illustrated why we believe that the C-SEP family is more appropriate in the context of top-down decision tree generation. The main difference between the two families of measures is that im- purity measures examine each subset in a partition separately withoutparticularregard to cross-subset class overlap. They detect overlap indirectly by averaging over all the subsets. While indirect detection works well in the two-class case, it deteriorates as the number of classes grows. Since members of the C-SEP family of measures evalu- ate a partition by comparing two class vectors, they require that partitions be strictly binary. This does not limit the expressive power of the trees produced. Furthermore, we hypothesize and informally argue that binary decision tree generation is likely to produce better trees than ID3-type branching. is hypothesis is verified empirically by com- paring the performance of ID3 with its binary tree generating counterpart, ID3-BIN. The family C-SEP, with the ORT measure being represen- tative of its members, was defined using the same approach used in defining the family of impurity measures: specify where the maxima and minima should occur, and hope, with some assumptions of smoothness, that the behavior of the measure on the cases in-between the minima and maxima is “reasonable.” The term “reasonable” implicitly means: correctly captures the aspects that make a partition good. The reason we make this implicit assumption is that, we, as designers of these measures, do not really know how to evaluate the partitions that constitute neither minimal nor maximal partitions according to the measure(s) being con- sidered. Given a choice among several impure partitions, the entropy heuristic calls for favoring the partition in which the average class distribution is most uneven. On the other hand, faced with the same choices, the ORTmeasure favours the partition for which unlike classes overlap least and like classes overlap most. However, we have no clear reason to favor one measure over the other in those regions, since we do not know which is the better partition in the first place. What we did in this paper is point out that for some regions that are “well-understood” by us, the impurity measures fail to detect good partitions. This failure was a consequence of the fact that impurity measures are defined on single sets. We corrected this aspect by defining a new family of measures. The proper approach to the selection measure design prob- lem must first answer this question in some justifiable way: When can we say that one partition is better than another, meaning that it will eventually lead (or is likely to lead) to a tree with fewer leaves given the training data? The intent of this paper is to point out that the problem of attribute selection is an important, and not yet adequately addressed problem. Future work here seems impossible without a formalism which allows us to answer the general question of what constitutes a better partition when gener- ating a tree in a non-backtracking framework. We know how to answer the question if we perform a full lookahead search, but that is computationally infeasible. If there are Fayyad and Irani 109 Edativo Ratios of Error Ratea (GIDS*d.O) Ratios of Number of Leaves (GID3*=1.0) 2.2- 2.0- 1.8. 1.6. 1.4. 1.2. l.O-. 0.8. 0.6 - 0.4 + q ID8 q IDS-N Ll q IDS-BIN q O-BTREE Data Set Data Set Figure 3: Performance of Various Algorithms (Relative to GID3*) over SeveraI Domains. Ku attribute-value pairs in the problem, and the minimal tree has tz leaves, then an exhaustive search requires exploring at least (c:r) possible trees, since the binary tree has n - 1 internal (decision) nodes. A good selection measure should not be expected to find the minimal tree since this would make P=NP, a fact that we generally consider unlikely to be true. However, this does not rule out the possibility of solving the problem in the sense of formulating a measure that leads to minimal or near-minimal trees with high prob- ability. Such an investigation is, of course, left as future work. Acknowledgments Thanks to R. Uthu~samy for valuable comments on this paper. The work described in this paper was carried out in part by the Jet Propulsion Laboratory, California Institute of Technology, under a contract with the National Aeronautics and Space Administration. References [l] Breiman, L., Friedman, J.H., Qlshen, R.A., and Stone, C.J. (1984). Classification and Regression Trees. Monterey, CA: Wadsworth & Brooks. [2] Cheng, J., Fayyad, U.M., lrani, K.B., and Qian, 2. (1988). “Improved decision trees: A generalized version of lD3.” Proceedings of the Fi@h International Conference on Ma- chineLearning(pp. 100-108). SanMateo, CA: Morgan Kauf- mann. [3] Clark, P. and Niblett, T. (1989). “The CN2 induction algo- rithm.” Machine Learning, 3,26 1-284. [4] Fayyad, U.M. and lrani, K.B. (1990). “What should be mini- mized in a decision tree?” Proceedingsof the Eighth National Conference on Artificial Intelligence AAAI-90 (pp. 749-754). Cambridge, MA: MlT Press. [5] Fayyad, U.M. and lrani, K.B. (1991). “A Machine Learning Algorithm (GlD3*) for Automated Knowledge Acquisition: Improvements and Extensions.” General Motors Research Report CS-634. Warren, MI: GM Research Labs. [6] Fayyad, U.M. (199 1). On the Induction of Decision Trees for Multiple Concept Learning. PhD dissertation, EECS Dept., The University of Michigan. 110 Learning: Inductive [7] Fayyad,U.M., Doyle, R., Weir, N. andDgorgovski, S. (1992). “An automated data classification technique for reducing a very large astronomy data set.” Proceedings of ISY Conf on Earth and Space Science Information Systems. Pasadena, CA: NASA-JPL. [8] Goodman, R. and Smyth, P. (1988) “Decision tree design from a communication theory standpoint.” IEEE Transac- tions on Information Theory 345. [9] lrani, K.B., Cheng, J., Fayyad, U.M., and Qian, 2. (1990). “Applications of Machine Learning Techniques in Semicon- ductor Manufacturing.” Proceedings of The S.P.I.E. Confer- ence on Applications of Artificial Intelligence VIII (pp. 956- 965). Bellingham, WA: SPlE: The lntemational Society for Optical Engineers. [lo] lrani, K.B., Cheng, J., Fayyad, U.M. and Qian, Z. (1992) “A Machine Learning Approach to Diagnosis and Control with Applications in Semiconductor Manufacturing.” A chapter in Intelligent Modeling, Diagnosis, and Control of Manufactur- ing Processes. B. Chu and S. Chen (Eds). World Scientific Publishing. [ 1 l] Lewis, PM. (1962). “The characteristic selection problem in recognition systems.” IRE Transactions on Information Theory, IT-& 171-178. [12] Mingers, J. (1989) “‘An empirical comparison of selection measures for decision-tree induction.” Machine Learning 3:4 (3 19-342). [ 131 Quinlan, J.R. (1986). “Induction of decision trees.” Machine Learning I, 81-106. [14] Quinlan, J.R. (1990). “Probabilistic decision trees.” In Ma- chine Learning: An Artificial Intelligence Approach, Volume III, Y. Kodratoff & R. Michalski (Eds.) San Mateo, CA: Mor- gan Kaufmann. [ 151 Smyth, P. and Goodman, R.M. (1991) “An information theo- retic approach to rule induction from databases.“IEEE Trans- actions on Knowledge and Data Engineering, to appear. | 1992 | 38 |
1,230 | David Perry Greene and Stephen F. Smith Graduate School of Industrial Administration / School of Computer Science Carnegie Mellon University Pittsburgh, PA 15213 dglv@andrew.cmu.edu and sfsQisl1 .ri.cmu.edu Abstract COGIN is a system designed for induction of sym- bolic decision models from pre-classed examples based on the use of genetic algorithms (GAS). Much research in symbolic induction has focused on techniques for reducing classification inaccu- racies that arise from inherent limits of underly- ing incremental search techniques. Genetic Al- gorithms offer an intriguing alternative to step- wise model construction, relying instead on model evolution through global competition. The diffi- culty is in providing an effective framework for the GA to be practically applied to complex in- duction problems. COGIN merges traditional in- duction concepts with genetic search to provide such a framework, and recent experimental results have demonstrated its advantage relative to basic stepwise inductive approaches. In this paper, we describe the essential elements of the COGIN ap- proach and present a favorable comparison of CO- GIN results with those produced by a more sophis- ticated stepwise approach (with support post pro- cessing) on standardized multiplexor problems. Introduction The conventional symbolic induction problem is one of formulating a decision model which maps combina- tions of attribute-values into a set of classes. Given a set of pre-classed examples, the goal is to find the “simplest” model which most accurately classifies the data. To deal with the combinatorics of construct- ing symbolic models, traditional techniques rely on a deterministic stepwise bias. While this bias makes search tractable, it is acknowledged that in noisy or complex spaces, such an approach can result in mis- formed models which predict poorly [Breiman et.al. 19841. Recognizing this, a large body of research has focused on rectifying this problem through the ad- dition of auxiliary techniques (e.g., pruning[Quinlan 19861, model transformation[Quinlan 19871, alternative fitness measures[Holte, Acker & Porter 19891, or repre- sentation change[Matheus & Rendell 19891). In many cases these corrective techniques have shown very good results. An alternative approach to dealing with the com- binatorics of constructing symbolic decision models is to move outside of the confines of stepwise search paradigms. Genetic Algorithms (GAS) offer one such possibility, which has motivated the development of COGIN, a GA-based system designed specifically for symbolic induction from examples. In a recent study, initial experiments with COGIN demonstrated the clear superiority of it’s genetic based search over basic stepwise approaches on problems of increasing com- plexity. A recent study by Quinlan [Quinlan 198S] presents an opportunity to compare the performance of the COGIN approach versus a post-processing alternative. In his paper, Quinlan provided comparisons with an earlier genetic classifier on the statistical multiplexor problem. The multiplexor is a particularly interest- ing function because it provides the type of non-linear complexity which is problematic for decision tree build- ing. In this paper we describe the conceptual frame- work underlying the COGIN approach and examine three multiplexor functions of increasing scale com- plexity under conditions of varying training samples sizes (as described in Quinlan’s original paper). GAS and Symbolic Induction In contrast to deterministic, step-wise search mech- anisms, the GA is a probabilistic search technique, based on the concept of adaptive efficiency in natu- ral organisms, where solutions are iteratively developed and improved through competition among alternatives [Holland 19751. A GA maintains a pool of candidate solution structures (the population). A search cycle is iterated where structures in the current population are selected and recombined to produce new structures Greene and Smith 111 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. (offspring) for evaluation, and a new population is con- figured. Selection of structures is biased by their eval- uated utility (fitness), and new structure creation via recombination acts to exploit the constituent “build- ing blocks” of high performance structures. From a sampling perspective, this leads to an increasing con- centration of trials to those regions of the search space observed to be most profitable. By their probabilis- tic nature, GAS are relatively insensitive to both non- linearities and noise. The reader is referred to [Gold- berg 19891 for an introduction to the theory and prac- tice of GAS. Previous research in GA-based learning provides two basic paradigms for mapping this basic search model to the symbolic induction problem. The first, designated the Pitt Approach (e.g., [Smith 1983, Grefenstette, Ramsey & Schultz 1990, DeJong & Spears 1991]), as- sumes a population of alternat,ive decision models. In this case, the fitness measures driving the search relate to the overall worth of candidate models (e.g., classi- fication accuracy). The second paradigm, referred to as the Classifier System (or Michigan) approach (e.g., [Holland 1986, Wilson 19871): alternatively assumes that the population collectively constitutes the current decision model, with individuals representing specific model components. In this case, fitness measures re- flect the utility of individual components within the model (e.g., discriminability), and the overall perfor- mance of the model is evaluated externally. In either paradigm, a model representation is required that al- lows generation of meaningful new structures (models or model components) through simple recombination of existing structures. In the context of symbolic in- duction this is most simply accomplished by represent- ing a decision model as a disjunctive set of rules, where each rule (i.e. model component) contains a single con- junctive condition over an ordered list of attribute val- ues and a classification. CQGIN Effective use of genetic search in the context of con- ventional symbolic induction requires a framework that promotes the fundamental model building ob- jectives of predictive accuracy and model simplicity. Such a framework is provided by COGIN (COverage- based Genetic INduction), a system for genetic in- duction of symbolic decision models from pre-classed examples[Greene & Smith 19921. COGIN manipulates a population of single condition rules which are col- lectively interpreted as a candidate decision model, analogous to the classifier system paradigm mentioned above. However, in direct contrast to the incremen- tal learning assumptions of classifier system research, COGIN is designed to directly exploit the static struc- ture of the conventional symbolic induction problem. In particular, coverage of the examples in the training set is used throughout the search as both an explicit constraint on model complexity (size) and a basis for creating a pressure toward appropriate classification diversity within the model. On any given cycle of CO- GIN’s search, newly created rules compete with rules in the current decision model to cover subsets of the training set, and survival of a given rule is a direct func- tion of its ability to better fill a particular classification niche in the evolving model than any competitors. In more detail, the operation of COGIN proceeds as follows. At the start of each cycle, a percentage of the rules constituting the current model are randomly paired and recombined to produce a set of new can- didate rules. Each of these rules in then assigned a fitness measure and pooled with the original rules of the current model for competitive configuration of a new model. The fitness of a given rule is defined as lexicographically-screened entropy (using the formula- tion given in [Mingers 19891). That is, maximum en- tropy within a given interval of classification error. The heart of the cycle is the competition step, which is carried out through application of a coverage-based filler. The filter operates by “allocating” training ex- amples to rules that match them in fitness order. The output of the filter, which constitutes the new decision model, is the set of rules receiving at least one exam- ple, and all other candidate rules are discarded. After the new model has been determined, its predictive ac- curacy relative to the training set is evaluated. During this process, fitness is used as a basis for conflict res- olution, and a default rule (the majority class of the training set) is invoked in the event that no rules match a given training set example. If the new model yields a higher predictive accuracy than the best model eval- uated thus far in the search or performs at the same level and contains fewer rules than the previous best model, then it is retained as the new best for future comparison and the cycle repeats. The overall search process terminates after a pre-specified number of iter- ations, and the best model produced during the search is taken as the final model. Figure 1 provides a representative example the dy- namics of this search process, assuming a training set of 7 examples, with examples 1, 2 and 5 of class 0 and examples 3, 4, 5, and 7 of class 1. Notationally, each rule in the figure is depicted by number, followed by the set of matching examples, its action and its fitness. For example, [rl:l3 4 6-+1(.089)] indicates that rule rl matches examples 1, 3, 4 and 6, assigns class 1 and has a fitness of .089. At generation IV the current model 112 Learning: Inductive Fll F20 Training set size 50 100 150 200 100 200 300 400 500 200 400 600 800 1000 COGIN I Decision Tree I Derived Rules 1 size 14.7 17.6 15.1 14.8 33.1 33.4 30.1 26.4 23.6 73.0 122.2 137.8 113.0 84.1 I ~ I I accur . size accur. 87.2% 10.2 76.9% 94.5% 21.8 91.8% 97.4% 22.2 98.0% 98.1% 24.6 100% 70.1% 23.0 63.2% 93.3% 41.8 78.1% 97.2% 63.4 86.6% 99.4% 68.6 92.5% 99.9% *** 59.7% 49.0 68.8% 69.0% 95.8 82.1% 82.4% 121.0 87.4% 93.1% 171.4 92.4% 97.5% *** size 3.0 4.0 4.0 4.0 5.8 8.2 8.0 8.0 accur. ss.l% 100% 100% 100% -Tmz-- 98.3% 100% 100% *** --ilEEr 88.0% 97.4% 98.3% *** 8.6 14.4 16.2 18.4 Table 1: Comparative Performance of COGIN and C4 with C4.5 (a descendant of C4) on the 6 multiplexor problem was reported. Running both systems in so called “batch-incremental” mode, GABIL was found to outperform C4.5 with respect to online predictive performance over time as new examples were sequen- tially accumulated. COGIN, on the other hand, is directly based on the same “batch learning” assumptions as C4, and designed specifically to solve the same class of sym- bolic induction problems. As such, Quinlan’s study provides benchmark results against which the perfor- mance of COGIN can be directly evaluated, and such an evaluation would appear to provide an isolatable as- sessment of GA-based and stepwise search procedures in a batch learning context. Moreover, since [Quinlan 19881 reports both the performance results obtained by C4’s decision tree building approach (with pruning) and the improved results obtained by C4’s additional “decision tree to production rule” post-processing op- tion, this study provides the opportunity to assess the performance of a COGIN’s GA-based inductive frame- work relative to a step-wise inductive framework with various levels of auxiliary support techniques. In the following section, the results of this experimental com- parison are reported. Experimental Table 1 contains performance results obtained with COGIN on the 6, 11, and 20 bit multiplexor prob- lems (denoted F6, Fll, and F20 respectively) along with the results previously reported for C4 in [Quinlan 19881. For each problem instance (F6, Fll, or F20), runs were made with five randomly generated training sets of each designated size and performance of the gen- erated decision model was evaluated with respect to a holdout set of 1000 previously unseen cases. Given the stochastic nature of COGIN’s search, five runs were made with each generated training set. In each run, COGIN’s search was terminated after a pre-specified number of iterations (generations). In the case of the F6 experiments, the search was run for 300 generations; in the Fll and F20 experiments the search was run for 600 generations. The performance results reported in Table 1 for each training set size reflect averages across these runs (25 in the case of COGIN, 5 in the case of the deterministic C4). The average model sizes shown reflect number of rules or number of decision tree nodes as appropriate. From the results, we see that COGIN performed comparably to C4 across all instances of the multi- plexor problem considered. In both the 6 and 11 bit multiplexor problems, COGIN achieves accuracy levels above 90% at the same training set size as is achieved by C4’s post generated rules (although at lower abso- lute levels), and in the largest 20 bit multiplexor prob- lem an accuracy level over 90% at the training set size of 800. Thus, from the standpoint of predictive accu- racy, both C4 and COGIN appear to scale similarly across problems in terms of number of examples re- quired. COGIN outperformed the decision tree results fairly consistently over all problems. Only on the simplest f6 multiplexor did COGIN fail to attain a higher abso- lute accuracy than the C4 decision tree at the largest training set size (98.1% vs 100%). However, given the probabilistic nature of COGIN’s search, convergence to a correct solution on all runs was not really expected. In this case, COGIN did in fact achieve 100% accuracy Greene and Smith 113 gen: N Coverage-Based Filter gen: N+l gen: Nt2 Figure 1: An example of COGIN’s search process consists of 4 rules rl, r2, r3, r4 which correctly predict 6 of the 7 examples (86%) in the training set and have an average rule fitness of .070. Three new rules are created on this cycle (r5, r6, r7), and the “allocation” of training examples within the filter (depicted) leaves no examples for rules r2, r3, or r6. These rules are dis- carded and the remaining rules (r7, r5, rl, r4) become the generation N+ 1 model. Notice that this model has the same number of rules of the generation N model, but actually a lower predictive accuracy. At the same time, the average rule fitness has increased, suggesting the emergence of better building blocks. After gener- ating new rules and applying the filter, at Generation N + 2 the new model is in fact seen to correctly clas- sify all training set examples. While this example was created for illustrative purposes, this behavior is quite representative of the behavior indicated by the perfor- mance graph of actual system runs (2) discussed later in the paper. In a recent paper[Greene & Smith 19921, we pre- sented experimental results comparing the perfor- mance of COGIN with two other representative sym- bolic induction systems, CN2[Clark & Niblett 19891 and ID3[Q um an * 1 19861, that provided evidence of the utility of this approach. More specifically, COGIN demonstrated the leverage provided by genetic search across model building problems of varying complexity, with performance differential trends that suggest that this leverage increases with problem complexity. On a suite of 53 test data sets representing 2 and 4 class problems with increasingly complex generating func- tions and increasing levels of noise, COGIN performed significantly better than either compared system across all the experimental factors (number of classes, noise, form of data generating function). At the same time, these results compared only the basic search techniques; no use of any pre or post pro- cessing techniques was made in running any of the three systems. Our goal in the next section is to exam- ine the performance of COGIN’s basic search process against the published performance of ID using well de- veloped rule refinement procedures on a standardized multiplexor problem. The Multiplexor Problem The multiplexor family of problems is defined for rE = 1 , . . . as follows: an ordered list of n = iE + 2” binary valued features is interpreted as a bit string of k ad- dress bits and 2” data bits, where the binary encoding of the address bits indexes the particular data bit that is activated (turned on). The problem presents an in- teresting challenge for step-wise induction approaches, since address bits do not independently relate to clas- sification outcome and the apparent discriminability of individual features is thus misleading. Multiplexor problems have been the subject of prior comparisons of GA-Based and step-wise learning pro- cedures. In [Wilson 19871, the ability to effectively learn multiplexors of size 6, 11, and 20 was reported using a classifier system approach. A subsequent study [Quinlan 1988] applied C4 (a decision-tree approach descended from ID3) to this same set of problems and, despite the potential difficulty raised above, achieved comparable levels of performance using much smaller numbers of training examples. Further research on this problem set within the incremental classifier system paradigm for GA-based learning (e.g. [Booker 1989, Liepins & Wang 19911 has yielded sizable reductions in the number of examples required, but still consider- ably more than required in [Quinlan 19881. Arguments are made in [Liepins & Wang 19911 that, in fact, the classifier system paradigm can be expected to be inher- ently inefficient with respect to number of examples re- quired in learning stationary Boolean concepts. In [De- Jong & Spears 199 l], a comparison of GABIL (a GA- based concept learner based alternatively on the Pitt paradigm of evolving complete classification models) 114 Learning: Inductive in 20 of the 25 runs that were averaged. Performance levels achieved by COGIN and the C4 decision tree on the 6 multiplexor problem at smaller training set sizes were fairly equivalent, with the exception of the smallest training set size of 50, where COGIN’s abso- lute performance level exceeded even that of C4’s post derived rules. In the 11 multiplexor problem, COGIN’s perfor- mance dominates that of the decision tree at all train- ing set sizes and closely tracks the performance levels achieved by C4’s post-derived rules. At the 400 train- ing set size level, for example, COGIN achieved 100% accuracy on the 1000 unseen examples in 17 of the 25 averaged runs. The progression of 20 multiplexor problems yielded the only cases where the performance of the C4 deci- sion trees outperformed the models generated by CO- GIN. At the smallest training set sizes of 200 and 400, the performance differential is around 10%. At the training set size of 600, the differential narrows to 5% and COGIN’s performance finally overtakes the deci- sion tree’s at a training set size of 800. Some account- ability for this unexpected performance differential at lower training set levels might be attributable to char- acteristics of the specific training sets used by each system. But, with training set sizes representative of such low proportions of the instance space (e.g. .035% at the 400 level), it seems evident that entropy coupled with the additional lexicographic bias toward accurate rules does not provide sufficient search bias. With respect to average size of the generated models (i.e., number of rules or decision tree nodes), a second interesting scaling relationship can be seen. In all three multiplexor problems, the size of the generated deci- sion tree model increases monotonically with the size of the training set. In the case of COGIN, however, a different pattern is observed. The size of the model ap- pears to increase with training set size only to a point, and then decreases fairly steadily as training set size is further increased. This pattern can be clearly seen in the 20 bit multiplexor problem. While it is difficult to extrapolate from the training set sizes tested, the observed pattern does suggest that the turning point occurs when a training set size large enough to provide sufficient grist for COGIN’s search is reached. In the 11 multiplexor problem, the size of the model steadily de- creases as increasingly larger training sets are provided. Thus, as the training set size is increased, the models generated by COGIN not only get more accurate but also more succinct. The sizes of the C4 post-derived rule sets are significantly smaller than COGIN’s. How- ever, here COGIN is at a distinct disadvantage, since a portion of the decision tree to rule set transforma- generatbns Figure 2: Performance curves for 800 example F20 problems tion involves selection of a default rule and a shift to a 1 class recognition model. This representational shift was not attempted within COGIN. Thus, for exam- ple in the 6 multiplexor problem, the minimal correct model for COGIN is 8 rules as opposed to 4 for C4. The dominant indicator of the computational com- plexity of COGIN’s search process is the number of candidate rules evaluated. We indicated above that all COGIN experiments were run for a fixed number of generations (300 for F6; 600 for Fll and F20). Consid- ering the average total number of individual rule eval- uations performed over all F6 and F20 runs (6413 and 106,458 respectively), we find roughly a g-fold compu- tational increase in computational expense as in scal- ing from F6 to F20 ( compared to the B-fold increase reported for C4 in [Quinlan 19881). Finally, Figure 2 gives some insight the dynamics of COGIN’s search. It tracks the averages of four values over time across one run on each of the five 800 example training sets for the 20 bit multiplexor problem: the % accuracy on the training set, the % accuracy on the 1000 example holdout set (of course unavailable to the system during the search), the average fitness of the rules in the current model, and the number of rules in the current model (the curves of the last two values are scaled to the maximum value seen). We can see that 100% accuracy on the training set is achieved very early on in the search, with the size of the current model generally increasing as well (a function of the dominant accuracy bias). At this point, the entropy bias takes over and focuses the search toward more general rules and correspondingly smaller models (rule sets). Greene and Smith 115 Discussion In this paper we examined the relative performance of a new GA-based framework for symbolic induction, embodied in the COGIN system, with an inductive system built around decision tree construction. While previous research has established the advantage of CO- GIN relative to basic stepwise search approaches, much work has gone into rectifying the limits of incremental approaches and it is these total systems which establish the performance standards for comparison. The multi- plexor problem provides a search space which presents inherent difficulties for stepwise learning, and Quin- lan’s C4 demonstrates the large performance gains pos- sible through post-processing. Nonetheless, the com- parison presented showed the basic COGIN system to perform surprisingly well. COGIN was seen to gener- ate models which were generally superior to pruned trees and often comparable to the converted rules. These results were achieved despite COGIN’s reliance on a fairly minimal amount of search bias and no post processing. Our examination of generated models sug- gests opportunities for further improvement through post processing and this is one direction of our cur- rent research. Generally speaking, the results clearly demonstrate the viability of GAS in symbolic induc- tion from examples contexts. They also complement the earlier results of [DeJong & Spears 19911 in re- futing preliminary conclusions reported in [Quinlan 1988] about the comparative abilities of GA-based ap- proaches. Acknowledgments This work was supported in pa.rt by the US ARMY Hu- man Engineering Laboratory under contract DAAD05- 90-R-0354, and the Robotics Institute. References L. Breiman, J. Friedman, R. Olshen, and C. Stone. Classification and Regression Trees. Wadsworth Inc., 1984. L. Booker. Triggered rule discovery in classifier sys- tems. In D. Shaffer, editor, Proceedings 3rd Interna- tional Conference on Genetic Algorithms, Washing- ton, DC, June 1989. Morgan Kaufmann Publishers. P Clark and T. Niblett. The CN2 induction algo- rithm. Machine Learning, 3(4), March 1989. K.A. DeJong and W.M. Spears. Learning concept classification rules using genetic algorithms. In Pro- ceedings 11th International Conference on Artificial Intelligence, Syndey, Australia, August 1991. Morgan Kaufmann Publishers. D.E. Goldberg. Genetic Alorithms in Search, Op- timization and Machine Learning. Addison-Wesley Publishing, 1989. J.J. Grefenstette, C.L. Ramsey, and A.C. Schultz. Learning sequential decision rules using simulation models and competition. Machine Learning, 5(4), Oc- tober 1990. D.P. Greene and S.F. Smith. Competition-based in- duction of decision models from examples. Machine Learning, (forthcoming). R.C. Holte, L.E. Acker, and B.W. Porter. Concept learning and the problem of small disjuncts. In Pro- ceedings 11th International Joint Conference on Arti- ficial Intelligence. Morgan Kaufmann Publishers, Au- gust 1989. J.H. Holland. Adaptation in Natural and Artificial Systems. University of Michigan Press, Ann Arbor, MI, 1975. J.H. Holland. Escaping Brittleness: the Possibilities of General Purpose Learning Algorithms Applied to Parallel Rule-Based Systems, volume 2. Tioga Press, Palo Alto, CA, 1986. G.E. Liepins and L.A. Wang. Classifier system learn- ing of boolean concepts. In Proceedings 4th Inter- national Conference on Artificial Intelligence, San Diego, CA, July 1991. Morgan Kaufmann Publishers. C.J. Matheus and L.A. Rendell. Constructive induc- tion on decision trees. In Proceedings 11th Inter- national Joint Conference on Artificial Intelligence. Morgan Kaufmann Publishers, August 1989. J.R. Quinlan. The effect of noise on concept learn- ing. In Machine Learning: An Artificial Intelligence Approach, volume II. Morgan Kaufmann Publishers, Palo Alto, CA, 1986. J.R. Quinlan. Generating production rules from de- cision trees. In Proceedings 10th International Joint Conference on Artificial Intelligence. Morgan Kauf- mann Publishers, August 1987. J .R. Quinlan. An empirical comparison of genetic and decision-tree classifiers. In Proceedings 5th Inter- national Conference on Machine Learning. Morgan Kaufmann Publishers, June 1988. S.F. Smith. Flexible learning of problem solving heuristics via adaptive search. In Proceedings 8th In- ternational Joint Conference on AI, Karlsruhe, West Germany, August 1983. S.W. Wilson. Classifier systems and the animate problem. Machine Learning, 2, 1987. 116 Learning: Inductive | 1992 | 39 |
1,231 | Ste in Daniel Suthers, Beverly es ent of Computer Science University of Massachusetts Amherst, Mass. 01003 (suthers, bev, corne~l}@cs.umass.edu Abstr4Wt Human explanatory dialogue is an activity in which participants interactively construct explanatory models of the topic phenomenon. However, current explanation planning technology does not support such dialogue. In this paper we describe contributions in the areas of discourse planning architectures, heuristics for knowledge communication, and user interface design that take steps towards addressing this problem. First, our explanation planning architecture independently applies various constraints on the content and organization of explanation, avoiding the inflexibility and contextual assumptions of schematic discourse plans. Second, certain planning operators simulate a human explainer’s efforts to choose and incrementally develop models of the topic phenomenon. Third, dialogue occurs in the medium of a “live information” interface designed to serve as the representational medium through which the activities of the machine and human are coupled. Collectively these contributions facilitate interactive model construction in human-machine dialogue. The Discrepancy AI Technology eory an This research addresses the automated generation of explanations in the context of interactive dialogues, particularly in educational settings. Explanation is viewed as a conversation in which agents articulate, elaborate on, transform or reject conceptual models of the topic phenomenon. This view is consistent with the recent literature on “situated cognition,” which portrays knowledge and karning as partially embedded in the social and physical world [ 1,6, 171. Human dialogue is seen as a process of constructing and sharing representations that are meaningful because the dialogue participants perceive and act upon these representations 133. However, current technology for automated explanation has yet to support the kind of interactive model construction we envision. Few explanation planners even use multiple models of their topics of explanation, let alone account for interactive model construction in their planning. (McGQ~ [9] and Paris [15] perform limited 24 Explanation and Tutoring selection between multiple “perspectives” during explanation. In the most relevant work to date, White & Frederiksen [22] designed a curriculum of models and transformations between them. The curriculum is traversed in a manner sensitive to the student. However, the student and machine do not explicitly participate in model construction.) Many discourse planners are based on schematic plan operators that fix the possible explanation patterns, and so lack the prerequisite flexibility. Perhaps most crucially, until now explanation planning has neglected the key role of a shared representation of the models under construction which can be examined and manipulated by dialogue p cipants (whether human or machine). el ~~~s~r~~~~~~ Dialogues This paper describes small but collectively significant steps towards a technology that is more consistent with the view of dialogue just discussed. Specifically, we present three contributions in the areas of discourse planning architectures, heuristics for knowledge communication, and user interface design that function together to facilitate interactive model construction in human-machine dialogue. First, our hybrid explanation planning (HEP) architecture separates various constraints that bear on the content and organization of explanations, and represents these constraints as various kinds of operators that dispose the explainer to respond to the current situation in appropriate ways [20,21]. An architecture that factors the constraints on explanation so that they can operate independently does not suffer from the inflexibility and contextual assumptions of schematic discourse plans. Second, certain explanation planning operators in our implemented explanation generator are sensitive to the dialogue history and user model to enable the machine to choose between explanatory models and to incrementally elaborate on them in response to user questions. Some operators reason about the tradeoff between the informativeness and the comprehensibility of candidate models for an e ation, enabling the planner to work coherently with owledge bases that provide multiple models of each object or phenomenon. Other operators select model elaborations and justifications based on the dialogue history, providing a first step towards From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Prior discussion had introduced a circuit. Student dragged phrases with mouse to construct Student double-clicked part of previous explanation; Kit dynamically commcted Figure 1: A Question Answering Dialogue with PEG automating model transformations like those hand-crafted by White & Frederiksen [22]. Third, dialogue occurs in the medium of a “live information” object-oriented direct-manipulation interface, called Information Kit or IKit [4]. The information is “live” in the sense that each conceptually significant segment of displayed information retains the full functionality of the underlying data structure from which it was generated. Thus, displayed information can be interpreted by the machine (as well as humans) in other contexts. This is a step towards shared “representations” [3], as the interface representations are available for perception and manipulation by both human and computer dialogue participants. The remainder of the paper first describes an example dialogue with our implemented explanation system, to provide a concrete example for subsequent discussion. Then the next three sections describe the contributions made by the HEP architecture, our model selection and presentation operators, and the IKit “live information” interface. Finally, we discuss ways in which this work fails to live up to our own visions. Suthers, Woolf, and Cornell 25 A Dialogue The HEP Architecture Here we provide an example of a question answering dialogue with an implemented explanation system that consists of the HEP architecture plus planning operators plus the Kit interface. We are using the domain of basic electricity and electrical networks. In our example, the circuit at the top of the “Explainer Notebook” in Figure 1 had just been introduced. “Exchanges” consisting of a question and a response are numbered for convenience. In general, the student’s questions were parsed by a natural language interpreter when the “?” icon was clicked. The responses were planned using internal representations (predicate calculus indexed in a frame-like concept hierarchy) before translation into natural language by a template-based generator. To construct the second question, the student mouse- selected and dragged down two phrases from the explainer’s first response (shown in boldface in the second question). Since “live information” remains attached to its internal representations, the machine need not reparse these phrases. Question 5 in Figure 1 was asked by selecting and double clicking part of response 4, from which the explainer dynamically constructed a menu of questions applicable to that response (shown to the right of exchange 5). The question that the student selected was echoed in the query box in exchange 5. Whenever the student mouse-selects an interface object, an internal focus of attention data structure is updated by bringing the selected context into the foreground. Focus of attention is used to identify the referents of phrases such as “the switch” (question l), and to estimate what models are currently under active consideration by the human participants. While planning the response in exchange 6, the planner noticed that a potentially unfamiliar concept, namely Ohm’s Law, was to be used, and asked whether the student wanted a background explanation for it (dialogue to the right of exchange 6). The student asked for a definition, which was provided as the first part of response 6. This example provides an instance of a model construction dialogue. For example, in exchange 2 the student requested further information on the relationship between the switch closing and the light bulbs lighting. The planner determined that structural and causal relationships were the appropriate relationships for associating these two events, and chose the association that elaborated on the model already in focus in exchange 1 (other associations were available). In exchange 3, the student proposed her own addition to this model, which was verified by the explainer and subsequently elaborated on in exchanges 4-6 in response to follow-up questions. A manipulable representation of dialogue was employed for deictic reference in exchanges 2 and 5, and popup menus were generated in a manner sensitive to the context in which they were invoked. We now discuss the HEP architecture, the model selection operators, and the Kit interface in more detail. Human explanation is flexible yet constrained behavior. It is flexible because people construct explanations interactively to meet the needs of the participants. It is constrained because good explanation conforms to the requirements of effective knowledge communication. Flexible yet constrained behavior can be achieved by allowing the various constraints on the content and organization of an explanation to function independently, rather than combining them into schematic operators. Observing that these constraints imply a variety of planning subtasks having distinct information processing requirements, we have designed a hybrid explanation planning architecture, HEP, that matches mechanisms to the requirements of these subtasks, facilitating explicit representation of planning knowledge for each task. No schematic operators are used: all structural relationships are constructed based on reasoning about the functionality of components of the explanation, rather than being prespecified in abstract plans. Figure 2 illustrates how the architecture matches explanation planning subtasks to mechanisms. The arrows in Figure 2 indicate how the events generated by operators in one task group may result in the scheduling of operators of another task group. (The user model provides information to the other task groups.) Operators from several task groups can be executing simultaneously, coordinated by an agenda mechanism and a common workspace, in a manner similar to 1141. In the following section, we describe some operators that use this architecture to engage in model construction dialogues. The reader is referred to [20, 211 for further detail on the architecture. The HEP architecture provides a clear correspondence between operators and sources of constraints. Spreading activation propagates assumptions about concept familiarity from concepts a student uses to related concepts, and a simulation model predicts inferences a student might make from an explanation (task 1 in Figure 2). Goal refinement operators specify what kinds of knowledge count as relevant answers to a question (task 2). Preferences select an informative and comprehensible model in a manner sensitive to the user model and dialogue history (task 3). Plan critics specify ways in which an explanation may have to be augmented to facilitate the student’s appreciation, comprehension and retention of the explanation (task 4). A graph traversal derives the order in which the parts of the explanation are presented. Constraints on this traversal ensure that the explanation is organized to enhance the communicative functionality of the parts being ordered (task 5). The inferential task for user modeling is currently not implemented: see [23] for one approach. For brevity we omit discussion of the Associative aspect of user modeling: see [21]. The remaining tasks are discussed briefly below. 26 Explanation and Tutoring Task Group Refinement 4. Identify need for Opportunistic Plan Critics supporting explanations 5. Order to enhance Ebcploitive Constrained functionality Graph Traversal Figure 2: tching Tasks to Appropriate Mechanisms in HEP s c 2). A top-down 8, is an appropriate mechanism for refining an explanation goal to the communicative acts that achieve it. Such a planner is given n of refinement operators that fferent behind each utterance, enabling failure to communicate and to respond coherently to follow-up questions [ 111. c tW se 3). T al i in identification of multiple models ant responses to a question. Model selection is crucial to a There are a num ternatives based such as to motivate forthcoming ma [ 161, provide background information need to understand a subsequent ex correct inferences and prevent false ones 1231, or introduce other topics of interest [7, 161. These augmentations have been modeled in some planners as preconditions on top- down plan operators [2, 8, 1 I]. plan supporting explanations that can be predicted beforehand, it is limited in a fundamental manner. The need for supporting explanations depends on what the explainer plans to say in the primary explanation and on what the explainer believes the hearer will understand and appreciate without further explanation. Only after a goal has been refined into the models used to satisfy it will one be able to identify the concepts and propositions in the model that require supporting explanations. This is especially true in an explanation system that has multiple models for each topic phenomenon, any one of which could be chosen for a given explanation. In HEP, we use data-driven plan critics for supporting explanations. These critics examine the evolving plan and post new goals in a context-sensitive manner. Data-driven operators are appropriate ause this is an opportunistic task. for Coherence (Task 5). An explanation e material from several models, each of which can contain multiple propositions and examples. This material must be ordered for purposes presentation. A non-arbitrary ordering decision only on the basis of some relevant relationship units being ordered. (Examples are given below). HEP is designed to exploit these relationships to enhance the intended communicative functionality of the explanation. an operators install ordering constraints in response to appearance of the relevant relationships. Then a graph traversal of the plan is conducted that orders propositions in a manner respecting the declared constmints. odd Cmstrustio Operators In this section, we consider how heuristics for cooperative model construction are embodied in plan operators that propose relevant types of models, choose between alternate models within a type, identify where supporting explanations are needed, and order the selected material to be coherent. casing eievant odels. Given a question, only certain models will make sense as the basis for a response. Goal refinement operators (see task 2 in Figure 2) are used Suthers, Woolf, and Cornell 27 to propose relevant models, by refining explanatory goals into specifications that, when matched to the knowledge base, access relevant portions of candidate models called “views” [ 18, 191. For example, explanation 2 in Figure 1 is based on a specification to find sequences of propositions that associate “the switch Sl is closed” with “the light bulbs light up.” Explanation 5 in Figure 1 is based on a specification to find conditions related to the proposition contrasting the current through the lights by causal and conditional relationships. Choosing Between Proposed Models. The domain theory can provide alternate models on which to base an explanation. We have identified a number of “preferences” (see task 3 in Figure 2) that choose from among these models in a manner resolving the tradeoff between informativeness and comprehensibility with respect to previous queries and explanations. Preferences am predicates that take two models as arguments and return “C, “=“, or “>” to indicate which is preferred, if either. Some of the preferences we have implemented are: Say-Something-New: Ensures that an explanation is informative in the context of previous dialogue by preferring models that contain some new proposition. Minimize-Unfamiliar-Concepts: Promotes comprehensibility by counting the number of potentially unfamiliar concepts (according to the associative user model) in each proposed model and preferring the model with the minimal count. Elaborate-Focal-A4odels: Helps the questioner relate new knowledge to the model active in his or her working memory by preferring models that elaborate on a model in the focus of attention. Maximize-Active-Concepts: Keeps dialogue on the same conceptual basis for continuity by preferring models that contain proportionally more concepts that have been used in recent dialogue. Minimize-New-Propositions: Reduces the amount of new information to be assimilated by counting the number of propositions that have not been stated previously and preferring the model with the minimal count. Given a set of models, a preference is applied by identifying the subset of models that are most preferred under that preference, restricting subsequent consideration to those models. Preferences are prioritized (the above list is the default ordering) and applied in priority order until a single model remains or until there are no more preferences to apply, in which case the final choice is random. To illustrate application of these preferences, consider explanation 5 and the second paragraph of explanation 6 in Figure 1. Both of these explanations were based on models that goal refinement identified as relevant for question 5. Applying the ferences, th say something new, but the model underlying explanation 5 contains fewer unfamiliar concep& so was preferred at that point in the dialogue. Then, goal refmement for question 6 resulted in an identical model specification as for question 5. However, at this point in the dialogue, the preference to say something new will remove the model expressed in explanation 5 from consideration. The m el in explanation 6 el rates on that in explanation 5, so was preferred by the elaboration preference. for S~~~~r~~~g After refinement an retrieval identified which to base explanation 6 of ” plan critic identified Ohm’s Law iar concept, and verified this with was then posted to define tations could be added. For example, clarifications to int out intended inferences and prevent false ones can be made based on reasoning about the inferences a student might make [23]. Ordering for Co ur ordering operators are based on the theoretical assumption that the relevant relationships to exploit in ordering an explanation are those forming gradients along which the student can incrementally incorporate communicated concepts and propositions into his or her current model. We assume that reconstruction is facilitated by attaching new knowledge structures to existing ones, in particular by explaining concepts before they are used to express other concepts, by introducing concepts when they bear some conceptual relationship to other concepts that have already been introduced, and by doing so where possible with propositions expressing such relationships. For example, explanation 2 is ordered to follow e associative path between the topic propositions. In explanation 6, the background definition was placed before the model it supports. [20, 211 discuss these and other ordering opemors in detail. The above dialogue illustrated how information displayed in the IKit interface can be mouse-selected to obtain a menu of questions or to reference the object in follow-up questions. This functionality reduces the demands on natural language interpreters [12]. Other relevant functionality is also available. For example, the user can incorporate display elements into her own documents (by mouse-dragging across windows), where they will retain their underlying semantic representation. This enables a student to construct a “live” multimedia notebook including the models discussed in a session with the explainer. ile retaining the link between information’s conceptual structure and its appearance, IKit also distinguishes the two. Appearance is determined by the kind of “displayer” within which the information object is 28 Explanation and Tutoring presented. The same information can be displayed under alternate views. For example, a user can mouse-drag a unit of text into a graphic displayer and obtain a picture of the underlying information (provided one is available). Also, once we add simulation displayers to Kit, the student will. be able to drag a model into such a displayer to obtain a simulation of its behavior. Thus, users can refine the information’s appearance after it has been presented. This is desirable because programs cannot always m media choices. When the switch Sl is closed, the open circuitturns in!13 closed cimb. ~c~cLcuiGenaBletne~c~entto~w~ughthe lightbubs As a result, the light bulbs IigM up. Ingeneral,the IlghtLl lsbrlghterthanthe IightL2becausetheral33oNW oftheekxtriccurentttmdghthelightL1 ismmthantheraleofflowdths ieledrk cumerMroughthe light L2. 1 First,Ohm’sLawisakindofa!awdphyslcs. Ohnfsiawstat?esthat ~cu??entIsequalbtheratiQof I 0vecreskWice: I-YIR. So,the~esist~Rl Isinthes Btconlaining the ligh4 L2 and the baltefy Bl (see figure ‘S ubckcut Containing L@ht LT, above), but t’s nut the case that the resistor is in the subcircuitcontaining the light Ll and the battery Bl (see l7gur-e ‘S u&&cut Containing Light Ll”, above). Applying ohm’s Law I-the arnoutioMe resistance divldlng the YO gedthebattefyB1 lnthe ‘subcircuit containing the light L2 and the battety 81 is more than the arnountoflhe resistance divtiing the \roLge of the batbwy Bl in the subcit~it containing the light Ll and the batty 81, l=therelbre~~~orlkw~thee~currena~oughthe IlghtLl tstrtom than~rateor~worIheelecblccvrentUrroughthaligl~L2. Figure 3: Protot Current Model Text Display Currently, we use the display of the dialogue history as the medium on which subsequent activities of the explainer and questioner are focused. However, we believe that we could make better use of Kit as a medium of interaction. When two people interact to come to a shared understanding, they often create external representations such as diagrams and text. These representations make models explicit to be commented on and modified, thereby serving to coordinate the activities of the dialogue participants. For this pu ose, the dialogue history is inadequate as a shared representation of the conceptual models under construction. It records the sequence of interactions that led to the current models, but does not make these models explicit. If the “live information” interface is to realize its full potential as a medium for coordinating the activities of an automated exphtiner and a human user, both the machine and the human should be able to make their models explicit. Towards this end, we are experimenting with a “current model” displayer (Figure 3). The model underlying this display is updated by merging the current explanation plan with the previous contents of the current model. Elaboration models replace their simplified counterparts during the merge. Text plan annotations are also merged, and the result is run through the usual text generator to display the machine’s version of the current model. For example, Figure 3 shows the textual portion of the current model displayed at the end of the dialogue of Figure 1. The user can select and query this representation in the same manner as the dialogue history. However, we currently lack the crucial ability for the user to edit and add to this model. Once such capabilities are added, the current model display could serve the same function as other external representations used in dialogue, including dialogue between multiple users of the system, as well as between users and machine. We have discussed three technological contributions towards supporting interactive model construction dialogues: the separation of various constraints on the content and organization of explanation; sensitivity of operators to the dialogue history in a manner that simulates a human explainer’s efforts to support construction; and a live information inte the representational medium through whrc the machine and human are coupled. These contributions synergize as follows. An explanation generator based on independently applied constraints rather than schematic plans provides the flexibility necessary for explanations to emerge out of the requirements of the dialogue. The elements of the interface representation of the explanation can be fully annotated with the concepts and intentions behind each element. This annnotated display then serves as a medium through which the activities of the machine and human are coordinated. The human participant’s subsequent queries and assertions can unambiguously reference active model components through direct manipulation of those components, and the machine’s model selection operators elaborate on the same components in subsequent explanations. t system is limited in various ways that could ith further research. HEP does not provide for curriculum planning or goal-oriented tutorial behavior over extended interactions. Cawsey [2] has shown how to model teaching exchanges using higher-level top-down refinement rules, an approach that would not be difficult to add to the architecture. However, an exchange-level planner still lacks a sense of curriculum and long-term tutorial strategy. HEP can be embedded in a tutor with such capabilities, for example that of [ 13 1. Modification of the planning operators to be sensitive to the tutor’s long-term goals would be necessary. As discussed above, the use of the interface to couple the activities of human and machine could be improved. Also, the natural language parser is too weak to interpret arbitrary user additions to the current model display, and there are information consistency issues to resolve concerning when user editing invalidates the pre- existing underlying model. More fundamentally, a tighter coupling would be obtained if the machine was designed to reason with the interface representations, rather than merely reasoning about them in separate, internal data structures. Finally, as the technology and implementation become sufficiently robust for applications, we will need to evaluate the effectiveness of explanation operators and interface design in teaching actual students. Sutbers, Woolf, and Cornell 29 Acknowledgments The authors appreciate comments on prior drafts from Klaus Schultz, David Skalak and the anonymous reviewers. Support was received from the National Science Foundation under grant number MDR8751362 and from External Research, Apple Computer, Inc., Cupertino CA. References [l] J. Brown, A. Collins & P. Duguid: Situated Cognition and the Culture of Learning. Educational Researcher 18: 32-42,1988. [2] A. Cawsey: Generating interactive explanations. Proceedings of the Ninth National Conference on Artificial Intelligence, pp. 86-9 1. Anaheim, California, 1988. [3] W. J. Clancey: Situated Cognition: Stepping out of Representational Flatland. AI Communications - The European Journal on Artiftcial Intelligence. 4(2/3): m-112, 1991. 143 M. Cornell, B. Woolf & D. Suthers (submitted): Using “live information” in a multimedia framework. Intelligent Multimedia Interfaces, Edited by Mark mgrbury* [S] E. IIovy: Pragmatics and natural language generation. Artificial Intelligence. 43(2): 153-197, 1990. [6] J. Lave: Cognition in Practice. Cambridge University Press, Cambridge, 1988. [7] J. Lester 8z P. Porter: A revision-based model of instructional multi-paragraph discourse production. Proc. 13th Cognitive Science. Chicago, pp. 796-800, 1991. [8] M. Maybury: Planning multisentential english text using communicative acts. Unpublished doctoral dissertation, Cambridge University, 1990. [9] K. McCoy. Generating context-sensitive responses to object-related misconceptions. Artificial Intelligence. 41(2): 157-195, 1989. [lo] K. McKeown, M. Wish & K. Matthews: Tailoring explanations for the user. Proc. 9th NCAI. Los Angeles, California, pp. 794-798,1985. 1121 J. Moore Be W. Swartout: Pointing: A way toward explanation dialogue. Proc. 10th National Conference on Artificial Intelligence, Los Angeles, August 1990. [13] T. Murray, &z B. Woolf: Encoding domain and tutoring knowledge via a tutor construction kit. Proc. 10th AAAI, San Jose, CA, 1991. [14] S. Nirenburg, V. Lesser, & E. Nyberg: Controlling a language generation planner. Proc. 11th Int. Joint Con. on Artificial Intelligence, Detroit, pages 1524- 1530, 1989. [IS] C. Paris Combining Discourse Strategies to Generate Descriptions to Users along the Naive/Expert Spectrum. Proceedings of the 10th International Joint Conference on Artijiical Intelligence, August, Milan, Italy, pp. 626-632, 1987. [16] E. Rissland (Michener): Understanding understanding mathematics. Cognitive Science. 2(4), 1978. [17] L. Suchman: Plans and Situated Actions: The Problem of Human-Machine Communication. Cambridge Press, Cambridge, 1987. [18] A. Souther, L. Acker, J. Lester & B. Porter: Using view types to generate explanations in intelligent tutoring systems. Proc. Cognitive Science Conf., Montreal, 1989. 1193 D, Suthers: Providing multiple views of reasoning for explanation. Proc. ITS-88, Montreal, 1988. [20] D. Suthers: A task-appropriate hybrid architecture for explanation. Computational Intelligence. 7(4), 1991. [21] D. Suthers. An analysis of explanation and implications for the design of explanation planners. Ph.D. dissertation, University of Massachusetts, Amherst, 1992. [22] B. White & J. Frederiksen: Causal model progressions as a foundation for intelligent learning environments. Artificial Intelligence. 42(l), 99-157, 1990. [23] I. Zukerman: A predictive approach for the generation of rhetorical devices. Computational Intelligence. k25-40, 1990. [ll] J. Moore & W. Swartout: A Reactive Approach to Explanation. Proceedings of the Eleventh International Joint Conference on Artificial Intelligence. Detroit, Michigan, 1989. 30 Explanation and Tutoring | 1992 | 4 |
1,232 | Joo- hlst Singapore 051 I, Republic of Singapore In this paper, we propose a framework for integrating fault diagnosis and incremental knowledge acquisition in connectionist expert systems. A new case solved by the Diagnostic Function is formulated as a new example for the Learning Function to learn incrementally. The Diagnostic Function is composed of a neural networks-based Example Module and a symbolic-based Rule Module. While the Example Module is always first invoked to provide the short- cut solution, the Rule Module provides extensive coverage of cases to handle odd cases when Example Module fails. Two applications based on the proposed framework will also be briefly mentioned. Neural networks have been recognized as a new and powerful paradigm to fault diagnostic applications in the past few years (Dietz et al. 1989, ?&Duff & Simpson 199Oa-c, Uhrig & Guo 1989, Venkatasubramanian et al. 1990, Yamamoto et al. 1990). This new method, known as Connectionist Expert Systems (Gallant 1988), alleviates the knowledge acquisition “bottleneck” and problem solving “brittleness” faced by traditional rule- based expert systems. It also enjoys the robustness and noise tolerance of similarity-based systems. However, it does not provide complete or near complete coverage of diagnostic cases and is inadequate in providing explanation to the user on its solution. There are generally two ways to overcome these problems. One active area of research has been to extract or interprete rules from a trained neural network (Fu 199 1, Nottola et al. 1991, Towel1 & Shavlik 1991) so as to understand the behaviours of the network. While this does not lend itself to handle unfamiliar cases, the other approach, favoured by us, supplements the network with a knowledge-based, symbolic module -- Rule Module (hereafter, RM). As similarity-based learning, which requires no domain knowledge model, is not universally applicable (Harandi & Lange 1990), other approches that rely on partial domain models are necessary to make use of the background knowledge. From the viewpoint of models of expertise, connectionist model falls within the implicit models (Slatter 1990). Other models of expertise like deep models and competence models (Slatter 1990) offer as alternatives for our RM. In essence, RM, which reasons from first principles, is useful for solving novel cases while the prototype-based neural network -- Example Module (hereafter, EM) -- which reasons from previous experience, is especially suited for solving frequently encountered problems with fast response. An analogous idea that integrate model-based reasoning and case-based reasoning to solve large novel problem is pursued in (Rajamoney & Lee 1991). The other aspect of our approach is incremental learning (hereafter, IL). The loose coupling of EM and RM described above is tightened by feeding the new cases that fails the EM but solved by RM to EM to be incorporated into its network knowledge base incrementally. This allows the refinement of both reasoning processes and domain knowledge without looking at all past cases again. This responsiveness in learning will also be useful in real- time operation. We describe the proposed framework in Section 2. The network representation of EM and the requirement of the learning algorithm are discussed in Section 3. The inference engine and symptom selection scheme in backward chaining follow in the next section. Two applications based on the framework will be briefly discussed in Section 5. The framework that we proposed is summarized in Figure 1. After constructing the initial knowledge base for EM, the user, the fault diagnostic (hereafter, FD) function, and the IL function form a closed loop that allows the system to learn while it is being used. The system automatically and incrementally acquires the diagnostic knowledge from examples generated by the FD function. The FD invokes the EM to solve a case which matches the symptoms with the prototypes of past cases learned. It provides short-cut solution to a familiar case but fails on a novel case during which the R&l is called upon to solve the case by step-by- step reasoning. The RM can follow causal models, rules, troubleshooting flowcharts or even solicit the answer from the expert in case where explicit knowledge is not available. The idea being that the verified fault(s) are used as new examples for EM to learn spontaneously. In this way, the knowledge base of EM grows over time during Lim, Lui, and Wang 159 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. operation and the chance of failure on new cases decreases. The RM is also useful as a means to provide rigorous explanation when necessary. Figure 1: Framework to combine fault diagnosis and incremental learning. 3 Network Representation The knowledge base of EM is represented as a feedforward 34ayer classification network (Figure 2). The nodes in the input layer and output layer denote the symptoms and the faults (classes) respectively. The hidden layer, whose nodes are recruited when necessary, captures the representative past examples (or their central tendencies) -- prototypes. The input layer is fully connected to the hidden layer while only those prototypes of the same fault class are joined to their respective output node. The input symptoms form the clustering space where each fault class is represented by a union of the regions representing the Symptom Layer Prototype Layer Fault Layer Figure 2: Network architecture. Figure 3: Fault clusters in symptom space. prototypes of the class after learning. Figure 3 shows three fault classes (Fl, F2, F3) with examples represented as ‘x’ on a Zdimensional symptom space (Sl, S2). Note that the boundary of a prototype can be ‘fuzzy’ by using the degree of similarity as the degree of belongness. We require the hidden layer be constructed incrementally as follows. Given an example with input vector and its fault class, the learning algorithm compares the symptoms with those captured by the existing prototypes. If the new example is close enough, by means of similarity measure such as Euclidean distance, to some prototype(s) of the same fault class, the prototype(s) can be refined to capture this example or no action is taken. We can also penalise those well-matched prototypes of different fault classes. Otherwise, a new prototype is recruited to represent this new example with a connection to its fault class. A general formulation of the decisions to make in learning is given below: Suppose a new example consists of an input symptom vector, I, and output fault class, F. Let Pj be the pattern encoded by a prototype j, @(x,y) be a distance function and Q(x) be a decreasing nonlinear function, and p be some predetermined threshold, then, Refine Pj to match more with I or take no action if there exists some prototype j of fault F, such that Q(@(I,Pj)) 2 o (1) Generate new prototype to encode I and connect it to fault F if for all prototypes j of fault F, such that Q(@(19j)) < P (2) Adjust Pj to differ more from I or take no action if there exists some prototype j NOT of fault F, such that a(Q(I,Pj)) 2 o (3) Note that many variants of the above general formulation are possible. Also if CJ is increasing, the relational operators ‘2’ and ‘c‘ become ‘I’ and 5‘ respectively. When only the distance is necessary, In reduces to an identity function. With this formulation, learning a new example needs not look at all the past 160 Learning: Neural Network and Hybrid examples learned and thus the border between batch and incremental learning becomes blur. This kind of generative learning (Honavar & Uhr 1991) allows the network connectivity to be determined adaptively. It might also produce networks that learn rapidly without sacrificing the ability to generalize correctly to new input patterns in non-stationary, rapidly changing environments and has potential to solve the stability-plasticity dilemma (Grossberg 1980). There are a number of network architectures that fulfill our incremental learning requirement described above, to mention a few (Alpaydin 1991, Honavar & Uhr 1991, Reilly et al. 1982). We have also developed a new supervised incremental clustering algorithm which approximates the likelihood of the examples by using Gaussian prototypes (ie. Q is the weighted Euclidean distance, Q is the Gaussian function). The details of this learning algorithm will be reported elsewhere. We also envision the easiness of this class of learning algorithms to handle exceptions as nested exemplars as in (Salzberg 1991). To further compact the internal representation, a number of network pruning schemes can also be considered (Alpaydin 199 1, Le Gun et al. 1990, Mozer & Smolensky 1989, Hanson & Pratt 1989). 4 Consultation The general flow of consultation, as depicted in Figure 4, is described as follows. The user first enters some initial symptom(s) that he observed to the system. The EM is invoked which performs sequential, repetitive hypothesize- and-test cycles, resembling human diagnostic reasoning @stein et al. 78, Kassirer & Gorry 78, Rubin 75), until the fault is located. In particular, based on the current set of symptoms, the inference engine infers (hypothesis generation or hypothesis updating) a list of most probable faults and presents them to the user. The user verifies the fault by replacing the faulty component suggested by the system and testing if the problem disappears. If the user acknowledges that the actual fault has not been found, the system performs backward chaining (hypothesis testing) to solicit the values of relevant unknown symptoms which are useful in discriminating the possible faults. Once the real fault has been located, the user can save the case as a new example for IL. Wowever, if the case is unfamiliar to EM, no satisfactory solution will be generated by the EM. The RM can then be activated which follows rules or first principle of the equipment model to pinpoint the fault. Similarly the result can be formulated as a new case for IL. 4.8 Inference Engine With the proposed network representation, the EM infers the faults from the current symptoms by the nearest neighbor algorithm or its variants as follows: Figure 4: Consultation flow. Let the input symptom vector be I, I’j be the pattern encoded by a prototype j, distance function and a(x) be a decreasing nonlinear function, and Q be some predetermined acceptance threshold, then, A fault F is ‘fined’ if (4) We can regard this maximum activation of the prototypes of fault class F as the confidence measure for F. The fired faults are displayed to the user. As an alternative to using the threshold, we can select the top few faults with the highest confidence measure. The purpose of backward chaining is to obtain more information (unknown symptom values) in order to better differentiate the fault clusters in a higher dimensional space. We have two possible schemes, namely Information Heuristic Scheme and the Fuzzy Entropy Scheme. 4.2.B Information The Information Heuristic Scheme attempts to select most informative unknown symptom which roug appears in half of the representative prototypes of the currently inferred faults with other heuristic information as follows: owledge For each undetermined symptom i, compute Hi =Ei+Wi-Ci Select symptom i* such that Hi* is the maximum where Wi is the weightage (importance) of symptom i and Lim, Lui, and Wang 2.61 Ci is the cost incurred to determine the value of symptom i. They are to be supplied by the domain experts. Ei is the ‘effectiveness’ of symptom i which is obtained as follows: Let Fj be one of the currently inferred faults, Pj be the pattern encoded by the prototype of Fj which has the maximum activation, and Gj be this maximum activation, then Z Gj* Aij j Ei = M- C Gj*Aij M j if C Gj*A**>- j 1J 2 where Aij is a boolean flag to indicate whether symptom i appears in prototype pattern Pj, and M is the number of the currently inferred faults. 4.2.2 Fuzzy Entropy Scheme The Fuzzy Entropy Scheme (Wang 90, Zhang & Wang 88, Zadeh 78) selects the undetermined symptom with the smallest entropy as follows: For each undetermined symptom i, compute Ti = -K x C R(@(I,PF)) * IOg fi(@(IpF)) SiE S FE Fsi Select symptom i* such that Ti* is the minimum where si, the value of symptom i, ranges over all three possible values of symptom, namely (-1, 0, +l ) , for the outer summation, Fsi, is the set of inferred faults F with the addition of Si into the currently known symptoms, PF denotes the pattern of the prototype with the maximum activation of fault F, and K is a constant. The computation is intensive as the new set of faults have to be recomputed for each possible value of each unknown symptom considered. 5 Applications INSIDE (Inertial Navigation System Interactive Diagnostic Expert) (Lim et al. 1991, Lui et al. 1991) is a connectionist dignostic expert system developed for the Singapore Airline (SIA) to assist technicians in diagnosing the avionic equipment known as Inertial Navigation System (INS). In this application, the EM is based on the RCE network (Reilly 1982) and the RM is a Flowchart Module which implements the troubleshooting flowcharts supplied by the INS manufacturer. The backward chaining scheme is similar to the Information Heuristic Scheme described above. There are 209 symptoms and 85 faults. With 990 past cases, 216 prototypes were formed. The diagnostic accuracy of the EM alone is 65%-75%. From the experiments that we carried out, the success rate improves when the training data size increases. Although the number of prototypes increases accordingly, the rate of increment declines. The system, which also has a record-keeping and report- generating module, tooks 20 man-months to complete in 1990 and is now in operation. In the second quarter of 1991, we also conducted a feasibility study for the Port of Singapore Authority (PSA) to develop a prototype diagnostic system called COINCIDE (COnnectionist INcremental-learning Crane Interactive Diagnostic Expert) to train the new technicians in troubleshooting the quay cranes. In this case, the EM utilizes the supervised incremental clustering algorithm that we developed and due to time constraint, no RM has been implemented. Instead, when the EM fails to give a satisfactory answer, the human expert will instruct the system with the actual fault(s) for the system’s IL to update the knowledge base. Both symptom selection schemes discussed in Section 4 have been incorporated, but the latter requires heavy computation that prolongs the response time. In this study, only the most-frequently- breakdown Spreader subsystem of the whole huge quay crane is considered, which consists of IO0 symptoms and 93 faults. With limited time, the size and quality of the collected training data is not adequate for a quantitative analysis of the performance of the system at the moment. However, an initial benchmark of the learning algorithm on the INSIDE’s data has shown a performance level of 88% (Chng 1992). There is a high possibility that we will extend the prototype to an operational system in the near future. We have proposed a framework for connectionist expert systems to integrate the automatic and incremental construction of knowledge base with the diagnostic capability. A network representation based on prototypical learning is described and the suitable class of learning algorithm is identified. We also discuss the nearest neighbor-like inference engine and two possible backward chaining schemes. Finally, two applications based the framework are presented. We are now turning our framework into a generic connectionist expert systems kernel which can be customized with different learning algorithms, RMs, and application domains easily. In the forthcoming future, we are also looking into IL algorithms with faster convergence rate and more compact prototype layer as well as neural network-based RM (Lim et al. 1991). 162 Learning: Neural Network and Hybrid We would like to express our gratitudes to Dr Ding Liya, Mr Chen Chung-Chih, and Mr Chng Tiak Jung for contributing ideas in shaping the framework. eferences Alpaydin, E. (1991). GAL: Networks that grow when they learn and shrink when they forget. Tech. Report TR91-032, International Computer Science Institute, Berkeley. Chng, T.J. (1992). Connectionist Expert System For Fault Diagnosis. Honours Year Project Report. Dept. of Information Systems and Computer Science, National University of Singapore. Dietz, W.E., Kiech, E.L., & Ali, M. (1989). Jet and Rocket Engine Fault Diagnosis in Real Time. Journal of Neural Network Computing, Summer, pp. 5-18. Elstein, A., Shulman, L., & Sprafka, S. (1978). Medical Problem Solving - An Analysis of Clinical Reasoning. Harvard University Press. . (1991). Rule Learning by Searching on Adapted Nets. In Proceedings Ninth National Conference on Artificial Intelligence, pp. 590-595. G allant, S.I. (1988). Connection& Expert Systems. Communications of the ACM, 31(2): 152-169. Grossberg, S. (1980). How does the brain build a cognitive code? Psychological Review 1: 1-5 1. Hanson, S.J. & Pratt, L.Y. (1989). Some comparisons of constraints for minimal network construction with backpropagation. In D.S. Touretzky (Ed.) Neural Information Processing Systems (Vol. I). San Mateo, CA: Morgan Kaufmann. Harandi, M.T. & Lange, R. (1990). Model-based Knowledge Acquisition. In H. Adeli (Ed.), Knowledge Engineering, Volume 1, Fundamentals. McGraw-Hill Publishing Company. Honavar, V. & Uhr, L. (1991). Generative Learning Structures and Processes for Generalized Connectionist Networks. Tech. Report #91-02, Dept. of Computer Science, Iowa State University. Kassirer, J. $ Gorry, G. (1978). Clinical Problem Solving: A Behavioral Analysis. Ann. Intl. Med., 89, pp. 245-25s. Le Cun, Y., Denker, J.S., & Solla, S.A. (1990). Optimal Brain Damage. In D.S. Touretzky (Ed.) Neura 1 Information Processing Systems (Vol. 2). San Mateo, CA: Morgan Kaufmann. Lim, J.H, Lui, H.C., & Teh, H.H. (1991). A Rule Inferencing System Based On Neural-logic. Submitted to IEEE Transactions on Neural Networks. Lim, J.H., Lui, H.C., Tan, A.H., & Teh, H.H. (1991). INSIDE: A Connectionist Case-based Diagnostic Expert System That Learns Incrementally. In Proceedings of IJCNN’91, Singapore, Nov. 18-2 1, 199 1. Lui, H.C., Tan, A.H., Lim, J.H., & Teh, H.H. (1991). Practical Application of a Connectionist Expert System: The INSIDE Story. In Proceedings of the World Congress on Expert Systems, Orlando, Florida, Dec. 16-19,1991. McDuff, R. & Simpson, P. (199Oa). An Investigation of Neural Networks for F-16 Fault Diagnosis I: System Description. In Conference Record of IEEE Anktestcon 1989, Philadelphia, PA, pp. 351-357. McDuff, R. & Simpson, P. (1990b). An Investigation of Neural Networks for F-16 Fault Diagnosis II: System Performance. In Proceeding of the SPIE Technical Symposium on Aerospace Sensing, Applications of Neural Networks. McDuff, R. 6% Simpson, P. (199Oc). An Adaptive Resonance Diagnostic System. The Journal of Neural Networks, Summer 1990. (preprint) McMillan, C., Mozer, M.C., & Smolensky, P. (1991). The Connectionist Scientist Game: Rule Extraction and Refinement in a Neural Network. Tech. Report CU-CS- 530-91, Dept. of Computer Science, Institute of Cognitive Science, University of Colorado. Mozer, M.C. & Smolensky, P. (1989). Skeletonization: a technique for trimming the fat from a network via relevance assessment. In D.S. Touretiky (Ed.) Neural Information Processing Systems (Vol. I). San Mateo, CA: Morgan Kaufmann. Nottola, C., Condamin, L., & Naim, P. (1991). Hard Neural Networks for Rule Extraction. A Methodological Approach Applied to Business Financial Evaluation. In Proceeding of Neuro-Mimes 91, Nimes, France, Nov. 4- 8, 1991. Rajamoney, S.A. & Lee, H-Y. (1991). Prototype-Based Reasoning: An Integrated Approach to Solving Large Novel Problems. In Proceeding Ninth National Conference on Artificial Intelligence, MI Press/The MIT Press, pp. 34-39. Reilly, D.L., Cooper, L.N., & Elbaum, C. (1982). A Neural Model for Category Learning. Biological Cybernetics 45, pp. 35-41. Rubin, A. (1975). The Role of Hypotheses in Medical Diagnosis. In Proceeding of IJCAI, 1975, pp. 856-862. Salzberg, S. (1991). A Nearest Hyperrectangle Learning Method. Machine Learning 6, pp. 25 l-276. Slatter, P.E. (1990). Models of Experrise in Knowledge Engineering. In H. Adeli (Ed.), Knowledge Engineering, Volume 1, Fundamentals. McGraw-Hill Publishing Company. Towell, 6.6. & Shavlik, J.W. (1991). The Extraction of Refined Rules from Knowledge-Based Neural Networks. Machine Learning Research Group Working Paper 91-4, University of Wisconsin-Ivladison. Submitted (8/9I) to Machine Learning. Uhrig, R. & Guo, Z. (1989). Use of Neural Networks in Nuclear Power Plant Diagnosis. In Proceeding of the SPIE Technical Symposium on Aerospace Sensing, Applications of Artificial IntelligenceVII. Venkatasubramanian, V., Vaidyanathan, R., dz Yamamoto, Y. (1990). Process Fault Detection and Diagnosis using Neural Networks--I. Steady-State Lim, Lui, and Wang 163 Processes. Computers Chem. Engng, 14(7):699-712. Wang, Pei-Zhuang. (1990). A Factor Spaces Approach to Knowledge Representation. Fuzzy Sets and Systems, 36: 113-124. Yamamoto, Y. & Venkatasubramanian, V. (1990). Integrating Qualitative and Quantitative Neural Networks for Fault Detection and Diagnosis. Submitted to AICWEJ. Zadeh, L.A. (1978). Fuzzy Sets as a Basis for a Theory of Possibility. Fuzzy Sets and Systems, 1: 3-28. Zhang, IIong-Min & Wang, Pei-Zhuang. (1988). A Fuzzy Diagnostic Expert System - FUDES. FAS, Presented at 7th NAFIPS Conference, San Francisco, CA, USA. 164 Learning: Neural Network and Hybrid | 1992 | 40 |
1,233 | Using I llou- Richard Ma&n and Jude W. Shavlik Computer Sciences Department University of Wisconsin Madison, Wisconsin 53706 email: maclin&s. wisc.edu Abstract We describe a method for using machine learning to refine algorithms represented as generalized finite-state automata. The knowledge in an automaton is trans- lated into an artificial neural network, and then refined with backpropagation on a set of examples. Our tech- nique for translating an automaton into a network ex- tends KBANN, a system that translates a set of propo- sitional rules into a corresponding neural network. The extended system, FSKBANN, allows one to refine the large class of algorithms that can be represented as state-based processes. As a test, we use FSKBANN to refine the Chou-Fasman algorithm, a method for predicting how globular proteins fold. Empirical evi- dence shows the refined algorithm FSKBANN produces is statistically significantly more accurate than both the original Chou-Fasman algorithm and a neural network trained using the standard approach. Introduction As machine learning has been increasingly applied to complex real-world problems, many researchers have found themselves turning to systems that refine existing theories rather than building theories from scratch. Ig- noring existing knowledge is dangerous, since the result- ing learned concept may not contain important factors already identified in earlier work. Our research extends the KBANN system (Towel1 et al., 1990). KBANN uses knowledge represented as simple, propositional rules (a domain theory) to create an initial neural network containing the knowledge from the rules. Work in the domain of gene recognition (Towell, 1991) shows knowledge-based neural networks are more effective than randomly configured networks - even when the original domain theory is not good at solving the prob- lem. This paper describes an addition to KBANN that extends it for domain theories that employ state infor- mation. State is important because researchers outside ma- chine learning generally publish algorithms, rather than the sets of rules which machine learning researchers call domain theories. Many algorithms maintain some sense of state, so our extension makes it easier to use machine learning to refine existing “real-world” knowledge. We test our extended system by refining the Chou-Fasman (1978) algorithm for predicting (an aspect of) how glob- ular proteins fold, an important and particularly diffi- cult problem in molecular biology. State in a domain theory represents the context of the problem. For example, if the problem is to find a path across a room, the state variables may include whether the light is on. The rules introduced to solve this problem take into account the state of the prob- lem - rules to turn on the light would only be consid- ered when the state indicates the light is off. In this style of problem solving, the problem is not solved in one step, but as a series of actions, each leading to a new state, leading to a goal state (turning on the light, navigating to the couch, etc.). The extended KBANN system, called Finite-State KBANN (FSKBANN), trans- lates domain theories that use state information, repre- sented as generalized finite-state automata (FSAs). As in KBANN, FSKBANN translates the state-based domain theory into a neural network, and refines the network using backpropagation (Rumelhart et al., 1986). The protein-folding problem is an open problem that is increasingly critical as the Human Genome Project (Watson, 1990) proceeds. The Chou-Fasman algorithm is a well-known and widely-used solution. The protein- folding problem is also interesting because many ma- chine learning techniques have been applied to it, including neural networks (Holley & Karplus, 1989; Qian & Sejnowski, 1988), inductive logic program- ming (Muggleton & King, 1991), case-based reasoning (Cost & Salzberg, in press), and multistrategy learning (Zhang, 1990). 0 ur work combines the Chou-Fasman algorithm with a neural network to achieve a more ac- curate result than either method separately. Maclin and Shavlik 165 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. B:-D,E. B:-E,notF. C:-F.G. Figure 1: Sample of KBANN: (a) set of rules, (b) dependen- cies among the rules, (c) corresponding network, and (d) network with near-zero weights added. This paper presents and empirically analyzes the FSKBANN approach for problem solving in domains where prior state-based knowledge exists. The next sec- tion presents the KBANN algorithm and discusses how we extended it to handle state information. The third section defines the protein-folding problem and reviews previous approaches taken. Following that are experi- ments we performed to test the utility of FSKBANN. Finite-State KBANN Before describing FSKBANN, we review the KBANN (for Knowledge-Based Artificial Neural Networks) al- gorithm (Towel1 et al., 1990). KBANN translates a do- main theory represented as simple rules into a promis- ing initial neural network. This technique allows neural networks to take advantage of pre-existing knowledge. KBANN takes as input a set of propositional, non- recursive rules, such as those shown in Figure la. Figure lb shows dependencies among the rules. A de- pendency is a link between two propositions - arcs show conjunctive dependencies. From the set of dependen- cies, it is easy to map to a network by replacing each proposition with a unit (and adding units where con- junctions are combined into disjunctions). Figure lc displays the resulting network. This network has the same behavior as the rules for every input vector. After setting the weights and biases of the units in the net- work, KBANN connects each unit to any unconnected units at the next lower level in the network using a small-weight link (the resulting network appears in Fig- ure Id). KBANN adds these connections so that it can learn new dependencies during backpropagation learn- ing. For further details see Towel1 (1991). To handle a wider class of problems, we extended KBANN to domain theories represented as generalized FSAs’ . The main extension is the type of network onto ‘The notion of FSA in FSKBANN is generalized in that rather than taking a single input value at each step, the FSA may take a set of input values. Table 1: Type of problem solving addressed by FSKBANN. Given: a state-dependent domain theory and a goal description Repeat Set input = externally-provided information + current internal representation of the problem-solving state Produce, using the domain theory and goal description, output = result specific to this problem solving step + next internal representation of the problem-solving state Until a Termination Criterion is met. I n I Figure 2: A schematic view of an FSKBANN network. which the domain theory is mapped. FSKBANN maps domain theories onto a variant of simple recurrent net- works (Elman, 1990), where a subset of the network output is copied back as input of the network in the next step. The copied output represents the previous state calculated by the network and can be used in cal- culating the next succeeding state. Table 1 describes the class of problem solvers to which FSKBANN is applicable. Consider a problem solver that determines the next state from externally-provided in- put and its internal representation of the current state. The externally-provided input may involve a descrip- tion of the initial state or the measurements of sensors (e.g., as in a reactive planner). The task of the prob- lem solver is to produce the appropriate output for this step in the problem solution (e.g., the operator to ap- ply), as well as choose its internal representation of the next state. This process repeats until a termination condition is met (e.g., a goal state is reached). The description in Table 1 is a definition of state- based problem solving. The contribution of FSKBANN is a mechanism for using neural networks to improve an existing state-dependent domain theory. The inputs and outputs in Table 1 directly map to input and output units in a neural network, and the basic KBANN algo- rithm uses the domain theory to determine the number and connectivity of the hidden units. Figure 2 shows a 166 Learning: Neural Network and Hybrid Table 2: Sample primary and secondary structures. Table 3: Results of non-learning prediction algorithms. PriIIlary (20 possible amino acids) SVFLFPPKPK . . . Secondarv (three Dossible structures) C B fl B k? C C C (Y Cy . . . diagram of the type of network produced by FSKBANN. FSKBANN requires the user to provide sample in- put/output pairs which are used to train the network. It also requires inputs and outputs to be of bounded size, which means the domain theory can only store a finite amount of state. Finally, FSKBANN requires the domain theory be propositional, since no good mecha- nism exists for dealing with predicate calculus variables in neural networks. While these are currently limita- tions, we posit that many “real-world” algorithms can be represented in this finite-state framework. rotein-Folding This section introduces the protein-folding problem, de- scribes an algorithm from the biological community to solve this problem, and shows how the algorithm is mapped into the above framework. Proteins are long strings of amino acids, several hundred elements long on average. There are 20 amino acids in all (repre- sented by different capital letters). The string of amino acids making up a protein is the primary structure of the protein. Once a protein forms, it folds into a three- dimensional shape, known as its tertiary structure. Ter- tiary structure is important because the form of the protein strongly influences its function. At present, determining the tertiary structure of a protein is costly and time consuming. An alternative approach is to predict the secondary structure of a pro- tein as an approximation. Secondary structure in a pro- tein is a description of the local structure surrounding each amino acid. One prevalent system of determining secondary structure divides a protein into three types of structures: (1) a-helix regions, (2) P-strand regions, and (3) random coils (all other regions). For our pur- poses, we can think of the secondary structure of a pro- tein as simply a sequence corresponding to the primary sequence. Table 2 shows a sample mapping between a protein’s primary and secondary structures. Table 3 contains results of some standard algorithms for solving the secondary-structure problem from the biological literature (Chou & Fasman, 1978; Garnier & Robson, 1989; Lim, 1974). Figure 3 shows the general structure of this type of network. In the data sets used to test the algorithms, 54-55% of the amino acids are part of coil structures, so 54% accuracy can be achieved trivially by predicting coil. Note, many biological re- searchers believe algorithms which use only local infor- mation can achieve at best SO-SO% accuracy (Cohen & Presnell, personal communication, 1991). I Method Accuracv Comments I Chou & Fasman 58% data from Qian & Sejnowski (1988) Garnier & Robson 58% data from Qian & Sejnowski (1988) Lim 50% from Nishkawa (1983) Predicted Secondary m output Units Hidden Units Input ,T i T Units . . . F LEQ Q Y V V!,FdD R D N GA R L . . . Primary Input Widow structure Figure 3: Neural network used by Qian & Sejnowski. Table 4: Neural network results for structure prediction. Method Accuracy Hidden Units Window Size Holley & Karplus 63.2% 2 17 Qian & Sejnowski 62.7% 40 13 A second approach to the secondary-structure prob- lem is to use a neural network (Qian & Sejnowski, 1988; Holley & Karplus, 1989). The neural networks in these efforts have as input a window of amino acids consisting of the central amino acid being predicted, plus several amino acids before and after it in the sequence (similar to NETTALK networks, Sejnowski & Rosenberg, 1987). The output of the network is the secondary structure for the central amino acid. Table 4 presents results from these studies, which used different data sets. Our approach is to combine the knowledge from biological methods into a neural learning method to achieve a better solution. We chose as our biological method the Chou-Fasman algorithm, since this algo- rithm is widely used. The Chou-Fasman approach finds amino acids that are likely part of a-helix and /?-strand regions, and extends these predictions to neighboring amino acids. This algorithm cannot be easily repre- sented using propositional rules, since the prediction for an amino acid may depend on the predictions for its neighbors, but the algorithm can be represented as a generalized FSA (see Maclin & Shavlik, to appear). The resulting network is similar to the network shown in Figure 3 with two major differences. One, the input to the network includes three extra units that contain the past output of the network - the state of the net- work. Two, the topology of the hidden units is deter- mined by FSKBANN, analogously to Figure 1, using the Chou-Fasman algorithm as the domain theory. Table 5 shows how the Chou-Fasman algorithm maps into the FSKBANN framework of Table 1. Maclin and Shavlik 167 Table 5: Mapping the Chou-Fasman algorithm into FSKBANN (2” = secondarv structure. A.A. = amino acid). domain theory = the Chou-Fasman algorithm goal = assign a 2’ to each A.A. external input = a sliding window of A.A.s current state = the predicted 2’ for the previous A.A. results = the predicted 2’ for the current A.A. next state = ditto Experimental Study We performed several experiments on the protein problem to evaluate FSKBAMN. They demonstrate FSKBANN has a small but statistically-significant gain in accuracy over both standard artificial neural net- works (ANNs) and over the non-learning Chou-Fasman algorithm. We also show in-depth empirical analyses of the strengths of the different methods. Experimental Details We performed our experiments using the data from Qian and Sejnowski (1988). Their data set consists of 128 segments from 106 proteins with a total of 21,623 amino acids. 54.5% of the amino acids are part of coil structures, 25.2% part of o-helix structures, and 20.3% part of P-strand structures. Ten times we divided the proteins randomly into training and test sets containing two-thirds (85 proteins) and one-third (43 proteins) of the original proteins, respectively. We used backpropagation to train the neural net- works in the two network approaches (FSKBANN and standard ANNs). Training was terminated using patience2 as a stopping criterion. During training, we divided the proteins used for training into two portions - a training set and a tuning set. We use the training set to train the network and the tuning set to estimate the generalization of the network. For each epoch, the system trains the network on each of the amino acids in the training set; it then assesses accuracy on the tuning set. We retain the set of weights achieving the highest accuracy for the tuning set and use this set of weights to measure test set accuracy. The system ran- domly chooses a “representative” tuning set; a tuning set is representative if the percentages of each type of structure (a, p, and coil) in the tuning set approximate the percentages for the training proteins. Note the sys- tem does not consider the testing set when comparing the percentages. Through empirical testing, we found a tuning set size of five proteins achieved the best results for both FSKBANN and ANNs. Note that this style of training is different from that reported by Qian and 2The patience criterion (Fahlman & Lebiere, 1990) states that training continues until the error rate has not decreased for several training cycles. In this study we set the criterion to be four epochs.- Table 6: Test set accuracies for prediction methods. I Method Total Helix Strand Coil Chou-Fasman 57.3% 31.7% 36.9% 76.1% ANN 61.8% 43.6% 18.6% 86.3% - w/ state 61.7% 39.2% 24.2% 86.0% FSKBANN 63.4% 45.9% 35.1% 81.9% - w/o state 62.2% 42.4% 26.3% 84.6% Table 7: Correlation coefficients from prediction methods. Method Helix Strand Coil 1 Sejnowski. They tested their network periodically, re- taining the network that achieved the highest accuracy for the test set. FSKBANN uses 28 hidden units to represent the Chou-Fasman domain theory. Qian and Sejnowski re- port that their networks generalized best when they had 40 hidden units. Using the method outlined above, we compared standard ANNs containing 28 and 40 hid- den units. We found that networks with 28 hidden units generalized slightly better; hence, for this paper’s experiments we use 28 hidden units in our standard ANNs. This also has the advantage that the FSKBANN and ANNs use the same number of hidden units. Results and Analysis Tables 6 and 7 contains results averaged over the 10 test sets. The statistics reported are percent accuracy overall, percent accuracy by secondary structure, and correlation coefficients for each structure. The correla- tion coefficient is good for evaluating the effectiveness of the prediction for each of the three classes separately. The resulting gain in overall accuracy for FSKBANN over both ANNs and the non-learning Chou-Fasman method is statistically significant at the 0.5% level (i.e. with 99.5% confidence) using a t -test. The apparent gain in accuracy for FSKBANN over ANN networks appears small (only 1.6 percentage points), but this number is somewhat misleading. The correlation coefficients give a more accurate picture. They show that the FSKBANN does better on both CV- helix and coil prediction, and much better on P-strand prediction. The reason that the ANN solution does well in overall accuracy is it predicts many coil structures (the largest class) and does well on these predictions. The gain in accuracy for FSKBANN over the Chou- Fasman algorithm is fairly large and exhibits a corre- sponding gain in all three correlation coefficients. It is interesting to note that the FSKBANN and Chou- Fasman solutions produce almost the same accuracy for 168 Learning: Neural Network and Hybrid Table 8: Region-oriented prediction statistics. Occurrence Description FSKBANN ANN Chou other El a- helix other P-strand Average length of pre- dicted helix regions (num- ber of regions). Percentage actual helix re- gions overlap predicted he- lix regions (length of over- laps). Percentage predicted helix regions do not overlap ac- tual helix regions. Average length of predicted strand regions (number of regions). Percentage actual strand regions overlap predicted strand regions (length of overlaps). Percent age predicted strand regions do not over- lap actual strand regions. 8.52 (1774) 67% (6.99) 34% 3.80 (2545) 54% (3.23) 37% 7.79 (2067) 70% (6.34) 39% 2.83 (1673) 35% (2.65) 37% 8.00 (1491) 56% (5.76) 36% 6.02 (2339) 46% (4.01) 44% P-strands, but the correlation coefficients demonstrate that the Chou-Fasman algorithm achieves this accuracy by predicting more P-strands. Also shown in Tables 6 and 7 are results for ANNs that included state information - networks similar to Qian and Sejnowski’s but where the previous output forms part of the current input vector. These results show that state information alone is not enough to in- crease the accuracy of the network prediction. The final row in Tables 6 and 7 shows results for ANNs that use the non-state knowledge from the do- main theory. These networks are simple feedforward networks where the topology of the network is deter- mined by the knowledge from the domain theory that does not involve state. These results show state infor- mation is integral to the domain theory since networks without could only do as well as standard ANNs. Finally, to analyze the detailed performance of the various approaches, we gathered additional statistics about the FSKBANN, ANN, and Chou-Fasman solu- tions. These statistics analyze the results by regions. A region is a consecutive sequence of amino acids with the same secondary structure. We consider regions be- cause the measure of accuracy obtained by comparing the prediction for each amino acid does not adequately capture the notion of secondary structure as biologists view it (Cohen et al., 1991). For biologists, knowing the number of regions and the approximate order of the regions is nearly as important as knowing the ex- act structure for each amino acid. The statistics assess how well each solution does on predicting a-helix re- gions and ,&strand regions (see Table 8). Table 8 gives a picture of the strengths and weakness of each approach. It shows that the FSKBANN solu- tion overlaps slightly fewer actual o-helix regions than the ANNs, but that these overlaps tend to be some- what longer. On the other hand, the FSKBANN net- works overpredict fewer regions than ANNs (i.e. pre- dict fewer a-helix regions that do not intersect actual a-helix regions). Table 8 also indicates FSKBANN and ANNs more accurately predict the occurrence of regions than Chou-Fasman approach does. Table 8 demonstrates that FSKBANN’S predictions overlap a much higher percentage of actual ,&strand re- gions than the Chou-Fasman algorithm or ANNs. The ANNs do extremely poorly at predicting overlapping actual /?-strand regions. The FSKBANN networks do as well as the ANNs at not overpredicting ,&strands, and both do better than the Chou-Fasman method. Taken together, these results indicate that the FSKBANN solu- tion does significantly better than the ANN solution on predicting ,&strand regions without having to sacrifice much accuracy in predicting o-helix regions. Overall, the results suggest more work needs to be done on developing methods of evaluating solution qual- ity. Solutions that find approximate locations of o-helix and P-strand regions and those that accurately predict all three classes should be favored over solutions that only do well at predicting the largest class. Most impor- tantly, the results show that for difficult problems, such as the protein-folding problem, the FSKBANN approach can be worthwhile. Future Work FSKBANN uses a domain theory to give a network a “good” set of initial weights, since search starts from that location in weight space. Therefore augmenting the Chou-Fasman domain theory with other informa- tion may increase the solution’s accuracy. Informa- tion in Table 8 indicates current weaknesses. With this knowledge, domain theory extensions addressing these weaknesses can be developed by studying the biological literature. An interesting property of the networks is that the magnitude of predictions is correlated with their accu- racy. This information could be used in a more complex prediction method: instead of predicting all of the pro- tein’s structure in one scan, predict only the strongest activated areas first, then feed these predictions back into the network for the next scan. Finally, a problem with the KBANN approach is ex- tracting information in a human-readable form from the trained network (Towel1 & Shavlik, 1992). We need to address rule extraction for the augmented networks of FSKBANN to extract learned FSAs. Related Research As has been mentioned, the architecture used by FSKBANN, simple recurrent networks, is discussed by Elman (1990). The idea of using this type of network to represent an FSA has been explored by Cleeremans Ma&n and Shavlik 169 et al. (1989) and Giles et al. (in press). Cleeremans et al. showed that this type of network can perfectly learn to recognize a grammar derived from an FSA. The major difference between FSKBANN and other research on learning FSAs is we focus on using an initial FSA domain theory, rather than learning it from scratch. Zhang (1990) 1 a so applies machine learning to the secondary-structure problem. His method combines in- formation from a statistical technique, a memory-based reasoning algorithm, and a neural network. The best results he reports are 66.4% for a training set size of 96 proteins (Zhang, personal communication, 1991). An- other learning technique applied to this problem is the nearest-neighbor algorithm PEBLS (Cost & Salzberg, in press). They report approximately 64% accuracy for a training set similar in size to the one we used. Conclusions We present and evaluate FSKBANN, a system that broadens the KBANN approach to a richer, more ex- pressive vocabulary. FSKBANN provides a mechanism for translating domain theories represented as general- ized finite-state automata into neural networks. The extension of KBANN to domain theories that include knowledge about state significantly enhances the power of KBANN; rules expressed in the domain theory can take into account the current problem-solving context (i.e. the state of the solution). We tested FSKBANN by refining the non-learning Chou-Fasman algorithm for predicting protein sec- ondary structure. The FSKBANN-refined algorithm proved to be more accurate than both standard neural network approaches to the problem and a non-learning version of the Chou-Fasman algorithm. The success of FSKBANN on the secondary-structure problem indicates it may be a useful tool for addressing other tasks including state information. However, work must be done both in improving the neural-network re- finement process and the extraction of symbolic knowl- edge from the trained network. Acknowledgments This research was partially supported by NSF Grant IRI- 9002413 and ONR Grant N00014-90-J-1941. References Chou, P. & Fasman, G. (1978). Prediction of the secondary structure of proteins from their amino acid sequence. Ad- vanced Enzymology, 47:45-148. Cleeremans, A., Servan-Schreiber, D., & McClelland, J. (1989). Finite state automata and simple recurrent net- works. Neural Computation, 1:372-381. Cohen, B., Presnell, S., Cohen, F., & Langridge, R. (1991). A proposal for feature-based scoring of protein secondary structure predictions. In Proc. of the AAAI-91 Workshop on AI Approaches to Classification and Pattern Recognition in Molecular Biology, (pp. 5-20). Cost, S. & %&berg, S. (in press). A weighted nearest neigh- bor algorithm for learning with symbolic features. Machine Learning. Elman, J. (1990). Finding structure in time. Cognitive Sci- ence, 14:179-211. Fahlman, S. & Lebiere, C. (1990). The cascade-correlation learning architecture. In Advances in Neural Information Processing Systems (volume ii?), (pp. 524-532). Garnier, J. & Robson, B. (1989). The GOR method for predicting secondary structures in proteins. In Fasman, G., editor, Prediction of Protein Structure and the Principles of Protein Conformation. Plenum Press, New York. Giles, C., Miller, C., Chen, D., Chen, H., Sun, G., & Lee, Y. (in press). Learning and extracting finite state automata with second-order recurrent neural networks. Neural Com- putation. Holley, L. & Karplus, M. (1989). Protein structure predic- tion with a neural network. Proc. of the National Academy of Sciences (USA), 86:152-156. Lim, V. (1974). Algorithms for prediction of a-helical and p- structural regions in globular proteins. Journal of Molecular Biology, 88:873-894. Ma&n, R. & Shavlik, J. (to appear). Using knowledge-based neural networks to improve algorithms: Refining the Chou- Fasman algorithm for protein folding. Machine Learning. Muggleton, S. & King, R. (1991). Predicting protein secondary-structure using inductive logic programming. Technical report, Turing Institute, Glasgow, Scotland. Nishikawa, K. (1983). A ssessment of secondary-structure prediction of proteins: Comparison of computerized Chou- Fasman method with others. Biochimica et Biophysics Acta, 748:285-299. Qian, N. & Sejnowski, T. (1988). Predicting the secondary structure of globular proteins using neural network models. Journal of Molecular Biology, 202:865-884. Rumelhart, D., Hinton, G., & Williams, R. (1986). Learn- ing internal representations by error propagation. In Rumel- hart, D. & McClelland, J., editors, Parallel Distributed Pro- cessing, Volume 1. MIT Press. Sejnowski, T. & Rosenberg, C. (1987). Parallel networks that learn to pronounce English text. Complex Systems, 1:145-168. Towell, G. (1991). Symbolic knowledge and neural networks: Insertion, refinement and extraction. PhD thesis, Dept. of Computer Sciences, Univ. of Wisconsin, Madison, WI. Towell, G. & Shavlik, J. (1992). Interpretation of artifi- cial neural networks: Mapping knowledge-based neural net- works into rules. In Advances in Neural Information Pro- cessing Systems (volume 4). Towell, G., Shavlik, J., & Noordewier, M. (1990). Refine- ment of approximate domain theories by knowledge-based neural networks. In Proc. of the Eighth National Conference on ArtificiaZ Intelligence, (pp. 861-866). Watson, J. (1990). The Human Genome Project: Past, present, and future. Science, 248:44-48. Zhang, X. (1990). E pl x oration on protein structures: Rep- resentation and prediction. PhD thesis, Dept. of Computer Sciences, Brandeis Univ., Waltham, MA. 170 Learning: Neural Network and Hybrid | 1992 | 41 |
1,234 | ichard S. Sutton GTE Laboratories Incorporated Waltham, MA 02254 sutton@gte.com Abstract Appropriate bias is widely viewed as the key to efficient learning and generalization. I present a new algorithm, the Incremental Delta-Bar-Delta (IDBD) algorithm, for the learning of appropri- ate biases based on previous learning experience. The IDBD algorithm is developed for the case of a simple, linear learning system-the LMS or delta rule with a separate learning-rate parameter for each input. The IDBD algorithm adjusts the learning-rate parameters, which are an important form of bias for this system. Because bias in this approach is adapted based on previous learning experience, the appropriate testbeds are drifting or non-stationary learning tasks. For particular tasks of this type, I show that the IDBD algo- rithm performs better than ordinary LMS and in fact finds the optimal learning rates. The IDBD algorithm extends and improves over prior work by Jacobs and by me in that it is fully incremen- tal and has only a single free parameter. This paper also extends previous work by presenting a derivation of the IDBD algorithm as gradient descent in the space of learning-rate parameters. Finally, I offer a novel interpretation of the IDBD algorithm as an incremental form of hold-one-out cross validation. People can learn very rapidly and generalize extremely accurately. Information theoretic arguments suggest that their inferences are too rapid to be justified by the data that they have immediately available to them. People can learn as fast as they do only because they bring to the learning situation a set of appropriate bi- ases which direct them to prefer certain hypotheses over others. To approach human performance, ma chine learning systems will also need an appropriate set of biases. Where are these to come from? Although this problem is well known, there are few general answers. The field of pattern recognition has long known about the importance of feature selection, and the importance of representations is a recurring theme in AI. But in both of these cases the focus has always been on designing in a good bias, not on acquir- ing one automatically. This has resulted in an accu- mulation of specialized and non-extensible techniques. Is there an alternative? If bias is what a learner brings to a learning problem, then how could the learner itself generate an appropriate bias? The only way is to gen- erate the bias from previous learning experience (e.g., Rendell, Seshu, & Tcheng 1987). And this is possible only if the learner encounters a series of different prob- lems requiring the same or similar biases. I[ believe that is a correct characterization of the learning task facing people and real-world learning machines. In this paper, I present a new algorithm for learn- ing appropriate biases for a linear learning system based on previous learning experience. The new al- gorithm is an extension of the Delta-Bar-Delta algo- rithm (Jacobs 1988; Sutton 1982; Barto & Sutton 1981; Kesten 1958) such that it is applicable to incremen- tal tasks-supervised learning tasks in which the ex- amples are processed one by one and then discarded. Accordingly, I call the new algorithm the Incremental Delta-Bar-Delta (IDBD) algorithm. The IDBD algo- rithm can be used to accelerate learning even on sin- gle problems, and that is the primary way in which its predecessors have been justified (e.g., Jacobs 1988; Silva & Almeida 1990; Lee & Lippmann 1990; Sutton 1986), but its greatest significance I believe is for non- stationary tasks or for sequences of related tasks, and it is on the former that I test it here. The 1 Algorithm The IDBD algorithm is a meta-learning algorithm in the sense that it learns the learning-rate parameters of an underlying base learning system. The base learn- ing system is the Least-Mean-Square (LMS) rule, also known as the delta rule, the ADALINE, the Rescorla- Wagner rule, and the Widrow-Hoff rule (see, e.g., Widrow & Stearns 1985). This learning system is of- ten thought of as a single connectionist unit as shown in figure 1. The unit is linear, meaning that its out- put y(t), at each time step (example number) t, is a Sutton 171 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. This exponential relationship between the learning rate, oi, and the memory parameter that is actually modified, pi, has two advantages. First, it is a natural way of assuring that ai will always be positive. Second, it is a mechanism for making geometric steps in oi: if pi is incremented up and down by a fixed step-size, then oi will move up or down by a fixed fraction of its current value, e.g., up or down by 10%. This is de- sirable because some ai must become very small while others remain large; no fixed step-size would work well for all the oi. The IDBD algorithm updates the pi by Figure 1: The base-level learning system is a single linear unit using the LMS or delta rule. weighted sum of its real-valued inputs xi(t): y(t) = g W(t)%(t), (1) kl were each w;(t) is the value at time t of a modifiable weight wi a&oLiated with zi. At each time step, the learner receives a set of inputs, Xi(t), computes its out- put, y(t), and compares it to a given desired output, y*(t). The aim of learning is to minimize the squared error S2(t), where 6(t) = y*(t) - y(t), on future time steps. The LMS learning rule updates the weights at each time step according to: Wi(t + 1) = W(t) + aS(t)Xi(t)j (2) where Q! is a positive constant called the learning rate. In the IDBD algorithm there is a different learning rate, oi, for each input xi, and these change according to a meta-learning process (cf. Hampson & Volper 1986). The base-level learning rule is ’ Wi(t + 1) = Wi(t) + CYi(t + l)S(t)Xi(t). (3) The learning rates are a powerful form of bias in this system. Learning about irrelevant inputs acts as noise, interfering with learning about relevant inputs. A rough rule of thumb is that learning time is propor- tional to the sum of the squares of the learning rates (assuming all inputs have equal variance; see \Nidrow & Stearns 1985). In effect, learning rates are a valu- able resource that must be distributed carefully. In- puts that are likely to be irrelevant should be given small learning rates, whereas inputs that are likely to be relevant should be given large learning rates. In the IDBD algorithm, the learning rates are all of the form c&(t) = ,fl@). (4 ‘The cr; are indexed by t + 1 rather than t simply to indicate that their update, by a process described below, occurs before the wi update (see figure 2). Pi(t + 1) = Pi(t) + @S(t)zi(t)h(t), (5) where 0 is a positive constant, the meta-learning rate, and hi is an updated by additional per-input memory parameter hi(t+l) = hi(t) [ l-ai(t+l)xf(t)] ++ai(t+l)6(t)xi(t), where [XI+ (6) is x, if x > 0, else 0. The first term in the above equation is a decay term; the product ai(t + 1)$(t) is normally zero or a positive fraction, so this term causes a decay of hi towards zero. The second term increments hi by the last weight change (cf. (3)). The memory hi is thus a decaying trace of the cumulative sum of recent changes to wi. The intuitive idea behind the IDBD algorithm is a simple one. Note that the increment to pi in (5) is pro- portional to the product of the current weight change, b(t)xi(t), and a trace of recent weight changes, hi(t). By accumulating this product, the overall change in & becomes proportional to the correlation between cur- rent and recent weight changes. If the current step is positively correlated with past steps, that indicates that the past steps should have been larger (and equa- tion (5) accordingly increases pi). If the current step is negatively correlated with past steps, that indicates that the past steps were too large; the algorithm is overshooting the best weight values and then having to m-correct in the opposite direction (here equation (5) decreases pi). The intuitive idea of the IDBD algorithm as de- scribed above is the same as that of Jacob’s (1988) Delta-Bar-Delta algorithm. The primary difference is that Jacobs’s algorithm can be applied only on a batch- by-batch basis, with updates after a complete presen- tation of a training set, whereas here we assume exam- ples arrive one-by-one and are not necessarily revisited afterwards. The key to making the new algorithm in- cremental is the way the trace hi is defined such that it fades away only to the extent that the correspond- ing input xi is present, as indicated by x”(t). The new algorithm also improves over Jacobs’s in that the de- =aY rate is not a separate free parameter, but is tied to the current learning rate. The new algorithm in fact has only one free parameter, the metalearning rate, 8, whereas Jacobs’s algorithm has three free parameters. 172 Learning: Neural Network and Hybrid Initialize hi to 0, and wi, pi as desired, i = I, . . . , n Repeat for each new example (2 1, . . . , x,, , y* ) : n j/ + xi=1 WXi Sty”-y Repeat for i= l,...,n: pi + pi + BSxihi Qli 4- e Bi Wi * Wi + CviSXi hi + hi + [I - aixf]+ + CviSxi 0.005 0.010 0.015 0.020 Figure 2: The IDBD Algorithm in Pseudocode Qn the other hand, Jacobs’s algorithm was designed for nonlinear networks. While I do not foresee great difficulties extending the IDBD algorithm to the non- linear case, that is beyond the scope of this paper. In practice, it is often useful to bound each pi from below by, say, -IO, to prevent arithmetic underflows. In addition, it is prudent to limit the change in /3i on any one step to, say, f2. However, these boundings were not required to obtain the empirical results pre- sented in the next section. The capabilities of the IDBD algorithm were assessed using a series of tracking tasks-supervised-learning or concept-learning tasks in which the target concept drifts over time and has to be tracked (cf. Schlimmer 1987). Non-stationary tasks are more appropriate here than conventional learning tasks because we are trying to assess the IDBD algorithm’s ability to learn biases during early learning and then use them in later learn- ing. To study this one needs a continuing learning problem, not one that can be solved once and is then finished. Experiment 1: Does I help? Experiment 1 was designed to answer the question: Does the IDBD algorithm perform better than the or- dinary LMS algorithm without IDBD? The task in- volved 20 real-valued inputs and one output. The in- puts were chosen independently and randomly accord- ing to a normal distribution with mean zero and unit variance. The target concept was the sum of the first five inputs, each multiplied either by +l or -I, i.e.: y* = 51x1+ 8212 + s3x3 + 54x4 i- @ix5 + ~~6+~~7+*-+~~20, where all the si are either + 1 or - 1. To make it a tracking problem, every 20 examples one of the five si was selected at random and switched in sign, from +l to -1, or vice versa. Thus, the same five inputs were always relevant, but their relationship to the tar- get concept occasionally changed. If the IDBD algo- rithm can successfully identify which inputs are rele- Figure 3: Comparison of the average asymptotic per- formances of IDBD and LMS algorithms over the rel- evant ranges of their step-size parameters (QI, upper axis, for LMS, and 0, lower axis, for IDBD). The IDBD algorithm results in less than half the level of error over a broad range of values of its step-size parameter. For parameter values above those shown, both algorithms can become unstable. vant, then it should be able to track the drifting target function more accurately than ordinary LMS. Because this is a tracking task, it suffices to per- form one long run and measure the asymptotic track- ing performance of the algorithms. In this experiment I ran each algorithm for 20,000 examples so as to get past any initial transients, and then ran another 10,000 examples. The average mean-squared error over that 10,000 examples was used as the asymptotic perfor- mance measure of the algorithm. The algorithms used were ordinary LMS with a range of learning rates and the IDBD algorithm with a range of meta-learning rates. The pi in the IDBD algorithm were set initially such that tyi = 0.05, for all a’ (but of course this choice has no affect on asymptotic performance). The results for both algorithms are summarized in figure 3. With its best learning rate, ordinary LMS attains a mean squared error of about 3.5, while the IDBD algorithm performs substantially better over a wide range of 0 values, attaining a mean squared er- ror of about 1.5. The standard errors of all of these means are less that 0.1, so this difference is highly sta- tistically significant. The IDBD algorithm apparently learns biases (learning rates) that enable substantially more accurate tracking on this task. Exp. 2: find the optimal a;? Experiment I shows that the IDBD algorithm finds a distribution of learning rates across inputs that is bet- ter than any single learning rate shared by all, but it does not show that it finds the best possible distribu- tion of learning rates. While this may be difficult to show as a general result, it is relatively easy to confirm empirically for special cases. To do this for the task used in Experiment 1, I chose a small value for the Sutton 173 IRRELEVANT et 1 looK TIME STEPS (# Examples) 1 2flw 25By Figure 4: Time course of learning-rate parameters, un- der IDBD, for one relevant and one irrelevant input. meta-learning rate, 8 = 0.001, and ran for a very large number of examples (250,000) to observe the asymp- totic distribution of learning rates found by the algo- rithm (as before, the learning rates were initialized to 0.05). Figure 4 shows the behavior over time of two of the cyi, one for a relevant input and one for an irrele- vant input. After 250,000 steps, the learning rates for the 15 ir- relevant inputs were all found to be less than 0.007 while the learning rates for the 5 relevant inputs were all 0.13f0.015. The learning rates for the irrelevant in- puts were apparently heading towards zero (recall that they cannot be exactly zero unless /3i = -oo), which is clearly optimal, but what of the relevant inputs? They should all share the same optimal learning rate, but is it @ 0.13, as found by the IDBD algorithm, or is it some other value? We can determine this empirically simply by trying various sets of fixed learning rates. The irrelevant inputs were all given fixed zero learning rates and the relevant inputs were fixed at a variety of values between 0.05 and 0.25. Again I ran for 20,000 examples, to get past transients, and then recorded the average squared error over the next 10,000 examples. The results, plotted in figure 5, show a clear minimum somewhere near 0.13f0.01, confirming that the IDBD algorithm found learning rates that were close to opti- mal on this task. Derivation of the IDBD Algorithm as Gradient Descent Many useful learning algorithms can be understood as gradient descent, including the LMS rule, backpropa- gation, Boltzmann machines, and reinforcement learn- ing methods. Gradient descent analysis can also be used to derive learning algorithms, and that in fact is the way in which the IDBD algorithm was invented. In this section I derive the IDBD algorithm as gradient descent. To illustrate the basic idea of gradient-descent anal- ysis, it is useful to first review how the base learn- 174 Learning: Neural Network and Hybrid L 0 . -.i= 1.8 - 2 3.6 1 31.4 - a : Figure 5: Average error as a function of the learning- rate parameter of the relevant inputs (the irrelevant inputs had zero learning-rate parameters). Error is minimized near CY = 0.13, the value found by the IDBD algorithm. ing rule, the LMS rule (2), can be derived as gradi- ent descent. Recall that we are trying to minimize the expected value of the squared error S2(t), where b(t) = y*(t) - y(t). The expected error as a function of the weights forms a surface. In gradient descent, a current value for w is moved in the opposite direction of the slope of that surface. This is the direction in which the expected error falls most rapidly, the direc- tion of steepest descent. Because the expected error is not itself-known, we use instead the gradient of the sample error S2(t): 1 ass(t) Wi(t + 1) = Wi(t) - -CY- 2 aWi(t)’ (7) The scalar quantity $X is the step-size, determining how far the weight vector moves in the direction of steepest descent. The righthand side: 3 drops out as we expand the Wi(t + 1) 1 S2(t) = Wi(t) - --cY- 2 aWi(t) Wt) = Wi(t) - OS(t)- @W(t) = Wi(t) - &S(t) a[Y*(o - YWI d?&(t) (8) aY(t) = Wi(t) + OS(t)- dwi (t) = = W(t) + aS(t) thus deriving the LMS rule (2). The derivation for the IDBD algorithm is very sim- ilar in principle. In place of (7), we start with &(t + 1) = @i(t) - :Op, i (9) where now $0 is the (meta) step-size. In this equa- tion, the partial derivitive with respect to pi without a time index should be interpretted as the derivative with repect to an infintesimal change in pi at all time steps. A similar technique is used in gradient-descent analyses of recurrent connectionist networks (c.f., e.g., Williams & Zipser 1989). We then similarly rewrite and expand (9) as: Pi(t + 1) = Pi(t) - ab2(t) BWj(t) fez-- j aWj(t) 8th 1 86’(t) aWj(t) Rs Pitt)- ijgawi(r)x. 00) The approximation above is reasonable in so far as the primary effect of changing the ith learning rate should be on the ath weight. Thus we assume $@ NN 0 for i # j. From (8) we know that -?jis = h(t)Xj(t); therefore we can rewrite (10) as pi(t + 1) m ,4(t) + @s(t)xi(t)hi(t), (11) where hi(t) is defined as p. The update rule for hi is in turn derived as follows:’ hi(t + 1) = aWi(t + 1) ap i It is often not recognized that the size of the step in the direction of the gradient may depend on the cur- rent value of the parameters being modified. Moreover, even the direction of the step can be changed, as long as it it is in the same general direction as the gradi- ent (positive inner product), without losing these key properties.2 For example, one could add a factor of 4, for any p, to the increment of /3i in (9) to obtain an en- tire new family of algorithms. In fact, experiments in progress suggest that some members of this family may be more efficient than the IDBD algorithm at finding optimal learning rates. There is little reason beyond simplicity for prefering the IDBD algorithm over these other possibilities a priori. The gradient analysis presented in this section tells us something about the IDBD algorithm, but it may also tell us something about incremental bias-learning algorithms in general. In particular, it suggests how one might derive bias-learning algorithms for other base learning methods, such as instance-based learn- ing methods. In instance-based learning systems an important source of bias is the parameters of the inter- instance distance metric. Currently these parameters are established by people or by offline cross-validation methods. An interesting direction for further research would be to attempt to repeat the sort of derivation presented here, but for instance-based methods. 0 =api Wj(t) + ePict+l)6(t)Xj(t)] (12) Conchsion WI The results presented in this paper provide evidence = hi(t) + @i(t+l)b(t)xi(t) + 8i(t+1) -xi(t), that the IDBD algorithm is able to distinguish relevant ap i from irrelevant inputs and to find the optimal learning using the product rule of calculus. Using the same rates on incremental tracking tasks. Depending on the approximation as before (in (lo)), we write problem, such an ability to find appropriate biases can result in a dramatic reduction in error. In the tasks W) = W) -- = -6 C Wj(t)Xj(t) used here, for example, squared error was reduced by aPi aI% ’ i approximately 60%. The IDBD algorithm achieves this a: while requiring only a linear increase in memory and m -- [tui(t)xi(t)] = -hi(t)xi(t)- computation (both increase by roughly a factor of three i over plain L&IS). This algorithm extends prior work Finally, plugging this back into (12) yields both because it is an incremental algorithm, operating on an example-by-example basis, and because it has hi(t + 1) w hi(t) + t8i”+“a(t)zi(t) - e’i(t+l),f(t)hi(t) fewer free parameters that must be picked by the user. r ‘I Also presented in this paper is a derivation of the IDBD m hi(t) [I- cQ(t + I)xf(t)] +oi(t + l)b(t)zi(t), algorithm as gradient descent. This analysis refines which, after adding a positive-bounding operation, is previous analyses by improving certain approximations the original update rule for hi, (6), while the derived and by being applicable to incremental training. update (11) for pi is the same as (5). On the other hand, only a linear version of the IDBD The above demonstrates that the IDBD algorithm is algorithm has been explored here. In addition, the a form of stochastic gradient descent in the learning- results presented do not show that the IDBD algorithm rate parameters pi. In other words, the algorithm will is the best or fastest way to find optimal learning rates. tend to cause changes according to their effect on over- Further work is needed to clarify these points. all error. At local optima, the algorithm will tend to be A good way of understanding the IDBD algorithm stable; elsewhere, it will tend to reduce the expected may be as an incremental form of cross validation. error. These might be considered necessary properties Consider the form of cross validation in which one ex- for a good learning algorithm, but they alone are not 2Such algorithms are no longer steepesbdescent algo- sufficient. For example, there is the issue of step-size. rithms, but they are still descent algorithms. Sutton 175 ample is held out, all the others are used for training, and then generalization is measured to the one held out. Typically, this is repeated N times for a training set of size IV, with a different example held out each time, and then the parameters are set (or stepped, fol- lowing the gradient) to optimize generalization to the one held out, averaged over all N cases. Obviously, this algorithm can not be done incrementally, but some- thing similar can be. At each time step, one could take the new example as the one held out, and see how all the training on the prior examples generalized to the new one. One could then adjust parameters to im- prove the generalization, as the IDBD algorithm does, and thereby achieve an effect very similar to that of conventional cross validation. Such methods differ fun- damentally from ordinary learning algorithms in that performance on the new example is optimized without using the new example. The IDBD algorithm is being explored elsewhere as a psychological model. The base learning algorithm used here, the LMS rule, has often been used to model human and animal learning behavior. Although that modeling has been generally successful, there have also been a number of areas of divergence between model and emperiment. In many cases the discrepancies can be significantly reduced by augmenting the LMS model with relevance-learning methods (e.g., Kruschke 1992; Hurwitz 1990). The IDBD algorithm is also being ex- plored in this regard, and the initial results are very encouraging (Gluck, Glauthier, & Sutton, in prepara- tion; Gluck & Glauthier, in preparation; see also Sut- ton 1982). One possible use of the IDBD algorithm is to assess the utility (relevance) of features cre- ated by constructive-induction methods or other representation-change methods. It is intriguing to think of using IDBD’s assessments in some way to ac- tually direct the feature-construction process. Finally, a broad conclusion that I make from this work has to do with the importance of looking at a series of related tasks, such as here in a non-stationary tracking task, as opposed to conventional single learn- ing tasks. Single learning tasks have certainly proved extremely useful, but they are also limited as ways of exploring important issues such as representation change and identification of relevant and irrelevant features. Such meta-learning issues may have only a small, second-order effect in a single learning task, but a very large effect in a continuing sequence of related learning tasks. Such cross-task learning may well be key to powerful human-level learning abilities. Acknowledgements The author wishes to thank Mark Gluck, without whose prodding, interest, and assistance this paper would never have been written, and Oliver Selfridge, who originally suggested the general approach. I also thank Richard Yee, Glenn Iba, Hamid Benbrahim, Chris Matheus, Ming Tan, Nick Little&one, Gregory Piatetsky, and Judy Franklin for reading and providing comments on an earlier draft of this paper. eferences Barto, A.G. & Sutton, R.S. (1981) Adaptation of learn- ing rate parameters, Appendix C of Goal Seeking Com- ponents for Adaptive Intelligence: An Initial Assessment. Air Force Wright Aeronautical Laboratories/Avionics Lab- oratory Technical Report AFWAL-TR-81-1070, Wright- Patterson AFB, Ohio. Gluck, M.A. & Glauthier P.T. (in preparation) Represents tion of dimensional stimulus structure in network theories of associative learning. Gluck, MA., Glauthier, P.T., & Sutton, R.S. (in prepara- tion) Dynamically modifiable stimulus associability in net- work models of category learning. Hampson, S.E. & Volper, D.J. (1986) Linear function neu- rons: Structure and training. Biological Cybernetics 53, 203-217. Hurwitz, J.B. (1990) A hidden-pattern unit network model of category learning. PhD thesis, Harvard Psychology Dept. Jacobs, R.A. (1988) I ncreased rates of convergence through learning rate adaptation. Neural Networks 1, 295-307. Kesten, H. (1958) A ccelerated stochastic approximation. Annals of Mathematical Statistics 29, 41-59. Kruschke, J.K. (1992) ALCOVE: An exemplar-based con- nectionist model of category learning. Psychological Re- view. Lee, Y. & Lippmann, R.P. (1990) Practical characteristics of neural network and conventional pattern classifiers on artificial and speech problems. In Advances in Neural In- formation Processing Systems 8, D.S. Touretzky, Ed., 168- 177. Rendell, L.A., Seshu, R.M., and Tcheng, D.K. (1987) Lay- ered concept learning and dynamically-variable bias man- agement , Proc. Tenth International Joint Conference on Artificial Intelligence, 308-314. Schlimmer, J.C. (1987) C oncept acquisition through rep- resentation adjustment. PhD thesis, University of Califor- nia, Information and Computer Science Dept., Technical Report 87-19. Silva, F.M. & Almeida, L.B. (1990) Acceleration tech- niques for the backpropagation algorithm. In Neural Net- works: EURASIP Workshop 1990, L.B. Almeida and C.J. Wellekens, Eds., 110-l 19. Berlin: Springer-Verlag. Sutton, R.S. (1982) A theory of salience change dependent on the relationship between discrepancies on successive tri- als on which the stimulus is present. Unpublished working paper. Sutton, R.S. (1986) T wo problems with backpropagation and other steepest-descent learning procedures for net- works. Proceedings of the Eighth Annual Conference of the Cognitive Science Society, 823-831. Widrow, B. & Stearns, S.D. Adaptive Signal Processing. Englewood Cliffs, NJ: Prentice-Hall, 1985. Williams, R.J. & Zipser, D. (1989) Experimental analysis of the real-time recurrent learning algorithm. Connection Science 1, 87-111. 176 Learning: Neural Network and Hybrid | 1992 | 42 |
1,235 | Geoffrey G. Tbwell+ towell@learning.siemens.com shavlik@cs.wisc.edu University of Wisconsin 1210 West Dayton Street Madison, Wisconsin 53706 Abstract The previously-described KBANN system integrates ex- isting knowledge into neural networks by defining the network topology and setting initial link weights. Stan- dard neural learning techniques can then be used to train such networks, thereby refining the information upon which the network is based. However, standard neural learning techniques are reputed to have diffi- culty training networks with multiple layers of hidden units; KBANN commonly creates such networks. In ad- dition, standard neural learning techniques ignore some of the information contained in the networks created by KBANN. This paper describes a symbolic inductive learning algorithm for training such networks that uses this previously-ignored information and which helps to address the problems of training “deep” networks. Em- pirical evidence shows that this method improves not only learning speed, but also the ability of networks to generalize correctly to testing examples. Introduction KBANN is a “hybrid” learning system; it combines rule- based reasoning with neural learning to create a system that is superior to either of its parts. Using both theory and data to learn categorization tasks, KBANN has been shown to be more effective at classifying examples not seen during training than a wide variety of machine learning algorithms (Towel1 et al., 1990; Noordewier et ad., 1991; Towell, 1991). However, recent experiments (briefly described on the next page) point to weaknesses in the algorithm. In addition, neural learning techniques are commonly thought to be relatively weak at training networks that *This research was partially supported by Office of Naval Research Grant N00014-90-J-1941, National Science Foun- dation Grant IRI-9002413, and Department of Energy Grant DE-FG02-91ER61129. ‘Currently at: Siemens Corporate Research, 755 College Road East, Princeton, NJ 08540. have several layers of hidden units. Unfortunately, the networks created by KBANN (KBANN-nets) frequently have this “deep network” property. Hence, algorithms such as backpropagation (Rumelhart et al., 1986) may not be well suited to training KBANN-nets. To address both this problem with the training of KBANN-nets and KBANN’S empirically discovered weak- nesses, this paper introduces the DAID (Desired An- tecedent IDentification) algorithm. Following a descrip- tion of DAID, we present results which empirically verify that DAID achieves both of its goals. The KBANN Algorithm KBANN, illustrated in Figure 1, is an approach to com- bining rule-based reasoning with neural learning. The principle part of KBANN is the rules-to-network trans- lation algorithm, which transforms a knowledge base of domain-specific inference rules (that define what is ini- tially known about a topic) into a neural network. In so doing, the algorithm defines the topology and con- nection weights of the networks it creates. Detailed ex- planations of this rules-to-network translation appear in (Towel1 et al., 1990; Towell, 1991). As an example of the KBANN rules-to-network trans- lation method, consider the small rule set in Figure 2a that defines membership in category A. Figure 2b rep- resents the hierarchical structure of these rules: solid and dotted lines represent necessary and prohibitory dependencies, respectively. Figure 2c represents the KBANN-net that results from the translation of this do- Initial ::i \;;;z -;; -Neura,~R~ Training Translation Learning Network Examples Figure 1: The flow of information through KBANN. Towel1 and Shavlik 177 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. A:-B,C. B :- not H. B :-not F,G. C :- I, J. fc) I i Figure 2: Translation of a domain theory into a KBANN- net. main knowledge into a neural network. Units X and Y in Figure 2c are introduced into the KBANN-net to han- dle the disjunction in the rule set (Towel1 et al., 1990). Otherwise, each unit in the KBANN-net corresponds to a consequent or an antecedent in the domain knowledge. The thick lines in Figure 2c represent heavily-weighted links in the KBANN-net that correspond to dependen- cies in the domain knowledge. Weights and biases in the network are set so that the network’s response to inputs is exactly the same as the domain knowledge. The thin lines represent links with near zero weight that are added to the network to allow refinement of the domain knowledge. More intelligent initialization of the weights on these thin lines is the focus of this paper. This example illustrates the two principal benefits of using KBANN. First, the algorithm indicates the fea- tures that are believed to be important to an example’s classification. Second, it specifies important derived features, thereby guiding the choice of the number and connectivity of hidden units. Initial Tests of KBANN The tests described in this section investigate the effects of domain-theory noise on KBANN. The results of these tests motivated the development of DAID. These tests, as well as those later in this paper, use real-world problems from molecular biology. The pro- moter recognition problem set consists of 106 training examples split evenly between two classes (Towel1 et al., 1990). The splice-junction determination problem has 3190 examples in three classes (Noordewier et al., 1991). Each dataset also has a partially correct domain theory. Earlier tests showing the success of KBANN did not question whether KBANN is robust to domain-theory noise. The tests presented here look at two types of domain-theory noise: deleted antecedents and added an- tecedents. Details of the method used for modifying existing rules by adding and deleting antecedents, as well as studies of other types of domain-theory noise, are given in (Towell, 1991). 0.3= 8 2 B 0.2. g O.l= z Is 0.0. 0 10 20 30 40 50 Probability of the Addition of Noise to the Domain Theory Drop an antecedent T - - - Fully-connected standard ANN 4-b Add an antecedent Figure 3: Effect of antecedent-level noise on the classi- fication accuracy in the promoter domain. Figure 3 presents the results of adding noise to the promoter domain theory. All results represent an av- erage over three different additions of noise. Eleven randomized runs of ten-fold cross-validation (Weiss and Kulikowski, 1990) are used to test generalization. Not surprisingly, this figure shows that test set error rate increases directly with the amount of noise. More in- teresting is that the figure shows the effect of delet- ing antecedents is consistently larger than the effect of adding antecedents. Clearly, irrelevant antecedents have little effect on KBANN-nets; with 50% noise’ the performance of KBANN-nets is still superior to that of a fully-connected standard ANN (i.e., an Artificial Neural Network with one layer of hidden units that are fully connected to both the input and output units). Conversely, drop- ping only 30% of the original antecedents degrades the performance of KBANN-nets to below that of standard ANNs. Symbolic Induction on omain Theories The experiments in the previous section indicate that it is easier for KBANN to discard antecedents that are useless than to add antecedents initially believed to be irrelevant. Hence, a method that tells KBANN about potentially useful features not mentioned in the domain theory might be expected to improve KBANN’S learning abilities. The DAID algorithm, described and tested in the re- mainder of this paper, empirically tests this hypothesis. It “symbolically” looks through the training examples to identify antecedents that may help eliminate errors in the provided rules. This is DAID ‘s sole goad. The algo- rithm accomplishes this end by estimating correlations between inputs and corrected intermediate conclusions. In so doing, DAID suggests more antecedents than are ‘50% noise means that for every two antecedents speci- fied as important by the original domain theory, one spuri- ous antecedent was added. 178 Learning: Neural Network and Hybrid Network aeural Figure 4: Flow of information using KBANN-DAID. useful; it relies upon KBANN’S strength at rejecting use- less antecedents. DAID adds an algorithmic step to KBANN, as the addition of the thicker arrows in Figure 4 illustrates. Briefly, DAID uses the initial domain theory and the training examples to supply information to the rules-to- network translator that is not available in the domain theory alone. As a result, the output of the rules-to- network translator is not simply a recoding of the do- main theory. Instead, the initial KBANN-net is slightly, but significantly, shifted from the state it would have assumed without DAID. Overview of the DAID algorithm The assumption underlying DAID is that errors occur primarily at the lowest levels of the domain theory.2 That is, DAID assumes the only rules that need cor- rection are those whose antecedents are all features of the environment. DAID’S assumption that errors oc- cur solely at the bottom of the rule hierarchy is sig- nificantly different from that of backpropagation (and other neural learning methods). These methods assume that error occurs along the whole learning path. As a result, it can be difficult for backpropagation to correct a KBANN-net that is only incorrect at the links con- necting input to hidden units. Thus, one of the ways in which DAID provides a benefit to KBANN is through its different learning bias. This difference in bias can be important in net- works with many levels of connections between inputs and outputs (as is typical of KBANN-nets). In such networks, backpropagated errors can become diffused across the network. The result of a diffuse error signal is that the low-level links all change in approximately the same way. Hence, the network learns little. DAID does not face this problem; its error-determination pro- cedure is based upon Boolean logic so errors are not diffused needlessly. 2This idea has a firm philosophical foundation in the work of William Whewell. His theory of the consilience of inductions suggests that the most uncertain rules are those which appear at the lowest levels of a rule hierarchy and that the most certain rules are those at the top of the hierarchy (Whewell, 1989). Algorithm specification To determine correlations between inputs and interme- diate conclusions, DAID must first determine the “cor- rect” truth-value of each intermediate conclusion. Do- ing this perfectly would require DAID to address the full force of the “credit-assignment” problem (Minsky, 1963). However, DAID need not be perfect in its deter- minations because its goal is simply to identify poten- tially useful input features. Therefore, the procedure used by DAID to track errors through a rule hierarchy simply assumes that every rule which can possibly be blamed for an error is to blame. DAID further assumes that all the antecedents of a consequent are correct if the consequent itself is correct. These two ideas are encoded in the recursive procedure BACK UPANS WER that is outlined in Table 1, and which we describe first. BACKUPANSWER works down from any incorrect fi- nal conclusions, assigning blame for incorrect conclu- sions to any antecedents whose change could lead to the consequent being correct. When BACKUPANSWER identifies these “changeable” antecedents, it recursively descends across the rule dependency. As a result, BACKUPANSWER visits every intermediate conclusion Table 1: Summary of the DAID algorithm. DAID: GOAL: Find input features relevant to the corrected low-level conclusions. Establish eight counters (see text) associating each feature-value pair with each of the lowest-level rules. Cycle through each of the training examples and do the following: Q Compute the truth value of each rule in the original domain theory. Use BACKUPANSWER to estimate the correct value of each lowest-level consequent. e Increment the appropriate counters. Compute correlations between each feature-value pair and each of the lowest-level consequents. Suggest link weights according to correlations. BACKUPANSWER: GOAL: Determine the “correct” value of each intermediate conclusion. 1. Initially assume that all antecedents are correct 2. For each antecedent of the rule being investigated: (B Determine the correctness of the antecedent o Recursively call BACKUPANSWER if the an- tecedent is incorrect Towel1 and Shavlik 179 which can be blamed for an incorrect final conclusion. Given the ability to qualitatively trace errors through a hierarchical set of rules, the rest of DAID is relatively straightforward. The idea is to maintain, for the con- sequent of each of the lowest-level rules, counters for each input feature-value pair (i.e., for everything that will become an input unit when the rules are translated into a KBANN-net). These counters cover the following conditions: e does the feature have this value? o is the consequent true for this et of features? e does the value of the consequent agree with BACKUPANSWER% expected value? Hence, each of the lowest-level consequents must main- tain eight counters for each input feature (see Table 1). DAID goes through each of the training examples, run- ning BACKUPANSWER, and incrementing the appropri- ate counters. After the example have been presented, the coun- ters are combined into the following four correlations3: Notice that these correlations look only at the relation- 1. between conseq( incorrect Ifalse) and feat( present), i.e., a consequent being false and disagreeing with BACKUPANSWER and a feature being present, 2. between conseq(correct Ifalse) and feat(present), 3. between conseq(incorrect 1 true) and feat(present) , 4. between conseq(correct 1 true) and feat(present). ship between features that are present and the state of intermediate conclusions. This focus on features that are present stems from the DAID’S emphasis on the ad- dition of antecedents. Also, in our formulation of neu- ral networks, inputs are in the range [O.. . l] so a fea- ture that is not present has a value of zero. Hence, the absence of a feature cannot add information to the network. DAID makes link weight suggestions according to the relationship between the situations that are aided by the addition of a highly-weighted features and those that are hurt by the addition of a highly-weighted fea- ture. For instance, correlation 1 between a feature and a consequent has a large positive value when adding that feature to the rule would correct a large portion of the occasions in which the consequent is incorrectly false. In other words, correlation 1 is sensitive to those situa- tions in which adding a positively-weighted antecedent would correct the consequent. On the other hand, cor- relation 2 has a large positive value when adding a 3The correlations can be computed directly from the counters because the values being compared are always ei- ther 0 or 1. 180 Learning: Neural Network and Hybrid positively-weighted antecedent would make a correct consequent incorrect. Hence, when suggesting that a feature be given a large positive weight it is important to consider both the value of correlation 1 and the dif- ference between correlations I and 2. Similar reason- ing suggests that the best features to add with a large negative weight are those with the largest differences between correlations 3 and 4. Actual link weight sug- gestions are a function of the difference between the relevant correlations and the initial weight of the links corresponding to antecedents in the domain theory (i.e., the thick lines in Figure 2).4 Recall that the link-weight suggestions that are the end result of DAID are not an end of themselves. Rather, they are passed to the rules-to-network trans- lator of KBANN where they are used to initialize the weights of the low-weighted links that are added to the network. By using these numbers to initialize weights (rather than merely assigning every added link a near- zero weight), the KBANN-net produced by rules-to- network translator does not make the same errors as the rules upon which it is based. Instead, the KBANN- net is moved away from the initial rules, hopefully in a direction that proves beneficial to learning. Example of the algorithm As an example of the DAID algorithm, consider the rule set whose hierarchi- cal structure is depicted in Figure 5. In this figure, solid lines represent unnegated dependencies while dashed lines represent negated dependencies. Arcs connecting dependencies indicate conjuncts. Figure 6 depicts the state of the rules after the pre- sentation of each of the three examples. In this fig- ure, circles at the intersections of lines represent the values computed for each rule - filled circles represent “true” while empty represent “false.” The square to the right of each circle represents the desired truth value of each consequent as calculated by the BACKUPANSWER procedure in Table 1. (Lightly-shaded squares indicate that the consequent may be either true or false and be considered correct. Recall that in BACWPANSWER, once the value of a consequent has been determined to be correct, then all of its dependencies are considered to be correct.) Consider, for example, Figure 6i which depicts the rule structure following example i. In this case the fi- nal consequent a is incorrect. On its first step back- ward, BACKUPANSWER determines that c has an in- correct truth value while the truth value of b is cor- *Our use of correlations to initialize link weights is rem- iniscent of Fahlman and Lebiere’s (1989) cascade correla- tion. However, our approach differs from cascade correla- tion in that the weights given by the correlations are sub- ject to change during training. In cascade correlation, the correlation-based weights are frozen. a 8 .* .- l 8 b c d e f g h ’ j k Figure 5: Hierarchical stricture of a simple rule set. Figure 6: The state of the rule set after presenting three examples. rect. (Desired truth values invert across negative de- pendencies.) Because b is correct, all its supporting antecedents are considered correct regardless of their truth values. Hence, both d and e are correct. After seeing the three examples in Figure 6, DAID would recommend that the initial weights from f to d and e remain near 0 while the initial weight from f to c be set to a large negative number. However, the sug- gestion of a large negative weight from f to c would be ignored by the rules-to-network translator of KBANN because the domain theory specifies a dependency in that location. Tests of KBANN-DAID Results in this section demonstrate the effectiveness of the KBANN-DAID combination along two lines: (1) generalization, (2) effort required to learn. Following the methodology of the results reported earlier, these results represent an average of eleven ten-fold cross- validation runs. Figure 7 shows that DAID improves generalization by KBANN-nets in the promoter domain by almost two percentage points. The improvement is significant with 99.5% confidence according to a one-tailed Z-test. DAID only slightly improves generalization for splice- junctions. Also important is the computational effort required to learn the training data. If DAID makes learning eas- ier for KBANN-nets, then it might be expected to ap- pear in the training effort as well as the correctness reported above. Figure 8 plots the speed of learning on both splice-junctions and promoters. ( DAID requires about the number of arithmetic operations as in a sin- gle backpropagation training epoch.) Learning speed is measured in terms of the number of arithmetic opera- Splice-Junction Domain Figure 7: Generalization using DAID. (Estimated using lo-fold cross-validation). PromoterDomain Splice-Junction Domain KBANN KBANN Std KBANN KBANN Std DAID ANN DAID ANN Figure 8: Training effort required when using DAID. (Effort is normalized to basic KBANN.) tions required to learn the training set. The results show that DAID dramatically speeds learning on the promoter problem. (This result is statis- tically significant with greater than 99.5% confidence.) DAID also speeds learning on the splice-junction prob- lem. However, the difference is not statistically signifi- cant. In summary, these results show that DAID is effec- tive on the promoter data along both of the desired dimensions. DAID significantly improves both the gen- eralization abilities, and learning speed of KBANN-nets. Conversely, on the splice-junction dataset, DAID has lit- tle effect. The difference in the effect of DAID on the two problems is almost certainly due to the nature of the re- spective domain theories. Specifically, the domain the- ory for splice-junction determination provides for little more than Perceptron-like learning (Rosenblatt , 1962)) as it has few modifiable hidden units. (Defining “depth” as the number of layers of modifiable links, the depth of the splice-junction domain theory is one for one of the output units and two for the other.) Hence, the learn- ing bias that DAID contributes to KBANN - to changes at the lowest level of the domain theory - is not signif- icant. On the other hand, the promoter domain theory has a depth of three. This is deep enough that there is a significant difference in the learning biases of DAID and backpropagation. Towel1 and Shavlik 181 Future Work We are actively pursuing two paths with respect to KBANN-DAID. The simpler of the paths is the investiga- tion of alternate methods of estimating the appropriate link weights. One approach replaces correlations with ID3’s (Quinlan, 1986) information gain metric to select the most useful features for each low-level antecedent. This approach is quite similar to some aspects of EI- THER (Ourston and Mooney, 1990). Another method we are investigating tracks the specific errors addressed by each of the input features. Rather than collecting error statistics across sets of examples, link weights are assigned to the features to specifically correct all of the initial errors. The more challenging area of our work is to achieve a closer integration of DAID with backpropagation. Cur- rently DAID can be applied only prior to backpropaga- tion because it assumes that the inputs to each rule can be expressed using Boolean logic. After running either backpropagation or DAID, this assumption is invalid. As a result, DAID’S (re)use is precluded. It may be pos- sible to develop techniques that recognize situations in which DAID can work. Such techniques could allow the system to decide for each example whether or not the clarity required by DAID exists. Hence, DAID would not be restricted to application prior to neural learning. Conclusions This paper describes the DAID preprocessor for KBANN. DAID is motivated by two observations. First, neural learning techniques have troubles with training “deep” networks because error signals can become diffused. Second, empirical studies indicate that KBANN is most effective when its networks must learn to ignore an- tecedents (as opposed to learning new antecedents). Hence, DAID attempts to identify antecedents, not used in the domain knowledge provided to KBANN, that may be useful in correcting the errors of the domain knowl- edge. In so doing, DAID aids neural learning techniques by lessening errors in the areas that these techniques have difficulty correcting. DAID is a successful example of a class of algorithms that are not viable in their own right. Rather, the mem- bers of this class are symbiotes to larger learning al- gorithms which help the larger algorithm overcome its known deficiencies, Hence, DAID is designed to reduce KBANN’S problem with learning new features. Empiri- cal tests show that DAID is successful at this task when the solution to the problem requires deep chains of rea- soning rather than single-step solutions. DAID’S success on deep structures and insignificance on shallow structures is not surprising, given the learn- ing bias of DAID and standard backpropagation. Specif- ically, DAID is biased towards learning at the bottom of reasoning chains whereas backpropagation is, if any- thing, bias towards learning at the top of chains. In a shallow structure like that of the splice-junction do- main, there is no difference in these biases. Hence, DAID has little effect. However, in deep structures, DAID dif- fers considerably from backpropagation. It is this dif- ference in learning bias that results in the gains in both generalization and speed that DAID provides in the pro- moter domain. References Fahlman, S. E. & Lebiere, C. 1989. The cascade- correlation learning architecture. In Advances in Neural Information Processing Systems, volume 2, pages 524- 532, Denver, CO. Morgan Kaufmann. Minsky, M. 1963. Steps towards artificial intelligence. In Feigenbaum, E. A. & Feldman, J., editors, Computers and Thought. McGraw-Hill, New York. Noordewier, M. 0.; Towell, G. G.; & Shavlik, J. W. 1991. Training knowledge-based neural networks to recognize genes in DNA sequences. In Advances in Neural Informa- tion Processing Systems, volume 3, Denver, CO. Morgan Kaufmann. Ourston, D. & Mooney, R. J. 1990. Changing the rules: A comprehensive approach to theory refinement. In Pro- ceedings of the Eighth National Conference on Artificial Intelligence, pages 815-820, Boston, MA. Quinlan, J. R. 1986. Induction of decision trees. Machine Learning, 1:81-106. Rosenblatt, F. 1962. Principles of Neurodynamics: Per- ceptrons and the Theory of Brain Mechanisms. Spartan, New York. Rumelhart, D. E.; Hinton, G. E.; & Williams, R. J. 1986. Learning internal representations by error propagation. In Rumelhart, D. E. & McClelland, J. L., editors, Parallel Distributed Processing: Explorations in the microstruc- ture of cognition. Volume 1: Foundations, pages 318-363. MIT Press, Cambridge, MA. Towell, 6. G.; Shavlik, J. W.; & Noordewier, M. 0. 1990. Refinement of approximately correct domain theo- ries by knowledge-based neural networks. In Proceedings of the Eighth National Conference on Artificial Intelli- gence, pages 861-866, Boston, MA. Towell, G. G. 1991. Symbolic Knowledge and Neural Networks: Insertion, Refinement, and Extraction. PhD thesis, University of Wisconsin, Madison, WI. Weiss, S. M. & Kulikowski, C. A. 1990. Computer Sys- tems that Learn. Morgan Kaufmann, San Mateo, CA. Whewell, W. 1989. Theory of the Scientific Method. Hackett, Indianapolis. Originally published in 1840. 182 Learning: Neural Network and Hybrid | 1992 | 43 |
1,236 | ei Lonnie Chrisman School of Computer Science Carnegie Mellon University Pittsburgh, PA 15213 chrisman@cs.cmu.edu Abstract It is known that Perceptual Aliasing may sig- nificantly diminish the effectiveness of reinforce- ment learning algorithms [Whitehead and Ballard, 19911. Perceptual aliasing occurs when multiple situations that are indistinguishable from imme- diate perceptual input require different responses from the system. For example, if a robot can only see forward, yet the presence of a battery charger behind it determines whether or not it should backup, immediate perception alone is insufficient for determining the most appropriate action. It is problematic since reinforcement algorithms typi- cally learn a control policy from immediate per- ceptual input to the optimal choice of action. This paper introduces the predictive distinctions approach to compensate for perceptual aliasing caused from incomplete perception of the world. An additional component, a predictive model, is utilized to track aspects of the world that may not be visible at all times. In addition to the control policy, the model must also be learned, and to al- low for stochastic actions and noisy perception, a probabilistic model is learned from experience. In the process, the system must discover, on its own, the important distinctions in the world. Exper- imental results are given for a simple simulated domain, and additional issues are discussed. Introduction Reinforcement learning techniques have recently re- ceived a lot of interest due to their potential appli- cation to the problem of learning situated behaviors for robotic tasks ([Sutton, 19901, [Lin, 19911, [Mahade- van and Connell, 19911, [Mill&n and Torras, 19911, [Chapman and Kaelbling, 19911). The objective for a reinforcement learning agent is to acquire a policy for choosing actions so as to maximize overall perfor- mance. After each action, the environment provides feedback in the form of a scalar reinforcement value, and the discounted cumulative reinforcement is cus- tomarily used to assess overall performance. Percepta 6 At At C J Ra ard Figure 1: Data Flow Through System Components. The effectiveness of reinforcement learning tech- niques may significantly diminish when there exist per- tinent aspects of the world state that are not directly observable. The difficulty arises from what [Whitehead and Ballard, 19911 h ave termed perceptual &using, in which two or more perceptually identical states require different responses. An agent that learns its behav- ior as a function from immediate percepts to choice of action will be susceptible to perceptual aliasing ef- fects. Nevertheless, common factors such as the pres- ence of physical obstructions, limited sensing resources, and restricted field of view or resolution of actual sen- sors make incomplete observability a ubiquitous facet of robotic systems. The Lion algorithm [Whitehead and Ballard, 19911, the CS-QL algorithm [Tan, 19911, and the INVOKE-N algorithm [Wixson, 19911 were previously introduced to cope with perceptual aliasing. Each of these al- gorithms compensates for aliasing effects by accessing additional immediate sensory input. This paper intro- duces a new approach that overcomes limitations of previous techniques in two important ways. First, as- sumptions of deterministic actions and noiseless sens- ing are dropped. And second, the new technique ap- plies to tasks requiring memory as a result of incom- plete perception [Chrisman et al., 19911. For example, if a warehouse robot has permanently closed and sealed a box and the box’s contents determines its next ac- tion, it is necessary to remember the box’s contents. Incomplete perception of this sort cannot be overcome by obtaining additional immediate perceptual input. The current predictive distinction approach intro- duces an additional predictive model into the system1 , ‘Predictive models have been used in reinforcement learning systems for various purposes such as experience C hrisman 183 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. as shown in Figure 1. The predictive model tracks the world state, even though various features might not be visible at all times. Instead of learning a transfer function from percepts to evaluation of action, rein- forcement learning now learns a transfer function from the internal state of the predictive model to action evaluation. Deterministic actions and noiseless sens- ing are not assumed; therefore, the predictive model is probabilistic2. A sufficient predictive model will usually not be supplied to the system a priori, so the model must be acquired or improved as part of the learning process. Learning the model involves not only estimating transition and observation probabili- ties, but also discovering what the states of the world actually are (c.f., [Drescher, 19911). This is because perceptual discriminations can no longer be assumed to correspond directly with world states. With a noisy sensor, it may be possible to observe two or more dif- ferent percepts from the same state, or perceptual in- completeness may cause identical percepts to register from distinct world states. In our experiments, the agent begins initially with a small, randomly generated predictive model. The agent proceeds to execute actions in the world, per- forming a variation of Q-learning [Watkins, 19891 for action selection using the internal state of the pre- dictive model as if it were perceptual input. After some experience has been gathered, this experience is used to improve the current predictive model. Using maximum likelihood estimation, probabilities are up- dated. Next, the program attempts to detect distinc- tions in the world that are missing from its current model. When the experience gives statistically signifi- cant evidence in support of a missing discrimination, a new distinction is introduced by recursively partition- ing the internal state space of the model and readjust- ing probabilities. The system then cycles, using the new improved model to support Q-learning. The next section introduces the general form of the predictive model and the Bayesian estimation proce- dure that uses it to update belief about the state of the world. The process of reinforcement learning when the model is provided is then discussed, followed by the model learning algorithm. Some empirical results are reviewed, and finally important issues and future research topics are listed. The Predictive Model A predictive model is a theory that can be used to make predictions about the effects of actions and about what the agent expects to perceive. In general, it may be necessary to maintain internal state in order to track replay (e.g., [Lin, 19911, DYNA [Sutton, 19901) 21t may also be possible to apply recurrent neural net- works to learn and use a predictive model in a simi- lar fashion ([Jordan and Rumelhart, 19921, [Lin, personal communication]). aspects of the world that may occasionally become un- observable to the agent. For example, to predict what will be seen after turning around, a predictive model should remember the contents of that location the last time it was visible. Interestingly, the ability to predict is not the characteristic that makes predictive mod- els useful for overcoming perceptual aliasing. Instead, it is the internal state that is formed and utilized to make predictions which is valuable to the reinforce- ment learner. The central idea behind the current approach is that the information needed to maximize predictiveness is usually the same information missing from perceptually aliased inputs. Predictions need not be deterministic, and in fact in this context, deterministic models are inappropriate. The models here are stochastic. It is assumed that at any single instant t, the world state st is in exactly one of a finite number of classes, cZass(st) E { 1,2, . . . . n}, and class identity alone is sufficient to stochastically determine both perceptual response and action effects ( i.e., the Murkov assumption). A single class in the model may correspond to several possible world states. The agent has available to it a finite set of actions A. For each action and pair of classes, U~j specifies the probability that executing action A from class i will move the world into class j. The class of the world state is never directly observable - only probabilis- tic clues to its identity are available in the form of percepts. The perceptual model, bj(o), specifies the probability of observing v when the world state is in class j. Together, Ui4j and bj(v) form the complete predictive model. For this paper, v is assumed to be a finite and nominal (unordered) variable. Predictive models of this form are commonly referred to as Par- tially Observable Murkov Decision Processes ([Lovejoy, 19911, [Monahan, 19821). The actual class of the world at any instant is never directly observable, and as a result, it is in general not possible to determine the current class with absolute certainty. Instead, a belief is maintained in the form of a probability vector Z(t) = (nl(t), q?(t), . . ..?r.(t)), where xi(t) is the believed probability that class(+) is i at the current time t. Whenever an action is executed and a new observation obtained, Bayesian conditioning is used to update the belief vector as follows Tj(t + 1) = k * bj(v) >: utjri(t) where A is the action executed, v is the sensed percept, and k is a normalizing constant chosen so that the components of Z(t + 1) sum to one. Reinforcement Learning Once a predictive model is available to the system, the task of the reinforcement learner is to learn the value of each action from each possible belief state. Specif- ically, the system must learn the function Q(i;, A) : 3” x A -+ 8, which returns the estimated cumulative 184 Learning: Robotic discounted rewards (referred to as the Q value) when given an action A E A and a vector of probabilities n’ specifying the belief about the state of the world. To learn this function, a variation of the Q-learning algo- rithm ([Watkins, 19891, [Barto et al., 19911) is used. However, the Q-learning algorithm must be modified in this case because the domain of Q is not discrete and finite as the unmodified algorithm requires. To learn the Q function, a very simple approxima- tion is used. For each class i in the predictive model and each action A, a value V[i,A] is learned. &($,A) is then approximated as Q(i;, A) M 2 n;V[i, A] d=l This approximation is accurate when the model is highly predictive of the class distinctions that impact the optimal control, so that most probability mass is usually distributed among classes that agree upon the optimal action. This approximation works well for many applications requiring memory to address per- ceptual aliasing, but is inappropriate for choosing be- tween information gathering actions and active percep- tion. Learning Q involves only adjusting the values of V. This is done using the Q-learning rule, except that each class is treated as being only fractionally occu- pied. Each entry is adjusted by that fraction using the update rule V[i, Al = (1 - Pri(t))V[i, A] + P%(t)(r + yU(fqt + 1))) U@(t -k 1)) = m;xQ(ii(t + l),A) where A is the action taken, r is the reward received, y is a discount factor, and ,0 is the learning rate. All V[i,A] for i = 1, . . . . n are updated after each action. If the model identifies a single class as the only one with a non-zero probability mass, the update rule reduces to conventional Q-learning. With a predictive model in hand and the above updating rule in place, the overall scenario for this part of the system is the same as with most reinforce- ment learning systems. At each cycle, the agent ob- tains its current state estimate Z(t) (in this case, from its predictive model) and executes the action having the largest Q(i;(t),A). After the action completes, Bayesian conditioning uses n(t) and the new percep- tual input v to obtain Z(t + 1). The updating rule is applied and the cycle repeats. Model Learning Experience obtained by the agent from executing ac- tions and the resulting perceptual input is used to im- prove its current predictive model. The task of the model learning algorithm is to obtain the best pre- dictive model it can from this experience. This in- volves two aspects. First, given a set of classes, both the action transition probabilities U~j and the obser- vation probabilities bj(v) must be adjusted in order to maximize predictiveness. Second, the algorithm must detect and incorporate any additional distinctions ex- isting in the world that are not currently accounted for by the model. Incorporating a new distinction in- volves enlarging the number of classes recognized by the model. If no initial predictive model is supplied to the system, the system begins with a two state model with randomized probabilities and then uses the algo- rithm to improve and enlarge it from experience. Being probabilistic, model learning involves statisti- cal assessment, making it is necessary to collect a body of experience before running the model learning algo- rithm. The agent executes for a prespecified number of cycles (m), recording each action-observation pair and continuously performing (modified) Q-learning. The agent then invokes the model learning algorithm, us- ing the recorded experience as input, to produce an improved predictive model. The entire process then repeats. Since policy and model learning are inter- leaved, model learning is sensitive to the current con- trol policy (c.f., [Jordan and Rumelhart, 19921). As the control policy tends towards optimality, recorded experience will be primarily composed of states on the path to goal achievement, leading the model learning algorithm to learn mostly about situations that impact goal achievement. Probability Adjustment The first task in improving the model is adjusting the probabilities U~j and bj (v) so as to maximize the pre- dictiveness of the model. Simultaneously learning both action and perception models presents difficulties since the true class of the world is never directly revealed to the system. If the true class of the world were known at each instant, the problem would be trivial since the transition and observation frequencies could simply be counted and used. Nevertheless, it is possible to use the probability distribution i;(t), representing the be- lief about the class of the world. For example, if at time tl the DROP action is executed, we can use ?(tl) and i;(tl + 1) to assess the expected, rather than the actual, transition. If rs(tl) = 0.6 and rT(tl + 1) = 0.9, then the count of the number of times that the DROP action results in a transition from class 2 to class 7 is incremented by 0.6 x 0.9 = 0.54. After the expected counts are tallied, the counts are divided as usual to ob- tain expected frequencies, which are then used for the resulting model probabilities. Before frequency count- ing, the Baum forward-backward procedure [Rabiner, 19891 is used to obtain improved an estimate for ii. The Baum forward-backward procedure is an efficient dynamic programming algorithm with a run-time com- plexity of O(m . 1X1), where m is the length of the ex- perience trace, and (X( is size of the model (i.e., the number of probabilities in the model). After the model (denoted by X) has been adjusted using the above procedure, the process must be re- peated until quiescence is reached. In the current sys- tem, quiescence is detected when no parameter of the model changes by more than 0.01. Let A(t) denote the action taken at time t. [Baum et al., 19701 proved that each iteration of this algorithm is guaranteed to im- prove the predictive power of the model, measured by Pr(v(O), . . . . v(m)lA(l), . . . . A(m), X), until quiescence is reached. The algorithm for this portion of the model learning is a variant of the “Balm-Welsh” algorithm for maximum likelihood estimation adapted here to learn Partially Observable Markov Decision Processes. Discovering New Distinctions It is generally not known beforehand how many classes suffice for obtaining the necessary level of predictabil- ity, or what these classes are. The second portion of the algorithm is responsible for detecting when the current model is missing important distinctions and for incor- porating them into the model. The primary challenge in discovering important dis- tinctions is detecting the difference between random chance and underlying hidden influences missing from the current model. This is done in the system by per- forming two or more experiments under slightly differ- ent conditions and comparing the experiences. When the behavior of the system differs by a statistically sig- nificant amount between experiments, it is determined that an underlying influence is missing from the model (the unknown influence is at least partially determined by the experimental conditions), and so a new distinc- tion is introduced. In the current case, this turns out to be equivalent to detecting when the Markov property of the model does not hold. When the model learning algorithm is invoked, a sequential list of action-observation pairs has already been recorded and given to the algorithm as input. This experience is partioned into two groups with the earliest half forming the first group and the latest half forming the second group. Because reinforcement learning was actively changing the agent’s policy while the experience was being gathered, the experimental conditions (determined by the policy) will be slightly different between the two groups. This forms the basis for detecting a missing distinction. For each class i of the model, the expected frequen- cies from each group are tallied. For each action A and each class j, this yields the estimates ltej and 2ttj for the number of expected transitions from i to j with action A for groups 1 and 2 respectively. These two sampled distributions are compared for a statisti- cally significant difference using the Chi-squared test. A similar test is performed for the observation counts IU~(V) and ZU~(V), the expected number of times v is observed while in class j. If either test shows a sta- tistically significant difference in distribution, class i is split into two, causing the total number of classes, n, to increment by 1. This is somewhat reminiscent of the G algorithm [Chapman and Kaelbling, 19911. Whenever a class is split, the complete model learning algorithm is recursively re-invoked. Experimental Results This section reports the results of applying the com- plete system to a simple simulated docking application with incomplete perception, non-deterministic actions, and noisy sensors. The scenario consists of two space stations separated by a small amount of free space with loading docks located on each station. The task is to transport supplies between the two docks. Each time the agent successfully attaches to the least-recently vis- ited station, it receives a reward of +lO. In order to dock, the agent must position itself in front of the sta- tion, with its back to the dock, and backup. When- ever the agent collides with the station by propelling forward into the dock, it receives a penalty of -3. At all other times, it receives zero reinforcement. Three actions are available to the agent: GoForward, Backup, TurnAround. The agent is always facing ex- actly one of the two stations, and TurnAround causes it to face the other. Depending on the current state, the GoForward action either detaches from the load- ing dock, launches into free space, approaches the next station from free space, or collides (with a penalty) into a space station directly ahead. Backup is almost the inverse of GoForward except that it is extremely unreliable. Backup launches from a station with prob- ability 0.3. From space, it approaches a station in re- verse with probability 0.8. And from docking position, it fails to dock 30% of the time. When actions fail, the agent sometimes remains in the same position, but sometimes accidentally gets randomly turned around. The agent’s perception is very limited. From a sta- tion, it sees the station or only empty space depending on which way it is facing. In free space perception is noisy: with probability 0.7 the agent sees the forward station, otherwise it sees nothing but empty space. The two stations appear identical to the agent except that the least-recently visited station displays an “ac- cepting deliveries” sign which is visible to the agent exactly when the station is visible. When docked, only the interior of the dock itself is visible. The +lO reward is also observable for one time unit after receipt. The system began with a randomly generated two state predictive model and zero-initialized Q values ( i.e., V[-, -1 = 0). Model learning was invoked after each m = 1000 actions to improve the model. The complete cycle was repeated 15 times. A discounting rate of y = 0.9 and learning rate of 6 = 0.1 were used for reinforcement learning. To detect missing distinc- tions with the Chi-Squared test, a significance level of cv = 0.05 was used. Throughout the run, the agent executed a random action with probability 0.1, and executed the action with the largest Q the rest of the time. In Figure 2, one dot was plotted corresponding to 186 Learning: Robotic Auto-Estimated Porformana Figure 2: Estimated Performance during Training. the agent’s best estimate for the utility of the cur- rent choice of action at each decision cycle3. From the density of dots, five lines appear to eventually stand out. These correspond to the five states of the world where the agent spends most of its time once the optimal policy is learned. From a loading dock, the agent detaches (with GoForward), launches into free space (GoForward), approaches the next station (GoForward), turns around, and then backs up to at- tach to the dock. From the egocentric viewpoint of the agent, it then appears to be where it had started. By the end of the run, it recognizes these five situations, and the Q value estimate for each is fairly stable, form- ing the five discernible lines on the graph. Although these five are the most frequently visited states, by the end the system actually learns a predictive model with a total of 11 classes. The final learned model was compared to the simu- lator’s reality. In one case, the learned model distin- guishes two different regions of free space, one where the station is visible, the other where it is not, and sets the transition probabilities of launching into each respective region of free space to 0.7 and 0.3. The model is exactly equivalent to the simulator but based upon a different ontology. Along the optimal path, the model is detailed and accurate, although there are two extra classes that are not necessary. Off the op- timal path, all existing (and no spurious) distinctions are identified, but a few transition probabilities are in error (undoubtedly due to the lack of experience with those situations). 3Using the agent’s own estimate of its performance can sometimes be a misleading indication of actual perfor- mance. By comparing a graph of measured cumulative discounted rewards to Figure 2, it was verified that Fig- ure 2 does give a valid indication of actual performance, although Figure 2 does make the convergence rate appear somewhat worse than it actually is. However, Figure 2 pro- vides far more information, both about actual performance and about the internal workings of the system. Additional Issues The system has been run on several additional sim- ple simulated applications, and from this experience, a number of issues have been identified. On a few ap- plications, the system performed poorly, leading to an investigation for the underlying reasons and the identi- fication of the first few issues below. A few additional concerns are also listed. Dealing with all these limita- tions constitutes area for future research. The Exacerbated Exploration Problem: The explo- ration/exploitation tradeoff is a known difficulty with reinforcement learning in general ([Kaelbling, 19901, [Thrun, 19921); however, the problem is amplified tremendously by perceptual incompleteness. The ad- ditional aggravation stems from the fact that the state space structure is not provided to the system, but must instead be discovered. The result is that the agent sometimes cannot tell the difference between un- explored portions of the world and heavily explored portions of the world because until it has discovered the difference, the two areas look the same. This is an inherent problem accompanying incomplete perception and not unique to the current approach. Increasing the frequency of choosing random actions from 0.1 to 0.3 sometimes overcame this problem, but there is reason to believe that efficiently overcoming this problem in P eneral may require the use of an external teacher (e.g., Whitehead, 19911, [Lin, 19911). The Problem of Extended Concealment of Crucial Features: Some domains have the characteristic that some hidden feature or influence is crucial to perfor- mance, but the feature only rarely allows its influ- ence to be perceived. This is perhaps the single most significant limitation to the predictive distinction ap- proach. The problem is that high quality prediction is possible even when the crucial feature is ignored. In other words, the internal state that is useful for making predictions may, in some cases, not include the inter- nal state necessary for selecting actions. This prob- lem arises in the space station docking domain when the “accepting deliveries” sign is not used, leaving the agent the difficult task of discovering the crucial con- cept of “least-recently visited.” Oversplitting: It is common for the current system to learn more classes than are actually necessary. Con- glomerating nearly identical states may be desirable (c.f., [Mahadevan and Connell, 19911). The Utile-Distinction Conjecture: Is it possible to only introduce those class distinctions that impact util- ity? If the color of a block is perceivable but irrelevant to the agent’s task, is it possible for the agent to avoid introducing the color distinction into its model, while at the same time learning distinctions that are utile? I conjecture that this is not possible and that it is nec- essary to recognize a distinction and gather experience after the distinction is identified in order to obtain any information regarding the utility of the distinction, A refutation to this conjecture would be extremely in- C hrisman 187 teresting and would also provide an ideal solution to the input generalization problem ([Chapman and Kael- bling, 19911). Conclusion Perceptual aliasing presents serious troubles for stan- dard reinforcement learning algorithms. Standard al- gorithms may become unstable as the result of percep- tually identical states that require different responses ([Whitehead and Ballard, 19911). The predictive dis- tinction approach uses a predictive model to track por- tions of the world that are not totally observable. It assumes an adequate model cannot be supplied to the system, so the model itself must be learned. The model is fully probabilistic and learning it involves not only learning transition and perception probabilities, but also discovering the important underlying class distinc- tions that exist in the world. Bayesian updating and conditionin f track the world state, and a variation of Q-learning Watkins, 19891 learns a mapping from the internal state of the model to the utility of each pos- sible action. The overall approach is based upon the central idea that internal state useful for prediction may capture the important information for choosing actions missing from perceptually aliased inputs. Acknowledgements I am very grateful to Tom Mitchell for help and guid- ance during the development of this work, and to Tom Mitchell, Reid Simmons, and Sebastian Thrun for reading and making helpful comments on previous drafts. The research was sponsored by NASA under contract number NAGW-1175. The views and conclu- sions contained in this paper are those of the author and should not be interpreted as representing the of- ficial policies, either expresed or implied, of NASA or the U.S. government. References Barto, Andy G.; Bradtke, Steven J.; and Singh, Satin- der P. 1991. Real-time learning of control using asyn- chronous dynamic programming. Technical Report COINS 91-57, Department of Computer Science, Uni- versity of Massachusetts. Baum, Leonard E.; Petrie, Ted; Soules, George; and Weiss, Norman 1970. A maximization technique oc- curring in the statistical analysis of probabilistic func- tions of markov chains. Annals of Mathmatical Statis- tics 41(1):164-171. Chapman, David and Kaelbling, Leslie Pack 1991. In- put generalization in delayed reinforcement learning: An algorithm and performance comparisons. In IJ- CAI. Chrisman, Lonnie; Caruana, Rich; and Carriker, Wayne 1991. Intelligent agent design issues: Inter- nal agent state and incomplete perception. In Proc. AAAI Fall Symposium on Sensory Aspects of Robotic Intelligence. Drescher, Gary L. 1991. Made-Up Minds: A Con- structivist Approach to Artificial Intelligence. MIT Press. Jordan, Michael I. and Rumelhart, David E. 1992. Forward models: Supervised learning with a distal teacher. Cognitive Science. In press. See also MIT Center for Cognitive Science Occasional Paper #40. Kaelbling, Leslie Pack 1990. Learning in Embedded Systems. Ph.D. Dissertation, Stanford University. Teleos TR-90-04. Lin, Long-Ji 1991. Programming robots using rein- forcement learning and teaching. In Proc. Ninth Na- tional Conference on Artificial Intelligence. Lin, Long-Ji 1992. personal communication. Lovejoy, William S. 1991. A survey of algorithmic methods for partially observable markov decision pro- cesses. Annals of Operations Research 28147-66. Mahadevan, Sridhar and Connell, Jonathan 1991. Automatic programming of behavior-based robots us- ing reinforcement learning. In Proc. Ninth National Conference on Artificial Intelligence. Mill&n, Jose de1 R. and Torras, Carme 1991. Learning to avoid obstacles through reinforcement. In Proc. Eighth International Machine Learning Workshop. Monahan, George E. 1982. A survey of partially ob- servable markov decision processes: Theory, models, and algorithms. Management Science 28:1-16. Rabiner, Lawrence R. 1989. A tutorial on hidden markov models and selected applications in speech recognition. Proceedings of the IEEE 77(2). Sutton, Richard S. 1990. Integrated architecture for learning, planning, and reaction based on approxi- mating dynamic programming. In Proc. Seventh In- ternational Conference on Machine Learning. Tan, Ming 1991. Cost-sensitive reinforcement learn- ing for adaptive classification and control. In Proc. Ninth National Conference on Artificial Intelligence. Thrun, Sebastian B. 1992. Efficient exploration in reinforcement learning. Technical Report CS-CMU- 92-102, School of Computer Science, Carnegie Mellon University. Watkins, Chris 1989. Learning from Delayed Rewards. Ph.D. Dissertation, Cambridge University. Whitehead, Steven D. and Ballard, Dana H. 1991. Learning to perceive and act by trial and error. Ma- chine Learning 7~45-83. Whitehead, Steven D. 1991. A complexity analysis of cooperative mechanisms in reinforcement learning. In Proc. Ninth National Conference on Artificial Intelli- gence. Wixson, Lambert E. 1991. Scaling reinforcement learning techniques via modularity. In Proc. Eighth International Machine Learning Workshop. 188 Learning: Robotic | 1992 | 44 |
1,237 | I-hman Information Processing Group Department of Psychology Princeton University Princeton, New Jersey 08544 jjg@phoenix.princeton.edu Abstract This paper will present computer models of three robotic motion planning and learning systems which use a multi-sensory learning strategy for learning and control. In these systems machine vision input is used to plan and execute movements utilizing an algorithmic controller while at the same time neural networks learn the control of those motions using feedback provided by position and velocity sensors in the actuators. A specific advantage of this approach is that, in addition to the system learning a more automatic behavior, it employs a computationally less costly sensory system more tightly coupled from perception to action. There has been considerable discussion in the AI and robotics literature in recent years on the acquisition of planning and control behaviors which directly couple input to output, thereby avoiding unbounded search in planning and high computational costs for control @rooks, 1989; Mitchell, 1990; Handelman et. al., 1990, 1992). The term “reactive behavior” is predominantly used in the planning domain and “reflexive behavior” is similarly used in the control domain for these direct responses. The more general term used in the psychology literature to denote the acquisition of stimulus-response behavior in the sensory- motor as well as other more cognitive domains is “automaticity” (Schneider & Fisk, 1983). We use the term automaticity here because planning and control functions both become automatic in the simulations below. There are numerous examples of robotic systems which have been trained with a single sensory modality, e.g., vision, force or position feedback (Mitchell, 1987; Mel, 1989; Handelman et. al., 1990,1992). In this paper we present simulations of the acquisition of automatic behavior in systems which initially use vision to perform a task and then learn to perform the same task using *This work was supported by a grant from the James S. McDonnell Foundation to the I-Iuman Information Processing Group at Princeton University and a contract from the DARPA Neural Network Program. proprioceptive sensory input. This muth-sensory approach allows the system to switch from a global planning and control algorithm to simple control laws learned in restricted parts of state space. In addition, the automatic behavior utilizes a computationally less costly and more direct sensory input for the execution of the task. Humans possess an ability to use multiple sensory modalities for both learning and control (Smyth, 1984). Typically they initially rely upon visual information for motor control, and then, with practice, switch to the proprioceptive control of motion (Notterman & Weitzman, 1981; Posner et. al., 1976; Fleishman & Schneider, 1985). This ability is particularly useful because vision is so important for monitoring the environment and planning motion. For example, in sports, a novice must devote a great deal of visual attention to the control of his or her limbs and the execution of those tasks necessary for play. Qn the other hand, an expert has learned, through practice, motor programs which rely for their execution predominantly upon kinesthetic input from limbs and muscles -- leaving the visual sense free to attend to other aspects of the game (Fischman & Schneider, 1985). In this paper we present simulations for three examples of hybrid approaches to robotic systems. In the first, visual information is initially used to plan and control the motion of an arm, avoiding an obstacle. Then a neural net is trained to learn a chained response using angle feedback from the joints which generates the same trajectory. In the second task, a robotic arm dribbles a ball while using visual information to sense the position of the ball, arm, and obstacles. As the ball is dribbled, a neural network learns the proper responses for dribbling the ball through kinesthetic joint information. In this case the neural network learns the control law for the arm as it interacts dynamically with an external object. In the final task, an anthropomorphic planar manipulator uses vision to learn proprioceptive compensations to calibration errors in joint angle, velocity, and length perception for a repetitive reaching task. Gelfand, et al. 189 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Visual Information Figure 1. A schematic diagram of a hybrid learning and control system. This system plans and executes the motion of an arm using visual input and trams the arm to perform the task using feedback from position sensors in the actuators. A Hybrid Learning and Control System A schematic diagram of the system that was used in the fist two simulations reported here is shown in Fig. 1. A robot manipulator is shown performing a task with a machine vision system initially determining the appropriate trajectory of the manipulator based on relevant information about the work space. This visual information is fed to the modules marked kinematic control and visual control. The visual control module utilizes visual feedback of the position of the arm to execute movement along the planned path. During the execution of this visually guided motion, sensors provide information about the arm’s position to a CMAC neural network. (Albus, 1975) This network is trained to provide the proper control outputs to cause the arm to move in the same path as under visual system control. The process described above is supervised by an execution monitor responsible for monitoring the perfomxmce of the kinesthetic control system relative to the visually controlled system and for switching control between the two systems. The execution monitor also monitors the gross performance of the system. If problems are encountered such as an unexpected collision, control may be switched back to the visual system, which allows for more comprehensive diagnostic and planning activity. Learning Control of Arm Motion in the Presence of an Obstacle In this demonstration, we use a visual system to locate an object in two dimensional space and to control the motion of the two link manipulator. The CMAC neural network, introduced by Albus, is particularly well suited as a function approximator for the performance of this control task (Albus, 1975; Lane et. al., 1992). The CMAC was trained to control the position of the manipulator as a function of joint angle. During the training passes, the RMS distance from the visually controlled manipulator position to the position suggested by the CMAC is monitored and determines when the CMAC has adequately learned the desired trajectory. When the CMAC is sufficiently trained, the execution monitor then switches from the visual controller to the kinesthetic controller. Visual Control Trial Number Trial Number Figure 2a-2b. Diagram of a robotic arm under visual control training a CMAC neural network to execute the same trajectory using joint angle feedback. The graph at the bottom of each figure depicts the RMS difference between the visual and CMAC control as discussed in the text. In Fig. 2b control of the arm has been transferred to the CMAC. Referring to Fig. 2, we see a two link manipulator constrained to a horizontal plane. The arrangement of the manipulator, the object, and the visual system are shown. For the sake of this demonstration we used a simple binocular visual system which locates the object in space using the angles from the object to the sensors. The path was calculated by first determining a point of closest approach to the obstacle based on the size of the end effector. This point and the given initial and final end effector positions were used to compute a spline function to represent the desired path. The visual system monitors the position of the end effector as the motion is controlled by torques calculated by the inverse dynamics of the arm. As arm moves along the path, the CMAC is given as input, the current joint angles and joint velocities, and the desired joint angles at the end of the segment. The CMAC is trained to output the required torques at each of the two joints to produce the desired end effector trajectory. The training consists of comparing the torque output of the inverse dynamic controller with that of the CMAC and 190 Learning: Robotic training the weights by the standard CMAC learning algorithm (Albus, 1975; Lane et. al., 1992). en the error reaches a predetermined threshold, control is switched to the CMAC. The results of this demonstration are shown in Figs. 2a-2b. These figures depict the behavior of the system after the indicated number of runs. Each training run consists of a complete sweep of the trajectory from the initial position to the final position. In each figure, we use a thin line to indicate the actual trajectory of the end effector as controlled by the visual input controller. The heavy lines are the motion that would result from commands from the CMAC controller. At the bottom of each figure, we show the RMS differences of the joint angles plotted against the number of training runs. In Fig. 2a, the dotted lines from the robot’s binocular visual sensors to the end effector indicate that the system is under visual control. We can see that the output of the CMAC begins to approximate the desired path. The RMS difference becomes smaller and the trajectories depicted by the light and heavy lines become coincident. In Fig. 2b, we show the final performance of the system after control has been transferred to the CMAC. Figure 3a-3d. Diagrams of the simulated basketball dribbler described in text. In Figs. 3a-3b the vision system is responsible for both the control of the arm and for sensing of the obstacle position. In Figs. 3c-3d the arm is under CMAC neural network control using joint angle feedback and the sensing of the obstacle is under visual control. In this demonstration the arms of a simulated robot are depicted dribbling a ball using visual feedback while a CMAC is trained with kinesthetic feedback as its input. This dribbler is modeled in two dimensions and is shown in Figs. 3a-3d. The task involves dribbling a ball in the presence of an obstacle moving at a constant velocity from left to right. Initially, the planner uses the visual location of the ball to determine where and when to catch the ball and push it back towards the floor so as to avoid the obstacle. This is accomplished by visually observing the position and velocity of the ball, the position of the obstacle, and the position of the end effector. While this visually controlled dribbling is going on, the CMAC is trained with kinesthetic feedback from the joint angles of the manipulator. 0 50 100 Number of Dribbles 150 Figure 4. A graph of the relative RMS positional difference between the visually controlled end effector position and the suggested CMAC end effector position during the training of the dribbler. In this example, control of the arm was switched to the CMAC after the 125th dribble. During dribbling, the momentum of the ball interacts with the impedance of the arm. When the ball strikes the hand, its momentum will cause the arm to fold upward, absorbing the impact. The final position of the arm can therefore be used to compute the velocity vector of the ball as it impacted the hand. The inputs to the CMAC are the position at which the ball makes contact with the hand, the total consequent deflection, and the obstacle’s current position. The CMAC is then trained to output the position at which the end effector should stop in its downward motion in order to release the ball to continue towards the floor. For the sake of simplicity in this model, the manipulator arm moves in a straight path from the point of maximum deflection to the point of release. When the output of the CMAC is sufficiently close to the visually controlled output, the program switches control Gelfand, et al. 191 from the visual system to the CMAC. The petiormance of correction. When this contribution becomes sufficiently the model is shown in Fig. 4. small, the visual system may be dedicated to another task without a significant change -m performance. Learning to Compensate for Perceptual Calibration Errors In this demonstration, we use a visual system to learn compensations for calibration errors in the proprioception of a six-link planar manipulator. Feedback error learning was used to train a CMAC to dynamically compensate for misperception of the vector distance from the endpoint of the manipulator to the desired target (Miyamoto, 1988). Feedback error learning occurs when a neural net is trained using the output of a feedback controller operating in parallel with the neural net. The output of Berkinblit’s kinematic algorithm was filtered to generate desired joint angular positions, velocities and accelerations, which in turn were implemented by a hybrid dynamic controller composed of a PD controller and an adaptive Splinet trained using feedback error learning (Berkinblit, 1986, Lane et. al., 199 1, 1990). This system is described in full detail in (Gelfand, et. al., 1992). Figure 5. A diagram of the movement of REACHER as it moves from the original to the final posture. The heavy lines indicate the starting posture of the manipulator. The curved line indicates the path generated by the Berkinblit algorithm for the manipulator. Fig. 5 shows the six link planar manipulator in the initial position with the end effector trajectory to the target. In this experiment we perturbed the perception of joint angles and velocities randomly with a maximum amplitude of f.05 rad. and f.02 rad./s respectively. In addition, we perturbed the lengths of the links by up to flcm. For comparison, the robot stands approximately lm high. We began with a system with no sensor errors and then perturbed the calibrations and joint lengths twice, once after 5 sweeps and once after 30 sweeps. Fig. 6 displays the contribution of the vision system to the endpoint 80% 0 10 20 30 40 Number of Sweeps 50 Figure 6. Percent contribution of vision to endpoint correction in response to two perturbations in the calibration of proprioceptive sensors and link lengths. Discussion The results described in this paper illustrate a powerful behavioral strategy used by intelligent biological systems to cope with a myriad of sensory input and control responsibilities. The functionality of present day machine vision systems is near the limit of their ability to contribute to the complex analysis of the robotic environment. Strategies which offload sensory responsibilities to other sensor systems make it possible to utilize vision systems for those tasks for which they are more qualified. Finally, we should be aware that we learn multiple cues for the execution of learned tasks, some of which may not be apparent when we start. These cues include information from our auditory system, somatosensory system and other senses in addition to sight and kinesthesis. Intelligent robotic control systems of the kind described here should really measure the correlations among sensory inputs and pick those which provide the maximum sensitivity for the control of learned actions. As Mitchell points out, this is becoming “increasingly perceptive.” (Mitchell, 1990; Tan, 1990.) Acknowledgements This work was largely inspired by discussions with David Touretzky and Joseph Notterman. We also acknowledge helpful discussions with Lorraine Crown. 192 Learning: Robotic References Albus, J. 1975. A New Approach to Manipulator Control: ode1 Articulation Controller (C C). J. Byn. Syst. Meas. and Cont. 97~270-277. Berkinblit, M.V.; Gel’fand, I.M.; and Feldman, A.G. 1986. Model of the Control of the Movements of a Multijoint Limb. Neural Networks 3 l(1): 142-153. Fischman, M. G. and Schneider, T. 1985. Skill Level, Vision, and Proprioception in Simple One Hand Catching. J. Mot. Behavior 17~219-229. Fleishman, E. A. and Rich, S. 1963. Role of Kinesthetic and Spatial-Visual Abilities in Perceptual- J. Exptl. Psychology 66:6-l 1. Gelfand J.J.; Flax M.G.; Endres R.E.; Lane S.H.; and Handelman D.A. 1992. Multiple Sensory Modalities for Learning and Control, in Venkataraman, S.T. and Gulati, S., eds., Perceptual Robotics, Springer-Verlag, New York. Forthcoming. Handelman, D.A.; Lane, S.H.; and Gelfand, J.J. 1990. Integrating Neural Networks and Knowledge-Based Systems for Intelligent Robotic Control. IEEE Control Systems Magazine 10(3):77-87. Handelman, D.A.; Lane, S.H.; and Gelfand, J.J. 1992. Robotic Skill Acquisition Based on Biological Principles. In Kandel, A. and Langholz, G., e&., Hybrid Architectures for Intelligent Systems, CRC Press, Boca Raton, Fla., 301-328. Lane, S.; Handelman, D.; and Gelfand J. 1992. Theory and Development of Higher Order CMAC Neural Networks. IEEE Control Systems Magazine 12(4). Forthcoming. Lane, S.H.; Flax, M.G.; Handelman, D.A.; and Gelfand, J.J. 1991. Multi-Layer Perceptrons with B-Spline Receptive Field Functions. In Advances in Neural Information Processing Systems III. San Mateo, Ca.: Morgan Kaufmann, 684-692 Lane, S.H.; IIandelman, D.A.; and Gelfand, J.J. 1990. Can Robots Learn Like People Do? In Rogers, S., ed, Applications of Artificial Neural Networks, kx. of the SPIE, 1294:296-309. Mel, B. 1989. Further Explorations in Visually-Guided Reaching: Making Murphy Smarter. In D. Tourtetzky, ed., Advances in Neural Information Processing Systems I. San Mateo, Ca.: Morgan Kaufmann 348-355. Mitchell, T. 1990. Becoming Increasingly Reactive. In Proceedings of AAAI-90, 1051-1058. Boston, August, 1990, American Association for Artificial Intelligence, Menlo Park, Ca.. Miyamoto, H.; Kowato, M.; Setoyama, T.; and Suzuki, R. 1988. Feedback Error Learning Neural Network for Trajectory Control of a Robotic Manipulator. NeuraZ Networks 1~251-265. Notterman, J. M. and Weitzman, D. 0.1981. Organization and Learning of Visual-Motor Information During Different Orders of Limb Movement: Step, Velocity, Acceleration. J. Exp. Psych.: Human Perception and Performance 7~9 16-927. Posner, M. I.; Nissen, M.J.; and Klein, R.M. 1976. Visual Dominance: an Information Processing Account of its origin. Psychology Review 83:157-171. Schneider, W. and Fisk, A. 1983. Attention Theory and Mechanisms for Skilled Performance. In Magill, R., ed., Memory and The Control of Action, North-Holland Publishing, Amsterdam, 119-143. Smyth, M. M. 1984. Perception and Action. In Smyth, M. M., and Wing, A. M., eds., The Psychology of Human Movement, Academic Press, New York, 119-15 1. Tan, M. 1990. A Cost-Sensitive Learning System for Sensing and Grasping Objects. Proc. IEEE Conf. on Robotics and Automation, 858-863. Los Alamitos: IEEE. Miller, W. T. 1987. Sensor Based Control of Robotic Manipulators Using a Generalized Learning Algorithm IEEE J. Rob. and Automat. 3:157-165. Gelfand, et al. 193 | 1992 | 45 |
1,238 | Automatic Programming of obots using John R. Koza Stanford University Computer Science Department Stanford, CA 94305 USA E-MAIL: Koza@Sunbum.Stanford.Edu PHONE: 415-941-0336 FAX: 415-941-9430 Abstract The goal in automatic programming is to get a computer to perform a task by telling it what needs to be done, rather than by explicitly programming it. This paper considers the task of automatically generating a computer program to enable an autonomous mobile robot to perform the task of moving a box from the middle of an irregular shaped room to the wall. We compare the ability of the recently developed genetic programming paradigm to produce such a program to the reported ability of reinforcement learning techniques, such as Q learning, to produce such a program in the style of the subsumption architecture. The computational requirements of reinforcement learning necessitates considerable human knowledge and intervention, whereas genetic programming comes much closer to achieving the goal of getting the computer to perform the task without explicitly programming it. The solution produced by genetic programming emerges as a result of Darwinian natural selection and genetic crossover (sexual recombination) in a population of computer programs. The process is driven by a fitness measure which communicates the nature of the task to the computer and its learning paradigm. Introduction and Overview In the 195Os, Arthur Samuel identified the goal of getting a computer to perform a task without being explicitly programmed as one of the central goals in the fields of computer science and artificial intelligence. Such automatic programming of a computer involves merely telling the computer what is to be done, rather than explicitly telling it, step-by-step, how to perform the desired task. In an AAAI-91 paper entitled “Automatic Programming of Behavior-Based Robots using Reinforcement Learning” Mahadevan and Connell (1991) reported on using reinforcement learning techniques, such as Q learning (Watkins 1989), in producing a program to control an autonomous mobile robot in the style of the subsumption architecture (Brooks 1986, Connell 1990, Mataric 1990). In particular, the program produced by reinforcement learning techniques enabled an autonomous mobile robot to perform the task of moving a box from the middle of a room to the wall. In this paper, we will show that the James P. Rice Stanford University Knowledge Systems Laboratory 70 1 Welt h Road Palo Alto, CA 94304 USA Rice@Sumex-Aim.Stanford.Edu 415-723-8405 onerous computational requirements imposed by reinforcement learning techniques necessitated that a considerable amount of human knowledge be supplied in order to achieve the reported “automatic programming” of the box moving task. In this paper, we present an alternative method for automatically generating a computer program to perform the box moving task using the recently developed genetic programming paradigm. In genetic programming, populations of computer programs are genetically bred in order to solve the problem. The solution produced by genetic programming emerges as a result of Darwinian natural selection and genetic crossover (sexual recombination) in a population of computer programs. The process is driven by a fitness measure which communicates the nature of the task to the computer and its learning paradigm. We demonstrate that genetic programming comes much closer than reinforcement learning techniques to achieving the goal of getting the computer to perform the task without explicitly programming it. Background on Genetic Algorithms John Holland’s pioneering 1975 Adaptation in Natural and Artificial Systems described how the evolutionary process in nature can be applied to artificial systems using the genetic algorithm operating on fixed length character strings (Holland 1975). Holland demonstrated that a population of fixed length character strings (each representing a proposed solution to a problem) can be genetically bred using the Darwinian operation of fitness proportionate reproduction and the genetic operation of recombination. The recombination operation combines parts of two chromosome-like fixed length character strings, each selected on the basis of their fitness, to produce new offspring strings. Holland established, among other things, that the genetic algorithm is a mathematically near optimal approach to adaptation in that it maximizes expected overall average payoff when the adaptive process is viewed as a multi-armed slot machine problem requiring an optimal allocation of future trials given currently available information. Recent work in genetic algorithms can be surveyed in Goldberg 1989 and Davis (1987, 1991). 194 Learning: Robotic From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. ackground on Genetic Programming For many problems, the most natural representation for solutions are computer programs. The size, shape, and contents of the computer program to solve the problem is generally not known in advance. The computer program that solves a given problem is typically a hierarchical composition of various terminals and primitive function appropriate to the problem domain. In robotics problems, the computer program that solves a given problem typically takes the sensor inputs or state variables of the system as its input and produces an external action as its output. It is unnatural and difficult to represent program hierarchies of unknown (and possibly dynamically varying) size and shape with the fixed length character strings generally used in the conventional genetic algorithm. In genetic programming, one recasts the search for the solution to the problem at hand as a search of the space of all possible compositions of functions and terminals (i.e. computer programs) that can be recursively composed from the available functions and terminals. Depending on the particular problem at hand, the set of functions used may include arithmetic operations, primitive robotic actions, conditional branching operations, mathematical functions, or domain-specific functions. For robotic problems, the primitive functions are typically the external actions which the robot can execute; the terminals are typically the sensor inputs or state variables of the system. The symbolic expressions (S-expressions) of the LISP programming language are an especially convenient way to create and manipulate the compositions of functions and terminals described above. These S-expressions in LISP correspond directly to the parse tree that is internally created by most compilers. Genetic programming, like the conventional genetic algorithm, is a domain independent method. It proceeds by genetically breeding populations of computer programs to solve problems by executing the following three steps: (1) Generate an initial population of random compositions of the functions and terminals of the problem (computer programs). (2) Iteratively perform the following sub-steps until the termination criterion has been satisfied: (a) Execute each program in the population and assign it a fitness value according to how well it solves the problem. (b) Create a new population of computer programs by applying the following two primary operations. The operations are applied to computer program(s) in the population chosen with a probability based on fitness. (i) Reproduction: Copy existing computer programs to the new population. (ii) Crossover: Create new computer programs by genetically recombining randomly chosen parts of two existing programs. (3) The single best computer program in the population at the time of termination is designated as the result of the run of genetic programming. This result may be a solution (or approximate solution) to the problem. The basic genetic operations for genetic programming are fitness proportionate reproduction and crossover (recombination). The reproduction operation copies individuals in the genetic population into the next generation of the population in proportion to their fitness in grappling with the problem environment. This operation is the basic engine of Darwinian survival and reproduction of the fittest. The crossover operation is a sexual operation that operates on two parental LISP S-expressions and produces two offspring S-expressions using parts of each parent. The crossover operation creates new offspring S- expressions by exchanging sub-trees (i.e. sub-lists) between the two parents. Because entire sub-trees are swapped, this crossover operation always produces syntactically and semantically valid LISP S-expressions as offspring regardless of the crossover points. For example, consider the two parental S-expressions: (OR (NOT Dl) (AND DO Dl)) (OR (OR Dl (NOT DO)) (AND (NOT DO) (NOT Dl)) Figure 1 graphically depicts these two S-expressions as rooted, point-labeled trees with ordered branches. The numbers on the tree are for reference only. Assume that the points of both trees are numbered in a depth-first way starting at the left. Suppose that point 2 (out of 6 points of the first parent) is randomly selected as the crossover point for the first parent and that point 6 (out of 10 points of the second parent) is randomly selected as the crossover point of the second parent. The crossover points in the trees above are therefore the NOT in the first parent and the AND in the second parent. Figure I Two parental computer programs shown as trees with ordered branches. Internal points of the tree correspond to functions (i.e. operations) and external points correspond to terminals (i.e. input data). Figure 2 shows the two crossover fragments are two sub-trees. These two crossover fragments correspond to the bold sub-expressions (sub-lists) in the two parental Koza and Rice 195 LISP S-expressions two offspring. shown above. Figure 3 shows the Figure 2 The two crossover fragments. Figure 3 Offspring resulting from crossover. When-the cr&sbver operation is applied to two individual parental computer programs chosen from the population in proportion to fitness, it effectively directs the future population towards parts of the search space containing computer programs that bear some resemblance to their parents. If the parents exhibited relatively high fitness because of certain structural features, their offspring may exhibit even higher fitness after a recombination of features. Although one might think that computer programs are so brittle and epistatic that they could only be genetically bred in a few especially congenial problem domains, we have shows that computer programs can be genetically bred to solve a surprising variety of problems, including 0 discovering inverse kinematic equations (e.g., to move a robot arm to designated target points) [Koza 1992a], 0 planning (e.g., navigating an artificial ant along a trail), a optimal control (e.g., balancing a broom and backing up a truck) [Koza and Keane 1990, Koza 1992d], * Boolean function learning [Koza 1989,1992c], and 0 classification and pattern recognition (e.g., two intertwined spirals) [Koza 1992e]. A videotape-visualization of the application of genetic programming to planning, emergent behavior, empirical discovery, inverse kinematics, and game playing can be found in the Artificial Life II Video Proceedings [Koza and Rice 19911. Box Moving Robot In the box moving problem, an autonomous mobile robot must find a box i&ated in the middle of an irregularly shaped room and move it to the edge of the room within a reasonable amount of time. The robot is able to move forward, turn right, and turn left. After the robots finds the box, it can move the box by pushing against it. However, this sub-task may prove difficult because if the robot applies force not coaxial with the center of gravity of the box, the box will start to rotate. The robot will then lose contact with the box and will probably then fail to push the box to the wall in a reasonable amount of time. The robot is considered successful if any part of the box touches any wall within the allotted amount of time. The robot has 12 sonar sensors which report the distance to the the nearest object (whether wall or box) as a floating point number in feet. The twelve sonar sensors (each covering 30”) together provide 360” coverage around the robot. The robot is capable of executing three primitive motor functions, namely, moving forward by a constant distance, turning right by 30°, and turning left by 30”. The three primitive motor functions MF, TR, and TL each take one time step (i.e., 1.0 seconds) to execute. All sonar distances are dynamically recomputed after each execution of a move or turn. The function TR (Turn Right) turns the robot 30” to the right (i.e., clockwise). The function TL (Turn Left) turns the robot 30” to the left (i.e., counter- clockwise). The function MF (Move Forward) causes the robot to move 1.0 feet forward in the direction it is currently facing in one time step. If the robot applies its force orthogonally to the midpoint of an edge of the box, it will move the box about 0.33 feet per time step. The robot has a BUMP and a STUCK detector. We used a 2.5 foot wide box. The north (top) wall and west (left) wall of the irregularly shaped room are each 27.6 feet long. The sonar sensors, the two binary sensors, and the three primitive motor functions are not labeled, ordered, or interpreted in any way. The robot does not know a priori what the sensors mean nor what the primitive motor functions do. Note that the robot does not operate on a cellular grid; its state variables assume a continuum of different values. There are five major steps in preparing to use genetic programming, namely, determining (1) the set of terminals, (2) the set of functions, (3) the fitness measure, (4) the parameters and variables for controlling the run, and (5) the criteria for designating a result and for terminating a run. The first major step in preparing to use genetic programming is to identify the set of terminals. We include the 12 sonar sensors and the three primitive motor functions (each taking no arguments) in the terminal set. Thus, the terminal set T for this problem is T = {s 00, s01,502,503,..., Sll,SS, (MF), (TR), (TL) }. The second major step in preparing to use genetic programming is to identify a sufficient set of primitive functions for the problem. The function set F consists of F=(IFBMP,IFSTK,IFLTE,PROGN2). The functions IFBMP and IFSTK are based on the BUMP detector and the STUCK detector defined by Mahadevan and Connell. Both of these functions take two arguments and evaluate their first argument if the detector is on and otherwise evaluates their second argument. 196 Learning: Robotic The IFLTE (If-Less-Than-or-Equal) function is a four- argument comparative branching operator that executes its third argument if its first argument is less than its second (i.e., then) argument and, otherwise, executes the fourth (i.e., else) argument. The operator IFLTE is implemented as a macro in LISP so that only either the third or fourth argument is evaluated depending on the outcome of the test involving the first and second argument. Since the terminals in this problem take on floating point values, this function is used to compare values of the terminals. IFLTE allows alternative actions to be executed based on comparisons of observation from the robot’s environment. IFLTE allows, among other things, a particular action to be executed if the robot’s environment is applicable and allows one action to suppress another. It also allows for the computation of the minimum of a subset of two or more sensors. IFBMP and IFSTK are similarly defined as macros The connective function PROGN~ taking two arguments evaluates both of its arguments, in sequence, and returns the value of its second argument. Although the main functionality of the moving and turning functions lies in their side effects on the state of the robot, it is necessary, in order to have closure of the function set and terminal set, that these functions return some numerical value. For Version 1 only, we decided that each of the moving and turning functions would return the minimum of the two distances reported by the two sensors that look forward. Also, for Version 1 only, we added one derived value, namely the terminal ss (Shortest Sonar) which is the minimum of the 12 sonar distances so, Sl, . . . , s 11, in the terminal set T. The third major step in preparing to use genetic programming is the identification of the fitness function for evaluating how good a given computer program is at solving the problem at hand. A human programmer, of course, I program. es human intelligence to write a computer ntelligence is the guiding force that creates the Box start Robot End ) 1 I I Figure 5 Typical random robot trajectory from generation 0. program. In contrast, genetic programming is guided by the pressure exerted by the fitness measure and natural selection. The fitness of an individual S-expression is computed using fitness cases in which the robot starts at various different positions in the room. The fitness measure for this problem is the sum of the distances, taken over four fitness cases, between the wall and the point on the box that is closest to the nearest wall at the time of termination of the fitness case. A fitness case terminates upon execution of 350 time steps or when any part of the box touches a wall. If, for example, the box remains at its starting position for all four fitness cases, the fitness is 26.5 feet. If, for all four fitness cases, the box ends up touching the wall prior to timing out for all four fitness cases, the raw fitness is zero (and minimal). The fourth major step in preparing to use genetic programming is selecting the values of certain parameters. The major parameters for controlling a run of genetic programming is the population size and the number of generations to be run. The population size is 500 here. A maximum of 51 generations (i.e. an initial random generation 0 plus 50 additional generations) is established for a run. Our choice of population size reflected an estimate on our part as to the likely complexity of the solution to this problem; however, we have used a population of 500 on about half of the numerous other problems on which we have applied genetic programming (Koza 1992a, 1992b, 1992~). In addition, each run is controlled by a number of minor parameters. The values of these minor parameters were chosen in the same way as described in the above references and were not chosen especially for this problem. Finally, the fifth major step in preparing to use genetic programming is the selection of the criteria for terminating a run and accepting a result. We will terminate a given run when either (i) genetic programming produces a individual for generation 0. Moza ancl Rice 197 computer program which scores a fitness of zero, or (ii) 51 generations have been run. The best-so-far individual obtained in any generation will be designated as the result of the run. Learning, in general, requires some experimentation in order to obtain the information needed by the learning algorithm to find the solution to the problem. Since learning here would require that the robot perform the overall task a certain large number of times, we planned to simulate the activities of the robot, rather than use a physical robot. Version I. Figure 5 shows the irregular room, the starting position of the box, and the starting position of the robot for the particular fitness case in which the robot starts in the southeast part of the room. The raw fitness of a majority of the individual S-expressions from generation 0 is 26.5 i start I il kgure 7 Trajectory of the best-of-run individual rl - a Figure 9 Trajectory of the best-of-run individua with the robot starting in the northeast. 198 Learning: Robotic (i.e., the sum, over the four fitness cases, of the distances to the nearest wall) since they cause the robot to stand still, to wander around aimlessly without ever finding the box, or, in the case of the individual program shown in the figure, to move toward the box without reaching it. Even in generation 0, some individuals are better than others. Figure 6 shows the trajectory of the best-of- generation individual from generation 0 from one run. This individual containing 213 points finds the box and moves it a short distance for one of the four fitness cases, thereby scoring a raw fitness of 24.5. The Darwinian operation of fitness proportionate reproduction and genetic crossover (sexual recombination) is now applied to the population, and a new generation of 500 S-expressions is produced. Fitness progressively improved between generations 1 and 6. In generation 7, the best-of-generation individual succeeded in moving the box to the wall for one of the ‘igure 8 Trajectory of the best-of-run individua ‘igure 10 Trajectory of the best-of-run individa with the robot starting in the southwest. four fitness cases (i.e., it scored one hit). Its fitness was 21.52 and it had 59 points (i.e. functions and terminals) in its program tree. By generation 22, the fitness of the best-of-generation individual improved to 17.55. Curiously, this individual, unlike many earlier individuals, did not succeed in actually moving the box to a wall for any of the fitness cases. By generation 35, the best-of-generation individual had 259 points and a fitness of 10.77. By generation 45 of the run, the best-of-generation individual computer program was successful, for all four fitness cases, in finding the box and pushing it to the wall within the available amount of time. Its fitness was zero. This best-of-run individual had 305 points. Note that we did not pre-specify the size and shape of the solution to the problem. As we proceeded from generation to generation, the size and shape of the best-of-generation individuals changed. The number of points in the best-of- generation individual was 213 in generation 0, 59 in generation 7, 259 in generation 35, and 305 in generation 45. The structure of the S-expression emerged as a result of the selective pressure exerted by the fitness measure. Figure 7 shows the trajectory of the robot and the box for the 305-point best-of-run individual from generation 45 for the fitness case where the robot starts in the southeast part of the room. For this fitness case, the robot moves more or less directly toward the box and then pushes the box almost flush to the wall. Figure 8 shows the trajectory of the robot and the box for the fitness case where the robot starts in the northwest part of the room. Note that the robot clips the southwest corner of the box and thereby causes it to rotate in a counter clockwise direction until the box is moving 2000 Generation 0 3 3 g 1000 2 !a n 0 1 2 Hits 4 . Generatron 15 0 1 2 Hits 4 Generation 2Q 0 1 2 Hits 4 Figure 31 Hits histogram for generations 0,15, and 20 for Version 2. almost north and the robot is at the midpoint of the south edge of the box. Figure 9 shows the trajectory of the robot and the box for the fitness case where the robot starts in the northeast part of the room. For this fitness case, the robot’s trajectory to reach the box is somewhat inefficient. However, once the robot reaches the box, the robot pushes the box more of less directly toward the west wall. Figure 10 shows the trajectory of the robot and the box for the fitness case where the robot starts in the southwest part of the room. Version 2 In the foregoing discussion of the box moving problem, the solution was facilitated by the presence of the sensor ss in the terminal set and the fact that the functions MF, T L, and T R returned a numerical value equal to the minimum of several designated sensors. This is in fact the way we solved it the first time. This problem can, however, also be solved without the terminal ss being in the terminal set and with the three functions each returning a constant value of zero. We call these three new functions MFO, TLO, and TRO. The new function set is F0 = (MF~,TR~,TLO,IFLTE,PROGN~). We raised the population size from 500 to 2,000 in the belief that version 2 of this problem would be much more difficult to solve. In our first (and only) run of Version 2 of this problem, an lOO%-correct S-expression containing 207 points with a fitness of 0.0 emerged on generation 20: (IFSTK (IFLTE (IFBMP (IFSTK (PROGN2 SO2 SO9) (IFSTK Slo 507)) (IFBMP (IFSTK (IFLTE (MFO) (TRO) SO5 SO9) (IFBMP SO9 508)) (IFSTK SO7 Sll))) (IFBMP (IFBMP (PROGN2 SO7 (TLO)) (PROGN2 (TLO) 503)) (IFBMP (PROGN2 (TLO) SO3) (IFLTE SO5 (TRO) (MFO) SOO))) (IFLTE (IFBMP SO4 SOO) (PROGN2 (IFLTE SO8 SO6 SO7 Sll) (IFLTE SO7 SO9 S10 502)) (IFBMP (IFLTE (TLO) SO8 SO7 S02) (IFLTE S10 SO0 (MFO) SO8)) (IFBMP (PROGN2 SO2 So9) (IFBMP SO8 S02))) (IFSTK (PROGN2 (PROGN2 SO4 S06) (IFBMP (MFO) SO3)) (PROGN2 (IFSTK SO5 (MFO)) (IFBMP (IFLTE (TRO) SO8 (IFBMP SO7 S06) 502) (IFLTE S10 (IFBMP SlO 508) (MFO) S08))))) (IFLTE (PROGN2 SO4 S06) (PROGN2 (IFSTK (IFBMP (MFO) SO9) (IFLTE SlO SO3 SO3 SO6)) (IFSTK (IFSTK SO5 Sol) (IFBMP (MFO) SO7))) (PROGN2 (IFLTE (IFSTK SO1 (TRO)) (PROGN2 SO6 (MFO)) (IFLTE SO5 SO0 (MFO) 508) (PROGN2 Sll SO9)) (IFBMP (MFO) (IFSTK SO5 (IFBMP (PROGN2 (IFSTK (PROGN2 SO7 SO4) (IFLTE SO0 SO7 SO6 S07)) (PROGN2 SO4 S06)) (IFSTK (IFSTK (IFBMP SO0 (PROGN2 SO6 SlO)) (IFSTK (MFO) SlO)) (IFBMP (PROGN2 SO8 SO2) (IFSTK SO9 SO9))))))) (IFLTE (IFBMP (PROGN2 Sll SO9) (IFBMP SO8 Sll)) (PROGN2 (PROGN2 SO6 SO3) (IFBMP (IFBMP SO8 S02) (MFO))) (IFSTK (IFLTE (MFO) (TRO) SO5 SO9) (IFBMP (PROGN2 (TLO) 502) SO8)) (IFSTK (PROGN2 SO2 503) (PROGN2 SO1 504))))) Figure 11 shows the hits histogram for generations 0, 15, and 20. Note the left-to-right undulating movement of the center of mass of the histogram and the high point of Koza and Rice 199 the histogram. This “slinky” movement reflects the improvement of the population as a whole. We have also employed genetic programming to evolve a computer program to control a wall following robot using the subsumption architecture (Koza 1992b) based on impressive work successfully done by Mataric (1990) in programming an autonomous mobile robot called TOTO. Comparison with Reinforcement Learning We now analyze the amount of preparation involved in what Mahadevan and Connell describe as “automatic programming” of an autonomous mobile robot to do box moving using reinforcement learning techniques, such as the Q learning technique developed by Watkins (1989). Reinforcement learning techniques, in general, require that a discounted estimate of the expected future payoffs be calculated for each state. Q learning, in particular, requires that an expected payoff be calculated for each combination of state and action. These expected payoffs then guide the choices that are to be made by the system. Any calculation of expected payoff requires a statistically significant number of trials. Thus, reinforcement learning requires a large number of trials to be made over a large number of combinations of possibilities. Before any reinforcement learning and “automatic programming” can take place, Mahadevan and Connell make the following 13 decisions: First, Mahadevan and Connell began by deciding that the solution to this problem in the subsumption architecture requires precisely three task-achieving behaviors. Second, they decided that the three task-achieving behaviors are finding the box, pushing the box across the room, and recovering from stalls where the robot has wedged itself or the box into a comer. Third, they decided that the behavior of finding the box has the lowest priority, that the behavior of pushing the box across the room is of intermediate importance, and that the unwedging behavior has highest priority. That is, they decide upon the conflict-resolution procedure. Fourth, they decided on the applicability predicate of each of the three task-achieving behaviors. Fifth, they decided upon an unequal concentration of the sonar sensors around the periphery of the robot. In particular, they decided that half of the sensors will look forward, and, after a gap in sonar coverage, an additional quarter will look to the left and the remaining quarter will look to the right. They decided that none of the sonar sensors will look back. Sixth, they decided to preprocess the real-valued distance information reported by the sonar sensors in a highly nonlinear problem-specific way. In particular, they condensed the real-valued distance information from each of the eight sensors into only two bits per sensor. The first bit associated with a given sensor (called the "NEAR" bit) is on if any object appears within 9 - 18 inches. The second bit (called the "FAR" bit) is on if any object appears within 18 - 30 inches. The sonar is an echo sonar that independently and simultaneously reports on both the 9 - 18 inch region and the 18 - 30 region. Thus, it is possible for both bits to be on at once. Note that the sizes of the two regions are unequal and that inputs in the range of less than 9 inches and greater than 30 inches are ignored. This massive state reduction and nonlinear preprocessing are apparently necessary because reinforcement learning requires calculation of a large number of trials for a large number of state-action combinations. In any event, eight real-valued variables are mapped into 16 bits in a highly nonlinear and problem- specific way. This reduces the input space from 12 floating-point values and two binary values to a relatively modest 2’* = 262,144 possible states. An indirect effect of ignoring inputs in the range of less than 9 inches and greater than 30 inches is that the robot must resort to blind random search if it is started from a point that is not within between 9 and 30 inches a box (i.e., the vast majority of potential starting points in the room). Seventh, as a result of having destroyed the information contained in the eight real-valued sonar sensor inputs by condensing it into only 16 bits, they now decided to explicitly create a particular problem-specific matched filter to restore the robot’s ability to move in the direction of an object. The filter senses (i) if the robot has just moved forward, and (ii) if any of four particular sonar sensors were off on the previous time step but any of these sensors are now on. The real-valued values reported by the sonar sensors contained sufficient information to locate the box. This especially tailored temporal filter is required only because of the earlier decision to condense the information contained in the eight real-valued sonar sensor inputs into only 16 bits. Eighth, they then decided upon a particular non-linear scale (-1, 0, +3) of three reinforcements based on the output of the matched filter just described. Ninth, they then decided upon a different scale (+l and -3) of two reinforcements based on an especially-defined composite event, namely the robot “continu[ing] to be bumped and going forward” versus “loses contact with the box.” Tenth, they defined a particular timer for the applicability predicate for the pushing behavior and the unwedging behavior (but not the finding behavior) lasting precisely five time steps. This timer keeps the behavior on for five time steps even if the applicability predicate is no longer satisfied by the state of the world, provided the behavior involved was once turned on. Eleventh, they decided upon the scale (+l and -3) for reinforcement of another especially defined composite event connected with the unwedging behavior involving “no longer [being] stalled and is able to go forward once again.” Twelfth, after reducing the total input space to 218 = 262,144 possible states, they then further reduce the input space by consolidating input states that are within a specified Hamming distance. The Hamming distance is applied in a particular nonlinear way (i.e., weighting the NEAR bits by 5, the FAR bits by 2, the BUMPED bit by 1, 200 Learning: Robotic and the STUCK bit by 1). This consolidation of the input space reduces it from size 2l 8 = 262,144 to size 29 = 512. This final consolidation to only 512 is again apparently necessitated because the reinforcement learning technique requires calculation of a large number of trials for a large number of state-action combinations. Thirteenth, they then perform the reinforcement on each of the three behaviors separately. The first four of the above 13 decisions constitute the bulk of the difficult definitional problem associated with the subsumption architecture. After these decisions are made, only the content of the three behavioral actions remains to be learned. The last nine of the decisions constitute the bulk of the difficulty associated with the reinforcement learning and executing the task. It is difficult to discern what “automatic programming” or “learning” remains to be done after these 13 decisions have been made. It is probably fair to say that the 13 preparatory decisions, taken together, probably require more analysis, intelligence, cleverness, and effort than programming the robot by hand. In contrast, in preparing to use genetic programming on this problem, the five preparatory steps included determining the terminal set, determining the set of primitive functions, determining the fitness measure, determining the control parameters, and determining termination criterion and method of result designation, The terminal set and function set were obtained directly from the definition of the problem as stated by Mahadevan and Connell (with the minor changes already noted). Our effort in this area was no greater or less than that of Mahadevan and Connell. Defining the domain-specific fitness measure for this problem required a little thought, but, in fact, flows directly from the nature of the problem. Our choice of population size required the exercise of some judgment, but we used our usual default values for the minor control parameters. We used our usual termination criterion, and method of result designation. In fact, determination of the fitness measure was the critical step in applying genetic programming to the problem. Genetic programming allows us to generate a complex structures (i.e., a computer program) from a fitness measure. As in nature, fitness begets structure. References Brooks, Rodney. 1986. A robust layered control system for a mobile robot. IEEE Journal of Robotics and Automation. 2(l) March 1986. Connell, Jonanthan. 1990. Minimalist Mobile Robotics. Boston, MA: Academic Press 1990. Davis, Lawrence (editor). 1987. Genetic Algorithms and Simulated Annealing. London: Pittman 1987. Davis, Lawrence. 199 1. Handbook of Genetic Algorithms. New York: Van Nostrand Reinhold. 199 1. Goldberg, David E. 1989. Genetic Algorithms in Search, Optimization, and Machine Learning. Reading, MA: Addison-Wesley 1989. Holland, John H. 1975. Adaptation in Natural and Artificial Systems. Ann Arbor, MI: University of Michigan Press 1975. Koza, John R. 1989. Hierarchical genetic algorithms operating on populations of computer programs. In Proceedings of the I I th International Joint Conference on Artificial Intelligence. 768-774. San Mateo, CA: Morgan Kaufman 1989. Koza, John R. 1992a. Genetic Programming: On Programming Computers by Means of Natural Selection and Genetics. MIT Press, Cambridge, MA, 1992. Forthcoming. Koza, John R. 1992b. Evolution of subsumption using genetic programming. In Bourgine, Paul and Varela, Francisco (editors). Proceedings of European Conference on Artificial Life. Cambridge, MA: MIT Press 1992. Koza, John R. 1992~. The genetic programming paradigm: Genetically breeding populations of computer programs to solve problems. In Soucek, Branko and the IRIS Group (editors). Dynamic, Genetic, and Chaotic Programming. New York: John Wiley 1992. Koza, John R. 1992d. A genetic approach to finding a controller to back up a tractor-trailer truck. In Proceedings of the 1992 American Control Conference. American Automatic Control Council 1992. Koza, John R. 1992e. A genetic approach to the truck backer upper problem and the inter-twined spirals problem. In Proceedings of International Joint Conference on Neural Networks, Washington, June 1992. IEEE Press. Koza, John R. and Keane, Martin A. 1990. Genetic breeding of non-linear optimal control strategies for broom balancing. In Proceedings of the Ninth International Conference on Analysis and Optimization of Systems. Antibes,France, June, 1990. 47-56. Berlin: Springer- Verlag, 1990. Koza, John R. and Rice, James P. 1991. A genetic approach to artificial intelligence. In Langton, C. G. (editor). Artificial Life II Video Proceedings. Redwood City, CA: Addison-Wesley 1991. Mahadevan, Sridhar and Connell, Jonanthan. 1990. Automatic Programming of Behavior-based Robots using Reinforcement Learning. IBM Technical Report RC 16359. IBM Research Division 1990. Mahadevan, Sridhar and Connell, Jonanthan. 1991. Automatic programming of behavior-based robots using reinforcement learning. In Proceedings of Ninth National Conference on Artificial Intelligence. 768-773. Volume 2. Menlo Park, CA: AAAI Press / MIT Press 1991. Mataric, Maja J. 1990. A Distributed Model for Mobile Robot Environment-Learning and Navigation. MIT Artificial Intelligence Lab report AI-TR- 1228. May 1990. Watkins, Christopher. 1989. Learning from Delayed Rewards. PhD Thesis. King’s College, Cambridge 1989. Koza alnd Rice 201 | 1992 | 46 |
1,239 | Satinder P. Singh Department of Computer Science University of Massachusetts Amherst, MA 01003 singh@cs.umass.edu Abstract Reinforcement learning (RL) algorithms have tra- ditionally been thought of as trial and error learn- ing methods that use actual control experience to incrementally improve a control policy. Sutton’s DYNA architecture demonstrated that RL algo- rithms can work as well using simulated experi- ence from an environment model, and that the re- sulting computation was similar to doing one-step lookahead planning. Inspired by the literature on hierarchical planning, I propose learning a hier- archy of models of the environment that abstract temporal detail as a means of improving the scala- bility of RL algorithms. I present H-DYNA (Hier- archical DY NA), an extension to Sutton’s DYNA architecture that is able to learn such a hierarchy of abstract models. H-DYNA differs from hier- archical planners in two ways: first, the abstract models are learned using experience gained while learning to solve other tasks in the same envi- ronment, and second, the abstract models can be used to solve stochastic control tasks. Simulations on a set of compositionally-structured navigation tasks show that H-DYNA can learn to solve them faster than conventional RL algorithms. The ab- stract models also serve as mechanisms for achiev- ing transfer of learning across multiple tasks. Introduction Planning systems solve problems by determining a se- quence of actions that would transform the initial prob- lem state to the goal state. In a similar manner, problem-solving agents or controllers’, that have to learn to control an external environment, incorporate planning when they use a model of the control prob- lem to determine an action sequence, or an open loop control policy, prior to the act& process of control- ling the environment. Recent work on building real- time controllers has highlighted the shortcomings of ‘In this paper I interchangeably. will use the terms agent and controller planning algorithms: their inability to deal with uncer- tainity, stochasticity, and model imperfection without extensive recomputation. Some researchers have pro- posed reactive controllers (e.g., Schoppers 1987) that dispense with planning altogether and determine ac- tions directly as a function of the state or sensations. Others (e.g., Dean & Boddy 1988) have proposed con- trol architectures that use anytime algorithms, i.e., use the results of partial planning to determine the action in a given state. Sutton (1991) has noted that reactive controllers based on reinforcement learning (RL) can plan con- tinually, caching the results of the planning process to incrementally improve the reactive component. Sut- ton’s (1990) DYNA architecture is one such controller that learns a control policy as well as a model of the environment. Whenever time permits, simulated ex- perience with the model is used to adapt the control policy (also see Barto et al. 1991). As noted by Sutton (1991), the computation performed by the RL algo- rithm on simulated experience is similar to executing a one-step lookahead planning algorithm. The differ- ence between traditional planning algorithms and RL is that in RL the results are cached away into an eval- uation function that directly and immediately affects the control policy. The inability of RL-based controllers to scale well to control tasks with large state or action spaces has limited their application to simple tasks (see Tesauro 1992 for an exception). An approach to scaling RL algorithms can be derived from the research on hierar- chical planning (e.g., Sacerdoti 1973). Most hierarchi- cal planners assume access to a hierarchy of abstract models of the problem state-space. They first plan in the highest level, and then move down the hierarchy (and if necessary back up) to successively refine the abstract plan until it is expressed solely in terms of primitive actions. Although using abstract models is not new to RL (e.g., Chapman & Kaelbling 1991), such research has focussed on abstracting structural detail. I present a RL-based control architecture that learns a hierarchy of abstract models that, like hierarchical planners, abstract temporal detail. 202 Learning: Robotic From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. einfbrcernent Learning Algorithm! Unlike planning-based controllers, RL-based con- trollers are embedded in an optimal control framework (Barto et al. 1990). Th us, the RL agent has to learn a sequence of actions that not only transforms an exter- nal dynamic environment to a desired goal state2, but also improves performance with respect to an objective function. Let S be the set of states of the environment and Al be the set of primitive actions3 available to the agent in each state. In this paper, I focus on RL agents that have to learn to solve Markovian Decision Tasks (MDTs), where at each time step t the agent observes the state of the environment, Q, and executes an ac- tion, at. As a result, the agent receives payoff Rt and the state of the environment changes to st+l with prob- ability Et,,,+, (at). Th e o ‘ec ive function, J, consid- bj t ered in this paper is the discounted sum of payoff over an infinite horizon, i.e., J(i) = ~~~~ Y’Rt. The dis- count factor, 0 5 y 5 1 causes immediate payoffs to be weighted more than future payoffs. A closed loop control policy, which is a function assigning actions to states, that maximizes the agents objective function is an optimal control policy. If a model of the environment is available, i.e., the transition probabilities and the payoff function are known, conventional dynamic programming (DP) algo- rithms (e.g., Ross 1983) can be used to find an optimal policy. If a model of the environment is not available to the agent, RL algorithms that approximate DP, such as Sutton’s (1988) temporal differences (TD), can be used to approximate an optimal policy. An essential com- ponent of all DP-based algorithms4 for solving MDTs is determining an optimal value function V* : S -+ 3, that maps states to scalar values such that in each state the actions that are greedy with respect to V* are opti- mal. DP-based RL algorithms use repeated experience at controlling the environment to incrementally update P, an estimate of the optimal value function. The basic algorithmic step common to most DP- based learning algorithms is that of a “backup” in which the estimated value of a successor state is used to update the estimated value of the predecessor state. For example, the TD algorithm uses the state tran- sition at time t to update the estimate as follows: fT t+l(zt) = (loo-cr)~(~t)+cr[Rt+y~(at+l)], where Q! is the learning rate parameter. Bertsekas and Tsitsiklis (1989) show that under certain conditions the order of the backups over the state space is not important to 21n some optimal control problems the goal is to follow a desired state trajectory over time. I do not consider such tasks in this paper. 3For ease of exposition I assume that the same set of actions are available to the agent from each state. The extension to the case where different sets of actions are available in different states is straightforward. 4Algorithms based on policy iteration are an exception. the convergence of some DP algorithms (also see Barto et al. 1991) to the optimal value function. The rate of convergence, though, can differ dramatically with the order of the backups, and a number of researchers have used heuristics and domain knowledge to change the order of backups in order to accelerate learning of the value function (e.g., Kaelbling 1999; Whitehead 1991). While the inability of RL algorithms to scale well in- volves many issues (Singh 1992a; Barto & Singh 1990), the one of relevance to this paper is that most RL al- gorithms perform backups at the scale of the primitive actions, i.e., actions executable in one-time step in the real world. At that fine a temporal scale problems with large state spaces can require too many backups for convergence to the optimal value function. To do backups at longer time scales requires a model that makes predictions at longer time scales, i.e., makes pre- dictions for abstract actions that span many time steps in the real world. One way to abstract temporal detail would be to simply learn to make predictions for all possible se- quences of actions of a fixed length greater than one. However, the combinatorics of that will ontweigh any resulting advantage. Furthermore, it is unlikely that there is a single frequency that will economically cap- ture all that is important to predict. In different parts of the state space of the environment-model, “inter- esting” events, i.e., events that merit prediction, will occur at different frequencies. Any system identifica- tion technique that models the environment at a fixed frequency will be inefficient as compared to a system identification technique that can construct a variable temporal resolution model (VTRM), i.e., a model with different temporal resolutions in different parts of the state space. Learning Abstract Mode Tasks If the agent is to simply learn to solve a single task, the computational cost of constructing a VTRM may not be worthwhile (see Barto and Singh 1990). My approach to the scaling problem is to consider problem-solving agents that have to learn to solve mul- tiple tasks and to use repeated experience at solv- ing these tasks to construct a hierarchy of VTRMs that could then be used to accelerate learning of sub- sequent tasks. Besides, building sophisticated au- tonomous agents will require the ability to handle mul- tiple tasks/goals (Singh 1992b). Determining the use- ful abstract actions for an arbitrary set of tasks is dif- ficult, if not impossible. In this paper, I consider an agent that has to learn to solve a set of undiscounted (7 = l), compositionally- structured MDTs labeled Tr, 25,. . . , Tn. Each task re- quires the agent to learn the optimal path through a sequence of desired states. For example, task Ti = [a@2 * - * z,~], where ~j E S for 1 5 j 5 m. Task Singh 203 Ti requires the agent to learn the optimal trajectory from any start state to e, via intermediate states x1,332,***, a,-1 in that order. The MDTs are com- positionally structured because they can be described as a temporal sequence of simpler tasks each of which is an MDT in itself. Thus, the task of achieving desired intermediate state z optimally is the elemental MDT X = [z] defined over the same environment. Without loss of generality, I will assume that the n composite MDTs are defined over a set of N intermediate states labeled ~1, ~2, . . . , ON. Equivalently, the n compos- ite MDTs are defined over N elemental MDTs labeled xl,x2,-vxN~ The payoff function has two components: C(e,a), the “cost” of executing action a in state x, and r(x), the “reward” for being in the state x. It is assumed that C(x,u) 5 0, and is independent of the task being performed by the control agent, while the reward for being in a state will in general depend on the task. For task Ti, the expected payoff for executing action a in state z and reaching state y is &(a,~, y) G r;(y) + C(x,a). Further, I assume that ri(y) > 0 iff y is the final goal state of task Ti; Ti(y) = 0, elsewhere. For a set of compositionally-structured MDTs, de- termining the abstract actions for the hierarchy of VTRMs is relatively straightforward. The abstract ac- tions for the second level5 VTRM should be the el- emental MDTs Xl, X2,. . . , XN. Thus, the abstract action X1 would transform the environment state to al E S. The expected payoff associated with this ab- stract action can be acquired using experience at solv- ing MDT X1. Note that these abstract actions are a genemlized version of macro-operators (Iba 1989; Korf 1985) because unlike macros which are open loop se- quences of primitive actions that transform the initial state to a goal state and can handle only deterministic tasks, the abstract actions I define are closed loop con- trol policies that transform the environment from any state to a goal state and can handle stochastic tasks. Furthermore, unlike macro-operators, these abstract actions are embedded in an optimal control framework and could be learned incrementally. Consider two levels of the hierarchy of VTRMs: M-l, the lowest level VTRM whose action set A1 is the set of primitive actions, and M-2, the second level VTRM whose action set ~lz = (Xl, X2, . . . , X,3. The set of states remains S at all levels of abstraction. Note, that predicting the consequences of executing an ab- stract action requires learning both the state transition for that abstract action and its expected payoff. Un- der the above conditions the following restatement of a proposition, proved in Singh 1992a, is true: Proposition: If the abstract environment- model (M-2) is defined with the abstract actions 5Given the recursive nature of the definition of compos- ite tasks, the abstract actions for levels higher than two can be defined as the composite tasks themselves. &,X2,.. . , XN, and the costs assigned to the ab- stract actions are those that would be incurred under the optimal policies for the corresponding MDTs, then for all composite tasks Ti, Vs E S, K2(s) = vi*(s). Vi2 is the value function for task Ti that is learned by doing DP backups exclusively in the abstract model M-2, and Vi* is the optimal value function for task Tie The above proposition implies that after learning the abstract model, backups can be performed in the ab- stract model alone to learn the optimal value function. Hierarchieai DYNA The Hierarchical DYNA (H-DYNA) architecture is an extension of Sutton’s (1990) DYNA architecture. H- DYNA, shown in Figure 1, consists of a hierarchy of VTRMs, a policy module for each level of the hierarchy, and a single evduation function module. Note that the actual environment itself is shown in parallel with the M-l to emphasize their interchangeability. The evalu- ation module maintains an estimate, pi, of the optimal value function for each task Ti. Let the action set for the VTRM at level i be denoted A. For task Ti, let &j(x, aj, y) denote the estimate of the expected payoff for executing action aj E & in state x and reaching state y. For the VTRM at level one the backups will be over state pairs connected by primitive actions, and the payoffs are available directly from the environment. For VTRMs at levels > 1, the payoffs associated with the abstract actions will have to be learned over time using experience with the tasks corresponding to the abstract actions. The policy module at level j keeps a weight function for each task Ti, wdj : S x & + !J2. For level j, the probability of executing action a for task Ti is: Pj(i,CZ) = ew;j(X,a) c a'EJQj ewij(X,a') ' for x E S and a E J& When solving task Ti, the primitive control actions to be executed are always determined by the policy module at level 1. Whenever time permits, a backup is performed using experience in any one of the hierar- chy of environment models. For both real (level = 1) and simulated experiences on task Ti the evaluation function and the policy module involved (say level j) are updated as follows: G(X) = G(X) + a(&j(X, a, Y) + ye(Y) - e(X)) Wij(X,tZ) = W(X,a) + a[fiij(X, a, y) + &(Y) -C(x)], where a E Aj transforms state z E S to state y E S and results in a payoff of &.i (x, a, y). For real expe- riences, the task Ti is automatically the current task being performed by the agent and the state z is the 204 Learning: Robotic current state. However, for simulated experience in the abstract models, an arbitrary task and an arbi- trary state can be chosen. If there is no data available for the chosen state-task pair in the abstract model, no backup is performed. In addition, for every real experience, i.e., after ex- ecuting a primitive action, the transition probabilities for that action in M-1 are updated using a supervised learning algorithm. Cumulative statistics are kept for all the states visited while performing the task Ti in the real environment. When the agent finishes task Ti, i.e., when the final state for task Ti is achieved, all the environment models that have that task as an abstract action are updated. For example, after the agent finishes elemental task X1, the abstract model M-2 is updated because Xr E &. See Appendix for details. Tl Figure 1: The Hierarchical Dyna (H-DYNA) architec- ture. ulti ~~i~~~i~~~~ EdCS I illustrate the advantages of the H-DYNA architec- ture on a set of deterministic navigation tasks. Fig- ure 2 shows an 8 x 8 grid room with three goal lo- cations designated A, B and C. The robot is shown as a filled circle and the filled squares represent ob- stacles. In each state the robot has 4 actions: UP, DOWN, LEFT and RIGHT. Any action that would take the robot into an obstacle or boundary wall does not change the robot’s location. There are three el- emental tasks: “visit A”, “visit B”, and “visit C”, labeled [A], [B] and [C] respectively. Three compos- ite tasks: Tl = [Al?], T2 = [BC], and Ta = [ABC] were constructed by temporally concatenating the cor- responding elemental tasks. It is to be emphasized that the objective is not merely to find any path that leads to the goal state, but to find the least-cost path. The six different tasks, along with their labels, are de- scribed in Table 1. Table 1: Task Set Label Description Decomposition IA1 I visit A I [Al I , I. T3 visit A, then B and then C [AB’C] I The cost associated with all the state-action pairs was fixed at -0.25 for all tasks. For each task a value of 1.0 was associated with the final goal state for that task. Thus, no intermediate reward was provided for successful completion of subtasks. In the simulations, I will consider only two levels of the hierarchy, i.e., VTRMs M-l and M-2. Figure 2: The Grid Room: See text for details. This simulation was designed to illustrate two things: first, that it is possible to solve a composite task by doing backups exclusively in M-2, and second, that it takes fewer backups to learn the optimal value function by doing backups in M-2 as compared to the number of backups it takes in M-l. To learn M-2, I first trained H-DYNA on the three elemental tasks [A], [B] and [Cl. The system was trained until M-l had learned the ex- pected payoffs for the primitive actions and M-2 has learned the expected payoffs for the three elemental tasks. This served as the starting point for two sepa- rate training runs for task T3. For the first ruu, only M-l was used to generate information for a backup. For the second run the same learning parameters were used, and only M-2 was used to do the backups. To make the conditions as similar as possible for the comparison, the order in which the states were updated was kept the same for both runs by choosing predecessor states in a fixed order. After each backup, the absolute difference between the estimated value function and the previously computed optimal value function was determined. This absolute error was summed over all states for each backup and then averaged over 1000 backups to give a single data point. Figure 3 shows the learning curves for the two runs. The dashed line shows that the value function for the second run converges to the optimal value function. Sin& 205 backups performed in M-2 are more effective in reduc- ing the error in the value function than a backup in the real world. Figure 3: Learning curves: See text for details The two curves show that it takes far fewer backups in M-2 than M-l for the value function to become very nearly-optimal. Figure 4: On-line Performance: See text for details. Simulation 2 This simulation was conducted on-line to determine the effect of increasing the ratio of backups performed in M-2 to the backups performed in the real world. The robot is first trained on the 3 elemental tasks for 5000 trials. Each trial started with the robot at a ran- domly chosen location, and with a randomly selected elemental task. Each trial lasted until the robot had either successfully completed the task, or until 300 ac- tions had been performed. After 5000 trials H-DYNA had achieved near-optimal performance on the three elemental tasks. Then the three composite tasks (See Table 1) were included in the task set. For each trial, one of the six tasks was chosen randomly, the robot was placed in a random start state and the trial con- tinued until the task was accomplished or there was a time out. The tasks, Tl and Ta were timed out after 600 actions and the task Ts after 800 actions. iscussion The idea of using a hierarchy of models to do more efficient problem solving has received much attention in both the AI and the control engineering community. H-DYNA is related to hierarchical planning techniques in that search for a solution is conducted in a hierar- thy of models. However unlike hierarchical planning, where the models are given beforehand and the search is conducted off-line and sequentially, H-DYNA learns the model using on-line experience and can conduct the search in parallel. While the connection between DP backups and one-step lookahead planning was first emphasised by Sutton (1991) in his DYNA architec- ture, H-DYNA takes this one step further by demon- strating that doing backups in an abstract model is similar to multi-step planning in general and hierar- chical planning in particular. H-DYNA as a hierar- chical control architecture has the advantage of being continually “reactive” (much like DYNA) and at the same time performs deep lookahead searches using the abstract models. For this simulation it is assumed that controlling the robot in real-time leaves enough time for the agent to do n backups in M-2. The purpose of this simulation is to show the effect of increasing n on the number of backups needed to learn the optimal value function. No backups were performed in M-l. The simulation was performed four times with the following values of n: 0, 1, 3 and 10. Figure 4 shows the results of the four different runs. Note that each backup performed in M-2 could potentially take much less time than a backup performed in the real world. Figure 4 displays the absolute error in value function plotted ‘as a func- tion of the number of backups performed. This results of this simulation show that even when used on-line, The use of compositionally-structured tasks made the problem of figuring out the “interesting” subtasks simple. In addition the optimal solutions to composite tasks could be expressed in terms of the optimal solu- tions to the elemental tasks. Both of the above condi- tions will not be true for a more general set of MDTs. However, it may still be possible to discover significant “landmark” states using experience at solving multiple tasks in an environment and to use these states as goal states for the abstract actions to form VTRMs. Doing RL backups in such VTRMs could then quickly lead 206 Learning: Robotic to near-optimal solutions to new tasks. Such solutions could then *be optimized using further experience at solving that task. Further research is needed to test these intuitions. Acknowledgments I thank Andy Barto, Rich Sutton, Steve Bradtke, Richard Yee, and Vijag Gullapalli for their guidance and help. This material is based upon work supported by the Air Force Office of Scientific Research, Bolling AFB, under Grant AFOSR-89-0526 and by the Na- tional Science Foundation under Grant ECS-8912623. Appendix Learning abstract environment models I keep a list of all states visited in the real world while performing a elemental task Z’i. At each time step, the list is checked to see if the current state is in the list, if so, its cumulative cost is set to zero, else the current state is added into the list with cumulative cost zero. The current payoff is added into the cumulative payoff of all the states in that list. When the goal state is reached, the next state for all the states in the list is known as well as their cumulative payoff. As the policy evolves over time the cumulative payoff will change, but the next state will remain fixed. In this method the list can grow to contain the entire state set. Furthermore, searching for the current state is expensive, though efficient data structures (Union- Find) algorithms can be used. This method will be infeasible for large state sets. A more incremental method is to fix the list size to, say, k:, and then only keep the last Ic states in that qneue and manage it in a FIFO manner. Thus when a state x is moved out of the queue, the next state for E is set to be the next state stored for the current state in M-2 and the cumulative payoff to that stored in the queue added to the cumulative payoff stored for the current state in M-2. References Barto, A.G. and Singh, S.P. 1990. On the computa- tional economics of reinforcement learning. In Proc. of the 1990 Connectionist Models Summer School, San Mateo, CA. Morgan Kaufmann. Barto, A. G.; Sutton, R. S.; and Watkins, C. 1990. Learning and sequential decision making. In Gabriel, M. and Moore, J. W., editors 1990, Learning and Computational Neuroscience. MIT Press, Cambridge, MA. Batto, A.G.; Bradtke, S.J.; and Singh, S.P. 1991. Real- time learning and control using asynchronous dynamic programming. Technical Report 91-57, Uni- versity of Massachusetts, Amherst, MA. Also submit- ted to AI Journal. Bertsekas, D. P. and Tsitsiklis, J. N. 1989. Pare& lel and Distributed Computation: Numerical Methods. Prentice-Hall, Englewood Cliffs, NJ. Chapman, D. and Kaelbling, L. P. 1991. Input gener- alization in delayed reinforcement learning: An algo- rithm and performance comparisons. In Proceedings of the 1991 International Joint Conference on Artifi- cial Intelligence. Dean, T. and Boddy, M. 1988. An analysis of time dependent planning. In Proceedings AAAI-88. 49-54. Iba, 6. A. 1989. A heuristic approach to the discovery of macro-operators. Machine Learning 3:285-317. Kaelbling, L. P. 1990. Learning in Embedded Systems. Ph.D. Dissertation, Stanford University, Department of Computer Science, Stanford, CA. Technical Report TR-90-04. Korf, R.E. 1985. Learning to Solve Problems by Searching for Macro- Operators. Pitman Publishers, Massachusetts. Ross, S. 1983. Introduction to Stochastic Dynamic Programming. Academic Press, New York. Sacerdoti, E. D. 1973. Planning in a hierarchy of abstraction spaces. In Advance Papers of the Third International Joint Conference on Artificial Intelli- gence. Schoppers, M. J. 1987. Universal plans for reactive robots in unpredictable domains. In Proceedings of the IJCAI- 8 7. Singh, S.P. 1992a. Scaling reinforcement learning algorithms by learning variable temporal resolution models. In Proceedings of the Ninth International Ma- chine Learning conference. Forthcoming. Singh, S.P. 1992b. Transfer of learning. by compos- ing solutions for elemental sequential tasks. Machine Learning. Sutton, R. S. 1988. Learning to predict by the meth- ods of temporal differences. Machine Learning 3%44. Sutton, R. S. 1990. Integrating architectures for learn- ing, planning, and reacting based on approximating dynamic programming. In Proc. of the Seventh Inter- national Conference on Machine Learning, San Ma- teo, CA. Morgan Kaufmann. 216-224. Sutton, R. S. 1991. Planning by incremental dy- namic programming. In Birnbaum, L. and Collins, G., editors 1991, Machine Learning: Proceedings of the Eighth International Workshop, San Mateo, CA. Morgan Kaufmann. 353-357. Tesauro, G. J. 1992. Practical issues in temporal dif- ference learning. Machine Learning. Whitehead, S. D. 1991. Complexity and cooperation in Q-learning. In Birnbaum, L. A. and Collins, 6. C., editors 1991, Maching Learning: Proceedings of the Eighth International Workshop, San Mateo, CA. Mor- gan Kaufmann. 363-367. Singh 207 | 1992 | 47 |
1,240 | ite Automata wit an Application Thomas Deanl* Dana Angluin2t Sean Engelson2$ Leslie Kaelblingl Evangelos Kokkevisl Oded Maronl lDepartmen t of Computer Science Brown University, Providence, RI 02912 Abstract We assume that it is useful for a robot to construct a spatial representation of its environment for naviga- tion purposes. In addition, we assume that robots, like people, make occasional errors in perceiving the spatial features of their environment. Typical perceptual er- rors include confusing two distinct locations or failing to identify the same location seen at different times. We are interested in the consequences of perceptual uncertainty in terms of the time and space required to learn a map with a given accuracy. We measure accu- racy in terms of the probability that the robot correctly identifies a particular underlying spatial configuration. We derive considerable power by providing the robot with routines that allow it to identify landmarks on the basis of local features. We provide a mathematical model of the problem and algorithms that are guaran- teed to learn the underlying spatial configuration for a given class of environments with probability 1 - 5 in time polynomial in l/S and some measure of the struc- tural complexity of the environment and the robot’s ability to discern that structure. Our algorithms ap- ply to a variety of environments that can be modeled as labeled graphs or deterministic finite automata. Introduction In previous work [Basye et al., 19891, we have ar- gued that robot map learning - inferring the spa- tial structure of an environment relevant for naviga- tion - can be reduced to inferring the labeled graph induced by the robot’s perceptual and locomotive ca- pabilities. Following Kuipers and Byun [Kuipers, 1978, Kuipers and Byun, 19SS] and Levitt et al. [Levitt e2 *This work was supported in part by a National Sci- ence Foundation Presidential Young Investigator Award IRI-8957601, by the Air Force and the Advanced Research Projects Agency of the Department of Defense under Con- tract No. F30602-91-C-0041, and by the National Science foundation in conjunction with the Advanced Research Projects Agency of the Department of Defense under Con- tract No. IRI-8905436. ‘Supported by NSF Grant CCR-9014943. $ Supported y b the Fannie and John Hertz Foundation. 2Department of Comp uter Science Yale University, New Haven, CT 06520 a/., 19871, we assume that the robot has sensory ca- pabilities that enable it to partition space into regions referred to as docaldy distinctive places (LDPs), and that the robot is able to navigate between such regions reliably. The graph induced by the robot’s capabilit,ies has vertices corresponding to LDPs and edges correspond- ing to navigation procedures. In an office environment, the LDPs might correspond to corridors and the junc- tions where corridors meet and the navigation proce- dures to control routines for traversing the corridors separating junctions [Dean et al., 19901. We are interested in algorithms for learning the in- duced graph in cases where there is uncertainty in sens- ing. Uncertainty arises when the information available locally at an LDP is not sufficient to uniquely identify it (e.g., all L-shaped junctions look pretty much alike to a robot whose perceptual apparatus consists solely of ultrasonic range sensors). Uncertainty also arises as a consequence of errors in sensing (e.g., occasionally a T-shaped junction might be mistaken for an L-shaped junction if one corridor of the junction is temporarily blocked or the robot is misaligned with the walls of the corridors, resulting in spurious readings from specular reflections). In general, it is not possible for a robot to recover the complete spatial structure of the environment [Dudek et al., 19881 (e.g., the robot’s sensors may not allow it to discriminate among distinct structures). As a result, we will be satisfied if the robot learns the discemable structure of its environment with high cm2;fidence. In the following sections, we will define precisely our use of the terms ‘discernable’ and ‘high confidence.’ Preliminaries To formalize the problem, we represent the interaction of the robot with its environment as a deterininistic finite automaton (DFA). In the DFA representation, the states correspond to LDPs, the inputs t,o robot actions (navigation procedures), and the outputs to the information available at a given LDP. A DFA is a six tuple, A4 = (Q, B, Y, C, Qo, 7)) where e Q is a finit e nonempty set of states, 208 Learning: Theory From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. e B is a finite nonempty set of inputs or basic actions, 0 Y is a finite nonempty set of outputs or percepts, o 5 is the transition function, ( : Q x B --f Q, e 40 is the initial state, and Q y is the output function, y : Q - Y. Let A = B* denote the set of all finite sequences of ac- tions, and ]a] denote the length of the sequence a E A. Let q(a) be the sequence of outputs of length ]a] + 1 resulting from executing the sequence a starting in Q, and qu be the final state following the execution of the sequence a starting in q. An automaton is said to be reduced if, for all q1 # q2 E Q, there exists a E A such that ql(u) # 42(u). A reduced automaton is used to represent the discernable structure of the environ- ment; you cannot expect a robot to discern the differ- ence between two states if no sequence of actions and observations serves to distinguish them. A homing se- quence, h E A, has the property that, for all ql, q2 E Q, ql(h) = ax(h) implies qlh = qnh. Every automaton has a homing sequence; however, the shortest homing se- ;;;;Te may be as long as ]&I2 [Rivest and Schapire, There are a variety of sources of supplementary knowledge that can, in some ca.ses, simplify inference. For instance, it may help to know the number of states, IQ], or the number of outputs, ]Y I. It often helps to have some way of distinguishing where the robot is or where it was. A reset a.llows the robot to return to the initial state at any time. The availability of a reset provides a powerful advantage by allowing the robot to anchor all of its observations with respect to a uniquely distinguishable state, qo. A homing sequence, h, allows the robot to distinguish the states that it ends up in immediately following the execution of h.; the sequence of observations q(h) constitutes a unique signature for state qh. Rivest and Schapire [Rivest and Schapire, 19891 h s ow how to make use of a homing sequence as a* substitute for a reset. A sequence, d E A, is sa.id to be a distinguishing sequence if, for all ql, q2 E Q, ql(d) = q2(d) implies q1 = q2. (Every distinguishing sequence is a homing sequence, but not the other way around.) A distinguishing sequence, d, allows the robot to distinguish the states illat it starts executing d in; the sequence of observations q(d) constitutes a unique signature for q. Not all automata have a distinguishing sequence. Uncertainty in Observation In this paper, we are interested in the case in which the observations ma.de at an LDP are corrupted by some stochastic noise process. In the remainder of this paper, we distinguish between the output function, y, and the observation function, ‘p. We say that the out- put function is unique if Vq,, q2 E Q, yy(ql) = y(q2) implies q1 = 42; otherwise, it is sa.id to be ambiguous. If the output function is unique and cp = y, then there is no uncertainty in observation and learning is easy. The case in which the output function is ambiguous and cp = y has been studied extensively. The prob- lem of inferring the smallest DFA consistent with a set of input/output pairs is NP-complete [Angiuin, 1978, Gold, 1978l.l E ven finding a DFA polynomially close to the smallest is intractable assuming P#NP [Pitt and Warmuth, 19891. Angluin [Angluin, 19871, build- ing on the work of Gold [Gold, 19721, provides a polynomial-time algorithm for inferring the smallest DFA given the ability to reset the automaton to the initial state at any time and a source of counterex- amples. In Angluin’s model, at any point, the robot can hypothesize a DFA and the source of counterex- amples will indicate if it is correct and, if it is not, provide a. sequence of inputs on which the hypoth- esized and actual DFAs generate different output,s. Rivest and Schapire show how to dispense with the reset in the general case [Rivest and Schapire, 19891, and how to dispense with both the reset and t,he source of counterexamples in the case in which a distinguishing sequence is either provided or can be learned in polynomial time [Rivest and Schapire, 1987, Schapire, 19911. This last result is particularly important for the task of learning maps. For many manlmade and nat,ura.l environments it is straightforward to determine a dis- tinguishing sequence. Iii most office environnient,s, a short, randomly chosen sequence of turns will serve to distinguish all junctions in the environment. Large, complicated mazes do not have this propert’y, but we are not interested in learning such environments. The case in which cp # y is the subject of t,his paper. In particular, we are interested in the case in which there is a probability distribution governing what the robot observes in a state. There are several alt,ernatives for the sample space of the distribution governing the robot,‘s observations. ln this paper, we concentrate on the case ii1 which each visit’ to a location is an independent, trial. To avoid pathological situations, we assume t,hat t,he robot, better than proba.bilit’y observes t,he a&,ual output wit,h chance; that is, bl E Q, Wcp(q) = Y(d) 2 (2 > 0.57 where, in this case, p(q) is a random varia.ble ranging over Y. This model is a special case of the hidden Markov model [Levinson et al., 19831 in which state transitions are deterministic and the stochastic pro- cesses associa.ted with the observations of states are restricted by the above requirement. The closer Q is to l/2, the less reliable the robot’s observations. In the following section, we provide algorithms that al- low the robot to learn the structure of its environment with probability 1 - S for a given 0 < 6 < 1. We are interested in algorithms that learn the environment ‘There has to be some requirement on the size of the DFA, otherwise the robot could choose the DFA corre- sponding to the complete chain of inputs and outputs. Dean et al. 209 in a total number of steps that is polynomial in l/5, l/(a - l/2), and the size of the automaton, Ih/rl. We do not consider the case in which the robot re- mains in the same state by repeating the empty se- quence of actions and observes the output sufficiently often to get a good idea of the correct output. Our rationale for not considering this case is that the inde- pendence assumption regarding different observations of the same state are not even approximately satisfied if the robot does not take any overt action between ob- servations, whereas if there are overt actions between observations, the observations are more likely to be in- dependent. Learning Algorithms In the following, we present a high-probability, polynomial-time procedure, Localize, for localizing the robot (directing the robot to a state that it can dis- tinguish from all other states), and then show how this procedure can be used to learn environments in which the robot is given a distinguishing sequence.2 Finally, we discuss how Localize might be used to learn a distinguishing sequence in certain cases in which a distinguishing sequence is guaranteed to exist. We do not assume a reset. We do, however, assume that the transition graph is strongly connected, thereby avoid- ing the possibility that the robot ca.n become trapped in some strongly connected component from which it can never escape. The localization procedure The procedure Localize works by exploiting the fact that movement is deterministic. The basic idea is to execute repeatedly a fixed sequence of actions until the robot is certain to be “going in circles” repeating a fixed sequence of locations visited, corresponding to a cyclic walk in the underlying deterministic automaton. If we knew the period of repetition of the sequence of locations, we could keep separate statistics on the out- puts observed at each location. These statistics could then be used to deduce (with high probability) the cor- rect outputs at those locations, and hence to localize the robot by supplying a signature for the state the robot is in. The problem then is to figure out the period of repe- tition of the walk with high probability. We keep statis- tics for the alternative hypotheses for the period of the cycle, which are then analyzed to determine with high probability the true period of the cycle. Recall that the Markov assumption implies a sta- tionary probability distribution over the outputs at 2 In [Kaelbling et al., 19871, we consider a more effi- cient approach for the case in which y is unique which, under more restrictive conditions than those required .in this paper, infers the underlying automaton by estimating the transition probabilities on the observed states (i.e., the probability of observing i next given that the robot ob- served j last). each state. If the states are numbered from 1 to n and the outputs are oj for j = 1,2,. . . , k, let ai,j de- note the probability of observing symbol oj given that the robot is in state i. We assume an upper bound m on the number of states of the automaton. Let s = blb2 . . .b~~l be a se- quence of one or more basic actions; we assume that s is a distinguishing sequence for the underlying au- tomaton. Let pi be the state reached after executing the sequence of actions P+‘, that is, m repetitions of s followed by i repetitions of s. The first m repetitions ensure that the robot is in the cyclic walk. The se- quence of states qo, ql, q2, . . . is periodic; let p denote the least period of the cycle. Note that p < m. Our main goal is to determine (with high probability) the value of p. For each e = 0, . . . , Is] - 1, we also consider the sequence of states qf reached after executing the se- quence of actions sm+“brb2 . . . be. That is, y% is the state reached from q; by executing the first e Isa.sic ac- tions from the sequence s. For each e, the sequence d,dd&... is also periodic of period p. For each e, consider the sequence of (correct) outputs from the states sf: 7% = y(qf). The output sequence Y~,YLY~,.*.. is also periodic, of some least period pe dividing p. Since we are not assuming the outputs are unique, pe may be smaller than p. However, p will be the LCM of all the pe’s. It is clear that p is a multiple of each pe, so suppose instead that the LCM p” of all the pe’s is a proper divi- sor of p. This implies that as we traverse the cycle of p distinct states, qo, ql, . . . qP, the output sequences qi (s) must repeat with period p” < p, which implies that two distinct states have the same sequence of outputs, contradicting the assumption that s is a distinguishing sequence. Thus, it would suffice if we could determine each of the values pe, and take their LCM. In fact, what we will be able to do is to determine (with high probability) values qe such that pe divides qe and qe divides p - this also will be sufficient. To avoid the superscripts, we describe the procedure for the sequence qo, ql, qa, . . .; it is analogous for the others. Consider any candidate period x 5 m, and let g = gcd(p, 4. For each 0 5 i 5 x - 1, consider the sequence of states visited every 7r repetitions of s, starting with m + i repetitions of s. This will be the sequence of states qi, qi+, qi+sx, qi+3*, . . . . Since qi is periodic of period p, this sequence visits each state of the set {qi+hg : k = 0, 1, . . . , p/g - 1) in solne order, and then continues to repeat this cycle of p/g states. Hereisanexampleforp= 15,7r= lO,g=5. Inthis case, row T of Table 1 gives the indices of the states visited every 10 repetitions of s, starting from m + 1 repetitions of s, assuming that the basic period of the states under repetitions of s is qo, q1, . , . , q14. Note that in Table 1, the set of states visited for row Y is the same as the set of states visited for row 13 + 5, 210 Learning: Theory Step # I States visited 0 10 5 0 10 5 . . . 1 11 6 1 11 6 . . . 2 12 7 2 12 7 . . . 3 13 8 3 13 8 . . . 4 14 9 4 13 9 . . . 5 0 10 5 0 10 . . . 6 1 11 6 1 11 . . . 7 2 12 7 2 12 . . . 8 3 13 8 3 13 . . . 9 4 14 9 4 14 . . . Table 1: Sequences of visited states for 0 5 r 5 4. This holds in general: the set of states visited every x repetitions of s starting from m + 1 repetitions of x is the same as the set of states visited every 7r repetitions of s starting from m + T + g repeti- tions of 7r. Thus, the sequence of sets So, S1, . . . , S,-1 is periodic with period g. In the special case x = p, row 1’ will consist exclu- sively of visits to state qr. In the special case g = 1, that is, 7r and p relatively prime, each row will consist of repetitions (in some fixed order) of a visit to each of the p states. What we observe Of course, what we can observe is just the stochastically determined output at each state the robot visits. The overall operation of the algorithm will be to repeat the action sequence s a total of m + m2t times, with t chosen to ensure that we know the true output frequencies accurately, with high probability. For each candidate period 7r 5 m we form a table with 7r rows numbered 0 to 7r - 1, and k columns, one for each possible output symbol gj. In row r and column j we record the relative frequency of observations of symbol aj a.fter executing P+l’+‘* for 21 = O,l,...,mt - 1. Since T 5 m and r 5 T - 1, these observations are all available in a run containing nz + m2t repetitions of s. If in this table each row has a “majority output” whose observed frequency is a.t least + + $sep, where Y the table is said to be plausible. Otherwise, the table is ignored. If the table is plausible, we then take the sequence of 7r majority outputs determined by the rows and find the minimum period r’ (dividing 7~) such that the sequence of majority outputs has period K’. As our candidate for the period of the sequence of outputs we take the LCM of all the numbers r’ obtained this way from plausible tables. Justification Why does this work? When x = p, the rows of the table correspond exactly to the dis- tinct states qr, so with high probability in each row we will get a frequency of at lea.st a + $sep for the correct output (provided t is large enough) from each state, and therefore actually have the sequence of cor- rect outputs for the cycle of p states, whose period is (by hypothesis) p’. Thus, with high probability the ta- ble corresponding to 7r = p will be plausible, and one of the values 7r’ will be p’ itself. When 7r # p, as we saw above, the set of states S, visited in row T is determined by g = gcd(r, p) and 1’ mod g. In the limit as t becomes large each state in S,. is visited equally often and the expected frequency of aj for row r is just the average of oi,j over i E S,. . Since the sets S,. are periodic over 1’ with period g, the expected frequencies for a given symbol in rows 0,1,2 )...) ?r- 1 is periodic, with least period dividing g. Thus, provided t is large enough, if the table for x is plausible, the value K’ will be a divisor of g (with high probability), and so a divisor of p. Thus, with high probability, the value we determine will be the LCM of p’ and a set of values 7r’ dividing p, and therefore will be a multiple of p’ and a divisor of p, as claimed. Recall that we must repeat this opera- tion for the sequences qf determined by proper prefixes of the action sequence s, and take the LCM of all the resulting numbers. However, the basic set of ohserva- tions from m + m”t repetitions of s can be used for all these computations. Required number of trials In this section, we de- termine a sufficient bound on t to guarantee that with probability 1 - 5, the observed output frequencies con- verge to within asep = +$(a - $) of their true values. Recall that p denotes the least period of the sequence qo, (11,427 ’ * . . First consider the frequency table for 7r. Let g = gcd(p, X) and p = gh. Let Sr = {qil,qi2,. . . ,qi,> be the set of states visited in row 1’ of the table. Let V, denote the number of visits to state qi, used in calcu- lating row 7’. The expected frequency of observa.tions of output Uj in row 1’ is The total number of visits to states in row I* is mt, and the states are visited in a fixed cyclic order. Since h 5 m, each state in S,. is visited at least t times in row 1’. More precisely, for each U, U, is either Lmt/hJ or [mt/hj. If we choose t sufficiently large that for each state i in S,. the observed frequency of output gj is within $sep of ai,j with probability at least l-S/lsll;~~~, then with probability at least 1 - 6/lslkm”, the observed frequency of symbol gj in row 7’ will be within isep of its expected value fr,j, and with probability at least 1 - S/Is/m, each of the at most km entries in the table for K will be within $sep of its expected value. In this case, the probability will be at least l-S/Is1 that all the values in all the (at most m) tables will be within $sep of their expected values. We repeat this operation for each of the IsI proper prefixes of s, so, in this case Dean et al. 211 the probability is at least 1 - 6 that all the observed frequencies in all the tables considered for each prefix of s will be within $sep of their expected values. We consider what happens in the case that all the en- tries in all the tables are within fsep of their expected values. In the case x = p, the expected value of the cor- rect output for state q,. and hence row Y of the table is at least o, which means that the observed frequencies for the correct outputs will all exceed $ + $sep, and the table will be plausible and the “majority outputs” will be the correct outputs, of period p’ by hypothesis. In the case of ?r # p, no output aj whose frequency f,*,j in a row is at most $ can have an observed fre- quency exceeding 3 + $sep. Thus, each output with an observed frequency exceeding i + isep has a true frequency of greater than $, and so is uniquely deter- mined for that row. This guarantees that if the table for x is plausible, then the “majority output” from row T is uniquely determined by the set S,. , and the se- quence of “majority outputs” will be periodic of some period dividing g = gcd(r,p), as claimed. Thus, as- suming all the values in all the tables are within $sep of their expected values, the LCM of the values of 7r’ will correctly determine a value q that is a multiple of p’ and a divisor of p. Since this is true for each prefix of s, the correct value of p is determined. In the extended version of this paper, we show that it is sufficient to repeat s times in order to guarantee that Localize succeeds with probability at least 1 - 6. The algorithm Based on the discussion above, we now present Localize. For simplicity, we assume that all the possible out- puts are known and correspond to the integers 1 Y”‘, L. Build a table T(;rr, !Z, ?a, j) of size m x IsI x m x Ic. Initialize all the table entries to zero.3 Execute the sequence s m times to ensure that the robot is in a closed walk that it will continually tra- verse for as long as it continues to execute s.~ Initialize the sequence counter: R - 0 and the step counter: c - 0. Execute s at least N times, incrementing R each time. After executing each individual step, do: (a) Increment the step counter: c - c + 1. Let e = c mod IsI, and j be the label observed im- mediately following execution. 31f the labels are not known, then the table can be constructed incrementally, adding new labels as they are observed. 4Following Step 2, the next action should be the first action in s. (b) For each 7r = 1.2.. . . , m - 1, the table entry I T( 7r, e, R mod 7~, j) is incremented by 1. Let Let P be the LCM of all 7r’ such that there exist T and e such that for all Y < K there exists j such that F(~F, -!Z, T, j) > 4 + ;sep and X’ is the period of the outputsargrnaxjF(;lr,4?,r,j)forr=O,l,..., X-1. Conclude that the robot is currently located at the state corresponding to row T = R mod P in the main table for P, and return as the hypothe- sis for the correct outputs of the distinguishing se- quence s from this state the sequence of outputs arg maxj F(P, 4!, T, j) for 4! = 0, 1, . . . , IsI - 1 followed by arg maxj F(P, 0, (r + 1) mod P, j). The map learning procedure Now we can define a procedure for learning maps given a distinguishing sequence, s. Suppose for a moment that Localize always returns the robot to the same state and that the robot can always determine when it is in a state that it has visited before. In this case, the robot can learn the connectivity of the underlying au- tomaton by performing what amounts to a depth-first search through the automaton’s state transition graph. The robot does not actually traverse the state transi- tion graph in depth-first fashion; it cannot inana.ge a depth-first search since, in general, it cannot backtrack. Instead, it executes sequences of actions corresponding to paths through the state transition graph starting from the root of the depth-first search tree by return- ing to the root each time using Localize. When, in the course of the search, a state is recognized as having been visited before, an appropriate arc is added to the inferred automaton and the search ‘backtracks’ to t(he next path that has not been completely explored. The algorithm we present below is more complicated because our localization procedure does not nccessar- ily always put the robot in the same fina. stat,e and because we are not able to immediately ident’ify the states we encounter during the depth-first sea.rch. The first problem is solved by performing many searches in parallel ,’ one for each possible (root) state that Localize ends up in. Whenever the Localize is executed the robot knows (with high probability) what state it, has landed in, and can take a step of the depth-first search that has that state as the root node. The second problem is solved by using a number of executions of 5The idea of using multiple searches starting from the states resulting from Localize is similar to the way in which Rivest and Schapire [Rivest and Schapire, 19891 run mul- tiple versions of Angluin’s L’ algorithm [Angluin, 19871 starting from the states the robot ends up in after execut- ing a given homing sequence. 212 Learning: Theory the distinguishing sequence from a given starting state to identify that state with high probability. The algorithm, informally, proceeds in the following way. The robot runs Localize, ending in some state q. Associated with that state is a depth-first search which is in the process of trying to identify the node at the end of a particular path. The actions for that path are executed, then the distinguishing sequence is executed. The results of the distinguishing sequence are tabu- lated, then the robot begins this cycle again with the localization procedure. Eventually, the current node in some search will have been explored enough times for a high-probability determination to be made about its unique signature. Once tha.t is done, if a node with the same signature has been identified previously in this search, the two nodes are identified in the hypoth- esized state transition graph and the search backtracks. If the signature is new, then a new node with the corre- sponding signature is added to the hypothesized graph and the search proceeds to the next level of depth. We now explain the algorithm more formally. The algorithm With each state, q, that the robot ends up in using Localize, we associa,te a. set, Vq , of pairs (x, y), where x is a sequence of basic actions represent- ing a path through the state transition graph and y is a. high-probability estimate of the sequence of outputs obtained by executing the distinguis-hing sequence, s, after executing the actions in d: starting from Q. That is, with high probability qx(s) = y. In addition, each q has a current path, xg and signa.ture estimation table, Tu. The signature estimation table is indexed in one dimension by IsI, the length of the distinguishing se- quence, and in the other dimension by rl-, the number of possible outputs. The set of states in the hypothesized automaton is acquired over time from the output of Localize and the high-probability signatures obtained in identifying states. We will refer t,o states and their signatures interchangeably. Each time a new signa.ture is encountered, the robot initia.lizes the associated data. structures as follows. 1. v4 - ww>l 2. xq - First(B) 3. For each 0 5 i 5 IsI and 1 5 j 5 k, T,[i, j] t 0. Here we assume that the set of basic actions, B, is ordered and that First(B) denotes the first action in B. The null sequence is denoted A. Using the above initialization subroutine, the map-lea.rning procedure is described as follows. 1. Execute Localize, ending in some state q. 2. If q is new, then initialize it. 3. Execute x9. 4. For current output aj, increment Tq [0, j]. 5. For i from 1 to IsI, (a.) Execute next basic a,ction in s, getting output aj. (b) Increment T4 [i, j] . 6. If sum of the entries in a row of Tp equals M (in this case the distinguishing sequence has been executed M times from the end of the current path), then (4 (b) (4 (d) Let y = s1 . . . ~1~1, where si = argmaxj Ty [i, j]. Add (xg , y) to VP. If there is no other entry in Vq with signature equal to y, then set xg to the concatenation of x9 and First(B), else backtrack by setting xg to t#he next unexplored path in a depth-first search of Vq or return Vq if no such path exists. For all 0 < i 5 IsI and 1 5 j 5 k, T,[i, j] - 0. 7. Go to Step 1. Required number of steps The above procedure will return the results of the first depth-first search that is finished. The returned Vq contains all of the information required to construct the sta.te t8ra.nsition graph for the automaton with high probability xssum- ing that Localize succeeds with high enough probabil- ity and that the estimations used in identifying sta.tes are correct with high enough probability. Suppose that p = 1 -S is the probability that Localize succeeds. The parameter p must be chosen so that 1/(2tr) < [3 < 1, by setting N appropriately. In the extended version of this paper, we show that for fixed /3 if 1 M = 2(Q@ - l/2)2 In 2WmPI . ql then the above algorithm will learn the map exactly with probability at least 1 - 7, and so the algorithm is polynomial in l/(c~ - i), IBI, Ic, m, IsI, and l/11. Learning distinguishing sequences The above procedures rely on the robot having a distin- guishing sequence. If we are not given a distinguishing sequence but, know that such sequences exist, it, would be useful to be able to learn one. Unfortunately, even if outputs are deterministic and the target DFA has a distinguishing sequence (but we don’t know it), we can- not hope to find a distinguishing sequence in polyno- mial time by exploration only, in general. (The reason is that the adversary argument that shows that DFAs cannot be learned using membership queries only can be modified so that the target DFAs all have distin- guishing sequences.) Suppose, however, that the robot has a generator of candidate sequences that (i) gen- erates sequences of length at most polynomial in t,he number of states, and (ii) generates correct distillguish- ing sequences with a probability bounded below by an inverse polynomial in the number of states. In this case, we can learn a map in polynomial time with high probability. The idea is that if we have two candidate sequences s and s’ one of which is a correct distinguishing sequence and one of which is not, we can build two maps M and n/r’ using them, and with high probability the correct Dean et al. 213 sequence produces the correct map. Then, given two maps M and M’ that are not isomorphic, we can find a sequence of actions for which they make a different prediction. We execute the sequence of actions and check the resulting observation. The correct map has a probability of at least alpha of agreeing with the ob- servation, the incorrect map has a probability of at most 1 - a. This is repeated sufficiently often to have a high probability of the correct map succeeding more often. Thus, we can specify a method of comparing two maps with the property that a correct map wins the comparison with high probability. If this is used on a sufficiently large set of candidates from the generator, then with high probability there will be a true distin- guishing sequence in the set and the overall winner will be a correct map. Collclusions In this paper, we provide general methods for the in- ference of finite automata with stochastic output func- tions. The complete analysis of the algorithms pre- sented in this paper are provided in an extended ver- sion available upon request. Practically speaking, the running times given in the proof% for the theorems de- scribed in this paper are unacceptable; ultimately, we are interested in algorithms whose effort in relatively benign environments is bounded by some small con- stant factor of the size of the environment. Our ob- jective here is foundational; we are trying to under- stand the fundamental sources of complexity involved in learning about the structures induced by perception. Given our best attempts to devise efficient algorithms, it would seem that robots with perceptual systems that are not capable of consistently identifying any location with probability better than cy, where a is not much greater than 0.5, or are unable to make multiple in- dependent observations of their current state are seri- ously disadvantaged. In previous work [Basye ell cl!., 19891, we concen- trated on problems in which the state transition func- tion is stochastic. In future work, we intend to com- bine our results to handle uncertainty in both move- ment and observation. We are also interested in iden- tifying and exploiting additional structure inherent in real environments (e.g., office environments represent a. severely restricted class of planar gra.phs) and in ex- ploring more forgiving measures of performance (e.g., it is seldom necessary to learn about the entire envi- ronment as long as the robot can navigate efficiently between particular locations of interest). References Angluin, Dana 1978. On the complexity of minimum inference of regular sets. ITzformation and Control 39:337-350. Angluin, Dana 1987. Learning regular sets from queries and counterexamples. Inf’ormation and Com- putation 75:87-106. Basye, Kenneth; Dean, Thomas; and Vitter, Jef- frey Scott 1989. Coping with uncertainty in map learning. In Proceedings IJCAI 11. IJCAII. 663-668. Dean, Thomas; Basye, Kenneth; Chekaluk, Robert; Hyun, Seungseok; Lejter, Moises; and Randazza, Margaret 1990. Coping with uncertainty in a control system for navigation and exploration. In Proceedings AAAI-90. AAAI. 1010-1015. Dudek, Gregory; Jenkins, Michael; Milios, Eva.nge- 10s; and Wilkes, David 1988. Robotic explora.tion as graph construction. Technical Report RBCV-TR-88- 23, University of Toronto. Gold, E. Mark 1972. System identification via sta.te characterization. Automatica 8:621-636. Gold, E. Mark 1978. Complexity of automatlou iden- tification from given sets. Information and Control 37:302-320. Kaelbling, Leslie; Basye, Kenneth; Dean, Thomas; Kokkevis, Evangelos; and Maron, Oded 1992. Robot map-learning as learning labeled graphs fro111 noisy data. Technical Report CS-92-15, Brown University Department of Computer Science. Kuipers, Benjamin J. and Byun, Yung-Tai 1988. A robust, qualitative method for robot spatial reasou- ing. In Proceedings AAAI-88. AAAI. 774-779. Kuipers, Benjamin 1978. Modeling spatial knowledge. Cognitive Science 21129-153. Levinson, S. E.; Rabiner, L. R.; and Sondhi, M. M. 1983. An introduction to the application of the theory of probabilistic functions of a Markov process to auto- matic speech recognition. The Bell System Technical Journal 62(4):1035-1074. Levitt, Tod S.; Lawton, Daryl T.; Chelberg, David M.; and Nelson, Philip C. 1987. Qualitative landmark-based path planning and following. In Pro- ceedings AAAI-87. AAAI. 689-694. Pitt, Leonard and Warmuth, Manfred K. 1989. The minimum consistent DFA problem cannot be approx- imated within any polynomial. In Proceedings of the Twenty First Annual ACM Symposium on Theoreti- cal Computing. 421-432. Rivest, Ronald L. and Schapire, Robert E. 1987. Diversity-based inference of finite automata. In Pro- ceedings of the Twenty Eighth Annual Symposium on Foundations of Computer Science. 78-87. Rivest, Ronald L. and Schapire, Robert E. 1989. In- ference of finite automata using homing sequences. In Proceedings of the Twenty First Annual ACM Sym- posium on Theoretical Computing. 411-420. Schapire, Robert E. 1991. The design and analy- sis of efficient learning algorithms. Technica. Report MIT/LCS/TR-493, MIT Laboratory for Computer Science. 214 Learning: Theory | 1992 | 48 |
1,241 | livious ear ie Michael J. Kearns AT&T Bell Laboratories 600 Mountain Avenue, Room 2A-423 Murray Hill, New Jersey 07974-0636 mkearns@research.att .com Abstract In this paper we introduce an extension of the Probably Approximately Correct (PAC) learning model to study the problem of learning inclusion hierarchies of concepts (sometimes called is-a hi- erarchies) from random examples. Using only the hypothesis representations output over many dif- ferent runs of a learning algorithm, we wish to reconstruct the partial order (with respect to gen- erality) among the different target concepts used to train the algorithm. We give an efficient al- gorithm for this problem with the property that each run is oblivious of all other runs: each run can take place in isolation, without access to any ex- amples except those of the current target concept, and without access to the current pool of hypothe- sis representations. Thus, additional mechanisms providing shared information between runs are not necessary for the inference of some nontrivial hi- erarchies. Introduction and Motivation In this paper we introduce an extension of the Probably Approximately Correct (PAC) learning model (Valiant 1984) to study the problem of learning inclusion hier- archies of concepts (sometimes called is-a hierarchies) from random examples. (In this paper, a concept is simply a set, or equivalently, its Boolean characteristic function.) Using the hypothesis representations out- put over many different runs of a learning algorithm, we wish to reconstruct the partial order (with respect to generality) among the different target concepts used to train the algorithm. Informally, our intention is to model the ability to not only learn (in the sense of recognition) the abstract concepts chair and furniture, but to also infer that all chairs are furniture. The scenario we have in mind is roughly the following: a learning algorithm L is run many times, and each time is trained on a potentially different target concept f. Each run results in the ad- dition of a new hypothesis representation r to an exist- ing pool. In addition to the usual criterion that each P should provide a good predictive approximation to its corresponding target concept f, we would like the pool of hypothesis representations to effectively support in- clusion tests between any pair of target concepts. More precisely, given any ri and r2 in the pool (where ~1 was the result of training L on a target concept fl, and r2 was the result of training L on fz), by examining rl and ~2 we should be able to determine if fi > f2 (that is, f2(4 = 1 implies fi (2) = 1 for all z), fz ,> fr , or fi and fz are incomparable. 1 We will present an algorithm for this problem that meets the following three conditions: 1. 0 blliviousness: Every run of the algorithm can take place in complete isolation, and is oblivious of all past and future runs. When being trained on a target concept f, the algorithm needs access only to examples off. It does not consult the current pool of hypothesis representations or receive examples of other concepts. Thus, all runs of the algorithm are pairwise statistically independent. 2. A Closed System: The pool of hypothesis rep- resentations output by the algorithm functions as a closed system. By this we mean that the inclusion test on r1 and r2 takes place without any additional sampling of values of fi or f2, and the information re- quired to determine the relationship between fi and f2 is entirely contained in rl and r2. 3. Succinctness of ypotheses: The learning algorithm does not vacuously satisfy the obliviousness condition by, for instance, storing a large random sam- ple of f as part of its hypothesis representation r and thus letting this random sample become part of the “closed system” of representations. Such an approach would effectively allow each inclusion test to be per- formed with simultaneous access to examples of both target concepts participating in the test, and would render our first two conditions meaningless. The al- gorithm explicitly synthesizes from the training data some representation that is considerably more succinct than the training data itself, but that facilitates inclu- ‘The most natural hypothesis representation T would seem to be simply the representation of some concept h that approximates the corresponding target concept f. While such a representation is clearly sufficient for the standard (predictive) learning problem, we will show that in our model it is not sufficient for supporting inclusion tests, but that allowing t to represent tp~o concepts (that is, 7 = (h, h’), where h and h’ are two different concepts ap- proximating f) is sufficient. We will eventually clarify this issue rigorously, but for now will continue to refer to “hy- pothesis representations” in an abstract way. Kearns 215 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. sion testing. It is important to emphasize that we in no way con- sider these three conditions to be definitive for models of learning with inclusion testing. For instance, we do not wish to dismiss models that allow the current run of a learning algorithm access to the current pool of hypothesis representations, or that allow some limited sampling as part of the inclusion testing process. The main claim we wish to support here is that in many cases of interest, such additional mechanisms are un- necessary, and the above criteria can be met by prov- ably efficient and correct algorithms. One of our primary motivations is the problem of performing precise logical inference using imperfect learned predicates. If we interpret the output of a con- cept learning algorithm as an empirically acquired log- ical predicate, then the ability to use these predicates to accurately detect inclusions among the correspond- ing target concepts can be viewed as a simple form of this problem, since inclusion is equivalent to implica- tion or subsumption. We investigate this connection in greater depth in a section near the end of the paper. A summary of the paper follows. We begin with an informal discussion of the special problems posed for inclusion testing in the PAC model, and follow this with formal definitions for the PAC model. We then sketch our model of PAC learning with inclusion test- ing, and give a necessary technical aside that limits the pairs of target concepts for which we may reasonably expect to detect inclusion. Our first result proves that there is no hope that any PAC learning algorithm will already provide inclusion testing via direct comparison (with respect to 3) of the hypothesis concepts, because a single hypothgsis con- cept contains insufficient information. This then leads us to consider learning algorithms that compute mul- tiple hypothesis concepts on each run. The main tech- nical result of the paper is an algorithm that uses this approach, and provably provides PAC learning with in- clusion testing for any concept class that is closed un- der intersection (or dually, under union). We present this result over two sections, first sketching the intu- ition informally for a special case, and then stating the general theorem. We then give a modified version with considerably improved sample complexity, and discuss various ways of reconstructing an entire hierarchy or partial order of inclusions. In the final sections, we re- turn to the more general problems of logical inference using learned predicates, and discuss some of our other results. Why Use the PAC Model? The choice of the PAC model as the basis for our study of learning concept hierarchies is significant due to the probabilistic nature of the PAC model. In a model where the examples are generated randomly, it is in general impossible to exactly identify the target con- cept - a small amount of error is unavoidable. From this small error arises the difficulty in detecting inclu- sions. As an example of this difficulty, consider the stan- dard algorithm for learning an unknown target rectan- gle in the real plane whose sides are parallel to the co- ordinate axes (we will refer to such rectangles as being axis-parallel), where the examples are drawn according to an unknown and arbitrary probability distribution over the plane. (We will return to this problem as a running example throughout the paper). The algo- rithm takes a sufficiently large set of positive examples of the target rectangle f, and outputs as its hypothesis the most specific axis-parallel rectangle that includes all of these positive examples. While it is well-known that this algorithm meets the criteria of the PAC model (Blumer et al. 1989), consider what happens when we run this algorithm twice independently (that is, using an independent random sample for each run), using the same target rectangle f and the same distribution for each run. Although each of the two hypothesis rect- angles h and h’ output by the algorithm will be with 6 high probability) good approximations to f wit re- spect to the distribution, the variations in the random samples for the two runs will almost certainly result in both (h - h’) and (h’ - h) being nonempty. Thus, it will be impossible to detect that the target was identi- cal for the two runs simply by direct comparison (with respect to the ordering 2) of the rectangles h and h’. This example is quite relevant, since detecting when the target was identical on two runs is a special (and hardest) case of detecting inclusions between targets. Some additional learning mechanism seems to be required here. In fact, in Theorem 1 we prove that some additional mechanism is required in a very gen- eral sense. We feel that using the PAC model to study learning hierarchies of concepts captures an interest- ing question: How is it possible to have imperfect hy- potheses for target concepts, yet still be able to use these hypotheses to precisely relate (with high proba- bility) the target concepts to each other with respect to inclusion? T AC Learning Model Let X be a and let F be any class of concepts (Boolean function;) over X. We think of X as the input space, and J= as the class of possible target concepts. In this paper we will think of concepts both as sets and as functions, and will use the notation f (2) to indicate the (0, 1) value assigned to x by f, and fi ,> f2 to indicate that for all x E X, f2(x) = 1 3 fi(x) = 1. Eet 27 be any probability distribution over X. On an execution using a particular target concept f E F and the distribution V, a learning algorithm in our model will be given access to an oracle EX( f, D) that runs in unit time and returns examples of the form (x, f(x)), where x is chosen randomly and independently accord- ing to D (denoted x E 27). Given any concept h, there is a natural measure of the error o with respect to f and D, defined by error(h) = zEp[f(x) # h(x)]. Note that error(h) has an implicit dependence on f and ‘D that we omit for brevity. If error(h) 5 6, we say that h is e-good (with respect to f and D). We are now ready to give the definition of PAC learn- ing (Valiant 1984) ( see also (Haussler et al. 1991)): Definition 1 Let F be any class of concepts over X. Then F is efficiently PAC learnable if there is an ulgo- rithm L such that for any target concept f E F, for any 216 Learning: Theory distribution 2) over X, and for any values 0 < E < 4 and 0 < S < 3, if L is given inputs e and 6 and access to EX(f,V), th e o f 11 owing two conditions are met: e (Eficiency) L runs in time polynomial in the inputs 3 and $, and d (Learning) L outputs a concept h E 3 2 that with probability at least I- 6 satisfies error(h) 5 C. This probability is taken over the random examples re- $-;ed by EX(f, % and any internal randomization . We refer to h as the hypothesis of L, and we cull L a PAC learning algorithm for 3. Note that the hypothesis of the learning algorithm is “Probably Approximately Correct”, hence the name and acronym of the model. It will often be the case that the input space X and the class 3 have infinite cardinality, but are naturally parameterized by some complexity measure n. A typ- ical example is Xn = (0, 1)“) and 3,, is the class of all conjunctions of literals over the Boolean variables Now let X = UT-lX, and 3 = Ur?,Fn. %st&$?he asymptotic comgexity of learning &such cases, we allow the learning algorithm to also have a polynomial dependence on the smallest n such that f E 3n in the efficiency condition of Definition 1 above. C Learning with Hnclusion Testing Ideally, we would like to find PAC learning algorithms that meet the following additional criteria: if the learn- ing algorithm is run once using the oracle EX(fi, V) for fl E 3 to obtain the hypothesis hl E 3, and then run again independently using the oracle EX( f2, V) for f2 E 3 to obtain the hypothesis h2 E 3, then hl and h2 satisfy (with high probability) (1) hl 2. h2 if and only if fi > f2, and (2) h2 1 hl if and only if f2 ,> fi. Thus, we v&h to detect any%clusions that hold among pairs of target concepts by direct comparison of the hy- potheses output by a PAC learning algorithm. We will shortly see (Theorem 1) that this demand is actually too ambitious for even the simplest classes 3. We will then show that if we allow each run of the learning algorithm to output two hypothesis concepts, so that the run on EX(fi ,V) will result in a pair of concepts (hi, h:) E 3 )< 3, and the run on EX( f2, V) will result in a pair of concepts (hi, hs) E 3 x 3, then criteria equally useful to the conditions (1) and (2) above can be achieved. Looking ahead, the intuitive idea is to find two hypothesis concepts that are upper and lower bounds on the target concept with respect to generality (although this too turns out to be difficult, and our algorithm essentially “fakes” this method). There are two important points to be made regard- ing the model we have sketched. First, note that al- though the target concept changes from run to run of the learning algorithm, the underlying distribution V ‘A more standard definition allows h to be a member of a possibly more expressive hypothesis class ‘H 1 3. How- ever, the given definition suffices for the purposes of this paper. is the same for all runs. Since we think of V and rep- resenting the learner’s (fairly) constant environment, we find this invariance realistic and natural. For in- stance, it is reasonable to expect that the distribution on chairs used to train the learner is the same as the restriction of the distribution on furniture to chairs, and it can even be argued that this invariance is what makes detection of inclusions possible at all. It is also crucial to the results we present here. Second, notice that we have limited our attention to detecting inclusions only between pairs of concepts. This will be justified later in the paper, where we pro- vide several different methods of reconstructing an en- tire hierarchy (or more generally, a partial order) using only pairwise inclusion tests. egenerate Case of usion Before presenting our results, we first need to place a technical restriction on the pairs (fl, f2) for which we demand correct inclusion detection. Returning to our running example will best serve our purposes here: suppose that fi and f2 are overlapping axis-parallel rectangles in the real plane such that fi 2 f2 (thus f2 - fi # S), but V[fi - fi] = 0. Then the distribution of labeled examples generated by the oracle EX( f2, V) is identical to the distribution of labeled examples gen- erated by the oracle EX(fi’, V , where f2’ = fi n f2 1 (also an axis-parallel rectangle . Thus, the learning algorithm has no hope of distinguishing whether the target rectangle is f2 or f2’ (even given unbounded sampling and computation time), and the answer to inclusion tests with fi is different in each case. This motivates the following definition. Definition 2 Let fi and f2 be concepts from the class 3 over X, and let V be a distribution on X. For 0 < y < 3, we say that the pair (fi, f2) is y-fair (with respect to V) if the following two conditions hold: e either fi ,> f2 or D[f2 - fl] 1 27, and o either f2 1 fi or V[fi - f2] 2 2~. For the reasons given above, for the remainder of the paper we will restrict our attention to the problem of detecting inclusions between pairs of target concepts (fi, f2) that are c-fair, where E is the error input to the learning algorithm. 3 Notice that if we only consider c-fair pairs of tar- get concepts, there is a significant statistical separa- tion between inclusion and non-inclusion: for any tar- get concepts fi, f2 E 3, either fi 2 f2 (in which case V[f2 - fl] = 0) or V[fz - fl] 2 2~. This suggests that if we have perpetual access to the distribution V or ‘1 alternatively, are willing to store large random samp es from V), then we can detect inclusions simply on the basis of an appropriate statistical test. We can indeed prove that this is possible in a rather general sense. Such solutions violate the three conditions outlined in the Introduction and Motivation section. We will pro- ceed to describe algorithms avoiding such violations. 3We choose to make double use of E in this way only for simplicity. We could instead add a new input y to the learning algorithm, demanding that all pairs be y-fair and allowing the running time to depend polynomially on $. Kearns 217 PAC Algorithms Do Not Suffice The obvious approach to inclusion testing is the one we have already sketched: suppose L is a PAC learning algorithm. If L outputs a concept hi in response to training on fi, and L outputs a concept h2 in response to training on fi, then to determine if fi _> f2, just see if hl 2 h2. Earlier we showed that for a particular algorithm for PAC learning rectangles in the plane, this approach encounters difficulty. Our first result shows that this approach in fact fails for essentially any concept class and any PAC algorithm. Theorem 1 Let 3 be any class of concepts over X containing at least two concepts that are di$erent but not complementary. Then there is no PAC learning algorithm L for 3 meeting the following condition: For any D and any pair (fl, f2) E 3 x 3 that is e-fair with respect to D, if L is run using EX(fi,V) to obtain a hypothesis concept hl, and L is run using EX(fz,V) to obtain a hypothesis concept ha, then with probability at least 1 - 6, hl > h2 if and only if fi _> fi, and hz 1 hl if and only-if f:! ,> fi. Proof: Suppose for contradiction that L meets the stated condition. Let m(c, S) be the number of exam- ples drawn by L on inputs c and S. Without loss of generality (Haussler et al. 1991), we assume that L is deterministic. Let V be any fixed distribution on X. Fix the ac- curacy input E and the confidence input S < i, let = m(~, 6), and define the mapping GL v : 3 --f 2x E follows: for any f E 3 GL D(f) is the unique con- cept over X such that when L’is run with inputs c and 6 and access to oracle EX(f, D), the hypothesis con- cept h output satisfies h at least 1 - S. To see that = GL,?(f) with probability GL,P is well-defined, notice that if over two independent runs of L using oracle EX( f, ‘Do>, the probability exceeds S that the hypothe- ses hl and h2 output by L do not satisfy hl = h2, then the probability that (hl, h2) fails to meet the condi- tions of the theorem for the pair (f, f) exceeds 6. We now give a lemma proving that the output of L must remain constant under certain small perturba- tions of the target distribution. Lemma 2 Let x E X, let Vo be a distribution on X, and let VI be the distribution that is generated by drawing from V o with probability 1 - & and draw- ing x with probability k. Then for all f E 3, GL,df) = GL,Do(f). Proof: The probability that in m draws from VI all m points are drawn from VO is at least a. Thus the probability that L outputs a hypothesis concept h such that h = GLp,,(f) in m draws from EX(f,Vl) is at least f (1 - 26) = $ - 6 > S for S 5 $. This implies GL,df) = GL,df). (Lemma 2) Now let fi, f2 E 3 and x E X be such that x E f4f2 and X - fiAf2 is nonempty (these must exist by our assumptions on 3). Without loss of gen- erality, we will assume z E fi and x 6 f2. Let 230 be any distribution such that Vo[fiAf2] = 0. Note that with respect to such a distribution, fi and f2 are indistinguishable, so GL,D,,( fl) = GL,D,( f2). Assume without loss of generality that x E GL,DO(fi). Now construct a sequence of distributions VI, . . . , Vt such that for each 1 5 i 5 t, Vi is generated by draw- ing from Vi, 1 with probability 1 - &, and drawing z with probability &. Then by repeated applica- tion of Lemma 2, we obtain GL,p,(fi) = GL,DO(f2) = GLp,(fz) = . . . = GLp,(f& and thus x E GLp,(f& Thus the error of GL,p,(fz) with respect to f2 and Vt (which is just Vt[GL,n,( fs)A-t;]) is at least Vt[x] = & cf=,( 1 - &)i = 1 - (1 - &)t+l. This can be made as close to 1 as desired for t large enough, con- tradicting the claim that L is a learn Note that Theorem 1 holds even if the learning al- gorithm is given unbounded computation time. The ypothesis Method Theorem 1 shows that there is no hope of simply run- ning a PAC algorithm and hoping that direct com- parison (with respect to 2) of the independently com- puted hypothesis concepts will provide accurate inclu- sion testing. In this section we begin the description of our approach to providing inclusion testing in a PAC setting by computing two hypothesis concepts on each independent run, rather than a single hypothesis. We begin with a theorem proving that if inclusion fails to hold between a pair of e-fair target concepts, inclusion must also fail to hold for any e-good hypothe- ses. Theorem 3 Let fi and f2 be concepts over X satis- fying fi 2 f2, and let V be a distribution over X such that V[f2 - fi] 2 2~ (thus, (fl, f2) is e-fair with respect to V). If hl is a concept over X that is e-good with re- spect to fi and V, and h2 is a concept over X that is e-good with respect to f2 and V, then hl 2 ha. Proof: Suppose for contradiction that hl 1 h2. Then on each point x E (f2 - fl), either x E hlAf1 or x E hAf2, so V[fiAh]+V[f2Ahz] 2 V[fi-fl] 2 2~. Thus we must have either V[fiAhl] 2 c or V[fiAh,] c, a contradiction. 1 Theorem 3) Stated in the contrapositive, Theorem 3 tells us that if we can find any c-good hypothesis hl for fi and any c-good hypothesis h2 for f2 such that hl _> h2, then we may assert with confidence that fi > f2. This suggests the following approach to design&g learning algorithms that support inclusion testing in the PAC model: when training on a target concept f, rather than trying to find a single c-good hypothesis h, the learning algorithm should try to find many “different” hypotheses (h’, . . . , hk), each one c-good for f. Then given the hypothesis list (hi, . . . , hf) from a run on fi and the hypothesis list (hi,. . . , hi) from a run on f2, we assert that fi _> f2 if and only if for some 1 5 i, j 5 L, we have hf 2 hi. If all hypotheses are e-good with respect to the corresponding target, Theorem 3 guarantees that no false inclusions will be detected; it remains to determine conditions on the hypothesis lists that will guarantee that all true inclusions will 218 Learning: Theory be detected. We call this generic scheme the multiple hypothesis method. Theorem 1 proves that the Ic = 1 case of the multiple hypothesis method must always fail. We will shortly prove that for many concept classes of interest, the Ic = 2 case can be made to work. The intuition is that we would like to use two hy- pothesis concepts to upper and lower bound the target concept. Thus, when learning f we should find one c-good hypothesis h” that is more specific than f (that is, h” C_ f), and another c-good hypothesis hg that is more general than f (that is, hg ,> f). Our hypothesis list will then be (h”, hg). Note that if fi 2 f2, then we have hf ,> fl 2 f2 _> h& so the inclusion will be detected correctly by the comparison method for the lists (hi, hy ) and (h$, h;) g iven above. The hypotheses hS, and h; are not used to answer the test fi 2 f2, but are used for the test f2 _> fi. Unfortunately, for almost every class of interest (in- cluding all those mentioned in this paper) it is difficult to find one of h” and h 9. As an example of the diffi- culty, for Boolean conjunctions the set g(S) of maxi- mally general conjunctions consistent with a set S of positive and negative examples can grow expynentially in the number of variables (Haussler 1988). However, in the next section we show that for many concept classes, while it may be difficult to find a suit- able hg (or hS) we can nevertheless successfully simu- lute the above approach. The idea is to replace the idealized h” and hg described above with a “weak” hypothesis hwk and a “strong” hy- pothesis hst . The names are a reference to the number of examples used to obtain each hypothesis, as will be- come clear shortly. We think of h wk as playing the role of h”, and hst as playing the role of hg. As before, hwk will be more specific than the target concept f, that is hwk G f. In contrast to the idealized hg , however, hst will also obey hst C f. Thus, our hypothesis list (hwk, hSt) for f will consist of two overly specific hy- potheses. The key property we will guarantee is that if fi 2 f2, and we run our learning algorithm once using fi to obtain (hr”, hit) and again independently using f2 to obtain (hyk, hst), then with high probabil- ity hit _> hZJk. We now explain the intuition behind our algorithm’s computation of h,“” and hit. We return to the example of learning axis-parallel rectangles in the plane to illustrate our ideas. Suppose fi and f2 are rectangles such that fi 2 f2. Consider first the computation of hyk, when EX(f2, V) is the source of examples. Our algorithm will take a certain number m& of positive examples of f2 (where m,& is determined by the analysis), and set hy” be the most specific rectangle including all these positive examples 4Note that it is not enough to find any element of both the “lower version space” S(S) and the “upper version space” O(S) (Mitchell 1982); here we actually need to know that the chosen elements are truly more specific and more general than the target. (see Figure 1, where each * represents a positive exam- ple of f;! received by the algorithm during its compu- tation of h?Jk). For the analysis, consider the four rectangular sub- regions L,R,T and B of f2 that are respectively flush with the left, right, top and bottom of f2, as shown in Figure 1. Define these regions to each have weight exactly 5 ,&$ under the distribution V (thus they may have differing areas). We now wish to argue that L, R, T, B C (f2 - hYk), as shown in Figure 1; thus hyk has “missed” a “significant” part of f2 on all four sides, where by “significant” we mean weight td with respect to V. To see this, note that the probabil- ity that we hit L at least once in m& examples is at most (a = k. Thus the probability we fail to w ’ hit L is at least 1 - - , in which case L & (f2 - hyk). The same analysis o%!ously holds for the regions R,T _ - and B. --a- l f2 fll Figure 1. Now consider our algorithm’s independent compu- tation of hit, when EX(fi,V) is the source of exam- ples. With respect to correctly detecting the inclusion fl ,> f2, the intuitive goal of this computation is to hit all four of the subregions L,R,T and B of f2 de- fined above. Note that since each of the subregions has weight exactly (b under V, then if we take mst 23 (mwk)3 p osi ive examples of fi from V, then t with probability considerably greater than I- & we will have at least one hit in each of the four &bre- gions. Our hypothesis hit is the most specific rectan- gle including all the positive examples of fi. If all four subregions were hit on this run, and none of them were hit in the computation of hrk, then it is easily verified that hit 1 hyk, as desired. These two events occur si- multaneously with probability at least 1 - e, so for mwk large enough we detect the inclusion gith high probability. The informal analysis given here exploits the geom- etry of rectangles. In the following section we give our main algorithm, a generalization of the algorithm for rectangles, and state a theorem showing that it works under rather general circumstances, even when this ge- ometric intuition is absent. We emphasize that the sample sizes suggested here were for illustrative pur- poses only. The proposed algorithm is actually consid- ‘Distributions ZJ that defy such a definition are handled in the full proof; here we simply sketch the intuition. Kearns 219 erably more efficient, and can be further improved as will be shown in a later section. The ain Algorithm We first develop the necessary definitions and machin- ery for our algorithm. Let 3 be any class of concepts over X, and let S C X be any set of positive exam- ples of f E 3. Then we define minF(S) to be the unique most specific concept in 3 that includes the set S - that is, minF(S) is the concept f' E 3 sat- isfying f’ ,> S, and for any f” E 3 such that f" 2 S we have f” > f’. If no such f’ exists, then minF(S) is undefined. There is a characterization of the classes for which minF(S) is always defined due to (Natarajan 1987). We say that 3 is closed under intersection if for any fi,,f2 E3we have finf2 ~3. Theorem 4 (Natarajan 1987) Let 3 be a concept class over X. Then minF(S) is defined for every set S of positive examples of any f E 3 if and only if 3 is closed under intersection, and furthermore we have minm = nftEF,f13S ft. We next define the well-known Vupnik-Chervonenkis dimension of a class 3. Definition 3 Let 3 be a concept class over X and let S be a finite subset of X. Then S is shattered by 3 if l{f n s : f E 3}/ = 2w Definition 4 Let 3 be a concept class. The Vapnik- Chervonenkis (VC) d imension of 3 is the largest in- teger d such that there exists a set S of cardinality d that is shattered by 3. If no such d exists, the VC dimension is infinite. Our algorithm is defined for any class 3 that is closed under intersection and has finite VC dimension, and is given below. Main Algorithm: 1. Take ?nvrk = 0( $ log i) random examples of the unknown target function f E 3 from the oracle EX( f, V), where d is the VC dimension of 3. Ig- nore the negative examples received, and let Swk be the set of positive examples received. 2. Compute hwk = minF(S”“). 3. Take m,t = 0( $ log2 i) additional random exam- ples from EX(f,V), and let SSt be the set of positive examples received. 4. Compute hst = minF(Swk U Sst). 5. Output (hwk, hst). Recall our method for answering an inclusion test for targets fi, f2 E 3: if the algorithm is run once using target concept fi and outputs (hpk, hit), and run independently using target concept f2 and outputs (hJJk, hst), then we assert that fi _> f2 if and only if hit 1 hyk wk , and assert that f2 _> fi if and only if list > h 2- 1. The central theorem we give is the following: Theorem 5 Let 3 be any concept class over X that is closed under intersection and has VC dimension d. Let V be any distribution over X, and let (fl, f2) E 3 x 3 be e-fair with respect to V. Then if the Main Algorithm is run once using oracle EX( fi , V) and again indepen- dently using oracle EX(fz,V), then with probability at least 1 - 6, we have e (Learning) hpk and hit will both be e-good with re- spect to fi and V, and hyk and hGt will both be e-good with respect to f2 and V, and e (Inclusion Testing) hit > hTk if and only if fi _> f2, and Qt _> hyk if and only if f2 _> fi. Furthermore, if minF(S) can always be computed in time polynomial in ISI, then the Main Algorithm runs in time polynomial in :, i and d. Proof: (Outline) The details of the proof are omit- ted; here we simply sketch the main ideas. That all four hypotheses are c-good for their corresponding tar- gets follows from a standard PAC analysis; see (Blumer et al. 1989). That no false inclusions will be detected follows immediately from Theorem 3. To show that a true inclusion fi _> f2 will be detected, we argue in two steps. First, we must show that the region f2 -hit will have such small weight under V that m,& exam- ples from V are unlikely to hit the region. This can be shown with a VC dimension analysis using tools of (Blumer et al. 1989), and a simple probabilistic argu- ment. Second, given that the r&k examples drawn to compute hyk miss the region fl - hst, we must show hTk C hit. This follows from the fact that 3 is closed under intersection. Theorem 5) Note that the Main Algorithm requires only posi- tive examples. There is a straightforward dual to the algorithm that uses only negative examples (in order to find weak and strong maximally general hypothe- ses) that is provably correct for any class closed under union. Comments and We begin by noting that our Main Algorithm meets the three conditions given in the Introduction and Motiva- tion section in the strongest possible sense. Oblivious- ness follows immediately from the fact that each run of the Main Algorithm uses examples of only a sin- gle target concept, and is statistically independent of all other runs. The pool of hypothesis pairs (hyk, hft) clearly form a closed system since we need only con- sult the two pairs corresponding to target concepts fi and fj to determine the relationship between fi and fj. The hypothesis pairs are the most succinct representa- tion we could possibly hope for in light of Theorem 1. It is well-known that minF(S) can be efficiently computed for the classes of axis-parallel rectangles in n dimensions (Blumer et al. 1989)) conj unc- tions of Boolean literals and k-CNF formulae over the n-dimensional hypercube (Valiant 1984), and sub- spaces of certain n-dimensional vector spaces (Helm- bold, Sloan and Warmuth 1990). To all of these classes we may immediately apply the Main Algorithm and obtain an algorithm running in time polynomial in $, 220 Learning: Theory i and n, thus providing reliable inclusion testing. The same holds for the dual algorithm for the dual classes. The time and sample complexity of the Main Algo- rithm are dominated by the strong sample size m,t. In this section we describe a method that applies only to certain classes, but greatly reduces m,t and hence the complexity of our algorithm. We again illustrate the main idea using the example of axis-parallel rectangles in the plane. Recall that if we have rectangles fi 2 fi, then the goal in computing hi’ is to hit all four of the regions L, R,T and B ( see Figure l), where each of these four regions had a certain small but significant weight p (where p = &) under 23. The key observation ys if we can somehow make p larger while still forcing all four regions to be con- tained in f2 - hyk, then we can make m,t smaller, since the regions we are trying to hit now have larger weight under 2). To do this, we modify the compu- tation of the weak hypothesis for our Main Algorithm (described here for the target fz) as follows: starting with h,W” = min~(S”~) where Swk is the set of positive examples, we “squeeze in” each side of h$‘” until a frac- tion 5 of the examples are misclassified on each side (see Figure 2). Note that we are essentially setting h yk = mini for an appropriately chosen subset S’ 5 SWk. Since this results in only 5 of the examples being misclassified by hyk, it is easy to show that hyk is still r-good for f2. Now, however, we may define the regions L,R,T and B so that they have weight p = 5. This turns out to be considerably larger than the pre- vious value for p, and allows the computation of hit in the Main Algorithm (which is left unmodified except for the new sample size) to take only mSt = O(mwk) examples. -w-m w--w *; L i *I I I- -w- -------?L-----ea------ 1 I 1 I I I B I 1 I f2 I fll Figure 2. This modified algorithm is easily generalized to work for the classes of n-dimensional axis-parallel rectan- gles and conjunctions of Boolean literals over the n- dimensional hypercube. In these cases the required sample sizes now become r&k = o(? log f) and mSt = O(? log $), so mSt = O(m,k), and in fact both runs have the optimal number of examples required for stan- dard PAC learning. Recorastructing a ieraschy of Ccmcepts So far we have limited our attention to detecting in- clusions between any pair of target concepts. In this section we give methods for reconstructing an entire inclusion hierarchy of target concepts using pairwise inclusion tests among the hypotheses. Suppose that our Main Algorithm will be called 2 times on target concepts fi, . . . , fl. Then if we set the confidence input on each run to be b, where 6 is the overall confidence we wish to achieve, it is easy to show that with probability at least 1 - S, the inclusion tests between any two hypothesis pairs (hi”‘“, hgtj and (hj”“, hjt) will correctly determine the inclusion rela- tionship between fi and fj. We have a number of significant improvements to this method that we now describe. First of all, the method as stated has an undesirable dependence on 1. In many cases we may not know the value of 1 in ad- vance. We can in fact give an “on-line” version of this method: if the Main Algorithm is run on a sequence of target concepts fi, . . . ,fi,. . . of unknown length, then for any value of i the ith run of the algorithm takes time polynomial in i (and the other usual parameters). The simple trick used is to divide up the confidence param- eter S grudually over the runs (using an appropriate decreasing sequence such as &), rather than allot- ting an equal portion of 6 as is done above. We can also give a reconstruction method in which each run of the Main Algorithm takes time polynomial in the hierarchy depth instead of the size. Following any of these methods, we can also implic- itly propagate positive examples upwards through the hierarchy in a useful way. The basic idea is most easily illustrated for the case of Boolean conjunctions of lit- erals. Suppose that our algorithm has output two hy- pothesis conjunction pairs (hyk, hit) and (hyk, h;t) for unknown target conjunctions fi and f2, and we guess that fl _> f2 because hit _> h?fk. Then assuming this guess is correct, we can do the following: if the variable ~i does not appear in hst then we are safe in deleting si from Ihit (we will refer to the resulting conjunction as the modified strong conjunction for fi). The reason for this is that if fi _> f2, pi was deleted from hit due to a positive example of f2 in which zi = 0. Since this is also a positive example of fi , the deletion is justified in hit as well. Thus, starting from the bottom of the hierarchy, we propagate all deletions in the strong conjunction of a node upwards to the strong conjunction of the node’s parent, to obtain modified strong conjunctions for all nodes except the leaves. This method has two advan- tages: first, propagating the deletions upwards results in modified strong conjunctions of greater accuracy; and second, the concept represented by the modified strong conjunction of any node will actually be a sub- set of the concept represented by the modified strong conjunction of that node’s parent. This provides an interesting contrast to Theorem 1, which essentially shows that directly obtaining such conjunctions as the output of the learning algorithm is impossible. Here we have shown that such conjunctions can be constructed once all hypothesis pairs are available. This same method applies to the Main Algorithm: the operation that is analogous to propagating dele- Kearns 223. tions upwards is simply letting the modified strong hy- pothesis for fl be the most specific representation h in J= that satisfies h 1 hit U hst. Such an h is guaranteed to exist since r is closed under intersection. 6 Detecting More Complex Implications Consider the following straightforward reformulation of the inclusion testing problem as a limited type of logical inference using learned representations: after (independent) training on target concepts fi and fj, we would like to use the hypothesis representations Q and Tj output by a learning algorithm to determine the validity of logical assertions of the form fi =+ fj (short- hand for (Vz E X)[fi are thinking of fi z) = 1 j fi (z) = 11). Here we an 6 fj as logical predicates whose exact description is inaccessible, and only the learned hypothesis representations may be used to determine the validity of the assertion. This reformulation nat- urally leads us to ask if more complex assertions can also be accurately validated using the methods we have presented. Here we briefly sketch the possibilities and apparent limitations in this direction. For instance, consider formulae of the form (Vf=lfi) + fj. S UC a h f ormula is valid if and only if we have fi E fj for all 1 < i 5 k, so we can use the hy- pothesis pairs ( hyk, hft) (from independent runs of the Main Algorithm) to guess that (Vi”=, fi) a fj is valid if and only if we have hyk C hj” for all 1 5 i 5 k. It is easy to prove that under our assumption that the tar- get functions are pairwise c-fair with respect to V, this test will with high probability give the correct result for any class F meeting the conditions of Theorem 5. For similar reasons, we can determine the validity of fj a (/\FZ1 fi) by checking that we have hi”” C hft for all 1 5 i 5 k. A more subtle example is formulae of the form fj + (Vf==,fi). When the targets are drawn from a class F that is closed under intersection, if such a formula is valid we will have (with high probability) hrk n fi c hft for each 1 5 i < k, since hi”” n fi E F. From this we obtain uhl(hrknfi) E Ufllhft, or equiv- alently hyk n (Ufzl fi) z $, hft. Since hrk n (uf=, fi) is equivalent to hrk whenever fj E (Uf=, fi) (because hi”” E fj always), this means we can test the validity of the formula by checking that hi”” E (Uf=, hit). The formula type (A;= 1 fi) + 1’ is one for which there is no apparent method for using our Main Algo- rithm’s hypothesis pairs to determine validity. Thus it is worth emphasizing that the ability to detect sim- ple implications using learned representations does not automatically imply the ability to perform general in- ference - although our methods handle a number of 61n order to safely apply this method, it is crucial that all pairs of target representations in the hierarchy be r-fair. Otherwise, our algorithm may detect false inclusions, in which case the upward propagation is unjustified and may result in modified strong hypotheses with large error with respect to ‘D. formula types, they fail on others, and in general we must expect that different hypothesis representations may support or omit various assertion types. Other Results and Conclusion Our Main Algorithm can be modified to apply to some settings in which minF(S) may not be defined. We can give algorithms that provide accurate inclusion testing for conjunctions of Boolean literals even in the pres- ence of a large rate of classification noise (based on a PAC algorithm due to (Angluin and Laird 1988)), and accurate inclusion testing for monotone DNF formula in the PAC model with membership queries (based on an algorithm due to (Angluin 1988)). We also have results on applying our methods to detect the validity of formulae in mixed logic, where we allow both target function symbols fi, and exact descriptions of defined concepts. An example of such a formula is fi 3 (fj V ~r?Es~s). Here fi and fj are target functions whose exact descriptions are Boolean conjunctions (but which we can reason about only via learned hypothesis representations), and ziZs25 is the exact description of a conjunction over the same vari- able set. In conclusion, in this paper we have introduced a new model for studying the detection of inclusions be- tween independently learned target concepts, and have given an algorithm in this model that is efficient, uses minimal shared information between runs, and has op- timally succinct hypothesis representations. Acknowledgements I would like to give warm thanks to Umesh Vazirani for collaborating in the early stages of this research. I am also grateful to William Cohen, John Denker, Wenry Kautz, Rob Schapire and Bart Selman for enjoyable conversations on this material. References D. Angluin. Queries and concept learning. Machine Learning, 2:319-342, 1988. D. Angluin and P. Laird. Learning from noisy examples. Machine Learning, 2~343-370, 1988. A. Blumer, A. Ehrenfeucht, D. Haussler, and M. K. War- muth. Learnability and the Vapnik-Chervonenkis dimen- sion. JA CM, 36(4):929-965, 1989. D. Haussler, M. Kearns, N. Littlestone, and M. K. War- muth. Equivalence of models for polynomial learnability. Information and Computation, 95(2):129-161, 1991. D. Helmbold, R. Sloan, and M. Warmuth. Learning in- teger lattices. In Proceedings of the 1990 Workshop on Computational Learning Theory, pages 288-300, San Ma- teo, CA, 1990. Morgan Kaufmann publisher. Also to ap- pear in SIAM J. on Computing. T. M. Mitchell. Generalization as search. Art. Intell., l&203-226, 1982. B. K. Natarajan. On learning boolean functions. In Pro- ceedings of the Nineteenth Annual ACM Symposium on Theory of Computing, pages 296-304, New York, New York, May 1987. L. G. Valiant. A theory of the learnable. Comm. ACM, 27(11):1134-42, 1984. 222 Learning: Theory | 1992 | 49 |
1,242 | Computer Science Department 9 Hebrew University Givat Ram, Jerusalem, Israel tantush@cs.huji.ac.il, jeff@cs.huji.ac.il Abstract In this paper we analyze a particular model of con- trol among intelligent agents, that of non-absolute control. Non-absolute control involves a “supervi- sor” agent that issues orders to a “subordinate” agent. An example might be a human agent on Earth directing the activities of a Mars-based semi-autonomous vehicle. Both agents operate with essentially the same goals. The subordinate agent, however, is as- sumed to have access to some information that the supervisor does not have. The agent is thus expected to exercise its judgment in following or- ders (i.e., following the true intent of the super- visor, to the best of its ability). After presenting our model, we discuss the planning problem: how would a subordinate agent choose among alterna- tive plans? Our solutions focus on evaluating the distance between candidate plans. Introduction Imagine that you have sent your robot Explorer to ana- lyze the Martian surface. Though your communication with him is limited, you are able, from time to time, to send him general goals, such as “Get a soil sample from Region A.” Explorer is an obedient robot, but after failing to hear from him for some time, you ask why there’s been a delay in retrieving the soil. Ex- plorer informs you that because there is a large valley between his current location and Region A (a valley of which you, his master, had been unaware), he has be- gun construction of a small plane to fly over the valley. In truth, getting the soil sample wasn’t that important to you. Had you known the cost of Explorer’s plan to accomplish your goal, you would have been willing to have him get a sample from Region B. Explorer knew that you didn’t know about the valley, so he could have reasoned that your plan for the soil collection was much simpler than his. If only he had had the intelligence to inform you of the discrepancy! On another occasion, you tell Explorer to move to Region C. While you believe he is able to do this using a particular route, he knows of two alternative short- cuts. Each shortcut will have side effects (one route may pollute the only well of water in the region and the second route might cause damage to his photoelec- tric cells). By what criteria should Explorer plan his travels, given his knowledge of your goals? Multi-Agent Planning Research on planning in Distributed Artificial Intel- ligence (DAI) h as focused on two major paradigms: planning for multiple agents and distributed problem solving. In the first paradigm, a single intelligent agent (the “master”) constructs a plan to be carried out by a group of agents (the “slaves”), then hands out pieces of the plan to the relevant individuals [Rosenschein, 1982; Konolige, 1982; Lesser, 1987; Katz and Rosenschein, 19921. In the second paradigm, a group of intelli- gent agents jointly construct the final plan, and subse- quently cooperate in carrying it out [Genesereth et al., 1986; Durfee and Lesser, 19871. In the master-slave model, the slave follows the ex- act detailed orders of the master. It has no interests of its own, and does not attempt to reason about the master’s knowledge or plans. In the second model, all agents may share equally in control and decision mak- ing. Each agent might have its own goals and control its own actions. To promote its interests, each can reason about other agents’ knowledge and goals. In some scenarios, agents have conflicting goals, negoti- ate, and compete over resources [Kraus et al., 1991; Zlotkin and Rosenschein, 19911. We are interested in that important family of scenar- ios in which the control method combines both aspects. In these scenarios, there are supervising and supervised agents, where the control of a supervising agent over the supervised one is non-absolute. Such a hierarchy is typically exhibited in organizations with a pyramid structure, but also characterizes all other situations in which the supervised agent is expected to show some intelligence. We will refer to the supervising agent as the “supervisor ,‘? and to the supervised agent simply as the “agent.” Ephrati and Rosenschein 263 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. The supervisor's view The goal The agent’s “lew Determining Plan Deviation We are concerned with the following possible control relationships between the supervisor and the agent: The supervisor generates and sends the agent a com- plete plan; The supervisor does not (or cannot) generate a com- plete plan, but generates and sends the agent a par- tial (abstract) plan; The supervisor has not generated a complete (or par- tial) plan, or perhaps has generated it but cannot send it because of constraints on communication. In- stead, the supervisor sends a high-level goal. Given a complete plan, the agent should in princi- ple follow it, but this may not be possible or desirable if the supervisor’s model of the world is faulty. Thus, even in this situation, or when the agent has been given a partial plan or a goal, the agent is expected to gen- erate a complete plan based on its own, more accurate knowledge. The agent’s complete plan should not differ radically from the supervisor’s specified plan, or (if no complete plan was specified), what the agent predicts the supervisor would have generated as a plan. The intuition is that if the world does not differ greatly from what the supervisor believes, and if the agent’s model of the supervisor’s beliefs is accurate, the plans they generate will also not differ greatly. If there is sufficient deviation between their plans, then some- one’s model is wrong, and some action should probably be taken (e.g., communicate). This is true when the the agent’s plan is much “better” than the supervisor’s plan, and when it is much “worse;” in both cases, some realignment may be necessary. Thus, we are concerned with measuring the distance between plans. Note that we consider plan deviation among correct plans; even though they all achieve the goal, some are more suitable than others. We are concerned with more than just having a plan to achieve a goal-we are concerned with the structure of the resulting cor- rect plan. The main research issues of concern in these situ- ations are reasoning about knowledge, nonmonotonic reasoning, shared knowledge and knowledge revision, communication, and planning. In this paper, we limit ourselves to issues of planning. A Blocks World Example Consider a scenario in the slotted blocks world as de- scribed in Figure 1. This example will be used several times in the paper. The domain is described by the following predicates: Blocks(n) - The total number of blocks in the world; Stacked(bZock1, block2, slot) - block1 is on top of bdock2, and located at slot (if block1 is on the table, block2 and slot are identical); At(s) - The agent is at slot s. The domain oper- ators are: GO(Q) sj) - The agent goes from si to sj; Carry(b, si, sj) - Agent carries block b from si Figure I: A scenario in the slotted blocks world to sj ; Paint(b) color) - Agent paints block b a par- ticular color; Destroy(b) - Agent destroys block b; Create(b) - Agent creates a new block b. In the initial state the agent believes the supervisor’s knowledge of the world to be described by: {Blocks(S), Stucked(B, ~1, sl),l At(sz), Stacked(W, ~3, sg), Stucked(B, s5, ~5)). The agent’s own knowledge of the world is: {Bbocks(4), Stacked(B) ~1, sl), At(q), Stacked(W, ~3, SQ), Stacked(W) W, ~3)) Stacked(B) ~5, ~5)). Given only the supervisor’s goal, {Stucked(W, s3, s3), Stucked(B, r/v, ss)}, the agent must decide which of the many alternative plans for achieving the goal he should carry out. Assumptions and Definitions The agent keeps a model of the supervisor’s knowl- edge base (KB) concerning the domain that the agent operates in, and updates it during the interac- tion. This model may in fact differ from the actual view of the domain held by the supervisor. The goal G is a set of predicates that might be given by the supervisor to the agent. SC are the states of the world in which G holds; we use SG to stand for any state in SG. An agent u’s plan P(u, sg,sE) (denoted by P”) is a set of consecutive operations: [opp, op;, . . . , op:], that brings about sz starting from the initial state sg. The set of all such alternative plans is pa. Each operation of a plan P transforms the world from one state into another [se, ~1,. . . , sn+i] (such that s,+l = SG). Given a cost function (C: OP --+ R) over the do- main’s operators [Finger, 19861, we define the cost of a plan C(P) to be xi=, C(opk). Based on a comparison with the supervisor’s com- plete plan (either transmitted, or generated by the agent from a goal or partial plan using his model of the supervisor’s knowledge base), the agent has to choose one plan from pa. In fact, the generation of the plans in Pa can themselves be guided by the supervisor’s nlan Ps, and the entire set Pa may not need to be explicitly generated. Assume the following cost function over the op- erators of our example: C(Go(si, sj )) = ] i - j 1, C(Curry(b, si, sj)) = 2* 1 i - j 1, C(Puint(b, color)) = ‘B refers to any Black block, W to any White one. 264 Multi-Agent Coordination 6 if color is Black and 8 if it is White, C(Destroy(b)) = 3 and C(Creute(b)) = 18. In the example of Figure 1, the assumed supervi- sor’s plan is (Go(s2, sl), Curry(B, ~1, ~3)) (cost5). The agent is faced with choosing one of the following alter- native plans (for simplicity, we ignore some other pos- sibilities): P; = (Go(+, s3), Puint(W, Bluck)){cost7} P; = (Go(s4, SQ), Destroy(W), Go(s3, sg), Curry(B, s5, ss)){costlO} P3a = (Go( sq, s3 >, Destroy(W), GO(SQ, ~1)) Curry(R, sl, ss))(costlO} P4” = (GO(Sq ) s3 >, Cu~r~(w,s3,s4), Go(s4,s5), Curry(B) s~,s~)){cos~~} Ps” = (Go(s4, .s3 >, Curv(W s3,4, G+z, sl), Curry( B, s1 , ~3)) { cost8). What follows are some plausible criteria for mea- suring distances between plans. Although we refer here to the entire plan, it may be possible to take into consideration abstract plans (i.e., to measure plan distances at higher levels of abstraction, incompletely specified [Chapman, 1987]), so as to reduce the com- putational complexity. Comparing Outcomes and Costs One way of evaluating the distance between plans is to take into consideration only the final outcome of a plan or its overall cost. The following are three alternative ways of doing so: (1) Comparing the cost of plans generated by the agent to the cost of the supervisor’s plan: One method of comparison would be to consider only the cost of each plan, regardless of its actual steps or side effects. Such a consideration suggests the following cost metric: O,(Pl,P2) =I c(e) - C(P2) I * Under certain circumstances, it might be satisfactory to choose the plan that minimizes the cost difference from the supervisor’s (assumed) plan, or any plan such that D,(P, P”) d oes not exceed a freedom threshold parameter T,. Using the cost function given above, we get the following distance values: D,(PF, P”) = 2, D@-f, P”) = 5) D,(P& P”) = 5) D,(P&PS) 4 3) Dc(Pt, P”) = 3. With the criterion of cost difference minimization, PT would be chosen. (2) Comparing the deviation of the KBs: The freedom the agent has in generating plans may lead to some unpredicted side effects, and there is the po- tential that these side effects are undesirable from the supervisor’s point of view. One symptom of such side effects is deviation between the supervisor and agent KBs. An intuitive solution is, therefore, to have the agent choose actions so as to minimize KB deviation. One method of evaluating the distance between KBs is to consider the cost of the plan that would trans- form one into the other. Using this criterion, the agent might be expected to minimize (or bound to TO) the following “outcome metric”: DO(Pa, P”) = max(C(P(u, sz, sk)), C(P(s, s&, s$))) Applying the outcome metric to the example we get the following values: D,(P,“, P”) = 22, D,(Pc, P”) = 0) D,(P,“) P”) = 12, D,(P,d, P”) = 32, D,(P,“, P”) = 20. PC minimizes KB deviation. For example, the goal state that is created by Pp differs from the one that is generated by P” by {Blacks(4), Stucked( B, ~1, sl)>. The plan that transforms the world from the agent’s actual goal state to the supervisor’s presumed goal state is (Go(s3, si), Destroy(B), Go(q) ss)){cost7}. The plan that transforms the world from the super- visor’s presumed goal state to the agent’s actual goal state is (GO(Q) sl), Create(B), Go(q) s3))(cost22}. Thus, the cost of the more expensive plan is 22. A more sophisticated outcome metric would distin- guish between differences caused by the plan, and dif- ferences that preceded plan execution. In the example above, there was already a difference in the number of blocks in the world prior to the plan’s execution, and the outcome metric should perhaps not consider the variation in number of blocks at plan’s end. (3) Avoiding irreversible consequences: The so- lution presented above might not always be compatible with the kind of intelligence we would like the agent to exhibit. Consider a user (the supervisor) ordering “rm "/pub/*" to an intelligent UNIX operating sys- tem agent (the agent) [Finger, 19861. If the agent is aware that the user does not know about the existence of some files in his /pub directory, we would like it to warn the user, although the deletion of all files in this case would actually bring the two KBs closer. Situations can thus occur where the KBs get closer, but there is a loss of resources known only to the agent. Therefore, we want to prevent the agent from changing important parts of the world that are not known to the supervisor (SE - SC). This could be done by bounding the cost of the plan needed to recreate the resources: C,(P”, P”) = C(P(U) s;, so” - si)). Notice that this constraint can be integrated into the cost metric if the cost of an operation reflects the cost of reversing it. This is not, however, always desirable since (for instance) we would not want the rm opera- tion to be very expensive under all circumstances. In our example, the difference between the two knowledge bases is: { Blocksc4), At (4)) Stucked( W, W, ~3)). Therefore CT(Pf) P”) = 9) Cp(P& P”) = 22) CT(P& P”) = 22, C,.(Pt, P”) = 7, C,.(Pt, P”) = 7. For instance, to restore his exclusive knowledge from the final state of Pr, the agent would perform (Paint (I?, White), Go(s3, s4)). Starting at the final state of PC, the agent would perform (Curry(B) ~3, sz), Go(s2, ~3)) Create(W), Go(ss,+)). P: and Pt minimize the cost needed to recreate resources. Ephrat i and Rosenschein 265 Distance Between Sets of States Above, we treated each plan as a single, indivisible unit. Alternatively, we could take into consideration in our evaluation each step of a plan, and the correspond- ing state to which it leads. These states can be used to measure distance between the plans. We associate with two plans (PI, Pz) th eir corresponding sets of states (SPl , Sp2). Figure 2 shows the corresponding sets of states of Pf, Pz, Pt and P’. Assuming the existence of a distance metric between two states n(s,, ~2) (see the following section), the agent could make geometric measurements of distance between sets of points ade- quate for measuring the difference between two plans. Here are three plausible metrics between sets of points. p; El ih El El El El Ed El El Eil ki q i ----- ----- -_--- ----- ----- Figure 2: Sets of states corresponding to plans (1) The Hausdorff metric: One way of measur- ing inter-plan distance is to choose one “representa- tive” state from each plan, and consider their dis- tance. Above, for example, we considered the plans’ final states to be representative. Other alternatives might be to take the plans’ maximally distant states (or minimally distant) as representative, or the two “centers of gravity” of both plans. The Hausdorff metric is also based on the dis- tance between a representative state from each plan. This metric is used in the field of image processing to measure the distance between two shapes [Atal- lah, 1983; Arkin et al., 19901. Taking the state in the first set that is closest to any state in the sec- ond set, one measures the distance between this state in the first set and the furthest state in the sec- ond set. Doing this in both directions (both plans as the first set), one takes the maximal distance: H,,,(S” ) S”) = max(k(Ss, S’), h(S”, S’)), where W, B) = max,EA rninbEB d(a, b). It may be prefer- able at times to use the sum, H,,,, of the h metrics. Assume that the inter-state metric returns the fol- lowing distance values between each of the states in the supervisor’s plan, and each of the states in the agents’ plans (as described in Figure 2). For simplicity, we look at only three agent plans: (~“0 --> ((5>4,4), (5,4, L3,5), (5,4,3,4,8)),2 (4 --> U&5,5), (6,5,2,4,6), (6,5,4,3, g)), (s; --> ((3,7,3), (3,7,4,6,3>, (3,7,3,9,3)). These values yield HSU,(SP”, Spp) = 10, HsUm(SPS, SpT) = 9, HJUm(SPS, Spt) = 8. Pt mini- mizes the Hausdorff metric. (2) The “Shifting” distance: This measurement considers the overall differences between two plans. The measurement is done by summing the distance of each state in one plan from the set of states in the other. Defining the distance between one state and a set of states to be D(s’, S) = minsES d(s’, s), we get the distance between one set of states and another to be the total shifts needed for merging this set with the other: Sh(S”, 9) = x qs, Y). SES” The distance between the sets can be defined by the min, the mux, or, more informatively, the summa- tion of (Sh(Sa, S’), Sh(S”, S’)). As with the use of an “outcome metric,” this measurement suffers from the fact that as the states converge the distance gets smaller, even though important data may be lost. Following the values given in the example above, we get: Shs,,(SPs, SpF) = 24, Shs,,(Sps, ,S@t) = 25, S11,,, (SPS ) SPt) = 27. PF minimizes the Shifting Distance metric. (3) The “Dynamic deviation” distance: This metric considers the sequential order in which the states of each plan were generated. Let Ss = -i s&s;, . . .) sk} and S” = {ss, s;“, . . . , sz}. Assuming (without loss of generality) that m = min(m, n), we define the distance between the plans to be the sum- mation of the sequential relative deviations produced by operators of each plan: m Ds(SU, SS) = c qsq, sf) + 2 qsq, s;>. i=l i=m Referring to the example, this metric yields: Ds(Sp* , sp: ) = 13, Ds(Sps, Spz) = 28, Ds(Sps, Sp,“) = 30. The deviation metric captures, in a sense, the “di- rection” of the deviation (i.e., whether it is growing or shrinking). The deviation metric’s advantage with respect to the other two metrics is its relatively easy computation and the fact that it can dynamically guide search. Using the Hausdorff metric, on the other hand, is preferable when we are concerned only in prevent- ing the agent from radical exceptions to the supervi- sor’s intended plan, while not being bothered by many small variations. A computational advantage of the Hausdorff metric is that it can better constrain the generation of a plan dynamically, since it considers only one member of S” while the Shifting measurement 2The notation compares the distance between the first state of the supervisor’s plan, SO, and the 3 states in PF, the 5 states in Pg, and the 5 states in Pt. 266 Multi-Agent Coordination takes all of them into account. The Shifting metric, on the other hand, is suitable when the overall distance from the intended plan (whether caused by one dras- tic change or many small ones) is of importance. All these metrics (or their variations) may be taken into ac- count in accordance with different freedom parameters. For example, using the Hausdorff metric, if our agent plans “forward” and follows the “best first” strategy, after generating the first two states of the three plans it would choose pz and will not find it necessary to further explore the’ two other alternatives. etric etween States Our techniques above depended on our being able to provide a distance metric between states. There are several sensible ways to define such a distance metric, and the following are some basic ideas. Any of the following state metrics can be used as part of any of the plan-metrics mentioned above. - (1) Distance between predicates: Since we con- sider each state to be described by a set of predicates, a straightforward metric can be generated by the sum- mation of the differences between conflicting predicates of the two states in question.3 As consider two states that differ only -~ a trivial example, by the location of one object (obj). The definition -D@(At(obj, 21, yl), M-6 32, ~2)) = J I Xl - 332 1 + 1 yl - y2 1 is suffi- cient to serve as a distance metric between these states. This method can be refined by giving different weights to su ch metrics in accordance with some special consid- erations. For example, if there is a dangerous region in the agent’s operating domain the above metric should be given a higher weight if (22, ~2) E DungerSet. In that case the location might be used to change the weight of other differences such as Dii$(Armed(obj), UnArmed( obj)). The values that were used as the metric between states in the previous examples followed the follow- ing rough definitions (based on the cheapest operation that can eliminate the difference): Difl(Blocks(nl), BEocks(n2)) = 3* 1 nl - n2 I, Difl(At(si), At(sj)) = 1 i - j I, Di#(Stacked(b, I 2* 1 i-j I. OC, Si), Stacked(b, ZOC, Sj)) = (2) Considering ultimate goals: A more mean- ingful metric might consider either the agent’s or the supervisor’s global goals (or both). For example, if one of the supervisor’s global g&s is Abo&(objl , objs) and both states satisfy Stacked(objs, obj2), we would like Oifl( Stucked(objl, objg), Stucked(objl, objq)) to return a higher value than, for instance Oifl( StacLed(objl , objg), Stucked(objl , objd)). Global goals can be given at a higher level of abstraction, such as “minobjEU.S.Navy In(obj, Iruq) .” The fact that such ul- 3This is related to the measures (such as cardinality of sets) proposed by Ginsberg for evaluating distance be- tween possible worlds in his research on counterfactual planning [Ciinsberg, 19861. timate goals can be from different sources (i.e., from the supervisor and agent) allows the consideration of subjective points of view (with respect to these sources) and thus enriches the overall control mech- anism. If the supervisor of the example had as a global goal the maximization of the number of blocks in the state, we would not like PF or Pi to be consid- ered. This may be done by giving a very high value to Difl(Blocks(nl), Blocks(n2)). (3) Using the domain operators: Another possibil- ity is to measure the deviation of two states with regard to the operators that generated them. When compar- ing two states, the metric will be based on how the current state was reached, with particular operators considered to cause greater variations than others. For example, we might define Difl(Go(si, sj),Go(sk , sr>) = I Sj - sl I to reflect the deviation or convergence caused by following these two operations. This mea- sure is most appropriate for use with the sequen- tial deviation metric (D,). In the example, defining D$(Curry(b, si, sj), Puint(b, c)) > 20 would make J’F inferior to all other plans according to all the suggested metrics. (4) Considering the plan that unifies the two states: According to this approach, the metric be- tween any two states is defined by the plan needed to bring about the differing predicates of one state start- ing from the other: W(Sl, s2) = max(P*(sl, sa), P*(s2, sr)), where p*(a) s2) =minp P(u, sr , ~2) (the minimization cri- terion may be the cost of the plan or just the number of operations). A further consid- eration might also be to take into account the perspective of the supervisor: w7+1, s2) = max(P,*(sl, 4, p&t, SI), ps*(sl, Q),~(sz, ~1)). No- tice that the use of such a metric makes the outcome metric (i.e., bounding KB deviation) redundant. All of the distance computations above may be costly to perform directly, but the calculation of dis- tance between sets need not use a single distance func- tion uniformly. For example, one might use a (rel- atively cheap) approximate distance function to map states into an n-dimensional geometric space. Only then would one use the states’ approximate “locations” to decide on which ones to apply the more expensive and accurate distance function. elated Work The subject of non-absolute control (i.e., how an agent can coherently integrate local goals with outside goals) has received some attention in DAI. Durfee [Durfee, 19881 has looked at the problem in the domain of distributed vehicle sensing. His method of “partial global plans” (PGP) allows agents to coordinate ac- tivity around common tasks. The agents may exist at the same level of an authority hierarchy, or one may be above another in that hierarchy. Agents do not, how- ever, reconcile their activity by measuring distance be- Ephrati and Rosenschein 267 tween candidate partial global plans. In addition, all local plans that fully satisfy the constraints imposed by a PGP are satisfactory; in our approach, we derive useful information from plan deviation, even though all plans are technically correct (i.e., achieve the goals). Malone has also been interested in issues relating to the organization of agents (both human and artificial), and has published various analyses of different human organizations and their relationship to machine orga- nization [Malone, 19861. In the field of telerobotics, there has also been discussion of how to effectively ma- nipulate robots at a distance, though robots there are generally less intelligent than those in which we are interested (see, for example, [Conway ei al., 19901). Conclusions We have considered how a subordinate agent might choose among alternate plans for achieving his supervi- sor’s goals. The techniques exploit the knowledge that the subordinate has about the supervisor, and allow the agent to choose its actions appropriately. The dis- cussion focused on metrics for evaluating the distance between plans, considering several techniques (such as the potential cost of moving from one final state to the other, and a cost on difficult to reverse consequences). One key point is that a plan can be considered a set of states, and the distance between plans can be modeled using a distance metric between sets of states (e.g., the Hausdorff metric). To use any distance metric between sets of states, it is also necessary to establish a suitable distance metric between individual states. Techniques for making plan comparisons can serve in other scenarios where plans are to be compared (for example, maintaining consistency among several sub- ordinate agents, choosing among agents to carry out a plan, predicting the likelihood that a plan will be car- ried out). Issues such as these will be of importance in building flexible multi-agent systems. Acknowledgments We want to thank Barbara Grosz, Michael Werman, and an anonymous referee for their insightful com- ments on previous versions of this paper. This research was partially supported by the Israel National Council for Research and Development (Grant 032-8284). References Arkin, E.; Chew, L. P.; Huttenlocher, D. P.; Kedem, K.; and Mitchell, J. S. B. 1990. An efficiently com- putable metric for comparing polygonal shapes. In Proceedings of the First ACM-SIAM Symposium on Discrete Algorithms. Atallah, M. J. 1983. A linear time algorithm for the Hausdorff distance between convex polygons. Infor- mation Processing Letters 17:207-209. Chapman, D. 1987. Planning for conjunctive goals. Artificial Intelligence 32(3):333-377. Conway, Lynn; Volz, Richard A.; and Walker, Michael W. 1990. Teleautonomous systems: Pro- jecting and coordinating intelligent action at a dis- tance. IEEE Transactions on Robotics and Automa- tion 6(2):146-158. Durfee, E. H. and Lesser, V. R. 1987. Using par- tial global plans to coordinate distributed problem solvers. In Proceedings of the Tenth International Joint Conference on Artificial Intelligence, Milan. 875-883. Durfee, Edmund H. 1988. Coordination of Dis- tributed Problem Solvers. Kluwer Academic Publish- ers, Boston. Finger, J. J. 1986. Exploiting Constraints in Design Synthesis. Ph.D. Dissertation, Stanford University, Stanford, CA. Genesereth, Michael R.; Ginsberg, Matthew L.; and Rosenschein, Jeffrey S. 1986. Cooperation without communication. In Proceedings of The National Con- ference on Artificial Intelligence, Philadelphia, Penn- sylvania. 5 l-57. Ginsberg, Matthew L. 1986. Possible worlds planning. In Georgeff, M. and Lansky, A., editors 1986, Rea- soning ubout Actions and Plans. Morgan Kaufmann Publishers, Los Altos, California. 2 13-243. Katz, Matthew J. and Rosenschein, Jeffrey S. 1992. Verifying plans for multiple agents. Journal of Ex- perimental and Theoretical Artificial Intelligence. To appear. Konolige, Kurt 1982. A first-order formalization of knowledge and action for a multi-agent planning sys- tem. Machine Intelligence 10. Kraus, Sarit; Ephrati, Eithan; and Lehmann, Daniel 1991. Negotiation in a non-cooperative environment. Journal of Experimental and Theoretical Artijcial In- telligence 3(4):255-282. Lesser, Victor R. 1987. Distributed problem solv- ing. In Shapiro, Stuart C., editor 1987, Encyclopedia of Artificial Intelligence. John Wiley and Sons, New York. 245-25 I. Malone, Thomas W. 1986. Organizing information processing systems: Parallels between human orga- nizations and computer systems. In Zacharai, W.; Robertson, S.; and Black, J., editors 1986, Cogni- tion, Computation, and Cooperation. Ablex Publish- ing Corp., Norwood, NJ. Rosenschein, Jeffrey S. 1982. Synchronization of multi-agent plans. In Proceedings of The National Conference on Artijkial Intelligence, Pittsburgh, Pennsylvania. 115-l 19. Zlotkin, Gilad and Rosenschein, Jeffrey S. 1991. In- complete information and deception in multi-agent negotiation. In Proceedings of the Twelfth Inter- national Joint Conference on Artificial Intelligence, Sydney, Australia. 225-23 1. 268 Multi-Agent Coordination | 1992 | 5 |
1,243 | An Analysis Pat Langley Wayne Iba* evin Thompson+ {LANGLEY,IBA,I~TIIOMPSO}@~~~LEM~.ARO.NASA.G~V AI Research Branch (M/S 269-2) NASA Ames Research Center Moffett Field, CA 94035 USA Abstract In this paper we present an average-case analysis of the Bayesian classifier, a simple induction algo- rithm that fares remarkably well on many learning tasks. Our analysis assumes a monotone conjunc- tive target concept, and independent, noise-free Boolean attributes. We calculate the probability that the algorithm will induce an arbitrary pair of concept descriptions and then use this to compute the probability of correct classification over the in- stance space. The analysis takes into account the number of training instances, the number of at- tributes, the distribution of these attributes, and the level of class noise. We also explore the be- havioral implications of the analysis by presenting predicted learning curves for artificial domains, and give experimental results on these domains as a check on our reasoning. Probabilistic Approaches to Induction One goal of research in machine learning is to discover principles that relate algorithms and domain character- istics to behavior. To this end, many researchers have carried out systematic experimentation with natural and artificial domains in search of empirical regularities (e.g., Kibler & Langley, 1988). Others have focused on theoretical analyses, often within the paradigm of probably approximately correct learning (e.g., Haus- sler, 1990). However, most experimental studies are based only on informal analyses of the learning task, wherea.s most formal analyses address the worst case, and thus bear little relation to empirical results. A third a.pproach, proposed by Cohen and Howe (1988), involves the formulation of average-case mod- els for specific algorithms and testing them through experimentation. Pazzani and Sarrett’s (1990) study of conjunctive learning provides an excellent exa.mple of this technique, as does Hirschberg and Pazzani’s (1991) work on inducing MNF concepts. By assum- ing information about the target concept, the num- *Also affiliated with RECOM Technologies ‘Also affiliated with Sterling Software. ber of attributes, and the class and attribute frequen- cies, they obtain predictions about the behavior of induction algorithms and used experiments to check their analyses. 1 However, their research does not fo- cus on algorithms typically used by the experimental and practical sides of machine learning, and it is im- portant that average-case analyses be extended to such methods. Recently, there has been growing interest in proba- bilistic approaches to inductive learning. For example, Fisher (1987) has described COBWEB, an incremental algorithm for conceptual clustering that draws heavily on Bayesian ideas, and the literature reports a number of systems that build on this work (e.g., Allen & Lang- ley, 1990; Iba & Gennari, 1991; Thompson & Langley, 1991). Cheeseman et al. (1988) have outlined AUTO- CLASS, a nonincremental system that uses Bayesian methods to cluster instances into groups, and other researchers have focused on the induction of Bayesian inference networks (e.g., Cooper & Kerskovits, 1991). These recent Bayesian learning algorithms are com- plex and not easily amenable to analysis, but they share a common ancestor that is simpler and more tractable. This supervised algorithm, which we re- fer to simply as a Bayesian classifier, comes originally from work in pattern recognition (Duda & Hart, 1973). The method stores a probabilistic summary for each class; this summary contains the conditional probabil- ity of each attribute value given the class, as well as the probability (or base rate) of the class. This data structure approximates the representational power of a perceptron; it describes a single decision boundary through the instance space. When the algorithm en- counters a new instance, it updates the probabilities stored with the specified class. Neither the order of training instances nor the occurrence of classification errors have any effect on this process. When given a test instance, the classifier uses an evaluation function (which we describe in detail later) to rank the alter- ‘A related app roach involves deriving the optimal learn- ing algorithm under certain assumptions, and then imple- menting an approximation of that algorithm (e.g., Opper & Haussler, 1991). Langley, Iba, and Thompson 223 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. DOMAIN BAYES IND/C4 FREQ. SOYBEAN 100.0 f 0.0 93.8 f 3.4 36.2 CHESS 87.5 f 0.4 99.3 f 0.1 52.2 LYMPHO 81.1 f 1.8 74.8 f 2.2 56.7 SPLICE 94.6 f 0.4 89.2 f 0.5 53.2 PROMOTERS 87.4 f 2.2 74.5 f 1.9 50.0 Table 1: Percentage accuracies for two induction al- gorithms on five classification domains, along with the accuracy of predicting the most frequent class. native classes based on their probabilistic summaries, and assigns the instance to the highest scoring class. Both the evaluation function and the summary de- scriptions used in Bayesian classifiers assume that at- tributes are statistically independent. Since this seems unrealistic for many natural domains, researchers have often concluded that the algorithm will behave poorly in comparison to other induction methods. However, no studies have examined the extent to which violation of this assumption leads to performance degradation, and the probabilistic approach should be quite robust with respect to both noise and irrelevant attributes. Moreover, earlier studies (e.g., Clark & Niblett, 1987) present evidence of the practicality of the algorithm. Table 1 presents additional experimental evidence for the utility of Bayesian classifiers. In this study we compare the method to IND’s emulation of the C4 algorithm (Buntine & Caruana, 1991) and an al- gorithm that simply predicts the modal class. The five domains, from the UC1 database collection (Murphy & Aha, 1992), include the “small” soybean dataset, chess end games involving a king-rook-king-pawn confronta- tion, cases of lymphography diseases, and two biologi- cal datasets. For each domain, we randomly split the data set into 80% training instances and 20% test in- stances, repeating this process to obtain 50 separate pairs of training and test sets. The table shows the mean accuracy and 95% confidence intervals on the test sets for each domain. In four of the domains, the Bayesian classifier is at least as accurate as the C4 reimplementation. We will not argue that the Bayesian classifier is superior to this more sophisticated method, but the results do show that it behaves well across a variety of domains. Thus, the Bayesian classifier is a promising induction algo- rithm that deserves closer inspection, and a careful analysis should give us insights into its behavior. We simplify matters by limiting our ana.1ysi.s to the induction of conjunctive concepts. Furthermore, we assume that there are only two classes, that each at- tribute is Boolean, and that attributes are indepen- dent of each other. We divide our study into three parts. We first determine the probability that the al- gorithm will learn a particular pair of concept descrip- tions. After this, we derive the accuracy of an arbi- trary pair of descriptions over all instances. Taken to- gether, these expressions give us the overall accuracy of the learned concepts. We find that a number of fac- tors influence behavior of the algorithm, including the number of training instances, the number of relevant and irrelevant attributes, the amount of class and at- tribute noise, and the class and attribute frequencies. Finally, we examine the implications of the analysis by predicting behavior in specific domains, and check our reasoning with experiments in these domains. Probability of Induced Concepts Consider a concept C defined as the monotone con- junction of T relevant features Al,. . . , A,. (i.e., in which none of the features are negated). Also assume there are i irrelevant features A,.+l, . . . , A,.+a. Let P(Ag) be the probability of feature Aj occurring in an instance. The concept descriptions learned by a Bayesian clas- sifier are fully determined by the n training instances it has observed. Thus, to compute the probability of each such concept description, we must consider differ- ent possible combinations of n training instances. First let us consider the probability that the algo- rithm has observed exactly Ic out of n positive in- stances. If we let P(C) be the probability of observing a positive instance and we let x be the observed frac- tion of positive instances, then we have P(x = i, = (;)qcyp - p(c)]“-’ . This expression also represents the probability that one has observed exactly n - Ic negative instances. Since we assume that the concept is monotone con- junctive and that the attributes are independent, we have P(C) = n,‘=, P(Aj), which is simply the product of the probabilities for all relevant attributes. A given number of positive instances iE can produce many alternative descriptions of the positive class, de- pending on the instances that are observed. One can envision each such concept description as a cell in an T + i dimensional matrix, with each dimension rang- ing from 0 to L, and with the count on dimension j representing the number of positive instances in which attribute Aj was present. One can envision a similar matrix for the negative instances, again having dimen- sionality P + i, but with each dimension ranging from 0 to n - k, and with the count on each dimension j rep- resenting the number of negative instances in which Aj occurred. Figure 1 shows a positive cell matrix with r+i=S,k= 2. The designated cell holds the prob- ability that the algorithm has seen two instances with Al present, 1 instance with A2 present, and 0 instances with A3 present. In both matrices, one can index each cell or concept description by a vector of length r + i. Let P(celZc)k be the probability that the algorithm has produced the 224 Learning: Theory Figure 1: A positive cell matrix for three attributes and k: = 2. Values along axes represent numbers of positive instances for which Aj was present. cell indexed by vector u” in the positive matrix given k positive instances; let P(celZg)ra-k: be the analogous probability for a cell in the negative matrix. Then a weighted product of these terms gives the probability that the learning algorithm will generat,e any particular pair of concept descriptions, which is P(k, ii, + = P(x = !)P(celZ,-)k P(;cell,-),-k . n In other words, one multiplies the probability of seeing k out of n positive instances and the probabilities of encountering cell u’ in the positive matrix and cell v’ in the negative matrix. However, we must still determine the probability of a given cell from the matrix. For those in the positive matrix, this is straightforward, since the attributes re- main independent when the instance is a member of a conjunctive concept. Thus, we have r+i P(cell,-)k = n P(yj = j=l cf) as the probability for cella in the positive matrix, where yj represents the observed fraction of the k in- stances in which attribute Aj was present. Further- more, the probability that one will observe Aj in ex- actly $ out of k such instances is P(Aj IC>“j[l - P(Aj IC)]“-“J . In the absence of noise, we have P(Aj IC) = 1 for all relevant attributes and P(AjlC) = P(Aj) for all irrel- evant attributes. The calculation is more difficult for cells in the neg- ative matrix. One cannot simply take the product of the probabilities for each index of the cell, since for a conjunctive concept, the attributes are not statistically independent. However, one can compute the proba.bil- ity that the n - k observed negative insta.nces will be composed of a particular combination of instances. If we let P(Ij 16) be the probability of Ij given a neg- ative instance, we can use the multinomial distribution to compute the probability that exactly dl of the n - k instances will be instance 11, d2 will be instance 12, . . . . and dw will be instance &,. Thus the expression (n - k)! dl!d2!...dw! P(I1 Icy’ P(I2 ILy” . . . P(Iw IC>dw gives us the probability of a particular combination of negative instances, and from that combination we can compute the concept description (i.e., cell indices) that result. Of course, two or more combinations of in- stances may produce the same concept description, but one simply sums the probabilities for all such combina- tions to get the total probability for the cell. All that we need to make this operational is P(Ij IC), the prob- ability of Ii given a negative instance. In the absence of noise, this is simply P(Ij)/P(C), since P(ClIj) = 1. We can extend the framework to handle class noise by modifying the definitions of three basic terms - P(C), P(Aj IC), and P(Ij IC). One common definition of class noise involves the corruption of class names (i.e.,.replacing the actual class with its opposite) with a certain probability z between 0 and 1. The proba- bility of the class after one has corrupted values is P’(C) = (l-z)P(C)+z(l-P(C)) = P(C)[l--2z]+z ) as we have noted elsewhere (Iba & Langley, 1992). For an irrelevant attribute Aj, the probability P(Aj IC) is unaffected by class noise and remains equal to P(Aj), since the attribute is still independent of the class. However, the situation for relevant attributes is more complicated. By definition, we can reexpress the corrupted conditional probability of a relevant at- tribute Aj given the (possibly corrupted) class C as P’(Aj IC) = “‘p4iac) , where P’(C) is the noisy class probability given above. Also, we can rewrite the numerator to specify the situ- ations in which corruption of the class name does and does not occur, giving P’(Aj IC) = (1 - %)P(C)P(Aj IC) + %P(C)P(Aj IC) P’(C) . Since we know that P(Aj IC) = 1 for a relevant at- tribute, and since P(AjlC) = [P(Aj) - P(C)]/P(C) for conjunctive concepts, we have P’(Aj IC) = (I- %)P(C) + %[P(Aj) - P(C)] P(C)[l - 22]+ % 7 which involves only terms that existed before corrup- tion of the class name. We can use similar reasoning to compute the post- noise probability of any particular instance given that it is negative. As before, we can rewrite P’(lj 16’) as P'(Ij A C) _ (1 - %)P(C)P(Ij IC) + %P(C)P(Ij IC) P’(C) - 1 - (P(C)[l - 2%]+ %) 9 Langley, Pba, and Thompson 225 but in this case the special conditions are somewhat different. For a negative instance, we have P(Ij IC) = 0, so that the second term in the numerator becomes zero. In contrast, for a positive instance, we have P(Ij IC) = 0, so that the first term disappears. Taken together, these conditions let us generate probabilities for cells in the negative matrix after one has added noise to the class name. After replacing P(C) with P’(c), P(AjlC) with P’(Aj IC), and P(Ij IC) with P’(Ij IC), the expressions earlier in this section let us compute the probability that a Bayesian classifier will induce any particular pair of concept descriptions (cells in the two matri- ces). The information necessary for this calculation is the number of training instances, the number of rele- vant and irrelevant attributes, their distributions, and the level of class noise. This analysis holds only for monotone conjunctive concepts and in domains with independent attributes, but many of the ideas should carry over to less restricted classes of domains. Accuracy of Induced Concepts To calculate overall accuracy after n training instances, we must sum the expected accuracy for each possible instance weighted by that instance’s probability of oc- currence. More formally, the expected accuracy is h’, = x P(Ij)I<(Ij), . To compute the expected accuracy K(lj), for instance I’, we must determine, for each pair of cells in the posi- tive and negative matrices, the instance’s classification. A test instance Ij is classified by computing its score for each class description and selecting the class with the highest score (choosing randomly in case of ties). We will define acc~~acy(lj),,~,~,~ for the pair of con- cept descriptions u’ and v’ to be 1 if this scheme cor- rectly predicts Ij’s class, 0 if it incorrectly predicts the class, and $ if a tie occurs. Following our previous notation, let n be the number of observed instances, k be the number of observed pos- itive instances, uj be the number of positive instances in which attribute Aj occurs, and ‘uj be the number of negative instances in which Aj occurs. For a given instance Ij, one can compute the score for the positive class description as SCOre(C)j = f !!i &t&i if Aj is present in Ij k otherwise, and an analogous equation for the negative class, sub- stituting n - k for k and v for u. To avoid multiplying by 0 when an attribute has never (always) been ob- served in the training instances but is (is not) present in the test instance, we follow Clark a.nd Niblett’s (1987) suggestion of replacing 0 with a small value, such as 1/2n. To compute the expected accuracy for instance Ij, we sum, over all possible values of k and pairs of con- cept descriptions, the product of the probability of se- lecting the particular pair of concept descriptions af- ter k positive instances and the pair’s accuracy on Ij. Thus, we have n UV k=O ii v’ where the second and third summations occur over the possible vectors that index into the positive matrix U and the negative matrix V. To complete our calcula- tions, we need an expression for P(Ij ), which is the product of the probabilities of features present in Ij. Implications for Learning Behavior Although the equations in the previous sections give a formal description of the Bayesian classifier’s behavior, their implications are not obvious. In this section, we examine the effects of various domain characteristics on the algorithm’s classification accuracy. However, because the number of possible concept descriptions grows exponentially with the number of training in- stances and the number of attributes, our predictions have been limited to a small number of each. In addition to theoretical predictions, we report learning curves that summarize runs on 100 randomly generated training sets. Each curve reports the aver- age classification accuracy over these runs on a single test set of 200 randomly generated instances contain- ing no noise. In each case, we bound the mean accu- racy with 95% confidence intervals to show the degree to which our predicted learning curves fit the observed ones. These experimental results provide an important check on our reasoning, and they revealed a number of problems during development of the analysis. Figure 2 (a) shows the effects of concept complexity on the rate of learning in the Bayesian classifier when no noise is present. In this case, we hold the num- ber of irrelevant attributes i constant at one, and we hold their probability of occurrence P(A) constant at $. We vary both the number of training instances and the number of relevant attributes r, which determine the complexity of the target concept. To normalize for effects of the base rate, we also hold P(C), the prob- ability of the concept, constant at 4; this means that, for each of the r relevant attributes, P(A) is P(C)lI’, and thus is varied for the different conditions.2 As typical with learning curves, the initial accuracies begin low (at f) and gradually improve with increasing numbers of training instances. The effect of concept complexity also agrees with our intuitions; introducing 2An alternative approach would hold P(A) constant for relevant attributes, causing P(C) to become P(A)‘. This nudges the initial accuracies upward but otherwise has little effect on the learning curves. 226 Learning: Theory (4 In d 0 5 10 15 20 25 30 35 40 Number of training instances Figure 2: Predictive accuracy of a Bayesian classifier in a conjunctive concept, assuming the presence of one irrelevant attribute, as a function of training instances and (a) number of relevant attributes and (b) amount of class noise. The lines represent theoretical learning curves, whereas the error bars indicate experimental results. additional features into the target concept slows the learning rate, but does not affect asymptotic accuracy, which is always 1.0 for conjunctive concepts on noise- free test cases. The rate of learning appears to degrade gracefully with increasing complexity. The predicted and observed learning curves are in close agreement, which lends confidence to our avera.ge-case analysis. Theory and experiment show similar effects when we vary the number of irrelevant attributes; learning rate slows as we introduce misleading features, but the al- gorithm gradually converges on perfect accuracy. Figure 2 (b) p resents similar results on the interac- tion between class noise and the number of training instances. Here we hold the number of relevant at- tributes constant at two and the number of irrelevants constant at one, and we examine three separate levels of class noise. Following the analysis, we assume the test instances are free of noise, which normalizes ac- curacies and eases comparison. As one might expect, increasing the noise level z decreases the rate of learn- ing. However, the probabilistic nature of the Bayesian classifier leads to graceful degradation, and asymptotic accuracy should be unaffected. We find a close fit be- tween the theoretical behavior and the experimental learning curves. Although our analysis does not in- corporate attribute noise, experiments with this factor produce similar results. In this case, equivalent levels lead to somewhat slower learning rates, as one would expect given that attribute noise can corrupt multiple values, whereas class noise affects only one. Finally, we can compare the behavior of the Ba.yesian classifier to that of WIIOLTST (Pazzani QL Sarrett, 1990). One issue of interest is the number of train- ing instances required to achieve some criterion level of accuracy. A quantitative comparison of this nature is beyond the scope of this paper, but the respective a.nalyses and experiments show that the WHOLIST al- gorithm is only affected by the number of irrelevant at- tributes, whereas the Bayesian classifier is sensitive to both the number of relevant and irrelevant attributes. However, the Bayesian classifier is robust with respect to noise, whereas the WHOLIST algorithm is not. iscussion In this paper we have presented an analysis of a Bayesian classifier. Our treatment requires that the concept be monotone conjunctive, that instances be free of attribute noise, and that attributes be Boolean and independent. Given information about the num- ber of relevant and irrelevant attributes, their frequen- cies, and the level of class noise, our equations compute the expected classification accuracy after a given num- ber of training instances. To explore the implications of the analysis, we have plotted the predicted behavior of the algorithm as a function of the number of training instances, the number of relevant attributes, and the amount of noise, finding graceful degradation as the latter two increased. As a check on our analysis, we run the al- gorithm on artificial domains with the same character- istics. We obtain close fits to the predicted behavior, but only after correcting several errors in our reasoning that the empirical studies revealed. In additional experiments, we compare the behavior of the Bayesian classifier to that of a reimplementation of C4, a more widely used algorithm that induces de- cision trees. In general, the probabilistic method per- forms comparably to C4, despite the latter’s greater sophistication. These results suggest that such simple methods deserve increased attention in future studies, whether theoretical or experimental. In future work, we plan to extend this analysis in several wa.ys. In particular, our current equations han- dle only class noise, but as Angluin and Laird (1988) have shown, attribute noise can be even more prob- lematic for learning algorithms. We have developed Langley, Iba, and Thompson 227 tentative equations for the case of attribute noise, but the expressions are more complex than for class noise, in that the possible corruption of any combination of attributes can make any instance appear like another. We also need to relax the constraint that target con- cepts must be monotone conjunctive. Another direction in which we can extend the present work involves running additional experiments. Even within the assumptions of the current analysis, we could empirically study the extent to which vio- lated assumptions alter the observed behavior of the algorithm. In addition, we could analyze the attribute frequencies in several of the domains commonly used in experiments to determine the analytic model’s abil- ity to predict behavior on these domains given their frequencies as input. This approach would extend the usefulness of our average-case model beyond the arti- ficial domains on which we have tested it to date. Overall, we are encoura.ged by the results that we have obtained. We have demonstrated that a simple Bayesian classifier compares favorably with a more so- phisticated induction algorithm and, more important, we have characterized its average-case behavior for a restricted class of domains. Our analysis confirms intu- itions about the robustness of the Bayesian algorithm in the face of noise and concept complexity, and it pro- vides fertile ground for further research on this under- studied approach to induction. Acknowledgements Thanks to Stephanie Sage, Kimball Collins, and Andy Philips for discussions that helped clarify our ideas. References Allen, J.A., & Langley, P. (1990). Integrating mem- ory and search in planning. Proceedings of the Work- shop on Innovative Approaches to Planning, Schedul- ing, and Control (pp. 301-312). San Diego: Morgan Kaufmann. Angluin, D., & Laird, P. (1988). Learning from noisy examples. Machine Learning, 2, 343-370. Buntine, W., & Caruana, R. (1991). Introduction to IND and recursive partitioning (Technical Report FIA- 91-28). Moffett Field, CA: NASA Ames Research Cen- ter, Artificial Intelligence Research Branch. Cheeseman, P., Kelly, J., Self, M., Stutz, J., Taylor, W., & Freeman, D. (1988). AUTOCLASS: A Bayesian classification system. Proceedings of the Fifth Interna- tional Conference on Machine Leurn,ing (pp. 54-64). Ann Arbor, MI: Morgan Kaufmann. Clark, P., & Niblett, T. (1989). The CN3 induction algorithm. h1achine Learning, 3, 261-284. Cohen, P. R., & IIowe, A. E. (1988). IIow evaluation guides AI research. AI Magazine, 9, 35-43. Cooper, G. F., & Herskovits, E. (1991). A Bayesian method for constructing Bayesian belief networks from databases. Proceedings of the Seventh Conference on Uncertainty in Artificial Intelligence (pp. 86-94). Los Angeles: Morgan Kaufmann. Duda, R. O., & Hart, P. E. (1973). Pattern classifi- cation and scene analysis. New York: John Wiley & Sons. Fisher, D. H. (1987). Knowledge acquisition via incre- mental conceptual clustering. Machine Learning, 2, 139-172. Haussler, D. (1990). Probably approximately cor- rect learning. Proceedings of the Eighth National Conference on Artificial Intelligence (pp. 1101-1108). Boston: AAAI Press. Iba, W., & Gennari, J. H. (1991). Learning to rec- ognize movements. In D. H. Fisher, M. J. Pazzani, & P. Langley (Eds.), Concept formation: Knowledge and experience in unsupervised learning. San Mateo: Morgan Kaufmann. Iba, W., & Langley, P. (1992). Induction of one-level decision trees. Proceedings of the Ninth International Conference on Machine Learning. Aberdeen: Morgan Kaufmann. Hirschberg, D. S., & Pazzani, M. J. (1991). Averuge- case analysis of a k-CNF learning algorithm (Techni- cal Report 91-50). Irvine: University of California, Department of Information & Computer Science. Kibler, D., & Langley, P. (1988). Machine learning as an experimental science. Proceedings of the Third European Working Session on Learning (pp. 81-92). Glasgow: Pittman. Murphy, P. M., & Aha, D. W. (1992). UCI Repository of machine learning databases [Machine-readable data repository]. Irvine: University of California, Depart- ment of Information & Computer Science. Opper, M., & Haussler. D. (1991). Calculation of the learning curve of Bayes optimal classification algorithm for learning a perceptron with noise. Proceedings of the Fourth Annual Workshop on Computational Learning Theory (pp. 75-87). Santa Cruz: Morgan Kaufmann. Pa.zzani, M. J., & Sarrett, !‘V. (1990). Average-case analysis of conjunctive learning algorithms. Proceed- ings of the Seventh International Conference on Ma- chine Learning (pp. 339-347). Austin, TX: Morgan Kaufmann. Thompson, K., & Langley, P. (1991). Concept forma- tion in structured domains. In D. H. Fisher, M. J. Paz- zani, gL P. Langley (Eds.), Concept formation: Knowl- edge and experience in unsupervised learning. San Ma- teo: Morgan Kaufmann. 228 Learning: Theory | 1992 | 50 |
1,244 | ee ing rasad Tadepalli Department of Computer Science Oregon State University Corvallis, QR 97331 (tadepalli@cs.orst .edu) Abstract Speedup learning seeks to improve the efficiency of search-based problem solvers. In this paper, we propose a new theoretical model of speedup learn- ing which captures systems that improve problem solving performance by solving a user-given set of problems. We also use this model to motivate the notion of “batch problem solving,” and argue that it is more congenial to learning than sequen- tial problem solving. Our theoretical results are applicable to all serially decomposable domains. We empirically validate our results in the domain of Eight Puzzle.’ Introduction Speedup learning seeks to improve the efficiency of search-based problem solvers. While the theory for concept learning is well-established, (for example, see [Valiant 1984; Natarajan 1991]), the theory of speedup learning is rapidly evolving [Cohen 1989; Elkan & Greiner 1991; Etzioni 1990; Greiner 1989; Laird 1990; Natarajan & Tadepalli 1988; Natarajan 1989; Subra- manian & Feldman 1990; Tadepalli 1991a, etc.]. In this paper, we propose a formal model of speedup learning which views learning as jumps in the average asymp- totic complexity of problem solving. The problem solv- ing is “slow” in the beginning. But as the problem solver gains experience, its average asymptotic com- plexity reduces; thus it converges to a “fast” problem solver. The model we propose is based on and extends our previous work. In our earlier work, reported in [Natarajan & Tadepalli 19881 and [Tadepalli 1991a], learning begins with a teacher-supplied set of problems and solutions. In these models, examples provide two kinds of information to the learner: First, they provide the problem distribution information, i.e., they tell the learner which problems are likely to occur in the world. Second, they also provide the solutions to these prob- lems. Although this makes learning tractable, it is ‘This research was partially supported by the National Science Foundation under grant number IRI:0111231. burdensome to the teacher in that she is required to solve the problems before giving them to the learner. In the new model, the teacher is only required to pro- vide the problems. Since the learner has access to a complete and correct, if inefficient, problem solver, it can solve these problems by itself, while also learning a more efficient problem solver for the given distribution of problems. The price for this decreased burden on the teacher is an increased complexity of learning. Hence it can be described as “unsupervised learning,” and it captures the kind of learning attempted by problem solving and learning architectures like SOAR and PRODIGY [Laird, Rosenbloom & Newell 1986; Minton 19901. However, most learning/problem solving architectures including the above assume sequential problem solving in that they do not attempt to solve a second problem until they have fully solved the first problem. In this paper we lift this sequential constraint on the problem solver and allow the system to solve a sample of prob- lems in any way it is convenient. We call this “batch problem solving.” We show that there are some im- portant advanta.ges to batch problem solving in that it can effectively take advantage of the multiple examples to discover regularities in the domain structure, which are otherwise difficult to uncover. We show that earlier results by Korf in learning problem solving in domains like the Rubik’s Cube can be explained in this framework [Korf 19851. In particu- lar, we generalize Korf’s results and present algorithms that not only learn macro-tables but also learn the or- der in which the macro-operators might be used. We precisely define what it means to learn in this model and characterize the conditions under which this kind of learning is possible. We support our theoretical re- sults with experiments. Previous Work This work is motivated by the experimental systems in Explanation-Based Learning (EBL), and the need to theoretically justify and explain their learning behavior [Laird, Rosenbloom & Newell 1986; Dejong & Mooney 1986; Minton 1990; Mitchell, Keller & Kedar-Cabelli Tadepalli 229 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. 1986, etc.]. Our model of speedup learning draws its inspiration from “Probably Approximately Correct” (PAC) learning introduced by Valiant, which captures effective concept learning from examples [Valiant 1984; Natarajan 19911. Our work is similar in spirit to many evolving mod- els of speedup learning. For example, Cohen ana- lyzes a “Solution Path Caching” mechanism and shows that whenever possible, it always improves the per- formance of the problem solver with a high proba- bility [Cohen 19891. Unlike in our work, however, the improved problem solver is not necessarily effi- cient. Greiner and Likuski formalize speedup learn- ing as adding redundant learned rules to a horn-clause knowledge base to expedite query-processing [Greiner & Likuski 19891. S u b ramanian and Feldman analyze an explanation-based learning technique in this frame- work, and show that it does not work very well when recursive proofs are involved [Subramanian & Feldman 19901. Etzioni uses a complexity theoretic argument to arrive at a similar conclusion [Etzioni 19901. Our results show that a polynomial-time problem solver can be learned under some conditions even when the “proof” or the problem solving trace has a recursive structure. This is consistent with the positive results achieved by speedup learning systems like SOAR in do- mains like Eight Puzzle [Laird, Rosenbloom & Newell 19861. Our framework also resembles that of [Natarajan 19891 in that both of these models learn from prob- lems only. Natarajan’s model requires the teacher to create a nice distribution of problems, so called “ex- ercises,” which reflects the population of subproblems present in the given problems. Our model does not have this requirement, but relies on exponential-time search to build its own solutions. PAC Speedup Learning Framework The framework we introduce here is most similar to that of [Natarajan & Tadepalli 19881. The main differ- ence between the two is that in the current framework, unlike the previous one, the teacher only gives ran- dom problems to the learner without solutions. In this sense, this is “unsupervised learning.” The key feature of a speedup learning system is that it has access to a “domain model” or a “domain the- ory,” which includes goal and operator models. This domain theory is also complete in that it can in prin- ciple be used to solve any problem using exhaustive search. The task of the learner is to take such a do- main theory and a random sample of problems and output an efficient problem solver, which solves any randomly chosen problem with a high probability. As in the PAC model, we require that the practice prob- lems are chosen from the same distribution as the test problems. A problem domain D is a tuple (S, G, 0), where 0 s= A set of states or problems. @G = A goal which is described as a set of conjunc- tive subgoals (91, 92, . . .}, where each subgoal gi is a polynomial-time procedure that recognizes a set of states in S that satisfy that subgoal. SO = A set of operators {01,02, . . .}, where each oi is a polynomial-time procedure that implements a partial function from S to S. The combination of the goal G and the operators 0 is called a theory of D. Multiple goals can be accom- modated into the above model by changing the state description to have two components: the current state and the goal. The operators manipulate only the cur- rent state, and G compares the current state to the goal description and determines if it is satisfied. We assume that if an operator is applied to a state in which it is not applicable, it results in a distinguishable “dead state.” We denote the result of applying an operator o to a state s by o(s). The size of the state or problem s is the number of bits in its description, and is denoted by Is]. For simplicity, we assume that the operators are length-preserving, i.e., IsI = lo(s)\. Unlike the standard EBL approaches, our goals and operators are not parameterized. Although this might appear to be a serious limitation, it is not the case. To keep the cost of instantiation tractable, the number of parameters of an operator (or macro-operator) must be kept small. If so, it can be replaced by a small num- ber of completely instantiated operators, and hence it reduces to our model. Another important deviation from the EBL domain theories is that our operators are opaque. In addition to being a more realistic assump- tion, this also makes it possible to efficiently represent the domain theory [Tadepalli 1991b]. A problem s is solvable if there is a sequence of op- erators p = (or, . . ., od), and a sequence of states (so, * * ‘9 sd), such that (a) s = se,(b) for all i from 1 to d, si = oi(si-I), and (c) sd satisfies the goal G. In the above case, ,O is a solution sequence of s, and d is the length of the solution sequence p. We call the maximum of the shortest solution lengths of all problems of a given size n, the diameter of problems of size n. A problem solver f for D is a deterministic program that takes as input a problem, s, and computes its solution sequence, if such exists. A meta-domain 2 is any set of domains. A learning algorithm for 2 is an algorithm that takes as input the theory of any domain D E 2 and some number of problems according to any problem distribu- tion P and computes as output an approximate prob- lem solver for D (with respect to P). The learning protocol is as follows: First, the do- main theory is given to the learner. The teacher then selects an arbitrary problem distribution. The learning algorithm has access to a routine called PROBLEM. At each call, PROBLEM randomly chooses a prob- lem in the input domain, and gives it to the learner. The learning algorithm must output an approximate 230 Learning: Theory problem solver with a high probability after seeing a reasonable number of problems. The problem solver need only be approximately correct in the sense that it may fail to produce correct solutions with a small probability. Definition 1 An algorithm A is a learning algorithm for a meta-domain 2, if for any domain D E 2, and any choice of a problem distribution P which is non- zero on only solvable problems of size n, 1. A takes as input the specification of a domain D E 2, the problem site n, an error parameter E, and a confidence parameter S, 2. A may call PROBLEM, which returns problems x from domain D, where x is chosen with probability P(x). The number of oracle calls of A, and the space requirement of A must be polynomial in n, the diam- eter d of problems of size n, $, $, and the length of its input. 3. With probability at /east (1 - 6) A outputs a problem solver f which is approximately correct in the sense that C ,EaP(x) 2 E, where A = {xlf faib on x}. 4. There is a polynomial R such that, for any problem solver f output by A, the run time off is bounded by R(n, 4 $, $). The number of oracle calls of the learning algorithm is its sample complexity. Note that we place no re- strictions on the time complexity of the learning algo- rithm, although we require that its space complexity and the time complexity of the output problem solver must be polynomials. The speedup occurs because of the time complexity gap between the problem solving before learning and the problem solving after learning. We call this framework PAC Speedup Learning. Serial Decomposability and Macro-tables This section introduces some of the basic terminology that we will be using later. Here we make the assumption that states are rep- resentable as vectors of n discrete valued features, where the maximum number of values of any feature is bounded by a polynomial h(n). We represent the value of the ith feature of a state s by s(i), and write s = (s(l), . . . , s(n)). In Rubik’s Cube, the variables are cubic names, and their values are cubic positions. In Eight Puz- zle, the variables are tiles, and their values are tile positions. Note that the above assumption makes it difficult to represent domains with relations, e.g., the blocks world. Following Korf, we say that a domain is serially de- composable if there is a total ordering on the set of features such that the effect of any operator in the do- main on a feature value is a function of the values of only that feature and all the features that precede it [Korf 19851. Procedure Solve (Problem s) For i := 1 thru n begin 3 * := s(Fi); solution := solution.M(j, i) S := APP~Y(S, M(i 4); end; Return (solution); Table 1: Korf’s Macro-table Algorithm Rubik’s Cube is serially decomposable for any order- ing of features (also called “totally decomposable”). In Eight Puzzle, the effect of an operator on any tile de- pends only on the positions of that tile and the blank. Hence Eight Puzzle is serially decomposable for any ordering that orders the blank as the first feature. We assume that there is a single, fixed goal state g described by (g(l), . . . , g(n)). Assume that a domain is serially decomposable with respect to a feature ordering Fr , . . . , Fn. A macro-table is a set of macros M(j, i) such that if M(j, i) is used in a solvable state s where the features Fr thru Fi-1 have their goal values, and the feature I’$ has a value j, then the resulting state is guaranteed to have goal values g(Fr), . . ., g(Fi) for features Fr thru Fa. Definition 2 A meta-domain 2’ satisfies a serial de- composability bias if for any domain D in 2, there is a feature ordering 0 = Fl, . . . , Fn such that, (a) D is se- rially decomposable for 0, and (b) every problem which is reachable from any solvable state is also solvable. If a domain is serially decomposable for the feature ordering Fl, . . . , F, , then any move sequence that takes a state where the features Fl thru Fi,1 have their goal values and the feature Fi has a value j to any other state where the features Fl thru Fi have their goal values can be used as a macro M(j, i). The reason for this is that the values of features Fl thru Fi in the final state only depend on their values in the initial state, and not on the values of any other features. Theorern 3 (Korf) If a meta-domain satisfies the serial decomposability bias, then it has a macro-table. If a full macro-table with appropriately ordered fea- tures is given, then it can be used to construct solu- tions from any initial state without any backtracking search [Korf 19851, by repeatedly picking the appropri- ate macro and applying it to the state. The algorithm shown in Table 1 would do just that, assuming that Fi represents the feature that corresponds to the ith column in the macro-table. atclz Learning of Macro-tables In this section we describe and prove its correctness. our batch learning algorithm Tadepalli 231 Procedure Batch-Learn (Problem set S, Current Column i, Current feature ordering F, Current Macro-table M) Candidate features CF := (1,. . .,n} - {Fj]l 5 j < i}; If CF = @ Then return (M, F); For each problem p E S For each feature f E CF If there is a macro m = C(p(f), f) stored for f Then If m works for p Then do nothing Else CF := CF - {f} EL+2 C(P(f)> f) := ID-DFS(p, F U{ f)); If CF = @ Then return (Fail); For each f e CF Begin Fi := f Add the new column C(*,f) to the macro-table M S’ := {s’I$ = APPW, CW), f)), where s E Sl If Batch-Learn(S’, i + 1, F U(f), AI) succeeds Then return (M, F) Else restore S, M, and F to old values; End Return (Fail) ; Table 2: An Algorithm to Learn Macro-tables Korf’s learning program builds a macro-table by ex- haustively searching for a correct entry for each cell in the table [Korf 19851. Unlike in Korf’s system, we do not assume that the feature ordering in the macro- table is known to the system. The program must learn the feature ordering along with the macro-table. One way to learn this would be to exhaustively consider all possible feature orderings for each example. However, that would involve a search space of size O(n!). Our batch learning algorithm considers all n! order- ings in the worst-case, but uses multiple examples to tame this space. We consider different feature order- ings while we build the macro-table column by column. That is, we move to the ith column in the macro-table only when we have a consistent feature Fi-1 for the . 2 - lth column, and a set of macros for it which can solve all problems in the sample. The reason for this is that it allows us to prune out bad feature orderings early on by testing the macros learned from one prob- lem on the other problems. In the algorithm of Table 2, CF is the set of candi- date features for the next column i of the macro-table, and C is the set of candidate columns for each feature in CF. At any column i, for each candidate feature f and feature value w, C(V, f) contains a macro that would achieve the goal values for { Fl , . . . , Fi- 1) U{ f } when the goal values for features in { FI , . . . , Fi- 1) have already been achieved and the current value of feature f is w. If at any given time, there is already an ap- plicable macro in C for the problem under considera- tion, it is tested on that problem. If it does not work, 617 613 123 843 847 804 502 250 765 Problem 1 Problem 2 Goal Figure 1: Two problems and the goal then that feature cannot give rise to a serially decom- posable ordering, and is immediately pruned. For a given feature f, if there is no applicable macro for the problem, then the set of subgoals that correspond to features { Fl, . . . , Fi-1) U{ f} is solved by an iterative- deepening depth first search, and the macro is stored in C. If there is an extension to the current feature or- dering which retains the serial decomposability, then the program would end up with a set of consistent features and corresponding candidate macro-columns. The program explores each such candidate by back- tracking search until it finds a serially decomposable ordering of features and a consistent macro-table. Af- ter learning a macro-column, the program updates the sample by solving the corresponding subgoal for each problem in the sample and proceeds to the next col- umn. Example: Eight Puzzle Let r, I, u, and d represent the primitive operators of moving a tile right, left, up, and down respectively in Eight Puzzle. Macros are represented as strings made up of these letters. For notational ease, features (tiles) are labeled from 0 to 8, 0 standing for the blank and i for tile i. The positions are numbered by the tile num- bers in the goal state, which is assumed to be fixed. Two problems and the goal state are shown in Figure 1. Assume that the learner is building the very first col- umn in the macro-table. Since this is the first column, the program considers all features from 0 thru 8 as po- tential candidates and considers bringing each feature to its goal value. By doing iterative-deepening depth first search (ID-DFS) on the first problem, the program determines that the macro-operator “d” would achieve subgoal 0, i.e., bring the blank to its goal position, the macro-operator “drdl” would achieve subgoal 1 and so on. Hence it stores these different macros in the po- tential first columns of the macro-table: C(6,O) = “d”, C(2,l) = “drdl”, C(5,2) = “drdlulurdldru,” and so on. While doing the same on the second problem, the program checks to see if there is a macro in the table which is applicable for any subgoal. Since the position of the tile 1 is the same (2) in both the examples, the same macro C(2,l) must be able to get tile 1 to its goal position for both the problems, provided that tile 1 is one of the correct candidates for the first column. However, applying the macro C(2,l) = “drdl” on the second problem does not succeed in getting the tile 1 232 Learning: Theory to its destination. Hence tile 1 is ruled out as the first column in the macro-table, and the program proceeds to the other tiles. Note how multiple examples were used to avoid un- necessary backtracking. If the problem solver were to solve the second problem only after it completely solved the first problem, it would not have known that ordering tile 1 as the first feature is a bad idea un- til much later. In our algorithm, a bad feature or- dering would be quickly detected by one example or another. Although backtracking is still theoretically possible, given enough number of examples, our pro- gram is found not to backtrack. This illustrates the power of batch problem solving. o We are now ready to prove the main theoretical re- sult of this paper. Theorem 4 If (a) 2 is a me-la-domain that satisfies the serial decomposability bias, and (b) the number of distinct values for each feature of each domain in Z is bounded by a polynomial function h of the problem size n, then Batch-Learn is a learning algorithm for Z. Proof (sketch): The proof closely follows the proof of sample complexity of finite hypothesis spaces in PAC learning [Blumer et al., 19871. Assume that after learning from m examples, the learning algorithm terminated with a macro-table T. A macro-table is considered “bad” if the probability of its not being able to solve a random problem without search is greater than E. We have to find an upper bound on m so that the probability of T being bad is less than S . The probability that a particular bad macro-table solves m random training problems (without search) is (1 - c)~. This is the probability of our algorithm learning a particular bad macro-table from a sample of size m. Hence, for the probability of learning any bad macro-table to be less than S, we need to bound ]BI(l - E)~ by 6, where B is the set of bad tables. Note that a table is bad only if (a) some of the macros in the macro-table are not filled up by any example, or (b) the feature ordering of the table is incorrect. Since the total number of macros in the full table is bounded by nh( n), the number of unfilled sub- sets of the macros is bounded by 24”). Since the number of bad orderings is bounded by n!, the to- tal number of bad tables IBI is bounded by n!2”h(n). Hence we require n!2”h(n)(l - e)” < 6. This holds if m > $-{n Inn + nh(n)ln2 + In i}. Since h is polynomial in n, the sample complexity is polynomial in the required parameters. The macro- table can be used to solve any problem in time poly- nomial in problem size n and the maximum length of the macro-operators, which is bounded by the diam- eter d (because ID-DFS produces optimal solutions). The space requirements of Batch-Learn and the macro problem solver are also polynomial in d and n. Hence Batch-Learn is a learning algorithm for Z. m The above theorem shows that the batch learning al- gorithm exploits serial decomposability, which allows it to compress the potentially exponential number of so- lutions into a polynomial size macro-table. Note that the solutions produced by the problem solver are not guaranteed to be optimal. This is not surprising, be- cause finding optimal solutions for the N x N general- ization of Eight Puzzle is intractable [Ratner & War- muth 19861. However, the solutions are guaranteed to be within n times the diameter of the state space, be- cause each macro is an optimal solution to a particular subgoal. Experimental Validation The batch learning algorithm has been tested in the domain of Eight Puzzle. An encouraging result is that our program was able to learn with far fewer num- ber of examples than predicted by the theory. With E and S set to 0.1, and n = h(n) = 9, the theoreti- cal estimate of the number of examples is around 780. However, our program was able to learn the full macro- table and one of the correct feature orderings with only 23 examples with a uniform distribution over the prob- lems. As expected, the problem solving after learning was extremely fast, and is invariant with respect to the number of macros learned. The difference in the number of examples can be at- tributed to the worst-case nature of the theoretical es- timates. For example, knowing that only about half of the macro-table needs to be filled to completely solve the domain reduces the theoretical bound by about half. Knowing that there are many possible correct fea- ture orderings (all orderings that order the blank as the first feature) would further reduce this estimate. The distribution independence assumptions of the theory also contribute to an inflated estimate of the number of training examples. Discussion Our paper introduced the notion of batch problem solving, which seems more amenable to learning than incremental problem solving. The idea of batch prob- lem solving is very general and can be used in conjunc- tion with other learning algorithms as well. We showed that it helps avoid unnecessary backtracking by using information from multiple problems. Backtracking is avoided when there are many correct feature orderings, as in the Eight Puzzle domain, as well as when there are only a few. In the case when there are many such orderings, the program will have many opportunities to find a correct one, and is likely to avoid backtracking. When there are only a few orderings, then most of the incorrect orderings are likely to be ruled out by discov- ering conflicts, once again avoiding backtracking. Even when an incorrect feature ordering is learned due to a skewed problem distribution, this might still probably result in an approximately correct problem solver, be- Tadepalli 233 cause the same distribution that was used in learning is also to be used in testing the problem solver. Our algorithm has interesting consequences to sys- tems that combine “empirical” and “explanation- based” learning methods. For example, both A-EBL of [Cohen 19921 and IOE of [Dietterich & Flann 19891 em- pirically generalize complete explanations. We char- acterize speedup learning as finding a tractable prob- lem solver for a given problem distribution and a given bias. The best algorithm for a given bias might finely combine the features of “empirical” and “explanation- based” approaches. For example, it may be appro- priate to empirically combine parts of the explana- tions of many examples, which might in turn help find the remaining parts of the explanations. This is ex- actly what our algorithm does, while exploiting the serial decomposability property of the domain. Just as there is no single general-purpose concept learn- ing algorithm, there is also no effective general-purpose speedup learning algorithm. Our methodology points to building special-purpose learning algorithms that are specifically designed to exploit various structural properties of sets of problem domains. We aim to build a tool box of speedup learning algorithms, each algo- rithm implementing a particular bias. Conclusions This paper integrates work from a number of areas in- cluding EBL, PAC learning, and macro-operator learn- ing. We introduced a new model of speedup learning, which extended our earlier work by placing the respon- sibility to solve the training problems on the learner. In this sense, it is “unsupervised.” We presented a new, implemented algorithm that learns feature order- ings and macros for serially decomposable domains, and showed it to be correct and effective. We also in- troduced the idea of batch problem solving which ap- pears more powerful than sequential problem solving in the context of speedup learning systems. Acknowledgments I am indebted to Balas Natarajan for introducing me to theoretical machine learning and lending me his hand whenever I needed it. I thank Jonathan Gratch, Srid- har Mahadevan, and the reviewers of this paper for many helpful comments. References Blumer, A., Ehrenfeucht, A., Haussler, D. and War- muth, M. Occam’s razor. Information Processing Letters, 24:377-380, 1987. Cohen, W. Solution path caching mechanisms which provably improve performance. Technical Report DCS-TR-254, Rutgers University, 1989. Cohen, W. Abductive explanation-based learning: A solution to the multiple inconsistent explanation problem. Machine Learning, 8, 1992. Dejong, G. and Mooney, R. Explanation-based learn- ing: A differentiating view. Machine Learning, 2, 1986. Elkan, C. and Greiner, R. Measuring and improving the effectiveness of representations. In Proceedings of IJCAI-91, Morgan Kaufmann, San Mateo, CA, 1991. Etzioni, 0. Why PRODIGY/EBL works. In Proceed- ings of AAAI-90, MIT Press, Cambridge, MA, 1990. Flann, N. and Dietterich, T. G. A study of explanation-based methods for inductive learning. Machine Learning, 4, 1989. Greiner, R and Likuski, J. Incorporating redundant learned rules: A preliminary formal analysis of EBL. In Proceedings of IJCAI-89, Morgan Kaufmann, San Mateo, CA, 1989. Korf, R. Macro-operators: A weak method for learn- ing. Artificial Intelligence, 26, 1985. Laird, J. E., Rosenbloom, P. S., and Newell, A. Chunking in Soar: The anatomy of a general learning mechanism. Machine Learning, 1, 1986. Laird, P. and Gamble, E. Extending EBG to term- rewriting systems. In Proceedings of AAAI-90, MIT Press, Cambridge, MA, 1990. Minton, S. Quantitative results concerning the utility of explanation-based learning. Artificial Intelligence, 42, 1990. Mitchell, T., Keller, R., and Kedar-Cabelli, S. Explanation-based generalization: A unifying view. Machine Learning, 1, 1986. Natarajan, B., and Tadepalli, P. Two new frame- works for learning. In Proceedings of Machine Learn- ing Conference, Morgan Kaufmann, San Mateo, CA, 1988. Natarajan, B. On learning from exercises. In Proceed- ings of Computational Learning Theory Conference, Morgan Kaufmann, San Mateo, CA, 1989. Natarajan, B. Machine Learning: A Theoretical Ap- proach. Morgan Kauffman, 1991. Ratner, D. and Warmuth, M. Finding a shortest so- lution for the N X N extension of the 15-PUZZLE is intractable. In Proceedings of AAAI-86, Morgan Kaufmann, San Mateo, CA, 1986. Subramanian, D. and Feldman, R. The utility of EBL in recursive domain theories. In Proceedings of AAAI- 90, MIT Press, Cambridge, MA, 1990. Tadepalli, P. A formalization of explanation-based macro-operator learning. In Proceedings of IJCAI-91, Morgan Kaufmann, San Mateo, CA, 1991. Tadepalli, P. Learning with Inscrutable Theories. In Proceedings of International Machine Learning Work- shop, Morgan kaufmann, San Mateo, CA, 1991. Valiant, L. G. A theory of the learnable. Communi- cations of the ACM, 11, 1984. 234 Learning: Theory | 1992 | 51 |
1,245 | Statistical A to Solving t ti Russell Greiner* Siemens Corporate Research Princeton, NJ 08540 greiilep~leztrilii~g.sienleiis.com Abstract h4any “learning from experience” systems use information estractecl from problem solving ex- periences to moclify a performance element PE, forming a new element PE’ that can solve these and similar problems more efficiently. How- ever, as transformations that improve perfor- mance on one set of problems can degrade per- formance on other sets, the new PE’ is not al- ways better than tile original PE; this depends on tlie clistribution of problems. We therefore seek the performance element whose expected perfornamce, over this distribution, is optimal. Unfortmiately. the actual clistribntion. which is needed to determine which element is opti- mal, is usually not known. h>Ioreover, the task of finding the optimal element. cvcn knowing tlie distribution, is intractable for most inter- esting spaces of elements. This paper presents a method, PALO, tliat sicle-steps these prob- lems by nsing a set of samples to estimate the uiil;nown distribution. and by using a set of tr&sformations to Bill-climb to a local opti- 11111111. Tllis process is based on a mathemat- ically rigorous form of utility unulgsis: in par- ticular, it uses statistical tecliniqm33 to deter- mine whether the result of a proposecl transfor- mation will be better than the original system. We also present an efficient way of implement- ing this learning system in the contest of a gen- eral class of performance elements, and include empirical evidence that this approach can work effectively. *Much of this work was performed at the University of Toronto, where it was supported by t,he Institute for Robotics and Intelligent Systems and By an operating grant from the National Science and Engineering Research Council of Canada. We also gratefully acknowledge receiving many helpful comments from William Cohen. Dave Mitchell, Dale Schuurmans and the anonymous referees. ‘Supported 1)~ a University of Toront.0 Open Fellowship and a Research Assistantship from the Department of Com- puter Science. Igsr JuriSicd Departiiieiit of Computer Science University of Toronto Toronto; Ontario M5S 1A4: Canada juris@cs.toroi~to.edu I Introduction Problem solving is inherently combinatorially expensive [NilSO]. There are, of course, many methocls designed to sicle-step this problem. One collection of techniques is based on the observation that many problems oc- cur repeatedly; this has led to a nmnber of “learning from esperience” (or “LFE”) systems [DeJSS, hdCI<+SS. LNR87] that each use,information gleaned from one set of problem solving esperiences to modify the unclerly- ing problem solver. forming a new one capable of solving similar problems more efficiently. Unfortmiatcly. a modification that improves the prob- lem solver’s performance for 011~ set of problems can clegracle its performance for other problems [hiinS$b, GreSl]; hence. many of these modifications will in fact lower the system’s overall performance. This paper aclclresses this problem (often called the “EBL’ utility problem” [h%lSSb, SERSl]) 1 )y using a statistical tech- nique to cletermine whether the result of a proposed modification will, with provably high confidence, be bcf- ter than the original system. We cstcncl this tcclinique to develop a LFE algorithm, PALO. that produces a sys- tem whose performance is, with arbitrarily big11 prob- ability. arbitrarily close to a local optimum. We then focus on an instantiation of this general PALO algorithm that can solve a learning problem that provably camlot be algorithmically solved in a stronger sense. as well as empirical clata that demonstrates PALO’s effectiveness. In more cletail [Bh!ISJ%]: ,4 performance element PE is a program that attempts to solve the given problems. A learning element LFE uses information gleaned from these problem solving esperience(s) to transform PE into a new performance element: PE’.’ Just as coil- cept learning can be characterized as a search through a space of possible concept descriptions [kIit$2], so the LFE system can be viewed as searching throng11 a space of possible PEs, seeking a new performance element PE’ whose performance is superior to that of the original PE. Typical LFES traverse the space of possible PEs using transformations tllat modify a given PE by adding ’ **EBL” ablxcviat,cs “&planation-IJasd hcarning” . “These t,wo components. PE and LFE. may correspond the same hundlc of code: cf.. SOAR [LNRS’T]. We often view this PE’ as a modified version of PE. Greiner and Jur%ica 241 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. macro-rules, re-ordering isting rules, and so on. the rules, adding censors to ex- Our previous papers have presented algorithms that find the PE’ whose performance is optimal [GL89, GreSl] or nearly-optimal [OG90, G091]? where perfor- mance is measured as the expected cost of a PE over some fixed distribution of problems. Unfortunately, the task of finding the globally optimal PE is intractable for most interesting cases [GreSl]. In contrast F most other previous LFE research [DeJ88, MCIi+89, LNR87] has focused on experimen- tal techniques for incrementally modifying a problem solver, producing a series of performance elements PEo, . . . , PE, where each PE i+i is a modification of PEi (e.g., PEi+i might contain one new macro-rule not in PE;). Unfortunately, esisting methods do not always guarantee that each PE i+l is an improvement over PEi; a fortiori, the overall m-step process may produce a final PE, that is not even superior to the initial PEe, much less one that is optimum in the space of PEs.~ This paper integrates ideas from both lines of research, by describing a tractable incremental algorithm that is (probabilistically) g uaranteed to find a locally optimal performance element. Iii particular, Section 2 motivates the use of “expected cost” as a quality metric for per- formance elements. Section 3 then clescribes a statisti- cal tool for evaluating whether the result of a proposed modification is better (with respect to this metric) than the original PE; this tool can be viewed as mathemat- ically rigorous version of [MiiQBa] ‘s “utility analysis” . It uses this tool to define the general PALO algorithm, that incrementally produces a series of performance ele- ments PEo, . . . , PE, such that each PEi+i is statisti- cally likely to be an incremental improvement over PEi and, with high confidence, the performance of the final element PE, is essentially a local optimal. Finally, Sec- tion 4 presents an instantiation of this program that uses a specific set of transformations to “hill-climb” in a par- ticular, very general, space of performance elements. It also presents an efficient way of obtaining approsima- tions to the information PALO needs? and provides em- pirical evidence that this program does work effectively. Here, PALO is efficiently finding a locally optimal PEl, in a space of PEs for which the globally optimal PE,, cannot be tractably found. The conclusion discusses how this work extends related research. 2 Framework We view each performance element PE as a function that takes as input a problem (or query or goal, etc.) to solve, q, and returns an answer. In general, we can consider a large set of (implicitly defined) possible performance elements, (PEi}; Section 4 considers the naturally oc- curring set of problem solvers that use different control strategies. Which of these elements should we use; i.e., which is “best”? The answer is obvious: The best PE is the one that performs best in practice. To quantify this, we need 3Section 5 provides a more comprehcnsiye literature search, and includes a few exceptions to the above claims. 242 Learning: Utility and Bias to define some measure on these elements: We start by defining c(PEj, 4;) to be the “cost” required for PEj to solve the problem qi. (The c(., .) function defined in Section 4 measures the time required to find a solution.) This cost function specifies which PEj is best for a sin- gle problem. Our PEjs, however, will have to solve an entire ensemble of problems & = { 4; }; we clearly prefer the element that is best overall. We therefore consider the distribution of queries that our performance element will encounter, which is modelled by a probability func- tion, Pr : & I+ [0, 11, where Pr[ qi ] denotes the proba- bility that the problem qi is selected. This Pr[ -1 reflects the distribution of problems our PE is actually acldress- ing; n. b., it is not likely to be a uniform distribution over all possible problems [Go179], nor will it necessarily correspond to any particular collection of “benchmark challenge problems” [Ke187]. We can then define the expected cost of a performance element : C[ PE] ‘ef E[c(PE, q)] = c Pr[cl] x c(PE, cd qEQ Our mlderlying challenge is to find the performance element whose expected cost is minimal. There are! however, two problems with this approach: First, we know to know the distribution of queries to determine the expected cost of any element and hence which cle- ment is optimal; unfortunately the distribution is usually not known. Second, even if we knew that distribution information, the task of identifying the optimal element is often intractable. 3 The PALO &prithm This section presents a learning system, PALO, that side-steps the above problems by using a set of sample queries to estimate the distribution, and by efficiently hill-climbing from a given initial PEo to one that is, with high probability, close to a local optimm11. This section first states the theorem that specifies PALO’s fimctional- ity, then summarizes PALO’s code and sketches a proof of the theorem. PALO takes as arguments an initial PEa and param- eters e, 6 > 0. It uses a set of sample queries clrawn at random from the Pr[ .] distribution4 to climb from the initial PEe to a final PE,, using a particular set of possible transformations T = { rj } , where each Tj maps one given performance element into another; see Subsec- tion 4.2. PALO then returns this final PE,,. Theorem 1 states our main theoretical results.5 Theorem 1 The PALO( PEo, E, 6) process increnaen- tally produces a series of performance elements PEo, PE1,. . . , PE,, staying at a particular PEj for only a podynomial number of samples before either clinab- ing to PEj+i or terminating. With probubility at Zeast 1 - 6, PALO will terminate. It then returns un element *These samples may be produced by the user, who is sim- ply asking questions relevant to one of his tasks. 5Tllis proof, and others, appear in the espanded version of this paper [GJ92]. Algorithm PALO( PEo, E, 6 ) e ico jto Ll: Let S + {} Neigh C- { rk(PEj)}k A maz = max { h[PE’, PEj] ] PE’ E Neigh } L2: Get query q (from the user). Let s + su {a) i t i + INeigh] e If there is some PE’ E Neigh such that A[PE’, PEj,S] 2 R[PE’, PEj] Jm then let PEj+r + PE’, j + j + 1. Return to Ll. e If ISI > 2A$ae In $$ ( > and VPE’ E Neigh. A[PE’, PEj, S] < 9 then halt and return as output PEj- o Otherwise, return to L2. (1) (2) Figure 1: Code for PALO PE, whose expected utility c[ PE,, ] is, with probability at least 1 - S, both 1. at least’ as good as the orh$nal PEe; i.e., C[PE,] 5 q PEo]; and 2. an E-local optimum’ - i.e., V7-j E 1. qPEm] 5 c[. Tj(PEm.) ] + E Cl. The basic code for PALO appears in Figure 1. In essence, PALO will climb from PEj to a new PEj+i if PEj+l is likely to be strictly better than PEj; i.e., if we are highly confident that C[ PEj+i ] < C[ PEj 1. TO determine this, define cli = A[PE,, PEp,qi] dLf c(PE,, qi) - c(PEp, qi) to be the difference in cost between using PE, to deal with the problem qi, and using PEP. AS each query qi is selected randomly according to a fixed distribution, these dis are independent, identically distributed random vari- ables whose common mean is ,X = C[ PE, ] - C[ PEP 1. (Notice PEP is better than PE, if 1-1 > 0.) Let Y, ‘zf iA[PE,, PEP, {q;)F=i ] be the sam- ple mean over n samples, where A[PEa, PEB, S] def Cq&wL 4) - c(PEp, 4) for any set of queries S. This average tends to the population mean, p as n -+ 00; i.e., p = lim,,, Y,z. Chernoff bounds [Che52] describe the probable rate of convergence: the probability that “I<, is more than p + y” goes to 0 exponentially fast as n increases; and, for a fixed n, exponentially as y increases. Formally, ‘Notice a “O-local optimal” corresponds to the stanclard notion of “local optimal”; hence “e-local optimal” generalizes local optimality. where A is the range of possible values of c(PE,, gi) - c(PEp, qi).7 This A = A[PE,, PEp] is also Lzsed in both the specification of A,,, and in Equation 1. Section 4.2 below discusses how to compute this value for relevant PE;/rj (PEi) pairs. The PALO algorithm uses these equations and the val- ues of A[ PE’, PEj, S] to determine both how confident we should be that C[ PE’] > C[ PEj ] (Equation 1) and whether any “7-neighbor” of PEj (i.e., any rk(PEj) ) is more than E better than PEj (Equation 2). 4 Instantiation: Learning Go0 Strategies The algorithm shown above can deal with essentially ar- bitrary sets of performance elements, cost functions and sets of transformations. This section presents a par- ticular instantiation of this framework: Subsection 4.1 presents a moclel for a general class of “graph-based per- formance elements” ‘PEG and the obvious cost function. Subsection 4.2 then describes the set of “re-ordering” transformations IRo, each of which re-arranges the or- der in which PE traverses the arcs of the graph. It also describes an efficient way of approsimating the values of A[rj(PE), PE, S]. S u b section 4.3 presents some em- pirical results that demonstrate that a system that uses these approximations can be effective. We choose the PEG class of performance elements as it corresponds to many standard problem solvers (includ- ing PROLOG [CiVfSl]; see also [GNU]); and the IRo class of transformations on strategies, as it corresponds to many EBL systems and moreover, the task of finding the global optimality strategy is NP-hard [GreSl]. 4.1 Graph Based PEs This subsection uses a particularly simple performance element PEo to illustrate the class PEG, whose elements each correspond to a finite graph whose arcs have fixed costs. After describing a relatively simple model. it presents several extensions, leading to a more realistic, comprehensive model. The PEe element is based on the rules shown in the upper left corner of Figure 2 (producing the correspond- ing “reduction graph” shown in that figure), operating with respect to the facts shown in the lower left corner. We focus on how this system deals with queries of the form GoodCar , for some ground K - e.g., returning Yes to the queries GoodCar(D1) and GoodCar(D2)) and No to the queries GoodCar(D4) and GoodCar(Fido) . In general, we can identify each performance element PE = (6, 0) E PEG with a reduction graph G and a strategy 0, where a reduction graph G = (N, A. S, f) is a structure formed by a set of rules: 1’v is a set of nodes (each corresponding to a proposition; e.g., the nocle iVe corresponds to “GoodCar( K> ” and ~1’2 corresponds to the empty disjunction), and A c N x N is a set of arcs, each corresponding either to the use of a rule (e.g., the al arc ‘See [Bol85, p. 121. N.b., these inequalities holds for cssen- tially urbitrury distributions, not just normal distributions, subject, only to the minor constraint that the sequence {A;} has a finite second moment. Greiner and Juri%ca 243 a~: (Attempt: Cheap(n) - Fact Set Cheap(D2), Cheap(D3) , Cheap(D51, . . . Red(Di), Red(D3), Red(DEi), . . . Gold(DG), . . . pt: Gold(K)) Figure 2: “Reduction Graph” GA (used by PEQ and PEr) from No to Nr is based on the rule RI) or a database retrieval (e.g., the u2 arc from Nr to N2 corresponds to the attempted database retrieval Cheap(K)). The set S c N is the subset of N’s “success nodes” (here, each is an empty disjunction such as N2 or N5, shown in doubled hoses); reaching any of these nodes means the proof is successful. The cost function f : A H 7Z$ maps each arc to a non-negative value that is the cost required to perform this reduction. We will let fi refer to the value of f(@ The strategy 0 specifies how the PE will traverses its graph G. Here, it corresponds to a simple sequence of arcs, e.g., @(my) = (al, a2, a3, a4, a5, a6, a7) (3) is the obvious left-to-right depth-first strategy, with the understanding that PE = (GA, Otcrg)) stops whenever it reaches a success node (e.g., if a2 succeeds, then PEe reaches N2 and so stops with success), or has exhausted all of its reductions.’ There are other possible strategies, including other non-left-to-right depth-first strategies, e.g., q?-9,) = (a3, a4, a5, a3, a7, al, a2) as well as non-depth-first strategies, etc. (4) We focus on two members of P4?G: PEe = (G.4, Q-,)) and P& = (GA, @(,,,)). Cost of Solving Problems: We can compute the cost for PEj to solve qi, c( PEj, gi), from the above specifi- cation. For example, c(PEa, GoodCar(D2) ) = fi + f2, ad @Eo, GoodCar( = fl + f2 + f3 + f-4 + f5, as the (al, up) path failed as Cheap(D1) is not in the fact set. As each strategy stops as soon as it finds an answer, clifferent strategies can different costs for a given query; e.g., c(PE1, GoodCar(D1)) = fa + f4 + f5 differs from c( PEe , GoodCar (Dl) ), etc. We can view each strategy as a sequence of paths, where each path is a sequence of arcs that descend ‘Notice that strategies, in&ding PEo, accept the first solution found, meaning they are performing “satisficing searches” [SK75].Hence, we are only considering the cost re- quired to produce an answer, and not the quality of the an- swcr itself. There are obvious extensions to this cost model that can incorporate different utility values for answers of different8 “qualities”; see [GE91]. 244 Learning: Utility and Bias from some already-visited node down to a retrieval; e.g., 01 = ( (a1 a2), ( a3 a4 as), (~6 a~) ). We define the e2- petted cost of a strategy as the weighted sum of the costs of its paths, each weighted by the probability that we will need to pursue this path, i.e., that none of the prior paths succeeded [Smi89, G091]. (Of course, the cost of a path is the sum of the cost of its arcs.) While the models of performance elements and cost presented above are sufficient for the rest of this article, they appear quite limited. We close this subsection by presenting some of the extensions that lead to a more comprehensive framework. N. b., the model presented in [GJ92] incorporates all of these extensions. Extendl. (G eneral Graph) The above definitions are sufficient for the class of simple “disjunctive reduction graphs”, which consist only of rules whose antecedents each include a single literal. To deal with more gen- eral rules: whose antecedents are conjunctions of more than one literal (e.g., “B(X)&!(X) + A(s)“)? we must use directed hyper-graphs: where each “hyper-arc” cle- scends from one node to a set of children nodes: where the conjunction of these nodes logically imply their common parent. We would also define S to be a set of subsets of N, where the query processor woulcl have to reach each member of some s E S for the deriva- tion to succeed. This extension leads to additional complications in specifying strategies; see also [G091, Appendis A]. Extend2. (Probabilistic Experiments) We say that “the arc ai is blocked in the context of the query q” if no strategy can traverse a; when answering the query q; e.g., the retrieval arc a2 is blocked in the contest of GoodCar(D1) as the associated literal Cheap(D1) is not in the fact set. So far, we have implicitly as- sumecl that retrieval arcs can be blocked, but rule- based arcs cannot. If we permit the literals in the rules to include constants, however, rule-based arcs can also be blockable. Consider, for esample, adding the rule “VX Owner(Fcar, s) + GoodCar(Fcar)“, which states that the particular car Fear is goocl if it is owned by anybody. Notice a performance element will be able to traverse the rule-based reduction arc from GoodCar (z) to Owner(Fcar, LC) only if the query is GoodCar(Fcar); notice this arc is blocked for every other query. Our model can handle these situations by allowing any arc (not just retrieval arcs) to be blockable. Extend3. (General Cost Function) The algorithms pre- sented in this paper can accommodate more compli- cated f(e) cost functions, which can allow the cost of traversing an arc to depend on other factors - e.g., the success or failure of that traversal, which other arcs have already been traversed, etc. Extend4 (Infinite Set of Queries) Our analysis can ac- commodate even an infinite number of queries, as we can partition them into a finite set of equivalence classes, where all members of an equivalence classes have the same cost for each strategy. This follows from the observation that the cost of using a strat- egy to solve a query depends only on which arcs are blocked, meaning we can identify each query with the subset of arcs that can are blocked for that query. For example, we can identify the query GoodCar(B1) with the arc-set (~2, a~} and GoodCar(B2) with {as, a7}, etc. 4.2 Re-Ordering Transformations This subsection considers a way of modifying a perfor- mance element PE = (G, 0) by reordering the strat- egy (i.e., changing from 0 to 0’) while preserving the underlying reduction graph G. For example, after-find- ing that (ai, a2) failed but the (u3, ~4, -us) path suc- ceeded, one might transform PEe = (GA, et,,,)) into PE1 = (GA, +-gc)), by moving a3 (and its children) be- fore al. (and its children). In general, given any reduction graph G = (N, A, S, f), define IRo = {~~1,~2}~1,~2 to be the set of all possible “simple strategy transformations”, as follows: Let rl, r2 E A be two arcs that each descend from a single node (e.g., al and a3 each descend from the node No); and consider any strategy @A = z-1 0 7l-2 0 7i-3 0 x4, (5) where the o operator is concatenation and each nj is a (possibly empty) sequence of arcs, and in particu- lar, ~2 = (rl, . . .) corresponds to rl and its children, and 7r3 = (~2, . . .), to r2 and its children.g Then og = rTl,r2 (@A) will be a strategy that differs from Oe only in that rl and all of its descendents are moved earlier in the strategy, to before r2; i.e., @B = 7rl,r2(@A) = 7r1 0 z-3 0 7r9 0 x4 . -2 (6) (To understand the transformation from @A = et,,,) to @B = %3,,, &rg)) = @(rgc): let x2 = (%,a2), ‘IT3 = (as, a4, u5, ~6, a~) and ~1 = ~4 = 0.) Notice that the rrr,r2 transformation will map a strategy 0 to itself if rl already comes before r2 in 0. TRo is the set of all such Trl ,r2S- Approximating A[PEi, PE’, S]: The PALO algorithm requires values of A[PE,: , rj (PEi), S] for each 7-j E 1. One obvious (though espensive) way of obtain- ing these values is to construct each rj(PEi) perfor- mance element, and run this element on each q E S, recording the total cost each requires. This can be expensive, especially when there are many differ- ent rj (PEi)s. Fortunately, there is an alternative that involves running only the PEi element and us- ing the statistics obtained to find both under-estimates L(PE;, rj(PEi), S) 5 A[PE;, rj(PE;), S] and over- estimates U(PEi, rj(PEi), S) 2 A[PEi, rj(PEi), S], that can be used in Equations 1 and 2, respectively. In general, the PEA = (G, @A) element terminates as soon as it finds an answer; based on the decomposition shown in Equation 5, there are four cases to consider, de- pending on the path (one of { ~1,7r2,7r3,7r4}) in which this first answer appears. (For our purposes here, we view “finding no answer at all” as “finding the first answer in the final 7r4” .) If this first answer appears in either or ~1 or ~4, then A[PEA, PEB,~] = 0, where PEB = (G, 0~) from Equation 6. If the first answer appears in ~3, then we know that A[PEA, PEB,~] = f(rz), where f(ri) in general is the sum of the costs of the arcs in 7ri. For ex- ample, consider using PEe to deal with the Goodcar (Di) query: As the a2 arc fails and a5 succeeds, the first an- swer appears within 7r3 = (as, ~4, u5,a6, a7). PEo will find that answer, after it has first examined the path 7i2 = (al, a2) at a .cost of f(r2) = f( (al, a2)) = f-1 + f2. Notice PEr would also find this same solution in ~3. However, PEi would not have first examined ~2, mean- ing its cost is f(7r2) kess than the cost .of PEo. Hence, A(PEo,PEr,GoodCar(Dl)) = f(n2). The situation is more complicated if the first an- swer appears in 74, as the value of A[PEA, PEB. Q] de- pends on information that we cannot observe by watch- ing PEA alone. (E.g., consider using PEo to deal with Goodcar(D2). As a2 succeeds, PEo’s first answer appears in 7r2. As PEe then terminates, we do not know whether an answer would have appeared within ns.) While we cannot determine the exact value of A[PEA, PEB, 41 in these situations, we can obtain up- per and lower bounds, based on whether a solution would have appeared in those unexplored paths: here -f( 7r3) 5 A[PEA, PEB, 41 5 f(7r2) - f+(n3), where f+(ns) is de- fined to be the cost of finding the first possible solution in the path 7rs. (E.g., f+(( a3~~4~a5~a6~a7)) =f3+f4+.f5, as this is the first solution that could be found. Notice this under-estimates the cost of this path in every sit- uation, and is the actual cost if the retrieval associated with a5 succeeds.) The table below gives the lower and upper bounds L(q) 5 A[PEA, PEB, q] 5 U(q), for all four cases (one for each 7ri):lO This table only bounds the value of A[ PEA, PEB, q] for a single sample. The value of A[ PEA, PEB, S] will be between L(PEA, PEB,S) def CclcsL(q) and ‘To simplify the presentation, this article will only con- sider depth-first strategies; [GJ92] extends this to deal with arbitrary strategies. “[G.J92] shows how to obt,ain slightly tighter bounds, based on information that is available from PE,4’s computation. Greiner and JuriGca 245 U(PEA, PEB, S) ‘ef C4eS U(q). To compute these bounds, we need only ma&ain a small number of coun- ters, to record the number of times a solution is found within each subpath: let kz (resp., ks) be the number of times then the first solution appears within r2 (resp., x3); L(PEA,PEB,S) = h * [f(r2>I - k2 * [-f(~3)I U(PEA,PEB,S) = k3 . [f(77.2)] + k2 . [f(nz) - f(r3>1 PALO’ Process: Now define PALO’ to be the variant of PALO that differs only by using these L(PE’, PEj, S) values (resp . , U(PE’, PEj, S) values) in place of A[PE’, PEj, S] in Equation 1 (resp., Equation 2). PALO’ can compute upper and lower bounds of A[PE, 7j(PE), S] for each ~~1,~2 E IRo using only the values of a small number of counters: in general, it needs to maintain only one counter per retrieval. To complete our description: PALO’ also needs one more counter to record the total number of sample queries seen, corresponding to 15’1. Equation 1 needs the (static) values of A[7,r,r2(PE~), PEA)] for each rk E IRo. Each ~~1.~2 induces a particular segmentation of each strategy into the subsequences @A -= n-1 0 7r2 0 7r3 0 x4. Here, +~,Y~(PEA), PEA] = f(r2) + f(n), as each value of A[ v-,~,~~(PEA), PEA, 41 is in the range t-f(r3)7 f(r2)l. 4.3 Empirical Results The PALO algorithm only works “statistically”, in that its results are guaranteed only if the samples it sees are truly representative of the distribution, and moreover, if the distribution from which these samples is drawn is sta- tionary. The PALO’ algorithm is even more problematic, as it only uses approximations of the needed statistics. Given these hedges, it is not obvious that the PALO’ algorithm should realZy work in a real domain. We are beginning to experiment with it in various real domains, including expert systems and natural language proces- sors. Here, we report on its performance in various artificial settings, where we can insure that the distribution is stationary. l1 Consider again the reduction graph shown in Figure 2, and’assume unit cost for’each arc, whether it represents a rule-based reduction or a database retrieval. We will define the distribution of queries in terms of the (independent) probabilities of the various database retrievals; here, P( Cheap(%) in Fact Set } GoodCar query asked) = 0.01 P( Red(K) in Fact Set 1 GoodCar query asked ) = 0.2 P( Gold(&) in Fact Set 1 GoodCar query asked) = 0.8 Given these values, it is easy to compute the expected costs of the various strategies [Smi89]: C[ O(,,,) ] = 3.772, C[ @(,,) ] = 3.178, C[ @(,,,)I = 2.96 and CL @(,t-c) 1 = 2.36; hence, the optimal strategy is l1 We decided against using a blocks-world example as it would be more complicated to describe, but would be no more meaningful as we would still have to make up a distribution of problems, specifying how often a problem involves stacking blocks,, versus forming arches, versus . . . 246 Learning: Utility and Bias q,,,). l2 Of course, we do not initially know these prob- ability values, and so do not know which strategy is op- timal. We ran a set of experiments to determine whether PALO’, starting with Olcrg), would be able to find a good strategy. We set S = 0.05 (i.e., a 95% confidence bound), and considered E E (1.0, 0.5, 0.2, 0.1, 0.05 ), trying 10 trials for each value. Using E = 1.0, PALO’ quickly found the strategy et,,,), which is a l.O-local optimum (even though it is not the global optimum). As et,,,) is “7”“-adjacent” to the initial O(,,,), this meant PALO’ performed only one hill- climbing step. PALO’ used an average of ]Sl fi: 5.3 sam- ple queries to justify climbing to et,,,), and another on average = 44 queries to realize this strategy was good enough; hence, this total learning process required on average M 49 total queries. For the smaller values of E, PALO’ always went from @(,,,) to @(,,,) as before, but then used a second hill-climbing step, to reach the globally-optimal O(,,,). As would be expected, the num- ber of steps required for each transition were about the same for all values of E (notice that Equation 1 does not involve E) : for E = 0.5, 0.2, 0.1, 0.05, PALO’ re- quired about 6.3, 6.6, 5.0, 5.4 samples to reach et,,,), and then an additional 31.5, 36.6, 39.0, 29.8 samples to reach a(,,,). The major expense was in deciding that this et,,,) was in fact an e-local optimum; here, this required an additional 204, 1275, 5101, 20427 samples, re- spectively. Notice this is not time wasted: the overall “0 ~g,,~-performance-element-&-PALO’-learning- element” system is still solving relevant, user-supplied, problems, and doing so at a cost that is only slightly more expensive than simply running the O(,,,)- performance-element alone, which we now know is an optimal element. In fact, if we ignore the Equation 2 part of PALO’s code, we have, in effect, an anytime al- gotithm [BD88, DB88], that simply returns better and better elements over time. Of course, there are advantages to knowing when we have reached a local optimum: First, we can then switch off the learning part and thereafter simply run this (prob- ably locally) optimal performance element. Second, if we are not happy with the performance of that element, a PALO-variant can then jump to different performance element in another part of the space, ‘and begin hill- climbing from there, possibly using a form of simulated annealing approach [RMt86]. The extended paper [GJ92] presents other experimen- tal data, based on other probability distributions, reduc- tion graphs, parameter values, and so forth. In general, PALO”s performance is similar to the above description: For each setting, PALO’ climbs appropriately, requiring successively more samples for each step. Our one sur- prise was in how conservative our approximations were: using the S = 0.05 setting, we had anticipated that PALO’ would miss (i.e., not reach an e-local optimal) approx- 12We continue to identify each strategy with the sequence of database retrievals that it will attempt. Hence, Ot,,.,) = (a5,a6:a7,a3,a4,al,a2). imately 1 time in 20. However, after several hundred runs, with various settings and graphs, we have found that PALO”s error rate is considerably under this rate. We are now experimenting with variants of PALO’ that are less conservative in their estimates, in the hope that they will be correspondingly less sample-hungry. (See also [GD92] .) Finally, while this paper has focused on but a single set of proposed transformations IRo, there are many other transformation sets TX that can also be used to find an efficient satisficing system; e.g., [Gre92a] dis- cusses a set of transformations that correspond to opera- tor compositions. l3 The “PALO-style” approach is not re- stricted to speed-up learning; it can also be used to build learning systems that can find performance elements that are nearly optimal in terms of other measures, in- cluding accuracy [Gre92d] or categoricity [Gre92b]; see also [GE91, Gre92c]. 5 Conclusion Comparison with other relevant research: There are many other research projects - both theoretical and empirical - that also address the task of using a set of examples to produce a more efficient performance ele- ment. Most of the formal models, however, either deal with learning problems that are far harder than the prob- lems actually attempted by real learning systems (e.g., [GL89, GregI]) or model only relatively narrow classes of learning algorithms (e.g., [NT88, CohSO]). By contrast, our model is very general and directly relevant to many systems. There are also a great number of existing LFE sys- tems, and considerable experimental work on the utility problem. Our research is not simply a retrospective anal- ysis of these systems; it also augments that experimental work in the following specific ways. First, we show an- alytically that one subproblem of the utility problem - the problem of determining if a proposed modification is in fact an improvement - can be (probabilistically) solved a priori (i.e., before building.that proposed mod- ified system), based on only a polynomial number of test cases. This result analytically confirms previous experi- mental results. Second, we show that utility analysis can be used to probabilistically guide an incremental learner to a performance element that is essentially a locally optimal PE. (While existing systems have used utility analysis when climbing to elements with superior perfor- mance, none have used it to produce elements that are guaranteed to be optimal, in even our weak sense.) Fi- nally, we can use our utility analysis to determine when not to learn - i.e., to determine when none of the pos- sible transformations is (likely to be) an improvement. While this aspect of utility analysis has not yet been 13This requires a slight variant of the basic PALO algorithm shown in Figure 1: That algorithm assumes that there is a fixed set of neighbors to a given performance element. By contrast, the number of possible macros depends on the num- ber of .rules in the system, which grows as more rules are added. This involves certain changes to the PALO algorithm; see [CG91]. investigated empirically, it is likely to be important in practice, as it can prevent a learning algorithm from modifying, and therefore possibly degrading, an initial element that happens to already be optimal. The cor- rect action for the learner to take for such initial PEs is simply to leave them unmodified - i.e., not to learn. The work reported in [GD91, GD92] is perhaps the most similar to ours, in that their system also uses a statistical technique to guarantee that the learned con- trol strategy will be an improvement, based on a utility analysis. Our work differs, as we formally prove specific bounds on the sample complexity, and provide a learn- ing system whose resulting PE’ is (with high probability) both superior to the initial PE and a local optimal. Contributions: Learning from experience (LFE) re- search is motivated by the assumption that problems are likely to reoccur, meaning it may be worth trans- forming an initial performance element into a new one that performs well on these problems. Most existing LFE systems actually perform a series of such transfor- mations; in essence searching through a space of possible PEs, seeking an efficient performance element PE’. This underlying efficiency measure depends on the overall clis- tribution, which unfortunately is typically unknown. We therefore define an algorithm PALO that can use samples to reliably navigate through this space of possible per- formance elements, to reach a PE’ that is essentially a local optimal. These transformations require certain sta- tistical information; we also describe how to obtain such information efficiently -- at a cost that is only minimally more expensive than running a single performance ele- ment. Finally, we present a specific application of this algorithm for a particular relevant space of PEs, one for which the task of finding a globally optimal PE is NP- complete, and include empirical data that confirms that the PALO system can work efiectively. References [BD88] [BMS 5781 [Bo185] [CG91] [Che52] [CM811 [CohSO] M. Boddy and T. Dean. Solving time depen- dent planning problems. Technical report, Brown University, 1988. 13. Buchanan, T. Mitchell, R. Smith, and C. Johnson, Jr. Models of learning systems. In Encyclopedia of Computer Science and Technology, volume 11. Dekker, 1978. B. Bollobas. Random Graphs. Academic Press, 1985. W. Cohen and R. Grciner. Probabilistic hill climbing. In Proceedings of CLNL-91. Berke- ley, September 1991. H. Chernoff. A measure of asymptotic effi- ciency for tests of a hypothesis based on the sums of observations. Annals of Matkematl:- cal Statistics, 23:493-507, 1952. W. Clocksin and C. Mellish. Programming in Prolog. Springer-Verlag, New York, 1981. W. Cohen. Using distribution-free learning theory to analyze chunking. In Proceeding of CSCSI-90, 1990. Greiner and JuriGca 247 [DB88] [De 5881 [GD91] [GD92] [GE911 [GJ92] [GL89] [GN87] [GO911 [Go1791 [GreSl] [ Gre92a] [ Gre92b] [ Gre92c] [Gre92d] [KelS’T] [LNR87] per T. Dean and M. Boddy. An analysis of time-dependent planning. In Proceedings of AAAI-88, 1988. G. DeJong. AAAI workshop on Explanation- Based Learning. Sponsored by AAAI, 1988. J. Gratch and G. DeJong. A hybrid approach to guaranteed effective control strategies. In Proceedings of I WML-91, 1991. J. Gratch and G. DeJong. COMPOSER: A probabilistic solution to the utility prob- lem in speed-up learning. In Proceedings of AAAI-92, 1992. R. Greiner and C. Elkan. Measuring and im- proving the effectiveness of representations. In Proceedings of IJCAI-91, 1991. R. Greiner and I. Jurisica. EBL systems that (almost) always improve performance. Tech- nical report, Siemens Corporate Research, 1992. R. Greiner and J. Likuski. Incorporating re- dundant learned rules: A preliminary formal analysis of EBL. In Proceedings of IJCAI-89, 1989. M. Genesereth and N. Nilsson. Logical Foun- dations of Artificial Intelligence. Morgan Kaufmann Publishers, Inc., Los Altos, CA, 1987. R. Greiner and P. Orponen. Probably ap- proximately optimal derivation strategies. In Proceeding of KR-89, 1991. A. Goldberg. An average case complexity analysis of the satisfiability problem. In Pro- ceedings of CADE-79, 1979. R. Greiner. Finding the optimal derivation strategy in a redundant knowledge base. Ar- tifi&Z Intelligence, 50( 1):95-116, 1991. R. Greiner. Effective operator composi- tion. Technical report, Siemens Corporate Research, 1992. R. Greiner. Learning near optimal horn ap- proximations. In Proceedings of Knowledge Assimilation Symposium, Stanford, 1992. R. Greiner. Probabilistic hill-climbing: The- ory and applications. In PrQceedings of CSCSI-92, 1992. R. Greiner. Producing more accurate rep- resentational systems. Technical report, Siemens Corporate Research, 1992. Richard M. Keller. Defining operationality for explanation-based learning. In Proceed- ings of AAAI-87, 1987. J. Laircl, A. Newell, and P. Rosenbloom. SOAR: An architecture of general intelli- gence. Artificial Intelligence, 33(3), 1987. [MCK+89] S. Minton, J. Carbonell, C. Knoblock, D. Kuokka, 0. Etzioni, and Y. Gil. [Min88a] [Min88b] [Mit82] [Nil801 [NT881 [OG90] [RMt86] [SERSl] [SK751 [Smi89] Explanation-based learning: A problem solving perspective. Artificial Intelligence, 40(1-3):63-l 19, September 1989. S. Minton. Learning Search Control Knoawl- edge: An Explanation- Based Approech. Kluwer Academic Publishers, Hingham, MA, 1988. S. Minton. Quantitative results concerning the utility of explanation-based learning. In Proceedings of AAAI-88, 1988. T. Mitchell. Generalization as search. Art@ cial Intelligence, 18(2):203-26, March 1982. N. Nilsson. Principles of Artifical Intelli- gence. Tioga Press, Palo Alto, 1980. B. Natarajan and P. Tadepalli. Two frame- works for learning. In Proceedings of ML-88, 1988. P. Orponen and R. Greiner. On the sample complexity of finding good search strategies. In Proceedings of COLT-90: 1990. D. Rumelhart, J. McClelland, and the PDP Research Group, editors. Parallel Dis- tributed Processing: Explorations in the Mi- crostructure of Cognition, volume 1: Foun- dations. The MIT Press, Cambridge, 1986. A. Segre, C. Elkan, and A. Russell. A criti- cal look at experimental evaluations of EBL. Machine Learning Journal, 6(2), 1991. H. Simon and J. Kadane. Optimal problem- solving search: All-or-none solutions. Artifi- cial Intelligence, 61235-247, 1975. D .Smith. Controlling backward inference. Artificial Intelligence, 39(2):145-208, 1989. 248 Learning: Utility and Bias | 1992 | 52 |
1,246 | ir Lawrence B. Holder Department of Computer Science Engineering University of Texas at Arlington Box 19015, Arlington, TX 76019-0015 holder@cse.uta.edu Abstract The overfit problem in inductive learning and the utility problem in speedup learning both describe a common behavior of machine learning methods: the eventual degradation of performance due to increasing amounts of learned knowledge. Plot- ting the performance of the changing knowledge during execution of a learning method (the per- formance response) reveals similar curves for sev- eral methods. The performance response gener- ally indicates an increase to a single peak fol- lowed by a more gradual decrease in performance. The similarity in performance responses suggests a model relating performance to the amount of learned knowledge. This paper provides empiri- cal evidence for the existence of a general model by plotting the performance responses of several learning programs. Formal models of the perfor- mance response are also discussed. These models can be used to control the amount of learning and avoid degradation of performance. Introduction As machine learning methods acquire increasing amounts of knowledge based on imperfect (e.g., sparse, noisy, low probability) instances, the amount of low- utility knowledge increases, and performance degrades. The general utility problem in machine learning refers to the degradation of performance due to increas- ing amounts of learned knowledge [Holder, 19901. This term derives from the utility problem used by Minton [1988] to describe this phenomenon in speedup learning, but generalizes to other machine learning paradigms. Other researchers have observed the ubiquity of the utility problem in machine learning paradigms and compare the utility problem in speedup learning to the problems of noise and overfit in induc- tive learning [Yoo and Fisher, 19911. This work sug- gests that individual methods for avoiding the general utility problem may derive from a general model of the relationship between learned knowledge and per- formance that applies to several learning paradigms. Amount of Learned Knowledge Figure 1: Performance era1 utility problem. response indicative of the gen- identifying this lrlodel would provide a general mech- allisrn for preventing performance degradation due to the general utility problem. The analysis in this paper reveals some irnportant properties of such a model. A useful tool for analyzing the general utility prob- lem in machine learning is the performance response: the performance of the learned knowledge measured during the course of learning (see Figure 1). The units along the horizontal axis represent a simple transfor- mation in the learner’s hypothesis. For example, the transforrnatiorl performed by a splitting method is a single split . Since a knowledge transformation may not always increase the amount of learned knowledge in terirls of the size of the knowledge, an increase along this axis represents a refinement of existing knowledge. The vertical axis of the performance response measures the perforinance of the learned knowledge after each transformation. The classification accuracy of induc- tive learners and the problem-solving time of speedup learners are the focus of this work. Figure 1 illustrates the typical performance response of a learning method that suffers from the general util- ity problem: an initial performance increase to a sin- gle peal; followed by a more gradual decrease. The next two sections reveal this common trend in the per- formance responses of inductive and speedup learn- ers. A model of this trend can be used to avoid the performance clegradation by controlling the amount of lenrued knowledge to coincide with the peak of the performance response. Holder [1991a] describes the Molder 249 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. MBAC (Model-Based Adaptive Control) system that uses an empirical model of the performance response to control learning, MBAC adapts a parabolic model of the performance response peak by sampling the ac- tual performance response of the learner. Although the parabolic model forces MBAC to adhere to the trend in Figure 1, several samples are necessary to in- sure identification of the true peak. A separate model is maintained for each learning method/performance dimension pair. MBAC uses the models to select an appropriate learning method according to the model’s predicted peak performance. MBAC then invokes the learner, performing the number of knowledge transfor- mations necessary to reach the peak of the performance response model. Experimentation with MBAC shows that the parabolic model is capable of choosing an ap- propriate learning method and controlling that method [Holder, 1991a]. However, a more formal model of the performance response is necessary to improve the MBAC approach. The section following the empirical results discusses some preliminary formal models. Inductive Learning The general utility problem in inductive learning re- lates to the overfit problem. Overfit occurs when the learning method identifies errant patterns in the train- ing data. Errant patterns may arise due to noise in the training data or inadequate stopping criteria of the method. As demonstrated below, the overfit behavior of splitting, set-covering and neural network learning methods follow the general utility problem trend in Figure 1. Splitting Methods Splitting methods recursively split the set of training data by choosing an appropriate feature or feature- value pair. The knowledge produced by a splitting method can be represented as a decision tree. The learned knowledge changes every time the method makes a split; therefore, one choice for the x-axis of the performance response is the number of splits. The y-axis (performance) measures the classification accu- racy of the knowledge after each split, as measured using a separate set of test data. Figure 2 illustrates three performance responses ob- tained from the ID3 inductive learner [Quinlan, 198S] on the DNF2 domain [Pagallo and Haussler, 19901. Each performance response in Figure 2 represents a different decision tree node expansion order. Each per- formance response is an average over ten trials. Each trial consists of selecting random training and testing sets, generating the decision tree using the training set, and measuring accuracy after each split using the test- ing set. As Figure 2 reveals, the order of the knowledge transformations is important for perceiving the desired performance response trend in Figure 1. The effects of overfit increase as the decision tree becomes deeper; therefore, a breadth-first traversal of the tree defers h 0.88 iii s 0.86 8 Q 0.84 0.82 0.80 0.78 0.76 0.74 - Breadth First ...... Depth First 0.72 J I I I I I I 0 25 50 75 100 125 150 Figure 2: Performance responses of ID3 on the DNF2 domain for three different orders of decision tree ex- pansion. )r 0.75 l- 8 5 8 0.73 a 0.71 0.69 A 0.671 %p -_-- 0 10 20 30 40 50 60 70 80 Splits Figure 3: Performance response of ID3 on the Flag domain. overfit to later splits. A general-to-specific ordering along the amount of learned knowledge axis is necesi sary for perceiving the performance response trend in most learning methods suffering from the general util- ity problem. Figure 3 shows the performance response of ID3 on the Flag1 domain using the breadth-first splitting order. Both figures illustrate a performance response that follows the trend of Figure 1. The chi-square pre-pruning [Quinlan, 1986] and reduced-error post-pruning [Quinlan, 19871 techniques help to alleviate overfit, Gut on average the accuracy of the resulting tree is still less than the peak accuracy of the performance response. Similar results were ob- tained with the PLSl splitting method [Rendell, 19831, which uses an increase in the t, parameter to increase pruning. Table 1 shows that these pruning techniques do not completely alleviate the overfit problem. Set-covering Methods A set-covering method for inductive learning con- structs a hypGthesis which describes a subset -of the training insGnces, and then applies the same method ‘The Flag domain is available from the UC Irvine ma- clhe learning databases. 250 Learning: Utility and Bias Random Best Unique > 1 Complete Disjunct Figure 4: Performance response of AQ for three mecli- cal domains. on the remaining training instances. Since set- covering methods typically learn disjunctive normal form (DNF) expressions for the hypotheses, the dimen- sion used to measure the amount of learned knowledge is the number of disjuncts in the induced hypothesis. During experimentation with the AQ set-covering method, [Michalski, 19891 found that repetitive appli- cation of AQ can yield less accurate hypotheses than a more conservative application strategy combined with a more flexible inference mechanism than exact match- ing. Michalski compared the accuracy of the colrqlele DNF hypothesis produced by AQ to truncated ver- sions of the same hypothesis. The first truncated ver- sion of the hypothesis consists of the single disjunct covering the most examples (best disjunct). The sec- ond truncated version of the hypothesis consists of only those disjuncts covering more than one unique exam- ple (unique > I). The truncated hypotheses use a sim- ple matching procedure for classifying uncovered and multiply-covered examples. Although based on only four points, Figure 4 ap- proximates the performance response of AQ in three medical domains (Lymphography, Breast Cancer and Primary Tumor) averaged over four trials.2 Figure 4 demonstrates that A& also suffers from the general utility problem with increasing numbers of disjuncts, and the response curves indicate the same trend as in Figure 1. Holte et al. [1989] alludes to similar behavior in the CN2 set-covering method. 2Data from i ndividual trials was not available for signif- Although the utility problem has been verified in sev- icance testing. eral speedup learning systems [Minton, 1988; Tambe ,, 0.58 8 5 8 Q: 0.56 BackProp Response on Flag -.-- 0 100 200 300 400 500 600 700 800 900 1000 Cydes &+ 0.70 E 3 8 a 0.65 0.60 BackProp Response on DNF2 -.-- 0 100 200 300 400 500 600 700 800 900 1000 cycles Figure 5: BackProp performance response. Neural Network Methods The rnultilayer perceptron using error back- propaga- tion [Rumelhart et al., 19861 updates the weights of the network according to errors in classifying the train- ing instances. Each pass through the set of training instances is called a cycle. As the number of cycles increases, the network more accurately classifies the training instances. However, overfit eventually occurs as the network learns the training instances too pre- cisely, degrading accuracy on the testing data. To an- alyze the overfit of the back-propagation neural net- work, the performance response measures accuracy of the network after every five cycles. Figure 5 shows the performance response of the error back-propagation neural network (BackProp) on the Flag and DNF2 domains. The networks contained on hidden layer with four units. The BackProp response on the Flag and DNF2 domains follows the general util- ity problem trend as in Figure 1. Table 1 reveals that on average the network at the initial peak performs better than the final network. Geman et al. [1992] found similar behavior in the domain of handwritten number recognition. Speedup Learning Holder 251 a, 0.70 E 2 0.65 0 2 $ 0.60 .G 0.55 Planner Response on Blocks 0.451 ! ! ! ! ! ! ! ! ! 1 0 10 20 30 40 50 60 70 80 90 100 Macrops Learned Q) 0.011 E 0.010 g 0.009 3 0.008 tij ’ + 0.007 0.006 0.005 Planner Response on Robot “.“” r . 0 ii lb 15 20 25 Macrops Learned Figure 6: Planner performance response. and Newell, 1988; Mooney, 1989; Markovitch and Scott, 19891, the experiments typically do not show the performance response of the system.3 Figure 6 plots the performance response of a macro-operator learner consisting of a forward-chaining planner and a STRIPS-like plan generalizer [Fikes et al., 19721. Two domains are used in the experimentation. The blocks domain consists of four operators for stacking and un- stacking blocks. The robot domain consists of eight operators allowing the robot to move boxes within a layout of connected rooms. The experiments proceed by solving a training prob- lem in the domain, generalizing the resulting plan, adding the generalized plan to the set of available op- erators, and then measuring the amount of CPU time needed to solve a separate set of test problems using the augmented set of operators. The x-axis of the per- formance response is the number of learned macrops. The y-axis measures the inverse CPU time needed to solve the set of test problems. Although erratic in the blocks domain, the performance response plots in Fig- ure 6 follow the trend of the general utility problem. 3Cohen [1990] p lots control-rule learning response 5The Breast Cancer (BC), Flare and Voting (Vote) do- curves for several planning domains. nlains are front the UC Irvine machine learning databases. Table 1: Percentage final performance of peak for in- ductive learners. Method BC ID3 91.2 ID3 Chi 99.0 89.0 ID3 Chi 99.9 90.8 ID3 Red-Err 98.6 PLSl t, = 1.5 92.4 PLSl t, = 2.0 94.6 BP4 82.8 Domain 1 Flag , Vote I DNk2 88.2 1 88.5 94.4 89.9 96.1 95.4 98.7 97.6 98.5 98.4 ’ 98.5 89.8 I 88.2 Table 2: Percentage final performance of peak for Plan- ner. Domain Method Blocks Robot Planner 67.4 76.1 Trends Previous sections verify the existence of the general utility problem in several learning methods. The per- formance responses of these methods follow the trend illustrated in Figure 1. Adopting a model of this trend permits the control of the general utility problem by constraining the amount of learned knowledge to reside at the point corresponding to the peak performance. Tables 1 and 2 quantify the possible performance gailIs by using this model-based control of the amount of learned knowledge. Each entry in the tables is the percentage final performance of peak performance (2 * 100) averaged over ten performance response curves. Table 1 lists entries for several of the pre- viously described inductive learning methods4 on five clif’feren t domains 5. Table 2 lists entries for the Planner speedup learner on two domains. Note that the entries in Table 2 can be arbitrarily deflated by allowing the speedup learner to acquire more macrops. As shown in Tables 1 and 2, the final performance is less than the peak performance for all but one case. A majority of the values are statistically significant, and in the cases where the siguificance is low, the peak of the performance response is no worse than the fi- nal perforrrlauce. Thus, the ability to constrain the alnount of learned knowledge to the point correspond- ing to peak performance will improve the performance of the learner. Although individual methods exist for alleviatiug the general utility problem in each particu- lar learning method, the performance response model offers a general method for avoiding the general utility problem in mauy machine learning methods. 4BP4 is error back-propagation with one hidden layer containing fo’our units. 252 Learning: Utility and Bias 800 1000 L(SQlits) Figure 7: Performance response derived by Breiman et al. [1984] for a decision tree induction method. Fon-nal Models Breiman et al. [1984] d erive a formal model of the per- formance response for splitting methods. The shape of the performance response is the result of a tradeoff be- tween bias and variance. Bias expresses the degree of fit of the decision tree to the training data. A low bias (many small hyper-rectangles) is preferred to a high bias (few large hyper-rectangles), because low bias al- lows a more precise fit to the data. However, a low bias increases the likelihood that hyper-rectangles produce classification error (variance) due to fewer points on which to base the classification. The analysis expresses the bias and variance in terms of the number of leaves L in the decision tree. Assum- ing binary splits at each node of the tree, the number of splits is L - 1. Therefore, the behavior of the bias and variance as the number of splits increase will be similar to the behavior as L increases. The expression for the classification error R(L) in terms of the bias B(L) and the variance V(L) is R(L) = B(L) + V(L) + R* (1) where R* is the Bayes optimal classification error. Breiman et al. derive the following constraints on the bias B(L) and the variance V(L): c B(L) 5 L2/M’ V(L) 5 J V(L N N) 5 R* where C is a constant, M is the dimension of the instance space (i.e., number of features used to de- scribe the training instances), and N is the number of training instances. Equation 1 is an expression of the classification error response curve. Figure 7 plots the bias B(L), variance V(L), Bayes error R* , and estimated classification error R(L) from Equation 1, where C = 0.35, M = 20, N = 1000 and R* = 0.15. The plot extends from L = 0 to 1000. Subtracting this error curve from one would yield the accuracy re- sponse curve. The similarity of this performance re- sponse to that of Figure 1 supports the existence of a single peak and the inevitability of overfit in split- ting algorithms without appropriate stopping criteria or post-pruning techniques. Maximizing performance while avoiding overfit requires the determination of the number of splits L corresponding to the minimum of the error response curve. A similar analysis applies to set-covering methods, where the number of disjuncts in the DNF hypothe- sis replaces the number of splits in the decision tree. The corresponding expressions for bias and variance as a function of the number of disjuncts have a similar behavior as those depending on the number of splits, and the set-covering response curve follows the behav- ior in Figure 7. Geman et al. 119921 describe a similar moclel for two-layer networks in terms of the number of hidden units, and nearest neighbor methods in terms of the number of neighbors. Holder [1991a] describes a possible relationship between the number of cycles and the number of hidden layers in a multilayer network. These models assume that an increase in the amount of learned knowledge corresponds to an increase in the complexity of the resulting hypothesis. One definition of complexity is the degree of the function represented by the hypothesis. Given that the candidate hypothe- ses have a sufficient degree of complexity to allow over- fit, ordering the amount of learned knowledge in terms of increasing complexity insures the presence of the general utility problem trend. A speedup learner is similar to an inductive learner in that both seek a concept that maximizes perfor- mance. The concept sought by a speedup learner is a set of macro-operators or control rules minimizing the time taken by the problem solver to solve prob- lems from some domain. If the set of problems used to train the learner is not representative of the distribu- tion of problems in the domain, then the performance obtained for the training examples may degrade per- formance on the testing examples for reasons similar to overfit in inductive learners. However, the factors underlying the performance degradation are different from those affecting inductive learners. Minton [1990] identifies three ways in which macro-learning affects the problem-solving performance of a speedup learner. A simple quantification of these three components in terrns of branching factors behaves similarly to the general utility problem trend [Holder, 1991a], but the exact relationship between macro-operator (or control rule) learning and performance is not fully understood. Conclusions Both inductive and speedup learning methods suffer frown the general utility problem: the eventual degra- dation of performance due to increasing amounts of learned knowledge. The performance response curves of’ these methods indicate a common trend depicted in Holder 253 Figure 1. A model of this trend can be used to con- trol the amount of learned knowledge to achieve peak performance, which is typically greater than the final performance of the learning method (see Table 1). The model could also predict the achievable performance of the learning method as a means of selecting an a pro- priate method for a learning task [Holder, 1991b P . The MBAC approach uses and empirical model of the performance response. However, an empirical model requires samples of the actual performance re- sponse (runs of the learning method) and suffers from inaccuracies due to discrepancies between the empirical and true model of the performance response. There- fore, the MBAC approach (or any approach to con- trolling and estimating the performance of a learning method) would benefit from a formal model of the performance response that depends on properties of the current learning task, such as number of instances and dimension of the instance space. The formal rnod- els discussed earlier represent preliminary progress to- wards this goal. The underlying forces of bias and variance and the constraints on the order of knowledge transformations serve to unify several inductive and, at a high level, speedup learning methods. Continued refinement of models of the general utility problem will provide a general framework for controlling and com- paring different learning paradigms. Acknowledgements I would like to thank Larry Rendell, members of the Inductive Learning Group at University of Illinois, and the reviewers for their helpful suggestions. Thanks also to Ray Mooney, Jude Shavlik and Carl Kadie for their implementations of the learning methods. This research was partially funded by the National Science Foundation under grant IRI 8822031. References Breiman, L.; Friedman, J. H.; Olshen, R. A.; and Stone, C. J. 1984. Classification and Regression Trees. Wadsworth. Cohen, W. W. 1990. Learning approximate control rules of high utility. In Proceedings of the Seventh International Conference on Machine Learning. 268- 276. Fikes, R. E.; Hart, P. E.; and Nilsson, N. J. 1972. Learning and executing generalized robot plans. Ar- t$kiul Intelligence 4(3):189-208. Geman, S.; Bienenstock, E.; and Doursat, R. 1992. Neural networks and the bias/variance dilemma. Neu- ral Computation 4(1):1-58. Holder, L. B. 1990. The general utility problem in machine learning. In Proceedings of the Seventh Inter- national Conference on Machine Learning. 402-410. Holder, L. B. 1991a. Maintaining the Utility of Learned Knowledge Using Model-Based Adaptive Control. Ph.D. Dissertation, Department of Com- puter Science, University of Illinois at Urbana- Champaign. Holder, L. B. 1991b. Selection of learning methods using an adaptive model of knowledge utility. In Pro- ceedings of the First International Workshop on Mul- tistrutegy Learning. 247-254. Holte, R. C.; Acker, L. E.; and Porter, B. W. 1989. Concept learning and the problem of small disjuncts. In Proceedings of the Eleventh International Joint Conference on Artificial Intelligence. 813-818. Markovitch, S. and Scott, P. D. 1989. Utilization fil- tering: A method for reducing the inherent harmful- ness of deductively learned knowledge. In Proceedings of the Eleventh International Joint Conference on Ar- tificial Intelligence. 738-743. Michalski, R. S. 1989. How to learn imprecise con- cepts: A method based on two-tiered representation and the AQl5 program. In Kodratoff, Y. and Michal- ski, R. S., editors 1989, Machine Learning: An Ar- tificial Intelligence Approach, Vol III. Morgan Kauf- mann Publishers. Minton, S. 1988. Learning Search Control Knowledge: An Eq~lunution-Bused Approach. Kluwer Academic Publishers. Minton, S. 1990. Issues in the design of operator com- position systems. In Proceedings of the Seventh Inter- nutionul Conference on Machine Learning. 304-312. Mooney, R. J. 1989. The effect of rule use on the util- ity of explanation-based learning. In Proceedings of the Eleventh International Joint Conference on Arti- ficial Intelligence. 725-730. Pagallo, G. and Haussler, D. 1990. Boolean feature cliscovery in empirical learning. Machine Learning 5( 1):71-100. Quinlan, J. R. 1986. Induction of decision trees. Ma- chine Leurning l( 1):81-106. Quinlan, J. R. 1987. Simplifying decision trees. In- ternutional Journal of Man-Machine Studies 27:221- 234. Rendell, L. A. 1983. A new basis for state-space learn- ing systems and a successful implementation. Artifi- cial Intelligence 20(4):369-392. Rumelhart, D. E.; Hinton, G. E.; and Williams, R. J. 1986. Learning internal representations by error prop- agation. In Parallel Distributed Processing, Volume 1. MIT Press. chapter 8, 318-362. Tambe, M. and Newell, A. 1988. Some chunks are expensive. In Proceedings of the Fifth International Collference on Machine Learning. 451-458. Yoo, J. and Fisher, D. 1991. Concept formation over prol>lei-ri-solving experience. In Proceedings of the Twevth Internutional Joint Conference on Artificial Intelligence. 630-636. 254 Learning: Utility and Bias | 1992 | 53 |
1,247 | iv rucc! Department of Computer Science University of Pit&burgh Pittsburgh, PA 15260 foster@cs.pitt .edu The concept of inductive bias can be broken down into the underlying assumptions of the domain, the particular implementation choices that restrict or order the space of hypotheses considered by the learning program (the bias choices), and the in- ductive policy that links the two. We define in- ductive policy as the strategy used to make bias choices based on the underlying assumptions. In- ductive policy decisions involve addressing trade- offs with respect to different bias choices. With- out addressing these tradeoffs, bias choices will be made arbitrarily. From the standpoint of induc- tive policy, we discuss two issues not addressed much in the machine learning literature. First we discuss batch learning with a strict time con- straint, and present an initial study with respect to trading off predictive accuracy for speed of learning. Next we discuss the issue of learning in a domain where different types of errors have different associated costs (risks). We show that by using different inductive policies accuracy can be traded off for safety. We also show how the value for the latter tradeoff can be represented explicitly in a system that adjusts bias choices with respect to a particular inductive policy. Pntroduetion In order for an inductive learning program to de- fine concepts that generalize beyond its training examples, it must incorporate inductive bias - as- sumptions that lead it to prefer certain inductive steps over others. Mitchell [Mitchell 19801 defined bias as “any basis for choosing one generalization over another other than strict consistency with the observed training instances.” Systems bias their learning in many ways, including using restricted description languages, heuristics to search the hy- pothesis space, and domain knowledge to guide the search. The strength of a bias has been de- fined as the fraction of hypotheses considered by the learner within that bias relative to all possible hypotheses [Utgoff 19841. More recently, machine learning researchers have worked to formalize the notion of inductive bias in terms of specific restrictions of or orderings to the hypothesis space [Rendell 19861, [Haussler 19$8], [Dietterich 19911. Such formalisms help to shed light on the problem of inductive bias, but something from Mitchell’s original definition was lost in the process. We are gaining insight into the various ways of restricting and ordering hy- pothesis spaces. However, the difference between the bias choice and the strategy for making a bias choice often goes undiscussed. For example, a preference for simplicity may lead to the choice of a certain ordering (e.g., preferring the shorter expression in some language), but they are not equivalent. In this paper we define inductive policy as the strategy used to make inductive bias choices, based on underlying assumptions (and prefer- ences) in the domain. Inductive policy decisions address tradeoffs with respect to different bias choices. Without addressing these tradeoffs, bias choices will be made arbitrarily. We present ini- tial studies of tradeoffs not addressed much in the machine learning literature: trading off predictive accuracy for speed of learning, and trading off ac- curacy for safety in a domain where different er- rors have different costs. also show how the value for the latter tradeoff can be represented ex- plicitly. To avoid confusion in the subsequent discussion let us call a choice of implementation restricting or ordering the space of possible hypotheses (pos- sibly dynamically) a bias choice. A particular inductive policy is based on underlying assump- tions of the learning domain and task and ad- dresses the tradeoffs with respect to the different Provost and Buchanan 255 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. bias choices. As with bias choices the granular- ity of inductive policies can vary, and determining the exact boundaries between assumptions, pol- icy, and bias choice may provide for interesting discussions. However, there is a qualitative differ- ence between bias choices and the strategies for making them. To illustrate the difference, let us consider a learning task where an underlying assumption is that the set of features given may not be ade- quate for learning the concept with a simple de- scription language. Two somewhat different in- ductive policies come to mind immediately: (i) use a learning system with a more complex de- scription language, or (ii) surround the first- or- der system with techniques for constructive induc- tion (in effect, increasing the complexity of the de- scription language). Each of these policies leads to different possible sets of bias choices (for ex- ample, the choice of a particular constructive in- duction implement ation). The sets of bias choices are reduced by further, finer grained, policy de- cisions. Another example of underlying assump- tions in a domain concern the tot al number of examples available for learning and the amount of processing power. With many examples and little computing power, the machine learning re- searcher immediately wants to consider different strategies than if the opposites were true, e.g., (i) use a relatively inexpensive algorithm, (ii) use a technique for selecting a subset of examples (in- t elligent or random), or (iii) use an increment al learning method. Decisions at the inductive policy level are made with respect to the underlying assumptions of a domain (or the preferences of the investigator) and the tradeoffs among them. Different induc- tive policies, and their associated bias choices, can lead to different learning performance. In order to make decisions at the policy level we need to un- derstand the tradeoffs. Explicitly addressing inductive policy is not new. Samuel, in his classic checkers program, de- cided to use a linear combination of terms from the domain realizing that this choice would pro- hibit him from expressing interactions among the terms, but would provide him with a simpler rep- resentation [Samuel 19631. Later he decided to move toward the other end of the tradeoff spec- trum, choosing the more complicated signature ta- bles that would allow him to represent interactions among terms. Although previous work in machine learning has implicitly addressed such tradeoffs, we feel that it is useful to make the distinction between bias choice and policy explicit. McCarthy argued [McCarthy 19581 that rep- resenting knowledge declaratively in a reasoning program was a prerequisite for a learning program to augment or edit it. Similarly, insofar as the pos- sible bias choices of a learning program are explic- itly defined, it is conceivable that a second-order system can tune them so that the first-order sys- tem can learn better or faster [Buchanan et al., 19781. Different inductive policies apply in dif- ferent domains, leading to different bias choices. Whether these choices are made by hand or by a second-order system, their explicit representation facilitates their change. ifferent uctive Policies Decisions are made at the inductive policy level that tie the bias choices to the underlying prefer- ences and assumptions. Different bias choices may involve different learning programs, or, as far as the bias of the learning program has been made explicit, different bias choices within a given pro- gram. In this section we will investigate how dif- ferent inductive policy decisions, reflecting differ- ent assumptions about tradeoffs in the learning task, can lead to differences in the performance of a learning program. More specifically, we show how different policies dealing with assumptions about the time available for learning can lead to differences in the predictive accuracies of the re- sultant concept descriptions. Then we illustrate how differences in inductive policy with respect to different prediction errors can lead to differences in the overall cost of using a learned concept de- scription. Finally, we show how by using a func- tion that represents explicitly the weight given to the costs of prediction errors, a system can learn a concept description that better satisfies the un- derlying cost assumptions. The learning program used in this section is MC-RL, a multiclass version of the RL4 learn- ing system [Clearwater & Provost 19901. MC-RL uses an explicit bias representation, its partial do- main model (PDM), t o enable easy changes in bias choices based on decisions at the inductive policy level. In section 3.3 we use the ClimBS system [Provost 19921, which automatically adjusts MC- RL’s bias based on explicitly represented bias ad- justment operators. The focus of this paper is on the inductive policies used, rather than the par- ticular systems. Space constraints prohibit more detailed description. 256 Learning: Utility and Bias Tradeoff: accuracy vs. time to learn One policy decision that must be made is based on assumptions about the amount of time avail- able for learning. The bias choices made when a large amount of time is available will be differ- ent from those made when there is a time limit. In the literature, one sees analyses of learning pro- grams’ efficiencies, both analytically (usually with respect to asymptotic computational complexity) and empirically (usually on UCI database or artifi- cial domains). Such comparisons are usually used for explicit or implied comparisons of learning pro- grams. These comparisons are the beginning of a body of data on which inductive policy decisions can be based. Little research addresses explicit limits on the time available for learning (other research in AI addresses resource bounded reasoning, see e.g., [Bratman et al. 19881). The tradeoff of time spent learning versus prediction quality is discussed in [desJardins 19911; desJardins describes a method for using probabilistic background knowledge to select maximally relevant features to describe con- cept s (for increment al learning). Also with respect to incremental learning, [Pazzani & Sarrett 19901 discusses predictive accuracy as a function of the number of examples for conjunctive learning al- gorithms. [Clearwater et al. 19891 discusses in- cremental batch learning as a way of presenting intermediate results when a time limit is reached, and saving the “best rules so far” in case the time limit is less than the time to process a single batch. [Holder 19901 h s ows how the PEAK system can address the problem of a time limit on the use of a learned concept (and the use of EBL to speed it up). We discuss trading off predictive accuracy for short learning time for a batch learning system as a preliminary study. Qur goal is to be able to learn a good concept description within a specified time limit. If a basic assumption of a given learning task is that there will only be x time units for learning, the inductive policy followed will be different from that followed when there is no such limit. One in- ductive policy that might be followed in such a situation is: use a heuristic search that is guaran- teed to terminate in x time units and return the best concept description the system could learn in that time. We have begun to investigate the relationship between the beam width of MC-RL’s search of the space of syntactically defined rules, the time taken to learn, and the accuracy of the resultant concept description. 0000 1000 Figure 1: Increased search with increased beam width in mushroom domain. beam width Figure 2: Increased accuracy with increased beam width in mushroom domain. Analytic results predict that the search time for the MC-RL system will grow linearly with the beam width. Figure 1 shows the actual relation- ships found in the mushroom domain from the UCI repository (points show mean values over 10 runs with randomly selected training sets, error bars show 95% conhdence interval using Student’s 0 These relationships are sublinear (note the logarithmic scales); the analysis could not take into account the contribution of some of MC-RL’s heuristics for pruning the search space. Figure 2 shows the corresponding classification accuracies of the result ant rule sets (points, as above; tested on separate test sets). Similar re- sults were found in the automobile-domain. The graceftpl degradation of the classification perfor- mance with smaller beam width indicates that it may indeed be profitable to determine the maxi- mum beam width such that the search is guaran- teed to terminate within the given x time units. Such a calculation would involve a determination of the time to search a single node on a given ma- Provost and Buchanan 257 chine with a given PDM and number of examples, and a curve that is guaranteed to bound (from above) the actual run times (the analytically de- rived curve may suffice, with the determination of the constants). Once the performance of the system within given time limits has been characterized, it can be compared with that of other approaches and higher level tradeoffs can be studied. For exam- ple, even if enough space is available for batch learning it might be found that it is better to use an incremental learning system for a certain class of time constrained learning tasks-i.e., the gain in speed by using a policy of incremental learn- ing outweighs the gain by using a quick heuristic search in a batch algorithm, to yield a concept description with the same accuracy (or perhaps a combination of the two policies gives the best results). Other inductive policies take advantage of the relative speed with which a large portion of the target concept description can be learned. For example, part of an inductive policy might be: use a quick heuristic search, then switch to a more time consuming search using the knowledge gained with the quick search to guide and restrict subsequent learning. In addition, a quick search is useful for exploratory work in making other bias choices. Better Safe than Sorry Another set of assumptions that affect inductive policy decisions addresses the costs of making in- correct predictions or of failing to make a pre- diction (errors of comrnission or omission). Ma- chine learning work usually treats these costs as equal and concentrates solely on predictive accu- racy. One exception to this is the CRL system [Tcheng et al. 19891, which allows the user to specify domain dependent error metrics, which can then be used to guide the learning (results as to the method’s efficacy are not presented). Another exception is the work of [Etzioni 19911, which studies the introduction of decision analytic techniques (which take into account costs, bene- fits and likelihoods) into an agent’s control policy (and the use of learning to aid estimation). The decision to learn with sensitivity to prediction cost is an inductive policy decision that affects induc- tive bias choices (similar to the decision to be sen- sitive to the cost of measuring features, as in [Tan and Schlimmer 19901). We have investigated different inductive policies using MC-RL in the mushroom domain. MC-RL learns a set of rules, some of which predict that a mushroom mat thing the antecedent is poisonous, others predict that the mushroom is edible. This rule set is used as part of the knowledge base for an inference engine that gathers evidence from the rules that fire on an example, and combines the evidence to make its prediction. The inference engine simply finds all the rules that match the example and uses an evidence gathering function supplied for the domain when more than a single concept is predicted by the fired rules. The default evidence gathering function has the rules vote to determine the concept to predict. In the mushroom domain the cost of making a mistake is lopsided. Under normal circumstances, no harm is done when an edible mushroom is clas- sified as poisonous. In contrast, classifying a poi- sonous mushroom as edible is dangerous. In this domain, the assumption that a certain prediction is more costly than another should lead to a differ- ent inductive policy than that taken when one can assume that all mistakes can be weighted equally. Obviously, a completely safe policy would be not to even use a learning program; instead use a con- cept description that always predicts a mushroom is poisonous- dangerous predictions would never be made. However, this approach would never al- low any mushroom to be eaten. The policy used by mushroom experts varies from expert to ex- pert. A very conservative policy requires consid- erably more evidence, for example, than a less con- servative one [Spear 19921. Table 1 lists the results of several experiments in this domain with different inductive policies and associated bias choices. The experiments are de- scribed in detail below. The table lists the number of rules learned for a given experiment, the pre- dictive accuracy (on a test set), and the percent of predictions that classify a poisonous mushroom as edible (% dangerous) when using the voting strat- egy and a “better safe than sorry” strategy in the inference engine. Better safe than sorry (BSTS) simply predicts that a mushroom is poisonous if any rule in the rule set classifies it so. A repre- sentative set of 1015 examples (every eighth) was chosen from the database for efficiency reasons; this was split randomly into training sets of size 100 and test sets of size 915. The results in Ta- ble 1 are averages over 10 runs; 95% confidence intervals are given. Experiment 1 used a bias chosen empirically to give a high predictive accuracy. With the voting 258 Learning: Utility and Bias Table 1: Experiments comparing (%) accuracy (correct predictions/total * 100) and (%) risk (dangerous predictions/total * 100) associated with rules learned with different policies and bi- ases in the mushroom domain. Experiments l-6 are described in the text (below). strategy approximately half of the incorrect pre- dictions made were of the dangerous type-over 2 percent of the test examples. With BSTS this fraction is reduced to approximately 1 percent. The rest of the experiments tested different in- ductive policies (and the associated bias choices) designed to lower the fraction of predictions that were dangerous. In Experiment 2, MC-RL was run as in Exp. 1 for the rules predicting mush- rooms to be poisonous; however, the rules for ed- ibility were restricted not to cover any negative training examples and to be simpler in form (only 3 conjuncts allowed instead of 5) to avoid possible fitting of the data. The result was that the frac- tion of dangerous predictions was reduced slightly, without a significant decrease in the predictive ac- curacy. Experiment 3 was identical to Experiment 2, except that each edibility rule was forced to cover a larger fraction of the positive examples (403 instead of 20%). The fraction of danger- ous predictions was reduced again, accompanied by a decrease in predictive accuracy. Forcing each edibility rule to cover an even larger fraction of positive examples (Exp. 4-60%) did not decrease the dangerous predictions, but did decrease the predictive accuracy. Experiments 2 through 4 took the policy that the poisonous classification accuracy should be high, but that only rules that are in some sense “safe” should be learned for the edibility class. Experiments 5 and 6 combine this with a differ- ent policy. While edibility rules are learned as in Exp. 2, when searching for rules for the poi- sonous class MC-RL is instructed to learn a large, highly redundant set by turning off its heuristic for selecting a small “good” rule set. The hope is that many alternative descriptions of poisonous mushrooms will do a better job of catching the few examples that had previously slipped by. This is in fact seen to be the case, especially when used in the BSTS inference engine. The final experiment combines the best of the two inductive policies- learning only “good” rules for edibility (by set- ting the positive threshold for edibility rules to 0.4) while learning a highly redundant set of rules for the poisonous class. When used in the BSTS inference engine, the fraction of dangerous predic- tions is reduced to 0.04 percent (in all but 1 of 10 runs it was zero) and the predictive accuracy was still 84.5 percent. These experiments show how different policies can lead to different tradeoffs of accuracy for safety of predictions. They show particular poli- cies that are useful in the mushroom domain; their utility in other domains has yet to be shown. Specifying a priori the specific bias choices that will perform best given a high level specification of a policy is a matter for further investigation. The method used above was to determine empir- ically a good set of bias choices, guided by the inductive policy. The next section shows how the tradeoff of accuracy for safety can be represented explicitly, and a system for bias adjustment can determine the bias choices that yield a good con- cept description. Explicit Specificat ion of Inductive Policy ias Adjustment System The ClimBS system [Provost 19921 performs a hill climbing search in MC-RL’s bias space, incremen- tally constructing a concept description across bi- ases (using a greedy rule set pruning heuristic, similar to that described in [Quinlan 19871) and using the learned knowledge to guide and restrict \its bias space search. ClimBS is provided with a starting bias, bias transformation operators, and a rule set evaluation function. It uses the trans- formation operators to create tentative candidate biases, learns rules with each, combines these with the previously learned rule set, and chooses the best of the tentative sets with respect to the eval- uation function. The current bias is set to the bias with which the best rule set was learned; and the process iterates until one of several stopping criteria is met. ClimBS is a second-order system for automati- cally adjusting inductive bias of a fist-order sys- tem (MC-RL). ClimBS allows for an (partial) ex- plicit specification of bias choices corresponding Provost and Buchanan 259 Table 2: Experiments comparing the accuracy and risk of rules learned with different inductive poli- cies represented as bias evaluation functions in the ClimBS bias adjustment system. Experiments 7- 10 are described in the text (below). Accuracy and risk are defined as in Table 1. to bias adjustment policies. The particular set of bias transformation operators, combined with ClimBS’ hill climbing search and the bias evalu- ation function, correspond to a policy for chang- ing fist-order bias choices based on an evaluation of the results of learning. The set of operators used to generate the results below operated on the positive threshold for individual rule perfor- mance, the negative performance threshold, the complexity of the description language (the maxi- mum number of conjuncts allowed in a rule), and the beam width of the heuristic search. The ini- tial bias was very restrictive (the parameters listed above were set at 0.9, 0, 1, and 1, respectively), and the operators weakened the bias along the several dimensions. This corresponds to a policy of trying to learn “good” rules first, and subse- quently reducing the standards to complete the concept description. Table 2 shows the results of several experiments in which ClimBS was used to learn rules for the mushroom domain. The bias evaluation function was varied across the experiments to reflect dif- ferent assumptions about the tradeoff of accuracy vs. the cost of making dangerous errors. The table lists the number of rules learned, the pre- dictive accuracy of the rule set, and the percent of the predictions that are dangerous. As above, the results are averaged over 10 trials, 95% confi- dence intervals are given; 100 (randomly selected) examples were used for learning, 400 for bias eval- uation, and 515 for testing. In Experiment 7, the default evaluation func- tion (only consider predictive accuracy, use vot- ing strategy) was used. As in Experiment 1, al- though the classification accuracy is impressive, over two percent of the examples were dangerously classified as edible, when they were actually poi- sonous. In Experiment 8 the evaluation function compared biases based on predictive accuracy, us- ing the BSTS evidence gathering function. The accuracy of the resultant descriptions are not de- graded much, while the fraction of dangerous pre- dictions is reduced to one-third its previous value. Recall that switching to the BSTS engine provided a significant reduction in dangerous predictions. Experiments 9 and 10 use a linear combination of predictive accuracy and number of dangerous predictions to evaluate the rule sets learned with different biases. In particular, the function used was: f = number of correct predictions - w * num- ber of dangerous predictions. I[n Experiment 9, w = 10; in Experiment 10, w = 50. One can see the tradeoff of classification accuracy for safe pre- dictions that is manifest in the rule sets learned by ClimBS. The 0.16 percent dangerous predic- tion rate obtained in Experiment 10 is still four times that of Experiment 6. However, ClimBS was not equipped with an operator that would turn off the heuristic for selecting a small “good” rule set (as was done in Section 3.2); this heuris- tic was always on. ChmBS performance is com- patible with that of Experiment 3. Note that the variance of the classification accuracy is larger when the more complicated evaluation functions are used. This may be a side effect of the conver- gence criterion used. (If over the last 5000 (MC- RL) nodes searched the concept description had not improved, ClimBS terminated its search). ClimBS allows for the specification of the rela- tive value of different rule sets with respect to their performance. This explicit represent ation of how the system should deal with the accuracy/safety tradeoff allows the system to adjust the first-order bias to find a concept description that gives a good score with respect to this function, and thereby performs well with respect to the tradeoff. The problem of specifying the bias evaluation function (in light of a particular inductive policy) remains. Bowever the faction from Experiment 10 was the first chosen. We assert that specifying this func- tion and letting ClimBS automatically adjust the bias is easier than the manual bias adjustment, because its specification is more directly related to the assumption in question (i.e., the relative importance of the different prediction errors and predictive accuracy). Conclusions We believe that the results showing that pre- dictive accuracy degrades gracefully with shorter times taken to learn are not tied to the particu- 260 Learning: Utility and Bias lar bias choices used, but would be shown with different heuristic searches or different evaluation functions in the beam search used. With respect to the accuracy/safety tradeoff, we believe that the increases in safety shown with manual bias ad- justment in MC-RL are due to the policies (learn only “good” rules for edibility, learn highly redun- dant sets of rules for poisonous) used to guide the selection of bias choices, more than to the bias choices themselves. With ClimBS, we be- lieve the power comes from the policy of using an evaluation faction that takes the specific trade- off into account when making bias choices, rather than from the particular evaluation function used (the bias choice). Substantiating or refuting these claims is future work. These claims of the importance of concentrat- ing on inductive policy in addition to concentrat- ing on bias choices must be qualified by repeating the theme that we have stressed throughout the paper. Concentrating on inductive policy provides focus for studies of inductive bias choices. In turn, the tradeoffs with respect to the different possible bias choices help to guide the selection of policy for a given task. Without studies of how different bias choices affect learning systems’ performances with respect to these tradeoffs, bias choices will be made arbitrarily-without an inductive policy. en&s This work benefited from discussions with Scott Clearwater, Randy Jones, Tom Mitchell, Jeff Schlimmer, Kurt VanLehn, and the Pitt machine learning discussion group. This work was sup- ported by NLM grant l-ROI-EM05104 and an IBM Graduate Fellowship. Bratman, M.; Israel, ID.; and Pollack, M. 1988. Plans and Resource- Bounded Practical Reason- ing. Computational Intelligence 4( 4)) 349- 355. son, C.; Mitchell, T.; and 1s of Learning Systems. In edia of Computer Science and Technology 11, 24-51. Clearwater, S.; Cheng, T.; Buchanan, B. 1989. Incremental In Proc. of ML-89, 366-370. Morgan Kaufmann. Clearwater, S. and Provost, F. 199 RL4: A Tool for Knowledge-Based Induction. Proc. of the 2nd Int. IEEE Conf. on Tools for AI, 24-30. IEEE Computer Society Press. desJardins, M. 1991. Probabilistic Evaluation of Bias for Learning Systems. Proc. of ML-91, 495-499. Morgan Kaufmann. Dietterich, T. 1991. Machine Learning: Is- sues, Answers, and Quandaries. Keynote Lecture, AAAI-91. Etzioni, 0. 1991. Embedding Decision-analytic Control in a Learning Architecture. Artijicial In: telligence 49 (1991), 129-159. ussler, D. 1988. Quantifying Inductive Bias: earning Algorithms and Valiant’s Learning Framework. Artificial Intelligence 36, I-77-221. Bolder, L. 1990. The General Utility Problem in Machine Learning. In Proc. of ML-90,402-410. Morgan Kaufmann McCarthy, J. 1958. Programs with Com- mon Sense. Reprinted in R. Bra&man and I-I. Levesque (Eds.), Readings in Knowledge Repre- sentation, 299-308. Morgan Kaufmann, 1985. Mitchell, T. 1980. The Need for Biases in Learn- ing Generalizations. Technical Report CBM-TR- 117, Department of Computer Science, Rutgers University. Pazzani, M. and Sarrett, W. 1990. Aver- age Case Analysis of Conjunctive Learning Algo- rithms. In Proc. of ML-90, 339-347. Morgan Kaufmann. Provost, F. 1992. Searching the Bias Space: Policies for Inductive Bias Adjustment. Ph.D. thesis , forthcoming . Quinlan, J. 198‘7. Generating Production Rules fr Decision Trees. Proc. of IJCAI-87. endell, L. 1986. A General Framework for In- duction and a Study of Selective Induction. Ma- chine Learning 1 (1986)) 177-226. Samuel, A. 1963. Some Studies in Machine Learning Using the Game of Checkers. In E. Peigenbaum and J. Feldman (Eds.), Computers and Thought U-105. McGraw-Bill. Spear, M. 1992. Vice President of Research, Sylvan Spawn Laboratories. Private Communica- tion. Tan, M. and Schhmmer, J. 1990. Two Case Studies in Cost-Sensitive Concept Aquisition. In Proc. of AAAH-90, 854-860. Morgan Kaufmann. Tcheng, D.; Lam , B.; Lu, S.; and Rendell, L. 1989. Building ust Learning Systems by Combining Lnducti d Optimization.” In Proc. of IJ 89, 806-812. Morgan Kaufmann. Ut P. 1984. Shift of Bias for Inductive Con- cept Learning. Ph.D. thesis, Rutgers University. I?rovost and Buchanan 261 | 1992 | 54 |
1,248 | onathan Gratch and Gerald Beckman Institute for Advanced Studies,University of Illinois 405 N. Mathews, Urbana, IL 61801 e-mail: gratch.cs.uiuc.edu Abstract In machine learning there is considerable interest in tech- niques which improve planning ability. Initial investiga- tions have identified a wide variety of techniques to address this issue. Progress has been hampered by the utilityprob- lem, a basic tradeoff between the benefit of learned knowl- edge and the cost to locate and apply relevant knowledge. In this paper we describe the COMPOSER system which em- bodies a probabilistic solution to the utility problem. We outline the statistical foundations of our approach and com- pare it against four other approaches which appear in the lit- erature. earning is often entertained as a mechanism for improving the efficiency of planning systems. Researchers have proposed a wide array of techniques to modify plan- ning behavior, including macro-operators [DeJong86, Fikes72, Mitchell861, chunks [Laird86], and control rules [Minton88, Mitchell83]. With these techniques comes a growing battery of successful demonstrations in domains ranging from g-puzzle to Space Shuttle payload process- ing. Unfortunately, in what is now called the utility prob- lem, learned knowledge can hurt performance [Minton88]. This is underscored by a growing body of demonstrations where learning degrades planning performance Etzio- ni90b, Gratch91 a, Minton85, Subramanian90]. In an earlier paper we elaborated the limitations in a par- ticular learning approach - [Gratchglb]. That paper sketched the COMPOSER system as one solution to these limitations. COMPOSER is intended as a general probabil- istic solution to the utility problem. In this paper we detail our approach and report on a series of empirical evaluations. These tests compare COMPOSER’S learning criterion against the approaches adopted by PRODIGY/EEL [Min- ton88], STATIC [Etzioni90b], a hybrid of PRODIGY/EBL and STATIC [Etzioni90a], and PALO [Greiner92]. The re- sults substantiate our earlier analyses. They also cast doubt on the efficacy of nonrecursive control knowledge. This is significant as nonrecursive control knowledge has received considerable attention in the literature [EtzionigOb, Letov- y90, Subramanian901. Learning as Searc Learning can be viewed as a transformational process in which the learning system applies a series of transforma- tions to a performance element (see [Buchanan77, Gratch921). The transformations available to a learner de- fine its vocabulary of transformations. These are essential- ly learning operators and collectively they define a tramfor- mation space. For instance, acquiring a macro-operator can be viewed as transforming the initial system (the origi- nal planner) into a new system (the planner operating with the macro-operator). A learning system must explore this space for a sequence of transformations which result in a better planner. To evaluate different learning approaches we must clari- fy our intuitive notions of when one planner is more effi- cient than another. We characterize planners through a nu- meric utilityfinction which ranks the behavior of a planner over a fixed distribution of problems. We equate efficiency with minimizing planning time. Other measures are possi- ble and our approach could apply to them as well. For any given problem, utility increases as the time to solve the problem decreases. The utility of a planner is defined as the sum of the utility of each problem in the distribution weighted by its probability of occurrence: UlYlLJTY(planneri) = - Cost(planneri,prob)xPr@rob) c prob EDishibution Note that higher utility does not entail that the planning time of any particular problem is reduced. Rather, the ex- pected cost to solve any representative sample of problems is less. Utility is a preference function over planners. It is also useful to discuss the utility of individual transformations. The incremental utiEity of a transformation is defined as the change in utility that results from applying the transforma- tion to a particular planner (e.g. adopting a control rule). This means the incremental utility of a transformation is conditional on the planner to which it is applied. We denote this as: AUTILITY(TransformationlPlanner). 3c COMPOSER uses the previous definition of utility to evalu- ate and adopt control knowledge which, with highprobabil- ity, improves planning performance. Its design was moti- vated by deficiencies in PRODIGY/EBL. Another paper illustrates how these deficiencies are shared by many other speed-up learning techniques [Gratch92]. In this paper we focus on the implementation of COMPOSER. In Gratch and DeJong 235 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. [Gratchg lb] wenotethat PRODIGY/EBL adopts two heuris- tic simplifications toidentify beneficial control rules. First, aspects of the problem distribution are learned from a single example. Secondly, control rules are treated as ifthey donot interact. These simplifications have the unfortunate conse- quence that PRODIGY/EBL can learn control strategies which yield planners which are up to an order of magnitude slower than the original planner. We replace this heuristic approach with a rigorous alternative. 3.1 Algorithm COMPOSER is implemented within the PRODIGY 2.0 ar- chitecture. This system includes the PRODIGY planher, a STRIPS-like system. The learning component of PRODI- GY/EBL analyzes solution traces and proposes control rules to correct inefficiencies observed during planning. These control rules are condition-action statements which inform the PRODIGY planner to delete or prefer certain node, oper- ator, or variable binding choices. COMPOSER primarily utilizes selection and rejection rules. This is discussed fur- ther in Section 5. COMPOSER differs from PRODIGY/EBL in how statis- tics are gathered and how control rules are introduced into the PRODIGY planner. We implement a hill-climbing ap- proach to the utility problem. The basic algorithm is sketched in Figure 1. We assume the user has provided a training set which is drawn randomly according to a fixed distribution of Droblems. Input: TRAINING~EXAMPLES CONTROL~STRATEGY - (ZI CANDIDATE-SET = 0 While more training examples solve problem with Planner+CONTROLJ%lXATEGY learn new rules and add them to CANDIDATE_SET acquire statistics for all rules in CANDIDATE_SET from trace POSITM~RULES - @ Forall rules E CANDIDATE_SET If ~UTIL~(rulelPRODIGY+CONTROL~STRATEGY) significantly negative Then remove rule from CANDIDATE_SET If kJTlLITY(rulelPRODIGY+CONTROL_sTRATEGy) significantly positive Then add rule to POSITIVE~RWLES If POSITIVE RULES add rule w%h highest utility to CONTROL-STRATEGY remove this rule from CANDlDATE_SET discard all statistics on rules in CANDIDATE_SET Output: CONTROL~STRATEGY Figure 1: The COMPOSER algorithm Learning occurs with a single pass through the training examples. The algorithm incrementally adds control rules to a currently adopted control strategy. A rule is added only if it has demonstrated its benefit to a pre-specified confi- dence level. Once added, the rule changes how the planner behaves on subsequent training examples. New rules are proposed, and statistics gathered, with respect tothe current control strategy. In this manner a control strategy is “grown” one rule at a time until the training set is exhausted. 3.2 A~~~~~~~g Uti%ity Statistics Gathering bcremental utility statistics is the one aspect of COMPOSER which ties it to a particular representation for control knowledge - control rules. Other transformations would require analogous data gathering procedures. A control rule should only be adopted if it improves the average efficiency of the problem solver. This average can be estimated by determining how the rule performs on indi- vidual problems and combining information from several problems. The next section discusses how to combine in- formation. But first we will describe how COMPOSER ex- tracts incremental utility values on individual problems. How can we determine the incremental utility of a control rule on a particular problem? Ideally we have access to an efficient analytic model of the problem solver which can predict incremental utility. Unfortunately it is difficult to provide such a model for a non-trivial problem solver like PRODIGY. Instead we can measure utility empirically. The obvious approach is to solve the same problem multiple times - once for the current control strategy without the rule in question, and once using the strategy augmented with a candidate rule. The difference in problem solving cost between these runs is the incremental utility of the con- trol rule on that problem. This problem must be repeatedly solved for each candidate rule. Clearly this approach is too expensive in practice. COMPOSER uses a more efficient approach for gathering incremental utility values. It extracts a utility value for each candidate rule simultaneously from a single solution trace. While PRODIGY/EBL also derives multiple estimates from a single example, its technique is rendered inaccurate by the interactions which occur among rules (see [Gratchglb]). COMPOSER solves the interaction problem by extracting estimates without allowing the candidate rules tochangethe search behavior of the planner. Control rules only effect search behavior if they are adopted into the control strategy. In contrast toadoptedrules, the actions of candidate rules are not acted upon. They are simply noted in the problem solving trace. After a problem is solved, COMPOSER ana- lyzes the annotated trace, and identifies the search paths which would have been avoided by each rule. The time spent exploring these avoidable paths indicates the savings which would be provided by the rule. This savings is com- pared with the recorded precondition match cost, and the difference is reported as the incremental utility of the rule for that problem. It should be noted that this procedure is more expensive than the heuristic approach adopted by PRODIGY/EBL. This is because COMPOSER pays the penalty of matching preconditions without acquiring any of the benefit of candi- date control rules. We are not aware of a reliable technique which avoids this additional cost. 236 Learning: Utility and Bias 3.3 Commitment Criterion The incremental utility of a transformation across the prob- lem distribution is estimated by averaging utility values from successive problems. The estimates should be accu- rate but based on as few examples as possible. In the field of statistics this is referred to as a sequential analysisprob- Zem (see [Govindarajulu81]). Observations are gathered until some stopping criterion is satisfied. As this criterion will commit COlvWOSER to adopting or discarding atrans- formation we refer to this as a commitment criterion. In this case we are estimating the incremental utility of transfor- mations to some specified confidence. . Formally, COMPOSER must choose among two hypothe- ses for each candidate: II.o: AUTILITY(rulelplanner+control~strategy) e= 0, Hr : AUTILITY(rulelplanner+control&rategy) > 0 In general there will be a discrepancy between the aver- age of a sample and the true population mean. If the rule is negative, we wish to bound the probability that it will ap- pear positive, andviceversa. It suffices torestrict theproba- bility that the difference between the true utility and the esti- mate is larger than the magnitude of the true utility: r PI-( IESmTE - AIJTE,I”I?‘I > IAU’I’ILI’I’YI ) = 6 We use a distribution-free commitment criterion devel- oped by Nadas [Nadas69]. The technique dynamically de- termines the number of examples sufficient to approximate- ly achieve the specified confidence level. By approximate we mean that if the specified error level is F the observed er- rorrate may be slightly more or less than is. The discrepancy is a function of the underlying distribution, but this type of approximation is very close in practice (see woo- droofe821). Examples must be taken until the following in- equality holds: where -&, is the average utility of the rule r over n prob- lems, Xr,i is the utility of r on the ith problem, Vr,,2 = n-l + n-l X(X, i --xr,J2 is the variance of the current sample, and n is greater than some small constant r~ (we adopt a value of no = 3 recommend by Adam Martinsek (personal com- munication) and evaluated in moodroofe821). The param- eter a satisfies the constraint that @(-a) = (1 - F)/2, where Q is the cumulative distribution function of the standard normal distribution. The commitment criterion permits COMPOSER toidenti- fy when transformations are beneficial with some pre-spe- cified probability. After each problem solving attempt, COMPOSER updates the statistics and evaluates the com- mitment criterion for each control rule in the candidate set. If no control rule has attained the confidence requirement, another problem is solved. If the commitment criterion identifies control rules with positive incremental utility l.This is a two-sided statistical test and thus is overly conservative. We are not aware of a good one-sided test for this problem. (there may be more than one), COMFQSER adds the control rule with highest positive incremental utility to the current strategy, and removes it from the candidate set.2 Statistics for the remaining candidates are discarded as they are con- ditional on the previous control strategy. If the commitment criterion identifies candidate rules with negative incremen- tal utility, they are eliminated from the candidate set. Elimi- nating a candidate does not affect the current strategy, so the statistics associated with the remaining candidate control rules are not discarded. This cycle is repeated until thetrain- ing set is exhausted. Each time a transformation is adopted the expected efficiency of the PRODIGY planner is in- creased, giving CONIFQSER an anytime behavior [Dean88]. uated COMPOSER’s commitment criterion against several other commitment criteria Before discussing the experiments we review these other criteria. 4.1 mom PRODIGY/EBL adopts transformations with a heuristic util- ity analysis. As control rules are proposed they am added tothe current control strategy. The savings afforded by each rule is estimated from a single example and this value is credited to the rule each time it applies. Match cost is mea- sured directly. If the cumulative cost exceeds the cumula- tive savings, the rule is removed from the current control strategy. The issue of interactions among transformations is not addressed. 4.2 STATHC'sNonrecursive STATI[C utilizes a commitment criterion based on Etzioni’s structural theory of utility. The criterion is grounded in the nonrecursive hypothesis which states that transformations will have positive incremental utility, regardless of problem distribution, if they are generated from nonrecursive expla- nations of planning behavior (i.e. no predicate in a subgoal is derived using another instantiation of the same predi- cate). The issue of interactions between transformations is not addressed. STATIC applies this criterion to control rules but the issue is important in macro-operators as well [Le- tovsky90, Subramanian90]. STAnC has out performed PRODIGY/EBL’s on several domains. The nonrecursive hypothesis is cited as theprinci- ple reason for this success @tzioni9Ob]. This claim is diffi- cult to evaluate as these systems can generate very different control rules. We clarify this issue by testing the nonrecur- sive hypothesis with the NONREC system, a re-implemen- tation of STATIC’s nonrecursive hypothesis within the PRO- DIGY/EBL framework. NONREC replaces PRODIGY/EBL’s commitment criterion with a criterion which only adopts nonrecursive control rules. 2. If each candidate rule is estimated to a particular error level, the strat- egy of adopting thefirst positive rule to reach significance can result in a higher overall error level. The discrepancy is a function of how many candidate rules with negative utility are estimated to have positive util- ity. This discrepancy has not proven significant in our experience and there are ways to bound it at the cost of more training examples. Gratch and IDeJong 237 4.3 A Composite System Etzioni has suggested that the strengths of STAnC and PRO- DIGY/EBL could be combined into a single system Etzio- nMa]. He proposed a hybrid system which embodies sev- eral advancements including a two layered utility criterion. The nonrecursive hypothesis acts as an initial filter, but the remaining nonrecursive control rules are subject to utility analysis and may be later discarded. We implemented the NONREC-UA system to test this hy- brid criterion. As control rules are proposed by PRODIGY/ EBL’s learning module, they are first filtered on the basis of thenonrecursive hypothesis. The remain rules undergoutil- ity analysis as in PRODIGY/EBL. 4,4 PALO’S Chernoff Bounds Greiner and Cohen have proposed an approach similar to COMPOSER’s [Greiner92]. The Probably Approximately Locally Optimal (PALO) approachalsoadopts ahill-climb- ing technique and evaluates transformations by a statistical method. PALO differs in its commitment criteria and and that it incorporates a criterion for when to stop learning. PALO terminates learning when it has (with high probabili- ty) identified a near-local maximum in the transformation space. We will focus on the different commitment criteria which is based on Chernoff bounds. The difference is that PALO provides stronger guarantees at the cost of more examples. This means that if the user specifies an error level of 6, the true error level will never exceed 6, and may in fact be much lower.3 Our PALO-RI system evaluates this approach. Like COMPOSER, PALO- RI uses a candidate set of rules. In this case the size of the set is fixed before learning begins. A candidate is adopted when the following inequality holds: where Xr,i is the incremental utility of rule r on problem i, C is the maximum size of the candidate set, s is one plus the number of rules in the current control strategy, and & is a is the maximal per problem AUTILITY of rule r. The pa- rameter Cis the size of the candidate set. We discuss the set- ting of the various parameters in the next section. 4.4 Experiments We compare the STRIPS domain from [Minton88], the AB- WORLD domain from lI3zioni90a] for which PRODIGY/ EBL produced harmful strategies, and the BIN-WORLD do- main from [Gratchgla] which yielded detrimental results for both STAnC and PRODIGY/EBL’s learning criteria. Re- sults are summarized in Figure 2. In each domain the sys- tems are trained on 100 training examples drawn randomly from a fixed distribution. The current control strategy is 3. PALO adopts three conservative refinements over COMPOSER: 1) chernoff bounds replace our approximate NBdas technique. 2) the worst case discrepancy from footnote 2 is bounded. 3) instead of bounding the error of adopting a bad rule at each step, PALO bounds the sum of all errors in the transformation sequence. saved after every twenty training examples.4 The graphs il- lustrate learning curves where the independent measure is thenumber of training examples and the dependent measure is execution time for 100 test problems drawn from the same distribution. This process is repeated eight times, using dif- ferent but identically distributed training and test sets. Val- ues in Figure 2 represent the average of these eight trials. “Rules Added” indicates the average number of rules learned by the system; “Train Time” is the number of sec- onds required to process the 100 training examples; “Test Time” is the number of seconds required to generate solu- tions for the 100 test problems. COMPOSER and PALO-RI require confidence parame- ters which were set at 90%. PALO-RI’s behavior is strongly influenced by parameters whose optimal values are difficult to assess. We tried to assign values close to optimal given the information available to US.~ As mentioned, COMPOSER does not implement a gener- al approach to evaluating preference rules. In particular, it cannot properly evaluate the incremental utility of prefer- ence rules in the AB-WORLD and STRIPS domains. To en- sure that differences reflect the commitment criteria and not thevocabulary of transformations, we disabled the learning of preference rules for every system in the STRIPS and AB- WORLD domains. We evaluated the ramifications of this change by comparing PRODIGY/EBL with and without preference rules and found that, in both domains, more effi- cient strategies resulted when preference rules were dis- abled. This is consistent with statements made by Minton concerning preference rules [Minton p. 1291. It was quickly apparent that PALO-RI would not adopt any transformations within the 100 training examples. We tried to give the system enough examples to reach quies- cence but this proved too expensive. The problem is two- fold - first, too many training examples were required; secondly, and as a consequence of the first problem, the can- didate set grew large since harmful rules were not discarded as quickly as in COMPOSER. This increased the cost to solve each training example. To collect statistics on PALO- RI we only performed one instead of five learning trials. Furthermore, we terminated PALO-RI after the first trans- formation was adopted or 10,000 examples, whichever came first. 4.5 Discussion The results illustrate several interesting features. COMPOS- ER exceeded the performance of all other approaches in ev- ery domain. In AB-WORLD and STRIPS, COMPOSER identified beneficial control strategies. ln BIN-WORLD the system did not adopt any transformations. It does not ap- 4. PRODIGY/EBL’s utility analysis requires an additional settling phase after training. Each control strategy produced by PRODIGY/ EBL and NONREC+UA received a settling phase of 20 problems fol- lowing the methodology outlined in [Minton88]. 5. C was fixed based on the size of the candidate list observed in prac- tice. In the best case a rule can save the entire cost of solving a problem, so for each domain, lambda for each rule was set at the maximum prob- lem solving cost observed in practice. AB-WORLD - C=30 lambda=lS; STRIPS - C=2O,lambda=lOO; BIN-WORLD - C=5,lambda=150. 238 Learning: Utility and Bias 100 50 0 0 20 40 60 80 ld # of traiing examples 2403 2100 1800 1500 1200 900 600 300 I I 6300 5600 4900 4200 3800 2800 2100 14co 700 - I 0 2’0 4; 6’0 sb lh0 # of tmhhg examples Figure 2: Summary of empriical results pear that any control rule improves performance in this do- main. It should be stressed that all systems utilized the same learning module. Therefore the results represent differ- ences in commitment strategies rather than in the vocabu- lary of transformations. As expected, COMFQSER and PALO-RI had the highest learning times as they incur the precondition cost of candi- date control rules without gaining the benefit of their rec- ommendations. The one exception was BIN-WORLD where COMPOSER quickly discarded a very expensive con- trol rule which PRODIGYEBL, NONREC, and NON- REC+UA retained. An encouraging result is that COMPOS- ER’s learning times were not substantially higher than the non-statistical systems. PALO-RI’s learning times were significantly higher. The results cast doubts on the nonrecursive hypothesis. NONREC yielded the worst performance on all domains. Even in conjunction with utility analysis the results are mixed - benefit on the AB-WORLD, slightly worse than utility analysis alone in STRIPS, and worse than no-leam- ing in BIN-WORLD. A post-hoc analysis of control strate- gies did indicate that the best rules were nonrecursive, but many nonrecursive rules were also detrimental. The slow- down on BIN-WORLD primarily results from one nonrecur- sivecontrol rule. Thus it appears that nonrecursiveness may be an important property but is insufficient to ensure per- formanceimprovements. Theseresultsare interesting since Etzioni reports that STATIC outperforms PRODIGY/EBL and No Learning in AB-WORLD. The nonrecursive hy- pothesis cannot completely account for this difference. We attribute the difference to the fact that STA~C and NONREC entertain different sets of control rules. NONREC was con- strained to use the vocabulary which was available to PRO- DIGY/EBL while STATIC has its own rule generator. Finally, although PALO-RI did not improve performance within the 100 training examples, we believe that if it were given sufficient examples it would out perform all other systems. With extended examples it did exceed COMPOS- ER’s performance in AB-WORLD. This is because the PALO approach commits to transformations with highest incremental utility while COMPOSER balances incremental utility against variance. Unfortunately the cost of PALO’s performance improvement is very high, both in terms of ex- amples and learning time. Thus, while COMPOSER may identify somewhat less beneficial strategies, it achieves much faster convergence. 5 Our investigations have exposed two important issues for future research. First, there are difficulties in extending COMPOSER’s utility gathering approach to preference rules. It is easy to record the match cost for these rules. The problem stems from determining how much a rule would save if it were added to the control strategy. This is straight- forward in the case of rules which delete alternatives. The search space explored by the planner using such a rule will always be a subset of the search search space explored with- out the rule. This is not necessarily the case with preference rules. A candidate preference rule can suggest search paths which are not explored in the solution trace. Determining the savings of a preference rule under these circumstances is expensive. The learning system must re-invoke the plan- ner and explore the alternative path. This need may arise many times in one problem. Gratch and DeJong 239 This discussion points to a general issue that some trans- formation vocabularies may be easier to implement within the COMPOSER framework than others. Perhaps the issue can be resolved by identifying alternative means to gather utility values. This problem disappears if we are willing to solve training probIems multiple times - with and without the candidate transformation - but this is unlikely to be feasible in practice. A second issue is that our commitment criteria needs fur- ther investigation. The PALO approach, compared to COM- POSER’s, provides stronger guarantees and can yield better control strategies but at a higher learning cost. Neither tech- nique directly accesses the tradeoff between the improve- ment due to learning and the cost to achieve that improve- ment. Currently we are investigating ways to apply decision theoretic methods to resolve this tradeoff in a prin- cipled way. 6 conclusions Learning shows great promise to extend the generality and effectiveness of planning techniques. Unfortunately, many learning approaches are based on poorly understood heuris- tics. In many circumstances a technique designed to im- prove planning performance can have the opposite effect. In this paper we discussed one general approach to the util- ity problem which gives probabilistic guarantees of im- provement through learning. Our implementation is re- stricted to control rules but could be extended to other representations of control knowledge. We contrasted COM- POSER with four other learning techniques -three which do not provide guarantees, and one which does. The utility analysis method of PRODIGY/EBL, the nonrecursive hy- pothesis of STATIC, and even a combination of both can produce substantial performance degradations. Greiner and Cohen’s PALO approach should yield somewhat better performance improvements than COMPOSER but at a sub- stantially higher learning cost. Acknowledgements This research is supported by the National Science Founda- tion, grant NSFIRI 87-l 9766. We benefited from many dis- cussions with Adam Martinsek and Russ Greiner. Thanks to Oren Etzioni and Nick Lewins for their comments. eferenees [Buclianan77] B. 6. Buchanan, T. M. Mitchell, R. 6. Smith andC. R. Johnson, “Models of Learning Systems,% Encyclopedia of Computer Science and Technology, Vol. 11, J. Belzer, A. G. Holzman, &A. Kent (ed.), Marcel Dekker, New York, NY, 1977, pp. 24-5 1. [DeJong86] G. F. DeJong and R. J. Mooney, “Explanation-Based Learning: An Alternative View,” Machine Learning 1, 2 (April 1986), pp. 145-176. [Dean881 T. Dean and M. Boddy, “An Analysis of Tie-Depend- ent Planning,“AAAZ88, Saint Paul, MN, August 1988 [Etzioni9Oa] 0. Etzioni, “Why Prodigy/EBL Works,” AAA190, Boston, MA, August 1990, pp. 916-922. [Etzioni9Ob] 0. Etzioni, “A Structural Theory of Search Control,” Ph.D. Thesis, Department of Computer Science, Carnegie Mellon University, Pittsburgh, PA, In preparation, 1990. pikes721 R. E. Fikes, P E. Hart and N. J. Nilsson, “Learning and Executing Generalized Robot Plans,” ArtiJciai Irzteliigence 3,4 (1972), pp. 251-288. [GovindarajuluS l] 2. Govindarajulu, The Sequential Stistical Analysis, American Sciences Press, INC., Columbus, OH, 1981. [Gratch9la] J. Gratch and 6. DeJong, “A Hybrid Approach to Guaranteed Effective Control Strategies,” MDZ, Evanston, IL, June 1991. [Gratch9lb] J. M. Gratch and G. F. DeJong, “Oncomparing oper- ationality and utility,” Technical Report UIUC- DCS-R-91-1713, Department of Computer Science, Uni- versity of Illinois, Urbana, IL, 199 1. [Gratch92b] J. Gratch andG. DeJong, “A Framework of Simplifi- cations in Letig to Plan,“FirstZnternationai Conference on ArtijWal Intelligence Planning Systems, College Park, MD, 1992. [Greiner92] R. Greiner and W. W. Cohen, “Probabilistic Hill- Climbing,” Proceedings of Computational Learning Theory and ‘Natural’ Learning Systems, 1992. &aird86] J. E. Laird,P S. Rosenbloomand A. Newell, Universal SubgoaZingandChrsnking:TheAutomaticGenerationand Learning of Goal Hierarchies, Kluwer Academic Publish- ers, Hingham, MA, 1986. [Letovsky90] S. Letovsky, “Operationality Criteria for Recursive Predicates,” AMZ90, Boston, MA, August 1990 [M&on851 S. Minton, “Selectively Generalizing Plans for Pro- blem-solving,” IJcAZ85, Los Angeles, August 1985, pp. 596-599. [Minton88] S. N. Minton, “Learning Effective Search Control Knowledge: An Explanation-Based Approach,” Ph.D. The- sis, Department of Computer Science, Carnegie-Mellon University, Pittsburgh, PA, March 1988. [Mitchell831 T. M. Mitchell, l? E. Utgoff and R. Banerji, “Learn- ing by Experimentation: Acquiring and Refining Problem- solving Heuristics,% Machine Learning: An ArtijXal Irz- teZZigence Approach, R. S. Michalski, J. G. Carbonell, T. M. Mitchell (ed.), Tioga Publishing Company, Palo Alto, CA, 1983, pp. 163-190. [Mitchell861 T. M. Mitchell, R. Keller and S. Kedar-Cabelli, “Ex- planation-Based Generalization: A Unifying View,” Ma- chine Learning I, 1 (January 1986), pp. 47-80. [Nadas69] A. Nadas, “An extension of a theorem of Chow and Robbins on sequential confidence intervals for the mean,” The Annals of Mathematical Statistics 40, 2 (1969), pp. 667-671. [Subramanian90] D. Subramanian and R. Feldman, “The Utility of EBL in Recursive Domain Theories,” AAAZ90, Boston, MA, August 1990, pp. 942-949. [woodroofe82] M. Woodroofe, Nonlinear Renewai Theory in SequentiaZ Analysis, SOCIETY for INDUSTRIAL and APPLIED MATHEMATICS, Philadelphia, PA, 1982. 240 Learning: Utility and Bias | 1992 | 55 |
1,249 | aen Allmeida tof mputer Science SUNY Plattsburgh Plattsburgh, NY 12901 almeidmj@ splava.cc.plattsburgk.edu Abstract Iterative sentences such as Mary knocked on the door four times, John played the sonata every other day, and Mary was often busy can be understood as asserting that some situation type is either repeated a certain number of times or with a certain frequency. The semantic content of iterative sentences has been standardly represented by some logical formula which quantifies over instances of a non-iterative situation type. The principal claim of this paper, and the basis of the representations proposed in it, is that we also require iterative situation types and instances in order to completely handle the range of possible interpretations of iterative sentences. Iterative sentences such as Mary knocked on the door four times, John played the sonata every other day, and Mary was often busy can be understood as asserting that some situation type is either repeated a certain number of times or with a certain frequency. As with so many topics in the analysis of temporal information in natural language, one of the earliest discussions of the semantics of iterative sentences is in (Bennett & Partee 1972). Important discussions are also given in (Aqvist, Hoepelman, & Rohrer 1980), (van Eynde 1987), and (Parsons 1990). In all of these treatments, the semantic content of iterative sentences is essentially represented by some logical formula which quantifies over instances of a non-iterative situation type. The principal claim of this paper, and the basis of the representations proposed in it, is that we also require iterative situation types and instances in order to completely handle the range of possible interpretations of iterative sentences. The first section of this paper presents an overview of the basic, i.e., non-iterative, situation types which function as the fundamental components of the iterative types. The second section briefly discusses the representation of the aspectual progressive. It will be shown that the range of possible interactions between the progressive and iterative modifiers provides important clues to the structure of the iterative types. In the following section, the different kinds of iterative situations are described, and approaches to the representation of two of the principal types- nallity iteratives and definite period ency iteratives -are proposed. In the final section, these approaches are extended to include iteratives of iteratives. aspectual classes are sets of event or situation types grouped together primarily on the basis of their temporal properties. This section presents a brief overview and systematization of the basic, i.e., non-iterative, aspectual classes which will provide a foundation for the discussion of iteratives that follows. The most familiar of these aspectual classes- achievements, accomplishments, activities, and states- come from the work of (Vendler 1967), and have been intensively studied for many years. Since Vendler’s original discussion, it has become clear that many of the components of a sentence can affect the ultimate classification of the situation described or expressed by that sentence. Excellent discussions of this notion of “aspectual composition” can be found in (Dowty 1979) and (Verkuyl 1972,1989). In (Almeida 1989, 1991), the aspectual classes are analyzed according to three fundamental and roughly orthogonal distinctions. The first of these distinctions is that situation types in general can be divided into three major classes depending on the nature of the intervals of time at which they can hold or occur: point - situations, which can only hold/occur at instantaneous points of time, interval-situations, which can only hold/occur at noninstantaneous intervals of time, and oust-interval-situations, which can hold/occur at both instantaneous and noninstantaneous periods of time. The second distinction is between situations which are homogeneous in overall structure, so that the parts of the same nature as the whole, and those which are eterogeneous, that is, consisting of distinct stages, phases, or sub-situations. The most significant difference between homogeneous and heterogeneous situations is that homogeneous situations have the so- Almeida 291 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. called subinterval property, while heterogeneous situations do not. A situation type has the subinterval property if all of the subsituations (down to a certain “grain size”) of any instance of that situation type are themselves instances of that same type. In addition, homogeneous situations take for-adverb& to indicate their duration, while heterogeneous situations take in- adverbials. The third distinction is the contrast between dynamic situations, which involve change of some sort, and nondynamic (stative) situations, which do not. Using these three criteria, Vendler’s original classes can be characterized as follows: achievements, such ‘zls those expressed by Mary fell asleep and John reached the top, are heterogeneous dynamic point-situations; accomplishments, such as those expressed by Mary played the sonata and John run a mile, are heterogeneous dynamic interval-situations; activities, such as those expressed by John run and Mary played the piano, are homogeneous dynamic interval-situations; and states, such as those expressed by Mary is busy and John is tired, are homogeneous nondynamic point- interval-situations. The Aspectual The progressive construction in English, i.e., the combination of auxiliary be and the -ing form of the main verb, has an unusually wide range of us s. Probably the most important use of the progressive ’ > the aspectual progressive. It is the aspect al progressive which is being contrasted with the simple, i.e., nonprogressive, construction in such pairs of sentences as John was running at three o’clock versus John run at three o’clock, and Mary was speaking when I entered the room versus Mary spoke when I entered the room. In the theory of the aspect& progressive desc b ‘bed in (Almeida 1989, 1991), progressive situations are represented using a function, prog, which is defined as taking as its single argument a homogeneous interval- situation type, and as having as its value the corresponding homogeneous point-interval-situation type-a progressive situation type. Since prog can only be applied to homogeneous interval-situations, the formation of the progressives of heterogeneous situations requires the use of an additional function, which takes as its argument a heterogeneous interval- situation type, and has as its value the corresponding homogeneous interval-situation type. Thus, hm can be understood as a “homogenizing” function which, among other things, has the effect of changing the temporal properties of the situation types it is applied to. Similar ideas to this conversion of a heterogeneous situation to a homogeneous situation, generally as a step in the formation of progressive situations, occur in the theories of (Bennett 1981) and (&ens & Steedman 1988). 292 Natural Language: Interpretation As examples of the application of these functions, consider the sentences John played the piano (an activity) and John played the sonata (an accomplishment). For the purposes of this paper, their semantic content can be represented as follows: (1) 3(e,t)[inst(e,play(johnl,pianol)) & time(e,t)] (2) Zl(e,t)[inst(e,play(johnl ,sonatal)) & time(e,t)] In these formulas e represents an instance of the relevant situation type, and this instance is asserted to hold/occur at time t. (note: throughout this paper tense will be disregarded.) The corresponding progressive sentences have the representations: (1) Zl(e,t)[inst(e,prog@lay(johnl ,pianol))) & time(e,t)] (2) Y(e,t)[inst(e,prog(hm(play(johnl ,sonatal)))) & time(e,t)] Iterative situations can be understood as being composed of some underlying component situation type which is either repeated a certain number of times or with a certain frequency. We can, therefore, distinguish two major types of iterative situation: (1) cardinality iteratives-where the component situation type is conceived of as being repeated some number of times, and (2) frequency iteratives-where the component situation type is conceived of as being repeated with a certain frequency. The temporal properties, and hence the representations, of these two classes differ significantly. Cardinality Hteratives Cardinality iterative situations are expressed through the use of adverbials of number or cardinal&y, such as five times, several times, and twice. For example, John played the sonata twice describes an iterative situation consisting of two component situations, each of the type piayCjohnP,sonataP). All cardinality iterative situations are heterogeneous interval-situations, regardless of the nature of their component situations, so their durations are given by in-adverbials, as in, for example, John was sick twice in a week. Parsons (1990) contends that cardinality adverbials can quantify over either times or events. For example, Twice, Brutus stubbed Caesar seems to say there are two separate times or occasions at which Brutus stabbed Caesar. On the other hand, Brutus stubbed Caesar twice allows the continuation: But both stabbings were simultaneous; one WQS in the buck und one in the thigh (p.224). Parsons’ representation for Brutus stubbed Caesar twice is (p.3 11, note 11): (3 I)[1 c now -8~ (3 eiW e2)h f e2 & (3 t)[member(t,I) & stabbing(el) & agent(el ,Brutus) & theme(el,Caesar) 8~ cul(el,t)] & (3 t)[member(t,I) & stabbing(e2) & agent(e2,Brutus) 6% theme(e2,Caesar) & cul(e2,t)]]] In this formula, the predicate cul asserts that the event represented by its first argument culminates or comes to a successful conclusion at the point of time represented by the second argument. (It should be noted that the particular method used to represent the basic situation types is not significant to the points I wish to make in this discussion.) Parsons’ representation for Twice, Brutes stabbed Caesar is (p-31 1, note 10): 0 t1)@ t2)h f t2 8~ (3 I)[I < now & at(I,tl) 82 (3 e)(3 t)[member(t,I) & stabbing(e) & agent(e,Brutus) 82 theme(e,Caesar) &. cul(e,t)] & (3 I)[I < now B at(I,t2) & (3 e)(3 t)[member(t,I) & stabbing(e) & agent(e,Brutus) & theme(e,Caesa.r) & cul(e,t)]]] While the distinction between iteratives in which the component events may be simultaneous and those in which the component events must be non-simultaneous is an interesting one, I am inclined to treat it as a difference in the implicatures of these sentences rather than as reflecting a fundamental difference in logical form. Since Parsons’ event iteration is ambiguous with respect to these two possibilities, it seems to be the more basic of these representations. Also, it will be shown below that the difference between sentence-initial component events, the individual stabbings. It will be shown that a stronger argument for the need for tokens for iterative situations and types is the existence of progressive iterative sentences such as Brutus was stubbing Caesar twice and John WQS playing the sonata three times. The proposed representation for the cardinality iterative situation expressed by the sentence John played the sonata twice, an iterated heterogeneous situation, is: 3(e,t)[inst(e,play-twice) & time(e,t)] subtype(play-twice,cardinality-iterative-type) & cardinality-of(component-set-of(play-twice)) = 2 & time(play-twice,time-of(play-twice)) & V(e)[member(e,component-set-of(play-twice)) + 3(t)[inst(e,play(johnl,sonatal)) & time(e,t) & during(t,time-of(play-twice))]] In these formulas, the token play-twice represents the iterative situation type, which is conceived of as a set of events where the cardinality of the set is given by the cardinality adverbial. The representation for the sentence Twice, John played the sonutu is essentially the same, except that there may be an additional assertion to the effect that the component events cannot be simultaneous. Actually, the nature of many situation types precludes the possibility of simultaneity regardless of the sentence position of the iterative adverbial. The difference in scope possibilities between sentence- initial and sentence-final modifiers becomes manifest in progressive iterative sentences. For example, the sentence John WQS playing the sonata twice is ambiguous between the following two readings: and sentence-final modifiers can be unders instead as reflecting a difference in the scope possibilities of the modifier in logical form. (1) 3(e,t)[inst(e,prog(hm(play-twice))) & time(e,t)] (2) 3(e,t)[inst(e,playing-twice) & time(e,t)] Parsons’ representations of cardinality iteratives have two significant shortcomings. The first is the awkward way in which the cardinality information is represented-in both cases it is necessary to explicitly incorporate as many tokens of times or events as is given by the cardinality adverbial. This is easy enough to do when the cardinality is two or three, but this approach becomes impractical as the number of subtype(playing-twice,cardinality-iterative-type) 8~ cardinality-of(component-set-of(playing-twice)) = 2 & time(playing-twice,time-of(playing-twice)) & V(e)[member(e,component-set-of(playing-twice)) + 3Q[in~(~~~mfplay(john 1 ,somW))) & duringit,time-of(playing-twice))]] times/events increases. However, a more fundamental problem with these representations is the absence of any tokens to represent the iterative situations or the iterative types themselves. Why might we need such tokens? One possible reason is to serve, as in the case of non-iterative events, as the objects of perception predicates such as see or hear. For example, in the sentence Cassius saw Brutus twice stub Caesar, it could be argued that what Cassius saw was an iterative event consisting of two instances of Brutus stabbing Caesar. But, it could also be argued that Cassius did not see an iterative event at all but only its The first reading is the progressive of the iterative situation itself, as in (At 5 o’clock), John was (in the process of) playing the sonata twice. In contrast, the second reading is that there were two occurrences of John’s being in the process of playing the sonata. This is also the interpretation of Twice, John was playing the sonata. In the first reading, the progressive function has a wider scope than the cardinality iterative modifier, while in the second reading the iterative modifier has the wider scope. Parsons is able to represent the second reading but not the first. Almeida 293 John played the piano twice, an iterated activity situation, has an analogous representation, and its progressive similarly has two possible interpretations. When the component event type is homogeneous, as in this example, the instances of the component type must always be temporally separate from one another, that is, there must be a temporal gap of some sort between each pair of instances of the component type. In summary, the general pattern for the proposed representation of cardinality iteratives is as follows (note: capitalized symbols would be replaced by the relevant values): 3(e,t)[inst(e,Card-her-Type) & time(e,t)] subtype(Card-Iter-Type,cardinality-iterative-type) & cardinality-of(component-set-of(Card-Iter-Type)) = Number & time(Card-Iter-Type&me-of(Card-Iter-Type)) & v(e)[member(e,component-set-of(Card-her-Type)) 4 3(t)[inst(e,Component-Type) dz time(e,t) & during(t,timeof(Card-Iter-Type))]] Frequency Iteratives Frequency iterative situations are expressed through the use of adverb& of frequency, such as often, always, occasionally, every hour, and every other day. (Quirk et al. 1972) distinguish two major subclasses of frequency adverbials: definite period frequency adverbials and indefinite frequency adverbials. The definite period frequency adverbials (called periodic cyclic adverbials in (van Eynde 1987)), e.g., every hour, weekly, every other day, explicitly name the times by which the frequency is measured, while the indefinite frequency adverbials (called proportion adverbials in (Parsons 1990) and indefinite cyclic adverbials in (van Eynde 1987)), e.g., often, alwuys, usually, occasionally, do not. All frequency iteratives are homogeneous situations. This seems intuitively right, and is confirmed by the fact that all frequency iteratives can take for-adverb&, as in, for example, John played the sonata every other day for Q month. Of course, they may have a very large “grain size”, hence the oddness of For five minutes, John played the sonutu every other day. In addition, frequency iteratives can be either interval-situations or point-interval-situations, depending on the nature of the component situation type. Indefinite frequency adverbials are often used in statements of habituality, as well as in nontemporal sentences such as A quadratic equation usually has two roots (Lewis, 1975). These adverbials are also discussed in (Bennett & Partee 1972), (Aqvist, Hoepelman, & Rohrer 1980), (van Eynde 1987), and (Parsons 1990). The representation of these iterative situations usually involves the use of generalized quantifiers. In this paper, only definite period frequency iteratives will be dealt with. The proposed representation for the definite period frequency iterative John played the sonata every day is: 3(e,t)[inst(e,play-every-day) & time(e,t)] subtype(play-every-day,def-period-f?eq-itemtive-type) & time(play-every-day,time-of(play-every-day)) & tl(t)[(member(t,sequence-of(days)) & during(t,time-of(play-every-day))) + !I(e’,t’)[inst(e’,play(john 1 ,sonatal)) & time(e’,t’) & during(t’,t)]] It is necessary to make use of a sequence of days, rather than simply a set, because of the possibility of using quantifiers like every-other and every-third which presuppose an ordering. Van Eynde’s (1987) representation for definite period frequency iteratives is similar to the one proposed here, except that it does not incorporate the notion of a sequence of intervals, and, most importantly, there is no token for the iterative situation itself. As in the case of cardinal&y iteratives, the progressive function has scope interactions with the frequency iteration modifiers. For example, John was playing the sonata every day is ambiguous between two interpretations, which can be represented as follows: (1) 3(e,t)[inst(e,prog@lay-every-day)) & time(e,t)] (2) 3(e,t)[inst(e,playing-every-day) & time(e,t)] subtype(playing-every-day,def-period-fmq-iterative-type) & time(playing-every-day,time-of(playing-every-day)) & V(t)[(member(t,sequence-of(days)) & during(t,time-of(playing-every-day))) + 3(e’,t’)[inst(e’,prog(hm(play(johnl ,sonatal)))) & time(e’,t’) & during(t’,t)]] The first reading is the progressive of the frequency iterative type itself. The second reading is more clearly expressed by Every day, (when Mary got home,) John was (in the process of) playing the sonata, that is, the iteration of the progressive. In the case of the cardinality iteratives, the instances of the component situation type must be properly individuated from one another. Is this also true in the case of frequency iteratives? When the underlying component situation type is heterogeneous, the issue does not arise, but what happens if it is homogeneous, as in Mary played the piano every duy ? This sentence suggests that there were temporally-separated instances of piano playing, but is this necessarily so? In particular, if we know that Mary played the piano non- stop from 12:00 to 5:00, can we still truthfully say that iWary played the piano every hour (from 12:OO to 5:00)? I believe that we can. Therefore, with frequency iteratives, no assumptions can be made about the 294 Natural Language: Interpretation separateness of the “instances” of the underlying situation type. This is the reason that the component events of frequency iteratives are not represented as constituting a set, as they are in cardinality iteratives. In summary, the general pattern for the proposed representation of definite period frequency iteratives is: 3(e,t)[inst(e,Def-Freq-Type) & time(e,t)] subtype(Def-Freq-Type,def-period-&q-itemtive-type) & time@ef-Freq-Type,time-of(Def-Freq-Type)) dz Quantifier(t)[(member(t,sequence-of(Interval-Type)) h during(t,time-of(Def-Freq-Type))) + 3(e’,t’)[inst(e’,Component-Type) & time(e’,t’) &z during(t’,time-of@ef-Freq-Type))]] Itesatives f Iteratives Iterative situations can themselves be iterated quite freely, as in, for example, John played the sonata twice every day, John played the sonata every other a!ay vor a week) twice, John played the sonata three times (in a row) twice, and John played the sonata every other day (for Q week) every month. The representations for iteratives of iteratives are generated in a straightforward fashion-the representations as described above are simply embedded within one another depending on the scope relations of the iterative modifiers. For example, John played the sonata twice every duy, where a cardinality iterative is within the scope of a definite frequency iterative, has the interpretation: 3(e,t)[inst(e,play-twice-every-day) & time(e,t)] subtype(play-twice-every-day,def-period-freq-iter-type) & time(play-twice-every-day, time-of(play-twice-every-day)) & V(t)[(member(t,sequence-of(days)) & during(t,time-of(play-twice-everyday))) + Zl(e’,t?[inst(e’,play-twice) & time(e’,t? 8~ dur@&‘,Oll As defined previously, play-twice is the type for John pluy the sonata twice. Representations for Every dQr, John played the sonata twice and Twice every day, John played the sonata can be similarly generated. Finally, the progressive John was playing the sonata twice every day has three possible interpretations, all of which can easily be represented using this approach. Conclusion In this paper, approaches to the representation of two major types of iterative situation-cardinality iteratives and definite period frequency iteratives-were proposed. In addition, some of the major temporal properties of these iterative types were described. Most importantly, I have argued that we require iterative situation types in our semantic representations. eferences Almeida, M.J. 1989. A Theory of the Aspectual Progressive. In Proceedings of the 1 lth Annual Conference of the Cognitive Science Society, 244-251. Hillsdale, NJ: LEA. Almeida, M.J. 1991. Aspect and the Temporal Properties of the Aspectual Classes. Unpublished Manuscript. Aqvist, L., Hoepelman, J., and Rohrer, C. 1980. Adverbs of Frequency. In Rohrer, C. ed. Time, Tense and Quantzfiers. Tubingen: Niemeyer. 1-17. Bennett M. 1981. Of Tense and Aspect: One Analysis. In Tedeschi, P.J., and Zaenen, A. eds. Tense and Aspect, Vol. 14 of Syntax and Semantics. New York: Academic Press. 13-29. Bennett, M., and Par-tee, B. 1972. Toward the Logic of Tense and Aspect in English. Santa Monica, Calif.: System Development Corporation. Dowty, D.R. 1979. Word Meaning and Montague Grammar. Dordrecht: D. Reidel. Lewis, D. 1975. Adverbs of Quantification. In Keenan, E.L. ed. Formal Semantics of Natural Language. Cambridge: Cambridge University Press. 3-15. Moens, M., and Steedman, M. 1988. Temporal Ontology and Temporal Reference. Computational Linguistics 14(2): 15-28. Parsons, T. 1990. Events in the Semantics of English: A Study in Subatomic Semantics. Cambridge, Mass: MIT Press. Quirk, R., Greenbaum, S., Leech, G., and Svartvik, J. 1972. A Grammar of Contemporary English. London: Longman. van Eynde, F. 1987. Iteration, Habituality and Verb Form Semantics. In Proceedings of the Third Conference of the European Chapter of the Association for Computational Linguistics, 270-277. Morristown, NJ: Association for Computational Linguistics. Vendler, 2. 1967. Linguistics in Philosophy. Ithaca, NY: Cornell University Press. Verkuyl, H.J. 1972. On the Compositional Nature of the Aspects. Dordrecht: D. Reidel. Verkuyl, H.J. 1989. Aspectual Classes and Aspectual Composition. Linguistics and Philosophy 12( 1): 39-94. Almeida 295 | 1992 | 56 |
1,250 | Actions, at ionale Clauses and ses* Cecile T. Balkanski Aiken Computation Lab, Harvard University Cambridge, MA 02138 cecile@das. harvard .edu Abstract Utterances that include rationale clauses and means clauses display a variety of features that af- fect their interpretation, as well as the subsequent discourse. Of particular importance is the infor- mation that is conveyed about agents’ beliefs and intentions with respect to the actions they talk about or perform. Hence, for a language interpre- tation system to handle these utterances, it must identify the relevant features of each construction and draw appropriate inferences about the agents’ mental states with respect to the actions and ac- tion relations that are involved. This paper de- scribes an interpretation model that satisfies this need by providing a set of interpretation rules and showing how these rules allow for the derivation of the appropriate set of beliefs and intentions as- sociated with each construction. Introduction Utterances that describe or refer to multiple actions display a variety of features that affect their interpre- tation, as well as the subsequent discourse. Of par- ticular importance is the information that is conveyed about agents’ beliefs and intentions with respect to the actions they talk about or perform. For example, al- though the following utterances are about the same two actions, some of the beliefs and intentions that are communicated may be diametrically opposed: (1) a. John dirtied the carpet by walking across the room. b. John walked across the room to dirty the carpet. The speaker of (la) communicates her belief that John’s walking across the room resulted in John’s dirtying the carpet, but she may or may not be con- veying a belief that John actually intended to walk across the room as a way of dirtying the carpet. The speaker of (lb), on the other hand, does express her *This research has been supported by a contract from U S WEST Advanced Technologies, by the Air Force Office of Scientific Research under Contract No.AFOSR-89-0273, and by an IBM Graduate Fellowship. 296 Natural Language: Interpretation belief that John intended to walk across the room as a way of dirtying the carpet, but not necessarily that John’s walking across the room actually resulted in his dirtying the carpet. Utterance (la) includes a means clause and utter- ance (lb), a rationale clause. As their names suggest, means clauses express the means by which an action is performed, while rationale clauses express the purpose, or rationale, of the main clause action’. The above examples show that these types of utterances express similar relations between actions, but that the speaker and performing agent (i.e., the agent whose actions are being described in the utterance) may have different attitudes with respect to these actions. These differ- ences are critical because of their effect on subsequent discourse; for example, continuation (a) is felicitous in (2)) below, but not in (3)) and continuation (b) is felic- itous in (3) but not in (2). They are also important be- cause of their effect on planning and plan recognition. Among those actions that fail, for example, only those that are intended will constrain replanning (Bratman 1987). (2) John dirtied th e carpet by walking across the room, . . . a. but he didn’t even realize it. b. ?but that didn’t work because his shoes were clean. (3) John walked across the room to dirty the carpet, . . . a. ?but he didn’t even realize it. b. but that didn’t work because his shoes were clean. For a language interpretation system to handle ut- terances about actions appropriately, it must therefore be able to determine the relationships between actions expressed in multi-action utterances and derive the be- liefs and intentions of the speaker and performing agent with respect to these actions and action relationships. This paper describes an interpretation model that ad- dresses this need. This model comprises an axioma- tization of basic principles of belief and intention and ‘Rationale c lauses are to be distinguished from purpose clauses, e.g., “Mary bought a suit to wear at the meeting”, and infinitival relative clauses, e.g.: “John found the book to give to his sister”. One difference among these construc- tions is that only rationale clauses can be paraphrased using the words “in order to”(Huettner & al 1987). From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. a set of interpretation rules for deriving the action re- lations expressed in these utterances. It thereby ac- counts for both the overlap and the difference in mean- ing between utterances with rationale clauses and ut- terances with means clauses, as illustrated in (l), (2) and (3). While utterances with rationale clauses may be about sequential or simultaneous actions (Balkan- ski 1992), this paper focuses on utterances concerning simultaneous actions. This paper extends a companion paper (Balkanski 1992) in addressing the mental states of the speaker and performing agent and in considering utterances about present and future, as well as past actions. Sur- prisingly little research has addressed the interpreta- tion of means clauses and rationale clauses. There is a large body of linguistics research on purpose clauses, but it focuses on syntactic aspects of the construction and issues of control (e.g., Bach (1982), Jones (1991)). The planning literature provides very useful theories of action and action relations, which will be referred to later in this paper. In the computational linguistics literature, Huettner’s work on the generation of ad- junct clauses (Huettner & al 1987) and Di Eugenio’s analysis of instructions (Webber & Di Eugenio 1990; Di Eugenio 1992) both examine purpose constructions, but from different perspectives than that of this paper. Huettner focuses on decision making in the generation process, e.g., determining which argument to gap (i.e., delete) when. Di Eugenio uses action relations similar to those presented here, but does not address issues re- garding differences in the mental states of the speaker and performing agent, temporal aspects of action oc- currences, or the role of contextual conditions, all of which are central to this paper. eliefs and intentions expressed in utterances with rationale and means clauses This section examines in more detail the characteris- tic beliefs and intentions expressed in utterances with rationale clauses and means clauses. These properties, illustrated in (1)) (2) and (3), emerged from a detailed analysis of multi-action utterances in task-oriented dia- logues (Balkanski 1990) and a subsequent examination of selections from Associated Press news stories. Utterances with rationale clauses or means clauses are about two actions, the occurrence of one of them possibly generating (Goldman 1970), i.e., resulting in, the simultaneous performance of the other2. The generation relation, independently motivated by work in plan recognition (Pollack 1986; Balkanski 1990; Lochbaum 1991), holds of two actions A and B when (a) their agents and times are the same, (b) there is a 2Because utterances with rationale clauses are not re- stricted to simultaneous actions, they are not restricted to the generation relation either; the general case in treated in the companion paper (Balkanski 1992). set of contextual conditions, called generation-enabling conditions (e.g., John’s shoes being dirty) that hold during performance time and (c) there is a conditional generation relation between the act-type of A, the act- type of B and these conditions. A conditional gen- eration relation holds among act-types o and /3 and conditions C if whenever an action of type cy occurs while these conditions hold, an action of type p oc- curs at the same time. In this paper, the generation relation will be notated as GEN(A,B) where A and B are actions, comprising an act-type, agent and time (Balkanski 1990). A n important property of this rela- tion is that if it holds of two actions A and B, and A occurs, then so does B. This follows from the genera- tion relation requiring the relevant generation-enabling conditions to hold during performance time. Utterances with means clauses and rationale clauses, therefore, refer to both a generating and a generated ac- tion, performed by the same agent at the same time. In utterances with means clauses (MC), the generating action is expressed in the adjunct clause, whereas in ut- terances with rationale clauses (RC), it is expressed in the matrix clause. Let A represent the generating ac- tion (e.g., John’s walking across the room during some time interval) and B the generated action (e.g., John’s dirtying the carpet during that time interval). Let S be the speaker, G the performing agent, T, the time of speech, and T, the time of action (past, present or future). The beliefs and intentions expressed in these two 14 PI [cl idI H IfI types of utterances are the following: In both types of utterances, S believes that A occurred (respectively, is occurring, will occur). In utterances with MCs, but not necessarily those with RCs, S believes that B occurred (is occurring, will occur). In utterances with MCs, but not necessarily those with RCs, S believes that GEN(A,B). In the MC case, therefore, but not necessar- ily in the RC case, S believes there is a condi- tional generation relation between the act-types of A and B and some set of generation-enabling conditions, and that these conditions held (are holding, will hold). In utterances with RCs, but not necessarily those with MCs, S believes that A was intended (will be intended) on the part of G. In utterances with RCs, but not necessarily those with MCs, S believes that B was intended (will be intended) on the part of G. In utterances with RCs, but not necessarily those with MCs, S believes that A was intended (will be intended) on the part of G us a way of generating B. In the RC case, therefore, but not necessarily in the MC case, S believes that G ex- pects (at the start of action time) the relevant generation-enabling conditions to hold. The belief in [a] is readily associated with these ut- Balkanski 297 terances. Those in [b],[c], [e] and [f] were illustrated in (l), (2) and (3). Although the belief in [d] is likely to hold of utterances with means clauses like (2) (i.e., the walking action was probably intended on the part of John), this need not be the case, as illustrated in (4a) below. Utterance (4b) shows that the use of a rationale clause forces an interpretation in which the speaker believes that the generating action (here the slipping action) is intended on the part of its agent. (4) a. John broke his arm by slipping on the ice. b. John slipped on the ice to break his arm. The beliefs and intentions listed above are formalized in (5); their truth values with respect to utterances with rationale clauses and means clauses are given in Table 1, where a “1” indicates that the corresponding belief is true, and a “?” that it can be true or false, depending on the context. (5) [a] BEL(S, T,, OCCUR(A)) [b] BEL(S, TJ, OCCUR(B)) [c] BEL(S, ‘L, GEN(A,B)) [d] BEL(S, T,, INT(G,start(T,),act-type(A),T,)) [e] BEL(S, T,, INT(G,start(T,),act-type(B),T,)) [f] BEL(S, T,, INT(G,start(T,), act-type(A) & GEN(A,B), T,)) Beliefs: Utterances with RCs: Utterances with MCs: 1 1 1 ? ? ? Table 1: Beliefs and intentions expressed in utterances with MCs and RCs The functions “start” and “act-type” return, respec- tively, the starting point of a time interval and the act- type of an action (e.g., the act-type “dirty the carpet” for the action of John’s dirtying the carpet during T). The predicate BEL holds of an agent, a time (interval) and a proposition if the agent believes the proposi- tion during that time. The predicate OCCUR holds of an action if that action occurs. Because actions have associated times, the OCCUR predicate inherits its time from its argument. When the time of action A is past, then OCCUR(A) is true if A occurred in the past; when the time of A is present, then OCCUR(A) is true if A is an action currently being performed; fi- nally, when the time of A is future, then OCCUR(A) is true if A is an action that will necessarily occur in the future. Although it is impossible to determine whether an action will necessarily occur in the future, when used in belief contexts (as in this paper), this predicate make claims about an agent’s beliefs about the past, present or future occurrence of actions. The predicate INT holds of an agent, a time (point) Ti , an act-type, and a time (interval) T2 if the agent intends at Tr to perform an action of that type during T2. Because Tr =start(Ts) in [d], [e] and [f], these beliefs are about present-directed intentions (Bratman 1987). Whether or not G also had, at an earlier time, a future- directed intention to perform an action of type A (or ) is not of concern here3. The GEN relation in [f] is used as a modifier indicating the way in which an action is performed. That is, INT(G, Ti , act-type(A) 8~ GEN(A,B), 3’2)) means that G intends at Tr to per- form an action of the type of A during T2 us a way of generating B (Lochbaum & al 1990). The beliefs represented in Table 1 hold for past, present and future actions, as indicated by the verb tenses used in the English descriptions. The exam- ples in the Introduction were about past actions, but the same acceptability judgments are obtained with present and future actions. For example, in uttering (6a), below, S may have reason to believe that Mary’s keeping Sue up is unintentional, or, in uttering (6b), that John will fail to reset the printer. (6) a. Mary is keeping S ue up by playing the piano. b. John will press the red button to reset the printer. These beliefs also hold for utterances in which the speaker and the agent are the same person. For ex- ample, the speaker of (7a), below, believes that she intended to extend her arm out of the window [d], in- tended to signal for a left turn [e], and intended to extend her arm as a way of signaling for a turn [f]. She also believes that she extended her arm [a], but not necessarily that in doing so, she signaled for a turn [b],[c] (e.g., maybe she knows that the driver behind her could not see her arm). Similar results obtain for present and future actions. For example, the speaker of (7b) may have doubts about her success in signaling for a turn. In utterances with means clauses, e.g. (7c), the speaker may or may not intend to dirty the carpet even if she believes that she is doing so (or will do ~0)~. So beliefs [e] and [f] can be true or false, as desired, despite the speaker’s having beliefs [b] and [cl. (7) a. I extended my arm out of the car window to signal for a left turn. b. I am extending (or will extend) my arm out of the window to signal for a turn. c. I am getting (or will get) the carpet dirty by walking across the room. The goal of the analysis presented in the remainder of this paper is to derive the beliefs and intentions given in Table 1. These beliefs and intentions will be derived on the basis of the logical form of an utterance, a set of axioms about belief and intention, and interpretation rules defining the meaning of the relevant linguistic constructions. 3We are also not concerned with the performing agent’s intentions during action time, since when an agent is ac- tually performing an action A, we no longer say that he intends to A (Bratman 1987). 4This distinction co rresponds to the difference between doing A intentionally and intending to do A (Bratman 1987). 298 Natural Language: Interpretation roeessing framework This section presents the logical forms that are input to the interpretation model, and a set of axioms about belief and intention that are necessary for the interpre- tation process. Logical forms Logical forms represent the literal meaning of an ut- terance and are derived compositionally by semantic interpretation rules based on the syntactic structure of the utterance. We present here the main aspects of our representations; a detailed description is given in the companion paper (Balkanski 1992). Our logical forms reify actions (Davidson 1967) and are represented as existentially quantified sentences of first-order logic, with predicates that include an additional argument position for the action being described. Multi-action utterances are handled by introducing multiple action variables and by representing connectives like “by” and “to” using two-place predicates ranging over these ac- tion variables, as illustrated in (8)5. (8) John will dirty the carpet by walking across the room. LF: 3x1, x2, dirty(x2) A agt(xz, John)/\ obj(x2, Carpet) A future(x2)A wdk(x~) A ioc(x~, Room) A by(x2, XI) b. John will walk across the room to dirty the carpet. LF: 3x1, x2, walk(x:1) A agt(xl, John)/\ ~oc(xl, Room) A future( dirty(x2) A obj( x2, carpet) A to( XI, x2) Every action argument is represented as a separate predicate to avoid having either to introduce existential variables for missing arguments or to determine how these arguments are recovered during the process of building the logical form. As will be shown later in this paper, the missing agent and time arguments of the adjunct clause actions in the logical forms in (8) will be recovered through the interpretation of the action relations. Rather than denoting “real” action tokens, action variables in our formalism correspond to action enti- ties in the discourse model that may represent either actual (i.e., “real”) actions, namely, actions that have occurred, or unrealized actions, that is, actions that have not yet occurred or might never occur (Balkanski 1991). Quantification is therefore over a universe that contains everything that can be talked about, with no commitment to existence in the real world (as in, e.g., Hobbs (1985), Schubert & Hwang (1990)). Since the mapping from action variables to action entities is not an issue relevant to the main topic of this paper, we 5 Extensional representations of propositions, like this one, have difficulties with respect to certain intensional phenomena such as substitution of identicals. Hobbs dis- cusses this problem and a number of possible solutions (Hobbs 1985), but these questions lie beyond the scope of the present paper. assume from here forward that action variables have been replaced by their corresponding action entities. Axioms Agents’ beliefs are taken to be closed under logical sequence and distributive over conjunctions: con- Closure: BEL(g, t, p)A BEL(g, t, p --) q) + BEL(g, t, a) Distributivity: BEL(g, t, pl A . . . A p,) 4 BEL(g, t, PI) A . . .A BEL(g,t,pn) to Agents uttering a declarative sentence are assumed believe the propositional content of that utterance6: eclarative rule: UTTER(s, t,“p”) + BEL(s, t, p) where “p” is a declarative utterance and p its LF. We also adopt an intention axiom, 11, assumed to be believed by all agents, that states necessary conditions on an agent’s intention to perform an action as a way of generating another. According to 11, if G intends at ti to do o at t2 as a way of generating b, then he must intend to do cy at t2 and to do ,/3 at t2, and he must believe that the two actions are related by generation (Pollack 1986). 11: INT(g, tl, a & GEN(a, b), t2) + INT(g, t19 a, t2)A INT(g, tl, P, &)A BE% tl SEW, b)) where cy = act-type(u) and ,0 = act-type(b) Interpretation The process of interpreting a logical form consists in applying interpretation rules to the various predicates of that logical form. This section presents these rules and describes the way in which the appropriate beliefs and intentions expressed in utterances with rationale and means clauses are derived on the basis of them. To emphasize the fact that reasoning takes place in belief contexts, interpretation rules are embedded in belief predicates. Interpretation rules The inference rules defining the meaning of means clauses and rationale clauses are given below. They formalize those given in the companion paper (Balkan- ski 1992) and extend them in a number of ways, as dis- cussed below. The by and to predicates in the left hand side of the rules are the logical form predicates repre- senting the NL connectives introducing means clauses and rationale clauses. Note that the order of the argu- ments in the by and GEN predicates is reversed. 6A more complete treatment of declaratives would re- quire a complex theory of speech acts (e.g., Cohen & Levesque (1990), Perrault (1990)); these topics, however, lie beyond the scope of this paper. Balkanski 299 LF1: BEL(s, t, by@, a) + GEN(a, b) A OCCUR(a)) LF2: BEL(s, t, to(a, b) - INT(agt(a), start(time(a)), act-type(a) & GEN(a, b), time(u))) The LFl rule maps the LF representation of means clauses to the generation relation, capturing the fact that the speaker of an utterance with a means clause believes that the occurrence of the main clause action follows from that of the adjunct clause action. The second conjunct of this rule specifies the speaker’s be- lief of the occurrence of the generating action. This occurrence is indeed a feature of the means clause con- struction and not of the form of the verb, namely a gerund; as explained below, the occurrence of an ac- tion may be derived from certain tensed verbs. The LF2 rule maps the LF representation of these constructions to the performing agent’s intention to perform the main clause action as a way of generating the adjunct clause action. By virtue of intention ax- iom 11, it then follows that the speaker of an utterance with a rationale clause believes that the agent believes (believed, or will believe) that these actions are re- lated by generation (in addition to believing that the agent intended (or will intend) to perform both ac- tions). Given that the speaker may believe that the agent’s beliefs are incorrect, the generation relation in these utterances is, in a sense, only potential. This is as desired since, as discussed earlier, the speaker does not necessarily believe that a generation relation actu- ally holds between the two actions that are referred to in the utterance. In the companion paper (Balkanski 1992), we dis- cussed the potentiality of the generation relation in utterances with rationale clauses, but did not propose a way of capturing it. In this paper, casting the anal- ysis in the context of the beliefs and intentions of the speaker and performing agent allows for a very sim- ple and elegant treatment of this aspect of rationale clauses. The form of a verb may sometimes provide infor- mation about the occurrence of the associated action. For example, a past tense (action) verb indicates the speaker’s belief that the corresponding action occurred. Similarly, a present or future tense verb indicates the speaker’s belief of the present or future occurrence of the associated action. Tensed verbs are represented in the logical form by the predicates past, present or fu- ture, as illustrated in (8). The following inference rule captures the fact that these predicates express asser- tions about action occurrences: LF3: BEL(g, t,past(a) V present(a) V future(a) + OCCUR(a)) Applying the rules This section illustrates the interpretation process by applying the interpretation rules and axioms presented in the preceding sections to the sample utterances and logical forms in (8), thereby showing how the beliefs and intentions recapitulated in Table 1, are derived. As mentioned earlier, action variables are assumed to have been replaced by action constants (let ~1 and 22 be replaced by A and B respectively). The logical forms under consideration are therefore conjunctions of ground literals. By the Declarative rule, the speaker, S, believes these logical forms and by the Distributivity rule, S be- lieves each conjunct of those propositions, and in par- ticular the one expressing the action relation, namely: (9) MC case: BEL(S, T,, by(B,A)) RC case: BEL(S, T,, to(A,B)) The beliefs in (10) then follow from (9) and the inter- pretation rules LFl and LF2 (along with the Closure and Distributivity axioms): (10) MC case: BEL(S, T,, GEN(A,B)) A BEL(S, T,, OCCUR(A)) i.e., beliefs [c] and [a] from Table 1. RC case: BEL(S,T,,INT(agt(A), start(time(A)), act-type(A)&GEN(A,B), time(A))) i.e., belief [f] from Table 1. In the RC case, it follows from S’s belief of inten- tion axiom 11 that S also believes that the agent of A believed (believes, or will believe) that A and B are related by generation: (11) RC case: BEL(S,T, ,BEL(agt(A),start(time(A)), GEN(A,B))) Because S only believes that the performing agent believed (believes or will believe) a GEN relation be- tween A and B, S herself may or.may not believe that relation, depending on whether or not S believes the agent’s beliefs are correct. This is as desired, given the “?” for belief [c] in Table 1. By the Declarative and Distributivity rules, S also believes the conjuncts in the logical forms that .express the tense of the matrix clause verbs, namely: (12) MC case: BEL(S, T,, future(B)) RC case: BEL(S, T,, future(A))) It then follows from these beliefs and the interpreta- tion rule LF3 occurred: that S believes the corresponding action (13) MC case: BEL(S, T,, OCCUR(B)) i.e., belief [b] from Table I. RC case: BEL(S, T,, OCCUR(A)) i.e., belief [a] from Table 1. In the MC case, S’s belief about the occurrence of B, the generated action, can also be derived from beliefs [a] and [cl (see (lo)), on the basis of the definition of generation. In the RC case, however, this belief cannot be derived from sentential information alone: neither from the form of the verb (the logical form does not 300 Natural Language: Interpretation include future(B)), nor from the interpretation of the construction (i.e., LF2). This is as desired, given the “?” in Table 1 for belief [b]. Looking now at intentions, nothing can be derived in the MC case about the agent’s intention to perform either A or B, independently, or one as a result of the other, as desired given the “?” for beliefs [d], [e] and [f] in Table 1. In the RC case, given that S believes that the agent of A intends to perform A as a way of generating B (see (IO)), it follows from S’s belief of intention axiom II that S also believes that the agent of A intends both to perform A and to perform B. We have now shown how each belief in Table 1, along with its associated truth value, is derived. In addition, the present analysis also accounts for the missing agent and time arguments of the adjunct clause actions in (8a) and (8b). B ecause the generation relation requires the agents and times of the generating and generated actions to be identical, these missing arguments can be recovered on the basis of the agent and time informa- tion associated with the actions expressed in the main clause of the utterances. @onc.hsion This paper presented an interpretation model that ac- counts for the particular features of utterances with means clauses and rationale clauses. The model achieves this goal by deriving the appropriate set of beliefs and intentions of the speaker and performing agent regarding the actions and action relations ex- pressed in these utterances This model is being refined and extended in a num- ber of directions. We are analyzing utterances with ra- tionale clauses and means clauses embedded in negated contexts and modal contexts. Initial analysis of these utterances shows that the interpretation rules can ac- count for them as well if they are applied within the embedding context. For example, given the utter- ance “John wanted to dirty the carpet by walking across the room” , the model should derive Want(John, GEN(A,B) A OCCUR(A)) from LFl and Want(John, OCCUR(B)) f rom LF3, where A is the action of John’s walking across the room (during some time interval) and B that of John’s dirtying the carpet (during the same time interval). We are also examining the mean- ing of the “by” and “to” connectives in contexts other than means clauses and rationale clauses in order to in- tegrate the interpretation rules presented here into an interpretation model of wider scope. Finally, we are investigating further additions to our theory of inten- tion and working on a Prolog implementation of our interpretation model. Acknowledgments. I would like to thank Barbara Grosz, Karen Lochbaum and Stuart Shieber for many helpful discussions and comments regarding this paper. eferences Bach, E. 1982. Purpose clauses and control. In Jacob- son, P. and Pullum, G., eds, The Nature of Syntactic Representation. D. Reidel Publishing Company. Balkanski, C. T. 1990. Modelling act-type relations in collaborative activity. Technical Report TR-23-90, Harvard Univ. Balkanski, C. T. 1991. Logical form of complex ac- tion sentences in task-oriented dialogs. In Proc. 29th Annual Meeting of the ACL, Student Session. Balkanski, C. T. 1992. Action relations in rationale clauses and means clauses. Proc. COLING’92. Bratman, M. E. 1987. Intention, Plans, and Practical Reason. Harvard University Press. Cohen, P. R. and Levesque, H. J. 1990. Rational interaction as the basis for communication. In Co- hen, P. R., Morgan, J. L., and Pollack, M. E., eds, Intentions in Communication. MIT Press. Davidson, D. 1967. The logical form of action sen- tences. In Rescher, N., editor, The Logic of Decision and Action. University of Pittsburgh Press. Di Eugenio, B. 1992. Goals and action in natural language instructions. Technical Report MS-CIS-92- 07, Univ. of Pennsylvania. Goldman, A. I. 1970. A Theory of Human Action. Princeton University Press, Princeton, NJ. Hobbs, J. 1985. Ontological promiscuity. In Proc. 23rd Annual Meeting of the ACL. Huettner, A., Vaughan, M., and McDonald, D. 1987. Constraints on the generation of adjunct clauses. In Proc. 25th Annual Meeting of the ACL. Jones, C. 1991. Purpose clauses: syntax, themat- its and semantics of English purpose constructions. Kluwer Academic Publishers. Lochbaum, K. E., Grosz, B. J., and Sidner, C. L. 1990. Models of plans to support communication: An initial report. In Proc. AAAI’SU. Lochbaum, K. E. 1991. An algorithm for plan recogni- tion in collaborative discourse. In Proc. 29th Annual Meeting of the ACL. Perrault, C. R. 1990. An application of default logic to speech act theory. In Cohen, P. R., Morgan, J. L., and Pollack, M. E., eds, Intentions in Communica- tion. MIT Press. Pollack, M. E. 1986. Inferring domain plans in question-answering. Technical Report 403, SRI In- ternational, Menlo Park, CA. Schubert, L. K. and Hwang, C. H. 1990. An episodic knowledge representation for narrative texts. Techni- cal Report 345, Univ. of Rochester. Webber, B. and Eugenio, B. D. 1990. Free adjuncts in natural language instructions. In Proc. COLING’90. Balkan&i 301 | 1992 | 57 |
1,251 | Daniel Jurafsky Computer Science Division, 573 Evans Hall University of California at Berkeley Berkeley, California 94720 jurafsky@cs.berkeley.edu Introduction Models of parsing or of sentence interpretation generally fall into one of three paradigms. The Zinguisticparadigm is concerned with computational models of linguistic theories, the computational paradigm with the computationally best process for computing the meaning or structure of a sen- tence, and the psychological paradigm with psychological modeling of human interpretation of language. Rarely have models attempted to cross disciplinary boundaries and meet the criteria imposed by each of these paradigms. This paper describes a model of human sentence inter- pretation which addresses the fundamental goals of each of these paradigms. These goals include the need to produce a high-level and semantically rich representation of the mean- ing of the sentence, to include a motivated and declarative theory of linguistic knowledge which captures linguistic generalizations, and to account in a principled manner for psycholinguistic results. The model consists of a grammar and a semantic inter- preter named Sal which include: a theory of grammar called Construction-Based Interpre- tive Grammar (CIG) which represents knowledge of lan- guage as a collection of uniform structures called gram- matical constructions representing lexical, syntactic, se- mantic, and pragmatic information. an evidential access function, which uses different knowl- edge sources to interactively guide its search for the cor- rect constructions to access. an information-combining operation called integration, which is a unification-like operation augmented with knowledge about the semantic representation language and with a mechanism for functional application. a selection algorithm which prefers more coherent inter- pretations and which prunes low-ranked interpretations. Thanks to Robert Wilensky, Nigel Ward, Michael Braverman, Marti Hearst, Jane Edwards, Graeme Hirst, and Peter Norvig for many helpful comments on these ideas and on the dissertation on which this paper is based. This research was sponsored by the Defense Advanced Research Projects Agency (DOD), moni- tored by the Space and Naval Warfare Systems Command under N00039-88-C-0292, and the Office of Naval Research, under con- tract N00014-89-J-3205. The Grammar The grammar that is embedded in Sal is a linguistic theory called Construction-Based Interpretive Grammar (GIG), part of a family of theories called Construction Grammars (Fillmore et al. 1988; Kay 1990; Lakoff 1987). CIG defines a grammar as a declarative collection of structures called grammatical constructions which resemble the construc- tions of traditional pre-generative grammar. Each of these constructions represents information from various domains of linguistic knowledge, including phonological, syntac- tic, semantic, pragmatic, and frequency information. Thus the grammar constitutes a database of these constructions, which might be called a constructicon (on the model of the word lexicon). Lexical entries, idioms, and syntactic struc- tures are all represented uniformly as constructions; thus the constructicon subsumes the lexicon, the syntactic rule base, and the idiom dictionary needed by other theories. Like many recent theories of grammar (such as Pollard & Sag 1987; Bresnan 1982; Uszkoreit 1986) CIG repre- sents constructions as partial information structures which can be combined to build up larger structures. CIG dif- fers from most recent grammatical theories in a two major ways. First, CIG allows constituents of constructions to be defined semantically as well as syntactically, such as the first constituent of the WH-NON-SUBJECT-QUESTION con- struction introduced below (Jurafsky 1991 & 1992 discuss constructions like the HOW-SCALE construction which re- quire semantic information to correctly specify their con- stituents). Second, CIG includes weak constructions, which are abstract constructions (like the lexical weak construc- tions VERB or NOUN) which structure the grammar in an abstraction hierarchy that is useful for access, for defining other constructions, and for learning. Figure 1 shows an example of the CREATE construction, the lexical construction which accounts for the verb cre- ate, showing that the construction is named CREATE, has a frequency of 177, and is a subtype of the weak VERB construction. The constitute of the construction is a seman- tic structure which is an instance of the Creation-Action concept. Semantic structures in CIG are represented in a simple frame-like representation language. This concept has two subordinate relations, Creator and Created, both currently unfilled (that is, filled by unbound variables $a 302 Natural Language: Interpretation From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. and $b). This construction has only one constituent, which includes phonological (or graphemic) conditions specifying the form “create”. The frequency numbers which appear in constructions are taken as number of occurrences per mil- lion in the Brown Corpus, computed from Francis & KuEera (1982) and Elleg&d (1978); although these works assume different models of syntax than CIG, it was usually possible to translate the numbers appropriately. weak construction a~--tiVerb abstraction link ----A construction frequency i construction narnaW&r&& J 177) J a Creation-Action $c constitute (creator $a) \k variable (Created $b)) constituent link-4- graphemic constraints constituent ,*“create’‘-@ a.@ Figure 1: The “Create” Construction A more complex construction is the WH-NON-SUBJECT- QUESTION construction (Jurafsky 1990), which accounts for sentences which begin with certain wh-clauses which do not function as the subject of the sentence, such as the sentence “How can I create disk space?“. The representation for the construction appears in Figure 2. The constitute of the construction instantiates the Question concept; its seman- tics is specified by integrating the semantics of the ‘fronted’ wh-element with the semantics of the other constituents. (Thus by not using syntactic traces, empty categories, or coindexing as place-holders for semantic integration, Sal is consistent with the evidence in Figure 4 that distant fillers are directly integrated.) Each of the construction’s four con- stituents are specified by other predicates. The first, “how”, is a wh-element, as shown in Figure 2 by the Identify con- cept. The Identify concept characterizes all wh- construc- tions - it instantiates a frame in which the identity of some element is in question, and where some background infor- mation is provided to help identify the element. The second constituent (“can”) is an auxiliary verb, and participates to- gether with the third constituent (the NOUN-PHRASE) in the SUBJECT-PREDICATE construction. The second and fourth constituents are constrained to occur in an instance of the VERB-PHRASE construction. This constituent-by-constituent method is more fine-grained and on-line than the rule-to-rule method (Bach 1976) used by most other models which waits for semantic integration until the completion of an entire construction or rule. Sal is parallel because it can maintain more than one inter- pretation simultaneously, although only for a limited time. Sal is interactive because it allows syntactic, semantic, and higher-level expectations to help in the access of linguistic information, integrate constructions into the interpretation, and choose among candidate interpretations. Sal is uniform because a single interpretation mechanism accounts for the access, integration, and selection of structures at all levels of sentence processing. Sal’s single mechanism thus sub- sumes a lexical analyzer, a parser, an idiom processor, and a semantic interpreter. Figure 3 outlines the architecture. INPUT STRING The Interpreter 11 As a cognitive model, Sal is qualitatively consistent with all of the psycholinguistic results summarized in Figure 4. These results, and the criteria discussed in the introduction above, constrain Sal’s architecture toward four properties; it is on-line, parallel, interactive, and uniform. Sal is on-line because it maintains an interpretation for the utterance at all times, updating after each constituent of each construction. Sal’s architecture consists of three components: the work- ing store, the long-term store, and the interpretation func- (a Question $q (Queried $var) (a Figure 2: The Wh-Non-Subject-Question Construction The access threshold The Grammar (long-term store) X ACCESS POINT of X K Access Buffer working store The selection threshold SELECTION POINT of M (because N is pruned) Interpretation Store Figure 3: The Architecture of Sal Jurafsky 303 Lexical constructions are accessed in parallel. Swinney (1979), Tanenhaus et al. (1979) Idioms are accessed in parallel. Cacciari & Tabossi (1988) Syntactic constructions are accessed in parallel. Kurtzman (1985). Gorrell(1987) and (1989) More frequent constructions are accessed more easily. “Qler (1984), Zwitserlood (1989). Simpson & Burgess (1985) The access-point of a construction is not immediate, varying with Swinney & Cutler (1979). Cacciari & Tabossi (1988) the context and the construction. The interpreter builds interpretations on-line. Marslen-Wilson et al. (1988). Potter & Faulconer (1979). Marslen- Wilson (1975) The processor uses lexical valence and control knowledge in inte- gration, including semantic and thematic knowledge. Shapiro et al. (1987), Clifton et al. (1984), Boland et al. (1990), Tanenhaus et al. (1989) The processor experiences difficulty when encountering “filled gaps” in non-subject position, but not in subject position. Crain & Fodor (1985), Tanenhaus et al. (1985), Stowe (1986), Garnsey et al. (1989), Kurtzman et al. (1991) The processor integrates distant fillers directly into the predicate, rather than mediated by an empty category. Pickering & Barry (1991), Boland & Tanenhaus (1991) The processor prefers filling arguments to adjuncts Ford et al. (1982) The processor prefer to fill expected constituents Crain & Steedman (1985) Lexical, syntactic, and semantic knowledge are all used in comput- Taraban & McClelland (1988), Stowe (1989), Trueswell & Tanen- ing preferences haus (1991), Zwitserlood (1989) Figure 4: Sal Models Psycholinguistic Data tion. The working store holds constructions in parallel as they are accessed, and partial interpretations in parallel as they are being built up. The long-term store holds the lin- guistic knowledge of the interpreter (i.e., the grammar). The interpretation function includes functions of access, inter- pretation, and selection. The first of Sal’s sub-functions is the access function. Access Function: Access a construction whenever the evidence for it passes the access threshold cy. The access function amasses evidence for constructions that might be used in an interpretation by assigning values to each piece of evidence, including syntactic, semantic, and frequency evidence, amassed from both bottom-up and top- down sources. When the evidence for a construction (i.e., the number of access points) has passed the access thresh- old a, the interpreter copies the construction into the access buffer, which is part of the working store; this point in time is the access point. The access buffer can hold more than one construction in parallel - Figure 4 summarizes evi- dence for parallelism, variable access-point, and sensitivity to frequency in access. This access threshold is a constant value; the access point, however, will vary across different constructions and contexts. This evidential access mecha- nism is a more general and knowledge-based approach to the access of linguistic knowledge than previous models, which have generally relied on a single kind of information to access rules. This might be bottom-up information, as in shift-reduce parsers, or top-down information, as in many Prolog parsers, solely syntactic information, as in the above as well as left-corner parsers, or solely semantic or Zexi- cal information, as in conceptual analyzers like Riesbeck & Schank (1978). The access algorithm presented here can use any of these kinds of information, as well as frequency information, to suggest grammatical constructions; for ex- ample top-down knowledge of a verb’s semantic argument structure may suggest possible verb-phrase constructions to access, while bottom-up semantic information about a word’s meaning may suggest the access of constructions 304 Natural Language: Interpretation which might begin with words of that semantic class. Integration Function: An interpretation is built up for each construction, as each of its constituents are pro- cessed, by integrating the partial information provided by each constituent. The integrationfunction incrementally combines the mean- ing of a construction and its various constituents into an interpretation for the construction. The operation used to combine structures is also called integration, designed as an extension of the unification operation. While unification has been used very successfully in building syntactic structure, extending the operation to building more complex semantic structures requires three major augmentations (see Jurafsky (199 1) for some traces and 1992 for further details): @ The integration operation is defined over the frame-like representation language which is used to describe con- structions. This allows the interpreter to use the same semantic language to specify constructions as it uses to build final interpretations, without requiring translation from feature structures to semantics. The integration operation can also use information about the representa- tion language to decide if structures should integrate; for example if the representation language specifies that con- struction A abstracts over construction B, the operation will integrate them successfully. o The integration operation distinguishes constraints on constituents or on valence arguments fromfiZZers of con- stituents or valence arguments o The integration operation is augmented by a slash oper- ator, which allows it to join semantic structures by em- bedding one inside another. This is accomplished by finding a semantic gap inside one structure (the matrix), and binding this gap to the other structure (theJiZZer). This operation is similar to the functional-application opera- tion and the lambda-calculus used by other models of semantic interpretation such as Moore (1989). The selection function chooses an interpretation from the set of candidate interpretations in the interpretation store. The function chooses the interpretation which is the msst coherent with grammatical expectations: Selection Choice Principle: Prefer the interpretation whose most recently integrated element wm tie most coherent with the interpretation and its lexica.& syntac- tic, semantic, and probabilistic expectations. Sal emphasizes the use of local coherence, that is, coher- ence with grammaticalized expectations such as valence, constituent, or frequency expectations. Interpretations are ranked according to the coherence ranking below: anking (in order of preference): (3) Integrations which fill a very strong expectation such as one for an exact construction, or for a construction which is extremely frequent. (I) Integrations which fill a strong expectation such as a valence expectation or a constituent expectation. (I) Integrations which fill a weak expectation, SW& as for an optional adjunct or include feature matching rather than feature imposing. (I) Integrations which fill no expectations, but which are still successfully integrated into the interpretation. Psycholinguistic evidence for preferring more coherent in- terpretations is summarized in Figure 4; that grammatical expectations are useful in interpretation is not surprising. More surprising perhaps is that these grammatical expec- tations can override globally more plausible interpretations (Norvig 1988). In the following well-known garden-path examples the reader initially arrives at an interpretation which is semantically anomalous due to grammatical ex- pectations: e The landlord painted all the walls with cracks. e The horse raced past the barn fell. o The complex houses married and single students. e The grappling hooks on to the enemy ship. Although the current implementation of Sal’s grammar is not large enough to parse these sentence, the selection al- gorithm does account for each of them. In each case, they occur because the more plausible interpretation is pruned too early, because some alternative interpretation was more coherent. In the first sentence, the verb ‘paint’ has a valence expectation for an instrument, in the second the main verb sense of ‘raced’ is better integrated than the reduced rela- tive, in the third the nominal sense of ‘houses’ is 10 times as frequent as the verbal sense, and in the last the construction ‘grappling hooks’ has a constituent expectation for the word ‘hooks’. Sal’s Selection Timing Principle is an extension of Gib- son’s (199 1) pruning algorithm: Selection Timing Principle: Prune interpretations whenever the difference between their ranking and the ranking of the most-favored interpretation is greater than the selection threshold cr. Interpretations are ranked according to the number of points they are assigned by the coherence ranking above, and an interpretation is pruned whenever it becomes much worse st-favored interpretati the interpretation reshold, 0, at which in tations are pruned, The fact that Sal prunes less-favored interpretations on- line proves useful in solving some well-known complexity problems for parsing. Many researchers have noted that the problem of computing syntactic structure for a sentence can be quite complex. Church & Patil(l982) showed, for example, that the number of ambiguous phrase-structure trees for a sentence with multiple preposition-phrases was proportional to the Catalan numbers, while Barton et al. (1987) showed that the parsing problem for a grammar with agreement and lexical ambiguity is NP-complete. It might seem that the problems of computing interpretations would be even more complex, as the interpreter must produce a semantic structure as well as a syntactic one.’ However, it is the need to represent ambiguities for in- definite lengths of time in parsing that causes complexity. Sal builds interpretations on-line, and hence ambiguities are resolved quickly, either because o tic constraints or by the Selection prunes less-favored interpretations on-line. Thus placing cognitive constraints on Sal actually simplifies the process- ing enough to avoid complexity problems.2 elate esearc While there have been many models of natural language in- terpretation, most have been limited their scope to a single paradigm. For example many processing models which are associated with linguistic theories, such as Ford et al. (1982) (LFG), lvIarcus (1980) (EST), or Fong (1991) (GB), are solely parsing models, including no semantic knowledge. Alternatively, some models such as Riesbeck & Schank (1978), DeJong (1982) and others of the Yale school, em- phasize semantic knowledge but exclude syntactic knowl- edge. Some models, such as Lytinen (1986), which do include both syntactic and semantic knowledge, don’t ad- dress psychological criteria. Models from the psycholin- guistic community often address only small domains like lexical access. There are some models of interpretation which attempt to address all three paradigms. Hirst’s (1986) model included a Marcus-like parser, a lexical disambiguation system consis- tent with psychological results, a semantic interpreter, and a mechanism for resolving structural ambiguities. Hirst’s model influenced the design of Sal; Sal differs in consist- “The most common way of reducing complexity, the use of dynamic programming techniques (e.g., well-formed substring ta- ble of Kuno (1965). the chart pursing algorithm of Kay (1973), and the Eartey algorithm of Earley (1970)), may not generalize from parsing to interpretation, since the internal structure of a given substructure may be needed by the interpreter, and may involve binding variables differently in the context of different interpretations. 21n fact, augmenting Sal by the simple assumption that the in- terpreter’s working store is limited in the number of total structures it can maintain, as suggested by Gibson (1991). would ensure that the total amount of ambiguity the interpreter can maintain will calwcrys be limited by a small constant. Jurafsky 305 ing of a single unified mechanism rather than four separate modules, and emphasizing the use of semantic knowledge directly in the CIG grammar, thus accounting for long- distance dependencies and other phenomena in semantic rather than syntactic ways. Cardie Jz Lehnert’s (1991) interpreter resembles Sal in attempting to model psychological results, particularly in the use of semantic constraints to process wh-clauses. Their system differs from Sal in its focus, emphasizing robustness rather than linguistic criteria. For example, the interpreter doesn’t represent larger grammatical constructions, only in- cluding local intraclausal linguistic information. Also, be- cause their model only allows linguistic structures to be accessed bottom-up by lexical input, it is unable to account for psycholinguistic results on access in Figure 4. Implementation Comments Sal has been implemented in Common Lisp with a small CIG test grammar of about 50 constructions. This section presents a trace of the interpretation of the sentence “How can I create disk space?“. In the first part of the trace the input word “how” sup- plies sufficient evidence for two constructions, MEANS- How and HOW-SCALE to be accessed. These constructions then supply evidence for the WH-NON-SUBJECT-QUESTION construction, and these are integrated together. At the end of this stage, the interpretation store contains two WH-NON- SUBJECT-QUESTION interpretations, one with the MEANS- HOW construction and one with the HOW-SCALE construc- tion. In this second part of the trace, the input “can” provides evidence for the three lexical constructions CAN-~, CAN-~, and CAN-~, as well as some larger constructions. After integration, the interpretation store contains a large num- ber of possible interpretations, most of which are ruled out because they failed to integrate successfully, leaving only one. This successful interpretation includes the MEANS- HOW construction and the auxiliary sense of “can”. Next the word 7” is input and integrated into the in- terpretation. Note that although there is some top-down evidence for the verb-phrase construction (because the WH-NON-SUBJECT-QUESTION construction expects a verb- phrase next), it is not accessed, because it is an abstract weak construction, and there is insufficient evidence for any of the more concrete strong verb-phrase constructions. Next the word “create” is input and integrated into the interpreta- tion, along with an appropriate type of verb-phrase. Again, the top-down evidence for the abstract NOUN-PHRASE con- struction is insufficient to access it. Next the word “disk” is input, which provides evidence for the lexical construc- tion DISK, as well as the noun-compound DISK-SPACE, and the DOUBLENOUN construction, which handles compound nouns. Finally, the word “space” accesses the lexical construc- tion SPACE. The selection algorithm must now choose be- tween two interpretations, one with the DISK-SPACE con- struction, and one with the DOUBLENOUN construction in which the nouns are respectively “disk” and “space”. Be- <cl> (parse ' (how can i create disk space)) *** ACCESS *** Input word: how Bottom-up Evidence for constructions (means-how howscale) Constructions (means-how howscale) are accessed Bottom-up Access of (whnonsubjectquestion), integrated directly into Access Buffer Top-down Evidence for constructions (aux) Access of constructions nil *** INTEGRATION *** After integration, Store contains: ((whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion)) *** SELECTION *** After removing failed integrations Store contains (whnonsubjectquestion whnonsubjectquestion) *** ACCESS *** Input word: can Bottom-up Evidence for constructions (can-l can-2 can-3 doublenoun bare-mono-trans-vp) Top-down Evidence for constructions nil Access of constructions nil *** INTEGRATION *** After integration, Store contains: ((whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion)) *** SELECTION *** After removing failed integrations Store contains (whnonsubjectquestion) *** ACCESS *** Input word: i Bottom-up Evidence for constructions (i) Top-down Evidence for constructions (verb-phrase) Access of constructions nil *** INTEGRATION *** After integration, Store contains: ((whnonsubjectquestion whnonsubjectquestion)) *** SELECTION *** After removing failed integrations Store contains (whnonsubjectquestion) *** ACCESS *** Input word: create Bottom-up Evidence for constructions (create bare-mono-trans-vp) Top-down Evidence for constructions (noun-phrase) Access of constructions nil *** INTEGRATION *** After integration, Store contains: ((whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion)) *** SELECTION *** After removing failed integrations Store contains (whnonsubjectquestion) 306 Natural Language: Interpretation cause the DISK-SPACE construction has a strong expectation for the word “space”, this first interpretation is selected. *** ACCESS *** Input word: disk Bottom-up Evidence for constructions (disk diskspace doublenoun) Top-down Evidence for constructions (noun) Access of constructions nil struction, obviates the need for a separate lexical analyzer, parser, and semantic interpreter, and allows access, integra- tion, and selection to be sensitive to a rich framework of linguistic evidence. Second, by filling the roles of a parser, a semantic interpreter, a linguistic model, and a cognitive model, Sal can use linguistic functionality such as capturing generalizations to aid construction access, and cognitive re- quirements such as modeling human memory limitations to reduce processing complexity. *** INTEGRATION *** After integration, Store contains: ((whnonsubjectquestion whnonsubjectquest ion whnonsubjectquestion whnonsubjectquesti on) 1 eferences BACH, EMMON. 1976. An extension of classical transformational grammar. In Problems of Linguistic Metatheory (Proceedings of the 1976 Conference). Michigan State University. BARTON, JR, 6. EDWARD, ROBERT C. BERWICK, & ERIC SVEN RIsTm. 1987. Computational complexity and natural language. Cambridge, MA: MIT Press. *** SELECTION *** After removing failed integrations Store contains (whnonsubjectquestion whnonsubjectquestion) *** ACCESS *** Input word: space Bottom-up Evidence for constructions (space doublenoun) Top-down Evidence for constructions nil Access of constructions nil *** INTEGRATION *** After integration, Store contains: ((whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion whnonsubjectquestion)) *** SELECTION *** After removing failed integrations Store contains (whnonsubjectquestion whnonsubjectquestion) Pruning construction 'whnonsubjectquestion' (1 points), because difference from construction 'whnonsubjectquestion' (3 points) exceeds selection threshold Input Exhausted. Result is: (a question $q (queried $p*) (background (a means-for Snewvar285 (means Sp*) (goal (a ability-state Sas (actor (a speechsituation-speaker)) (action (a forcedynamicaction Snewvar291 (action (a creation-action (created (a disk-freespace)) (creator (a speechsitn-speaker Summary Sal and CIG arose from an attempt to build a model which jointly incorporated the insights of artificial intelligence and natural language processing systems, of psycholinguistic models of processing, and of linguistic models of gram- matical representation. The interdisciplinary nature of the work results in a number of advantages. First, combining syntactic, semantic, lexical and idiomatic knowledge in a single linguistic knowledge structure, the grammatical con- BOLAND, JULIE E. & MICHAEL K. TANENHA US. 1991. The role of lexical representations in sentence processing. In Understanding word and sentence, ed. by G. B. Simpson, 33 l-366. Elsevier. BOLAND, JULIE E., MICHAEL K. TANENHA us, t!k SUSAN M. GAIX- NSEY. 1990. Evidence for the immediate use of verb control information in sentence processing. Journal of Memory and Language, 29~413-432. BRESNAN, JOAN (ed.). 1982. The mental representation ofgram- matical relations. Cambridge, MA: MIT Press. CACCWRI, CRISTINA & PATRIZA TABOSSI. 1988. The comprehen- sion of idioms. Journal of Memory and Language, 27:668-683. CARDIE, CLAIRE 8c WENDY LEHNERT. 1991. A cognitively plau- sible approach to understanding complex syntax. In Proceedings of the Ninth AAAI, 117-124. Morgan Kaufmann. CHURCH, KENNETH & &WESH PATIL. 1982. Coping with syntactic ambiguity. American Journal of Computational Linguistics, 8(3- 4): 139-149. ON, JR, CHARLES, LYN FIuzlER, & CyruHIA co-. 1984. Lexical expectations in sentence comprehension. Jour- nal of Verbal Learning and Verbal Behavior, 23~696-708. GRAIN, STEPHEN & JANET DEAN FODOR. 1985. How can gram- mars help parsers? In Natural languageparsing, ed. by David R. Dowty, Lauri Kartunnen, & Arnold Zwicky, 94-128. Cambridge: Cambridge University Press. GRAIN, STEPHEN & MA.RK STEEDMAN. 1985. On not being led up the garden path: the use of context by the psychological syntax processor. In Natural language parsing, ed. by David R. Dowty, Lauri Kartunnen, & Arnold Zwicky, 320-358. Cambridge: Cam- bridge University Press. DEJONG, GERALD. 1982. An overview of the FRUMP system. In Strategies for natural language processing, ed. by Wendy G. Lehnert & Martin H. Ringle, 149-176. NJ: Lawrence Erlbaum. EARLEY, JAY. 1970. An efficient context-free parsing algorithm. Communications of the ACM, 6(8):45 1-455. ELLEG&, ALVAR. 1978. The syntactic structure of English texts: A computer-based study offour kinds of text in the Brown University Corpus. Number 43 in Gothenburg Studies in English. Goteborg: Acta Universitatis Gothoburgensis. FLLLMORE, CHARLES J., PAUL KAY, & M. C. O’CONNOR. 1988. Regularity and idiomatic@ in grammatical constructions: The case of let alone. Language, 64(3):501-538. FONG, SANDIWAY. 1991. The computational implementation of principle-based parsers. In Principle-based parsing, ed. by Jurafsky 307 Robert C. Berwick, Steven P. Abney, & Carol Tenny, 65-82. Dordrecht: Kluwer. FORD, MARILYN, JOAN BRESNAN, & RONALD M. KAPLAN. 1982. A competence-based theory of syntactic closure. In The mental representation of grammatical relations, ed. by Joan Bresnan. Cambridge, MA: MIT Press. FRANCIS, W. NELSON & HENRY K&ERA. 1982. Frequency anal- ysis of English usage. Boston: Houghton Mifflin. GARNSEY, SUSAN M., MICHAJX K. TANENHA us, & ROBERT M. CHAPMAN. 1989. Evoked potentials and the study of sentence comprehension. Journal of Psycholinguistic Research, 18( 1):5 l- 60. GIBSON, EDWARD, 1991. A computational theory ofhuman linguis- tic processing: Memory limitations and processing breakdown. Pittsburgh, PA: Carnegie Mellon University dissertation. GORRELL, PAUL G., 1987. Studies of human syntacticprocessing: Ranked-parallel versus serial models. Connecticut: University of Connecticut dissertation. GORRELL, PAUL G. 1989. Establishing the loci of serial and par- allel effects in syntactic processing. Journal of Psycholinguistic Research, 18(1):61-73. HIRST, GRAEME. 1986. Semantic interpretation and the resolution of ambiguity. Cambridge: Cambridge University Press. JURAFSKY, DANIEL. 1990. Representing and integrating linguistic knowledge. In Proceedings of 13th Coling, 199-204, Helsinki. J-SKY, DANIEL. 1991. An on-line model of human sentence interpretation. In Proceedings of the 13th Annual Conference of the Cognitive Science Society, 449-454, Chicago. JURAFSKY, DANIEL, 1992. An on-line computational model of hu- man sentence interpretation: A theory of the representation and use of linguistic knowledge. Berkeley, CA: University of Cali- fornia dissertation. Computer Science Division Report #92/676. KAY, MARTIN. 1973. The MIND system. In Natural language processing, ed. by Randall Rustin, 155-188. New York: Algo- rithmics Press. KAY, PAUL. 1990. Even. Linguistics and Philosophy, 13:59-216. KUNO, SUSUMU. 1965. The predictive analyzer and a path elimi- nation technique. Communications of the ACM, 8(7):453-462. KIJR‘IZMAN, HOWARD S., 1985. Studies in syntactic ambiguity resolution. Cambridge, MA: MIT dissertation. KURTZMAN, HOWARD S., L~REN F. CRAWFORD, & CAYLEE NYCHIS-FLORENCE. 1991. Locating wh- traces. In Principle- based parsing, ed. by Robert C. Berwick, Steven P. Abney, & Carol Tenny, 347-382. Dordrecht: Kluwer. LAKOF~F, GEORGE. 1987. Women, Jire, and dangerous things. Chicago: University of Chicago Press. LYTINEN, STEVEN L. 1986. Dynamically combining syntax and semantics in natural language processing. In Proceedings of the Fi;frh AAAI, volume 1,574-578. Morgan Kaufmann. MARCUS, MITCHELL P. 1980. A theory of syntactic for natural language. Cambridge, MA: MIT Press. recognition MARSLEN-WILSON, WILLIAM. 1975. Sentence perception as an interactive parallel process. Science, 189:226-228. MARSLEN-WILSON, WILLIAM, COLIN M. BROWN, & LOR- RAINE KOMISARJEVSKY TYLER. 1988. Lexical representations in spoken language comprehension. Language and Cognitive Processes, 3(1):1-16. MOORE, ROBERT C. 1989. Unification-based semantic interpre- tation. In Proceedings of the 27th Annual Conference of the Association for Computational Linguistics, 33-41, Vancouver, Canada. NORVIG, PETER. 1988. Interpretation under ambiguity. In Pro- ceedings of the I4th Annual Meeting of the Berkeley Linguistics Society, 188-201, Berkeley, CA. ~CKERING, MARTIN & GUY BARRY. 1991. Sentence processing without empty categories. Language and Cognitive Processes, 6(3):229-259. POLLARD, CARL & IVAN A. SAG. 1987. Information-based syntax and semantics: Volume 1: Fundamentals. Chicago: University of Chicago Press. POITER, MARY C. Br BARBARA A. FAULCONER. 1979. Under- standing noun phrases. Journal of Verbal Learning and Verbal Behavior, 18:509-521. -BECK, CHRISTOPHER K. & ROGER C. SCHANK. 1978. Compre- hension by computer: Expectation-based analysis of sentences in context. Pn Studies in the perception of language, ed. by W. J. M. Levelt & G. B. Flores d’Arcais, 247-293. London: Wiley. SHAPIRO, L. P., E. ZURIF, & J. GIUMSHAW. 1987. Sentence processing and the mental representation of verbs. Cognition, 27:219-246. SIMPSON, GREG B. & CURT BIJRGE~S. 1985. Activation and selec- tion processes in the recognition of ambiguous words. Journal of Experimental Psychology: Human Perception and Performance, 11(1):28-39. STOWE?., LAURIE A. 1986. Evidence for on-line gap location. Language and Cognitive Processes, 1(3):227-245. STOWE, LAURIE A. 1989. Thematic structures and sentence com- prehension. In Linguistic structure in languageprocessing, ed. by G. N. Carlson & M. K. Tanenhaus, 3 19-357. Dordrecht: Kluwer. SWINNEY, DAVID A. 1979. Lexical accessduring sentencecompre- hension: (re)consideration of context effects. Journal of Verbal Learning and Verbal Behavior, 18~645-659. SWLNNEY, DAVY, A. & ANNE CUTLER. 1979. The access and processing of idiomatic expressions. Journal of Verbal Learning and Verbal Behavior, 18~523-534. TANENHAUS, MICHA~, K., JULIE E. BOLAND, SUSAN M. GARNSEY, & GREG CARLSON. 1989. Lexical structures in parsing long- distance dependencies. Journal of Psycholinguistic Research, 18( 1):37-50. TANENHAUS, MICHAEL K., JAMES M. LEIMAN, & MARK S. SF% DENFSERG. 1979. Evidence for multiple stages in the processing of ambiguous words in syntactic contexts. Journal of Verbal Learning and Verbal Behavior, 18~427-440. TANENHAUS, MICHAEL K., LAURIE A. STOWE, Bc GREG CARLSON. 1985. The interaction of lexical expectation and pragmatics in parsing filler-gap constructions. In Program of the 7th Annual Conference of the Cognitive Science Society, 361-365, Irvine. TARABAN, ROMAN h JAMES L. McC LELLAND. 1988. Constituent attachment and thematic role assignment in sentence processing: Influences of content-based expectations. Journal of Memory and Language, 27~597-632. TRUESWELL, JOHN C. & MICHAEL K. TANENHAUS. 1991. Tense, temporal context and syntactic ambiguity resolution. Language and Cognitive Processes, 6(4):303-338. TYLER, LORRAINE K. 1984. The structure of the initial cohort: Evidence from gating. Perception & Psychophysics, 36(5):417- 427. USZICOR~T, HANS. 1986. Categorial unification grammars. In Proceedings of 11 th Coling, Bonn. University of Bonn. ZW~TSJZRL~OD, PIENIE. 1989. Thelocus of the effects of sentential- semantic context in spoken-word processing. Cognition, 32:25- 64. 308 Natural Language: Interpretation | 1992 | 58 |
1,252 | Literal Meaning and re Steven L. Lytinen and Robert R. Burridge and Jeffrey D. Kirtner Artificial Intelligence Laboratory The University of Michigan Ann Arbor, MI 48109 Abstract Based on psychological studies which show that metaphors and other nonliteral constructions are comprehended in the same amount of time as comparable literal constructions, some researchers have concluded that literal meaning is not com- puted during metaphor comprehension. In this paper, we suggest that the empirical evidence does not rule out the possibility that literal meaning is constructed. We present a computational model of metaphor comprehension which is consistent with the data, but in which literal meaning is com- puted. This model has been implemented as part of a unification-based natural language processing system, called LINK. Introduction How are metaphors and other nonliteral constructions understood? A point of contention with regard to this question has been whether or not it is necessary to compute the literal meaning of a metaphorical utter- ence en route to understanding its intended (nonliteral) meaning. A large body of research in psycholinguistics has revealed that, in appropriate contexts, metaphors and other nonliteral constructions are comprehended no slower than comparable literal constructions, and sometimes even faster. This evidence, along with other related studies, has led some researchers to conclude that computation of literal meaning is not a necessary step in the understanding of metaphors. In this paper, we suggest that the existing psycho- logical data does not provide the necessary evidence to determine whether or not literal meaning is computed during the comprehension of metaphors and other non- literal expressions. Moreover, from a computational standpoint, there are reasons to prefer an approach in which literal meaning is always computed. This moti- vates our own model of metaphor processing, in which literal meaning is computed. We present our approach, and show that our model is consistent with the existing psychological data. An important feature of our model is that the non- literal interpretation of a potentially metaphorical ex- pression is &omaiicalZy computed from the expres- sion’s literal meaning, irregardless of the context in which it appears. We argue that the existing data can- not distinguish between this processing model and one in which literal meaning is not computed. Our approach to processing metaphors has been im- plemented in a natural language processing (NLP) sys- tem called LINK. LINK is an integrated, unification- based system, in which syntactic, semantic, and do- main knowledge are all implemented in unification con- straint rules. In order to process metaphors, we have added a set of mapping rules, which construct alterna- tive (metaphorical) interpretations from literal mean- ings constructed during parsing. Context then deter- mines which of the literal or metaphorical interpreta- tions of the expression is most appropriate. This paper is organized as follows: first, we present an argument for why, from a computational stand- point, there is a reason for computing the literal meaning of a metaphor and for the use of mapping rules. Next, we examine previous computational mod- els which have proposed the use of mapping rules, and the psychological evidence which seems to refute these theories. Finally, we present our model, and show why it is consistent with the psychological data. The need for mapping rules Can the meanings of metaphorical expressions be com- puted directty, or is it necessary to compute their literal meaning first? Consider the following example: The stock market rose today. What would it mean to understand this metaphor directly? Assuming the traditional compositional ap- proach to semantic interpretation, it would mean that the intended meaning of the sentence must be con- structed from the meanings of its pieces (either lexical items or phrases). However, if we combine the literal meanings of “stock market” and “rose,” we obviously will not arrive at the correct interpretation of this sen- tence. We could define one or both of these terms as Lytinen, Burridge, and Kirtner 309 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. ambiguous, with “literal” and “metaphorical” senses, but it is not clear that we can easily separate the mean- ing of the metaphor into components to be associated with individual lexical items or phrases, as the compo- sitional approach requires. For example, “rose” could be defined ambiguously, as either referring to an in- crease in altitude or an increase in a numeric indica- tor, but this does not capture the generalization that almost any word which refers to a change in altitude can be used in the same way. Consider the following examples: The stock market plummeted today. My fever has gone up. Computer science enrollments are leveling off. The 10% jump in property taxes this year was outra- geous. If we defined “rose” as ambiguous, we would also have to define every other word which refers to a change in altitude as ambiguous, in order to account for the productivity of this metaphor, not a plausible soluti0n.l Metaphors such as the above example, which are tied to general concepts rather than specific lexical items, are not uncommon. We will not attempt to argue this point here, as many others have presented convinc- ing arguments as to the prevalence of highly produc- tive metaphors and other nonliteral constructions (e.g., Lakoff and Johnson, 1980; Langacker, 1987). Given their prevalence, it is important that we properly ac- count for them, with a mechanism which explains their productivity. How can we write appropriately general interpreta- tion rules for these kinds of metaphors? Since they are often syntactically and lexically flexible, it seems that the only way to do so is at the semantic level. Instances of a given metaphor share commonalities in “literal” meaning (e.g., all lexical items that can be used in the “rose” metaphor normally refer to a change in alti- tude) and also in “intended” meaning (e.g., when used metaphorically, words like “rose” refer to a change in value of a numerical indicator). Thus, it seems natu- ral to write an interpretation rule that transforms the literal meaning of a construction to an alternate non- literal one. We will refer to this kind of rule as a mapping rule. In the case of the “rose” metaphor, the mapping is from a change in altitude to a change in value of a numerical indicator. The direction of the change in value is “the same” as the direction of the change in altitude: that is, increase in altitude means increase in the numerical indicator. ’ Presumably, words that are commonly used in a par- ticular metaphor (such as “rose”) do develop their own “metaphorical” senses, thereby enabling direct comprehen- sion of these alternate senses. However, given the produc- tivity of many metaphors, it seems implausible that distinct senses would develop for all lexical items that can be used in a metaphor. How can mapping rules be used in semantic inter- pretation? Comprehension of a nonliteral construction using a mapping rule would involve constructing the literal interpretation of the construction, identifying the appropriate mapping rule, and applying the rule to the literal interpretation, thereby yielding the in- tended (nonliteral) interpretation. The Standard ragmatie Model Many previous theories of metaphor comprehension have proposed the use of mapping rules to account for metaphor comprehension (e.g., Induryka, 1987; Car- bonell, 1982; Searle, 1978). In fact, this approach has been called the Standard Pragmatic Model (Gerrig, 1989). Gerrig outlined three general steps in the Stan- dard Model: 1. Construct the literal meaning of the utterance 2. Identify a failed literal meaning semantic or pragmatic constraint in the 3. APPLY a mapping rule to to the intended meaning. transform the literal meaning This model makes two predictions about process- ing. First, since steps 2 and 3 must be performed after completion of step 1, it predicts that comprehension of metaphors is slower than comprehension of comparable literal utterances. Second, since step 3 above is only executed if “normal” semantic and pragmatic process- ing fails to interpret an utterance, it predicts that the metaphorical interpretation of an utterance is not com- puted in a context in which the literal interpretation is acceptable. Numerous psychological studies contradict both of these predictions. First, many studies have shown that, in an appropriate context, metaphor comprehen- sion is as fast as comprehension of comparable literal expressions. In (Ortony et al., 1978) subjects read one or more sentences which set up a context, then read the target sentence, and then indicated as quickly as possible that they understood the target by pressing a key. There were two variations on this basic design. In experiment 1, the context was either short or long. In the short context, subjects took longer to understand nonliteral than literal targets, but in long contexts the reading times were not significantly different. In ex- periment 2, the targets were phrases that could have either a literal or idiomatic interpretation, depending on context. It was found that targets with an idiomatic interpretation took no longer to process (and may be processed faster) than the literal interpretations of the same targets. Gibbs (1979) reported similar contextual effects on the comprehension of indirect requests. Subjects read stories, one line at a time, which ended in either an indirect request (e.g., “Must you open the window?“) or a direct request (e.g., “Please open the window”). In an appropriate context (i.e., a story in which the context set up the expectation for a request), indirect 310 Natural Language: Interpretation requests took no longer to comprehend than the direct requests. More recent experiments have on the whole con- firmed that metphors take no longer to process than literal statements in appropriate contexts. See Gerrig (1989) or Gibbs (1984) f or a more extensive discussion of the evidence. Gibbs has also examined the question of whether or not literal meanings of indirect requests are ac- tivated during comprehension. In (Gibbs, 1983), he found no evidence for activation of literal meaning if an indirect request was comprehended in an appro- priate context. Immediately after reading an indirect request such as “Can you pass the salt?” subjects were asked to make sentence/nonsentence judgments on tar- get sentences. When the target was a paraphrase of the literal meaning of the indirect request (e.g., a tar- get about ability to pass the salt), there was no fa- cilitation of this judgment task from the indirect re- quest preceding it. However, in the reverse situation, facilitation did occur: subjects were faster at making sentence/nonsentence judgments on paraphrases of the indirect request meaning even if the request was meant literally. Gibbs concluded from this assymetry of prim- ing that literal meaning of indirect requests was not computed, but that the nonliteral meaning always was. Clucksberg, Gildea, & Bookin (1982) addressed the question of when literal and nonliteral meanings or metaphors are computed. Subjects were asked to make judgments about the literal truth of sentences of the form “All/Some X are Y.” Subjects took significantly longer to judge the truth of sentences which had a rea- sonable metaphorical meaning than those which did not. That is, judgment about the literal truth of sen- tences such as “All men are wolves” was slower than for “All men are telephones.” Since the task only re- quired subjects to make judgements based on literal meaning, the results suggest that metaphor compre- hension is an automatic process; i.e., metaphorical in- terpretations are computed even when literal meaning is intended. The evidence against the Standard Model has led some to conclude that literal meaning is not computed during comprehension of nonliteral constructions. Per- haps the strongest proponent of this view is Gibbs, who goes so far as to question the validity of the no- tion of literal meaning (Gibbs, 1984). However, as we will argue in the next section, it is not the construc- tion of literal meaning and the use of mapping rules that causes the Standard Model to make these incor- rect predictions, it is the way in which mapping rules are applied in the model. Metaphor Processing in LINK We now present our alternative theory of metaphor processing, which is implemented in the LINK sys- tem. While our model also utilizes mapping rules, it differs from the Standard Pragmatic Model in that the rules are applied automatically, rather than in a failure-driven manner. As we will see later, automatic application of mapping rules leads to correct predic- tions about reading times and activations. In LINK, metaphor processing follows these general steps: Incrementally construct the (literal) interpretation of constituents of the utterance. As they are constructed, try to match the interpretations against mapping rules. If any rules match, also contruct the result of the mapping (the metaphorical interpreta- tion) as an alternative interpretation of the constituent. Use contextual information to determine which of the candidate interpretations is (are) preferred. This model is a refinement of Martin’s (1990) the- ory of metaphor processing.2 tin’s approach in three ways: first, the construction of metaphorical interpretations in LINK is an incremental process, which proceeds during the comprehension of a sentence. In Martin’s system, all metaphorical inter- pretations were constructed after completion of pars- ing. Second, mapping rules in LINK are used to pro- cess other nonliteral constructions, such as metonymies and figures of speech. Finally, because metaphor pro- cessing is integrated with parsing, LINK’s mapping rules can contain a mixture of syntactic and seman- tic information. This is important in the process- ing of other types of nonliteral constructions, such as metonymies and figures of speech. Before we can explain the details of LINK’s mapping rules, we must give a general overview of LINK. LINK’s unification grammar All syntactic, semantic, and pragmatic knowledge is encoded in LINK in unification constraint rules. These rules are very similar in form to other unification gram- mars, such as PATR-II (Shieber, 1986). Each con- straint rule consists of a set of equations, each of which constrains the interpretation which the parser can build in some way, by limiting, for a class of nodes (i.e., any node with a particular label), the set of arcs that can lead from a node of that cl a&, as well as the types of nodes that arcs can lead to. Here are two sim- plified examples of constraint rules: s: [;I = ;; (hea;) = (2 head) PI PI PI (head subj) = (1 head) Bl V: (1) = ate C51 (head rep) = EAT-FOOD PI (head subj rep) = (head rep actor) PI (head dobj rep) = (head rep object) [8] % Martin’s theory, the initial representation con- structed was called the “primal representation” of the ut- terance. We view this as equivalent to literal meaning, although it is not clear that Martin would agree. Lytinen, Burridge, and Kirtner 311 Each equation in the first rule (eqs. l-4) specifies a property which any node labeled S must have. Equa- tions constrain properties that nodes may have by specifying the label of the node to be found at the end of a path, or sequence of arcs (equations l-2); or by specifying that two paths must lead to the identical node (equations 3-4). Identity here is defined by the unijication operation. Unification merges the proper- ties of two nodes; thus, two paths can unify if their values have no properties which explicitly contradict each other. Functionally, the above rule encodes information about English sentences as follows. Equations 1 and 2 specify that a sentence is made up of two subcon- stituents: NP and VP, in that order. Equation 3 as- signs the HEAD of the sentence to be the same as the HEAD of the VP, by unifying the VP’s HEAD path with the HEAD path of the S. Finally, equation 4 as- signs the NP to be the subject of the sentence. The HEAD property is used to bundle information together, so that it can be shared across rules. Because of equation 3, any information on the HEAD of the VP is accessible from the S node. Similar equations would assign the head of the verb (V) to be the HEAD of the VP, and a particular lexical item to be the HEAD of the V. The second rule (eqs. 5-8) is an example of a lexical entry. These rules typically provide the values which are propagated by HEAD links. Equation 6 specifies the semantic representation of the word “ate.” By con- vention, the semantic representation of a constituent appears as the value of the (head rep) path . Equations 7-8 specify mappings from syntactic to semantic depen- dencies. Whatever constituent fills the SUBJ role in the sentence will also be assigned as the ACTOR of the EAT-FOOD, and the syntactic direct object (DOBJ) will be assigned as the semantic OBJECT. Thus, in conjunction with equation 4, the sentence “John ate the apple” is interpreted to mean that “John” is the ACTOR of the action EAT-FOOD. Equations 7 and 8 are used in conjunction with the system’s domain knowledge, to impose restrictions on the semantic properties (i.e., the values of the REP path) of the subject and direct object of “ate” (i.e., the ACTOR and OBJECT of EAT-FOOD). Domain knowledge is also encoded in constraint rules. In this particul& case, the relevant rule is the following: EAT-FOOD: (actor) = HUMAN PI (object) = FOOD PI (instrument) = UTENSIL [ll] Because of the mapping provided by “ate” between its subject and the ACTOR of EAT-FOOD, the restric- tion that this constituent’s representation must be HU- MAN is propagated up to the NP which fills the SUBJ role specified by equation 5. Similarly, the FOOD re- striction on the object of an EAT-FOOD would prop- agate to the NP assigned as the direct object (DOBJ) of “ate”, because of equations 11 and 13. Semantic or domain knowledge is often used to elim- inate inappropriate interpretations of ambiguous lexi- cal items or constructions. For example, in the sen- tence “John ate the chips,” the POKER-CHIP sense of “chips” would be eliminated, since it is not a type of FOOD. This mechanism for eliminating contextu- ally inappropriate interpretations is important in the selection of literal or metaphorical interpretations of potentially metaphorical expressions. LINK’s mapping rules The definition of a mapping rule in LINK is shown be- low. A <label> is any syntactic or semantic category used in the grammar. A <var> (variable) by conven- tion begins with a ‘?‘, and the same set of variables appear in the left and right hand sides of a rule. <mapping-rule> ::= <spec> * <spec> <spec> ..- ..- <label> <eqn> . . . <eqn> <eqn> ..- ..- <path> = <label> 1 <path> = <var> 1 <path> = (<var> <label>) 1 <path> = <path> Mapping rules are interpreted to mean the following: whenever the parser builds a node with the appropri- ate label, and that node explicitly satisfies all the con- straints specified in the left-hand-side constraint list, then an alternate interpretation can be built; namely, a node satisfying the description on the right hand side. Variables indicate mappings between the values of properties of the original node and properties of the alternate node. LINK is implemented as a chart parser. Thus, al- ternative interpretations of a constituent can co-exist, as competing links in the chart. Selection of an inter- pretation is in effect performed when a complete parse can be found which uses one of the competing links. To illustrate, let us consider three different exam- ples of mapping rules. First, here is a mapping rule for the highly productive CHANGE-ALTITUDE is CHANGE-VALUE metaphor: A-ALTITUDE: * A-VALUE: (change) = ?X The simplicity of this rule reflects the productivity of the metaphor. Rather than just providing an am- biguous definition for one word, such as “rose”, it auto- matically creates an alternate interpretation whenever the semantic content of any word or group of words is constructed that fits the LHS. Thus sentences as dis- parate as “the temperature fell” and “The population of NYC is slowly creeping upward” are handled by the same rule. Additional semantic constraints in other rules would ensure selection of the appropriate inter- pretation, depending on the semantic category of the 312 Natural Language: Interpretation OBJECT. Thus “the plane is rising” would be inter- preted literally, while “the temperature is rising” would be interpreted metaphorically. Mapping rules in LINK are used to process other nonliteral constructions, such as metonymies and fig- ures of speech. Here is a rule for a common metonymy used in conjunction with the CHANGEALTITUDE is CHANGEVALUE metaphor: PHYS-OBJ: (assoc-num) = (?X%JMBl%) Many physical objects are used to refer to closely as- sociated numbers, e.g., the stock market for the Dow Jones Industrial Average, or the thermostat for its tem- perature setting. This rule means that “stock market” can be interpreted as either the building or the DJIA. Finally, here is a rule for the idiom “to go through the roof”, meaning to increase (in height or some other dimension) rapidly: VP: (head rep) = PI?&WE VP: (head rep) = A-ALTITUDE (head obj rep) = (head rep change) = + ROOF (head rep change rate) = FAST In this example, as with many idioms, none of the literal constructs of the LHS are relevant to the non- literal interpretation, so there is no need for variables. This rule also demonstrates that the syntactic content of the construct may be used as easily as the semantic. It is also possible for rules to refer to exact words and their order. Now consider the following example: The stock market went through the roof. In parsing this sentence, LINK creates literal and non-literal interpretations (links on the chart) for both phrases (“the stock market” and “went through the roof”) before trying to combine them to form a com- plete sentence. Given the semantic constraint that the stock market building is IMMOVABLE, and thus can- not be a (semantic) object of verbs requiring motion, then only the triply non-literal interpretation will unify to create a complete interpretation. If we make no such restriction, then there will be three S-nodes created, and the sentence is truly ambiguous. This example also demonstrates the flexibility of the first mapping rule, as alternate word definitions would need to be quite convoluted to arrive at the CHANGE-VALUE in this sentence. LINK’s model and the psychological data Now that we have described LINK’s model of metaphor processing in detail, let us return to the psychological data discussed earlier to see if our model is compati- ble with this data. Summarizing the experiments dis- cussed earlier, there are three main findings: 1. In the are no appropriate slower than context, reading reading times for times literal for metaphors constructions. 2. Common metaphorical even when expressions meanings appear to be computed are intended to be taken literally. of 3. Literal meanings are not primed after comprehension a sentence containing a nonliteral construction. Recall that all three of these findings contradict the Standard Pragmatic Model. But do they necessar- ily imply that literal meaning is not computed during metaphor comprehension, as some have suggested? We would argue that the first two findings are problematic for the Standard Model not because it states that lit- eral meaning is computed first, but rather because of its assertion that metaphor processing is failure-driven. According to the Standard Model a metaphorical in- terpration is not constructed unless some difficulty is encountered in constructing a literal interpretation. Waiting for a semantic (or pragmatic) constraint vi- olation before invoking a mapping rule results in the incorrect prediction of additional processing time for metaphors, as well as the incorrect prediction that metaphorical meanings will not be computed during comprehension of literal utterances. Thus, it seems to be step 2 of the Standard Model that results in the incorrect predictions. Our theory differs from the Standard Model in sev- eral ways. First, in our theory the rules are applied automatically, regardless of whether or not semantic or pragmatic failures are encountered while constructing literal meaning. Second, in our theory mapping rules never eliminate possible interpretations, they instead add other interpretations as alternatives. This differs from the Standard Model, in which literal meaning is transformed into (i.e. replaced by) a metaphorical in- terpretation. Because of these differences, our model can also ac- count for findings 1 and 2 above. First, literal expres- sions and metaphors will take the same amount of time to compute, because metaphorical interpretations are always computed, even in contexts in which the literal meaning is the one which is intended. Second, the fact that metaphorical interpretation is an automatic pro- cess means that even in literal contexts, metaphorical meaning is constructed. This accounts for the findings of (Glucksberg et al., 1982) and (Gibbs, 1983), in which evidence was found that nonliteral interpretations were constructed in literal contexts. We still have to explain the third finding, namely that literal meaning is not primed after comprehen- sion of a sentence containing a metaphorical expres- sion. This would seem to suggest that literal meaning has not been computed, which would contradict our theory. How can we account for this discrepancy? To answer this question, consider the situation in which an ambiguous word is encountered in an utterance. Swin- ney (1979) and Tanenhaus et al. (1979) have shown that all senses of an ambiguous word (even if it is syn- tactically ambiguous) are activated briefly (between 200 and 600 msecs), regardless of context, when the word is encountered, after which contextual informa- Lytinen, Bnrridge, and Kirtner 313 tion suppresses inappropriate senses. We envision that this same selection process is used in metaphor com- prehension. After a mapping rule has been applied, the situation is analogous to one in which all senses of an ambiguous word have been activated. As possi- ble alternative interpretations are computed, contex- tual information constrains which interpretations are acceptable in that context. Thus, by the end of a sen- tence containing a metaphor, it is quite likely that the literal sense of the metaphorical expression has already been suppressed by contextual constraints, just as al- ternate meanings of an ambiguous word are suppressed by context. This suggests that Gibbs’ (1983) results in- dicating that literal meanings were not primed at the end of a sentence may have been due to the target ap- pearing after suppression of the literal meaning had already taken place.3 Conchlsion The psychological evidence that we have cited above clearly indicates that metaphorical and other nonlit- era1 constructions are processed as quickly as compa- rable literal constructions, given an appropriate con- text. This evidence has shown the Standard Pragmatic Model to be an inadequate model of human metaphor processing. Since the Standard Model stipulates that the first step in understanding an utterance is to com- pute its literal meaning, and since the Standard Prag- matic Model’s failure to explain the psychological data is directly tied to this first step in understanding, the role of literal meaning in understanding has come into question. Many researchers, Gibbs among them, have claimed that the evidence shows that literal mean- ing need not be computed on the way to computing metaphorical meaning. We have argued that the problem with the Standard Pragmatic Model lies not in the fact that it computes literal meaning, but in the process by which literal meaning is computed and used to compute intended meaning. We have presented an alternative model of metaphor comprehension which computes literal mean- ing but which is consistent with the existing psycho- logical data. Although we feel that there are strong computa- tional motivations for preferring an approach such as ours that uses mapping rules, it appears that the ex- isting empirical evidence is not adequate to distinguish between Gibbs’ model, in which literal meaning is not computed, and our alternate model. The data are in- adequate because, in general, they only tell us about processing at the sentence level, rather than the word 3We still need t o explain Gibbs’ finding that nonliteral meanings were still primed at the end of a sentence which was interpreted literally. It is possible that the asymmetry of these results could be explained by frequency effects: if the indirect request sense of a construction occurs much more frequently than the literal sense, this might overpower the ability of context to suppress this meaning. 314 Natural Language: Interpretation or phrase level. The reading time comparisons which we have discussed have been done on entire sentences rather than on individual words or phrases, and prim- ing experiments have tested facilitation only at the end of sentences. Thus, existing results say little about the process of metaphor comprehension at the word or phrase level. It is at this level that we could distinguish between the competing theories. References Carbonell, J. (1982). Metaphor: An inescapable phe- nomenon in natural language comprehension. In Lehnert , W. and Ringle, M. (eds), Strategies for Natural Language Processing. Lawrence Erlbaum Associates, Hillsdale, NJ, pp. 415-434. Gerrig, R. (1989). Constraints on theories of metaphor. Cognitive Science 13, pp. 235-241. Gibbs, R. (1979). Contextual effects in understanding indirect requests. Discourse Processes 2, pp. l-10. Gibbs, R. (1983). Do people always process the literal meanings of indirect requests? Journal of Experi- mental Psychology: Learning, Memory, and Cogni- tion 9; pp. 524-533. Gibbs, R. (1984). Literal meaning and psychological theory. Cognitive Science 8, pp. 275-304. Gluckserg, S., Gildea, P., and Bookin, H. (1982). On understanding nonliteral speech: Can people ignore metaphors? Journal of Verbal Learning and Verbal Behavior 22, pp. 577-590. Induryka, B. (1987). Approximate semantic transfer- ence: A computational theory of metaphors and analogies. Cognitive Science 11, pp. 445-480. Lakoff, G., and Johnson, M. (1980) Metaphors We Live By. Chicago: University of Chicago Press. Langacker, R. (1987). Foundations of Cognitive Gram- mar, Vol. 1. Stanford, CA: Stanford University Press. Martin, J. (1990). A computation Model of Metaphor Interpretation. San Diego: Academic Press. Ortony, A. Schallert, D., Reynolds, R., and Antos, S. (1978). Interpreting metaphors and idioms: Some effects of context on comprehension. Journal of Verbal Learning and Verbal Behavior 17, pp. 465- 477. Searle, J. (1978). Literal meaning. Erkenntnis, 13, pp. 207-224. Shieber, S. (1986). An Introduction to Unification- based Approaches to Grammar. CSLI, Stanford CA. Swinney, D. (1979). L exical access during sentence comprehension: (Re)consideration of context ef- fects. Journal of Verbal Learning and Verbal Be- havior 18, pp. 645-659. Tanenhaus, M., Leiman, J., and Seidenberg, M. (1979). Evidence for multiple stages in the processing of ambiguous words in syntactic contexts. Journal of Verbal Learning and Verbal Behavior 18, pp. 427- 440. | 1992 | 59 |
1,253 | Dept. Electronic Engineering, Queen Mary & Westfield College, Mile End Road, London El 4NS, UK nickj@qmw.ac.uk and amamdani@qmw.ac.uk Abstract Joint responsibility is a new meta-level description of how cooperating agents should behave when engaged in collaborative problem solving. It is independent of any specific planning or consensus forming mechanism, but can be mapped down to such a level. An application of the framework to the real world problem of electricity transportation management is given and its implementation is discussed. A comparative analysis of responsibility and two other group organisational structures, selfish problem solvers and communities in which collaborative behaviour emerges from interactions, is undertaken. The aim being to evaluate their relative performance characteristics in dynamic and unpredictable environments in which decisions are taken using partial, imprecise views of the system. As computing systems are being applied to ever more demanding and complex domains, so the infeasibility of constructing a single monolithic problem solver becomes more apparent. To combat this complexity barrier, system engineers are starting to investigate the possibility of using multiple, cooperating problem solvers in which both control and data is distributed. Each agent has its own problem solving competence; however it needs to interact with others in order to solve problems which lie outside its domain of expertise, to avoid conflicts and to enhance its problem solving. To date, two types of multi-agent system have been built: those which solve particular problems (eg air traffic control (Cammarata, F&Arthur & Steeb 1983), vehicle monitoring (Lesser & Corkill 1983) and acting as a pilot’s aid (Smith & Broadwell 1988)) and those which are generaI (eg MACE (Gasser, Braganza & Herman 1988) and ABE (Hayes-Roth et al. 1988)). However, as yet, there have been few serious attempts at applying general- + The work described in this paper has been partially supported by the ESPRIT II project P2256 (ARCHON) purpose systems to real size, industrial problems (Jennings & Wittig 1992). One of the major stumbling blocks to this advancement has been the lack of a clear, implementable theory describing how groups of agents should interact during collaborative problem solving (Bond 8r Gasser 1988; Gasser & Huhns 1989). Such a theory becomes especially important in complex domains in which events occur at unpredictable times, in which decisions are based on incomplete and imprecise information, in which agents posses multiple areas of problem solving competence and when social interactions are complex (i.e. involve several iterations over a prolonged period of time). In these harsh environments it is difficult to ensure that a group’s behaviour remains coordinated, because initial assumptions and deductions may be incorrect or inappropriate; therefore a comprehensive theory must provide a grounded basis from which robust problem solving communities can be constructed. Many authors have recognised that intentions, a commitment to present and future plans (Bratman 1990) are essential in guiding the actions of an individual (Cohen & Levesque 1990; Werner 1989). However in order to describe the actions of a group of agents working collaboratively the notion of joint intentions, a joint commitment to perform a collective action while in a certain shared mental state (Cohen 8z Levesque 1991) is needed to bind the actions of team members together. Most accounts concentrate exclusively on what it means for a joint intention to exist (Rae & Georgeff 1991; Searle 1990; Tuomela & Miller 1988); this description being in terms of nested structures of belief and mutual belief about the goals and intentions of other agents within the community. In contrast, the notion of joint responsibility (Jennings 1991a) outlined in this paper stresses the role of intentions as “conduct controllers” (Bratman 1990) - specifying how agents should behave whilst engaged in collaborative problem solving. This behavioural specification offers a clearer path from theory to implementation; providing functional guidelines for architecture design, criteria against which the monitoring component can evaluate ongoing problem solving and a Jennings and Mamdani 269 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. prescription of how to act when collaborative problem solving becomes untenable. Responsibility subsumes the work on joint persistent goals (Levesque, Cohen & Nunes 1990), defining a finer structure for joint commitment which involves plan states as well as goal states. The responsibility framework has been implemented in GRATE* (Jennings 1992) and demonstrated on the exemplar domain of monitoring electricity transportation networks. The problems faced in this domain are typical of many industrial applications - especially the need to respond to the dynamics of the process being controlled/ monitored and taking decisions using partial, imprecise views of the system. An introduction to electricity transport management is given and a joint action involving three agents is described. The responsibility framework is outlined and its implementation in GRATE* is discussed. Finally some experimental results are given: offering an empirical evaluation of the characteristics of the proposed framework in dynamic, unpredictable environments. Monitoring Electricity Transport Networks To be available at customers’ sites, electricity has to be transported, sometimes over many hundreds of kilometres, from the power station where it is produced. During this process, there is significant scope for problems (eg power lines may become broken, substations damaged by lightning strikes, etc.). To ensure early detection of such problems, many distribution companies have installed sophisticated monitoring and diagnosis software. An illustration of three such systems, working together to produce a list of faults, is given below: Figure 1: Cooperating Agents The CSI is responsible for receiving messages from the network and analyzing them to determine whether they represent a fault. The AAA can pinpoint the elements at fault and the BAI can indicate the group of elements out of service, both agents using information from the CSI. Several cooperative scenarios can be identified between this group of agents (Aarnts et al. 1991), however we concentrate on the one depicted above. The CSI is continuously receiving information about the state of the network, which it groups together and analyses. In most cases, this information will periodically be sent to the BAI and AAA so that they can update their network models. However when the information encodes a fault, the CSI immediately informs the other two. The AAA starts its diagnostic process for identifying the specific network elements at fault - initially producing a quick, approximate answer which it subsequently refines using a more accurate procedure. At the same time, the BAI starts determining the group of elements out of service (the black out area), which when calculated is passed onto the AAA. In order to be consistent, the elements identified by the AAA should also be in the black out area produced by the BAI - a fact taken into account by the AA.A while carrying out its detailed diagnosis. While the AAA and BAI are working on the diagnosis, the CSI continues to monitor the network in order to detect significant changes in status, which will invalidate any diagnoses being made, or indicate whether the fault was only transient. Once a fault has been detected, each agent has a role to play and by combining their expertise, problem solving is enhanced. Overall system robustness and performance can be improved by intelligently sharing information which is available in the system, but not readily available to all the agents. There are two main cases in which this can be seen: firstly if the CSI detects that the fault is transient, meaning the other two are attempting to diagnose a nonexistent fault. Secondly if further faults occur, the network topology may be so radically altered that the diagnosis is predicated on invalid assumptions. The formal account of joint responsibility uses modal, temporal logics to define preconditions which must be satisfied before joint problem solving can commence and to prescribe how individual team members should behave once it has (Jennings 1991a). Both facets are essential ingredients for a full definition of joint intentionality. Once the need for joint action has been established, three conditions need to be met before it can actually begin. Firstly, a group of agents who wish to solve a common problem must be identified. In our example, willing participants are those which have or can be persuaded to have the goal of participating in the detection of faulty network elements. Secondly, participants must agree that they will work together to achieve their common objective w in particular they must acknowledge the principle that a 270 Multi-Agent Coordination common solution is essential. Without acknowledging this, there can be no intentional joint action, only unintentional (accidental) interaction (Bratman 1990). The actual solution will only begin to be developed once all prerequisites have been satisfied. Finally agents must agree that they will obey a “code of conduct” to guide their actions and interactions whilst performing the joint activity. This code specified below ensures that the group operates in a coordinated and efficient manner and that it is robust in the face of changing circumstances. Prescription of Behaviour A comprehensive description of how individuals should behave in social interactions needs to address the duality of roles which they play - describing how to carry out local problem solving and how to act towards others The notion of commitment is central to the definition of joint responsibility and means that once agents agree they will perform an action they will endeavour to carry it out. Therefore once the common solution has been agreed, all participants should ensure that they reserve sufficient resources to carry out the actions in which they are involved. However because of the unpredictability and dynamics of the environment - events may occur which affect this commitment. For example new information may become available which invalidates previous assumptions or unexpected events may require urgent attention. In such circumstances, it would be irrational for an agent to remain committed to the previously agreed actions; so conditions for reneging need to be enumerated. There are two levels at which lack of commitment can occur: to the common objective (eg there is no longer a need to diagnose faults) or to the common solution. The following reasons for dropping commitment to the common objective have been given (Levesque, Cohen & Nunes 1990): 0 the objective already holds eg another agent has computed the faulty elements 0 the motivation for the objective is no longer present eg CSI realises that the correspond to a fault group of alarms do not * the objective will never be attained eg AAA realises that it is not being supplied with sufficient alarm messages to make a diagnosis However conditions under which agents can drop commitment to the common solution also need to be defined (Jennings 1991a). Separate conditions relating to plan states are necessary because dropping commitment to a plan typically involves developing a new solution for the same problem rather than dropping the goal completely (i.e. it has a different functional role) and also that it provides a more detailed specification for the system implementor. Reasons include: 0 following outcome the agreed plan does not lead to the desired eg CSI detects a substantial change in the network, meaning that the models being used by the AAA and BAI are so inaccurate that any ensuing diagnosis will be incorrect e one (or more) of the actions cannot be executed eg CSI is no longer receiving information about the network and so is unable to monitor its status e one of the agreed actions has not been performed correctly eg the BAI has been distracted by an unplanned task and cannot produce the black out area at the agreed time. Meaning the AAA cannot compare its initial hypotheses with the black out area to ensure consistency before undertaking the detailed analysis. When an individual becomes uncommitted (to either the objective or the means of attaining it) it cannot simply stop its own activity and disregard other team members. Rather it must endeavour to inform all team members of this fact and also of the reason for the change. This ensures team members can monitor the progress of events which affect their joint work and, in the case of failure, the amount of wasted resource can be minimised. Combining the local and social facets, leads to the following prescription of behaviour for each team member: while committed to joint action do perform agreed activities at correct times monitor situation to ensure commitment is still rational if no longer jointly committed then suspend local actions associated with joint act determine if local remedial action available inform others of lack of commitment, proposed remedy if exists reason and The remedy will depend on the reason for dropping commitment; varying from rescheduling actions if the plan was not executed correctly, to drawing up a new solution if the plan no.donger leads to the desired objective, to abandoning the joint action if the objective is unattainable or the motivation no longer valid. Jennings and Mamdani 271 Implementing Responsibility Joint responsibility is a me&level prescription of agent behaviour during collaborative problem solving which is independent of the mechanisms used to obtain agreements and carry out planning. It is, therefore, equally applicable in communities where one agent carries out all the planning for other agents and in those in which the planning is carried out as a collaborative activity. It makes explicit much of the reasoning present in such planning systems, thus facilitating deeper reasoning about the process of collaboration. There are an infinite number of possible realizations of the framework (of which GRATE* is but one); each with its own protocol for obtaining agreements and defining the common solution. GRATE* agents have the architecture shown below - thicker arrows represent data flow and the thinner ones control. Communication Manager Acquaintance Models I ASSESSMENT Figure 2: GRATE* Agent Architecture An agent is divided into two parts: the domain level system (DLS) in which the agent’s problem solving competence is located and the cooperation and control layer (CCL) which ensures that domain level actions are coordinated with those of others. The CCL has three main problem solving components - each implemented as an independent production system communicating with the others via messages. The situation assessment module provides an overview and evaluation of the local and global situation, as perceived by that agent. It monitors local actions to ensure commitments are honoured, detects commitment failures and proposes remedial solutions if they exist. The cooperation module has to establish social interactions once the situation assessment module detects the need (eg enact the GRATE* responsibility protocol), maintain established social interactions and provide feedback on social action initiations from other agents. The control module is the interface to the DLS and is responsible for managing all interactions with it. The information store provides a repository for all domain information received by the CCL (emanating from either the DLS or as a result of interaction with other agents). The acquaintance and self models are representations of other agents and of the local domain level system respectively (Jennings 1991b). In the GRATE* protocol, each team has one leader - the agent which detects the need for joint action. This agent then contacts other community members to establish whether they are interested in participating in the group activity. Interested community members create a joint intention representation within their self model (see below) and return a message indicating their willingness to participate. Name: (DIAGNOSE-FAULT) Motivation: ((DIAGNOSE-NETWORK-FAULT)) Chosen Recipe: (((START(IDENTIFY-INITIAL-BOA)) (START(GENERATE-TENTATIVE-DIAGNOSIS)) (START (MONITOR-DISTURBANCE))) ((START(PERFORM- FINAL-DIAGNOSIS)))) Start Time: 8 Maximum End Time: 82 Duration: 74 Priority: 20 Status: EXECUTING-JOINT-ACTION Outcome: (VALIDATED-FAULT-HYPOTHESES) Participants: ((SELF PROPOSER EXECUTING-JOINT- ACTION) (CSI TEAM-MEMBER EXECUTING-JOINT- ACTION) (BAl TEAM-MEMBER EXECUTING-JOINT- ACTION)) Bindings: (@A/ (IDENTIFY-INITIAL-BOA) 19) (SELF (GENERATE-TENTATIVE-DIAGNOSIS) 19) (CSI (MONITOR-DISTURBANCE) 19) (SELF (PERFORM- FINAL-HYPOTHESIS-DIAGNOSIS) 35)) Contribution: ((SELF ((GENERATE-TENTATIVE- DIAGNOSIS) (YES SELECTED)) ((PERFORM-FINAL- DIAGNOSIS) (YES SELECTED))) @A/ ((IDENTIFY- INITIAL-BOA) (YES SELECTED))) (CSI ((MONITOR- DISTURBANCE) (YES SELECTED)))) Most of the structure is self evident, however some slots require explanation. The chosen recipe (Pollack 1990) for joint intentions is a series of actions together with some temporal ordering constraints that will produce the desired outcome and for individual intentions (see figure 3) it is the name of a local recipe. For joint intentions the status refers to the current phase of the protocol - forming-group, developing-solution or executing-joint-action; whereas for individual intentions it is simply executing or pending. The participants slot indicates the organisational structure of the group - in this example there is one organiser (AAA) and two other team members (BAI & CSI). The 272 Multi-Agent Coordination bindings indicate the agents who were chosen to participate, the actions they are to perform and the time at which these actions should be carried out. The contribution slot records those agents who expressed an interest in participating in the joint action, the actions they could potentially contribute, an indication of whether they were willing to make this contribution in the context of the joint action and whether or not they were ultimately chosen to participate. When all the potential team members have replied indicating their willingness (or not) to participate, the leader decides upon a recipe for realising the desired outcome. It then starts the detailed planning of the recipe’s action timings using the following algorithm: Forall actions in recipe do select agent A to carry out action a (criteria: minimize number group members) calculate time (tJ for a to be performed based on temporal orderings send (a, tol) proposal to A A evaluates proposal against existing commitments (C’s): if no-conflicts (a, t& then create commitment C, for A to (a, t& if conflicts((a, t,), C) h priority(a) > priority(C) then create commitment C, for A to (a, t.& and reschedule C if conflicts((a, ta), C) h priority(a) c priority(C) then find free time (tol + At& note commitment C, and return updated time to leader if time proposal modified, update remaining action times by At, Making a commitment (above) involves creating an individual intention to perform an action: Name: (ACHIEVE (IDENTIFY-INITIAL-BOA)) Motivation: (SATISFYJOINT-ACTION (DIAGNOSE- FAULT))) Chosen Recipe: (IDENTIFY-INITIAL-BOA) Start Time: 19 Maximum End Time: 34 Duration: 15 Priority: 20 Status: PENDING Outcome: (Black-Out-Area) Figure 3: Individual Intention Representation Experimental Wesdts - START (IMP) + START (RESP) -g- END (IMP) -f+ END (RESP) eGomImi SELFISH IYPLlctT Figure 4: Varying Chance of Unsustainability Delay in Joint Action End 250T Joint Action Start Time T50 200 40 150 30 100 20 so 10 0 0 1 2 3 4 6 5 Number Rule Firings in CCL pw Unit7 0 + Delay (IMP) - stert (IMP) 4- Deley (RESPI =+= Stert (REP) Figure 5a: Varying Amount of CCL Processing Power Action Time 260 a 200 fY 1 2 3 4 5 8 7 8 9 10 11 12 13 14 15 Communication Cost To verify the claim that the responsibility framework is FigureSb: Varying Message Delay Jennings and Mamdani 273 capable of ensuring robust joint problem solving in dynamic and unpredictable environments, a series of comparative experiments were undertaken using the cooperative scenario outlined earlier. Three organisational structures were compared: responsibility, implicit group formation and selfish problem solvers. With the implicit organisational structure the agents do not explicitly form groups (there is no joint intention), rather the group structure “emerges” as a result of interaction (Steels 1991). In the selfish organisation, groups and common solutions are formed as in the GRATE* responsibility protocol. However if an agent comes to believe that the joint action has become unsustainable, it stops the associated local processing, but does not inform others of its lack of commitment. This is deemed selfish because the agent who detects a problem and realises that the joint action is doomed to failure does not expend additional resources informing others, since doing so brings it no direct benefit. Figure 4 shows the performance of the three groups, in the face of varying chances of the joint action becoming unsustainable. An increased chance of unsustainability corresponds to a more dynamic environment or an environment in which decisions are based on less stable views. The distribution of the reason for unsustainability is uniform over the conditions described earlier, as is the time during the joint action at which the problem occurs. Wasted effort is defined to be the number of processing cycles from the reason for commitment failure occurring, to the time when an agent stops performing its associated actions. The average is taken over all the agents in the team (3 in this case) over 100 runs. As this figure shows, the average wasted effort for the responsibility framework is significantly less than the other two organisational forms, confirming our hypothesis that it leads to robust behaviour in complex environments. The implicit group performs better than the selfish one because agents exchange information (based on known interests stored in the acquaintance models (Jennings 1991b)) which can lead to the recipient reahsing that some of its intended actions are no longer appropriate and hence should be abandoned. This informal interchange means that in the case of unsustainability, an agent which cannot detect a problem with the joint action itself may be supplied with the necessary information by an agent who can. In contrast, in the selfish group structure such informal communication paths were deliberately not used since calculating agents interested in a piece of information requires computational resource - meaning agents which were unable to detect a problem were left to complete all their actions. Therefore when claiming that self interest is the basis for cooperation (Durfee, Lesser & Corkill 1988; Axelrod 1984), it is important to note that it should not be used as a criteria for defining agent behaviour once the social action has started. Participation in group problem solving requires some element of compromise, meaning self interest needs to be tempered with consideration for the group as a whole. Other studies were also carried out to examine the behaviour of the responsible (RESP) and implicit (IMP) groups when processing power is limited and communication delays varied. Figure Sa shows the affect of limiting the CCL’s processing power - in terms of the total number of rules it can fiie per cycle. It shows that the difference in start times between the two organisational forms remains virtually constant except when the amount of processing per time unit becomes very small. This is somewhat surprising since it was envisaged that the responsibility protocol would require greater processing power and hence be more adversely affected. The responsibility framework always takes longer to start, because it constructs groups and common solutions afresh each time a joint action is required. In practice it is unlikely that such activities would need to be undertaken every time, because common patterns would begin to emerge and hence reasoning from first principles would not be necessary. The figure also shows that except in cases where processing is severely limited, the delay (compared with infinite processing power) in the time taken to finish the joint action is approximately the same for both organisational forms. Figure Sb shows the affect of varying the time taken for a message to be delivered. By showing a sharper rise in start and finish times, it highlights the greater communication overhead present in the responsibility protocol - a result consistent with theory and practice of organisational science Conclusions The responsibility framework provides a new meta-level description of how agents should behave when engaged in collaborative problem solving. It has been implemented in the GRATE* system and applied to the real-world problem of electricity transportation management. An analysis of its performance characteristics has been undertaken: comparing it with emergent and selfish group organisational structures. These experiments highlight the benefits, in terms of decreased resource wastage, of using responsibility as a means for prescribing agent behaviour in dynamic and unpredictable environments. They also indicate that, in most cases, the GRATE* responsibility protocol requires no more processing power than the implicit group structure. One potential drawback, that of a large communication overhead, has been identified - therefore for less complex forms of social interaction or 274 Multi-Agent Coordination time critical environments it may be appropriate to devise a more efficient protocol, whilst retaining the behavioural specification for robust and coherent behaviour. Acknowledgments We would like to acknowledge the help of all the ARCHON partners: Atlas Elektronik, JRC Ispra, Framentec, Labein, IRIDIA, Iberdrola, EA Technology, Amber, Technical University of Athens, University of Amsterdam, Volmac, CERN and University of Porto. In particular discussion with, and comments from, Erick Gaussens, Thies Wittig, Juan Perez, Inaki Laresgoiti and Jose Corera have been particularly useful. eferences Aamts, R., Corera, J., Perez, J., Gureghian, D. and Jennings, N. R. 1991. Examples of Cooperative Situations and their Implementation. Journal of Software Research, 3 (4), 74- 81. Axelrod, R. 1984. The Evolution of Cooperation. Basic Books Inc. Bond, A. and & Gasser, L. eds. 1988. Readings in Distributed Artificial Intelligence, Morgan Kaufmann. Bratman, M. E. 1990. What is Intention?. Intentions in Communication, (eds P.R.Cohen, J.Morgan & M.E.Pollack), 15-33, MIT Press Cammarata, S., McArthur, D. and Steeb, R. 1983. Strategies of Cooperation in Distributed Problem Solving. Proc. IJCAI 767-770. Cohen, F? R. and Levesque, H. J. 1991. Teamwork. SRI Technical Note 504. Cohen, P R. and Levesque, H. J. 1990. Intention is Choice with Commitment. Artificial Intelligence, 42,213-261. Durfee, E. H., Lesser, V. R. and Corkill, D. D. 1988. Cooperation through Communication in a Distributed Problem Solving Network, in Distributed Artificial Intelligence (Ed M.Huhns), 29-58 Gasser, L. and Huhns, M. eds 1989. Distributed Artificial Intelligence Vol II, Pitman Publishing. Gasser, L., Braganza, C., and Herman, N. 1988. MACE: A Flexible Testbed for Distributed AI Research, in Distributed Artificial Intelligence (Ed M.Huhns), 119-153. Hayes-Roth, F. A., Erman, L., Fouse, S., Lark, J., and Davidson, J. 1988. ABE: A Cooperative Operating System and Development Environment. AI Tools & Techniques, (Ed M.Richer), Ablex. Jennings, N. R. and Wittig, T. 1992. ARCHON: Theory and Practice in Distributed Artificial Intelligence: Theory and Praxis (eds L.Gasser & N.Avouris), Kluwer Academic Press (forthcoming) Jennings, N. R. 1992. GRATE*: A Cooperation Knowledge Level System For Group Problem Solving. Technical Report, Dept. Electronic Engineering, Queen Mary & Westfield College. Jennings, N. R. 1991a. On Being Responsible. in MAAMAW, Kaiserslautem, Germany. Jennings, N. R. 1991b. Cooperation in Industrial Systems. ESPRIT Conference, 253-263, Brussels. Lesser, V. R. and Corkill, D. 1983. The Distributed Vehicle Monitoring Testbed: A Tool for Investigating Distributed Problem Solving Networks. AI Magazine, 15-33. Levesque, H. J., Cohen, P. R. and Nunes, J. H. 1990. On Acting Together”, AAAI, 94-99. Pollack, M. E. 1990. Plans as Complex Mental Attitudes. Intentions in Communication, (eds I?R.Cohen, J.Morgan dz M.E.Pollack), 77- 103, MIT Press Rao, A. S. and Georgeff, M. P 1991. Social Plans: A Preliminary Report. MAAMAW, Kaiserslautem, Germany. Searle, J. R. 1990. Collective Intentions and Actions. in Intentions in Communication, (eds PR.Cohen, J.Morgan & M.E.Pollack), 401416, MIT Press Smith, D. and Broadwell, M. 1988. Pilot’s Associate: An Overview. SAE Aerotech Conference Steels, L. 1991. Towards a Theory of Emergent Functionality, in From Animals to Animats, ed J.Meyer and S.Wilson, 451-461, Bradford Books. Tuomela, R. and Miller, K. 1988. We-Intentions. Philosophical Studies 53,367-389. Werner, E. 1989. Cooperating Agents: A Unified Theory of Communication & Social Structure. in Distributed Artificial Intelligence Vol II, (eds L.Gasser & M.Huhns), 3-36. Jennings and Mamdani 275 | 1992 | 6 |
1,254 | atism- riven Control Paul S. Jacobs Artificial Intelligence Laboratory GE Research and Development Center Schenectady, NY 12301 USA psjacob&crd.ge.com Analysis * Abstract Traditional syntactic models of parsing have been inadequate for task-driven processing of extended text, because they spend most of their time on misdirected linguistic analysis, leading to problems with both efficiency and coverage. Statistical and domain-driven processing offer compelling possibilities, but only as a comple- ment to syntactic processing. For semantically- oriented tasks such as data extraction from text, the problem is how to combine the cover- age of these “weaker” methods with the detail and accuracy of traditional lingusitic analysis. A good approach is to focus linguistic analysis on relations that directly impact the semantic results, detaching these relations from the com- plete constituents to which they belong. This approach results in a faster, more robust, and potentially more accura.te parser for real text. 1 Introduction During the last several years, the field of natural lan- guage understanding research has moved very quickly from the analysis of single sentences in interface appli- cations to the accurate extraction of data from large bodies of real text. The rapid scale-up of text interpre- tation systems seems close to producing programs that can accurately extract shallow data from broad volumes of text, such as a daily newspaper or reference volume. These emerging applications demand new technologies, especially in the control of parsing. The task of adequately processing naturally-occurring texts is so difficult for traditional models of langua.ge analysis that systems that do relatively little parsing often appear to do as well [Sundheim, 1989; Sharman *This research was sponsored (in part) by the Defense Ad- vanced Research Project Agency (DOD) and other govern- ment agencies. The views and conclusions contained in this document are those of the authors and should not be inter- preted as representing the official policies, either expressed or implied, of the Defense Advanced Research Project Agency or the US Government. et al., 1990; Church et al., 19891 as programs that can parse broadly using well-developed grammars and models of language. However, in task-driven evalu- ations such as the recent DARPA-sponsored Message Understanding Conference (MUC-3) [Sundheim, 1991; Lehnert and Sundheim, 19911, the programs that, com- bine sound partial parsing with other strategies seem to outperform both the traditi0na.l parsing and the no- parsing approaches. The message of these experiments is that weak methods are not, superior to parsing, but that parsing must be carefully controlled to produce use- ful information from t,est. Broad-coverage parsers “run amok” ’ when confronted with extended texts without sufficient, information to control t,lie interpretation pro- cess. Relation-driven control is a partial parsing method that combines the benefits of linguistic parsing with domain-driven analysis and “weak” methods by combin- ing information at the level of linguistic relations, us- ing these rela.tions t<o guide parsing, recovery, and se- mantic interpretation. The motivation for this polythe- oretic approach is that full parsing really outperforms wea.k methods when there is sufficient knowledge to con- t’rol parsing and to produce meaningful results when the parser fails. Linguistic relations, such as subject-verb and verb-complement, are the focal point of this method because they rela.te to lexical and semantic preferences better than individual lexical items or complex synta.ctic structures. The relation-driven control method is implemented in the current version of the GE NLToolset [Jacobs and Rau, 1990b], although many aspects of the method are incomplete. In this preliminary form, the approach tested successfully in the government-sponsored MUC-3 evaluation [Krupka et nl., 1991b], showing significant if not dramatic effects on system covera.ge and speed with- out a loss of accuracy. The rest of this paper will give some examples of tahe problems with full text parsing, present the relat,ion-driven control strategy with results from processing representat~ive samples of text, and ex- ‘amok (Webst,er’s New World Dictionary, 1988): Malay umul;, attacking furiously . . ..run (or go) amok 1 to rush about in a frenzv to kill 2 to lose control of oneself and behave outrageously or’ violent)ly 3 to become wild or undisciplined Jacobs 315 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. plain how the method text extraction system. impacts the performance of the somehow caused t,he deaths and tl1a.t t,he workers died. 2 Problems in extracting data from real text No data extraction system can adequately process an arbitrary text in an arbitrary domain. The limitations come both from failed parses and absurd interpretations that serve no useful purpose. The current state of the art is that programs can perform very limited processing of fairly broad bodies of text as in news categorization, [Hayes et al., 1988; Jacobs, 1992131, and somewhat more detailed processing of similar texts in constrained domains [Sundheim, 19911. It is within reason to expect that work over the next sev- eral years will produce programs that can, for example, read a daily newspaper and extract useful, structured in- formation from most items. The breadth and accuracy of parser coverage is clearly still in the critical path, as linguistic parsers tend to be of little help once the severe constraints of a domain are lifted. As an example of the effects of these problems, the following is an analysis of a typical sentence selected from a corpus of WaZZ Street Journal text (November 2, 1989) obtained through the ACL Data Collection Initiative, along with some of the problems that our system had on its first pass at analyzing this corpus [Jacobs et al., 19901. We have informally verified that many other language analysis programs have most of the same problems. The first sentence of the WaZZ Street Journal story is as follows: A form of asbestos once used to make Kent cigarette filters has caused a high percentage of cancer deaths among a group of workers ex- posed to it more than 30 years ago, researchers reported. (34 words) This text is about typical in length and complexity for the first sentence of a news story, and was not from any domain that we had covered. While the system did produce some valid semantic information, such as that asbestos had caused the dea.ths, that cancer is a disease, and that the workers were somehow involved in dying, it encountered the following difficulties, which we consider to be representative: e Failed parses and attachments, e.g., the phrase to make Kent cigarette filters was attached as a prepo- sitional phrase modifying form, because used does not allow an infinitive complement. o Extraneous considerations, e.g., the program found several parses with the noun phrase Kent cigarette filters broken up, with used as the main verb of the sentence or with jilters as a verb. a Inadequate depth of interpretation, e.g. the pro- gram correctly determined that cancer modified deaths, as well as the sense of among, but did not produce any representation of the fact that cancer Clearly, some of these problems result from a lack of system knowledge; for example, the program did not rec- ognize the word asbestos and should have been able to link diseases to deaths (since it, did “know” that cancer is a disease). On the other hand, just as many of the problems result from too much knowledge-that is, the extra work and false interpretations stemming from the complexity of the system. These problems boil down to two paradigmatic issues-coverage and attachment. The double-edged sword of coverage Extending a parsing system’s knowledge base avoids “gaps” and increases the range of inputs that can be in- terpreted, but also increases the combinat#orics of parsing and the likelihood that the system will produce an in- correct interpretation. For example, knowing that make and high can be nouns seems necessary for handling real texts, but the system must’ discard such possibil- ities quickly from consideration in the Iient cigarette example. Similarly, determiners are optional in many prepositional phrases wit,11 the preposition to, but this knowledge can cause spurious parses of many infinitive phrases. Intuitively, disambiguating to at the sentence level doesn’t seem to make sense, if to lunch is a thou- sa.nd times more likely to be a prepositional phrase tl1a.n to n?crke. But this is precisely the sort of disa.mbiguation most pa.rsers t,ry t#o do, often relying on sentence-level constraints where “weaker” lexical or domain knowledge would produce much bet,ter result,s. The entrapment of at tacluneut Attachment, especially of prepositional phrases, has been the focus of much parsing work (e.g. [Frazier and Fodor, 1978; Schubert, 19861) because it is the source of most, of the combinatorics in parsing. Yet phrase a.ttach- ment, does not, a.lways contribute very much to t,he results of text analysis, particularly in dat#a. extraction. Even worse, an otherwise inconsequential a.ttachment decision can actually interfere with get)tiiig t,lie correct semantic interpretation. Regardless of the degree to which syntax contributes to correct attachment,, t,he combination of at,tachment possibilities is a misdirected parsing effort. In addit,ion to phrases like nllzo~~,g n group of workers, which can le- gitimately att#a.ch in three places, t#emporal modifiers like more than 30 years ago ca.n attach almost anywhere. This sort of phrase is especially common in uews sto- ries. The result is that, a typical parser spends more time deliberat*ing where to at*tach phrases whose attach- ment doesn’t help sema.nt,ic interpretation than it does on phrases whose attachment, does mat.ter, and parsing is fuiidament~ally misdirected. The relation-driven control strategy, by loosely cou- pling linguistic processing and attachment to constituent structure, a.voids problems wit 11 spurious lexical and at- 316 Natural Language: Parsing tachment decisions and allows these decisions from a combination of knowledge sources. to derive 3 Relation-driven control At the heart of these issues is the problem that most full parsers are fundamentally clause-driven, from the extreme case of those that produce no information at all when they fail to recognize a sentence, to the more typical parsers that resolve attachment ambiguities at the sentence level. Many programs often can’t tell if a word is a noun or a verb without building a complete sentence structure around it. Relation-driven control is a model of parsing and se- mantic interpretation in which linguistic relations serve as the focal point of analysis. These relations, such as those between subject and verb, verb and complement, or noun and modifier, are independent of syntactic anal- ysis in that they are not tied to a particular complex lin- guistic structure. While the relations are themselves lin- guistic structures, they associate easily with conceptual roles and statistical knowledge (such as co-ocurrence), making it easier to validate them without a full parse. Figure 1 breaks down the major components of our system, showing how relation-driven control mediates among three general types of processing-( 1) corpus- driven, shallow pre-processing, (2) linguistic analy- sis, including parsing and semantic interpretation, and (3) post-processing, mainly template-filling and other domain-driven processing. The term template here refers to the final result of data extraction-a frame with a set of conceptual features for each particular type of object or event (see Section 4). This model is imple- mented, although there is a great deal more work to be done, particularly in expanding the pre-processing and recovery components. The system uses the TRUMP [Ja- cobs, 1992c] analyzer, and is currently being extended to use Carnegie Mellon University’s implementation of Tomita’s algorithm [Tomita, 19861 for multi-lingual pro- cessing under the government-sponsored TIPSTER pro- gram. A relation is a triple consisting of a head, a role, and a filler (or non-head). Each linguistic relation ma.ps into a conceptual relation that associates word senses with conceptual roles, giving rise to three types of semantic preferences. Figure 2 illustrates a relation and the three types of preferences. Relations can derive from lexical preferences and other patterns established during pre-processing, from the se- mantic interpretation of constituents during parsing, and from domain knowledge when recovering from failed parses. Relation-driven control focuses the interpreta- tion task on determining a preference score for each sense of each content word in the text, along with the semantic and template roles associated with that word sense. During interpretation, the program drops linguis- tic structures with low relation scores. After syntactic processing, the matrix of preference scores produces a to- tal that selects the preferred interpretation of the text, even where the system has failecl to produce a complete parse. The role preference shown in Figure 2 is a measure of how well the filler fills a role. This is where the equivalent of selectional restrictions, and most domain knowledge, comes into play. For example, foods make good fillers for the patient of eating activities. Such preferences can be expressed even at the level of individual senses; for example, pibot is a good filler for the agent role of flying activities. The rel preference measures the salience of a role with respect to the head. For example, concepts such as mon- etary objects and units of measure “expect” to be qual- ified by some quantity. Thus, while the baseline prefer- ence for yard is for an enclosed area, the preferred inter- pretation of ten yards is as a measure. There is no reason why areas shouldn’t be modified by quantities, but the role is much more salient for measures. The base preference associates the filler with the head, independent of the particular role. For example, employ- ment actions and professions tend to be related, regard- less of roles. Thus art employmcni would typically mean the hiring of people in the art, profession, rather than the use of works of art (or any of the other poor sense combinations). Distinguishing this sort of preference is necessary because the language very often provides little information about the conceptual role. In the example shown in Figure 2, the sentence in- cludes a free infinitive adjunct to be acquired...-a com- mon sort of interpretation problem because the normal syntactic preferences would be to try to attach the phrase starting with the rightmost, “node” (agreement). The role target is salient, and a company makes a good filler for the role, so both role and reI preferences are very high in the relation shown. The system thus favors any parse tl1a.t will include t,his relation, and will attempt to retain the relation even if the parser fails. The rela.tion-driven cont5rol triangle supports fault tol- erance, because strong preferences coming from any part of t’his dat’a struct’ure can determine the remaining por- tions. For example, a strong base preference often guides a.ttachment decisions even in t,he a.bsence of role prefer- ences. Most weights in the system are assigned automatically, either through statistical analysis in the case of colloca- t,ions or by a knowledge-based rule that computes pref- erence scores according to their position in the hierar- chy. Thus a preference for food is automatically assigned a higher weight than a preference for animafe because food is deeper in the hierarchy (i.e. the weight is as- signed a.utomatically; the preference itself is manually coded). This method is reasonably effective because the interpreter is most oft.en comparing one or two combi- nations with preferences to a great many combinations with no preferences or nega.tive preferences (violated re- strictions). The discussion that, follows gives some more details and examples of the benefits of relation-driven control with respect t,o the corpus- and t,a.sk-driven components Jacobs 317 Pre-processing I Analysis Figure 1: Sta.ges of data extraction of the system. 3.1 Pre-processing Pre-processing helps to segment texts, control the in- terpretation of words in the text, and identify where phrase attachment is necessary. As Figure 1 shows, the relation-driven control strategy depends on key informa- tion that the system obtains prior to parsing, including lexical preferences and other “dynamic” lexical informa- tion, statistical results such as phrase acquisition [Ja- cobs, 1992a], and template activation and other domain- specific segmentation. 2 The following is a sample text taken from the develop- ment corpus of the MUC-3 message understanding eval- uation, with the results of the segmentation component of pre-processing: Original text: SIX PEOPLE WERE KILLED AND FIVE WOUNDED TODAY IN A BOMB AT- TACK THAT DESTROYED A PEASANT HOME IN THE TOWN OF QUINCHIA, ABOUT 300 KM WEST OF BOGOTA, IN THE COFFEE-GROWING DEPARTMENT OF RISARALDA, QUINCHIA MAYOR SAUL BOTERO HAS REPORTED. (41 words) Segmented text: [SIX PEOPLE] [WERE KILLED] AND FIVE [WOUNDED] [TIME: TODAY] [IN A BOMB ATTACK] THAT [DESTROYED] [A PEAS- ANT HOME] [LOCATION: IN THE TOWN 2The identification of segments of texts that activate and fill templates is described in [Jacobs, 19901 318 Natural Language: Parsing OF QUINCHIA] [DISTANCE: *COMMA* ABOUT 300 KM WEST OF BOGOTA] [LO- CATION: *COMMA* IN THE COFFEE *HY- PHEN* GROWING DEPARTMENT OF RIS- ARALDA] [SOURCE: *COMMA* QUINCHIA MAYOR SAUL BOTERO HAS REPORTED] *PERIOD* The task in processing these examples is to fill, for each news story, a set of possible templates, each cont,aining 18 fields indicating t.he t,ype of event, perpetrator(s), vic- tim(s), etc. By grouping and labeling portions of text early, the program greatly reduces the amount of real parsing that must be done, eliminates many failed parses, and pro- vides template-filling information that helps with later processing. For example, the phrase in ihe town of Quinchia is at least five ways ambiguous-it could mod- ify a peasant h.ome, destroyed, a bomb attack, wounded, or were killed and jive [were] wounded. However, all five of these possibilities have the same effect on the final templates produced, so the program can defer any deci- sions about how to parse these phrases until after it has determined that the killing, wounding, at#tacking, and destruction are all part’ of the same event. Since these choices combine with the anlbiguity of other phrases, the parsing process would otherwise be needlessly combina- toric. In fact, parsing cont8ributes nothing after a peasant home, so this sentence can be processed as a l&word ex- ample with some extra modifiers. In addition to reducing the combinatorics of modi- fier attachment, this pre-processing helps in resolving false ambiguities that are a matter of style in this sort of text. In this example, the ellipsis in five [were] ,wounded would be difficult, except that, wounded, like many tran- sitive verbs, is never used as an active verb wit,hout a di- rel preference; How much does “acquire” want a TARGET? role preference: How well does “Burndy Corp. ” fit the TARGET role? is there a lexical relation between “‘Burndy” and “acquired”? Norwalk, Conn. -DJ- We Figure 2: Relations and semant8ic preferences rect object. The early bracketing of the text allows the parser, through the relation-driven control module, to resolve the common past participle-past tense ambigui- ties without having to wait for a complete verb phrase. 3.2 Domain-driven processing The integration of domain-driven analysis and linguistic analysis is probably the hardest and most critical prob- lem for data extraction systems, as explained in [Rau and Jacobs, 19883 and [Passonneau et al., 19901. With relation-driven control, the system looks for linguistic re- lations in the text that affect template filling whether or not it succeeds in producing a complete parse, and avoids relations that do not influence template filling. The seg- mentation of the text during pre-processing guides this process. Relation-driven control uses the template acti- vators, typically verbs, as “pivots”, and looks for rela- tions (such as subject-verb and verb-object) that might include each pivot. These attachments do not wait for a complete parse, so this method is more robust, and favors attachments that are valid in the domain. Relation-driven control depends on having a rough structure of the events of the text prior to parsing. This is realistic in most domains we have dealt with, including the terrorism stories, where death and destruction are subsidiary to attacks and bombings. 3 The event struc- ture determines what roles must be filled linguistically, avoiding attachment of shared roles (such as instrument, time and location) and favoring the attachment of valid roles. In this example, the program produces the templat,es in Figure 3. 31n corporate mergers and acquisitions [Jacobs and Rau, 199Oa], rumors, offers, and stock moves are subsidiary takeover events. This section has addressed the principal issues in fo- cusing parsing to resolve the coverage and at,tachment problems described in Section 2. The next section will present some preliminary result,s from this broad-scale effort,. 4 System evaluation and status In earlier project’s, such as SCISOR [.Ja.cobs and Rau, 199Oa] and other efforts involving the GE NLToolset [Jacobs and Rau, 199Ob], our programs produced accu- racy of over 80% in data extract,ion from texts in lim- ited domains (for example, get,ting an average of 80% of the suitors correct in stories about mergers and ac- quisitions) and have compared very favora.bly to other systems in evaluat,ions on a. common task. The system was in t,he t’op group in every measure in t,he MUC- 3 evaluation [Krupka ef nl., 1991a; Lehnert and Sund- heim, 19911 ( 1 ’ 1 w 11~ 1 uses a much harsher scoring method), while producing half a.s many templates as most of the otther top systems. The program increased in processing speed over a two-year interval by a fa.ctor of 12, to over 1000 words/minute. Most importantly, the techniques described here helped achieve accuracy in MUC-3 com- parable to the MUCK-II evaluation two years earlier, although an analysis showed MUC-3 at least an order of magnitude broader [Hirschman, 19911 along several dimensions. Having been t,ested in an early version in MUC-3, the relation-driven cont.rol stra.tegy is a major component of the GE-CMU team’s technical strategy in the DARPA TIPSTER-Dat’a Extraction project. Interestingly, this strategy is the closest to traditional parsing of all the TIPSTER teams, with other groups relying more heav- ily on met~hods such as probabilistic parsing and phrase- based domain-driven analysis. One of the major moti- Jacobs 319 P* MESSAGE ID l TEMPLATE ID 3: DATE OF INCIDENT TYPE OF INCIDENT :* CATEGORY OF INCIDENT . PERPETRATOR: ID OF INDIV(S) i: PERPETRATOR: ID OF ORG(S) PERPETRATOR: CONFIDENCE 9: PHYSICAL TARGET: ID(S) PHYSICAL TARGET: TOTAL NUM 10. PHYSICAL TARGET: TYPE(S) 11. HUMAN TARGET: ID(S) 12. HUMAN TARGET: TOTAL NUM 13. HUMAN TARGET: TYPE(S) ' 14. TARGET: FOREIGN NATION(S) 15. INSTRUMENT: TYPE(S) 16. LOCATION OF INCIDENT 17. EFFECT ON PHYSICAL TARGET(S) 18. EFFECT ON HUMAN TARGET(S) 16. - . HUMAN TARGET: ID(S) HUMAN TARGET: TOTAL NUM HUMAN TARGET: TYPE(S) TARGET: FOREIGN NA'iIilNW INSTRUMENT: TYPE(S) LOCATION OF INCIDENT 17. EFFECT ON PHYSICAL TARGET(S) 18. EFFECT ON HUMAN TARGET(S) 1)EV-MUC3-0644 67 NOV 89 BOMBING TERRORISM :PEASANT HOME" ATHER "PEOPLE" %ILIAN ZOLDMBIA: QUINCHIA (CITY): RISARALDA (DEPARTMENT) SOME DAMAGE DEATH INJURY EEV-MUC3-0644 (GE) 87 NOV 89 MURDER TERRORISM * * "PEOPLE" &vILIAN BOMB COLOMBIA: QUINCHIA (CITY): RISARALDA (DEPARTMENT) * * Figure 3: Results of Data. Extraction vations for the emphasis on control strategy in the GE- CMU team has been to take advantage of the established framework of the CMU Generalized LR Parser within the context of GE’s text processing system. This project is barely underway; however, the system has already pro- cessed its first message set after the integration of the CMU parser with a GE grammar and pre-processor. The combination of systems of this scope in linguistic analysis is, to our knowledge, unprecedented, and illustrates the growing importance of control strategies for combining different analysis technologies. 5 Conclusion The relation-driven control strategy directs linguistic processing toward identifying and disambiguating rela- tions centering on relevant portions of text, instead of on completing and attaching syntactic constituents. This strategy eliminates much of the needless combinatorics of parsing without ignoring the syntactic constraints and preferences that affect semantic results. This ongoing work has produced an efficient parser with broad cover- age that has been applied to large quantities of real text, with some promising results in word sense discrimination and data extraction. References [Church et al., 19891 I<. Church, W. Gale, P. Hanks, and D. Hindle. Parsing, word associations, and predicate- a.rgument relations. Iii Proceedings of ihe Iiltern.a- tional Workshop 011 Parsing Technologies. Carnegie Mellon University, 1989. [Frazier and Fodor, 19781 L. Frazier and J . D. Fodor. The sausage machine: A new two-stage parsing model. Cognition., 6:291-325, 1978. [Hayes et al., 19883 Phil Hayes, Laura Knecht, and Monica Cellio. A news story ca.tlegorization system. In Proceedings of Second Conference on Applied Nat- ural Language Processing, Austin, TX, February 1988. Associa$ion for Comput8a.tional Linguistics. Hirschman, 199 l] L. Hirschman. Comparing muck-ii and muc-3: Notes on evaluating the difficulty of differ- ent tasks. In Proceedings of fhe Third Message Under- standing Colzference (MrJC-.9), San Ma.teo, <‘A, May 1991. Morgan I<aufma.nn Publishers. Jacobs and Rau, 199Oa] Paul Jacobs and Lisa Rau. SCISOR: Extracting information from on-line news. C~onlllzllnicntiolzs of th,e Associniion for c‘on7puting Machinery, 33( 11):88-97, November 1990. 320 Natural Language: Parsing [Jacobs and Rau, 1990b] Paul S. Jacobs and Lisa F. Rau . The GE NLToolset: A software foundation for intelligent text processing. In Proceedings of the Thirteenth International Conference on Computa- tional Linguistics, volume 3, pages 373-377, Helsinki, Finland, 1990. [Jacobs et al., 19901 Paul S. Jacobs, George R. Krupka, Susan W. McRoy, Lisa F. Rau, Norman K. Sond- heimer, and Uri Zernik. Generic text processing: A progress report. In Proceedings of the Third DA RPA Speech and Natural Language Workshop, Somerset, PA, June 1990. Morgan Kaufmann. [Jacobs, 19901 Paul Jacobs. To parse or not to parse: Relation-driven text skimming. In Proceedings of the Thirteenth International Conference on Gomputa- tional Linguistics, pages 194-198, Helsinki, Finland, 1990. [Jacobs, 1992a] Paul S. J acobs. Acquiring phrases sta- tistically. In Proceedings of the 30th Annual Meet- ing of the Association for Computational Linguistics, Newark, Delaware, 1992. Submitted. [Jacobs, 1992b] Paul S. Jacobs. Joining statistics with NLP for text categorization. In Proceedings of the 3rd Conference on Applied Natural Language Processing, April 1992. [Jacobs, 1992c] Paul S. Jacobs. TRUMP: A trans- portable language understanding program. Interna- tional Journal of Intelligent Systems, 7(3):245-276, 1992. [Krupka et al., 1991a] George R. Krupka, Lucja Iwariska, Paul S. Jacobs, and Lisa F. Rau. GE NLToolset: Muc-3 test results and analysis. In Proceedings of the Third Message Un- derstanding Conference (Muc-3), San Mateo, Ca, May 1991. Morgan Kaufmann Publishers. [Krupka et al., 1991b] George R. Krupka, Paul S. Ja- cobs, Lisa F. Rau, and Lucja Iwaliska. Description of the GE NLToolset system as used for Muc-3. In Proceedings of the Third Message Understanding Con- ference (Muc-31, San Mateo, Ca, May 1991. Morgan Kaufmann Publishers. [Lehnert and Sundheim, 19911 Wendy G. Lehnert and Beth M. Sundheim. A performance evaluation of text analysis technologies. Artificial In.telligence Magazine, 12(3):81-94, Fall 1991. [Passonneau et al., 19901 R. Passonneau, C. Weir, T. Finin, and M. Palmer. Integrating natural language processing and knowledge based processing. In Proceedings of the Eighth National Conference on Artificial Intelligence, pages 976-983, Boston, 1990. [Rau and Jacobs, 19SS] Lisa F. Rau and Paul S. Ja- cobs. Integrating top-down and bottom-up strategies in a text processing system. In Proceedings of Second Conference on Applied Natural Language Processing, pages 129-135, Austin, TX, Feb 1988. ACL. [Schubert, 19861 L. Schubert. Are there preference trade-offs in attachment decisions? In Proceedings of the Fifth National Conference On Artificial Intelli- gence, 1986. [Sharman et al., 19901 R. Sharman, F. Jellinek, and R. Mercer. Generating a grammar for statistical train- ing. In Darpa Speech and Nafural Language Workshop, Hidden Valley, Pa, 1990. [Sundheim, 19891 Beth Sundheim. Second message un- derstanding (MUCK-II) report. Technical Report 1328, Naval Ocean Systems Center, San Diego, Ca, 1989. [Sundheim, 19911 Beth Sundheim, editor. Proceedings of the Third Message Understanding Conference (Muc- 3). Morgan Kaufmann Publishers, San Mateo, Ca, May 1991. [Tomita, 19861 M. T omita. Eficient Parsing for Natu- ral Language. Kluwer Academic Publishers, Hingham, Massachusetts, 1986. Jacobs 321 | 1992 | 60 |
1,255 | A Probabilistic Parser pplied to Software sting Documents Mark A. Jones AT&T Bell Laboratories 600 Mountain Avenue, Rm. 2B-435 Murray Hill, NJ 07974-0636 jones&esearch.att .com Abstract We describe an approach to training a statisti- cal parser from a bracketed corpus, and demon- strate its use in a software testing application that translates English specifications into an au- tomated testing language. A grammar is not ex- plicitly specified; the rules and contextual proba- bilities of occurrence are automatically generated from the corpus. The parser is extremely success- ful at producing and identifying the correct parse, and nearly deterministic in the number of parses that it produces. To compensate for undertrain- ing, the parser also uses general, linguistic sub- theories which aid in guessing some types of novel structures. Introduction In constrained domains, natural language processing can often provide leverage. In software testing at AT&T, for example, 20,000 English test cases prescribe the behavior of a telephone switching system. A test case consists of about a dozen sentences describing the goal of the test, the actions to perform, and the con- ditions to verify. Figure 1 shows part of a simple test case. Current practice is to execute the tests by hand, or else hand-translate them into a low-level, executable language for automatic testing. Coding the tests in the executable language is tedious and error-prone, and the English versions must be maintained anyway for read- ability. We have constructed a system called KITSS (Knowledge-Based Interactive Test Script System), which can be viewed as a system for machine-assisted translation from English to code. Both the English test cases and the executable target language are part of a pre-existing testing environment that KITSS must fit into. The basic structure of the system is given in Figure 2. English test cases undergo a series of trans- lation steps, some of which are interactively guided by a tester. The completeness and interaction analyzer is the pragmatic component that understands the basic ax- 322 Natural Language: Parsing Jason M. Eisner Emmanuel College, Cambridge Cambridge CB2 3AP England jmel4Qphoenix.cambridge.ac.uk GOAL: Activate CFA [call forwarding] using CFA Acti- vation Access Code. ACTION: Set station B2 without redirect notification. Station B2 goes offhook and dials CFA Activation Access Code. VERIFY: Station B2 receives the second dial tone. ACTION: Station B2 dials the extension of station B3. VERIFY: Station B2 receives confirmation tone. The status lamp associated with the CFA button at B2 is lit. VERIFY: . . . Figure 1: An Example Test Case ioms and conventions of telephony. Its task is to flesh out the test description provided by the English sen- tences. This is challenging because the sentences omit many implicit conditions and actions. In addition, some sentences ( “Make Bl busy”) require the analyzer to create simple plans. The analyzer produces a formal description of the test, which the back-end translator then renders as executable code. A more complete de- scription of the goals of the system, its architecture and the software testing problem can be found in [Nonnen- mann and Eddy 19921. This paper discusses the natural language processor or linguistic component, which must extract at least the surface content of a highly referential, naturally occurring text. The sentences vary in length, ranging from short sentences such as “Station B3 goes onhook” to 50 word sentences containing parentheticals, subor- dinate clauses, and conjunction. The principal leverage is that the discourse is reasonably well focused: a large, but finite, number of telephonic concepts enter into a finite set of relationships. socessing in The KITSS linguistic component uses three types of knowledge to translate English sentences quickly and accurately into a logical form: From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Transformation Figure 2: KITSS Architecture syntactic: empirical statistics about common con- structions semantic: empirical statistics about common con- cepts referential: expert knowledge about the logical rep- resentation of concepts Figure 3 illustrates the syntactic, semantic, and logical representations computed for one analysis of the sentence “Place a call from station Bl to station B2.” We will not say much here about the referen- tial knowledge that finally rewrites the surface seman- tic representation as temporal logic. KITSS currently uses a hand-coded production system that includes linguistic rules (e.g., active-passive and conjunction), discourse rules (e.g., definite reference), and domain- specific canonicalization rules. An undirected parser would generate many alterna- tive (incorrect) hypotheses regarding the structure and interpretation of the sentence in Figure 3. It might try attaching the prepositional phrases to the noun phrase “a call,” or treating “to station B2” as an in- finitive phrase. In designing a parsing technique for the KITSS system, we wanted to exploit the statisti- cal regularities that make one interpretation far like- lier than others. In line with our earlier success on statistical error-correction for optical character recog- nizers (OCR devices) [Jones et al 19911, we sought ways to “bootstrap” the acquisition of statistical do- main knowledge- in this case, knowledge about the likelihood of syntactic and semantic substructures in the test case sentences. Note that initially we may have only a corpus of raw sentences, not a corpus of their target syntactic and semantic structures. While it is impractical to hand- analyze a large portion of the corpus, it is possible to do a relatively small number of sentences by hand, to get started, and then to use the parser itself as a tool to suggest analyses (or partial analyses) for further sen- tences. A similar approach to training is found in [Sim- mons 19911. We will assume below that we have access to a training set of syntactic and semantic structures.l ssues in robabilistic Parsing To generalize from the training corpus to new sen- tences, we will need to induce a good statistical model of the language. But the statistical distributions in a natural language reflect a great many factors, some of them at odds with each other in unexpected ways. Chomsky’s famous sentence, “Colorless green ideas sleep furiously,” is syntactically quite reasonable-but semantic nonsense-but, for historical reasons, quite common in conference papers. Or consider the classic illustration of attachment ambiguity: “I saw a man in the park with a telescope.” One interpretation of this sentence holds that I used a telescope to see a man. To judge the relative likelihood, we may want to know how often telescopes are used for “seeing” (vs. “sawing”); how often a verb takes two prepositional phrases; who is most likely to have a telescope (me, the man, or the park); and so on. Thus many features of a sentence may be signifi- cant. Within a restricted domain such as KITSS, the distributions are further shaped by the domain subject matter and by stylistic conventions. Sentences such as ‘Station B3 goes onhook” may be rare in the newspa- per but common in the KITSS application. For sta- tions to “go” is a test script idiom. We want our statistics to capture more than the syn- tactic correlations. Our strategy is to build up rich in- terpretations of the sentences as we are parsing them. We take care to interpret every subtree that we gener- ate. Thus, when we are deciding whether to combine two subtrees later on, we will know what the subtrees “mean .” Furthermore, we will have semantic readings for other, possibly relevant portions of the sentence. The semantic information helps to expose deep sim- ilarities and deep differences among sentences. Two trees that are semantically similar are likely to com- bine in similar ways. With semantic interpretations, we directly represent the fact that in one hypothesis the telescope is used for seeing. This fact is obscured in the corresponding syntactic tree-and even more so in the original sentence, where “saw” and “telescope” appear far apart. Formally, let Sz be a given space of possible inter- pretations. We model a phrase structure rule, L” + lIn KITSS, only the syntactic bracketing is ever fully manual. The system automatically constructs a semantics for each training example from its syntax, using a set of translation rules. Most of these rules are inferred from a default theory of syntactic-semantic type correspondences. Jones and Eisner 323 String: Place a call from station Bl to station B2 . Syntax: (SP (S (VP (VP (VP (VB "Place") (NP (AT "a") (NN "call"))) (PP (IN "from") (NP (NN "station") (NPR "Bl")))) (PP (IN tttott) (NP (NN "station") (NPR "B2"))))) (\. 'I.")) Semantics: (PLACE (:OBJECT (CALL (:NUMBER SING) (:REF A))) (:FROM (STATION (:NUMBER SING) (:NAME "Bl")>> (:TO (STATION (:NUMBER SING) (:NAME "B2"))) (:MOOD DECL) . ..I Logic: ((OCCURS (PLACES-CALL Bl B2 CALL-812))) Figure 3: Representations Formed in Processing a Sentence RI R2 . . . &, as an m-ary function taking values in s2. RI . . . & give type restrictions on the m arguments. The function describes how to build an interpretation of type L from m contiguous substring interpretations of types Rl...R,. The rule number Ic distinguishes rules that have the same domain and range, but dif- fer functionally (e.g., in the case of a noun with two meanings); the chart maintains distinct hypotheses for the alternative interpretations. In practice, our R consists of joint syntactic-semantic interpretations. The syntactic half of an interpretation is simply the parse tree. The semantic half is built compositionallyfromlexically-derived heads, slots and fillers in a standard frame language, as illustrated in Figure 3. Experiments confirm the value of this approach for statistical parsing. When we run our parser with se- mantics turned off, its syntactic accuracy rate drops from 99% to 66%, and it runs far more slowly. The KITSS Algorithm The KITSS parsing algorithm (given as Algorithm 1 in Appendix A) is a variant of tabular or chart pars- ing methods for context-free languages [Cocke and Schwartz 1970; Earley 1970; Graham et al 19801. It scans the sentence from left to right, assembling possi- ble partial interpretations of the sentence; but it con- tinually discards interpretations that are statistically unlikely. The grammar rules and statistics are generated au- tomatically by training on a bracketed corpus. The grammar is taken to be the smallest set of symbols and rules needed to write down all the parse trees in the corpus. The statistics are context-sensitive; they concern the frequencies with which the interpreted sub- trees co-occur. Incremental training is permitted. The model is that the system considers a new sample sen- tence, updates its database, and throws the sentence away. A grammar is given by G = (V, C, P, S), where V is the vocabulary of all symbols, C is the set of terminal symbols, P is the set of rules, and S is the start symbol. The start symbol is restricted to be non-recursive. A distinguished start symbol (e.g., ROOT) can be added 324 Natural Language: Parsing to the grammar if necessary. For an input sentence w= ala2.. . +,I (ai E C), let wi,j denote the substring ai+l . ..CLj. For example, 200,s denotes the first three words. The algorithm operates bottom-up from left to right in the input string. At each point j in the input string, the algorithm constructs hypotheses about the imme- diately preceding substrings wi,j. A complete hypoth- esis is a parse tree for some substring of the sentence; we write it as [L r1 r2 . . . rm], where L -+ R1 R2 . . . R, is a rule in P and each subtree ri is itself a complete hypothesis with root Ri. An incomplete hypothesis is similar, except it is missing one or more of its rightmost branches. We write it as [L rl r2 . . . rp +], 0 5 q < m. We use the notation hi,j to refer to a hypothesis that dominates the string wi,j. If a hypothesis hi,j is judged to be likely, it is added to a set ti,j in a ([WI + 1) x ([WI + 1) chart t. “Empty” hypotheses, which are created directly from the grammar, have the form [L +]. “Input” hy- potheses just assert the existence of ai and are com- plete; these are usually assigned probability 1, but nor- malized sets of input hypotheses could be used in noisy recognition environments such as speech or OCR. Longer hypotheses are created by the @ operator, which attaches a new child to a tree. The 8 product of two hypotheses is the smallest set respecting the condition that whenever 1 h i,j = [L Pi . . . rq +], hj,k = rq+l, and (L--+R1...RqRq+l...R,)~P then { 1: f: ’ ’ . rq rq+l t-3 E (hi,j CZJ hj,k) if Q + 1 < m . . . r,] E (h,j 8 hj,tc) ifq+l=m Note that @ returns a set of 0, 1, or 2 hypotheses. The first argument of @ is ordinarily an incomplete hypothesis, while the second is a complete hypothe- sis immediately to its right. Otherwise @ returns the empty set. The operator can easily be extended to act on sets and charts: &@R:=U{h@h’ 1 h@, h’eR} t @ R I= (IJti,j) @ R The algorithm returns the set of complete hypotheses in to,lwl whose roots are S, the start symbol. Each of these parses has an associated probability. V = {VP, V, “Place”, NP, Det, “a”, N, “call”. . .} c = { “Place”, “a”, “call”. . .} P = {VP + V NP, NP --f Det N, V -+ “PZace”, Det --+ “a”, N + ‘%all”. . .} s = VP /vp\ / / iNP\ V Det N I I I “Place” Ua” ,tcall” Figure 4: A Parse Tree for w = “Place” “u” “cald” During the parsing process, a left-context probability or LCP, Pr(ha,j 1 WO,~), is used to prune sets of com- peting hypotheses. Pruning severity depends on the beam width, 0 < E <_ 1. A beam width of 10m2 keeps only those alternative hypotheses that are judged at least 1% as likely as the leading contender in the set. The correct parse can survive only if all of its con- stituent hypotheses meet this criterion; thus E opera- tionally determines the set of garden path sentences for the parser. If any correct hypothesis is pruned, then the correct parse will not be found (indeed, perhaps no parse will be found). This can happen in garden path sentences. It may also happen if the statistical database provides of the language. an inadequate or incomplete model Probability Calculations The parsing algorithm keeps or discards a hypothe- sis according to the left-context probability Pr(ha.; 1 wo,j). The more accurate this value, the better we will do at pruning the search space. How can we compute it without assuming context-freeness? We are able to decompose the probability into a product of corpus statistics (which we look up in a fixed hash table) and the LCPs of other hypotheses (which we computed earlier in the parse). Space pre- vents us from giving the formal derivation. Instead we will work through part of an example. Figure 4 gives a small grammar fragment, with a possible parse tree for a short sentence. For conve- nience, we will name various trees and subtrees as fol- lows: place = “Place”o,l a = “a ” 1 ,2 call = “call”~,s de: = [I/ “Place”]o,l = [Det “u”]l,2 n = [N “cab1”]2,3 nP1 = [NP [Det “a”] +]1,2 nP = [NP [Det “a”] [IV “call”]]l,~ VP1 = [VP [V “Place”] +]o,l vp = [ VP [V “Place “I [NP [Det “u”] [N %z11”]]]0,~ These trees correspond to the hypotheses of the pre- vious section. Note carefully that-for example-the tree vp E vpl @ np is correct if and only if the trees vp’ and np are also correct. We will use this fact soon. Left-Context Probabilities We begin with some remarks about Pr(np 1 wo,~), the LCP that np is the correct interpretation of ~1,s. This probability depends on the first word of the sentence, wo,r, and in particular on the interpretation of wo,r. (For example: if the statistics suggest that “Place” is a noun rather than a verb, the np hypothesis may be unlikely.) The correct computation is Pr(w 1 w0,3) = Pr(d&v I w0,3) (1) + Pr(X&w I w0,3) + Pr(Y& np I w0,3)+ . . . where vpl,X, Y,... are a set of (mutually exclusive) possible explanations for “Place.” The summands in equation 1 are typical terms in our derivation. They are LCPs for chains of one or more contiguous hypothe- ses. Now let us skip ahead to the end of the sentence, when the parser has finished building the complete tree vp. We decompose this tree’s LCP as follows: WP I wo,3) = Pr(vp& vpl& np I w0,3) (2) = Pr(vp I vpl&np&wo,3) - Pr(+Q np I w0,3) The first factor is the likelihood that vp” and np, if they are in fact correct, will combine to make the big- ger tree vp E vpl @ np. We approximate it empirically, as discussed in the next section. As for the second factor, the parser has already found it! It appeared as one of the summands in (l), which the parser used to find the LCP of np. It de- composes as Pr(vpl&v I w0,3) (3) = Pr(vpl&np&np’&n 1 wo,3) = Pr(np I vp1&np1&n&wo,3) .Pr(vpl& npl& n I wo,3) The situation is exactly as before. We estimate the first factor empirically, and we have already found the second as Pr(vp’& npl& n I wo,3) = Pr(vpl& np'&n&call I wo,3) = Pr(n I vpl& np'& call&wo,3) ePr(vpl& npl& call I wo,3) (4) Jones and Eisner 325 At this point the recursion bottoms out, since call cannot be decomposed further. To find the second fac- tor we invoke Bayes’ theorem: Pr(vpl & npl & call I wo,3) (5) = Pr(vpl & npl & cadl I ~10,s & call) ’ = Pr(vpl & npl I ~10,s & call) Pr( call 1 vpl & npl & ~0.2) . Pr(vpl & npl 1 ~10,~) - CX PrWl I X & w0,2) - Pr(X 1 ~42) The sum in the denominator is over all chains X, in- cluding vpl & np ‘, that compete with each other to ex- plain the input we,2 = “Place a”. Note that for each X, the LCP of X & call will have the same denomina- tor. In both the numerator and the denominator, the first factor is again estimated from corpus statistics. And again, the second factor has already been computed. For example, Pr(vp’ & np’ I WOJ) is a summand in the LCP for np’. Note that thanks to the Bayesian procedure, this is indeed a left-context probability: it does not depend on the word “call,” which falls to the right of npl . Corpus Statistics The recursive LCP computation does nothing but mul- tiply together some empirical numbers. Where do these numbers come from ? How does one estimate a value like Pr(up I vp’ & np & WO,~)? The condition ~10,s is redundant, since the words also appear as the leaves of the chain vp’ & np . So the ex- pression simplifies to Pr(vp I vp’ & np). This is the probability that, if vpl and np are correct in an ar- bitrary sentence, vp is also correct. (Consistent alter- natives to vp = [VP v np] might include [ VP v np pp] and [VP v [NP np pp]], where pp is some prepositional phrase.) In theory, one could find this value directly from the bracketed corpus: (a) In the 3 bracketed training sentences (say) where l A = [VP [V “Place”] +]o,r appears 0 B = [NP [Det “u”] [N ‘bd~“]]l,3 appears in what fraction does [VP [V “Place”] [NP [Det “u”] [IV “cuU”]]]0,3 appear? However, such a question is too specific to be practical: 3 sentences is uncomfortably close to 0. To ensure that our samples are large enough, we broaden our question. We might ask instead: (b) Among the 250 training sentences with o A= [VP [V...]+]i,i e B = [NP . . .]j,k (some i < j < rE) in what fraction is B the second child of A? Alternatively, and ask we might take a more semantic approach (c) Among the 20 training sentences with Q A= a subtree from i to j @B = a subtree from j to rE o A has semantic interpretation A’ = (V-PLACE . . . > e B has semantic interpretation B’ = (n-CALL . . . ) in what fraction does B’ fill the OBJECT role of A’? Questions (b) and (c) both consider more sentences than (a). (b) considers a wide selection of sentences like “The operator activates CFA . . . .” (c) confines itself to sentences like “The operator places two priority calls 9) . . . . As a practical matter, an estimate of Pr(vp I vpl & np) should probably consider some syntactic and some semantic information about vp 1 and np . Our cur- rent approach is essentially to combine questions (b) and (c). That is, we focus our attention on corpus sentences that satisfy the conditions of both questions simultaneously. Limiting Chain Length The previous sections refer to many long chains of hy- potheses: Pr(vpl & npl & call I wo,3) Pr(n I vpl & npl & wo,3) In point of fact, every chain we have built extends back to the start of the sentence. But this is unacceptable: it means that parsing time and space grow exponentially with the length of the sentence. Research in probabilistic parsing often avoids this problem by assuming a stochastic context-free lan- guage (SCFG). In this case, Pr(vpl & npl & call I wo,3) = Pr( VP1 1 wO,l) ’ Pr(d 1 w1,2) - Pr( cd 1 w2,3) and Pr(n I vpl & npl & wo,3) = Pr( n I w2,3). This assumption would greatly condense our compu- tation and our statistical database. Unfortunately, for natural languages SCFGs are a poor model. Follow- ing the derivation S =+* John solved the N, the prob- ability of applying rule {N + fish} is approximately zero-though it may be quite likely in other contexts. But one-may limit the length of chains less dras- tically, by making weaker independence assumptions. With appropriate modifications to the formulas, it is possible to arrange that chain length never exceeds some constant L 2 1 . Setting L = 1 yields the context- free case. Our parser refines this idea one step further: within the bound L, chain length varies dynamically. For in- stance, suppose L = 3. In the parse tree [ VP [ V “Place “I [NP [Det “u”] [Adj “priority”] [N “m/Y’]]], 326 Natural Language: Parsing we do compute an LCP for the entire chain vp’ & np2 & n, but the chain vp’ & npl & udj is consid- ered “too long.” Why? The parser sees that udj will be buried two levels deep in both the syntactic and semantic trees for vp. It concludes that Pr(adj I vp’ & np’) R Pr( udj I np’), and uses this heuristic assumption to save work in sev- eral places. In general we may speak of high-focus and low-focus parsing. The focus achieved during a parse is defined as the ratio of useful work to total work. Thus a high-focus parser is one that prunes aggressively: it does not allow incorrect hypotheses to proliferate. A completely deterministic parser would have 100% fo- cus. Non-probabilistic parsers typically have low focus when applied to natural languages. Our parsing algorithm allows us to choose between high- and low-focus strategies. To achieve high focus, we need a high value of E (aggressive pruning) and ac- curate probabilities. This will prevent a combinatorial explosion. To the extent that accurate probabilities re- quire long chains and complicated formulas, the useful work of the parser will take more time. On the other hand, a greater proportion of the work will be useful. In practice, we find that even L = 2 yields good focus in the KITSS domain. Although the L = 2 prob- abilities undoubtedly sacrifice some degree of accuracy, they still allow us to prune most incorrect hypotheses. Related issues of modularity and local nondetermin- ism are also discussed in the psycholinguistic literature (e.g., [Tanenhaus et al 19851). Incomplete Knowledge Natural language systems tend to be plagued by the potential open-endedness of the knowledge required for understanding. Incompleteness is a problem even for fully hand-coded systems. The correlate for statistical schemes is the problem of undertraining. In our task, for example, we do not have a large sample of syn- tactic and semantic bracketings. To compensate, the parser utilizes hand-coded knowledge as well as statis- tical knowledge. The hand-coded knowledge expresses general knowledge about linguistic subtheories such as part of speech rules or coordination. As an example, consider the problem of assign- ing parts of speech to novel words. Several sources of knowledge may suggest the correct part of speech class-e.g., the left-context of the the novel word, the relative openness or closedness of the classes, morpho- logical evidence from affixation, and orthographic con- ventions such as capitalization. The parser combines the various forms of evidence (using a simplified rep- resentation of the probability density functions) to as- sign a priori probabilities to novel part of speech rules. Using this technique, the parser takes a novel sen- tence such as “XX YY goes ZZ,” and derives syntactic and semantic representations analogous to “Station Bl goes offhook.” The current system invokes these ad hoc knowledge sources when it fails to find suitable alternatives using its empirical knowledge. Clearly, there could be a more continuous strategy. Eventually, we would like to see very general linguistic principles (e.g., metarules and x theory [Jackendoff 19771) and powerful informants such as world knowledge provide a priori biases that would allow the parser to guess genuinely novel structures. Ultimately, this knowledge may serve as an inductive bias for a completely bootstrapping, learning version of the system. esults and Summary The KITSS system is implemented in Franz Com- mon Lisp running on Sun workstations. The system as a whole has now produced code for more than 70 complete test cases containing hundreds of sentences. The parsing component was trained and evaluated on a bracketed corpus of 429 sentences from 40 test cases. The bracketings use part of speech tags from the Brown Corpus [Francis and Kucera 19821 and tra- ditional phrase structure labels (S, NP, etc.). Because adjunction rules such as VP + VP PP are common, the trees tend to be deep (9 levels on average). The bracketed corpus contains 308 distinct lexical items which participate in 355 part of speech rules. There are 55 distinct nonterminal labels, including 35 parts of speech. There are a total of 13,262 constituent de- cisions represented in the corpus. We have studied the accuracy of the parser in using its statistics to reparse the training sentences correctly. Generally, we run the experiments using an adaptive beam schedule; progressively wider beam widths are tried (e.g., lo- ‘, 10e2, and 10B3) until a parse is ob- tained. (By comparison, approximately 85% more hy- potheses are generated if the system is run with a fixed beam of 10s3 .) For 62% of th e sentences some parse was first found at E = 10-l, for 32% at 10V2, and for 6% at lo- 3. For only one sentence was no parse found within E = 10 -3. For the other 428 sentences, the parser always recovered the correct parse, and cor- rectly identified it in 423 cases. In the 428 top-ranked parse trees, 99.92% of the bracketing decisions were correct (less than one error in 1000). Significantly, the parser produced only 1.02 parses per sentence. Of the hypotheses that survived pruning and were added to the chart, 68% actually appeared as parts of the final parse. We have also done a limited number of randomized split-corpus studies to evaluate the parser’s general- ization ability. After several hundred sentences in the telephony domain, however, the vocabulary continues to grow and new structural rules are also occasionally needed. We have conducted a small-scale test that ensured that the test sentences were novel but gram- matical under the known rules. With 211 sentences for training and 147 for testing, parses were found for 77% of the test sentences: of these, the top-ranked Jones and Eisner 327 parse was correct 90% of the time, and 99.3% of the bracketing decisions were correct. Using 256 sentences for training and 102 sentences for testing, the parser performed perfectly on the test set. In conclusion, we believe that the KITSS applica- tion demonstrates that it is possible to create a robust natural language processing system that utilizes both distributional knowledge and general linguistic knowl- edge. Acknowledgements Other major contributors to the KITSS system include Van Kelly, Uwe Nonnenmann, Bob Hall, John Eddy, and Lori Alperin Resnick. Appendix A: The KITSS Parsing Algorithm Algorithm 1. PARSE(w): (* create a (Iwl+ 1) x (1~1 + 1) chart t = (ti,j): *) to,0 := {[S +I}; for j := 1 to Iwl do Rl := tj+j := {aj); R2 := 0; while RI # 0 R := PRUNE((t @I RI) u (PREDICT(R1) 8 RI) u R2); RI := R2 := 0; for hi,j E R do ti,j := ti,j U {hi,j}; if h;,j is complete then RI := R1 U {hi,j} else RQ := R2 U {hi,j} endfor endwhile endfor; return { all complete S-hypotheses in to,lwl} Subroutine PREDICT(R): return {[A +] I A + BI . . . B, is in P, some complete &-hypothesis is in R, and A # S} Subroutine PRUNE(R): (* only likely rules are kept *) RI.- . thr&!%i := c * maxhi,jER Pr(hi,j 1 wo,j); for hi,j in R do if Pr(hi,j I wo,j) 2 threshoZd then R’ := R’ U {hi,j} endfor; return R’ References Cocke, J. and Schwartz, J.I. 1970. Programming Lan- guages and Their Compilers. New York: Courant In- stitute of Mathematical Sciences, New York Univer- sity. Earley, J. 1970. An Efficient Context-Free Parsing Al- gorithm. Communications of the ACM 13(2): 94-102. 328 Natural Language: Parsing Francis, W. and Kucera, H. 1982. Frequency Analysis of English Usage. Boston: Houghton Mifflin. Graham, S.L., Harrison, M.A. and RUZZO, W.L. 1980. An Improved Context-Free Recognizer. ACM Transactions on Programming Languages and Sys- tems 2(3):415-463. Jackendoff, R. 1977. x Syntax: A Study of Phrase Structure. Cambridge, MA.: MIT Press. Jones, M.A., Story, G.A., and Ballard, B.W. 1991. Using Multiple Knowledge Sources in a Bayesian OCR Post-Processor. In First International Confer- ence on Document Analysis and Retrieval, 925-933. St. Malo, France: AFCET-IRISA/INRIA. Nonnenmann, U., and Eddy J.K. 1992. KITSS - A Functional Software Testing System Using a Hybrid Domain Model. In Proc. of 8th IEEE Conference on Artificial Intelligence Applications. Monterey, CA: IEEE. Simmons, R. and Yu, Y. 1991. The Acquisition and Application of Context Sensitive Grammar for En- glish. In Proc. of the 29th Annual Meeting of the Association for Computational Linguistics, 122-129. Berkeley, California: Association for Computational Linguistics. Tanenhaus, M.K., Carlson, G.N. and Seidenberg, MS. 1985. Do Listeners Compute Linguistic Repre- sentations? In Natural Language Parsing (eds. D. R. Dowty, L. Karttunen and A.M. Zwicky), 359-408. Cambridge University Press: Cambridge, England. | 1992 | 61 |
1,256 | Classifying Texts Using Relevancy Signatures Ellen Riloff and Wendy Lehnert Department of Computer Science University of Massachusetts Amherst, MA 01003 riloff@cs.umass.edu, lehnert@cs.umass.edu Abstract Text processing for complex domains such as terrorism is complicated by the difficulty of being able to reliably distinguish relevant and irrelevant texts. We have discovered a simple and effective filter, the Relevancy Signatures Algorithm, and demonstrated its performance in the domain of terrorist event descriptions. The Relevancy Signatures Algorithm is based on the natural language processing technique of selective concept extraction, and relies on text representations that reflect predictable patterns of linguistic context. This paper describes text classification experiments conducted in the domain of terrorism using the lVlUC- 3 text corpus. A customized dictionary of about 6,000 words provides the lexical knowledge base needed to discriminate relevant texts, and the CIRCUS sentence analyzer generates relevancy signatures as an effortless side-effect of its normal sentence analysis. Although we suspect that the training base available to us from the MUC-3 corpus may not be large enough to provide optimal training, we were nevertheless able to attain relevancy discriminations for significant levels of recall (ranging from 11% to 47%) with 100% precision in half of our test runs. Text Classification Text classification is central to many information retrieval applications, as well as being relevant to message understanding applications in text analysis. To appreciate the importance and difficulty of this problem, consider the role that it played in the ME-3 (The Third Message Understanding Conference) performance evaluation. Last This research supported by the Office of Naval Research, under a University Research Initiative Grant, Contract #N00014-86-K-0764, NSF Presidential Young Investigators Award NSFIST-835 1863, and the Advanced Research Projects Agency of the Department of Defense monitored by the Air Force Office of Scientific Research under Contract No. F49620-88-C-0058. year 15 text analysis systems attempted to extract information from news articles about terrorism (Lehnert & Sundheim 199 1; Sundheim 199 1). According to an extensive set of domain guidelines, roughly 50% of the texts in the MIX-3 development corpus did not contain legitimate information about terrorist activities. Articles that described rumours or lacked specific details were designated as irrelevant, as well as descriptions of specific events that targetted military personnel and installations (a terrorist event was defined to be one in which civilians or civilian locations were the apparent or accidental targets in an intentional act of violence). In order to achieve high- precision information extraction, the MUC-3 text analyzers had to differentiate relevant and irrelevant texts without human assistance. A system with a high rate of false positives would tend to generate output for irrelevant texts, and this behavior would show up in both the scores for overgeneration and spurious event counts. An analysis of the MUC-3 evaluation suggests that all of the MUC-3 systems experienced significant difficulty with relevant text classification (Krupka et al. 1991). Although some texts will inevitably require in-depth natural language understanding capabilities in order to be correctly classified, we will demonstrate that skimming techniques can be used to identify subsets of a corpus that can be classified with very high levels of precision. Our algorithm automatically derives relevancy signatures from a training corpus using selective concept extraction techniques. These signatures are then used to recognize relevant texts with a high degree of accuracy. Terrorism is a complex domain, especially when it is combined with a complicated set of domain relevancy guidelines. Relevancy judgements in this domain are often difficult even for human readers. Many news articles go beyond the scope of the guidelines or fall into grey areas no matter how carefully the guidelines are constructed. Even so, human readers can reliably identify some subset of relevant texts in the terrorism domain with 100% precision, and often without reading these texts in their entirety. Text skimming techniques are therefore a Riloff and Lehneit 329 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. promising strate H y for text classification as long as lower levels of recall are acceptable. Although it might be unrealistic to try to classify all of the news articles in a corpus with a high degree of precision using anything less than a complete, in-depth natural language processing system, it is realistic to try to identify a subset of texts that can be accurately classified using relatively simple techniques.2 Intuitively, certain phrases seem to be very strong indicators of relevance for the terrorism domain. “X was assassinated” is very likely to be a reference to a terrorist event in which a civilian (politician, government leader, etc.) was killed. “X died” is a much weaker indicator of relevance because people often die in many ways that have nothing to do with terrorism. Linguistic expressions that predict relevance for a domain can be used to recognize and extract relevant texts from a large corpus. Identifying a reliable set of such expressions is an interesting problem and one that is addressed by relevancy feedback algorithms in information retrieval (Salton 1989). Selective Concept Extraction using C Selective concept extraction is a sentence analysis technique that simulates the human ability to skim text and extract information in a selective manner. CIRCUS (Lehnert 1990) is a sentence analyzer designed to perform selective concept extraction in a robust manner. CIRCUS does not presume complete dictionary coverage for a particular domain, and does not rely on the application of a formal grammar for syntactic analysis. CIRCUS was the heart of the text analyzer underlying the UMass/MUC-3 system (Lehnert et al. 1991), and it provided us with the sentence analysis capabilities used in the experiments we are about to describe. 3 The most important dictionary entries for CIRCUS are those that contain a concept node definition. Concept nodes provide the case frames that are used to structure CIRCUS output. If a sentence contains no concept node triggers, CIRCUS will produce no output for that sentence. lRecal1 refers to the percentage of relevant texts that are correctly classified as relevant. Precision is the percentage of texts classified as relevant that actually are relevant. To illustrate the difference, imagine that you answer 3 out of 4 questions correctly on a true-or-false exam. Your recall rate is then 75%. Your precision, however, depends on how many of the questions you actually answered. If you only answered 3 of them, then your precision is 100%. But if you answered all 4 then your precision is only 75%. 2Many information retrieval tasks and message understanding applications are considered to be successful if low levels of recall are attained with high degrees of !2 recision. The UMass/MUC-3 system posted the highest recall score and the highest combined scores for recall and precision of all the MUC-3 text analyzers (Sundheim 1991). One of the research goals stimulated by our participation in MUC-3 was to gain a better understanding of these concept nodes and the vocabulary items associated with them. Our UMass/MUC-3 dictionary was hand-crafted specifically for MUC-3. A preliminary analysis of our MUC-3 dictionary indicated that we had roughly equal numbers of verbs and nouns operating as concept node triggers (131 verbs and 125 nouns). Other parts of speech also acted as concept node triggers, but to a lesser extent than verbs and nouns. Out of roughly 6000 dictionary entries, a total of 286 lexical items were associated with concept node definitions. All concept node definitions contain a set of enablement conditions that must be met before the concept node can be considered valid. For example, if the lexical item “kill” is encountered in a sentence, a case frame associated with that item may be valid only if this instance of “kill” is operating as a verb in the sentence. Expectations for an agent and object will be useful for the verb “to kill” but not for a head noun as in “went in for the kill”. Enablements are typically organized as conjunctions of conditions, and there is no restriction on what types of enablements can be used. The enablement conditions for concept nodes effectively operate as filters that block further analysis when crucial sentence structures are not detected. If a filter is too strong, relevant information may be missed. If a filter is too weak, information may be extracted that is not valid. When sentence analysis fails due to poorly crafted enablement conditions, no other mechanisms can step in to override the consequences of that failure. It is often the case that a single phrase will make a text relevant. For instance, a single reference to a kidnapping anywhere in a text generally signals relevance in the terrorism domain regardless of what else is said in the remainder of the articleP One implication of this fact is that it is not always necessary to analyze an entire text in order to accurately assess relevance. This property makes the technique of selective concept extraction particularly well-suited for text classification tasks. We claim that specific linguistic expressions are reliable indicators of relevance for a particular domain. These expressions must be general enough to have broad applicability but specific enough to be consistently reliable 41n fact, there can be exceptions to any statement of this type. For example, an event that happened over 2 months ago was not considered to be relevant for MUC-3. Our approach assumes that these special cases are relatively infrequent and that key phrases can indicate relevance most of the time. Our technique will therefore produce weaker results under relevancy guidelines that detail special cases and exceptions if those conditions appear frequently in the target texts. 330 Natural Language: Parsing over large numbers of texts. For example, the word “dead’ often appears in a variety of linguistic contexts such as “he was found dead”, “leaving him dead”, “left him dead”, “they counted 15 dead”, etc. Some of these expressions may provide stronger relevancy cues than others. Fsr example, “<person> was found dead” is a strong relevancy cue since there is a good chance that the person was the victim of a terrorist crime, whereas “enumber dead” is a much weaker cue since it is often used in articles describing military episodes that are not terrorist in nature. Similarly, the word “casualties” by itself is not a strong relevancy cue since many articles discuss casualties in the context of military acts. But the expression “no casualties” is highly correlated with relevance since it often refers to civilians. We will refer to linguistic expressions that are strong relevancy cues as relevancy signatures. In our system, these linguistic expressions are represented by ordered pairs of lexical items and concept nodes where the lexical item acts as a trigger for the concept node. For example, the pattern “was found dead” is represented by the pair (“dead”, $found-dead-pass$) where dead is the key word that triggers the concept node $found-dead-pass$ which in turn activates enabling conditions that expect the passive form of the verb “found” to precede the word dead. By taking advantage of the text corpus and answer keys used in MUC-3, we can automatically derive a set of relevancy signatures that will reliably predict the relevance of new texts. The following section describes the algorithm that derives a set of relevancy signatures from a training corpus and then uses those signatures to classify new texts. ellevancy Signatures Algorit MUC-3 provided its participants with a corpus of I300 news articles for development purposes and two additional sets of 100 texts each that were made available for test runs (the TSTl and TST2 texts). All of the MUC-3 texts were supplied by the Foreign Broadcast Information Service and they were drawn from a variety of news sources including wire stories, transcripts of speeches, radio broadcasts, terrorist communiques, and interviews. The MUC-3 text corpus was supplemented by hand-coded case frame instantiations (answer keys) for each text in the corpus. The MIX-3 text corpus and answer keys therefore gave us access to 1500 texts and their correct relevancy classifications. For our experiments, we set aside a small portion of this corpus for testing purposes and dedicated the remaining texts to the training set. The training set was then used to derive a set of relevancy signatures. The Relevancy Signatures Algorithm is fairly simple. Given a set of training texts, we parse each text using CIRCUS and save the concept nodes that are produced during the parse along with the lexical items that triggered those concept nodes. As we parse the training texts, we update two statistics for each word/concept node pair: [I] the number of times that the pair occurred in the training set (IV), and [2] the number of times that it occurred in a relevant text (NR). The ratio of NR over N gives us a “reliability” measure. For example, .75 means that 75% of the instances (for that pair) appeared in relevant texts. Using these statistics, we then extract a set of “reliable” lexical item/concept node pairs by choosing two values: a reliability threshold (R) and a minimum number of occurrences (IV& The reliability threshold specifies the minimum reliability measure that is acceptable. For example, R=90 dictates that a pair must have a reliability measure greater than 90% in order to be considered reliable. The minimum number of occurrences parameter specifies a minimum number of times that the pair must have occurred in the training set. For example, M=4 dictates that there must be more than 4 occurrences of a pair for it to be considered reliable. This parameter is used to eliminate pairs that may have a very high reliability measure but have dubious statistical merit because they appeared only a few times in the entire training set. Once these parameters have been selected, we then identify all pairs that meet the above criteria. We will refer to these reliable word/concept node pairs as our set of relevancy signatures. To illustrate, here are some relevancy signatures that were derived from the corpus using the parameter values, R=90 and M=lO along with some text samples that are recognized by these signatures: (“injur~,$injury- 1$) the terrorists injured 5 people (“located”,$location-pass- l$) the banks were located (“occurred”,$bomb-attack-2$) an explosion occurred (“perpetrated”,$perp-pass- 1 $) the attack was perpetrated by . . . (“‘placed”,$loc-val- l$) the terrorists placed a bomb . . . (“placed”,$loc-val-pass- l$) a bomb was placed by . . . (“planted”,$loc-val-pass-I$) a bomb was planted by . . . To classify a new text, we parse the text and save the concept nodes that are produced during the parse, along with the lexical items that triggered them. The text is therefore represented as a set of these lexical item/concept node pairs. We then consult our list of relevancy signatures to see if any of them are present in the current text. If we find one, the text is deemed to be relevant. If not, then the text is deemed to be irrelevant. It is important Riloff and Lehnert 331 to note that it only takes one relevancy signature to classify a text as relevant. Experimental To judge the effectiveness of the Relevancy Signatures Algorithm, we performed a variety of experiments. Since our algorithm derives relevancy signatures from a training set of texts, it is important that the training set be large enough to produce significant statistics. It is harder for a given word/concept node pair to occur than it is for only the word to occur, so many potentially useful pairings may not occur very often. At the same time, it is also important to have a large test set so we can feel confident that our results accurately represent the effectiveness of the algorithm. Because we were constrained by the relatively small size of the MUC-3 collection (1500 texts), balancing these two requirements was something of a problem. Dividing the MUC-3 corpus into 15 blocks of 100 texts each, we ran 15 preliminary experiments with each block using 1400 texts for training and the remaining 100 for testing. The results showed that we could achieve high levels of precision with non-trivial levels of recall. Of the 15 experiments, 7 test sets reached 80% precision with 2 70% recall, 10 sets hit 80% precision with 2 40% recall, and 12 sets achieved 80% precision with 2 25% recall. In addition, 7 of the test runs produced precision scores of 100% for recall levels > 10% and 5 test sets produced recall levels > 50% with precision over 85%. Based on these experiments, we identified two blocks of 100 texts that gave us our best and our worst results. With these 200 texts in hand, we then trained once again on the remaining 1300 in order to obtain a uniform training base under which the remaining two test sets could be compared. Figure 1 shows the performance of these two test sets based on the training set of 1300 texts. Each data point represents the results of the Relevancy Signatures Algorithm for a different combination of parameter values. We tested the reliability threshold at 70%, 75%, 80%, 85%, 90%, and 95% and varied the minimum number of occurrences from 0 to 19. As the data demonstrates, the results of the two test sets are clearly separated. Our best test results are associated with uniformly high levels of precision throughout (> 78%), while our worst test results ranged from 47% to 67% precision. These results indicate the full range of our performance: average performance would fall somewhere in between these two extremes. Low reliability and low M thresholds produce strong recall (but weaker precision) for relevant texts while high reliability and high M thresholds produce strong precision (but weaker recall) for the relevant texts being retrieved. A high reliability threshold ensures that the algorithm uses only relevancy signatures that are very strongly correlated with relevant texts and a high minimum number of occurrences threshold ensures that it uses only relevancy signatures that have appeared with greater frequency. By adjusting these two parameter values, we can manipulate a recall/precision tradeoff. A OE’blOl-500 (66 rel) 0N801-900 (39 rer) Figure 1: Relevancy Discriminations on Two Separate Test Sets Using Relevancy Signatuses Wowever, a clear recall/precision tradeoff is evident only when the algorithm is retrieving statistically significant numbers of texts. We can see from the graph in Figure 1 that precision fluctuates dramatically for our worst test set when recall values are under 50%. At these lower recall values, the algorithm is retrieving such small numbers of texts (less than 20 for our worst test set) that gaining or losing a single text can have a significant impact on precision. Since our test sets contain only 100 texts each, statistical significance may not be reached until we approach fairly high recall values. With larger test sets we could expect to see somewhat more stable precision scores at lower recall levels because the number of texts being retrieved would be greater. The percentage of relevant texts in a test set also plays a role in determining statistical significance. Each of the test sets contains a different number of relevant texts. For example, the best test set contains 66 relevant texts, whereas the worst test set contains only 39 relevant texts. The total percentage of relevant texts in the test corpus provides a baseline against which precision must be assessed. A constant algorithm that classifies all texts as relevant will always yield 100% recall with a precision level determined by this baseline percentage. If only 10% of the test corpus is relevant, the constant algorithm will show a 10% rate of precision. If 90% of the test corpus is relevant, the constant algorithm will achieve 90% precision. If we look at the graph in Figure 1 with this in mind, we find that a constant algorithm would yield 66% precision for the first test set but only 39% for the second test set. From this vantage point, we can see that the Relevancy Signatures Algorithm performs substantially better than the constant algorithm on both test sets. It was interesting to see how much variance we got across the different test sets. Several other factors may have contributed to this. For one, the corpus is not a randomly ordered collection of texts. The MUC-3 articles were often ordered by date so it is not uncommon to find 332 Natural Language: Parsing sequences of articles that describe the same event. One block of texts may contain several articles about a specific kidnapping event while a different block will not contain any articles about kidnappings. Second, the quality of the answer keys is not consistent across the corpus. During the course of MUC-3, each participating site was responsible for encoding the answer keys for different parts of the corpus. Although some cross-checking was done, the 9 uality of the encoding is not consistent across the corpus. The quality of the answer keys can affect both training and testing. The relatively small size of our training set was undoubtedly a limiting factor since many linguistic expressions appeared only a few times throughout the entire corpus. This has two ramifications for our algorithm: (1) many infrequent expressions are never considered as relevancy signatures because the minimum number of occurrences parameter prohibits them, and (2) expressions that occur with low frequencies will yield less reliable statistics. Having run experiments with smaller training sets, we have seen our results show marked improvement as the training set grows. We expect that this trend would continue for training sets greater than 1400, but corpus limitations have restricted us in that regard. Relevancy signatures were motivated by our observation that human readers can reliably identify many relevant texts merely by skimming the texts for domain-specific cues. These quick relevancy judgements require two steps: (1) recognizing an expression that is highly relevant to the given domain, e.g. “were killed” in the domain of terrorism, and (2) verifying that the context surrounding the expression is consistent with the relevancy guidelines for the domain, e.g. “5 soldiers were killed by guerrillas” is not consistent with the terrorism domain since victims of terrorist acts must be civilians. The Relevancy Signatures Algorithm simulates the first step in this process but can misclassify texts when the surrounding context contains additional information that makes the text irrelevant. In particular, relevancy signatures do not take advantage of the slot fillers in the concept nodes. For example, consider two similar sentences: (a) “a civilian was killed by guerrillas” and (b) “a soldier was killed by guerrillas”. Both sentences are represented by the same relevancy signature: (killed, $murder-pass- l$) even though sentence (a) describes a terrorist event and sentence (b) does not. To address this problem, we developed a variation of the 5During the course of this research, we found that about 4% of the irrelevant texts in the MUC-3 development corpus were miscategorized. These errors were uncovered by spot checks: no systematic effort was made to review all the irrelevant texts. We therefore suspect that the actual error rate is probably much higher. Relevancy Signatures Algorithm that augments the relevancy signatures with slot filler information. While relevancy signatures classify texts based upon the presence of case frames, augmented relevancy signatures classify texts on the basis of case frame instantiations. The algorithm for deriving and using augmented relevancy signatures is described below. Given a set of training texts, we parse each text and save the concept nodes that are generated. For each slot in each concept node, we collect reliability statistics for triples consisting of the concept node type, the slot name, and the semantic feature of the filler.6 For example, consider the sentence: “The mayor was murdered.” The word “murdered” triggers a murder concept node that contains “the mayor” in its victim slot. This concept node instantiation yields the slot triple: (murder, victim, ws- government-official). We then extract a set of “reliable” slot triples by choosing two values: a reliability threshold Rslot and a minimum number of occurrences threshold Mslot. These parameters are analogous to the relevancy signature thresholds. To classify a new text, we parse the text and save the concept nodes that are produced during the parse, along with the words that triggered them. For each concept node, we generate a (triggering word, concept node) pair and a set of slot triples. If the (triggering word, concept node) pair is in our list of relevancy signatures, and the concept node contains a reliable slot triple then we classify the text as relevant. Intuitively, a text is classified as relevant only if it contains a strong relevancy cue an enabled by this cue contains at least one slot filler that is also highly correlated with relevance. We compared the performance of the augmented relevancy signatures with the original Relevancy Signatures Algorithm in order to measure the impact of the slot filler data. Figure 2 shows the results produced by the augmented relevancy signatures on the same two test sets that we had isolated for our original experiments, after training on the remaining 1300 texts. Each data point represents a different combination of parameter values. This graph clearly shows that the augmented relevancy signatures perform better than the original relevancy signatures on these two test sets. The most striking difference is the improved precision obtained for DEV 801-900. There are two important things to notice about Figure 2. First, we are able to obtain extremely high precision at low recall values, e.g., 8% recall with 100% precision and 23% recall with 90% precision. Relevancy signatures alone do not achieve precision greater than 67% 6Since slot fillers can have multiple semantic features, we create one triple for each feature. For example, if a murder concept node contains a victim with semantic features ws- human & ws-military then we create two triples: (murder, victim, ws-human) and (murder, victim, ws-military). Riloff and Lehnert 333 for this test set at any recall level. Second, although there is a very scattered distribution of data points at the lower recall end, we see consistently better precision coupled with the higher recall values. This trend suggests that the augmented relevancy signatures perform better than the original relevancy signatures when they are working with statistically significant numbers of texts. 1 A OEWOl-500 (66 rel) 9 OEV801-900 (39rel) 1 Figure 2: Relevancy Discriminations on Two Separate Test Sets Using Augmented Relevancy Signatures Noting that the relevancy signatures demonstrated extremely strong performance on DEV 401-500, it is reassuring to see that the augmented relevancy signatures achieve comparable results. The highest recall level obtained with extremely high precision by the original relevancy signatures was 70% with 96% precision. The augmented relevancy signatures achieved significantly higher recall with the same precision, 80% recall with 96% precision. This suggests that augmented relevancy signatures can also achieve considerably greater levels of recall with high precision than relevancy signatures alone. Conclusions The Relevancy Signatures Algorithm was inspired by the fact that human readers are capable of scanning a collection of texts, and reliably identifying a subset of those texts that are relevant to a given domain. More importantly, this classification can be accomplished by fast text skimming: the reader hits on a key sentence and a determination of relevancy is made. This method is not adequate if one’s goal is to identify all possible relevant texts, but text skimming can be very reliable when a proper subset of relevant texts is sufficient. We designed the Relevancy Signatures Algorithm in an effort to simulate this process. In fact, the Relevancy Signatures Algorithm has an advantage over humans insofar as it can automatically derive domain specifications from a set of training texts. While humans rely on domain knowledge, explicit domain guidelines, and general world knowledge to identify relevant texts, the Relevancy Signatures Algorithm requires no explicit domain specification. Given a corpus of texts tagged for domain relevancy, an appropriate dictionary, and suitable natural language processing capabilities, reliable relevancy indicators are extracted from the corpus as a simple side effect of natural language analysis. Once this training base has been obtained, no additional capabilities are needed to classify a new text. It follows that the Relevancy Signatures Algorithm avoids the knowledge-engineering bottleneck associated with many text analysis systems. As a result, this algorithm can be easily ported to new domains and is trivial to scale-up. With large online text corpora becoming increasingly available to natural language researchers, we have an opportunity to explore operational alternatives to hand-coded knowledge bases and rule bases. As we have demonstrated, natural language processing capabilities can produce domain signatures for representative text corpora that support high-precision text classification. Acknowledgements We would like to thank David Fisher for ongoing technical support that enabled preliminary experiments with the UMass/MUC-3 system on a Macintosh platform. References 1. Krupka, G., Iwanska, L., Jacobs, P., and Rau, L. 1991. GE NLToolset: MUC-3 Test Results and Analysis. In Proceedings of the Third Message Understanding Conference, 60-68. San Mateo, CA. Morgan Kaufmann. 2. Lehnert, W.G. 1990. Symbolic/Subsymbolic Sentence Analysis: Exploiting the Best of Two Worlds. In Advances in Connectionist and Neural Computation Theory. (Eds: J. Pollack and J. Barnden), 135-164. Norwood, NJ. Ablex Publishing. 3. Lehnert, W.G., Cardie, C., Fisher, D., Riloff, E., and Williams, R. 1991. The CIRCUS system as used in MUC- 3, COINS Technical Report 91-59. Department of Computer and Information Science, University of Massachusetts at Amherst. 4. Lehnert, W.G. and Sundheim, B. 1991. A Performance Evaluation of Text Analysis Technologies. AI Magazine, vol 12; no.3, pp. 81-94. 5. Salton, G. 1989. Automatic Text Processing: The Transformation, Analysis, and Retrieval of Information by Computer. Reading, MA. Addison-Wesley Publishing Company, Inc. 6. Sundheim, B. 1991. (ed.) Proceedings of the Third Message Understanding Conference. San Mateo, CA. Morgan Kaufmann. 334 Natural Language: Parsing | 1992 | 62 |
1,257 | Uri Zernik General Electric - Research and Development Center PO Box 8, Schenectady, NY 12301 Abstract Thematic analysis is best manifested by contrasting collocations1 such as “shipping pacemakers” vs. “ship- ping departments”. While in the first pair, the pace- makers are being shipped, in the second one, the de- partments are probably engaged in some shipping ac- tivity, but are not being shipped. Text pre-processors, intended to inject corpus-based intuition into the parsing process, must adequately distinguish between such cases. Although statisti- cal tagging [Church et al., 1989; Meteer et al., 1991; Brill, 1992; Cutting et al., 19921 has attained impres- sive results overall, the analysis of multiple-content- word strings (i.e., collocations) has presented a weak- ness, and caused accuracy degradation. To provide acceptable coverage (i.e., 90% of colloca- tions), a tagger must have accessible a large databa.se ( i.e., 250,000 pairs) of individually analyzed colloca- tions. Consequently, training must be based on a cor- pus ranging well over 50 million words. Since such a large corpus does not exist in a tagged form, training must be from raw corpus. In this paper we present an algorithm for text tag- ging based on thematic analysis. The algorithm yields high-accuracy results. We provide empirical results: The program NLcp (NL corpus processing) acquired a 250,000 thematic-relation database through the 85- million word Wall-Street Journal Corpus. It was tested over the Tipster 66,000-word Joint-Venture corpus. z 3 ‘In this discussion, a collocation is defined as a pair of cooccurring content words 2This research was sponsored (in part) by the Defense Advanced Research Project Agency (DOD) and other gov- ernment agencies. The views and conclusions contained in this document are those of the authors and should not be interpreted as representing the official policies, either expressed or implied, of the Defense Advanced Research Project Agency or the US Government. 3We thank A CL/DC1 (Data Collection Initiative), the Collins publishing company, the Wall Street Journal, for providing invaluable on-line data, and the TreeBank project for providing tagged corpus for reference. Pre-processing: The Big Picture Sentences in a typical newspaper story include idioms, ellipses, and ungrammatical constructs. Since authen- tic language defies textbook grammar, we must, re- think our basic parsing paradigm, and tune it to t,he nature of the text under analysis. Hypothetically, parsing could be performed by one huge unification mechanism [Kay, 1985; Shieber, 1986; Tomita, 19861 which would receive its tokens in the form of words, characters. or morphemes, negotiate a.11 given constraints, and protluce a full cha.rt# wit.11 all possible interpreta.tions. However, when tested on a real corpus (i.e., Wall Street Journal ( WSJ ) news stories), t’his mechanism colla.pses. For a typical well-behaved 33-word sentence it produces hundreds of candidate interpretations. To allevia.te problems associat#ed with processing real text, a new stra.tegy has emerged. A pre-processor, capitalizing on statistical da.ta [Church et al., 1989; Zernik and Jacobs, 1990: Da.gan et al., 19911, and trained to exploit properties of the corpus itself, could highlight regularities, identify thematic rela.tions, and in general, feed digest.ed text, into the unification parser. In this paper we investigate how a parser can be aided in the analysis of multiple content-word st$rings, which are problematic since t’hey do not include synt.as “sugar” in t,lie form of function words. re-Processing Up Against? The Linguistic Phenomenon Consider the following Wall Street Journal (WSJ), (August 19, 1987) pa.ragra.ph processed by the NLcp pre-processor [Zernik el nl., 19911. Separately, Kaneb Services spokesman/nn said/vb holders/nn of its Class A preferred/jj stock/ml failed/vb to elect two directors to the company/nn board/nn when the annual/$ meeting/nn re- sumed/vb Tuesday because there are questions as to the validity of the proxies/nn submitted/vb for review by t.he group. The company/nn adjourned/vb its annual/jj meeting/m3 May 1 2 to allow/vb timc/nn for ne- Zernik 335 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. gotiations and expressed/vb concern/nn about fu- ture/jj actions/nn by preferred/vb holders/ml. The task under investigation is the classification content-word pairs into one of three categories. Local context: Consider local context dominates: t’he following 2 cases where of 1. and expressed/VB concern/NN about 2. Services spokesman/NN said/VB holders 3. class A preferred/JJ stock/NN *comma* The constructs expressed concern and spokesman said must be tagged verb-object and subject-verb respec- tively. Preferred stock, on the other hand, must, be identified and tagged as a fixed adjective-noun con- struct. An Architecture for Text-Processing Text processing proceeds through the stages [Zernik and Krupka, submitted 19921: following Training-Time Thematic Analysis: High- frequency collocations are collected from a large cor- pus. A thematic-relation database (250,000 itelns) is constructed, based on the diversity of each collo- cation in the corpus. Processing-Time Tagging: e Perform lexical dictionary. analysis based on Collins on-line e Perform initial tagging based on a fixed set of knowledge-base rules. Difficult cases such as content-word strings are left untagged. o Based on the thematic-relation database, tag the collocations. Leave untagged cases not covered by the database. Processing-Time Parsing: Perform syntactic anal- ysis of the tagged text by a unification parser [Tom&a, 19861. The training and the consequent t ions are addressed in this paper. tagging of colloca- The Input: Ambiguous Lexical Tags The complex scope of the pre-processing task is best illustrated by the input to the pre-processor shown in Figure 1. This lexical analysis of the sentence is based on the Collins on-line dictionary (about 49,000 lexi- cal entries extracted by NLcp) plus morphology. Each word is associated with candidate parts of speech, and almost all words are ambiguous. The tagger’s task is to resolve the ambiguity. Ambiguous words such as services, preferred, and ex- pressed, should be resolved as noun (nn,), adjective (jj), and verb (vb), respectively. While some pairs (e.g., an- nual meeting) can be resolved easily, other pairs (e.g., preferred stock and expressed concerns) are more diffi- cult, and require statistical training. Part-Of-Speech Resolution A program can bring to bear 3 ing part,-of-speech ambiguity: types of clues iii 336 Natural Language: Parsing resolv- 1. the preferred stock raised 2. he expressed concern about The words the and he dictat’e tha.t preferred and ex- pressed are adjective and verb respectively. This kind of inference, due to its local nature, is captured and propagated by the pre-processor. Global context: Global-sentence constraint8s shown by the following two examples: 1. and preferred stock sol d yesterday was . . . 2. and expressed concern about . . . *period* are In case 1, a main verb is found (i.e., was), and pre- ferred is taken as an adjective; in case 2, a main verb is not found, and therefore expressed itself is taken as the main verb. This kind of a.mbiguity requires full-fledged unification, and it, is not handled by the pre-processor. Fortunately, only a small percent of the cases (in newspaper st’ories) depend on globa. reading. Thematic Analysis: Corpus analysis provides cer- tain preferences [Beckwith ff ctl., 19911 collocation total vb-1111 jj-nn preferred stock 2314 100 0 expressed concern 318 1 99 The construct8 eapressed cu11cent, which appears 31X times in the corpus, is almost, always (99 t8imes out of 100 counted cases) a verb-noun construct: on the other hand, preferred sfock, which appears in t,he cor- pus 2314 times. is 100 times out, of 100 an acljective- noun, const,ruc t,. Figure 2 which illustrates t’he use of a fixed and a variable collocation in context, motivates the need for thematic analysis. In t’liis small sample, 8 out, of 35 cases (the ones marked “-“) cannot, be resolved reliably by using local context only. Without using Uiematic analysis, a. tagger will produce arbit,rary tags for fn&l,g a.nd operating. Indeed, existing st8atistical taggers [Church ef al., 1989; Meteer et al., 1991: Brill, 1992; Cutting ef d., 19921 which rely 011 bigrams or t,rigra.ms, but. do not employ thematic analysis of individual collocat.io~ls fare poorly on t,liis linguistic aspect,. ’ Learning fro112 Raw Corpus A database of collocations must8 be put in place in order to perform educat.ed thematic analysis as shown above. 4The univaria e- t analysis strat,egy [Brill, 1993] of using default single-word probability, is not successful in this case. All cases of ope&iny would by default be tagged incorrectly as verb since the noun/verb ratio for oyemtiny is 454/331 in the 2- million word portion of WSJ manually tagged by bhe TreeBank project. [Santorini. 19901). Kaneb NM said JJ VB its DT preferred JJ VB to PP directors NN company NN annual JJ tuesday NM proxies NN Services NNVB holders NN Class JJ NN stock NNVB elect VB to PP board NNVB meeting NNVB questions NNVB submitted JJ VB spokeslnan NN of PP A DTJJ failed ADVB two JJ NN the when c": resumed JJ VB validity NN group NN VB Figure 1: Lexical Analysis of Sentence: Words plus Parts of Speech e latest version of the UNIX V th Microsoft js MS *slash* DOS ties obtained licenses for the nths before IBM can provide an *comma* much as Microsoft 's r *colon* eta systems inc. its cyber uses an unusual internal *hyphen* Telegraph Co. 's UNIX willing to suffer with a crude at someday the Macintosh II 's operating operating operating operating operating operating operating operating operating operating system software and some system *period* Microsoft system *period* With the system that taps its math system software is now th system has not been debug system *s-colon* to sell system *comma* fast becom system *period* system would be enhanced phen* compatible computers and operating systems has created an op allow the equity investors to spect that some countries will *comma* probably will want to scheduling *comma* some might ed that rotated 360 degrees to th cheap local deposits and by ins by nimbly trading zeros to dexes and futures contracts to itional financing *s-colon* to pendent publishers *comma* and olon* but if brazil decides to that some practical jokers had onent systems on time *period* ravel plans by a few months to tic producers can successfully ing lobbyists and scurrying to homeowners 's refinancing to g complete pc systems *period* rally came from investors who n part by investors rushing to *comma* stayed long enough to ber of institutional investors mma* mo *period* Companies are for example *dash* *dash* have take advantage of federal tax benef take advantage of the option to pay take advantage of an option such as take advantage of the opportunity t take advantage of the view *period* taking advantage of its low overhea take advantage of short *hyphen* te take advantage of various different take advantage of future business o take advantage of our considerable take advantage of any price rally * taken advantage of the offer *dash* Taking advantage of changing demogr take advantage of the low fares *pe take advantage of the tax to eke ou take advantage of the current hosti take advantage of lower interest ra Taking advantage of their lower *hy took advantage of rising stock pric take advantage of britain 's high c take advantage of the amenities tha took advantage of the rally to roll taking advantage of that to rebuild taken advantage of the strong yen t Figure 2: KWIC Table for operating-system and take-advantage. Note the diverse inflections _ . . . compared withthefixed natureofoperuting systems. The sentences marked "+-- can hc tagged appropriately using local context. The sentences marked ((-)) cannot be tagged without thematic analysis. IJnless t,he t*agger is falniliar with the appropriate phrases, it cannot determine whether t,he combination is verb-noun or aclject,ive-noun, t t t t t t t t t t t t Zernik 337 I 2 produced-car 9 produced-cars 5 produces-cars 4 produce-car 13 produce-cars 17 producing-cars 2 production-cars 947 companies-said 242 companies-say 13 companies-saying 135 companies-says 14146 company-said 43 company-say 20 company-saying 698 company-says 3491 joint-venture 807 joint-ventures 2 joint-venturing Verb-Noun Relations 387 expressed-concern 72 taken-advantage 25 expressed-concerns 22 takes-advantage 10 expresses-concern 995 take-advantage 31 expressing-concern 3 take-advantages 3 expressing-concerns 260 taking-advantage 33 express-concern 159 took-advantage Noun- Verb Relations 118 analysts-note 192 analysts-noted 192 analysts-noted 13 analysts-noting 79 analyst.-not.ed 6 analyst-notes 6 analyst-notes 6 analyst-notes 9 analyst-noting Adjective-Noun Constructs 3558 preferred-stock 11 preferred-stocks 51 spokesman-acknowledged 8 spokesman-acknowledges ‘) _ spokeslllan-ackllo\Vledging 3 operates-systems 627 operating-system 86 operating-systems 3 operational-systems 2 operat.es-system Figure 3: Fixed and variable collocations. Fixed phrases (e.g., preferred stocks) allow only a narrow variallce. Full-fledged thematic relations (i.e., produced cars) a.ppea.r in a wide variety of forms. 338 Natural Language: Parsing Where Is the Evidence? Ideally, the database could be acquired by counting frequencies over a tagged corpus. However, a suffi- ciently large tagged corpus is not available. Other statistical taggers have required much smaller training texts: A database of univariate (i.e., single word) statistics can be collected from a l-million word corpus [Brill, 19921; a database of state-transitions for part-of-speech tagging can also be collected from a l- million corpus ([Church et al., 1989]), or even from a smaller 60,000-word corpus ([Meteer et al., 19911). However, to acquire an adequate database of col- locations, we needed the full 85-million WSJ corpus. As shown by [Church et al., 19911, the events we are looking for, i.e., word cooccurrence, are much sparser than the events required for state-transition, or for univariate-statistics. In conclusion, since no apriori tagged training corpus exists, there is no direct evidence regarding part-of- speech. All we get from the corpus are numbers that indicate frequency and mutual information score (MIS) [Church et al., 19911 f 11 0 co ocations. It is necessary to infer the nature of combinations from indirect corpus- based statistics as shown by the rest of this paper. Identifying Collocation Variability The basic linguistic intuition of our analysis is given in KWIC tables such as Figure 2. In this table we com- pare the cooccurence of the pairs operating-system and take-advantage. The verb-noun collocation shows a di- verse distribution while the adjective-noun collocation is quite unchanged. A deeper analysis of variation analysis is presented in figure 3, which provides the frequencies found for each variant in the WSJ corpus. For example, joint venture takes 3 variants totaling 4300 instances, out of which 4288 are concentrated in 2 patterns, which in effect (stripping the plural S suffix) are a single pattern. For produce cur no single pat tern holds more than 21% of the cases. Thus, when more than 90% of the phrases are concentrated in a single pattern we classify it as a fixed adjective-noun (or noun-noun) phrase. Oth- erwise, it is classified as a noun-verb (or verb-noun) thematic relation. Training-Time Thematic Analysis Training over the corpus requires inflectional morphol- ogy. For each collocation P it P’s Variability Factor VF(p) is calculated according to the following formula: VFCP) = fW(plural(P)) + f W(singular(P)) fR( stemmed( P)) Where fW(plurul(P)) means the word frequency of the plural form of the collocation; fW(singuZur(P)) means the frequency of the singular form of the collocation; fR(stemmed(P)) means the frequency of the stemmed collocation. The I/‘F for prodttced curs is given as an example: V F( produced - cars) f W”produced - cars) + f W(produced - car) ~ f R(produce - cur) * r\ + l+9+5+~4+y13+17+~ 52 = = = = 0.21 Accordingly, VF(producing - car) = VF(producing - cars) = 0.32; and VF( produce-car) is (by coincidence) 0.32. In contrast, VF(joint-venture) is 1.00. A list of the first 38 content-word pairs encountered in the the Joint-Venture corpus is shown in Figure 4. The figure illustrates the frequency of each collocation P in the corpus relative to its stem frequency. The ratio, called VF, is given in the first column. The second and third columns present the collocation and its frequency. The fourth and fifth column present the stemmed colloca- tion and its frequency. The sixth column presents the mutual information score. Notice that fixed collocations are easily distinguish- able from thematic relations. The smallest VF of a fixed collocation has a VF of 0.86 (finance specialist); the la.rgest VF of a t~hematic relation is 0.56 (produce concrete). Thus. a thrcsl~oltl. say 0.7’5, can effect,ively be established. Processing-Time Tagging Relative to a database such as in Figure 4, the tagging algorithm proceeds as follows, as t.he t,ext is read word by word: 1. Use local-context, rules to tag words. When no rule applies for tagging a word. then t.ag the word *‘??” ( “untagged” ) . 2. If the last, word pair i?; a collocat,ion (e.g., holding compun res) , and one of tlic t,wo words is tagged “‘?‘I”, then genera.te t#he S+&rippetl version (i.e., holding company), and t,lie affls-stripped version (i.e.. 11 old compun y). 3. Look up database. (4 (b) (4 If neither collocation is found, then do not.hing; if only a.ffix-stripped collocat,ion is found, or ifVF (variabilit’y factor) is smaller than threshold, then tag first, word a. verb and the second word a noun; If VF is larger than threshold, then tag adjective- noun or noun-110~11 (depending on lexical proper- ties of word, i.e., running vs. meeting). Checking for the noun-verb case is symmetrical (in step 2.1)). The threshold is different. for each suffix and should be determined esl)eriment ally (initial t~hrt~shold can be t(aken as 0.7’5). Zernik 339 VF(P) P 1.00 business-brief 1.00 joint-ventures 1.00 aggregates-operation 0.56 produce-concrete 1.00 crushed-stones 0.00 forming-ventures 0.00 leases-equipment 1.00 composite-trading 1.00 related-equipment 0.17 taking-advantage 0.99 electronics-concern 1.00 work-force 0.00 beginning-operation 1.00 makes-additives 1.00 lubricating-additive 0.18 showed-signs 1 .oo telephone-exchange 0.95 holding-company 1.00 phone-equipment 1.00 phone-companies 0.93 venture-partner 0.26 report-net 1.00 net-income 1.00 home-appliance 0.99 brand-name 0.96 product-lines 1.00 equity-stake 1.00 earning-asset 1.00 problem-loans 0.86 finance-specialists 1.00 finished-products 1.00 mining-ventures 1.00 gas-industry 0.18 began-talks 0.55 produce-electricity 1.00 power-plants 1.00 oil-heating 0.97 contract-dispute 4298 9 5 12 0 0 10629 65 260 482 2014 0 5 4 62 66 7752 51 572 140 283 9759 96 683 965 266 46 252 30 93 18 154 27 27 1353 14 187 stemmed(P) business-brief joint-venture aggregate-operation produce-concrete crush-stone form-venture lease-equipment composite-trade relate-equipment take-advantage electronic-concern work-force begin-operation make-a.dditive lubrica.te-a.dditive show-sign telephone-exchange hold-company phone-equipment, phone-company venture-part’ner report-net net-income home-applia.nce brand-name product-line equity-stake earn-asset problem-loan finance-specialist. finish-product mine-venture gas-industry begin-talk produce-electricity power-pla.nt oil-1iea.t contract-dispute fR(sl ‘d(P)) MIS(P) 10083 4300 9 9 12 44 12 10629 65 1510 485 2014 1 GO 5 4 339 GG 8124 51 572 150 1072 9759 96 687 1009 26G 46 252 35 93 18 154 152 49 1353 14 19X 9.95 12.11 5.84 4.59 11.08 5.50 4.35 9.41 5.28 9.25 6.87 7.79 4 . 1 1 4.39 14.W G.28 5.56 6.21 G.02 5.56 6.17 6.10 10.54 11.01 8.98 7.12 6.65 4.4G 5.10 5.06 5.79 5.03 5.05 4.5G G.14 8.12 4.01 13.64 Figure 4: Thematic-Relations Database: Each colloca.tiou is associated wif,h a Va.riability Factor (VF). A high VF indicates a fixed construct while a low VF (under 0.75) indicates a. verb-noun t,hemat.ic relat,ion. 340 Natural Language: Parsing Notice that local-context rules override corpus pref- erence. Thus, although preferred stocks is a fixed con- struct, in a case such as John preferred stocks, the al- gorithm will identify preferred as a verb. Evaluation The database was generated over the WSJ corpus (85- million words). The database retained about 250,000 collocations (collocations below a certain MIS are dropped). The count was performed over the Tipster Joint-Venture 1988 corpus (66,186 words). In the eval- uation, only content words (i.e., verbs, nouns, adverbs, and adjectives, totaling 36,231 words) are observed. Out of 36,231 content words, 1,021 are left untagged by the tagger due to incomplete coverage. 12,719 of the words in the text fall into collocations (of 2 or more content words). 6,801 of these words are resolved by local context rules. 4,652 of these words are resolved by thematic analysis. The remaining 1266 are untagged. Part-of-speech accuracy is 97%, estimated by check- ing 1000 collocations. A mismatch between adjective and noun was not counted as an error. Problematic Cases Our algorithm atic cases. yields incorrect results in two problem- Ambiguous Thematic Relations: Collocations that entertain both subject-verb and verb-object relations, i.e., selling-companies (as in “the company sold its subsidiary . . .” and “he sold companies . . . ” ). Interference: Coinciding collocations such as: market-experience and marketing-experience, or ship-agent and shipping-agent. Fortunately, these cases are very infrequent. Limitat ions Adjectives and nouns are difficult to distinguish in raw corpus (unless they are marked as such lexically). For example, since the lexicon marks light as both adjective and noun, there is no visible difference in the corpus between light/JJ beer and Zight/NN bulb. Our algo- rithm tags both light cases as a noun. Corpus Size and Database Size Two parameters are frequently confused when assess- ing tagging effectiveness: training-time corpus size and run-time database size. A larger training corpus improves both coverage (the number of cases that are tagged) because more collo- cations have been encountered. It also improves pre- cision (the number of cases that are tagged correctly) since for each collocation, more variations have been analyzed. In order to acommodate the tagger to a specific ar- chitecture (2OMbyte SPARC, in our case), the pro- gram might be linked with only a partial database (low frequency collocations are removed). Cutting down on run-time database does not reduce precision. In the configuration evaluated above, the run-time tagger used only the most frequent 200,000 collocations out of the entire collection of 250,000. Conclusions We have presented a mechanism for injecting corpus- based preference in the form of thematic relations into syntactic text parsing. Thematic analysis (1) is cru- cial for semantic parsing accuracy, and (2) presents the weakest link of existing statistical taggers. The algorithm presented in this paper capitalizes on the fact that text writers draw fixed phrases, such as cash flow, joint venture, and preferred stock, from a lim- ited vocabulary of collocations which can be capt,ured in a database. Human readers, as well as computer programs, are successful in interpreting the test he- cause they have previously encouiit,erecl and acquirecl the embedded colloca.tions. Although the algorithm identifies fixed collocations as such, it allows local-context rules to override those corpus-based preferences. As a result, exceptional cases such as he is operating sysieln.s, or h,c preferred stocks are handled appropriately. It turns out, that writers of a. highly edited text such a.s WSJ know how to avoid potentia.1 false rea.dings by ma.king sure that exceptions are marked by local context “sugar”. Our general line of thinking follows [Church et nl., 1991; Beckwith et nl., 1991; Dagan et al., 1991; Zernik a.ncl Jacobs, 1990; Sma.dja., 19911: in order for a program to interpret na.tural language text, it must, train on and exploit word connect,ious in t,lie text undei interpreta.tion. References R. Beckwith, C. Fellba.um, D. Gross, and G. Miller. Wordnet,: A 1exica.l da.tabase organized on psycholin- guistic principles. In U. Zernik, editor, Lexical Acqui- siiion.: Exploiting On-Line Diciionary to Build a Lex- icon. Lawrence Erlbanml Assoc., Hissda.le, NJ, 1991. Eric Brill. A simple rule-based part of speech tag- gers. In Proceedangs of Third Conference on. Applied Natural Language Processing, Morristown, NJ, 1992. Associa.tion for Computational Linguistics. K. Church, W. Gale, P. Hanks, and D. Hindle. Pars- ing, word a.ssociations, and predicate-argument, rela- tions. In Proceedings of the International Workshop on Parsing Technologies, Ca.rnegie h1ellon University, 1989. K. Church, W. Gale, P. Ha.nks, and D. Hindle. Using statistics in lexical ana.lysis. In ‘cr. Zernik, edit,or, Lex- ical Acquisition: Vsing Ott-Line Resources lo Blrild N Zernik 341 Lexicon. Lawrence Erlbaum Associates, Hillsdale, NJ, 1991. D. Cutting, J. Kupiee, J. Pedersen, and P. Sibun. A practical part-of-speech tagger. In Proceedings of Third Conference on Applied Natural Language Pro- cessing, Morristown, NJ, 1992. Association for Com- putational Linguistics. I. Dagan, A. Itai, and U. Schwall. Two languages are more informative than one. In Proceedings of the 29th Annual Meeting of the Association for Computational Linguistics, Berkeley, CA, 1991. M. Kay. Parsing in Functional Unification Grammar. In D. Dowty, L. Kartunnen, and A. Zwicky, editors, Natural Language Parsing: Psychological, Computa- tional, and Theoretical Perspectives. Cambridge Uni- versity Press, Cambridge, England, 1985. M. Meteer, R. Schwartz, and R. Weischedel. Post: Using probabilities in language processing. In Pro- ceedings of the 12th International Joint Conferewe on Artificial Intelligence (IJCAI-91), 1991. B. Santorini. Annotation manual for the pen tree- bank project. Technical report, University of Pennsyl- vania, Computer and Information Science, Philadel- phia, PA, 1990. S. Shieber. An Introduction to Unification-based Ap- proaches to Grammar. Center for the Study of Lan- guage and Information, Palo Alto, California, 1986. F. Smadja. Macrocoding the lexicon with co- occurrence knowledge. In U. Zernik, editor, Lexi- cal Acquisition: Using On-Line Resources to Build a Lexicon. Lawrence Erlbaum Associates, Hillsdale, NJ, 1991. M. Tomita. Eficient Parsing for Natural Lan- guage. Kluwer Academic Publishers, Hingham, Mas- sachusetts, 1986. U. Zernik and P. Jacobs. Tagging for learning. In COLING 1990, Helsinki, Finland, 1990. U. Zernik and G. Krupka. Pre-processing for parsing: Is 95% accuracy good enough? submitted 1992. U. Zernik, A. Dietsch, and M. Charbonneau. Im- toolset programmer’s manual. Ge-crd technical re- port, Artificial Intelligence Laboratory, Schenectady, NY, 1991. 342 Natural Language: Parsing | 1992 | 63 |
1,258 | Computation of U r Stochastic A. Corazza Ht. De Mori 6. Satta Istituto per la Ricerca School of Computer Science, Institute for Research in Scientifica e Tecnologica, McGill University, Cognitive Science, 38050 Povo di Trento, 3480 University str, Montreal, University of Pennsylvania, Italy Quebec, Ca.nada., N3A2A7 Philadelphia, PA, USA corazza@irst .it renato6cliucli.cs.nicgill.ca gsatta@llinc.cis.upenn.edu Abstract the basis of the input acoustic features A: Automatic speech understanding and automat’ic speech recognition extract different kinds of infor- mation from the input signal. The result of the former must be evaluated on the basis of the re- sponse of the system while the result of the latter is the word sequence which best matches the input signal. In both cases search has to be performed based on scores of interpretation hypotheses. A scoring method is presented based on stochastic context-free grammars. The method gives optimal upper-bounds for the computation of the %est8” derivation trees of a sentence. This method allows language models to be built based on stocha.stic context-free grammars and their use with an ad- missible search algorithm that interprets a speech signal with left-to-right or middle-out strategies. Theoretical and computational aspect,s are dis- cussed. Pr(a 1 A) = Pr(A 1 a) Pr(a)Pr(A)-1 (1) A possible criterion to decide when a solution is op- tinlal is based on the maximization of (l), that is the same as maximizing the following OF: f(a) = Pr(A 1 a) Pr(a) (2) where the first factor Pr(A 1 (T) is given by the acoustic model, usua.lly Hidden Markov models, while Pr(a) computation is based on the stochastic language moclel. Introduction In Automatic Speech Recognition (ASR) and Aut,o- matic Speech Understanding (ASU) systems, models based on Context-Free Grammars (CFGs) have been proved effective both in pruning impossible sentences and in predicting a list of words that. can possibly expand a partially recognized sentence. Moreover, stochastic language models can give a probabilistic de- scription of the sentence distribution. This informat,ion can be used both in an Optimization Function (OF) to decide when a solution is optimal, and in a. Scormg Function (SF) to guide the search at each expansion step. In order to give this probabilistic description CFGs can be extended into Stochastic CFGs (SCFGs). Formal description of SCFGs will be given in the next section. Given a stochastic language model, the Bayes rule permits rewriting the conditioned probability of the solution u, represented by a sequence of words, on ASU differs from ASR because it has to produce a response action rather than a sequence of recog- nized words. The choice of this action is performed by processing the most likely interpretation of the in- put, which for SCFGs is given by the most probable - derivation corresponding to the sequence of words u. Therefore, while in ASR systems Pr(a) represents the probabilit,y of the sequence of words 0, i.e. the sum of the probabilities of all the derivations associated to (T, in ASU systems Pr(c) should be the probability of the most likely derivation of CT, i.e. the maximum of the probabilities of the derivations associated to 0. Two different SFs must be used in the two cases. In general, if a search strategy like A* is used, a scoring function is defined on a partially recognized sentence o’p and is required to be an upper-bound of the values of the OF on all the complete solutions that can be derived from it. Scores for the ASR approach are pre- sented in [Corazza et al., 1991a]. In this paper we are proposing a SF for the case in which the OF associates to each sequence of words its best derivation. Such a scoring is obtained by: s(“,) = sl(A I~pb2(5) (3) where s1(,4 I up) is an upper-bound on Pr(A I a) and can be obt,ainecl as will be briefly discussed in the last section, while sz(~~>) is the proba.bility of the best com- plete derivation tree that can derive op. *The work presented here is part of MAlA, the int,e- grated AI project under development at. 1stitut.o per la Ricerca Scientifica e Tecnologica (IRST). In the following sections the computation of s2 is studied for partial solutions derived by left-to-right as well as middle-out parsing strategies. In the last sec- tion we argue tha.t this upper-bound is optimal and we 344 Percept ion From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. compare it with upper-bounds proposed in the litera.- ture for ASR, showing that our approach results in a more feasible computation. Background In this section basic definitions and notation adopted in this paper are introduced. Let A be a gene& set of symbols. A string u over A is symbols from A; we a finite sequence of write 1~1 to denote the leugth of u. The null string E is the (unique) string whose length equals zero. Let u = zu1 . . . wra, n > 1; we write rl-:U and u:k, 0 < k < n, to denote the prefix string w1 . . . wk and the sujj?x string w,+k+l . . . wn respectively. The set of all strings over A is denoted A* (E in- cluded). Let u and v be two strings in A*; uv denotes the concatenation of u and v (u before v). The con- catenation is extended to sets of strings in the following way. Let L1, L2 E A*; uL1 denotes {;L 1 x = UP, y E Ll), Llu denotes {x 1 x = yu, y E Ll} and L1 L:! denotes (x 1 x = yz, y E L1, z E L2). A SCFG is a 4tuple G, = (N, C, P, , S), where N is a finite set of nonterminal symbols, C is a. finite set of terminal symbols such that N n C = 0, S E N is a special symbol called start symbol and P, is a finite set of pairs (p, Pr(p)), where p is a production and Pr(p) is the probability associated to p in 6,. Productions a.re represented with the form H - y, H E N, y E (N U Cl”, and symbol P denotes the set of all productions in P’. As a convention, productions which do not belong to P have zero probability. We assume G, to be a proper SCFG, that is the following relation holds fol every H in N: x Pr(H + y) = 1. (4) rE(NuC)’ The grammar G, is in Chomsky Normal Form (CNF) if all productions in P have the form H - F’I I;; or H - w, where H, 8’1, F2 E N, w E C. Without loss of gen- erality, we assume in the following that G, is in CNF; for convenience, we also assume N = {HI, . . . , HlN 1) , Hl = s. The definition of derivation in a SCFG, can be found in the literature on formal langua.ges (see for exa.m- ple [Gonzales and Thomason, 1978], [Wetherell, lOSO]). Let y be a string in (N u C)“. A derivation in G, of y from a nonterminal H is represented as a derivation. tree, indicating all productions that have been used in the derivation (with repetitions). We write H(y) to denote the set of all such trees. Let r be a. deriva- tion tree in H(r); Pr(r) is the probability of r, and is obtained as the product of probabilities of a.11 produc- tions involved in r (with repetitions). The operator Pm, defined as follows, is introduced: Pm(H(L)) = T~H~LI{prw~. (5) Let L be a string set, L & (N U C)* . We generalize the preceding notation and write H(L) to represent the set of all derivation trees with root H and yield in L; Pm(H(L)) ’ tl 1s le maximum among probabilities of all r in H(L) . In this paper we will develop a framework for the computation of Pm( H (L)) for L = {u}, L = UC* and L = C*uC*, where u is a given string over C. As discussed in the introduction, these quantities can be used as upper-bounds in the search for the most likely complete derivation for the input signal. Due to space constraints, only the highlights of the theory are presented in this paper. A complete description a.long with formal proofs can be found in [Corazza et id., 19911. Let A and f.3 be two sets; we write A - 8 to denote the asymmetric set-diflerence between A and B, that is the set {x I x E A, x ft B} Let Ml be an m x n array and let n/12 be an n x p array; a binary operation 8 is defined a.s follows: [Ml 0 A&][i, j] = l~-fyn{M&k] - M2[kj]}. (6) Let Ad be a 1 x 11. arra, aid Z be a subset of (1, .., n}; we define argmax{ AI, 2) to be the set {i I M[i] 2 AI[k], b E 2). If A4 is an m x n array, we extend the notation to M[i], the i-th row of A4, in the fol- lowing way. Let Z C {l,.., m} x (1,. . . ,n}; we de- fine argmax{M[i],Z} to be the set {(;,j) I IU[i,j] 2 Af[i, h], (i, h) E Z}. Off-line computations Some of the expressions required for computing the “best” derivation probability of a sentence partial in- terpretation do not depend on the input string, but only on the grammar; therefore these terms can be computed once for all. Methods for the computation of these quantities are studied in the following. The basic idea is to use a “dynamic programming” tech- nique which is reminiscent of the well-known methods for removing useless symbols from a context-free gram- n1a.r (see for example [Harrison, 19781). A summary of these quantities is schematically depicted in Figure 1. Hi ~~$iJ z:* ~~ . . . . . . . . . . . . ..S.i . . . . . . . . . . . z* c* c* Figure 1: Summ.ary of the quantities computed off-line. Computation of upper-bounds for a gap As a first step we consider the set of all derivation trees wllose root is Hi and whose yield is a terminal string. Corazza, De Mori, and Satta 345 Let us define an INI x 1 array MS such that M,[i] = Pm(Hi(C*)). (7) The elements of MS can be computed as follows. Let r be a derivation tree such that a path from its root to one of its leaves contains more than one occurrence of a nonterminal Hj. Let also r’ be the derivation tree obtained from r by removing the subtree rooted in the occurrence of Hj closer to the root of T and replac- ing it with the subtree rooted in the occurrence of Hj closer to the yield of r. It is possible to show that the probability of r’ is strictly less than the probability of r. The process can be iterated, showing that every optimal tree has height not greater than IN]. As a sec- ond point, let Tk be the set of all derivation trees with height not greater than h. By induction on K, it is possible to show that within Tk a set of at least x7 trees {71,72, * * *, rk} is ak~~ys found, whose roots are la.beled by different symbols Hi,, Hi,, . . , , Hak and whose prob- abilities are optimal, that is these probabilities define the elements M,[il], M,[i2], . . . ,M,[ik] (this result. is proved in [Corazza et al., 19911 and is exploited in the following to speed-up the computation). A tabular method can then be used to compute array M,, where at the k-th iteration we consider set Tk. As a consequence of the two observations above, the method converges to MS in at most INI iterations and at each iteration at least one new element of array iVg is available (in the following the remaining elements are indexed by sets &). The method is defined by the following relations: (i) let Zs = (1,. . Ap[i] = Zl = -3 INI): (ii) for every k > Mjk)[i] = m$x{Pr(Hi - w)}, i E X0; To - argmax{@l), X0); 2: I max{MjkB1)[i], “,“i”c Pr(Hi --, HhHli Mjk-l)[h]Mjk-')[I] } }, i E &-I; I A&“-‘)[i], i E 10 - Zkvl; 2, = G-1 - argmax{fW~k-l),X~-,}. A closer inspection of the above relations reveals tha.t the computation can be carried out in a.11 amount of time O(]N]]PS]). Computation of factors for prefix and suffix upper-bounds In the next section, we will need to know the proba- bilities of the “optimal” derivation trees whose root is Finally, we consider the maximum probability of the Hi and whose yield is composed of a nonterminal Hj derivation trees whose root is Ha and whose yield is a nonterniinal Hj surrounded by two strings in C*; these followed by a string in C*. Let us define an IN] x IN] a.rray L, such that (see Figure 1) L,[i,j] = Pm(Hi(HjC*)). (8) Elements of the array L, can be computed using a tab- ular technique very similar to the one employed in the computation of MS, as described in the following. Let Tk be the set of all derivation trees in Hi(HjC*) such that the path from the root node Hi to the left-corner node Hj has length not greater than k. At the k-th iteration in the computation, we consider the “best” probabilities of elements in Tk and we are guaranteed to converge to the desired array L, in no more than IN] iterations. Moreover, at each iteration in the computa- tion we are guaranteed that at least IN] new elements of L, are available (again see [Corazza et al., 19911 for a forma.1 proof of this statement); the remaining ele- ments are recorded using sets &: this enables us to speed-up the computation. We specify in the following the relations that can be used in the computation of L, (note how elements of array A/r, are exploited): (i) for (i,j) E ZO, 20 = {(h, k) 1 1 5 h,k 5 INI}: Li’)[i, j] = m;x{Pr(Hd --+ Hj Hh)“g IhI) 11 = zo - U argmax{ Lp)[i], Zo}; l<i<lNI -- (ii) for every k 2 2: Lr)[i, j] = ma-u{ Lr-“[i, j], “,“ix{ Pr(Hi - HhHl) ’ = Lr-‘)[h, j]A&“-“[Z] } }, (id) E xk-1; Lr-‘)[i, j], (i,j) E 10 - Zk-1. Zk = &-1 - u argmax{Lp-‘)[i], &-I}. l<i<lNI -- Let us consider now the maximum probabilities of derivation trees whose root is Hi and whose yield is a st,ring in the set C” Hj, that is L,[i, j] = Pm(Hi(C*Hj)). (9) A symmetrical result can be obtained for the com- putation of array L,. The details are omitted. As a final remark, we observe that the computation de- scribed above can be carried out in an amount of time wNl”lm* Computation of factors for island upper-bounds 346 Percept ion probabilities will be employed in the next section in the computation of syntactic island upper-bounds. Let us define an IN] x IN] array Li such that (see Figure 1) Li[i, j] = Pm(Hi(C*HjC*)). W) In this case too, we use a tabular method and orga- nize the computation in such a way that the method converges to Li after no more than INI iterations; the recursive relations are a straightforwa.rd a.da.ptation of the relations studied for array L,: (i) for (i, j) E ZO, ZO = {(h, k) I 1 L k k I INI): Lc”[i j] a 3 = max{m;x{Pr(Hi - Hj r-I,)M,[h], mhx(PrW -+ HhHj)AIg[h])), z1 = 10 - U argmax{ Li”[i], I&J}; l<i<lNl -- (ii) for every i(: 2 2: LCk’[i a , j] = max{ Lik-‘)[i, j], mhy{Pr(Hi - HIHh)Lj”-l’[/, j] Mg[/l]), = yk{Pr(Hi + HhHl)iifg[h] I,:“-‘)[[, j]}} , (i, j) E &.-I; Likwl)[i, j], (i, j) E 20 - 2k-I; zk = it&-l - U argmax{L!“-l)[i],&-i). l<i<JN( -- As in the previous case, the corresponding compu- tation can be carried out in an amount of time w121~sl>~ n-line computations As already discussed in the introduction, we are inter- estesin finding the probability of an “optimal” deriva- tion in 6, of a sentence which includes, as a prefix or as an island, an already recognized word sequence 21. In this section we present the main result of this pa,- per, namely an efficient computation that results in such a probability. Using the adopted notation, we will restate the problem as one of finding the proba- bility of the “optimal” derivations of sentences in the languages UC* and C*uC*. The studied computations make use of some expressions introduced in the previ- ous section. A summary of the computed quantities is schematically depicted in Figure 2. Best derivation probabilities In what follows, we will need the probability of the most likely derivation of a given string u. Such a quan- tity can be computed using a proba.biIistic version of the Kasami-Younger-Cocke (CYK) recognizer (see for example[Aho and Ullman, 19721) based on the Viterbi ~ s(“)lil ~ i(“)[il T.+. c” u x* Figure 2: Summary of the quantities computed on-line. algorithm, as shown in [Jelinek and Lafferty, 19911. The following relations describe this algorithm using the notation adopted in this paper. Let u = w1 . . . w, be a string in C” and Mb(u) be an IN] x 1 array such that hfb(u)[i] = Pr(max : Hi(u)). (11) It is easy to prove, by induction on the length of u, that tZlie following recursive relation characterizes Mb(u): f Pr(Ha - u), IUI = 1; A/lb(tl)[i] = &(t:u)[h]b&j(u:( ]UI - t))[i]}, IuI > 1. The computation of Mb(u) requires O(]pS]]u]3) time; this is also the running time for the original CYK al- gorithm. Prefix upper-bounds Let u = w1 . . . w, be a string in C”. We define an IN] x 1 array Mp(u) as follows: n/r,(u)[i] = Pm(Hi(uC*)). (12) The definition states that every element Mp(u)[i] equals the probability of an optimal derivation tree ri whose root is labeled by Hi and whose yield includes ZL as a prefix. The computation of such an element can be carried out on the basis of the following observation. The derivation tree ri can always be decomposed into trees ??i and Tij such that 7; is the least subtree of rj that completely dominates prefix u and rij belongs to Hi (C”); this is shown in Figure 3. It turns out that both 55 and 7;; are the optimal trees that satisfy such a requirement‘: Since we already dispose of the- prob- ability of Tij, which is element L,[i, j] defined in the previous section, we are left with the computation of probabilities of ?i for a given u and for every root node tij . We present some relations that can be used in such a computation. The following IN] x 1 auxiliary array is associated wit,11 a. string ‘11 using the probability of a SCFG G, in Corazza, De Mori, and Satta 347 U c* c* Figure 3: CompuMion of M,(u)[i]. Chomsky Normal Form: PT(Hi - u), It11 = 1; Gp(u)[i] = O<~p&pwi - HhW m(t:u)[h] Mp(u:(IuI - t))[i] }, lzcl > 1. Apart from the case IuI = 1, element Gp(u)[i] corre- sponds to the probability of optimal derivation trees in Ha(uC*) such that each immediate constituent of the root Ha spans a proper substring of u (see again Figure 3). The following result, which is proved in [Corazza et al., 19911, relates array Mp(u) to ar- rays Ep(u) and L,. Let the array Lb [i, j] = L,[i, j], i# j, and Lb[i,i] = 1, 1 5 i _< INI; then we have: i&(u) = LI, 8 &gu). (13) We observe that array 6&(u) depends upon arra.ys Mp( u,) for every proper suffix u, of u. Both ar- rays can then be computed recursively, first consid- ering u = wta, then using IMP (ulra) for the computa- tion of the arrays associated with u = ZU~,~ZD,, and so on. A careful analysis of the above relations re- veals that the overall computation can be carried out in time 0(max{lP,llu13, lNi21u1)). This is roughly the same amount of time independently required by practi- cal algorithms for the (partial) recognition of the string hypothesized so far. In a symmetrical way with respect to array Mp(u), we define an INI x 1 array M,(u): M,(u)[i] = Pm(Hi(C*u)). (14) Relations very close to the one discussed above have bzn studied for the computation_of an auxilia,ry array M,(u) such that M,(u) = L/, @ M,(u) (L: is the same as L, with unitary elements on the diagonal). Island upper-bounds We conclude with the problem ability that a nonterminal Hi of computing the prob- derives in an optimal way a string of terminal symbols that includes a given sequence u as an island. The relations reported below have been obtained using the same recursive technique that has been applied in the previous subsection. Given the string u = 201 . . . ZU, in C”, Ma(u) is the INI x 1 array defined as: Mi(u)[i] = Pm(Hi(C*uC*)). (15) Let us consider the INI x 1 auxiliary array gi(u) defined as follows (see Figure 4): Figure 4: Computatzon of Mi(u)[i]. I ( Pr Hi - u), IUI = 1; Z(u)[i] = o<~~,h,,{pr( Hi - HhHl) m(t:u)[h] &&-+I - t>p-J }, IUI > 1. Note that Ei(u) is recursively computed using arrays A/r, (up) and Aipius) for every proper prefix and suffix of u such that. u,u, = u. Finally, the matrix Mi(u) can be obtained as: Mi(U) = Li @I Z&(U). (16) where Li is the same as Li with unitary elements on the diagonal. The same computational requirements discussed for the prefix upper-bounds are found for the island upper-bounds. Discussion and conclusions Several proposals have been advanced in the ASR lit- erature for the use of A*-like algorithms, based on the integration of acoustic and syntactic upper-bounds to drive the search process toward both acoustically and syntactically promising analyses. Different degrees of approximation can be used in the computation of sl(AIop) in (3) depending on the available constraints on the sequences of words which can fill in the gaps. Of course, tighter constraints allow one to conceive a more informative heuristic function resulting in a more efficient A* algorithm. Syntactic upper-bounds have been recently proposed in [Jelinek and Lafferty, 19911 and [Corazza et al., 1991a] that can be used in ASR to find the most plau- sible word sequence (T that matches the input signal. 348 Perception This requires the maximization of the probability of the set of all the possible derivation trees spanning CT. In ASU, however, it is more interesting to find the most likely tree spanning c, which represents the best syntactic interpretation. In fact, different syntactic in- terpretations can support different system’s responses. In this paper a theoretical framework has been intro- duced for the computation of the latter type of syntac- tic upper-bounds, in case of partial analyses obtained by a monodirectional left-to-right parser or by a bidi- rectional island-driven parser. Motivations for the use of island-driven parsing strategies in automatic speech processing have been presented in [Woods, 19821. In fact island-driven flexibility allows the introduction of optimal heuristics that, when used with monodirec- tional parsing strategies, do not guarantee admissibil- ity. Given the optimization function corresponding to the greatest probability of a derivation, the proposed syntactic scoring function is optimal. To see this, note that the analysis process can be intended as a search on a tree in which every internal node corresponds to a. partial derivation and every leaf node corresponds to a complete derivation of a sentence in the language; for each internal node, its children represent the deriva.- tions that can be obtained from it in one parsing step. It can be shown (see [Nilsson, 19821) that the num- ber of nodes explored in such a search is the minimal one whenever the scoring function employed defines an upper-bound which is as tight as possible. The syn- tactic scoring function we have proposed is the best conceivable one: in fact, for any internal node it re- sults in the largest value of the optimization function computed on all possible solutions tl1a.t can be reached from that node. In comparison with ASR, note that the ASR scoring functions proposed in [Jelinek and Lafferty, 19911 and [Corazza et al., 1991a] are defined by the sum of the values obtained by the optimiza.tion function on the reachable solutions: therefore, in prac- tical cases these scores are far from being the tightest ones. Unfortunately, for the optimization functions re- quired in ASR cases, better scoring functions present serious computational problems. As far as efficiency is concerned, two different steps must be distinguished in the computation of the stud- ied scoring function. In a previous section some re- lations have been introduced that can be computed off-line; the computation requires an amount of time that is quadratic in the number of productions in G,. Relations introduced in a following section must be computed on-line, because they depend on the ana- lyzed string u. The best derivation probability for u can be computed in an O(lPllu13) amount of time, while the computation of prefix, suffix and island probabilities takes O(max{lPJju13, lPJ2ju1}) time. In one-word extension of a previously analyzed string u, the score updating takes an amount of time which is w-=wl142~ lmw Finally, the proposed framework can be straightfor- wardly adapted to compute upper-bounds when the number of words necessary to complete the sentence is given. In this case, upper-bounds may be closer to the right values. Acknowledgements The authors are indebted to Roberto Gretter for his valuable comments on this paper and for his contribu- tion to this research. References Aho, A. V. and Ullman, J. D. 1972. The Theory of Pursing, Translation and Compiling, volume 1. Prentice-Hall, Englewood Cliffs, NJ. Corazza, A.; De Mori, R.; Gretter, R.; and Satta, G. 1991. Computation of the Maximum Probabil- ity of Partial Interpretations Generated by an Island- Driven Parser. Draft. Cora.zza, A.; De Mori, R.; Gretter, R.; and Satta, G. 1991a. Computation of Probabilities for a Stochastic Island-Driven Parser. IEEE Transactions on Pattern Anulysis and Machine Intelligence 13(9):936-950. Gonzales, R. C. and Thomason, M. G. 1978. Syntuc- tic Pattern Recognition. Addison-Wesley Publishing Company, Reading, MA. Harrison, M. A. 1978. Introduction to Formal Lun- guuge Theory. Addison-Wesley Publishing Company, Reading, MA. Jelinek, F. and Lafferty, J. D. 1991. Computation of the probability of initial substring generation by stochastic context free grammars. Computational Linguistic 17(3):315-323. Nilsson, N. J. 1982. Principles of Artificial Intelli- gelice, volume 1. Springer-Verlag, Berlin, Germany. Wetherell, C. S. 1980. Probabilistic Languages: A Re- view and Some Open Questions. Computing Surueys 12(4):361-379. Woods, W. A. 1982. Optimal Search Strategies for Speech Understanding Control. Artificial Intelligence 18(3):295-326. Corazza, De Mori, and Satta 349 | 1992 | 64 |
1,259 | A Computational Venu Govindaraju, Sargur N. Srihari, and David Sher Department of Computer Science 226 Bell Hall State University of New York at Buffalo Buffalo, New York 14260 USA Abstract The human face is an object that is easily located in complex scenes by infants and adults alike. Yet the de- velopment of an automated system to perform this task is extremely challenging. This paper is concerned with the development of a computational model for locat- ing human faces in newspaper photographs based on cognitive research in human perceptual development. In the process of learning to recognize objects in the visual world, one could assume that natural growth favors the development of the abilities to detect the more essential features first. Hence, a study of the progress of an infant’s visual abilities can be used to categorize the potential features in terms of their im- portance. The face locator developed by the authors takes a hypothesis gelaerate and test approach to the task of finding the locations of people’s faces in dig- itized pictures. Information from the accompanying caption is used in the verification phase. The system successfully located a.11 faces in 44 of the 60 (73%) test newspaper photographs. Introduction This paper is about developing a computational model for locating ’ human faces in photographs, guided by cognitive principles. Since the human brain is the most efficient visual system known, it would benefit a com- putational system to utilize the findings of cognitive research on human perceptual development. To render credibility to the subject of this research one must address the question of whether a human face is any more or less important than other objects in the visual world. If faces are “special”, then are they special enough to warrant the development of a *This work was supported in part by grants from the National Science Foundation (NSF IRI-86-13361) and East- man Kodak Company. ’ The terms “recognition” and “location” of faces are used synonymously throughout this paper. These terms are used to indicate the ability to distinguish any human face from other objects. It does not imply the ability to at,tach names to people’s faces. This latter ability will be referred to as “identification”. computational model nizing them? Surely, _ _ solely for the purpose of recog- this does not imply that com- putational models need to be developed for every con- ceivable object (books, trees, houses, etc.). Such an approach would undermine the foundations of the well established field of general object recognition which ad- vocates the development of general purpose computa- tional models that can be used too recognize a whole class of objects. There is ample evidence gathered from research in perceptual development of infants that huma.n beings do treat faces as “special” objects. The expertise of infants in the task of face recognition points to the pos- sible existence of a special face processing mechanism in the human brain. Therefore, developing a compu- tational model to do the same becomes an important problem within the purview of AI. After all, the field of AT deals with building programs for tasks of cognition performed by humans. In some sense, face recognition is as much a member of the family of AI problems as, say the problem of Natural Language Understanding, if not more so, because face perception is one of the first cognitive tasks that humans perform. Most of the computer vision research in the area of faces thus far, has focused on “identifying” a well- framed face when given a pre-stored set of labeled faces. The task of “locating” a generic human face in a cluttered background has been relatively unexplored [Govindaraju et ad., 19901. The few references to face location [Baron, 1979, Lambert, 19871 are limited to cases where the background is benign and there is a single face in the scene. Newspaper photographs have been chosen to serve as a test bed for the computational model. The choice is motivated by several reasons. Newspaper photographs provide a rich source of photographs of people. Since, the backgrounds are usually natural and cluttered, they truly represent the real life situ- ation, unlike photographs taken in laboratory simu- lated conditions [Lambert, 19871. Moreover, the rules of photo-journalism can be used to advantage as they impose certain constraints on the types of photographs which can appear in newspapers [Arnold, 19691. Faces 350 Perception From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. identified by the caption are clearly depicted without occlusion and usually contrast well against the back- ground. Information derived from the accompanying caption can aid the processing of the photograph. For instance, the caption gives a clue to the number of people in the photograph along with their spatial ar- rangement [Srihari, 19911. This paper discusses the cognitive and computa- tional aspects of a system that can locate faces in news- paper photographs. The system successfully located all the faces mentioned in the caption in 44 of the 60 newspaper photographs (73%) it was tested on. Input to the face Zocatin.g system is a digitized news- paper photograph (Figure la). A hypothesis generate and test paradigm has been adopted to process the photograph and output the locations of the faces (Fig- ure 111). Figures la to If show the various stages in the hypothesis generation phase. Moment based filters are used to reject obvious non-faces (Figure lg). The caption of the photograph: “Bernard and Mai Bar- low with her daughter Nguyen Thi Ngoc Linh in Linh in Leominister Massachusetts”, tells the system that there are three people in the photograph. Heuristic rules are used to verify three of the four hypothesized candidates (Figure lh) [Srihari, 19911. The details per- taining to the implementation of the image processing routines have been published by the authors elsewhere [Govindaraju et al., 19901. Face specificity The evidence supporting the importance of face per- ception to humans is examined in order to establish face location by computers as an important AI prob- lem. To quote [Davies et al., 19811: “No other object in the visual world is quite so important to us as the hu- man face. Not only does it establish a person’s iden- tity, but also, through its paramount role in commu- nication, it commands our immediate attention.” Our ability to perceive and identify faces is so unusually good that it appears that we must have evolved a spe- cial face processing mechanism. [Davies et al., 19811 argue that not only is the face recognition mechanism innate, a particular area in the brain is specially de- signed to handle ima.ges of faces. Their experiments indicate that faces can be quickly processed and later recalled despite small transformations, even after long intervals of time. [Yin, 19691 has demonstrated that inverting faces affects their recognition to a greater ex- tent than inverting other mono-oriented stimulus. He concludes that the peculiar behavior of perception with respect, to faces somehow implies that they are treated specially. [Perett et al., 19791 report evidence for the presence of cells in the temporal lobe of the rhesus monkey that responds only to facial images. Around the same time, [Rosenfield and Hoesen, 19791 suggested that even in a comparatively lower level of primate development there is a capacity to abstract the essential characteristics of a face. How our facility for storing and processing faces evolved is not exactly known. Obviously, accurate recognition of the other members of the same species is important for any animal that lives in social groups [Ellis, 19811. F or many species, olfactory identification is an important means of classifying group members from strangers and high dominance from low domi- nance animals. The higher primates, however appear to rely more on vision to make such classification. Al- though, face is by no means the only clue to identity, its involvement in emotional expression probably means that the face provides an important indication of indi- viduality. Cognitive perspective In the process of designing computational algorithms for the purpose of recognizing visual objects, one is confronted with the question of whether to pick feature A or feature B? Is it wise to look for eyes in order to recognize faces or is it more appropriate to look for oval blobs corresponding to the shape of an entire face? Typically, most sequential vision algorithms reduce the image data at every stage, as they move towards more symbolic representations. Hence, the question of which features should be used first, is vital to a computational model. We address such questions pertaining to the feature selection process from a cognitive perspective. Our approach is to take clues from the chronolog- ical sequence in which various features are used by humans in the process of attaining a fully matured faculty of face recognition. The perceptual abilities of a one-month old, for instance, are less developed than the abilities of a four-month old. Assuming that natural growth favors the development of the abilities to detect the more essential features first, a study of the progress of infant’s visual abilities before achiev- ing complete maturity, can be used to categorize the features in terms of their importance. Infant perception Experiments with the perceptual ability of infants is based on two part,icular patterns observed in their be- havior. First, if an infant does look at one stimuli more than the other, it can be concluded that the infant can tell the difference between the two stimuli. Secondly, if the infants are given a choice between familiar stimuli and a novel one, they prefer the novel stimuli. The infant habituates to the familiar stimuli by looking at it less and less. So, if stimuli A is presented repeatedly to the infant and after habituation, if stimuli B is pre- sented, the infant would look at B for a longer time if it can tell the difference between A and B. However, if the infant cannot tell the difference, it will continue to habituate on stimulus B. Following are some exper- imental inferences gathered from a review of literature in child psychology. Govindaraju, Srihari, and Sher 351 (4 (f) Figure 1: Face locators: (a) Newspaper photograph, (b) Edge image, (c) Spurious edges are filtered, fragmented pieces are linked and contours are segmented at corners, (d) Feature curves matched with model, (e) Face location hypothesis, (f) Gray level data extracted from hypothesized regions, (g) Filters reject some false candidates, (h) Caption and heuristic rules are used to select true candidates. (d 0-4 352 Perception 1. 2. 3. 4. 5. A one-month old child just begins to perceive dif- ferences in contrast. [Caron et a/., ] report that the edges of the face and the hair-line are the first fea- tures encoded by an infant. [Fantz, 1966, Stechler, 19641 claim that two-month old infants prefer a human face to any other stimu- lus. At about this age, their contrast sensitivity im- proves and they begin to fixate upon their mother’s eyes. A three- month old child is able to perceive finer details of facial expressions [Maurer and Salapatek, 19761. A four-month old child can distinguish proper ar- rangement of facial features from a scrambled face. [McCall and Kagan, 19671 also conclude that at this age the whole configuration of the face is encoded by the infant. [Davies eZ al., 19811 state that the emphasis of the infant’s fixation is first on the upper part of the face and later on the lower part. From cognition to computation In designing the recognition algorithms, several ap- proaches are plausible. One could work with gray- scale data, or edge-image data. Line drawings have the advantage of reducing the amount of data drasti- cally at the cost of some loss of information. Humans are good at interpreting line drawings suggesting that the shape information of an object is adequately cap- tured by this transformation [Marr, 19821. Moreover, the discussion above indicates that perhaps the first feature encoded by an infant is the edges of the face. Therefore, cognitive principles dictate that a face lo- cating system should choose the edges of the shape of a face as the primary feature. Since infants encode eyes and other face-specific features later, a computa- tional model can use these features after the the shape of faces is recognized. An AI methodology that accommodates the strategy of using different features at different stages is the Gen- erate and Test paradigm. A gray-scale image can be converted to an edge-image which captures the shapes of all the objects by an edge-detector (Figure lb). The hypothesis generation phase processes the edge data to find instances of matches between the edges and a pre- stored model (Figure 2). A number of false matches can occur in cluttered images, when edges spuriously align to match the shape of a face. The output of the generation phase is a set of candidates which mark locations in the image as plausible faces (Figure le). Since the hypothesis verification phase only examines the candidates returned by the generation phase, it is critical that the generation phase not miss any face, while allowing for false candidates. According to this criterion, features based on the edges are ideally suited. The verification phase examines the gray-level data within the hypothesized locations (Figure If) and searches for eyes. Presence of regions correspond- ing to eyes is confirmed by evaluating the spa- tial relations between pairs of dark regions in the hypothesized locations and the corresponding edges [Govindaraju et al., 19901. Once again, examining the configuration of facial features is aptly a postprocess- ing operation if one adheres to the chronology followed by infants. Developing a computational model based on cogni- tive principles does not necessarily guarantee an ef- ficient and accurate recognit#ion system. The human brain might be having access to hardware which mod- ern computers do not. However, our own analysis and experiments, indicate that at least in the task of face perception, efficiency and accuracy are not compro- mised by the cognitive approach. In fact, face lo- cating systems which are not cognitively motivated [Baron, 1979, Lambert, 19871 have been proven suc- cessful only in a limited domain of photographs where there is a single person featuring in plain background. Most of these methods use “eyes” as the primary fea- ture. Since eyes occupy a very small area in a photo- gra,ph, it is difficult to accurately locate them. How- ever, in a cognitive approach, eyes are searched for in small hypothesized regions during the verification phase, making the task more amenable. The criteria for selection of shape features has been extensively studied in computer vision literature [Marr, 19821. Features with small spatial extent are unreliable to compute (e.g., extracting eyes from gray- scale photographs). On the other hand, features with large spatial extent are sensitive to partial occlusion but easy to extract. Model of a generic face A generic face model is defined in terms of features based on the edges of the front view of a face (Fig- ure 2). Since, most newspaper photographs carry front view of faces of people mentioned by the cap- tion [Arnold, 19691, such a restriction is admissible for our purpose. However, our system can also handle side views of faces as the shape of the side view of a face is roughly the same as the front view. Hence the main constraint imposed by our system is that the people’s faces should be the primary subject of the photograph, implying that the faces must be in the focus of the camera. L, %,R correspond to the left side, the right side and the front view of a face. The chin-curve is not used because the chin rarely shows up in the edge-data. Furthermore, since the lower parts of a face are per- ceptually less significant [Davies et a/., 19811, ignoring the chin curve is cognitively justified. Anthropometric literature recommends the use of the golden ratio when generating an ideal face [Farkas and Munro, 19871. We define the relative sizes of features in terms of a ratio (golden ratio) thus ensuring scale independence of our methodology. Govindaraju, Srihari, and Sher 353 $- x (width) x (golden ratio) height _ = golden ratio width c-----------------------r width Figure 2: Feature curves: obtained from the generic shape of a human face. System implementation Implementation of the various modules of the hypoth- esis generation phase is briefly described in this sec- tion. Details of the implementation have been pub- lished in [Govindaraju et al., 19901. The system has three modules. The feature extraction module detects all instances of feature curves. The feature represen- tation module describes the scheme adopted for rep- resenting each feature curve. The feature matching module identifies groups of labeled features that can belong to a face. Feature extraction A string of image processing operations are applied to extract the features. The Marr-Hildreth operator is applied to obtain the edge image. A thinning algo- rithm is used to obtain a skeleton (structure) of the image. Contours provided by edge-detecting programs are often fragmented (Fig. lb). We have developed a method of linking neighboring contours based on their proximity and the consistency in their directions (Fig- ure lc). The corners in the contours are found by ob- taining the second derivatives. The corner points are used to segment contours into feature curves (Figure lc). Feature representation A feature curve is represented by a 4-tuple {A%,Q, .A, t} and labeled as one of {C,R,B). Let A and R be the end points of a feature curve; A and B can each be a terminal point of a contour or a corner point. A% is a vector corresponding to the chord of the curve; 0 is the angle made by A$ and the hori- zontal; ! is the length of the curve in pixels; 4 is the area enclosed by the curve and the chord in pixels. If 0 21 O” the curve is labeled as ?-t; if 0 25 90’ the curve is labeled as C or R. The direction of concavity of the curve determines whether it corresponds to the left- side (,G) or right-side (R) of the face (Figure 2). If the label of a. feature curve cannot be conclusively deter- 354 Perception mined (X), the labels of adjacent feature curves are used to constrain its label. One such constraining rule is illustrated in Figure 3. Feature matching Extracted features are matched against the model using a mathematical framework of templates and springs [Fischler and Elschlager, 19731. The templates are rigid and correspond to labeled feature curves while the springs capture the spatial relations between the templates. The springs “pull” and “push” to align the image features with the model. The work done in the alignment process gives a measure of the “goodness” of the match. Experiments and evaluation The system takes an observation (edges, geometry of features etc.) of the sensory events (pixels in a small area of the image, whose size depends on the expected size of a face) and makes a decision whether the area contains only random activity (noise) or signal (a face) as well. The system can decide a face when a face is actually present (hit); it can decide noise when a face is actually present (miss); it can decide a face when no face is present (false alarm); and it can decide noise when when no face is present (correct rejection). To avoid subjectivity, we consider all faces mentioned by the caption as identifiable. We record a “hit” if the position of the face is marked by a box which at least encloses the eyes of the face but is no larger than twice the area of the face. If we consider the unit of evaluation as an entire picture and let n be the number of faces, we can define the measures of performance in the following way. Performance SU : Success All identifiable faces are ‘hit’ PS : Partial Success At least half the faces are ‘hit’ ER : Error Less than half the faces are ‘hit’ Rule i H H if a feature contour of unknown label (X) is vertical (0 M 90’) and is connected to a feature contour labeled H above it then label X - L if X is to the left of H and label X E R otherwise Figure 3: Typical rules from the feature labeling rule based system. The system was trained on a set of 20 pictures where training-constitutes tuning the various program param- eters. The system was tested on a set of 60 newspaper photographs 2. During the testing phase none of the parameters were altered. Out of 60 test pictures, the system located all the faces featuring in 44 of the pic- tures (SU: 73%); the system failed to locate at least half the identifiable faces in 12 pictures (ER: 20%). There were 90 faces distributed among the 60 test pic- tures. The system located 68 of the those faces (76%). On average, approximately two false alarms were gen- erated per picture and approximately 1 false alarm per face. If a picture had a single face, our system success- fully located the only face 83% of the time. References Arnold, E.C. 1969. Modern Newspaper Design.. Harper and Row, New York, NY. Baron, R.J. 1979. Mechanisms of human facial recog- nition. Master’s thesis, Department of Computer Sci- ence, University of Iowa. Caron, A.L.; Caron, R.F.; Caldwell, R.C.; and Weiss, S.E. 1973. Infant perception of the structural proper- ties of the face. Developmental Psychology 9:385-399. Davies, G.; Ellis, H.; and Shepherd, J., editors 1981. Perceiving and Remembering Faces. Academic Press. Ellis, H. 1981. Perceiving and Remembering Faces. Academic Press. chapter Theoretical aspects of faces recognition. Fantz, R.L. 1966. Perceptual Development in Chil- dren. International IJrliversity Press, New York. chap- ter Pattern discriminat,ion and selective attention as determinants of perceptual development from birth. 2 Collected from the The Bq&lo News of January 1991. Farkas, L.G. and Munro, I.R. 1987. Anthropometric facial proportions in medicine. Charles C Thomas, Springfield, USA. Fischler, M.A. and Elschlager, R. A. 1973. The repre- sentation and matching of pictorial structures. IEEE Transactions on Computer c-22( 1). Govindaraju, V.; Srihari, S.N.; and Sher, D.B. 1990. A computational model for face location. In Third In- ternational Conference on Computer Vision, Osaka, Japan. IEEE-CS. 718-721. Lambert, L.C. 1987. Evaluation and enhancement of the AFIT autonomous face recognition machine. Master’s thesis, Air Force Institute of Technology. Marr, D. 1982. Vision. W.H. Freeman and Company, San Fransisco. Maurer, D. and Salapatek, P. 1976. Development changes in scanning of faces by young infants. Child Development 471523-527. McCall, R.B. and Kagan, J. 1967. Attention in the infant: Effects of complexity, contour, perimeter, and familiarity. Child Development 38:987-990. Perett, D.E.; Rolls, E.T.; and Caan, W. 1979. Vi- sual cells in the temporal lobe selectively responsive to facial features. In European Conference on Visual Perception, The Netherlands. Rosenfield, S.A. and Hoesen, G.W. Van 1979. Face recognition in rhesus monkey. Neuropsychologia 17:503-509. Srihari, R. 1991. Piction: A system that uses caption to label human faces in newspaper photographs. In Proceedings of the AAAI. 80-85. Stechler, G. 1964. Newborn attention as affected by labor. Science 144:315-317. Yin, R.K. 1969. Looking at up-side down faces. Jour- nal of Experimental Psychology 81:141-145. Govinclaraju, Srihari, and Sher 355 | 1992 | 65 |
1,260 | Yibing Yang and Alan Yuille Division of Applied Sciences Harvard University Cambridge, MA 02138 yibing@hrl.harvard.edu Abstract The instantaneous image motion field due to a camera moving through a static environment en- codes information about ego-motion and environ- mental layout. For pure translational motion, the motion field has a unique point termed focus of expansion/contraction where the image velocity vanishes. We reveal the fact that for an arbi- trary 3D motion the zero-velocity points, whose number can be large, have the regularity of be- ing approximately cocircular. More generally, all the image points with the same velocity u are lo- cated approximately on a circle (termed the iso- velocity circle (IVC)) determined solely by u and the ego-motion, except for the pathological cases in which the circle degenerates into a straight line. While IVCs can be recovered from 3 or more pairs of iso-velocity points in the motion field using a linear method, estimating ego-motion reduces to solving systems of linear equations constraining iso-velocity point pairs (Yang 1992). Introduction When a camera moves through a fixed environment, the image points are endowed velocities, resulting in a time-varying motion field. A monocular observer can make use of the motion field information to recover the shapes of the objects and the motion relative to it (Gib- son 1950). Mathematical studies further show that in general motion and relative depth are uniquely deter- mined by the instantaneous motion field (Horn 1987). It has be found difficult, however, to bestow a com- puter the ability of ego-motion recovery, despite many efforts (e.g., (Longuet-Higgins & Prazdny 198O)(Wax- man & Ullman 1985) (Jepson & Heeger 1991)). The main difficulty comes from the highly nonlinear rela- tionship between the observables (i.e., the motion field values) and the unknowns (i.e., motion and depth). *This research was supported in part by the Brown/Harvard/MIT Center for Intelligent Control Sys- tems with U.S. Army Research Office grant number DAAL03-86-K-0171. 356 Perception The Gestalt psychologists have formulated a number of principles of perceptual organization among which are grouping by proximity and grouping by common fate (Koflka 1935). We would rather refer grouping to grouping by proximity but applied to two conju- gate spaces, the image space and the velocity space. It is generally believed that the Gestalt laws may work because they reflect sensible assumptions that can be made about the world of physical and biological objects (Marr 1982). For example, because matter is cohesive, adjacent regions are likely to belong together and move together. In this paper, we will demonstrate the usage of grouping iso-velocity points (IVPs) for ego-motion per- ception, thanks to the constraints resulting from the rigid environment assumption. As a theoretical con- tribution of this work, the Iso-Velocity Point Theo- rem reveals the fact that any image point of velocity u must lie approximately on a semi-circle termed the iso-velocity circle (NC) which is determined by the motion and the velocity u. With the geometry of the circle not dependent on depth information, structure and motion are segregated. (For the pathological cir- cumstances of ego-motion, the circle may degenerate into a straight line.) Applicable to any 3D ego-motion and rigid surfaces, this theorem provides new insight into the image motion perceived by a moving observer. Our other contribution is a computer algorithm for motion/structure from optical flow. The proposed al- gorithm computes the IVCs from three or more pairs of IVPs, thus eliminating the need of identifying at least. three IVPs in order to determine a single IVC. The computation of ego-motion, separated from a subse- quent depth recovery procedure, involves no differenti- ating/searching/iterating but grouping IVP pairs and solving systems of largely over-constrained Zineurequa- tions each of which is specified by one pair of IVPs. Motion Field Motion Field Equation Like many researchers, we adopt a camera-based co- ordinate system with the origin being the projection center and the optical axis running along the Z-axis. From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Under perspective projection, a world point P = (X, Y, Z’)T is imaged at p = (g, y, f>* = ;P, where f is the focal length. Suppose the camera moves with in- stantaneous translational velocity t = (tz, t,, tt)T and rotational velocity r = (Ye:, ry, r,)* relative to a static environment. Then the induced image velocity at p is where i is the unit vector in the Z-direction. This is the well-known motion field equation which specifies the image velocity Ij as a function of motion {t, r} and depth 2, as well as the image position p. To gain more insight into the relation between Ij and p, we rewrite the motion field equation in the following form: MF pers : u = f -lx wherex=(z,y)Tandu=(u,V)T=f-lx. Ifboththe translational velocity t and depth Z are magnified or reduced by the same factor, the motion field remains unchanged. This scale factor ambiguity shows that the absolute magnitude of the translational motion is not encoded in the motion field. Only the relative values ts/tL, t,/t, and Z/t, take effects, assuming t, # 0. Suppose the image size is Ii pixels. The objective of motion recovery is to estimate the 5 motion parame- ters {t,/t,, t,/t,, rz, py, rr}, and the K relative depth values, given the 2K image velocity values {uk, viz}. Motion Fields in A Small Field of View The motion field value in eq. (1) is quadratic in x for constant depth. If the field of view (FOV) is sufficiently small,l or maxllxll/f < 1 in the image, then the mo- tion field equation can be expressed in the following simplified form: MF para : u = b/Z rp -r 2 b/Z The above equation holds if world point P is mapped to the image point p under the so-called puruperspective projection (Ohta et al. 1981)(Aloimonos 1988) which is an approximation of perspective projection under the condition of small FOV. Note that if we further assume lateral translation, i.e., t, = 0, then we get the motion field equation under ‘The visual information within a small FOV is of par- ticular importance. The human eye has much better reso- lution near the optical axis. It has a high-resolution fovea where over a lo range the resolution is better by an order of magnitude than that in the periphery. orthographic projection: MF,,th : u = by - b/Z - ry -rzx - t,/Z + r, > (3) This motion field is ambiguous (up to scale); differ- ent motion/structures can give rise to the same mo- tion field. Indeed, if rz:, ry, Z are replaced by rk = rz + cty , r; = rY - ct,, Z’ = (c + l/Z)-l, (c = const.) respectively, then MF,,th remains unchanged. In this case, it is well understood that motion/structure can be recovered from the position information of features at three or more time instants (Ullman 1979). Fixed Points on Image A well-known fact concerning the pure translational motion is the existence of a unique image point called the focus of expansion/contraction (FOE) where the image velocity vanishes. Viewing MFpers as an au- tonomous differential equation system, we expect more than one fixed points in the general case that 1: # 0. Local analysis has shown the fixed points contain useful information about the ego-motion (Verri et al. 1989). What we are going to explore in this paper is the global regularity of the fixed points. Let us consider the fixed points of MFpara, catego- rizing them (Jordan 1987) in the extreme cases. When Z --, 00, we have u - (rzy/f - ry, -rzx/f + rz)T The motion field looks as if it were induced by pure rotation, It has a unique fixed point x = g+w=y)*, which is obviously a center. On the other hand, as Z + 0, we have u - &x/f - WzYlf - t,y In this case, the rotational effects are negligible and the unique fixed point is a node x = E(&, t,)T, corre- sponding to the direction of translation. At any image position, the image velocity points to this node. Definition. The point N k (tz, ty)T f/tz on the image plane is called the node of translation and the point C !? h QTf lrt ? the center of rotation. As a matter of fact, the node of translation has the same definition as the FOE. We deem it neces- sary to give a new name in order to avoid confusion, because conventionally the latter is used only in the context of pure translation. The center of rotation is the rotational counterpart of the FOE which has been largely overlooked in the computer vision community. Although C by itself is linked to the trivial case of pure rotational motion, the alliance of C with N will prove very useful for characterizing general motion, as illustrated below. Theorem 1. All fixed points of MFpara lie exclu- sively on one of the two semi-circles defined by N and C. Yang and Yuille 357 Proof. The key to the proof is the observation that in eq. (Z), matrix + specifies a similitude. Let < = x + iY, IJ = u + iv be the complex representations of x and U, respectively. Then eq.- (2) can be rewritten as p = (t%/z-ir,)f-l~-t,/Z-r,+i(-t,/Z+r,) (4) Let /..J = 0 and then the fixed point is &) = (tx + it,) + (CJ - ir”)Zf t, - ir, Z Notice that the depth 2 takes values on the real axis (of the complex plane) only and 2 is mapped to i by a bilinear transformation which maps a straight line - to a circle biuniformly. When 2 changes from 0 to 00, i changes accordingly from <N = (& + ;tY)f/tz to tc = (TX + &Ml T, on a circle which has a diameter specified by [N and tC. Clearly, [N and tC are the complex representations of N and C, respectively. ho-Velocity Points Theorem Inspired by the regularity obeyed by the fixed points, we proceed to investigate the iso-velocity points (IVPs) of an arbitrary velocity. Roughly speaking, the relation between a fixed point and an IVP is like the relation between a zero-crossing and a level-crossing. Iso-Velocity Circles We shall show that all the IVPs of MFpers are approx- imately co-circular and all the IVPs of MFpora are ex- actly co-circular. Here an important question that has to be answered is how good the approximation is. Theorem 2. (Iso-Velocity Points Theorem: Non- degenerate case). All the IVPs Xu = (x : u(x) = u, llxll/f 5 7) of MFpers are nearly co-circular in the sense that for any x E Zu, there is a point Cu,x within the circle centered at Cu = C + (-v, u)* f/r, with radius 8 = 2 angle with respect~t~~(asnudchcthat x spans the right u,x (see Fig. 1). Proof Eq. (1) can be rewritten as u = -tx/z - ry +t,z/(Zf) + w//f + 6 (5) V =-tY/Z+rS- r.z x/f + tJ Yl(Zf) + v” (6) where (5, G)* = fm2 ulations yield XX* ( -rY , rs)T. Algebraic manip- t, r,z ( x - tzfltz y - tyf /t, > ( = -y + (r9 + u - G)f/rZ 2 - (Tz - v + qf /rz > Notice that the LHS can be written as (X-N)t, /(rdZ) and the RHS is perpendicular to (x - Cu,x), where G.l,x = kX - v + G)f/b (ry + u - iif/rz Hence we have (x - N) -L (x - Cu,x) Figure 1: The iso-velocity circle. From eq. (7) we get IlCw- Cull = II+, -gq = jlf$xx*(-r,, rzy]l t This completes the proof. As illustrated in Fig. 1, the IVPs are located approx- imately on a circle defined by N and CU. The former is independent of u and the latter is not. The circle is centered at MU = (N + Cu)/2 and has a radius Ru = IlN - C,ll/2. We denote the IVC as {N, Cu} or {Wdh}. Theorem 2 shows that the relative uncertainty of Cpx has an upper bound proportional to the square of the FOV value (i.e., maxIIxll/f) and the magnitude of the center of rotation. Therefore, the uncertainty of both the center and the radius of the IVC is ~2~~C~~/2. Points on the Iso-Velocity Circle Since eq. (2) corresponds to G = G = 0 in eqs. (5) and (6), the IVPs of MFpara lie exactly on the IVC . For ease of discussion, we now concentrate on the study of the behavior of the IVPs of MFpara rather than those of MFpers. Exactly speaking, the IVPs can be located on only half of the circle, specified by N and Cu, because of the positive-definiteness of depth 2. Let xu denote an image point with velocity u. The position of xu on the IVC (N, Cu} encodes the depth information Z(xu). Theorem 3. If at image position xu the image velocity of MFpara is u and the depth value is 2, then on the IVC {MU, Ru} the angular position of xu is LxuMuN = 2arctan2(t, /Z, Pi). Proof. We know that eq. (2) can be written as eq. (4 Or ( = (tx + ity) + (rp + u - i(rx - v))Z f t, - ir, Z 358 Perception Without loss of generality, we assume vector CUN points to the positive direction of the x-axis. (We can always achieve this configuration by rotating the viewer-based coordinate system around the optical axis.) Let N = B + C + iA and Cu = B - C + iA, where C > 0. Then the above equation reduces to ~ = iA + (B + C,:% - ii~~- C)rzZ t- % Since the IVC is centered at Mu = B + iA we have L[MUN = L(t - Mu) = L C(t, + ir,Z) t .z- ir,Z Because C is assumed to be positive, the angular po- sition of xu is LxuMuN = 2arctan2(t,/Z, rz) This completes the proof. It is worth emphasizing that the angular position of xu does not change with-u. As 2 increases from 0 to 00, xu(Z) moves% the counterclockwise (clockwise) direction from N to Cu if t, and rz have the same (op- posite) sign. When 2 is small, 0 changes linearly with 2; as 2 becomes bigger, 8 gradually approaches the saturation value r. As a result, the angular variation of xu does not depend solely on the depth variation. Obviously, the co-circular property is a necessary condition and does not mean-that points on the 1% have the same velocity. Suppose x is a point on the IVC (N, C,} with angular position ~9, then u(x) = Q only if Z(x) = t, tan O/r,. For this reason, it is possible that no point on {N, C,} has image velocity u(x) = LY. Especially, the motion field can have no fixed points. Degenerate Cases Up to now we have assumed that tzro # 0; otherwise the IVC does not exist. Here we discuss the degenerate cases where either tt or rz vanishes. Theorem 4. (Iso-Velocity Points Theorem: Degen- erate cases). (A) If rz = 0, t, # 0, then all the IVPs xu = {x : u(x) = u, x/f 5 7) of MFpers lie approx- imately on the straight line passing through N with direction cIU = u - (GY, -r,)*-in the-sense that for any x E Xu, there is a point du,x, lldu,x - dull 5 ~~ljrll, such that the triple points N, N+du,x, x are collinear. (B) If t, = 0, r, # 0, then all the IVPs Xu = (x : u(x) = u, llxll/f 5 r} of MFpers lie approximately on the straight line passing through Cu with direction d = (-ty , t,)* in the sense that for any x E Xu, there is a point Cu,x, (ICu,x - Cull 5 ~~IlCll, such that the triple points Cu,x, Cu,x + d, x are collinear. Proof Similar to that of Theorem 2. For a 3D motion with either lateral translation or lateral rotation, the IVC degenerates to the iso-velocity line (IVL). When rt = 0 the IVLs intersect at N; when t, = 0 the IVLs are perpendicular to t. As indicated before, orthographic projection corresponds to para- perspective projection plus lateral translation. Hence the iso-velocity points of MF,,.th are (exactly) collinear and the IVLs are perpendicular to the translational di- rection. Numerical Evaluations To gain some empirical understanding, we solve the motion field equation for a sequence of depth values. Without loss of generality we assume$’ = 1. For mo- tion t = (2,O,lO)*,r = tersect at N = (.2, O)T. (-3, -5,10) , the IVCs in- The three IVCs shown in Fig. 2 (left) correspond to different velocities ~11 = (wqT,U2 = (4,l)*,w = (8, -l)*. For each and ev- ery velocity uj, we compute a set of image positions % = (xj,k) corresponding to Zk = tz/rZ tan&/2, where 01~ = /en/lo, X: = -9, -8,. . . ,8,9,10, by solving - eq. (1). (Somewhat remarkably, the solution is unique for each 2.) Points in Xj , j = 1,2,3 are denoted by 0, +, x respectively. We can see that the quadratic term in eq: (1) makes the IVPs deviate more or less from the IVCs. The deviations can hardly be perceived in the vicinity of the origin. In Fig. 2 (right) we show the angle Bj,, = Lxj,kMjN VS. depth Zk. Without the quadratic term in eq. (l), 0 should be an arctangent function of 2. Summary For a given image velocity, the contributions from mo- tion and depth can be segregated; motion determines the circle which is the set of feasible image positions having that velocity and depth affects the relative po- sition on that circle. Our results obtained so far are illustrated in the following row implies approximation diagram where the gray ar- iso-velocity points Ego-Motion The recovery of ego-motion/structure from noisy mea- surements of motion field is an important problems in machine vision which has been intensively studied in the past two decades. Thanks to the Iso-Velocity Point Theorem, the task can be accomplished by first esti- mating the five motion parameters N, r. We will show two important results: (A) the IVCs can be estimated from pairs of IVPs and (B) the problem of ego-motion recovery reduces to solving two systems of linear equa- tions. Yang and Yuille 359 Computing WCs An IVC can be estimated from a set of three or more IVPs. Problem arises when the motion field may have only pairs of IVPs or in other words, there may only be two-fold overlapping in the velocity space (see Fig. 3 (upper-right) for an appreciation of the uv-space). As a matter of fact, the IVCs can be computed from (three or more) pairs of IVPs. Let u’ = (-v, u)*, X = f/(2rd). The center of an IVC can be written as (see Fig. 1 j Mu = M+ Xul , where X and M = (Ad,, My)* are to be solved. Suppose xu = (x, y)* and x& are a pair of IVPs and jzu = (xu + xu’)/2. Then we have MU- Zulxu - XL Therefore the inner product of LHS and RHS is zero: ( Mx - Av - (x + q/a My + Au - (y + !/j/2 ).( ;$)=o Let w = (X - x’, y - y’, (y - y’ju - (x - x’)v) and h= f(~” + y2 + x’~ + Y’~). Then we get w(M~,Iw,J)* = h (8) With each pair of IVPs providing such a constraint, M and X can be solved from at least 3 pairs of IVPs. In practice, we often have a large number of IVP pairs and thus we can resort to a Least Squares (ES) estimator or a robust estimator. In the following we use the LS method. In order to treat all sample pairs equally, eq. (8) needs to be normalized before computing pseudo- inverse. Computing Ego-Motion After been solved for, M and X may be used to com- pute N and C. The idea is to remove the motion field component induced by camera rod1 which is now known. By virtues of Theorem 4, the resulting mo- tion field have IVPs collinear with the node of transla- tion. By estimating the intersection of (two or more) straight lines passing through pairs of IVPs we can lo- cate N. Then we can solve for r easily, noting that C=2M-N. Experiments With the 256 x 256 depth map shown as an intensity image in Fig. 3 (upper-left), a motion field u = u(x) is generated for the camera to move at t = (-1, 0, lo)* and r = (O,l,lO) T. The focal length is 5 times the image size or FOV=11.42O. The interior orientation of the camera is a such that the optical axis passes through the image center. Each image grid point x is mapped to u(x) in the velocity space shown in Fig. 3 (upper-right) (note the folding). The IVPs are com- puted from the manifolds of constant u and constant v. In Fig. 3 (lower-left), conjugate IVPs are linked by line segments. We solve for M, X using the LS method and get M = (-53.54,67.10)*,X = 60.95 (in cells). After removing the flow component induced by cam- era roll, the resulting flowfield has the IVPs shown in Fig. 3 (lower-right). Clearly the IVLs seem to inter- sect at a common point. Apply the LS technique again and we get N = (-126.85,19.44)* (in cells). More ex- periments can be found in (Yang 1992). Concluding Remarks We have seen that the image points with the same velocity provide useful information for motion per- ception. The IVPs corresponding to ego-motion can be distinguished from those corresponding to indepen- dently moving objects by taking into account contin- gency in the image space. While the latter indicate exterior motion(s), the former can be used for recover- ing ego-motion in an efficient, stable way. References Aloimonos, J. 1988. Shape from texture. Biological Cyberbetics. 58:345-360. Gibson, J.J. 1950. The Perception of the Visual World. Boston, MA: Houghton Mifflin. Horn, B.K.P. 1987. Motion fields are hardly ever am- biguous. Int. Journal of Computer Vision. 11259-274. Jepson, A.D. & Heeger, D.J. 1991. A fast subspace algorithm for recovering rigid motion. In Proc. IEEE Workshop on Visual Motion. 124-131. Princeton, NJ. Jordan, D.W. 1987. Nonlinear Differential Equations. New York: Oxford University Press. Koffka, K. 1935. Principles of Gestalt Psychology. New York: Harcourt Brace. Longuet-Higgins, H.C. & Prazdny, K. 1980. The in- terpretation of a moving retinal image. Proceedings of the Royal Society of London B. 208:385-397. Maybank, S.J. 1985. The angular velocity associated with the optical flow field arising from motion though a rigid environment. Proceedings of the Royal Society of London A. 401:317-326. Marr, D. 1982. Vision. San Francisco: W.H. Freeman and Co. Ohta, Y.K., Maenobu, K. & Sakai, T. 1981. Obtain- ing surface orientation from texels under perspective projection. In Proc. Int. Joint Conf. Artif. Intell. 746-75 1. Vancouver, Canada. Ullman, S. 1979. The Interpretation of Visual Motion. Cambridge, MA: MIT Press. Verri, A., Girosi, F. & Torre, V. 1989. Mathematical properties of the 2-D motion field: from singular points to motion parameters, J. Opt. Sot. Amer. Waxman, A.M. & Ullman, S. 1985. Surface structure and 3-D motion from image flow: A kinematic analysis. Int. Journal of Robotics Research. 4(3):72-94. Yang, Y. 1992. Ph.D. diss., Division of Applied Sci- ences, Harvard Univ. Forthcoming. 360 Perception ‘*, -02 - i : e + ‘Y I .:+ 1” / . .i. : ? ‘.* .,” ,...!i’ ‘O -0.4 - \ 9, i *.. j ii e -0.6 - I. ” !. . ,I -0.6 -0.4 -02 0 0.2 0.4 0.6 150 - loo- 50- f 0 -“““- -50 - -ml- -HO- -2001 I -8 -6 4 -2 0 2 4 6 8 x/f Z Figure 2: IVPs and IVCs (left) and angular positions (right). Figure 3: Computing the node of translation. Yang and Yuille 361 | 1992 | 66 |
1,261 | ter co regg Collins and Louise ryor The Institute for the Learning Sciences Northwestern University 1890 Maple Avenue, Evanston IL 60201 colIins@ils.nwu.edu, pryor@ils.nwu.edu Abstract One of the most common modifications made to the stan- dard STRIPS action representation is the inclusion of filter conditions. A key function of such filter conditions is to distinguish between operators that represent different context-dependent effects for the same action. We con- sider how filter conditions may be used to provide this functionality in a complete and correct partial order plan- ner. We conclude that they are not effective, and that in general the use of filter conditions is incompatible with the basic assumptions that lie behind partial order plan- ning. We present an alternative mechanism, using the secondary preconditions of Pednault (1988, 1991) to represent context-dependent effects. The use of sec- ondary preconditions is effective, and preserves com- pleteness and correctness. Planning algorithms that are designed to possess desirable theoretical properties tend to ignore many of the functional considerations faced by practical planners. In particular, planners whose purpose is to demonstrate provably com- plete and correct algorithms (Chapman 1987, McAllester & Rosenblitt 1991), use a highly restricted version of the standard STRIPS1 action representation (Fikes & Nilsson 1971). In contrast, many planners that are intended for practical use introduce extensions to the basic representa- tion, notably filter conditions (Tate 1977, Wilkins 1988, Currie & Tate 1991). In this paper we investigate the ef- fects of adding filter conditions to a provably complete and correct planner, and present an alternative mechanism that provides much of the same functionality in a cleaner and more efficient way. I. I Filter conditions Afilter condition for an action is a precondition that does not become a new subgoal. Typical uses of filter condi- tions include the following: ‘In the basic STRIPS representation, an action consists of a name, a list of preconditions, a list of states that will be true after the successful execution of the action (the add list) and a list of states that will cease to be true after the successful ex- ecution of the action (the delete list). In the Char&k & McDermott (1985) version of the blocks world, the operator to move an object has the filter condition the object is a block. In SIPE (Wilkins 1988), the operator that fetches ob- jects from room1 has the filter condition the object is in room 1. In O-Plan (Currie & Tate 1991), the operator for a particular method of oil rig construction has the filter condition the soil type is sandy. In general, filter conditions are used to judge the applica- bility of an operator. If an operator has filter conditions that are not already true in the current partial plan the use of the operator is ruled out. Filter conditions are thus treated very differently from ordinary preconditions, which become new subgoals to be achieved through subsequent planning. In this paper we consider the use of filter condi- tions in accounting for context-dependent effects, although they have been used for several other purposes as well (Collins $ Pryor 1992). Filter conditions account for context-dependent effects by distinguishing between otherwise similar action repre- sentations so that the correct effects can be represented. For example, in the blocks world the operator for picking up a block that is supported by another block clears that block, while the operator for picking up a block that is supported by the table has no equivalent effect (since the table is al- ways considered to be clear). In order to ensure that the cor- rect effects are asserted, Charniak & McDermott (1985) define two pickup operators, one with the filter condition (on ?X table), and the other with the filter condition (on ?X ?other) where ?other is constrained to be another block. We have investigated the implementation of filter condi- tions in a complete and correct partial order planner. Our conclusion is that any such implementation fails to achieve the intended functionality of filter conditions. However, another extension to the basic STRIPS represen- tation, secondary preconditions (Pednault 1988,1991), can be integrated into the planner in a natural way, and pro- vides the desired functionality in respect of context- dependent effects. We have implemented secondary precon- ditions in the partial order planner, and present a compari- Collins and Pryor 375 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. A set of steps The actions to be executed. A set of open conditions States to be achieved. A set of links Each link is of the form (step7 state stepz), where state is required for the execution of step;! and is achieved by stepl. A partial ordering Ordering constraints on the steps. A list of unsafe links Those links for which there is a step (the clobbering step) that could potentially (according to the partial ordering) be executed be- tween srep 7 and step2 and that would unachieve state. A set of codesignation Required or forbidden bindings for constraints the variables in the partial plan. Figure 1: The structure of partial plans son of the efficiency of filter conditions and secondary pre- conditions in accounting for context-dependent effects. I.2 The basic algorithm Our investigations were carried out using the systematic non-linear planner (SNLP), which was written by Barrett, Soderland & Weld (1991) using the algorithm of McAllester & Rosenblitt (1991). The basic action repre- sentation in SNLP is the usual STRIPS representation with preconditions, add list and delete list, augmented by codes- ignation constraints on the variables (Chapman 1987). SNLP operates by searching the space of partial plans (figure 1). The basic algorithm is: 0 The most promising partial plan is chosen from the search queue. * If the partial plan is complete the search process is terminated and the resulting plan is returned. . If there are any unsafe links, one such link is removed from the unsafe list and each modification shown in figure 2 is attempted. Each successful modification produces a new partial plan, which is added to the search queue. Links made unsafe due to the modifica- tion are added to the unsafe list. 0 Otherwise, there is at least one open precondition, for Promotion Introduce an ordering to ensure that the clob- bering step occurs after the step at the end of the unsafe link. Demotion Introduce an ordering to ensure that the clob- bering step occurs before the step at the begin- ning of the unsafe link. Separation Introduce codesignation constraints to ensure that the state resulting from the clobbering step cannot unify with the state in the unsafe link. Figure 2: Modifications for unsafe links Add new Find an operator with a proposition in its add list Step that can be unified with the open condition. Make the operator the new step, add its preconditions to the list of open conditions, and add its codesigna- tion constraints. Add a link from the new step to the unenabled step. Add new Find a step with a proposition in its add list that can link be unified with the open condition. Add a link from the found step to the unenabled step. Add link Add the bindings necessary for the unification to the set of codesignation constraints. Make the appropriate ordering constraint. Figure 3: Modifications for open preconditions a step that is therefore not yet enabled. One such pre- condition is removed from the open list and each modification shown in figure 3 is attempted. Each successful modification produces a new partial plan, which is added to the search queue. Links made unsafe due to the modification are added to the unsafe list. nce evaluation lanning algorithms described in this paper on an artificial domain designed to highlight the effects of operator selection on planning efficiency. The domain con- sists of a series of tiers, each of which can hold an infinite number of blocks. Each block may be in any of six orien- tations (like dice) (figure 4). There is just one type of ac- ti ise moves a block up a tier while changing its ori- entation by a quarter turn to the next position in a cycle of the six. In order to move a block from a tier, there must be another block on the same tier (no tier may be left empty as the re- sult of a move). Goals are expressed as a required position, for example (on A tier3). In this domain loops are impossi- ble, and there are no unachievable subgoals or expensive actions. Figure 5 shows two of the operators in this do- I Tier 1 In order to move block D to Tier 3, one of A&C must be moved first. After D has been moved, it will have face 4 uppermost. 376 Planning Action: Raise a block (raise ?block) (raise ?block) Preconditions: (on ?block tied) (on ?other tied) Filter (up ?block facel) conditions: (on ?block tierl) (on ?other tierl) (up ?block face6) Add list: (on ?block tier2 ) (on ?block tier2) (up ?block face2) (up ?block fad) Delete list: (on ?block tierl) (on ?block tier!) (up ?block fad) (up ?block face6) Codesignation (not (?block ?other)) (not (?block ?other)) constraints Figure 5: Operators for raising a block using filter conditions main expressed in terms of a STRIPS representation modi- fied to include filter conditions. To test the feasibility of a straightforward implementation of filter conditions, we constructed a modified version of the SNLP planner using an extended STRIPS representation as shown in figure 5, above. The modified algorithm pro- ceeds in exactly the same way as the standard SNLP algo- rithm until all outstanding subgoals of a partial plan are satisfied. At this point, the planner attempts to show that the existing plan satisfies all the filter conditions of its op- erators; if any filter condition is unsatisfied, the plan is re- jected. In order to ensure that a filter condition is met, the planner may add constraints to the plan in the same way that it might to guarantee that unsafe links are not clob- beredz. In the algorithm sketched above, filter conditions do not do much filtering. Because they are not considered until the plan is otherwise complete, filter conditions play no role in pruning the search space during plan construction. An important part of the functionality of filter conditions- ruling out unreasonable uses of individual operators in par- tial plans-is thus missing. Clearly, we would prefer a planning algorithm in which filter conditions are considered earlier in the process. Un- fortunately, this is problematic in SNLP, as, in fact, it would be in any partial order planner3. As long as a plan in such a planner remains incomplete, it cannot be stated with certainty that a particular filter condition in that plan 20ur implementation uses the normal mechanism for adding links to test the satisfiability of the filter conditions, and can thus be viewed as an adaptation of the technique suggested by McAllester & Rosenblitt (1991) for dealing with abstractions. 30r in a total order planner that may insert a new step any- where in the plan, such as that used by McDermott (1989). cannot be established, since it is always possible that a step that establishes the condition will subsequently be added to the plan. It is therefore impossible to rule out any incomplete partial plan based on its filter conditions in a partial order planner. We can thus predict that a partial or- der planner using filter conditions will perform ineffi- ciently. This hypothesis is supported by the empirical re- sults we describe in section 4 below. One possible compromise solution might be to priori- tize the search through the plan space based on an estimate of the likelihood that the filter conditions in a given partial plan will ultimately be established. This method has the drawback that the information necessary to make such an estimate is not readily available. However, by counting the number of currently unestablished filter conditions a partial plan contains, the planner can make a crude guess as to the probability that the plan will eventually achieve these conditions. This information could then be used as one factor in the evaluation metric used to determine the order of search. To test this alternative mechanism for im- plementing filter conditions, we implemented a version of SNLP in which partial plans that include unestablished fil- ter conditions are penalized in the search process. As the empirical results in section 4 show, this implementation performs better than the basic implementation of filter conditions, despite the extra work involved in checking the filter conditions after each modification. Our implementations demonstrate that it is possible to implement filter conditions directly in SNLP. Unfortu- nately, as we have just seen, there are severe drawbacks to any such implementation, stemming not from any pecu- liarities of the SNLP algorithm but from the nature of par- tial order planning itself. These drawbacks led us to ex- plore the alternative approach described below. Pednault (1988, 1991) presents a method that accounts for context-dependent effects directly, without the need for sep- arate operators to distinguish representations of the same action. In his method, a distinction is drawn between those preconditions that are necessary in order for it to be possi- ble to execute an action, which are termedfe&biZity or primary preconditions, and those preconditions that specify the effect of an action on a particular state, termed sec- ondary preconditions. There are two types of secondary pre- condition: 0 A causation precondition is a condition that must be true in order for a particular state to become true as a result of a particular action. e A preservation precondition is a condition that must be true in order for a particular state to remain true through the execution of a particular action. Gollins and Pryor 377 Raise a block Action: (raise ?block) Preconditions: (on ?block ?t) (on ?other ?t) Add list: (on ?block tier2) Causation preconditions: (?t tierl) Delete list: (on ?block tierl) Preservation preconditions: (not (?t tierl)) Codesignation (not (?block ?other)) constraints: (up ?block facel) (up ?block faces) (up ?bfock facel) (up ?block ?face) (not (?face?face6)) Figure 6: Part of the raise operator using secondary preconditions For instance, in our example domain, filter conditions can be used to distinguish between the various operators that raise a block, depending on the orientation and posi- tion of the block the planner wishes to raise. There are six turning operators, one for each of the six possible orienta- tions. The operators for raising a block from different lev- els must also be distinguished. Using filter conditions, then, we need twelve operators to represent the single ac- tion of raising a block in our domain. Using secondary preconditions we need only a single representation of the raise action, part of which is shown in figure 6. The add list of this operator contains all conditions that may poten- tially be added by the action, each associated with its cau- sation preconditions. If the causation preconditions cannot be established, the condition is not added by the action. Similarly, the delete list contains all conditions that may potentially be deleted by the action, each associated with its preservation preconditions. If the preservation precondi- tions can be established, then the condition will not be deleted. 3.1 Secondary preconditions in SN Figure 6 shows part of the representation of the raise oper- ator in our example domain using secondary preconditions. Prevention If the clobbering arises through the [addition, deletion] of a desired state, prevent if by adding the [causation, preservation] preconditions of the relevant proposition on the [add, delete] list (required to be [false, true]) to the list of open conditions, and adding the [negation of the cau- sation, preservation] codesignation constraints to the set of codesignation constraints. Figure 7: New modification for unsafe links with secondary preconditions 378 Planning Add new If the open condition is required to be false, find an step operator with a proposition in its delete list that can be unified with the open condition. Make the opera- tor the new step, add its preconditions (required to be true) and its codesignation constraints. Add a new link from the new step to the unenabled step. Add new If the open condition is required to be false, find a link step with a proposition in its de/eta list that can be unified with the open condition. Add a link from the found step to the unenabled step. Add fink Ensure that the proposition is Meted by adding one of the preservation preconditions of the proposition on the delete list (required to be fake) to the list of open conditions, or adding the negation of one of the preservation codesignation constraints of the proposition on the delete list. Add the bindings necessary for the unification to the set of codesignation constraints. Make the appropriate ordering constraint. Figure 8: New modifications for open preconditions required to be false Each effect on the add list has causation preconditions and codesignation constraints associated with it, and similarly each effect on the delete list has associated preservation preconditions and codesignation constraints. These extra conditions are attached only if they are not already feasibil- ity preconditions. The basic SNLP algorithm can accommodate the addition of secondary preconditions without major modification? The required changes concern the structure of open condi- tions, and the generation of possible modifications to a partial plan that may be made in order to resolve an unsafe link (see figure 7) or establish an open condition (see fig- ure 8). An open condition may now be required to be either true or false. The truth of a condition is established, as be- fore, by a link from an add condition of a prior step: the falsity of a condition is established analogously by a link from a delete condition of a prior step. A condition may be required to be true if it is: An enabling precondition of a step. A causation precondition of an effect possibly added by a step when the addition is required in order to es- tablish the truth of a further effect. A preservation precondition of an effect possibly deleted by a step when the deletion must be prevented so as not to clobber another condition. A condition may be required to be false if it is: 0 A causation precondition of an effect possibly added by a step when the addition must be prevented so as not to clobber another condition 4McDermott (1989) has implemented secondary preconditions in a total order planner. He does not compare their effective- ness with that of filter conditions. ‘--.-&mm SNLP SNLP-F SNLP-FU .p SNLP-SP 1 2 3 1 2 3 1 2 3 1 2 3 Problem size Problem size Problem size Problem size A: Successes B: Mean cpu C: Mean cpu ratio Figure 9: Performance of SNLP using secondary preconditions ean path length ratio 0 A preservation precondition of an effect possibly de- leted by a step when the deletion is required in order to establish the falsity of a further effect The secondary preconditions of an effect are never ex- panded into subgoals unless the effect either is used to es- tablish a condition or must be prevented from clobbering an established condition. If neither of these cases applies, the truth or falsity of the effect has no influence on any other step in the plan, and it is ignored. From this description of the modified algorithm it can be seen that secondary preconditions fit straightforwardly into the structure of SNLP, providing a neat way of repre- senting context-dependent effects without multiplying the number of operators that are needed to represent the actions in a domain. Operators in this framework make the nature of context-dependent effects more explicit than do STRIPS operators with filter conditions. The modified algorithm preserves completeness and correctness. The performance of a planner can be measured by either the efficiency of the plans that it produces, or the efficiency of its search procedure. However, in our example domain, it turns out that in all cases in which a plan was found it was the most efficient one possible. We have therefore evalu- ated the algorithms only in terms of their search efficiency. We used three data sets for our evaluation, with one, two, or three blocks in the goal conditions. Each set con- sists of fifty randomly generated solvable problems. We ran four algorithms on each set, SNLP modified to include secondary preconditions (SNLP-SP) (see section 3, SNLP modified to include filter conditions (SNLP-F), SNLP modi- fied to include filter conditions and using unestablished fil- ter conditions to penalize partial plans in the search (SNLP- FU) (see section 2), and an unmodified version of SNLP. Figure 9 shows a comparison of the results of running the four algorithms. Graph A shows the number of prob- lems in each data set solved by each algorithm within a limit of 25QOQ units on the cpu time spent. SNLP-SP was the most successful algorithm: in no case did another algo- rithm solve a problem on which SNLP-SP failed. Graph B shows the mean cpu time taken by the four algorithms, with problems that were not solved taken into account at the time limit. Graph C presents the relative efficiency of the algorithms on those problems that they solve. For each problem, the time taken by each algorithm was di- vided by the time taken by SNLP-SP, and the graph shows the means of these ratios. Only those problems solved by the algorithm under consideration are included. Graph D presents a similar analysis of the number of nodes on the search path that led to a solution. It can be seen that the algorithm using secondary pre- conditions, SNLP-SP, generally solved more problems within the time limit than the others, took less cpu to do so, and traversed a shorter search path. Moreover, our claim that filter conditions are not effective in a partial or- der planner because they cannot be used effectively to rule out unpromising plans is supported by the fact that SNLP- F performs very little better than the basic algorithm. We performed pairwise T-tests on planned comparisons be- tween SNLP and SNLP-F, SNLP-F and SNLP-FU, and SNLP- FU and SNLP-SP for the number of successes as shown in graph A, the cpu time as shown in graph B, and the path length. For the latter two measures, we used the value at failure for those problems that were not solved within the time limit. The results for all problems taken together are shown in figure 10, and can be summarized as follows, at a 95% significance level: Succsss rate: All three comparisons were significant, with the second algorithm in each pair solving more problems within the time limit. Collins and Pryor 379 Comparison Successes CPU Path length Mean Tvalue Mean T value Mean T value SNLP- -0.087 -2.906 670 1.905* -224.7 -4.903 SNLP-F SNLP-F - -0.220 -6.483 6943 8.886 396.4 7.122 SNLP-FU SNLP-Fu - -0.047 -2.701 1611 5.407 30.7 6.622 SNLP-SF Figure 10: Mean differences and T-values (pcO.05 except *) Cpu time: There was no significant difference between SNLP and SNLP-F. The other two comparisons were significant, with the second algorithm in each pair performing better. Path length: SNLP-SP performed significantly better than SNLP-FU, which performed significantly better than SNLP-F. The other comparison was also signifi- cant, but in the reverse direction: SNLP had a shorter path length to solution than SNLP-F. The results are analyzed further in (Collins & Pryor 1992). An important difference between the algorithms that is not shown above is that the mean number of offspring of a partial plan, or branching factor, was much lower for SNLP-SP than for the other algorithms (1.7 compared to between 3.4 and 4.3). This implies that the efficiency ad- vantage of using secondary preconditions will become pro- gressively more pronounced as problems become more complex. 6 Conclusions We have investigated the feasibility of implementing filter conditions in a provably complete and correct partial order planner. While such an implementation is possible, it must fail to achieve the desired functionality of filter con- ditions for reasons that stem from the fundamental as- sumptions behind partial order planning. We therefore sought an alternative mechanism through which to repre- sent context-dependent effects, and found a candidate in the secondary preconditions of Pednault (1988, 1991). The implementation of secondary preconditions in a partial or- der planner is straightforward, and preserves completeness and correctness (Collins & Pryor 1992). A comparison of the empirical results obtained from the modified algo- rithms and the original algorithm supports our claim that the use of secondary preconditions accounts more effi- ciently for context-dependent effects than does the use of filter conditions. Acknowledgments. Thanks to Brian Drabble, Eric Jones, Bruce Krulwich, Austin Tate and Dan Weld for use- ful discussions, to Dan Weld for supplying the original SNLP code, and to the reviewers for their comments. This work was supported in part by the AFOSR under grant number AFOSR-91-0341-DEF, and by DARPA, moni- tored by the ONR under contract N-00014-91-J-4092. The Institute for the Learning Sciences was established in 1989 with the support of Andersen Consulting, part of The Arthur Andersen Worldwide Organization. The Institute re- ceives additional support from Ameritech, an Institute Partner, and from IBM. Allen, J., Hendler, J., & Tate, A. eds. 1990. Readings in Planning. San Mateo, CA: Morgan Kaufman. Barrett, A., Soderland, S., $ Weld, D. S. 1991. Effect of Step-Order Representations on Planning. Technical Report 91-05-06, Department of Computer Science and Engineering, University of Washington, Seattle. Chapman, D. 1987. Planning for Conjunctive Goals. Artificial Intelligence, 32: 333-337, and in (Allen et al. 1990). Charniak, E., & McDermott, D. 1985. Introduction to Artijicial Intelligence. Reading, MA: Addison-Wesley. Collins, G., and Pryor, L. 1992. Representation and Performance in a Partial Order Planner. ILS tech report, in preparation. Currie, K., & Tate, A. 199 1. O-Plan: the open planning architecture. Artificial Intelligence 52: 49-86. Fikes, R. E., & Nilsson, N. J. 1971. STRIPS: A new ap- proach to the application of theorem proving to problem solving. Artificial Intelligence 2: 189-208, and in (Allen et al. 1990). McAllester, D., & Rosenblitt, D. 1991. Systematic Non- linear Planning. Proceedings of the Ninth National Con- ference on Artificial Intelligence, Anaheim, CA. McDermott, D. 1989. Regression Planning. Technical Report YALEU/CSD/RR #752, Computer Science De- partment, Yale University. Pednault, E. P. D. 1988. Synthesizing plans that contain actions with context-dependent effects. Computational Intelligence 4: 356-372 Pednault, E. P. D. 1991. Generalizing Nonlinear Planning to Handle Complex Goals and Actions with Context- Dependent Effects. Proceedings of the Twelfth Intema- tional Conference on Artificial Intelligence, Darling Ha&our, Sydney, Australia. Tate, A. 1977. Generating project networks. IJCAI 1977, and in (Allen et al. 1990). Wilkins, D. E. 1988. Practical Planning: Extending the Classical AI Planning Paradigm. San Mateo, CA: Morgan Kaufman 380 Planning | 1992 | 67 |
1,262 | Mutluhan Erol ana S. P&u+ V. S. Subrahmanians kutluhan@cs.umd.edu nau@cs.umd.edu vs@cs.umd.edu Computer Science Department University of Maryland College Park, MD 20’742 Abstract In this paper, we examine how the complexity of domain-independent planning with STRIPS-Style operators depends on the nature of the planning operators. We show how the time complexity varies depending on a wide variety of conditions: whether or not delete lists are allowed; whether or not negative preconditions are al- lowed; whether or not the predicates are restricted to be propositions (i.e., 0-ary); whether the planning operators are given as part of the input to the planning problem, or instead are fixed in advance. Introduction Despite the acknowledged difficulty of planning, it is only recently that researchers have begun to exam- ine the computational complexity of planning problems and the reasons for that complexity (Chapman, 1987; Bylander, 1991; Gupta & Nau, 1991; Gupta & Nau, 1992; Minton et al., 1991; McAllester and Rosen- blitt, 1991). H ere, we examine how the complexity of domain-independent planning depends on the na- ture of the planning operators. We consider planning problems in which the current state is a set of ground atoms, and each planning operator is a STRIPS-style operator consisting of three lists of atoms: a precondi- tion list, an add list, and a delete list. So that it will be decidable whether a plan exists (Erol et al., 1992; Erol et al., 1991), we make the “datalog” restriction that no function symbols are allowed and only finitely many constant symbols are allowed. Our results are summarized in Table 1. Examination of this table re- veals several interesting properties: *This work was supported in part by NSF Grant NSFD CDR-88003012 to the University of Maryland Systems Re- search Center, as well as NSF grants IRI-8907890 and IRI- 9109755. + Also in the Systems Research Center and the Institute for Advanced Computer Studies. *Also in the Institute for Advanced Computer Studies. For PLAN EXISTENCE,~ comparing the propositional case (in which all predicates are restricted to be O- ary) with the datalog case (in which the predicates may have constants or variables as arguments) re- veals a regular pattern. In most cases, the complex- ity in the datalog case is exactly one level harder than the complexity in the corresponding propo- sitional case. we have EXPSPACE-complete versus PSPACE-complete, NEXPTIME-complete versus NP- complete, EXPTIME-complete versus polynomial. If delete lists are allowed, then PLAN EXISTENCE is EXPSPACE-Complete but PLAN LENGTH is Only NEXPTIME-complete. Normally, one would not ex- pect PLAN LENGTH to be easier than PLAN EXIS- TENCE. In this case, it happens because the length of a plan can sometimes be doubly exponential in the length of the input. hi PLAN LENGTH we are given a bound k, encoded in binary, which confines us to plans of length at most exponential in terms of the input. Hence in the worst case, PLAN LENGTH is easier than PLAN EXISTENCE. We do not observe the same anomaly in the propo- sitional case, because the lengths of the plans are at most exponential in the length of the input. Hence, giving an exponential bound on the length of the plan does not reduce the complexity of PLAN LENGTH. As a result, in the propositional case, both PLAN EXISTENCE and PLAN LENGTH are PSPACE- complete. When the operator set is fixed in advance, any op- erator whose predicates are not all propositions can be mapped into a set of operators whose predicates are all propositions. Thus, planning with a fixed set of datalog operators has basically the same complex- ity as planning with propositional operators that are given as part of the input. PLAN LENGTH has the same complexity regardless of whether or not negated preconditions are allowed. ‘Informally, PLAN EXISTENCE is the problem of deter- mining whether a plan exists, and PLAN LENGTH is the problem of determining whether there is a plan of length 5 Ic. Formal definitions appear in the next section. Erol, Nau, and Subrahmanian 381 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. 1 Language restrictions dat alog (no function symbols, and only finitely many constant 1 symbols) 1 propositional (all predicates are 1 0-ary) QNo operator Table 1: Complexity of domain-in Dependent phming. How the oper- Allow de- Allow negated Telling if a Telling if there’s a ators are given lete lists? preconditions? plan exists plan of length 5 k given in the input I no” fixed yes/no ves no Yes 60 noa yes/no given in the input Yes no I no noa /noP fixed I ves/no I ves/no I Las more than one precondition. EXPSPACE-complete NEXPTIME-complete EXPTIME-complete NEXPTIME-complete NEXPTIME-complete NEXPTIME-complete PSPACE-complete in PSPACE -Y PSPACE-complete in PSPACE r in NP y 1 in NP -Y in P in NLOGSPACE PSPACE-complete6 in NP y in NP PSPACE-complete 1 NP-complete ’ 1 NP-complete in P 6 NP-complete NLOGSPACE-complete NP-complete constant time constant time aEvery operator with more than one precondition is a composition of other operators. TWith PSPACE- or NP-completeness for some sets of operators. 6These results are due to Bylander (1991). All other results are new. This is because what makes the problem hard is the task of choosing operators that achieve several sub- goals in order to minimize the overall length of the plan, and this task remains equally hard regardless of whether negated preconditions are allowed. 5. Delete lists are more powerful than negated precon- ditions. Thus, if the operators are allowed to have delete lists, then whether or not they have negated preconditions has no effect on the complexity. Definitions Let ,!Z be any datalog (i.e., function-free first-order) language. Then a state is any nonempty set of ground atoms in C. Intuitively, a state tells us which ground atoms are currently true. Thus, if a ground atom A is in state S, then A is true in state S; if B $ S, then B is false in state S. Thus, a state is simply an Herbrand interpretation for the language L, and hence each formula of first-order logic is either satisfied or not satisfied in S according to the usual first-order logic definition of satisfaction. Let ,!Z be any datalog language. A planning operu- tor cy is a 4-tuple (Name(a), Pre(a), Add(a), Del(o)), where 1. Name(a) is a syntactic expression of the form Q(&,..., Xn) where each Xi is a variable symbol 0fL; 2. Pre(a) is a finite set of literals, called the precondi- tion list of cy, whose variables are all from the set Wl,...,&h 3. Add(o) and Del(o) are both finite sets of atoms (possibly non-ground) whose variables are taken 382 Planning Fig. 1: Initial configuration Fig. 2: Goal configuration from the set {Xl, . . . , X,}. Add(a) is called the add list of o., and Del(a) is called the delete list of CY. Observe that atoms and negated atoms may occur in the precondition list, but negated atoms may not occur in either the add list or the delete list. A planning domain is a pair I? = (Se, O), where So is the initial state and 0 is a finite set of operators. A planning problem is a triple P = (SO, 0, G), where (So, 0) is a planning domain and G is a goal (an exis- tentially closed conjunction of atoms). In both cases, the language of $ is the datalog language L generated by the constant, predicate, and variable symbols ap- pearing in P, along with an infinite number of variable symbols. Example 1 (Blocks World) Consider a blocks- world domain containing three blocks a, b, c, along with Nilsson’s “stack”, “unstack”, “pickup”, and “put- down” operators (Nilsson, 1980). Suppose the initial and goal configurations are as shown in Figs. 1 and 2. This domain can be represented as follows: * Language. The language ic contains a supply of vari- able symbols X1, X2, . . . , and three constant sym- bols a, b, c to represent the three blocks. ,C contains a binary predicate symbol “on”, unary predicate sym- bols “ontable”, “clear”, and “holding”, and a 0-ary predicate symbol “handempty”. Operator names, such as “stack”, “unstack”, etc., are not part of L. Opercators. The “unstack” operator is the following 4-tuple (the “stack”, “pickup”, and “putdown” op- erators are defined analogously): Name : unstack(Xr , X2) Pre : {on(Xl, XZ), clear(&), handempty Del : {on(&, X2), clear(&), handempty Add : {clear(Xz), holding(Xi)} Planning Domain. The planning domain is (So, S), where So and 0 are as follows: s() = {clear(a), on(a, b), ontable( clear(c), ontable( handempty( 0 = {stack, unstack, pickup, putdown). Plannzng Problem. The planning problem is (So, 0, G), where G = (on(b, c)}. Let P = (Ss,O) b e a planning domain, LL be an _ _ operator in 0 whose name is cu(Xi, . . . , X,), and 0 be a substitution that assigns ground terms to each Xi, 1 5 i < n. Suppose that the following conditions hold: (A6lA is an atom in Pre(cr)) c S; (S0llB is a negated literal in Pre(a)} II S = 0; S’ = (S - (Del(o)0)) U (Add(a)) 8. Then we say that CY is tLexecutabZe in state S, resulting in state S’. This is denoted symbolically as S 2 S’. Suppose P = (So, 0, G) is a planning problem. A plan in P that achieves G is a sequence such that G is satisfied by S,, i.e. there exists a ground instance of G that is true in Sn. The length of the above plan is n. Let P = (So, 0) be a planning domain or P = (So, 0, G) be a planning problem; and let C be the language of P. Then: 1. 0 and P are positive if for all cy E 0, Pre(a) is a finite set of atoms (i.e. negations are not present in Pre(a)). 2. f and P are deletion-free if for all CY E 0, Del(a) = . 3. 0 and I? are context-free if for all a! E 0, IPre(c;u)l < 1, i.e., Pre(cu) contains at most one atom. 4. 0 and P are side-e$ect-free if for all Q E 0, IAdd U Del(a)1 5 1, i.e., LY has at most one post- condition. 5. 0 and P are propositional if every predicate P in ,C is a propositional symbol (i.e. a 0-ary predicate symbol). PLAN EXISTENCE is the following problem: “given a planning problem I? = (So, 0, G), is there a plan in I? that achieves G?” PLAN LENGTH is the following problem: 2 “given a planning problem P = (Se, 0,G) and an integer k: encoded in binary, is there a plan in I? of length Ic or less that achieves G?” in-hating Negated w below that if delete list can remove negations from preconditions of operators in polynomial time. Thus, if delete lists are allowed, negated preconditions do not affect the complexity of planning. Theorem 1 (Eliminating Negated Precondi- tions) In polynomial time, given any planning domain P = (So, 0) we can produce a positive planning do- main P’ = (Sk, 0’) having the following properties: 1. For every goal G, a plan exists for G in P if and only if a plan exists for G in 2. For every goal G and non-negative integer I, there exists a plan of length I for G in P if and only if there exists a plan of length d + 2”’ for G in P’, where Ic is the maximum arity among the predicates of B and v = [lg cl, where c is the number of constants in P (i.e., w is the number of bits necessary to encode the constants in binary). Here is a sketch of P’. For each predicate in P, we introduce a complementary predicate in P’, and modify the operators such that whenever one is added, the other is deleted and vita versa. Hence negated preconditions can be replaced by their complementary predicates. We use a chain of operators to assert the instances of complementary predicates whose corre- sponding instances are not in the initial state of P. We set the preconditions such that any plan in P’ has to start with this chain. This guarantees that property 2 is satisfied. Note that P’ will not be deletion-free, even if P is. rying Sets of In this section, we consider the complexity of planning in the “domain-independent” case, in which the oper- ators are part of the input and thus different problem instances may have different operator sets. 21n this definition, we follow the standard procedure for converting optimization problems into yes/no decision problems. What really interests us, of course, is the prob- lem of finding the shortest plan that achieves G. This prob- lem is at least as difficult as PLAN LENGTH, and in some cases harder. For example, in the Towers of Hanoi problem (Aho et al., 1976) an d certain generalizations of it (Graham et QI., 1989), the length of the shortest plan can be found in low-order polynomial time-but actually producing this plan requires exponential time and space, since the plan has exponential length. For further discussion of the rela- tion between the complexity of optimization problems and the corresponding decision problems, the reader is referred to pp. 115-117 of Garey & Johnson (1979). Ed, Nau, and Subrahmanian 383 Case 1: Propositional Operators The following theorems deal with the special case in which all predicates are propositions (i.e., 0-ary). Theorem 2 (due to Bylander (1991)) 1. 2. 3. 4. 5. If we restrict P to be propositional, then PLAN EX- ISTENCE is PSPACE-complete. If we restrict P to be propositional and positive, then PLAN EXISTENCE iS PSPACE-complete. If we restrict P to be propositional and deletion-free, then PLAN EXISTENCE is NP-complete. If we restrict P to be propositional, deletion-free, and positive then PLAN EXISTENCE is in P. If we restrict P to be propositional, positive, and side-effect-free, then PLAN EXISTENCE is in P. Theorem 3 If we restrict P to be propositional, pos- itive, context-free, and deletion-free, then PLAN EXIS- TENCE is NLOGSPACE-complete. Theorem 4 If we restrict P to be propositional, posi- tive, context-free and deletion-free, then PLAN LENGTH iS NP-complete. Corollary 1 If we restrict P to be propositional, pos- itive and deletion-free, then PLAN LENGTH is NP- complete. Corollary 2 If we restrict P to be propositional and deletion-free, PLAN LENGTH is NP-complete. Theorem 5 PLAN LENGTH is PSPACE-complete if we restrict P to be propositional. It is still PSPACE- complete if we restrict P to be propositional and pos- itive. Both Theorem 3 and Clause 5 of Theorem 2 require restrictions on the number of clauses in the precondi- tions and/or postconditions of the planning operators. These restrictions can easily be weakened by allowing the operators to be composed, as described below. An operator cy is composable with another operator ,f3 if the positive preconditions of p and del(cr) are dis- joint, and the negative preconditions of ,0 and add(o) are disjoint. If cy and ,f3 are composable, then the composition of a! with /? is Pre : Pre(ar) U (PI - Add(o)) u (P2 - de@)) Add : Add(P) U (Add(a) - Del(P)) Del : Del(p) U (Del(o) - Add(P)) where PI and P2, respectively, are ,0’s positive and negative preconditions. Theorem 6 (Composition Theorem) Let P = (Se, 0) be a planning domain, and 0’ be a set of oper- ators such that each operator in 0’ is the composition of operators in 0. Then for any goal G, there is a plan to achieve G in P iff there is a plan to achieve G in P’, where P’ = (So, 0 u 0’). The above lets us extend the scope of several previ- ous theorems: Corollary 3 Suppose we restrict P = (SO, 0, G) to be such that 0 = 01 U 02, where 01 is propositional, deletion-free, positive and context-free, and every op- erator in 02 is the composition of operators in Or. Then PLAN EXISTENCE is NLOGSPACE-complete. Corollary 4 Suppose we restrict P = (SO, 0, G) to be such that 0 = 01 U 02, where 01 is propositional, positive, and side-effect-free, and every operator in 02 is the composition of operators in 01. Then PLAN EX- ISTENCE is in P. Example 2 (Reformulation of Blocks World) Bylander (1991) reformulates the blocks world so that each operator is restricted to positive preconditions and one postcondition. Instead of the usual “on” and “clear” predicates, he uses proposition o&j to denote that block i is not on block j. For each pair of blocks i and j, he has two operators: one that moves block i from the top of block j to the table, and one that moves block i from the table to the top of block j. These operators are defined as follows: Name : totableii Pre : (ofh,i,off2,i,. . . , ofL,i, Offl,j, Off2,j, . . . . O&--l,j, offa+1,j, . . . ) Offn,j} Del: 0 Add : Ioffi,j 1 Name : toblockij Pre : {Offl,i,Off2,i,.~~,Oft~,i,OflFl,j,off2,j, . . . . n,j,Offi,l,Off~,2,...,Offi,n} Del : {Off;: Add: 0 In Bylander’s formulation of blocks world, P is pos- itive and side-effect-free. Thus as a consequence of Clause 5 of Theorem 2, in Bylander’s formulation of blocks world PLAN EXISTENCE can be solved in poly- nomial time. In Bylander’s formulation of the blocks world, it is not possible for blocks to be moved directly from one stack to another. This has two consequences, as de- scribed below. The first consequence is that in Bylander’s formu- lation of blocks world, PLAN LENGTH can be solved in polynomial time. To show this, below we describe how to compute how many times each block b must be moved in the optimal plan. Thus, to see whether or not there is a plan of length k or less, all that is needed is to compare k with c how many times b must be moved. b Let S be the current state, and b be any block. If the stack of blocks from b down to the table is consis- tent with the goal conditions (whether or not this is so 384 Planning can be determined in polynomial time (Gupta & Nau, 1992)), then b need not be moved. Otherwise, there are three possibilities: 1. If b is on the table and the goal requires that b be on some other block c, then in the shortest plan, b must be moved exactly once: from the table to c. 2. If b is on some block c and the goal requires that b be on the table, then in the shortest plan, b must be moved once: from c to the table. 3. If b on some block c and the goal requires that b be on some block d (which may be the same as c), then in the shortest plan, b must be moved exactly twice: from c to the table, and from the table to d. The second consequence is that translating an or- dinary blocks-world problem into Bylander’s formula- tion will not always preserve the length of the optimal plan. The reason for this is that in the ordinary for- mulation of blocks world, the optimal plan will often involve moving blocks directly from one stack to an- other without first moving them to the table, and this cannot be done in Bylander’s formulation. It appears that Bylander’s formulation cannot be extended to al- low this kind of move another without violating the restriction that each has only positive preconditions and one postcondition. We can easily overcome the above problem by aug- menting Bylander’s formulation to include all possi- ble compositions of pairs of his operators. Theorem 2 does not apply to this formulation, but Corollary 4 does apply, and gives the same result as before: PLAN EXISTENCE can be solved in polynomial time. Since this extension to Bylander’s formulation allows stack-to-stack moves, there is a one-to-one correspon- dence between plans in this formulation and the more usual formulations of the blocks world, such as those given in (Charniak & McDermott, 1985; Warren, 1990; Nilsson, 1980; Waldinger, 1990; Gupta & Nau, 1991; Gupta & Nau, 1992). Thus, from results proved in (Gupta & Nau, 1992), it follows that in this exten- sion of Bylander’s formulation, PLAN LENGTH is NP- complete. Case 2: Datalog Operators Below, we no longer restrict the predicates to be propo- sitions. As a result, planning is much more complex than in the previous case. Theorem 7 If we restrict P to be positive and deletion-free, then PLAN EXISTENCE is EXPTIME- complete. Theorem 8 If we restrict P to be deletion-free, then PLAN EXISTENCE is NEXPTIME-complete. Theorem 9 PLAN EXISTENCE is EXPSPACE-complete. It is still EXPSPACE-Complete if we restrict P to be positive. We show below that when we restrict preconditions of planning operators to contain at most one atom, then the planning problem is PSPACE-Complete. Theorem 10 If we restrict to be context-free, positive, and deletion-free, then PLAN EXISTENCE is PSPACE-complete. Theorem 11 If we restrict P to be deletion-free, pos- itive, and context-free, then PLAN LENGTH is PSPACE- complete. Theorem 12 PLAN LENGTHisNEXPTIME-completein each of these cases: P is deletion-free and positive; P is deletion-free; P is positive; no restrictions on P. Fixed Sets of Operators The above results are for the case in which the set of operators is part of the input. However, in many well known planning problems, the set of operators is fixed. For example, in the blocks world (see Example l), we have only four operators: stack, unstack, pickup and putdown. In this section we will present complexity results on planning problems in which the set of operators is fixed, and only the initial state and goal are allowed to vary. The problems we will consider will be of the form: “given the initial state So and the goal 6, is there a plan that achieves G?” We assume no predi- cate/proposition that does not appear in the operators appears in G or Se. Since the operators can neither add nor delete atoms constructed from these predicates, this is a reasonable restriction. Case 1: Propositional Operators Propositional planning with a fixed set of operators is very restrictive. The number of possible plans is constant. We include the following two results just for the sake of completeness. Theorem 13 PLAN EXISTENCE can be solvedin con- stant time if we restrict P = (Se, 0,G) to be proposi- tional and 0 to be a fixed set. Corollary 5 PLAN LENGTH can be solved in constant time if we restrict P = (Se, 0, G) to be propositional and 0 to be a fixed set. Case 2: Datalog Operators When the set of operators is fixed, we can enumerate all ground instances in polynomial time, reducing the problem to propositional planning with a varying set of operators.3 Thus, the following theorem follows from 3This is similar, but not identical, to the reformulation of the Blocks World given in Example 2. The reformu- lation in Example 2 also involved replacing the “on” and “clear” predicates by a single “off” predicate, as well as some changes to the nature of the planning operators. Erol, Nau, and Subrahmanian 385 Theorems 2-5 and their corollaries. Theorem 14 1. 2. 3. 4. If we restrict P to be fixed, deletion-free, context-free and positive, then PLAN EXISTENCE is in NLOGSPACE and PLAN LENGTH is in NP. If we restrict P to be fixed, deletion-free, and posi- tive, then PLAN EXISTENCE is in P and PLAN LENGTH is in NP. If we restrict P to be fixed and deletion-free, then PLAN EXISTENCE and PLAN LENGTH are in NP. If we restrict P to be fixed, then PLAN EXISTENCE and PLAN LENGTH are in PSPACE. The above theorem puts a bound on how hard plan- ning can be with a fixed set of operators. The following theorems state that we can find fixed sets of operators such that their corresponding planning problems are complete for these complexity classes. Theorem 15 There exists a fixed positive deletion- free set of operators 0 for which PLAN LENGTH is NP- hard. Theorem 16 There exist fixed deletion-free sets of operators 0 for which PLAN EXISTENCE and PLAN LENGTH are NP-hard. Theorem 17 There exists a fixed set of positive oper- atorsO for which PLAN EXISTENCE and PLAN LENGTH are PsPACE-hard. Conclusion The primary aim of this paper has been to develop an exhaustive analysis of the complexity of planning with STRIPS-style planning operators (i.e., operators comprised of preconditions, add lists, and delete lists). Based on various syntactic restrictions on the planning operators, we have developed a comprehensive theory of the complexity of planning. In order to guarantee that PLAN EXISTENCE and PLAN LENGTH are decidable, we have restricted the planning language L to be a datalog language. Thus, II: has no function symbols, as is the case in STRIPS and many other planning systems. In (Erol et al., 1992; Erol et al., 1991), we show that if Z is allowed to contain function symbols (and thus contain infinitely many ground terms), then PLAN EXISTENCE and PLAN LENGTH are both undecidable in general. In summary, planning is a hard problem even under severe restrictions on the nature of planning operators. Thus, in order to construct efficient planners, it is im- portant to find other ways to prevent the complexity from getting out of hand. For example, Yang et al. (1990; 1992) h s ow how to develop efficient algorithms for merging plans to achieve multiple goals, given cer- tain kinds of restrictions on what kinds of goal and subgoal interactions can occur. eferences Aho, A. V.; Hopcroft, J. E.; and Ullman, J. D. 1976. The Design and Analysis of Computer Algorithms. Addison- Wesley, Reading, MA. Bylander, Tom 1991. Complexity results for planning. In IJCAI- $1. Chapman, David 1987. Planning for conjunctive goals. Artificial Intelligence 32:333-378. Charniak, Eugene and McDermott, Drew 1985. In- troduction to Artifkial Intelligence. Addison-Wesley, Reading, MA. Erol, K.; Nau, D.; and Subrahmanian, V. S. 1991. Complexity, decidability and undecidability results for domain-independent planning. CS TR-2797, UMI- ACS TR-91-154, and SRC TR 91-96; under review. Erol, K.; Nau, D.; and Subrahmanian, V. S. 1992. When is planning decidable? In Proc. First Internat. Conf. AI Planning Systems. To appear. Garey, Michael R. and Johnson, David S. 1979. Com- puters and Intractability: A Guide to the Theory of NP-Completeness. W. H. Freeman and Company, New York. Graham, R. L.; Knuth, D. E.; and Patashnik, 0. 1989. Concrete Mathematics: a Foundation for Com- puter Science. Addison-Wesley. Gupta, Naresh and Nau, Dana S. 1991. Complexity results for blocks-world planning. In Proc. AAAI-91. Honorable mention for the best paper award. Gupta, N. and Nau, D. 1992. On the complexity of blocks-world planning. Artificial Intelligence. To ap- pear. McAllester, D. and Rosenblitt, D. 1991. Systematic nonlinear planning. In Proc. AAAI-91. Minton, S.; Bresna, J.; and Drummond, M. 1991. Commitment strategies in planning. In Proc. IJCAI- 91. Nilsson, N. J. 1980. Principles of Artificial Intelli- gence. Tioga, Palo Alto. Waldinger, R. 1990. Achieving several goals simulta- neously. In Allen, James; Hendler, James; and Tate, Austin, editors 1990, Readings in Planning. Morgan Kaufman. 118-139. Originally appeared in Machine Intelligence 8, 1977. Warren, D. H. D. 1990. Extract from Kluzniak and Szapowicz APIC studies in data processing, no. 24, 1974. In Allen, James; Hendler, James; and Tate, Austin, editors 1990, Readings in Planning. Morgan Kaufman. 140-153. Yang, Q.; Nau, D. S.; and Hendler, J. 1990. Optimiza- tion of multiple-goal plans with limited interaction. In Proc. DARPA Workshop on Innovative Approaches to Planning, Scheduling and Control. Yang, Q.; Nau, D. S.; and Hendler, J. 1992. Merg- ing separately generated plans with restricted inter- actions. Computational Intelligence. To appear. 386 Planning | 1992 | 68 |
1,263 | yzi F * Adele E. Howe Experimental Knowledge Systems Laboratory Department of Computer Science University of Massachusetts Amherst, MA 01003 Net: howe@cs.umass.edu Abstract Plans fail for many reasons. During planner devel- opment, failure can often be traced to actions of the planner itself. Failure recovery analysis is a proce- dure for analyzing execution traces of failure recovery to discover how the planner’s actions may be causing failures. The four step procedure involves statistically analyzing execution data for dependencies between ac- tions and failures, mapping those dependencies to plan structures, explaining how the structures might pro- duce the observed dependencies, and recommending modifications. The procedure is demonstrated by ap- plying it to explain how a particular recovery action may lead to a particular failure in the Phoenix planner. The planner is modified based on the recommendations of the analysis, and the modifications are shown to im- prove the planner’s performance by removing a source of failure and so reducing the overall incidence of fail- ure. Introduction Plans fail for perfectly good reasons: the environ- ment changes unpredictably, sensors return flaky data [Lee et al., 19831, and effecters do not work as ex- pected [Hayes, 19751. During planner development, plans fail for not so good reasons: the effects of actions are not adequately specified [Atkinson et al., 19861, apparently unrelated actions interact [Sussman, 19731, and the domain model is incomplete and incorrect [Chien and Weissman, 19751. Planners should not cause their own failures, but figuring out what went wrong and preventing it later is not easy. Failures tell us what went wrong, but not why. The failure re- pair alleviates the immediate problem, but does not tell us how to fix the cause or even whether the re- pair itself might not cause failures later. This paper *This research was supported by a DARPA-AFOSR contract F49620-89-C-00113, the National Science Founda- tion under an Issues in Real-Time Computing grant, CDA- 8922572, and a grant from the Texas Instruments Corpo- ration. I wish also to thank Paul Cohen for his help in de- veloping these ideas and David Hart, Scott Anderson and David Westbrook for their help with Phoenix. presents a procedure, called failure recovery analysis (FRA), for analyzing execution traces of failure recov- ery to discover when and how the planner’s actions may be causing failures [Howe, 19921. Most approaches to debugging planners are knowl- edge intensive. Sussman’s HACKER [1973] detects, classifies and repairs bugs in blocks world plans, but it requires considerable knowledge about its domain. Hammond’s CHEF [1987] backchains from failure to the states that caused it, applying causal rules that describe the effects of actions. Simmons’s GORDIUS [1988] debugs faulty plans by regressing desired effects through a causal dependency structure constructed during plan generation from a causal model of the do- main. Kambhampati’s approach [1990] requires the planner to generate validation structures, explanations of correctness for the plan. His theory of plan modifica- tion compares the validation structure to the planning situation, detects inconsistencies, and uses the valida- tion structure to guide the repair of the plan. These approaches assume that the planner or debug- ger has a strong model of the domain. The approach presented in this paper, FRA, requires little knowledge to identify contributors to failures and only a weak model to explain how the planner might have caused failures. Complementary to the more knowledge in- tensive approaches, this approach is most appropriate when a rich domain model is not available or when the existing model might be incorrect or buggy, as when the system is under development. The consequence of relying on a weak model is that while FRA can detect possible causes of the failure, it cannot identify the cause precisely enough to im- plement a repair. Debugging a planner requires judg- ment about what would be the best modification and whether the failure is worth avoiding at all. In repair- ing one failure, others might be introduced. In FRA, the designer decides how best to repair the failures. The Planner and its Environment Previous experiments and analyses of failure recov- ery in the Phoenix system (introduced below) showed that changing how the planner recovers from failures Howe 387 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. changed the type and frequency of failures encountered [Howe and Cohen, 19911. In these experiments, seem- ingly minor changes to the design of Phoenix’s failure recovery component, such as adding two new failure recovery actions with limited applicability, had unex- pected consequences. Failure recovery analysis of these experiments should explain why a well-justified modi- fication to the planner produced such havoc. The Phoenix system is a simulator of forest fire fight- ing in Yellowstone National Park and an agent archi- tecture [Cohen et al., 19891. A single agent, the flre- boss, coordinates the efforts of field agents who build fireline to contain the spread of the fire. Its spread is influenced by weather and terrain, but even when these factors remain constant, the fire’s spread is un- predictable. Plan failures are a natural result of this unpredictability of the environment, but they may also result from flaws in Phoenix’s plans. A plan failure is detected when a plan cannot ex- ecute to completion. Failures may be detected dur- ing plan generation or execution and are classified into 11 domain-specific types. For example, a violation- insuficient-time failure (abbreviated vit) is detected through execution monitoring when a plan will take longer to complete than it has been allotted. To repair a failure, the planner applies one of a set of actions - usually six, but in one version of the system, eight. Most of the actions can be applied to any failure, but the scope and nature of their repairs varies. For example, replan-parent (abbreviated up) is applicable to any failure and recomputes the plan from the last major decision point; while substitute-projection-action (abbreviated sp) repairs only two types of failures by replacing the failed action with another. Failure Recovery Analysis Failure recovery analysis involves four steps. First, execution traces are searched for statistically signifi- cant dependencies between recovery efforts and subse- quent failures. Second, dependencies are mapped to structures in the planner’s knowledge base known to be susceptible to failure. Third, the interactions and vulnerable plan structures are used to generate expla- nations of why the failures occur. Finally, the explana- tions serve to separate occasional, acceptable failures from chronic, unacceptable failures, and recommend redesigns of the planner and recovery component. The first step is fully automated, and the second step is par- tially automated. The entire process will be illustrated with an example of how one of the recovery actions, sp, can influence vii! failures. Step 1: Isolating Dependencies The first step in FRA is to search failure recovery data for statistical dependencies between recovery efforts and failures. One failure, Fs, is dependent on another, Fj, if Fs is observed to occur more often following Fi than after any other failure. In general, the precursor, Table 1: Contingency Table for [Fne,.Rsp, F,it] Ff, can be replaced with anything observable during execution - recovery actions, planning actions, events in the environment or some combination. For example, if Ff denotes a failure and Ri denotes the recovery ac- tion that repaired Ff, then Ff -I& - Fg is an execution truce leading to failure Fs, and Ff& 1s the precursor. For any precursor, the question is the same: Does a failure depend on some action or event that preceded it? Dependencies can be isolated by statistically analyz- ing execution traces. Execution traces can be viewed as transitions between failure types and actions, and then these transitions can be analyzed for dependen- ties. The statistical analysis is a two-step process: Combinations of failures and actions are first tested for whether they are more or less likely to be followed by each of the possible failures. Then the significant com- binations are compared to remove overlapping combi- nations. To determine whether failures are more or less likely after particular precursors, contingency tables are con- structed for each precursor P, and each failure Fj by counting: 1) instances of Ff that follow instances of P,, 2) instances of Fj that follow instances of all precursors other than P, (abbreviated Pz), 3) failures other than Ff (abbreviated FF) that follow P, and 4) failures FT that follow Pz. These four frequencies are arranged in a 2x2 contingency table like the one in figure 1: the precursor in this table is FnerRsp, a failure and a re- covery action. F,,, is the failure not-enough-resources, which is detected when the fire cannot be fought with the available resources. R,, is the recovery action sp. The targeted failure is F,it. In this case we see a strong dependence or association between the precur- sor, FnerRsp, and the failure, F,it: 42 cases of F,;t fol- low FnerRgp and only 21 failures other than Fvit follow &,, R,,. But while FneTRSP leads most frequently to failure Fvit, precursors other than FneTRsp lead to Fvit relatively infrequently (250 instances in 905). A G-test on this table will detect a dependency between the fail- ure and its precursor; in this case, G = 41.4,~ < .OOl, which means that the contingency table in figure 1 is extremely unlikely to have arisen by chance if FnerRsp and F,it are independent. So we conclude that Fvit depends on FneT R,, (abbreviated [FneTRSpr F,;t]). Failure recovery analysis requires contingency tables for three types of precursors: failures (Fj ), recovery actions (ILp) and pairs of a failure and the recovery ac- tion that repaired it (Fi R,). Because these precursors are strongly related (recovery actions repair failures), 388 Planning any dependency could be due to .F’f itself, R, itself, or Ff R, together. A statistical technique based on the G- test differentiates the three hypotheses by comparing the sum of the effects due to the pairs (e.g., Ff R, for all possible 2&s) to the effect due to just the grouped effect (e.g., Ff). The intuition behind the test is that if the pairs do not add much information about the effect then they can be disregarded; conversely, if the grouped effect, Ff or _&, masks differences between the pairs, then the grouped effect should be disregarded as misleading. For example, by comparing the example dependency, [J?~erRsp, .&it], and related pairs to the grouped effect, [Rsp, _??&I using a variant of the G-test, we find that [FmerRbp, F,;t] adds little information over knowing [_&,, F,it], so [FnerRspr &it] is disregarded. Step 2: Mapping to Suggestive Plan Structures Step 1 tells us whether a failure depends on what pre- cedes it, but not how the dependency relates to the planner’s actions. The next step is to determine how the constituents of the dependencies (the recovery ac- tions and failures) interact with each other in plans. This step has two parts: associating each dependency with actions in plans and finding structures in the plans that might lead to failures. Associating Dependencies with Plans: The con- stituents of a dependency are associated with plan ac- tions. The association is motivated by the following two relationships: Failures are detected by plan ac- tions, and recovery actions transform failed plans by adding or replacing plan actions. So each dependency can be represented as sets of actions specifying all the ways the failures in the dependency are detected, and all the ways the recovery action in the dependency adds actions to plans. For example, to associate the depen- dency identified in step 1, [Rap, FV;,], with plan actions, we determine what actions are added by R,, and what actions detect Fvit, as displayed in figure 1. R,, trans- forms a failed indirect attack plan (abbreviated Pi,) into a repaired plan Pia by substituting a different type of fireline projection calculation action for the failed one. Fireline projections are the planner’s blueprint for the placement of fireline to contain a forest fire; the Phoenix plan library includes three different actions for calculating projections: multiple-fixed-shelZ (Ap-,,+), tight-shell (A p-ta), and model-based (Ap-mb). R,, re- places one of these with another; so we know that R,, adds one of these three projection actions. Failure Fvit is detected when plan monitoring indicates that progress against the fire has been insufficient and not enough time remains to complete the plan. F,;t is de- tected by an envelope action (a structure for comparing expected to actual progress [Hart et al., 19901) called indirect-attack-envelope (A,,,). Identifying Structures that Lead to Failure: The plan library is searched for plan structures that gov- F ACtiOanS: pi sets variable StidVariable Figure 1: Mapping a dependency to two suggestive structures ern the interaction between the actions of the depen- dency. These structures, called suggestive structures, are idioms in the plans that suggest causes of failure or that tend to be vulnerable to failure; they coor- dinate actions within plans and describe shared com- mitments to a course of action or shared expectations about the world. Suggestive structures can improve plan efficiency, but make the related actions sensitive to changes in the environment or intolerant of varia- tions in the plan. Designers make trade-offs by using such structures; they intend that the efficiency gained from them outweighs the cost of occasional failure. One example of a suggestive structure is a shared variable in a plan: as long as every action that uses the variable agrees about how it is set and used, shared variables can be invaluable for coordinating actions. But if some of these assumptions are implicit or under- specified, the variable might be a source of failures; for example, one action might assume that the variable’s units are minutes and another might assume seconds. Some suggestive structures from the Phoenix plan lan- guage are: Shared Variables One action sets some variable and another uses it. Shared Resources Two actions allocate and use the same resource. Assuming Stability in the Environment One ac- tion senses the environment and passes the result onto another or two actions share assumptions about the state of the environment. Sequential Actions One is guaranteed to follow an- other in some plan. Iteration Constructs Multiple actions are added to the plan by the same decision action. For example, Phoenix supports a rescheduling construct that du- plicates actions until some condition is met. To find suggestive structures, the plan library is searched for all plans that contain one of the possible Howe 389 combinations of the actions in the dependency. Each such plan is checked for suggestive structures involving the dependency actions. In the example, the projec- tion calculation actions (Ap_mfs, A*-ts and A,_,a) and the envelope action (A,,,) appear together in three different indirect attack plans. All three indi- rect attack plans include the same suggestive struc- tures: shared variable and sequential ordering. Fig- ure 1 shows how the projection calculation actions and the envelope action are related in the indirect attack plans. All projection calculation actions set the vari- able at tack-pro j ection which is used by the envelope action. The envelope action always follows the projec- tion calculation action in the indirect attack plans. Step 3: Explaining Dependencies Steps 1 and 2 determine what actions of the planner’s might lead to the observed failures. Step 3 completes the story of how the planner causes failures by con- structing explanations of how the suggestive structures might have produced the observed dependencies. For example, the suggestive structure, shared variables, can cause failures when two actions in a plan use the vari- able differently, each making its own impkit assump- tions about the value of the shared variable. Combi- nations of suggestive structures lead to many expla- nations; the two suggestive structures found in Step 2 for the dependency [Rsp, .F,;t] underlie two different explanations: Implicit Assumptions Two actions make different assumptions about the value of a plan variable to the extent that the later action’s requirements for successful execution are violated. Band-aid Solutions A recovery action may repair the immediate failure, but that failure may be symp- tomatic of a deeper problem, which leads to subse- quent failures. The shared variable can cause a failure if the substi- tuted projection calculation action sets the variable dif- ferently than was expected by the envelope action; the projection may not be specified well enough to be prop- erly monitored or may violate monitoring assumptions about acceptable progress. Alternatively, the recovery action R,, could lead to F,,it if the recovery action is repairing only a symptom of a deeper failure; the fire may be raging out of control or the available resources may really be inadequate for the task. The explanations amount to sketches of what might have gone wrong. They do not precisely determine the cause, but rather attempt to provide enough evidence of flaws in the recovery actions or the planner to mo- tivate a redesign. Step 4: Recommending Redesigns Step 4 determines whether and how to repair the causes of failure. Each failure explanation translates directly to a set of possible plan modifications. The modifica- tions are based on experience with repairing flaws of the types described by the explanations. In the ex- ample, the [Rsplr F,it] dependency is explained as due to two possible mechanisms: implicit assumptions and band-aid solutions. Each indicates a different prob- lem with the plan library and each leads to a different modification: implicit Assumptions Add new variables to the plan description to make the assumptions explicit or change the plans so that the incompatible actions are not used in the same plans. Band-aid Solutions Limit the application of the suspect recovery action or add new recovery actions to repair the failure. The recommendation is not intended to be imple- mented by the system itself. Modifying a planner re- quires judgment about what would be the best mod- ification and whether the failure is worth avoiding at all. In repairing one interaction effect, others might be introduced. Utility of Failure Recovery Analysis Failure recovery analysis is worthwhile only if it can tell us something about our planners that we didn’t already know, and if the effort required to perform the analysis is commensurate with the information gained. While the analysis of the Phoenix planner is ongoing, so far the results are promising. As this section describes, the recommendations of the example analysis in this paper have been tested in Phoenix and the modification has been shown to improve the planner’s performance. Diagnosing Failures in Phoenix The example analysis recommended two modifications. One required limiting the application of the suspect recovery action. In this case, the recovery action had been added to improve recovery performance in two expensive failures, removing it would set performance back to previous levels. The other modification, which was adopted, was to check how the projection calcu- lations set and the envelope action uses the variable attack-projectionand make explicit the differing as- sumptions of the three projection actions so that later actions could reason about the assumptions. The three actions differ in how they search for projections and in how they assess the resources’ capabilities. The enve- lope action uses summaries of the resources’ capabili- ties to construct expectations of progress for the plan. By examining the code, it became obvious that the summaries set by the three projection actions differed not only in how they were estimated but also in what capabilities were included (e.g., rate of building fireline, rate of travel to the fire, startup times for new instruc- tions, and refueling overhead). Because the envelope assumed that the summaries reflected only the rate of building fireline, the conditions for signaling fail- ures effectively varied among the different projection actions. To accommodate these differences, the pro- jection actions were restructured to set separate vari- 390 Planning Dependencies A Total Shared B Total _RJl 15 4 12 r .F, Fl 15 4 12 -FR, F] 16 0 0 Table 2: Overlap in dependency sets for original plan- ner (A) and modified planner (B) ables for each of the capabilities; the envelope action then combines the separate variables to define expected progress. The modified planner was tested in 87 trials of the same experiment setup used for the earlier three experiments and analyzed for dependencies. If the recommended modification was appropriate, the ob- served [Rsp, F,it] dependency should have disappeared, as well as other dependencies involving projection actions and the envelope action. In fact, all four of the dependencies involving projection actions and the envelope action previously observed - [Rsp, F,it], [FnerRrp, Gt], [FpTjRrp, %t], and [&.&A &it] - were missing from the modified planner’s execution traces. Additionally, the restructuring of the actions led to a lower incidence of a general failure to calcu- late projections (F,,j); Fprj accounted for 20.8% of the failures in the previous experiment and only .3% in this experiment. By repairing a hypothesized cause of fail- ure, one would also expect the overall rate of failures to decline. The data showed a decrease in the mean failures per hour from .41 in the previous experiment to .33 in this experiment. Because the dependency sets reflect the interaction of the planner and failure recovery, similar designs for the planner and failure recovery should result in similar dependency sets. We can test this intuition by examin- ing the dependency sets derived from execution of dif- ferent versions of the system and counting the number of significant dependencies shared by the different ver- sions. Table 2 shows the number shared between the most similar previous system and the modified plan- ner: about 30% (4 out of 15 total) of the [R, F] and [F, F] dependencies from the first set appeared in the second.’ The more we change the system, the more the dependency sets should change. In fact, the depen- dency sets for these two planner and recovery configu- rations as well as two others showed moderate overlap between similar systems, but negligible overlap across systems that differed by more than one aspect of their design. Some of the implications of the overlap in de- pendencies will be discussed in the last section. Applying FRA to Phoenix improved the planner’s ‘Many more dependencies appeared in the first than the second set. The reduction in overall number of dependen- cies between these sets was mostly due to the elimination of dependencies involving the failure Fptj, which was hardly ever observed in execution traces of the modified planner. performance by removing the targeted dependency and reducing the overall incidence of failure. The analysis showed how failures depend on their immediate pre- decessors. The cost of this information is the effort required to perform the analysis and the computation time required for the experiments. The computational effort required for the analysis was minimal; calculat- ing the first step and part of the second took less than five minutes for the two data sets. Generating the ex- ecution traces for the two data sets required about 45 hours of CPU time or about two days per data set. Considering the possible repercussions of even simple planner modifications, the turnaround time for results seems worth the information gained. Generalizing to Other Planners The experience with Phoenix should generalize to other planners. The primary requirement for FRA is lots of data about how the planner performs. Each experiment with Phoenix represents over 5000 hours of simulated time. Simulators expedite controlling the environment and gathering data; controlled testing of planners in “real” environments increases the effort re- quired to collect the data. The consequence of getting too little data is that rare failures and their associ- ated dependencies will be missing. The technique does not guarantee that all dependencies will be found; the confidence in the dependency relationship increases lin- early with the amount of data. Given the availability of the data, the first step in FRA is applicable to any planner and environ- ment. The remaining steps have been tailored to Phoenix, but conceptually could be expanded for other planners. These three steps are based on ex- plaining failures by matching patterns to explanations and modifications (as in the “retrieve-and-apply” ap- proach [Owens, 19901). The previous application of the “retrieve-and-apply” approach to debugging other planners (e.g., [Sussman, 1973, Hammond, 19871) sug- gests that generalizing FRA involves expanding its model of the planner - the set of suggestive struc- tures and explanations - to include ones appropriate for other planners. Beyond the need to expand the underlying knowl- edge, FRA will need to be extended in other ways as well. The dependencies encompass only temporally ad- jacent failures and actions. The combinatorial nature of the dependency analysis precludes arbitrarily long sequences of precursors, but at least in the analyzed data sets, increasing the temporal separation between the precursor and the failure decreases the size of the dependency sets, suggesting that the incidence of de- pendencies over longer chains is small. A new experi- ment design is being developed to selectively eliminate recovery actions from the available set to test whether each precipitates or avoids particular failures. Rather than examining all possible chains of which some ac- tion is a member, the new analysis removes the action Howe 391 from consideration which results in execution traces free from the interaction of the missing action. By com- paring the dependencies for each action removed, one can infer which dependencies were due to interactions with the missing actions. For example, if an action, say Rsp, is removed from the set and the frequency of F,,it relative to other failures decreases, then one could see whether dependencies in [F,Rsp, F,it] triples explain all the surplus F,it failures when R,, is in the set, or whether R,, affects F,i, over longer intervals. Conclusion Analyses of failure recovery can contribute in several ways to our understanding of planner performance. As described, FRA can identify contributors to failure and assist in the debugging and evaluation of planners with incomplete or incorrect domain models. Additionally, the dependencies provide a measure of similarity be- tween test situations. The more the environment and agent changes, the more one expects observed effects to change; thus, dependencies can be a kind of similarity measure across planners and environments. The lesson from this analysis is that while design changes rarely have isolated effects, designers do not have to give up hope of analyzing the effects. They can track the effects: They make minor changes and havoc ensues, but they have a way to assess the havoc. Phoenix is an example of a system that can interleave plans in arbitrary ways, as dictated by situation. De- bugging its failures by “watching the system” or by predicting all possible execution traces is simply not feasible, but running Phoenix many times and ana- lyzing the data is feasible. Failure recovery analysis isolates indirect effects of design changes and proposes explanations and modifications based on a weak model of the planner and its environment; its primary contri- bution is in helping us understand how planning deci- sions and actions interact and assisting in debugging planners under development. References Atkinson, David; James, Mark; Porta, Harry; and Doyle, Richard 1986. Autonomous task level control of a robot. In Proceedings of ROBEXS 86, Second Annual Workshop on Robotics and Expert Systems. 117-122. Chien, R.T. and Weissman, S. 1975. Planning and execution in incompletely specified environments. In Proceedings of the Fourth International Joint Con- ference on Artificial Intelligence, Tiblisi, Georgia, USSR. 160-174. Cohen, Paul R.; Greenberg, Michael; Hart, David M.; and Howe, Adele E. 1989. Trial by fire: Understand- ing the design requirements for agents in complex en- vironments. AI Magazine lO(3). Hammond, Kristian J. 1987. Explaining and repair- ing plans that fail. In Proceedings of the Tenth Inter- 392 Plannine: national Joint Conference on Artificial Intelligence, Milan, Italy. International Joint Council on Artificial Intelligence. 109-l 14. Hart, David M.; Cohen, Paul R.; and Anderson, Scott D. 1990. Envelopes as a vehicle for improv- ing the efficiency of plan execution. In Sycara, Ka- tia P., editor 1990, Proceedings of the Workshop on Innovative Approaches to Planning, Scheduling and Control, Palo Alto, Ca. Morgan Kaufmann Publish- ers, Inc. 71-76. Hayes, Philip J. 1975. A representation for robot plans. In Proceedings of the Fourth International Joint Conference on Artificial Intelligence, Tiblisi, Georgia, USSR. International Joint Council on Ar- tificial Intelligence. Howe, Adele E. and Cohen, Paul R. 1991. Failure recovery: A model and experiments. In Proceedings of the Ninth National Conference on Artificial Intel- ligence, Anaheim, CA. 801-808. Howe, Adele E. 1992. Accepting the Inevitable: The Role of Failure Recovery in the Design of Planners. Ph.D. Dissertation, University of Massachusetts, De- partment of Computer Science, Amherst, MA. Forth- coming. Kambhampati, Subbarao 1990. A theory of plan mod- ification. In Proceedings of the Eight National Confer- ence on Artificial Intelligence, Boston, MA. 176-182. Lee, M.H.; Barnes, D.P.; and Hardy, N.W. 1983. Knowledge based error recovery in industrial robots. In Proceedings of the Eighth International Joint Con- ference on Artificial Intelligence, Karlsruhe, West Germany. 824-826. Owens, Christopher 1990. Representing abstract plan failures. In Proceedings of the Twelfth Cognitive Sci- ence Conference, Boston, MA. Cognitive Science So- ciety. 277-284. Simmons, Reid G. 1988. A theory of debugging plans and interpretations. In Proceedings of the Seventh National Conference on Artificial Intelligence, Min- neapolis, Minnesota. 94-99. Sussman, Gerald A. 1973. A computational model of skill acquisition. Technical Report Memo no. AI-TR- 297, MIT AI Lab. | 1992 | 69 |
1,264 | On the synthesis of useful social r artificial agent societies (preliminary report) Yoav Shoham and Moshe Tennenholtz Robotics Laboratory Department of Computer Science Stanford University Stanford, CA 94305 Abstract We present a general model of social law in a compu- tational system, and investigate some of its proper- ties. The contribution of this paper is twofold. First, we argue that the notion of social law is not epiphe- nomenal, but rather should be built into the action representation; we then offer such a representation. Second, we investigate the complexity of automati- cally deriving useful social laws in this model, given descriptions of the agents’ capabilities, and the goals they might encounter. We show that in general the problem is NP-complete, and identify precise condi- tions under which it becomes polynomial. 1 Introduction This paper is concerned with the utility of social laws in a computational environment, laws which guaran- tee successful coexistence of multiple programs and programmers.We imagine an environment in which multiple planners/actors are active; we will call these ‘agents’ here, without attaching precise technical meaning to the term (but see the formal development in the next section).l To illustrate the issues that come up when design- ing a society, consider the domain of mobile robots. Although still relatively simple, state-of-the-art mo- bile robots are able to perform several sorts of tasks. They can move from place to place, identify and grasp simple objects, follow moving objects, and so on. Each of these tasks involves sophisticated techniques, but is, broadly speaking, achievable with existing planning and control technology. However, when we consider gathering several robots in a shared environ- ment, a host of new problems arises. The activities ’ As a special case, we are interested in extending work of Agent Oriented Programming (AOP) [IO]. the frame- of the robots might interfere with one another: The planned spacetime paths of robots might intersect, an object needed by one robot might be removed by an- other, bottlenecks might occur, and so on. Similarly, robots may require the assistance of other robots to carry out their task. How is one to deal with these phenomena? There are two extreme answers, neither of which is in gen- eral acceptable. One is to assume a single program- mer, whose job it is to program all the robots. As such, he will need to worry about all possible inter- actions among them, in exactly the same way as he worries about the interactions among the different ac- tions of a single robot (see [2] or [5]). This answer is unsatisfactory for several reasons. First, it is unrea- sonable to expect that a single individual will control all agents. For example, in the Gofer project [3] 100 or so mobile robots are to be programmed individu- ally in much the same way as workstations are used. Second, the set of agents can be expected to change over time, and one would hardly want to have to re- program all agents upon each addition or deletion of an agent. Finally, even if a single programmer were given the task of programming all the agents, we have given him no guidelines as to how to achieve the task. To the extent that he will proceed by programming each agent individually, he will be forced to deal with the interactions among the different programs. An alternative extreme answer is to admit that agents will be programmed individually in an uncon- strained fashion, to acknowledge that as a result in- teractions will occur, and to equip the agents with the means for handling these interactions during ex- ecution. These means may take various forms. For example, one approach is to merely detect the interac- tions as they occur, and appeal to a central supervisor for resolution. An alternative method for handling in- teractions is to equip the agents with communication capabilities, and program them to engage in series of communications to resolve interactions. Again, using 276 Multi-Agent Coordination From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. the domain of mobile robots for illustration, when two robots note that they are on a collision course with one another, they may either appeal to some central traffic controller for coordination advice, or alternatively they might engage in a negotiation re- sulting (say) in each robot moving slightly to its right. The use of negotiation to resolve conflicts is com- mon in the distributed AI literature (see [l] or [S]). Nonetheless, there are limitations to this second ap- proach as well. By placing no constraints in advance, the number of interactions may be prohibitive; either the central arbiter may be deluged by pleas, or else agents will have to enter into negotiations at every step. While we certainly do not argue against the utility of either a central coordinator or a negotia- tion mechanism, we do argue that it is essential to add a mechanism that will minimize the need for ei- ther. Again, we draw on the domain of mobile robots for intuition. Suppose robots navigate along marked paths, much like cars do along streets. Why not adopt a convention, or, as we’d like to think of it, a social 1a.w) according to which each robot keeps to the right of the path ? If each robot obeys the convention, we will have avoided all head-on collisions without any need for either a central arbiter or negotiation. This then is the image, which is not original to us; it is implicit in many places in AI, and was made ex- plicit already by Moses and Tennenholtz ([7],[$]). The society will adopt a set of laws; each programmer will obey these laws, and will be able to assume that all others will as well. These laws will on the one hand constrain the plans available to the programmer, but on the other hand will guarantee certain behaviors on the part of other agents. The two approaches discussed above simply mark the endpoints of this tradeoff continuum. The first, “single programmer” approach stretches the notion of a social law so as to completely dictate the behavior of each agent, leaving no freedom to the individual programmer. The sec- ond approach adopts an opposite, degenerate form of social law, the vacuous law. The goal of the intended theory of social laws will be to relax the restriction to these extreme solutions, and instead to strike a good balance between allowing freedom to the individual programmers on the one hand and ensuring the co- operative behavior among them on the other. How is one to decide on appropriate social laws? One approach is to hand-craft laws for each domain of application. This is the approach we take in a t companion paper [9], where we present a number of traffic laws for a restricted domain of mobile robots. Several systems built by DA1 researchers have used organization structures (see [4]) for enabling agents to achieve a cooperative goal. These structures can be considered as a type of social laws. III this paper we tackle a different problem; we are interested in a general model of social law in a computational sys- tem, and in general properties that can be proved in that model. The contribution of this paper is twofold. First, we argue that the notion of social law, or con- straints, is not epiphenomenal, but rather should be built into the action representation; we then offer such a representation. Second, we investigate the complex- ity of automatically deriving useful social laws in this model, given descriptions of the agents’ capabilities, and the goals they might encounter over time. We show that in general the problem is NP-complete, and identify precise conditions under which it becomes polynomial. The remainder of this paper is structured as fol- lows. In the next section we set up the formal model of multi-agent actions. In section 3 we state the com- putational problem precisely, and show that in its full generality the problem is NP-complete. We also show a similar result for one natural restriction on the gen- eral model. In section 4 we formulate additional nat- ural restrictions on the general model; we show that these conditions are both necessary and sufficient for the problem to become polynomial. Finally, we look at a special case in which the states of agents happen to be encodable concisely, and show that there too the problem is polynomial. We conclude with a sum- mary, discussion of related work, and planned future work. The general framewsr The term ‘agent’ is common in AI, and used in di- verse ways. Here we will take an agent to have state, and to engage in actions which move it among states. Although this basic definition is consistent with most uses of the term in AI, it is perhaps somewhat too im- poverished to be worthy of the lofty name. However, our goal here is not to contribute to the theory of in- dividual agents but to the theory of social law, and so it will be illuminating to initially adopt a model in which all the complexity arises from the existence of multiple agents, and not from the behavior of in- dividual agents. We adopt a synchronous model: Agents repeatedly and simultaneously take action, which leads them from their previous state to a new one. The actions of an agent is taken from a given repertoire. The problem in defining the transition functions of agents is due to the fact that the state in which the agent Shoham and Tennenholtz 277 ends up after taking a particular action at a particu- lar state, depends also on actions and states of other agents. Thus, in principle, we could think of the tran- sition function of the entire system, a mapping from the states and actions of all agents to the new states of all agents. In this view, for example, in order to deter- mine the effect of one car turning left at an intersec- tion, we would have to specify the states and actions of all other cars. An alternative view would be to define the transition function of each agent indepen- dently, and account for the effects of other agents by making the function nondeterministic. In this view, for example, the effect of turning left at an intersec- tion would be either a new position and direction of the car, or a collision. These are two extreme approaches to modelling concurrent actions. In the first approach, all infor- mation about other actions must be supplied, and the transition function produces the most specific predic- tion. In the second approach, nu information about other agents is supplied, and the transition function produces the most general prediction. Instead of adopting either extreme view, we propose an inter- mediate approach. We propose adding the concept of social law, or constraints on the behavior of agents. The constraints specify which of the actions that are in general available are in fact allowed in a given state; they do so by a predicate over that state. The transi- tion function now’takes as an argument not only the initial state and the action taken by the agent, but also the constraints in force; it produces a prediction about the set of possible next states of the agent. For example, it might predict that as a result of turning left at the intersection, given certain trafic rules, the car will successfully complete the turn. We claim that this is a natural representation of actions, and an advantageous one. Generally speak- ing, the prediction based on constraints will be more general than the prediction that is based on the pre- cise states and actions of all other agents, and more specific than the prediction based on no information on the other agents. A final comment, before we present the formal model. We make an assumption of homogeneity; specifically, we assume that the sets of states and the available actions are common to all agents. We do not assume that the agents will necessarily be in the same state at any time, nor that they will take the same action when in the same state; only that they “have the same hardware.” Similarly, we assume an egali- tarian society, in which the same constraints apply to all agents. None of these assumptions are crucial to our approach, but they simplify the discussion. The formal model Definition 2.1: Given a set of states S, a first order language C (with an entailment relation k), and a set of actions A, a constraint is a pair (a, cp) where a E A and cp E C is a sentence. A social law is a set of constraints (ai, cpi), at most one for each ai E A. The language L will be used to describe what is true and false in different states. Given a state s E S and a sentence ‘p E C:, s might satisfy or not satisfy ‘p. We denote the fact that s satisfies ‘p by s b ‘p. The intuitive meaning of (ai, cpi) will be that cpi is the most general condition about states which prohibits taking action ai. In the sequel, we will use the following notation. Given a pair of social laws, sir and s/a, we denote by s/a < sir the fact that for every (ai, cpi) E sla there exists (ai, cpj) E sir such that ‘pj b ‘pi. Intuitively, it will mean that sdr is more restrictive than s/g. Definition 2.2 : A social agent is a tuple (S, L, A, SL, T) where S, ,C, A are as above, SL a set of social laws, and 7’ is a total transition function T : S x A x SL -+ 2s such that: e For every s E S, a E A, sl E SL, if s + cp holds and (a,~) E sl then T(s, a, sI) = a, the empty set. o For every s E S, a E A, s/l E SL, ~12 E SL, if sZ2 < sll then T(s, a, sll) s T(s, a, sl2). In practice, the transition function T will be only partially specified. If T(s, a, sZ) is not explicitly de- fined for a particular sl, then T(s, a, sI) is assumed to be the conjunction of all explicitly defined T(s, a, s/i) satisfying that s/i < sl. If this conjunction is over an empty set then T(s, a, ~1) = @, the empty set. Definition 2.3: A social multi-agent system is a col- lection of social agents which share the set of states, the language for describing states, the set of poten- tial actions, the set of potential social laws, and the transition function.2 2Recall again that the same hardware”. this only means that the agents “have 278 Multi-Agent Coordination The multi-agent system defined in the previous sec- tion provides one degree of freedom in addition to those present in standard multi-agent models: The social law in effect. Once we fix the social law, the social multi-agent system reduces to a standard one, since all transitions which are incompatible with this law are now ignored. (Note, however, that the re- maining transitions may still be nondeterministic.) Thus, a social multi-agent system and a particular social law together induce a standard multi-agent sys- tem, which makes no reference to social laws. Loosely speaking, the computational problem will be to select from among the candidate social laws one that, given the social multi-agent system, will induce a ‘good’ standard system. But what makes for a ‘good’ sys- tem? For this purpose we identify a subset of the set of states, which we call focal states. We will be in- terested in a social law which will ensure that each agent, given two focal states, is able to construct a plan guaranteed to move him from one state to the other - no matter what actions are taken by other agents. Note the existence of a certain tradeoff: The more restrictive the law, the more can the planner rely on the effects of his actions, but, on the other hand, the more restrictive the law, the fewer actions are available to the planner in the first place. In se- lecting a social law we wish to strike a good balance, allowing each agent enough freedom to achieve its goals but not enough freedom to foil those of others. We now turn to the formal development. Intu- itively, an agent’s legal plan is a decision on how to act in each state, in a way which is consistent with the law in force: Definition 3.1 : Given a social agent (S,L,A,SL,T) and a social law sl E SL, a legal plan is a total function DO : S ---f A such that if (a, cp) E sl and s /= cp holds, then DO(s) # a. An execution of the plan from a state SO is a sequence of states SO, s1, ~2, . . . such that si+l E T(sa, DO(si), sl). Note that a plan forces the agent to take action at every step, but we certainly allow the user to include the null action, which might leave states unchanged. Also note that even if the null action is included, some social laws may prohibit it in certain states! Definition 3.2: Given a social multi-agent system We start by imposing the following restriction: For and a subset F of the set of states (the focal states), each state s, the number of transitions which might a useful law is a law for which, given any ~1, s2 E F, there exists a legal plan such that every execution of that plan in s1 includes ~2. Note that, strictly speaking, we cannot speak of a plan ‘leading’ to the goal, since the plan is by defini- tion infinite. Also note that this definition does not mean that there necessarily exists one fixed sequence of actions that will connect two focal states; an action of the agent may have nondeterministic effects, and the following action in the execution of the plan may depend on the state in which the agent landed. We are now in a position putational problem: to phrase a precise com- Definition 3.3 : [The Useful Social Law Problem (USLP)] Given a social multi-agent system and a set of focal states, find a useful law if one exists, or, if no such law exists, announce that this is the case. The technical results in this paper concern the computational complexity of the USLP. In order to present quantitative results we have to be more pre- cise about some of the details of our model. In the following we will assume that the number of states in the representation of an agent is finite and is de- noted by n, and we will measure the computational complexity as a function of n. We assume that the total size of an agent’s representation is polynomial in n. We also assume that each property of the form s /= (p, and of th e f orm sll < 2712 can be efficiently verified. The following theorem shows that the general USLP is intractable, although its complexity is lower than the complexity of many other problems dis- cussed in multi-agent activity (see [ll]): Theorem 3.1: The USLP is NP-complete. We point again that, since the USLP is computed off-line, this result is not entirely negative. Still, it would be satisfying to be able to achieve lower com- plexity by imposing various restrictions on the struc- ture of agents. This is what we do in the next two sections. 4 Several eneral el Shoham and Tennenholtz 279 change s is bounded by O(Zog(n)).3 This is a straight- forward generalization of the natural “bounded fan- out? restriction which is common for classical au- tomata. Intuitively, this restriction says that the number of actions an agent might perform at a given state is small relative to the total number of states, while the quality of the information about constraints which might be relevant to the effects of a particular action in a particular state is relatively high. Our log- arithmic bound enables us to treat the case in which the number of transitions which are applicable in any given state is small relative to the total number of states, while it is still a function of that number. No- tice that the total number of actions and social laws appearing in the representation might still be much more than logarithmic. The computational problem restriction is defined as follows: related to the above Definition 4. I. : [The Bounded Useful Social Law Problem (BUSLP)] G iven a social multi-agent system where the number of transitions which might change a particular state is bounded by O(log(n)), and a set of focal states, find a useful law if one exists, or, if no such law exists, announce that this is the case. On it own, this natural restriction does not buy us a whole lot as far as the computational complexity goes: Theorem 4.1: The BUSLP is NP-complete. However, we have not presented this restriction as a. mere curiosity; we now present precise conditions under which the BUSLP become tractable. Consider the following three restrictions: 1. The number stant c. of focal states is bounded by a con- 2. For any pair of focal states si, s2 E F , there exists a legal plan all of whose executions reach s2 starting at s1 while visiting the same sequence ofstates. Intuitively, this requirement states that it is not enough that there be a plan, as required in the definition of a useful law; the plan must be deterministic. 3. For any pair of focal states ~1, sz E F , there exists a legal plan all of whose executions reach s2 starting at s1 in no more than 0 ( a > steps. Intuitively, this requirement states that it is not enough that there be a plan; the plan must be short. 31f qs, a, sl*) = T(s,a, sip) for s/2 < sll then we do not count T(s, a, ~11) as one of the transitions. These three restrictions may or may not be accept- able; although we expect that they are reasonable in some interesting applications, we take no stance on this here. The significance of these restrictions is that they allow us to state precise conditions under which the BUSLP becomes polynomial: Theorem 4.2: The B USL P is polynomial if restric- tions 1, 2, and 3 hold, and NP-complete otherwise. agents In the previous section we provided necessary and suf- ficient conditions under which the BUSLP becomes polynomial; note that this result does not provide necessary conditions for the USLP to become polyno- mial (it provides only sufficient conditions for that). Indeed, in this section we mention a different restric- tion of the USLP which guarantees polynomial time complexity. The general framework imposes no structure on the set of states, and places no restrictions on the num- ber of laws which affect the results of any particular action. In practice, there is much more structure in the makeup of agents. For example, while the set of states might be very large, it is usually possible identify components of the agent, such that the set of states of the agent consists of the Cartesian prod- uct of the sets of states of the individual components. If we consider for example the representation of a robot, then one component may relate to its loca- tion, another to its orientation, and another to its arm position. This rnodularity of states is the first restriction we consider here; specifically, we assume that there exist O(log(lz)) components, each of which can be in one of a constant number of states. Thus the state of an agent consists of the Cartesian product of these states. The total number of an agent’s states is still n; note that this is no contradiction. The modularity of state gives rise to a modular- ity of action; usually, only a small number of social laws will be relevant to determining the change in the state of a particular component as a result of a par- ticular action. In the robotic setting, for example, a change in the particular location of the robot might depend on particular traffic laws, but not on laws requiring one to shut windows after opening them, on laws prohibiting one from taking the last cookie 280 Multi-Agent Coordination without announcing the fact, and perhaps not even on many of the possible traffic laws. We capture this intuition by requiring that the change of a particular state of a particular component can depend on only a constant number of social laws. We will use the term modular social agent to de- note an social agent whose structure has these two properties of modularity, and modular social multi- agent system to denote a collection of such agents.4 Notice that these restrictions are separate from those discussed in the previous section. Modular systems have the following property: Theorem 5.1: Given a modular social multi-agent system, the USLP is polynomial. 6 Conclusions A basic approach to coordinating multiple agents is to restrict their activities in a way which enables them to achieve their dynamically-acquired goals while not interfering with other agents. Although this is, we believe, a commonsensical approach, it has not re- ceived much attention so far within AI; exceptions include [7] and [8], where the authors investigate sev- eral basic principles and formal aspects of this ap- proach. We have presented model of multi-agent ac- tion whose novel feature is the explicit mention of social laws in the definition of agents. We then inves- tiga,ted the fundamental computational problem in- volved with finding useful social laws: We showed the general problem intractable, and then identified re- strictions which achieve tractability. We believe that the formal model and complexity results both consti- tute an essential contribution to our understanding of the role of social law in artificial intelligence. Much remains to be done. For example, as was mentioned at the beginning, we have assumed a ho- mogeneous society, both in term of the makeup of agents and in terms of the applicability of social laws. In future work we will relax this assumption, made here only for convenience. Harder assumptions to re- lax include the assumption of law-abiding citizenship; here we have assumed that all agents obey the social laws, but what happens if some don’t? How vulnera- ble is the society to rogue agents? In fact, arguments had been made about that social laws will sometimes be break, and that the penalty for this should be con- sidered in the stage of design. Similarly, we have as- sumed that the useful social law is computed off-line. *A full formal definition will appear in the full paper. Sometimes this is infeasible, however, either because the makeup of the agents is not known in advance, or because it changes over time. In such cases, can we devise methods by which, through trial error, the agents will over time converge on a social law? These are some of the questions in which we are currently interested. rences PI PI PI Fl PI PI PI PI PI WI Pl3 A. H. Bond and L. Gasser. Readings in Dis- tributed Artificial Intelligence. Ablex Publishing Corporation, 1988. S.J. Buckley. Fast motion planning for multi- ple moving robots. In Proceedings of the 1989 IEEE International Conference on Robotics and Automation, pages 322-326, 1989. P. Caloud, W. Choi, J.-C Latombe, C. Le Pape, and M. Yim. Indoor aut#omation with many mobile robots. In Proceedings IEEE Interna- tional Workshop on, Intelligent Robots and Sys- tems, Tsuchiura, Japan, 1990. Edmund H. Durfee, Vicror R. Lesser, and Daniel D. Corkill. Coherent Cooperation Among Communicating Problem Solvers. IEEE Trans- actions on Computers, 36: 1275-1291, 1987. M. Erdmann and T. Lozano-Perez. On multi- ple moving robots. Algorithmica, 2(4):477-521, 1987. S. Kraus and J. Wilkenfeld. The Function of Time in Cooperative Negotiations. In Proc. of AAAI-91, pages 179-184, 1991. Yoram Moses and M. Tennenholtz. Artificial So- cial Systems Part I: Basic Principles. Technical Report CS90-12, Weizmann Institute, 1990. Yoram Moses and M. Tennenholtz. On Formal Aspects of Artificial Social Systems. Technical Report CS91-01, Weizmann Institute, 1991. Y. Shoham and M. Tennenholtz. On Traffic Laws for Mobile Robots. Submitted to AIPS-92. Yoav Shoham. Agent Oriented Programming. Technical Report STAN-CS-1335-90, Dept. of Computer Science, Stanford University, 1990. M. Tennenholtz and Yoram Moses. On Coop- eration in a Multi-Entity Model. In Proc. 11th International Joint Collference on Artificial In- telligence, 1989. Shoham and Tennenholta 281 | 1992 | 7 |
1,265 | Constrained Decision Charles Petrie MCC AI Lab 3500 West Balcones Center Austin, TX 78759 petrie@mcc.com Abstract This paper synthesizes general constraint satisfac- tion and classical AI planning into a theory of in- cremental change that accounts for multiple ob- jectives and contingencies. The hypothesis is that this is a new and useful paradigm for problem solv- ing and re-solving. A truth maintenance-based architecture derived from the theory is useful for contingent assignment problems such as logistics planning. Introduction There is a large class of practical planning problems that require not only general constraint satisfaction but also search by reduction and incremental replan- ning lacking in classical constraint satisfaction for- malisms. Classical AI planning, in the form of hier- archical nonlinear planning, provides a useful method of search reduction, but an inadequate representation for consistency and replanning. Such problems, which we call Constrained Decision Problems (CDPs), are characterized by multiple objec- tives, a large space of acceptable solutions from which only one is sought, general constraints, succinct rep- resentation by decomposable goals, and replanning: the necessity to react precisely to changed conditions. Travel planning is a prototypical example of a CDP: a plan consists of assignments, rather than actions, sat- isfying constraints and depending upon assumptions that may change during planning and execution. As a simple example, suppose we want to represent the following travel planning knowledge. Given the goal of traveling from one place to another, there are three methods of doing so: flying, and taking a bus or a taxi. Flying is preferable if the trip is more than 100 miles. Otherwise a taxi is preferable. If we choose to fly, we decompose the problem into two subproblems: choosing a flight to the nearest airport and finding a way from the airport to our final destination. We pre- fer the cheapest flight. There are contingencies. In- dividual flights and buses can be canceled. Airports can be closed. Taxis and cars may be unavailable. All evision Drive Goal-l Visit Arlington from Austin Choose Taxi X Budget / \ Goal-2 Goal-3 Find a flight Visit Arlington from DFW / Budgetcr---PChOose / Taxi 2 udget X I Choose Choose -Budget -Q-----D, BUS DEL201 X X Figure 1: Problem State travel methods have costs. There is a travel budget constraint. The following problem solving scenario indicates the desired use of this knowledge by a planner. The goal was to go from Austin to Arlington, Texas. The plan- ner made a decision to fly. This resulted in two sub- goals: finding a flight to the DFW airport, and getting from the airport to the suburb of Arlington. Initially, based on cost, flight AA86 and the airport shuttle bus were chosen, the taxi being preferable but too expen- sive. Then flight AA86 was canceled. The planner noted that part of the plan no longer worked and at- tempted to fix just that part. Another flight, DEL201, was tried but it was too expensive, even using an airport shuttle bus. The de- Petrie 393 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. cision to fly had to be retracted, since there were just the two flights. A taxi was too expensive to use for the whole trip, so the plan was to go by bus from Austin to Arlington. Figure 1 shows this state of problem solv- ing. X denotes an alternative that was tried and either invalidated or rejected due to the budget constraint. 0 denotes the current solution. Now, if flight AA86 is rescheduled in this state, the planner should notify the user of this opportunity and allow the user to drop back to this preferable state if we desired. Similarly, the user would like to know by how much the budget should be increased to afford flight DEL201. And the planner should inform the user if that option is possible upon discovery of a new shuttle bus price. In no case do we want our current plan changed automatically. This might be only part of a larger plan the user doesn’t want rearranged. No previous formalism is suitable for providing the computer support illustrated above. Alternatively, ad hoc applications with such functionality quickly be- come too difficult to manage for more complex prob- lems. Existing shells do not supply the right primitives to reduce the complexity. In this paper, we provide a formalism and an architecture that simplifies repre- senting and solving such CDPs, The example above is represented in the architecture by declaring two types of goals, four operators for satisfying them, one con- straint, and three preference rules. The contingencies are represented by operator conditions. Why Not Constraint Satisfaction? CDPs are typically constrained task/resource assign- ment problems that occur over time, such as con- struction planning, teacher/course assignment, and logistics. However, constraint satisfaction or inte- ger programming techniques are unsuitable for these problems. l First, global objective functions of integer program- ming are inadequate for multiple objectives. Second, replanning from scratch is inadequate because of the desirability of minimal change to a plan and the lack of control integer programming provides. Third, to formulate a constraint satisfaction or in- teger programming problem, one must enumerate all of the possibilities/variables. However, CDPs are con- structive in that new objects are typically created at runtime; e.g., a subcomponent of a design or a leg of a trip. But an attribute together with an object defines a variable to which a value may be assigned; e.g, the cost of a particular trip leg. Thus defining all variables means anticipating the creation of all possible objects, whether used in the final plan or not. This is a diffi- cult task in the formulation of constructive problems. ‘Integer p ro ramming g is a special case of constraint satisfaction with an additional objective function to be maximized. Yet the integer programming and constraint tion formalisms needlessly require this work. satisfac- Generalizing Classical Planning CDPs only require a single solution (or a few) out of a large space of acceptable ones. Hierarchical, nonlin- ear planning (HNP) is a good problem solving tech- nique for CDPs. In hierarchical planning [lo], a plan can progress from higher to lower levels of abstraction through plan transformations. In nonlinear planning [ll], actions need not be totally ordered with respect to time, and ordering need be introduced only as neces- sary [12]. If HNP is used in heuristic-guided depth-first search, problem decomposition is provided, only a few solutions are explored, and objects and assignments are created only when the required level of specificity is reached. But classical HNP does not provide for the general constraint satisfaction needed by CDPs, where constraints on assignments are frequently boolean or global resource usage. task QSji~~ schema application I schema 1 MAKE-O/V 1 I reduction new task primitive task Figure 2: HN Planning Classical HNP defines the application of s&emus to tusks[4]. We generalize this as the application of oper- ators to goals, perhaps creating new subtasks and/or actions. We generalize this to say that the application of an operator to a goal may result in subgoals and/or variable assignments. Figures 2 and 3 illustrate two major differences between HNP schema reduction and CDR decision making. The first is that the choice of an operator to reduce a goal from a conflict set of ap- plicable operators is a decision with a rationale. Sec- ond, actions and orderings are represented as general variable assignments. More typically in a CDP, an as- signment is something like the cost of the leg of a trip or, in another example, the assignment of a professor to teach a course. The importance of representing a decision rationale and assignments is described below. 394 Planning goal ON(A B tl) q operators I I 1 decision MAKE-ON reduction @Fade”..,, new goal = PUT-ON(A B tl) assignment Figure 3: CDP Solving ecision evision HNP proceeds by reducing tasks until nothing but primitive tasks are left. CDP solving proceeds sim- ilarly. If an operator has been validly applied to a goal, then that goal is reduced and need not be fur- ther achieved. When no goal is left un-reduced, all goals are satisfied and a complete solution consisting of assignments is achieved. Constraints are consistency conditions, initially satisfied, that may be violated by decisions. Goals are patterns to be reduced by opera- tors. Consistency is directly evaluated by the planner whereas goal satisfaction is assumed if an operator has been applied. We can then cast the design of a plan as a series of such operator applications, i.e., decisions. Backtracking and replanning are cases of decision re- vision. Backtracking In classical HNP, schemas have pre- and post- conditions that might conflict with each other. HNP is specialized to satisfy the implicit binary constraints de- fined by these conditions. This is optimal for temporal action sequence consistency, but not for general con- straints. E.g., gadgets may not be configured with wid- gets, no one may teach more than two classes, and the budget must not be exceeded. In contrast to STRIPS- style conditions, in CDPs, we require that all possible conflicts among decisions be explicitly stated as con- straints among resulting assignments. (Constraints are encoded as Horn clauses and indexed to the variables in their domain in the implementation.) This is no more restrictive than the STRIPS requirement to state all relevant conditions, and it allows more general con- straints to be represented. Using the general notion of variable assignment al- lows the use of general techniques of constraint satis- faction, including variable choice, delayed resolution, propagation, and dependency-directed backtracking. When some set of assignments is determined to con- flict with a constraint, it can always be resolved by retracting some minimal set of decisions.2 That is, decisions are a distinguished set of assumptions that can be retracted at will. This retraction of decisions is backtracking. Because only decisions are consid- ered that support the assignments in the conflict, it is dependency-directed backtracking. Replanning - Catastrophes An expectation about the environment in which plan actions will be taken is another kind of assumption. Associated with each operator is a set of admissibid- ity conditions. A decision is valid only as long as these hold. The admissibility of one decision may not depend upon the validity of others - that would be a constraint. But admissibility may depend upon assumptions about the plan execution environment, such as the availabil- ity of a resource. Events may prove such expectations wrong - a contingency occurs. E.g., a flight is canceled or a professor falls ill. In such a case, some decisions will become invalid. This may cause the loss of satis- faction of some goal - a catastrophe. It is important to represent these assumptions dif- ferently from the contingent nature of decisions. The latter can be retracted at will (until committed) in the face of constraints. But to change our assumptions about the environment for the sake of planning conve- nience is to indulge in the wishful thinking noted by Morris [5]. Backtracking must be restricted to deci- sion retraction: environmental assumptions can only be changed because of new information. eplanning - Bpport unit ies There may be a partial ordering associated with each set of operators, and operator instances, applicable to a goal. Based on heuristics, this ordering provides a rationale for the decision to apply one, from the con- flict set of possibilities, to the goal. (These preferences are also encoded as Horn clauses in the implementa- tion.) If the goal is viewed as an objective, this partial ordering defines the local optimadity of different ways of satisfying the objective. This optimality may be conditional on environmental expectations in the same way that admissibility was. If they change, the or- dering may change. Possibly, some decision ought to be revised. For instance, suppose that airline flights change costs and another is cheaper than the one cur- rently planned. Or a previously preferred flight that was canceled is rescheduled. Optimality also depends upon goal validity, which in turn may also depend upon events. If enrollment is ‘This is easily h s own in the formal CDP theory given in PI* Petrie 395 less than expected, a goal of providing six logic courses may no longer be valid. The decision to provide a sixth course may no longer be optimal, though it is still valid. If a friend will be away on vacation while we are traveling, we do not need to include visiting his city in our plans. Backtracking and Replanning Catastrophes and opportunities can also result from backtracking. Whether a decision is invalidated by an external event or rejected as a part of constraint sat- isfaction, the invalidation of a dependent assignment may mean that one or more goals is no longer reduced or satisfied - a catastrophe. The invalidation of a sub- goal because of the rejection of the parent decision may mean the loss of optimality for subsequent decisions, which are opportunities to improve the plan, perhaps by simple elimination of some assignments. An important subcase of an opportunity caused by backtracking is when the best decision, say A,, for goal a is rejected because it conflicts with some second de- cision Ib for some other goal b. Then the next decision made, say Yea, is optimal only with respect to the re- jection of A,. But if I’b, originally in conflict with A,, is itself later rejected, then the current decision, Tcs, has lost its rationale for optimality and represents an opportunity. The important point is that backtracking and re- planning require the same change management ser- vices. The change must be propagated to the depen- dent assignments and subgoals, and the catastrophes and opportunities detected. Thus both backtracking and replanning are special cases of general decision re- vision. Incremental Revision CDPs requires replanning to be done incrementally. First, replanning and planning must be interleaved for problems in which execution begins before the plan is complete. This alone requires that replanning proceed in the same incremental fashion as does depth-first, heuristic guided search that is appropriate for CDPs. It is also the case that the notion of replanning from scratch does not capture the constraints over the plan- ning work itself. It is easy to construct integer pro- gramming task/resource assignment examples in which the unexpected unavailability of a resource would cause all assignments to be changed in order to satisfy the global objective function. But this ignores planning work. Typically, there are constraints over how much change is acceptable in a plan. A department chairman will not want to rearrange every professor’s schedule if it is not necessary to do so. A less than optimal solu- tion that adequately responds to the catastrophe may be the best solution if it minimally perturbs the plan. This consideration is especially important for multi- ple objectives with local optimalities. While it is im- portant to know about opportunities to improve the satisfaction of some objective without making that of another worse, it is not always best to revise the plan to take advantage of them. A complex design should not be massively changed because of a small improve- ment made possible by the use of a newly available component. Computational Support The CDP model describes how a system should react to change. Some response is syntactically determined by the nature of the dependencies. Other change re- quires semantic reasoning: the syntactic task is only to provide information for the reasoning and respond to the conclusion. The reasoning may be performed by the user or heuristic rules. Backtracking and replan- ning differ in the source of the change and the initial response. In CDP replanning, contingencies cause invalidation of admissibility conditions for decisions, making the decisions invalid. Abstractly, a contingency is a hard, unary constraint: there is no choice about how to re- spond. If the flight is canceled, the system can syntac- tically determine that the decision to use that flight must be invalidated. The computational support is in- dexing of decisions by admissibility conditions. Rejection in backtracking to resolve constraint vio- lations also invalidates decisions. General constraint satisfaction generally requires reasoning about which decisions to retract. If we can’t afford to go to both cities, we must decide which to cut. So in backtracking, the initial syntactic task is only to present the relevant alternatives. Retraction is controlled by the user or rules. The primary computational support is indexing assignments by their supporting decisions and relevant goals. Once a decision has been invalidated, whether be- cause of backtracking or replanning, the syntactic task is the same: propagation of the invalidation and detec- tion of catastrophes and opportunities. The computa- tional support for decision invalidation in both cases is indexing decision, decision rationale, and goal validity by supporting decisions. In particular, for catastrophes, the computational support required is to identify the assignments and the transitive closure of goals no longer reduced or satisfied because of the invalidity of affected decisions. Associ- ated assignments and goals must lose their validity. For opportunities, the task is to identify which decision ra- tionales, or goal validities, are invalidated. Although this information should be conveyed to the user, the plan should not be automatically revised, as discussed in the previous section. Detecting opportunities is the particularly difficult and important search task of context maintenance. Surprisingly, it turns out to be equivalent to track- ing the pareto optimaZity[3] of a solution for multiple objectives. No part of a pareto optimal solution can be improved without making some other part worse. 396 Planning 01 02 03 04 05 06 07 Figure 4: Pareto Optimality As illustrated in Figure 4, if the satisfaction of objec- tive 03 can only be obtained at the expense of the satisfaction of some other, say 04, and a similar sit- uation exists for all other parts of the solution, then it is pareto optimal. On the other hand, if we could improve the satisfaction of 03 while not affecting that of any other objective, then the solution is not pareto optimal and we have detected an opportunity. This special case, discussed above, of an opportu- nity caused by backtracking turns out to correspond to and provide semantics for a known computational technique: generating contradiction resolution justifi- cations in a truth maintenance system (TMS)[G, $1. Dependencies In [9], we give a formal theory of CDP solving. The entailments in that theory make precise the ontology and dependencies discussed above. The theory pro- vides semantics for the dependencies in a computa- tional architecture, REDUX, for revising plan states. REDWX uses a TMS to represent the dependencies that correspond to the entailments that represent the CDP model. Rather than use entailments, we use the TMS notation to describe partially the CDP dependen- cies. These dependencies are also the implementation encoding. In passing, we note that truth maintenance is a natu- ral candidate for a mechanism to propagate the effects of change in a design or plan, given some reasonable tradeoffs between completeness and tractability. But truth maintenance has not been used extensively for design and planning, despite many proposals for doing so. We claim that the problem is a lack of semantics for dependencies and that the CDP model provides these VI* Figures 5 and 6 show templates for most of the de- Assigned op ,V&agoal h edision op vals goal dmissible-op op vals goal 9 e&ion op vals goal Figure 5: Decision Validity Justification pendencies generated each time a decision is made in a plan. In this graph, each node may have one or more justifications denoted by a directed line. The arrow points to the node being justified. The open cir- cle connects with solid and dotted lines to supporting nodes. If the solid line supporting nodes are valid (IN in TMS language) and none of the dotted line sup- porting nodes are (i.e., OUT), then the justification is valid and so is the node being supported. For a node to be valid, it must have at least one valid justification. A node such as Retracted-Decision initially has no justification and so cannot be valid. Determining these validities for such a graph is the TMS labeling task [2]. It should be emphasized that most of these nodes may have more than one justification and the job of the TMS is to correctly label the graph, thus propagating change. When a decision is made, the rationale for choos- ing the operator instance determines the justification for Best-Op. This is done in REDUX by converting into a TMS justification a backward chaining proof of the optimality of choosing the operator instance. Horn clause rules are used that have an unless metapred- icate encoding negation as failure. When coverted to TMS justifications, these Unless clauses become ele- ments of the OUT-lists and are typically used to encode assumptions as described by Doyle[2]. Similarly, the Admissible-op node will have a jus- tification based on a proof of the validity of the ad- missibility conditions for the operator instance. As- sumptions here are also encoded via Unless clauses converted to OUT-lists. The Valid-goal node for the Petrie 397 Best- op vals cs-set f Decision op vals goal Rejected-Decision op vals goal Admissible-op op vals goal Figure 6: Decision Optimality Justification parent goal will already have a valid justification; oth- erwise, making this decision would not be on the task agenda. The validity of each new subgoal depends upon the validity of the parent goal and the decision, as indicated in the justification for the node Valid- goal. The node Optimality-loss is initially invalid. If it becomes valid, for instance if the decision rationale loses its validity, this signals a possible opportunity. The Decision nodes are always encoded as assump- tions because of the Retract&d-Decision nodes in the OUT-list of their justifications. These retrac- tion nodes may have a premise[2] justification provided or removed as a metadecision by the problem solver. This in turn depends upon the validity of Rejected- Decision nodes. The justifications for rejection nodes are created in dependency-directed backtracking and correspond to the conditional proof justifications of Doyle[2], and the elective justifications we described in [6]. The CDP model provides these with seman- tics (tracking pareto optimal&y) for the first time, as described previously in [8] and in more detail in [9]. Control We will use the REDUX implementation to describe informally control of CDP solving. There is an agenda with four possible kinds of tasks: satisfying a goal, re- solving a constraint violation, responding to an oppor- tunity, and resolving a case in which no operator may be applied to some goal. Control over the agenda is de- termined by heuristic rules using a Choose-tusk predi- cate. Partial orderings over operator instances are de- termined by a Prefer-operator predicate. There is an explicit rejection predicate, Prefer-rejection, for con- trolling backtracking. Constraint propagation is con- trolled by Propagate-operator when desired. By providing a Prefer-god predicate, together with some default heuristics, we find that Choose-tusk and Prefer-rejection are rarely used. For example, one de- fault heuristic is: reject first the decision that reduces the lesser preferred goal. Another is: given a choice be- tween the tasks of satisfying two goals, choose the the preferred goal first. (This turns out to implement the variable choice technique in constraint satisfaction.) And in REDUX, subgoals inherit preference from su- pergoals. All of these preferences are encoded as Horn clause rules in REDUX. REDUX contains other useful default heuristics. For instance, it is generally useful to first resolve a con- straint violation before attempting to satisfy any sub- goals resulting from the decisions involved in the vio- lation. Since one or more of them may be retracted,3 it is wise to avoid working to satisfy goals that may become invalid when the decisions are revoked. An- other example is that it is generally better to attempt all ways of consistently satisfying a subgoal than to retract immediately the decision creating the subgoal. By incorporating such heuristics, problem representa- tion is simplified in most cases. Application The claim of the value of the CDP model illustrated in Figures 2 and 3 is the same as for any other representa- tion and problem solving method: it simplifies formu- lating and solving a large and useful class of problems: those with the kinds of backtracking and replanning functionality indicated by the travel example. Plan- ning problems with general constraints, multiple objec- tives, and contingencies should be easier to formulate and solve with a CDP model-based architecture than by using other formalisms or ad hoc expert systems. Testing this thesis requires building applications in a CDP-based architecture such as REDUX. Extended versions of the travel example have been constructed. In [9], we describe two larger applications. One is a telephone network multiplexor configuration application previously done with a commercial expert 3 One option is to suspend constraint violation resolution and to have an inconsistent plan with known problems. 398 Planning system. This application has no contingencies but re- quired over 200 Lisp functions for control in addition to many other utilities and shell object definitions. The REDUX implementation provided equivalent control with five (5) operators and fewer than ten rules, as- sertions, and constraints. We claim that the REDUX implementation was clearer and made it easier to try different search strategies. As an example, we include here the three (3) main REDUX operators; REFINE, FINISH, and COMPONENT-CHOICE, together with a preference between the operators REFINE and FINISH that en- codes component decomposition, using the domain predicates defined by the earlier implementation: REFINE: instance: operator variables: (?artifact) applicable-goal: (Design ?artif act) from Required( ?art if act ?bp ?part > new-assignment: (Part-of ?artifact ?part) > from Required( ?art if act ?bp ?part ) new-goal: (Design ?part)> from Requiredc ?art if act ?bp ?part ) new-goal: (Select-BP ?artifact ?bp)) from New-component( ?artifact ?bp) FINISH: instance: operator variables : (?artif act) applicable-goal: (Design ?artifact) new-assignment: (terminal-part ?artifact)) prefer-operator( REFINE (?artifact) FINISH (?artifact)) COMPONENT-CHOICE: instance: operator variables: (?artif act ?bp ?part) applicable-goal: (Select-BP ?artifact ?bp) from Required-Choice( ?artifact ?bp ?part) new-assignment: (Part-of ?artifact ?part)) new-goal: (Design ?part>) The component decomposition computation starts with the assertion of a goal with the consequent De- sign < component >. The applicable-goal attribute of the operators REFINE and FINISH will both unify with such a goal. (The ? denotes a unification variable in the language syntax, distinct from a plan variable.) Because of the preference, REFINE will always be tried first. However, there is a condition on applicability, in- dicated by the from keyword. That the component is decomposable is indicated by proof or assertion of the clause using the Required predicate. If this is not, the case, then REFINE is not applicable, and FINISH will be used, constructing a leaf node on the decomposition. If REFINE is used, it uses the Part-of predicate to assign the subcomponent (bound to ?part) and cre- ates two new goals. One is always a recursive genera- tion of the goal Design with a subcomponent subcom- ponent. However, another domain predicate. New- component indicates a choice between possible sub- components. This subgoal, Select-BP, is reduced by the COMPONENT-CHOICE operator. There will be several instances of this operator generated by the from condition on the applicable-goal clause: differ- ent choices will bind to the variable ?purt Not shown are particular preferences among choices that are ex- pressed using it Prefer-operator. COMPONENT- CHOICE recurses to the Design goal. Also not shown is the preference (using Prefer-goal) for the Select- BP goal over the Design goal and other preferences expressing such domain cont8rol strategies. The second application was professor and course as- signment, emphasizing revision as contingencies oc- curred during an academic year. The inadequacy of integer programming was described in [I]. The corre- sponding expert system, based on a research shell with a TMS, had about 60 control rules and was extremely difficult to build and manage.4 The corresponding RE- DUX implementation had five (5) operators and four (4) control preferences. Again, the control strategy was clear and easy to experiment with the REDUX implementation. We also found that explanations say- ing why some operator instance was chosen to reduce a goal from a conflict set, of such instances facilitated debugging. The admissibility conditions of operators were more useful in this application. In a simplified syntax, as- sumptions are indicated with the keyword contingency. Thus, an operator that assigned a teacher to a course in semester would have the condition: contingency: Unavailable-teacher(?teacher ?sem). This would translate into a clause in the OUT-list of the justifica- tion supporting an Admissible-op node. Finally, the use of a TMS deserves mention. While it is not necessary for implementing the CDP model, a TMS does provide a convenient and efficient utility for a CDP architecture. We have not done an efficiency analysis, but as long as the decisions are not too glob- ally interdependent, TMS justification caching and la- bel updating seems to take less computation than the backward chaining proofs with the shell we used. And the CDP approach described above avoids the usual burdens imposed on developers using a TMS. Unlike the standard problem solver/TMS model, these depen- dencies are generated automatically and have seman- tics. The us& need not think about them, nor about the TMS at all; only about the CDP model of problem solving. For none of the three applications would the use of a classical planner have been appropriate. Nor was *Many more utility rules, assertions, and frames were required for the application, but were not counted because similar constructs were needed for the REDUX application as well. However, these utilities had nothing to do with revision and control. Pet rie 399 integer programming or simple constraint satisfaction a good alternative. Expert systems approaches were difficult and cumbersome. We conclude that the CDP model, and the REDUX architecture, facilitates the construction of at least modest CDPs and that there is suggestive evidence to warrant further development and study of larger problems. The CDP model also provides a foundation for the comparison of specialized formalisms, such as HNP and integer programming. References [l] Dhar V. and Raganathan N., “An Experiment in Integer Programming,” Communications of the ACM, March 1990. Also MCC TR ACT-AI-022-89 Revised. [2] Doyle J., “A Truth Maintenance Sys- tem,” Artificial Intelligence, 12, No. 3, pp. 231-272, 1979. [3] Feldman, Allan M., Welfare Eco- nomics and Social Choice Theory, Kluwer, Boston, 1980. [4] Kambhampati, S., “Flexible Reuse and Modification in Hierarchical Plan- ning: A Validation Structure Based Approach,” University of Maryland, CS-TR-2334, October, 1989. [5] Morris, P. H., Nado, R. A., “Repre- senting Actions with an Assumption- Based Truth Maintenance System,” Proc. Fifth National Conference on Artificial Intelligence, AAAI, pp. 13- 17, 1986. [S] Petrie, C., “Revised Dependency- Directed Backtracking for Default Reasoning,” Proc. AAAI-87, pp. 167- 172, 1987. Also MCC TR AI-002-87. [7] Petrie, C., “Reason Maintenance in Expert Systems,” Kuenstliche Intel- ligence, June, 1989. Also, MCC TR ACA-AI-021-89. [8] Petrie, C., “Context Maintenance,” Proc. AAAI-91, pp. 288-295, July, 1991. Also MCC TR ACT-RA-364-90. [9] Petrie, C., “Planning and Replanning with Reason Maintenance,” U. Texas at Austin, CS Dept. Ph.D. disserta- tion. Also MCC TR EID-385-91. [lo] Sacerdoti, E., “Planning in a Hierar- chy of Abstraction Spaces,” IJCAI-73, Palo Alto, CA, 1973 [ABSTRIPS] [ll] Sacerdoti, E., “The Non-linear Nature of Plans,” IJCAI-75, Tbilisi, USSSR, 1975. [NOAH] [12] Tate, A., “Project Planning Using a Hierarchical Non-linear Planner,” Dept. of AI Report 25, Edinburgh University, 1977. [NONLIN] 400 Planning | 1992 | 70 |
1,266 | Artificial Intelligence Laboratory Department of Electrical Engineering and Computer Science The University of Michigan, Ann Arbor, MI 48109-2122 nbge@caen.engin.umich.edu & irani@caen.engin.umich.edu Abstract This paper presents a methodology which enables the derivation of goal ordering rules from the anal- ysis of problem failures. We examine all the plan- ning actions that lead to failures. If there are re- strictions imposed by a problem state on taking possible actions, the restrictions manifest them- selves in the form of a restricted set of possible bindings. Our method makes use of this obser- vation to derive general control rules which are guaranteed to be correct. The overhead involved in learning is low because our method examines only the goal stacks retrieved from the leaf nodes of a failure search tree rather than the whole tree. Empirical tests show that the rules derived by our system PAL, after sufficient training, performs as well as or better than those derived by systems such as PRODIGY/EBL and STATIC. Introduction When a problem solver is given a problem with a conjunctive goal condition, perhaps the most diffi- cult task to perform is the ordering of the individ- ual component goals to avoid harmful goal interac- tions. Efforts have been made in the past to cope with this problem either by learnin Minton 19881 or through reasoning ‘i [Sussman 1975; 1989; Etzioni 19911. Cheng and Irani The learning approach taken by Minton’s PRODIGY [Minton 19881 shows com- prehensive coverage on learning from various prob- lem solving phenomena by using EBL (Explanation- Based Learning). The goal ordering rules learned through PRODIGY/EBL, however, are often overly specific and unnecessarily verbose. The reasoning ap- proaches taken by Cheng’s system [Cheng and Irani 19891 and Etzioni’s STATIC [Etzioni 19911 derive very general goal ordering rules by analyzing domain oper- ators. STATIC’s problem space compilation method derives various types of search control rules in addi- tion to goal ordering rules. However, since both these methods are not based on analysis of problem-solving traces, certain constraints specifically imposed by dy- namic attributes’ of a problem state cannot be de- tected. Moreover, the above systems require a priori domain-specific knowledge. PRODIGY/EBL uses such knowledge in its compression phase which is critical for enhancing the utility of the learned rules. STATIC and Cheng’s system rely on such knowledge to reason about the effects of the operators. Whenever a new problem domain is given, it is not trivial to determine a priori what type of knowledge is needed and in which particular form. In this paper, we present a new learning method which can derive goal ordering rules from the anal- ysis of problem failures without relying on any ex- plicit a priori knowledge beyond that given in the problem description. The condition of a rule derived by this method involves dynamic as well as static attributes2 of a problem state. These conditions are guaranteed to be correct and much more general than those of PRODIGY/EBL, although slightly less gen- eral than those of Cheng and of STATIC. A plan- ning and learning system called PAL has been im- plemented and tested on PRODIGY’s test domains of Blocksworld, Stripsworld, and Schedworld (machine scheduling). The rules derived by PAL performed as well as, and in some cases better than, those of the other systems, while the overhead of learning in PAL is shown to be the lowest. In the following, we first review the goal interac- tion problem and discuss the limitations of previous approaches. Then, we give an overview of the PAL’s planner and describe PAL’s learner and how it learns from failure analysis. Next come the experimental re- sults which compare PAL with PRODIGY/EBL and STATIC. Other related works are then briefly dis- cussed before concluding remarks. Goal interaction refers to the phenomena where the actions for achieving the individual component goals ‘The attributes that can change by operator application such as the locations of movable objects. 2The attributes which are not dynamic such as a room configuration or unchangeable properties of objects. Ryu and Irani 401 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. interfere with one another. Harmful interactions are avoided if the goals are attacked in a right order. Goal ordering rules prescribe the condition under which a certain ordering should be followed. Conditions de- rived by previous approaches have limitations as illus- trated by the following example. In Stripsworld, condition for goal ordering is some- times represented by a complicated relational concept. When the goals are (status dx closed) and (inroom ROB m), for example, ROB(robot) must get into ~21 before closing dx if dx is the only doorway to rx. On the other hand, if dx is a door not connected to rx, ROB should get into rx after closing dx. The control rule learned from the first case should contain in its antecedent the following condition in addition to the goals: Vd (connects d rx ra) + d = dx. Similarly, the rule learned from the second case should have the following condition: Vr (connects dx r rb) ---t r # rx. The current implementation of STATIC fails to derive these conditions and constructs the over-general rule that prefers (inroom ROB rx) to (status dx closed) re- gardless of the relative location of dx. Over-general rules can mislead a planner into generating inefficient plans by expanding extraneous nodes. Cheng’s system derives the right conditions with the help of domain- specific knowledge. STATIC may similarly need ad- ditional domain-specific knowledge to derive the right conditions. When the correct condition for goal or- dering involves dynamic attributes of a problem state, these two systems fail because they do not examine problem states or search traces. PRODIGY derives over-specific conditions which overly restrict the ap- plicability of its rules while demanding high matching cost. PAL is able to derive correct conditions through analysis and generalization of the goal stacks retrieved from a failure search tree. PAL’s Planner PAL’s planner employs means-ends analysis [Newell, Shaw, and Simon 19601 as its basic search strategy. Given a problem with a conjunctive goal condition, PAL processes the component goals from the goal stack in the order presented or as recommended by learned rules. When a goal is true in a state, the goal is re- moved from the goal stack. Otherwise, for each instan- tiation of each of the goal’s relevant operators, a new copy of the goal stack is created. The instantiated op- erator and its preconditions are posted on a new copy of the goal stack. These preconditions become subgoals and are treated in the same way as the top level goals. An operator in a goal stack is applied when all its pre- conditions are satisfied. If an operator is applied, it is deleted from the goal stack together with the goal or subgoal that it achieves. This process recurs until an pushthrudr (?b ?d ?rx) (sp) (pushable ?b) (connects ?d ?ry ?rx) (bp) (dp) (status ?d open) (inroom ?b ?ry) (nextto ?b ?d) (nextto ROB ?b) (inroom ROB ?ry) (dl) (nextto ROB ?$) (nextto ?b ?$) (nextto ?$ ?b)( inroom ROB ?$> (inroom ?b ?$) (ma) (inroom ?b ?rx) (sa) (inroom ROB ?rx) (nextto ROB ?b) Figure 1: An operator used in PAL. empty goal stack is found (success) or a dead-end is reached (failure). Operator Representation and Control Heurist its In PAL’s planning model, the literals used in plan rep- resentation are separated into two categories, static and dynamic. The static literals in a state description can never be changed throughout legal state transitions dictated by operator applications. Dynamic literals are those that can be deleted and/or added by operators. Figure 1 illustrates the six-slot operator represen- tation used in PAL. Most of the default search con- trol heuristics are incorporated into this representation scheme. The first three slots are for the preconditions, the dl slot is for the delete list, and the ma and sa slots are for the elements of add list exhibiting major effect and side effect of the operator, respectively. The static literals of the preconditions are separately kept in the sp slot. When a static precondition of an operator is unsatisfied, the operator is immediately abandoned because it is not applicable. The preconditions in bp slot, although dynamic, play the same role as static preconditions to heuristically restrict the selection of bindings. Only the dynamic preconditions in dp slot can become subgoals when they are unsatisfied. A sim- ilar scheme is adopted in [Dawson and Siklbssy 19771. The ma, sa separation of add list implements operator selection heuristics. An operator is considered rele- vant to a goal only when it has a literal in its ma slot which unifies with the goal. This easily implements the kinds of heuristics that prevent object-moving opera- tors from being used to move the robot, as can be seen in the pushthrudr operator. Although we claim not to be using a priori domain knowledge explicitly, we may be using it implicitly in the operator descriptions. Strategy for Handling Goal Interactions PAL encounters harmful goal interactions in two dif- ferent forms, namely, protection violation and prereq- uisite violation. A protection violation is detected when an application of an operator deletes a previ- ously achieved goal. For PAL, a protection violation is a failure and therefore it backtracks. A prerequisite 402 Planning violation is detected when a precondition of an oper- ator is found deleted by another operator applied for a previous goal. A prerequisite violation, however, is considered a failure only when the violated precondi- tion is impossible to be re-achieved. Such irrecoverable prerequisite violations are frequently observed in the Schedworld domain. If violations are unavoidable with a given ordering of goals, PAL re-orders the goals. Learning from Goal Interactions PAL learns goal ordering rules if goals attacked in a certain order lead to failures which involve violations. Learning involves derivation of the general condition under which a certain ordering fails. The central idea of our method is to take into account the mechanism of operator instantiation during failure analysis. We can understand how certain harmful interactions are unavoidable in a given situation by examining how all possible ways of taking actions lead to dead ends. If there are restrictions imposed by the problem state on taking possible actions, then t,he restrictions man- ifest themselves in the form of a restricted set, of pos- sible bindings of operators. Our method makes use of these observations to derive general control rules with- out relying on any a priori domain-specific knowledge. Due to space limitation, we describe our method for the ca,se of learning from two-goal problems, although the method can be extended to TX-goal problems [Ryu 19921. Mechanism of Operator Instantiation When an operator relevant, to a goal is instantiated, an initial binding is first, generated by matching the goal with an add literal. This binding is later completed by matching preconditions with the current state descrip- tion. A dynamic precondition under a certain binding becomes a subgoal if it, is not satisfied by the state un- der that binding. Given a dynamic precondition p of an operator op, a set D of preconditions other than p is called a determinant for p with respect to an add literal a of op if all the variables appearing in p ex- cept those in c1 appear in D. For example, the set) of two literals in the sp slot of the pwshthrudr operator in Figure 1 is a determinant, for any precondition in the dp slot with respect, to the add literal in ma3 PAL assumes that, for any operator op, its sp together with the bp slot constitute a determinant for any dynamic precondition in the (11) slot of op with respect to any add literal in its mu slot.4 Goal Stack Analysis The reason why all attempts to achieve a subgoal lead to failures is well recorded in the goal stacks of the fail- 3PAL’s determinants are siulilar to PRODIGY’s binding generators. 4Under a certain conrlition, this assumption can be re- laxed without compromising the correctness of the learned rule conditions. Details are explained in [Ryu 19921. Rl R2 R3 R4 RS R6 Figure 2: A state in the robot navigation domain. (inroomB1 R2) (inroom Bl R2) (inroom Bl R2) , pushthrudr(B1 D23 R2) / / pushthrudr(B1 D12 R2) / / pushthrudr(B1 D25 R2) cycle cycle protection violation base section first section second section deletes g 1 Figure 3: Some failure goal st,acks. ure search tree. Consider a simple problem with the initial state of Figure 2 and the goals 91 = (stutus 025 closed) and gz = (inroo~~ BI RL). If 91 is achieved first, every attempt4 to achieve 92 either leads to a goal stack cycle (failure by goal repetition) or violation of gl because DZ5 is the only pat,hway for R1 to be moved into 83. PAL extracts and generalizes t)his configura.- tional constraint, and the relative loca.tion of the box B1 by investigating the failure goal stacks. Figure 3 shows some of the goal stacks retrieved from the failure search tree obtained during the attempt to achieve g2 after achieving 91. Each goal stack is di- vided int,o sections for easy reference. The section con- taining the top level goal is called the base section. The remaining part is uniformly divided iuto sections each of which consists of an operator and its unsatis- fied preconditions. They are called the first section, secontl secfjon., and so on as indicated in the figure. The subgoal at, the top of each section (note the goal stacks are shown upside down) is said to be uctive. Sometimes a section of a failure goal stack contains an active subgoa.1 which cannot be achieved because the binding is not, correct. Such an active subgoal, if achieved in other search branch under a right binding, is said to be uchievuble. Each of the active subgoals in the goal stacks of Figure 3 is not achieved in any search branch. This type of active subgoals are called unuchiewuble. The unachieva.ble active subgoals con- stitute the real rea.son for failure. A failure goal stack whose active subgoals are all unachievable is said to Ryu and Irani 403 be an instance of an unavoidable failure. Only from the goal stacks of all the unavoidable failures, can we construct an explanation of how all the alternative at- tempts to achieve a goal lead to failures. In our exam- ple, only the three goal stacks shown in the figure are used for learning. Let K be a set of all the unavoidable failure goal stacks from the failure search tree obtained during the attempt to achieve the second goal after achieving the first goal. Let efi denote the j-th section of a goal stack Ici E K. Two sections of different goal stacks are identical if the operators and the ordered preconditions in the two sections are exactly the same. The following two lemmas are helpful in further processing the goal stacks. Lemma 1 Let ki and kh be twp different goal stacks in K. If the active subgoals of e: and ek are identical for some j, m 2 1, then j = m and ei = ek for all l<n<j. The lemma should be intuitively obvious because the goal stacks ki and kh are expanded copies of the sa.me goal stack (see Section PAL’s Planner). Lemma 2 Let p be an active subgoal of the j-th sec- tion which is not the top section of a goal stack in K. Then, each of all the instantiated re1evan.t operators considered for p during search appears in the (j + I)-th section of a goal stack in K. The goal stacks in K show all the unsuccessful at,- tempts to achieve goals from the top level to the lowest level until failures are explicitly detected. Based on the fact that the goal stacks of alternative attempts share identical portions from the base up to the sections of different attempts (Lemma l), PAL re-arranges these stacks into a tree structure. We can view each goal stack as a chain of sections with each of the sections connected by edges, starting from the base to the top section. The base section, shared by all the goal stacks, becomes the root of a tree to be constructed. Then, starting from the first section for each level, any iden- tical sections seen at a level are merged into a single node, with the sections at the next level becoming chil- dren of the merged node. Figure 4 (a) shows the tree (called C-tree) derived from our failure goal stacks. Each node in the tree cor- responds to a section of a goal stack. However, in each node of the tree, the operators are replaced by their determinants (sp and bp slots) and the preconditions other than the active ones are simply removed. The determinant in a node can be considered a condition under which the node’s subgoal emerges given the goal of its parent node. The leaf node of protection vio- lation does not contain any determinant because the deletion causing the violation is solely determined by the initial binding. This node does not contain a sub- goal either. Instead, it contains the literal which is deleted. nects D23 R3 R2) nnects Dl2 Rl R2) nnects D25 R5 R2) goal stack cycle goal syz! cycle protection violation Icgz (inmom bxrx) I Figure 4: The C-tree and F-tree of our example. Generaliaat ion PAL generalizes the C-tree by substituting constants with variable symbols startink from the root in a top- down manner. -The constants resulting from instanti- ation of operator variables are denoted by upper case letters. Only these constants are generalized to vari- ables. Varia.bles are denoted by lower case letters. The generalization process can be viewed as the reverse of the operator instantiation. First, the goal at the root is variabilized and the constant/variable substitu- tion used is passed down and applied to the children nodes. This is the reverse of the initial binding gen- erated when the relevant operators for the goal are instantiated. The already achieved goal (gr) is also variabilized and kept separately. Next, the determi- nants of sibling nodes under the root are generalized to look identical if they are just different instantiations of the same determinant of an operator. Once a determi- nant of a node is generalized, the subgoal in the same node can be accordingly generalized by applying the constant/variable substitution used in variabilizing the determinant. After all the nodes at the same level are generalized, the nodes are split into parent and child with the determinant as a parent and the subgoal as a child. Negation symbols are attached in front of the generalized subgoals to reflect the fact that they are not satisfied. All the determinants generalized to look identical are then merged into a single node moving their children (subgoals) under the merged node. Any 404 Planning identical subgoal nodes are also merged at this time and different children are put under an OR branch to indicate the fact that different subgoals can be cre- ated from a single operator depending on the bindings. Then, only the substitutions used for variabilizing the subgoals are passed down and applied to the nodes at the next level and the same process is repeated. The children of a subgoal node are always put under an AND branch because all the relevant operators for the subgoal should lead to failures. When a leaf node is generalized, the repeated subgoals (cycle failure) and violated goals are replaced by the respective conditions for failure. Such failure conditions are easily derived by examining the repeated subgoal and the delete/add lists of the operator involved in the violation. As a final step, PAL removes redundant literals from the resulting tree. A literal in a determinant node is redundant if it, already appears in one of its ancestor nodes. A literal yp in a subgoal node is redundant if p is deleted by every operator which achieves 91. The reason is that our tree is intended to represent the con- dition on the state after gl is achieved. In our example, -(status da open) is redundant, under the condition da - dx because the operator achieving the violated goal (status dx closed) d e e 1 t es it. The tree after generaliza- tion, called an F-tree, is shown in Figure 4 (b). The pg and cg in the root represent the previously achieved goal (gl) and the current goal (gs), respectively. An F-tree is comparable to a failure subgraph of STATIC’s problem space graph (PSG) where goal/subgoal relationships are represented by connect- ing the goals and preconditions of operators with their relevant operators successively [Etzioni 19901. Mow- ever, the difference is that an F-tree summarizes con- sequences of different sets of bindings of each single operator observed in a failure example, while it is not feasible for STATIC to consider the implications of all possible bindings of operators in PSG without guid- ance from examples. The F-tree of Figure 4 (b) spec- ifies the relative location of the target object b3: (dy- namic attribute) as one of the reasons for the observed violation failure. Ordering constraints depending on the dynamic attributes of a problem state are difficult to be detected by problem space analysis as exhibited by STATIC and Cheng’s system. When an F-tree is matched against a new problem, an initial binding is first generated by matching the two goals in the root, with the problem goals. This ini- tial binding is then passed down to children nodes for further matching. When a node is matched, the partial bindings passed from its parent are used and extended by matching new variables in the node. When a set of partial bindings generated in a node is passed down through AND branches, all the partial bindings must be successfully completed in every subtree under the branches. If it is passed through OR branches, each partial binding must be completed in at least one sub- tree under the branches. Otherwise, the matching is (and (current-node 1121 (candidate-goal n2 (status dx closed)) (candidate-goal n2 (inroom bx rx)) (known n2 (pushable bx)) (for-all (da ra) such-that (known n2 (connects da ra rx)) (or (is-equal da dx) (and (known n2 (not (iuroom bx ra) > > (for-all (rb) such-that (lmouu n2 (connects db rb ra>> (is-equalrb rx)))))) Figure 5: The rule condition represented by the F-tree of our example. considered to have failed. The interpretation of the F-tree of Figure 4 (b) is given in Figure 5 in the self- explanatory PRODIGY’s rule format.. The following theorem states that if an F-tree matches the state after achieving the first goal of a problem, then all the attempts to achieve the next goal will confront the same type of failures summarized in the F-tree. Theorem 1 Consider a problem with two ordered goals ga and gb. If the state after achieving g, matches an F-tree, then gb cannot be achieved from that state provided that the given operators are coherent.5 For an F-tree to be more useful, it should be possible to use it even before the first goal is achieved. For this, an F-tree has to be isolated as explained in the following. Given a goal g, a subset A of given operators is called the goal achievement closure (GA c) of g, if (1) all the operators that can achieve g are in A, (2) all the operators that can achieve any precondition of an operator in A are also in A, and (3) A is the minimal such set. An F-tree with the two goals pg and cg is said to be isolated from pg if none of the generalized subgoals in the tree can possibly be achieved by any operator in the GA C of pg. Theorem 2 Consider a problem with the ordered pair of goals ga and gb. Suppose an F-tree F with the two goals pg and cg match the initial state of the problem, and the two goals pg and cg match the goals ga and gb, respectively. If F is isolated from its pg, then F matches the state after achieving ga. Intuitively, the operators applied for ga are those in the GAC of pg which matches ga, and thus none of them can achieve the subgoals in the F-tree. Then, by Theorem 1, gb cannot be achieved from the state reached by achieving go. If an isolated F-tree matches a problem, we want to change the goal ordering assuming that the conditions of Theorem 1 and Theorem 2 are met. Only the isolated F-trees are qualified as rules. 5All the operators of our test domains are coherent. The definition of coherency is omitted for space limitation. De- tails are explained in [Ryu 19921. Ryu and Irani 405 EBL STATIC PAL Blocks 762/19=40 9.9/18=0.55 4.3/10=0.43 Strips 1057/30=35 40.5/35=1.16 8.7/14=0.62 Sched 1374/37=37 19.4/46=0.42 4.9/20=0.25 Table 1: Learning overhead in cpu seconds divided by the number of control rules derived. Table 2: Numer of goal ordering rules derived. Comparison to PRODIGY/EBL and STATIC PAL was trained and tested on PRODIGY’s test domains.6 The training and test problem sets are based on those used in [Etzioni 19901. Since the pur- pose of Minton’s and Etzioni’s experiments was to test the effectiveness of various types of control rules, their problem set contains many single-goal problems which do not serve our purpose. From both the train- ing and test sets, single-goal problems are replaced by multiple-goal problems to better see the effects of learning and using goal ordering rules. Table 1 shows that PAL spent the shortest average learning time.7 PRODIGY/EBL’s learning time includes the cost of utility evaluation. PAL’s learning time includes the overhead of deriving non-isolated F-trees which are abandoned. Since STATIC and PRODIGY/EBL de- rive rules for other types of search control as well as goal ordering, the above comparison is not really fair. Wowever, we believe that learning goal ordering rules is a more complicated task than learning other types of control rules. Table 2 shows the number of derived goal ordering rules. We used PRODIGY’s planner as a testbed. For ef- ficiency of the planner in other aspects of search such as selection and rejection of operators or bindings, we had the planner equipped with STATIC’s control rules excluding the goal ordering rules. We empirically ob- served that STATIC’s rules were in general more effec- tive than PRODIGY/EBL’s. The effectiveness of the goal ordering rules derived by each system is then mea- sured by successively loading and testing each set of 6Cheng’s system [Cheng 19911 is excluded from this comparison because its variabihzation method for the de- rived goal ordering constraints is not implemented. In a separate experiment, PAL’s learning outperformed Cheng’s pre-processing [Ryu 19921. 7Since PAL was run on a different machine (Sun Sparc- station), we re-scaled our original data (3.1, 6.2, and 3.5 based on the comparison of the data given in [Etzioni I 1990 with the data obtained by running the same set of sample problems on our machine. Note, however, that data in Ta- ble 3 are original, not re-scaled. ordering rules 1 cpu sets nodes 1 sol. length none 11 1224 I 4587 I 529 (59) I STATIC EBL 1044 590 I 3551 1832 I 499 495 (soj (63) I PAL 11 587 1 1831 1 495 (63j 1 (a) 100 Schedworld problems ordering rules 11 cpu sets nodes 1 sol. length none II 109 I 5929 I 1009 PAL 63 2601 837 b) 100 Blocksworld problems Table 3: Effects of different sets of goal ordering rules. goal ordering rules. Table 3 compares the test results of running the planner (learning module turned off) without and with different sets of goal ordering rules. The planner was observed to run more efficiently with more effective goal ordering rules, and to generate bet- ter (shorter) solutions with less number-of expanded nodes. The Schedworld is distinguished from the other do- mains in that problem solving generates very shallow search trees. STATIC performed well in this domain because the ordering constraints of the domain can be captured by operator analysis due to the shallowness. The solution lengths are for the 59 problems which were solvable within resource limits with each of the rule sets. The numbers in parentheses are the numbers of solved problems. In Blocksworld and Stripsworld, PAL’s rules performed most effectively. STATIC’s rules were not as effective as PAL’s in Blocksworld be- cause the current version of STATIC fails to derive the rule preferring (on y Z) to (on x y), which are goals fre- quently seen in this domain. In Stripsworld, STATIC generated a few over-general rules (four out of sixteen) including those mentioned earlier. The effect of over- general rules, given a set of test problems, can be ei- ther beneficial or harmful depending on the distribu- tion of the problems. In Table 3 (c), STATIC* denotes STATIC rules excluding the over-general rules. Related Work The Steppingstone system [Ruby and Kibler 19911 learns subgoal sequences which are used after fail- ures are observed, while PAL’s rules are used before problem-solving to avoid failures. ALPINE [Knoblock 19901 learns abstraction hierarchies for planning by an- alyzing possible goal interactions. PAL and STATIC learn only from necessary goal interactions. ALPINE 406 Planning is closer to Cheng’s method in that both are prob- lem specific methods. Currently, it cannot generalize an abstraction hierarchy for later use in similar prob- lems. Kambhampati’s validation structure based ap- proach [Kambhampati 19901 deals with generalizing reusable plans in hierarchical planning. Kambham- pati’s other method for generalizing plan [Kambhampati and Kedar artially ordered 1991 P uses the Modal Truth Criterion [Chapman 19871 to analytically gener- alize interaction-free plans. However, the generalized plans of both these approaches are described in terms of operators rather than goals. The goal ordering rules of PAL can be viewed as plans at higher level of ab- straction with broader applicability. Conclusion We have presented a learning algorithm which is both efficient and effective for deriving sufficient conditions for ordering conjunctive goals. We have shown that some complicated relational concepts representing con- ditions for search control can be derived by a relatively simple method using a minimal amount of information collected from a search tree, namely the failure goal stacks. Unlike other systems, PAL does not rely on any explicit a priori domain-specific knowledge which is often difficult to provide. One of the drawbacks of PAL’s approach is that the generality of the rules it de- rives is sometimes limited by the specifics of the train- ing problem instances, while STATIC and Cheng’s sys- tem do not have such dependency. However, PAL can learn rules whose conditions depend on the dynamic at- tributes of a problem state, which is beyond the scope of those two systems. Moreover, PAL does not suf- fer from the problems of conflict or over-generality ob- served with PRODIGY and STATIC. Acknowledgments Authors are grateful to the PRODIGY group at Carnegie Mellon University for providing us with the PRODIGY system. Thanks also go to Steve Minton and Oren Etzioni for providing their data and giving helpful hints for testing their systems. References Chapman, D. 1987. Planning for Conjunctive Goals. Artificial Intelligence 32~337-377. Cheng, J. and Irani, K.B. 1989. Ordering Problem Subgoals. In Proceedings of the Eleventh International Joint Conference on Artificial Intelligence, 931-936. Detroit, Michigan. Cheng, J. 1991. Deriving Subgoal Ordering Con- straints Prior to Problem Solving and Planning. Ph.D. diss., EECS Dept., The University of Michi- gan. Dawson, C. and Siklossy, L. 1977. The Role of Pre- processing in Problem Solving Systems: “An Ounce of Reflection is Worth a Pound of Backtracking.” In Proceedings of the Fifth International Joint Confer- ence on Artificial Intelligence, 465-471. Etzioni, 0.1990. A Structural Theory of Explanation- Based Learning. Ph.D. diss., School of Computer Sci- ence, Carnegie Mellon University. Etzioni, 0. 1991. STATIC: A Problem-Space Com- piler for Prodigy. In Proceedings of the Ninth National Conference on Artificial Intelligence, 533-540. Kambhampati, S. 1990. Mapping and Retrieval Dur- ing Plan Reuse: A Validation Structure Based Ap- proach. In Proceedings of the Eighth National Con- ference on Artificial Intelligence, 170-175. Kambhampati, S. and Kedar, S. 1991. Explanation- Based Generalization of Partially Ordered Plans. In Proceedings of the Ninth National Conference on Ar- tificial Intelligence, 679-685. Knoblock, C. 1990. Learning Abstraction Hierarchies for Problem Solving. In Proceedings of the Eighth Na- tional Conference on Artificial Intelligence, 923-928. Minton, S. 1988. Qualitative Results Concerning the Utility of Explanation-Based Learning. In Proceedings of the National Conference on Artifkiat Intelligence. St. Paul, MN. Minton, S. 1989. Learning Search Control Knowledge: an Explanation-Based Approach. Kluwer Academic Publishers. Newell, A., Shaw, J.C. and Simon, H.A. 1960. Re- port on a General Problem-Solving Program. In Pro- ceedings of International Conference on Information Processing, 256-264. Paris, Prance. Ruby, D. and Kibler, D. 1991. Steppingstone: An Empirical and Analytical Evaluation. In Proceedings of the Ninth National Conference on Artificial Intet- ligence, 527-532. Ryu, K.R. 1992. Learning Search Control Knowledge for Planning with Conjunctive Goals. Ph.D. diss., EECS Dept, The University of Michigan. Sussman, G.J. 1975. A computer model of skill acqui- sition. New York: American Elsevier. Ryu and Irani 407 | 1992 | 71 |
1,267 | Philip E. Agre mt of communicatio y of Califoruia, San La Jolla, California 92093 pagrs@weber.ucsd.edu Abstract We present a novel object-centered formalization of action which allows us to define an interesting class of tasks, called cooking tasks, which can be performed without backtracking. Since backtrack- ing is unnecessary, actions can be selected incre- mentally using a greedy method without having to precompute a plan. Such an approach is ef- ficient and rapidly adjusts to unforeseen circum- stances. Our argument is that cooking tasks are widely encountered in everyday life because of the special properties of a given culture’s artifacts. In other words, culture has structured the world so as to make it easier to live in. We present an im- plementation of these ideas, experimental results, and control experiments using a standard nonlin- ear planner. Introduction A computational theory of action should have two properties: (1) it should explain how agents can achieve goals and maintain background conditions; and (2) it should pl ex ain how agents can choose their ac- tions in real time.l Classical planning (the notion that one acts by constructing plans and then executing them; see Fikes & Nilsson 1971) offered definite ideas about both of these things: (1) a plan-construction algorithm solves a well-defined problem (in the sense of a function from discrete inputs to discrete outputs) and can thus be proven to produce only correct plans; and (2) agents can choose actions in real time once a ‘Support for this research was provided in part by the University Research Initiative under Office of Naval Re- search contract N00014-86-K-0685, and in part by the Advanced Research Projects Agency under Office of Naval Research contract N00014-85-K-0124. This work was also conducted in part at the University of Chicago, where it was supported in part by the Defense Advanced Research Projects Agency, monitored by the Air Force Office of Sci- entific Research under contract F49620-88-C-0058. Agre is supported by a Spencer Fellowship from the National Academy of Education. Ian Horswill MIT Artificial telligence Laboratory 545 Technology Square Cambridge, Massachusetts 02139 ian@ai.mit.edu plan has been constructed and so long as the assump- tions behind this plan continue to correspond to the unfolding reality. Despite all the abuse it has taken (e.g., Agre & Chapman 1991, Suchman 1987), clas- sical planning, unlike the more recent ‘reactive’ and ‘situated’ architectures (see Agre & Chapman 1987, Brooks 1986, Fox & Smith 1984, Georgeff & Lansky 1987, Rosenschein & Maelbling 1986), does provide non-trivial accounts of both of these issues (though see Kaelbling 1988, Lyons & Arbib 1989). And no doubt those accounts will get better with time, as formal in- vestigation of plan-construction algorithms leads to the discovery of tractable or parallelizable special cases of the general ‘planning problem’. In this paper we sketch an alternate account of these two issues of correctness and efficiency. We propose that part of the answer lies in culture, and specifi- cally in the formal properties of a given culture’s reper- toire of artifacts. By modeling the world in terms of classes of objects and examining the formal proper- ties of those classes, we can define a broad category of ordinary tasks in which an agent can always choose an action which will move it closer to its goal with- out constructing a plan. Since the inventory of objects available to the agent is determined by that agent’s culture, we refer to this simplification of action on ac- count of the formal properties of objects cultural sup- port for improvisation. Of course, not all of human life has this property. But we can isolate the particular problems which require more complex computational resources and devote those resources only when they are necessary. (This idea is similar in spirit to the analysis of constraint satisfaction problems by Dechter and Pearl (1985) and Mammond and Converse’s no- tion of stabilization (1991).) We do believe however that all activity is improvised in the sense that an agent continually redecides what to do (Agre forthcom- ing). Our intent is to distinguish the forms of impro- vised activity which can be performed by simple mech- anisms from the more complex and varied-but equally improvised-activities of making schedules, imagining scenarios, using plans, thinking up precedents, and so forth. Agre and Horswill 363 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. This paper is organized as follows. First we intro- duce a greatly simplified formalization of artifacts, ma- terials, and actions involving these things. We then de- fine ‘cooking tasks’, which are tasks which only involve objects in certain classes and goals of certain types. We demonstrate that cooking tasks can be performed in a ‘greedy’ fashion. We then sketch some extensions to the simple model which broaden the model’s coverage and are used by the program in the next section. This program, called Toast, implements an elaboration of this scheme and gives an example of it in action. We conclude by suggesting some of the wider consequences of this general type of research. Ontology of Cooking Tasks This section sketches a formal model of objects, ac- tions, and tasks. Due to space restrictions, we have greatly simplified the model, which as a result cannot quite express everything that goes on in Toast. A later section discusses some of the issues that this version of the formalism leaves out. Note that the formalism is for the purpose of analyzing interactions between the agent and its environment; it does not necessarily de- scribe any structures in the agent’s head. Let us characterize objects in the world according to the roles they play in customary routine activities. A given object type (or type for short) will be character- ized by a state graph, which is a finite labeled directed graph. The nodes in this graph are called states and the label on the arcs are called operations. An op- eration can be non-deterministic in the sense that it labels several arcs leading from the same state. An object instance (or instance for short-we will speak of ‘objects’ when it’s clear whether we mean types or in- stances) has an associated object type. A world state is a finite set of instances and a mapping from each of these instances to a state in its type’s state graph. A history is a function from natural numbers (represent- ing ‘time’) to world states. A history thus follows a set of instances through a series of changes. (Toast can create and destroy objects but the simplified formal model here cannot.) An action type (or action for short) consists of a fi- nite sequence of pairs, each consisting of an object type and an operation from that type’s state graph. An ac- tion instance consists of an action type and a sequence of object instances, each of the appropriate type and current state. For now we assume that only one action takes place at a time, so that an action instance deter- mines a (partial) function from world states to world states, defined in the obvious way. A history is thus determined by an initial world state and a sequence of action instances. Let a task consist of a finite set of object types called an inventory, an initial world state, and a finite set of goals, each of which consists of an object type and a state from that type’s graph. A goal is satisfied in a given world state if that world state includes some instance of the indicated type that is in the indicated state. (So one cannot assert that two instances of a given type must be in a given state.) So far these definitions are unexceptional. All of the complexity problems of classical planning (Chap- man 1987) apply to this scheme as well. One cure for complexity problems is the discovery of additional con- straint in the task. The claim we make for our scheme is that it allows us to define one important source of complexity-ameliorating constraint in a natural way, as follows. Let us categorize object types according to the prop- erties of their state graphs. We will refer to a given cat- egory of types as an object ciluss (or class for short). We will find that certain classes have advantageous com- putational properties. We will define a particular class of tasks, coo&g tasks, whose entire inventory of object types falls into two classes: tools and materials. First, let us say that a given action type is focused if it only involves a single object, that is if it only consists of a single operation. An operation is focused if it is part of some focused action. Let us refer to a state in a given type’s state graph as free if it can be reached from any other state in that graph using only focused operations. A tool, then, is an object which possesses at least one free state. Each tool will have a distinguished free state, called its normal state, the point of which will become clear presently. (One common normal state is “clean and dry.“) The notion of a material is defined relative to a given set of tools. A tool action is an action that involves some number of tools (though typically one), and pos- sibly one object which is not a tool; a normal tool ac- tion is a tool action in which the operations that apply to tools require them to be in their normal states. A material is an object whose state graph is acyclic and has a distinguished raw state, from which all its other states can be reached by means of operations found in normal tool actions. (Of course, a material might have all manner of other operations in its state graph as well.) A cooking task, then, is a task whose inventory con- sists of tools and materials. These classes, together with a third class used by Toast, containers, cover the vast majority of objects found in the average kitchen. There is thus some reason to believe that the formal- ism bears some relation to the computational issues in- volved in actual cooking. Cooking is an attractive do- main (compare Hammond, Converse, & Martin 1990, Lansky & Fogelsong 1987) because it is fairly compli- cated but still routine, has fairly well-defined proper- ties but regularly admits of uncertainty and surprise, and has plainly been organized in customary ways to allow action to be driven in large part by vision (com- pare Agre & Chapman 1987, Ballard 1991, Larkin 1989). On the other hand, our simple formalization of cooking does not approach the true complexity of cooking and kitchens (Hardyment 1988), or of artifacts 364 Planning (Forty 1986, Norman 1988), as cultural phenomena. On the other hand, these abstract ‘cooking tasks’ are not limited to the preparation of food; they are likely to be found in any activity involving the same general classes of objects. No doubt each activity will require its own extensions to the crude model we have out- lined so far. The general strategy, though, is the same: relating the formal properties of artifacts to the com- putational demands of improvised action. This object-centered model of action is similar to the conventional state-space model in that both of them model potential actions using directed graphs. Given a task in our model, one could construct a conventional state space for it by computing the graph-theoretic product of all the state graphs for each object instance. This graph would, of course, be extraordinarily compli- cated. The object-centered model thus makes explicit a great deal of formal structure that the conventional model leaves implicit in the state graph. OW Cook This section describes the process of solving a cook- ing task and sketches the design of an agent that can do so efficiently. The general idea is that the agent is in the kitchen, standing adjacent to the countertops and stove and looking down at them. We assume that the agent can readily detect the states of all visible objects. The agent achieves its goals by using nor- mal tool actions to push materials through their state graphs along certain customary trajectories; and it uses focused actions to get tools into normal states. The al- gorithm thus depends on a culturally evolved abstruc- tion (Anderson & Farley 1988, Knoblock 1989) that minimizes interactions among the actions in cooking tasks. This section’s algorithm (unlike that of Toast) does not clean its tools when it is done; this requires a notion of ‘background conditions’ (see below). The algorithm requires that the agent’s machinery come with an action table for each material type that maps a state in that material’s state graph and a goal state to normal tool actions (if one exists) which can convert instances of that material to the next state along its trajectory toward goal state. (These tables are not plans. They do, however, resemble STRIPS triangle tables (Fikes and Nilsson 1971). They also re- semble GPS difference tables (Newell and Simon 1963), though their use results in concrete actions, not moves in a search space.) The algorithm also needs similar tables for each tool (i.e., each object type in the ‘tool’ class) to come up with focused actions to move the tools toward their normal states. (These tables are eas- ily constructed from the objects’ state graphs, though we believe that people normally acquire the tables in other ways, for example through apprenticeship.) With all of this tedious background, the algorithm is now straightforward: While there are unsatisfied goals, Choose (arbitrarily) an unsatisfied goal. Let G be the specified goal state. Find an instance M of the specified material type. Determine its current state S. Let A be the entry for the S and G in M’s action table. Choose tool instances to fiII each of A’s participant slots, preferring instances which are already in their normal states. If some chosen tool T is not in its normal state then perform the action specified in T’s action table for its current state otherwise perform A using M and the chosen tools. Proving this algorithm correct is simple. Clearly if the algorithm terminates, then the goals will all have been achieved. To see that the algorithm termi- nates, construct separate ‘progress functions’ for the materials and tools, each defined as the sum of dis- tances from goal (or normal) states across instances of the respective class. Note that these progress func- tions are bounded. The material progress function never increases. The tool progress function always de- creases except possibly on iterations when the mate- rial progress function decreases. Finally, the material progress function function must decrease when the tool progress function reaches zero, if not before. Thus the material progress function much reach zero in a finite number of iterations, causing the algorithm to termi- nate. xtensions The formalization in the previous section has been grossly simplified; it is only just complicated enough to illustrate the potential computational advantages of an object-centered model of action. Toast, as mentioned above, includes a number of extensions to this formal- ism which introduce some additional issues. Extending the algorithm and correctness proof to address these is- sues is somewhat complicated. Some of the issues are familiar from computer science. Others though require a closer analysis of cooking problems. Several aspects of this work are still in progress. Extensions in the Toast Toast employs an extra class of objects called contain- ers. Containers include objects like bowls, cups, and plates, but they also include countertops, stove burn- ers, fridges, and cupboards. Unlike tools, containers remain committed to a single purpose for an extended period of time. It is thus possible to run out of them or to deadlock. As far as we can tell, the only sure answer to this is to have enough containers (although see Holt 1972). Toast’s world may contain many instances of a given type. These instances may begin their lives in cup- boards or fridges or they may arise through the chop- ping of other instances (e.g., chopping celery or sepa- rating egg whites; cf Dale 1990). Toast needn’t keep track of which instance is which, since it assumes that 365 all instances of a material in the same state are inter- changeable. Toast also regularly mixes an object into another object, thus destroying the former. In addition to goals, Toast also maintains a set of ‘background conditions’ whenever it is otherwise idle. Background conditions specify that all instances of a given type should be in a given state and location. For example, this allows Toast to clean up after making breakfast. Unimplemented extensions Other extensions remain unimplemented. While Toast allows stove burners and toasters to perform their own actions, this requires more thought when those ac- tions can lead to undesired states, like burned eggs. At this point one would like to formulate a more ex- plicit notion of ‘tending’ something. Kitchens are full of tricks to keep you from forgetting things you’re cook- ing (whistling kettles, timers, smells and sounds, and the general policy of looking around a lot), and these will want to be formalized as well. The model ought to explicitly treat the agent’s body, hands, eyes, and senses (hearing, smell, eic.). An agent might go around with a spatula in its hand and a dish-towel over its shoulder, putting them down only when necessary. This is more efficient than the current scheme, which vaguely imagines tools to be picked up from the countertop and put back down after each ac- tion. It would also allow us to make use of deictic rep- resentation (Agre & Chapman 1987, Agre forthcom- ing), rather than the unnecessarily clumsy variables- and-constants scheme used here. In general, as the Toast formalism becomes more realistic, we expect it to drift from its similarity to traditional planning for- malizations of action. Goals should be able to include numerical existen- tial quantifiers (“two slices of bread toasted”) and re- lations (“all the pots are in the cupboard”). As it is, the model requires that the agent work with only one instance of any given material type at a time, which is plainly too restrictive. But getting this right entails extending the definition of actions so that objects can be chosen through some kind of unification, as in “pick up the bowl containing the beaten eggs and pour them into the pan” as opposed to simply “put the beaten eggs into the pan” as at present. This complicates the proofs, but should present no fundamental problem. Formalizing relations will also make it easier to ex- press the difference between a spoon that is really ‘dirty’ and a spoon that is simply covered with the material that one is stirring. Similarly for containers. Experiments We have developed two programs using these ideas. The first program is a system construction tool for Common Lisp which models system construction as a cooking problem: program modules as materials whose Mute&d. Eggs. Fresh +broken --*beaten *cooked. Material. Butter pat. Fresh *melted. Material. Milk supply. Non-empty +empty. Material. Pancake batter. &s-flour --rhas-sugar *has-dry -+has-milk +has-aJl *mixed. Material. Pancake. Cooking +cooked-l-side +flipped +cooked *burnt. Material. Bread slice. Fresh +toasted -+buttered. Tools. Forks, spoons, knives, spatulas, whisks. Clean *dirty, dirty hclean. Containers. Bowls, plates, pans, stove burners, countertop, toaster, bread bag. Active objects. Agent, stove burners, toaster. Figure 1: Some object types in the current system. states include ‘compiled’, ‘loaded’, etc. Being table- driven, it is flexible and efficient. The program is in regular use. The second is Toast. In this section we will discuss Toast’s performance on making breakfast. Toast Makes Toast’s simulated kitchen contains several types of ob- jects (see figure 1 for a partial list), each with its own behavior. Toast’s goals are represented as triples of the form (class, state, container) specifying that an object of the specified class in the specified state, should be placed in the specified container. The container is then moved to an ‘out-basket’, namely the kitchen table, thus preventing it from being used in further opera- tions. Figure 2 shows a sample run of Toast cooking an omelette, two pancakes a slice of buttered toast, set- ting the table, and cleaning up. Toast switches be- tween goals as they become blocked waiting for mate- rials to cook. Toast is also opportunistic: when making the second pancake, it notices that there is already bat- ter available. Toast has deficiencies however. It doesn’t overlap the cooking of the two pancakes because it it thinks that the one pancake can satisfy both pancake goals until the first is moved to the out-basket. It also doesn’t realize that it can recycle a used pan for cook- ing two copies of the same thing. The simulated kitchen contained 110 objects of 25 different types. The run took less than 30 seconds on a Macintosh 11x, one third of which was spent formatting the output. We have also run Toast as a short-order cook in a ‘restaurant’ consisting of the kitchen and a set of ‘cus- tomers’ who randomly place orders by pushing new goals onto Toast’s goal list. Space does not permit the inclusion of a trace from the restaurant runs. One problem with Toast in this domain is that since it con- tains no notion of giving priority to time-critical oper- ations, it can burn an omelette if it gets swamped with too many tasks. The Toast source code is available from the authors on request. 366 Planning 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 30 31 36 46 56 57 58 59 60 69 79 89 90 91 92 93 94 95 96 97 98 99 100 101 102 [Making omelette] (ADD-EGG EGG-10 OMELETTE- BATTER-O) (ADD-EGG EGG-9 OMELETTE-BATTER-O)’ (BEAT OMELETTE-BATTER-O WHISK) (MOVE PAN-4 BURNER-4) (MOVE BUTTER-PAT-15 PAN-4) (MELT BURNER-4 PAN-4 BUT’fER-PAT-15) (MOVE SLICE-23 TOASTER) . [Waiting for butter so &aking toast] (START TOASTER SLICE-23) (MOVE KNIFE-4 PLATE-l) [Waiting for toast so setting table] *** Done with goal (KNIFE CLEAN PLATE-l) *** (MOVE PLATE-l KITCHEN-TABLE) (MOVE FORK-4 PLATE-l) *** Done with goal (FORK CLEAN PLATE-l) *** (MOVE SPOON-4 PLATE-l) Toaster popa! (MOVE BUTTER-PAT-14 KNIFE-3) [Back to toast] (BUTTER SLICE-23 KNIFE-3 BUTTER-PAT-14) (POUR-OMELETTE-BATTER OMELETTE-BATTER-O . ..) [Butter melted so back to omelette] (MOVE SLICE-23 PLATE-l) [Setting table] *** Done with goal (SLICE BUTTERED PLATE-l) *** *** Done with goal (SPOON CLEAN PLATE-l) *** (POUR-FLOUR FLOUR BOWL-3) [Making pancake] (ADD-SUGAR SUGAR PANCAKE-BATTER-O) (ADD-BAKING-POWDER BAKING-POWDER PANCAKE-BATTER-O) (FOLD OMELETTE-O SPATULA-2) [Tending omelette] (ADD-MILK MILK-DISPENSER PANCAKE-BATTER-O) [Back to pancakes] (ADD-EGG EGG-8 PANCAKE-BATTER-O) (MIX PANCAKE-BATTER-O SPOON-3) (MOVE PAN-3 BURNER-3) (FLIP OMELETTE-O SPATULA-2) [Tending omelette] (MOVE BUTTER-PAT-13 PAN-3) [Pancake] (MELT BURNER-3 PAN-3 BUTTER-PAT-13) (MOVE OMELETTE-O PLATE-l) [Finishing omelette] *** Done with goal (OMELETTE COOKED PLATE-l) *** (SPOON-BATTER PANCAKE-BATTER-O PAN-3 BUTTER-PAT-13) [Pancake] (FLIP PANCAKE-O SPATULA-2) (MOVE PANCAKE-O PLATE-3) *** Done with goal (PANCAKE COOKED PLATE-3) *** (MOVE PLATE-3 KITCHEN-TABLE) (MOVE PAN-2 BURNER-2) [Pancake 21 (MOVE BUTTER-PAT-12 PAN-2) (MELT BURNER-2 PAN-2 BUTTER-PAT-12) (SPOON-BATTER PANCAKE-BATTER-O PAN-2 BUTTER-PAT-12) (FLIP PANCAKE-l SPATULA-2) (MOVE PANCAKE-l PLATE-2) *** Done with goal (PANCAKE COOKED PLATE-2) *** (MOVE PLATE-2 KITCHEN-TABLE) (CLEAN PAN-2) [Cleanup] (CLEAN PAN-3) (CLEAN SPOON-3) (CLEAN SPATULA-2) (CLEAN BOWL-3) (CLEAN KNIFE-3) (CLEAN PAN-4) (CLEAN WHISK) (CLEAN BOWL-4) (TURN-OFF BURNER-2) (TURN-OFF BURNER-3) (TURN-OFF BURNER-4) Figure 2: Sample run of the breakfast program. The agent was given the goals of making an omelette, two pancakes, a slice of toast, and setting the table, then cleaning up. Our comments appear in square brackets. Control experiments To insure that the breakfast maker problem was not entirely trivial, we implemented a STRIPS formaliza- tion of a subset of the domain and tested it using the SNLP non-linear planner (Barrett, Soderland, & Weld 1991) on the omelette making subproblem. A solution to this involves breaking and beating three eggs, melt- ing butter, initial cooking, then folding and browning each side. The planner could solve the problem when led through the correct plan a few steps at a time, but could not solve the complete omelette cooking sub- problem from start to finish given the resources which we had available to us. (The planner ran for 6 hours on a Symbolics XL1200 before exhausting its paging disk.) The planner was able make toast and set the table however. These experiments are only intended to demonstrate that cooking problems are non-trivial, and therefore that the domain constraints discussed in this paper are quite powerful. They are not a fair comparison of im- provisation and planning. An abstract planner might fare better, as might a version of STRIPS (or, indeed, GPS) with a suitably object-centered representation. (We owe this observation to Dave McAllester). Our point is not that Toast can solve problems that other leading brands cannot. Instead, our contribution has been to point out a source of constraint in the real world that that makes some elaborate machinery un- necessary, while simultaneously helping to explain why so much ordinary activity can be so readily improvised. Conclusion This study of the computational virtues of cultural ar- tifacts illustrates one part of a larger story about the nature of human intelligence. Debate in AI is often polarized between extreme answers to the question of how much thought goes into a given action: the ‘plan- ning’ view says ‘lots’ and the ‘reactive’ view says ‘very little’. Our answer is, ‘lots, but most of it resides in the culture, not in the individual’. Tools, we would argue, act as carriers of a culture’s accumulated in- telligence. Those who develop exceptional insight into their tasks sometimes improve their tools or invent new ones. Other members of the culture can then learn to use those tools without having to learn a domain model deep enough to explain the design of the tools. Vygot- sky (1978) refers to these processes as externalization and internalizution respectively. For example, we can use a spatula without knowing why it was made with holes in it or make coffee without understanding why the filter and its holder are shaped as flattened cones. Our model illustrates the normal, unexceptional case when culturally shaped people and culturally shaped artifacts interact in unproblematic improvisation. More generally, we see our research as merely one example of a new conception of AI research that has been emerging in the last few years. On this view, Agre and Horswill 367 AI research uses principled characterizations of agent- environment interactions in guiding the design of new agents or the explanation of existing ones. In the present case, we have discovered a property of the cul- tural world that allows a large class of interactions to proceed in a computationally simple fashion. This convergence between an important sociological phe- nomenon and an important source of computational tractability points toward a larger category of explana- tory computational theories. Though future research will presumably revise the details of this conclusion, further investigation of the computational properties of agent-environment interactions will surely lead to deeped understandings of situated activity in people, animals, and robots alike. Acknowledgments John Batali, David Chapman, Gary Drescher, David McAllester, Penni Sibun, and Lynn Stein provided us with valuable advice and guidance. References Agre, P. E. & Chapman, 19. 1987. Pengi: An imple- mentation of a theory of activity. In Proceedings of the Sixth National Conference on Artificial Intelli- gence, 196-201. Agre, P. E. 1993. The Dynamic Structure of Every- day Life. Cambridge: Cambridge University Press. Forthcoming. Anderson, J. S. & Farley, A. M. 1988. Plan abstraction based on operator generalization. In Proceedings of the Seventh National Conference on Artificial Intel- ligence, 100-104. Ballard, D. H. 1991. Animate vision. Artificial Intel- ligence 48( 1): [??I. Barrett, A.; Soderland, S.; & Weld, D. 1991. The effect of step-order representations on planning. Univer- sity of Washington CSE TR 91-05-06. Brooks, R. A. 1986. A robust layered control system for a mobile robot. IEEE Journal of Robotics and Automation 2( 1): 14-23. Chapman, D. 1987. Planning for conjunctive goals. Artificial Intelligence 32(3): 333-377. Dechter, R. & Pearl, J. 1985. The anatomy of easy problems: A constraint-satisfaction formulation. In Proceedings of the Ninth International Joint Con- ference on Artificial Intelligence, 1066-1072. Dale, R. 1990. Generating recipes: An overview of Epicure. In Dale, R.; Mellish, C.; & Zock, M. eds. Current Research in Natural Language Generation. Orlando: Academic Press, 229-255. Fikes, R. E. & Nilsson, N. J. 1971. Strips: A new approach to the application of theorem proving to problem solving. Artificial Intelligence 2(3): 189- 208. Forty, A. 1986. Objects of Desire. New York: Pan- theon. Fox, M. S. & Smith, S. 1984. ISIS: A knowledge-based system for factory scheduling. Expert Systems l( 1): 25-49. Georgeff, M. P. & Lansky, A. L. 1987. Reactive rea- soning and planning. In Proceedings of the Sixth National Conference on Artificial Intelligence, 677- 682. Hammond, K.; Converse, T.; & Martin, C.. 1990. Inte- grating planning and acting in a case-based frame- work. In Proceedings of the Eighth National Con- ference on Artificial Intelligence, [??I. Hammond, K. & Converse, T. 1991. Stabilizing environments to facilitate planning and activity: an engineering argument. In Proceedings of the Ninth National Conference on Artificial Intelli- gence, [787?]. Hardyment, C. 1988. From Mangle to Microwave: The Mechanization of Household Work. Oxford: Polity Press. Holt, R. 6. 1972. Some deadlock properties of com- puter systems. ACM Computing Surveys 4(3): 179- 196. Kaelbling, L. P. 1988. Goals as parallel program spec- ifications. In Proceedings of the Seventh National Conference on Artificial Intelligence, 60-65. Knoblock, 6. 1989. A theory of abstraction for hierar- chical planning. In Benjamin, D. P. ed. Change of Representation and Inductive Bias. Boston: Kluwer. Lansky, A. L. & Fogelsong, D. S. 1987. Localized rep- resentations and planning methods for parallel do- mains. In Proceedings of the Sixth National Con- ference on Artificial Intelligence, 240-245. Larkin, J. H. 1989. Display-based problem solving. In Klahr, D. & Kotovsky, K. eds. Complex Informa- tion Processing. Hillsdale, NJ: Erlbaum, 319-341. Lyons, D. M. & Arbib, M. A. 1989. A formal model of computation for sensory-based robotics. IEEE Transactions on Robotics and Automation s(3): 280-293. Newell, A. & Simon, H. A. 1963. GPS: A program that simulates human thought, in Feigenbaum, E. A. & Feldman, J. eds. Computers and Thought. New York: McGraw-Hill. Norman, D. A. 1988. The Psychology of Everyday Things. New York: Basic Books. Rosenschein, S. J. & Kaelbling, L. P. 1986. The syn- thesis of digital machines with provable epistemic properties. In Proceedings of the Conference on Theoretical Aspects of Reasoning About Knowl- edge. Suchman, L. 1987. PZans and Situated Action. Cam- bridge: Cambridge University Press. Vygotsky, L. 1978. Mind in Society: The Devel- opment of Higher Psychological Processes. Cam- bridge: Harvard University Press. Originally pub- lished in Russian in 1934. 368 Planning | 1992 | 72 |
1,268 | Department of Computer Science University of Waterloo Waterloo, Ontario, Canada N2L 3Gl Abstract In the best case using an abstraction hierarchy in problem-solving can yield an exponential speed-up in search efficiency. Such a speed-up is predicted by var- ious analytical models developed in the literature, and efficiency gains of this order have been confirmed empir- ically. However, these models assume that the Down- ward Refinement Property (DRP) holds. When this property holds, backtracking never need occur across abstraction levels. When it fails, search may have to consider many different abstract solutions before find- ing one that can be refined to a concrete solution. In this paper we provide an analysis of the expected search complexity without assuming the DRP. We find that our model predicts a phase boundary where abstraction provides no benefit: if the probability that an abstract solution can be refined is very low or very high, search with abstraction yields significant speed up. However, in the phase boundary area where the probability takes on an intermediate value search efficiency is not nec- essarily improved. The phenomenon of a phase bound- ary-where search is hardest agrees with recent empirical studies of Cheeseman et al. [CKTSl]. Introchction In this paper we examine the benefits of hierarchical problem-solving. Hierarchical problem-solving is ac- complished by first searching for an abstract solution to the problem and then using the intermediate states of the abstract solution as intermediate goals to de compose the search for the non-abstract solution. This technique has been used in a number of problem-solvers in AI [NS72, Sac74, Sac77, Ste81, Tat77, Wi184]. It has long been known that the identification of in- termediate states which decompose a problem can sig- nificantly reduce search [NSS62, Min63]. However, the *This work is supported by grants from the Natural Science and Engineering Council of Canada and by the Institute for Robotics and Intelligent Systems. The au- thors’ e-mail addresses are fbacchusGlogos s Waterloo. ca and qya.ngOlogos.waterloo.ca. analysis of the benefit yielded by decomposition, pro- vided in these works, ignores the cost of finding the in- termediate states. In hierarchical problem-solving these states are found by searching in an abstract version of the problem-space. The abstract space is smaller and hence the benefit gained by decomposing the non- abstract space often outweights the cost of searching this space. Empirical evidence of the net benefit of the hierarchical approach has been provided by ABSTRIPS [Sac741 and by the work of Newell and Simon [NS72]. However, only small problems and limited domains were considered by these works. Korf [Kor85] has provided an analysis of the bene- fits of using macro operators as the abstraction device. With this type of abstraction, however, once we find a solution in the abstract space (the space generated by the macro operators) we have a non-abstract solution: no further search is required. Nevertheless, Korf’s anal- ysis can be viewed as demonstrating that searching for an abstract solution is significantly more efficient that searching for a non-abstract solution. Knoblock’s analysis of hierarchical problem-solving p(no91] is the most detailed to date, and has had a sig- nificant influence on this work. However, his analysis assumes that backtracking does not occur across ab- straction levels: once an abstract solution is found we need never search for another one. Hence, Knoblock’s work can be viewed as demonstrating that searching the decomposed non-abstract space plus searching the abstract space once yields a significant net benefit over searching the non-abstract space. In previous work [BY911 we have identified this as- sumption as an important property of an abstraction hierarchy, and have termed it the downward refinement property (DRP). Formally, this property holds when ev- ery abstract solution can be refined in a useful manner1 to the next lower level of abstraction. This implies that an abstract solution can always be refined to a con- ‘There is a formal characterization of “useful” which en- sures that the work done at the abstract level is not undone during refinement. Such refinements are termed monotonic. See [KTYSl] and [SY91] for more details. Bacchus and Yang 369 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Crete solution without backtracking across abstraction levels, given that a concrete-level solution to the plan- ning problem exists. When the DRP fails the planner may expend search effort trying to refine a particular abstract solution be- fore discovering that it is unrefineable. This would cause backtrack in the abstraction hierarchy to find an alternate abstract solution. Search would then continue by trying to refine this new abstract solution. Clearly, if such backtracking occurs frequently the overhead of searching the abstraction hierarchy could overwhelm the benefits of using abstraction.. In fact, experiments with ABSTRIPS and ABTWEAK VT901 have shown that abstraction only increases search efficiency in hierar- chies where the probability is high that an abstract so- lution is refineable (i.e., where we do not have to do much backtracking in the abstraction hierarchy). In hi- erarchies where this is not the case, using abstraction can in fact decrease the efficiency of the planner.2 In order to understand this phenomenon more thor- oughly we provide an analytical model of search complexity as a function of this probability, i.e., the probability that an abstract solution can be refined. This also provides a more realistic analysis of the ben- efits of abstraction in problem-solving: unlike previous models it takes the important factor of search through the abstraction hierarchy into consideration. Our analysis demonstrates the existence of two quali- tatively distinct cases. When we have the DRP or when the probability that an abstract solution can be refined is low, search complexity does not depend on the shape of the abstraction space, and in fact it can be made lin- ear if the number of levels of abstraction can be made large enough. On the other hand, in the middle region, where the DRP fails and the probability of refinement is not that small, search complexity depends on both the number of levels of abstraction and on the branching factor in the abstraction space. In this region increas- ing the number of levels of abstraction is not always a useful option as that also increases search complexity. An additional contribution of this work is that it pro- vides an analytical model that supports the recent em- pirical results reported by Cheeseman et al. [CKTSl]. At the extremes where most abstract solutions can be refined and where very few can, search is relatively easy. In the former case backtracking is minimized, while in the latter case it does not require much work to rec- 2This effect is in Dart due to the additional (constant fac- tor) overhead involv& in using abstraction. ’ 3There have been other analytical models of search com- plexity presented in the literature, e.g., [KP83, MP91]. How- ever, these works have addressed fundamentally different search problems. For example, the works cited consider the problem of searching for an optimal path in an infinite binary tree with branches of cost 1 and 0. Search through a hierarchy of abstraction spaces, considered here, cannot be mapped to this model. ognize that you are on the wrong path, i.e., backtrack- ing is cheap. The middle region, however, represents a phase boundary where a larger proportion of hard search problems lie: average search complexity rises in this region. Here, a significant fraction of the abstract solutions are unrefineable, and it can take a great deal of work to detect that you are on a bad path. In the sequel we will first present the basic problem- solving framework under which we are working, and identify the assumptions which make the analysis tractable. We then present the details of our analy- sis. From the model we are able to generate various predictions and we discuss those next. Finally, we close with a discussion of the implications of the work and some conclusions. The Problem-Solving amework The problem-space is defined by a collection of states and operators which map between the states. A prob- lem consists of an initial state and a goal state, and it is solved by searching for a sequence of operators whose composition will map the initial state to the goal state. In hierarchical problem-solving an abstract version of the original, ground or concrete, problem-space is used. The abstract version is generated via some reduction or generalization of the operators or states in the ground space. For example, in ABSTRIPS the operators are gen- eralized by dropping some of their preconditions; this has the effect of increasing the domain of the function they define on the states. A hierarchical problem-solver first searches the ab- stract space for a solution. However, this solution will no longer be correct when we move to a lower level of abstraction; instead it can only serve as a skeletal plan for the lower level. A correct solution at the lower level is generated by refineing the abstract plan, and this is accomplished by inserting additional operators between the operators in the abstract plan. If we have m oper- ators in the abstract plan, refinement to the next lower level can be viewed as solving m “gap” subproblems. Solving the gaps amounts to finding new sequences of operators which when placed between the operators of the abstract plan generate a correct solution at the lower level. The Analytical ode1 The Tree of Abstract Plans The total search space explored by a hierarchical problem-solver can be viewed as a tree generated by the abstraction hierarchy. In this tree each node at level i represents a complete i-th level abstract plan. The chil- dren of a node represent all of the different refinements of that plan at the next (lower) level of abstraction. The leaf nodes are complete concrete-level plans. The task in searching through the abstraction space is to find a path from the root down to a leaf node representing a correct concrete-level solution. Each node on the path 370 Planning must be a legal i-th level abstract plan to the problem at hand and must be a refinement of the i+l-level abstract plan represented by its parent. The work in searching this tree comes from the work required to find the plan at each node and will depend on the number and depth of the nodes the search examines. The root represents a special length one solution to every problem: a universal plan. Its presence is sim- ply a technical convenience. The levels of the tree are numbered (n, . . . , 0) with the root being at level n and the leaves at level 0. Hence, discounting the universal plan at level n, our abstraction hierarchy has n levels. To make our analysis useful we make some additional assumptions. First, we assume that the abstraction hierarchy is reg- ular. In particular, we assume that it takes approxi- mately k new operators to solve every gap subproblem where k is constant across abstraction levels. Refineing a solution to the next level amounts to solving a gap subproblem between every pair of operators; hence the refined solution will be k times longer. Since the root is a solution of length 1, this means that the solutions at level i are of length kn-“, and that the concrete-level solution is of length kn, which we also denote by e. As this assumption degenerates the value of abstrac- tion degenerates. If we end up having gap subprob- lems which require solutions of length O(e) instead of O(k) = O(@/“), then solving them will require search of O@‘) where b is the branching factor generated by the operators in the ground space.4 This is no better than search without abstraction. Second, we assume ,that the individual gap subprob- lems can be solved without significant interaction. If, say, r gap subproblems interact we will have to search for a plan that solves all of them simultaneously. Such a plan would be of length O(rk) and would require O(br’) search. As rk approaches e we once again degenerate to search complexity of O(b’) where abstraction yields no benefits. Our two assumptions, then, are basic assumptions required before the abstraction hierarchy yields any in- teresting behavior at all. When these assumptions fail the abstraction hierarchy is simply not decomposing the problem effectively. Knoblock [KnoSl] also relies on these assumptions, but his assumption of indepen- dent subproblems is phrased as an assumption that backtracking only occurs within a subproblem. This is significantly stronger as it also prohibits backtracking across abstraction levels. The tree of abstract plans will have a branching factor that, in general, will vary from node to node. This branching factor is the number of i-l level refinements possible for a given i level solution, i.e., the number of children a node at level i has. Let the maximum 4The branching factors of the abstract but we can use b as an upper bound. spaces are lower, of these branching factor be B. For simplicity we will use B as the branching factor for all nodes in the tree. Note, B has no straightforward relationship with b the branching factor generated by the operators. The Probability of event If a hierarchy has the then every solution at ab- straction level i can be refined to a solution at abstract level i-l. A reasonable way in examine the behavior of hierarchies in which the DRP fails is to assign a proba- bility, p, to the event that a given i-th level solution can be refined to level i- 1. DRP now corresponds to the c=P = 1. If p = 1 we need never reconsider the initial part of a path of good solutions. The DRP guarantees we can extend the path down to level 0. If p < 1, how- ever, we might build a path of correct solutions from the root down to a node at level i, and then find, upon examining all of its children, that it is not refineable to the next level. This will force a backtrack to the penul- timate node at level i + 1 to find an alternate level i solution, one which is refineable. This may cause fur- ther backtrack to level i + 2, or search may progress to lower levels before backtracking occurs again. We are interested in the complexity of search when a ground-level solution exists. In this case it follows from the upward solution property [Ten891 that there will be at least one path of correct solutions in the tree from the root to a leaf node. Our task, then, is to explore the average case complexity of search in abstraction hi- erarchies in which (1) the probability that a given node in the abstraction search tree can be refined is p, and (2) there is at least one good path, i.e., a path of good nodes, from the root to a leaf in the tree. Average case complexity can be found by considering randomly generated abstraction trees. Our tree has a constant branching factor B and height n + 1. ence, it has N B”+l-l = B-l nodes. A random tree is generated by labeling each node independently as being refineable (good) with probability p, or not refineable (bad) with probability 1 - p. Each of the 2N distinct trees that can be generated by this process has probability pg(l - P) N-g, where g is the number of good nodes. Some of these trees will not contain a good path from the root to a leaf. We remove these trees, and renormalize the probabilities of the remaining trees so that they sum to 1. That is, we take the conditional probability. One other piece of notation we use is b(K, N, P) to denote the binomial distribution, i.e., the probability of K successes in N independent Bernoulli trials each with probability P of success. nalytic Forms Now we present the analytic forms which result from an analysis of the above model. The reader is referred to our full report for the proofs of the following results [BY92]. Bacchus and Yang 371 1) Let NodeWork be the amount of work required to refine a node at level i. At level n we have one subprob- lem to solve which requires O(bk) computation. At level n-l the nodes are abstract solutions of length k, result- ing in k subproblems each requiring 0(@ computation. This trend continues to level 1, but at level 0 the solu- tions are concrete and do not need to be refined. Hence, we have NodeWork = kneibk and NodeWork(0) = 0. 2) Let F(i) be the probability that a random subtree rooted at level i fails to contain a good path from its root to a leaf. A subtree can fail to contain a good path in two exclusive ways: (a) the root could be a bad node or (b) the root could be good but somewhere among its descendents all the good paths terminate before reach- ing level 0. stop by level 1, as if a node at level 1 is good this means that it can be refined to a good ground-level so- lution and the initial tree would not be bad. Hence, BadTreeWork(0) = 0, and we obtain the recurrence: BadTreeWork(i) = kn-‘bk+pB(BadTreeWork(i-I)). By expanding the first few terms of this recurrence we can find a general expression: + (pBk)i - 1 BadTreeWork(i) = bkkn-* pBk-l ’ (1) The second case can be analyzed using the theory of branching processes [Fe168, AN72]. If the root is good it initiates a branching process where it might have some number of good children and they in turn might have some number of good children and so on. We can con- sider the production of bad children as points were the process terminates. The number of good children of the root is binomially distributed: b(m, B,p) is the proba- bility of having m good children, and its generating function is G(s) = (CJ + PS)~,~ where q = 1 - p. Let Gi(s) = G(s) and Gj = Gj_i(G(s)), i.e., the j-th iter- ate of G(s). 4) Let GoodTreeWork(i) be the expected amount of computation required to search a good subtree with root at level i, i.e., a subtree which contains at least one good path from its root to a leaf. Our ultimate aim is to analyze GoodTreeWork(n). To examine a good tree we have to expand its root node. Then we must search the subtrees under the root, looking for a good subtree rooted at the next level. Once we find such a subtree we never need backtrack out of it. (There may however, be any amount of backtracking involved while search- ing the bad subtrees encountered before we find a good subtree.) From the theory of branching processes it is known that the probability that there are no path of i good nodes from the root is Gi( 0). For example, the prob- ability of there being no paths of 2 good nodes from the root (i.e., the probability of no good child having a good child) is Gs(O) = G(G(0)) = G(qB) = (q+pqB)B. Putting (a) and (b) together we obtain: F(i) = q + p[Gi(O)], and we can compute F(i) directly for any value of i and p. From this result and known results about the asymptotic behavior of branching processes we can identify three regions of importance: when p 5 l/B we have lim+oo F(i) = 1; when l/B < p < 1 we have 0 c limi-+oo F(i) < 1 with the value of the limit decreasing as p increases; and when p = 1 we have Vi.F(i) = 0. 3) Let BadTreeWork(i) be the expected amount of com- putation required to search a subtree with root at level i that does not contain a good path. To ensure that such a tree is a dead end we have to search un- til we have exhausted all candidate good paths. We always have to expand the root which is at level i and hence requires NodeWork = knwibk computa- tion. With probability p the root is refineable and we will then have to examine all of the B subtrees under the root, all of which must be bad (otherwise the initial tree would not be bad). This process must The root has B children, and hence between 1 and B good subtrees under it. Let m be the number of good subtrees under the root. The probability of m taking any particular value is b(m, B, 1 - F(i-1)): each subtree can be viewed to be the result of a Bernoulli trial where the probability of failure (a bad subtree) is F(i-1). However, we also know that the case m = 0 is impossible, and must renormalize the probabilities by dividing them by 1 - b(0, B, 1 - F(i-1)). If there are in fact m good subtrees, then by it can be proved [BY921 that on average we will have to search (B - m)/(m + 1) bad subtrees before finding a good subtree. The expected number of bad subtrees that must be searched can then be computed by summing the average number of trees for each values of m times the probability of that value of m holding. The observations above can be put together to yield a recurrence which can be simplified to the following form. GoodTreeWork(i) = (2) knSibk (g) + E BadTreeWork(j)IQ). j=l In this equation I’(i) represents the average number of bad subtrees we need to examine at level i. A closed form for P(i) involving B and F(i) can be given [BY92]. Predictions of the Model 5When this generating function is expanded as a power We can now examine what these expressions tell us series in s the coefficient of sm is equal to the probability about the expected amount of work we need to do of m good (refineable) children among the B offspring, i.e., b(m, B,p). when doing hierarchical problem-solving: we examine GoodTreeWork(n) under various conditions. First it is 372 Planning Table 1: Search Complexity for Different Regions of Refinement Probability. useful to know the following results derived in the full report [BY921 : n-l c BadTreeWork(j) = i o(bkkn-l) P < l/B O(bkknmln) p=l/B j=l 0(bkk’+1(pB)n-2) p > l/B (3) 1) In the region 0 5 p 5 l/B, lim++, F(i) = 1. It can be shown that I’(i) + (B - 1)/2 as F(i) + 1. Applying Eq. 3 we obtain: GoodTreeWork(n) = O(bkk”-l) pB < 1 O(bkkn-‘n) pB = 1. (4 2) In the region l/B < p < 1, lirnidbo F(i) lies between 1 and 0, decreasing as p increases. For any fixed value of p and B it can be shown that that I’(i) tends to a constant value independent of n, and that this value lies between 0 and (B - 1)/2. Applying Eq. 3 we obtain: GoodTreeWork(n) = O(bkkn-’ (pB)“-2) (5) 3) Finally, when p = 1 the DRP holds and V’i.F(i) = 0. Hence, I’(i) = 0 for all i and Eq. 3 simplifies to p-ibk Ic’_l ( > k-l ’ Evaluating this expression at i = n we obtain: GoodTreeWork(n) = bkO(kn-‘). Implications of the Analysis (6) There are two cases to consider: n constant and n vari- able. In certain domains we can make n, the number of abstraction levels, vary with e. For example, in the Towers of Hanoi domain we can place each disk at a separate level of abstraction [KnoSl]. In other domains, e.g., blocks world, it is not so easy to construct a vari- able number of abstraction levels, and n is generally fixed over different problem instances. The length of the concrete-level solution is equal to kn. Let 4! = kn. We want to express our results in terms of 4!. If we can vary n with 4! then we can ensure that k remains constant and we have that n = log,(e). In this case, bk will become a constant. Otherwise, if n is constant, k = @! will grow slowly with 4?. In this case, bk = bs grows exponentially with 4!, albeit much more slowly that be (c.f., [KnoSl]). This essential dif- ference results in different asymptotic behavior for the two cases n variable and n constant. Table 1 gives the results of our analysis for these two cases expressed in terms of the length of solution 4!. Non-abstract search requires O(b’); hence, it is evi- dent from the table that when 0 5 p 5 l/B and when P = 1 abstraction has a significant benefit. If we can vary n we can obtain an exponential speed-up, and even if n is not variable, we still obtain a significant speed up by reducing the exponent 8 to its n-th root. Our result for p = 1 agrees with that of Knoblock [KnoSl]: here we have the DRP and all of his assumptions hold. Our results for the region 0 5 p 5 l/B, however, ex- tend his analysis, and indicate that abstraction is useful when the probability of refinement is very low. What is happening here is that although the number of bad subtrees that must be searched is large, it does not re- quire much effort to search them: most paths die out after only a small number of levels. As p approaches l/B we see that the search com- plexity increases by a factor of n, and as we move to the region l/B < p < 1 things are worse: we increase by a factor, (PB)“, that is exponential in n. In these regions it is not always advantageous to increase the number of abstraction levels n, especially in the region l/B < p < 1. Asp increases in the region l/B < p < 1 search first becomes harder and then becomes easier, as the number of bad subtrees to be searched drops off. Search complexity varies continuously until it again achieves the low complexity of p = 1 where the DRP holds. Our analysis also tells us that if the number of pos- sible refinements for an abstract solution (B) is large, then searching the abstraction tree is more expensive in the worst region l/B < p < 1. This is to be expected: the abstraction tree is bushier and in this region we have to search a significant proportion of it. Also of interest is that B does not play much of a role outside of this region, except, of course, that it determines the size of the region. Hence, if we know that the DRP holds,6 or if the probability of refinement is very low, we do not have to worry much about the shape of the abstraction tree. However, without such assurances it is advanta- geous to choose abstraction hierarchies where abstract solutions generate fewer refinements. For example, this might determine the choice of one criticality ordering over an alternate one in ABSTRIPS-style abstraction. A question that remains is how does one determine the refinement probability p? One method is to use a learning algorithm to keep track of the statistics of 6Various tests for detecting if the DRP holds of an abstrac- tion hierarchy are given in [BY91]. Bacchus and Yang 373 successful and unsuccessful refinements. Such statistics can be used to estimate p. Once such estimates are ob- tained they can be used to measure the merit of a partic- ular abstraction hierarchy. It then becomes possible to construct an adaptive planner that can use these mea- surements to decide whether or not to use abstraction, to decide between alternate abstraction hierarchies, or even to automatically construct good abstraction hier- archies. We have implemented statistics gathering in a working planning system, and are currently investigat- ing the design of an adaptive planner. We have also recently completed a series of experiments to provide empirical confirmation of the results presented here. These developments will be reported on in the full re- port [BY92]. [AN721 [BJW P-W [CKTSl] [Fe1681 [KnoSl] [Kor85] lP831 wTY91] [Min63] eferences K. B. Athreya and P. E. Ney. Branching Pro- cesses. Springer-Verlag, New York, 1972. Fahiem Bacchus and Qiang Yang. The down- ward refinement property. In Procceedings of the International Joint Conference on Ar- tifical Intelligence (IJCAI), pages 286-292, 1991. Fahiem Bacchus and Qiang Yang. The down- ward refinement property and its effect on planning efficiency, 1992. In preparation. Peter Cheeseman, Bob Kanefsky, and Willian M. Taylor. Where the really hard problems are. In Procceedings of the Inter- national Joint Conference on Artifical Intel- ligence (IJCAI), pages 331-337, 1991. William Feller. An Introduction to Probability Theory and Its Applications: Volume 1. John Wiley and Sons, New York, 1968. Craig Knoblock. Search reduction in hierar- chical problem solving. In Proceedings of the AAAI National Conference, pages 686-691, 1991. Richard Korf. Planning as search: A quanti- tative approach. Artificial Intelligence, 33:65- 88, 1985. R. M. Karp and J. Pearl. Searching for an optimal oath in a tree with random costs. Ar- tificial Intelligence, 21:99-116, 1983. Craig Knoblock, Josh Tenenberg, and Qiang Yang. Characterizing abstraction hierarchies for planning. In Proceedings of the AAAI Na- tional Conference, pages 692-697, Anaheim, CA., 1991. Marvin Minsky. Steps towards artificial in- telligence. In Edward A. Feigenbaum, edi- tor, Computers and Thought, pages 406450. McGraw-Hill, New York, 1963. [MPSl] [NS72] [NSS62] [Sac741 [Sac771 [Ste81] [Tat771 [Ten891 [wi184] [YT901 C. J. H. McDiarmid and 6. M. A. Provan. An expected-cost analysis of backtracking and non-bactracking algorithms. In Procceedings of the International Joint Conference on Ar- tijkal Intelligence (IJCAI), pages 172-177, 1991. Allen Newell and A. Simon, Herbert. Human Problem Solving. Prentice-Hall, Englewood Cliffs, N.J., 1972. Allen Newell, J. C. Shaw, and Herbert A. Simon. The processes of creative thinking. In COrntemporary Approaches to Creative Thinking, pages 63-119. Altherton Press, New York, 1962. Earl Sacerdoti. Planning in a hierarchy of abstraction spaces. Artificial Intelligence, 5:115-135, 1974. Earl Sacerdoti. A Structure for Plans and Behavior. Elsevier, Amsterdam, 1977. Mark Stefik. Planning with constraints. Ar- tificial Intelligence, 16:111-140, 1981. Austin Tate. Generating project networks. In Procceedings of the International Joint Conference on Artijical Intelligence (IJCAI), pages 888-893, 1977. Josh Tenenberg. Inheritance in automated planning. In Ronald J. Brachman, Hector J. Levesque, and Raymond Reiter, editors, Pro- ceedings of the First Conference on Principles of Knowledge Representation and Reasoning. Morgan Kaufmann, San Mateo, California, 1989. David Wilkins. Domain-independent plan- ning: Representation and plan generation. Artificial Intelligence, 22:269-301, 1984. Qiang Yang and Josh D. Tenenberg. Abtweak: Abstracting a nonlinear, least com- mitment planner. In Proceedings of the AAAI National Conference, pages 204-209, 1990. 374 Planning | 1992 | 73 |
1,269 | ositional onstraint 0 ta Mukesh Dalal Rutgers University Computer Science Department New Brunswick, New Jersey 08903 daM@cs.rutgers.edu Abstract We present an efficient method for inferring facts from a propositional knowledge base, which is not required to be in conjunctive normal form. This logically-incomplete method, called propositional fact propagation, is more powerful and efficient than some forms of boolean constraint propaga- tion. Hence, it can be used for tractable deduc- tive reasoning in many AI applications, including various truth maintenance systems. We also use propositional fact propagation to define a weak logical entailment relation that is more powerful and efficient than some others presented in the literature. Among other applications, this new entailment relation can be used for efficiently an- swering queries posed to a knowledge base, and for modeling beliefs held by a resource-limited agent. Introduction Given a particular knowledge base, it is often impor- tant to determine all those facts that can be logically inferred. Since the general problem is intractable,l many AI systems forsake completeness and infer only those facts that can be efficiently obtained. For in- stance, most implementations of logical truth mainte- nance systems [Reiter and de Kleer, 19871 use a weak reasonin method known as boolean constraint prop- agation McAllester, 19801. However, for boolean con- P straint propagation to be tractable, the knowledge base must first be converted into conjunctive normal form - a transformation which may increase its size expo- nentially [de Kleer, 19901. In this paper, we propose a new method for infer- ring facts from a propositional knowledge base. This method, called propositional fact propagation (PFP), does not require the knowledge base (KB) to be in ‘For this paper, a problem is intractable if the cor- responding decision problem is NP-Hard or CoNP-Hard [Garey and Johnson, 19‘791. Also, a knowledge base is any propositional theory, and a fact is any atomic formula or its complement. conjunctive normal form (CNF), and is more power- ful and efficient than boolean constraint propagation (BCP). For any KB, PFP obtains at least all the facts, and sometimes many more, that can be obtained by BCP on the CNF transformation of the KB. For any KB of size n, PFP takes at most Q(nk) time, where L is the maximum nesting of logical connectives in the KB. PFP is incremental, i.e., formulas can be added to the KB without recomputing the earlier results. Intuitively, PFP infers facts from the simpler sub- formulas of the KB, and then uses them to infer facts from the more complex formulas that contain these sub-formulas. Whenever possible, it simplifies the sub- formulas by propagating the facts inferred from them. For example, if the KB consists of a single formula Q v (P A W= v Q)) then PFP simplifies it and infers Q. Note that the CNF transformation of this KB produces {&VP, Q-P) from which BCP cannot obtain the fact Q.2 By com- bining many such steps, PFP can perform some subtle reasoning. For example, consider another KB consist- ing of a single formula ((V v TV) A ((S A R) v S)) v (PA((QA~PAR)V(SAT))) v W(XVW) (1) We show later that PFP simplifies this KB to obtain a much simpler KB {S, (PAT)VVVWVX} Notice that the CNF transformation of the original KB is significantly larger. The general problem of determining whether a given KB logically entails a given formula is intractable. By using PFP, we define a weak logical entailment rela- tion, k , that is tractable. Intuitively, for any KB 2For now, it suffices to know that BCP is a variant of unit resolution [Chang and Lee, 19731 for any KB in CNF. A precise definition is given later. Dalal 409 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. I’ and formula $, I’ /-J $ iff PFP can determine that I? U {+I is inconsistent. This entailment relation is more powerful and efficient than some others pre- sented in the literature (c.f. the logic of explicit belief [Levesque, 1984b; Frisch, 19871). We show that )- can be used for efficiently answering queries posed to a KB, and for modeling beliefs held by a resource-limited agent. The rest of the paper is organized as follows. After some preliminary definitions, we define PFP and illus- trate it by some examples. We then present a tractable algorithm to apply PFP on any given KB. Next, we define the weak entailment relation + 9 and discuss some of its applications. Given the limited space here, we relegate all proofs and detailed motivations and dis- cussions to [Dalal, 19921. Preliminaries We denote propositional symbols by upper case letters P, Q,. -0; and literals (P, +, etc.) by lower case letters P, 9, * ’ a- The complement operator - on literals is defined as follows: if p = Q, then -p = 1Q; if p = l&, then -p = Q. There are two special literals, t and f, that denote true and f&e respectively, and are complements of each other. For a set, A, of literals, -A denotes the set containing the complement of each literal in A. We consider only those formulas that are in negation normal form (NNF), i.e., finitely built from the liter- als using only two connectives, A (conjunction) and V (disjunction). 3 A formula that’s just a literal is called a fact. A formula without any conjunctions is called a &use. A theory (or a KB) is any set of formulas. A theory is called cEuusu1 (or in CNF) if all its formulas are clauses. We denote formulas by lower case Greek letters $, 6,. . . and theories by upper case Greek let- ters I?, iI,. . . . For any finite theory l?, we use Ar and VI’ to denote the conjunction and disjunction respec- tively, of all the formulas in I’. The semantic notions of satisfiability, entailment (b) and equivalence (E) are defined as usual [Mendelson, 19641. For any theory I’, we use lits(r) to denote the set of all literals that occur in I’; facts(r) to denote the set of all facts in I’; and nf(l?) to denote the set of all non-facts in I’, i.e., the set (I’ - facts(r)). As usual, a singleton set ($1 is often abbreviated as +. Propositional Fact Propagation Propositional fact propagation is a method for infer- ring some facts that are logically entailed by a propo- sitional theory. Intuitively, PFP first infers facts from the simplest sub-formulas in the theory, and then uses 3We do not lose any generality due to this syntactic restriction, since any formula also involving 1 (negation) and + (implication) can be transformed efficiently into this syntax, without any significant increase in the size of the formula. them to infer facts from the more complex formulas that contain these sub-formulas. Whenever possible, it simplifies the sub-formulas by propagating the facts inferred from them. Consider the formula, 4 = QV(PA(-PVQ)). Since fact P can be inferred from the sub-formula (PA(lPV Q)), it can be simplified to obtain (P A Q). Since fact Q can now be inferred from both the disjuncts of the simplified $, it can also be inferred from II,. Further simplifying II) leads to a logically equivalent formula Q. The intuitions used in this example are formalized below. Facts can be inferred from a formula in two ways. A fact p can be conjunctively inferred from a formula II, iff there is a formula 0 such that 11) is logically equivalent to pAa. Similarly, a fact p can be disjunctively inferred from a formula $ iff there is a formula u such that $ is logically equivalent to p V 6. If follows that a fact p can be conjunctively (or disjunctively) inferred from a formula 4 iff 7(1 + p (p b $). Thus, in either case, the general problem of determining the set of facts that can be inferred from a particular formula is CoNP-Complete. However, a subset of these facts can be tractably determined using the following recursive definitions of C and D: 1. for any literal p, C(p) = D(p) = {p); 2. for any conjunctive formula, $ = u A p, W) = C(a) u C(P), and D($) = D(o) I-I II(p); 3. for any disjunctive formula, $ = u V ~1, W) = C(u) n C(P), and II($) = D(a) U D(k); 4. for any theory I’, C(r) = u+~ITW), and D(r) = n+ErW). The next lemma shows that the sets C and D contain conjunctively and disjunctively inferred facts, respec- tively. Lemma 1 Any fact p in C(q) (or D($)) can be con- junctively (disjunctively) inferred from the formula II,. Both kinds of inferred facts can be propagated to simplify a formula. The basic propagation step is de- fined as follows: For any formula 3, and any satisfiable set of facts A, +A is the formula obtained by simplify- ing $ after substituting each literal in A by t and its complement by f. The simplification rules are: For example, ((P V Q) A -P&p = Q. This example also shows that propagation of facts is likely to simplify a formula. The next lemma shows that propagating facts inferred from a formula does not change its logical content. Lemma 2 If a fact p con be conjunctively inferred from a formula $, then $ E p A q&,. If a fact p can be disjunctively inferred from a formula $, then $ rpVyLp* 410 Problem Solving: Constraint Satisfaction Thus, a formula can be simplified by first inferring facts from it, and then propagating them. This can be repeated until no more new facts can be inferred. This process can be recursively applied to each sub-formula. However, it suffices to propagate only conjunctively inferred facts through conjunctive sub-formulas, and disjunctively inferred facts through disjunctive sub- formulas. Special care is needed when the set of in- ferred facts is unsatisfiable. This happens when either the set contains f, or it contains a pair of complemen- tary facts. A theory I? is said to be basic inconsistent, binc(I’), iff the set facts(P) is unsatisfiable. For any formula or a theory, the function $ defined below in- fers some facts and propagates them: 1. for any literal p, f(p) = p; 2. for any conjunctive formula 4, if binc( C(9)) otherwise 3. for any disjunctive formula +, m) = { L(@ v $LD(l/i) if binc(D($)) otherwise 4. for any theory I’? fm = { &k) u ($ if binc( C( I’)) c(r) : ti E I’} otherwise It follows from Lemma 2 that any formula $ is logi- cally equivalent to f(q). S ince a theory can be viewed as a (possibly infinite) conjunctive formula, it also fol- lows that any theory I’ is logically equivalent to f(P). Now consider the following reduction rules: ti * f(N r * f(r) Intuitively, a reduction using any of these rules sub- stitutes a sub-formula (or theory) by a logically- equivalent but possibly simplified formula (theory). For any theory, a terminating sequence of reductions is such that no further non-trivial reduction, i.e., a re- duction that changes the theory, is possible. For any theory k, PI?P(P) is defined to be any theory obtained by any terminating sequence of reductions using the above two rules. Theorem P For any dKeory I?, PFP(I’) is independent of the pa&cular sequence of reductions. For any finite theory, any sequence of non-trivial reductions is of fi- nite length. As an example, consider a theory I’ consisting of only the Formula 1 given in the introduction. Let 1G, denote the conjunctive sub-formula PA((QA-tPAR)V(SAT)). Since C($J) = {P], f($) = PASAT. Let cr denote the disjunctive sub-formula (S A R) V S. Since D(O) = {S}, f(a) = S. After replacing II) by f(q) and a by f(a), the simplified theory I” is {((VVW)AS)V(PASAT)V(SA(XVW))) Since C(I”) = {S}, the theory can be further simplified to obtain f(I”), which is {S, (P AT) V V V W V X). Since, no further simplification is possible, PFP(I’) = f w* The next theorem shows that PFP preserves logical equivalence, and is modular, i.e., it can be applied to parts of a theory before applying to the entire theory. Theorem 2 For any two theories I? and A, PFP(P) 3 I’, and PFP(I’ u A) = PFP(PFP(P) u A) = PFP(PFP(P) u PFP(A)). PFP is logically incomplete, i.e., it may not infer all facts that are logically entailed by a theory. For example, although P is logically entailed by the theory {PvlQ, PvQ}, t i can’t be obtained using PFP. This example also demonstrates that the results obtained using PFP depends not only on the logical content of the theory, but also on its syntactic form. Compute-PET: An Algorithm Directly implementing the definition of PFP is likely to be quite expensive, since it would require many passes over the input MB. In this section, we sketch a tractable algorithm, called Compute-PFP, that avoids these multiple passes. [Dalal, 19921. A detailed description is given in Compute-PFP represents the given theory as a la beled tree, where each internal node is labeled by ei- ther A (conjunctive node) or V (disjunctive node), and each leaf is labeled by a literal. For instance, the theory {PvlQ, SVPVR} is represented by the tree shown in Figure 1. Whenever possible, the tree is simplified by suitably eliminating leaf nodes labeled by t or f (using the rules described in the definition of $A) and internal nodes that have only one child, and by merging pairs of parent-child nodes labeled by the same connective. The main task of Compute-PFP is identifying facts that can be inferred from the subtree rooted at any node, and then either propagating them through the subtree, or passing them to the parent node. Since the two kinds of nodes are processed similarly, we con- sider only the disjunctive nodes here. Figure 2 illus- trates the situation when a fact p can be disjunctively inferred from a disjunctive node - each node labeled bY P (01 “P) in the subtree 2’ is replaced by a node labeled by f (t), which is then suitably eliminated. Fig- ure 3 illustrates the only case (after all other simplifi- cation has been performed) when a fact p can be con- junctively inferred from a disjunctive node - the fact p is passed to the parent of the node. Compute-PFP maintains three arrays and a counter with each internal node N: N.max keeps a count of the number of children of N; for any literal p, N.occur[p] is a list of all children S of N such that the subtree rooted at S contains a node labeled by p; N.countb] keeps a count of the number of nodes la- beled by pin the subtree rooted at N; while Ndepthb] is the sum of distances of all these nodes from N. The Dalal 411 Figure 1: A labeled tree Figure 2: Fact propagation Figure 3: Computing C($) arrays N.occur are used to access all occurrences of a literal in a sub-formula. This is required in propagat- ing a fact p while computing f($) for some sub-formula 4. All the other information is used for quick detection of whether a fact is in C(4) (or D(+)) for a disjunc- tive (conjunctive) formula $. For instance, in Figure 3 there are exactly N.max (= n) occurrences of nodes la- beled by p, each at a distance 2 from N, in the subtree rooted at N. Thus, the necessary and sufficient con- ditions to detect such a case are N.count[P1 = N.max and N.depth[p] = 2 x N.max. Given a theory P, let n be its size, m be the number of distinct symbols in it, and (X: - 1) be the maximum number of alternations of connectives in the formu- las of the theory. Initially, the tree has O(n) nodes, each requiring O(m) space to store the various arrays. Thus, the total size of the tree is O(nm). However, only O(nk) space is actively used, and the tree can be built in O(nlc) time (using a random-access model of computation). Each simplification step either removes at least one node of the tree, or replaces a literal p by a constant t or f. Since there are n nodes to begin with, there can be at most O(n) such simplification steps. Each simplification step may require travers- ing a branch, and can take at most O(k) time. Thus, Compute-PFP takes at most O(nk) time and at most O(nm) space in total. Theorem 3 For any theory I’ of size n with at most (k - 1) alternations of connectives, Compute-PFP terminates in time O(nk). q Note that I% is usually a very small number. For example, L = P for a theory in either conjunctive or disjunctive normal form. Thus, the worst-case time complexity is quite close to linear. In [Dalal, 19921, we show that it is possible to reduce the space complexity to O(n Iog(m)) by increasing the time complexity to O(nk log(m)). Tractable Entailment Using PFP The general problem of determining whether a given theory logically entails a given formula is CoNP- Complete. Various attempts have been made to de- fine weak entailment relations that are tractable (cf. [Levesque, 1984a]). In this section, we use PFP for defining a new weak but tractable entailment relation that is more powerful and efficient than these previous ones. 412 Problem Solving: Constraint SatiSfaCtbn Let I’ be any theory and 4 be any formula. It is known that I? /= $ iff P U {+} is unsatisfiable. This result can be used to define a weak entailment rela- tion from any sufficient condition for unsatisfiability. In particular, the weak entailment relation b is de- fined as follows: I’ k II) iff PFP(I’U{+)) = {f).4 This intuitively means that PFP is able to determine incon- sistency of r U (1~)). S ome properties and examples of )- are listed below: Soundness: k is logically sound, i.e., if I’ b $ then r I=+ Pncomplet eness: )- is logically incomplete. For example, although (4) k $ for any formula ti9 if 4 = (Q V b) A (c V &) then (ti) & $J~ However, PFP is complete for certain restricted classes of theories and formulas. For instance, if I’ contains only Horn clauses and II) is a conjunctive formula, then I’ b II, iff I’ k 4. Monotonicity: k is monotonic, i.e., if I’ k II, and P C I”, then I” k $. It also conforms to some truth- functional properties of the two connectives. For in- stance, if I’ k + A CT, then I’ k $, and I’ k o. Also, if either I’ k 4 or I’ k 0, then I’ k + V CT. However, the contrapositive of the above two properties, which hold for b, do not hold for f- . Chaining: k 11 a ows some simple chaining, for in- stance, {P, 1P V Q} k Q. It also allows slightly more complex chaining, for instance, (1.P V Q, -IQ V R}+PvR. Syntactic Dependence: k depends on the syn- tactic form of the formulas. For instance, although the theories {P, Q V R} and {PVQ, PVlQ, QVR) are logically equivalent, only the former entails P using l-0 H owever , k is independent of some of the finer nuances of syntax - for instance, changing the order of formulas in the theory, or reordering the arguments of a connective. Tractability: The algorithm Compute-PFP can be used to determine k . Given a theory I’ of size n and at most (k - 1) alternations of connectives, and ‘Since PFP requires the input theory to be in NNF, the negation in front of $ should be first pushed all the way inside to atomic propositions. a formula $ of size Q and at most (T - 1) alterna- tions of connectives, Compute-PFP can determine in O(nk: + qr) time whether I’ b $. PFP can also be used to define another weak entail- ment b’. Recall that for any theory I’, PFP(I’) is a subset of facts that can be logically inferred from I’. If these facts are sufficient to make a formula $ true, then 4 can be logically inferred from I’. Thus, k ’ is defined as follows: for any theory I’ and formula 4, r t- “$ iff $facts(pFY(r)) = t* It follows that b ’ is sound, incomplete, monotonic, and depends on the syntactic form of the formulas. Although it can perform some simple chaining, for in- stance, {P, 1P V Q} b ‘Q, it can’t perform the more complex ones, for instance, (~Pv Q, 1Q V R) p ‘1PV R. For any theory P and formula $, if P b ‘4, then I’ b $3. Hence, the new relation b ’ is strictly weaker than k. If PFP(I’) is pre-computed and stored suit- ably such that any fact can be retrieved from it in con- stant time, then k ’ can be determined in only O(Q~) time, which is independent of the size of I’. Thus, k ’ can be determined more efficiently than )- . glications and Our problem is closely related to the problem of opti- mizing a boolean circuit or expression, which has been studied for many years (c.f. [Birkhoff and Bartee, 1970; Chen et al., 19911). H owever, the goals there are quite different from ours. For instance, there it is more im- portant to minimize the size (or delay, etc.) of the resulting circuit, or to obtain a canonical form (like CNF) even at the cost of using a more expensive ap- proach. Moreover, the optimizations there make use of don’t-cares, specific technology used to realize the circuit, etc. - issues that are not relevant for our purposes. Logical truth maintenance systems [Reiter and de Kleer, 1987; de Kleer, 19$6] perform limited deduc- tive reasoning from the set of formulas given to them. Most implementations of a Logical TMS use BCP to infer facts [McAllester, 19901. Given a theory Pg BCP monotonically expands it by adding facts as follows. In each step, if any single formula in P and all the facts in P‘ taken together logically entails any other fact, then the new fact is added to the theory I’. This step is repeated until no new fact can be so obtained, or the theory I’ becomes basic inconsistent.5 Given any clause and any set of facts, it is easy to determine any new facts that can be inferred. Thus, “In the T&IS literature (c.f. [de Kleer, 1990]), a distinc- tion is usually made between the facts (called assumptions) and the other formulas (called constraints) in the theory. Wowever, this distinction does not effect the results ob- tained using BCP. clausal BCP, which is BCP restricted to clauses, is tractable. Since the general problem of determining facts that can be inferred from an arbitrary formula is intractable, formula BCP, which is the unrestricted BCP, is inherently intractable. de Kleer [1990] sug- gests two techniques for using clausal BCP for theo- ries containing arbitrary formulas. In one, CNF-BCP, the formulas are first converted into CNF; and in the other, Prime-BCP, clausal BCP is applied to the prime implicants [Reiter and de Kleer, 19871 of each for- mula. Since computing prime implicants is itself an intractable problem, Prime-BCP is also inherently in- tractable. If no new symbols are added, then conversion to CNF may increase the size of the given theory expo- nentially. But conversion to CNF can be done in linear time and space by adding new symbols, each represent- ing a sub-formula of the theory [Cook, 19711. However, with either kind of conversion, CNF-BCP is strictly weaker than PFP, as shown in the next theorem (and the first example in the introduction). Theorem 4 For any theory I’, either PFP(I’) = (f} or facts(BCP(CNF(P))) C facts(PFP(P)). The above theorem and the tractability of Compute-PFP makes PFP an attractive technique for reasoning in TMS and other AI applications. Explicit Belief and Tractable Respondin to the problem of logical omniscience [Hin- tikka, 1975 , Levesque [1984b] introduces a semantic 9 notion of explicit belief, which is the set of beliefs that a resource-limited agent can infer from its implicit beliefs.6 This notion of explicit belief does not allow any chaining, i.e., an agent who explicitly believes in P and -P V Q may not believe in Q. The next theorem (and the observation that k allows some chaining) shows that the entailment k based on PFP is more powerful than the notion of explicit belief. Theorem 5 If belief in I? leads to an explicit belief in $, then I’ )- 4. The entailment relation k is also computationally less expensive, since it takes O(nq) time to determine whether a formula of size q can be explicitly believed, given a theory of size n [Levesque, 1984b]. Note also that computing explicit beliefs is known to be tractable only if all the formulas are in CNF, something not re- quired by k . Thus, the weak entailment relation, )- , presented in this paper is a significant improvement over the notion of explicit belief. E&Sent Query Answering Querying is an important function that should be pro- vided by any KB [Levesque, 1984a]. Let Ask(I’, $) be “Eater, Frisch [1987] developed a different but equivalent model theory. Dalal 413 the answer returned by the knowledge- query +. It is traditionally defined as: base I’ to the “yes” ifP++ Ask& $) = “no” if I? /= + “unknown” otherwise Reliance on k makes Ask intractable even for propo- sitional KBs. However, Ask can be made tractable by using a different entailment relation. We propose that the weak but tractable entailment relation k be used instead. Let Ask’ be the function obtained after re- placing b by b in the definition of Ask. Apart from the linear time worst-case complexity of k , there is an additional advantage due to the mod- ularity of PFP. If the KB does not change very often, then PFP(I’) can be computed once and then used for many different queries. Thus, the cost of PFP(I’) is amortized over many queries, further reducing the ac- tual time taken to answer each of them. Conclusions We presented PFP, which is an efficient method for inferring facts from a propositional knowledge base. Though it is logically-incomplete, it does not require the knowledge base to be in CNF, and is more pow- erful and efficient than CNF-BCP. We also presented an algorithm, Compute-PFP, whose worst-case time complexity is linear in the product of the size of the knowledge base and the maximum number of alterna, tions of connectives. We also used PFP to define two notions of weak but tractable entailment, and analyzed some of their properties. PFP has some limitations. Firstly, it is quite weak in some cases. For instance, it does not infer the fact P from the theory (PV&, PVYQ).~ Secondly, it lacks a model theory that provides an independent charac- terization. It seems that the PFP can be extended to logics with quantifiers and modality. It also seems possible to strengthen propagation while maintaining efficiency and the other properties, by limited use of case analy- sis. There is also a possibility of getting stronger prop- agation rules, that are still tractable. Our current re- search is directed towards realizing these possibilities. We are also in the process of implementing PFP, and testing its performance on large and realistic theories. PFP appears to be the first tractable fact propa gation technique that does not require converting for- mulas to CNF. We believe that PFP is likely to have significant applications in TMS and other similar AI systems, in modeling the beliefs of resource-limited agents, and in efficiently answering queries posed to a knowledge base. 7Note that both BCP and and the notion of explicit belief a9so suffer from this weakness. I would like to thank Alex Borgida, David Ethering- ton, Hari Hampapuram, Ringo Ling, Kumar Vada party, Ke-Thia Yao, Haym Hirsh and Kerstin Voigt for helpful discussions and comments on the earlier drafts of this paper. I also wish to thank AT&T Bell Labo- ratories for partial support during this research. eferences Birkhoff, G. and Bartee, T.C. 1970. Modern Applied Algebra. McGraw-Hill, New York. Chang, C. and Lee, R.C. 1973. Symbolic Logic and M’echanical Theorem Proving. Academic Press, Lon- don. Chen, K.-C.; Matsunaga, Y.; Fujita, M.; and Muroga, S. 1991. A resynthesis approach for network opti- mization. In Proceedings 28th ACM/IEEE Design Automation Conference. 458-463. Cook, S.A. 1971. The complexity of theorem prov- ing procedures. In Proceedings Third Annual ACM Symposium on the Theory of Computing. 151-158. Dalal, M. 1992. Fact propagation functions. In prepa- ration. de Kleer, J. 1986. An assumption-based truth main- tenance system. Artificial Intelligence 28:127-162. de Kleer, J. 1990. Exploiting locality in a TMS. In Proceedings Eight National Conference on Artificial Intelligence (AAAI-90). 264-271. Frisch, A.M. 1987. Inference without chaining. In Proceedings Tenth International Joint Conference on Artificial Intelligence (IJCAI-87). 515-519. Garey, M. and Johnson, D. 1979. Computers and Intractability: A Guide to the Theory of NP- Completeness. Freeman, W. H., NY. Hintikka, J. 1975. Impossible possible worlds vindi- cated. Journal of Philosophical Logic 4:475-484. Levesque, H.J. 1984a. Foundations of a functional approach to knowledge representation. Artificial In- telligence 23(2):155-212. Levesque, H.J. 1984b. A logic of implicit and explicit belief. Proceedings National Conference on Artificial Intelligence (AAAI-84) 198-202. McAllester, 19. 1980. An outlook on truth mainte- nance. Memo 551, MIT AI Lab. McAllester, D. 1990. Truth maintenance. In Proceed- ings Eight National Conference on Artificial Intelli- gence (AAAI-00). 1109-1116. Mendelson, E. 1964. Introduction to Mathematical Logic. Van Nostrand, Princeton, N.J. Reiter, R. and de Kleer, J. 1987. Foundations of assumption-based truth maintenance systems: Pre- liminary report. In Proceedings Sixth National Con- ference on Artificial Intelligence (AAAI-87). 183-188. 414 Problem Solving: Constraint Satisfaction | 1992 | 74 |
1,270 | Hewlett-Packard Laboratories, Filton Road, Stoke Gifford, Bristol ~~12 ~QZ, U.K. njh@hpl.hp.co.uk Abstract This paper investigates a problem of natural lan- guage processing from the perspective of reasoning work on constraint satisfaction. We formulate the task of computing singular, definite reference to a known contextual entity as a constraint satis- faction problem. We argue that such referential constraint problems have a structure which is of- ten simpler than the general case, and can there- fore often be solved by the sole use of low-power network consistency techniques. To illustrate, we define a linguistic fragment which provably gen- erates tree-structured constraint problems. This enables us to conclude that the limited operation of strong arc consistency is sufficient to resolve the class of noun phrase defined by the fragment. Introduction This paper investigates the computational problem of semantic evaluation in natural language processing. We consider the sub-problem of finding values for se- mantic variables, focussing on the task of computing singular, definite reference to a known contextual en- tity, as required for noun phrases like the green cup on the table. It is common to formulate this reference task as a constraint satisfaction problem (CSP). Many models of language processing then employ a full search algorithm, such as backtrack search, to solve the CSP and hence resolve the reference (e.g. Winograd, 1972). Backtrack search systematically explores the space of all solutions and will resolve general CSPs, in exponen- tial time. However, one suspects that natural language reference problems have a special modular structure which makes them simpler than general CSPs. If this is true, then, from a theoretical point of view, it is desirable to find a resolution strategy which more ac- curately models the linguistic problem in hand. Con- straint network consistency (Mackworth, 1977a) is a possible candidate for this strategy, since it offers a set of consistency-checking operations of varying power.’ The present paper starts by reviewing the CSP for- mulation of noun phrase reference, and the network consistency approach to CSPs. The aim of this paper is to show, through a small linguistic fragment, how we may ascertain the structure of referential constraint problems from the semantic translation rules which de- rive them. In this case, this allows us to infer that an extremely limited set of network consistency opera- tions are sufficient to resolve noun phrases interpreted by this fragment. We then consider this approach in the light of broader problems of semantic evaluation. eference as a Constraint Satisfaction roblem Mackworth (1977a) defines a constraint satisfaction problem (CSP) as a set of variables, each of which must be instantiated in a particular domain of values, and a set of constraints which the values of the variables must simultaneously satisfy. A CSP can be schematised as the formula in (1) (1) (34(322) * - * (ha) (Xl E &)(x2 (5 02) - * * (% E az) JyW~2,...,4 in which each variable xi is associated with a do- main Da, and where P(xi , x2, . . . , x~) abbreviates a conjunction of constraints on subsets of the vari- ables. A solution to a CSP is an assignment of values <al,a2,..., a,> E D1 x 02 x . . . D, to the variables <~l,X2,**-, x,> which simultaneously satisfies all the constraints. In order to characterise the problem of contextual reference, we must also define a notion of context. For the present purposes, we will adopt a simplified view of context, and represent the hearer’s contextual knowl- edge as a finite set of first-order predications, such as the following: ‘Barton, Ber w ck and Ristad (1987) make a parallel ar- i gument for morphological analysis. Haddock 415 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. (2) (man(manl), man(man2), man(man3), town(townl), town(town2), river(riverl), near(townl,riverl), visit(manl,townl), visit(man2,townl), visit(man2,town2)) For example, the context in (2) indicates that there are three men, two towns and one river, that man1 visits townl, and so on. Consider the problem of determining the contextual entities involved in the reference of the following in- definite noun phrase (assuming that the prepositional phrase near the river relates to the town), given the knowledge in (2): (3) a man who visits the town near the river The reference problem breaks into two parts: finding contextual values, and checking uniqueness where ap- propriate. The first part can be succinctly expressed as a CSP in the style of (1):2 (4) (3X192,x3)(x1 E 4)(x2 E 02)(x3 E D3) man(a) A visit(xl, x2) A town(x2) A near(x2, x3) A river(x3) In words, there exists an xi, x2, and x3, in speci- fied domains, such that xi is a man, 22 is a town and x3 is a river, and x1 visits x2, and 22 is near x3. We will assume that all variables in our reference- oriented CSPs start out with the same value do- main, namely the set of all entities in the context. So, in the context of (2), D1 = 02 = D3 = (manl, man2, man& townl, town2, riverl). Satisfac- tion of the formula in (4) will involve assigning x1, 22 and x3 values from this set, and seeing whether the in- stantiated constraints coincide with the formulae in the context. The second aspect of (3) concerns the presup- posed uniqueness of the town and the river. Unique- ness can be expressed as a meta-level check on the re- sults of constraint satisfaction, and we one such formulation later in the paper. will introduce Constraint Network Consistency The network consistency approach to CSPs has been discussed extensively in the literature (Mackworth, 1987; Dechter, 1991). Consistency algorithms do not engage in full search, and will only partially solve a CSP. Network consistency algorithms view the CSP as an annotated graph known as a constraint network, where each variable xi is represented as a vertex i, a unary constraint p(xi) is represented as a loop on the vertex i, and a binary constraint P(x;, xi) is rep- resented as an edge between i and j. (For present 20ur treatment of the global, indefinite NP as a non- specific reference to a known contextual entity is highly simplified, of course, and is included here for expository reasons only. visit near Figure 1: Constraint network. purposes, we will also use the term constraint graph to describe this representation.) Figure 1 shows the con- straint network for (4) ( omitting unary constraints). Various degrees of consistency can be defined in a constraint network, including node consistency and arc consistency (Mackworth, 1977a). A node i is node con- sistent if every value in its domain satisfies its con- straining unary predicate. An arc(i,j) is arc consistent if for every value in the domain Da there is at least one value in Dj such that the pair of values satisfy the con- straining binary predicate. (Since arc consistency is a directed notion, the arc consistency of edge(i,j) implies the consistency of arc(i,j) and arc(j,i).) A constraint network is node (arc) consistent if each of its nodes (arcs) is consistent. We say a constraint network is strongly arc consistent if it is node and arc consistent. A constraint network can be made node and arc con- sistent by a progressive operation of domain refine- ment, which removes values from domains until the consistency conditions hold. Assuming the context of (2), the network for (4) could be made could be made strongly arc consistent by an algorithm such as Mack- worth’s (1977a) AC-3, which propagates domain re- finement operations around the network. This would return the following refined domains: D1 = {manl, man2), D2 = {townl}, D3 = {riverl} The strongly arc consistent network allows us to infer that the set of solutions to the CSP is some subset of the cross-product of the refined domains. Strong arc consistency does not, in itself, guarantee that any solu- tions exist. Network consistency techniques are often used to reduce the search space posed by a CSP before the invocation of a search procedure, like backtracking, to find the exact set of solutions, which may be empty. However, an interesting and important characteris- tic of the reference problem is that the felicity of a definite NP can be determined without computing the actual tuples of values which solve its constraint prob- lem. All we require is that the procedure for reference evaluation is capable of associating each variable in the constraint problem with a set of entities, such that ev- ery entity in each variable’s set participates in some solution to the problem. The referential uniqueness of a variable in a CSP can then be confirmed by a sim- ple, meta-level check that its domain is a singleton set. In view of this requirement, we borrow the following definition from Dechter et al. (1989): 416 Problem Solving: Constraint Satisfaction Definition 1 A value a in a domain Di is feasible if there exists a solution to the constraint problem in which the variable xi is instantiated to a. The set of feasible values of a variable is its minimal domain. Under what circumstances does network consistency guarantee minimal domains? The degree of net- work consistency required for minimal domains can be shown to depend on the connective structure of the constraint graph (Montanari, 1974; Freuder, 1982). An instance of this relationship concerns tree-structured networks: Theorem 1 (Montanari, 1974; Freuder, 1982) The domains of a constraint network are minimal if the network is a tree and it is strongly arc consistent. There is a high premium on a CSP having a tree- structured constraint graph, since strong arc consis- tency can be achieved in O(a2n), where n is the num- ber of variables, and a is the size of each initial value domain (Dechter and Pearl, 1988). Moreover, unlike higher degrees of consistency, node and arc consistency can be achieved without changing the structure of the constraint graph. Hence, the application of a strong arc consistency algorithm to a tree-structured network will always yield minimal domains. Tree-Structured Fragment We now introduce an illustrative linguistic fragment which provably generates only tree-structured seman- tic forms. In common with many natural language systems, our fragment adopts a syntax-driven, com- positional style of semantic translation (Schubert and Pelletier, 1982). All constituents are associated with a four-part representation, comprising (1) a syntactic category, (2) a semantic variable, or tuple of variables, (3) a list of constraints (the constraint list), and (4) a list of meta-level conditions on the cardinalities of specified domains (the curdinulity list). For example, the lexicon contains the following entry for lake: (5) lake := N, : [lake(x)] : [] This entry defines (“:=” ) lake as a noun (N) associated with the semantic variable x, notated as a subscript. The word is associated with the single unary constraint l&e(x), and does not introduce any cardinality condi- tions. Square brackets are used to indicate lists, as in Prolog, and a list of more than one constraint should be read as a conjunction of constraints. All variables in a constraint list are assumed to be existentially quan- tified, and, moreover, all variables appearing in the representation of a constituent are local to that con- stituent. A preposition is defined in a similar manner: (6) near := P<G,y> : bedx, Y)] : [I Thus, the preposition near introduces the binary con- straint near(x, y) and, again, no cardinality conditions. However, in contrast to (5), the constituent is rela- tional. We therefore attach the tuple <x, y> to its syn- tactic category, P, where x associates with the prepo- sitional subject and v with the prepositional object. In order to illustrate a syntactic-semantic rule, as- sume that the rule set has already analysed the definite NP the lake as follows: (7) the lake := NP, : [lake(x)] : [ID,1 = I] Hence, the lake has been analysed as an NP associated with the variable x, the constraint lake(x), and the cardinality condition that the domain of x should be a singleton, ID,. 1 = 1. The PP near the lake can now be analysed by the following augmented phrase-structure rule: (8) PP, : (Cl + C2) : (Sl + S2) - P <z,y> : Cl : 5’1 NP, : 62 : S2 where {y = z} The rule in (8) combines a preposition with an NP on its right to form a PP. The constraint list of the PP constituent is formed by appending the constraint lists of its two subconstituents, Cl and C2; we notate this operation as Ci + C2. The same operation is per- formed on the subconstituents’ cardinality lists, 5’1 and 5’2. The rule above can thus be seen as conjoining two separate CSPs to form a larger, composite CSP. By it- self this operation will produce no variable-connections between the component CSPs. The responsibility for connective structure depends solely on the manner in which the rule manipulates the semantic variables sub- scripted on syntactic categories. In (8), the rule unifies the variable associated with the prepositional object with the variable associated with the NP. For clarity, we extract all such variable unifications to the right, in the form of a where-clause.3 Hence, the application of (8) to the constituents defined in (6) and (7) yields the following representation for the PP, (9) near the lake := PP, : [neur(x, y), lake(y)] : [IDy I = 11 in which the variable y from (6) has been unified with the variable x from (7), and is now named y. Figure 2 presents the complete fragment of aug- mented phrase-structure rules, and example lexical en- tries. The fragment, N PGl, treats simple examples of adjectival modification, and complex NPs involving subject relative clauses and PPs. Two example NP analyses are given below: 3A more corn mon practice is to encode such term unifi- cations directly into the rule (Pereira and Shieber, 1987). However, in the present circumstances this would be some- what opaque. Haddock 417 Rules NP, : (cl + C2) : (5’1 + 2%) - Det, : Cl : 5’1 N, : C2 : 5’2 where (z = y} N, : (Cl + C2) : (Sl + S2) - Adj, : Cl : S1 N, : c2 : s2 where {z = y} N, : (Cl + Cz) : (Sl + S2) - N, :c1:s1 PP, : c2:s2 where {z = y) NE : (Cl + C2) : (SI + S2) - N, : Cl : Sl REL, : c2 : s2 where {z = y} pp, : (cl + C2) : (Sl + 5’2) - P<z,y> : 61 : S1 NP, : C2 : 5’2 where {y = z} REL, : . : (Cl 7 C2) 1 (Sl s S2) = V<r,y> who VP, : c:s where {} VP, :Cl:S1 NP, : C2:S2 where {y = z} Sample Lexical Entries Jake := N, : [rake(z)] : [] near := P<z,y> : [near@, dl : [I green := Adj, : [green(x)] : [] visit := v<s,g> : [visit(x, y)] : [] the := Det, : [] : [IDsI = 11 Figure 2: The fragment NPGl. (10) a the man who bought the book NP, : [man(x), bw(x, Y), book(y)] : [IDsI = LlDyl = 11 b the green cup on the table NP, : [green(x), cw(x:), on@, y), table(y)] : [I&l = 1, lDyl = 11 The fact that our fragment NPGl generates only CSPs with tree-like constraint graphs hinges on the na- ture of the unifications performed in the where-clauses. First, we observe a fact which can be informally stated as follows: Lemma 1 If G’ and G” are trees, then the graph which results from unifying a single vertex u E V(G’) with a single vertex v E V(G”) is also a tree. This follows straightforwardly from the fact that a tree is a connected graph with IV( - 1 edges, where IV1 is the number of vertices. We can now state our theorem about N PGl: Theorem 2 The constraint lists generated by the lin- guistic fragment NPGl are tree-like. SKETCH PROOF. Theorem 2 can be proven from the following observations: (a) all lexical entries have tree- like constraint lists; (b) semantic variables are local to each lexical entry, and to each rule; and (c) each rule unifies at most one variable from its left-hand daughter with one variable from its right-hand daughter, and hence preserves tree-structure, by Lemma 1.0 Once the NP has been analysed, its constraint list can be transformed into a network and subjected to strong arc consistency. Once the network is consistent, the cardinality conditions are evaluated with respect to the refined domains. From Theorem 2 and Theorem 1, these domains are necessarily minimal. Hence: 418 Problem Solving: Constraint Satisfaction Corollary 1 Noun phrases interpreted by the frag- ment NPGl can be resolved by strong arc consistency. If either the consistency or the cardinality-checking phase should fail, the NP is rejected as infelicitous, an action which can help resolve structural ambigui- ties encountered by the syntactic parser.4 Since full node and arc consistency can be achieved in O(a2e), where e is the total number of constraints in the CSP (Dechter and Pearl, 1988), and given that it is easy to check if a set is a singleton, our NPs are re- solvable in the worst-case time of O(a2e). Thus for our fragment, evaluation time is linear in the linguistically generative parameter of semantic predicates. iscussion In the previous section we specified a set of syntactic- semantic rules with similar coverage to the kind of il- lustrative grammar fragment found in an introductory textbook on NLP, such as Pereira and Shieber (1987). We proved that it can only generate tree-structured CSPs, and in doing so demonstrated that the topol- ogy of the resulting constraint graph can be deduced, in part, from the nature of the compositional rules of semantic translation. This example raises a number of questions. Most importantly, what proportion of English semantic ex- pressions have such a tree-structured form? This is of course a difficult question to answer, given that we do not have a complete semantic account of the lan- ‘Haddock (1988, 1989) p rovides an implementation of a scheme of semantics similar to NPGl, and shows how Mack- worth’s (1977b) algorithm NC can be adapted to incre- mentally refine domains during categorial grammar pars- ing. This form of incremental semantic evaluation is used to interactively resolve syntactic ambiguities in the manner described. guage. Nevertheless, for those semantic structures that are readily treated as a conjunction of first-order pred- icates, we offer the tentative suggestion that there is a tendency towards tree-structure. As we have seen, simple nouns, and intersective adjectives such as red, translate into unary constraints; prepositions corre- spond to binary constraints, and verbs to n-ary con- straints, where n 2 1. Moreover, in the deep structure of the language, these semantic predicates tend to be strung together in a linear, sparse fashion. As further examples, (11) shows a constraint list representation for two other classes of expression, not covered by our simple fragment (assuming that proper names trans- late into constants, written in bold). (11) a Bill’s terminal [terminal(x), belonging-to(x, bill)] b the poster Bill designed in May [poster(x), design(e, bill, x), inAme(e, may)] In (lla), the possessive relates the variable x, for the terminal, to the constant bill via a binary predicate we have arbitrarily called belonging-to. (llb) adopts a Davidsonian treatment of event modification in which the temporal PP in May translates as a binary pred- icate in-time attached to an event-variable argument e of the predicate design. In both cases, the contraint graphs are trees. This is not to say that the first-order semantics of English is entirely tree-structured. Cycles may be in- troduced on at least three distinct levels of semantic interpretation. Here we give one example at each level, although these are not the only instances. First, at the lexical level, it is common to decompose lexical pred- icates into finer-grained predicates which correspond to the underlying knowledge representation. At least in principle, these sub-linguistic constraints may have an arbitrary connective structure. To take a simple example, the lexical constraint over(x, y) may map into above(x, y) A lcontact(x, y), which is cyclic (al- beit simple to eliminate). Second, at the structural level, certain syntactic-semantic rules can induce a kind of “double-binding” in the semantic translations. This occurs in the noun phrase in (12), for example, which contains what Engdahl (1983) calls a “parasitic gap” . (12) an apple which a man ate without peeling [event(xl), mm(x2), appk(xs), eat(xl, z273), wit houtpeeling(xl , x3)] So there exists an event x1 in which a man 52 eats an apple 2s and, furthermore, the event 51 is car- ried out without peeling the apple 23. It is not dif- ficult to devise contexts for this CSP which would thwart an appropriate strong arc consistency algorithm (such as Mackworth’s (197713) algorithm for n-ary con- straints), since the graph contains a cycle along the path (xr,xs,21). Finally, at the anaphoric level. Con- sider the indefinite NP in (13): (13) a man who visits a town near his birth-place [man(xl), visit(xl, x2), town(x2), nec+2, x3), birthpZace(x3, xl)] On the assumption that (13) refers non-specifically to some man known to the hearer, and depending on the state of the discourse, the possessive pronoun his may refer either to some male entity salient in the hearer’s discourse model or be bound to the reference of the entire complex noun phrase in which it is em- bedded. In the latter case it becomes an instance of what Partee (1978) and others have called “bound- variable anaphora” . To see why, consider the con- straint list translation for the bound-variable interpre- tation. Here, a man x1 visits a town 22 which is near the birthplace x3 of the man x1, whoever he is; the variable representing the reference of the male person whose birthplace it is has been bound to the variable representing the reference of a man who visits . . . . thus creating a cycle. That cyclic CSPs appear to be present in semantics is not in itself a problem. We simply need to make sure that we employ a stronger form of network con- sistency, in accordance with the complexity of the con- straint graph. For example, Freuder’s (1982) measure of graphical complexity (width) allows us to deduce that the CSP in (13) must be resolved by path con- sistency. Whereas arc consistency ensures that each node is consistent with any neighbouring node, path consistency is one degree stronger: it ensures that any consistent solution to a pair of variables is consistent with any third variable. 5 In principal it is possible to envisage a “lazy” semantic evaluator which knows just how much effort to put into the constraint problem it is given; however, we leave this as an avenue for further investigation.6 It is anticipated that the most immediate limitation of our general approach is the rigid view of logical form imposed by strict adherence to the definition of a CSP. The CSP paradigm does not straightforwardly admit quantified sentences such as Each man loved at least 5Freuder (1978) generalises these specific forms of con- sistency as 6consistency, where node, arc and path consis- tency correspond to i = 1,2,3, respectively. &consistency for i = n - 1 (where n is the number of variables) is as powerful as a full search procedure. ‘Here further work is also necessary to determine if cyclic linguistic representations fall into a well-defined topo- logical class, such as the K-tree (Freuder, 1991). Note that Ristad (1990) has argued that the bound-variable anaphora problem is NP-complete. Haddock 419 two women or a treatment of plural reference. Fur- thermore, intensional expressions abound in natural language semantics. For example, a standard repre- sentation of John believes that Mary loves Bill applies believe to the constant john and the proposition that Mary loves Bill: believe(john, Zove(mary, bill)) Given that the embedded sentence may be arbitrarily complex, such logical forms take us beyond the sim- ple relations assumed in network consistency. Exam- ples such as these show that further work is required in the borderland between natural language semantics and constraint network theory. Related Work and Conclusion Network consistency techniques have previously been applied to a variety of problems in natural language processing, including morphological analysis (Barton, Berwick and Ristad, 1987), form-class disambiguation @fly> 1986), P arsing (Maruyama, 1990), and word- sense disambiguation (Winston, 1984). Mellish (1985), Haddock (1988, 1989), and others have used network consistency to tackle various aspects of reference eval- uation. The published accounts of these investigations rarely discuss the issue of the sufficiency of network consis- tency for the task in hand. However, Mellish and Bar- ton et al do raise the question of adequacy, and both make the empirical observation that their network con- sistency algorithm seems to be adequate in their prob- lem arena (in both cases, approximate forms of strong arc consistency are used). Barton et al further hy- pothesise that natural-language problems may have a special modular, separable nature which makes them amenable to such techniques, but in neither case is the discussion related to a formal notion of adequacy, such as that provided by Freuder (1982). Against this background, the main development re- ported in this paper is a linguistic formulation for which we can prove the sufficiency of low-power net- work consistency techniques. This result has theoreti- cal significance, since it adds weight to Barton et al’s earlier suggestion that network consistency is a linguis- tically appropriate process of reasoning. Acknowledgements I am grateful to Kave Eshghi, Eugene Freuder and Martin Sadler for discussions about this work. References Barton, G. E., Berwick, R. C. and Ristad, E. S. (1987) Computatational Complexity and Natural Language. Cam- bridge, Mass.: MIT Press. Dechter, R. and Pearl, J. (1988) Network-Based Heuristics for Constraint-Satisfaction Problems. Artificial Intelli- gence, 34, l-38. Dechter, R., Meiri, I., and Pearl, J. (1989) Temporal Con- straint Networks. In Proceedings of the Fkst Interna- tional Conference on Principles of Knowledge Represen- tatdon and Reasoning, Toronto, Canada, pp.83-93. Dechter, R. (1991) Constraint Networks. In Shapiro, S. (ed) The Encycloped ia of Artifical Intelligence, 2nd edi- tion. John Wiley and Sons. Duffy, G. (1986) Categorial Disambiguation. In Proceed- ings of the 5th Annual Meeting of the American As- sociation for Artificial Intelligence, Philadelphia, Pa., pp.1079-1082. Engdahl, E. (1983) Parasitic Gaps. Linguistics and Phi- losophy, 6, 5-34. Freuder, E. C. (1978) Synthesising Constraint Expressions. Communications of the ACM, 21, 958-966. Freuder, E. C. (1982) A S ffi u cient Condition for Backtrack- Free Search. Journal of the ACM, 19, 24-32. Freuder, E. C. (1991) Completable Representations of Con- straint Satisfaction Problems. In Proceedings of the Sec- ond International Conference on Principles of Knowl- edge Representation and Reasoning. Haddock, N. J. (1988) I ncremental Semantics and Interac- tive Syntactic Processing. Unpublished Ph.D. Thesis, Dept. of AI and Centre for Cognitive Science, Univer- sity of Edinburgh. Haddock, N. J. (1989) Computational Models of Incremen- tal Semantic Interpretation. Language and Cognitive Processes, 4, 337-368. Mackworth, A. K. (1977a) Consistency in Network of Re- lations. Artificial Intelligence, 8, 99-118. Mackworth, A. K. (1977b) On Reading Sketch Maps. In Proceedings of the Fifth International Joint Conference on Artifical Intelligence, MIT, Cambridge, Mass., pp.598- 606. Mackworth, A. K. (1987) Constraint Satisfaction. In Shapiro, S. (ed) The Encyclopedia of Artifical Intelli- gence, Volume 1, pp.205-211. John Wiley and Sons. Maruyama, H. (1990) Structural Disambiguation with Con- straint Propagation. In Proceedings of the 28th Annual Meeting of the Association for Computational Linguis- tics, pp.31-38. Mellish, C.S. (1985) Computer Interpretation of Natural Language Descriptions. Chichester: Ellis Horwood. Montanari, U. (1974) Networks of Constraints: Fundamen- tal Properties and Applications to Picture Processing. Information Science, 7, 95-132. Partee, B. (1978) Bound Variables and Other Anaphors. In Waltz, D. L. (ed.) Th eoretical Issues in Natural Lan- v-w Processing-2, University of Illinois at Urbana-Champaign Urbana, Illinois, pp.79-85. Pereira, F. C. N. and Shieber, S. M. (1987) Prolog and Nat- ural Language Analysis. Center for the Study of Lan- guage and Information. CSLI Lecture Notes No. 10. Ristad, E. S. (1990) Computational Structure of Human Language. Technical Report AI-TR 1260, AI Lab, MIT. Schubert, L. and Pelletier, J. (1982) From English to Logic: Context-Free Computation of ‘Conventional’ Logical Trans- lation. American Journal of Computational Linguistics, 8, 27-44. Winograd, T. (1972) Understanding Natural Language. Ed- inburgh: Edinburgh University Press. Winston, P. (1984) Artificial Intelligence. Reading, Mass.: Addison- Wesley. 420 Problem Solving: Constraint Satisfaction | 1992 | 75 |
1,271 | ugene C. Freuder Computer Science Department University of New Hampshire Durham, NI-I 03824 USA pdh@cs.unh.edu; ecf@cs.unh.edu I-Iowever, in between, there may be a huge number of A b§tKlC& Constraint satisfaction problems involve finding values for variables subject to constraints on which combinations of values are permitted. They arise in a wide variety of domains, ranging from scene analysis to temporal reasoning. We present a new representation for partial solutions as cross products of sets of values. This representation can be used to improve the performance of standard algorithms, especially when seeking all solutions or discovering that none exist. Constraint-based reasoning has long been recognized as a primary component of AI problem solving and has seen increasing interest and application in recent years. Constraint-based reasoning has been used in many areas of artificial intelligence: vision, language, planning, diagnosis, scheduling, configuration, design, temporal reasoning, defeasible reasoning, truth maintenance, qualitative physics, logic programming, expert systems. This research focuses on the constraint satisfaction problem (CSP) paradigm, which underlies many of these applications [Mackworth 871. Constraint satisfaction problems involve finding values for a set of problem variables that simultaneously satisfy a set of constraints or restrictions on which combinations of values are permissible. A variety of approaches have been developed for solving these problems; the basic algorithmic tools are backtracking and constraint propagation [Nleseguer 891. A basic problem in constraint satisfaction problem search is a phenomenon that we might call “the battle of the bulge”. Search commonly proceeds by developing partial solutions, discarding them once it is clear that they cannot be extended to complete solutions. Initially we start with a small number of partial solutions. Ultimately, for some problems, there are relatively few complete solutions. lThis material is based upon work supported by the National Science Foundation under Grant No. RI-89 13040. The Government has certain rights in this material. partial solutions, candidates for completion to full solutions. Of course, this phenomena is common to other AI search domains. For example, beam search is an effort to address the problem in the classic state space domain. In fact the technique proposed here for addressing the problem was inspired by a very similar technique demonstrated by Wu [Wu 901 in what is, at least superficially, a very different search domain: diagnosis in the presence of multiple diseases. The general principle involved might be stated as follows: Find a method of representing search subspaces that permits operating on the subspaces more efliciently than operating on their individual elements. In the CSP context: Find a method of representing sets of partial solutions such that further values can be tested against a set more efficiently than against each member individually. We implement this principle by using a cross product representation of sets of partial solutions. Suppose, for example, that a, b, c, k are the potential values for variable X and c, d, e, h are the potential values for variable Y. If the pairs of values that satisfy the constraint between X and Y are: this set can be represented by two cross products: {abc}X{def}and(k}X{eh) A value for another variable can be tested against one of these cross product sets by testing against each value for each variable in the cross product. If the value g, for variable 2, is consistent with every value but b and h, we arrive at the extended partial solution sets: 04 X {de0 X &I and {k) X W X W. Hubbe and F’reuder 421 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. If the value m for Z is also consistent with every value but b and h we have the new partial solution sets: {ac}X(def}X{gm}and{k}X{e)X{gm). The cross product representation permits additive as opposed to multiplicative complexity. For example, value g for variable Z can be tested against the cross product representation {a b c} X {d e f} with six (3 + 3) consistency tests : 3 to see if g is consistent with a, b and c and 3 more to see if g is consistent with d, e and f. With the standard backtrack search tree representation we need to see if g is consistent with each of the 3 * 3 = 9 pairs, and for each pair 1 or 2 tests must be made, depending on whether the first test succeeds or not, resulting in a total of between 9 and 18 tests. A related technique was utilized in [Freuder and Quinn 851 to take advantage of variables that are not directly constrained. The lack of a direct constraint between variables implies that all combinations (the cross product of the variable domains) are consistent. Here all combinations in a cross product of subsets of the domains are consistent. This representation supports search algorithms that can be time as well as (relatively) space efficient, especially in searching for all solutions. We call this representation the cross product representation or CPR. It might seem that there would be a problem with a potential combinatorial space explosion in utilizing this representation. However, we will see that the cross product representation can be profitably utilized within an essentially depth-first search context where space is not a serious concern. CPR can be applied to both classical backtracking and forward checking, one of the most highly regarded variants of backtrack search in the literature [Golumb and Baumert 65; Haralick and Elliott 80; Nadel891. In both cases, when finding all solutions, adding CPR can not increase the number of constraint checks, a standard measure of CSP algorithm performance. This is true, in particular, in the special case where there are no solutions, and finding all solutions means discovering that the problem is insoluble. (A constraint check is counted every time we ask the basic question “is value a for variable X consistent with value b for variable Y”, i.e. is the pair (a b) allowed by the constraint between X and Y.) In practice CPR can greatly reduce the number of constraint checks required by backtracking or forward checking, in some cases even when searching for a single solution. In fact we have hopes that CPR will be helpful in searching for any solutions to “really hard problems” [Cheeseman, Kanefsky and Taylor 911, when many combinations of values almost succeed, but few fully succee& The second section discusses the experimental design we use to gather concrete constraint check and cpu time data. The third section presents a basic algorithm for adding CPR to backtrack search, and suggests directions for refinement. We establish the theoretical and practical advantages of the new algorithm. The fourth section discusses an algorithm for adding CPR to forward checking. The final section is a brief conclusion. We show in the next section that it is theoretically impossible for the addition of CPR to require more constraint checks from backtracking or forward checking, when seeking all solutions. (Between backtracking and forward checking neither is always superior in theory, though forward checking often is superior in practice.) However, several interesting questions remain, which experimental evidence can address: * How many constraint checks can be saved? * Can the savings be correlated with problem structure? * Does overhead cost seriously affect the savings? * Can we save when only seeking some solutions? We performed tests with classical backtracking (BT) and with backtracking augmented by CPR (BT-CPR) to address these questions. (The CPR augmentation of forward checking has not yet been implemented; however, BT-CPR has been compared, favorably in some cases, with forward checking.) Our test problems are binary CSPs: constraints involve two variables at a time. Random ten variable problems were generated with different specified “expected” values for three parameters: constraint density, constraint tightness and domain size. Domain size is a positive integer indicating the number of values per variable. Constraint tightness is a number between 0 and 1 indicating what fraction of the combinatorially possible pairs of values from two variable domains are not allowed by the constraint. (If the constraint between X, with values a and b, and Y, with values c and d, does not permit the pairs (a c) and (b c) and (b d), then the constraint tightness is .75.) Constraint density is just a bit more involved. Binary CSPs can be represented as constraint graphs, with the vertices corresponding to variables and the edges to constraints. We want to deal with problems with connected constraint graphs, as unconnected components can be solved independently. A connected constraint graph with n vertices has, at a minimum, n-l edges, and, at a maximum, (n2-n)/2 edges. Constraint density is a number between 0 and 1 indicating what fraction of the possible constraints, beyond the minimum n-l, that the problem possesses. For example, a CSP with a complete constraint graph, where every vertex is connected to every other, has a constraint density of 1; a tree-structured constraint graph has a constraint density of 0. 422 Problem Solving: Constraint Satisfaction The random problem generator allows us to specify “expected” values for density and, somewhat indirectly, tightness and domain size. For example, if we specify tightness is 5, every pair of values will have a 50/50 chance of being allowed. Our main set of test problems consisted of five problems for each of fifteen combinations of tightness and density parameter values. The density parameter values tested were .l, .5 and .9; the tightness parameter values tested were .l, .3, .5, .7 and .9. The expected domain size was 5. The method of generating problems has pros and cons that we do not have space to discuss fully here, but it should be noted that it permits some variation in actual results. For example, one variable domain size might actually be 3, another 7, rather than 5. We measure performance in terms of constraint checks and cpu time. We also compute the ratio of the two, the number of checks per second. Cpu time measurements need to be viewed with even more than the usual skepticism as tests were not always conducted with the same machine, and an improvement was made to the algorithms during testing. None of this however affects the constraint check count, and the overall conclusions to be drawn from the timing results clearly coincide with the overall conclusions to be drawn from the constraint check results. This set of problems includes many with no solutions and a few with millions of solutions. The ratio of the number of solutions to the number of possible value combinations ranges from 0 to about one in three. Constraint checks required by backtracking range from 8 to almost 78,000,OOO; time required by backtracking ranges from an unmeasurable .OO seconds (which we report as .Ol to avoid problems in dividing by 0 in computing ratios) to almost 14,000 seconds, nearly 4 hours. For each set of five problems with specified parameter values we calculated, for each algorithm, the average constraint checks required, the average cpu time utilized and the average checks/second ratio. Effort can vary considerably among a set of five problems for a fixed set of tightness, density and domain size expected-value parameters. Therefore we do not wish to impute too much to individual averages over these sets. However, there are clearly strong, broad patterns in the averages viewed together over the range of parameter values. We also compute ratios of BT and BT-CPR performance using constraint checks, cpu time and checks/second data. This permits a quick assessment of the relative performance of the two algorithms being compared. The larger the numbers the better the relative performance of BT-CPR. (Thus BT performance is in the numerator when comparing constraint checks and cpu time, and in the denominator when comparing checks/second) Any number greater than 1 indicates superior performance by BT-CPR. We were concerned that it could be misleading to compute, for example, constraint check ratios, for the two algorithms, by simply taking the average number of constraint checks used by one algorithm for a set of five problems and dividing it by the average number of constraint checks used by the other algorithm for the same five problems. One problem in the set of five might be so much larger than the others that it would unfairly dominate the result. Therefore we compute the ratio of constraint checks for each of the five problems separately and then average those ratios. The cpu time ratios, and the ratios of the checks/second ratios, were similarly computed The cross product principle can be used to augment classical backtrack search. An algorithm, BT-CPR, is given in Figure 1. BT-CPR involves a “generate and merge” process. Given a cross product P, and a value, v, for the next variable to consider, V, we compute the subset, P’, of the cross product, consistent with v, forming a new cross product P’ X v. We do this for each value v of V. These new cross products are children of P in the search tree. Any children of P which are identical except for the value of V can be merged into a single child. For example, if a and b are both consistent with the same cross product set P’, we can form the new cross product P’ X {a b). Procedure BT-CPR Push the set of values for the first variable onto CP-stack While CP-stack is not empty Pop P from the CP-stack N-list <- empty list For each value v in the first variable V that is not represented in P p’<-PX (v) B’ <- P’ after removing values inconsistent with v If P’ f empty cross product then N-list <- N-list append P Merge all P’ in N-list differing only in the value of V If V is the last variable to consider then output N-list as solutions else push all elements in N-list onto CP-stack Figure 1. BT-CPR Algorithm. Hubbe and F'reuder 423 The search process is basically depth-first; however, it generates all the children at a node at once, in order to allow merging among the children. There can be at most d children, where d is the maximum number of values for any variable, and the depth of search is limited by the number of variables, n. Thus there is an O(nd) upper bound on the number of cross products that the search needs to store at any point. There is clearly an O(nd) bound also on the number of values stored in any one cross product. CPR could also be added to a breadth-first search for all solutions. This would offer greater opportunity for merging solution sets. In a breadth-first implementation this merging could take place among all “cousins” across an entire level of the tree, rather than just among siblings. However, there would be considerable additional overhead This algorithm uses a very simple merging procedure. &lore elaborate merging heuristics, or more generally, a more elaborate search for an optimal representation as a set of cross products, are worth pursuing. Here again there will be cost/benefit considerations. In theory BT-CPR cannot do worse than classical backtracking in searching for all solutions to a CSP, and in practice it can do orders of magnitude better. Theorem I. Augmenting classical backtrack search with CPR will never increase the number of constraint checks required to search for all solutions to a CSP, or to determine that an unsolvable problem has no solution. Proof: Consider that the worst case for backtrack augmented by CPR occurs when all the cross product sets are singletons, sets of one element. But in this case BT- CPR essentially reduces to classical backtracking. 0 Note that this argument is independent of any ordering heuristics that may be applied to enhance backtrack search performance. Given a backtrack algorithm with good search ordering heuristics, adding CPR cannot increase the number of constraint checks required to find all solutions. Ordering is something of a catch-22 proposition for CPR. On the one hand, the “fail first” principle [Haralick and Elliott 801 suggests that we narrow the top of the search tree. On the other hand, CPR thrives on handling multiple possibilities in a concise manner. (Some initial testing suggest that employing the opposite of a good standard CSP search heuristic might sometimes be helpful in the CPR context.) Figure 2 shows the performance ratios, as explained in the previous section. BT-CPR never required more constraint checks than BT, of course; for all but the simplest cases it required less, up to three orders of magnitude less for the most weakly constrained set of problems. The constraints per second performance ratio is uniformly close to 1, suggesting that BT-CPR pays little overhead penalty. Indeed, BT-CPR has the advantage on three sets of problems. Cpu time is, in fact, less for BT-CPR on all but some of the simpler problems. Again the performance ratio climbs up to three orders of magnitude on the most weakly constrained set of problems. On one problem with the tightness parameter set to .l and the density parameter set to .l, BT-CPR required 25,854 constraint checks and 3.21 seconds while backtracking required 77,867,372 constraint checks and 13,986.59 seconds (almost four hours). Clearly, the advantage of CPR increases as the problems become less tightly constrained. Weakly constrained problems are actually difficult problems for finding all solutions for the simple reason that there are a lot of solutions to find, and there is relatively little pruning of the search space. These problems also have a great many solutions, but some applications may need to sift through a great many solutions, if only to collect summary statistics, or in search of a candidate that will pass a further testing process. A simple theoretical analysis shows that in the degenerate case where virtually all possibilities are solutions backtracking is O(n2dn) while backtracking with the cross product representation is O(nd2). Roughly speaking BT-CPR does at least an order of magnitude better on problems with either low density or low tightness parameters. When both parameters are low the performance ratio climbs to three orders of magnitude. It is important to note that while our experiments have provided what might be called “heuristic sufficient conditions” for CPR to do especially well, these are not presented as necessary conditions. We expect CPR to be especially useful under other conditions, as well. We expect CPR to help cope with what one might call “frustrating” problems, where many sets of value choices almost work, by merging many of the partial solutions into cross products. Note, for example, that we can take a test problem where CPR does extremely well because there are a lot of solutions, and transform it into another problem that allows no solutions, where CPR continues to do extremely well. Simply add an additional variable, all of whose values fail to be consistent with any of the solutions for the original variables. CPR can have an advantage even when we are only seeking some solutions. We may be looking for a fixed number or we may be taking solutions as needed, suspending search in a “lazy evaluation” mode. Figure 3 shows the constraint check effort required for BT and BT- CPR to supply x solutions, with x =l, 5, 10, 15, etc., for two sample problems with density parameter .5 and tightness parameter -3. (All the problems with density parameter .5 and tightness parameter greater than .3 failed to have any solutions.) Note that BT-CPR may return solutions in batches; for example, it may first find a cross 424 Problerrr Solving: Constraint Satisfaction a) BT constraint checks to BT-CPR constraint checks b) BT cpu time to BT-CPR cpu time 1.6 H il# 1.4 B 1.2 4 1 p5 2 0.8 Iif. p ::I i 0.2 s ss=.l 0 .3 c) BT-CPR checks per second to BT checks per second Figure 2. Performance ratios. Hubbe and F’reuder 425 product containing 6 solutions, then a cross product with 15 more, and so on. 18000 16000 p 8000 solutions 0 ..I... .,.. ..I... .I.... ,..,,,, . ..I.. .I’... , ovb=z 53 F4 z 22 s 3 E: solutions Figure 3. Asking for x solutions. In the first case, a problem with 44 solutions out of 2,880,OOO possibilities, BT-CPR is superior even when only a single solution is sought. In the second, a problem with 7,912 solutions out of 27,993,600 possibilites, BT- CPR requires more checks initially, but quickly becomes increasingly advantageous. It is even possible for BT-CPR to require less effort than BT when the problem has only one solution. For one of our problems, which did happen to have only one solution, out of 405,000 possibilities, BT-CPR found that solution with 765 constraint checks while BT required 1819 constraint checks. (BT-CPR required 456 more constraint checks to go on and determine that there were no more solutions; BT required 133 1 more.) Applying CPR to Forward Checking Forward checking works by “looking ahead”. When a value is chosen for a variable we examine all the remaining uninstantiated variables and remove from their domains any values inconsistent with the new choice. Again we add a “generate and merge” perspective, utilizing cross products. A node in the search tree will have associated with it a set of domains for uninstantiated variables, to be considered lower in the tree. In expanding a given node in the search tree we construct children corresponding to each of the values in the domain of the next variable, and for each of these values we prune the domains of uninstantiated variables with a forward checking process. Then we merge values for which these sets of domains are identical. For example, if values a and b for V are both consistent with {c d e} for W and (f g} for X, then a and b can be merged into a single child { a b ). The cross product involving (a b) and the sets at the nodes above (a b) in the tree will represent a set of partial solutions, and when we reach the bottom of the search tree, a set of solutions. (Values a and b are consistent with values above them in the search tree; this was assured by similar look ahead earlier in the search process.) An algorithm augmenting forward checking with CPR, FC-CPR, is shown in Figure 4. As before the process is basically depth-first, though generating all the children at a node at once, in order to allow merging among the children. The algorithm incorporates another improvement to forward checking, which utilizes a cross product representation. This is used here with FC-CPR, but could also be applied separately to forward checking. When search reaches a point where none of the remaining variables directly constrain each other (i.e. they form a “stable set”, see [Freuder and Quinn SS]), there is no point in continuing. All the remaining values have been (forward) checked against all previous choices already; all combinations will work. Thus the cross product of the domains of the remaining variables can be added to the partial solution(s) represented at that point in the search tree, and these combinations can be reported as solutions. As before, adding CPR to forward checking can not make things worse for us, and should in most cases improve matters. Theorem 2. Augmenting forward checking with CPR will never increase the number of constraint checks required to search for all solutions to a CSP or to determine that an unsolvable problem has no solution. Proof: Employ a similar reduction argument to that used for Theorem 1. 0 426 Problem Solving: Constraint Satisfaction While we have not yet implemented forward checking augmented by CPR, we found, in earlier experiments, that even BT-CPR can be orders of magnitude more efficient than forward checking for suitably weakly constrained problems. For example, on the sample problem cited above, where BT-CPR required 25,854 constraint checks and 3.21 seconds while backtracking required 77,867,372 constraint checks and 13,986.59 seconds, forward checking still took 33,789,729 checks and 2,029.5 seconds. Procedure FC-CPR Push onto Stack a list containing the empty cross procuct and the cross product of all variable domains While Stack is not empty Pop (Past-CP Future-CP) from Stack If there are no constraints among the variables represented by Future-CP (in particular, if there is only one variable represented) then return the solution represented by Past-CP X Future-CP else For each value, v, in the first variable, V, represented in Future-CP form Future-CP-v by removing from Future-CP the component corre- sponding to V and removing all values inconsistent with v For each maximal set of values, S, for variable V, for which Future-CP-v is identical for each v in S New-Past-CP <- Past-CP X S New-Future-CP <- Future-CP-v Push (New-Past-CP New-Future-CP) onto Stack Figure 4. Forward checking augmented by CPR. Conclusion This paper introduces a new representation for partial solutions to constraint satisfaction problems. This representation can be used with the standard CSP algorithms, backtracking and forward checking. When searching for all solutions or discovering that a problem is insoluble, CPR is guaranteed not to require any additional consistency checks. Experiments on random problems demonstrate that CPR can in fact greatly reduce the number of constraint checks required in many cases, and cpu times demonstrate that the savings can be far more important than CPR overhead. Analysis of these experiments provides heuristic sufficient conditions for CPR to excel CPR may also be of help when searching for subsets of solutions or even a single solution. Part of this work was done while the second author was a Visiting Scientist at the MIT Artificial Intelligence Laboratory. Richard J. Wallace and Karl Gevecker wrote the random problem generator. eferences [ Cheeseman, Kanefsky and Taylor 911 Cheeseman, P., Kanefsky B. and Taylor, W., Where the really hard problems are, Proceedings of the Twelfth International Joint Conference on Artificial Intelligence, 331-337, 1991. [Freuder and Quinn 851 Freuder, E. and Quinn, M., Taking advantage of stable sets of variables in constraint satisfaction problems, Proceedings of the Ninth International Joint Conference on Artificial Intelligence, 1985. [Golumb and Baumert 651 Golomb, S. and Baumert, L., Backtrack programming, JACK 12,516-524,1965. [Haralick and Elliott 801 Haralick R. and Elliott, G., Increasing tree search efficiency for constraint satisfaction problems, Art@cial Intelligence 14,263-313, 1980. [Mackworth 871 Mackworth, A., Constraint satisfaction, in Encyclopedia of Artificial Intelligence, S. Shapiro, ed., vol. 1, John Wiley & Sons, New York, 205-211, 1987. [Meseguer 891 Meseguer, P., Constraint satisfaction problems: an overview, AI Communications 2,3-17, 1989. [Nadel 891 Nadel, B., Constraint satisfaction algorithms, Computational Intelligence, Vol. 5, No. 4, 1989, pp. 188- 224, 1989. [Wu 911 Wu, T., Domain structure and the complexity of diagnostic problem solving, Proceedings of the Ninth National Conference on Artificial Intelligence, 855-86 1, 1991. Hubbe and Freuder 427 | 1992 | 76 |
1,272 | ensity of Solutions in for the ueens Pr Paul Morris IntelliCorp 1975 El Camino Real West Mountain View, CA 94040 morris@intellicorp. corn Abstract There has been recent, interest in applying hill- climbing or iterative improvement methods to constraint satisfaction problems. An important issue for such methods is the likelihood of en- countering a non-solution equilibrium (locally op- timal) point. We present analytic techniques for determining the relative densities of solutions and equilibrium points with respect to these al- gorithms. The analysis explains empirically ob- served data for the n-queens problem, and pro- vides insight into the potential effectiveness of these methods for other problems. Introduction In several recent, papers [Minton et al. 1990, Zweben 1990, Morris 1990, Sosic and Gu 19911, itera- tive improvement, methods for solving constraint satis- faction and optimization problems have been studied. These methods work by making local changes that re- duce a cost function. This process continues until a configuration or state is reached such that no local change can reduce the cost further. We will call such a configuration an equilibrium point. When an equi- librium point is reached, it is checked to see if it is an acceptable solution to the problem. If not, the al- gorithm may be restarted or some other action taken to proceed to a new equilibrium point. The papers above provide empirical evidence that such methods may lead to rapid solutions for important classes of problems. One way of viewing these methods is that they per- form a search of equilibrium points looking for solu- tions. Clearly the effectiveness of such a search is dependent on the density of solutions in equilibrium points. The methods will work particularly well if this density approaches 1. This motivates us to look for a way of analytically determining the density. Such an analysis is useful for predicting when iterative im- provement methods are likely to be of value, and com- plements a quite different, analytic approach presented in Minton et al. [1990] which estimates the probability that a single hill-climbing step leads towards a solu- tion. This paper provides first results in this area. We use n-queens as an illustrative problem since that has been a primary exemplar of the iterative improvement approach. However, the techniques are general, and should be useful elsewhere. In the next section, we re- view some empirical data on solution density for the n- queens problem. In the section after that, we present analyses that explain these data. In the final section, we discuss the applicability of the techniques to other problems. Empirical Results In this section, we describe empirical data reported by other authors, as well as results of our own ex- periments. For the latter, we estimated the density of solutions in equilibrium points (henceforth, we will call this the solution/equilibrium density) by starting with a random sample of initial states, running the al- gorithms to their first equilibrium point, and counting the so1utions.l As an initial data point, Minton et al. [1990] report that their MinConflicts Hill-Climbing2 (MCHC) algo- rithm applied to the n-queens problem never failed to find a solution for n 2 100. We take this as an in- dication that the solution/equilibrium density for the method tends to 1 as n tends to infinity. The MCHC algorithm employs several refinements. For example, the algorithm gets a “head start” on hill- climbing by using a preprocessing stage to produce an initial queen configuration with few attacks. Second, the algorithm permits random “sideways” local modi- fications that leave the number of queen attacks unal- tered. To better understand the value of these refine- ments, we experimented with a simpler algorithm that “This estimate is biased by the relative sizes of the basins of attraction of the equilibrium points. However, the results below concern gross differences in the density (whether it approaches 0 or l), and it seems reasonable to assume this is not affected by the bias. 2Note that here “hill-climbing” means movement to points of lower cost. 428 Problem Solving: Constraint Satisfaction From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. starts from a random initial configuration, and makes only modifications that strictly reduce the number of queen attacks. We will call this Simple Hill-Climbing (SHC). Experiments with n = 1000 yielded no solu- tions for this algorithm in a sample of 100 equilibrium points. This suggests that the solution/equilibrium density for SHC may tend to 0 as n tends to infinity. We also experimented with strict hill-climbing that starts close to a solution. This may be called Head- Start Hill-Climbing (HSHC) . The initial configura- tions were obtained by starting with a fixed solution to the lOOO-queens problem and randomly mutating the column positions of the queens on the first 20 rows. This yielded 1 solution in a sample of 100 equilibrium points. We take this as evidence for a limiting density OfO. Sosic and Gu [1991] describe an interative improve- ment algorithm for the n-queens problem that main- tains configurations with one queen per row and one queen per column. Thus, the column positions of the queens on rows 1 through n form a permutation of the integers from 1 to n. Their QSl algorithm starts with a random permutation and swaps the columns of queens in different rows to reduce the number of attacks. They report that for n 2 1000, the equilib- rium position was always a solution. This suggests a limiting density of 1 for QSl. To summarize these results, the empirical evidence is consistent with a limiting solution/equilibrium den- sity of 1 for MCHC and QSl, and of 0 for SHC and HSHC. Analytic Met The task in the n-queens problem is to place n queens on an n x n board such that no two queens are on the same row or column or diagonal. By an assignment for this problem, we mean a placement of the queens so that there is one queen on each row. Clearly, the solu- tions form a subset of the assignments. If we assume a uniform probability distribution on assignments, then the solution/equilibrium density can be expressed as the conditional probability that an assignment is a solution given that it is an equilibrium point. It does not appear feasible to rigorously compute the probability entirely from first principles. Our ap- proach will be to argue for and adopt reasonable as- sumptions about the distribution that will enable us to derive the empirically observed results. Note that our analysis is only intended to apply for large values ofn. Now consider a random assignment The principal assumption we adopt is of the queens. as follows. Assumption 1 The probability that an arbitrary square is attacked along a diagonal by one of the queens is bounded away from 1, i.e., there is a fixed 6 (independent of n) such the probability is less than 6 and 6 < 1. This is also assumed for conditional prob- abilities of this event, unless there the condition implies otherwise. is reason to believe We argue that the assumption is reasonable because there are 4n - 2 diagonals. Since there are only n queens, each of which sits on 2 diagonals, there must be at least 2n - 2 unoccupied diagonals. Even if these are the shorter diagonals, they will represent a fraction of the board that is bounded away from zero. Thus, provided any condition is such that the distribution remains roughly uniform as n increases, the probabil- ity that an arbitrary square is not in this region should be bounded away from 1. It is worth noting that a similar assumption with respect to column attacks would be false. Suppose we know that the first n - 1 queens do not attack each other. Then they lie on separate columns. Hence, the probability that the last queen is placed on a column that is already occupied is (n - 1)/n, which tends to 1 as n tends to infinity. The difference here is that there are only n columns, as compared to 4n - 2 diagonals, so columns are ultimately a scarcer resource. We now proceed to showing that solutions are dense in equilibrium points for Sosic and Gu’s QSl algo- rithm, and Minton et al.‘s MCHC algorithm. This requires analyzing the cost surface for the problem. In the n-queens problem, the cost of an assignment is the number of queen attacks, i.e., the number of queen pairs that share the same column or diagonal in the assignment. Notice that the total cost of an assignment can be broken down into two components, resulting from column attacks and diagonal attacks, respectively. We can study these separately by consid- ering two variations of the queens problem, which we call the n-rooks problem, and the n-bishops problem.3 The n-rooks problem is like the n-queens problem ex- cept diagonal attacks are ignored. Thus, any assign- ment that corresponds to a permutation is a solution. In the n-bishops problem, we ignore column attacks, so that any assignment with no diagonal attacks is a solution. The cost surface for the ordinary queens problem will then be a superposition of the surfaces for the component problems. In the following, the term simple equilibrium point refers to an equilibrium point with respect to simple hill-climbing. We will also sometimes use “equilibrium point” without qualifica- tion where it is clear from the context which algorithm is involved. We first consider the n-rooks problem. The follow- ing result is easily obtained. Theorem 1 In the n-rooks problem, equilibrium point is a solution. every simple 31n chess, a rook attacks along rows and columns, while a bishop attacks along diagonals. A queen combines the attacks of a rook and a bishop. Morris 429 Proof: Suppose an assignment is not a solution. Now choose X such that S < X < 1. Clearly Then there is some column that contains at least two En rooks. It follows that there must also be an empty column. Note that moving one of the doubled rooks to the empty column reduces the number of attacks. Thus, the assignment is not an equilibrium point. Next we consider the n-bishops problem. In this case, it is not true that every simple equilibrium point is a solution. (Consider, for example, a 4 x 4 board where the bishops are on the columns 1,3,2,2.) How- ever, it turns out that “almost every” (in a well- defined sense) such point is a solution. The basic in- tuition behind the proof is quite simple and can be expressed as follows. Suppose an assignment is not an n-bishops solution. Then there is some bishop that is attacked. Consider the n - 1 other squares that are on the same row as this bishop. Since, by assump- tion 1, the probability of diagonal attack is bounded away from 1, it follows that, with high probability (for sufficiently large n), at least one of these squares is not attacked. Thus, with high probability, the assign- ment is not an equilibrium point. As we see below, presenting a formal proof based on this idea requires some work. We have the following easy result. Lemma 1 For the n-bishops problem, suppose an as- signment is a simple equilibrium point. Then, for each row, either the bishop on that row is not attacked, or else every square on the row is attacked. Proof: Immediate. 1 Now let Ei denote the event that the bishop on the 6th row is not attacked by any of the other bishops, while Fi denotes the event that every square on the i- th row is attacked. Note that Ei and Fi are mutually exclusive. Set E = El A . . . A Ea. It is easy to see that an assignment is a solution if and only if E holds. Furthermore, if an assignment is a simple equilibrium point, then by Lemma 1, Ei V Fi must hold for every i. Thus, Pr[(El V FI) A . . . A (En V Fn)] provides an upper bound on the probability that an assignment is a equilibrium point. We have the fol- lowing lemma. Lemma 2 In the n-bishops problem, there exists a X with 0 < II < 1 such that Pr(Fi) < Xn Pr( Ei) for every i and suJJciently large n. Proof: Consider any i. Note that Fi implies a diag- onal attack on each of the n squares of row i. Recall that, by assumption 1, the probability of diagonal at- tack is less than S, for some S < 1. Thus, Pr(Fi) < S” and Pr(Ei) > (1 - 6). It follows that Pr(Fi) 6” P - WEa) < 1-S’ k < A” for sufficiently large n. The result follows. Corollary 1 Suppose A = Al A . . . A An, where for each i either Ai = Ei or Ai = Fi. Then, under the conditions of the lemma, there exists X, with 0 < X < 1, such that Pr(A) < Xn” Pr(E) where k is the number of values of i for which Ai = Fi. Proof: Let {ir, . . . , ik} be the values of i for which Ai = Fi. By an argument similar to that of the lemma, we get Pr(F;, A . . . A Fi,) < Sn” and Pr(Ei, A.. . A Eik) > (1 - S)k. It follows that Pr(Fi, A . . . A Fik) < Xn” Pr(Ei, A . . . A Eik) for a suitable X and sufficiently large n. Since assump- tion 1 allows us to ignore irrelevant conditioning on probabilities, we can add Aig(i,,...,i,) Ei to the con- juncts on both sides, giving Pr(A) < Xn’ Pr(E). We are now ready to prove the following result. Theorem 2 In the n-bishops problem, the density of solutions in simple equilibrium points approaches 1 for large 12. Proof: Note that if (El V PI) A . . . A (En V Fn) is converted to disjunctive normal form, the number of conjuncts with L occurrences of the Fa propositions will be i . 0 Thus, by Corollary 1, Pr[(El V Fl) A.. . A (En V Fn)] < Pr(E)[l + . . . + (Xrs)h + . . . + (Xn)n] = Pr(E)(l + A,), Since (1 + X”)” tends to 1, we have Pr(Ei A . . . A En) nl%& Pr((E1 V FI) A.. . A (En V Fn)) = 1. The result follows. It may be remarked that empirical testing produces results consistent with Theorem 2. We now return to consideration of the ordinary n-queens problem. One might expect some fraction of the n-rooks and n-bishops solutions to intersect, giving solutions to the full queens problem. Note, however, that the n-rooks solutions are isolated, i.e., each of them is surrounded (within one step) by non- solution assignments. It thus seems reasonable to ex- pect many of the n-rooks solutions to generate non- solution equilibrium points in the full problem. As we 430 Problem Solving: Constraint Satisfaction will see later, this makes simple hill-climbing ineffec- tive for generating solutions. One way of dealing with this problem might be to somehow “factor out” column attacks by performing hill-climbing while sticking to assignments that are already solutions to the n-rooks problem, i.e., permu- tations. In this case, the restricted cost surface might be expected to resemble that for the n-bishops prob- lem. It is well-known that the space of permutations can be traversed by a-step transpositions. This sug- gests generalizing the notion of simple hill-climbing to that of hill-climbing with bounded lookahead. A k-step hill-climbing algorithm is allowed to search k steps from the current assignment looking for one of lower cost. Each equilibrium point of a k-step hill- climbing algorithm will be called a k-step equilibrium point. In the queens problem, we are particularly in- terested in 2-step equilibrium points. We have the following results. Lemma 3 In the n-queens problem, the probability that a Z-step equilibrium point is a permutation ap- proaches 1 for suficiently large n. Proof: Informally, the idea of the proof is as fol- lows. Suppose an assignment is not a permutation. Then there is some column cl that contains at least 2 queens, and some other column c2 that is free of queens. Take one of the queens on cl, and move it to some other column j. If there is already one or more queens on that column, choose one such arbitarily and move it to ~2. Since there are n - 1 possible choices for j, it follows from assumption 1, that with arbi- trarily high probability (for sufficiently large n), we can choose j so that the moved queen(s) will now be free of diagonal attacks. Thus, we have not increased the count of diagonal attacks. But the count of col- umn attacks has been decreased. Thus, the original assignment was not a a-step equilibrium point. A more formal proof is similar to that of Theorem 2. In this case Ei would represent the event that the queen on row i is not attacked along a column by any of the other queens, while Fi would represent the event that it is so attacked and, moreover, none of the possible choices for j above frees the moved queen(s) of diagonal attacks. It is not hard to see that the probability of this Fi declines exponentially with n, as required in the proof. (In this case the probability of Ei declines linearly with n, but this does not impede the proof.) Lemma 4 In the n-queens problem, the probability that a d-step equilibrium point is free of diagonal at- tacks approaches 1 for sufJ&ziently large n. Proof: We present the proof informally. Suppose the assignment is not free of diagonal attacks. Then there must be some queen that is attacked along a di- agonal. Take that queen, and move it to some other column j. If there is already one or more queens on that column, choose one of them arbitarily and move it to the column vacated by the first queen. Since there are n - 1 possible choices for j, with arbitrarily high probability, we can choose j so that the moved queen(s) will now be free of diagonal attacks. Note that the column attack count has not been increased. But the count of diagonal attacks has been decreased. Thus, the original assignment was not a a-step equi- librium point. Again, the proof can be made formal along the lines of Theorem 2. Theorem 3 In the n-queens problem, the density of solutions in 2-step equilibrium points approaches 1 for large 12. Proof: Immediate from Lemmas 3 and 4. We can use these results to explain the performance of the QSl algorithm. Recall that this algorithm per- forms hill-climbing that swaps columns to reduce the number of diagonal attacks, i.e., it moves from per- mutation to permutation in 2-step jumps. Essentially the same proof as that of Lemma 4 can be used to show that, with arbitrarily high probability, the equi- librium permutation is free of diagonal attacks, i.e., it is a solution. This explains the high density of solu- tions encountered by this algorithm. In order to understand the behavior of MCHC, we divide simple equilibrium points that are not solutions into two categories: we will say such a point is a pit if every path from the point to a region of lower cost must pass through a region of higher cost; otherwise, the point is a plateau. (In the case of a plateau, we can reach a region of lower cost by passing through points of equal cost.) It is easy to see that MCHC will eventually escape from a plateau because of its random sideways movements. Note that MCHC either reaches a solution, or ends up cycling randomly among a fixed group of points with equal cost. Since MCHC escapes from plateaus, every such point must be a pit. We have the following lemma. Lemma 5 In the n-queens problem, every pit is a 2- step equilibrium point. Proof: We will show that if a point is not a a-step equilibrium point, then it cannot be a pit. Suppose a double queen movement leads to a lower cost. If neither queen move singly lowers the cost, this can only be because the two queens attack each other after one is moved first. But there is at most one attack between two queens. Thus, the intermediate state, at worst, has equal cost to the original state. By theorem 3, for large n, almost every 2-step equi- librium point is a solution; thus, there must be few pits relative to solutions. It follows that the frequency with which MCHC terminates in a solution should ap- proach 1 for large n. Morris 431 We now consider the negative data described in the section on empirical results. These data sug- gest that for SHC (simple hill-climbing) the solu- tion/equilibrium density tends to 0. This is borne out by the following result. Theorem 4 In the n-queens problem, the solu- tion/equilibrium density for SHC tends to 0 as n tends t 0 infinity. Proof: Suppose an assignment is a solution to the n-queens problem. Let q be a fixed queen. Consider the n-l possible new positions arrived at by swapping columns between q and some other queen. The prob- ability of diagonal attack on the squares to which the queens are moved is bounded away from 1 by assump- tion. We can also assume it is bounded away from 0, since at least n - 2 of the diagonals are occupied by queens. It follows that the probability that the swap leads to exactly one diagonal attack is bounded away from 0. Now let k be some arbitrary number. For suffi- ciently large n, with arbitrarily high probability, at least k of the possible swaps must lead to a position involving exactly one diagonal attack. Any such posi- tion is an equilibrium point under simple hill-climbing because a single queen movement from the position necessarily produces a column attack. The above shows that for every solution, with high probability, there are at least k non-solution equilib- rium points. However, there remains the possibility that these overlap for different solutions. We can deal with this consideration if we assume that solu- tions are distributed roughly uniformly across assign- ments. Since the density of solutions in assignments declines rapidly with n, and the equilibrium points exhibited above are within a bounded distance of the corresponding solution, it follows that the amount of overlap is ultimately not significant. Therefore, the solution/equilibrium density is less than l/k for suf- ficiently large 72. But k is arbitrary. Thus, the solu- tion/equilibrium density tends to 0. An examination of the proof of Theorem 4 shows it applies equally well to HSHC.4 These results sug- gest that “sideways” local change-not the “head start” preprocessing algorithm-is the important fac- tor leading to the high density of solutions for MCHC in the queens problem. Discussion In this section, we will try to place the results above in perspective, and see how they might apply to other problems. We are particularly interested in constraint satisfaction problems (CSPs), of which the n-queens problem is an example. Informally, a CSP consists of a set of variables, each of which is assigned a value *However, the density may approach zero at a slower rate with HSHC. from a set called the domain of the variable. The possible assignments are restricted by a set of con- straints, which mandate relationships or restrictions between the values of different variables. The reader is referred to Dechter [1990] for the formal definition of a CSP. We require some additional terminology. A simple equilibrium point that is not a solution will be called a basin. The radius of a basin is defined to be the number of steps required to escape from it, i.e., the minimum number of steps needed to reach a region of lower cost. Notice that saying solutions have high density in k-step equilibrium points is equivalent to saying that basins with radius greater than k are rare compared to solutions. We can summarize the results of the previous sec- tion as follows. In the n-queens problem, for large n, basins of radius greater than 2, and hence pits, are sparse relative to solutions, but plateaus of radius 2 are quite common. This suggests that, visually, each solution appears surrounded by “stairs,” with steps of width 2, rather like in an amphitheatre. Notice that the cost surface appears smooth when viewed at a coarse resolution. The proof method used in the queens problem can be generalized to support the following observation: If a problem area has the property that an arbitrary constraint violation can be removed within k steps with low probability of introducing a fresh violation, then hill-climbing with k-step lookahead will be an eflective solution technique. The n-bishops example demonstrates one way of showing that the low probability criterion is met. If a CSP has the property that the domain size of each variable is at least comparable to the number of vari- ables, and the probability that any one value is in conflict is bounded away from 1, then resetting a sin- gle variable will generally suffice to eliminate one con- flict, in large problems. Actually, the condition on the probability can be relaxed somewhat: instead of be- ing bounded away from 1, it is enough to suppose it does not approach 1 too quickly. Recall that the cru- cial property used in the proof of Theorem 2 is that (1 + Xn)n tends to 1. It turns out that this will be true even if X increases with n provided at least that X<l-l/n”forsomeo<l. A further point to observe is that the constraints in the queens problem fall into two categories. Con- straints corresponding to diagonal attacks meet the low probability criterion discussed above. However, the column attack constraints do not have this felici- tous property. We will refer to constraints that do not meet the low probability criterion as tight constraints. The analysis in the queens problem shows that if the space is reformulated so that tight constraints are somehow “factored out ,” then hill-climbing can be made effective. We can draw an analogy to game- playing programs where search continues until a qui- 432 Problem Solving: Constraint Satisfaction escent position is reached at which evaluation takes place. This may, for example, involve following down all possible sequences of captures. In the case of CSP solving using the techniques discussed here, quiescence would require that none of the tight constraints are violated. For example, in the QSl algorithm, a po- tential queen move must be accompanied by move- ment of a second queen so that a situation involving no column attacks is maintained. In terms of our ob- servation about hill-climbing with k-step lookahead, we remark that the lookahead need not involve a full- width search; instead, the search may be tailored to the structure of a particular problem. The queens problem also suggests that examining variant prob- lems that ignore one or more categories of constraints may provide a useful analysis tool for formulating the search strategy. The distinction between tight and non-tight con- straints suggests a piece of practical advice in organiz- ing an environment for scheduling or other activities requiring constraint satisfaction. It may be wise to allow a certain amount of slack in providing resources for the tasks. For example, we can predict from the analysis here that simple hill-climbing should be effec- tive, for large n, in placing n/2 queens without attack on an n x n board (because then the probability of both column and diagonal attacks would be bounded away from 1). Similarly, suppose n tasks requiring an exclusive resource of a particular type need to be performed within m time slots, so that at least n/m copies of the resource are required. The results here indicate that the allocation problem may be simplified if, say, en/m instances of the resource are available, where c > 1. An additional observation is that certain categories of constraints appear to be associated with basins of a definite size. For example, constraints associated with a fully subscribed resource (such as columns in the n-queens problem) tend to require swaps to make progress, i.e., they produce basins with a characteris- tic radius of 2. Similarly, equality constraints would generate basins of radius 2. Of course, basins result- ing from separate constraints may, by random coin- cidence, occur next to each other and coalesce into a basin of larger size. The Central Limit Theorem of probability theory suggests that for problems with sufficiently randomized constraints, the basin sizes should occur in a normal distribution with a mean that depends on the relative prevalence of constraints. Note that this does not necessarily increase in propor- tion to the size of the problem. This raises the possibility that for important classes of problems, hill-climbing with bounded lookahead might perform well. In [Morris, 19911, a hill-climbing algorithm is proposed that fills in basins as it goes along, so that it always reaches a solution if one exists. Roughly speaking, the algorithm simulates L-step hill- climbing for every k: at a cost bounded by V steps per simulated L-step. Here V is the “volume” of a basin of radius L, i.e., the number of steps required to fill it. This indicates that the algorithm should perform well in problems where the average basin size is small. Conchsion Using the n-queens problem as an illustrative exam- ple, we have shown that, under certain conditions, hill-climbing algorithms can enjoy the property that almost all equilibrium points will be solutions. The analysis explains the success of some algorithms pre- viously reported in the literature. Furthermore, it predicts circumstances under which more general con- straint problems may be amenable to similar ap- proaches. Acknowledgement The author is grateful Dechter for suggestions concerning this work. to Rina eferences R. Dechter. Enhancement schemes for constraint processing: backjumping, learning, and cutset de- composition. Artificial Intelligence, 41(3), 1990. S. Minton, M. D. Johnston, A. B. Philips, and P. Laird. Solving large scale constraint satisfaction and scheduling problems using a heuristic repair method. In Proceedings of AAAI-90, Boston, 1990. P. Morris. Solutions Without Exhaustive Search. In Proceedings of AAAI-90 Workshop on Constraint- Directed Reasoning, Boston, 1990. P. Morris. An ,Iterative Improvement Algorithm With Guaranteed Convergence. Technical Note TR- M-1991-1, IntelliCorp, Mountain View, California, 1991. R. Sosic, and J. Cu. 3,000,OOO Queens in Less Than One Minute. Sigart Bulletin, 2(2), 1991. M. Zweben. A Framework for Iterative Improvement Search Algorithms Suited for Constraint Satisfaction Problems. In Proceedings of AAAI-90 Workshop on Constraint-Directed Reasoning, Boston, 1990. Morris 433 | 1992 | 77 |
1,273 | ct ivat ion Function for inimieat ion Gadi Pinkas* Dept. of Computer Science Washington University St. Louis, MO 63131 Abstract Symmetric networks that are based on energy minimization, such as Boltzmann machines or Hopfield nets, are used extensively for optimiza- tion, constraint satisfaction, and approximation of NP-hard problems. Nevertheless, finding a global minimum for the energy function is not guaran- teed, and even a local minimum may take an expo- nential number of steps. We propose an improve- ment to the standard activation function used for such networks. The improved algorithm guaran- tees that a global minimum is found in linear time for tree-like subnetworks. The algorithm is uni- form and does not assume that the network is a tree. It performs no worse than the standard al- gorithms for any network topology. In the case where there are trees growing from a cyclic sub- network, the new algorithm performs better than the standard algorithms by avoiding local min- ima along the trees and by optimizing the free energy of these trees in linear time. The algo- rithm is self-stabilizing for trees (cycle-free undi- rected graphs) and remains correct under various scheduling demons. However, no uniform protocol exists to optimize trees under a pure distributed demon and no such protocol exists for cyclic net- works under central demon. Introduction Symmetric networks, such as Hopfield nets, and Boltzmann machines, mean-field and harmony net- works are widely used for optimization, constraint satisfaction, and approximation of NP-hard problems [Hopfield 821, [Hopfield 841, [Hinton, Sejnowski 861, [Peterson, Hartman 891, [Smolensky 86, page 2591. *Supported by NSF grant R-9008012 and by the Center for Intelligent Computer Systems at Washington University. tPartially supported by NSF grant IRI-9157636 and by the Air Force Office of Scientific Research, AFOSR 900136. Rina Dechter+ Dept. of Computer and Information Science University of California, Irvine These models are characterized by a symmetric ma- trix of weights and a quadratic energy function that should be minimized. Usually, each unit computes the gradient of the energy function and updates its own activation value so that the free energy decreases grad- ually. Convergence to a local minimum is guaranteed, although in the worst case it is exponential in the num- ber of units [K&f et al. 891, [Papadimitriou et al. 901. In many cases, the problem at hand is formu- lated as an energy minimization problem and the best solutions (sometimes the only solutions) are the global minima [Hopfield, Tank 85],[Ballard et al. 861, [Pinkas 911. The d esired connectionist algorithm is, therefore, one that reduces the impact of shallow local minima and improves the chances of finding a global minimum. Models such as Boltzmann machines and Harmony nets use simulated annealing to escape from local minima. These models asymptotically converge to a global minimum, meaning that if the annealing schedule is slow enough, a global minimum is found. Nevertheless, such a schedule is hard to find and there- fore, practically, finding a global minimum for such networks is not guaranteed even in exponential time (note that the problem is NP-hard). In this paper, we look at the topology of symmet- ric neural networks. We present an algorithm that optimizes tree-like subnetworks’ in linear time. It is based on a dynamic programming algorithm presented in [Dechter et al. 901. Our adaptation is connectionist in style; that is, the algorithm can be stated as a sim- ple, uniform activation function [Rumelhart et al. 861, [Feldman, Ballard 821. It does not assume the desired topology (tree) and performs no worse than the stan- dard algorithms for all topologies. In fact, it may be integrated with many of the standard algorithms in such a way that if the network happens to have tree- like subnetworks, the new algorithm out-performs the standard algorithms. The paper is organized as follows: Section 2 dis- ‘The network is characterized by an undirected graph without cycles; i.e., only one path exists between any two nodes. The terms cycle-free or unrooted tree are synony- mous in this context. 434 Problem Solving: Constraint Satisfaction From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. cusses connectionist energy minimization. Section 3 presents the new algorithm and gives an example where it out-performs the standard algorithms. Section 4 dis- cusses convergence under various scheduling demons and self-stabilization. Section 5 summarizes. Connectionist energy minimization Suppose a quadratic energy function of the form E(X1, .*., X,) = - 2 Wi,jXiXj + 2 -0iXi. i<j i Each of the variables Xi may have a value of zero or one (called the activation value), and the task is to find a zero/one assignment to the variables X1, . . . . X, that minimizes the energy function. To avoid confusion with signs, we will consider the equivalent problem of maximizing the goodness function: G(X1, . ..) X,) = 4(X1, .‘.) X,,) = x wi,Jxix,+~ui i<j il, III connectionist approaches, we look at the net- work that is generated by assigning a node i for ev- ery variable Xi in the function and by creating a weighted arc (with weight wi,j) between node i and node j for every term w;,j X;Xj . Similarly, a bias 0i is given to unit i if the term BiXi is in the func- tion. For example, Figure 2-b shows the network that corresponds to the goodness function E( X1 . 3Y Y -x xc +2x x -2x x : -3x -r,“I?= - . i 21 3 r Ea.& of the iodes is atsiined aLr&essini unit’and tlie network collectively searches for an assignment that maximizes the goodness. The algorithm that is repeat- edly executed in each unit/node is called the protocol or the activation function. A protocol is uniform if all the units execute it. We give examples for the discrete Hopfield net- work [Hopfield 821 and the Boltzmann mat hine [Hinton, Sejnowski 861, which are two of the most pop- ular models for connectionist energy minimization: In the discrete Hopfield model, ea.ch its activation value using the forlliula unit computes xi= l C iff C, Wzs3dYi3 2 -0ij 0 otherwise. For Boltzmann machines, the determination of the activation value is stochastic and the probability of set- ting the activation value of a unit to one is P(Xi = 1) = l/( 1 + e-CC3 W”‘XJ+‘z”T), where T is the annealing temperature. Both approaches ma.y be integrated with our topology-based algorithm; in other words, nodes that cannot, be identified as parts of a tree-like subnetwork use one of the standard algorithlus. Key idea The algorithm We assume that the model of communication is shared memory, multi-reader/single-writer, that scheduling is under a central demon, and that execution is fair. In a shared memory, multi-reader/single-writer, each unit has a shared register called the activation register. A unit may read the content of the registers of all its neighbors, but write only its own. Central demon means that the units are activated one at a time in an arbitrary order. 2 An execution is said to be fair if every unit is activated infinitely often. The algorithm identifies parts of the network that have no cycles (tree-like subnetworks) and optimizes the free energy on these subnetworks. Once a tree is identified, it is optimized using an adaptation of a constraint optimization algorithm for cycle-free graphs presented in [Dechter et al. 901. The algorithm be- longs to the family of nonserial dynamic programming ,~, methods [Bertele, Brioschi 721. 2 Let us assume first that the network is is an un- rooted tree (cycle-free). Any such network may be di- rected into a rooted tree. The algorithm is based on the observation that giveu an activation value (O/l) for a node in a tree, the optimal assignments for all its adjacent nodes are independent of each other. In particular, the optimal assignment to the node’s de- scendants are independent of the assignments for its ancestors. Therefore, each node i in the tree may com- pute two values: Gy and Gi. G,’ is the maximal good- ness contribution of the subtree rooted at i, including the connection to i’s parent whose activation is one. Similarly, Gf is the maximal goodness of the subtree, including the connection to i’s parent whose activation value is zero. The acyclicity property will allow us to compute each node’s Gt and Gy as a a simple function of its children’s values, implemented as a propagation algorithm initiated by the leaves. Knowing the activation value of its parent and the values G’y, Gi of all its children, a node can compute the maximal goodness of its subtree. When the infor- mation reaches the root, it can assign a value (O/l) that maximizes the goodness of the whole network. The assignment information propagates now towards the leaves: knowing the activation value of its parent, a node can compute the preferred activation value for itself. At termination (at stable state), the tree is op- timized. The algorithm has three basic steps: 1) Directing a tree. Knowledge is propagated from leaves towards the center of the network, so that after a linear number of steps, every unit in the tree knows ‘Standard algorithms need to assume the same condi- tion in order to guarantee convergence to a local minimum (see [IIopfield 8~1). TI lis condition can be relaxed by re- stricting only that adjacent nodes may not be activated at the same time. Pinkas and Dechter 435 its parent and children. 2) Propagation of goodness values. The values Gf , Gf are propagated from leaves to the root. At termination, every node knows the maximal goodness of its subtree, and the appropriate activation value it should assign, given that of its parent. In particular, the root can now decide its own activation value so as to maximize the whole tree. 3) Propagation of activation values. Starting with the root, each node in turn determines its activation value. After O(depth of tree) steps, the units are in a stable state, which globally maximizes the goodness. Each unit’s act&don register consists of the fields Xi (the activation value); Gy, Gi (the maximal good- ness values); and Pi', . . , Pi (a bit for each of the j neighbors of i that indicated which is i’s parent). Directing a tree The goal of this algorithm is to inform every node of its role in the network and of its child-parent relationships. Nodes with a single neighbor identify themselves as leaves first and then identify their neighbor as a parent (point to it). A node whose neighbors all point towards it identifies itself as a root. A node whose neighbors all but one point towards it selects the one as a parent. Finally, a node that has at least two neighbors not pointing towards it identifies itself as being outside the tree. Each unit uses one bit per neighbor to keep the pointing information: P! = 1 indicates that node i sees its jth neighbor as :ts parent. By looking at Pj, node i knows whether j is pointing to it. Identifying tree-like subnetworks in a general net- work may be done by the following algorithm: Tree Directing (for unit i): 1. Injtialization: If first time, then for all neighbors j, P? = 0. /* Start with clear pointers (this step is not nieded in trees) */ 2. If there is only a single neighbor (j) and Pj = 0, then Pi = 1. /* A leaf selects its neighbor as-parent if that neighbor doesn’t point to it */ 3. else, if one and only one neighbor (k) does not point to i (Pi = 0), then P;k = 1, and, for the rest of the neighbors, Pi = 0. /* X: is the parent */ 4. Else, for all neighbors j, Pj = 0. /* Node is either a root or outside the tree */ I n Figure l- a , we see a cycle-free network after the tree-directing phase. The ljumbers on the edges rep- resent the values of the Pi bits. In Figure l-(b), a tree-like subnetwork is identified inside a cyclic net- work; note that node 5 is not a root, since not all its neighbors are pointing towards it. (W Figure 1: Directing a tree: (a) A tree, (b) A cyclic graph Propagation of goodness values In this phase, every node i computes its goodness val- ues Gi, Gy by propagating these two values from the leaves to the root (see figure 2). x,=0 4 Rc\” x, = 0 x, = 1 1 x, = 0 x, = 1 (b) Figure 2: (a) Propagating goodness values, (b) Prop- agating activation values Given a node Xi, its parent Xk, and its children child(i) in the tree, it can be shown, based on the energy function (l), that the goodness values obey the following recurrence: Gfk = mCLX( c Gf’ -k Wi,kXiXk f 8iXi). jEchild(i) Consequently, a nonleaf node i computes its goodness values using the goodness values of its children as fol- lows: If Xk = 0, then i must decide between setting xi = 0, obtaining a goodness of Cj Gi, or setting 436 Problem Solving: Constraint Satisfaction Xi = 1, obtaining a goodness of cj Gj’ + 0i. This yields Gy =max( c Gj, c Gjf+&}. jEchild(i) jEchild(i) Similarly, when Xk = 1, the choice between Xi = 0 and Xi = 1 yields Gf =max( )-J Gi”, c +t-wi,k+oi}. j Echild(i) jEchitd(i) The initial goodness values for leaf nodes can be ob- tained from the above (no children). Thus, GP = max{O,Oi}, Gf = {O,wik + 0i). For example: If unit 3 in Figure 2 is zero, then the maximal goodness contributed by node 1 is GY = maxX1E{0,1} WlI = 2 and it is obtained at x1 = 1. Unit 2 (when Xs = 0) contributes GO, = maxx2E(o,l) {-X2} = 0, obtained at X3 = 0, while G = maxx-E{0,1~{3X2 - X2) = 2 is obtained at x2 = 1. As for nonleaf nodes, if X4 = 0, then when x3 = 0, the goodness contribution will be xk Gi = 2+0 = 2, while if X3 = 1, the contribution will be -3 + Ck Gi = -3 + 1 + 2 = 0. The maximal contri- bution Gg = 2 is achieved at X3 = 0. Propagation of activation values Once a node is assigned an activation value, all its children can activate themselves so as to maximize the goodness of the subtrees they control. When such a value is chosen for a node, its children can evaluate iheir activation values, and the process continues until the whole tree is assigned. There are two kinds of nodes that may start the process: a root which will choose an activation value to optimize the entire tree, and a non-tree node which uses a standard activation function. When a root Xi is identified, it chooses the value 0 if the maximal goodness is Cj Gj”, while it chooses 1 if the maximal goodness is Cj Gj’ + 0i. In summary, the root chooses its value according to xi = 1 iffCjG~+Bi~CjG~, 0 otherwise. In Figure 2, for example, G:+GA+O = 2 < Gg+Gg = 3 and therefore X4 = 0. An internal node whose parent is k chooses an acti- vation value that maximizes Cj G~‘+wi,kXiXk+t?iXi. The choice therefore, is between ‘& Gj” (when Xi = 0) and cj Gi + Wi,kXk + ei (when Xi = l), yielding: Xi = C 1 iff cj Gj’ + Wi,kxk + Oi 2 cj GT 0 otherwise. AS a special case, a leaf i, chooses Xi = 1 iff Wi,kXk 2 4, which is exactly the discrete Hopfield activation function for a node with a single neighbor. For exam- ple, in Figure 2, Xs = 1 since w4,sX4 = 0 > -05 = -1, and X3 =OsinceGi+G:+2X4+83= 1+2+0-3= 0 < 6: + GC: = 2. Figure 2-(b) shows the activation values obtained by propagating them from the root to the leaves. A complete activation function Interleaving the three algorithms described earlier achieves the goal of identifying tree-like subnetworks and maximizes their goodness. In this subsection, we present the complete algorithm, combining the three phases while simplifying the computation. The algo- rithm is integrated with the discrete Hopfield activa- tion function; however it can be integrated also with other activation function (eg. Boltzmann machine).3 Let i be the executing unit, j a non-parent neighbor of i, and k the parent of i: Optimizing on Tree-like Subnetworks (unit i): 1. Initialization: If first time, then (Vj) Pi = 0. /*Clear pointers (needed only for cyclic nets)*/ 2. Tree directing: If there exists a single neighbor k, such that Pi = 0, then P: = 1, and for all other neighbors j, Pj = 0; else, for all neighbors, Pi = 0. 3. Computing goodness values: G; = max{Cj~chi~d(i)G~p~,Cj~chi,d(i)G~p~ + ei)* G; = max(Cjechild(i) Gj”Piiy cjechild(i)(Gj’pj’ + Wi,j Pij) + 0i). 4. Assigning activation values: If at least two neighbors are not pointing to i, then /*use standard activation function (Hopfield) */ Xi = 1 1 if Cj Wi,jXj 2 -8i, 0 otherwise; else, /* Node in a tree (including root and leaves) */ Xi = 1 if Cj((G~ - G!)Pj + wi,jXjPi) 1 -0i, 0 otherwise. An example The example illustrated in Figure 3 demonstrates a case where a local minimum of the standard algorithms is avoided. Standard algorithms may enter such lo- cal minimum and stay in a stable state that is clearly wrong. The example is a variation on a harmony net- work [Smolensky 86, page 2591 and an example from [McClelland et al. 86, page 221. The task of the net- work is to identify words from low-level line segments. Certain patterns of line segments excite units that rep- resent characters, and certain patterns of characters excite units that represent words. The line strokes used 3Note how similar the new activation function is to the original Hopfield function. Pinkas and Dechter 437 avoided. Limitations and extensions Figure 3: A Harmony network for recognizing Local minima along the subtrees are avoided words: to draw the characters are the input units: Ll,..., L5. The units “N,” “ S,” “A,,, and “a‘” represent characters. The units “able,” “nose,” “time,” and “cart” represent words, and Hn, Hs, Ha, Ht, Hl,..., H4 are hidden units required by the Harmony model. For example, given the line segments of the character S, unit L4 is acti- vated (input), and this causes units Hs and “S” to be activated. Since “NOSE” is the only word that con- tains the character “S,” both H2 and the unit “nose” are also activated and the word “NOSE” is identified. The network has feedback cycles (symmetric weights) so that ambiguity among characters or line- segments may be resolved as a result of identifying a word. For example, assume that the line segments re- quired to recognize the word “NOSE” appear, but the character “N” in the input is blurred and therefore the setting of unit L2 is ambiguous. Given the rest of the line segments (e.g., those of the character “S”), the net- work identifies the word “NOSE” and activates units “nose” and H2. This causes unit “N” to be activated and so are all of its line segments. Thus the ambiguity of L2 is resolved. The network is indeed designed to have a global minimum when L2, Hn, “N,” H2, and “nose” are all activated; however, standard connectionist algo- rithms may fall into a local minimum when all these units are zero, generating goodness of 5 - 4 = 1. The correct setting (global minimum) is found by our tree-optimization protocol (with goodness: 3-1+3- 1+3-1+5-1-4+3-1+5=13). The thick arcs in the upper network of Figure 3 mark the arcs of a tree-like subnet- work. This tree-like subnetwork is drawn with pointers and weights in the lower part of the figure. Node “S” is not part of the tree and its activation value is set to one because the line-segments of “S” are activated. Once “S” is set, the units along the tree are optimized (by setting them all to one) and the local minimum is We have shown a way to enhance the performance of connectionist energy minimization networks with- out loosing much of the simplicity of the standard ap- proaches. Our simple algorithm is limited in two ways, however. First, the central demon (or atomicity of the protocol) is not a realistic restriction. We would like the network to work correctly also under a distributed demon, where any subset of units may be scheduled for execution at the same time. Second, we would like the algorithm to be self-stabilizing. It should converge to a legal, stable state given enough time, even after noisy fluctuations that cause the units to execute an arbitrary program state and the registers to have arbi- trary content. Scheduling demons Two negative results (presented in [Collin et al. 911 following [Dijkstra 741) regarding the feasibility of dis- tributed constraint satisfaction, can be extended and proved for computing the global minimum of energy functions: (1) No uniform deterministic distributed al- gorithm exists that guarantees a stable global mini- mum under a distributed demon, even for simple chain- like trees, and (2) no uniform deterministic algorithm exists that guarantees a stable global minima under a central demon for cyclic networks, even for simple rings. For proofs see [Pinkas, Dechter 921. These negative results should not discourage us, since they rely on obscure infinite sequences of exe- cutions which are unlikely to occur under a truly ran- dom demon. Our algorithm will converge to a global minimum under a distributed demon in each of the fol- lowing cases: (1) If step 2 of the protocol in section is atomic; (2) if for every node i and every neighbor j, node i is executed without j infinitely often; (3) if one node is unique and acts as a root, that is, does not execute step 2 (an almost uniform protocol); and (4) if the network is cyclic. Self-stabilization A protocol is self-stabilizing if in any fair execution, starting from any input configuration and any program state, the system reaches a valid stable configuration. The algorithm in Section is self-stabilizing for cycle- free networks (trees), and it remains self-stabilizing under distributed demon if every node executes with- out a neighbor infinitely often or if one node is act- ing as a root. The algorithm is not self-stabilizing for cyclic networks (see [Pinkas, Dechter 921) due to its tree-directing sub-protocol. To solve this problem, we may use a variation of the self-stabilizing tree-directing protocol of [Collin et al. 911. This algorithm remains self-stabilizing even in cyclic networks, although it is more complex and requires more space. 438 Problem Solving: Constraint Satisfaction Summary We have shown a uniform self-stabilizing connection- ist activation function that is guaranteed to find a global minimum of tree-like symmetric networks in lin- ear time. The algorithm optimizes tree-like subnet- works within general (cyclic) networks. The algorithm can be extended to be self-stabilizing for all cyclic net- works, but more space will then *be needed. We stated two negative results: (1) Under a pure distributed demon, no uniform algorithm exists to op- timize even simple chains, and (2) no uniform algo- rithm exists to optimize simple cyclic networks (rings) even under a central demon. We conjecture that these negative results are not of significant practical impor- tance, since in truly random scheduling demons the probability of having such pathological executions ap- proaches zero. Our algorithm remains correct under a distributed demon (without atornicity) if some weak assumptions are made. References D. H. Ballard, P. C. Gardner, M. A. Srinivas, “Graph problems and connectionist architectures,” Depart- ment of Computer Science, University of Rochester, Technical Report 167, 1986. U. BertelC, F. Brioschi, “Nonserial dynamic prognrm- ming, ” Academic Press, 1972. Z. Collin, R. Dechter, S. Katz, “On the feasibility of distributed constraint satisfaction,” In IJCAI-91: Proceedings of 12th International Conference on Ar- tificial Intelligence, Sydney, Australia, 1991. R. Dechter, 3. Pearl, “Network-based heuristics for constraint-satisfaction problems,” Artificial Intelli- gence 34, pp. l-38, 1988. R. Dechter, A. Dechter, J. Pearl, “Optimization in constraint networks,” in R.M. Oliver and J.Q. Smith (editors), Injluence diagrams, belief nets and decision analysis, John Wiley, 1990. E.W. Dijkstra, “Self-stabilizing systems in spite of distributed control,” Communications of the ACM 17, pp. 643-644, 1974. J .A Feldman, D.H. Ballard, “Connectionist models and their properties,” Cognitive Science 6, 1982. G.E Hinton, T.J. Sejnowski, “Learning and re- learning in Boltzman machines,” in J. L. McClelland, D. E. Rumelhart, Parallel Distributed Processing: Ex- plorations in the Microstructure of Cognition I, MIT Press, 1986. J. J. Hopfield, “Neural networks and physical sys- tems with emergent collective computational abili- ties,” Proceedings of the National Academy of Sci- ences 79, pp. 25542558, 1982. J. J. Hopfield, “Neurons with graded response have collective computational properties like those of two- state neurons,” Proceedings of the National Academy of Sciences , pp. 3088-3092, 1984. J.J. Hopfield, D.W. Tank, “Neural computation of decisions in optimization problems,” Biological Cy- bernetics 52, pp. 144-152, 1985. S. Kasif, S. Banerjee, A. Delcher, G. Sullivan, “Some results on the computational complexity of symmet- ric connectionist networks,” Department of Computer Science, The John Hopkins University, Technical Re- port JHU/CS-89/10, 1989. J. L. McClelland, D. E. Rumelhart, G.E Hinton, J.L. McClelland, “The appeal of PDP,” in J. L. McClel- land, D. E. Rumelhart, Parallel Distributed Process- ing: Explorations in the Microstructure of Cognition I, MIT Press, 1986. C. Papadimitriou, A. Shaffer, M. Yannakakis, “On the complexity of local search,” in ACM Symposium on the Theory of Computation, pp. 438-445, 1990. C. Peterson, E. Hartman, “Explorations of mean field theory learning algorithm,” Neural Networks 2, no. 6, 1989. G. Pinkas, “Energy minimization and the satisfiabil- ity of propositional calculus,” Neural Computation 3, no. 2, 1991. G. Pinkas, R. Dechter, “An improvement for Hop- field networks that avoids local minima along tree- like subnetworks in linear time,” Department of Com- puter Science, Washington University, Technical Re- port WUCS-92-2, 1992. D.E. Rumelhart, G.E Hinton, J.L. McClelland, “A general framework for parallel distributed process- ing,” in J. L. McClelland, D. E. Rumelhart, Paral- lel Distributed Processing: Explorations in the Mi- crostructure of Cognition I, MIT Press, 1986. P. Smolensky, “Information processing in dynamic sys terns: Foundations of harmony theory,” in J. L. McClelland, D. E. Rumelhart, Parallel Disl tributed Processing: Explorations in the Microstruc- ture of Cognition I, MIT Press, 1986. Pinkas and Dechter 439 | 1992 | 78 |
1,274 | A New Met Bart Selman AT&T Bell Laboratories Murray Hill, NJ 07974 selman@research.att.com is Y s Hector Levesque” David Mitchell Dept. of Computer Science Dept. of Computing Science University of Toronto Simon Fraser University Toronto, Canada M5S lA4 Burnaby, Canada V5A lS6 hector@ai.toronto.edu mitchell@cs.sfu.ca Abstract We introduce a greedy local search procedure called GSAT for solving propositional satisfiability problems. Our experiments show that this procedure can be used to solve hard, randomly generated problems that are an order of magnitude larger than those that can be handled by more traditional approaches such as the Davis-Putnam procedure or resolution. We also show that GSAT can solve structured satisfiability problems quickly. In particular, we solve encodings of graph coloring problems, N-queens, and Boolean induction. General application strategies and limitations of the ap- proach are also discussed. GSAT is best viewed as a model-finding procedure. Its good performance suggests that it may be advan- tageous to reformulate reasoning tasks that have tra- ditionally been viewed as theorem-proving problems as model-finding tasks. Introduction The property of NP-hardness is traditionally taken to be the barrier separating tasks that can be solved com- putationally with realistic resources from those that cannot. In practice, to solve tasks that are NP-hard, it appears that something has to be given up: restrict the range of inputs; allow for erroneous outputs; use defaults outputs when resources are exhausted; limit the size of inputs; settle for approximate outputs, and so on. In some cases, this can be done in a way that preserves the essence of the original task. For exam- ple, perhaps erroneous outputs occur extremely rarely; perhaps the class of allowable inputs excludes only very large, unlikely, or contrived cases; perhaps the approxi- mate answers can be guaranteed to be close to the exact ones, and so on. In this paper, we propose an algorithm for an NP-hard problem that we believe has some very definite advantages. In particular, it works very quickly (relative to its competition) at the expense of what ap- pears to be statistically minimal errors. *Fellow of the Canadian Institute for Advanced Research, and E. W. R. Steacie Fellow of the Natural Sciences and Engineering Research Council of Canada. 440 Problem Solving: Constraint Satisfaction The first computational task shown to be NP-hard by Cook (1971) was propositional satisfiability, or SAT: given a formula of the propositional calculus, decide if there is an assignment to its variables that satisfies the formula according to the usual rules of interpreta- tion. Unlike many other NP-hard tasks (see Garey and Johnson (1979) f or a catalogue), SAT is of special con- cern to AI because of its direct connection to reasoning. Deductive reasoning is simply the complement of sat- isfiability: Given a collection of base facts C, then a sentence a should be deduced iff CU{TK) is not satisfi- able. Many other forms of reasoning (including default reasoning, diagnosis, planning, and image interpreta- tion) also make direct, appeal to satisfiability. The fact that these usually require much more than the propo- sitional calculus simply highlights the fact that SAT is both a fundamental task and a major stumbling block to effective reasoners. Though SAT is originally formulated as decision problem, there are two closely related search problems: 1. model-finding: find an interpretation of the variables under which the formula comes out true, or report that none exists. If such an interpretation exists, then the formula is obviously satisfiable. 2. theorem-proving: find a formal proof (in a sound and complete proof system) of the negation of the formula in question, or report that there is no proof. If a proof exists, then the negated formula is valid, and so the original formula is not satisfiable. Whereas much of the reasoning work in AI has favored theorem-proving procedures (and among these, resolu- tion is the favored method), in this paper, we investi- gate the behaviour of a new model-finding procedure called GSAT. We will also explain why we think that finding models may be a useful alternative for many AI reasoning problems. The original impetus for this work was the recent suc- cess in finding solutions to very large N-queens prob- lems, first using a connectionist system (Adorf and Johnston 1990), and then using greedy local search (Minton et al. 1990). To us, these results simply indi- cated that N-queens was an easy problem. We felt that such techniques would fail in practice for SAT. But this From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. appears not to be the case. The issue is clouded by the fact that some care is required to randomly generate SAT problems that are hard for even ordinary back- tracking methods. ’ But once we discovered how to do this (and see Mitchell et al. (1992) for details), we found that GSAT’s local search was very good at finding mod- els for the hardest formulas we could generate. Because model-finding is NP-hard, we cannot expect GSAT to solve it completely and exactly within toler- able resource bounds. What we will claim, however, is that the compromises it makes are quite reasonable. In particular, we will compare GSAT to another proce- dure DP (which is, essentially, a version of resolution adapted to model-finding) and demonstrate that GSAT has clear advantages. But there is no free lunch: we can construct satisfiable formulas for which GSAT may take an exponential amount of time, unless told to stop earlier. However, these satisfiable counter-examples do appear to be extremely rare, and do not occur naturally in the applications we have examined. In the next section, we give a detailed description of the GSAT procedure. We then present test results of GSAT on several classes of formulas. This is followed by a discussion of the limitations of GSAT and some po- tential applications. In the final section, we summarize our main results. The GSAT’ procedure GSAT performs a greedy local search for a satisfying assignment of a set of propositional clauses.2 The pro- cedure starts with a randomly generated truth assign- ment. It then changes (‘flips’) the assignment of the variable that leads to the largest increase in the to- tal number of satisfied clauses. Such flips are repeated until either a satisfying assignment is found or a pre- set maximum number of flips (MAX-FLIPS) is reached. This process is repeated as needed up to a maximum of MAX-TRIES times. See Figure 1. GSAT mimics the standard local search procedures used for finding approximate solutions to optimization problems (Papadimitriou and Steiglitz 1982) in that it only explores potential solutions that are “close” to the one currently being considered. Specifically, we ex- plore the set of assignments that differ from the current one on only one variable. One distinguishing feature of GSAT, however, is the presence of sideways moves, dis- ‘After the current paper was prepared for publication, we were surprised to discover that a procedure very similar to ours had been developed independently, and was claimed to solve instances of SAT substantially larger than those dis- cussed here (Gu 1992). It is tempting, however, to discount that work since the large instances involved are in fact easy ones, readily solvable by backtracking procedures like DP in a few seconds. 2A clause is a disjunction of literals. A literal is a propo- sitional variable or its negation. A set of clauses corresponds to a formula in conjunctive normal form (CNF): a conjunc- tion of disjunctions. Thus, GSAT handles CNF SAT. procedure GSA%’ Input: a set of clauses (Y, MAX-FLIPS, and MAX-TRIES Output: a satisfying truth assignment of cy, if found begin for i := 1 to MAX-TRIES T := a randomly generated truth assignment for j := 1 to MAX-FLIPS if T satisfies (Y then return T P := a propositional variable such that a change in its truth assignment gives the largest increase in the total number of clauses of cy that are satisfied by T T := T with the truth assignment of p reversed end for end for return “no satisfying assignment found” end Figure 1: The procedure GSAT. cussed below. Another feature of GSAT is that the variable whose assignment is to be changed is chosen at random from those that would give an equally good improvement. Such non-determinism makes it very un- likely that the algorithm makes the same sequence of changes over and over. The GSAT procedure requires the setting of two pa- rameters MAX-FLIPS and MAX-TRIES, which deter- mine, respectively, how many flips the procedure will attempt before giving up and restarting, and how many times this search can be restarted before quitting. As a rough guideline, setting MAX-FLIPS equal to a few times the number of variables is sufficient. The setting of MAX-TRIES will generally be determined by the to- tal amount of time that one wants to spend looking for an assignment, which in turn depends on the ap- plication. In our experience so far, there is generally a good setting of the parameters that can be used for all instances of an application. Thus, one can fine-tune the procedure for an application by experimenting with various parameter settings. It should be clear that GSAT could fail to find an assignment even if one exists, i.e. GSAT is incomplete. We will discuss this below. xperimental results We tested GSAT on several classes of formulas: ran- dom formulas, graph coloring encodings, N-queens en- codings, and Boolean induction problems. For purposes of comparison, we ran the tests with the Davis-Putnam procedure (DP) (D avis and Putnam 1960). The DP procedure DP is in essence a resolution procedure (Vellino 1989). It performs a backtracking search in the space of all truth assignments, incrementally assigning values to Selman, Levesque, and Mitchell 441 formulas Tars clauses 50 215 70 301 100 430 120 516 140 602 150 645 200 860 250 1062 300 1275 400 1700 500 2150 ( M-FLIPS 250 350 500 600 700 1500 I 2000 2500 6000 / 8000 10000 SAT tries 6.4 11.4 42.5 81.6 52.6 100.5 248.5 268.6 231.8 440.9 995.8 time 0.4s 0.9s 6s 14s 14s 45s 2.8m 4.lm 12m 34m 1.6h choices 77 42 84 x lo3 0.5 x lo6 2.2 x lo6 - UY depth 11 15 19 22 27 time 1.4s 15s 2.8m 18m 4.7h - Table 1: Results for GSAT and DP on hard random 3CNF formulas. variables and simplifying the formula. If no new vari- able can be assigned a value without producing an empty clause, it backtracks. The performance of the basic DP procedure is greatly improved by using unit propagation whenever unit clauses arise:3 variables oc- curring in unit clauses are immediately assigned the truth value that satisfies the clause, and the formula is simplified, which may lead to new unit clauses, etc. This propagation process can be executed’ quite effi- ciently (in time linear in the total number of literals). DP combined with unit propagation is one of the most widely used methods for propositional satisfiability test- ing. Hard random formulas Random instances of CNF formulas are often used in evaluating satisfiability procedures because they can be easily generated and lack any underlying “hidden” structure often present in hand-crafted instances. Un- fortunately, unless some care is taken in sampling for- mulas, random satisfiability testing can end up look- ing surprisingly easy. For example, Goldberg (1979) showed experimentally how DP runs in polynomial av- erage time on a class of random formulas. However, Franc0 and Paul1 (1983) demonstrated that the in- stances considered by Goldberg were so satisfiable that an algorithm that simply guessed truth assignments would find a satisfying one just as quickly as DP! This issue is discussed in detail in (Mitchell et al. 1992). Formulas are generated using the uniform distribu- tion or fixed-clause length model. For each class of for- mulas, we choose the number of variables N, the num- ber of literals per clause K, and the number of clauses L. Each instance is obtained by generating L random clauses each containing K literals. The K literals are generated by randomly selecting K variables, and each of the variables is negated with a 50% probability. As discussed in Mitchell et al. (1992), the difficulty of such formulas critically depends on the ratio between N and 3A unit clause is a clause that contains a single literal. 442 Problem Solving: Constraint Satisfaction L. The hardest formulas appear to lie around the region where there is a 50% chance of the randomly generated formula being satisfiable. For 3CNF formulas (I< = 3), experiments show that this is the case for L e 4.3N.4 We should stress that for different ratios of clauses to variables, formulas can become very easy. For example, DP solves 10,000 variable 20,000 clause 3SAT instances in a few seconds, whereas it cannot in practice solve 250 variable 1062 clause instances. In this paper, when we speak of random formulas we mean those in the hardest region only. Unsatisfiable formulas are of little interest when test- ing GSAT, since it will always (correctly) return “no satisfying assignment found” in time directly proposi- tional to (MAX-FLIPS x MAX-TRIES). So we first used DP to select satisfiable formulas to use as test cases. This approach is feasible for formulas contain- ing up to 140 clauses. For longer formulas, DP simply takes too much time, and we can no longer pre-select the satisfiable ones. In such cases, GSAT is tested on both satisfiable and unsatisfiable instances. Table 1 summarizes our results: first the number of variables and clauses in each formula, and then statis- tics for GSAT and DP. For formulas containing up to 120 variables, the statistics are based on averages over 100 satisfiable instances; for the larger formulas, the av- erage is based on 10 satisfiable formulas. For GSAT, we report the setting of MAX-FLIPS (in the header short- ened to M-FLIPS), how many tries GSAT took before an assignment was found, and the total time used in finding an assignment. 5 The fractional part of the num- ber of tries indicates how many flips it took on the final successful one. So, for example, 6.4 tries in the first row means that an assignment was not found in the first 6 4For more than 150 variables per formula, the ratio seems to converge to 4.25N. In table 1, we have used this ratio for the higher values of N. The exact ratio is not known; the theoretical derivation of the “50% satisfiable” point is a challenging open problem. 5Both GSAT and DP were written in C and ran on a MIPS machine under UNIX. tries of 250 flips, but on the 7th try, one was found after 0.4 x 250 = 100 flips. For DP, we give the number of bi- nary choices made during the search, the average depth of the search tree (ignoring unit propagation), and the time it took to find an assignment. First, note that for each satisfiable formula found by DP, GSAT had no trouble finding an assignment. This is quite remarkable in itself, since one might expect it to almost always hit some local minimum where at least a few clauses remain unsatisfied. But apparently this is not the case. Moreover, as is clear from table 1, the procedure is substantially faster than DP. The running time of DP increases dramatically with the number of variables with a critical increase occur- ring around 140 variables. This renders it virtually use- less for formulas with more than 140 variables.6 The be- havior of GSAT, on the other hand, is quite different: 300 variable formulas are quite manageable, and even 500 variable formulas can be solved. As noted above, the satisfiability status of these large test cases was ini- tially unknown. Nonetheless, GSAT did still manage to find assignments for a substantial number of them. (See Selman et al. (1992) for more details.) Now consider in table 1 the total number of flips used by GSAT to find an assignment and the total number of binary choices in the DP search tree. Again, we see a dramatic difference in the growth rates of these numbers for the two methods. This shows that the difference in running times is not simply due to some peculiarity of our implementation.7 So, GSAT appears to be well-suited for finding satisfying assignments for hard random formulas. Moreover, the procedure can handle much larger formulas (up to 500 variables) than DP (up to around 140 variables). Again, we should stress that we have shown these results for the hardest region of the distribution. Like most other procedures, GSAT also solves the “easy” cases quickly (Selman et al. 1992). Graph coloring In this section, we briefly discuss the performance of GSAT on graph coloring. Consider the problem of col- oring with I< colors a graph with V vertices such that no two nodes connected by an edge have the same color. We create a formula with I< variables for each node of the graph, where each variable corresponds to assign- ing one of the IC possible colors to the node. We have clauses that state that each node must have at least one color, and that no two adjacent nodes have the same color. 6A recent implementation of a highly optimized variant of DP incorporating several special heuristics is able to han- dle hard random formulas of up to 200 variables (Crawford and Auton, personal communication 1991). 71f the depth continues to grow at its current rate, the DP search tree for 500 variable formulas could have as many as 21°0 nodes. Even when processing lOlo nodes per second, DP could take 1Ol2 years to do a complete search. Johnson et al. (1991) evaluate state-of-the-art graph- coloring algorithms on instances of random graphs. We considered one of the hardest instances discussed: a 125 vertex graph for which results are given in table II of Johnson et al. (1991). The encoding that allows for 18 colors consists of 89,288 clauses with 2,250 variables, and an encoding that allows for only 17 colors consists of 83,272 clauses with 2,125 variables. GSAT managed to find the 18-coloring in approximately 5 hours. (DP ran for many more hours but did not find an assign- ment.) This is quite reasonable given that the running times for the various specialized algorithms in Johnson et al. ranged from 20 minutes to 1.7 hours. Unfortu- nately, GSAT did not find a 17-coloring (most likely optimal; Johnson (1991)). s This is perhaps not too surprising given that some of the methods in Johnson et al. couldn’t find one either, while another took 21.6 hours, and the fastest took 1.8 hours. Interestingly, some of the best graph-coloring methods are based on simulated annealing, an approach that shares some im- portant features with GSAT. So, although it is not as fast as the specialized graph- coloring procedures, GSAT can be used to find near op- timal colorings of hard random graphs. Moreover, the problem reformulation in terms of satisfiability does not result in a dramatic degradation of performance, con- trary to what one might expect. The main drawback of such an encoding appears to be the inevitable polyno- mial increase in problem size. N-queens In the N-queens problem one has to find a placement of N queens on a N x N chess board such that no queen attacks another. Although a generic solution to the problem is known (Falkowski et al. 1986), it is based on placing the queens in a very specific, regularly repeated pattern on the board. The problem of finding arbitrary solutions has been used extensively to test constraint satisfaction algorithms. Using standard backtracking techniques, the problem appears to be quite hard. But in a recent paper, Minton et al. (1990) h s ow how one can generate solutions by starting with a random placement of the queens (one in each row) and subsequently moving the queens around within the rows, searching for a solution. This method works remarkably well: their method appears to scale linearly with the number of queens.g To test GSAT on the N-queens problem, we first translate the problem into a satisfiability question: we ‘By using initial assignments that are not completely random, as suggested by Geoff Hinton, we have recently been able to solve also this instance (Selman et al. 1992). ‘There are, it should be mentioned, notable differences in Minton’s and our approaches. One is the use of sideways moves. This appears essential in satisfiability testing, dis- cussed below. Also, GSAT chooses the variable that gives the best possible improvement, while Minton’s program se- lects an arbitrary queen and moves it to reduce conflicts. Selman, Levesque, and Mitchell 443 formulas GSAT Queens vars clauses flips tries time 8 64 736 105 2 0.1s 20 400 12560 319 2 0.9s 30 900 43240 549 1 2.5s 50 2500 203400 1329 1 17s 100 10000 1.6~10~ 5076 1 195s Table 2: Results for GSAT on CNF encodings of the N-queens problem. use one variable for each of the N2 squares of the board, where intuitively, a variable is true when a queen is on the corresponding square. To encode the N-queens problem, we use N disjunctions (each with N variables) stating that there is at least one queen in each row, and a large number of binary disjunctions stating that there are no two queens in any row, column, or diagonal. Table 2 shows the performance of GSAT on these formu1as.l’ For N larger than 30, a solution is always found on the first try. l1 Also, the number of flips is roughly 0.5 N 2. This is near optimal, since a random truth assignment places about that many queens on the board, and most of them must be removed. (On the order of N flips are needed if one starts with ap- proximately N queens randomly placed on the board in the initial state (Selman et al. 1992).) One of the most interesting aspects of this approach is that so few natu- ral constraints (such as the obvious one of using only N queens) are maintained during the search. Nonetheless, solutions are found quickly. Boolean induction Promising results have recently been obtained using integer programming techniques to solve satisfiability problems (Hooker 1988; Kamath et al. 1991). Most of the experimental evaluations of these methods have been based on the constant-density random clause model, which unfortunately under-represents hard in- stances (Mitchell et al. 1992). To compare GSAT and these methods, we considered the formulas as studied by Kamath et al. (1991) in their work on Boolean induc- tion. In Boolean induction, the task is to derive (“in- duce”) a logical circuit from its input-output behavior. Kamath et al. give a translation of this problem into a satisfiability problem. They present test results for their algorithm on these formulas. We considered the formulas presented in table 4.4 in Kamath et al. (1991). Table 3 shows our results. The performance of GSAT is comparable to the integer programming method, which is somewhat surprising given its relative simplic- ity. Further testing is needed to determine whether “The size of our propositional encodings prevented us from considering problems with more than 100 queens. “For fewer queens it may sometimes take a second try. This happens rarely though; about 1 in every 100 tries. formula time id vars clauses Int. progr. GSAT 16Al 1650 19368 2039s 1061s 16Bl 1728 24792 78s 2764s 16Cl 1580 16467 758s 7s 16Dl 1230 15901 1547s 63s 16El 1245 14766 2156s 5s Table 3: Results for GSAT on encodings of Boolean induction problems as given table 4.4 of in Kamath et al. (1991). there are classes of formulas on which the methods be- have very differently. Limitations and sideways moves So far, we have concentrated mainly on the strengths of GSAT. But it does also have some important lim- itations. The following conjunction of clauses shows that it can be “misled” into exploring the wrong part of the search space (numbers stand for propositional variables): (1 v 72 v 3) A (lVl3V4) A (lvl4v-12) A (lv5v2) A (1 v 15 v 2) A (+vl6v7) A (dv-7V8) A (llVl98V99) A (4i:-99V6) A Note that although most of clauses here contain a neg- ative occurrence of variable 1, the formula can only be satisfied if variable 1 is assigned positively (see the first 5 clauses). The problem is that the greedy approach re- peatly steers the search towards a negative assignment, since this does satisfy so many of the clauses. The only way GSAT will solve this example is if starts a search very close to a satisfying assignment, which could take an exponential number of tries. Finally, we consider sideways moves. In a departure from standard local search algorithms, GSAT continues flipping variables even when this does not increase the total number of satisfied clauses.12 To show why this is important, we re-ran some experiments, but only allow- ing flips that increase the number of satisfied clauses, restarting otherwise. Table 4 gives the results. All formulas considered were satisfiable. We tried 100 instances of the random formulas. The %-solved column shows what percentage of those instances was solved. Note that quite often no assignment was found, despite a very large number of tries. For comparison, we included our previous data on these formulas. It is clear that finding an assign- ment becomes much harder without the use of sideways moves. 12We have also seen cases where an assignment was found after a sequence of flips containing some that decreused the number of satisfied clauses, but these are very rare. Here we ignore such flips. 444 Problem Solving: Constraint Satisfaction type formulas M-TRIES no sideway moves all moves vars clauses %-solved tries time %-solved tries time random 50 215 1000 69% 537 10s 100% 6 1.4s random 100 430 100,000 39% 63,382 15m 100% 81 2.8m 30-queens 900 43240 100,000 100% 50,000 30h 100% 1 2.5s Table 4: Comparing GSAT with and without sideway moves. (MAX-TRIES is shortened to M-TRIES.) Applieat ions As we noted above, GSAT is a sound but incomplete model-finding procedure: when it succeeds in finding an interpretation, we know that it is correct; but neg- ative answers, although perhaps suggestive, are not conclusive. The practical value of GSAT for theorem- proving purposes, where the concern is precisely for un- satisfiabibity, is therefore limited. Fortunately, certain AI tasks have naturally been characterized as model- finding tasks, for example, the visual interpretation task (Reiter and Mackworth 1990). In addition, it is often possible to reformulate tasks that have traditionally been viewed as theorem-proving problems as model- finding ones. One example is the formulation of plan- ning as a model-finding task (Kautz and Selman 1992), and we suspect that there will be many others. Another potential application of GSAT lies in the generation of “vivid” representations (Levesque 1986) as a way of dealing with the computational problems encountered in knowledge representation and reason- ing systems. Determining what can be deduced from a knowledge base is intractable in general, but not if the knowledge is vivid in form. So, instead of relying on general theorem-proving in a knowledge-based sys- tem, one could use a two-step operation: first, use a model-finding procedure like GSAT off-line to generate one or more vivid representations (or models) of what is known; then, as questions arise, answer them efficiently by appealing to these vivid representations. Efficient model-finding procedures like GSAT have therefore the potential of making the vivid reasoning approach and the related model-checking proposal by Halpern and Vardi (1991) workable.r3 Conclusions We have introduced a new method for finding satisfying assignments of propositional formulas. GSAT performs a greedy local search for a satisfying assignment. The method is simple, yet surprisingly effective. We showed how the method outperforms the Davis-Putnam proce- dure by an order of magnitude on hard random formu- las. We also showed that GSAT performs well on graph I3 Most applica tions of GSAT would require formulas of first-order logic. If the Herbrand universe in question is finite, the generalization is straightforward. Otherwise, one approach we intend to investigate is to use a form of iterutioe deepening by searching for models in ever larger Herbrand universes. coloring problems, N-queens encodings, and Boolean in- duction problems. The price we pay is that GSAT is incomplete. Currently, there is no good explanation for GSAT’s performance. Some recent results by Papadimitriou (1991) and Koutsoupias and Papadimitriou (1992) do, however, provide some initial theoretical support for the approach. Our sense is that the crucial factor here is having some notion (however crude) of an ap- proximate solution that can be refined iteratively. In these terms, model-finding has a clear advantage over theorem-proving, and may lead us to AI methods that scale up more gracefully in practice. Acknowledgments The second author was funded in part by the Natural Sciences and Engineering Research Council of Canada, and the Institute for Robotics and Intelligent Systems. We thank David Johnson for providing us with the hard instances of graph coloring and Anil Kamath for the inductive inference problems. We also thank Larry Auton, Ron Brachman, Jim Crawford, Matt Ginsberg, Geoff Hinton, David Johnson, Henry Kautz, David McAllester, Steve Minton, Christos Papadimitriou, Ray Reiter, Peter Weinberger, and Mihalis Uannakakis for useful discussions. References Adorf, H.M., Johnston, M.D. (1990). A discrete stochastic neural network algorithm for constraint satisfaction problems. Proc. of the Int. Joint Conf. on Neural Networks, San Diego, CA, 1990. Cook, S.A. (1971). Th e complexity of theorem-proving procedures. Proceedings of the 3rd Annual ACM Symposium on the Theory of Computing, 1971, 151- 158. Davis, M. and Putnam, H. (1960). A computing pro- cedure for quantification theory. J. Assoc. Comput. Mach., 1960, 7:201-215. Falkowski, Bernd-Jurgen and Schmitz, Lothar (1986). A note on the queens’ problem. Information Process. Lett., 23, 1986, 39-46. France, J. and Paull, M. (1983). Probabilistic analysis of the Davis Putnam procedure for solving the sat- isfiability problem. Discrete Applied Math. 5, 1983, 77-87. Garey, M.R. and Johnson, D.S. (1979). Computers Selman, Levesque, and Mitchell 445 and Intractability, A Guide to the Theory of NP- Completeness. W.H. Freeman, New York, NY, 1979. Goldberg, A. (1979). On the complexity of the satisfi- ability problem. Courant Computer Science Report. No. 16, New York University, NY, 1979. Gu, J. (1992). Effi cient local search for very large-scale satisfiability problems. Sigart Bulletin, vol. 3, no. 1, 1992, 8-12. Halpern, J.Y. and Vardi, M.Y. (1991) Model checking vs. theorem proving: a manifesto. Proceedings KR- 91, Boston, MA, 325-334. Hooker, J.N. (1988) Resolution vs. cutting plane solu- tion of inference problems: Some computational ex- perience. Operations Research Letter, 7(l), 1988. Johnson, D.S. (1991) P ersonal communication, 1991. Johnson, D.S., Aragon, C.R., McGeoch, L.A., and Schevon, C. (1991) Optimization by simulated an- nealing: an experimental evaluation; part ii, graph coloring and number partioning. Operations Re- search, 39(3):378-406, 1991. Kamath, A.P., Karmarkar, N.K., Ramakrishnan, K.G., and Resende, M.G.C. (1991). A continuous approach to inductive inference. Submitted for publication, Kautz, H.A. and Selman, B. (1992). Planning as satis- fiability. Forthcoming. Koutsoupias, E. and Papadimitriou C.H. (1992) On the greedy algorithm for satisfiability. Forthcoming. Levesque, H.J. (1986). Making believers out of com- puters. Artificial Intelligence, 30, 1986, 81-108. Minton, S., Johnston, M.D., Philips, A.B., and Laird, P. (1990) Solving 1 ar g e-scale constraint satisfaction an scheduling problems using a heuristic repair method. Proceedings AAAI-90, 1990, 17-24. Mitchell, D., Selman, B., and Levesque, H.J. (1992). Hard and easy distributions of SAT problems. Forth- coming. Papadimitriou, C.H. (1991). On selecting a satisfying truth assignment. Proc. of 32th Conference on the Foundations of Computer Science, 1991, 163- 169. Papadimitriou, C.H., Steiglitz, K. (1982). Combina- torial optimization. Englewood Cliffs, NJ: Prentice- Hall, Inc., 1982. Reiter, R. and Mackworth, A. (1989). A logical frame- work for depiction and image interpretation. Artifi- cial Intelligence, 41, No. 2, 1989, 125-155. Selman, B., Levesque, H.J., Mitchell, D. (1992) GSAT: A new method for solving hard satisfiability prob- lems. Technical Report, AT&T Bell Laboratories, 1992. Vellino, A. (1989) The complexity of automated rea- soning. Ph.D. thesis, Dept. of Philosophy, University of Toronto, Toronto, Canada (1989). 446 Problem Solving: Constraint Satisfaction | 1992 | 79 |
1,275 | A General- ach to Distri Michael I?. Wellman USAF Wright Laboratory WL/AAA-1 Wright-Patterson AFB, OH 45433 wellman@wl.wpafb.af.mil Abstract Market price mechanisms from economics consti- tute a well-understood framework for coordinat- ing decentralized decision processes with minimal communication. WALRAS is a general ‘(market- oriented programming” environment for the con- struction and analysis of distributed planning sys- tems, based on general-equilibrium theory. The environment provides basic constructs for defining computational market structures, and a procedure for deriving their corresponding competitive equi- libria. In a particular realization of this approach for a simplified form of distributed transportation planning, we see that careful construction of the decision process according to economic principles can lead to effective decentralization, and that the behavior of the system can be meaningfully ana- lyzed in economic terms. Distributed Plan In a &tributed or multiagent planning system, the plan for the system as a whole is a composite of plans produced by its constituent agents. Planning might be distributed because agents are separated geograph- ically, have different information, possess distinct capa- bilities or authority, or were designed and implemented separately. In any case, because each agent has limited competence and awareness of the decisions produced by others, some sort of coordination is required to max- imize the performance of the overall system. However, central control or extensive communication is deemed infeasible, as it violates whatever constraints dictated distribution of the planning task in the first place. The task facing the designer of a distributed plan- ning system is to define a computationally efficient co- ordination mechanism and its realization for a given or constructed configuration of agents. By the term agent, I refer to a module that acts within the mech- anism according to its own knowledge and interests. The capabilities of the agents and their organization in an overall decision-making structure determine the behavior of the overall system. Because it concerns the collective behavior of self-interested decision mak- ers, the design of this decentralized structure is fun- damentally an exercise in economics. The problem of developing architectures for distributed planning is largely one of mechanism de&gn [Hurwicz, 1977; Reiter, 19861, and many ideas and results from eco- nomics are directly applicable. In particular, the class of mechanisms based on price systems and competition has been deeply investigated by economists, who have characterized the conditions for its efficiency and com- patibility with other features of the economy. When applicable, the competitive mechanism achieves co- ordination with minimal communication requirements (in a precise sense related to the dimensionality of mes- sages transmitted among agents [Reiter, 19861). The theory of genera2 equilibrium [Hildenbrand and Kirman, 19761 provides the foundation for a general ap- proach to the construction of distributed planning sys- tems based on price mechanisms. In this approach, we regard the constituent planning agents as consumers and producers in an artificial economy, and define their individual activities in terms of production and con- sumption of commodities. Interactions among agents are cast as exchanges, the terms of which are mediated by the underlying economic mechanism, or protocol. By specifying the universe of commodities, the con- figuration of agents, and the interaction protocol, we can achieve a variety of interesting and often effective decentralized behaviors. Furthermore, we can apply economic theory to the analysis of alternative architec- tures, and thus exploit a wealth of existing knowledge in the design of distributed planners. In the following, I describe this general approach and a programming environment based on it. An ex- ample problem in distributed transportation planning demonstrates the feasibility of decentralizing a prob- lem with nontrivial interactions, and the applicability of economic principles to collective problem solving. Transportation Example In a simplified version of the transportation planning problem, the task is to allocate a given set of cargo movements over a given transportation network. The 282 Multi-Agent Coordination From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. transportation network is a collection of locations, with links (directed edges) identifying feasible transporta- tion operations. Associated with each link is a speci- fication of the cost of moving cargo along it. Suppose further that the cargo is homogeneous, and amounts of cargo are arbitrarily divisible. A movement require- ment associates an amount of cargo with an origin- destination pair. The planning problem is to deter- mine the amount to transport on each link in order to move all the cargo at the minimum cost. A distributed version of the problem would de- centralize the responsibility for transporting separate cargo elements. For example, planning modules cor- responding to geographically or organizationally dis- parate units might arrange the transportation for cargo within their respective spheres of authority. Or decision-making activity might be decomposed along hierarchical levels of abstraction, gross functional char- acteristics, or according to any other relevant distinc- tion. This decentralization might result from real dis- tribution of authority within a human organization, from inherent informational asymmetries and commu- nication barriers, or from modularity imposed to facil- itate software engineering. Consider, for example, the abstract transportation network of Figure 1, taken from Harker [1988].l There are four locations, with directed links as shown. Con- sider two movement requirements. The first is to trans- port cargo from location 1 to location 4, and the second in the reverse direction. Suppose we wish to decentral- ize authority so that separate agents (called shippers) decide how to allocate the cargo for each movement. The first shipper decides how to split its cargo units be- tween the paths 1 -i 2 -+ 4 and 1 --) 2 --) 3 --+ 4, while the second figures the split between paths 4 ---) 2 -+ 1 and 4 --3 2 -+ 3 4 1. Note that the latter paths for each shipper share a common resource: the link 2 ---) 3. Because of their overlapping resource demands, the shippers’ decisions appear to be necessarily inter- twined. In a congested network, for example, the cost for transporting a unit of cargo over a link is increas- ing in the overall usage of the link. A shipper planning its cargo movements as if it were the only user on a network would thus underestimate its costs and po- tentially misallocate transportation resources. For the analysis of networks such as this, transporta- tion researchers have developed equilibrium concepts describing the collective behavior of the shippers. In a Figure 1: A simple network (from Harker [1988]). system equilibrium, the overall transportation of cargo proceeds as if there were an omniscient central plan- ner directing the movement of each shipment so as to minimize the total aggregate cost of meeting the re- quirements. In a user equilibrium, the overall alloca- tion of cargo movements minimizes each shipper’s total cost, with shippers sharing proportionately the cost of shared resources. There are also some intermediate possibilities, corresponding to game-theoretic equilib- rium concepts such as the Nash equilibrium, where each shipper behaves optimally given the transporta- tion policies of the remaining shippers [Harker, 19861. From our perspective as designer of the distributed planner, we seek a decentralization mechanism that will reach the system equilibrium, or come as close as possible given the distributed decision-making struc- ture. In general, however, we cannot expect to derive a system equilibrium or globally optimal solution with- out central control. Limits on coordination and com- munication may prevent the distributed resource allo- cation from exploiting all opportunities and inhibiting agents from acting at cross purposes. But under cer- tain conditions decision making can indeed be decen- tralized effectively via market mechanisms. General- equilibrium analysis can help us to recognize and take advantage of these opportunities. The LEAS Environment To explore the use of market mechanisms for dis- tributed planning, I have developed a prototype envi- ronment for specifying and simulating computational markets. The system, called WALRAS,~ provides ba- sic mechanisms implementing various sorts of agents, auctions, and bidding protocols. To specify a compui tational economy, one defines a set of goods and instan- tiates a collection of agents that produce or consume those goods. The simulation engine of WALRAS then “runs” these agents to determine an equilibrium allo- cation of goods and activities in the economy. ‘Named for the 19th-century French economist Lion Walras, who was the first to envision a system of inter- connected markets in price equilibrium. ‘Models of this sort are empIoyed in transportation anal- ysis to predict cargo movements and hence characterize the effect of variations in transportation infrastructure or pol- icy. Their intent is descriptive, as the agents are private individuals or firms outside the policymaker’s control. Al- though the overall role of a planning system is to prescribe behavior, the designer of a distributed architecture also requires a descriptive model of the modules’ behavior to characterize the effect of alternative configurations and co- ordination mechanisms. Wellman 283 Market Configuration and Equilibrium Agents fall in two general classes. Consumers can buy, sell, and consume goods, and their preferences for con- suming various combinations of goods are specified by their utility function. Producers can transform some sorts of goods into some others, according to their tech- nology or production function. Each type of agent may start with an initial allocation of some goods, termed their endowment. The objective of a consumer is to maximize its utility, subject to the constraint (the bud- get constraint) that the cost of its consumption bundle does not exceed the value of its endowment at the go- ing prices. The objective of a producer is to maximize profits given the going price of its output good and the inputs required for its production (the factor goods). WALRAS associates an auction with each distinct good. Agents act in the market by submitting bids to auctions. The form of a bid is determined by the auction protocol. In a price mechanism, bids spec- ify a correspondence between prices and quantities of the good that the agent offers to demand or supply. The auction derives a market-clearing price, at which the quantity demanded balances that supplied, within some prespecified tolerance. When the current price is clearing with respect to the current bids, we say the market for that commodity is in equilibrium. An agent acts competitively when it takes prices as given, neglecting any impact of its own behavior on the market-clearing price. Perfect competition reflects individual rationality when there are numerous agents, each small with respect to the entire economy. How- ever, when an individual agent is large enough to affect prices significantly, it forfeits utility or profits by failing to take this into account. Under the assumption of perfect competition, each agent’s constrained optimization problem is parame- terized by the prices of goods. We say that an agent is in equilibrium if its set, of outstanding bids corre- sponds to the solution of its optimization problem at the going prices. If all the agents and commodity mar- kets are in equilibrium, the allocation of goods dic- tated by the auction results is a competitive equilib- rium. From the perspective of mechanism design, com- petitive equilibria possess several desirable properties, in particular, the two fundamental welfare theorems of general equilibrium theory: (1) all competitive equilib- ria are Pareto optimal (no agent can do better without some other doing worse), and (2) any Pareto optimum is a competitive equilibrium for some initial endow- ment. These properties seem to offer exactly what we need: a bound on the quality of the solution, plus the prospect that we can achieve the most desired behav- ior by carefully engineering the configuration of the computational market. Moreover, in equilibrium, the prices reflect exactly the information required for dis- tributed agents to optimally evaluate perturbations in their behavior without resorting to communication or reconsideration of their full set of possibilities. Corn put ing Corn pet it ive Equilibria Under certain “classical” assumptions (essentially con- tinuity, monotonicity, and convexity of preferences and technologies), competitive equilibria exist, and are unique given some further restrictions. They are also computable, and algorithms based on fixed-point methods [Scarf, 19841 and optimization (variational in- equality) techniques have been developed. Both sorts of algorithms in effect solve the simultaneous equilib- rium equations by convergent iteration. However, by employing the equilibrium equations, these techniques violate the decentralization considerations underlying our distributed planning application.3 For example, the constraint that profits be zero is a consequence of competitive behavior and constant-returns technology. Since information about, the form of the technology and bidding policy is considered private to producer agents, it would not be permissible to embed the zero-profit condition into the equilibrium derivation procedure, as is sometimes done in computable general-equilibrium models. Similarly, explicitly examining the joint com- modity space in the search for equilibrium undercuts our original motive for decomposing complex activities into consumption and production of separate goods. WALRAS’S procedure is a decentralized relaxation method, akin to Lhe mechanism of tatonnement orig- inally sketched by LCon Walras to explain how prices might be derived. A tatonnement method iteratively adjusts prices up or down as there is an excess of de- mand or supply, respectively (e.g., in proportion to the excess). The method employed by WALRAS suc- cessively computes an equilibrium price in each sepa- rate market, in a manner detailed below.4 Like taton- nement, it involves an iterative adjustment of prices based on reactions of the agents in the market. How- ever, it differs from traditional tatonnement procedures in that (1) agents submit supply and demand curves rather than single quantities for a particular price, and (2) the auction adjusts individual prices to clear, rather than the entire price vector by some function of sum- mary statistics such as excess demand. Figure 2 presents a schematic view of the WALRAS bidding process. There is an auction for each distinct good, and for each agent, a link to all auctions in which it has an interest. There is also a “tote board” of current prices, kept up-to-date by the various auctions. ‘These methods are typically applied to the analysis of existing decentralized structures, such as transporta- tion industries or even entire economies [Shoven and Whal- ley, 19841. B ecause our purpose is to implement a dis- tributed system, we must obey computationa distributiv- ity constraints not relevant to the usual purposes of applied general-equilibrium analysis. *This general approach is called “progressive equilibra- tion” by Dafermos and Nagurney [1989]. WALRAS per- forms progressive equilibration in their sense, but adopts a different model of market structure in general, and trans- portation networks in particular. 284 Multi-Agent Coordination tote board Figure 2: WALRAS'S bidding process. Gi denotes the auction for the ith good, and Ai the ith trading agent. Each agent maintains an agenda of bid tasks, spec- ifying the markets in which it must update its bid or compute a new one. In Figure 2, agent Aj has pending tasks to submit bids to auctions 61, G7, and 64. The bid for a particular good corresponds to one dimension of the agent’s solution to its constrained optimization problem, which is parameterized by the prices for all relevant goods. Acting as a perfect competitor, a WAL- RAS agent bids for a good under the assumption that prices for the remaining goods are fixed at their current values. The bid itself is a schedule of quantities and prices (encoded in any of a variety of formats) specify- ing the amount of the good demanded or supplied as its own price varies. As new bids are received at auction, the previously computed clearing price becomes obsolete. Periodi- cally, each auction computes a new clearing price (if any new or updated bids have been received) and posts it on the tote board. When a price is updated, this may invalidate some of an agent’s outstanding bids, since these were computed under the assumption that prices for remaining goods were fixed. On finding out about a price change, an agent augments its task agenda to include the potentially affected bids. At all times, WALRAS maintains a vector of going prices and quantities that would be exchanged at those prices. While the agents have nonempty bid agendas or the auctions new bids, some or all goods may be in disequilibrium. When all auctions clear and all agen- das are exhausted, however, the economy is in com- petitive equilibrium (up to some numeric tolerance). This process is highly distributed, in that each agent need communicate directly only with the auctions for the goods of interest (those in the domain of its utility or production function, or for which it has nonzero en- dowments). Each of these interactions concerns only a single good; auctions never coordinate with each other. Agents need not negotiate directly with other agents, nor even know of each other’s existence. It is well known that tatonnement processes may not converge to equilibrium (but convergent results are in- deed competitive equilibria) [Scarf, 19841. The class of economies in which tatonnement works are those with stable equilibria: those without complementari- ties in preferences or technologies [Arrow and Hurwicz, 19771. I have been unable thus far to characterize WAL- RAS'S adjustment process simply enough to analyze its dynamics mathematically. Similar progressive equili- bration algorithms are known to converge for certain special cases [Eydeland and Nagurney, 19891. Market-Oriented Programming As described above, WALRAS provides facilities for specifying market configurations and computing their competitive equilibrium. We can also view WALRAS as a programming environment for decentralized resource allocation procedures. The environment provides con- structs for specifying various sorts of agents and defin- ing their interactions via their relations to common commodities. After setting up the initial configura- tion, the market can be run to determine the equi- librium level of activities and distribution of resources throughout the economy. To cast a distributed planning problem as a mar- ket, one needs to identify (1) the goods traded, (2) the agents trading, and (3) the agents’ bidding behavior. Finally, it might be advantageous to adjust some gen- eral parameters of the bidding protocol. These design steps are serially dependent, as the definition of what constitutes an exchangeable or producible commodity severely restricts the type of agents that it makes sense to include. Below, I illustrate the design task with a WALRAS formulation of the transportation example. Implementation WALRAS is implemented in Common Lisp and the Common Lisp Object System (CLOS). The current version provides basic infrastructure for running com- putational economies, including the underlying bidding protocol and a library of CLOS classes implementing a variety of agent types. The object-oriented imple- mentation supports incremental development of mar- ket configurations. In particular, new types of agents can often be defined as slight variations on existing types, for example by modifying isolated features of the demand policy or bid format. Although it models a distributed system, WALRAS runs serially on a single processor. Distribution con- straints on information and communication are en- forced by programming and specification conventions rather than by fundamental mechanisms of the soft- ware environment. Asynchrony is simulated by ran- domizing the bidding sequences so that agents are called on unpredictably. Indeed, artificial synchroniza- tion can lead to an undesirable oscillation in the clear- ing prices, as agents collectively overcompensate for imbalances in the preceding iteration.5 ‘In some formal dynamic models [Huberman, 1988; Kephart et OZ., 19891, homogeneous agents choose instan- taneously optimal policies without accounting for others Wellman 285 The current experimental system runs transporta- tion models of the sort described in the next sec- tion, as well as some abstract exchange and produc- tionVeconomies with parameterized utility and produc- tion functions (including the expository examples of Scarf [1984] and Sh oven and Whalley [1984]). Cus- tomized tuning of the basic bidding protocol has not been necessary. In the process of getting WALRAS to run on these examples, I have produced some substan- tial intermediate object structure, but much more is re- quired to fill out a comprehensive taxonomy of agents, bidding strategies, and auction policies. goods that might serve their objectives: in this case, movement along links that belong to some simple path from the shipper’s origin to its destination. WALRAS Transportation Market Market Structure Figure 3: WALRAS market configuration for the exam- ple transportation network. The primary commodity of interest in this problem is The model we employ for transportation costs is movement of cargo. Because the value and cost of a based on a network with congestion, thus exhibiting cargo movement depends on location, we designate as diseconomies of scale. In other words, the marginal a distinct good capacity on each origin-destination pair and average costs (in terms of transportation resources in the network (see Figure 1). To capture the cost or required) are both increasing in the level of service input required to move cargo, we define another good on a link. Using Barker’s data, costs are quadratic.6 denoting generic transportation resources. In a more Let ci,j(z) denote the cost in transportation resources concrete model, these might consist of vehicles, fuel, (good Go) required to transport 2 units of cargo on labor, or other factors contributing to transportation. the link from i to j. The complete cost functions are: To decentralize the decision making, we identify two groups of agents. The consumers, or shippers, have an interest in moving various units of cargo between speci- fied locations. We identify each movement requirement with a single shipper agent. The producers, or carri- ers, have the capability to transport cargo units over specified links, given varying amounts of transporta- tion resources. In the model described here, we asso- ciate one carrier with each available link. To achieve a global movement of cargo, shippers obtain transporta- tion services from carriers in exchange for the necessary transportation resources. d4 = c2,1(4 = c&c) = c4,$4 = z2 + 202, c&l?) = c&z) = C~,~(~) = 2z2 + 52. Finally, each shipper’s objective is to transport 10 units of cargo from its origin to its destination. Agent ehavior The interconnectedness of agents and goods defines the market configuration. Figure 3 depicts the WAL- RAS configuration for the example network of Figure 1. Let Ci,j denote the carrier that transports cargo from location i to location j, and Gi,j the good representing an amount of cargo moved over that link. Each car- rier Ci,j is connected to the auction for Gi,j, its output good, along with Ge -its input in the production pro- cess. Shipper agents are also connected to Go, as they are endowed with transportation resources to exchange for transportation services. In this model there are two shippers, S1,4 and $,I, where Si,j denotes a shipper with a requirement to move goods from origin i to des- tination j. On the demand side, shippers connect to In the case of a decreasing returns technology, the pro- ducer’s (carrier’s) optimization problem has a unique solution. The optimal level of activity maximizes rev- enues minus costs, which occurs at the point where the output price equals marginal cost. Using this result, carriers submit supply bids specifying transportation services as a function of link prices (with resource price fixed), and demand bids specifying required resources as a function of input prices (for activity level com- puted with output price fixed). For example, consider carrier C~J. At output price pl,2 and input price po, the carrier’s profit is P1,2Y - POCl,Z(Y), where y is the level of service it chooses to supply. Given the cost function above, this expression is maxi- mized at y = (pl,z - 2Opo)/2pu. Taking po as fixed, the carrier submits a supply bid with y a function of pr,z. that are simultaneously making the same choice, detracting from its value. Oscillation occurs as the result of delayed feedback about the others’ decisions. I have also observed this phenomenon empirically in a synchronized version of WALRAS. By eliminating the synchronization, agents tend to work on different markets at any one time, and hence do not suffer as much from this time delay. ‘The quadratic cost model is posed simply for concrete- ness, and does not represent any substantive claim about transportation networks. The important qualitative fea- ture of this model is that it exhibits decreasing returns, a defining characteristic of congested networks. Note also that Harker’s model is in terms of monetary costs, whereas we introduce an abstract input good. 286 Multi-Agent Coordination On the demand side, the carrier takes pr,z as fixed and submits a demand bid for enough good Go to produce y, where y is treated as a function of PO. The bidding behavior of shippers is more compli- cated. Rather than explicitly consider utility maxi- mization, we take the shipper’s objective to be to ship as much as possible (up to its movement requirement) in the least costly manner. Given a network with prices on each link, the cheapest cargo movement corresponds to the shortest path in the graph, where distances are equated with prices. Thus, for a given link, a shipper would prefer to ship its entire quota on the link if it is on the shortest path, and zero otherwise. In the case of ties, it is indifferent among the possible allocations. To bid on link i, j, the shipper can derive the thresh- old price that determines whether it is on a shortest path by taking the difference in shortest-path distance between the networks where link i, j’s distance is set to zero and infinity, respectively. In incrementally changing its bids, the shipper should also consider its outstanding bids and the cur- rent prices. The value of reserving capacity on a par- ticular link is zero if it cannot get service on the other links on the path. Similarly, if it is already commit- ted to shipping cargo on a parallel path, it does not gain by obtaining more capacity (even at a lower price) until it withdraws these other bids.7 Therefore, the actual demand policy of a shipper is to spend its un- committed income on the potential flow increase (de- rived from maximum-flow calculations) it could obtain by purchasing capacity on the given link. It is will- ing to spend up to the threshold value of the link, as described above. This determines one point on its de- mand curve. If it has some unsatisfied requirement and uncommitted income it also indicates a willing- ness to pay a lower price for a smaller amount of ca- pacity. Boundary points such as this serve to bootstrap the economy; from the initial conditions it is typically the case that no individual link contributes to overall flow between the shipper’s origin and destination. Fi- nally, the demand curve is completed by an arbitrary smoothing operation on these points. costs. The derived cargo movements are correct to within 10% in 36 bidding cycles, and to 1% in 72, where in each cycle every agent submits an average of one bid to one auction. The total cost (in units of Go), its division between shippers’ expenditures and carriers’ profits, and the equilibrium prices are pre- sented in Table 1. That the decentralized process pro- duces a global optimum is perfectly consistent with competitive behavior -the carriers price their outputs at marginal cost, and the technologies are convex. Why, then, is the perfectly competitive model typi- cally associated with user equilibrium (UE)? The an- swer is that in most models (including Harker’s), car- riers are not expressly modeled as agents, and it is assumed that shippers share proportionately the ex- act cost of transportation. Under such a regime, the economic cost facing shippers is the average cost of shipment along a link. We can realize this policy in WALRAS by modifying the carriers’ supply policy so that they just cover their average cost. The resulting solution is indeed UE.8 The lesson from this exercise is that we can achieve qualitatively distinct results by simple variations in the market configuration or agent policies. From our de- signers’ perspective, we prefer the configuration that leads to the more transportation-efficient SE. Exami- nation of Table 1 reveals that we can achieve this result by allowing the carriers to earn nonzero profits (eco- nomically speaking, these are really rents on the fixed factor represented by the congested channel) and re- distributing these profits to the shippers to cover their increased expenditures9 Results With the configuration and agent behaviors described, WALRAS derives the system equilibrium (SE), that is, the cargo allocation minimizing overall transportation 7Even if a shipper could simultaneously update its bids in all markets, it would not be a good idea to do so here. A competitive shipper would send all its cargo on the least costly path, neglecting the possibility that this demand may increase the prices so that it is no longer cheapest. This policy can cause perpetual oscillation. In the example network, the unique equilibrium has each shipper routing portions of its cargo on all available paths. Policies allocat- ing all cargo to one path can never lead to this result, and hence convergence to competitive equilibrium depends on the incrementality of bidding behavior. (S 0 One serious limitation of WALRAS is the assumption that agents act competitively. There are two ap- proaches toward alleviating this restriction in a com- putational economy. First, we could simply adopt models of imperfect competition, perhaps based on specific forms of imperfection (e.g., spatial monopo- listic competition) or on general game-theoretic mod- els. Second, as architects we can configure the mar- kets to promote competitive behavior. For example, decreasing the agent’s grain size and enabling free en- try of agents should enhance the degree of competi- tion. Perhaps most interestingly, by controlling the ‘Average-cost pricing is perhaps the most common mechanism for allocating costs of a shared resource. Shenker [1991] points out problems with this scheme- with respect to both efficiency and strategic behavior-in the context of allocating access to congested computer net- works, a problem analogous to our transportation task. ‘In the mode 1 of general equilibrium with production, consumers own shares-in the producers’ profits. This closes the loop so that all value is ultimately realized in consump tion. We can specify these shares as part of the initial con- figuration, just like the endowment. In this example, we d&tribute the shares evenly between the two shippers. Wellman 287 pricing total cost shipper carrier P&2 P2,I P2,3 P2,4 P3,I P3,4 P4,2 marginal cost (SE) 1136 1514 378 40.0 35.7 22.1 35.7 13.6 13.6 40.0 average cost (UE) 1143 1143 0 30.0 27.1 16.3 27.1 10.7 10.7 30.0 Table 1: Equilibria derived by WALRAS for the transportation example. Total cost = shipper expense -carrier profit. agents’ knowledge of the market structure (via stan- dard information-encapsulation techniques), we can degrade their ability to exploit whatever market power they possess. Uncertainty has been shown to increase competitiveness among risk-averse agents in some for- mal bidding models [McAfee and McMillan, 19871, and in a computational environment we have substantial control over this uncertainty. The existence of competitive equilibria and efficient market allocations also depends critically on the as- sumption of nonincreasing returns to scale. Although congestion is a real factor in transportation networks, for many modes of transport there are often other economies of scale and density that may lead to re- turns that are increasing overall [Harker, 19871. Having cast WALRAS as a general environment for distributed planning, it is natural to ask how univerd sal “market-oriented programming” is as a computa- tional paradigm. We can characterize the computa- tional power of this model easily enough, by corre- spondence to the class of convex programming prob- lems represented by economies satisfying the classical conditions. However, the more interesting issue is how well the conceptual framework of market equilibrium corresponds to the salient features of distributed plan- ning problems. Although it is too early to make a definitive assertion about this, it seems clear that many planning tasks are fundamentally problems in resource allocation, and that the units of distribution often cor- respond well with units of agency. Economics has been the most prominent (and arguably the most successful) approach to modeling resource allocation with decen- tralized decision making, and it is reasonable to sup- pose that the concepts economists find useful in the so- cial context will prove similarly useful in our analogous computational context. Of course, just as economics is not ideal for analyzing all aspects of social interaction, we should expect that many issues in the organization of distributed planning will not be well accounted-for in this framework. Finally, the transportation network model presented here is a highly simplified version of the actual planning problem for this domain. A more realistic treatment would cover multiple commodity types, discrete move- ments, temporal extent, hierarchical network struc- ture, and other critical features of the problem. Some of these may be captured by incremental extensions to the simple model, perhaps applying elaborations de- veloped by the transportation science community.1° “For example, many transportation models (including 288 Multi-Agent Coordination Rdated Work The techniques and models described here obviously build on much work in economics and transportation science. The intended research contribution here is to neither of these fields, but rather in their application to the construction of a computational framework for de- centralized decision making in general and distributed transportation planning in particular. The basic idea of applying economic mechanisms to coordinate distributed problem solving is not new to the AI community. Starting with the contract net [Davis and Smith, 19831, many have found the metaphor of markets appealing, and have built sys- tems organized around markets or market-like mecha- nisms [Malone et al., 19881. Miller and Drexler [1988] have explored this approach in depth, presenting some underlying rationale and addressing specific issues salient in a computational environment. Recently, Waldspurger et al. [1992] have developed computa- tional market mechanisms to allocate computational resources in a distributed operating system. For fur- ther remarks on this line of work, see [Wellman, 19911. WALRAS is distinct from these prior efforts in two primary respects. First, it is constructed expressly in terms of concepts from general equilibrium theory, to promote mathematical analysis of the system and fa- cilitate the application of economic principles to ar- chitectural design. Second, WALRAS is designed to serve as a general programming environment for im- plementing computational economies. Although not developed specifically to allocate computational re- sources, there is no reason these could not be included in market structures configured for particular applica- tion domains. Indeed, the idea of grounding measures of the value of computation in real-world values (e.g., cargo movements) follows naturally from the general- equilibrium view of interconnected markets, and is one of the more exciting prospects for future applications of WALRAS to distributed problem-solving. Finally, market-oriented programming shares with Shoham’s [ 19901 agent- oriented programming the view that distributed problem-solving modules are best de- signed and understood as rational agents. The two approaches support different agent operations (trans- Harker’s more elaborate formulation [Harker, 19871) allow for variable supply and demand of the commodities and more complex shipper-carrier relationships. Concepts of spatial price equilibrium, based on markets for commodities in each location, seem to offer the most direct approach to- ward extending the transportation model within WALRAS. actions versus speech acts), adopt different rational- ity criteria, and emphasize different agent descriptors, but are ultimately aimed at achieving the same goal of specifying complex behavior in terms of agent con- cepts (e.g.s belief, desire, capability) and social orga- nizations. Combining individual rationality with laws of social interaction provides perhaps the most natural approach to generalizing Newell’s [1982] “knowledge level analysis” idea to distributed computation. Conclusion In summary, WALRAS represents a general approach to the construction and analysis of distributed planning systems, based on general equilibrium theory and com- petitive mechanisms. The approach works by deriving the competitive equilibrium corresponding to a partic- ular configuration of agents and commodities, specified using WALRAS'S basic constructs for defining computa- tional market structures. In a particular realization of this approach for a simplified form of distributed trans- portation planning, we see that qualitative differences in economic structure (e.g., cost-sharing among ship- pers versus ownership of shared resources by profit- maximizing carriers) correspond to qualitatively dis- tinct behaviors (user versus system equilibrium). This exercise demonstrates that careful design of the dis- tributed decision structure according to economic prin- ciples can sometimes lead to effective decentralization, and that the behaviors of alternative systems can be meaningfully analyzed in economic terms. Acknowledgment I have benefited from discussions of computational economies with several colleagues, and would like to thank in particular Jon Doyle, Anna Nagurney, Scott Shenker, Carl Waldspurger, and Martin Weitzman for helpful comments and suggestions. References Arrow, Kenneth J. and Hurwicz, Leonid, editors 1977. Studies in Resource Allocation Processes. Cambridge University Press, Cambridge. Dafermos, Stella and Nagurney, Anna 1989. Supply and demand equilibration algorithms for a class of market equilibrium problems. Transportation Science 23~118-124. Davis, Randall and Smith, Reid G. 1983. Negotia- tion as a metaphor for distributed problem solving. Artijikiab Intelligence 20:63-109. Eydeland, Alexander and Nagurney, Anna 1989. Pro- gressive equilibration algorithms: The case of linear transaction costs. Computer Science in Economics and Management 2:197-219. Harker, Patrick T. 1986. Alternative models of spatial competition. Operations Research 34:410-425. Harker, Patrick T. 1987. Predicting Intercity Freight Flows. VNU Science Press, Utrecht, The Netherlands. Harker, Patrick T. 1988. Multiple equilibrium behav- iors on networks. Transportation Science 22:39-46. Hildenbrand, W. and Kirman, A. P. 1976. Introduc- tion to Equilibrium Analysis: Variations on Themes by Edgeworth and Walras. North-Holland Publishing Company, Amsterdam. Muberman, B. A., editor 1988. The Ecology of Com- putation. North-Holland. Hurwicz, Leonid 1977. The design of resource alloca- tion mechanisms. In Arrow and Hurwicz [1977]. 3-37. Reprinted from American Economic Review Papers and Proceedings, 1973. Kephart, J. 0.; Hogg, T.; and Huberman, B. A. 1989. Dynamics of computational ecosystems. Physical Re- view A 40:404-421. Malone, T. W.; Fikes, R. E.; Grant, K. R.; and Howard, M. T. 1988. Enterprise: A market-like task scheduler for distributed computing environments. In Huberman [1988]. 177-205. McAfee, R. Preston and McMillan, John 1987. Auc- tions and bidding. Journal of Economic Literature 25:699-738. Miller, Mark S. and Drexler, K. Eric 1988. Markets and computation: Agoric open systems. In Huberman [1988]. 133-176. Newell, Allen 1982. The knowledge level. Artijiciab Intelligence 18:87-127. Reiter, Stanley 1986. Information incentive and per- formance in the (new)2 welfare economics. In Reiter, Stanley, editor 1986, Studies in Mathematical Eco- nomics. MAA Studies in Mathematics. Scarf, Herbert E. 1984. The computation of equilib- rium prices. In Scarf, Herbert E. and Shoven, John B., editors 1984, Applied General Equilibrium Analysis. Cambridge University Press, Cambridge. l-49. Shenker, Scott 1991. Congestion control in computer networks: An exercise in cost-sharing. Prepared for delivery at Annual Meeting of the American Political Science Association. Shoham, Yoav 1990. Agent-oriented programming. Technical Report STAN-CS-90-1335, Stanford Uni- versity Computer Science Department. Shoven, John B. and Whalley, John 1984. Applied general-equilibrium models of taxation and interna- tional trade: An introduction and survey. Journal of Economic Literature 22:1007-1051. Waldspurger, Carl A.; Hogg, Tad; Huberman, Bernard0 A.; et al. 1992. Spawn: A distributed com- putational economy. IEEE Transactions on Software Engineering 18:103-117. Wellman, Michael P. 1991. Review of Huber- man [1988]. Artificial Intelligence 52:205-218. Wellman 289 | 1992 | 8 |
1,276 | n the Minimalbity and eeo onstraint Networ Department of Computing Science University of Alberta, Edmonton, Alberta, Cana.da T6G 2Hl vanbeek@ks.ualberta.cas Abstract Constraint networks have been shown to be use- ful in formulating such diverse problems as scene labeling, natural language parsing, and temporal reasoning. Given a constraint network, we often wish to (i) find a solution that satisfies the con- straints and (ii) find the corresponding minimal network where the constraints are as explicit as possible. Both tasks are known t.o be NP-complete in the general case. Task (i) is usually solved us- ing a backtracking algorithm, and task (ii) is of- ten solved only approximately by enforcing vari- ous levels of local consistency. In this paper, we identify a property of binary constraints called rozu convesity and show its usefulness in deciding when a form of local consistency called path consistency is sufficient to guarantee a network is both min- imal and decomposable. Decomposable networks have the property that a solution can be found without backtracking. We show that the row con- vexity property can be tested for efficiently and we show, by examining applications of constraint networks discussed in the literature, that our re- sults are useful in practice. Thus, we identify a large class of constraint networks for which we can solve both tasks (i) and (ii) efficiently. 1 Introduction Constraint networks have been shown to be useful in forlnulating such diverse problenls as gra.ph color- ing [Montanari, 19741, scene labeling [Huffnlan, 1971; Waltz, 19751, natural langua.ge parsing [Maruyama, 19901, and temporal reasoning [Allen, 1983; van Beek, 19901. A constraint network is defined by a set of vari- ables, a domain of values for each variable, and a set of constraints between the variables. Given a constraint network, we often wish to (i) find a solution-an in- stantiation of the variables that sa.tisfies the constraints and (ii) find the corresponding minimal network where the constraints are as explicit as possible. Finding t,he minimal network has application& in removing redun- dant information from a knowledge base [Meiri ei al., 19901 and temporal rea.soning [va.u Beek, 19891. How- ever, both tasks are known to be NP-complete in the general case. Task (i) is usually solved using a back- tracking algorithm, which is exponential in the worst, case but, is often useful in practice, and task (ii) is often solved only approximately by enforcing various levels of local consistency. In this paper, we identify a property of binary con- straints called r’ow convexity and show its usefulness in deciding when a form of local consistency called path consistency is sufficient to guarantee a network is both minimal and decomposable. Decomposable networks have the property that a solution can be found without backtracking. In particular, we first show that, if all of the binary constraints are taken from a language that is closed under composition, intersection, and transpo- sition and for which the binary constraints are all row convex, then we can guarantee a priori that the result of path consistency will be the minimal network and that the network will be decomposable. Second, we show tha.tO a large class of networks can be shown to have the row convexity property after path consistency. If such is the case, then the network is minimal and decompos- able. Third, we show tha.t, if there exists an ordering of the variables and of the domains of the variables such that, the binary constraints can be made row convex, then a solution can be found without backtracking. We also show that the row convexity property can be tested for efficiently and we show, by examining applications of constraint networks discussed in the literature, that our result#s a.re useful in practice. Thus, we identify a large class of constraint networks for which we can solve both tasks (i) and (ii) efficiently. 2 Background We begin with some needed definitions and describe re- lated work. A network of binary constraints [Montanari, 19741 is defined a.s a set X of n variables (21, x2, . . . . xn}, a do- main Di of possible values for each variable, and binary constraints between variables. A binary constraint or relation, Rij, between variables zi and xj, is a subset of the Cartesia.n product of their domains that spec- ifies t,he allowed pairs of values for xi and xj (i.e., Rij C Di x Dj ). For the networks of interest here, we require that (zJ~, xi) E Rji e (xi, xi) E Rij. An insfcr.nfintion of the variables in S is an n-tuple (Xl) x2, . ..) S,,), representing an assignment of Xi E Di to xi. A comisfenf instantintion of a. network is an in- st,antiation of the variables such that the constraints van Beek 447 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. between variables are satisfied. A consistent instanti- ation is also called a solution. A network is minim.ul if each pair of values allowed by the constraints par- ticipates in atI least one consistent, instantiation (i.e, if (xi, xi) E Rij, then (x;, xj) is part of some consistent instantiation of the network). Mackworth [1977; 19871 defines three properties of networks that characterize local consistency of net- works: node, arc, and path consistency. A network is path consistent if and only if, for every triple (xi, xk, xj) of variables, we have that, for every instantiation of xi and.xj that satisfies the direct relation, Rij, there exists an instantiation of CC~ such that Rik and Rkj are also satisfied. Montanari [1974] and Mackworth [1977] pro- vide algorithms for achieving path consistency. Freucler [1978] generalizes this to k-consistency. A network is k-con.sistent if a,nd only if given any instantiation of any k - 1 variables satisfying all the direct relations among those variables, there exists an instantiation of any kth variable such that the k values taken together satisfy all the relations among the k variables. Freuder [1982] de- fines strongly k-consistent as j-consistent for a.11 j 5 k. Node, arc, and path consistency correspond to strong one-, two-, and three-consistency, respectively. A strongly n-consistent network is called decompos- abEe. Decomposable networks have the property that any consistent instantiation of a subset of the varia.bles can be extended to a consistent instantiation of all of the variables without ba.cktracking [Dechter, 19901. A strongly n-consistent network is also minimal. However, the converse is not true as it, is possible for a network to be minimal but not strongly n-consistent. Following Montanari [1974], a binary relation Rij be- tween variables xi and zj is represented as a (O,l)- matrix with lDi ] rows and IDj ] columns by imposing an ordering on the domains of the variables. A zero en- try at row a, column b means that the pair consisting of the ath element of Di and the bth element, of Dj is not permitted; a one entry means the pair is permitted. A (O,l)-matrix is row convex if and only if in each row all of the ones are consecutive; that is, no two ones within a single row are separated 1)~ a zero in that same row. A binary relation R represented as a (O,l)-ma.trix is monotone if and only if the following conditions hold: if Rij = 1 a.nd k > i, then Rkj = 1, and if Rij = 1 and k 5 j, then Rik = 1. A binary relation R represented as a (O,l)-matrix is fun.ctionaZ if and only if there is at most one one in each row and in each column of R. We use a graphical notation where vertices represent variables and directed a.rcs are labeled with the con- straints between variables. As a graphical convention, we never show the edges (i, i), and if we show the edge (i, j), we do not show the edge (j, i). Any edge for which we have no explicit knowledge of the constraint is labeled with the (0,l) -ma.trix coiisisting of all ones; by convention such edges are also not shown. For example, consider the simple constraint network with va.riables xi and 22 and domains D1 = {a, 6, c} and 02 = {d, e, f}, shown below. 011 R12 = 1 1 010 110 The constraint 1212 does not a.llow, for example, the pair (a,d) but does allow the pa.irs (Q, e), (u, f). It can be seen that the constraint has the row convexity property. 2.1 Related work Much work has been done on identifying restrictions on constraint0 networks such that finding a solution and finding the minimal network can be done efficiently. These restrictions fall into two classes: restricting the topology of the underlying gra.ph of the network and restricting the type of the allowed constraints between variables. For work that falls into the class of restricting the topology, Montanari [1974] , 1 s lows that, if the constraint graph is a tree, path consistency is sufficient to ensure a network is minimal. Freuder [1982; 19851 identifies a relationship between a property called the width of a constraint graph and the level of local consistency needed to ensure a solution can be found without back- tracking. As a special case, if the constraint graph is a tree, arc consistency is sufficient to ensure a solution can be found without backtracking. Dechter and Pearl [1988] provide an adaptive scheme where the level of local consistency is adjustecl on a node-by-nocle basis. Freuder [1990] g eneralizes the results on trees to k-t#rees. For work that falls into the class of restricting the type of the constraints (the class imo which the present work falls), Decht,er [1990] identifies a relationship be- tween the size of the doma.ins of the variables and the level of local consistency needed to ensure the network is strongly n-consistent, and t3hus minimal and decom- posable. Montanari [1974] shows that path consistency is sufficient, to guarantee a network is both minimal and clecomposable if t’he relations are monotone, and Dev- ille and Van Hentenryck [1991] show that arc consis- tency is sufficient to test the satisfiability of networks with only functional and monotone constraints. Func- tional and monotone relations are row convex; hence, it will be seen that our results generalize Montanari’s and extend Deville and Van Hentenryck’s results. Im- portantly, in the above work, the problem of deciding whether the constraints have t,he desired properties is left to the user. We identify an efficient procedure for deciding whether a constraint network can be made row convex. Finally, for work t’hat falls into both classes, Dechter and Pearl [1991] present, effective procedures for deter- mining whether a constra.int network can be formulated as a cn~qnl theory and thus a solution can be found with- out backt#racl;ing. Whether a constraint network can be so formulated depends on the topology of the underly- ing constraint graph and the type of the constraints. 448 Problem Solving: Constraint Satisfaction 3 A SuEieient PreCondition Informally, the basic result of this section is tha.t if we know that the result of applying path consistency will be that all of the relations will be row convex, we can guarantee a priori that path consistency will find the minimal network and the minimal network will be de- composable. To use the path consistency algorithms, three operations on relations are needed: composition, intersection, and inverse ‘. Thus, if the relations in our constraint network are row convex and remain row con- vex under these operations, the result applies. More formally, the following lemma on the intersec- tion of (O,l)- row vectors that are row convex, is needed in the proof of the result. Lemma 1 Let F be a finite collection of (O,l)-row vec- tors that are row convex and of equal length such that every pair of row vectors in F have a non-zero entry in common; that is, their intersection is not the vector with all zeroes. Then all the row vectors an F have a non-zero en.try in common. Theorem 1 Let L be a set of (O,l)-matrices closed un- der composition, intersection, and transposition such that each element of L is row colzvex. Let R be a bi- nary constraint netzoork with all re1ation.s taken from L. The path consistency algorithm will correctly deier- mine the m,ininzal network of R. Further, the minimal network will be decomposable. Froof. The theorem is proved by showing that if all (O,l)-matrices are from C and the network is made path consistent, then the network is k-consistent for all k 5 n. Hence, the network is strongly n-consistent and therefore the network is minimal. To show that the network is k-consistent for all k 5 I?,, we show that it is true for a.n arbitra.ry k. Suppose thatV variables 21, . , . , ok- 1 can be cousistently instantiated. That is, let X1, . . . , X k-1 be an instantiation such that Xi Rij Xj i,j = l,...,k- 1 is satisfied. To show that the network is k-consistent, we must show that there exists at least one instantia.tion of varia.ble xk such that Xi Rik xk i= l,...,b- 1 (1) is satisfied. We do so as follows. The X1, . . ., Xk- 1 re- strict the allowed instantiations of xk. For each i in Eqn. 1, the non-zero entries in row Xi of the (O,l)- matrix Rik: are the allowed instantiations of xk. The key is tl1a.t all of these row vectors are row convex, i.e., the ones a.re consecutive. Hence, by Lemma. 1 it is suffi- cient to show tha.t any two row vectors have a non-zero entry in common to show that, they a,11 have a non-zero ‘When the relations are represented as (O,l)-matrices, these operations correspond to binary matrix multiplication, binary matrix intersection, and transposition of the ma- trix, respectively. The reader may consult [Montanari, 1974; Mackworth, 19771 for the details. entry in common. But this follows directly from the def- inition of path consistency. Hence, a.11 the constraints have a non-zero entry in common and there exists at least one instantiation of zk that satisfies Eqn. I for all i. IBecause we require that xj Rjixi e xi Rajxj we have also shown that, there exists at least one instantiation of variable xk such that xk REi Xi i= l,...,k- 1 is satisfied. Hence, we have shown that, for sistent instantiation of k - 1 variables, there insta.ntiation of a.ny kth variable such that any con- exists an Xi Rij Xj i,j= I,...,k is satisfied. Hence, the network is k-consistent. 0 The proof of the Theorem 1 is constructive and gives an algorithm for finding a consistent instantia- tion. Without loss of genera.lity, we assume the order of instantiation of the variables is x1, . . . , x,. INSTANTIATE(R) 1. choose an instantiation X1 of x1 that satisfies RI1 2. fori+ ton 3. do r + [l 1 ... l] 4. for j + 1 to i - 1 5. do r + rn(rowXj OfRji) 6. choose a.n instantiation Xi of xi that satisfies r Intersecting two row vectors in Step 5 takes O(d) time, hence the algorithm is O(dn2), where n is the number of variables and d is the size of the domains. The pa.th con- sistency procedure is O(n3) [Mackworth and Freuder, 19851. So, we ca.n find a solution and the minimal net- work for the class of constraint networks characterized by Theorem 1 in O(max(dn2, n3)) time. Example 1. Let the domains of the variables be of size two. The set of all 2 x 2 (O,l)-matrices is closed under composition, intersection, and t’ra.nsposition and each 2 x 2 (O,l)-matrix is row convex. Hence, the theo- rem applies to all constraint networks with domains of size two. As a specific example, the Graph 2-coloring problem can be formulated using such constraint net- works. Dechter [1990, p.2331 also shows, but by a dif- ferent method, that a strong 3-consistent (or path con- sistent) bi-va.lued network is minimal. Example 2. Let the domains of the variables be fi- nite subsets of the integers and let a binary constraint between two variables be a conjunction of linear inequal- ities of the form c1xi + bx:j < c or axi + bxj 5 c, where u, b, and c are rational constant,s. For example, the conjunction (32i + 2Xj < 3) A (-4Xi + 5Xj < 1) - is an allowed constraint between variables xi and xj. A network with constraints of this form ca.n be viewed as an int’eger linear program where each constraint is in two variables and the domains of the variables are van Beek 449 restricted to be finite subsets of the integers. It can be shown that each element in the closure under composi- tion, intersection, and transposition of the resulting set of (O,l)-matrices is row convex. Hence, by Theorem 1 we can guarantee that the result of path consistency will be the minimal network and the network will be decomposable. Two special cases are a restricted and discrete version of Dechter, Meiri, and Pearl’s [1991] continuous, bounded difference framework for temporal reasoning and a restricted and discrete version of Vilain and Kautz’s [1989] qualitative framework for tempora.1 reasoning. 4 Sufficient PostConditions Informally, the basic result of this section is that if we have applied path consistency to a network and the re- lations are row convex or can be made row convex, t’hen the network is minimal and decomposable. We also show that a known procedure from graph theory can be used for deciding whether a constraint network can be made row convex. Theorem 2 Let R be a path consistent binary con- straint network. If there exists an ordering of the do- mains Dl,. . ., D, of R such that ihe (O,l)-matrices are row convex, the network is minimal and decomposable. Example 3. Scene labeling in computer vision [Huff- man, 1971; Clowes, 19711 can be formulated a.s a. prob- lem on constraint networks. We use an example to il- lustrate the applica.tion of Theorem 2. Fig. 2 shows the variables in the constraint network and the constraints; Fig. 1 shows the domains of the variables and the order- ing imposed. For example, va.riable ~1 in Fig. 2 is a fork and can be instantiated with any one of the five label- ings shown in Fig. 1. The constraints between va.riables are simply that, if two variables share an edge, then the edge must be labeled the same at both ends. Not all of the constraints are row convex. However, once the path consistency algorithm is applied, the relations become row convex. Therefore, in this example, no reordering of the domains is needed in order to satisfy the theorem. Procedure Instantiate from the previous section can be used to find a solution. The four possible solutions are shown in Fig. 3. Arrow: + + - - e++ Figure 1: Huffman-Clowes junction labelings R24 = RZT = R5,j = &6 = R34 = R57 = 01100 &I = 1 10000 10000 1 01010 R31 = [ 10000 10000 1 01001 Ral = 1 10000 10000 1 Figure 2: Scene labeling constraint network The scene-labeling problem has been shown to be NP- complete in the general case [Kirousis and Papadim- itriou, 19851. We are attempting to prove the conjec- ture that constraint networks arising from orthohedral scenes are row convex once pa.th consistency is applied. w Figure 3: Solutions: (a) stuck on left wall, (b) stuck on right wall, (c) suspended in mid-air, (d) resting on floor. As noted in the previous example, when constructing a constraint network and the (O,l)-matrices that repre- sent the constraints, we must impose an ordering on the domains of the variables. Sometimes a natural order- ing exists, as when the domain is a finite subset of the integers, but often the ordering imposed is arbitrary and with no inherent meaning. An unlucky ordering may hide the fact that the constraint network really is row convex or, more properly, can be made row convex. How can we distinguish this case from the case where no ordering of the domains will result in row convexity? 450 Problem Solving: Constraint Satisfaction The following theorem property efficiently. SllOWS that we can test for this Theorem 3 (Booth and Lueker [1976]) An m x n (O,l)-matrix specified by its f nonrero entries can be tested for whether a permutation of the columns exists such that the matrix is row convex in O(m + n + f) steps. Example 4. Maruyama [1990] shows that natural language parsing can be formulated as a problem on constraint networks. In this framework, intermediate parsing results are represented as a constraint network and every solution to the network corresponds to an in- dividual parse tree. We use an example network from [Maruyama, 19901 to illustrate the application of The- orems 2 and 3. Consider the following sentence. Put the block on the floor on the table in the room. Vl NP2 pp3 pp4 pp5 The sentence is structurally ambiguous (there are four- teen different parses) as there are many wa.ys to at- tach the prepositional phrases. Fig. 4 shows the vari- ables and their domains; Fig. 5 shows the constraint network (the symbol I in the figure denotes the iden- tity matrix-the (O,l)- matrix consisting of ones along the diagonal and zeroes everywhere else). Maruyama states that a “simple backtrack search can generate the 14 parse trees of the sentence from the constraint net- work at any time.” The network is path consistent but it can be seen that the constraints are not all row convex given the original domain ordering used in [Maruyama, 19901. However, using the new domain ordering shown in Fig. 4, the constraints are now row convex. Hence, procedure Instantiate from the previous section can be used to find a solution in a backtrack-free manner. Variable Dam ain Original ordering New ordering Vl { Rnil} { Rnil} NP2 Ply Wll pp3 {Ll, P2) {Ll, P2) pp4 {Ll, P2, P3) (P2, P3, Ll} pp5 {Ll, P2, P3, P4) (P3, P4, Ll, P2) Figure 4: Varia.bles and domains for parsing example Let R be a path consistent binary constraint net- work. It remains to show how Theorem 3 can be used to determine whether an ordering of the domains of the variables exists such that all of the (O,l)-matrices Rij , 1 5 i, j 5 n, are row convex. The procedure is sim- ple: for each variable, ~j, we ta.ke the ma.trix defined by stacking UP Rlj OII top of R,j on top of. . . R,j and test whether the matrix ca.n be made row convex. For exam- ple, with reference to Fig. 5, for variable PP4 we would test whether the columns of the ma.trix consist,ing of the 3 columns and 11 rows under the column heading PP4 can be permuted to satisfy the row convexity property. Vl NP2 PP3 PP4 PP5 Vl I 1 11 111 1111 NP2 1 I 11 111 1111 PP3 : ; I 101 1011 111 1111 1 1 11 1001 PP4 1 1 0 P I 1101 1 1 11 1111 1 1 11 111 PP5 ; : ‘: ; 011 001 I 1 1 11 111 Figure 5: Matrix representation of conAraint network for parsing example [Maruyama, 19901 In this example such a permutation exists and corre- sponds to the new ordering of the domain of variable PP4 shown in Fig. 4. It is, of course, not true that for every path consistent network there exists an ordering of the domains such that the constraints are row convex. However, in those cases where there does not, sometimes a weaker result still a.pplies. Theorem 4 Let R be a path consistent binary con- straint network. If there exists an ordering of the vari- ables xl,. . . ,x, and of the domains D1, . . . , D, of R such that the (O,l)-matrices Rij, 1 5 i < j 5 n, are row convex, then a consistent instantiation can be found wathout backtracking. Example 5. Consider the constraint network with three variables and domains D1 = D2 = 03 = {a,b,c) shown in Fig. 6. The example is path consistent and no ordering of the domain of 22 exists that will simultane- ously make the (O,l)-matrices RI2 and R32 row convex. However, order 02 = {a,c,b} satisfies the condition of Theorem 4 and the variables can be instantiated in the order ~1, x2, x3 using procedure Instantiate, and it can be gua.ranteed that no backtracking is necessary (the example was chosen to illustrate the application of the theorem as simply a.s possible; in actuality, path consis- tency is sufficient for gua.ranteeing the minimality and decomposability of any three node network). 1 2 010 1 I 111 101 011 2 110 I 011 011 110 3 010 111 110 100 111 010 Figure 6: Matrix representation of constraint network that can be made “sufficiently” row convex van Beek 451 5 Conclusions Constraint networks have been shown to have many ap- plications. However, two common reasoning tasks: (i) find a solution that satisfies the constraints and (ii) find the corresponding minima.l network are known to be NP-complete in the general case. In this paper, we have identified a large, and we believe interesting a.ud useful, class of constraint networks for which we can solve both tasks (i) and (ii) efficiently. Acknowledgements. I would like to thank Rina Dechter for fruitful discussions on this topic. Financial assistance was received from the Central Research Fund of the University of Alberta and the Natural Sciences and Engineering Research Council of Cana.da. References [Allen, 19831 J. F. All en. Maintaiimlg knowledge about temporal intervals. Comm. ACM, 26:832-843, 1983. [Booth and Lueker, 19761 Ii. S. Booth ancl G. S. Lueker. Testing for the consecutive ones property, interval graphs, and gra.ph p1anarit.y using pq-tree al- gorithms. J. Compui. Sysf. Sci., 13:335-379, 1976. [Clowes, 19711 M. B. Clowes. On seeing things. Arfifi- cial Intelligence, 2:79-l 16, 1971. [Dechter and Pearl, 1988] R. Dechter and J. Pearl. Network-based heuristics for constraint satisfaction problems. Artificial Intelligence. 34:1-38, 1988. [Dechter and Pearl, 19911 R. Dechter and J. Pearl. Di- rected constraint networks: A relational framework for causal modeling. In Proceedings or lhe Trilelftlr International Joint Conference on Ariificial Inlelli- gence, pages 1164-1170, Sydney, Australia, 1991. [Dechter et al., 19911 R. Dechter, I. Meiri, and J. Pearl. Temporal constraint networks. Artificial Intelligence, 49:61-95, 1991. [Dechter, 19901 R. Dechter. From local to global con- sistency. In Proceedings of the Eighth Canadian Cou- fererlce on Artificial Intelligence, pa.ges 231-237, Ot- tawa., Ont., 1990. [Deville and Van Hentenryck, 19911 1’. Deville and P. Van Hentenryck. An efficient arc consist,ency algo- rithm for a class of CSP problems. In Proceedings of the Twelfth International Join1 Coijference on Arti- ficial Intelligence, pa.ges 325-330, Sydney, Australia, 1991. [Freuder, 19781 E. C. F* d ieu er. Synthesizing const,raint expressions. Contm. ACM, 21:958-966, 1978. [Freuder, 19821 E. C. Freuder. A sufficient condition for backtrack-free search. J. ACM, 29:24-32, 1982. [Freuder, 19851 E. C. Freuder. A sufficient condition for backtrack-bounded sea.rch. J. A Cf\I, 32:755-761, 1985. [Freuder, I9901 E. C. Freutler. Complexity of k-tree structured constraint satisfaction problems. In Pro- ceedings of the Eighth National Conference on Arti- ficial I 12 e 2 I 11’9 ence, pages 4-9, Boston, Mass., 1990. [IIuffman, 19711 D. A. Huffman. Impossible objects as nonsense sent#ences. In B. Meltzer and D. Michie, editors, Machine Intelligence 6, pages 295-323. Ed- inburgh TJniv. Press, 1971. [Kirousis and Papatlimit,riou, 198S] I,. RI. Kirousis and C. H. Pa.padimitriou. The complexity of recognizing polyhedral scenes. In Proceedings of the 26th Sym- posium on Foundaiions of Computer Science, pages 175-185, Portland, Oregon, October 1985. [Ma.ckworth and Freuder, 19851 A. I<. h4ackworth and E. C. Freuder. The complexity of some polynomial netswork consistency a,lgorithms for constraint satis- faction problems. Artificial Intelligence, 25~65-74, 1985. [Rlackworth, 19771 A. Ii. Mackwort(h. Consistency in n&works of relations. Arfi.ficial Intelligence, 8:99- 118, 1977. [Ma&worth, 19871 A. I<. Mackworth. Constraint sat- isfaction. In S. C. Shapiro, editor, Encyclopedia of A4rfiJicinl Intelligence. John Wiley & Sons, 1987. [Maruyama, 19901 II. Maruyama. St,ructural disam- biguation with constraint propagation. In Proceed- ings oj lhe 28th Conference of the Association for Comprrlafional Linguistics, pages 31-38, Pittsburgh, Pennsylvania, 1990. [R*IGri el al., 1990] I. RI eiri, R. Dechter, and J. Pearl. Tree decomposition wit,11 applications to constraint processing. In Proceedings of the Eighth National Conference on Artificial Intelligence, pages 10-16, Bost,on, RIa.ss., 1990. [M t on anari, 1974) IJ. Mont,anari. Networks of con- straints: Funtlament,al properties and applications to picture processing. Inform. Sci., 7:95-132, 1974. [van Beck, 1989] P. van Beek. Approximation algo- rithms for temporal reasoning. In Proceedings of the Elevenih Internaiional Joint Conference on. Artificial Intelligence, pages 1291-1296, Detroit, Mich., 1989. [van Beck, 19901 P. van Beek. Reasoning about qual- itative temporal inforination. In Proceedings of the Eiglrlh Nalioiral Conference 011 Arlificial Intelligence, pages 728-734, Boston, h’lass., 1990. [Vilain el al., 19891 R!. Vilain, II. Kautz, and P. van Reek. Constraint, propa.gation algorithms for tempo- ral reasoning: A revised report. In D. S. Weld and J. de Kleer, editors, Readings in Qvalitative Reason- ing about Physical Systems, pages 373-381. Morgan- Kaufman, 1989. [Waltz, 19751 D. Waltz. Understanding line drawings of scenes wit,11 shadows. In P. II. Winston, editor, The Psychology of Compuier Vistoi~, pages 19-91. hicGraw-Itill. 1975. 452 Problem Solving: Constraint Satisfaction | 1992 | 80 |
1,277 | s si Nageshwara Rae Vempaty, Department of Computer Sciences, University of Central Florida, Orlando, FE - 32816. E-mail: vnrao@teja.cs.ucf.edu Abstract In this paper, we explore the idea of representing CSPs using techniques from formal language theory. The so- lution set of a CSP can be expressed as a regular lan- guage; we propose the minimized deterministic finite state automaton (MDFA) recognizing this language as a canonical representation for the CSP. This represen- tation has a number of advantages. Explicit (enumer- ated) constraints can be stored in lesser space than traditional techniques. Implicit constraints and net- works of constraints can be composed from explicit ones by using a complete algebra of boolean opera- tors like AND, OR, NOT, etc., applied in an arbitrary manner. Such constraints are stored in the same way as explicit constraints - by using MDFAs. This ca- pability allows our technique to construct networks of constraints incrementally. After constructing this rep- resentation, answering queries like satisfiability, valid- ity, equivalence, etc., becomes trivial as this represen- tation is canonical. Thus, MDFAs serve as a means to represent constraints as well as to reason with them. While this technique is not a panacea for solving CSPs, experiments demonstrate that it is much better than previously known techniques on certain types of prob- lems. verview The finite domain constraint satisfaction problem (CSP)l is well known in Artificial Intelligence. It has been investigated in the past by a number of re- searchers in different contexts.(For a recent survey, re- fer to [Kumar, 19921.) A CSP involves a (finite) set of variables, a (finite) set of values for the variables and a set of constraints, each of which is a relation on the values of some of the variables. Constraint Satisfaction involves identifying value assignments to variables that satisfy all the constraints. The problem is formally de- fined in the next section. As might be expected, many sequential algorithms have been developed for solving CSPs; these include backtracking, arc consistency [Waltz, 1975; Mack- worth, 19771, path consistency [Freuder, 19881, lin- ear programming techniques [Rivin and Zabih, 19891, etc.. The representation often used for expressing a ‘Through out this paper, we use the acronym CSP to refer to the finite domain constraint satisfaction problem. constraint and storing it, is the list of tuples form, in which the tuples of values satisfying the constraint are enumerated. Since such lists may become cumbersome as the number of variables in the constraint increases, it became customary to restrict the constraints to be unary or binary. A CSP that satisfies this restric- tion is called a Binary CSP (BCSP). A general CSP can be converted into an equivalent BCSP, but this process usually entails the introduction of new vari- ables and constraints, and hence an increase in prob- lem size. Constraint propagation (discrete relaxation) algorithms construct new lists of tuples of more re- strictive constraints that can be extended to solutions of the CSP[Montanari, 1974; Dechter and Meiri, 1989; Rossi and Monatanari, 19901. Backtracking algo- rithms enumerate the entire universe of tuples pos- sible, to construct a list of tuples satisfying all the constraints[Nadel, 19881. However the list of tuples representation of a constraint has two important draw- backs (i) many types of constraints require an exponen- tial space. For example, consider a CSP on n vari- ables v~,w~,...,v,, with m values for each variable a1,a2,**-,%n. Consider a L-ary constraint that re- quires at least one of the variables to take a value of al. The number of tuples in this constraint is Q((m - l)k> and the size of a list representing this grows exponen- tially in /?. Now consider the problem of finding all solutions to such a constraint (referred to as VALidity query later on in this paper). Clearly, an enumeration of all solutions requires exponential space and time. Is there a better technique? (ii) some operations on constraints that lead to new constraints require an ex- ponential amount of computation time. For example, the typical operation of negating a constraint, requires exponential time. In the past, this problem was cir- cumvented by specifying simple constraints explicitly as tuple lists and a CSP is specified as an ‘and’ of the simple constraints. This type of representation is diffi- cult to manipulate and hence a one time algorithm is used to solve the CSP after it has been completely spec- ified. Implicit constraints were specified by ‘and’ing explicit constraints; it is difficult to extract the solu- tion set from such a representation. In this paper, we develop a representation that is more compact in many cases and permits us to use arbitrary logical op- erators like ‘and’, ‘or’, ‘not’, etc.. It is some times advantageous to construct CSPs and new implicit Vempaty 453 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. constraints incrementally[Dechter and Dechter, 1988; Mittal and Falkenheiner, 19901. Further, the list of tuples representation is not canonical; hence prob- lems such as determining the equivalence of two CSPs require enormous computation. Our representation is canonical and permits incremental construction of CSPS. In this paper, we propose the minimal deterministic finite state machine (MDFA) accepting (exactly) the satisfying tuples of a constraint as a means to handle CSPs. It is well known that MDFAs are canonical up to a renaming of states [Hopcroft and Ullman, 19791. Thus if we use a MDFA to represent a CSP, we have a compact and a canonical representation. New con- straints and networks of constraints can be constructed from known ones using arbitrary operators like inter- section (and), union (or), difference (diff), etc.. Thus CSPs can be specified with a complete algebra of op- erators, instead of just using and as in previous lit- erature. A detailed discussion of this representation is presented in the next section. To solve the clas- sical network of constraints problem with this repre- sentation, explicit constraints are first converted into MDFAs. MDFAs to represent implicit constraints and networks of constraints are constructed directly from these automata by applying the corresponding opera- tions. Algorithms for constructing such a representa- tion and processing queries are discussed in the third section. The computational difficulty of the new approach lies in constructing MDFAs corresponding to implicit constraints. Once the MDFAs are constructed, answer- ing queries is easy, since our representation is canon- ical. The strengths and weaknesses of this technique are analyzed and a comparison to past work is made in the fourth section. The new representation is much more effective on certain problems; experiments illus- trating this are presented. Conclusions and scope for future research are discussed in the last section. Representation of CSPs using M Finite State Automata(FSA) were used to represent and manipulate boolean functions by Clarke et. al. in [Kimura and Clarke, 199.0; Clarke et al., 19911. These are related to Binary Decision Diagrams (BDDs) devel- oped by Akers[Akers, 19821, Bryant[Bryant, 19861 and McCarthy. We extend this representation to deal with constraints and CSPs. We first generalize the defini- tion of a CSP and then give a canonical representation using MDFAs. Terminology A system to represent and manipulate CSPs has a set of n variables V = (~11,212, e . . , v,} and a domain of m values for the variables, 2) = {al, ~2,. . . , u,},~ with which constraints may be expressed. A L-ary con- straint C over the variables {vii, ~2, . . s, uik} is a sub- set of 2)” and it specifies permissible combinations of values for the variables { zlii, ~2, . . . , ?&}. It is a k-ary 2Having a different domain of values for each variable is equivalent and can be handled similarly 454 Problem Solving: Constraint Satisfaction relation. An n-tuple of values (also called a value as- signment) is a mapping from variables V to values 2>; it specifies a value for each variable. A value assign- ment satisfies a constraint if it gives a combination of values to variables that is permitted by the constraint; otherwise it falsifies it. Traditionally, CSPs were spec- ified as a set of constraints that need to be satisfied together. For example, the N-queens problem involves placing N queens on an NxN chess board such that (i) queen i is placed in row i and (ii no two queens attack each other, by a column, major d iagonal or minor diag- onal. The S-queens problem is graphically illustrated in Figure 1. A Ic-ary constraint C can be extended to an equiv- alent n-ary constraint, by adding in all the remaining variables in V and allowing them to take any com- bination of values from D. By using a special wild card value, -;4, to mean any, every Ic-tuple of C is now made into an n-tuple. An ordering of the variables Vl , u2, * - * %I is a permutation of these variables. A fixed ordering of variables is used by our system to list out the components of tuples for all the constraints. Henceforth, every constraint is considered to be n-ary and uses the ordering { ~1,02, . . . , Q}, to list its set of satisfying tuples S. Semantically speaking, this list of tuples defines the constraint. Note that such a list of ordered tuples forms a canonical representation if we sort the lists using a lexicographic ordering. But this representation appears to be cumbersome. (For ease of presentation, it is assumed that the set of vari- ables we are working with is fixed and it is denoted by v = (211) ?I2 * - * vn }. The set of values is also assumed to be fixed and is denoted by D = {ui , u2 . . . a,}. We use Ci, C2, ... to denote constraints.) We now define the syntax of an algebra for express- ing constraints. New constraints can be constructed from a given set of constraints by using using logical operators and, or and diff. The semantics of these operators are given by the intersection, union and dif- ference respectively, of the associated sets of satisfyin n-tuples. A Constraint Satisfaction Problem (CSP ‘i specifies some explicit constraints by enumerating their tuples and implicit constraints by using logical opera- tors over the explicit constraints. An algebra for spec- ifying constraints is formally defined below. Definition 1 Syntactic definition of a constraint :- the empty set @ is a constraint. It is the only unsat- isfiable constraint. a set containing a single ordered n-tuple of values is a constraint. Those with more tuples can be con- structed using the or operator defined below. If Cl and C2 are constraints, then so are (ClAC2), (ClvC2) and (Cl - C2). (Cl/\&) is the constraint that lists all tuples that belong to both Cl and C2. (ClVC2) is the constraint that lists all tuples that belong to Cl or 62. (Cl -C2) is the constraint whose tuples are present in Cl, but not in C2. Other op- erators like complementation, exclusive-or, etc., are analogously defined. A system handling CSPs needs to represent con- strain& defined this way and solve queries on them. Queries to the CSP system include the following types:3 1. SATisfiability : Is C = @ ? An answer to this query is expected to return a satisfying tuple if one exists. 2. VALidity : What is the set of tuples satisfying a constraint C ? 3. EQUivalence : set of tuples ? Are Ci and C2 satisfied by the same MDFA representation An ordered list of values of an n-tuple denotes a string of length n over the alphabet V. Recall that the seman- tic definition of a constraint says that it is a finite set of n-tuples. In formal language theory, viewing the tuples as strings, a constraint is a finite set of strings of length n. Since all finite sets are regular, a constraint is a regular language and hence can be recognized by using finite state machines. A deterministic finite state au- tomaton (DFA) is a five tuple (Q,V, 6, S, F) [Hopcroft and Ullman, 19791, where (i) Q is a (finite) set of states (ii) S is a transition function defined from Q x ZJ to Q (iii) S denotes the distinguished start state and (iv) F is the set of accepting states of the machine. A DFA is said to accept a string w over the alphabet V if and only if starting the machine in state S with w on the tape leads to an accepting state. A DFA can be repre- sented as a graph, using the nodes to represent states and the edges labeled by alphabet, to represent the transition function. The language accepted by a DFA is the set of strings accepted by it and it is always a regular language. A minimal deterministic finite state automaton (MDFA) f or a language L is the determinis- tic finite state machine with the least number of states among all DFAs accepting L. For example, the MDFA in Figure 2 accepts all strings of length n on 2). This MDFA liberally accepts the entire universe Vn. Com- pare this representation with the list of tuples represen- tation for an n-ary constraint that permits any n-tuple as a solution. The MDFA corresponding to a language is canoni- cal up to a renaming of states; refer to [Hopcroft and Ullman, 19791 for a proof of this and more details on finite state machines. In terms of graph theory, the minimized finite state automaton (MDFA) is canoni- cal up to an isomorphism. So we can use them as a canonical representation of constraints. Formally - Definition 2 The MDFA corresponding to a con- straint is the minimized deterministic finite state au- tomaton that accepts (all and only) the tuples satisfying the constraint. For example, the MDFA in Figure 2 represents the constraint Cu satisfied by all tuples of Vn. Even this trivial example illustrates that the MDFA representa- tion is compact. We require only n nodes and mn arcs (see Figure 2). The list of tuples representation re- quires a space of Vn. In this representation, we use MDFAs to represent explicit constraints as well as to represent a network of constraints which when ‘and’ed together specify a CSP in the traditional sense. Since 30ther queries like IMPIication, SUBsumption, etc., can be handled with the algebraic operators in a similar fashion all the constraints in our system are expressed over the same variable set V, equivalent constraints are repre- sented by identical MDFAs. The MDFA representa- tion of a constraint is minimal over all deterministic finite state machines representing the constraint. Re- call that the list of tuples representation itself defines a DFA. Hence, the MDFA representation is smaller than the list of tuples representation as well. Algorithms to handle FAS In this section, we present algorithms for constructing the MDFA representation of constraints and CSPs, and algorithms for answering queries. Algorithms for constructing the M Constructing the minimal canonical form involves two steps (i) first construct a DFA that recognizes the con- straint and (ii) minimize this machine to get the canon- ical MDFA representation. Constructing a finite state machine Given a con- straint defined by 1, we can construct a DFA by the following steps. We are in fact replaying the syntactic definition of the constraint in a bottom up fashion. The empty constraint is accepted by the empty DFA. This DFA has no states at all and hence has no sat- isfying tuple. The constraint which has a single satisfying tuple {(al, a2, * * - , a,)} has the DFA in Figure 3. It ac- cepts only the string 611612 . . . a,. Constraints with more tuples can be constructed using the or opera- tor. Given two constraints Cl and C2, with DFAs Mi and M2 representing them, we can construct DFAs for GVC2, c&72, Cl - C2., etc., as follows. Construct a new machine IMP, traditionally called the product machine [Hopcroft and Ullman, 1979; Kimura and Clarke, 19901, that simulates the working of both the machines Ml and M2. The state of MP is a pair, (ai, 42), where ~1 is used to simulate the working of Ml and q2 that of Ma. On reading alphabet a in the state (ql, qa), this new machine transits to state (&(ql, a), Sz(q2, a)). It thus traces the working of Ml and M2 together. We can deal with various operators, by defining the accepting states of MP, as follows :- Or:- To construct the union of two constraints, the state (ql, q2) of the product machine is made an accepting state iff q1 is an accepting state of Ml or q2 is an accepting state of M2. And:- To construct the intersection of two con- straints, the state (ql, q2) of the product machine is made an accepting state iff q1 is an accepting state of Ml and q2 is an accepting state of M2. DifE- To construct the difference of two con- straints, the product machine is made to accept a tuple in a state iff Ml reaches an accepting state and M2 reaches a rejecting state. We denote the number of states of Mi by ] Mi I. The product DFA of MI and M2 has at most ] Ml I* lM21 states in the worst case. This implies that the worst Vempaty 455 case complexity of the product construction algorithm is IDI * IMlj * IMzI. In the best case, its complexity is OWlI + IM2I)* Minimizing a DFA to the MDFA The DFA con- structed in the previous step should be minimized to get our canonical MDFA representation. This can be done using the standard algorithm in page 70 of [Hopcroft and Ullman, 19791. If IPI is the number of states of the product DFA we start with, the time com- plexity of this algorithm is 0( IZJl lP12). Since our DFAs are directed acyclic graphs, we can employ the linear time minimization algorithm in [Hopcroft and Ullman, 19791 for better performance. Answering Queries with MDFA representation Since our MDFA representation is canonical and min- imal, answering queries can be performed efficiently once MDFAs have been constructed. In the following discussion, it is assumed that MDFAs for Cl, C2, * . . have been constructed and they are named Ml, MS, * * *. Each of the Ci’s may have been specified as an explicit constraint, implicit constraints or a network of constraints. SATisfiability: Cl is satisfiable iff Ml has an ac- cepting state. A satisfying tuple for Cl is obtained by tracing any path from source to sink in Ml. This takes O(lVl ical, only t h t ime. Since our representation is canon- e empty constraint C(a is unsatisfiable and it has a unique representative Mcp. VALidity: The set of all satisfying tuples of Cl can be enumerated by a depth-first traversal of Ml. Ev- ery visit to the accepting state gives us a new satis- fying tuple. A41 itself is a compact representation of the satisfying set of Cl and can be used as a response to a VALidity query. EQUivalence: To check if Cl and C2 have the same satisfying tuples, we can simply check if the corre- sponding MDFAs Ml and MS are identical. Since our MDFAs are directed acyclic graphs, this can be done in 0( IZJl( IM1 I + IMZI)) time. Solving CSPs with MDFAs In order to solve a CSP with the above techniques, we execute the following steps: (i) Construct MDFAs for all explicitly enumerated constraints. (ii) For implicit constraints, networks of constraints and CSPs alge- braically constructed from explicit constraints, build MDFAs using product and minimization algorithms. (iii) Solve queries like SATisfiability, VALidity, etc., using query processing algorithms. A few general com- ments are worth mentioning, to aid the reader in corre- lating with previous techniques for solving a network of constraints. The MDFA constructed has a structural correspondence to the decision tree of top down back- track search algorithms for solving CSPs[Nadel, 1988; Grimson, 19901. The MDFA is a graph with equiv- alent states of the tree reduced to a single represen- tative and the failure nodes of the tree being com- pletely discarded. MDFA construction is a bottom up approach, where constraints are logically ‘and’ed to define a network of constraints. There is also an interesting difference between the way two constraints Cl and C2 are ‘and’ed with MDFAs and with discrete relaxation. Bottom up approaches like discrete relax- ation and its isomorphic relative, resolution[DeKleer, 19891, add a new restrictive constraint that is logically implied by Cl and C2. The MDFA approach presented here replaces Cl and C2, by their exact logical ‘and’ - c&72. Example of MDFA construction To illustrate the technique of solving CSPs using MD- FAs, consider the (toy) problem of S-queens, graphi- cally shown in Figure 1. We follow the convention that queen i is placed in row i. There are three unary con- straints Cl, C2 and C3, each specifying that a queen can be in any of the three columns. The three binary constraints C12, C23 and C31 specify that no pair of queens attack each other. Figure 5 shows the impor- tant steps involved in solving this CSP with MDFAs. First, we convert the explicitly specified constraints Cl, C2, C3, C12, C23 and C31 into MDFAs. Then we and these constraints in this order to get the con- straint that specifies the 3-queens problem depicted by the network of Figure 1. As the final MDFA is empty, S-queens problem does not have a solution. Even with this toy example, we can observe that with a MDFA representation, we deal with explicit constraints, implicit constraints and networks of con- straints (CSPs) in the same manner. One can reuse the MDFAs built for Cl,C23, etc., to build other con- straints and other CSPs and also to answer queries. In an application where constraint networks once speci- fied are reused again and again, the MDFA represen- tation saves recomputation time. For example, to solve another queens problem in which queen1 is allowed to attack queen2, we simply ignore C 12 and and the rest of the constraints we built for 3-queens. We can also infer that Cl, C2 and C3 can be ignored. This type of information is lost in the traditional CSP algorithms, as they are one time algorithms. Overall Complexity sf the New Strategy Constructing MDFAs for explicit constraints, mini- mization and answering queries can be performed in near linear time. When an implicit constraint C is com- posed from two constraints Cl and C2 with a binary operator, we need to construct the product machine from Ml and M2 and then minimize it. The complex- ity of the product-construction algorithm varies. It depends on the (i) size of the MDFAs involved and (ii) type of the satisfying sets for the constraints involved. The time consumed by the product construction algo- rithm, given two DFAs Ml and M2, is @(Ml + MS) in the best case and O(M1 * M2) in the worst case. In the first case, the product DFA is small. The second case can lead to blow up in size. Since the construction of an MDFA to solve a network of con- straints uses the product-construction algorithm re- peatedly, its run time is some times linear, some times quadratic and it may even be exponential in the worst case. The time complexity also depends on the order- ing used to enumerate variables and tuples. Heuristics 456 Problem Solving: Constraint Satisfaction for variable ordering devised for previous CSP algo- rithms [Purdom et al., 1981; Dechter and Meiri, 1989; Zabih and McAllester, 1988] seem to work very well in practice. The algorithms to handle query processing, after MDFAs have been constructed, are quite efficient. Thus, once the MDFA representation has been con- structed, it can be manipulated in almost linear time. This is not the case with the list of tuples representa- tion. Experimental Comparison with Previous Methods We performed some experiments to compare the MDFA based techniques with other known algorithms to solve CSPs. The forward checking algorithm (FC for solving CSPs combines backtracking with forwar 1 checking. It is also called backtracking combined with directed arc consistency (DAC) in [Dechter and Meiri, 19891. In [Dechter and Meiri, 19891, this algorithm was shown to be superior to path consistency and adaptive con- sistency algorithms on randomly generated CSP in- stances. We compared the algorithms presented in this paper with FC enhanced with dependency di- rected backtracking[Stallman and Sussman, 19771 to solve VALidity query on randomly generated CSP in- stances. On hard instances, the MDFA approach runs faster by a factor of 10 - 100, both in terms of time and number of states generated. We also compared the MDFA approach with forward checking and hyperres- olution on the pigeon hole clauses. (Hyperresolution is equivalent to discrete relaxation for this problem by a result of De Kleer[DeKleer, 19891.) Pigeon hole clauses express the pigeon hole principle (Ramseys theorem) - if n+ 1 pigeons are placed in n holes, then some hole will have at least two pigeons. Stephen Cook proposed that for any given n, the clause form of the pigeon hole principle is a hard problem for automated rea- soning systems in his classic paper [Cook, 19711. We compared MDFA approach with FC and Hyperresolu- tion on pigeon hole problem for different values of n and found that as n increases, the MDFA approach is much superior in terms of time as well as number of states generated. Table 1 summarizes our experimen- tal results. Hyperresolution is unable to solve any of the problems in the table in a time limit of 1 hour and is hence not listed. On the n-queens problem[Nadel, 19881, FC was found to be better than MDFAs. Conclusions and Future Research We presented a canonical representation for CSPs us- ing MDFAs and discussed algorithms for manipulating CSPs with it. Well known theoretical results on regular languages can be used to solve the finite domain con- straint satisfaction problem by viewing it as a problem on regular languages. The key property exploited is the fact that the domains V and 2) being dealt with are finite. Our representation, being compact and canoni- cal has a number of advantages. It enables us to con- struct implicit constraints using many different types of operators. Being a canonical form of solution sets, MDFAs serve as a representation tool as well as a rea- soning tool. They allow for incremental construction and manipulation of constraints. All these results indi- cate that the MDFA approach is suitable for construct- ing knowledge bases for storing constraints and reason- ing with them. The property of minimality guarantees a compact representation and the property of being canonical eliminates duplicate copies. Since an MDFA compactly represents the set of satisfying tuples, it al- lows fast query processing. Also, costly recomputation and backtracking are eliminated for repeated queries. A number of open problems arise in the context of our discussion: (i) On what type of problems is the bottom up MDFA construction more effective than the classical top down backtrack search algorithms like for- ward checking and constraint propagation algorithms like k-consistency ? worse? On what type of problems are they (ii) What is the order in which a network of constraints is best solved? When a series of constraints need to be composed, they can be composed in any or- der. Even though the final MDFA is the same, the sizes of intermediate MDFAs can be different for dif- ferent orderings. The discussion of this paper assumes that the num- ber of variables and the number of values is fixed; it also treats all constraints as n-ary constraints. The proof of the canonical nature of MDFAs in [Hopcroft and Ullman, 19791 suggests that we can relax these assumptions and devise more compact canonical rep- resentations for constraints. We propose to investigate this further in our future work. Acknowledgements:- The author would like to thank the following people for discussions and support, at various stages of this work: Ed Clarke and Handy Bryant of CMU, Vipin Kumar of the University of Min- nesota, Bob Boyer of the University of Texas at Austin and Carl Pixley of MCC. eferences Akers, S. B. 1982. Functional testing with binary deci- sion diagrams. In Proceedings of the 8th Annual IEEE Conference on Fault- Tolerant Computing. 75-82. Bryant, RandalI E. 1986. Graph based algorithms for boolean function manipulation. IEEE Transactions on Computers C-35(8):667-691. Clarke, Edmund M.; Kimura, S.; Long, David E.; Michaylov, Spirov; Schwab, Stephen A.; and Vidal, J. P. 1991. Parallel symbolic computation on a shared mem- ory multiprocessor. In Proceedings of the International Symposium on Shared Memory Multiprocessors. Cook, Stephen A. 1971. On the complexity of theorem proving procedures. In Proc. of the Third Annual ACM Symposium on Theory of Computing. 151-158. Dechter, Rina and Dechter, Avi 1988. Belief maintenance in dynamic constraint networks. In Proceedings of AAAI- 88. Dechter, Rina and Meiri, Itay 1989. Experimental evalua- ton of preprocessing techniques in constraint satisfaction problems. In Proceedings of IJCAI-89. 271-277. DeKleer, Johann 1989. A comparison of atms and csp techniques. In Proceedings of IJCAI-89. 290-296. Freuder, E. 1988. Backtrack-free and backtrack-bounded search. In Kanal, Laveen and Kumar, Vipin, editors 1988, Search in Artificial Intelligence. Springer-Verlag, New York. Vempaty 457 Grimson, W. E. L. 1990. The combinatorics of object recognition in cluttered environments using constrained search. Artificial Intelligence 44:121-165. Hopcroft, John E. and Ullman, Jeffrey D. 1979. Introduc- tion to Automata Theory, Formal Languages and Compu- tation. Addison-Wesley. Kimura, S. and Clarke, Edmund M. 1990. A parallel algorithm for constructing binary decision diagrams. In Proceedings of the International Symposium on Computer Design(ICCD). Kumar, Vipin 1992. Algorithms for constraint satisfaction problems: A survey. AI Magazine 13(1):32-44. Mackworth, A. K. 1977. Consistency in networks of rela- tions. Artificial Intelligence 8 (1):99-l 18. Mittal, S. and Falkenheiner, B. 1990. Dynamic constraint satisfaction problems. In Proceeding of AAAI-90. 25-32. Montanari, Ugo 1974. Networks of constraints: Funda- mental properties and applications to picture processing. Information Science 7,95-132. Nadel, Bernard 1988. Constraint satisfaction algorithms. In Kanal, Laveen and Kumar, Vipin, editors 1988, Search in Artificial Intelligence. Springer-Verlag, New York. Purdom, P.; Brown, C.; and Robertson, E. L. 1981. Back- tracking with multi-level dynamic search rearrangement. Acta Informatica 15:99-113. Rivin, Igor and Zabih, Ramin 1989. An algebraic ap- proach to constraint satisfaction problems. In Proceedings bf IJCAI-89. 284-289. Rossi, Francesca and Monatanari, Ugo 1990. Exact solu- tion of networks of constraints using perfect relaxation. In Proceedings of First International Conference on Knowl- edge Representation. Stallman, R. and Sussman, G.J. 1977. Forward reasoning and dependency directed backtracking. Artificial Intelli- gence 9 (2):135-196. Waltz, D. 1975. Understanding line drawings of scenes with shadows. In Winston, P. H., editor 1975, The Psy- chology of Computer Vision. McGraw Hill, Cambridge, MA. Zabih, Ramin and McAllester, David 1988. A rearrange- ment search strategy for determining propositional satis- fiability. In Proceedings of the 1988 National Conference on Artificial Intelligence. 155-160. Table 1: Experimental results on pigeon hole example. ClmdQndC2 fig 4. So/&g he a-queens CSP using MDFAs. * denotes a wild card meaning any. 458 Problem Solving: Constraint Satisfaction | 1992 | 81 |
1,278 | as ist avid itchell Dept. of Computing Science AT&T Bell Laboratories Simon Fraser University Murray Hill, NJ 07974 Burnaby, Canada V5A lS6 selmanQresearch.att.com mitchellQcs.sfu.ca Abstract We report results from large-scale experiments in satisfiability testing. As has been observed by others, testing the satisfiability of random formu- las often appears surprisingly easy. Here we show that by using the right distribution of instances, and appropriate parameter values, it is possible to generate random formulas that are hard, that is, for which satisfiability testing is quite difficult. Our results provide a benchmark for the evalua- tion of satisfiability-testing procedures. Introduction Many computational tasks of interest to AI, to the ex- tent that they can be precisely characterized at all, can be shown to be NP-hard in their most general form. However, there is fundamental disagreement, at least within the AI community, about the implications of this. It is claimed on the one hand that since the performance of algorithms designed to solve NP-hard tasks degrades rapidly with small increases in input size, something will need to be given up to obtain ac- ceptable behavior. On the other hand, it is argued that this analysis is irrelevant to AI since it based on worst-case scenarios, and that what is really needed is a better understanding of how these procedures per- form “on average”. The first computational task shown to be NP-hard, by Cook (1971) was propositional satisfiability or SAT: given a formula of the propositional calculus, de- cide if there is an assignment to its variables that makes the formula true according to the usual rules of inter- pretation. Subsequent tasks have been shown to be NP-hard by proving they are at least as hard as SAT. Roughly, a task is NP-hard if a good algorithm for it would entail a good algorithm for SAT. Unlike many other NP-hard tasks (see Garey and Johnson (1979) for a catalogue), SAT is of special concern to AI because of its direct relationship to deductive reasoning (i.e., *Fellow of the Canadian Institute for Advanced Re- search, and E. W. R. Steacie Fellow of the Natural Sciences and Engineering Research Council of Canada Dept. of Computer Science University of Toron to Toronto, Canada M5S lA4 hector8ai. toronto.edn given a collection of base facts C, a sentence cy may be deduced iff C U {lo} is not satisfiable). Many other forms of reasoning, including default reasoning, diag- nosis, planning and image interpretation, also make direct appeal to satisfiability. The fact that these usu- ally require much more than the propositional calculus simply highlights the fact that SAT is a fundamental task, and that developing SAT procedures that work well in AI applications is essential. We might ask when it is reasonable to use a sound and complete procedure for SAT, and when we should settle for something less. Do hard cases come up often, or are they always a result of strange encodings tailored for some specific purpose ? One difficulty in answering such questions is that there appear to be few applica ble analytical results on the expected difficulty of SAT (although see below). It seems that, at least for the time being, we must rely largely on empirical results. A number of papers (some discussed below) have claimed that the difficulty of SAT on randomly gen- erated problems is not so daunting. For example, an often-quoted result (Goldberg, 1979; Goldberg et al. 1982) suggests that SAT can be readily solved “on av- erage” in 0(n2) time. This does not settle the question of how well the methods will work in practice, but at first blush it does appear to be more relevant to AI than contrived worst cases. The big problem is that to examine how well a pro- cedure does on average one must assume a distribution of instances. Indeed, as we will discuss below, Franc0 and Paul1 (1983) refuted the Goldberg result by show- ing that it was a direct consequence of their choice of distribution. It’s not that Goldberg had a clever al- gorithm, or that the problem is easy, but that they had used a distribution with a preponderance of easy instances. That is, from the space of all problem in- stances, they sampled in a way that produced almost no hard cases. Nevertheless, papers continue to appear purport- ing to empirically demonstrate the efficacy of some new procedure, but using just this distribution (e.g., Hooker, 1988; Kamath et al. 1990), or presenting data suggesting that very large satisfiability problems - Mitchell, Selman, and Levesque 459 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. with thousands of propositional variables - can be solved. In fact, we are presenting one of the latter kind ourselves (Selman et al., 1992)! How are we to evaluate these empirical results, given the danger of biasing the sample to suit the procedure in question, or of simply using easy problems (even if unwittingly)? In this paper, we present empirical results showing that random instances of satisfiability can be generated in such a way that easy and hard sets of instances (for a particular SAT procedure, anyway) are predictable in advance. If we care about the robustness of the procedures we develop, we will want to consider their performance on a wide spectrum of examples. While the easy cases we have found can be solved by almost any reasonable method, it is the hard cases ultimately that separate the winners from the losers. Thus, our data is presented as challenging test material for de- velopers of SAT procedures (see Selman et al., 1992, for example). The SAT procedure we used for our tests is the Davis-Putnam procedure, which we describe below. We believe this was a good choice for two reasons: First, it has been shown to be a variant of resolution (Vellino 1989, Galil 1977), the most widely used gen- eral reasoning method in AI; second, almost all empir- ical work on SAT testing has used one or another re- finement of this method, which facilitates comparison. We suspect that our results on hard and easy areas generalize to all SAT procedures, but this remains to be seen. The rest of the paper is organized as follows. In the next two sections we describe the Davis-Putnam procedure, and consider it’s performance on one dis- tribution of formulas, the fixed clause-length model. We show that with the right parameter values, it pro- duces computationally challenging SAT instances. In the following section we consider a second distribu- tion, the constant-probability model, and argue that it is not useful in the evaluation of satisfiability-testing procedures. We then briefly review related work, and summarize our results. The Davis-Putnam Procedure The Davis-Putnam (DP) procedure (Davis and Put- nam 1960) is sketched in Figure 1. It takes as input a set of clauses C over a set of variables V, and returns either “satisfiable” or “unsatisfiable.” (A clause is a disjunction of literals. A set of clauses represents a conjunction of disjunctions, i.e., a formula in conjunc- tive normal form (CNF).) It performs a backtracking depth-first search in the space of all truth assignments, incrementally assigning truth values to variables and simplifying the formula. If no new variable can be as- signed a value without producing an empty clause, it backtracks by changing a previously made assignment. The performance of simple backtracking is greatly im- proved by employing unit propagation: Whenever a unit clause (one containing a sinle literal) arises, the 460 Problem Solving: Hardness and Easiness PROCED?JRE DP Given a set of clauses C defined over a set of variables V: If C is empty, return “satisfiable”. If C contains an empty clause, return “unsatisfiable”. (Unit-Clause Rule) If C contains a unit clause c, assign to the variable mentioned the truth value which satisfies c, and return the result of calling DP on the simplified formula. (Splitting Rule) Select from V a variable v which has not been assigned a truth value. Assign it a value, and call DP on the simplified formula. If this call returns “satisfiable”, then return “satisfiable”. Otherwise, set v to the opposite value, and return the result of calling DP on the re-simplified formula. Figure 1: The DP procedure with unit propagation. variable occurring in that clause is immediately as- signed the truth value that satisfies it. The formula is then simplified, which may lead to new unit clauses, and so on. This propagation process can be executed in time linear in the total number of literals. DP com- bined with unit propagation is one of the most widely used methods for propositional satisfiability testing. (It is also common to include the “pure literal rule”, which we excluded from this implementation because it is relatively expensive, and seemed to provide only a modest improvement on the formulas we consider here.) The fixed clause-length model In this section, we study formulas generated using the fixed clause-length model, which we call Random K- SAT. There are three parameters: the number of vari- ables N, the number of literals per clause K, and the number of clauses L. To keep the volume of data pre- sented manageable and yet give a detailled picture, we limit our attention to formulas with Ii’ = 3, that is, random 3-SAT. For a given N and L, an instance of random 3-SAT is produced by randomly generating L clauses of length 3. Each clause is produced by ran- domly choosing a set of 3 variables from the set of N available, and negating each with probability 0.5. We now consider the performance of DP on such random formulas. Figure 2 shows the total number of recursive calls by DP to find one satisfying assign- ment, or to determine that the formula is unsatisfiable. There are three curves, for formulas with 20, 40, and 50 variables. Along the horizontal axis is the number of clauses in the formulas tested, normalized through division by the number of variables. Each data point gives the median number of calls for a sample size of 500? ‘The means of the number of calls are influenced by a very small number of very large values. As the median is less sensitive to such “outliers”, it appears to be a more informative statistic. 2500 Number 20-variable 40-variable formulas formulas formulas 4 5 6 Ratio of clauses-to-variables 8 Figure 2: Median number of recursive DP calls for Random S-SAT formulas, as a function of the ratio of clauses- torvariables. In figure 2, we see the following pattern: For formu- las that are either relatively short or relatively long, DP finishes quickly, but the formulas of medium length take much longer. Since formulas with few clauses are under-constrained and have many satisfying as- signments, an assignment is likely to be found early in the search. Formulas with very many clauses are over-constrained (and usually unsatisfiable), so con- tradictions are found easily, and a full search can be completed quickly. Finally, formulas in between are much harder because they have relatively few (if any) satisfying assignments, but the empty clause will only be generated after assigning values to many variables, resulting in a deep search tree. Similar under- and over-constrained areas have been found for random in- stances of other NP-complete problems (see the discus- sion of the work of Cheeseman et al. (1991), below). The curves in figure 2 are for ad1 formulas of a given size, that is they are composites of satisfiable and un- satisfiable subsets. In figure 3 the median number of calls for 50-variable formulas is factored into satisfiable and unsatisfiable cases, showing that the two sets are quite different. The extremely rare unsatisfiable short formulas are very hard, whereas the rare long satisfi- able formulas remain moderately difficult. Thus, the easy parts of the composite distribution appear to be a consequence of a relative abundance of short satisfiable formulas or long unsatisfiable ones. To understand the hard area in terms of the like- lihood of satisfiability, we experimentally determined the probability that a random 50-variable instance is satisfiable (figure 4). There is a remarkable correspon- dence between the peak on our recursive calls curve and the point where the probability that a formula is satisfiable is 0.5. The main empirical conclusion we draw from this is that the hardest urea for sutisfiubil- ity is near the point where 50% of the formulas are satisfiable. This “50% satisfiable” point seems to occur at a fixed ratio of the number of clauses to the number of vari- ables: when the number of clauses is about 4.3 times the number of variables. There is a boundary effect for small formulas: for formulas with 20 variables, the point occurs at 4.55; for 50 variables, at 4.3; and for 140 variables, at 4.3. While we conjecture that this ratio approaches about 4.25 for very large numbers of variables, it remains a challenging open problem to un- ulyticully determine the “50% satisfiable” point as a function of the number of variables. Finally, note that we did not specify a method for Mitchell, Selman, and Levesque 461 10000 1 I . - I I I 1 Number of DP calls 9000 Satisfiable t 8000 7000 50%-satisfiable point . l . . 6000 5000 4000 3000 2000 1000 0 2 3 4 5 6 7 8 Ratio of clauses-to-variables Figure 3: Median DP calls for 50-variable Random 3-SAT as a function of the ratio of clauses-to-variables. Probability of being satisfiable + 50%-satisfiable point l * l . 0.7 0.6 Probability 0.5 0.4 0.1 0.0 ““““““” 2 3 4 5 6 7 Ratio of clauses-to-variables Figure 4: Probability of satisfiability of 50-variable formulas, as a function of the ratio of clauses-to-variables. choosing which variable to guess in the “splitting” step of DP. In our implementation, we simply set variables in lexical order (except when there are unit clauses.) DP can be made faster by using clever selection strate- gies (e.g., Zabih and McAllester 1988), but it seems unlikely that such heuristics will qualitatively alter the easy-hard-easy pattern. The formulas in the hard area appear to be the most challenging for the strategies we have tested, and we conjecture that they will be for every (heuristic) method. The constant-probability model We now examine formulas generated using the constant-probability model. The model has three pa rameters: the number of variables N, and number of clauses L as before; but instead of a fixed clause length, clauses are generated by including a variable in a clause with some fixed probability P, and then negating it with probability 0.5. Large formulas generated this way very often have at least one empty clause and sev- eral unit clauses, so that they tend to be either triv- ially unsatisfiable, or easily shown satisfiable. Thus, the more interesting results are for the modified ver- sion in which empty and unit clauses are disallowed. This distribution we call Random P-SAT. Analytic results by Franc0 and Paul1 (1983) sug- gest that one probably cannot generate computation- ally challenging instances from this model, and our 462 Problem Solving: Hardness and Easiness DP calls Figure 5: Comparison of median DP calls for 20-variable fixed-length and constant-probability formulas. Average clause-length of 3 Average clause-length of 4 Fixed clause-length of 3 I 160 140 120 100 80 60 40 20 I I s I I I I I 1 3 4 5 6 7 8 9 10 Ratio of clauses-to-variables experiments confirm this prediction. In Figure 5, we compare the number of recursive DP calls to solve in- stances of random P-SAT with the same figures for random S-SAT. Although we see a slight easy-hard- easy pattern (previously noted by Hooker and Fed- jki, 1989), the hard area is not nearly so pronounced, and in absolute terms the random P-SAT formulas are much easier than random 3-SAT formulas of similar size. Franc0 and Paull’s analysis (discussed below) and our experimental results show that the constant- probability model is not suitable for the evaluation of satisfiability testing procedures. elated work There is a large body of literature on testing the satis- fiability of random formulas, reporting mostly analytic results. The main impetus for this research was early experimental results by Goldberg (1979), which sug- gested that SAT might in fact be easily solvable, on av- erage, using DP. Franc0 and Paul1 (1983) showed that Goldberg’s positive results were a direct consequence of the distribution used - a variant of the constant- probability model - and thus overly optimistic. Gold- berg’s formulas were so easily satisfiable that an algo- rithm which simply tried randomly generated assign- ments would, with probability 1, find a satisfying as- signment in a constant number of guesses. Further analytic results for the constant-probability model can be found in Franc0 (1986), Franc0 and Ho (1988). Franc0 and Paul1 (1983) also investigated the perfor- mance of DP on random 3-SAT, and suggested that it might be more useful for generating random instances, an hypothesis we have confirmed experimentally here. They showed that for any fixed ratio of clauses to vari- ables, if DP is forced to find all satisfying truth as- signments (rather than stopping at the first one found, as our version does), its expected time will be expo- nential in the number of variables, with probability approaching 1 as the number of variables approaches infinity. Unfortunately, this result does not directly tell us much about the expected time to find a single assignment. A recent result by Chvatal and Szemeredi (1988) can be used to obtain some further insight. Extend- ing a ground-breaking result by Haken (1985), they showed that any resolution strategy requires exponen- tial time with probability 1 on formulas where the ratio of clauses to variables is a constant greater than 5.6. (They also show that with probability approaching 1 such formulas are unsatisfiable.) Given that DP cor- responds to a particular resolution strategy, as men- tioned above, it follows that on such formulas the av- erage time complexity of DP is exponential. This may appear inconsistent with our claim that over-constrained formulas are easy, but it is not. Chvatal and Szemeredi’s result holds for constant rsb tios of clauses to variables as both to go to infinity. So for any fixed ratio of clauses to variables well beyond the 50%-satisfiable point, there is some (possibly very large) number such that, whenever the number of vari- ables exceeds this number, DP is very likely to take exponential time. For formulas with fewer variables (and clauses), however, DP may still finish quickly. For example, our experiments show that DP consistently takes only several seconds to determine the unsatisfi- ability of IOOO-variable, 50,000-clause instances of 3- SAT (even though there are some 250-variable 1062- clause formulas that it cannot practically solve). For this large ratio of 50, the exponential behavior does not appear to occur for formulas with 1000 or fewer variables: those formulas lie in what we have termed the “easy area.” But for formulas with larger numbers of variables, eventually the truly easy area will occur Mitchell, Selman, and Eevesque 463 only at ever higher ratios of clauses to variables. Of course, even without increasing this ratio, we suspect that the formulas will nonetheless be relatively easy in comparison to those at the 50% satisfiable point. Turning to under-constrained formulas, the behav- ior of DP can be explained by the fact that they tend to have very many satisfying truth assignments - a fact we have verified experimentally - so that the procedure almost always finds one early in the search. Other analytic results for random 3-SAT are reviewed in Chao and Franc0 (1990), and Franc0 (1986). Not only are our experimental results consistent with the analytic results, they also provide a more fine- grained picture of how 3-SAT may behave in practice. One reason for the limitations of analytic results is the complexity of the analyses required. Another is that they are asymptotic, li. e., they hold in the limit as the number of variables goes to infinity, so do not nec- essarily tell us much about formulas that have only a modest number of variables (say, up to a few thousand) as encountered in practice. Finally, we would like to mention the valuable con- tribution of a recent paper by Cheeseman et al., (1991). This paper explores the hardness of random instances of various NP-complete problems, their main results being for graph coloring and Hamiltonian circuit prob- lems. They observe a similar easy-hard-easy pattern as a function of one or more parameters of instance gener- ation. They also give some preliminary results for sat- isfiability. Unfortunately, they do not describe exactly how the formulas are generated, and their findings are based on relatively small formulas (up to 25 variables). Also, their backtrack search procedure does not appear to incorporate unit resolution, which would limit its ability to find quick cutoff points. Possibly because of the preliminary nature of their investigation, they ob- serve that they do not know how to generate hard SAT instances except via transformation of hard graph col- oring problems. Although there are similarities in pat- tern, their hard area appears to be at a different place than in our data, suggesting that the mapping pro- cess generates a distribution somewhat different than random S-SAT. We also note that when formulas are not generated randomly, but encode some other NP- complete problem, such as graph coloring, the ratio of clauses to variables may not be a good indicator of expected difficulty. Moreover, it is possible to arbitrar- ily change the clause-to-variable ratio of a formula by “padding” it, without substantially affecting its diffi- culty. Conclusions There has been much debate in AI on the importance of worst-case complexity results, such as NP-hardness results. In particular, it has been suggested that satis- fiability testing might be quite easy on average. We have carried out a detailed study of the average- case difficulty of SAT testing for random formulas. We confirmed previous observations that many in- stances are quite easy, but we also showed how hard instances can be generated. The fixed clause-length model with roughly 4.3 times as many clauses as variables gives computationally challenging instances which have about a 0.5 probability of being satisfi- able. Randomly generated formulas with many more or fewer clauses are quite easy. Our data provide two important lessons. The first is that the constant-probability model is inappropriate for evaluating satisfiability procedures, since it seems to be dominated by easy instances for all values of the parameters. The second is that it is not neces- sarily the case that generating larger formulas provides harder formulas. For example, one can solve 1000 vari- able 3000 clause (under-constrained) and 1000 vari- able 50000 clause (over-constrained) random S-SAT in- stances in seconds using DP. On the other hand, even a highly optimized variant of DP2 cannot solve random S-SAT instances with 250 variables and 1075 clauses. Because random S-SAT instances can be readily gen- erated, those from the hard area can be very useful in the evaluation of satisfiability testing procedures, and algorithms for related tasks such as Boolean constraint satisfaction. We hope that our results will help prevent further inaccurate or misleading reports on the average case performance of SAT procedures. Acknowledgments We thank Henry Kautz for many useful discussions and comments, and Fahiem Bacchus for helpful com- ments on an earlier draft. The first and third authors were funded in part by the Natural Sciences and Engi- neering Research Council of Canada, and the Institute for Robotics and Intelligent Systems. References Chao, Ming-te and France, John (1990). Probabilis- tic Analysis of a Generalization of the Unit-Clause Literal Selection Heuristics for the k: Satisfiability Problem. Inform. Sci., 51, 1990, 23-42. Cheeseman, Peter and Kanefsky, Bob and Taylor, William M. (1991). Where the Really Hard Prob- lems Are. Proceedings IJCAI-91, 1991, 163-169. Chvatal,V. and Szemeredi, E. (1988). Many hard ex- amples for resolution. JACM, val. 35, no. 4, 1988, 759-208. Cook, S.A. (1971). The complexity of theorem- proving procedures. Proceedings of the 3rd Annual f5.-4”!mposium on the Theory of Computing, 1971, Davis, M. and Putnam, H. (1960). A computing pro- cedure for quantification theory. J. Assoc. Comput. Mach., 7, 1960, 201-215. France, J. (1986). Probabilistic analysis of algorithms for NP-complete problems. United States Air Force Annual Scientific Report, 1986. 2Recently developed by Jim Crawford (1992, personal communication). and Larry Auton 464 Problem Solving: Hardness and Easiness France, J. and Ho, Y.C. (1988). Probabilistic perfor- mance of a heuristic for the satisfiability problem. Discrete Applied Math., 22, 1988, 35-51. France, J. and Paull, M. (1983). Probabilistic analy- sis of the Davis Putnam procedure for solving the satisfiability problem. 1983, 77-87. Discrete Applied Math. 5, Galil, Zvi (1977). On the complexity of regular resolu- tion and the Davis-Putnam procedure. Theoretical Computer Science, 4, 1977, 23-46. Gallo, Giorgio and Urbani, Giampaolo (1989). Algo- rithms for Testing the Satisfiability of Propositional Formulae. J. Logic Programming, 7, 1989, 45-61. Garey, M.R. and Johnson, D.S. (1979). Computers and Intractability, A Guide to the Theory of NP- Completeness. New York, NY: W.H. Freeman, 1979. Goldberg, A. (1979). On the complexity of the satisfi- ability problem. Courant Computer Science Report, No. 16, New York University, NY, 1979. Goldberg, A., Purdom, Jr. P.W., and Brown, C.A. (1982). Average time analysis of simplified Davis- Putnam procedures. Information Process. Lett., 15, 1982, 72-75; see also “Errata”, vol. 16, 1983, p. 213. Kamath, A.P., Karmarker, N.K., Ramakrishnan, K.G., and Resende, M.G.C. (1990). Computational experience with an interior point al- gorithm on the satisfiability problem. Proceedings, Integer Programming and Combinatorial Optimiza- tion, Waterloo, Canada: Mathematical Program- ming Society, 1990, 333-349. Haken, A. (1985). The intractability of resolution. Theoretical Computer Science, 39, 1985, 297-308. Hooker, J.N. (1988). Resolution vs. cutting plane so- lution of inference problems: Some computational experience. 1-7. Operations Research Letter, 7( 1), 1988, Hooker, J.N. and Fedjki, C. (1989). Branch-and-cut solution of inference proble’ms in’ propositional logic, Working paper 77-88-89, Graduate School of Indus- yi;k Administration, Carnegie Mellon University, . Selman, B. and Levesque, H.J ., and Mitchell, D.G. (1992). A New Method for Solving Hard Satisfia- bility Problems. This proceedings. Vellino, A. (1989). Th e complexity of automated rea soning. Ph.D. thesis, Dept. of Philosophy, Univer- sity of Toronto, Toronto, Canada, 1989. Zabih, R. and McAllester, D. (1988). A rearrange- ment search strategy for determining propositional satisfiability. Proc. AAAI-88, 1988, 155-160. Mitchell, Selman, and Levesque 465 | 1992 | 82 |
1,279 | How Long Will It Take? * Ron Musick Stuart Russell Computer Science Division University of California Berkeley, CA 94720, USA musick@cs. berkeley.edu russell@cs.berkeley.edu Abstract We present a method for approximating the ex- pected number of steps required by a heuristic search algorithm to reach a goal from any ini- tial state in a problem space. The method is based on a mapping from the original state space to an abstract space in which states are charac- terized only by a syntactic “distance” from the nearest goal. Modeling the search algorithm as a Markov process in the abstract space yields a simple system of equations for the solution time for each state. We derive some insight into the behavior of search algorithms by examining some closed form solutions for these equations; we also show that many problem spaces have a clearly de- lineated “easy zone”, inside which problems are trivial and outside which problems are impossible. The theory is borne out by experiments with both Markov and non-Markov search algorithms. Our results also bear on recent experimental data sug- gesting that heuristic repair algorithms can solve large constraint satisfaction problems easily, given a preprocessor that generates a sufficiently good initial state. Introduction In the domain of heuristic problem solving, there is of- ten little information on how many operations it will take on average for a particular algorithm to solve a class of problems. Most results in the field concern such things as dominance, worst case complexities, completeness and admissibility. Average-case analy- ses deal with individual algorithms, and few if any re- sults have been obtained for search problems. Our ap- proach is to directly address this issue by developing an approximation of the expected number of steps an algorithm requires to reach a solution from any initial point in the state space. This method avoids detailed analysis of the search algorithm, and has been used to generate reasonably accurate results for some small *This research was supported in part by the National Science Foundation under grant number IRI-9058427 to medium sized problems; for some special cases, it is applicable to any size problem. The method is ap- plicable to Markovian search algorithms such as hill- climbing, random-restart hill-climbing, heuristic repair methods, genetic algorithms and simulated annealing. With some additional work, it could be applied to any bounded-memory search algorithm. We begin by introducing a mapping from a generic state space representation of any Markov process into a compact, abstract Markov model, in which states are characterized only by a syntactic “distance” from the nearest goal. This model is used to elicit a system of linear equations that can be solved by matrix methods to find the solution time for each state. For some special cases of the system of equations, we derive closed form expressions that enable us to make quantitative statements about the solution time of an algorithm, given estimates of the likelihood that the algorithm can reduce the syntactic “distance” on any step. When the likelihood increases for states closer to a goal, the theory demonstrates the existence of an “easy zone” within some radius of the goal states. Within this radius the expected number of steps to so- lution is small, but once a narrow boundary is crossed the expected number of steps grows rapidly. This has some interesting implications on how the initial state of heuristic algorithms affects the average length of a successful solution. The likelihood estimates can be obtained by theo- retical analysis of the algorithm and problem space, or by sampling. Although these methods are beyond the scope of this paper, we show that our predictions are not generally oversensitive to errors in these esti- mates. Finally, we claim that this Markov model can be a useful (albeit not perfect) model of a non-Markov process. Some preliminary empirical results are offered in support of this claim. An independent use of Markov models for algorithms appeared in in (Hansson et al., 1990), which uses a dif- ferent abstract space to optimize the search parameters of a hill-climbing algorithm. Work of a complementary nature has been done recently in (Cheeseman et al., 1991). Their approach can be described as an empirical 466 Problem Solving: Hardness and Easiness From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. investigation of the relationship between the difficulty of solution of a (constraint satisfaction) problem and various syntactic characteristics of the problem. They also discover a sharp transition between easy and hard or unsolvable problems. The Model Our ability to find the expected number of steps to solution depends strongly on the representation of the problem. ical State Space epresentation Any problem can be mapped into a state space repre- sentation consisting of a set S of states (So, S1 . . . , S,), a set A C S x S of weighted, directed arcs between the states, a set G C S of the goal states, and a state I E S. S is the set of possible states in the problem, A is the set of all transitions between states, G is the set of goal states, and I is the initial state (Newell and Simon, 1972). We assume WLOG: The weight on each arc is 1, Goal states are absorbing, meaning that there are no transitions out of a goal state, There are n features used to describe any state, Every operation, or transition, modifies only one fea- ture in the current state, and therefore counts as one step. (Hence, each state has 5 n outgoing arcs.) When we apply, for example, a hillclimbing algo- rithm to a problem, we are walking a path from the state I to a state g E 6, where each step in the path is a transition from some state Si to some state Sj, where (Si, Sj) E A. The above is a fairly standard basis for problem solv- ing in AI. When the algorithm to solve this problem is Markovl in nature, then it is possible to represent a problem and an associated algorithm by adding a probability to each transition. We therefore define pij to be the probability that the algorithm will move to Sj when in Si. Let NS(Si) be th e expected number of steps to reach a solution from state Si. To find the value of NS for all states we need only solve the the following set of linear equations: For every Si 4 G and every gi E G, NS(g;) = 0 n NS(Si) = c PijNS(Sj) + 1 j=l (1) NS(gi) = 0 because we are already at a goal state. The solution to this set of equations, if it exists, gives us the numbers we are looking for. There is, however, a major ‘The decision of which action to take in any state de- pends only on the current state and the set of transitions out of this state; there can be no direct dependence on past states. problem with such a direct approach. The state space of a small to medium sized problem is large enough to give us an enormous set of simultaneous equations, far too many to solve. Consider the 50-queens prob- lem where the goal is to place 50 queens on a 50x50 chess board without them attacking each other. In the most natural formulation of this problem, there are 50 variables, 1 for each row of the chess board. There are 50 possible values per variable. That leads to a state space with 50so states, and therefore 5050 simultaneous equations to solve! This is not very useful. Change of representation is a powerful tool in such cases, and has been used in the past to make classes of problems more tractable (Amarel, 1981; Nadel, 1990). Below we introduce a change of representation that drastically reduces the number of states in our state space representation, while retaining the information needed to estimate solution times. This change of representation is general enough to be applicable any problem/algorithm pair that can be modeled as above. Our Representation Let IIIFi be the set {c&l, . . . , di,} such that for state Si, dij is the number of features of Si that are different from the goal state gj E G. Define the distance dist(Si) to be min(DIFd). With this definition of distance, every goal state is at a distance of 0, and the largest distance possible is n, the number of features. Also, the shortest path from a state at a distance of i to the closest goal state will be 2 i in length. Note that with this definition, a given transition can decrease the distance while increasing the length of the shortest solution path. The new representation will have n + 1 abstract states {Do, . . . . D,), where Di corresponds to the set of states at a distance of i. The new goal state DO, corresponding to the set of goal states G, is the only ab- sorbing state. The states in this model no longer form a state space for the original problem/algorithm pair, but instead for the Markov model that approximates it. Since we allow transitions to affect only 1 feature, a transition from Di will leave us in either Da-l, Di, or D i+l. Thus there are a maximum of three transitions out of every state. The new transition probabilities tPii,tPi,i-19 Pi,i+l, t which must of course sum to 1, are defined as: hi = cS,EDi(‘(Sk) CSmEDj Pkm) p(sk) = CSj p(si)Pjk/ CSj,SlISI,SkEDi Pi1 where, given that the dist(Sk) = i and that we are currently in some state with a distance of i, P(Sk) is the prior probability that the state we are in is Sk. These equations show that it is possible, in princi- ple, to derive the new transition probabilities from the transition probabilities in the original space. However, it appears from the sensitivity analysis that it will also be acceptable (and often much more practical) to esti- mate these probabilities without any knowledge of the Musick and Russell 467 Figure 1: A Simple 3-Coloring Problem Regions A, B and C are to be colored red (r), green (g) or blue (b). I 1 Feature 1 Transition 1 I I State 1 Values 1 Probabilities 1 Goal? 1 Initial? s25 b,b,g s26 b,b,b . &s24-*+16 no no $24..+l? no no Table 1: Initial Representation of Problem The feature values shown are the colors associated with regions A, B and C, respectively. The transition probabilities show that our algo- rithm randomly selects a feature to change, then randomly changes the value. original transition probabilities, by sampling the algo- rithm’s behavior on a set of problems. Results of both methods are illustrated below. We now give a small example to demonstrate the transformation. Consider the 3-coloring problem in Figure 1, where the possible colors are (~,g, b) (red, green, blue). The goal is to find a color for each re- gion so that there are no neighboring regions with the same color. The allowable operations modify the color of one region at a time; thus there are a total of six possible transitions from any non-goal state. Let the algorithm for this problem be random, so that from the current state, one of the three regions is randomly chosen, then its color is changed to one of the two re- maining colors different from its current color. Table 1 shows the original state space representation, Table 2 shows our representation. State Represents States Transition Probabilities Goal? Initial? I I Do s5,7.11,15.19,21 Do yes no Dl S-Do-D2 +Do,+Dl,#2 no yes D2 sO.13.26 Dl no no 03 {I {I no no Table 2: Final Representation of Problem The second column shows where the states of the original represen- tation have been mapped. From the information in Table 2, we can predict a very quick solution. The transition probabilities tell us that from state 02 there is no choice but to move closer to a solution, to Dl. From state D1 , we have twice the chance to move to the goal state DO than to move further away again to D2. We will show below that, as one would imagine, the expected number of steps to solution is very dependent on the relative probabilities of moving towards or away from a solution. In fact, we explicitly measure the effect of this ratio on the expected number of steps for some special cases. The main result of this new representation is that the system of equations (1) becomes drastically smaller and simpler. For the general state space representation the size drops from O(nk) to O(n) where n is the num- ber of features, and k is the magnitude of the domain of the features. NS(Do) = 0 NS(Di) = tPi,i-lNS(Di-l) + tpi,iNS(Di) + tPi.i+lNS(Di+l) + 1 (2) Theoretical Implications of the Model We can rewrite the system of equations (2) as: NS(Do) = 0 -tPi,i- 1 NS(Di-1) + (1~ tpi,i)NS(Di) - tpi,i+lNS(Di+l) = 1 (3) Then putting this in matrix form, MxNS = F (4) where M is an (n + 1) x (n + 1) coefficient matrix, NS is the column vector (NS(Do), . . . , NS(D,))T, and F is the column vector (0, 1, . . . , l)T. By nature, M is a tridiagonal matrix, a matrix with 0 entries every- where but the diagonal and the two bands around it. On the lower band, all entries are of the form -tpi,i-1. These represent the (negative) probabilities of moving closer to the goal, from Di to Di,1. On the upper band, all the entries have the form -tpi,++l. These represent the probabilities of moving away from the goal. The diagonal contains entries of the form (1 - tpii) = tpi,i-1 + tpi,i+1. For convenience sake, throughout the rest of the paper we will call the lower band A (= [ai], an n x 1 column vector), the upper band C (= [ci]) and the diagonal B. Thus a 4 x 4 matrix M will look like: M= a1 bl Cl 0 0 02 b ~2 0 0 ag 83 (5) where in general cn example2 of how ai, = 0. In Figure 2 we show an bi and ci can vary as a function of the distance i. 2The particular transition probabilities shown were de- rived from mathematical analysis of a heuristic repair algo- rithm (Minton et al., 1990) applied to the class of random constraint satisfaction problems. This application is dis- cussed further below. 468 Problem Solving: Hardness and Easiness 1.0. 2 0.89 =: 3 0.69 A 0.4- B pc 0.2- 0.0-a Figure 2: Transition Probability Vectors Distance The vectors A, B and C a8 a function of distance. For example, --tplo,g = AIO = [alo] w .31 is the probability of moving from II10 to Dg on the next step. Because M is a tridiagonal matrix, solving for NS(Q) is a very efficient O(n) process. Furthermore, for some special cases of the M matrix, we can get a closed form for NS(Di). This not only allows us to calculate the solution time of a particular problem immediately, but, more importantly, it also tells us ex- actly what is influencing the expected number of steps over a whole class of problems. Closed Forms In this section we explore the case where ai = ui = Q and cd = ci = c, meaning that the A,B and C probability vectors are horizontal lines. This is not realistic for most problems, but it is an interesting case to examine (a biased random walk, or, in physics, a random walk in a uniform field). Solving the system of equations (4) for closed For tpl,s = --Q = -c, forms gives us: NS(Di) = ‘“n2;p;+o lji , For c = +a, or tz-31~ = &PI,O and 4 # 1 NS(Di) = ’ n+l(l- $7’) + i(1 - 4) Wl,O(l - dj2 (6) (7) The correctness of these equations has been tested empirically by comparing their predictions to those generated by solving the system of equations (4). The test set consisted of about 50 different prob- lem/algorithm descriptions, each of size n = 50. Note that we can derive equation (6) from (7) by letting 4 = 1 and applying L’Hopital’s rule twice. Based on equations (6) and (7) we can make several statements about the characteristics of the solution. FI e 8 Born equation (6) we can see that when a = c: NS(Di) is monotonically increasing as the distance i increases from 0 to n. (This also holds for equation m NS(Q) is directly proportional to i. This follows from a = c and b = --a - c = 2tpl.e. As the ten- dency to stay the same distance from the goal (@ii) increases, so increases the expected time to solution. For the case where c = &, equation (7) gives us some interesting information: e For 4 < 1, or when the probability to move closer to the goal is greater than to move away, the terms fP n+l and 4n+l-i are small, and the dominant term is i(1 - 4). Th is s h ows that for this case, NS(Di) increases nearly linearly as the distance from solu- tion grows, indicating that the problem will be easy to solve no matter what the initial state is. This coincided with the sample runs we have done. e For 4 > 1, or when we are more likely to move away from the goal than towards it, the terms @+l and 4 n+l-i are large, positive and dominant. Further- more note that within a very short distance i from the goal state Do, NS(Q) will grow to nearly its maximum value (see curve LA in Figure 3). This tendency increases as 4 grows larger. This is because at i = 1 the dominant term is @+l- 4” x 4n+1. As i increase to n, the dominant term grows monotoni- cally until it reaches 4 +l. This early jump suggests that when 4 > 1, if we do not start at a solution then we will never find a solution. Solutions for other continuous fuuctions The values in the A and C column vectors in the previ- ous section were restricted so that ai = aj and ci = ci. In this section we relax that restriction, and allow the values in A and C to vary according to any general function. Of course, the sum ai + bi + ci = 0 must still be true, by definition. Unfortunately, even for the case of linear variation of the values of A and C, we were unable to come up with a closed form. In fact, we believe it to be impossible to do so. We can still resort to solving the set of equations in (4) to get a feeling for NS(Di) in these more com- plicated systems. In Figure 3, we show the log plot of NS( Di) for several different problem/algorithm de- scriptions generated by solving the system of equations (4). From these plots and others like them, we have the following observations to make: e Our solutions have an interesting new characteristic. From the horizontal line cases described by equa- tions (6) and (7), we saw that the largest rate of increase occurs at distances near 0. However, when looking at lines LB and LC in Figure 3, we see a region between 0 5 i < 16 in which the expected number of steps to solution is small. Outside the re- gion, the expected number of steps to solution grows rapidly again. For example, for case LC in Figure 3, NS(Di) pl d ex o es at about 17, doubling with each step until reaching 23. For case LB the growth is even more dramatic. 4+ The boundary between this easy zone and the hard region can be very sharp, spanning just a few steps. e All of the hard problems reach asymptotes very quickly. The reason for this is that from any point, the probability of reaching state Dn before state DO Musick and Russell 469 Figure 3: Log plot of Expected Solution Times Log plots of expected solution times as a function of the distance of the initial state for several different problem/algorithms. LA: A, B and C are horizontal lines, c = 2a. LB: A is a cosine curve Al ta 1, A4g k: 0, C = 1 - bfA. LC:Aisaline,Al%l,Aqg=.2,C=l-A. LD: A, B and C are horizontal lines, C = A. LE: A, B and C are as depicted in Figure 2. is near 1, and the expected length of the solution from state Dn is a constant. This shows that for any heuristic problem solver, the choice of an initial state has a heavy impact on the expected solution time for the problem. Consider heuristic repair algorithms like that in (Minton e-t al., 1990). If indeed the preprocessor does not choose an initial state close to a goal state, then the algorithm will fail with high probability. A closed form solution will allow us to quantify the size of the easy zone, the sharpness of the boundary, and the magnitude of the subsequent jump of NS(Di). Sensitivity One issue that has not yet been addressed involves the sensitivity of the solution to errors in the estimates of A, B and C when we resort to solving the system of equations (4). After all, it might be unreasonable to expect to be able to determine the transition proba- bilities to within tenths of a percent, or even several percent of the true values. Let’s formalize this notion. Looking back at (3) and (4) we remember that F is a known matrix, but M is a matrix of error prone functions of tran- sition probabilities. Thus, we let TNS be the true NS(Di), TM be the true coefficient values, and ex- amine the effects of adding an error matrix X to the true coefficient values TM. This type of anal- ysis is presented in (Golub and Van Loan, 1983; Lancaster and Tismenetsky, 1985). 47~ Problem Solving: Hardness and Easiness (TM)TNS = F (8) (TM +X)NS = F NS = (TM + X)‘lF (9) We use the first few terms of a Taylor series expan- sion to get: (TM + X)-l F & TM-l(X)TM-lF + TM-IF (10) Merging (8), (9) and (10) we get NS & TNS + TM-l(X)TM-lF 01) Our measure of sensitivity is the relative error in TNS, or jw, calculated as: T”-;‘;~~;-‘F 5 n(TM)- IlXll IITMII (12) where n(TM) = IlTMll IITM-’ II is the condition number of the TM matrix, and ml iv-m is the relative error of TM. We can, of course, construct situations in which the TM matrix is very poorly conditioned. For example, if we let tpii be very close to 1, so that the probability of moving off state i is practically nil, then the corre- sponding bd = 0, and thus IITM-‘11 will be very large. In more normal situations, however, the TM matrix is well conditioned. Experimentally, perturbing the M matrix in (4) has led to similar relative disturbances in NS(Di). This is good; it implies that our confidence in NS( Di ) can be nearly as high as our confidence in the matrix that we created. Markov Models In general, the abstraction mapping we have applied does not preserve the Markov property of the original algorithm, and presumably the approximation will be even greater for an algorithm that is not Markov in the original space. At present, we can offer only em- pirical evidence that the results we obtain in our simple model bear a reasonable resemblance to the actual per- formance of the algorithm. Given our aims, it may be acceptable to lose an order of magnitude or two of ac- curacy in order to get a feeling for complexity of the given problem/algorithm pair. To investigate this issue, we built a non-Markov al- gorithm for the 8-puzzle problem and modeled it using the techniques described in the paper. The algorithm used to solve the 8-puzzle is a S-level look ahead hill climbing search guided by a modified manhattan dis- tance heuristic. The modification involves a penalty applied to any move that would place us in a state we have recently visited. When there are several options that look equivalent in the eyes of this heuristic, we choose randomly. Using this algorithm, we solved 100 randomly gen- erated 8-puzzles from each starting distance of 3, 4, Figure 4: A Markov model of a non-Markov process The line shown is the expected number of steps to solution predicted by the theory. The cross-bars show the mean and deviation of 100 actual runs from each initial distance. as 5, 6, 7, 8 and 9. For each run we kept track of the number of steps required to reach the solution. If the number exceeded 1000, we discarded the run. For each set of runs, we calculated the sample mean and the de- viation of the sample mean. These numbers represent the actual solution length characteristics of the non- Markov process. To generate the Markov model, we again solved 100 randomly generated &puzzles from each starting distance. These runs were used to cal- culate the transition probabilities by sampling, as de- scribed earlier. Using these transition probabilities, we solved the system of equations (4) to find NS(Q). Figure 4 shows the results. As can be seen from the figure, the resulting accuracy is quite acceptable. Conclusion This work represents the early stages of an effort to get a better understanding of how to solve combinato- rial problems. The logical conclusion of the effort will be an effective method for estimating the complexity (and variation thereof) of solving a member of a given class of problems, based on some description of the class. Results in this paper and in (Cheeseman et crl., 1991) show that the complexity can be highly depen- dent on certain parameters of the problem, and we have shown that these parameters can be estimated reason- ably well. An understanding of this extreme complex- ity-variation would uses metareasoning be to very useful for any system-that control combinatorial problem- solving, to allocate effort among subproblems, or decide how much effort to put into preprocessing. to The existence of an “easy zone” suggests that suc- cessful application of heuristic repair methods, which begin with an incorrect assignment of variables and gradually modify it towards a consistent depend on the density of solution, will solution states, the accuracy of the heuristic, and the quality of the starting state. In a forthcoming preprocessed paper, we derive these quantities for random constraint satisfaction problems, and examine the performance. correspondence of our model to actual Acknowledgements We would like to thank Jim Demmel and Alan Edel- man for their excellent suggestions dealing with matrix theory. References Amarel, S. 1981. On representation of problems of reasoning about actions. In Webber, B. L. and Nils- son, N. J., editors 1981, Readings in Artificial Intel- ligence. Morgan-Kaufmann, Los Altos, California. Cheeseman, P.; Kanefsky, B.; and Taylor, W. M. 1991. Where the really hard problems are. In Pro- ceedings of the Twelfth International Conference on AI. 331-337. Golub, G. H. and Van Loan, C. F. 1983. Matrir: Com- putations. The Johns Hopkins University Press, Bal- timore, Maryland. Hansson, 0.; Holt, G.; and Mayer, A. 1990. Toward the modeling, evaluation and optimization of search algorithms. In Brown, D. E. and White, C. C., editors 1990, Operations Research and Artificial Intelligence: the Integration of Problem Solving Strategies. Kluwer Academic Publishers, Boston. Lancaster, P. and Tismenetsky, M. 1985. The Theory of Matrices, Second Edition. Academic Press, New York. Minton, S.; Johnston, M.; Philips, A.; and Laird, P. 1990. Solving large-scale constraint satisfaction and sceduling problems using a heuristic repair method. In Proceedings of the Eigth National Conference on AI. 17-24. Nadel, Bernard A. 1990. Representation selection for constraint satisfaction: A case study using n-queens. IEEE Expert 5(3):16-23. Newell, A. and Simon, H. A. 1972. Human Problem Solving. Prentice hall, Englewood Cliffs, New Jersey. Musick and Russell 471 | 1992 | 83 |
1,280 | Using Deep Structure to r-8 s Colin I?. Williams and Tad Hogg Xerox Palo Alto Research Center 3333 Coyote Hill Road Palo Alto, CA 94304, U.S.A. CWilliams@parc.xerox.com, Hogg@parc.xerox.com Abstract One usually writes A.I. programs to be used on a range of examples which, although similar in kind, differ in de- tail. This paper shows how to predict where, in a space of problem instances, the hardest problems are to be found and where the fluctuations in difficulty are greatest. Our key insight is to shift emphasis from modelling sophisti- cated algorithms directly to rnodelling a search space which captures their principal effects. This allows us to analyze complex A.I. problems in a simple and intuitive way. We present a sample analysis, compare our model’s quantita- tive predictions with data obtained independently and de- scribe how to exploit the results to estimate the value of preprocessing. Finally, we circumscribe the kind problems to which the methodology is suited. Introduction The qualitative existence of abrupt changes in computa- tional cost has been predicted theoretically in (Purdom 1983, France & Paul1 1983, Huberman Jz Hogg 1987) and observed empirically in (Papadimitriou 1991, Cheese- man, Kanefsky & Taylor 1991). Indeed the latter results sparked fervent discussion at LJCAI-91. But the quan- titative connection between theory and experiment was never made. In part, this can be attributed to the theo- retical work modelling naive methods whilst the experi- mental work used more sophisticated algorithms, essential for success in larger cases. With the demonstrable exis- tence of phase transition phenomena in the context of real problems the need for a better theoretical understanding is all the more urgent. In this paper we present an approach to analyzing so- phisticated A.I. problems in such a way that we can predict where (in a space of possible problems instances) prob- lems become hard, where the fluctuations in performance are worst, whether it is worth preprocessing, how our es- timates would change if we considered a bigger version of the problem and how reliable these estimates are. Our key insight over previous complexity analyses is to shift emphasis from analyzing the algorithm directly to analyzing the deep structure of the problem. This allows us to finesse handling the minutiae of real algorithms and still determine quantitative estimates of critical values. The Problem We will take constraint satisfaction problems (CSPs) as representative examples of AL problems. In general, a CSP involves a set of p variables, each having an as- sociated set of domain values, together with a set of v constraints specifying which assignments of values to vari- ables are consistent (“good”) and inconsistent (“nogood”). For simplicity we suppose all variables have the same number, b, of domain values. If we call the variable/value pairings “assumptions”, a solution to the CSP can be de- fined as a set of assumptions such that every variable has some value, no variable is assigned conflicting values and all the constraints are simultaneously satisfied. Even with a fixed p and b different choices of con- straints can result in problems of vastly different difficulty. Our goal is to predict, in a space of problem instances, 1. where the hardest problems lie, and 2. where the fluctuations in difficulty are greatest. The other concerns mentioned above, e.g., what tech- nique is probably the best one to use, whether it is worth preprocessing the problem, and how the number of so- lutions and problem dficulty change as larger problem instances are considered, can all be tackled using the an- swers to these questions. Usually, an estimate of problem difficulty would be ad- dressed by specifying an algorithm and conducting a com- plexity analysis. This can be extraordinarily difficult es- pecially for “smart” programs. Instead we advocate ana- lyzing a representative search space rather than the exact one induced by any particular algorithm. Nevertheless, we should choose a space that mimics the efjPects of a clever search algorithm which we can summarize as avoiding redundant and irrelevant search. A space offering the po- tential for such economies is the directed-lattice of sets of 472 Problem Solving: Hardness and Easiness From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. assumptions that an assumption-based truth maintenance Fig. 1. The lattice of 4 assumptions, {A, B, C, D) showing levels 0 (bottom) through 4 (top). As assumptions are variable/value pairs the nogoods split into two camps: necessary nogoods (because at least one variable is assigned multiple values) and problem dependent nogoods (in which no variable appears more than once, so its status as a nogood is determined by domain constraints). We will assume our sophisticated A.I. program can make this distinction, allowing it to avoid considering the necessary nogoods explicitly. Thus we shall model a “reduced” lattice containing only the problem dependent nogoods’. Moreover, in the lattice model, the solutions are precisely the “goods” at level p because nodes at higher levels must include at least one necessary nogood and those at lower levels do not have a full complement of variables. How is difliculty defined? Finding a solution for the CSP involves exploring states in this lattice; the more states examined before a solution is found, the higher the cost. So we shall identify problem difficulty with Cs, the cost to find the first solution or prove there are none. Its precise value depends on the distribution of solutions in the lattice and the search method, but an approximation is given by using the cost to search for all solutions and, when there are solutions, dividing it by the number of solutions to estimate the cost to find just one of them. A simple direct measure of the cost to find all solutions counts the number of goods in the lattice since they represent partial solutions which could be considered during a search. This then gives if Nsoln > 0 (1) if Nsorn = 0 where G(j) is the number of “goods” at level j in the lattice and N,.,, = G(p) is the number of solutions. We should note that this cost measure directly corresponds ‘In (FVilliams & Hogg 1992) we compare this model with one containing all the nogoods and find no qualitative difference although the reduced lattice yields better quantitative results. to search methods that examine all the goods. Often this will examine more states than is really necessary and more sophisticated search methods could eliminate some or all of the redundant search. Provided such methods just remove a fixed fraction of the redundant states, the sharpness of the maximum in the cost described below means that our results on the existence and location of the transition apply to these sophisticated methods as well. Other cost measures, appropriate for different solution methods, could be defined in a similar way. For exam- ple, one could pick an order in which to instantiate the variables and restrict consideration to those sets of as- sumptions that contain variables in this order. This re- striction results in a tree, considerably smaller than the lattice, whose cost can be readily related to that of the lattice as follows. Each node at level j in the lattice specifies values for j variables. In a tree search pro- cedure these could be instantiated in j! different orders and likewise the remaining variables could be instantiated in (p - j)! orders. So each node at level j in the lat- tice therefore participates in j ! ( /I - j) ! trees. As there are /_L variables in total, there are ,u! orders in which all the variables could be instantiated. So the lattice cost mea- sure can be transformed into the tree cost measure by re- placing G(j) with j!(p - j)!G(j)/p! = ’ G(J)/ ( T fJ . This transformation gives a cost measure appropriate or sim- ple backtracking search in which successive variables are instantiated until no compatible extension exists at which point the method backtracks to the last choice. Since our interest lies in the relative cost of solving different CSP instances rather than the absolute cost and cost measures for the tree and full lattice attain maxima around the same problems (as confirmed empirically below), and the lattice cost is conceptually easier to work with (because we can ignore variable ordering), we use the lattice version. Although we characterize global parameters of the CSP in terms of the number of states that must be examined in the lattice we certainly do not want to have to construct the lattice explicitly because it can be enormous. Luckily, the lattice can be characterized in every detail by the set of minimal inconsistent partial assignments (which we’ll call the “minimized nogoods”) which can be obtained directly from the CSP by listing all inconsistent constraint instances and retaining only those that are not a superset of any other. These form a Sperner system (Bollobas 1986) because they satisfy the Sperner requirement that no set is a subset of any other. Note that minimized nogoods and minimal nogoods are slightly different: if there were no solutions there might be many minimized nogoods but there would be a single minimal nogood, namely the empty set. As we shall see, by mapping a CSP into its equivalent set of minimized nogoods we can predict the cost and number of solutions and hence the problem difficulty. This Williams and Hogg 473 approximately once the func- tional form for Psoln is own. IJnfortunately, an exact derivation of Psoln is complex. Wowever, since it ap- proaches a step function, its behavior is determined by the critical value /3 = p,“fi[ at which it changes from being near 1 to near 0, i.e., the location of the step. An approxi- mation to the exact position of the step can be obtained by assuming that the existence of each solution is indepen- dent of the others. Under this assumption, the probability to have no solutions is just the product of the probabilities that each state at the solution level is not a solution. Thus we have Psoln w I- (1 - JI,)~’ where pp, given in Eq. 2, is the probability that a state at the solution level is in fact a solution. T&ing logarithms and recognizing that at the transition between having solutions and not having solu- tions p, must be small gives us In (1 - PJoln) m -bpp, which can be written as Psoln N 1 -e-(Nsoln) because the expected number of solutions is just (N,,r,) = (G(p)). We see immediately that if (MS orn ) ---) 00, Psoln + 1 and if (N,oh) + 09 Psoha + 0. Fig. 2. Behavior of In (Nsoln) as a function of ,8 and p for k = 2; b = 3. The behavior of In (Nso,n) is shown in Fig. 2. This shows there is a transition from having exponentially many to having exponentially few solutions at some crit- ical value of p = &it. This value can be determined by using Stirling’s approximation to simplify the bino- mial coefficients from Eq. 3 appearing in In ( Nsoln) = In (G(p)) to give (Williams & Hogg 1992) In ( Nsolta) - /-L [ln (b) + /3 In (1 - bek)]. The transition from exponen- tially many to exponentially few solutions occurs at the point when this leading order term vanishes. IIence, P lnb crit = - In (1 - b-“) (5) Fig. 3. Approximation and b 3. = t0 Cob 8s a function of /I for k = 2 Thus, in this approximation, the probability profile, Psoln (p) does indeed approach a sharp step as p + 00, with the step located at flzii[ B ,&.it. Substituting for ( Nsorra ) in the approximation for Pjol,, yields Psoln RS l-exp (-exp (p[ln(b) +p ln(l - b--k)])),asketchof which is shown in Fig. 3. Notice how the sharpness of the step increases with increasing p suggesting the above approximations are accurate for large CSPs. Cost to First Solution or to Failure (Le., At this point we can calculate the average number of goods at any level (including the solution level) and the critical point at which there is a switch from having solutions to not having any. Thus we can estimate (C8) by: /(NJoln) P < Pcrit (6) P L Pcrit The behavior of (CJ versus ,B (a resealing of the number of minimized nogoods) is shown in Fig. 4. It shows that the cost attains a maximum at &at and that this peak become increasingly sharp as p -+ 00. Thus a slice at constant ~1 shows what happens to the computational cost in solving a CSP as we sweep across a range of CSPs having progressively more minimized nogoods. Notice that well below the critical point there are so few minimized nogoods that most states at level p are solutions so the cost is low. Conversely, well above the critical point there are so many minimized nogoods that most futile paths are truncated early and so the cost is low in this regime too. Another property of this transition is that the variance in cost, (Cz) - (C# )“, is a maximum in the vicinity of the phase transition region, a property that is quite typical of phase transition phenomena (Cheeseman, Kanefsky & Williams and Hogg 475 Fig. 4. Plot of the cost (C,) versus p for A = 2 and b = 3. Taylor 1991, Williams & Hogg 1991, Williams & Hogg 1992). We therefore have a major result of this paper: as the number of minimized nogoods increases the cost per so- lution or to failure displays a sudden and dramatic rise at a critical number of minimized nogoods, merit = &itp. Problems in this region are therefore significantly harder than others. This high cost is fundamentally due to in- creasing pruning ability of minimized nogoods with level in the lattice: near the transition point the nogoods have greatly pruned states at the solution level (resulting in few solutions) but still leave many goods at lower levels near the bulge (resulting in many partial solutions and a rela- tively high cost). Experimental Confirmation So much for the theory. But how good is it? To evaluate the accuracy of the above prediction of where problems become hard we compare it with the behavior of actual constraint satisfaction problems. Fortunately, Cheeseman et al. have collected data on a range of constraint satis- faction problems (Cheeseman, Kanefsky & Taylor 1991), so we take the pragmatic step of comparing our theory against their data. For the graph coloring problem we found p = iyb. By substituting Pcrit for /? we can predict the critical connectivity at which the phase transition takes place, Y theory crit * and compare it against those values Cheeseman et al. actually measured. Our model both predicts the qualitative existence of a phase transition at a critical connectivity (via P,-rit) and estimates the quantitative value of the transition point to within about 15%. Scaling is even better: as b changes from 3 to 4 this model predicts the transition point in- creases by a factor of 1.73, compared to 1.70 for the ex- perimental data, a 2% difference. The outstanding discrepancy is due to a mixture of the mathematical approximations made in the derivation, Table 1. Comparison of theory and experiment. The experimen- tal values were obtained from Fig. 3 of (Cheeseman, Kanefslq & Taylor). the absence of explicit correlations among the choices of nogoods in our model, the fact that Cheeseman et al. used “reduced” graphs rather than random ones to eliminate trivial cases, the fact that their search algorithm was heuristic whereas ours assumed a complete search strategy, and statistical error in the samples they obtained. We have proposed an analysis technique for predicting where, in a space of problem instances, the hardest prob- lems lie and where the fluctuations in difficulty are great- est. The key insight that made this feasible was to shift emphasis from modelling sophisticated algorithms directly to nmdelling a search space which captures their principal effects. Such a strategy can be generalized to any prob- lem whose search space can be mapped onto a lattice, e.g., satisficing searches (Ma&worth 1987) and version spaces (Mitchell 1982), provided one re-interprets the nodes and links appropriately. In general, the minimized nogoods may not all be confined to a single level or they may overlap more or less than the amount induced by our as- suming their independence. In (Williams and Hogg 1992) we explore the consequences of such embellishments and find no significant qualitative changes. However, for a fixed average, but increasing deviation in, the size of the minimized nogoods, the phase transition point is pushed to lower /3 and the average cost at transition is decreased. Similarly, allowing minimized nogoods to overlap more or less than random moves the phase transition point to higher or lower p respectively with a concomitant decrease or increase in the cost at transition. A further application is to exploit our cost formula to estimate the value of constraint preprocessing (Ma&worth 1987). Although the number of solutions is kept fixed, preprocessing has the effect of decreasing the domain size from b --) b’ causing a corresponding change in p + p’ given by the solution to N,aln(~, k; b, ,8) = Korn(p, kb’,P) h’ h ’ t w lc m urn allows the change in cost tobecomputed,C,(~,k,b,P) - C’&&b’,p’). Wefind that the rate of the decrease in cost is highest for problems right at the phase transition suggesting preprocessing has the most dramatic effect in this regime. 476 Problem Solving: Hardness and Easiness In addition, related work suggests cooperative meth- ods excel in regions of high variance. As the variance is highest at the phase transition, the proximity of a prob- lem instance to the phase transition can suggest whether or not cooperative methods should be used (Cleat-water, Huberman 6% Hsgg 1991). The closest reported work is that of Provan (Provan 1987a, Provan 1987b). Nis model is different from ours in that it assumed a detailed specidication of the mini- mized nogoods which included the number of sets by size together with their intra-level and inter-level overlaps. We contend that as A.I. systems scale up such details become progressively less important, in terms of understanding global behavior, and perhaps harder to obtain anyway. In the limit of large problems, the order parameters we have discussed (cardinality m and average size k) appear to be adequate for graph coloring. For other types of CSP it might be necessary to calculate other local characteris- tics of the minimized nogoods e.g. the average pairwise overlap or higher moments of their size, in order to make sufficiently accurate predictions. One can never know this until the analysis is complete and the predictions com- pared against real data. But then, one should not accept any theory until it has passed a few experimental tests. Experience with modelling other kinds of A.I. systems (Huberman & Hogg 1987, Williams 8t Hogg 1991) leads us to believe this phenomenon is quite common; the anal- ysis of relatively small A.I. systems, for which the de- tails most definitely do matter, do not always supply the right intuitions about what happens in the limit of large problems. Moreover, the existence of the phase transition in the vicinity of the hardest problems would not have been apparent for small systems as the transition region is somewhat smeared out. The results reported are very encouraging considering how pared down our model is, involving only two order pa- rameters, the number and size of the minimized nogoods. This demonstrates that, at least in some cases, a complete specification of the Sperner system is not a prerequisite to predicting performance. However, a more surprising result was that search spaces as different as the assumption lattice described here and the tree structure used in backtracking yield such close predictions as to where problems become hard. This sug- gests that the phase transition phenomenon is quite generic across many types of search space and predicting where the cost measure blows up in one space can perhaps sug- gest where it will blow up in another. This allows us to finesse the need to do algorithmic complexity analyses by essentially doing a problem complexity analysis on the lattice. This raises the intriguing possibility that we have stumbled onto a new kind of complexity analysis; one that is generic regardless of the clever search algorithm used. These observations bode well for the future utility of this kind of analysis applied to complex A.I. systems. References Bollobas , B . 1986. Combinatorics, Cambridge University Press. Cheeseman, P.; Kanefslcy, B.; and Taylor, W. M. 1991. Where the Really Hard Problems Are. In Proceedings of the Twelfth International Joint Conference on Artificial Intelligence, 33 l-337, Morgan Kaufmann. Clearwater, S.; Huberman, B. A.; and Hogg, T. 199 1. Cooperative Solution of Constraint Satisfaction Problems. Science, 254: 1181-l 183. de Kleer, J. 1986. An Assumption Based TMS, Artificial Intelligence, 28: 127-162. Prance and Paul1 1983. Probabilistic Analysis of the Davis Putman Procedure for Solving Satisfiability Problems, Dis- crete Applied Mathematics 5:77-87. Huberman, B.A. and Hogg, T. 1987. Phase Transitions in Artificial Intelligence Systems, Artificial Intelligence, 33:155-171. Mackworth, A. IS. 1987. Constraint Satisfaction. In S. Shapiro and D. Eckroth (eds.) Encyclopedia of Artifzcial Intelligence, 205-211. John Wiley and Sons. Mitchell, T. M. 1982. Generalization as Search. Artz$cial Intelligence, 18:203--226. Papadimitriou, C. H. 1991. On Selecting a Satisfying Truth Assignment. In Proceedings of the 32nd Annual Symposium of Computer Science, IEEE Computer Soci- ety. Provan, G. I987a. Efficiency Analysis of Multiple Context TMSs in Scene Recognition. Tech. Rep. OU-RRG-87-9, Robotics Research Group, Dept. of Engineering Science, University of Oxford. Provan, G. 1987b. Efficiency Analysis of Multiple Con- text TMSs in Scene Representation. In Proceedings of the Sixth National Conference on Artificial Intelligence (AAAI87), 173477: Morgan Raufmann. Purdom, P. W. 1983. Search Rearrangement Backtrack- ing and Polynomial Average Time, Art@ciaZ Intelligence, 21~117-133 Williams, C. P. and Hogg, T. 1991. Universality of Phase Transition Phenomena in A.I. Systems. Tech. Rep. SSL-9144, Xerox Palo Alto Research Center, Palo Alto, CalifQrnia. Williams, C. P. and Hogg, T. 1992. Exploiting the Deep Structure of Constraint Problems. Tech. Rep. SSL-92-24, Xerox Palo Alto Research Center, Palo Alto, California. Williams and Hogg 477 | 1992 | 84 |
1,281 | Franz Barachini, Hans Mistelberger Alcatel-ELIN Research Centre Ruthnergasse l-7 12 10 Vienna, AUSTRIA Tel.: (+43) 222 / 39 16 21/ 150 Email: es-barac@rcvie.at Abstract A major obstacle to the widespread use of expert sys- tems in real-time domains is the non-predictability of response times. While some rese‘archers have addressed this issue by optimizing response time through better al- gorithms or parallel hardware, there has been little re- search towards run-time prediction in order to meet user defined deadlines. To cope with the latter, real-time ex- pert systems must provide mechanisms for estimating run-time required to react to external events. As a starting point for our investigations we chose the RETE algorithm, which is widely used for real-time production systems. In spite of RETE’s combinatorial worst case match behavior we introduce a method for es- timating match-time in the RETE network. This paper shows that simple profiling methods do not work well, but by going to a finer granularity, we can get much bet- ter execution time predictions for basic actions as well as for complete right hand sides of rules. Our method is dynamically applied during the run-time of the produc- tion system by using continuously updated statistical data of individual nodes in the RETE network. 1 Introduction An expert system operating in a real-time environment would typically need to react to interrupts quickly ‘and to gen- erate a response within a given time-frame (Laffey et al. 1988). In this respect, execution time variance is the primary problem in providing perfomlance gu‘arantees for real-time production systems. Speeding up software and hardware is one approach to meet certain deadlines. RETE (Forgy 1982) and TREAT (Mi- mnker 1987) proved to be fast pattern matching algorithms for production systems. Special-purpose hardware h,as been developed (Bahr et al. 1991; Gupta et al. 1986a; Gupta et al. 1986b; Gupta & Tambe 1988) to increase the perfomlance of RETE. However, speed-up is limited and does not solve the 1. This research is p‘art of the ESPRIT project CIM-AT and supported by an FFF ‘and ITF grant from the Austrian government. hoop Gupta Department of Computer Science Stanford University Stanford, CA 94305, U.S.A. Tel.: (+l) 415 / 725 37 16 Email: ag@pepper.stanford.edu run-time prediction problem. In order to have an indication whether a deadline will be met, match-time predictability is a necessity for real-time applications. This is justified by the fact that most of the overall run-time ofexpert systems is used in the match phase (Gupta 1986). Ideas limiting match com- plexity are given by Haley (Haley 1987), Wang (Wang et al. 1990), Tambe (Tambe & Newell 1988; Tambe, Kalp, Rosen- bloom 1991), and Acharya (Acharya 1991). Haley and Wang try to put limits on the amount of data approaching the expert system. Tambe ‘and Ach‘arya shift match combinatorics from knowledge search to problem space search. Our first step towards the long-term goal of building real- time expert systems is the prediction of the time taken by ba- sic actions in the right h‘and sides of rules. For the sake of RETE’s consistency (Barachini & Theuretzbacher 1988) these actions are usually implemented as non-preemptable code pieces in most production system languages. Hence, the time for the execution of such ‘an action determines the granu- larity at which interrupts can actually be handled*. Moreover, if the estimated time for a basic action exceeds a user-defined deadline, the production system architecture allows us to raise certain exception handlers. Our next step is the prediction of run-time for complete right hand sides. We show that this goal c‘an be achieved with the same accuracy as for basic actions, and therefore the same deadline strategies can be applied. By using our method, a high-level reasoning system could detect situations when rule execution time might exceed an allocated time interval. If this is the case an exception handler would be raised delivering incomplete or suboptim,al results to the high-level reasoner. The estimation method for the basic actions and the com- plete right hand sides is dynamically applied during the run- time of the production system by using continuously updated statistical data of individual nodes in the RETE network. The idea is not restricted to RETE but can be applied to TREAT as well. After a brief overv$w on production systems, we intro- duce our notion of run-&me predictability. We show that sim- \ 2. In the literature ness of a system. this is also known as the 478 Problem Solving: Real-Time From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. ple profiling methods do not work well for run-time predic- tion. We describe the technique our run-time estimation tool is going to use for run-time forecast. We compare forec‘ast and actually measured run-times on several typic&al produc- tion systems. The run-time estimation method will be ex- plained in temls of PAMELA (PAttem Matching Expert sys- tem LAnguage) (Barachini 1991). Basic Statements and Definitions For the following discussion it is assumed that the reader is familiar with the RETE or TREAT algorithm as well as with the vocabulary normally used in reference to OPS (Brown- ston, F‘arrell, & Kant 1986; Forgy 1981). Production System A production system consists of a rule set, called the Produc- tion Memory (PM) and a database of assertions, called the Working Memory (WM). Each rule consists of condition statements, called the Left Hand Side (LHS) and a set of ac- tions, called the Right Hand Side (RHS). The RHS specifies infomlation which is to be added to or removed from the WM. In PAMELA there are basically three possible actions in the RHS. MAKE adds a new Working Memory Element (WME) to WM. REMOVE deletes an ex- isting WME from the WM. CHANGE modifies an already existing WME. Each WME corresponds to a certain type of data, called its Working Memory Type (WMT). Each RHS consists of one or several WME actions (MAKE, CHANGE or REMOVE). The production system repeatedly performs the so-called Recognize-Act Cycle (RAC). During this cycle a RHS is ex- ecuted, leading to a match phase which determines a Conflict Set (CS) of satisfied rule instantiations. The CS resolution procedure selects one rule to be fired and the act procedure ex- ecutes the RI-IS. The PAMELA inference engine uses an optimized RETE match algorithm (Barachini 1988). The RETE algorithm maps LHSs of rules to a discriminating data flow network. The data elements flowing through this network are called to- ken. When a WME is added to or removed from the WM, a positive tagged token (plus-token) resp. a negative tagged to- ken (minus-token) representing this action is passed to this data flow network. There are different node types av‘ailable in this network. The constant condition tests are perfomled at so-called one-input nodes (IIN) and matched tokens are stored in &alpha memories. Copies of matched tokens ‘are sent to successor nodes. The most run-time intensive node nor- mally is a two-input node (21N). Tokens arriving at two-in- put nodes are compared against the tokens stored in the oppo- site token memory. Successfully joined tokens Lare then sent again to a successor node. In this m,armer tokens flow through the network until they arrive at the end-node. If this is the case an instantiation enters the CS. Run-Time Predictability Within the context of the present paper we will investigate predictability for the following quantities: the time needed to perform one WME action and the time needed to perform all WME actions of a rule. Measurements have shown that most of the overall run-time of RHS is used by WME actions (Gupta 1986a). Therefore, it is worthwhile to concentrate our studies on these specific actions. We are aware that the RHS of a rule may include other statements than WME actions. These statements are assumed to be procedural whose run-time predictability is not the sub- ject of this paper. In most production system languages, WME actions are indivisible subt‘asks. Whenever an interrupt modifying WM contents rises during the match phase, it cannot be handled immediately. For the sake of consistency, it must be post- poned and can only be executed after the completion of the current action. In PAMELA, at the end of each WME action, the system reaches a so-called preemption point. At this pre- emption point, any interrupt is handled which may have risen since the previous preemption point. Thus, the time required for a WME action is particularly crucial as it represents the time the system needs to react to an external interrupt. The run-time for a rule’s RI-IS represents the time for a complete rule firing. Predictability at this level enables the system to detemiine whether the rule can be executed within ‘an allocated time frame. refiling Metho An obvious approach to run-time predictability is profiling of the qmantities we want to predict. In this section we will as- sess the quality of profiling methods with respect to the pre- diction for WME actions and for RHSs of rules. As a starting point of our investigation, we measured the run-time behavior of WME actions for specific WMT’s over all fired rules. We performed a whole bunch of me‘asurements with ParaOPS5 (Kalp et ‘al. 1988) on the Encore Multimax at Stanford. At the level of a WME action, the results depend on the WMT considered. For some WMT’s the run-time for a WME action is nearly constant, for other WMT’s run-time exhibits irregular behavior. By irregular run-time behavior we mean that the time for the execution of the WME action differs subst,antially from one RAC to the next. In order to find me,aningful data even in this latter case, we restricted ourselves to the study of run-time required for a WME action of a particular WMT, but now in the scope of a specific rule’s RHS. Unfortunately, our measurements show that this time is also rather irregular. It highly depends on the number of actions performed in the network, that is to say on the number of matches and on the number of insertions and Barachini, Mistelberger, and Gupta 479 Activation time (ms) 160 140 120 100 80 60 40 20 0 2 3 4 5 6 7 Actions Figure 1: MAKE “Goal” action-time in rule “Sequence 5” in RUBIK deletions. For example, in RUBIK” the rule “Sequence-S” has a very simple RI--IS, consisting only of one MAKE for the WMT “Goal”. Figure 1 shows the evolution of the time re- quired for the RHS firing of this rule. It w&as fired seven times during the execution for a specific cube configuration. When applying the profiling method to the run-time of a rule’s RHS, we encountered similar results. Each production system studied contained at le,ast one rule showing irreguhar run-time behavior. Based on this fact we conclude that profil- ing of rule execution times is not adequate for run-time pre- diction. To summarize, measurements of execution times for WME actions or RHSs cannot be used as a basis for run-time prediction. These discouraging results are quite general in na- ture. They hold for OPS-based as well as for PAMELA- based expert systems irrespective of their implementation method. We observed that for some WMTs the run-time be- havior is sufficiently regular to perform prediction at this lev- el of granularity. But we have also encountered WMTs for which it is not advisable to rely on rule- or WME action ex- ecution-time. In these cases more accurate tools b,ased on data at a liner level of granularity are needed. e Run-The Prediction As explained, simple profiling of run-time for RHSs and WME actions is not suitable for run-time prediction. There- fore, we investigate run-time estimations which rely on sta- tistical data, dynamically gathered at node-level of the RETE network. The method presented in this section is designed to predict run-time for individual tokens originating from a 3. RUBIK is a production system with 7 1 rules which 4. This is true for positive compare nodes only. Not solves the Rubik’s cube. nodes are treated separately. WME action. More precisely, we are going to estimate run- time for the match phase when a plus-token enters the RETE network. We concentrate only on plus tokens because PAME- LA treats minus-tokens in a very specific manner. The tokens in the network are linked together in a tree structure where each token points to its successors. Therefore, in contrast with the original RETE implementation, minus-tokens are not re- matched. Instead, tokens are directly removed from token memories during the deletion phase4. Since the number of to- kens being removed is known, we cCan calculate the exact run- time for minus-token treatment. Therefore, we concentrate only on plus-token treatment for the remainder of this paper. Run-Time Estimation at Token Level At the beginning of its flow through the RETE network, the token filters through one-input nodes. Only a small frac- tion of run-time is spent during one input-node treatment (Gupta 1986). Therefore, worst case run-time, which is linear in the number of incoming tokens for the one-input node net- work, is fairly sma.lI compared to overall match-time. This upper bound can be e‘asily calculated by the assumption that no liltering takes place in one-input nodes. We assume an im- plementation in which tokens of one WME of aRHS are gath- ered at the end of one-input node ch‘ains. The one input- nodes Cam treated first and we then start the estimation task. Thus, we know the exact number of tokens entering the two- input node network. The token flow in the network is characterized by several elementary operations. In a two-input node, each incoming token is comptiared against every token from the opposite memory. For each successful match, one new token is created and stored in the input memory of the successor. In order to estimate the time spent in a particular node during a plus-to- ken treatment, we rely on the following numbers: @ the number of tokens entering this node, @ the time required for one token insertion into a token memory, @ the time required for a match. All relevant token numbers for a specific plus-token (e.g. the number of new tokens produced by a two-input node) have to be estimated before actual matching suarts. Because of the worst case cotnbinatorial behavior of RETE and TREAT, it is not feasible to estimate these numbers only by evaluating the largest theoretical number of tokens that could flow through the network. Most of the time, this upper bound would be too large to be of any significcance. For the two-input nodes, our estimation is based on the im- plementation of a token flow ratio pk in each two-input node (see Figure 2). The factor pk represents the probability for a successful match at node k, when a token is compared against another. This probability factor pk is updated after each per- formed plus-token treatment. 488 Problem Solving: Real-Time Using formulas (1) to (8), we can estimate the number of tokens that will be created in the network. In order to estimate the time required for the plus-token treatment, we measured the time for an insertion in a token memory and the time for amatchonaT800 transputer5 (Bahret al. 1991), witbapreci- sion of 1 vs. We measured the following times: Figure 2: RETE network For our estimation, we use the following numbers: Vk 1.. Number of matches at node k nik . . . Number of tokens in right memory of node k nk . . . Number of tokens in left memory of node k ihk . . . Number of plus tokens entering the right memory of node k 6nk . . . Number of plus tokens entering the left memory of node k Pk +-- Probability for a successful match at node k For tokens entering the right memory of node k, we get Vk = nk * hik (1) snk+l =pk * Vk (2) for a two-input node and Vk = nk * hk (3) 6nk+l = 0 (4) for a not node. For tokens entering the left memory of node k, we get Vk = mk * 6nk (5) snk+l =pk * vk (6) for a two-input node and vk = nik * 6nk 6nk+ 1 = (1 - pk)“‘k * 6nk for a not node. (7) Go Note that equation (4) does not mean that no tokens are ac- tually created in the RETE network. It only means that those possibly created tokens are negative tokens, and, therefore, we do not take them into account because of PAMELA’s spe- ciaI minus-token treatment. 5 ps for a match invoking a simple equality test, which is the most common situation. But since PAMELA offers the possibility to call a C-function within the test, the time for a single match may be significantly longer. We will thus also have to make our predictions with larger match-times. 50 ys for an insertion in a right token memory. This time does not depend on the node nor on the token whose length is always one in a right memory. (50 + 6*L) p for an insertion in a left token memory, where L is the left token’s length. (L actually means the number of WMEs it consists of). This dependence is due to the fact that PAMELA loops L times to copy the token into the memory. Finally, the run-time prediction tool estimates the number of actions to be performed in the network (matches and inser- tionsj. In this way, match-time for the whole next WME ac- tion is estimated dynamically during run-time of the expert system. The run-time prediction adds some burden to the whole execution-time of the expert system. However, compared to match-time this additional time is small. On our Transputer- b‘ased system, 50 ps run-time overhead must be taken into consideration per affected two-input node. The measurements presented in this section were performed in the following way. Using the time required for each eie- mentary action, we implemented a simulator, which com- putes the time that it would take on a T800 tr‘ansputer. This method presents the great adv‘antage that we can vary the val- ues of the match-time and study their influence on the quality of our prediction. Our measurements were performed on seven production systems: EMAB, the monkey ‘and banan‘as production system writ- ten by NASA in an extended version with 29 rules RUBIK, a production system with 71 rules that solves the Rubik’s Cube by J. Allen TOURNEY, a production system assigning match sched- ules to a bridge tournament with 16 rules WALTZ, a pattern recognition programme with 33 rules 5. Our parallel architecture for speeding-up Produc- tion Systems is based on T800 Transputers. Barachini, Mistelberger, and Gupta 481 @ VAHlNE, a production system with 55 rules (by Alcatel - ELIN) that advises road maintenance in winter for giv- en weather conditions. 0 CARS, a production system with 62 rules (by Alcatel- ELIN) that dynamically maximizes traffic throughput on a network of roads and crossings. * ALAMOS, an industrial version of a production system that performs alarm correlation on S 12 which is Europe’s largest public switching system. The expert system con- tains 112 rules at the moment and is a collaboration effort between Alcatel-ELIN in Vienna and BELL in Belgium. VAHlNE, ALAMOS ‘and CARS are typical real-time pro- duction systems in the sense that they are continuously gath- ering data from the periphery via interrupts and polling mech- anisms. CARS is especially time critical since it has to react immediately on traffic congestions. Although all three exam- ples are only medium sized with respect to the number of rules they utilize vast amounts of data produced by the process pe- riphery. For reasons of statistical significance, we only present the results for those of the WMTs appearing sufficiently often during the expert system execution. The tables l-7 display the averages and the variances of the ratio (real time)/(esti- mated time) for each of the seven applications. monkey !w~ object 0.99 1.02 1.03 0.14 0.69 0.19 Table 1: EMAB Table 2: RUBIK apl 1.00 0.00 CXl con fou Pla 1.00 191.24 1.09 1 .oo 0.00 799.33 0.83 0.00 Table 3: TOURNEY Table 4: WALTZ Table 5: VAHINE time 1.05 0.03 cross 0.97 0.01 Table 6: CARS Table 7: ALAMOS 482 Problem Solving: Real-Time These results were obtained using specilic probability up- 60% of the time between 0.5 and 2.0. Therefore, and despite dating processes in two-input nodes. Let <y,,> be our esti- our barge variance (table 3), the result is even there meaning- mated probability for time n and let pI1 be the real ratio at time ful. Note also that the results are not significantly influenced n (ev‘aluated after match phase at time n) then we def”me: by the updating algorithm we choose. qhl+I> = c3*pn + <P&/4 (ALGO 1) In the following discussion, we will refer to this updating procedure as ALGO 1. More obvious updating algorithms are ALGO2andALGO3: <Pn+ 1’ = (pn + 9n>Y2 (ALGO 2) <pn+ 1’ = pn (ALGO 3) ALGO uses the real ratio pn of the last RAC only. ALGOl and ALGO also take the pn’s of all previous RACs into ac- count, but they have different damping factors for older p,,‘s. Altogether, the results in tables l-7 show a fairly small variance, allowing us to expect in most cases an error lower than a factor 2. The factor is smaI1 compared to prediction based on simple profiling methods. The only exception to this favorable behavior is the WMT “Context” in TOURNEY. This WMT works like a goal switch during the execution of TOURNEY. Therefore, a MAKE statement of this type can reveal an unexpected behavior which invalidates the proba- bilities. In reference to OPS such a MAKE statement is called a context switch, and as yet we are unable to predict match- time for a such a context switch WME. percentage of events 100 90 80 70 60 50 40 30 20 10 0 <al [.1,.5] [.5,.9] [.9,1.ll[l.1,21 [2,101 >lO real/estimated Figure 4: distribution of (real time)/(estimated time) for MAKE “goal” in RUBIK Nevertheless, the result is not as bad as it fust seems to be. In fact, although those variances above give M indication for the accuracy of the prediction, Figure 3 provides a more rele- vant infomlation. It shows the distribution of the ratio (real time)/(estimated time) for our three algorithms. Figure 3 shows that about 50% of the time the ratio (real time)/(estimated time) is between 0.9 and 1.1 using the three algorithms. It also shows that, even in the worst c,ase, 80% of the time the ratio real/estimated is between 0.1 and 10.0 and Another interesting context switch is the “Goal” WME in RUBIK. The corresponding distribution of the ratio (real time)/(estimated time) has been calculated with ALGOl and is shown in figure 4. Although the variance was once ag,a.in not very snmll (table 2), a match-time with a precision better than 10% is predicted by the run-time estimation method more than 90% of the time. In all other cases where a basic action does not correspond to a context switch, the run-time prediction is even more ac- curate. This accuracy is expressed by the very small variances of the corresponding WMTs in the tables l-7. percentage of events 60 50 40 30 20 10 0 ALGO 1 I ALGO 3 co.1 [O. 1,0.5] [0.5,0.9] [0.9,1.1] [l.l, 2.01 [2.0, 10.01 > 10.0 real/estimated Figure 3: distribution of (real time)/(estimated time) for lvlAK~ “Context” in TOURmy Barachini, Mistelberger, and Gupta 483 Results of the Run-Time Estimation Method for Rules So far we ‘are able to predict run-time for individual WME ac- tions only. We w&ant to go one step further and consider run- time prediction for a complete RHS, which may consist of several WME actions. The estimation mechanism is the same as for a single WME action but now the tokens of all WME actions belonging to one RHS Care gathered at the end of the one-input node ch,ai.ns before the estimation task starts. As a typical example we chose the RI-IS of the rule “mi- nus-90” in RUBIK. The RHS consists of 2 1 CHANGE state- ments. Figure 5 shows the act& (simulated) run-time versus the estimated run-time. Although the estimated run- time de- viates slightly from the actu‘al one, the estimation models quite well the run-time behavior. The good quality of estima- tion could only be achieved by using our described fine gran- uharity method. For al.l rules of the production systems pres- ented in this paper we observed a notable correspondence between real and estimated rule execution times. Only in those cases where the RHS contains a context switch WME, the accuracy of the prediction is severely reduced. Run-Time Estimation for a Complete Production System Task The prediction of the total answering time for a complete task consisting of many reasoning cycles still remains an open problem. This is due to the fact that the sequence of rule fir- ings cannot be known in advance. Even if we had tools that w able to extract relevant knowledge from the expert sys- tem’s behavior we would have difficulties in predicting mxt run-time (ms) rule-firing sequences. Although some research has beendone towards funding statical and dynamical rule dependences (Is- chida 1990), a general solution for finding correct sequences is lacking. This is especially true for interrupt4riven produc- tion systems which are continuously gathering on-line data from industrial processes. Even if we knew rule-liring se- quences in advance the reliability on the probabilities pk and on the estimated number of tokens in the RETE memories de- creases with incre‘asing number of RACs to be predicted. In intelligent high-level reasoning task5 the issue is not whether we can exactly predict run-time of specific tasks. The issue is more on the design of a problem-solving archi- tecture that allows us to fall back on more primitive methods and exception handlers when time is running out. In this paper we proposed a run-time estimation method that is able to predict match-time and rule execution time with significantly better precision than simple profiling methods. In the average case, we c<an predict run-time per rule and per WNlE action with an error of less than a factor of 2. Although our method cannot give a rigorous upper bound for the run-time of WME actions and rules, it is well suited to systems that have soft time constraints. Such systems do not require guaranteed answering times for particular events but rather an estimation of the average time for a typical re- quest. B‘ased on these run-time estimations, exception han- dlers can be raised which are able to deliver incomplete or suboptimal results to a high level-re‘asoning system before a user-defined deadline is exceeded. 320 280 240 200 160 120 80 40 0 Rid ----s- estimated Figure 5 : Rule execution times versus estimated runtimes of rule “minus-90” in RUBIK rule firings 484 Problem Solving: Real-Time We owe thanks to Gilles Verteneul and Xavier Ursat who im- plemented the run-time prediction method for the PAME- LA-C inference engine. This enabled us to perform predict- ability measurements and gave us a deeper insight into the statistical behavior of production systems. Furthermore we thank the AI group at the Alcatel-ELIN Research Center for providing us with production systems that are designed for application in industrial environments. eferences Acharya, A., Black, B., Paul, C.J., ‘and Strosnider, J.K. 1991. Reducing Problem-Solving Variance To Improve Predict- ability. Communications of the ACM, Vol. 34: 81-93. Bahr, E., B,arachini, F., Doppelbauer, J., Griibner, H., Kaspa- ret, F., Ma&l, T., and Mistelberger, H. 1991. A Parallel Pro- duction System Architecture. Journal oj* Purallel and Dis- tributed Computing 13: 456-462. Barachini, F. and Theuretzbacher, N. 1988. The Challenge of Real-Time Process Control for Production Systems. In Pro- ceedings of AAAI-88, Vol. 2: 705-709. Barachini, F. 1991. The Evolution of PAMELA. E.rpcrt SW- tems. The Iuterrutional Journal of K~~o~lcd~~ Engineering, Vol. 8: 87-98. Brownston, L., Farrell, R. G., and Kant, E. 1986. Progrum- ming Expert systems in OPS5. Addison-Wesley. Forgy, C. L. 1982. RETE : A Fast Algorithm for the Many Pattern/Many Object Pattern Matching Problem. Artifciul Intclligeizce, Vol. 19: 17-37. Forgy, C. L. 1981. OPS5 User’s Manual, Technical Report CMU-CS-8 l- 135. Carnegie-Mellon University. Gupta, A. 1986. Parallelism in Production Systems. Ph.D. diss, Department of Computer Science, Carnegie-Mellon University. Gupta, A., Forgy, C. L., Kalp, D., Newell, A., ‘and T‘ambe M. 1986a. Results of P~arallel Implementation of OPS5 on the Encore Multiprocessor, Technical Report. Department of Computer Science, Carnegie-Mellon University. Gupta, A., Forgy, C. L., Newell, A., and Wedig, R. 1986b. Parallel Algorithms and Architectures for Rule-B‘ased Sys- tems. In The 13th Annual International Symposium on Com- puter Arclritecturcs, IEEE and ACM. Gupta, A. and Tambe, M. 1988. Suitability of Message Pass- ing Computers for Implementing Production Systems. In Proceedings of AAAI-88, Vol. 2: 687-692. Haley, P. V. 1987. Real-Time for RETE. In Proceedings of ROBEX-87, Triangle Park, Instrument Society of America. Ishida, T. 1990. Methods and Effectiveness of Parallel Rule Firing. In Proceedings of IEEE Conference on Artificial In- telligence Applications: 116-122. Kalp, D., Tambe, M., Gupta, A.,Forgy, C., Newell, A.,Acha- rya, A., Milnes, B., and Swedlow, K. 1988. Parallel OPS5 Usel*‘s Mc~nuuZ, Draft. Carnegie-Mellon University. Laffey, T. J., Cox, P. A., Schmidt, J. L., Kao, S. M., and Read, J. Y. 1988. Real-Time Knowledge-Based Systems. In AI Maguzilre, Vol9, no 1: 2745. Miranker, D. 1987. TREAT : A New and Efficient Match Al- gorithm for AI Production Systems. Ph. D. Thesis, Columbia University. Tambe, M. and Newell, A. 1988. Some Chunks are Expen- sive. In Proceedings of the Fifth International Conference on Machine Learning: 45 l-458. Tambe, M., Kalp, D., and Rosenbloom, P. 1991. Uni-Rete : Specializing the Rete Match Algorithm for the Unique-attri- bute Representation, Technical Report, CMU-CS-91-180. Carnegie-Mellon University. Wang Chih-Kan, Mok Aloysius, K., Cheng Albert, M.K. 1990. MRL : A Real-Time Rule-Based Production System. In Proceedings of Real-Time Systems Symposium: 267-276. IBarachini, Mistelberger, and Gupta 485 | 1992 | 85 |
1,282 | eal-Time Search Algorit Babak Hamidzadeh Shashi Shekhar Computer Science Dept. University of Minnesota Minneapolis, MN 55455 ABSTRACT A real-time AI problem solver performs a task or a set of tasks in two phases: planning and execution. Under real-time constraints, a real-time AI problem solver must balance the planning and the execution phases of its opera- tion to comply with deadlines. This paper pro- vides a methodology for specification and analysis of real-time AI problems and problem solvers. This methodology is demonstrated via domain analysis of the real-time path planning problem and via algorithm analysis of DYNORAII and RTA* [ 11. We provide new results on worst-case complexity of the prob- lem. We also provide experimental evaluation of DYNORAII and RTA* for deadline compli- ance. 1. Introduction and Survey A real-time AI problem solver typically needs to address response-time constraints. In lightning chess, for example, the problem solver has to search for a move in the state space, within a time limit. Any amount of time saved within a move can be used in later moves. Thus, the lightning chess problem solver has to produce responses within the deadline put on a move, or in less time than that in order to buy time for more complicated decision problems to come. Response-time constraints relate to the limitation on the total time to plan a solution and to carry out the solution. Response-time constraint problems can further be divided into two classes: deadlines and optimal response times. Deadline situations provide a certain amount of time for the system to plan a solution. The deadlines may be fixed or they may vary from case to case. Finding an optimal solution within arbitrary dead- lines is hard and often NPcomplete [Z]. Anytime algo- rithms [3,4] formalize characteristics of a class of algo- rithms which are capable of handling variable deadlines. Another class of response-time constraint problems impose optimality constraints on the total response-time of the system. The total response-time is the sum of the time spent on planning a solution and the time it takes to execute the solution. The optimal response-time is not achieved by planning for optimal solutions since it may incur large planning costs. A trade-off between planning time and solution quality may be used to optimize the total response-time [S]. Simple blind search algorithms like depth first search, breadth first search and depth first iterative deepening [6] are useful for problem solving in small search spaces and situations where tight deadlines are 486 Problem Solving: Real-Time non-existent. Most real-world applications, however, face very large search spaces and, often times, constraints on response time. Classical search algorithms, such as A* [7] and IDA* [8] which guarantee optimal solutions in terns of execution times, do not guarantee meeting any constraints on response time. Anytime algorithms characterize the requirements of decision procedures capable of meeting deadline con- straints on planning time[3]. The utility of solutions planned via these algorithms increases over time. The algorithms can be terminated at any time and will return some answer at the time of termination. The answer returned improves if more time is available for planning. Me&Greedy algorithm[9] is an anytime algorithm. It uses a sequence of evaluation functions to evaluate the promise of a node during search. A greedy approach is used to order the multiple evaluation functions. Negative local benefit from a step of planning terminates the search in that direction. The algorithm may be terminated at any time and it will produce a solution at that time. NORA[S] uses hierarchical planning to improve the solution at hand via the set of semantic information for database query planning. NORA formalizes the tracle- off between planning cost and execution cost to address constraints on the total response time. This algorithm assumes that the set of all solutions are available at plan- ning time so it can pick one among them. It has been for- mally proven that the stopping criterion of NORA pro- vides near optimal response-times. A framework to address the more general problem of resource constraints may be built around utility theory[ 10,l l]. This model calculates utility and disutility of certain meta-level actions. It then uses these values to reason about continuing to plan or proceeding with an action. The utility values and the probability distributions are learned through experience. Problem solving in dynamic worlds has been addressed by RTA*[ 1,121. The algorithm works in cycles of partial planning followed by execution. The complete plan to reach the goal is not worked out if plan- ning ties a long time. The agent executes a partial plan without exploring all the consequences this commitment. RTA* uses a variation of minmax search [ 131, called minmin look-ahead search for partial planning. Minmin search looks forward from the current state to a fixed depth horizon and applies the heuristic evaluation func- tion (f=g+h) of A* to the nodes at the depth frontier. The best f value is then sent back to the current node. Korf has proven that RTA* is a complete and correct algorithm, namely it finds a solution if one exists, and executing the solution will, indeed, achieve the desired results. Dynamic Near Optimal Response-time Algorithm (DYNORA)[14] was designed to address both response- time constraints and issues concerning dynamic From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. environments, simultaneously. As a means of character- izing response-times, DYNORA formalizes the trade-off between solution quality and planning time, which is very unique. Also, by combining partial planning with execu- tion DYNORA adds a reactive behavior to its problem solving nature. The research in real-time search algorithms has not provided adequate validation of the performance of the proposed algorithms. A part of analyzing a real-time algo- rithm must demonstrate the capability of such algorithms to handle strict time constraints. It is difficult to compare the alternative algorithms in their performance and in dif- ficulty of formulation for specific real-world applications. This paper makes several contributions to real-time prob- lem solving research in AI. This paper provides a domain analysis of the real- time path planning problem, in section 2. The analyses of the problem will reveal certain constraints on how well we can expect any real-time algorithm to perform. We introduce a new real-time planning algorithm, named DYNORAII, in section 3.1. For the proposed algorithm, we provide formal and empirical performance analyses. In section 3.2 we show that the time distribution of the number of completed jobs can be used to test the capabil- ity of an algorithm to handle strict time constraints. Our empirical results, derived from experimentation on DYNORAII and other real-time planning algorithms, show that DYNORAII outperforms RTA* in compliance with deadlines. 2. Domain Analysis: Optimal Path Planning The analysis methodology can be divided into two parts: Domain analysis and algorithm analysis. In the domain analysis, the specified problem is analyzed independently of the algorithm that is intended to solve it. In the algorithm analysis, the algorithm that is intended to solve the specified problem is analyzed. The domain analysis can consist of some analytical results on worst- case time complexity of the problem. Other analysis can consist of solution density and solution quality analysis. A solution density analysis is concerned with the number of solutions that exist in an average-case or a worst-case state space. A solution quality analysis is concerned with how good a solution, in terms of some parameter(s) of interest, one can expect from an algorithm. Both of the latter analyses, namely the solution density and solution quality analysis, can help to determine the worst-case time complexity of the specified problem. An AI problem solver can be characterized by two main components. One component is the state space in which a solution is to be found. The other component is the search algorithm that is used to find the solution[l5]. A state space is represented via a graph G(V, E). A state in G is represented by a node Vi E V. Certain pairs of states are connected to each other via edges (Vi vi) E E. The two nodes representing an edge are the states that are connected by that edge in the state space G. Associated with each edge (Vi vi) is an execution cost ce(vi,vj) which is regarded as the cost of transforming vi to vi, or the cost of traversing the edge (vi vj). Also associated with each edge, is a planning cost cp(vi,Vj) which is the amount of planning required to come to the decision to traverse the edge (Vi Vi). Associated with each graph are two special nodes; the start node s and the goal node g. The problem of planning in a graph is that of searching for a path pi that connects s and g via existing edges in the graph. A path (plan) pi is represented as an ordered set of edges {(S V/)9 (V[ Vj), ’ ’ ’ , (v, g)l. Associated with a path pi in the graph is an execution cost C, such that ce = ce(v,,v,,,) , and a planning cost C, such that (vcv&p cp = C cp(vl,v,). An optimal path refers to a plan that (vtvm)q, reaches the goal node with the smallest possible execution cost. In dynamic state spaces, like the execution costs of edges, the total execution cost of a path is a function of time. An optimal path in such spaces refers to a plan that remains optimal over a period of time. The constraints on the total response time of the planning and execution processes of real-time problem solvers can be specified as follows. Total response times are characterized by the sum of the time it takes to plan a solution and the time it takes to execute that solution. If the execution cost C, and the planning cost C, of a solu- tion path in a state space are calculated in terms of time, the total response time of a plan can be calculated as cp + cc . Strict time constraints on total response times typically pose deadlines on the amount of time available for planning and execution of a solution. In such situa- tions a planning algorithm is required to plan a path from the start node to the goal node and execute that path, namely traverse all edges in the path and end up at the goal state, before a deadline is reached. Deadline situa- tions require guarantees on total response times. To characterize real-time path planning as a hard problem, we provide a worst-case time complexity analysis of optimal real-time planning. We specify the problem of optimal real-time planning as that of finding an optimal solution within a deadline or finding and exe- cuting an optimal solution in the minimum total response time. We present a graph-theoretic definition of this problem as follows. We define an optimal path in this problem to be the path connecting s and g with the smal- lest execution cost Ce. The time, C,, spent to search for a solution path is calculated by adding up the cost of plan- ning the move from one node to another for all the nodes on the path. The cost of a move from one node to another is calculated by adding up the expansion cost of every node that was expanded during planning for such a move. The total response time for a solution path is calculated by adding up the cost of planning the path and the cost of traversing that path, namely C, + Ce. It can be shown that the problem of finding and traversing the optimal path (i.e. Min(C,)) in the minimum time possible (i.e. Min(C,, + C,)) is NP-complete. An implication of this result is that guaranteeing optimal solutions within arbi- trary deadlines is NR-complete. This implication is posed as a corollary at the end of this section. We will provide a proof by using the method of polynomial reduction [ 161. We define the optimal real-time search (ORTS) problem as follows. Assume we are given a graph G(V, E), with ]V]=n and ]E]=m. We measure the size of the problem instance by the sum of the number of nodes and the number of edges, namely m+n. Given two nodes s Wamidzadeh and Shekhar 487 and g in V, our problem is to find and traverse the shortest path connecting s and g such that the total response time for such a path is a minimum. Therefore, a solution to this problem is a set of vertices V’ in V (V’={v 1,v’2,...,v’J, v’~=s, v’,=g) such that the path con- necting s and g is the shortest path in the graph, namely: ce(v’irv’i+r) is a minimum, and the total response i=l time to search for and i execute this path is also a minimum, namely: CJ7(V'j,V'j+l) + iCC(V’i,V’i+I) is a minimum. j=l i=l Theore 1: Given an instance I of the ORTS problem and positive integers L & P, the problem of answering whether there is a path of length less than L with a total response time less than P+L is NP-complete. PROOF: The ORTS problem is in NP, since a nondeter- ministic polynomial time algorithm can solve the decision version of the ORTS (DORTS) problem. This algorithm nondeterministically guesses a solution path, connecting nodes s and g in a graph, and verifies that the length of the path is less than L and the response time is less than P+L. Next, we reduce the problem of “Shortest Weight- Constrained path” (SWCP), a known NP-complete prob- lem [ 161 9 to the ORTS problem in polynomial time. SWCP can be stated as follows: Given a graph G(V,E), length Z(e)&? (where Z+ is the set of all positive integers), weight w (e&Z’ for each e&Z, specified vertices s ,tcV, and positive integers K and W, is there a simple path in G from s to t with total weight W or less and total length K or less? A direct, polynomial transformation of and instance 1’ of SWCP to and instance I of DORTS fol- lows: Graph G in 1’ is the same as G in I, with the same set of vertices and edges. Each l(e) in I’ has a corresponding ce(vi *vi) in I, such that l=ce and e is the edge in E which connects the vertices vi and vi (vi,vjEV). Similarly, each w(e) in I’ has a cP(vi9Vi) + Ce(Vi,Vj) in I, co&esponding such that w=cp +ce and e is the edge ii E which connects the vertices vi and vj (vi,vjeV). It is clear that the transformation function can be carried out in polynomial time. From these we deduce that the optimal real-time search problem is NP-complete. We note that the ORTS and SWCP problems are not NP-complete for the special case where weights W(e) are identical or the lengths l(e) are identical. One implication of the above results is that we should not seek optimal solutions for the real-time search problem without characterizing special cases. This is reflected in the algorithms that address the problem. Other implications of these results are reflected in the fol- lowing corollaries. CorolIary 1: The problem of searching for a path of optimal length, within a deadline is NP-hard. Corollary 2: The problem of searching for a path of optimal length, while optimizing total response times is NP- hard. The proofs of these corollaries are based on the corresponding decision problem of finding and executing a path of length L within time P+L. 3. Algorithm Analysis: In this section we analyze two real-time path planners. One of these path planners uses our new real- time search algorithm, DYNORAII, that is capable of handling time constraints in dynamic environments. We prove the new algorithm to be correct and complete in static worlds. We, then, provide the data from a set of comparison experiments that test the capability of these algorithms in meeting deadlines. Analysis of the data show that DYNORAII is capable of meeting much tighter deadlines with higher degrees of reliability. Analysis of the algorithm starts with correctness and completeness analyses. An algorithm is correct if the solution that it produces does indeed solve the specified problem. An algorithm is complete if it is guaranteed to find a solution when such a solution exists. The algo- rithm analysis can also contain verifications of optimality of the solution provided by the algorithm. A real-time AI problem solver is amenable to a variety of other analyses, including deadline compliance, which refers to the problem solver’s ability to meet a given deadline. In graph-theoretic framework, deadline compliance can be analyzed for a problem defined on a fixed graph. For example, the path planner can be analyzed to check the number of (start, goal) pairs, for which a path can be discovered and traversed within a given deadline. A distribution graph, representing the number of jobs that were able to meet a given deadline, provides a representation of deadline compliance ability. 3.1. Algorithm Specification: D ORAII DYNORAII performs planning and execution cycles repreatedly until a goal node is reached, assuming that the graph has a solution. A plan-execute cycle con- sists first of conducting a heuristic search (plan phase) for the next move starting at the current state (node) in the graph. The search continues from the start state to a cer- tain depth in the graph until the following stopping cri- terion is reached: c&ace (1) This stopping criterion provides a tradeoff between plan- ning costs (C,) and execution costs (C,). This tradeoff takes into account the utility of the heuristic solution found in the current plan phase versus the amount of plan- ning that was performed to find that solution. At the exe- cute phase, the algorithm commits to the best action found during the previous plan phase. In the case of path planning for a robot, for example, the execute phase con- sists of physically moving the robot from its current posi- tion to its next position which was chosen among a set of available options. Figure 1. provides pseudo-code of the DYNORAII algorithm. C,, in DYNORAII, is determined by the number of nodes that were evaluated during the search. These are the nodes whose h,g and f values were calculated, where h is the estimated distance from the evaluated node to the goal, g is the the cost of a move from the parent of the evaluated node to the evaluated node, and f is the sum of h and g. Ce is calculated by adding the actual length of the current path to the estimated distance between the current node and the goal node. When the criterion of inequality 1 is satisfied, the smallest f value found so far is returned to the top level of 488 IProblem Solving: Real-Time the algorithm. The successor node with the smallest f value is chosen as the next physical move for the DYNORAII algorithm. This process is repreated until a solution is reached. 1 Put the start node on the queue. 2.Until the first node in the queue is the same as the goal node or the stopping criterion is satisfied: 2.1.1.f the first node in queue is the same as the goal node, 2.1.1 Announ~ success. 2.2.H the stopping criterion is satisfied, 2.2.1.Execute the best action found. 2.3.Otherwise: 2.3.1 .Remove the first node from the queue. 2.3.2.Create a list of successor nodes of the removed node. 2.3.3.Por each successor node, 2.3.3.1.Assign cost of edge between the removed node and the successor node as cost value (i.e. g) of successor node. 2.3.3.2.Assign the value returned by the heuristic function to the heuristic value (i.e. h) of the successor node. 2.3.4.Add to queue, the list of those successor nodes that are not already on the queue. 2.3.5.Sort nodes in queue with respect to their sum of cost and heuristic values (i.e. f=g+h). Pigure 1: Pseudo Code for DYNORAR An important parameter involved in the tradeoff between CP and C, is a (see inequality 1). The appropri- ate value of a depends on certain characteristics of the graph and the application at hand. Examples of such characteristics are the graph size, the branching factor and the time available for planning. The general rule of thumb is to choose a large a when the search space is small, the branching factor is small and the time to plan is long. A small oe is chosen when the search space is large, the branching factor is large and the time to plan is short. The intuitive rationale behind these heuristics is that a large graph or a high branching factor with a large a can considerably increase the amount of planning. Also, when the available time to plan is short one must obvi- ously reduce the amount of planning in each plan-execute cycle. DYNORAII guarantees termination if a solution path from start node to goal node exists in the graph. It also is able to get out of local minima and graph cycles. This is done by penalizing cyclic and dead-end paths, and by leaving the h value of the second best path at each decision point [l]. Next, we will present some formal results about the algorithm and its performance. Empiri- cal results based on performance comparison experiments will follow. Theorem 2: DYNORAII is correct and complete. Proofs of the this theorem are provided in[ 171 3.2. Deadline Compliance Evaluation A part of analyzing a real-time algorithm must demonstrate the capability of such algorithms to handle strict time constraints. In this section we present the results of experiments that were designed to compare the performance of DYNORAII and RTA* in meeting dead- lines. This experiment was conducted on a randomly gen- erated graph, G(V, E), with 30 nodes. V in the graph represents the set of nodes and E represents the edges in the graph. The nodes of the graph are represented by their euclidean coordinates within a 100x1 system. The edges of the graph are repre two nodes at each end. The size of e graph is character- ized by the number of nodes (n) in the graph. The degree of connectivity (p) of the graph of this experiment was chosen to be 4/n. This avoids extremely small solution spaces (set of possible solution paths), as well as, trivial paths to the goal. For each possible pair of start and goal nodes in the graph (a total of 870 start-goal pairs) eight sets of data were collected. four of the eight sets corresponded to RTA*(n) fo , and 4. The other four sets corresponded to D I(a) for 81 = 0.05, 0.1, 0.5, and 1. We collected data on path length and number of nodes expanded to find the path. The former is a measure of execution cost and latter is a measure of planning cost. In face of strict time constraints an algorithm needs to guarantee results within a given deadline, namely an algorithm needs to specify the minimum amount of time that it requires to guarantee the completion of all the given jobs. Alternatively, an algorithm is required to pro- vide the fraction of the jobs that can be completed within any given deadline. For our problem of planning a path in a state space graph, the average, best and worst total response times of the search between the set of all possi- ble start and goal nodes will provide the distribution of job completions over time. This distribution will allow calculation of the number of jobs that will be guaranteed to be completed within arbitrary deadlines. Figures 2, 3, 4, 5, and 6 provide the results of analyzing the data produced by searching for a path between all possible start and goal nodes in the specified graph. These figures represent the population distribution of problem instances over deadlines. The population dis- tribution represents the percentage of problem instances, which can be solved with a response time less than the given deadline. Figure 2 demonstrates the effect of parameter a on DYNORAII’s capability to meet deadlines. Figure 3 demonstrates the same capability for RTA* and different values of the look-ahead parameter n. Figures 4, 5, and 6 represent the best case, worst case and average case per- formances of the two problem solvers. The average case population distribution for a given deadline is derived by computing the average population distribution for the given deadline over possible values of performance parameter a and n. The effect of performance parameters a and n on the problem solvers can be summarized as follows. DYNORAII’s ability to meet shorter deadlines increases as the value of a increases, as shown in Figure 2. How- ever, that RTA*‘s ability to meet deadlines decreases as the depth of search increases, as shown in Figure 3. The comparative performance of the two problem solvers can be judged by examining Figures 4, 5, and 6 which show the best, worst and average case comparisons of deadline compliance. DYNORAII outperforms RTA* in all three cases. This implies that DYNORAII can guarantee a response in a significantly shorter time than RTA*. Table 1 demonstrates the times that it takes both algorithms to complete %lOO of the jobs. Table 2 demon- strates the times that it takes both algorithms to complete %90 of the jobs. The data in table 1 represent the Hamidzadeh and Shekhar 489 0 100 zoo 300 400 500 600 100 000 900 1000 deadllnc Figure 2: Effect of a on DYNORAll(a)‘s Deadline Compliance 0 100 ZOO 300 400 500 600 700 000 900 1 eon db4d11nc Figure 4: Best-case performance of DYNORAII vs. RTA” Figure 5: Worst-case Performance of DYNORAII vs. RTA’ L ’ n ” ” ” 0 100 200 300 400 500 666 100 000 900 1000 &adIlm Figure 6: Average-case Performance of DYNORAll VS. RTA” I 0 100 200 300 400 500 LOO 100 100 900 ,000 dwdllrr Figure 3: Effect of n on RTA*(n)‘s Deadline Compliance 490 Problem Solving: Real-Time deadlines within which complete response cau be expected from each algorithm. The rows of the table present best, worst and average case response times to complete %I of the jobs at hand, respectively. The first two columns of the tables list best, worst and average times for DYNORAII and RTA* algorithms. The third column shows the percentage of improvement of Table 1: Best, Worst & Average Response Times for % 100 job completions The results of the previous section demonstrate that DYNORAII outperforms RTA* in meeting deadlines, in the average, best and worst cases. Collection and analysis of all possible searches of a specific graph allows us to produce a distribution of all jobs across total response times. The best and worst case analysis of algorithm per- formance requires a complete sample of all problem instances. It is this distribution that allows the average, best and worst case analysis of algorithm performance. Ri’A* RTA’ DYNORAII -DYNORAII x 1oo RTA” Best 260 85 67.3 Worst 460 280 39.1 Average 360 210 41.6 Table 2: Best, Worst 8r Average Response Times for %90 job completions Even though table 1 provides equal values for % 100 job completions in the worst case and the average case, these values are not equal for less than %loO job completions as shown in table 2. The average perfor- mance of the algorithms are better than their worst-case performance for less than %100 job completions. This is evident in the graphs of figures 5 and 6. In these graphs the average-case results are shown to reach %lQO job completions at steeper slopes than the worst-case results. 4. Conclusion Real-time problem solvers in AI can meet several but not all deadlines. Each real-time Al problem solver and algorithm should be analyzed. Domain analysis of real-time AI problem solver can reveal the constraints on the best possible performance of any algorithm, for the given detail of problem specification. Algorithm analysis can reveal the deadline compliance ability of specific algorithms in three ways. It characterizes the percentage of problem instances that can be solved by a given dead- line. It can also discover the range of deadlines within which the algorithm guarantees a solution to a given prob- lem instance. Finally, it can indicate the expected success of a given algorithm in meeting a given deadline for dif- feren t problem instances. We have presented a specification of real-time path planning problem and the real-time problem solvers for path planning. We have shown that real-time path plan- ning is a hard problem in order to justify the heuristic approach taken by real-time AI researchers to this prob- lem. We have provided a new heuristic real-time path planning algorithm, DYNORAII. We experimentally show that the proposed algorithm outperforms traditional real-time AI algorithms in deadline compliance. We plan to extend the analysis model to larger problems such as real-tune planning and to larger applications such as robot path planning. 5. References 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. 17. R.E. Korf, RealTime Heuristic Search First Results, Proc. AAAI Conference, (1987). M. R. Garey and D. S. Johnson, Computers and Intractability, W.H.Freeman and Company, New York (1979). T. Dean and M. Boddy, An Analysis of Time Dependent Plan- ning, Proc. AAAI, pp. 49-54 (1988). T. Dean and G. Siege, An approach to reasoning about continu- ous change for applications in planning, Proc. AAAI, pp. 132- 137 (1990). S. Shekhar and S. Dutta, Minimi&g Response Times In Real Time Planning And Search, Proceedings of 11th International Joint Conference OR Artijicial Intelligence, pp. 238-242 IJCAI, (1989). R. E. Korf, Search: a survey of recent results, Exploring artifi- cial intelligence ( Ed. H. #robe), Morgan Kauffman, (1988). P. E. Hart, N. J. Nilsson, and B. Raphael, A Formal Basis For the Heuristic Determination of Minimum Cost Paths, IEEE Transactions on System Science and Cybernetics F&C-4(2) pp. loo-107 (1968). R. E. Korf, Depth-First Iterative Deepening : An Optimal Admissible Tree Search, Artificial Intelligence 27 pp. 97-109 North-Holland, (1985). S. Russell and E. H. Wefald, Decision Theoretic Control of Rea- soning: General Theory and an Algorithm to Game Playing, Report No. UCBICSD 881435, p. Computer Science Division, U.C.Berkeley (1988). E. J. Horvitz, G. F. Cooper, and D. E. Heckennan, Reflection and Action Under Scarce Resources: Theoretical Principles and Empirical Study, Proceedings of 11th International Joint Conference on Artificial Intelligence, pp. 1121-l 127 IJCAI, (1989). M. Boddy, Anytime Problem Solving Using Dynamic Program- ming, Proc. Ninth National Conference on Artificial Intelli- gence, AAAI, (1991). R.E. Korf, RealTime Heuristic Search New Results, Proc. AAAI Conference, (1988). C. E. Shannon, Prog ramming a Computer For Playing Chess, Philmophical Magazine 41 pp. 256-275 (1950). B. Hamidzadeh and S. Shekhar, DYNORA: A Real-Time Plan- ning Algorithm to Meet Response Time Constraints in Dynamic Environments, Proc. Tools for Artificial Intelligence Confer- ence, TAI, (1991). N. J. Nilsson, Principles of Artificial Intelligence, Tioga, Palo Alto, CA (1980). M. R. Garey and D. S. Johnson, Complexity Results for Mul- tiprocessor Scheduling Under Resource Constraints, SIAM Jour- nal of computing, pp. 397-411 (1975). B. Hamidzadeh and S. Shekhar, Specification and Analysis of Real-Time AI Problem Solvers, Submitted to the IEEE Transac- tions on Sojiware Engineering, 0. Hamidzadeh and Shekhar 491 | 1992 | 86 |
1,283 | James G. Schmolze Department of Computer Science Tufts University Medford, MA 02155 USA Email: schmolze@s.tufts.edu Abstract Tb speed up production systems, researchers have developed parallel algorithms that execute multiple instantiations simultaneously. Unfor- tunately, without special controls, such systems can produce results that could not have been pro- duced by any serial execution. We present and compare three different algorithms that guaran- tee a serializable result in such systems. Cur goal is to analyze the overhead that serialization incurs. All three algorithms perform synchro- nization at the level of instantiations, not rules, and are targeted for shared-memory machines. One algorithm operates synchronously while the other two operate asynchronously. Of the latter two, one synchronizes instantiations using com- piled tests that were determined from an offline analysis while the other uses a novel locking scheme that requires no such analysis. Our ex- amination of performance shows that asynch- ronous execution is clearly faster than synchro- nous execution and that the locking method is somewhat faster than the method using com- piled tests. Moreover, we predict that the syn- chronization and/or locking needed to guarantee serializability will limit speedup no matter how many processors are used. A production system (PS) is an effective vehicle for implementing a variety of computer systems. Most notable are implementations of successful expert systems such as Rl [14]. Unfortunately, PSs are slow and will require substantial speedup when This work was supported in part for the first author by the National Science Foundation under grant number IRI-8800163 and in part for the second author by the Office of Naval Research under University Research Initiative grant number N00014-86-K-0764, NSF contract CDA-8922572, and DARPA contract NOOOlA-89-J-1877. Mr. Neiman gratefully acknowl- edges the support provided by his advisor Victor R. Lesser. Thanks also to the UMass Computer Science Dept. for providing access to the Sequent Symmetry and to lbp Level, Inc. for providing lbp Level Common Lisp. 492 Problem Solving: Real-Time Daniel E. Neiman Department of Computer Science University of Massachusetts Amherst, MA 01003 USA Email: dann@s.umass.edu executing large systems under demanding time constraints [4]. To speed them up, researchers have studied par- allel implementations with much of that research focusing on OPS5 [2] or CPS-like languages. Since most CPU time in OPS5 is spent in the MATCH step (over 90% according to [l] and over 50% according to [ll]), many efforts have tried to make parallel that one step while leaving the system to continue executing only one rule at a time (e.g., [5,6,9,15,20, 27,281). To gain even more speedup, several researchers have investigated systems that execute many rule instantiations simultaneously (e.g., [7,8,11,13,16, 17, l&21,22,23,24,25, 26, 291). Such parallelism is often called rule or production level parallelism. Each match of a rule is represented by an instant& tion, where any given rule can have many instantia- tions at a given point. When two or more instantia- tions execute simultaneously, we say they coexecute. It is possible for these latter systems to produce results that could never have been produced by a se- rial PS. To deal with this, most of the above systems guarantee serializability (some exceptions are [17, 18,291). In other words, they guarantee that the fi- nal result could have been attained by some serial execution of the same instantiations that were executed in parallel. 1 Numerous algorithms have been offered to guarantee serializability, most of which are based on the seminal work in [7], which enforced serializability by prohibiting the coexecu- tion of pairs of instantiations that interfere with each other. We will soon define interference. In this paper, we present and analyze three dif- ferent algorithms that execute multiple instantia- tions simultaneously while guaranteeing serializ- able results. Our goal is to measure the overhead that serialization incurs. These algorithms are ar- guably the three most precise such algorithms in the literature. They use a very precise criteria to deter- . We v&l not address the control problem. Given that most parallel PSs are non-deterministic, there may be many possible serializable results. The control problem is concerned with making the parallel PS produce the preferred result (e.g., see [12, 181). From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. mine interference and, as a result, prohibit coexecu- tions less often, which produces greater concurren- cy. Algorithm Al operates synchronously, which means that all the instantiations in the conflict set are executed in their entirety before new instantia- tions are considered. Interference checking is per- formed using tests created during an offline analy- sis. Algorithm A2 is an asynchronous version of Al. Algorithm A3 also operates asynchronously but uses a locking mechanism to prevent interfering instantiations from coexecuting. Al appears as al- gorithm Ml-Greedy in [24]. A2 and A3 have not previously been published. Section 2 describes the offline analysis used by algorithms Al and A2, which are themselves ex- plained in Sections 3 and 4, respectively. Section 5 discusses algorithm 83. Section 6 analyzes the per- formance of all three. Section 7 draws conclusions. Much of the following is a brief summary of the work presented in [24], which builds upon the framework set out in [7]. Let a production rule be written as P: Cl9 . . . . & -+ Al, . . . . &. P is the name, each Ci is a condition element (CE) and each A; is an action. Each Cr; has a sign of + or -, denoted S&&J;), and a literal, de- noted Lit(Q). S imilarly for A;. Variables that ap- pear in positive CEs are bound. Al% other variables are free. We only consider the actions of adding to or deleting from worlG2g memory 1. An instantiation of B, written i< consists of the name P plus the working memory elements (WMEs) that match the positive CEs of I? Alternatively, we can consider ip to be the name P plus the bindings of P’s bound variables that led to ip matching. Let 2M&h(‘,y,8) be true iff 6 is a substitution list that makes x unify with JL We will freely use instantia- tions as substitutions lists. For example, if (PA (OPEN 2E 1232) (WANTS Schmoke 1232)) is an instantiation of rule PA, shown below, it is equivalent to a substitution list where <seat>=BE, <flight>=1232 and <passenger>=Schmolze. PA: (QPEN <seat> c-flight>) (WANTS <passenger> <flight>) + (REMOVE 12) (MAKE RESERVATION <passenger> <Flight> <seat>). Let #((~,a) denote the result of substituting the variables in 6 into x. Let IV(x,y,c? ‘) be true iff 6’ is an independent variable substitution. Here, we re- name the variables iny so that x andy share no vari- ables. Finally, let ch(x,y,$J ‘) be defined as w(x,Y,~~ A iWtch(x,q!$y,,b3,6). We call ma& an independent variable match. We say that one instantiations disables another iff executing one causes the other to match no long- er. This occurs if the first adds (deletes) a E that the other matches negatively (positively). We define a test for inter-instantiation disabling as follows (the proofs for all theorems appear in 1241). Theorem 1: ip disables z? iff 3 j,k,G,Q’ such that: Sg?Z(Aj’) Z Sgn(Ck ‘) A We say that one- instantiations clashes with another iff executing one would add a E that executing the other would delete. We define a test for inter-instantiation clashing as follows. Theorem 2: ip clashes with 8 iff 3 j,kJ,a’ such that: Sgn(Aj’) + Sgn(& Q) A A?Match@(Lit(Ajp),ip), $(Lit@&Q),iQ),6,671. We note that clashing is symmetric, i.e., ip clashes with iQ iff ip clashes with i@ We let I be a set of instantiations and define a di- rected graph called IDO as the instantiation dis- abling order. For each i in I, there is a node in IDO( For each distinct il and i2 in where i2 dis- ables il, there is an edge from il to i2 in KU(I). This comprises all of IDO( We say that two instantiations coexecute if the time of the execution of their right-hand sides (RHSs) overlap. We finally arrive at serializability Theorem 3: The coexecution of a set of in&anti& tions, I, using our parallel model is serializable if IDO is acyclic and no two distinct instantiations in I clash. Interfering instantiations, then, are those that cause Theorem 3 to be violated. Our algorithms thus must make sure that, among the set of instan- tiations that are coexecuting, no two clash and there is no cycle of disabling relations. Our algorithms all work at the instantiation level, not the rule level. Most other published algorithms (e.g., [7,16]) iden- tify pairs of rules whose instantiations might dis- able (or clash), and then prohibit the coexecution of all their instantiations whether they would actually disable (or clash) or not. Thus, working at the instantiation level is much more precise. In fact, in [24], we show that frequently there is little parallel- ism to be gained by working at the rule level. In order to make our algorithms fast, we perform an offline analysis along the lines set forth in the above theorems. For each pair of rules, we synthe- size a function that takes an instantiation of each rule as arguments and returns true iff the first will disable the second. We do the same for clashing. These functions are produced in Lisp, compiled and Schmolze and Neiman 493 ‘ then demon is idle & loop to 1. 2. Demon is busy. Remove an instantiation from 3. Remove M instantiations from CS and place them queue & call its index i. in array A from 1 to M. 3. Forj:= i+l to Mwhile A[/] is still marked in do 4. Mark each instantiation in A as in. . If (Au] is still marked in) and 5. Schedule each instantiation in A. (A[r] clashes with or disables Au]) 6. Wait for quiescence (demon queue empty and then mark A[/] as out. 4. If A[/] is still marked in then execute it. 5. Loop to 1. then stored in tables for fast access and execution. 3. Al: Synchronous usin sis All three algorithms begin with a similar architec- ture which comes from the second author’s disserta- tion research [19]. We will explain that architecture here, followed by the details of Al. Given N processors, we assign 1 processor to be the scheduler and the remaining N-l processors to be demons. The specific jobs of the scheduler and de- mons differ for the different algorithms, but their basic jobs are the same. The scheduler pulls new instantiations off of the conflict set (CS) and decides whether or not to schedule them. Scheduling an instantiation consists simply of putting it on a shared queue. Each demon pull instantiations off the shared queue - each instantiation goes to ex- actly one demon - and executes them if the demon decides that execution is appropriate. This basic ar- chitecture is shown in Figure 2. The differences be- tween the three algorithms are in the processing that each does to an instantiation, and how each de- cides whether to schedule and/or to execute the instantiation. Figure 3 shows the scheduler’s and demons’ algo- rithms for Al. As can be inferred, the scheduler and 494 Problem Solving: Real-Time demons take turns doing work, and each such pair of turns is called apurallel cycle. The scheduler only begins when the demons are idle, whereupon it takes M instantiations from the conflict set, places them into an array and schedules them. It limits M, the number of instantiations considered per parallel cycle, to be BN, where F is a constant factor and N is the number of processors. We apply this limit be- cause the time that each demon spends testing for disabling and clashing is proportional to the size of M. We experimented with an F of 2,4, 3 and 1000 (1000 has the same effect as F=m) and found that F=2 consistently produced the fastest execution times. All of our results in Section 6 use F=2. The demons take the instantiations off of the queue one by one, test them for disabling and clash- ing, and if appropriate, execute them. Multiple instantiations can be tested as such in parallel be- cause each demon will only mark the instantiation it is considering and no other. Moreover, the body of code that executes an instantiation has been writ- ten to allow multiple simultaneous executions. Upon examination of the demon algorithm, one can infer that, after the demons finish, the set of instantiations in A that are still marked in meet the requirements of Theorem 3. As a result of line 3, there is no i-cj where both A[i] and Afj] are in and where either A[i] clashes with Au] or A[i] disables A2 Scheduler Algorithm 3. Mark /as in. 1. If there are instantiations in the CS then go to 2 4. Add /to E, a list of executing instantiations. else if the demons are quiescent Access to Eis critical code. Writers have (i.e., queue empty and all demons idle) unique access but there can be many readers. then exit else loop to I. 5. For J := each element in E 2. Remove a non-dead instantiation from CS and while (/ is in) and (/ is not dead) do schedule it. If (Jis in) and (Jis not dead) and 3. Loop to 1. (/ clashes with or disables J) then mark /as out. A2 Demon Algorithm 6. If (1 is in) and (1 is not de&) 1. If demon queue is empty then execute I & remove it from E then demon is idle & loop to 1. else remove /from Eand 2. Demon is busy. Remove an instantiation from return it to CS if it is not dead. queue & call it I. 7. Loop to 1. Figure 4: A2: Asynchronous algorit A3 Scheduler Algorithm A3 Demon Algorithm 1. If there are instantiations in the CS then go to 2 1. If demon queue is empty else if the demons are quiescent then demon is idle & loop to 1. (i.e., queue empty and all demons idle) 2. Demon is busy. Remove an instantiation from then exit else loop to 1. queue & call it /. 2. Remove a non-dead instantiation from CS. Call it 1. 3. Execute 1. 3. Try to acquire locks for 1. 4. Loop to 1. 4. If successful then schedule I else if I is not dead then return I to CS. 5. Loop to 1. Figure 5: A3: Async m using locks. Av]. Thus, no two in instantiations clash (remem- ber, clashing is symmetric) and there is no cycle of in disabling relations (since we have prevented any forward links of A[i] disabling Ali]). synchronous using ysis Al is synchronous, and as such, wastes a consider- able amount of time. Given that different instantia- tions take different amounts of time to execute, some demons sit idle while waiting for other demons to finish. An asynchronous algorithm eliminates this wasted waiting time (as was argued in 117, IS]), and so we designed A2. Figure 4 shows A2, an asynchronous version of Al. Here, the scheduler simply takes instantiations from the CS and schedules them, thereby perform- ing very little work. The scheduler also checks for an empty CS and quiescence, which signals no fur- ther executions. This is similar to Al, however, the scheduler does no waiting. The demons also behave similarly to the demons in Al. However, we must carefully define the execution time of an instantiation. An instantiation is said to be executing from the time that a demon removes it from the queue to the time that the de- mon either discards it or finishes executing its R A list E of the instantiations currently executing is maintained where E is a critical resource. Writers to E have unique access but multiple readers can have simultaneous access. In addition, and due to the asynchrony of the system, it is possible for an instantiation to become disabled while a demon is testing it in line 5. In that case, the system marks the instantiation as dead and no further processing is performed on it. For reasons similar to those for Al, A2 obeys Theorem 3 and yields a serializable result. 5. =Y Figure 5 shows A3, which is considerably different from Al and A2. Here, we try to acquire locks instead of checking for disabling/clashing; we will soon explain how this works. Moreover, since this occurs in the scheduler, lock acquisition is a serial process, which eliminates the potential for dead- lock. By the time an instantiation is scheduled, the system has already determined that it should execute, so the demons perform no decision-mak- ing: they simply take instantiations off the queue and execute them. Schmolze and Neiman 495 The locking scheme would be simple but for the use of negative CEs. While it is easy to lock a WME that is already in the WM, it is not so easy to lock the “non-existence” of a WME, as implied by a negative CE. However, we have designed an efficient way to use the Rete net [3] to identify precisely the set of WMEs that would match the negative CE. Sellis et al [23] also use locks for serializing but for negative CEs, they lock an entire class of WMEs. In the Bete net, when a WME is positively matched, a token representing that element is con- catenated to a set of tokens being propagated through the network. We can similarly create a pseudo-token corresponding to a successful match of a negated element. This token represents a pat- tern of the working memory elements that would disable this instantiation. This pattern is simply the set of tests encountered by the working memory ele- ment as it proceeds through the matching process; specifically, the inter-element uZpha tests preced- ing the NOT node, concatenated to the tests per- formed by the NOT node and unified with the posi- tively matched tokens in the instantiation. For example, if we had a rule such as the one shown below, the pseudo-token would have the form ((class = B) (element(l)=wombat) (ele- ment(2) =koala)). Thus, any currently executing instantiation that creates an element matching this pattern would disable an instantiation of PM stimu- lated by the working memory element (A wombat). (P PK (A <x>) WM = { (A wombat) ) - (B CX> koala) ---, (B CX> koala)) When a rule instantiation is created, we thus have two sets of tokens: the WMEs matching the left-hand side (LHS) and negative pattern tokens. ‘lb use the latter, we must also do the following. Be- fore each instantiation is scheduled, we develop a list of all the WMEs that it will add when it is executed. This is reasonable as the formation of ele- ments is usually inexpensive. Immediately before the instantiation is executed, we post all the WMEs it is about to add onto a global ADD list. We now ex- plain the operation of lock acquisition in detail. 1. Each WME has a read counter and write flag. Each instantiation has a read and write list. As each instantiation, 1, enters the CS, we add to its write list each WME matched on its LHS that would be modified or removed by I. The remain- ing WMEs matched on Ps EHS are placed on its read list. Next, we see if any of the WMEs on the read or write list have their write flag set. If so, we discard I because it will soon be disabled by another instantiation that is already executing. 496 Problem Solving: Real-Time 2. 3. If a WME on the write list has its read counter > 0, we do not execute I and instead, place it back on the CS. In this way, we do not disable another instantiation that is already executing while giv- ing I another chance later. If I has not been dis- carded or put back on the CS, we proceed. We compare r’s negated pattern tokens against the list of WMEs on the ADD list. If any match, then I is discarded as it will soon be disabled by an instantiation already executing. Otherwise, we proceed. We now acquire the locks, which amounts to in- crementing the read counters for the WMEs on the read list and setting the write flags for the WMEs on the write list. We also post the WMEs to be added to the ADD list. The demon also has some extra tasks. After it fi- nishes executing an instantiation I, it removes the elements that I added to the ADD list and decre- ments the read counters for those WMEs on ps read list. We note that accessing and modifying the ADD list, read counters and write flags must be per- formed in critical code. A3 does not check for clashing. While space does not permit our discussing it here, it turns out that the implementation of WM as a multiset in OPS5 makes testing for clashing unnecessary (e.g., we could go back to Al and A2 and safely remove the clashing tests). In order to determine the cost of serialization, we have implemented the three algorithms and run them against a benchmark PS that we call Toru- Waltz-N. Toru-Waltz-N began with Toru Ishida’s implementation of Dave Waltz’s constraint propaga- tion algorithm to identify objects from line drawings [30]. It was modified by the second author to increase the available rule concurrency by combining the initialization and processing stages and to allow rules to be asynchronously triggered.2 The time for serial execution is 12.79 seconds. In our parallel system, if we turn off the checks for ser- ializability, the best time we obtain is 1.2 seconds with 15 processors. Thus, 10.7 is the maximum pos- sible speedup for this benchmark and for our soft- ware without serialization. Any further reductions in speedup are due to the serialization component of our algorithms. Figure 6 shows the speedups attained by the three algorithms. Clearly A3 performed the fastest, . The text of the Toru-Waltz-N benchmark plus a dis- cussion of its implementation and performance can be found in [19]. Al: Synchronous algorithm using disables/clashes tests A2: Asynchronous algorithm using disables/clashes tests A3: Asynchronous algorithm using locks 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Number of Rule Demons Number of Rule Demons Figwe 7: Average Times Used attaining a maximum speedup of 5.70 (runtime of 2.24 seconds), followed by A2 with a maximum speedup of 4.64 (runtime of 2.75 seconds), and fol- lowed, finally, by Al, with a maximum speedup of 2.80 (runtime of 4.57 seconds). However, when A3 was run, additional mechanisms were used: match and action parallelism. Space does not allow us to describe those algorithms here, but we estimate that they reduce the run time by about 0.5 seconds. Subtracting 0.5 from A2’s best time of 2.75 seconds yields 2.25 seconds, or a speedup of 5.68. The run times of A2 and A3 are thus very similar. It is clear that the speedup for each algorithm ta- pers off at around 10 to 12 processors, indicating that these maximum speedups are close to the abso- lute maximums for these algorithms and bench- mark. The speedups realized fall quite short of 10.7, which was achieved without serialization. Serial- ization thus appears to cut the potential speedup roughly in half for this benchmark. The reason for Al being slowest is simple. Al is performing nearly the same work as A2, but has the disadvantage of being synchronous. Given that dif- ferent instantiations take different amounts of time to execute, this amounts to a waste of processor time as demons sit idle while waiting for other demons to finish. An asynchronous algorithm eliminates this wasted waiting time (as was argued in [17]). Conceptually, A2 and A3 perform the same type of interference checking, although they use very dif- ferent mechanisms to do so. It is interesting to see that they offer similar potential for speedup. If we take a brief look at these mechanisms, we see that A2 requires Q(M) time to check interference for each instantiation, where M is the number of instantia- tions currently coexecuting: each instantiation must be checked against all those currently coexe- cuting. It turns out that A3, when checking nega- tive CEs, also requires Q(M) time per instantiation since the size of ADD depends on M. However, when A3 checks positive CEs, the time required is not de- pendent on the size of M and, instead, is constant per rule, which makes this type of check very fast.3 To discover some of the limitations of these algo- rithms, we broke down the execution times of A2 and A3 further. Figure 7 shows a bar chart of the total run times for A2 along with the average time spent by the demons doing their two main tasks: testing for interference and executing instantia- tions. It is clear that the time spent testing in- creases with the number of demons. This makes sense because the average number of coexecuting 3. In [171, the second author argues that this is a good reason for preventing interference only for positive CEs and not for negative CEs, even though this falls short of guaranteeing serializability. Schmolze and Neiman 497 instantiations increases with the number of de- mons, so there is more testing to be done. The time spent executing rules decreases since there are more demons, and so each one executes fewer instantiations. Therefore, A2 will always be slower than a system that does not guarantee serializabil- ity because of this testing time. In A3, the interference checking is done via a locking mechanism. However, this mechanism must run serially in order to avoid deadlocks be- tween instantiations simultaneously attempting to acquire locks. All locking is thus performed in the scheduler. The most time consuming portion of the locking mechanism is the portion that deals with ne- gated tokens. If the cost of checking negated tokens against the ADD list is expensive as compared to the time needed to execute an instantiation, then the benefits of asynchronous execution are lost. In order to form an estimate of the overhead associated with negated tokens, we note that the processing per- formed when matching each working memory ele- ment being asserted against each negated pseudo- token pattern is essentially equivalent to the time of a beta node activation within the Rete net (for the check against the ADD list) and two memory node activations (one for each addition or deletion to the ADD list). This approximation is reasonable as the tests contained within the negated pseudo-tokens are derived from the NOT nodes which generated them. The beta nodes are the most time-consuming component of the pattern matching process and the number of beta nodes executed can be used to create an estimate of relative costs. Using the statistics gathered by Gupta [6], we note that the average instantiation activates approximately 40 beta node and memory operations (of course, the actual fig- ures depend on the size and complexity of the CEs). Thus the runtime detection of interactions due to negated tokens may incur costs of as much as 10% of the cost of actually executing the rule for each ne- gtied condition in the rule. Because the detection of interference must be carried out within a critical region of the scheduler, an overhead of this magni- tude would limit the potential parallelism within the system to a factor of 10 (assuming one negative CE per rule on average, which agrees roughly with the measurements in [6]), exclusive of other sched- uling costs.4 7. Conclusions We conclude that one pays a fairly high price for en- suring serializability While the design and imple- 4. We can model a system of this type as an M/M/x queue [lo]. 498 Problem Solving: Real-Time mentation of these algorithms could certainly be op- timized further, each incurs an unavoidable overhead. For A3, this overhead appears to be at least 10%. For A2, we do not have a firm estimate for the minimum overhead, but it is clear that the overhead increases with the number of processors, suggesting a firm limitation to speedup. For Al, we have shown that its performance will always lag be- hind that of A2. Overall, a speedup of 10 appears to be an absolute limit for A3, and probably applies to A2 and Al as well. In addition, we find that our ser- ializable algorithms obtain roughly half the speed- up obtained by a similar parallel system that does not guarantee serializability. One could potentially improve throughput by modifying our algorithms. For example, in A3 we could perform a compilation-time analysis on the rule set and divide the rules such that several lock acquisition processes could be used. Because our results depend on analyzing the ratio between lock acquisition times and rule execution times, mecha- nisms such as those described here may be more suitable for environments such as blackboard sys- tems in which the units of execution are of a higher granularity. Another possibility for decreasing the time required to acquire locks is to apply micrc+lev- el parallelism to the checking process such that new candidate instantiations are compared against executing instantiations in parallel, along the lines suggested in [9]. While we have concentrated on the detection of rule interactions in this paper, the overhead analy- sis is appropriate for any overhead such as control scheduling or heuristic pruning that has to occur within a critical region. We thus feel that this type of research is essential to our understanding of the applicability of parallelism to artificial intelligence research in general. References 111 l21 131 141 C. L. Forgy. On the Efficient Implementation of Pro- duction Systems. PhD thesis, Department of Com- puter Science, Carnegie Mellon University, Pitts- burg, PA, 1979. C. L. Forgy. OPS5 User’s Manual. Technical Report CMU-CS-81-135, Department of Computer Sci- ence, Carnegie Mellon University, 1981. C. L. Forgy. Fete: AFast Algorithm for the Many Pat- tern/Many Object Pattern Match Problem. Artificial Intelligence, September 1982. Charles Forgy, Anoop Gupta, Allen Newell, and Rob- ert Wedig. Initial Assessment of Architectures for Production Systems. In Proceedings of the Fourth National Conference on Artificial Intelligence (AAAI-&#), Austin, Texas, August 1984. c51 El E71 181 PI rm Em ml Cl31 El41 I351 I331 1171 II181 [191 Anoop Gupta. Implementing OPS5 Production Sys- tems on DADO. Technical Report CMU-CS-84-115, Department of Computer Science, Carnegie Mellon University, December 1983. Anoop Gupta. Parallelism in Production Systems. Morgan Kaufmann Publishers, Inc., Los Altos, CA, 1987. T. Ishida and S. J. Stolfo. ‘Ibwards the Parallel Execu- tion of Rules in Production System Programs. In Pro- ceedings of the International Conference on Parallel Processing, 1985. ‘Ibru Ishida. Parallel Firing of Production System Programs. IEEE lkmsactions on Knowledge and Data Engineering, 3( l):ll-17, 1991. Michael A. Kelly and Rudolph E. Seviora. AMultipro- cessor Architecture for Production System Matching. InProceedingsoftheSixthNational ConferenceonAr- tificial Intelligence (AAAI-87), Seattle, Washington, July 1987. Kleinrock and Leonard, Queueing Systems, Volume I: Theory, John Wiley and Sons, 1975. Chin-Ming Kuo, Daniel P. Miranker and James C. Browne. On the Performance of the CREL System. Journal of Parallel and Distributed Computing, 13(4):424-441, 1991. Steve Kuo, Dan Moldovan, and Seungho Cha. Con- trol in Production Systems with Multiple Rule Fir- ings. ‘lbchnical Report PKPL 90-10, Department of Electrical Engineering, University of Southern Cali- fornia, Los Angeles, CA, August 1990. Steve Kuo and Dan Moldovan, Implementation of Multiple Rule Firing Production Systems on Hyper- cube. In Proceedings of the Ninth National Confer- ence on Artificial Intelligence (k&U-91), pages 304-309, Anaheim, CA, July 1991. J. McDermott. Rl: A Rule-based Configurer of Com- puter Systems. Artificial Intelligence, 19(l), 1982. Daniel P. Miranker. TREAT A New and Eficient- Match Algorithm for AI Production Systems. Morgan Kaufmann Publishers, Inc., San Mateo, CA, 1990. Dan I. Moldovan. RUBIC: AMultiprocessor for Rule Based Systems. IEEE !Ikansactions on Systems, Man, and Cybernetics, 19(4):699-706, July/August 1989. Daniel Neiman. Control in Parallel Production Sys- tems: A Research Prospectus. Technical Report COINS TR 91-2, Computer and Information Sciences Department, University of Massachusetts, Amherst, MA, 1991. Daniel Neiman. Control Issues in Parallel Rule-Fir- ing Production Systems. In Proceedings of the Ninth National Conference on Artificial Intelligence (AAAI-91), pages 310-316, Anaheim, CA, July 1991. Daniel Neiman. UMass Parallel OPS5 Version 2.0: User’s Manual and Technical Report. Technical Re- c201 I311 I221 [=I II241 l.251 I261 IPI m31 [291 1301 port COINS TR 92-28, Computer and Information Sciences Department, University of Massachusetts, Amherst, MA, 1992. K. Oflazer. Partitioning in Parallel Processing of Pro- duction Systems. PhD thesis, Department of Com- puter Science, Carnegie Mellon University, 1987. (Also appears as ‘I&h. Rep. CMU-CS-87-114, March 1987.). A. 0. Oshisanwo and P. P. Dasiewicz. A Parallel Mod- el and Architecture for Production Systems. In Pro- ceedings of the 1987 International Conference on Par- allel Processing, pages 147-153, University Park, PA, August 1987. Alexander J. Pasik. A Methodology for Programming Production Systems and its Implications on Parallel- ism. PhD thesis, Columbia University, New York, 1989. Louiqa Raschid, Timos Sellis, and Chih-@hen Lin. Exploiting concurrency in a DBMS Implementation for Production Systems. Technical Report CS- TR-2179, Department of Computer Science, Univer- sity of Maryland, College Park, MD, January 1989. James G. Schmolze. Guaranteeing Serializable Re- sults in Synchronous Parallel Production Systems. Journal of Parallel and Distributed Computing, 13(4):348-365, 1991. James G. Schmolze and Suraj Goel. A Parallel Asynchronous Distributed Production System. In Proceedings of the Eighth National Conference on Ar- tifkial Intelligence (AAAI-90), Boston, MA, July 1990. Times Sellis, Chih-Chen Lin, and Louiqa Raschid. Implementing Large Production Systems in a DBMS Environment: Concepts and Algorithms. In Proceed- ings of the ACM-SIGMOD International Conference on the Management ofData, pages 404-412, Chicago, IL, 1988. S. J. Stolfo. Five Parallel Algorithms for Production System Execution on the DAD0 Machine. In Proceed- ings of the Fourth National Conference on Artificial Intelligence @AAI-84), 1984. Salvatore J. Stolfo and Daniel P. Miranker. The DAD0 Production System Machine. Journal of Par- allel and Distributed Computing, 3:269-296, 1986. Salvatore J. Stolfo, Ouri Wolfson, Philip K. Chan, Ha- sanat M. Dewan, Leland Woodbury, Jason S. Glazier, and David A. Ghsie. PARULEL: Parallel Rule Proces- sing Using Metarules for Redaction. Journal of Par- allel andDistributed Computing, 13(4):366-382, Dee 1991. D. L. Waltz. Understanding Line Drawings of Scenes with Shadows. In P. Winston, editor, The Psychology of Computer Vision, pages 19-91. McGraw Hill, New York, NY., 1975. Schmolze and Neiman 499 | 1992 | 87 |
1,284 | Real-time Metareasonin with Dynamic U. M. Schwuttke Jet Propulsion Laboratory California Institute of Technology MS T1704 4800 Oak Grove Drive Pasadena, CA 91109 urns@ nereid.jpl.nasa.gov Abstract This paper describes dynamic trade-off evaluation (DTE), a new technique that has been developed to improve the per- formance of real-time problem solving systems. The DTE technique is most suitable for automation environments in which the requirement for meeting time constraints is of equal importance to that of providing optimally intelligent solutions. In such environments, the demands of high input data vol- umes and short response times can rapidly overwhelm tradi- tional AI systems. DTE is based on the recognition that in time-constrained environments, compromises to optimal problem solving (in favor of timeliness) must often be made in the form of trade-offs. Towards this end, DTE combines knowledge-based techniques with decision theory to 1) dy- namically modify system behavior and 2) adapt the decision criteria that determine how such modifications are made. The performance of DTE has been evaluated in the context of sev- eral types of real-time trade-offs in spacecraft monitoring problems. One such application has demonstrated that DTE can be used to dynamically vary the data that is monitored, making it possible to detect and correctly analyze all anoma- lous data by examining only a subset of the total input data. In carefully structured experimental evaluations that use real spacecraft data and real decision making, DTE provides the ability to handle a three-fold increase in input data (in real- time) without loss of performance. Introduction Most AI systems have addressed self-contained applica- tions in which relatively unlimited time was available for producing solutions. Many real problems (such as moni- toring) have high and dynamic data rates; in such applica- tions the processing capability of AI systems may easily be exceeded by the processing requirements of the problem. In situations where these requirements change dynamical- ly, AI systems must be able to rationally adjust their decision-making parameters to track changing problem requirements. To do this, new methods are being sought to provide accurate responses in the presence of time con- straints and conflicting objectives. Many such methods recognize the need to make implicit trade-offs and com- The research described in this paper was carried out by the Jet Propulsion Laboratory, California Institute of Technology, under contract with the National Aeronatutics and Space Administration. ~00 Problem Solving: Real-Time L. Gasser Computational Organization Design Lab Institute for Safety & Systems Management University of Southern California Los Angeles, CA 90089-0021 gasser@ use .edu promises that favor timeliness over optimality. I-Iowever, in some ways, these approaches are still not ideally suited for complex real-time environments. For example, some approaches require a metareasoning step before each ac- tion in the domain-level reasoning process [Russell 19893, where it may be more optimal to selectively invoke metar- easoning, particularly when the metareasoning is not time-constrained. Other approaches such as those that use incremental (or “anytime”) algorithms [Dean 1990; Hor- vitz 19891 analyze the expected value of a computation prior to performing it. In severely time-constrained situa- tions, it may be better to vary the solution strategy accord- ing to the dynamics of the environment than to rationally terminate or continue a single fixed strategy. Thus, addi- tional methods are needed for complex, highly dynamic applications. While no techniques will handle all situations without overload, newer methods can make it possible to obtain increased performance from limited resources in critical moments. Toward this end, we introduce Dynamic Trade-off Eval- uation (DTE), a new approach to real-time metareasoning that combines decision theory and knowledge-based tech- niques to automatically determine both when trade-offs become necessary and how to implement them with mini- mal impact on solution quality. DTE offers a general methodology for explicitly making a variety of trade-offs. It provides the ability to perform metareasoning only when necessary by dynamically modifying the solution strategy based on both the dynamics of the environment and the changing goals of the monitored system. We have evalu- ated the performance of DTE in real spacecraft-monitoring problems with real data. In carefully structured experi- mental evaluations the DTE technique provides the ability to handle a three-fold increase in input data (in real-time) without performance loss. DTE is applicable to a wide va- riety of run-time trade-offs and can be integrated into a real-time monitoring architecture. The applicability of decision theory and the psychology of judgement to metareasoning was recognized early, with research on heuristic methods for controlling inference [Si- mon 19551. Mowever, initial enthusiasm for using decision From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. theory as an AI technique dwindled in favor of other ap- proaches that more easily expressed the rich structure of human knowledge [Horvitz 19881. Recently, there has been renewed interest in decision theory for real-time AI applications. A variety of techniques exist in multi-attribute utility theory for evaluating competing objectives. Wowever, only three variants of these have been commonly applied to real-world situations [von Winterfeldt 19861: the simple, multi-attribute rating technique Edwards 19771, differ- ence value measurement [Dyer 19791, and subjectively expected utility (SEU) measurement [Keeney 19761. Of these three techniques, the Edwards technique is the sim- plest computationally, because it uses additive (rather than multiplicative) utility and aggregation models, it relies on direct rating and ratio estimation (rather than probability methods) for determining utilities and weighting factors, and it involves only the calculation of a simple dot-product for each alternative under evaluation. Moreover, for many practical applications, the results of the simpler technique are theoretically and behaviorally comparable with the oth- er methods [von Winterfeldt 19861. Utility analysis methods studied in multi-attribute utility theory have generally been applied to one-time decision making in situations such as selecting real estate sites lEd- wards 19821 or evaluating coastal development proposals [Gardiner 19741. The implicit assumption under these methods is that the criteria and objectives which formed the basis of the evaluation process will remain valid after a decision has been made; once selected, a real estate site or a coastal development proposal should remain appropriate for a suitably long period. In this type of decision, it is ap- propriate that the decision criteria, weighting factors, and final evaluation be static. However, a single decision under static criteria will not appropriately reflect changing cir- cumstances in the environment of a continuous real-time problem solving system, where trade-offs must be made dynamically and continually. In contrast, DTE enables dynamic evaluation of real- time trade-offs and maintains the advantages of simplicity, robustness, and flexibility associated with static methods. In DTE, utility analysis is used to rank alternatives in a preference space. Domain knowledge provides decision rules that are used at run time to I) dynamically reweight decision criteria and 2) dynamically select among altema- tives in a preference space (based on situational attributes and operational modes). Here we describe the DTE pro- cedure in general. In the next section, we illustrate the specifics of DTE by showing how we have applied it in a case of trade-off analysis in spacecraft monitoring. The DTE procedure consists of six steps, some of which are dynamic parallels of steps in a static utility analysis proce- dure [Edwards 19771. The first three of these steps and part of the fourth must be completed during the design phase of the system. The other steps are automated, rcal- time control activities. The DTE procedure includes: 1. Definition of the trade-off instantiation mechanism. This step involves specifying when DTE is required and designing the mechanism that invokes the trade-off evalu- ation when appropriate. 2. Definition of application-specific alternatives and cri- teria that determine their values. The alternative actions to be considered in trade-off evaluation are specified, along with criteria that will be used to evaluate the alternatives. As part of this process, the system designers and domain experts also specify domain knowledge that defines the various ways of implementing each alternative. 3. Separate evaluation of each alternative. This is done in conjunction with the previous step, and involves reliance on subjective judgements in cases where no basis for ob- jective evaluation exists. Each alternative is ranked with respect to each of the evaluation criteria, i.e. on a scale of 0 to 100, and suitable consistency checks are applied to the evaluation. 4. Definition of weights and modes. Relative weights are assigned to each of the criteria, along with ranges within which the weights can vary. Domain knowledge is spec- ified to determine the circumstances under which the weights will be varied. In addition, multiple modes may be specified, where each mode is governed by a different set of weights. At run-time, both the variation of the weights and the choice of a mode are automatically determined, as needed. 5. Aggregation. The weights from the previous step are used to determine the aggregate value of each of the alter- natives, using an additive aggregation model. 6. Selection. The alternative with the maximum utility is selected and implemented. When the evaluation indicates that two or more alternatives are equally good, domain knowledge is used to select one alternative over the others, or, if the alternatives are not mutually exclusive, to perhaps select several of them. For a specific illustration of how to apply the DTE pro- cedure, we address a representativeness vs. timeliness trade-off that occurs in managing data for the NASA Gali- leo mission’s Solid State Imaging subsystem. We have also studied a second trade-off of problem solving strategy: focus (on a specific problem solving task) versus respon- siveness (to other unforeseen but possibly more important tasks) in Voyager mission system-level analysis problems. The details of this second trade-off are addressed else- where [Schwuttke 19911. The Solid State Imaging (SSI) subsystem on newer mis- sions has a much faster image frame rate than the technol- ogy used on previously. Readout rates can be as fast as one image every two seconds (compared to one every 96 sec- onds from Voyager). Forty-eight channels of camera status data are associated with each image. This includes dynamic data pertaining to exposure time, filter position, gain state, readout mode, and data compression mode, etc. There are also non-dynamic data channels that indicate general instrument status, voltages and currents. While non-dynamic channels could be managed with an exten- sion of existing data management techniques [Washington 19891, the dynamic data does not follow trends and re- Schwuttke and Gasser 501 quires a new approach. This is because the “correctness” of a data value is independent of the correctness of previ- ous values: a value that was correct at one moment can, without changing, become incorrect at the next moment, depending on subsystem goals. For example, exposure times vary with spacecraft goals. When goals change, new exposure times may be required; if data related to these parameters does not change, the goals will not be achieved. As a result, intelligent management of more complex data requires the application of knowledge-based techniques that reflect the dynamic goals of the monitored system. The large amount of data, the occasional dependence on heuristics, and the complexity of tasks make this an ideal problem for demonstrating the benefits of DTE. The basic real-time mission operations task involves comparison of telemetry to predicted data values or accept- ed limit ranges. The predictions reflect expected perfor- mance based on known command sequences and the limit ranges reflect the general operating parameters of the instrument. The task involves two AI components: intelli- gent data management and anomaly analysis, as shown in Figure 1; the latter capability has been addressed in the MARVEL system [Schwuttke 1991b] and will not be ad- dressed here. The (competing) data management goals in this application include adjusting input data volumes to meet processing capabilities, maximizing the content of the input information, maintaining alertness to unusual events in the input data, and focusing on particularly rele- vant tasks. The first step of DTE involves defining an instantiation mechanism. For this application, a software module that analyzes the size of the input backlog invokes trade-off evaluation. In the second step, the four possible data management alternatives (provided by an imaging subsystem specialist) include: 1.1) eliminating channels not in a basic monitor- ing set, 1.2) eliminating channels not in a heuristically defined minimal monitoring set, 2.1) reducing sampling rate on heuristically defined subset of channels, and 2.2) reducing sampling rate on the entire channel set. The four alternatives are evaluated on criteria that define represen- tativeness, or information content. For data reduction, these include: (A) non-dynamic behavior, (B) irrelevance to an existing problem area, and (C) non-negative impact on monitoring integrity. A data channel must be non- dynamic to be eliminated; frequent value changes indicate a high level of activity that must be monitored to maintain representativeness. Irrelevance to existing problem areas is also important in deciding which channels to remove from the monitored set. Finally, only channels that do not compromise situational monitoring integrity can be elimi- nated without impacting representativeness. The second step also requires the specification of rules that show how to implement the alternatives. The channel elimination alternatives and the second sampling rate al- ternative are influenced most heavily by a decision tree that defines which channel subsets may be deleted from the monitored set and when they may be deleted. In con- 502 Problem Solving: Real-Time 1 MONITORING I DYNAMIC TRADEOFF EVALUATION 1 t t MOiUlTORlNG ANAiYSlS OUTPUTS Figure 1. A DTE architecture for intelligent data manage- ment in a monitoring system. trast, the heuristically-defined sampling rate alternative is entirely governed by the situation in which it is applied. In a normal operating mode, the sampling rate can be re- duced on all channels that are not part of the critical subset. In an anomaly detection mode, sampling can only be re- duced on channels that are irrelevant to anomaly detection. However, in the event of extreme backlogs, sampling on all channels may be reduced. In such situations it is im- portant to note that if the minimal subset is not preserved, some loss of representativeness may result; domain knowl- edge must be used to make timeliness vs. representative- ness trade-off in these cases. Occasionally channels must be added irrespective of timeliness. This is because in anomaly detection mode, increased representativeness takes instant precedence, and channels pertinent to that anomaly must be added. When the system returns to a normal operating mode, the channels relevant to a previ- ously resolved anomaly may be candidates for removal from the monitoring set if timeliness must be improved. The third step calls for subjectively ranking each alter- native in the context of each criterion at design time, as shown in Figure 2. The ranking, obtained with the help of the subsystem expert, is on a scale of 0 to 100, with 100 having the maximum value, then checked for consistency. This step also involves assigning relative weights to the criteria. Initial weights and variance ranges for these weights are defined for adjusting the weights during the ALTERNATIVE NUMBER Figure 2. Alternative values for the SSI example. reasoning process. Weight variations are initiated when the system detects that its performance is degrading, and are implemented using rules that provide updates based on situational parameters. Two sets of weights are defined for this application, as shown in Figure 3. The first set applies in the normal op- erating mode and the second applies in an anomaly detec- tion mode. In the normal operating mode, the irrelevance of a channel to an existing problem area is given no weight, (no problems exist in this mode). However, in anomaly analysis mode, this attribute receives the most weight. In the fourth step, the single-attribute rankings and weights are aggregated into an overall evaluation of alter- natives which, with the application-specific domain knowledge, enables the selection of the best alternative for the given circumstances. This step differs significantly from the comparable static step for two reasons. First, cir- cumstances dictate varying weights, which in turn dictate varying aggregations. Secondly, circumstances may re- quire varying the knowledge that is applied from situation to situation. Examples of the varying aggregations that are obtained for both operating modes are shown in the tables of Figure 4. These tables show that the data management actions that are most compatible with maintaining maxi- mum representativeness are determined by external circumstances. The rankings of the alternatives with re- gard to representativeness is summarized in Figure 5, with the value of 1 being the highest ranking. The final step involves the selection of an alternative and is based on dynamic evaluation of the representativeness vs. timeliness trade-off. In order to make this trade-off, the four alternatives must also be evaluated with regard to timeliness. The timeliness impact of an alternative is di- rectly proportional to the percentage reduction (or increase) in the number of monitored channels that results from im- plementing that alternative. However, this percentage must be calculated immediately prior to making the trade- off, based on the channels in the current monitoring set, because the number of monitored channels is a dynamic quantity determined by the events leading up to the current circumstances. The following example shows the dynamic and adaptive nature of this evaluation. Assume that the monitoring system has just been activated. Initially, 49 data channels are in the monitored set. After some time, the system detects a growing input backlog, and responds by deciding that some channels must be removed from the monitored set. No anomalies N.O.M. A- NON-DYNAMIC BEHAVIOR - (.45+/- 0.2) (.15 +/-o.l) B- IRRELEVANCE TO AN N.O.M. (0.0) EXISTING PROBLEM AREA A.D.M. (.60) C- NON-NEGATIVE IMPACT N.O.M. (.15 +/- 0.2) ON MONITORING INTEGRITY A.D.M. (-25 +I- 0.1) (NOM- Normal Operation Mode I ADM- Anomaly Detection Mode) Figure 3. Criteria and weights for the SSI example. have been detected as yet, and no modifications to the starting weights have been suggested by the knowledge base. As a result, the system uses the aggregate values in the first line of Figure 3 as representativeness values for the four alternatives. Corresponding timeliness values are ob- tained by calculating the net percentage reduction in input data that would be achieved with each alternative. Actual timeliness values are plotted against the aggregate repre- sentativeness value as shown in Figure 6 (left). Both representativeness and timeliness arc rated on a scale of O- 100; 1 unit on the representativeness scale is equivalent to 1 unit on the timeliness scale. The indifference curves shown in the figure are created by this constant trade-off of units; alternatives lying on the same indifference curve have equivalent value, and alternatives lying nearest to the upper right of the graph are perceived as best. For this application, the alternatives in order of preference are 1.1, 1.2,2.2 and 2.1. (This is not the same order of preference as in Figure 4, which was based on representativeness alone.) As a result of this analysis, alternative 1.1 is implemented. Our system is now monitoring 17 of the 49 data channels, and is achieving adequate throughput. Later, an anomaly appears on one of the channels, which requires three additional channels to be added for anomaly analysis. The anomaly is solved, and at some later time, an anomaly appears on a second channel; this anomaly re- quires the addition of 12 more channels. We are now actively monitoring 32 channels, and are building a backlog. This causes the backlog detection module to ini- tiate metareasoning. Figure 6 (right) shows the re- evaluation at this point. Now, however, the selection of an alternative is not as obvious as in the previous cycle: alter- natives 2.1 and 2.2 are very close to lying on the same indifference curve. However, heuristics indicate that in the current mode, representativeness is the more important consideration, and alternative 2.1 must be selected. Even- tually, this anomaly is resolved, and we return to the normal operation mode. We have successfully tested DTE in the dynamic evalu- ation of the representativeness vs. timeliness trade-off in the Galileo SSI subsystem. This section describes the eval- uation procedures and presents the results obtained. To test DTE, we assembled test files containing simu- lated data that contains actual anomalies (supplied by JPL’s imaging-subsystem expert) in various anomaly den- sities (percentages of anomalous data in the file). The densities were chosen to provide evaluation of the DTE methods across the complete range of possible anomaly densities, in order to understand for which applications and situations DTE would be most successful. The test files were used to compare three different input management approaches. These included random data elimination, in- cremental filtering, and intelligent data management using dynamic trade-off evaluation. The first two methods pro- vide a way to compare DTE to conventional approaches Schwuttke and Gasser 503 I ALTERNATIVE NUMBER I Aggregate Value * (using weiqht *) 88.57 81.75 Aggregate Value ** (using welqh t **) 83.75 84.75 Aggregate Value**’ (using weight**“) 93.75 78.75 1.2 90 30 75 2.1 / 2.2 1 37.5 I 28.75 1 Figure 4. Aggregate alternative values for varying weights in single anomaly mode. Elimination of than. not Elimination of than. not Sampling reduction Sampling reduction in basic subset in critical subset on heuriitic subset on entire subset N.O.M. with no modification 1 2 3 4 N.O.M. with backlog modification 2 1 4 3 N.O.M. with monitoring modification 1 2 3 4 A.D.M. with no modification 3 2 1 4 A.D.M. with backlog modification 3 2 1 4 A.D.M. withmonitoring modification 2 3 1 4 Figure 5. Rankings of alternative values with respect to representativeness. actually used in practice. Random data elimination may appear to be an unusual choice. However, it most closely parallels the methods that less-experienced human analysts use in data-overload situations: when their data backlog becomes too large, they skip over the data in the backlog, and focus on the newly arriving data. Incremental filtering involves less loss of information. Data is filtered accord- ing to f = n/b (when ncb), where f is the fraction of samples passed through the filter, n is the total number of channel types, and b is the number of samples in the backlog. A backlog accrues according to the ratio of the incoming data rate to real-time processing rate (i.e., with a backlog ac- crual of x, data is arriving x times faster than it can be processed). Each of the three methods were evaluated with respect to performance under increasing backlog accrual. Finally, we used two criteria of performance: percentage of anomalies successfully detected and percentage of related data processed that is actually needed for correctly diag- nosing anomalies. The experimental results are summarized in Figure 7. The first of these graphs summarizes the average percent- age of anomalies successfully detected under increasing input data volumes and increasing anomaly density. The second graph summarizes the high-low spread of anomaly- relevant information that is processed under increasing in- put data volumes and increasing anomaly density. The first of these evaluation criteria is important with respect to automated monitoring, and the second is relevant to au- tomated anomaly analysis. Anomaly detection using DTE is highly successful for data rates as high as 2.5 times the real-time monitoring capability, particularly at anomaly densities of 10% or less. In these operating ranges, DTE outperforms both random data elimination and incremental filtering, detecting over 90% of all anomalies. The success of anomaly detection with random data elimination and in- cremental filtering, on the other hand, drops below 50% at backlog accrual rates as low as 1.5. Processing of anomaly-relevant information involves passing channels relevant to the analysis of a detected anomaly from the data management module to the moni- toring and analysis module. If anomaly-relevant channels are filtered by the data management module, some of the information needed for analysis will be lost. Intelligent data management with DTE is most successful at low (5% or lower) anomaly densities with backlog accrual rates that exceed real-time processing capabilities by as much as 2.5. Within these operational parameters, processing of anomaly-relevant information is as high as 95% for back- log accrual rates equal to twice the processing capability, 80% for backlog accrual rates equal to 2.5 times the pro- cessing capability, and 70% for backlog accrual rates equal to three times the processing capability. At these backlog 504 Problem Solving: Real-Time 80 0 20 40 60 80 Representativeness Representativeness Figure 6. Timeliness vs. Represntativeness Values for Galileo SSI input data management scenarios. accrual rates, the other two methods provide no more than 70%, 50%, and 50% of anomaly relevant data, respectively. Three criteria for intelligent data management systems have been identified Washington 19891. * The system should be responsive to changing resource requirements. For example, the amount of data sampled should vary with the computa- tional load placed on the system. * The system should be responsive to important and unusual events in the input data, even when it is “busy”. * The system should be able to focus its attention on parameters that are particularly relevant to the current reasoning task. The Galileo SSI application has shown that DTE pro- vides an effective way to achieve each of these criteria, not only for “thresholdable” data addressed by Washington, but also for goal-driven data that does not occur in his application. DTE enables both anomaly detection and anomaly diagnosis for low anomaly densities and moder- ate backlog accrual rates. Actual anomaly densities for this application average less than 3%, which is well within the acceptable operational parameters of the method. Figure 7 show performance degradation in the DTE method beginning at backlog accrual rates that exceed real- time processing capability by a factor greater than three. Furthermore, when the backlog accrual rates exceed pro- cessing rates by a factor of four or more, the DTE method begins to converge with the other two methods. This per- formance degradation is governed by the domain knowledge. The minimal monitoring set for complete anomaly detection (as defined by the domain expert) con- sists of one third of the entire channel set. When these channels are not monitored, some loss of monitoring in- tegrity will occur, as is demonstrated by degradation of the DTE method at backlog accrual rates of 3.5 or more. Sub- sequent testing shows that with an imaginary domain, in which the minimal set can be defined as a significantly smaller subset of the total channel subset, the effective in- crease in data reduction that can be achieved is on the same order as the decrease in size of the minimal set. A long- term solution to this problem in the context of a specific domain involves designing telemetry (or other input data) definition to later enable maximum data reduction. The more hierarchically the monitored data can be structured, the more the monitored data set can be reduced. The observed performance degradation at known data rates enables the system to predict its own failure and pro- vide warnings of reduced monitoring integrity. In a dis- tributed environment, a module that predicts its own failure to meet real-time constraints could actually request additional processing resources from the environment. Dynamic Trade-off Evaluation has been shown to be an effective technique that offers significant benefit to real- time AI systems. DTE incorporates a mix of knowledge- based and utility-theoretic techniques and is particularly valuable in real-time monitoring situations of moderate anomaly densities, varying data rates, and dynamic deci- sion criteria. In experimental evaluations, DTE signifi- Scbwuttke and Gasser 505 8 2oi- ----- -. -. - RANDOM DATA ELIMINATION s --- lOi-- INCREMENTAL FILTERING - DYNAMIC TRADEOFF EVALUATION Ol-J-- . ..-lII -I 1 1.25 1.5 2 2.5 3 4 INPUT VOLUME/PROCESSING CAPACITY - 20" 0 RANDOM DATA ELIMINATION L1\1 INCREMENTAL FILTERING I DYNAMIC TRADEOFF EVALUATION l---_I-. -I-. --~_- J 2 2.5 3 4 INPUT VOLUME/PROCESSING CAPACITY - Figure 7. Results of experimental analysis for anomaly detection and anomaly analysis at 3% anomaly density. cantly outperforms other commonly-used approaches to manage real-time monitoring data trade-offs in increasing- backlog situations. Moreover, DTE is a generic technique that can be effectively applied in many kinds of trade-off analysis for real-time systems. We have designed a generic architecture for DTE applications, treated elsewhere [Schwuttke 19911, and have taken initial steps to imple- ment DTE as an operational part of the MARVEL intelli- gent monitoring system [Schwuttke 1992; Schwuttke 19921 in use at JPL. Acknowledgments The authors wish to acknowledge mission expertise from William Cunningham, software contributions from Alan Quan, and helpful discussions with John Rohr, Kenneth Goldberg, Bruce Abramson, and Alice Parker. References Dean, T. 1990. Decision Theoretic Control of Inference for Time-Critical Applications, Technical Report CS-90- 44, Department of Computer Science, Brown University. Dyer, J. S. and Sarin, R A. 1979. Measurable Multi- attribute Value Functions. Operations Research, 22: 8 10-822. Edwards, W. 1977. How to Use Multi-attribute Utility Measurement for Social Decision Making, IEEE Trans- actions on Systems, Man and Cybernetics, SMC-7,326-40. Edwards, W. and Newman, J. R. 1982. Multi-attribute Evaluation. California: Sage. Gardiner, P. 1974. The Application of Decision Technol- ogy to Multiple Objective Public Policy Decision Making. Unpublished Ph.D. dissertation, University of Southern California. Horvitz, E. J.; Breese, J. S.; and Henrion, M. 1988. Deci- sion Theory in Expert Systems and Artificial Intelligence. International Journal of Approximate Reasoning, Special Issue on Uncertain Reasoning. Horvitz, E. J.; Cooper, G. F.; and Heckerman, D.E. 1989. Reflection and Action Under Scarce Resources: Theoreti- cal Principles and Empirical Study. Proceedings of the Eleventh International Joint Conference on Artificial In- telligence, 1121-l 127. Keeney, R. and Sicherman, A. 1976. An Interactive Com- puter Program for Assessing and Using Multi-attribute Utility Functions. Behavior& Science, 21: 173-182. Russell, S. and Wefald, E. 1989. On Optimal Game-Tree Search Using Rational Me&reasoning, Proc. of Eleventh Int. Joint Conf. on Artificial Intelligence, 334-340. Schwuttke, U. M. 1991. Intelligent Real-time Monitoring of Complex Systems. Ph.D. dissertation, Dept. of Electri- cal Engineering, University of Southern California. Schwuttke, U. M.; Quan, A. G.; and Gasser, L. 1991b. Im- proved Real-time Performance in Automated Monitoring Using Multiple Cooperating Expert Systems. Proc. of 4th International Conference on Industrial and Engineering Applications of AI and Expert Systems, 221-228. Schwuttke, U. M.; Quan, A. G.; Angelino R.; et al. 1992. MARVEL: A Distributed Real-time Monitoring and Anal- ysis Application. In Innovative Applications of Artificial Intelligence 4, eds. P. Klahr and C. Scott. Boston: MIT Press. Forthcoming. Simon, H. 1955. A Behavioral Model of Rational Choice. Quarterly Journal of Economics, 69. von Winterfeldt, D. and Edwards, W. 1986. Decision Anal- ysis and Behavioral Research. Cambridge: University. Washington, R. and Hayes-Roth, B. 1989, Input Data Management in Real-time AI Systems. Proceedings of the Eleventh International Joint Conference on Artificial In- telligence, 250-255. 506 Problem Solving: Heal-Time | 1992 | 88 |
1,285 | Eric awn NEC Research Institute 4 Independence Way Princeton NJ 0854 eric@research.nj .nec.com bstract We consider the approach to game playing where one looks ahead in a game tree, evaluates heuristi- cally the probability of winning at the leaves, and then propagates this evaluation up the tree. We show that minimax does not make optimal use of information contained in the leaf evaluations, and in fact misvalues the position associated with all nodes. This occurs because when actually play- ing a position down the game tree, a player would be able to search beyond the boundaries of the original search, and so has access to additional in- formation. The remark that such extra informa- tion will exist, allows better use of the information contained in the leaf evaluations even though we do not have access to the extra information itself. Our analysis implies that, while minimax is ap- proximately correct near the top of the game tree, near the bottom a formula closer to the probabil- ity product formula is better. We propose a simple model of how deep search yields extra informa- tion about the chances of winning in a position. Within the context of this model, we write down the formula for propagating information up the tree which is correct at all levels. We generalize our results to the case when the outcomes at the leaves are correlated and also to games like chess where there are three possible outcomes: Win, Lose, and Draw. Experiments demonstrate our formula’s superiority to minimax and probability product in the game of Kalah. $1: Introduction It is well known that minimax is an optimal game playing strategy provided the whole game tree can be searched (Von Neumann & Morgenstern 1947). For complex games such as chess, limitations in computa- tional resources allow only a partial search. (Shannon 1950) proposed that a computer might play chess by searching to a depth d, evaluating the positions found using some heuristic evaluation function, and then us- ing minimax to propagate values up the search tree. (Pearl 1984) proposed the probability product rule as an alternative to minimax. This proposal was based on the assumption that the heuristic evaluation func- tion estimates the probability that the position is a win against best play, and then follows from the re- mark that the correct way to combine (independent) probabilities is by probability product. This reasoning correctly asserts that a position with 100 alternative moves, each of which has independently .l probabil- ity of leading to a won game, is almost certainly a won position. We observe here that this offers little solace to the player in this position, if he can not fig- ure out which moves lead to wins, for he must choose one particular move, and then loses with probabity .9. This paper studies how optimal game play is affected by the computational limitations of the players. Due to these limitations, the game is effectively one of im- perfect information, and this information is effectively asymmetric. Neither Minimax nor Probability Prod- uct takes account of this. We describe a strategy which does. Imagine playing the following game, game 1. Player A makes either move Al or move A2. Then player I3 makes either move Bl or B2. Then player A pays player B $1 with probability Pij for i = Al or A2 and j = Bl or B2. Let Prr = .5, I32 = .5, P21 = .6, P22 = .l. Now player A should follow the optimal minimax strategy and make move 1, and the expected payoff to player B will be .5. Now imagine a slightly different game. The rules of game 2 are the same as game 1 except that after player A moves, but before player B moves, the payoffs are generated according to Pij, and player B is told what the outcome of his moves would be. Now if player A chooses move 1, there will be probability 1 - (1 - .5)2 = .75 that player B will have a move which wins for him. If player A chooses move 2, however, then the expected payoff for player B is only 1 - .4 x .9 = .64. Accordingly player A must change his strategy from the first game. : Now consider playing a game like chess by construct- ing the game tree to a depth of (say) 10 ply, evaluating the leaves using a necessarily noisy evaluation func- tion, and then propagating the value up the tree by Baum 507 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. minimax. We claim this minimax propagation makes suboptimal use of the information contained in the leaf evaluations. The notion of minimax is to assign values to the positions associated with the nodes 9 ply deep by taking the maximum value (to the opponent, player B) of the accessible positions 10 ply deep, just as we assigned a value to player B’s position at a depth of 1 ply in game 1 above. But, just as in game 2 above, our opponent has much better information about whether the outcome is a win or a loss for him than is contained in our evaluation function. This is because, when he comes to play in this position, he will search it 10 ply deep! Thus we should assign a value to our opponent, of being in this position, according to a formula closer to the probability formula useful in game 2, than the minimax formula useful in game 1. In general we ex- pect a smooth interpolation between using a formula near probability product deep in the search tree and using a formula near minimax near the top of the tree. We assume the evaluation function estimates the probability of winning at a position in actual play. In minimax only rank ordering of positions matters, so standard evaluation functions may require mono- tonic but nonlinear resealing. One may train evalua- tion functions to represent probability by accumulating statistics (Pearl 1984). Besides (Pearl 1984) there have been other previ- ous studies of alternative propagation schemes. (Chi & Nau 1989) claimed, for the game of three hole kalah, that probability product outperforms minimax for the same depth of search. In our experiments, see $5, we found minimax far superior to probability product and attribute their result to the fact that they only worked at depth 2 ply. Another approach was that of (Sla- gle and Dixon 1969) who remarked that the evaluation function was a noisy version of the truth and that mini- max is suboptimal because it ignores the fact that “it is valuable to have several good alternatives in a planned course of action”. Their M&N procedure assigns to a max(min) node some heuristic function of the M(N) highest(lowest) valued successors. We will not have space here to discuss issues of time complexity beyond remarks in this paragraph. The alpha-beta pruning algorithm computes the exact re- sult of minimaxpropagation in time roughly the square root of that required by brute force calculation. Now we argue that ‘the exact result of minimax propaga- tion’ is only an approximation to the correct propa- gation. Nonetheless, approximate use of information from a larger tree might likely be better than opti- mal use of information from a smaller tree. For this reason one should not expect practical improvements from the propagation algorithms discussed in this pa- per without addressing the question of pruning. We are here concerned only in principle with optimal use of the information. Once we understand what calcu- lation is in principle optimal, we may consider how to efficiently approximate it. An expanded version of this paper (Baum 1991) shows that much of the com- putational benefit of alpha-beta pruning can be taken over into propagation using truncated versions of our formula. Thus one can efficiently compute a better ap- proximation than minimax to the information-optimal propagation. A still more promising approach is also under investigation. Recently a number of authors (McAllester 1988), (Rivest 1988), (Russell & Wefald 1991), have proposed algorithms for growing a search tree including only relevant nodes. Ideas of these au- thors on pruning can be readily complemented by the results in the present paper on propagation. By com- bining ideas from these authors, some new algorith- mic ideas, and the information theoretic results of the present paper, we believe that improved search algo- rithms can be produced. This will be discussed else- where (Baum & Smith 1992). $2 derives a formula useful for propagating evalua- tions up game trees. 53 describes the approximations inherent in the formula of $2 and when it is optimal. $4 discusses generalization to the case of correlated probabilities. §5 describes experiments on the game of Kalah. $6 is a summary. 52: An Interpolation and Probabillistic Combination Consider the following one person game, game 3. Player A has b possible moves. A referee declares move i E (1, . . . . . b} a Win with probability pi. He does not tell player A these outcomes, however, until after A moves. Instead he supplies to player A b bits of in- formation hi, where hi is 1 with probability p”h given that move i is a Win, and is 1 with probability 1 - pi given that, move i is a Loss. Player A knows the pi and pzw and pi. Game 3 is a model of deep search in a game like chess. Think of hi as a hint about the value of move i. For appropriate p*h and pi, ha models the extra in- formation,in deep search relative to simple evaluation. If paw = p; = 1, ha tells the exact outcome, and game 3 is like game 2. If pi; = pi = i, there is no extra information, and game 3 is like game 1. What is the value V of game 3 to player A? By Bayes law, P(i = WI/& = a) = P(hi = ali = W)P(i = W) P(hi = a) ’ (2.1) Here a = 0,l. The notation should be evident. For example by P(i = Wlhi = 1) we mean the probability that move i leads to a win given that hi is 1. Now P(hi = 1) = P&Pi + (1 - z&)(1 - Pi) (2.2) P(hi = 0) = (1 -P”;v)(Pi) +&(I -Pi) (23 so P(i = Wjha = 1) = Pi& Pi P&pi + (1 - p”,)( 1 - pi) (2’4) 508 Problem Solving: Search and Expert Systems P(i = Wlhi = 0) = (1 - Pk)Pi (1 - P&&i) + pi(l - pi) (2*5) We now calculate the probability V of winning for player A who uses Bayes optimal strategy. Let P(i,a) f P(i = WJhi = a). Order the moves so P(i, 1) 2 P(i + 1,l) for all i. Let c be the smallest number for which an i satisfies P(i, 0) 2 P(c+ 1,1) (if there is no such number let c = b). Let ic be arg max P(i, 0). Then (Pi0 - P”w) + (1 - Pi)(P”l)) j=l,c i=l,j-1 (l-P%) +pio Pi,(l - &) + (1 - Pi,)(&) X (Pi(l - Pb) + (1 - Pi)(Pi)) (24 i=l,c When hl = 1, the Bayes optimal choice is move 1 (i.e. eqn’s 2.4 and 2.5 imply move 1 is most likely to win, independent of hi for i # 1). The payoff then is pl. This is the first term in the sum. When hl = 0, ha = 1 player A picks move 2. This has payoff p2 and occurs with probability (pl(l - pw) + (1 - pl)(p~))pw since h2 = 1 with probability pw when move 2 is a win and h = 0 with probability (1 -pw) when the first move is a Win or with probability pi when the first move is a Loss. This yields the second term in the sum. Finally if hi = 0 for i = 1,2, . . . . c, the Bayes optimal choice is move ie. This event yields the last term. Note that we recover the appropriate values in the limiting cases. When player A has no additional infor- mation beyond the pi, i.e. when Vi : psw = pi = 3, then c = 1 and V = PIPW t: PI(~ T PW) = PI, the minimax value. When Vi : pzw = pi = 1, the limit of perfect information, then c = b and we recover the probability formula V = 1 - n,=,,,(l - pi). Note also that formula 2.6 can easily be computed in time O(c) (once we sort the pi). In human chess play, consideration of drawing prospects is important, particularly in endgames. Many standard chess programs seem relatively weak in both their consideration of drawing prospects and their handling of endgames. The arguments of this section can be readily generalized to games with three outcomes: Win, Lose, or Draw. We compute at each position both the probability of Winning and of Draw- ing and can then make move decisions based on overall Utility of the prospects. Equations analagous to 2.6 can be derived for propagating VW (the probability of winning) and Vr, (the probability of drawing) up the search tree. One may also perform calculations involv- ing conditional probabilities. (Humans will frequently enter into a line of play which they are confident can be drawn but preserves winning chances.) Details are contained in the long version (Baum 1991). 53: A Model of Deep Search In this section we will first derive an exact formula, which optimally propagates leaf evaluations up a tree given essentially as much knowledge as one might in principle gather about how time for analysis improves evaluation of outcome. Formula 2.6 will arise as an ap- proximation, making more realistic assumptions about how much we know about how deen search and anal- ysis improves on simple heuristic e;aluation. Formula 2.6 will be seen to be exact in a simple model of eval- uations studied by (Schriifer 1986), and for this model we will give the appropriate pw and pi. We wish first to calculate the probability V that our opponent will win in a position where he has b possi- ble moves and we have evaluated by using our simple heuristic evaluation function the probability that he wins if he makes move i as pi. For generality, let Xi de- note the value(s) of any (collection) of other functions of the positionwhich might be useful. So, e.g., X might include an estimate of how “tactical” the position is, if we believe deep search to be more informative rela- tive to simple evaluation in “tactical” positions than in more “positional” situations. We will thus evaluate V in terms of (1) our heuristic evaluation of the probabil- ity of winning of its successors, and (2) an estimator, which we may previously train on &me large set of games, of how much deep search improves evaluation relative to our simple heuristic evaluator, where we al- low this estimator to depend on a small number of fea- tures. This estimator will be called P(qlp+, Xi) which we define to be the probability that extended analy- sis when actually playing this position, say by depth d search, will lead to the estimate that the nrobabilitv of winning by playing move i is between q and q + di. Now we have s 1 v= dq q x (Probability highest evaluated move has 0 probability q). (34 The highest evaluated move has probability estimate Q provided (a) none of the b alternatives has esti- mate higher than q> and 04 at least one has prob- ability estimate q . (Note this means between q and q + dq. For pedagogical clarity we omit epsilantics wherever possible.) The probability that none of the b moves is estimated to have probability higher than q is [niZl,*(l - s,’ dq’ P(q’Ipi, Xi))]. The probability that move .i has evaluation Q, given that it does not have -. - evaluation higher than q is P(&.Q,Xi) C1-JalW p(q'lPi,Xi))' Thus the probability that at least one of the b moves has probability q, given that none of them has evaluation higher than q, is {l-ni=l,a(l- p(q’pllxi) (1-J; w P(dlPlJi)) )}. Putting this together we find V=lldy q[iQa(l-ildd p(CtlPi,xi))l - 8 Baum 509 i=l,b f%lPi’ Xi> (1 - 1; 4’ fwlPa, w> >I (3.2) More generally, we must compute the probability of winning at a node at level I + 1 in the search tree, given that we have calculated, by propagation up from the leaves, that the probability of winning if we choose move i is pi. To do this we measure the distribution P(qlp{, Xi), and we have simply Unfortunately the utility of this formula is limited by any practical limitations in our ability to approximate P(qlpi, Xi). We propose equation 2.6 as a simple ap- proximation which is easy to use and reasonably accu- rate. The approximation inherent in 2.6 is that q can take on only one of two values, given pi and Xi, Thus P(qlpi,&) is simply the sum of two delta functions. These two values are given by eqns. 2.4 and 2.5. One value (corresponding to hi = 1) is a revised estimate from depth d search that the probability of winning is higher than depth 1 search estimates, and the other is a revised estimate that the probability is lower. In fact equation 2.6 can be seen to be exact in the widely studied model where the evaluation function is Boolean, returning either 0 or 1, and where our knowl- edge of correctness of our evaluation is dependent only on depth of search, and not on other features of the position. This second condition occurs, e.g., if we ne- glect (as is common in game programs) to estimate feature dependence of the accuracy of our calculation. Under these assumptions, if depth d search, returns a 1 (respectively a 0)) we assign a certain probability pz (respectively pi) that the position is Won. Accord- ingly P(qlpf) is bivalued and equation 2.6 exact. These conditions hold, e.g. in the model studied by (Schriifer 1986) and in the related model of (Nau 1983). (Schriifer 1986) studied the following model. We build a game tree starting from the root, which may be either a Win or a Loss node, and grow a tree with uniform branching ratio b. Below every Win node there are n Loss nodes and b - n Win nodes (where we define node values with respect to the player on move). By definition, a Win node must have at least one winning option, so n 2 1. Below every Loss node, again by definition, all b children are Wins. The tree is built to depth d. A heuristic evaluation function returns a noisy estimate of the true value of the leaves as follows. If the leaf is a Win node, the evaluation is e = 1 with probability 1 - et (and thus 0 with probability et) and if the leaf is a Loss node, the evaluation is 0 with probability 1 - eo (and thus 1 with probability ei). Now (Schriifer 1986) derives recursion relations re- lating the probability of error at level I + 1 above the leaves to that at level 1 (denoted e:), assuming the evaluation is propagated up the tree by minimax: ef& = (eF)n(l-e;t)b-n ; e& = l-(l-e,+)b (3.4) Analyzing these equations, (Schriifer 1986) showed that deep search is pathological (i.e. gets worse the deeper you search) provided n = 1, but is at least ex- ponentially convergent to zero error (i.e. e+ h* 0 and - N 0) if n > 1 and e$ and ei are sufficiently small. TSchriifer 1986) 1 a so analyzed a somewhat more com- plex model, where n is an i.i.d. random variable at each Win node in the tree, chosen with probability pj to be j for j = 1 up to b. These results cast con- siderable light on the question, hotly debated in the theoretical AI literature for ten years, of when game search is pathological. In Schriifer’s model we may calculate how deep search improves the accuracy of our evaluation. Also, since the evaluation function is bivalued, and since ac- curacy depends only on depth of search (rather than say other parameters of the position or game tree) the evaluator P(qlel) is is in fact zero except for two val- ues of q. In (Baum 1991) we calculate explicitly in this model P(qlel) d h an s ow that equation 3.3 reduces ex- actly to equation 2.6 for appropriate values of pw and pi. One demands that pw and pi be chosen so that the probability of winning given by eqns 2.4-5 is equal to that given by depth d search. We omit the lengthy Bayesian calculation for reasons of space but state the values of pw and pi which emerge. We find P&4) = (1 - ed+)(l- er+ - ea + e;teg - e,e;f) (1 - el+)(l - e$ - eJ) (3.5) , , PN = (1 - - e, + e;ted - (e;)(l - ez - ed) e,e:) (3.6) P&4) = (1 - e$)(ef- -eJ+ele$- (e;t)(l - ed+ - ed) hi) (3.7) POLU) = (1 - ed)(l - er - ef + e,e$ - er+ea) (1- el)(l- e$ - ez) (3.8) These formulae tell us how to calculate the pw and pi and use formula 2.6. Here the superscripts on pw and pr, correspond to the superscripts i in eqn 2.6 as follows. One should use superscript 1 (eqns 3.5-6) in equation 2.6 for moves i with pi 2 $ and one should use superscript 0 (eqns 3.7-8) for moves with pi < a. Recall that et (resp. el) is defined as the probability that a depth I search predicts a state is lost (resp. won) when in fact it is won (resp. lost) (and ef is simply e: for I = d). The ef and e: are thus directly measurable by taking statistics. Alternatively, they may be calculated in Schrcfer’s model. If our search is accurate, it will be a good approximation to neglect both ef and ef with respect to 1. This yields: Ptv 6 6 =l’p~=1---;p&=1---$‘p~=1 (3.9) 510 Problem Solving: Search and Expert Systems Thus convergence to perfect information is linear in the ratio of the accuracy of depth d search to depth 1 search. (Schriifer 1986) shows that, when deep search is not pathological, it is typically at least exponentially convergent. Thus pw and pi are likely near one for many levels in a search tree. 54: Correlations So far we have proceeded under the assumption that that probabilities pi of winning are independent. Since these are probabilities of winning of positions differing by only two moves, they more realistically should be considered correlated. Note that we are not concerned with correlations in the distribution of the values of the pi. This kind of correlation implies that if p = .9 for a position, than a sibling position is likely to have p 2 .5. This must occur, for if nearby positions are not more likely to lead to similar results, we could not play using a heuristic evaluation function. Instead we are discussing now correlations between the outcomes, given the probabilities. This kind of correlation occurs when two siblings each have p = .8, but the probability that either sibling wins is less (or more) than 1 - .22. In (Baum 1991) we give a more general discussion of correllations. Here for conciseness we specialize to a simple assumption about the form of correlations. This assumption seems plausible as an approximation, and is simple enough to allow a readily computable formula. Since we have little idea about the nature of the correlations in practice it also seems reasonable to choose a model which allows a one parameter fit. Our simplified model follows. Correlation is specified by one parameter: y. Given pl 2 p2 1 ., . 2 pi, we determine which moves lead to a win as follows. A referee first draws a bit Bc which has probability ypk of being 1. If Bc is a 1, then all moves, l,..., L are W. If Bc is a 0, then move i : i = 1, . . . , k: is a W with probability pa - ypk, where all of these are now determined independently. Note we don’t care what happens for i > Ic, because we assume either that these moves are totally correlated with move 1, or because in any case the combination of their correlation plus low probability means the player should never select them, independent of the hi, or because we simply consider strategies which truncate after considering the Ic best moves. If we only consider strategies which truncate after 2 moves (i.e. if k=2) this model of correlations can be easily seen to be without loss of generality. Now it is easy to write down the analogue of equation 2.6. Let V(pl,p2, . . . . pk) be defined by equation 2.6, where c --) Ic. For i = 1, . . . . Ic let (54 Call the value of the position, in the model with cor- relations, V’. Then v’ = -/Pk + (1 - YPk)V(i? (5.2) This is evident since with probability TpI,, Bc = 1, and the position is a win. Otherwise, the probability of winning is V(g). Note that in the limit of perfect correlation, i.e. y = 1 and p!, = ~2, we recover the minimax value pl , since then pi = 0, and so we discover in computing V(g) that c = 1 and 5.2 reduces to 7~2+ (1 - TPa)P: = Pl* §5: Experiments with alah This section describes preliminary experiments’ com- paring performance of programs using minimax, prob- ability product, and formula 2.6 on the game of Kalah. Kalah has been described as a “moderately complex game, perhaps on a par with checkers” (Slagle & Dixon 1970). See (Slagle & Dixon 1969) for a discussion of the rules. We mention here only that the object of Kalah is to capture stones. As evaluation function (Slagle & Dixon 1969) pro- posed and (Chi & Nau 1989) studied Kalah Advantage (KA) defined as the difference in number of stones cur- rently captured (scaled to be between 0 and 1 to esti- mate a probability of winning). We found this did not adequately estimate the probability of winning. In- stead we used the following. Define SrKA/NR where NR is the number of stones remaining on the board (and thus potentially winnable). Our evaluation func- tion then was El - (1 - S)/2. In head to head com- petition using depth 6 ply alpha-beta, E played a sub- stantially stronger game than KA. Note that when KA=NR (so that a mathematical win or loss has oc- curred) E is 1 or 0, and when KA=O, E = l/2. This is a reasonable estimate of the probability of winning for KA=O, but not precise since the side on move has an advantage (about 53% in our tournament). More com- prehensive experiments might take statistics to find a nonlinear, monotonic resealing of E which more closely estimated probability of winning. This would presum- ably increase the edge of formula 2.6. We simply chose to set, for E a parameter: Pw =PL=l-2 +cd-l) where d = 6 was the depth of our search and 1 = 0 9 “‘> 4 was the level above the leaf. The exponential form was suggested by the dependence of pw and pi in equations 3.9 on el and ed and the exponential increase in accuracy of deep search in Schriifer’s model. Note that for this first cut we approximated by setting pw = pi and by setting both independent of all other factors, including pi, the probability the move will win. More accurate tuning up of the piw and pi would be possible with more work. Presumably this would improve the performance of formula 2.6. A small tournament was played on 400 games for values of E = .8,.85,.9, and .95. Formula 2.6 seemed to have an edge against minimax ‘These experiments were performed by E. using code partially written by W. D. Smith. Wigderson Baum 511 for each of these values, but the edge was largest for c = .9 so we then performed a tournament of 20,000 games for this value. Note E = .9 corresponds to relatively modest choices of pw and pi. By parametrizing pw and pi in this way and choosing E to maximize results, we implicitly tuned against the degree of correlation, and the modest values of pw and pi may reflect a fair degree of correlation. Tournaments were performed by choosing 10,000 starting positions by making the first 6 moves at ran- dom. For each of these starting positions competitor A and B played both First and Second, where A and B could be any of minimax, formula 2.6, or probability product( All algorithms played to depth 6 ply (full width). Formula 2.6 won 9906 games against minimax, while minimax won 9171, and 923 were draws. Mini- max won 18359 games against PP, while PP won 1581, and 60 were drawn. 2.6 won 18882 against PP, while PP won 1040, and 78 were drawn. Note that probabil- ity product was awful, which is attributable to its poor treatment of correlations (Smith I992). Note that (ex- cluding draws) formula 2.6 beats minimax 52 f .03% of the games. This is a small but clear edge (significant at more than 50) which possibly could be improved by better tuning of the evaluation function to reflect prob- ability, better tuning of ptw and pk, and using a for- mula such as equation 5.2 which explicitly accounts for correlations. Note as discussed in $1, that this paper does not reflect time performance issues, but merely performance on equal depth trees. W : is@ussion We have remarked that minimax incorrectly values po- sitions since it does not account for extra information that players will have when they actually encounter the position. This extra information arises, for exam- ple, from their ability to do a deep search from the position. While it is not possible to know the “true” value of a position without actual possession of this extra information (and perhaps some in addition), the mere realization that the players will act based on ex- tra information allows more accurate estimation of the value of positions. A similar phenomenon will arise in search and planning contexts other than games. When computational or informational limitations force one to make a heuristic choice, one’s choice should take account of the relative computational advantages in future choices. We have given a formula (3.3) which correctly prop- agates up the tree the information contained in evalu- ations of the probability of winning at the leaves given detailed, but in principle available, information about the nature of extra information (under the assumption of independence of the leaf probabilities). Since this detailed information seems likely to be difficult to ob- tain in practice, we have proposed a simple formula for propagating information up the game tree. This model requires only limited, and readily obtainable estimates of the extra information. It is exact in widely studied models (e.g. Schriifer 1986.) Experiments in the game of Kalah exhibit the superiority of this formula to both minimax and probability product. Acknowledgement: I thank L.E. Baum for suggesting that I consider games with draws, W. D. Smith for helpful comments on a draft, and especially E. Wigder- son and W. D. Smith for the experimental work re- ported in $5. eferences Baum, E.B. 1991. “Minimax is not optimal for im- perfect game players”, preprint, submitted for publi- cation. Baum, E.B., and W. D. Smith. In preparation. Chi, P-C, D. S. Nau. 1989. ‘Comparison of the Minimax and Product Back-up Rules in a Variety of Games”, in Search in Artificial Intelligence, eds. L. Kanal and V. Kumar, Springer Verlag, New York, pp451-471. McAllester, D. A. 1988. ‘Conspiracy numbers for min- max search”, Artificial Intelligence v35 ~~287-310. Nau, D. S. 1983. “Decision Quality as a Function of Search Depth on Game Trees”, Journal of the ACM, V 30, No. 4, pp 687-709. Pearl, J. 1984. Heuristics, Intelligent Search Strate- gies for Computer Problem Solving, Addison Wesley Publishing Co, Reading MA. Rivest, R. L. 1988. “Game Tree Searching by Min/Max Approximation”, Artificial Intelligence 34 pp77-96. Russell, S., and E. Wefald. 1991. Do the Right Thing, Studies in Limited Rationality, MIT Press, Cambridge MA. Schriifer, G. 1986. “Presence and Absence of Pathol- ogy on Game Trees”, in D.F. Beal, ed., Advances in Computer Chess 4, (Pergamon, Oxford, 1986) pp lOl- 112. Shannon, C. E. 1950. “Programming a Computer for Playing Chess”, Philosophical Magazine 41(7): 256-75. Slagle, J. R., and J. K. Dixon. 1969. “Experiments with some programs that search game trees”, JACM V16, No 2 pp 189-207. Slagle, J. R., and J. K. Dixon. 1970. “Ex- periements with the M&N Tree-Sear&in Program, CACM 13(3)147-154. Smith, W.D., 1992. personal communication. Von Neumann, J., and 0. Morgenstern. 1947. Theory of Games and Economic Behavior Princeton Univer- sity Press, Princeton. 512 Problem Solving: Search and Expert Systems | 1992 | 89 |
1,286 | R. Peter Bonasso, James Autonisse, Marc 6. Slack Autonomous Systems Laboratory, the NIITRE Corporation 7525 Colshire Drive Mclean, Virginia 22 102 pbonasso@mitre.org Abstract This paper describes the results of using a reactive control software architecture for a mobile robot retrieval task in an outdoor environment. The software architecture draws from the ideas of universal plans and subsumption’s layered control, producing reaction plans that exploit low-level competences as operators. The retrieval task requires the robot to locate and navigate to a donor agent, receive an object from the donor, and return. The implementation employs the concept of navigation templates (NaTs) to construct and update an obstacle space from which navigation plans are developed and continually revised. Selective perception is employed among an infrared beacon detector which determines the bearing to the donor, a real-time stereo vision system which obtains the range, and ultrasonic sensors which monitor for obstacles en route. The perception routines achieve a robust, controlled switching among sensor modes as defined by the reaction plan of the robot. In demonstration runs in an outdoor parking lot, the robot located the donor object while avoiding obstacles and executed the retrieval task among a variety of moving and stationary objects, including moving cars, without stopping its traversal motion. The architecture was previously reported to be effective for simple navigation and pick and place tasks using ultrasonics. Thus9 the results reported herein indicate that the architecture will scale well to more complex tasks using a variety of sensors. Introduction We are interested in programming robots to carry out tasks robustly in environments where events for which the robot has a response can occur unpredictably, and wherein the locations of objects and other agents are usually not known with certainty until the robot is carrying out the required task. To achieve this we have taken the situated reasoning approach which closely integrates planning and plan monitoring through perception in real-time. The approach requires that the planning system selectively use the various sensors available to the robot to track changes in the environment and to verify that plan tasks are achieved. We are using an agent software architecture wherein reaction plans (Schoppers 1989) use subsumption competences (Brooks 1986) as operators. The benefits are that reaction plans need only map agent states into competences, thus reducing their size, and that formal goal representations may be used to augment the limited representational power of the subsumption competences. Our architecture is implemented in the GAPPS/Rex programming language (Kaelbling 1988), which expresses and enforces a formal semantics between an agent’s internal states and those of the environment (Rosenschein and Kaelbling 1986). The reaction plans and the layered competences are expressed in propositional reduction rules, augmented by Common LISP programming constructs. They are subsequently compiled into a circuit formalism which supports direct analysis of parallelism and enforces a constant time cycle execution regimen. Additionally, the accompanying programming environment supports generating the circuit code in C and other languages in which commercial robot control operating systems are written. Our previous work (Bonasso 199la, Bonasso 199lb) showed the efficacy of our agent architecture for following a trajectory among obstacles on land and underwater, and for pick and place tasks. Though these tasks were useful, particularly with human supervision, they required only ultrasonic and directional sensing and were of relatively low complexity. We desired to see how the architecture would scale to more complex tasks with more sophisticated sensors. The find and fetch task described below is both useful for robots to carry out and of sufficient complexity to suggest a positive answer to the scaling question. The Find and Fetch Our land mobile robot find and fetch task requires a robot to locate a donor agent which holds an object to be retrieved, to navigate safely among obstacles to the donor, to accept the object from the donor, and to return to its original location. Our goal was to generate a reaction plan for one of our mobile robots to carry out such a task outdoors in an area which held an unpredictable number of stationary and moving objects. A parking lot provided such an environment, due to the intermittent appearance of moving cars and walking people, and because the number and positions of the parked cars were constantly changing. Our land mobile robot is equipped with ultrasonic proximity sensors, an infrared (IR) beacon reader, roll and pitch inclinometers, and the PRISM real-time stereo system (Nishihara 1984). Since general object recognition was not a central part of our research, we specified that the donor agent would be identified by a special IR frequency Bonasso, Antonisse, and Slack 801 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. emission. The overall strategy taken was to use the IR reader to determine the bearing to the donor, use the stereo system to determine the range, and then navigate to the donor using the ultrasonics to avoid obstacles. Because we wished to limit human involvement in the demonstration, the donor agent used was a Hero 2000 mobile robot rigged with an IR transmitter. The Reaction Plan Figure I shows the GAPPS reduction rules used to generate the reaction plan which accomplishes the find and fetch task described above. The goalem function at the bottom of the figure invokes the GAPPS compiler on the top-level goal. This goal is a conjunction of 1) a priority conjunction of goals and 2) a standing goal to always move towards the current navigation goal. A navigation goal is posted from a computed trajectory to a target. The priority conjunction of the form (prio-and gl, g2,g3, . . . . gn) requires that all the goals be satisfied simultaneously, unless there are contradictory preconditions, in which case the plan should attempt to achieve the first n-l goals, etc. Using the preconditions in the reduction rules and the conjunctions in the top-level goal, the compiler generates a total of 63 ways to accomplish the top-level goal. By examining the rules, one can see that the competent behaviors being sequenced in the reactive layer are runaway, navigation, IR search, and PRISM (stereo) search. On each cycle of the resulting circuit 1, all the preconditions are examined to determine which set of behaviors will be active on that cycle. If “all goes as planned” this plan will first invoke the IR search activity until a bearing to the donor is found, then invoke the stereo search activity along the IR bearing until a range is found, and then, using the coordinates computed from the direction and range, invoke a navigation activity to reach the donor. Once the object has been received from the donor, the plan will invoke a navigation activity to return to the starting position. Being responsive to changes in the environment, however, this plan will, for example, also make sure the robot does not start the IR search if there are obstacles in close proximity, and will restart both the stereo search and IR search if the homing to the beacon is lost, e.g., if the Hero robot moves. One should note that the rules for (maint find-donor- direction) and (ach find-donor-location) do not explicitly call for setting the direction or computing the location of the donor. These are handled in the (we-know-the-donor- direction) and (set-the-goal-as-the-donors-location) functions. If on previous cycles these functions return FALSE or a null goal respectively, on the cycles in which the perceptual searches are completed, the functions will return TRUE and will set the new navigation goal position respectively. The Behaviors As stated above, the reaction plan allows the robot to accomplish its goal by interleaving the execution of the runaway, navigation, IR search and stereo ranging behaviors. No set of behaviors is committed to longer than one pulse of the circuit. In this way, the architecture achieves and maintains discrete states by managing continuous activity. The behaviors are discussed in more detail below. unaway Behavior The first behavior is an emergency behavior used for unexpected situations, such as the sudden appearance of an obstacle previously unseen due to specular reflection of the sonar pulses. This behavior is simply an energy minimizing routine (e.g., see Brooks 1986, Arkin 1987). The behavior takes the readings from a 24 sonar ring and a six sonar ring around the robot’s waist and skirt respectively and thresholds them to detect readings which lie within the robot’s safety radius (typically about 0.2 meters). Given danger readings, the behavior then generates a runaway vector which will drive the robot either forward or backward* away from the danger using an inverse square law summation of the sonar ranges. As is shown in the reaction plan (Figure I), this behavior is called whenever there are sonar readings indicating that there is an obstacle in the robot’s safety zone. The NaTigation Behavior The NaT (Navigation Template) navigation (or NaTigation) behavior is based on the use of Navigation Templates (Slack 1990a) for transforming a symbolic representation of the robot’s surroundings into a drive/steer control vector. On each pass through the circuit, the behavior accepts the 24 sonar readings and the current goal position (relative to the robot’s position) as input and uses that information to maintain a navigation plan for moving the robot to the goal position. The navigation plan is updated on each cycle, and thus the behavior will adapt to new goals, recasting current obstacle information into the new plan. The NaTigation behavior uses the sonar readings to maintain a model of the robot’s current surroundings. Because the behavior is implemented in a precomputed circuit language (Rex), a compute-time limit is placed on the number of obstacles for which the system allocates memory resources. For the runs reported here, the system was compiled to maintain up to ten obstacles, which provided our robot sufficient awareness of the environment to accomplish all of the experiments discussed herein. The obstacles are modeled as circles and each can contain up to five sonar readings, one from each of the last 1Though the circuit cycle time is 0.1 seconds, the system cycles from sensors to actuators about three times a second. *The robot employs a synchro-drive drive system; thus depending on the situation, the robot can either move forward away from the danger or back away from the danger which ever is the quickest way out of the situation. 802 Robot Navigation (if (anything-is-too-close) (if (we-know-the-donor-direction) (do action (move-away-from-danger)) (ach find-donor-location) (do anything) )I (maint find-donor-direction))) (defgoalr (ach move-to-goal) (defgoalr (maint find-donor-direction) (if (or (anything-is-too-close) (if (ir-search-has-been-started) (not (there-is-a-goal)) (do action (continue-search)) (we-are-at-the-goal)) (if (and (the-ir-search-is-finished) (do anything) (the-returned-angle-is-no-good)) (do action (move-according-to-NaT-plan)))) (do rpt-ir-failure? true) (do anything)))) (defgoalr (ach retrieve-widget-from-donor) (if (anything-is-too-close) (defgoalr (ach find-donor-location) (do goal (remember-the-current-goal-if-any)) (if (stereo-ranging-is-started) (if (donor-has-been-located) (if (a-range-value-has-been-returned) (ach fetch-widget&go-home) (if (the-range-value-is-no-good) (ach find-donor)))) (do rpt-prism-failure? true) (do anything)) (defgoalr (ach fetch-widget&go-home) (do action (continue-search))) (if (we-already-have-the-widget) (do action (start-stereo-ranging)))) (do goal the-robots-home-position) (do goal (set-goal-as-the-donors-location)))) (goalem (and (prio-and (maint runaway) (ach retrieve-widget-from-donor)) (ach move-to-goal))) igure I. CAPPS psudo code listing of the reduction rules implementing the control structure. The do command sets a value in a vector of outputs. Goalem invokes the CAPPS compiler. Functions such as (move-away-from-danger) or (move-according-@NaTplan) generate appropriate values to be communicated to the robot actuators in the runtime environment. five cycles of the circuit. Again, five readings was sufficient to allow the robot to accommodate the complexity of the environment in our experiments. On the sixth cycle the oldest reading is forgotten and a new reading may be placed into the obstacle representation. Those readings which when added would cause an obstacle to grow too large or which are at a great distance from the robot are not aggregated. This eventually leads to freeing up an obstacle resource (i.e., five cycles without a reading to add to the obstacle) which can then be used to model a new obstacle. Aggregation of new and decay of old information keeps the robot’s model of the local surroundings up to date (Slack 199Ob, Miller and Slack 1991). A grouping algorithm arranges the circles into groups which represent single logical obstacles with respect to the width of the robot, i.e., the robot cannot pass between the circles of a group. Then each group is assigned a spin, i.e., a decision to pass by the group in a clockwise or counterclockwise manner, based on the geometric relationships between the robot, the goal and the group (see Slack 1992). The result is a qualitative plan for moving among the obstacles. For example, consider the situation depicted in Figure 2 taken from an actual outdoor run with our robot3 . The goal position (donor robot) is in the upper left, and a car, moving at a greater relative speed, drove past the robot as indicated by the downward sloping vector. In the figure, the local obstacles fall into three groups: two trivial groups which the robot is to pass in a clockwise fashion and one large group resulting from the side of the car. The latter was initially assigned a clockwise spin because the first set of circles representing the car were detected to the right of the robot’s path. However, as the car moved past the robot, the obstacle group representing the car starts to form a blockade, changing the relationship between the group of obstacles, the robot and the goal. At that point, the NaTigation plan guided the robot counter- clockwise behind the car. It is this ability to make real- 3 In Figures 2 and 4, the positions of the robot and the objects are plotted from the telemetry of the robot’s position and sensors. Bonasso, Antonisse, and Slack 803 Robot’s current Position Trace of robot’s path Figure 2. An example of the robot’s reaction to a car moving across its trajectory time navigation planning decisions which gives the counterclockwise turn to make the shortest turn in the NaTigation behavior its robustness. direction the beacon was last detected. IR Search The basic IR search behavior is to turn the steer motor of the robot and look for IR intensity values values that indicate the presence of the beacon attached to the donor agent. The robot then stops the turn and makes a fine azimuth adjustment to compensate for overshoot. Our IR reader returns a status indicating the signal-to-noise ratio, a beacon number, a deviation angle in azimuth from the robot’s current heading, a deviation angle in elevation (not used) and an intensity (not used). The routine is expected to be polled for the search continuously by the reaction plan even after the bearing is established. Thus, once the search is complete, as long as the IR emissions stay within the field of view of the reader, subsequent requests will yield the same value, or cause the routine to make small turn adjustments, thus providing a rudimentary tracking capability. Stereo Search The first phase of the search is to start a 27c counterclockwise turn, tracking the status code. When 1) a status indicating the best low-noise signal is read and 2) the azimuth deviation changes sign, indicating that the beacon emission has passed the center of the reader, the turn is stopped. If the final position of the robot is not within a set cutoff value, a final turn correction is executed which is the negative of the azimuth deviation. Then the bearing to the beacon is computed and returned. The complexities in developing perception behaviors for our work center around robustness and control switching with the reactive motion of the robot. Since the runaway behavior can usurp the steer control from the IR behavior, the latter must be able to be interrupted and then resume the search. For example, to avoid starting a full turn after an interruption once the beacon has been found, the behavior remembers the robot orientation and position after each successful search. The behavior then uses that information to make either a clockwise or The stereo vision system consists of two synchronized Vidicom cameras mounted on a Zebra pan-tilt-verge control head which feed video data to the PRISM-3 stereo/motion processor. PRISM-3 convolves the video frame with a Laplacian of Gaussian (LOG) operator to extract salient reflective features of the scene despite varying luminance conditions, reads six (software- specifiable) windows from the resulting video image of each camera, and cross-correlates each window of one camera with each of the other. A peak in the resulting array of 36 correlation measures indicates that the corresponding windows may be sampling from the same point in the scene. A disparity measure is computed to sub- pixel accuracy and is used to estimate the range to the point4 . 4 Disparity is how far the cameras must be moved in x and y for the center of each camera to be focused on the same point in the scene. The range is the tangent of half the vergence angle times half the distance between the cameras. 804 Robot Navigation The behavior starts the search by verging at the ground a short distance (usually six feet) from the robot’s base in the direction of the steer motors. An expected range to the ground is computed from the height of the cameras and the angle of the downward tilt under the assumption that the ground is relatively flat. Errors in range are accounted for by the multiplicative and additive errors in camera heighh separation, tilt angle, verge angle, and pixel size. From this point on, when the vision system moves to a new point, it will set its vergence based on the expected range to the ground. Any error which falls outside the range of accountable errors is determined to be a discontinuity from the flat ground plane, i.e., an object is detected (see Figure 3). The cameras are panned left and right in increments that guarantee full coverage of the error envelope of the IR bearing result (usually +/- 2 degrees). The cameras are then tilted up in a step size determined by the minimum size of the object being searched for, and the panning is repeated. The process continues until a range discontinuity is found or a distance cutoff is attained. The ground distance to the discontinuity in the former case or an error flag in the latter case is returned as the result of the search. The routine can be interrupted and restarted, but since that usually indicates that the bearing to the donor agent has changed, the behavior currently saves none of the information it last computed, and starts a new search on each new request. The behavior is competent because it can account for its own mechanical uncertainties, and Strereo cameras because it can overcome the tendency of the head to stick in a down-looking position at steep tilt angles5 . The system was tested in both indoor and outdoor environments, but the following discussion focuses on the more difficult and thus more interesting outdoor environment. Outdoor environments are less structured than the indoors, and the number and types of light sources are not easily known or controllable. The area used for the experiments was a sloping parking lot behind one of the buildings of our organization, populated with cars, people and mobile trashcans which we could position for additional obstacles. On clear days with some overcast, the robot carried out the find and fetch task robustly and repeatedly. It located the Hero, navigated safely among moving people and cars traveling at normal parking lot speeds and positioned itself within the reach distance of the Hero’s arm (+/- 1.5 feet). The Hero then executed a simple reaction plan TV place objects on the robot’s platform using sonar ranging, and an 5 This sticking was due to debris in the gears which affected small angular motion. The behavior tracks expected encoder readings from the motors and invokes a series of increasingly involved unstick routines, the last being “ask a human for a helpful tap”. re 3. Using stereo vergence at expected ranges to detect objects on the ground plane Bonasso, Antonisse, and Slack 805 object-on-board keyboard signal was transmitted to the robot to indicate the object was on board. Then, as shown in the reaction plan of Figure 1, the robot navigated back to its starting position (the remembered starting position becomes the new goal position after the widget is on the platform) where it would station-keep awaiting the next command. As the reaction plan indicates, toggling the object-on-board command caused the robot to alternately navigate to the donor and to the starting position. Figure 4 depicts a typical run. For a donor position 25 feet from the retriever, the total time required to navigate the round trip course was between three and five minutes, depending on the number of obstacles to be negotiated. With IR and stereo search the total task completion time was between ten and twelve minutes, depending on the number of times dynamic obstacles interrupted the sensor searches. NaTigation and Runaway The first two goal reduction rules of Figure 1 above, show that the NaTigation and runaway behaviors are in an exclusive-or relationship, with the runaway behavior taking precedence in the case of a conflict. Due to the robustness of the navigation approach, during execution the runaway behavior is rarely activated, i.e., only when an object suddenly appears in danger proximity to the robot in one cycle. For example, during the run depicted in Figure 4, the runaway behavior was activated only once due to the fact that we deliberately rolled a trashcan within a few inches of the robot in order to block its path. This resulted in the robot backing away from the obstacle until the obstacle was beyond the danger radius and the runaway behavior thus became inactive. At that point, the navigation plan was modified to account for the obstacle and the robot proceeded smoothly towards the goal avoiding the obstacle6 . The limitation of the current approach results from the fact that while the navigation and runaway behaviors are robust within their local scope there is no global memory. As a result, the robot can become trapped in a box of obstacles which number more than the allocated memory resources. This rarely happened in our test runs, but see the conclusions section for our ideas on solving this problem. 6 For the example reported here, the robot’s maximum speed was 0.2 meters per second. The speed is set to be a function of the robot’s distance to the nearest obstacle as well as how well the robot was oriented with respect to the guidance from the NaTigation plan. Given these settings the robot was able to traverse to the Hero in well under two minutes. The overlapping circles throughout this figure show the aggregate of all the local models constructed by the NaTigation algorithm during the trip to the goal. I Runaway behavior activated Coming back Figure 4. A typical parking lot run 806 Robot Navigation Sensor Searches The outdoor limitations of the IR search routine were restricted to the sensor itself. The maximum range we were able to achieve was 25 feet. When the sun was in the background of the transmitter, even on cloudy days, the signal to noise ratio was too low to get reliable readings; a person was needed to serve as a sun block by standing behind the Hero in those instances. When wind gusts rocked the Hero, making the support to the transmitter unsteady, or when too few readings were obtained to sense the plus-to-minus change in azimuth angle, the reaction plan would appropriately restart (retry) the search . The stereo search had to deal with variable luminance conditions due to shadows, cloud cover, and time of day. As well, the flat earth assumption was violated with respect to the zero-slope condition we previously used indoors, and the ground surface (macadam) is coarser than our indoor carpet surface. We manually reset the camera’s f-stops for the luminance conditions, but to deal with the coarser ground texture, we added an automatic LOG size control which decreased the size of the convolution operator with respect to increased ranging distance. Subsequently, the surface coarseness served to provide more textured features, thus improving performance by reducing false correlations. The ground slope limited the effective range of the search only when the robot itself was situated in an area with slope different than that in the visual search path. This work can be compared most directly with recent efforts on the JPL Rover (Miller and Slack 1991). That effort used Reaction Action Packages (RAPS) (Firby 1989) for high-level goal representations and low-level behaviors written in the Alpha circuit language (GAT 1991). Extensive runs of a detailed simulation were conducted along with a partial outdoor run with the actual system, all of which showed the Rover able to negotiate rugged terrain and move robustly to a series of waypoints. A stereo system (Matthies 91) was the primary sensor used to feed a NaTigation planner. Our work shows comparable results using reaction plans and layered competences. The navigation approach is somewhat similar to the gradient summation work of Arkin and others (Arkin 1987), wherein obstacles act as repulsors and goals act as attractors. A major drawback to gradient summation approaches, however, is that there are no plan semantics for making motion decisions (i.e., whether to pass to the right or to the left of an object) based on the strategic goal. Thus, the algorithms often leave the robot oscillating in a local minima. Our approach essentially uses knowledge of the strategic goal to prevent the local minima situations from developing. PRISM-3 is one of a line of stereo-vision processors designed and built by Nishihara (Nishihara 1990) and is an outgrowth of the work on stereo undertaken by David Marr at MIT in the late 70’s and early 80’s (Marr 1982, Nishiham 1984). There is a wealth of related work on active vision (see (Ballard 1991) for an overview), some of the most relevant being the building of visual routines using stereo (Goombs and Brown I991), and the use of visual routines for auto-calibration of the vision system (Bajcsy 1988). Our work is the first we are aware of wherein task-specific routines were developed using frame-rate stereo ranging as a competence. Our experiments have shown that the architecture can scale to more complex tasks given the appropriate granularity of operators, and that the resulting robot behavior smoothly accommodates natural changes in the environment. Because of this, previously reported benefits of this approach -- use of robust behaviors, high-level goal representation, consistent semantics, and ease of programming -- take on a stronger significance. We conclude with a discussion of a number of directions to pursue in this work. They include extending the existing behaviors and increasing the capability of the overall fiid and fetch reaction plan. Because the current stereo search behavior searches out from the robot base along the ground plane, there can be no obstacles between the robot and the donor until this search is completed. This limitation can be changed by searching down from the horizon toward the robot base. Also, though we can improve upon the 23-25 foot range limit of the vergence control, there are fundamental limits to this ranging approach, and longer range searches should be based more directly on shape analysis from the image plane. Ultimately, we want the vision system to recognize as well as determine the distance to the donor agent. The IR range limitations suggest extending the IR search routine to navigate about the area in question looking for IR emissions. This will also allow the robot to find multiple donors to retrieve multiple objects. A solution to the box-canyon problem with the navigation mentioned earlier is to remember configurations of obstacles, thus allowing the construction of a global topological model. Using this information a planning system could adjust the robot’s current goal in order to lead the robot out of trouble (see e.g., Krogh and Thorpe 1986). A more fundamental direction of research which we are pursuing involves exploiting the high-level goal representation to allow for a deliberative planning capability. Our current version of GAPPS provides for STRIPS-like operators to be used by the compiler to regress reaction plans (Kaelbling 1990). These operators provide a representation than can serve as a basis for integration with an asynchronous planning system. Having the deliberative capability would allow the robot to generate new reaction plans to cover situations for which it has no response or when it cannot make useful progress in a reasonable amount of time. Bonasso, Antonisse, and Slack 807 References Arkin, R. C. 1987. Motor Schema Based Navigation for a Mobile Robot: An Approach to Programming by Behavior, in the Proceedings of the IEEE International Conference on Robotics and Automation, Raleigh, North Carolina, pp. 264-271. Bajcsy, R. 1988. Active Perception, Proceedings of the IEEE, Vo178, No. 8, August. Ballard, D. H. 1991. Animate Vision, Artificial Intelligence, v.48, p. 57-86, Elsevier Press,. Bonasso, R. Peter. 1991a. Integrating Reaction Plans and Layered Competences Through Synchronous Control, In Proceedings of the 12th International Joint Conference on Artificial Intelligence. Sydney, Australia, August. Morgan Kaufman. Bonasso, R. Peter. 199Ib. Underwater Experiments With A Reactive System For Autonomous Vehicles, In Proceedings of the 9th National Conference on Artificial Intelligence. Anaheim, CA., July . AAAI Press. Brooks, Rodney A. 1986. A Robust Layered Control System for a Mobile Robot, IEEE Journal of Robotics and Automation, RA-2: 14-23, April. Coombs, D. J. and Brown, C. M. 1991. Cooperative Gaze Holding in Binocular Vision, IEEE Control Systems Magazine, June. Firby, James R. 1989. Adaptive Execution in Complex Dynamic Worlds. PHD Diss., YALEU/CSD/RR #672, Yale University. Gat, Erann. 1991. Taking the Second Left: Reliable Goal- Directed Reactive Control for Real-World Autonomous Robots, Phd Diss., Dept of Computer Science, VPI. Kaelbling, Leslie Pack. 1988. Goals As Parallel Program Specifications. In Proceedings of the Seventh National Conference on Artificial Intelligence, pages 60-65, Minneapolis-St. Paul, Minnesota, 1988. AAAI Press. Kaelbling, Leslie Pack. 1990. Compiling Operator Descriptions into Reactive Strategies Using Goal Regression. TR90-10. Teleos Research. Palo Alto, CA. Krogh , B. H. and Thorpe, C. E. 1986. Integrated Path Planning and Dynamic Steering Control for Autonomous Vehicles, in the Proceedings of the International Conference on Robotics and Automation, San Francisco California, pp. 1664-1669, April. Marr, D. 1982. Vision, W. H. Freeman and Co., NY. Matthies, H. L. 1991. Stereo vision for planetary rovers: Stochastic modeling to near real-time implementation, Technical Report D-8 13 1, Jet Propulsion Laboratory, Pasadena, CA, January. Miller, D. P. and Slack, M. G. 1991. Global Symbolic Maps From Local Navigation, In Proceedings of the 9th National Conference on Artificial Intelligence, Anaheim, California, July. AAAI Press Nishihara, H. K. 1984. Practical real-time imaging stereo matcher, Optical Engineering, 23(5):536-545, October. Nishihara, H. K. 1990. RTVS-3: Real-time binocular stereo and optical flow measurement system. System description manuscript, Teleos Research, Inc., July. Rosenschein, Stanley J. and Kaelbling, Leslie Pack. 1986. The Synthesis of Digital Machines with Provable Epistemic Properties. In Proceedings of the Conference on Theoretical Aspects of Reasoning About Knowledge, pages 83-98. Morgan Kaufman. Schoppers, Marcel J. 1989. In Defense of Reaction Plans As Caches. AI Magazine, lO(4): 51-60. Slack, Marc G. 1990a. Situationally Driven Local Navigation for Mobile Robots, Ph.D. Diss., Dept. of Computer Science, VPI, May, also see JPL Pub. 90-17, NASA. Slack, Marc G. 199Ob. Coordinating Sensing and Local Navigation, In Proceedings of SPIE’s 9th Conference on Sensor Fusion, pages 459-470, Boston, November. Slack, Marc 6. 1992. Computation Limited Sonar-based Local Navigation, In Proceedings of the AAAI 92 Spring Symposium on Selective Perception, March. AAAI Press. 808 Robot Navigation | 1992 | 9 |
1,287 | and Computer Science Department Department of Computer Science Loyola College in Maryland The Johns Hopkins University Baltimore, MD 21210 Baltimore, MD 21218 Abstract In this paper we address the problem of making cor- rect decisions in the context of game-playing. Specif- ically, we address the problem of reducing or elimi- nating pathology in game trees. However, the frame- work used in the paper applies to decision making that depends on evaluating complex Boolean expressions. The main contribution of this paper is in casting gen- eral evaluation of game trees as belief propagation in causal trees. This allows us to draw several theoreti- cally and practically .interesting corollaries. In the Bayesian framework we typically do not want to ignore any evidence, even if it may be inaccurate. Therefore, we evaluate the game tree on several lev- els rather than just the deepest one. Choosing the correct move in a game can be imple- mented in a straightforward fashion by an efficient linear-time algorithm adapted from the procedure for belief propagation in causal trees. We propose a probabilistically sound heuristic that allows us to reduce the effects of pathology signifi- cantly. Introduction Decision-making in the presence of uncertainty is one of the most fundamental problems in Artificial Intelli- gence (common-sense reasoning), Economics, and the Social Sciences [Savage, 1972; von Neumann and Mor- genstern, 1944; Pearl, 1988; Horvitz, 1988; Russell and Wefald, 19891. In this paper we address the problem of making correct decisions in the context of game- playing. Specifically, we address the problem of reduc- ing or eliminating pathology in game trees. However, the framework used in the paper applies to decision making that depends on evaluating complex Boolean expressions. The main contribution of this paper is in casting evaluation of game trees as belief propagation in causal trees. This allows us to draw several theoretically and practically interesting corollaries. * Supported by NSF DARPA Grant CCR-8908092 and AFOSR Grant AFOSR-89-1151 8 In the Bayesian framework we typically do not want to ignore any evidence, even if it may be inaccurate. Therefore, we evaluate the game tree on several lev- els rather than just the deepest one. Choosing the correct move in a game can be imple- mented in a straightforward fashion by an efficient linear-time algorithm adapted from the procedure for belief propagation in causal trees. Given estimates on the accuracy of the evaluation function in a game tree, we achieve drastic improve- ments in the quality of move decisions. We propose a probabilistically sound heuristic that allows us to reduce the effects of pathology signifi- cantly. The paper consists of three parts. In the first part we develop a Bayesian decision procedure to choose correct moves in game trees. The main contribution of this section is in showing that optimal decision-making in game trees is a simple application of belief propaga- tion in causal trees. This belief propagation allows us to derive a simple and computationally efficient deci- sion procedure. We believe that this is a new applica- tion of belief propagation in causal trees. There are, however, two drawbacks in applying belief propagation in game trees. The underlying assumption in Bayesian decision- making is that we have good estimates of all prior and conditional probabilities. In practice, these of- ten are difficult to obtain. The procedure requires evaluating every node in the tree (as in MINIMAX). In practice, for large trees this is impractical. Pruning search trees is an essential component in computer game playing. Therefore, we next propose a simple heuristic decision rule. This rule is motivated by probabilistic considerations, and based on our ex- periments appears to be effective. The rule helps re- duce pathological behavior in “noisy” game trees and in some cases removes it altogether. The rule is based on the following observation. Given a set of witnesses Delcher and Kasif 513 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. for a binary random variable whose underlying statis- tics are unknown, it makes sense to use a weighted ma- jority of the witnesses’ reports to estimate the value of the underlying event. We analyze the error probability of this procedure. Finally, we report the results of our preliminary experiments using the above procedures. We imple- mented our procedure for a one-dimensional version of the board-splitting game. We report very encourag- ing performance results and compare Bayesian analysis with our heuristic procedure. Decision-making in game trees in a probabilistic set- ting has been considered before (for example, see [Fis- cher and Paleologou, 1991; Palay, 1983; Pearl, 1988; Nau, 1980; Russell and Wefald, 19891). Our approach differs, however, in that it relies on evaluating multi- ple levels in the game tree, and uses both rules and heuristics to combine the evidence accumulated by be- lief propagation. Pathology in Game Trees Pathology in game trees is an interesting phenomenon observed by Nau and Beal. (See [Beal, 1980; Nau, 1980; Nau, 1983; Pearl, 19841 for many references on the subject.) It was observed that, given certain as- sumptions, when we search deeper, the performance of a MIN/MAX procedure for choosing the best move ac- tually decreases. On the surface, this appears counter- intuitive and even somewhat paradoxical. When the assumptions that make pathology appear are under- stood, however, it is a perfectly logical behavior. Consider the following simple scenario. You are de- ciding whether to buy stock in XYZ Corporation. Your decision is based on the probability of the stock price rising. You consult n experts, who each have some probability of making an erroneous prediction. Sup- pose you are a very conservative investor and you will buy the stock iff all of the experts say it will go up. Then clearly, as the number of experts grows, the prob- ability of at least one of them predicting the stock will fall, when it actually will rise, grows along with the number of experts. Accordingly, the probability that you will not buy the stock if its price rises (i.e., the er- ror probability) increases. In the Bayesian framework, however, if we know each expert’s probability of error, it is usually better to have more experts. Random Game Trees and Pathology In this section we sketch a formal model of game trees where pathology is present. Our discussion follows Pearl [Pearl, 19841. We assume the reader is famil- iar with the basic notation of computer game playing (Zplayer games) and MIN/MAX trees. Game trees can be defined inductively as follows: 1. The root of the tree (level 0) represents the initial position of the game (with player MAX to play). P 514 Problem Solving: Search and Expert Systems If node X is on an even level A?, its successors on odd level 4! + 1 represent the positions that result after each possible move by player MAX at position X. If node X is on an odd level !, its successors on even level e + 1 represent the positions that result after each possible move by player MIN (the opponent) at position X. The leaves of the tree represent terminal positions of the game and are labelled with either WIN or LOSS (1 and 0, respectively), depending on the outcome (from MAX’s point of view). MIN/MAXing is a standard procedure to decide the correct move. It is generally not possible to evalu- ate the complete MIN/MAX tree to the terminal po- sitions, as its size grows exponentially. Note that if by some magical trick we actually had the correct evalu- ations of all nodes on level d (i.e., we had the values that MIN/MAX would propagate up to these nodes from the terminal nodes) we could do the MIN/MAX from that level on. Therefore, it is a standard pro- cedure to use a heuristic evaluation function to esti- mate the value (strength) of each node on some level d, and then use MIN/MAX to propagate these values to the root. Since this evaluation may be misleading, it is commonly assumed that employing the evaluation function at deeper levels of the tree produces better choices of moves at the root of the tree. A random tree model of a game is a tree where we assume a probability distribution on the labels of the terminal nodes (leaves). In our case, we assume that the value of each leaf is WIN or LOSS with independent uniform probabilities p and 1 - p, respectively. The inaccuracy of the evaluation function on level d is modelled probabilistically by assuming that the error of the evaluation function Eval on level d is given by the probability pe given by Pe = Pr(Eval(X) = WIN~X = LOSS) = Pr(Eval(X) = LOSS~X = WIN) That is, we assume that the evaluation errors on level d are distributed uniformly with probability pe. In other words, pe is the probability that the evaluation function on level d returns the incorrect result. Our results easily generalize to the cases where the one- sided probabilities of error are not the same and where pe is a function of d. Generally, as one searches deeper the probability of error decreases. That is, pe is the function of d. Our analysis in the next section applies to this case as well. Given the model described above, pathology arises [Nau, 1980; Pearl, 19841. N amely, when the evaluation function is employed deeper in the tree, the cumulative effect of errors may offset any increase in the accuracy of the evaluation function. Note, that this model pos- tulates two fairly strong independence assumptions: 1. Independence of WIN’s and Loss’es of adjacent nodes on the terminal level. (Root) 2. Independence of the results of the evaluation func- tion at different nodes on level d (i.e., independence of the errors of adjacent nodes). For proofs and further information on pathology see Nau [Nau, 19801 and Pearl [Pearl, 19841. However, pathology arises in practice even when assumption 2 is removed (for examples, see the experiments section below). It does not seem to be a problem in many real games such as chess, checkers and others. A rationale for this behavior can be found in [Pearl, 19841. Game ees as Bayesian Networks When making decisions in the presence of uncertainty, it is well-known that Bayes rule provides an optimal decision procedure, if we are given all prior and con- ditional probabilities. In this section we show how to model decision-making in games as belief propagation in causal trees. The result gives us a simple and effi- cient procedure to derive optimal decisions. We model each node in the game tree as a binary random variable whose values are WIN and LOSS. At any given node, choosing the correct move in this model is identified with finding the successor node that has the highest probability of being a WIN. Under this assumption, our task is to find the probability of each successor of the root node being a WIN node, given all the evidence that we have. Our evidence takes the form of an evaluation func- tion that we can apply to any node in the tree to esti- mate whether it is a WIN or LOSS node. More precisely, with each node X in the game tree, we associate an- other random variable X’ that represents the value of the evaluation function at node X. Thus, in general we assume that, instead of evaluating the game tree on only a single level d, we can evaluate it on all levels 1,2, . . . , d. The evaluation value at X’ is considered evidence for the actual (unknown) value of node X. Note also that the evaluation values of nodes that are ancestors and descendants of node X in the game tree may strongly influence our estimate of the true value of node X. All the conditional dependencies, therefore, can be captured in a causal tree. For an exact definition of such a tree see Pearl [Pearl, 19881. In such a tree, a directed arc from node X to node Y indicates that we know the conditional probability distribution Pr(Y IX). Pearl gives an efficient procedure to compute the be- lief distribution of every node in such a tree. Most importantly, this procedure operates by a simple prop- agation mechanism. In our case, we wish to compute, for each successor node of the root node of our game tree, the probability that it is a WIN, given all the evidence ( i. e., the values of the evaluation functions) contained in the tree down to some given depth d. Figure 1: A fragment of a typical game tree. Figure 2: The corresponding causal tree. ropagation in Game ees In this section we describe the basic ideas used to per- form the Bayesian analysis of the tree by an efficient belief-propagation procedure. We describe the evalu- ation in game trees, where the value of each interme- diate node can be expressed as the Boolean NAND of its immediate successors. Our technique generalizes in a straightforward fashion to a tree with an arbi- trary Boolean function at the intermediate nodes. For simplicity, we sketch only the main ideas in such an evaluation. Consider a typical game tree as in Fig- ure 1. The causal tree associated with it is shown in Figure 2. Our procedure evaluates the two probabili- ties that x 1 = WIN and 22 = WIN given all the available evidence. Without loss of generality consider X1. Following Pearl, the belief distribution of xl, defined by Bel(x1) = Pr(Xl jEbelowz:1 Y Xi) where E belowxl denotes all evidence nodes (i.e., eval- uation values) contained in Xi’s subtree, can be com- puted as follows: Delcher and Kasif 515 BeI = oPr(xiIx) . c J+(xI lw , wdBe@l)Be@2) 74lrU2 where cy is a constant that makes the beliefs sum to one. Note that we can assume that the values of Bel(ui) and Bel(u2) in this equation have been computed re- cursively by the same calculation. The base case for this recursion occurs at the deepest level of the evalua- tion where, in the absence of any evidence below these nodes, we use the prior probabilities. For the NAND function this calculation can be seen from the following table, where we denote pr(ul = lIEaetowu1, u;) and Pr(w = l(Ebelowu2, Ui) bY PUl and Pu,, respectively, and pe denotes Pr(x’l # x1): Probability O t1 PU,>( l Pt,j,)Pe - - 0 0 1 1 (1 - P,,)(l -pu,)(l - pe) - 0 1 1 ; C1 PU,)P?.J,Pe t1 - PUl)PUQ( 1 - pe) ; PUl (l PU2)pe - 1 0 1 P”lC1 - PU2)( 1 - pe) 1 1 0 ; Pu1P%(l -Pe) PUI PU9Pe Thus, for example, if xi = I then Bel(xl = 1) = CK [Cl - PU,)(l - Pu,)(l - Pe) + t1 - PUl)PU2(1 - Pe) + PUI C1 - Puz)(l - Pe)] Bel(xl = O) = cUpulPu2pe where o is simply chosen to make these values sum to one. A similar calculation applies for any Boolean function. Thus, we have the following: Proposition 1: The probability distribution of X1 is accurately modelled by the causal tree. Proposition 2: (Pearl) Bel(xa) can be calculated in linear time. A Heuristic Procedure As mentioned in the introduction there are two draw- backs to the above procedure. While it provides a very effective way to make decisions in game trees (see the experimental results in the next section), it requires a complete evaluation of the tree. This is generally im- possible. Pruning (such as alpha-beta) isan essential component of game tree evaluation. In addition, the Bayesian procedure requires knowing all prior and con- ditional probabilities. While, we can perhaps deal with the latter problem by using estimates of the probabili- ties ( CJ the full version of this paper), the former prob- lem appears to be fundamental. In fact, we believe that developing pruning mechanisms for very large Bayesian systems is a challenging and important open question. In this section we propose a “quick fix” to the prob- lem. Consider the following strategy. Rather then per- forming the belief propagation sketched in the previ- ous section, we still use the standard pruning methods such as alpha-beta. However, we perform the evalua- tion more than once, each time searching to a different depth in the tree. Let IUi denote the move chosen by the ith evaluation. Then the move we shall select is the one that represents the majority vote of the Mi’s. Evaluating the tree on several levels is not a new idea. This is precisely the strategy employed in ex- isting chess programs, namely iteratively deepening alpha-beta. The motivation there is to use the pre- vious levels to determine node ordering to improve the performance of subsequent deeper searches. However, we actually use the results of the shallow-level evalua- tion in choosing the move. This idea is motivated by probabilistic considerations. If we consider each one of the evaluations an independent Bernoulli trial, suc- ceeding (i.e., giving the correct result) with probability p, we actually can derive bounds on the error probabil- ity of this evaluation. The analysis is given in the full version of the paper. The experimental results given below support this intuition. Experiments In this section we apply the algorithms described in the previous section to the one-dimensional board-splitting game. The most important aspect of these results is that the approach outlined above works not only for an idealized model but also for a reasonable evaluation function. Board-Splitting Game The board-splitting game was suggested by Nau be- cause it accurately models the assumptions that ex- hibit pathology in game trees. Most importantly, it exhibits pathology even when a plausible evaluation function is used, rather than using randomly generated noise to pollute the propagation of MIN/MAX values. We describe a one-dimensional version of the game. We start play on a Boolean linear array of length 2”. We then randomly distribute ones and zeros to each cell on the board, choosing one and zero uniformly and inde- pendently with probabilities p and 1 - p, respectively. Players alternate turns. On his turn, a player splits the board exactly in the middle and chooses either the left or the right board. The game is continued on the chosen board, with the other side being discarded. The first player (MAX) wins iff the final remaining single-cell board contains a one; otherwise, MAX loses. It is clear that the number of ones in a given board is strongly correlated with the probability of MAX winning. There- fore, we use the function SUM, which simply sums the values on a given board, as a heuristic function in our experiments. Note that this function creates a strong 516 Problem Solving: Search and Expert Systems 50 45 40 e 0 t 35 ; 30 25 20 _..._... . . ____r___? /-----~ .+. I... .,...“. “““;;;:.:::‘:.::,..~Evaluation at level 8” ,/ ““..+ .__....__ . .:* . . 4’ .... . . . . __ ____ __ _.. . . . . . . . ..- . . . + x. -._. ‘0 Evaluation at level 4 . . . . . . _ -=;... . ,~ ___-- dtb- ---- 8’-- ‘-.‘p”- .-a-.-- -m’-- /SW:,; ‘-• /’ . . . . .& . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . _.~:.*“y...~x . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A_--- ,&----&’ ---_ -A&-~‘--A/--~--‘._r /’ Majority evaluation 0.k Ok6 Ok7 O.&t3 O.k.59 Oh0 0.61 Oh2 Oh3 Oh4 Pr (WIN) at Leaves Figure 3: Results obtained from 10,000 trials of the board-splitting game on a depth-10 tree using the SUM heuristic evaluation. dependency between the evaluation of parent and child nodes in the game tree. Experimental We performed two types of experiments. First, we ex- perimented with the SUM evaluation function. Second, we experimented with a noisy evaluation function that more closely matches the model where pathology oc- curs. Each experiment with the SUM was conducted as follows: In phase I, we generated a random board with 2n cells (i.e., a depth-n game tree). Using stan- dard MIN/MAX propagation we computed the values at each of the two children of the root, Left and Right. In phase II, we evaluated the tree to a specified level d < n and applied the evaluation function to each node on that level. Then, again we used MINIMAX to prop- agate those values to Left and Right. Finally we com- pared the results of the two phases of the experiment. Repeating the above procedure for a specified number of trials, we incremented an error counter as follows: 1 Level-d Evaluation: 1 Level-n Evaluation: 1 Error1 Left 1 Right Left < Right Yes Left < Right Left 2 Right Yes I Otherwise 1 No 1 To compute the majority heuristic, we computed the values of Left and Right by separately evaluating the tree to each of several successive depths. Then we chose the move recommended by the majority of the separate evaluations. The error was computed as above. Some typical results are shown in Figure 3. Note, that aggregating evidence using the majority heuristic outperforms the decision made by any of the individual evaluations. Additionally, the graph clearly shows the quality of our heuristic decision degrading “” I 45 _......................................................................................... :.:.:- . . . . . .* Evaluation at level 8 .**_.... +--.“” 4(-J- . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . : ,.d L . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ./+” I 35 _....I. r Evaluation at level4 .:...... :.I:::‘.. . .k’ . . . . . . . . . . . . . . . . . . . . . . . . . . . ,>d . . . ..__._.... A’ 1 2 30 . ...,:.:: .________.... . . . . . . ,/.I . . . . . . . . . . . . .._._____ e . . . . -a--- L 25 I . . . . . . . . . . . . . . . . . . . . ;: . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . _. .#&..L:~ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4:::‘:. ..-#..r.:.:: . . ,A Majority ewb8tion 20 . ,.+:.I . . . . . .._....... 1 -I , , 5 r* . . . . . . . . . . . . . . . . . . . . . . . . ,< . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . :.,A . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 I , * 1 ....... .&.:“. ev*adon .......... .......... ......... ,L __ ...... / ._ ........ !+e~an I 5- __-- 0 i 0.05 0.10 0.15 0.20 0.25 Pr (Evaluation Function Error) Figure 4: Results obtained from 10,000 trials of the board-splitting game on a tree of depth 10, using p = Pr(termina1 node = WIN) = 0.58. as the frequency of ones increases. This behavior can be predicted from the probabilistic model. In these preliminary experiments we have not yet incorporated this information in the decision rule. The experiments with inserting random noise were performed similarly, except that on level d we ran- domly perturbed the correct evaluation propagated from the terminal nodes by the MIN/MAX procedure. In other words, for a given evaluation error probabil- ity Pe7 we would flip the correct value of a node on level d with probability pe. In this fashion, for each node x, we generated the evidence node x’ such that R-(x’ = 11x = 0) = Pr(z’ = 01x = 1) = p,. We re- peated this on several levels and also compared the er- rors with the majority heuristic. The Bayesian analysis was performed using the belief propagation described earlier. Typical results are shown in Figure 4. We also compared the performance of our Bayesian analysis us- ing evidence from a single (bottom) level VS. evidence obtained by board evaluations on multiple levels. Some typical results are shown in Figure 5. iscussion It is clear that when the evaluation function used by our program is inaccurate, the MIN/MAX procedure does not provide an effective way to make optimal choices of moves, and pathology occurs. Given an ac- curate probabilistic model of the game we can deter- mine the move that is most likely to win by a com- plete Bayesian analysis of the evidence generated by our board evaluators applied to multiple levels of the game tree. In this paper we have pointed out that this evaluation can be done by adapting the known belief-propagation method used in causal trees. As ex- pected we have shown experimentally that this yields Delcher and Kasif 517 -- I 45 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ~&.~..~~~r.:Y”- __-- -IISaa~tlgn at s _ ................................. ./ .:. .......................................................... .......... I ........................... ;;::,.,;. ........ 0.05 0.10 0.15 0.20 0.25 Pr (Evaluation Function Error) Figure 5: Results obtained from 10,000 trials of the board-splitting game on a tree of depth 12, using p = Pr(termina1 node = WIN) = 0.58. a very effective decision-making mechanism. Most im- portantly, it significantly reduces pathology. Pearl has pointed out [Pearl, 19841 that in the presence of a noisy evaluation function we may benefit from using Bayesian product-propagation rules to propagate prob- abilistic estimates of the quality of positions on the bottom level. We have extended this technique relying on the fact that in a probabilistic setting it is better to consider all available evidence. We also have pointed out two drawbacks of Bayesian analysis in the context of game trees. First, the analysis is sensitive to the degree of accuracy of the probabilities involved in the computation. Second, and most important, like the MIN/MAX procedure, we would need to generate very large trees for a typical popular game. It would be in- teresting to develop pruning strategies for probabilistic game evaluation. In view of the drawbacks, we have proposed a heuris- tic strategy that simply takes a vote from indepen- dent iteratively deepening alpha-beta evaluations of the game tree. The procedure then selects the move recommended by a (weighted) majority of the evalua- tions. This procedure performs well in our experiments and, in fact, performs better than any of the separate evaluations from which it is computed. References Beal, D. 1980. An analysis of minimax. In Clarke, M. R. B., editor 1980, Advances in Computer Chess 2. Edinburgh University Press. 103-109. Fischer, M.J. and Paleologou, S. A. 1991. Decision making in the presence of noise. Technical Report YALEU/DCS/TR-875, Yale University. Horvitz, E. J. 1988. Reasoning under varying and uncertain resource constraints. In Proceedings of the Seventh National Conference on Artificial Intel- ligence. 111-116. Nau, D. S. 1980. Pathology on game trees: Summary of results. In Proceedings of AAAI-80. 102-104. Nau, D. S. 1983. Pathology on game trees revisited and an alternative to minimaxing. Artificial Intelli- gence 221-244. Palay, A. 1983. Searching with Probabilities. Ph.D. Dissertation, Carnegie-Mellon University. Pearl, J. 1984. Heuristics. Addison-Wesley. Pearl, J. 1988. Probabilistic Reasoning in Intelligent Systems. Morgan Kaufmann. Russell, S. J. and Wefald, E. II. 1989. On optimal game-tree search using rational meta-reasoning. In Proceedings of the Eleventh International Joint Con- ference on Artificial Intelligence. 334-340. Savage, L. J. 1972. The Foundations of Statistics. Dover. von Neumann, J. and Morgenstern, 0. 1944. The- ories of Games and Ecomomic Behavior. Princeton University Press. 518 Problem Solving: Search and Expert Systems | 1992 | 90 |
1,288 | Walter C. Hamscher Price Waterhouse Technology Centre, 6s Willow Road, Menlo Park, CA 94025 ha.mscher@tc.pw.com Abstract A domain model in SAVILE represents the steps involved in producing and processing financial data in a company, using an ontology appropriate for several reasoning tasks in accounting and auditing. SAVILE is an implemented program that demon- strates the adequacy and appropriateness of this ontology of financial data processing for evaluating internal controls, designing tests, and other audit planning related tasks. This paper discusses the rationale, syntax, semantics, and implementation of the ontology as it stands today. Motivation We wish to develop knowledge-based systems for au- ditors. Auditors issue opinions on the fairness of the financial statements of their clients. Although finan- cial statements consist of numbers that are typically summations of thousands of other numbers, auditors need not worry about the numbers per se. An auditor can instead think about the system that produced th.e numbers: financial records, documentation, accounting policies and procedures, accounting personnel training, security and a host of other non-numeric information. Hence, knowledge-based systems to support auditors could benefit from a foundational representation for data processing systems broadly construed to include both manual and computerized processing steps, while simultaneously suppressing details that are of no audit significance. Making these ontological commitments in a fresh do- main and getting them right is always a difficult un- dertaking; it is a distinct enterprise from selecting the syntactic form of the knowledge. This paper presents a case study of how these ontological commitments are being made in a principled way for a domain alien to most AI practitioners. Approach and contributions There are three key ideas behind the ontology and its realization in the SAVILE implementation: supporting simulation, exploiting existing ontologies, and trans- forming models to perform multiple tasks. Supporting simulation Auditing tasks are difficult in part because auditors must understand the relation- ship between a perturbation in an accounting system and its effects, which can be highly indirect because ac- counting systems are complex. Fortunately, accounting systems are composed of many interacting processing elements that from an audit standpoint are conceptu- ally simple, and this decomposability suggests that a model-based approach is appropriate: the user would build a computational model of the client system to automate the analysis of the effect of local perturba- tions. Simulation is one of the fundamental analysis techniques from which others can be derived. Thus an analogy with digital circuits composed of many Boolean elements and analyzed through simulation and other techniques is valid, relevant, and useful to keep in mind. Although a model-based approach has been proposed for financial tasks before, the models have generally been of relationships between variables representing fi- nancial and microeconomic quantities [Bouwman, 1983, Hart et uZ., 1986, Bailey et al., 1990, Bridgeland, 1990, Hamscher, 1991a]. SAVILE is one of the first programs to take this approach with an explicit model of data processing systems. Exploit iug exis tiug out ologies A formidable ob- stacle in this enterprise has been to develop an ontol- ogy of appropriate concepts. Indeed, formulating such an ontology in any fresh domain creates a “chicken and egg” problem: the tasks cannot be properly formulated until a,n ontology exists, but the concepts of interest and appropriate levels of detail in the ontology depend on the tasks. Also, an effective model-based strategy relies on the ability to acquire the models from domain experts, so that it is crucial to use concepts natural to potential model builders whose expertise lies in ac- counting, not computer science. SAVILE contributes a set of concepts that merges and extends three ontologies for describing accounting systems developed for) accountants and auditors themselves. (and Supporting multiple tasks As a practical matter the effort involved in building a model like that in SAVILE must be amortized over multiple tasks. The Hamscher 519 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. promise of reusable models is always implicit or ex- plicit in model-based reasoning research, but experi- ence has shown that for computational efficiency, dif- ferent tasks require different models. For an exam- ple, compare representations of digital circuit behav- ior for diagnosis [Hamscher, 1991b] and for test genera- tion [Shirley, 19861. SAVILE incorporates this lesson and takes the approach of using one model for interacting with model builders and users, while performing auto- mated transformations from this model into more effi- cient models prior to performing each task. SAVILE thus demonstrates a practical approach to model reusabil- ity grounded in the experience of previous model-based reasoning efforts and this constitutes another contribu- tion. The SAVILE ontology is a moving target in an ongoing project having a number of different goals. The basic vocabulary is stable, having not changed in months, and forms the majority of this report. There is cur- rently a fully implemented approach to both the task of evaluating internal controls [Hamscher, 19921 and to the planning of audit tests. A model acquisition envi- ronment has been defined, with an implementation in progress and close to demonstration. Other tasks such as risk assessment remain to be fleshed out. Each of these tasks and its relationship to the representation will be discussed later. Representing accounting systems Accounting systems process accounting data in the form of paper and electronic records, through activities that create, use, alter, and store those records. Examples of records include an invoice, a receiving report, an en- try in a database of receivables from customers, and a weekly sales summary. The “trail” that is left behind in the records by these activities is the raw material that auditors work with when executing an audit at the end of the year. A record will thus be a central concept in an ontology for modeling accounting systems that is meaningful to auditors. There are two general properties of accounting sys- tems that suggest other key concepts. First, they tend to preserve information, in the sense that modification or outright destruction of records is not nearly as com- mon as copying and filing records to allow recovery. The concept of a repository will refer to a set of records of the same type, often all physically in the same place (a basket, a folder, a receiving dock) but more generally to mean a set of records all in the same processing state. Second, records supporting separate economic trans- actions do not generally interact with one another ex- cept to be collected together into summaries and so forth. Hence it is usually possible to understand the behavior of the system by postulating a prototypical transaction, following its processing in isolation, and generalizing. Auditors seem to have no difficulty artic- ulating the accounting processing steps that occur in the course of executing and recording a normal trans- action between two economic entities, such as ordering, receiving, then paying for goods. The concept of an action is something that a person or other agent does to a record, such as creating it, copying it, compar- ing it to another record, or putting it into a repository. An activity is a sequence of related actions performed by a group of related agents; for example, “cash dis- bursements” is an activity in which invoices are both examined for validity and paid by issuing checks. Figure 1 shows the activities and repositories in a model (P&Pl) of a typical “purchases and payables” system. P&P1 processes purchases of goods from ven- dors and ensures that the goods are received, payables recorded, and vendors eventually paid. Records flow downward through the diagram. Each gray boxed item in the graph is an activity. Each other item is a reposi- tory, with a nearby icon distinguishing paper from elec- tronic media. The Stores activity, for example, has two input and two output repositories, each a set of pa- per purchase orders (On-Order-File, Filled-POs) and a set of electronic receiving reports (Rr2 and Rr3). Each repository is an input of at most one activity, and an output of at most one. Crucial steps in an accounting system are those that credit and debit the accounts. The repositories in Fig- ure 1 that are marked with “boxed T” icons repre- sent collections of credits Cr and debits Dr. Different systems interact, and the boundaries of a system are roughly determined by a single principal account; in this example the system P&P1 produces both credits and debits to the Payables account; the “cash” system would produce credits and debits to the Cash account, and so forth. This set of concepts and the others introduced be- low merges and extends existing ontologies. It ab- stracts away many details about the system imple- mentation as computerized and manual steps, to make explicit the information and steps that are relevant for auditing. The primary source was an experimen- tal program called TICOM designed to support a cer- tain class of queries about actions [Bailey et al., 1985, Bailey et al., 19891. A secondary source was guidance materials called AGS written within Price Waterhouse for the use of audit staff. A third ontology SEADOC used by a different accounting firm has important simi- larities [Elliott, 19831. Descriptions in accounting text- books also use a similar level of description. All of this provides evidence that the basic concepts are sound if not universal. Syntax These concepts are embodied in a language SPLAT: SAVILE Programming Language Attributed to TICOM. Syntactically, this is a set of class definitions in a frame language JOSIE [Nado et ul., 19911. Terms meant to de- note classes in SPLAT will be written in this font. For ex- ample, each of the basic concepts (record, action and so forth) is a class. SPLAT provides nine record classes such as invoice, order, purchase order, and check, each with a set of fields such as amount, vendor, and payee. Bi- 520 Problem Solving: Search and Expert Systems Purchasea And Payables Purchase-Or&-s 1 $$$ I D ::= On-Or&r-File f$$@) Filled- - Payable11 0-s Pnventori&l-Drs rs Figure 1: A Purchases and Payables System (P&Pl). nary relationships among classes and individuals, such as the input and output repositories of activity stores, are implemented as slot relations. Semantics The semantics of activities and the actions of which they are composed are an elaboration of Petri nets, supporting an interpreter that does event-driven sim- ulation. Records arrive in repositories, and when all of the input repositories of an activity have match- ing records, the activity fires and executes a sequence of actions. Typically the actions will have the effect of putting records into output repositories, thus firing other activities. This is an elaboration of Petri nets in the sense that activities may consist of complex se- quences of actions and the “tokens” are now structured objects (records) that maintain their identity as they change state (move from one repository to another). Actions Table 1 shows the current vocabulary of normal actions. Seven of these are inherited from TICOM, the remain- der are new. Action sequences are written as programs . .. q :... . . . . . ;:. :.., .:.:. .:.: .... q :.: :.:.: .. :.. :. : . . of an imperative programming language with all state- ments of the form action argument”; the arguments are dereferenced when the activity is fired. Dereferencing is context sensitive, in the sense that a repository ar- gument can specify eit,her the actual repository or the type of record it contains. For example, here is the action sequence of the Stores activity: Wait-for Purchase-Order Receiving-Report Ensure-Equal Purchase-Order Receiving-Report Put Purchase-Order Filled-POs Put Receiving-Report Rr3 First, a matching purchase order and receiving report arrive at the input repositories (the Wait-for). Next, each pair of fields that the two records have in common is tested for equality, and if any discrepancy occurs it is corrected (the Ensure-Equal). This represents the effect of accounting personnel reviewing and correcting dis- crepancies. An ensure-equal action is an example of an internul control: an action that does not produce any new information itself, but is only intended to detect problems in exist,ing information. Then, the purchase order is put into the repository Filled-POs and the re- ceiving report put into Rr3. amscher 521 assign (field destination-record) (field source-record) Put the contents of the source record field into the destination record field. compute (field destination-record) &rest arguments Assign to the destination record field a result that depends in some way on the arguments. create-empty record record-class &optional source-record Create a new record of a certain class and indicate that it was derived in some way from the source record. create record record-class &optional source-record Create a new record and assign all of the fields that it has in common with the source record. copy source-record record Create a new record that is a copy of the source record. credit or debit record account Use the “amount” field of the record to create a new debit or credit record in the account. post record debit-account credit-account Perform both a credit and debit operation to the appropriate accounts. ensure-equal first-record second-record Check that all of the fields that the two records have in common agree, and repair the problem if they do not. get record repository Extract a record from the repository put record reposit0 y Move a record into the repository. transfer record activity Move a record to another activity by putting it into an intermediate repository. sequence &rest actions Perform each of the actions. wait-for-all &rest repositories Get a matching set of records (that is, they have a common source), one from each repository. monitor-buildup repository &rest other-repositories If there is a record in the repository, periodically check the other repositories for matching records, and repair the problem if they do not appear. wait-for &rest repositories Monitor the buildup of records in all repositories, and wait for a match. Table 1: SPLAT Action Vocabulary. Some actions can be “macro expanded” into a se- quence of other actions. For example, the action Copy Rrl Rr2, meaning “make a copy called Rr2 of the record Rrl,” expands into a sequence including a create and several assign actions, one for each field in the record Rrl. Actions that do not expand are primitive. Potential mistakes in, omissions from, or deliberate changes to accounting procedures play a key role in the analysis of a system by an auditor. These are called activity failures in SAVILE; specifically, each action is associated with one or more possible failures. SAVILE enumerates the set of possible failures in an activity by local substitution in its action sequence; each action is replaced in turn by each of its possible failures. For non-primitive actions, expansion is performed first, and then the failures are enumerated. SAVILE is thus able to enumerate the potential failures in each activity based only on the SPLAT behavior description. This is a good and important property because it means that the au- ditor does not have to enumerate the possible failures, but need only provide a description of the correct be- havior of the system. Model acquisition Part of standard audit methodology includes an annual systems update in which the audit planner documents the organization of the client accounting systems, or, more typically, updates the documentation prepared the previous year. Existing software to support this includes a flow graphing program which allows the user to draw pictures of repositories and activities and to write narrative descriptions of the actions performed in each activity. However, having produced this doc- umentation, no existing software uses this information about the way the client system is organized to assist in the remaining task of analyzing its audit consequences. The potential benefits of a SAVILE model are thus sub- stantial. The key difference between what audit planners al- ready do and what SAVILE requires is the formalization of the knowledge about repositories, the records they contain, and the actions taken in each activity. There are several reasons to believe that this additional cost will not present an unacceptable burden. First, the level of abstraction in SPLAT is very high and uses concepts and terminology familiar to anyone with an undergrad- uate accounting background. Second, SPLAT is highly constrained. For example, given a fixed set of input and output repositories for an activity, the set of meaning- ful actions is restricted enough that an intelligent editor might be able to construct a reasonable guess at an ap- propriate action sequence. Third, it is rare to encounter a novel accounting system involving novel record types and activities; most are minor variations of standard types and structures, and a client model could prob- ably be produced substantially via copy and edit. A graphical interactive model acquisition environment is currently under development to see whether these intu- itions are right. 522 Problem Solving: Search and Expert Systems ary of the representation test for mistakes in previous processing steps; the prob- lem is to establish whether a given failure is detected by any control. In the P&P1 example, of the 28 significant failures only 14 are undetected by controls. SAVILE has a foundational representation for data pro- cessing systems that exploits existing terminology and uses a level of detail not substantially different from what practitioners already provide. The ontology relies on the fact that accounting systems are composed of many interacting actions that are each simple from an audit viewpoint. The user builds a model of the client system to allow automation of the analysis of the effect of local perturbations in the system, and graphical in- teraction is always done with respect to this model no matter what the task. Tasks SAVILE is oriented toward audit planning (hence the name: detailed audit plans are, in audit jargon, “tai- lored” to the client, as done by the pricey London hab- erdashery Savile Row). A strategy for audit planning can be formulated in SAVILE as the following series of subt asks: Assessing risk Some failures are more likely than others, and the auditor must ensure that the plan ad- dresses them. The risk of failure for a given action depends on factors such as its complexity, whether the data used change frequently, whether it is man- ual or automated, and so forth. Factors that might increase the risk of a given failure can already be systematically generated from SPLAT. These factors also have relationships to one another that are outside the current SAVILE ontology; knowledge-based risk as- sessment systems already exist to provide a basis for this extension [Dhar et al., 1988, Boritz et al., 1989, Peters, 19901. Significance Failures vary in their audit significance. Some have virtually no audit significance and can be filtered out of further consideration; for example, pur- chase orders that never get sent to a vendor do not make the financial statements incorrect. Conversely, a failure to post a credit to Payables would result in the final balance being understated, which could have audit significance depending on the total amount in- volved. In the P&P1 example, there are 40 possible failures but only 28 are significant under this criterion. In the causal network derived for the control evalua- tion task (discussed below) the impact on the financial statements of each failure is found by examining the set of repositories reachable from it in the causal network. This is a useful qualitative filter, and including the re- ported year end balance in each account would permit fine grained judgements as to relative significance. Evaluating controls Having focused on likely fail- ures with audit significance, some can be filtered out of consideration because they are detected by internal con- trols. Every accounting system contains controls that In SAVILE, a failure causes either a loss of records or propagation of corrupted records; downstream control actions such as ensure-equal and monitor-buildup detect the failure by detecting a discrepancy between the lost or corrupted record and other records. SAVILE enu- merates the possible failures from the SPLAT model, in- serts the failures, and simulates the movement of typical records through the system. The simulation results are abstracted on an activity-by-activity basis into a causal network that (i) suppresses details about records, fields, and normal execution order and data flow (ii) makes ex- plicit the causal relationships between underlying fail- ures and their symptoms in repositories downstream and (iii) embeds the assumption that any single trans- action can be affected by at most one non-control failure (but any number of failing controls can still occur dur- ing a single transaction, and many distinct failures may each perturb different transactions). This abstraction reduces the problem of finding the controls that detect a given failure to that of finding a path in a directed graph [Hamscher, 19921. Design of substantive tests The final audit plan should test the failures surviving the above filters. Each substuntive test in the plan involves examination of a sample of recorcls for evidence of failures. This is expen- sive in staff time and should be minimized; however, all testing must be completed within a short period after the end of the year, so planning for coverage of potential failures is equally important. The initial problem is to design a substantive test ca- pable of detecting instances of a particular failure. For example, suppose that the failure no-put purchase-order filled-pos is to be tested for. Intuitively, one way to test for this is to examine a sample of records that were each expected to be paired with a purchase order; in the P&P1 example, a sample of receiving-reports extracted from repository rr3. These receiving reports would then be traced to their matching purchase orders in filled- pos. To construct this test, SAVILE first transforms the model into dependencies among the fields of records in different repositories. For example, the action copy rrl rr2 in the Receiving activity means that all of the fields in the records of rr2 depend on the fields in records of rrl. This transformation suppresses, among other in- formation, the order of execution of actions. It makes explicit the actions that need to have succeeded in order for the test to succeed, hence it makes explicit the fail- ures that the test could detect. SAVILE then performs a kind of path sensitization [Bennetts, 19821 within these dependencies. Iii path sensitization, the goal of test- ing a particular action is decomposed into the subgoals of sensitizing the failure (working upstream toward a sample of records that were its “input”) and propagat- ing the result (working downstream from a sample of Hamscher 523 records that were its “output”). Each test designed for each (unfiltered) failure covers a small set of failures. Planning an audit then reduces to finding a set of tests to cover them all. Finding a minimal cover is intractable in principle, but probably acceptable in practice because of the modularity of sys- tems and the ability of path sensitization to produce narrowly focused tests. Finally, many of the substan- tive tests have steps in common, and for efficiency SAV- ILE merges them where possible. In the P&P1 example, there are 45 possible tests to cover 14 failures, but six of the tests cover all the failures and SAVILE subsequently merges these six into just two (complex) tests. Conclusion SAVILE demonstrates a new model-based approach to support auditing tasks. The foundation of this ap- proach is an ontology for modeling financial data pro- cessing systems with ancestry in the literature of do- main experts and supporting a plausible model acqui- sition strategy. SAVILE also suggests a practical ap- proach to reusable models, grounded in the observation that each task may require transformation into an in- termediate representation, substantiated by the use of a single model both for control evaluation and audit planning. Acknowledgments Maureen McGowan supplied domain expertise, includ- ing detailed analysis of the rationale behind real audit plans. Jim Peters and Andrew Bailey pointed me at accounting research literature on internal control eval- uation. Bob Nado supported JOSIE. Beau Sheil helped refine many ideas in SAVILE. R. Michael Young imple- mented the SAVILE user interface and helped bludgeon a reluctant CLIM into producing PostScript output for Figure 1. References [Bailey et al., 19851 A. D. Bailey, G. L. Duke, J. Ger- lath, C. Ko, R. D. Meservy, and A. B. Whinston. TICOM and the analysis of internal controls. The Accounting Review, LX(2):186-201, April 1985. [Bailey et al., 19891 A. D. Bailey, K. S. Han, R. D. Stansifer, and A. B. Whinston. The advanced inter- nal accounting control model using a logic program- ming approach. Working Paper of 7/20/89, 1989. [Bailey et al., 19901 A. D. Bailey, Y. Kiang, B. Kuipers, and A. B. Whin- ston. Analytical review and qualitative and causal reasoning in auditing. Draft of 4/15, 1990. [Bennetts, 19821 R. Bennetts. Introduction to Digital Board Testing. Crane Russak & Company, New York, 1982. [Boritz et al., 19891 J. E. Boritz, R. G. Kielstra, and A. M. Albuquerque. A prototype expert system for the assessment of inherent risk and prior probability of error. Report, School of Accountancy, University of Waterloo, Waterloo, Ontario N2L 3G1, February 1989. [Bouwman, 19831 M. J. Bouwman. Human diagnostic reasoning by computer: An illustration from financial analysis. Management Science, 29(6):653-672, June 1983. [Bridgeland, 19901 D. M. Bridgeland. Three qualitative simulation extensions for supporting economics mod- els. In Proc. Gth IEEE Conf. on A.I. Applications, pages 266-273, Santa Barbara, CA, March 1990. [Dhar et a/., 1988] V. Dhar, B. Lewis, and J. Peters. A knowledge-based model of audit risk. AI Magazine, 9(3):57-63, Fall 1988. [Elliott, 19831 R. I<. Elliott. Unique audit methods: Peat Marwick International. Auditing: A Journal of Practice and Theory, 2(2):1-12, Spring 1983. [Hamscher, 1991a] W. C. Hamscher. Model-based fi- nancial data interpretation. In 1st In-t. Conf. on AI Applications on Wall Street, New York, October 1991. IEEE Computer Society Press. Also in Working Notes of the 2nd International Workshop on Princi- ples of Diagnosis (Technical Report RT/DI/Sl-10-7, Dipartimento cli Informatica, Universita di Torino, 1991). [Hamscher, 1991b] W. C. Hamscher. Modeling digi- tal circuits for troubleshooting. A rtijkiul Intelli- gence, 51(1-3):223-271, October 1991. Also in J. de Kleer and B. Williams (eds.) Qualitative Reason- ing ubout Physicul Systems II (North-Holland, Ams- terdam, 1991 / MIT Press, Cambridge, Mass., 1992) and in W. C. Hamscher, J . de Kleer and L. Console teds), Reudings in Alodel-bused Diagnosis (Morgan Kaufmann, San Mateo, Calif., 1992). [Hamscher, 19921 W. C. Hamscher. Analysis of ac- counting systems via abstraction of simulation results into causal networks. Technical Report 25, Price Wa- terhouse Technology Centre, Menlo Park, CA 94025, January 1992. [Hart et al., 19861 P. E. Hart, A. Barzilay, and R. 0. Duda. Q ua I a ive l’t t reasoning for financial assess- ments: A prospectus. AI Magazine, 7( 1):62-68, Win- ter 1986. [Nado et al., 1991) R. Nado, J. Van Baalen, and R. Fikes. JOSIE: An integration of specialized repre- sentation and reasoning tools. ACM Sigart Bulletin special issue on implemented knowledge representa- tion and reasoning systems, 2(3):101-107, June 1991. [Peters, 1990] J. M. Peters. A cognitive computational model of risk hypothesis generation. Journal of Ac- counting Research, 28( Supplement):S3-103, 1990. [Shirley, 19861 M. H. Shirley. Generating tests by ex- ploiting designed behavior. In Proc. 5th National Conf. on Artificiul Intelligence, Philadelphia, PA, August 1986. 524 Problem Solving: Search and Expert Systems | 1992 | 91 |
1,289 | svi wit Tom Ishida NTT Communication Science Laboratories Sanpeidani, Inuidani, Seika-cho, Soraku-gun, Kyoto 619-02, Japan ishida@cslab.kecl.ntt.jp Abstract We previously proposed the moving target search (MTS) algorithm, where the location of the goal may change during the course of the search. MTS is the first search algorithm concerned with problem solving in a dynamically changing environment. However, since we constructed the algorithm with the minimum oper- ations necessary for guaranteeing its completeness, the algorithm as proposed is neither efficient nor intelligent. In this paper, we introduce innovative notions created in the area of resource- bounded planning into the formal search algorithm, MTS. Our goal is to improve the ef- ficiency of MTS, while retaining its completeness. No- tions that are introduced are (1) commitment to goals, and (2) deliberation for selecting plans. Evaluation re- sults demonstrate that the intelligent MTS is 10 to 20 times more efficient than the original MTS in uncertain situations. Existing search algorithms can be divided into two classes: o$-line search, which computes the entire so- lution path before executing the first step in the path, and realtime search, which always computes a plausi- ble next move and physically executes that move in constant time. However, all these algorithms assume that the problem is fixed and does not change over the course of the search. On the other hand, in the area of planning, where search algorithms have been often utilized, researchers are recently focusing on dynami- cally changing environments, where the goal state and the problem space change in run-time, and thus agents are resoume-bounded in constructing plans. Therefore, search algorithms capable of handling changing prob- lems will provide a computational basis for resource- bounded planning. In this direction, we have already investigated the case wherein the goal state changes during the course of the search, and proposed the moving target search (MT’S) algorithm [Ishida and Korf, 19911. Off-line search seems infeasible for implementing MTS because the search takes exponential time, and thus the target would have moved to a new position by the time a path was found. Therefore, we started from realtime search [Korf, 19901, and extended it to MTS. The MTS al- gorithm has been proved to be complete in the sense that it will eventually reach the target, assuming a fi- nite problem space and that the speed of the problem solver is faster than that of the target. We originally implemented MTS with the minimum operations necessary for guaranteeing its completeness. The obtained algorithm consists of a pair of steps, which are repeatedly performed: the first step is incremental learning of the estimated distance between the prob- lem solver and the target, and the second step moves the problem solver in the problem space. As a result, MTS is reactive, i.e., capable of performing each move in constant time, but it is neither efficient nor intelli- gent. Various experiments showed that the efficiency of the algorithm decreases rapidly as uncertainty in- creases. This is because, in uncertain situations, the heuristic function does not return useful information and the learning cost becomes high. In the area of resource-bounded planning, however, agent architectures to cope with environmental changes have been studied [Georgeff et al., 1987]. Cohen et al. [1990] have defined the notion of commitment as a persistent goal. Kinny et al. [1991] quantitatively evaluated how the degree of commitment affects agents’ performance. ’ The role of deliberation has been in- vestigated by Bratman et al. [1988]. Pollack et al. [1990] proposed the experimental environment called Tileworld and have been quantitatively evaluating the trade08 between deliberation and reactiveness. The challenge of this paper is to introduce these notions into formal search, and to improve the efficiency of MTS while retaining its completeness. Introduced notions are as follows: Commitment to goals: In MTS, the problem solver always knows the target’s position, but can ignore some of its moves. Experi- TDurfee et CI 1. 1988] [ performed multi-agent environments. a similar evaluation in Hshicb3 525 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. When the problem solver moves: 1. Calculate h(x’, y) for each neighbor x’ of x. 2. Update the value of h(x, y) as follows: h(x, Y) - max h(xc, Y) minzl(h(xf, y) + 1) 3. Move to the neighbor x’ with the minimum h(x’, y), i.e., assign the value of x’ to x. Ties are broken randomly. 526 Problem Solving: Search and Expert Systems ments show that changing the goal causes the prob- lem solver to start incremental learning over again toward the new goal. Thus, in uncertain situations, where the learning cost is significant, better perfor- mance could be obtained by committing to its goal and not changing it even if the target moves. Deliberation for selecting plans: When the problem solver moves, MTS always selects the neighboring position that offers the minimum es- timated distance to the goal. However, as the situa tion becomes uncertain, such a reactive decision be- comes inaccurate and often does not result in better performance. Thus, deliberative investigation using off-line search, though it decreases the speed of the problem solver, might improve overall performance in uncertain situations. 2. Moving Target Search We briefly characterize the moving target search prob- lem pshida and Korf, 19911. The problem space is rep- resented as a connected graph. The graph is undirected, allowing motion of either the problem solver or the tar- get along an edge in any direction. We assume that all edges in the graph have unit cost. There is an ini- tial position of the problem solver and an initial posi- tion of the target. The problem solver does not have a map of the problem space. We assume the problem solver and the target move alternately, and can traverse at most one edge in each turn. We reduce the speed of the target by assuming that periodically the target will make no move, and remain at its current position. The problem solver has no control over the movements of the target, but always knows the target’s position. There also exists a heuristic function that returns an es- timate of the distance between any pair of states. Note that MTS must acquire heuristic information for each goal location. The heuristic function must be admissk ble, meaning it never overestimates the actual distance [Pearl, 19841. Th e as is accomplished when the prob- t k lem solver and the target occupy the same state. The MTS algorithm is as follows. As the initializa- tion of the algorithm, the current state of the problem solver is assigned to 2, and the current state of the target to y. The heuristic function h(z, y) represents the estimated distance between z and y. The following steps are repeatedly performed until the task is accom- plished. When the target moves: 1. Calculate h(x, y’) for the target’s new position y’. 2. Update the value of h(x, y) as follows: h(x, Y) t max 3. Reflect the target’s move to the problem solver’s goal, i.e., assign the value of y’ to y. The MTS algorithm is complete in the sense that the problem solver executing MTS is guaranteed to eventu- ally reach the target, assuming a finite problem space, in which a path exists between every pair of nodes, starting with non-negative admissible initial heuristic values, and if the target periodically skips moves. The completeness of MTS is proved as follows: Define the heuristic error as the sum over all pairs of states a and b of h*(a, b) - h(a,b) where h*(a,b) is the length of the shortest path between a and b, and h(a, b) is the current heuristic value. Define the heuristic di$er- ence as h(x, y), the current heuristic value between the current state of the problem solver, x, and the current state of the target, y. Define the heuristic disparity as the sum of the heuristic error and the heuristic differ- ence. Proof was made by showing that the heuristic disparity decreases by at least one unit when the prob- lem solver moves, and increases by at most one unit when the target moves [Ishida and Korf, 19911. 3. Performance ottleneck of MTS Experiments To examine MTS performance, we implemented it in a rectangular grid problem space (100 x 100) with obsta- cles. We allow motion along the horizontal and vertical dimensions, but not along the diagonal. To erase prob- lem space boundaries, we formed a torus by connecting the opposite boundaries. Note that the rectangular grid represents one of the many problem spaces possible, but not a physical workspace. Though MTS is effective in any type of problem space, we use the rectangular grid as an experimental environment simply because it is suitable for plotting on a workstation display, and it helps humans to intuitively recognize what is going on in the problem space. Though each state basically has four neighbors, obstacles are generated by restricting the number of neighboring states. The Manhattan distance is used as the initial heuris- tic value. This is because the Manhattan distance rep- resents the actual distance if there is no obstacle, but it does becomes inaccurate as the number of obstacles increases. Thus the combination of obstacles and the Manhattan distance can naturally produce any degree of uncertainty. The problem solver and the target are initially positioned as far apart as possible in the torus, i.e., 100 units in Manhattan distance. Figure 1 illus- trates the sample track of MTS. In this figure, obsta cles were manually positioned, and the motion of the Problem Solver 10000 9000 8000 7000 6000 5000 4000 3000 2000 1000 0 0 5 10 15 20 25 30 35 Obstacle Ratio (%) Figure 1 Sample Track of MTS -+- Avoid -c- Meet -G-- Random + Stationary target was controlled by a human user to escape from the problem solver. Figure 2 shows the performance of MTS. In this eval- uation, obstacles are randomly positioned. X-axis rep- resents the ratio of obstacles: an obstacle ratio of 20% means that 2000 junctions in the 100 x 100 grid are ran- domly replaced by obstacles. With high obstacle ratios (more than 20%), obstacles join up and form walls with various shapes. The complexity of the maze rapidly in- creases as the ratio increases from 25% to 35%. When the ratio reaches 40%, the obstacles tend to discon- nect the problem space, separating the target from the problem solver. Y-axis represents the number of moves taken by the problem solver to catch the target. Num- bers in this figure are obtained by averaging 100 trials. The speed of the target is set to 80% of the problem solver: the target skips one in every five moves. The motion of the target is controlled by programs with the following four response modes. Avoid: The target actively avoids the problem solver: the target performs MTS to move toward the position as far apart as possible from the problem solver in the torus. Meet: The target moves cooperatively to meet the problem solver: the target performs MTS to decrease the estimated distance from the problem solver. Random: The target moves randomly. S&ztionary: The target remains stationary. In this case, MTS behaves exactly same as the realtime search algorithm called Learning Real- Time A * [Korf, 19901. The results of experiments show that the perfor- mance decreases as the situation becomes uncertain. Figure 2 Performance of MTS Though this phenomena is observed in all target’s be- havior modes, the performance decreases more rapidly when the target moves than when it remains station- ary. In Meet, though both agents perform MTS to meet each other, the effect appears to be negative. This is be- cause, in uncertain situations, the agents tend to reach the opposite sides of the same wall, and move back and forth in confusion. Neurist ic epression Let us examine the MTS behavior in more detail to fig- ure out why MTS becomes inefficient in uncertain sit- uations. Figure 3 represents the behavior of the prob- lem solver in a one dimensional problem space. X-axis represents the positions of the problem solver and the target, while Y-axis represents the estimated distance between the problem solver and the target. The ini- tial heuristic values are plotted with wide lines. Ar- rows indicate moves of the problem solver. Incremental updates of heuristic values performed by the problem solver are indicated by dark boxes. In this figure, the target is assumed not to move. As described in Fig- ure 3, the problem solver performing MTS repeatedly moves along the slope of heuristic values. To explain the problem solver’s behavior, we define a heuristic depression for each goal state as follows: Start from a set with single state whose heuristic value is equal to or less than those of the surrounding states. Extend the set by adding any neighboring state while keeping the heuristic values in the set equal to or less Ishida 527 t _Initial lieu fistic I Value 1 abcdefg h i j k 1 m n-o-p’ 1 cl Position of Problem Solver and Target The problem solver is initially positioned at “a,” and the target at “q.” r-~ Moves of the problem solver Figure 3 Behavior of MTS than those of the states surrounding the extended set. When no more state can be added, we call the result- ing set a heuristic depression. For example, in Figure 3, positions from d to h form a heuristic depression. Note that no depression exists in the actual distance. However, as the situation becomes uncertain, heuristic values differ significantly from the actual distances, and so heuristic depressions tend to appear frequently in the problem space. When placed in a heuristic depression, the problem solver has no way to decrease the heuristic difference, and recognizes that its heuristic values are inaccurate. The problem solver cannot reach the target without fill- ing the depression by repeatedly updating the heuristic values. Suppose the target moves during this learning process. Since MTS must maintain heuristic values for each goal location, the problem solver has to start the learning process over again for the target’s new posi- tion. This is why MTS performance rapidly decreases in uncertain situations. To summarize, the performance bottleneck of MTS exists in its ineficiency of filling the heuristic depres- sion. Thus, in the following sections, we propose to introduce two notions created in the area of resource- bounded planning: (1) commitment to goals to ignore the target’s moves and to concentrate on filling the heuristic depression, and (2) deliberation for selecting plans in which off-line search is performed to find a di- rection for getting out of the heuristic depression. The effect of introducing these notions will be reported in Section 6 using the same examples given in Figure 2. In the following discussion, we distinguish the original MTS algorithm as BMTS (Basic Moving Target Search) and the improved algorithm as IMTS (Intelligent Mov- ing Target Search). 4. Introducing Commitment In BMTS, the problem solver always knows the posi- tion of the target. However, we can extend BMTS so that the problem solver can ignore some of the tar- get’s moves. The extended BMTS only requires that the problem solver knows the position of the target at some point before the problem solver reaches the last known position of the target [Ishida and Korf, 19911. The question is, when the problem solver should ignore the target’s moves and when it should not. In this paper, we propose that the problem solver re- fleets the target’s move in the problem solver’s goal only when the heuristic diflerence decreases; otherwise (i.e., when placed in a heuristic depression) it commits to the target’s previous position and does not change its goal even if the target moves. However, as shown in Fig- ure 3, when filling a large heuristic depression, updat- ing heuristic values creates small depressions, and thus the heuristic difference may temporarily decrease (i.e., arrows are sometimes directed down). In such a situ- ation, even if the heuristic difference decreases, retar- getting still causes the learning process to be restarted again. Therefore, we introduce the degree of commit- ment (dot), which represents the strength of the prob- lem solver’s commitment to its goal. Let DOWN be the number of problem solver’s moves for which the heuristic difference continuously decreases. Let the problem solver reflect the target’s move in its goal only when DOWN 2 dot. Obviously, when dot = 0 the problem solver is most sensitive to the target’s moves, and behaves exactly the same as BMTS. On the other hand, when dot = 00, the problem solver is least sensitive. Note that when the problem solver reaches the committed goal (i.e., x = y), the problem solver must always change its goal to the target’s new 528 Problem Solving: Search and Expert Systems position . The problem solver thus changes its goal only when it reaches the last committed position of the tar- get. The IMTS algorithm with commitment is as follows. DOWN is set to 0 before execution. When the problem solver moves: 1. Calculate h(x’, y) for each neighbor x’ of x. 2. If h(x, y) > min,l(h(x’, y)}, DOWN + DOWN + 1. If h(x, y) 5 min,t(h(x’, y)), DOWN + 0. 3. Update the value of h(x, y) as follows: h(x, Y) + mcax h(x, Y) min21(h(xf, y) + 1) > 4. Move to the neighbor with the minimum h(x’, y), i.e ., assign the value of x’ to 31:. Ties are broken randomly. When the target moves: When DOWN 1 dot or x = y, perform the follow- ing: 1. Calculate h(x, y’) for the target’s new position y’. 2. Update the value of h(x, y) as follows (let t be the number of target’s moves from y to y’): h(x1 Y) + max h(x, Y) h(x, y’) -t > 3. Reflect the target’s move in the problem goal, i.e., assign the value of yt to y. solver’s In the above algorithm, the constant t is used to rep- resent the number of the target’s moves from the prob- lem solver’s current goal y to the target’s new position d.2 The completeness of the above algorithm can be easily obtained by extending the proof in [Ishida and Korf, 19911, and thus we omit it from this paper due to space limitations. 5. Introducing Deliberation Realtime search is not always more efficient than off-line search. From our experience, in uncertain situations, off-line search often results in better performance. This is because, in off-line search, the problem solver does not move back and forth, but extends its wave front step by step even in uncertain situations. Our expec- tation is that introducing off-line search enables MTS to efficiently find the boundary of a heuristic depres- sion, and thus overcomes the performance bottleneck. The question is, when and how far the problem solver 2Though it is not discussed in this paper, it might be a good idea to take account of the distance between y and I’, when reflecting the target’s move in the problem solver’s goal, i.e., if the target has moved far from the problem solver’s goal, it might be reasonable to change the goal to the target’s new position. should perform off-line search. Note that the target might run away if the problem solver inappropriately performs off-line search. Our idea is that the problem solver performs realtime search while the h euristic difference decreases; other- wise (i.e., when placed in a heuristic depression) per- forms o$-line search. To consider the cost of off-line search, we assume that, in each turn, the problem solver can expand one state in off-line search, instead of moving one edge in realtime search. This allows the target to move during the problem solver expands states in off-line search.3 We then introduce the de- gree of deliberation (dod) to restrict the range of off-line search. Let CLOSED be a set of expanded states and OPEN be a set of visited but not yet expanded states. States in a heuristic depression are to be collected in CLOSED. The number of states in CLOSED is de- noted by ICLOSEDI. We allow the problem solver to perform off-line search only when lCLOSEDl < dod. Obviously, when dod = 0 and dot = 0, IMTS behaves exactly the same as BMTS. However, as dod increases, the problem solver tends to spend more time in delib- eration. The IMTS algorithm with deliberation is shown as follows. CLOSED and OPEN are cleared before ex- ecution. The algorithm starts in the realtime mode. When the target moves, the same algorithm in Section 4 is applied. When the problem solver moves: [A] When in the realtime mode, perform the follow- ing: 1. Calculate h(x’, y) for each neighbor z’ of x. 2. If h(x, y) > min,l(h(x’, y)}, DOWN + DOWN + 1. If h(x, y) 5 min,l{h(x’, y)}, DOWN + 0. 3. If h(x, y) > min,l{h(x’, y)) or dod = 0, perform the following: 3.1 Update the value of h(x, y) as follows: h(x, Y) + max h(x, Y) min,l{ h(x’, y) + 1) 3.2 Move to the neighbor with the minimum h(x’, y), i.e., assign the value of x’ to x. Ties are broken randomly. 4. If h(x, y) 5 min,l{h(x’, y)} and dod # 0, shift to the off-line mode and execute [B]. [B] When in the off-line mode, perform the following: 3The lookahead mechanism has been introduced to re- duce the number of moves in realtime search [Korf, 19901. However, this mechanism is assumed to be completed in constant time (i.e., in each problem solver’s turn), and thus the tradeoff between deliberation and reactiveness has not been discussed. In this paper, we introduce off-line search into MTS, taking account of its overhead. Ishida 529 a bcdefg h i j klmnopq Position of Problem Solver and Target The problem solver is initially positioned at “a,” and the target at “q.” - Moves of the problem solver (Realtime Search) * -----* off-lie Search Figure 4 Behavior of IMTS with Deliberation 1. Calculate h( x’ , y) for each neighbor 2’ 4 CLOSED of x. 2. If h(x, y) 5 min,l(h(x’, y)) and lCLOSEDl < dod, perform the following: 2.1 Expand x: For each neighbor x’ $8 CLOSED U OPEN of x, add x’ to OPEN. Add x to CLOSED. 2.2 Set x to topen E OPEN with the minimum h(x )* open Y Y 3. If h(x, y) > mins~{h(x’, y)} or lCLOSEDI 2 dod, perform the following. 3.1 For all x closed E CLOSED, update the value of h(Xelosed,Y) a~ fOUOWS: h(xtAosed, Y) + h(x, Y) + 1 3.2 Clear OPEN and CLOSED. 3.3 Shift to the realtime mode and execute [A]. Figure 4 illustrates the deliberation process of the above algorithm using the same situation given in Fig- ure 3. The problem solver starts in the realtime mode. When placed in a heuristic depression, the problem solver commits to the target’s current position and shifts to the off-line mode. The problem solver then per- forms off-line search to find a boundary of the depres- sion. When the boundary is found, the problem solver updates the heuristic values of all states in CLOSED, gets out of the depression, shifts to the realtime mode, and continues to perform realtime search while the heuristic difference decreases. We briefly show the completeness of IMTS with de- liberation. Since the number of states in CLOSED is upper bounded by dod, each turn of the problem solver 530 Problem Solving: Search and Expert Systems (both in the realtime and off-line modes) can be pro- cessed in constant time. At each turn, the problem solver selects the realtime mode or the off-line mode. When the off-line mode is selected, (1) the number of states in CLOSED increases by one, or (2) the heuris- tic values of the states in CLOSED are updated all at once. In the former case, the heuristic disparity does not decrease, but in the latter case the heuristic dispar- ity decreases by jCLOSEDI units. This is because, for each state in CLOSED, the heuristic error decreases byh(x,y)+l--( x,-losed, y), while heuristic difference might increase by h(z, y) - h(Xclosed, y), and thus the heuristic disparity decreases by one unit. Therefore, in the combined sequence of the problem solver’s moves, the heuristic disparity decreases by at least lCLOSEDl units per lCLOSEDI turns. On average, the heuristic disparity is decreased by at least one unit in each turn in the off-line mode. In the realtime mode, since the process is the same as BMTS, the heuristic disparity decreases by at least one unit for each turn. On the other hand, when the target moves, the heuristic dis- parity increases by an average of at most one unit for each turn. Since the target periodically skips moves, the problem solver will eventually reach the target. 6. Evaluation Results We evaluated the effectiveness of IMTS in the same situation described in Figure 2. Note that the problem solver performs IMTS, while the target performs BMTS in Avoid, and IMTS in Mee-t. This is to more clearly show the performance improvement possible with the IMTS algorithms: In Avoid, we compare the case of IMTS pursuing BMTS with the case of BMTS pursu- 800 6OO~j 1000 v) $ 800 9 ‘i5 600 2 400 0 5 lb 15 2b 2‘S 3b 35 d S 1-O l-5 2b 25 3b 3k Obstacle Ratio 6) Obstacle Ratio (%) (a) dot= 10 (b) dot - 00 Figure 5 Performance of IMTS with Commitment ing BMTS ( as in Figure 2), and in Meed, the coopera- tive behavior of IMTS agents is compared with that of BMTS agents (as in Figure 2). The major results are as follows: Commitment to goals: Figure 5 plots the evaluated IMTS performance un- der the conditions of dot = 10 and dot = 00. Since Figure 2 can be seen as the result of dot = 0, the ef- fects of the degree of commitment to the overall per- formance can be evaluated by comparing these three figures. When dot = 10, actually this value yields almost the best performance for all dot values from 0 to 00, the performance improvement is 12 times in Random, 6 times in Meet, and 4 times in Avoid. The reason why the largest effect is obtained in Random is that the target cannot deviate from the initial position because of the random moves, and thus the problem solver can safely ignore the target’s moves. However, increasing the degree of commitment does not always improve the performance. When dot = 00, in Avoid, the performance instead decreases when the obstacle ratio is low. That is, in certain situations, since the heuristic function returns a fairly good es- timation, the problem solver had better be sensitive to the target’s moves. In Meet, the performance also decreases but for all obstacle ratios. This decrease is considered to be caused by ignoring the target’s cooper at ive behavior. Deliberation for selecting plans: Figure 6 represents IMTS performance with deliber- ation under the values of dod = 5 and dod = 25, which roughly mean off-line search is performed to the depth of 2 and 4, respectively. The degree of commitment (dot) is always set to 10. Compared with Figure 5(a), when dod = 25, the performance is further doubled in uncertain situations. These effects are observed in all target behavior modes including Stationary. This shows that deliberation is effective not only in moving target problems, but also in real- time search for fixed goals. Unlike the introduction of commitment, the per- formance does not decrease even when the degree of deliberation further increases. This is because lCLOSEDl cannot be too large in randomly gener- ated maps, since the ranges of heuristic depressions are naturally upper bounded. If ICLOSEDI is large, increasing the degree of deliberation might decrease IMTS performance. To summarize, introducing commitment and deliber- ation dramatically improves the efficiency of MTS. The evaluation results clearly show that (1) MTS perfor- mance is improved by 10 to 20 times in uncertain situ- ations depending on the target’s behavior modes, and (2) controlling the degree of commitment is essential to produce the optimal performance. a. Conclusion MTS performance has been improved by introducing notions created in the area of resource-bounded plan- Ishida 531 I 5 I- 6 P 700 600 500 400 300 200 100 0 5 10 15 20 25 30 35 Obstacle Ratio (“A) (a) dod = 5 (dot = 10) 600 1-o l-5 Obstacle Ratio (%) (b) dod = 25 (doe = 10) I -o- Avoid -o- Random -c- Meet + Stationary 1 Figure 6 Performance of IMTS with Deliberation ning. Since only a few steps are added to the original MTS, the obtained intelligent MTS has not lost its sim- plicity. However, the behaviors of the two algorithms as plotted on a workstation display are substantially dif- ferent. The intelligent MTS behaves like a predator: In certain situations, the problem solver is always sensitive to the target’s moves and reactively moves toward the target current position, while in uncertain situations, the problem solver ignores the target’s moves, commits to its current goal, and deliberates to find a promising direction to reach the goal. Throughout this work, we have tried to bridge the studies on conceptual modeling and algorithms con- cerned with resource-bounded planning. The results suggest that combining innovative notions and compu- tationally sound algorithms will provide robust and effi- cient methodologies for problem solving in dynamically changing environments. Acknowledgments The author wishes to thank Kiyoshi Nishikawa and Ryohei Nakano for their support during this work at NTT Laboratories, and Richard Korf, Jun-ichi Aka hani, Kazuhiro Kuwabara and Makoto Yokoo for their helpful discussions. References [Bratman et al., 19881 M. E. Bratman, D. J. Israel and M. Pollack, “Plans and Resource Bounded Practi- cal Reasoning,” Computational Intelligence, 4(4), pp. 349-355, 1988. [Cohen e2 al., 19901 P. R. Cohen and H. J. Levesque, “Intention is Choice with Commitment ,” Atiificial Intelligence, 42(3), 1990. [Durfee et al., 19881 E. H. Durfee and V. R. Lesser, “Predictability versus Responsiveness: Coordinating Problem Solvers in Dynamic Domains,” AAAI-88, pp. 66-71, 1988. [Georgeff et al., 19871 M. P. Georgeff and A. L. Lansky, “Reactive Reasoning and Planning,” AAAI-87, pp. 677-682, 1987. [Ishida and Korf, 19911 T. Ishida and R. E. Korf, “Moving Target Search,” IJCAI-91, pp. 204-210, 1991. [Kinny et al., 19911 D. N. Kinny and M. P. Georgeff, “Commitment and Effectiveness of Situated Agents,” IJCAI-91, pp. 82-88, 1991. [Korf, 19901 R. E. Korf, “Real-Time Heuristic Search”, Artificial Intelligence, Vol. 42, No. 2-3, March 1990, pp. 189-211. 1990. [Pearl, 19841 J. Pearl, Heuristics: Intelligent Search Strategies for Computer Problem Solving, Addison- Wesley, Reading, Mass., 1984. [Pollack et al., 19901 M. E. Pollack and M. Ringuette, “Introducing the Tileworld: Experimentally Evalu- ating Agent Architectures,” AAAI-90, pp. 183-189, 1990. 532 Problem Solving: Search and Expert Systems | 1992 | 92 |
1,290 | Linear-Space est-First Search: Summary of Richard E. Korf” Computer Science Department University of California, Los Angeles Los Angeles, Ca. 90024 korf@ks.ucla.edu Abstract Best-first search is a general search algorithm that, always expands next a frontier node of lowest cost. Its applicability, however, is limited by its expo- nential memory requirement. Iterative deepen- ing, a previous approach to this problem, does not expand nodes in best-first, order if t’he cost, function can decrease along a path. We present a linear-space best-first search algorithm (RBFS) that always explores new nodes in best-first or- der, regardless of the cost function, and expands fewer nodes than iterative deepening with a. non- decreasing cost function. On the sliding-tile puz- zles, RBFS with a weighted evaluation function dramatically reduces computation time with only a small penalty in solution cost. In general, RBFS reduces the space complexity of best-first search from exponential to linear, a.t the cost of only a constant factor in time complexity in our expcri- ments. Introduction: Best-First Search Best-first search is a very general heuristic search algo- rithm. It maintains an Open list of the frontier nodes of a partially expanded search graph, and a Closed list of the interior nodes. Every node has an associated cost value. At each cycle, an Open node of minimum cost is expanded, generating all of its children. The children are evaluated by the cost functfionY inserted into the Open list, and the pa.rent is placed on the Closed list. Initia.lly, the Open list contains just the initial node, and the algorithm terminates when a. goal node is chosen for expansion. If the cost of a node is its depth in the graph, then best-first search becomes breaclth-first search. If the -- *This research was supported by an NSF Presidential \Cung Investigator Award, No. IRI-8553925, and a grant from Rockwell International. Tlla.nks to Valerie Aylett for drawing the graphs and figures, to Cindy Mason, Jot Pem- berton, and Ed Purcell for their cornmcnt.s on an early draft of this manuscript, and to Stuart Russell for discussions on related work. cost of node n is g(n), the sum of the edge costs from the root to node n, then best-first search becomes Di- jkstra’s single-source shortest-path algorithm[Dijkstra 19591. If the cost function is f(n) = g(n)+ h(n), where h(lz) is a heuristic estimate of the cost of reaching a goal from node n, then best-first search becomes the A* algorithm[IIart, Nilsson, & Raphael 19681. Since best-first search stores all generated nodes in the Open or Closed lists, its space complexity is the same as its time complexity, which is typically expo- nential. Given the ratio of memory to processing speed on current computers, in practice best-first search ex- hausts the available memory on most machines in a matter of minutes, halting the algorithm. Previous Work: Iterative Deepening The memory limitation of best-first sea.rch was first addressed by iterative deepening[I<orf 19851. Itera- tive decpcning performs a series of depth-first searches, pruning branches when their cost exceeds a threshold for that iteration. The initial threshold is the cost of the root node, and the threshold for each succeed- ing iteration is the minimum node cost that exceeded the previous threshold. Since iterative deepening is a depth-first algorithm, it only stores the nodes on the current search path, requiring space that is only lin- ear in the search depth. As with best-first search, dif- ferent cost functions produce different iterative deep- cning algorit,hms, including depth-first iterative deep- ening (f( 12) = depth(n)) and iterative-deepening-A* (f(4 = m + 44)* If h(12) is consistent[Pearl 19841, all the cost func- tions described above are 7~2onutonic, in the sense that the cost of a child is always greater than or equal to the cost, of its parent. With a monotonic cost function, the order in which nodes are first expanded by iterative deepening is best first. Many importa.nt cost functions are non-monotonic, however, such as f(n) = g(n) + IV. h(n)[Pohl 1970] with CV > 1. The advantage of this cost function is that while it returns suboptimai solutions, it generates far fewer nodes thaa arc required to find optima.1 solutions. With a non-monotonic cost function, the cost of a Korf 533 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. Figure 1: SRBFS with non-monotonic cost function child can be less than the cost of its parent, and iter- ative deepening no longer expands nodes in best-first order. For example, consider the tree fragment in Fig- ure lB, ignoring the caption and inequalities for now, where the numbers in the nodes represent their costs. A best-first search would expand these nodes in the order 5, 1, 2. With iterative deepening, the initial threshold would be the cost of the root node, 5. Af- ter generating the left child of the root, node 2, iter- ative deepening would expand all descendents of node 2 whose costs did not exceed the threshold of 5, in depth-first order, before expanding node 1. Even if all the children of a node were generated at once, and or- dered by their cost values, so that uode 1 was expanded before node 2, iterative deepening would explore the subtrees below nodes 4 and 3 before expauding node 2. The real problem here is that while searching nodes whose costs are less than the current threshold, itera- tive deepening ignores the information in the values of those nodes, and proceeds strictly depth first. Recursive Best-First Search Recursive best-firs-t search (RBFS) is a linear-space al- gorithm that always expands nodes in best-first order, even with a non-monotonic cost function. For ped- agogical reasons, we first present a simple version of the algorithm (SRBFS), and then consider the more efficient full algorithm (RBFS). These algorithms first appeared in [Korf 1991a], the main results were de- scribed in [Korf 1991b], and a full treatment appears in [Korf 1991c], including proofs of all the theorems. Simple Recursive Best-First Search While iterative-deepening uses a global cost t,hreshold, Simple Recursive Best-First Search (SRBFS) uses a local cost threshold for each recursive call. It takes two arguments, a node aud an upper bound 011 cost, and explores the subtree below the node as long as it contains frontier nodes whose costs do not exceed the upper bound. It then returns the minimum cost, of t,he frontier nodes of the explored subtree. Figure 1 shows how SRBFS searches the tree in Figure 1B in best- first order. The initial call on the root, is made with an upper bound of infinity. We expand the root, and com- pute the costs of the children as shown in Figure 1A. Since the right child has the lower cost, we recursively Figure 2: SRBFS example w th cost equal to depth call SRBFS ou the right child. The best Open nodes in the tree will be descendents of the right child as long as their costs do not exceed the value of the left child. Thus, the recursive call on the right child is made with an upper bound equal to the value of its best (only) brother , 2. SRBFS expands the right child, and eval- uates the grandchildren, as shown in Figure 1B. Since the values of both grandchildren, 4 and 3, exceed the upper bound on their parent, 2, the recursive call ter- minates. It returns as its result the minimum value of its children, 3. This backed-up value of 3 is stored as the new value of the right child (figure lC), indicating that the lowest-cost Open node below this node has a cost of 3. A recursive call is then made 011 the new best child, the left one, with an upper bound equal to 3, which is the new value of its best brother, the right child. In general, the upper bound on a child node is equal to the minimum of the upper bound on its par- ent, and the current value of its lowest-cost brother. Figure 2 shows a more extensive example of SRBFS. In this case, the cost function is simply the depth of a node in the tree, corresponding to breadth-first search. Initially, the stored value of a node, F(n), equals its stntic value, f(n). After a recursive call on the node ret,urns, its stored value is equal to the minimum value of all frontier nodes in the subtree explored duriug the last call. SRBFS proceeds down a pakh until the stored values of all children of the last node expanded exceed 534 Problem Solving: Search and Expert Systems Figure 3: Inefficiency of SRBFS and its solution the stored value of one of the nodes further up the tree. It then returns back up the tree, replacing parent val- ues with the minimumof their children’s values, until it reaches the better node, and then proceeds down that path. The algorithm is purely recursive with no side effects, resulting in very low overhead per node gener- ation. In pseudo-code, the algorithm is as follows: SRBFS (node: N, bound: B) IF f(N)>B, RETURN f(N) IF N is a goal, EXIT algorithm IF N has no children, RETURN infinity FOR each child Ni of N, F[i] := f(Ni) sort Ni and F[il in increasing order of F[i] IF only one child, FL21 := infinity WHILE (F[l] C= B) FL11 := SRBFS(N1, MIN(B, F[23)) insert Ml and FE11 in sorted order return F Cl] Once a goal is reached, the actual solution path is on the recursion stack, and returning it involves simply recording the moves at each level. For simplicity, we omit this from the above description. SRBFS expands nodes in best-first order, even if the cost function is non-monotonic. IJnfortunately, how- ever, SRBFS is inefficient. If we continue the example from figure 2, where cost is equal to depth, eventu- ally we would reach the situation shown in figure 3A, for example, where the left child has been explored to depth 7 and the right child to depth 8. Next, a recur- sive call will be made on the left child, with an upper bound of 8, the value of its brother. The left child will be expanded, and its two children assigned their static values of2, as shown in figure 3B. At tllis point, a recursive call will be made on the right grandchild with an upper bound of 2, the minimum of it,s parent’s bound of 8, and its brother’s value of 2. Thus: the right grandchild will be explored to depth 3, the left grandchild to depth 4, the right to depth 5, the left to depth 6, and the right to depth 7, before new ground can finally be broken by exploring the left grandchild to depth 8. Most of this work is redundant, since t,he left child has alrea.dy been explored to depth 7. Full Recursive Best-First Search The way to avoid this inefficiency is for children to in- herit their parent’s values as their own, if the parent’s values are greater than the children’s values. In the above example, the children of the left child should inherit 7 as their stored value instead of 2, as shown in figure 3C. Then, the right grandchild would be ex- plored immediately to depth 8 before exploring the left grandchild. However, we must distinguish this case from that in figure 1, where the fact that the child’s value is smaller than its parent’s value is due to non- monotonicity of the cost function, rather than previous expansion of the parent node. In that case, the chil- dren should not inherit their parent’s value, but use their static values instead. The distinction is made by comparing the stored value of a node, F(n), to its static value, f(n). If a node’s stored value equals its static value, then it has never been expanded before, and its children’s val- ues should be set to their static values. If a node’s stored value exceeds its static value, then it has been expanded before, and its stored value is the minimum of its children’s last stored values. The stored value of such a node is thus a lower bound on the values of its children, and the values of the children should be set to the maximum of their parent’s stored value and their own static values. A node’s stored value cannot be less than its static value. The full recursive best-first search algorithm (RBFS) takes three arguments: a node N, its stored value V, and an upper bound B. The top-level call to RBFS is made on the start node s, with a value equal to the static value of s, f(s), and an upper bound of 00. In pseudo-code, the algorithm is as follows: RBFS (node: N, value: V, bound: B) IF f(N)>B, return f(N) IF N is a goal, EXIT algorithm IF N has no children, RETURN infinity FOR each child Ni of N, IF f(N)<V AND f(Ni)CV THEN F[i] := V ELSE F[i] := f(Ni) sort Ni and F[il in increasing order of F[i] IF only one child, FE21 := infinity WHILE (FL-11 <= B) FE11 := RBFS(N1, F[l], MIN(B, F[21)) insert Nl and F[l] in sorted order return F[l] Like SRBFS, RBFS explores new nodes in best-first order, even with a non-monotonic cost function. Its ad- vantage over SRBFS is that it is more efficient. While SRBFS expands all nodes in best-first order, RBFS only expands new nodes in best-first order, and ex- pands previously expanded nodes in depth-first order. If there are cycles in the graph, and cost does not always increase while traversing a cycle, as with a cost function such as f(n) = h(n), RBFS must be modified to avoid infinite loops. In particular, each new node must be compared against tile stack of nodes on the current path, and pruned if it is already on the stack. Korf 535 Theoretical Results We briefly present the main theoretical properties of SRBFS and RBFS. Space limitations preclude the for- mal statements and proofs of the theorems found in [Korf 1991c]. The most important result, and the most difficult to establish, is that both SRBFS and RBFS are best-first searches. In other words, the first time a node is expanded, its cost is less than or equal to that of all other nodes that have been generated, but not yet expanded so far. What distinguishes these algo- rithms from classical best-first search is that the space complexity of both SRBFS and RBFS is O(M), where b is the branching factor, and d is the maximum search depth. The reason is that at any given point, the recur- sion stack only contains the path to the best frontier node, plus the brothers of all nodes on that p&h. If we assume a constant branching factor, the space com- plexity is linear in the search depth. While the time complexities of both algorithms are linear in the number of nodes generated, this num- ber is heavily dependent on the particular cost func- tion. In the worst case, all nodes have unique cost values, and the asymptotic time complexity of both al- gorithms is O(b2d). This is the same as the worst-case time complexity of IDA* on a tree[Patrick, Almulla, & Newborn]. This scenario is somewhat unrealistic, how- ever, since in order to maintain unique cost values in the face of an exponentially growing number of nodes, the number of bits used to represent the values must increase with each level of the tree. As a more realistic example of time complcxit$y, we examined the special case of a uniform tree where the cost of a node is its depth in the tree, corre- sponding to breadth-first search. In this case, the asymptotic time complexity of SRBFS is 0( xd), where z = (b+ l+ db2 + 2b - 3)/Z For large values of b, this approaches O((b+ l)d). The asymptotic time complex- ity of RBFS, however, is O(bd), showing that RBFS is asymptotically optimal in this case, but SR.BFS is not. Finally, for the important special cease of a mono- tonic cost function, RBFS generates fewer nodes than iterative deepening, up to tie-brea.king among nodes of equal cost. With a monotonic cost function, both algo- rithms expand all nodes of a given cost. before cspand- ing any nodes of greater cost. In itemtive deepeuing, each new iteration expands nodes of greater cost. Be- tween iterations, the search path collapses to just the root node, and the entire tree must be regenerated to find the nodes of next greater cost. For RBFS, we cau similarly define an “itera.tion” as the int,erval of t8ime when those nodes being expanded for the first time are all of the same cost. When the last node of a given cost is expanded, ending the current itera.tion, the recursion stack contains the path to that node, plus the brothers of all nodes on that path. Many of these brother nodes will have stored values equa,l to the next greater cost, and the subtrees below these nodes will be explored in the next iteration. Other nodes attached to this path 50% 60% 70% 80% 90% 100% relative weight of h(n) term I ----- Bound - - - WIDA’ - RBFS/WA’ I Figure 4: Solutions Lengths vs. Weight on h(n) ma.y have greater costs associated with them, a.nd will not be searched in the next iteration. Thus, while it- erative deepening must regenerate the entire previous tree during each new iteration, RBFS will only explore the subtrees of brother nodes on the last path of the previous iteration whose stored values equal the up- per bound for the next iteration. If nodes of similar cost are highly clustered in the tree, this will result in significant savings. Even in those situations where the entire tree must be explored in each iteration, as in the case of brea.dth-first search, RBFS avoids regenerating the last path of the previous iteration, although the savings is not significant in that case. Experimental Results We implemented RBFS on the Travelling Salesman Problem (TSP) and the sliding-t,ile puzzles. For TSP, using the monotonic A* cost function f(n) = g(n) + h(?b), with the minimumspa.nning tree heuristic, RBFS genera.tes only one-sixth as many nodes as IDA*, while finding optimal solutions. Both algorithms, how- ever, generate more nodes than depth-first branch-and- bound, another linear-space algorithm. On the Eight Puzzle, with the A* cost function and the Manhattan Distance heuristic, RBFS finds optimal solutions while generating slightly fewer nodes than IDA*. Depth-first branch-and-bound doesn’t work on this problem, since finding any solution is difficult. In order to find sub-optimal solutions more quickly, we used the weighted non-monotonic cost function, m-4 = g(n) + W - h(n), with FV > l[Pohl 19701. M7e ran three different algorithms on the Fifteen Puz- zle with this function: weighted-A* (WA*), weighted- IDA* (WIDA*), and RBFS. The solutions returned are guaranteed to be within a factor of CV of optimal[Davis, Bramanti-Gregor, & Wang 19891, but in practice a.11 three algorithms produce significantly better solutions, as shown in figure 4. The horizontal a.xis is the rel- ative weight on 12.(n), or lOOFV/(IV + l), while the vert+al axis shows the solution lengths in moves. All data points are averages of the 100 problem instances in [Korf 1985]. The bottom line shows the solution lengths returned by WA* and RBFS. Since both algo- rithms are best-first searches, they produce solutions 536 Problem Solving: Search and Expert Systems n 1 ,ooo,ooo,ooo 0 1 oo,ooo,ooo d 1 o,ooo,ooo e 1 ,ooo,ooo s 100,000 53 58 83 68 73 78 moves I --- WIDA’ - RBFS I Figure 5: Nodes Generated vs. Solution Length of the same average quality, with individual differences due to tie-breaking among nodes of equal cost. VVe were not able to run WA* with less than 75% of the weight on h(n), since it exhausted the a.vailable mem- ory of 100,000 nodes. The middle line shows that, WIDA* produces significantly longer solutions as the the weight on h(n) increases, since it explores nodes in depth-first order rather than best-first order. As the weight approaches lOO%, the solution lengths re- turned by WIDA* grow to infinity. The top line shows the guaranteed bound on solution quality, which is IV times the optimal solution length of 53 moves. Figure 5 shows the average number of nodes gener- ated as a function of solution length by RBFS and WIDA*, with relative weights on h(lz) of less than 75%. Small weights on h(n) reduce the node gen- erations by orders of magnitude, with only small in- creases in the resulting solution lengths. Neither algo- rithm dominates the other in this particular problem domain. While the utility of f(n) = g(n) + W l h(n) has previously been demonstrated on problems small enough to fit the search space in memory, such as the Eight Puzzle[Gaschnig 1979; Davis, Bramanti-Gregor, & Wang 19891, these experiments show tha,t the benefit is even greater on larger problems. Finally, we ran RBFS and WIDA* on 1000 different 5 x 5 Twenty-Four Puzzle problem instances with TV = 3. RBFS returned solutions that avera.ged 169 moves, while generating an avera.ge of 93891,942 nodes, com- pared to an average of 216 moves and 44,324,205 nodes for WIDA*. In both cases, however, t.he variation in nodes generated over individual problem instances was over six orders of ma.gnitude. Wit,11 IT/’ = 3, RISFS outperforms RTA*[I<orf 1990a], heuristic sub- goal search[Korf 1990b], and Stepping Stone[Ruby S: Kibler 1989]. With Iv < 3, the running times of both RBFS and WIDA* precludecl solving sufkient num- bers of problems to draw meaningful conclusions. An important feature of RBFS is that it can clistin- guish a node being expanded for the first. time, from one being reexpanded, by comparing its stored value to its static value. If they are equal, it, is a. new node, and otherwise it has previously been expanded. This allows us to determine the overhead due to node rcgcneration. In our sliding-tile experiments, for a given value of CTr, the total nodes generated by RBFS were a constant times the number that would be generated by standard best-first search on a tree, in spite of enormous vari- ation in the number of nodes generated in individual problem instances. For example, with i;V = 3 RBFS incurred an 85% node regeneration overhead, which remained constant over different problem instances of both the Fifteen and Twenty-Four Puzzles. The node regeneration overhead varied from a low of 20% with w = 1, to a high of 1671% with 61% of the weight on h(n). The variation is due to the number of ties among nodes with the same f(fa) value. For efficiency, the weighted cost function is actually implemented by multiplying both g(n) and h(n) by relatively prime in- tegers Iv, and Ivb, respectively, where Iv = wh/I’vg. M’it h iv = is> = i%‘h = 1, many nodes with different g(n) and It(n) values have the same f(?z) value, whereas with IIrg = 39 and IITh = 61, most nodes with the same f(n) value have the same g(n) and h(n.) values as well, resulting in far fewer ties among f(n) values. In terms of time per node generation, RBFS is about 29% slower tl1a.n WIDA*, and about a factor of three faster than WA*. The reason that RBFS and WIDA* are faster than WA* is that they are purely recursive algorithms with no Open or Closed lists to maintain. The magnitude of these differences is due to the fact that node generation and evaluation is very efficient for the sliding-tile puzzles, and these d ifferences would be smaller on more complex problems. Related Work In comparing RBFS to other memory-limited al- gorithms such as hfR.EC[Sen & Bagchi 1989], hIA*[Chakrabarti et al. 19891, DFS*[Rao, Kumar, & Iiorf 19911, IDA*-CR[Sarkar et a.1. 19911, hIIDA*[Wah 1991], ITS[hIahanti et al. 19921, IE[Russell 19921, and ShIA*[Russell 19921, the most important differ- ence is that none of these other algorithms expand nodes in best-first order when the cost function is non- monotonic. IIowever, many of the techniques in these algorithms can be applied to RBFS as well, in order to reduce the node regeneration overhead. Recently, we became aware of the Iterative Expan- sion (II?,) algorit~hm[Russell 19921, which was developed independently. IE is virtually identical to SRBFS, ex- cept that, A node always inherits its parent’s cost if the parent’s cost is great’er than the child’s cost. As a. re- sult, IE is not a best-first search with a non-monotonic cost function, but, behaves the same as RBFS for the special ca.se of a monotonic cost function. The per- formance of IE on our sliding-tile puzzle experiments should be very similar to that of WIDA*. Some of the ideas in RBFS, IE, hIA*, and RIREC, in particular using the value of the next best brother as an upper bound, and backing up the minimum values of children to their parents, can be found in Bra.tko’s for- mulation of best-first search[BratBo 19861, which uses es1~0nentia.1 space, however. Korf 537 Conclusions RBFS is a linear-space algorithm that a.lways ex- pands new nodes in best-first order, even with a non- monotonic cost function. While its time complexity depends on the cost function, for the special case where cost is equal to depth, corresponding to breadth-first, search, RBFS is asymptotically optimal, generating O(bd) nodes. With a monotonic cost function, it finds optimal solutions, while expanding fewer nodes than iterative-deepening. With a non-monotonic cost func- tion on the sliding-tile puzzles, both RBFS and iter- ative deepening generate orders of magnitude fewer nodes than required to find optimal solutions, with only small increases in solution lengths. RBFS consis- tently finds shorter solutions than iterative deepening with the same cost function, but also generates more nodes in this domain. The number of nodes generated by RBFS was a constant multiple of the nodes t1la.t would be generated by standard best-first search on a tree, if sufficient memory were available to execute it. Thus, RBFS reduces the space complexity of best-first search from exponential to linear in general, while in- creasing the time complexity by only a constant factor in our experiments and analyses. References Bratko, I., PROLOG: Programming for Artificial In- telligence, Addison-Wesley, 1986, pp. 2G5-273. Chakrabarti, P.P., S. Ghose, A. Acharya, and S.C. de Sarkar, Heuristic search in restricted memory, Artifi- cial Intelligence, Vol. 41, No. 2, Dec. 1989, pp. 197- 221. Davis, H.W., A. Bramanti-Gregor, and J. Wang, The advantages of using depth and breadth components in heuristic search, in Methodologies for Intelligent Systems 3, Z.W. Ras and L. Saitta (Eds.), North- Holland, Amsterdam, 1989, pp. 19-28. Dijkstra, E.W., A note on two problems in connexion with graphs, Numerische Mathematih, Vol. 1, 1959, pp. 269-71. Gaschnig, J. Performance measurement and an.aly- sis of certain search algorithms, Ph.D. thesis, Depart- ment of Computer Science, Carnegie-hlellon Univer- sity, Pittsburgh, Pa, 1979. Hart, P.E., N.J. Nilsson, and B. Raphael, A formal basis for the heuristic determination of minimum cost paths, IEEE Transactions on Systems Science and Cybernetics, Vol. 4, No. 2, 1968, pp. 100-3.07. Korf, R.E., Depth-first itera.tive-deepening: A11 optsi- oral admissible tree search, Artificial Intelligence, j’ol. 37, No. 1, 1985, pp. 97-109. korf, R.E., Real-time heuristic search, Arl$cinl In- telligence, Vol. 4-, 3 No. 3-3, hlarcll 1990, pp. 189-311. Korf, R.E., Real-Time search for dynamic planning, Proceedings of the AAAI Symposium on Plwning in Uncertain, Unpredictable, or Changing Environ- ments, Stanford, Ca., March 1990, pp. 72-76. Korf, R.E., Best-first search in limited memory, in UCLA Computer Science Annual, University of Cal- ifornia, Los Angeles, Ca., April, 1991, pp. 5-22. Korf, R.S., Linear-Space Best-First Search: Extended Abstra.ct, Proceedings of the Sixth International Sym- posium on Computer and Information Sciences, An- talya, Turkey, October 30, 1991, pp. 581-584. Korf, R.E., Linear-space best-first search, submitted for publication, August 1991. RJahanti, A., D.S. Nau, S. Ghosh, and L.N. Kanal, An Efficient Iterative Threshold Heuristic Tree Search Algorithm, Technical Report UMIACS TR 92-29, CS TR 2853, Computer Science Department, University of hlaryland, College Park, Md, March 1992. Patrick, B.G., M. Almulla, and M.M. Newborn, An upper bound on the complexity of iterative- deepening-A*, in Proceedings of the Symposium on Artificial Intelligence and Mathematics, Ft. Laud- erdale, Fla., Dec. 1989. Pearl, J. Heuristics, Addison-Wesley, Reading, Mass, 1984. Pohl, I., Heuristic search viewed as path finding in a graph, Artificial Intelligence, Vol. 1, 1970, pp. 193- 204. Rao, V.N., V. Kumar, and R.E. Korf, Depth-first vs. best-first search, Proceedings of the National Confer- ence 011 Artifkial Intelligence, (AAAI-91), Anaheim, Ca., July, 1991, pp. 434-440. Ruby, D., and D. Kibler, Learning subgoal se- quences for planning, Proceedings of the Eleventh In- tern.ational Joint Conference on Artificial Intelligence (IJCAI-89), Detroit, Mich, Aug. 1989, pp. 609-614. Russell, S., Efficient memory-bounded search meth- ods, Proceedings of the Tenth European Conference on Artilfcial Intelligence (ECAI-92), Vienna, Austria, Aug., 1992. Sarkar, U.K., P.P. Chakrabarti, S. Ghose, and S.C. DeSarkar, Reducing reexpansions in iterative- deepening search by controlling cutoff bounds, Ar- tificial Intelligence, Vol. 50, No. 2, July, 1991, pp. 207-221. Sen, A.K., and A. Ba.gchi, Fast recursive formulations For best-first search that allow controlled use of mem- ory, Proceedings of the 11th International Joint Con- ference on Artificial Intelligence (IJCAI-89), Detroit, h$ichigan, Aug., 1989, pp. 297-302. Wall, B.W., MIDA*, An IDA* search with dy- namic control, Technical Report UILIJ-ENG-91- 2216, CRIIC-91-9, Center for Reliable and High- Performance Computing, Coordinated Science Labo- ratory, IJniversity of Illinois, Urbana, Ill., April, 1991. 538 Problem Solving: Search and Expert Systems | 1992 | 93 |
1,291 | Arnbuj ahanti+ ana S. l!+Jau§ Asian al Systems Res. Ctr. Comp. Sci. Dept. Comp. Sci. Dept. IIM, Calcutta Clomp. Sci. Dept. U. of Maryland U. of Maryland U. of Maryland Calcutta U. of Maryland College Park College Park College Park 700 027 College Park MD 20742 MD 20742 MD 20742 India MD 20742 Abstract We present the following results about IDA* and related algorithms: We show that IDA* is not asymptotically op- timal in all of the cases where it was thought to be so. In particular, there are trees satisfy- ing all of the conditions previously thought to guarantee asymptotic optimality for IDA*, such that IDA* will expand more than O(N) nodes, where N is the number of nodes eligible for ex- pansion by A*. We present a new set of necessary and suf- ficient conditions to guarantee that IDA* ex- pands O(N) nodes on trees. On trees not satisfying the above conditions, there is no best-first admissible tree search algo- rithm that runs in S = w?vq (where 1CIP) # 0( 1)) memory and always expands O(N) nodes. There are acyclic graphs on which IDA* ex- pands $422N) nodes. Introduction Heuristic search is applicable to a wide range of combi- natorial optimization problems. The objective of many heuristic search algorithms is to find a minimum cost solution path in a directed graph G. A solution path is a path from the start node s to a goal node. To find such a path, many algorithms use a node evaluation function f(n) = g(n) + hW *Supported in part by NSF Grant IRI 8802419, NSF Grant NSFD CDR-88003012 to the University of Mary- land Systems Research Center, NSF grant IRI-8907890, and CMDS project (Work order no. 019/7-148/CMDS- 1039f 90-91.) ‘Also in the Computer Science Department. Email: am@cs.umd.edu ‘Email: subrata@cs.umd.edu §Also in the Systems Research Center and the Institute for Advanced Computer Studies. Email: nau@cs.umd.edu ¶Email: kanal@cs.umd.edu where g(n) is the cost of a least-costly path currently known from s to n, and h(n) 2 0, the heuristic value of node n, is an estimate of h*(n). h is called the heuristic function and h*(n) is the cost of a minimum cost path from n to a goal node. A heuristic function h is called admissible if Vn E G, h(n) < h*(n). The function h is said to be monotone if ‘dp E G, h(p) 5 c(p, q) + h(q), where Q is a child of p. A* (Hart & Nilsson & Raphael 1968; Nilsson 1980) is a well-known heuristic search algorithm. A* has been shown to be very efficient in terms of number of node expansions (which is also a measure of its time com- plexity) in most cases (Dechter Sr; Pearl 1985). How- ever, one major problem with A* is that it requires exponential amount of memory to run. Due to this, A* runs out of memory even on problem instances of moderate size. To overcome the storage problem, a variant of A* called IDA* (Iterative Deepening A*) was introduced (Korf 1985; Korf 1988). IDA*‘s memory requirement is only linear in the depth of the search. This enables IDA* to solve much larger problems than that A* can solve in practice. One of IDA*% most important properties is that un- der certain conditions it is “asymptotically optimal in time and space over the class of best-first searches that find optimal solutions on a tree” (Korf 1988, p. 236). In this paper, we present the following results: 1. We show that IDA* is not asymptotically optimal in all of the cases where it was thought to be so. In particular, there are trees satisfying all of asymptotic optimality conditions given in (Korf 1988)) such that IDA* will expand more than O(N) nodes, where N is the number of nodes eligible for expansion by A*.l In addition, we present necessary and sufficient con- ditions for the desired O(N) worst-case time com- plexity of IDA* for tree searches. ‘Previous p a p ers have described trees on which IDA* expands more than O(N) nodes (Mahanti & Pal 1990; Patrick & Almulla & Newborn 1991), but the trees de- scribed in these papers did not satisfy Korf’s (1988) require- ments of finite precision and non-exponential node costs. Mahanti, et al. 539 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. For exponential search spaces with maximum node- branching factor bounded by a constant and with admissible heuristic, there does not exist any best- first admissible tree search algorithm which when running with S = WW) (WV # Q(l)) memory 7. have the O(N) worst-case time complexity like . When the heuristic is monotone, A* handles a graph like a tree and it never expands a node more than once. But for graphs, IDA* can not prevent the reex- pansion of a node through a costlier path. Thus, for graph search problems the performance of IDA* is bound to become worse than A*. We show that if we let the node-branching factor to grow with the prob- lem size, A* under monotone heuristic has Q(N) worst-case time complexity for general graphs, but IDA* under monotone heuristics has Q(22N) worst- case complexity for acyclic graphs. And, the total number of node expansions by IDA* can only in- crease in presence of cycles. There are many graph and tree search problems where the node-branching factor grows with the problem’size. Traveling sales- man, flow-shop scheduling, etc. are such examples. Due to space limitations, in this paper we omit the proofs of our theorems. For proofs, readers are referred to (Mahanti et al. 1992). DA* on Trees In this section we first define a set of basic symbols that will be used through out the paper, and then formally characterize the working of IDA*. Here we assume that the state space G is a tree, the maximum node- branching factor in G is bounded by a constant b > 0, and every arc of G has a cost 2 6, where 6 is a small constant. For each z > 0, we define WG(z) as follows: (i) P = (s) is in WG(z) if s is not a goal node and h(s) 5 z. (ii) For each path P = (s, nl , . . . , nk) in G, P is in WG (z) if the following conditions are satisfied: (a) nk is not a goal node, (b) The subpath P’ = (s, nl, . . . , ns-1) is in WG(z), and (c) cost(P) + h(nk) 5 z. We also define vG (4 = {mlm is a node in a path in WG(z)); JlfG (4 = lVG(%)l. Since by assumption the maximum node-branching factor b is a constant, and each arc (m, n) in G has a cost at least 6, it directly follows that for each z > 0, each of the entities defined above is finite. We define fi, i = 1,2, . . . , inductively as follows: fl = h(s); fi = mib{f(n)l n is a child of tip(P) and P is a maximal path in WG(fi-I)}, where by a maximal path P in WG(fi- I), we mean a path which is not a proper subpath of any other path in WG(fd-r). Al so, by tip(P) of a path P, we mean the last node on P. We let IG be the total number of iterations per- formed by IDA* on G, and ZG(l) < ZG(2) < . . . < ZG(IG) be the (distinct) threshold values used by IDA*. For j = 1,2,..., I, IDA*‘s j’th iteration is the set of all node expansion instants for which the threshold is z(j). By expansion of a node n in IDA*, we mean the gen- eration of at least one child of n. For each j, we define xG (8 = the set of nodes expanded by IDA* during iteration j; x”(j) = the number of nodes expanded by IDA* during iteration j; xnGew (3 = the set of new nodes expanded by IDA* during iteration j; xnGew (8 = the number of new nodes expanded by IDA* during iteration j; G xtot = the total number of node expansions done by IDA* on 6. In the terms defined above, we will usually omit the superscript G if the identity of G is clear. Alterna- tively, if we are discussing two state spaces G and G’, we will use X(j) for XG(j), X’(j) for X”‘(j), and so forth. From the above definitions, it follows immediately that X(l), . X,,,(j) = 1; X(j)-X(j-l), ;:2,3,...;(l) I I xtot = C x(j) = C IXW (2) j=l j=l Theorem 1 43 = fj, j = 1,. . . , I; (3) X(j) = V(fj), j= l,... J-1; (4) 43 = N(fi), j= l,... J-1; (5) Xnew (j) = C V(fl)> V(fj) - V(fj-I), j x ii: se.) I-li(6) xnew(j) = C Jqfl), ./V(fj)-N(fj-I),: z f:. a., .s?-J.~(~) Furthermore, X(I) E V(f1); xnew(I) C V(f1) - V(fr-1); xnew(4 L N(f1) - N(f1-1); with equality in the worst case. Corollary 1 f1 z h*(s). (8) (9) (10) 540 Problem Solving: Search and Expert Systems In view of the above corollary, we make the following definitions: WG = Wfr); vG = Y(P,); NG = hf(fr); LG = 1 + PLUG the number of nodes in P. In the above, we will omit the superscript G when the identity of G is clear. For example, given a network G, by N we shall mean the total number of nodes in G which are eligible for expansion by A*. The heuristic branching factor is defined as the average, over j = 2,... , I, of the quantity znew(j)/xnew(j - 1). Intuitively, this is the average ratio of the number of nodes of each f-value (assum- ing that the heuristic is monotone) to the the number of nodes at the next smaller f-value (Korf 1988). Under the premise that G is a tree with maximum node-branching factor b, and with admissible heuris- tics, Korf (1988) h as shown that the worst-case asymp- totic time complexity of IDA* is O(N) if the following conditions (labeled as mandatory and secondary) are true: Mandatory Condition: Heuristic Branching Factor > I. Secondary Conditions: 1. The search space must be exponential in the depth of the solution; 2. Representation of costs must be with finite preci- sion; 3. Cost values must not grow exponentially with depth. The first condition was used explicitly in the op- timality proof of IDA* (thus we call it a mandatory condition), and the other conditions appeared as pass- ing remarks (thus we call them secondary conditions). In the next section we show that these conditions are neither sufficient nor necessary to ensure the O(N) complexity of IDA*. We illustrate through examples that even when all of the above conditions are satis- fled, IDA* fails to achieve O(N) time complexity in the worst-case. IDA* on Example Trees In this section we illustrate through examples that the analysis of IDA* given in (Korf 1988) does not hold in general. We present constructions of example trees which satisfy the conditions stated in the previous sec- tion but yet IDA* fails to achieve O(N) worst-case time complexity while run on these trees. We also show that these conditions are not necessary either, i.e. IDA* can have O(N) complexity without satisfying these condi- tions. Example 1. In the search tree G given in Figure 1, each non-leaf node has a node-branching factor b = 2, and each arc has unit cost. G consists of two subtrees (called G1 and Gz) where each one is a full binary tree of height k. Gz is rooted at the right most node of G1. Every leaf node, except the one labeled as goal, is a non-terminal leaf node. For each node n in G, we assume h(n) = 0. Then h is monotone. The heuristic branching factor is 2k+&i+2(k-1) =2+ I w 1 M2 I_-- k2k k ’ Note that the goal node is at a depth of 2k = O(logN), where N is the total number of non-goal nodes in G. Therefore the search space is exponential. The maxi- mum cost value is 2k which grows only linearly with depth. The precision constraint is vacuously satisfied because the cost values are not fractions. Thus, all con- ditions (mandatory and secondary) are satisfied. Now we calculate the total number of node expansions by IDA* on the tree G. Clearly G1 and G2 each contain N’ = [N/21 nodes. The cost of the solution path is 2k = P[log,(N’+l)-11. Let No = bk + 2b”” + 3bk-2 + . . . + kb. Then the total number of node expansions by IDA* in the worst-case is xtot = No + kN’ + No 2 kN’+N’=k(N’+l) = Q(Nlog N). In the example above, we have shown that the condi- tions stated in (Korf 1988) for the asymptotic optimal- ity of IDA* are not sufficient. In the following example we show that these conditions are not necessary either. Example 2. Consider the search tree G in Figure 2. G consists of two subtrees G1 and 62. Gr is a full binary tree with N’ nodes and G2 contains a constant c number of nodes in the form of a degenerate tree. Every leaf node in G is a non-terminal node except the rightmost one (pc), which is a goal node. Each arc has cost 1, h(s) = k and heuristic value at all other nodes is zero. G contains total N = N’ + c - 1 non- goal nodes and one goal node. All the nodes of G1 will be expanded by IDA* in the first iteration. Thereafter, in each iteration only one new node will be expanded. The heuristic branching factor is Since the total number oiiterations (c+l) is constant, IDA* will expand only O(N) nodes on trees of type 6. Note that the mandatory condition stated previously is not satisfied in this case. In the following section we derive a new set of (nec- essary and sufficient) conditions for asymptotic opti- mality of IDA*. Mahanti, et al. 541 S = 720 G2 +2 Figure 1: IDA* SJ( N log N). Asymptotic Qptimality of IDA* Let bl > 1. Then IDA*‘s active iterations on G are the iterations iG iG 1 , 2 , . . . , izG defined inductively as follows: if = 1. For p = 2,...,u, ip” is the smallest integer such that x new(iG)/xnew(i~~~> L h. As usual, we omit the superscript G when the identity of G is obvious. Intuitively the active iterations are the iterations in which the number of new nodes expanded by IDA* grows exponentially. We call the remaining iterations dummy iterations. For each $,, let jPl, jP2,. . . , jPC, be the dummy iterations immediately following the active iteration iP. Dummy iterations can occur anywhere after the first active iteration il. For Q = 1,. . . , u, let cq be the num- 1 ber of dummy iterations that occur between iterations i, and i,+l . Note that cq 2 0, and cl + c2 + . . . + c, = I - u. We define MG = maxP cq, i.e., iVG is the max- imum number of adjacent dummy iterations. The total number of node expansions by IDA* de- pends not only on the number of dummy iterations but also on their positions. In the following theorem we show that, keeping the total number of iterations I and the number of active iterations u fixed, the total number of node expansions by IDA* increases as the dummy iterations are moved to the right, i.e. a dummy iteration j is moved to k where k > j. In particular the theorem states that the total number of node expan- sions xtot attains its maximum when all the dummy iterations appear after the last active iteration. Theorem 2 For all positive integers No, us, lo, let G(Ne, us, 10) be the set of all trees G for which N = NO, S = no nk Pl P2 PC-1 PC a -4 A/ Gl G2 Figure 2: IDA* O(N). U = ug, and I = le. Then for each N, u, 1, the maxi- mum value of zfot over all trees G E S(N, u, 1) occurs in a tree G for which all dummy iterations occur after the last active iteration, i.e., cl = c2 = . . . = c,-1 = 0. Theorem 3 provides a sufficient condition for asymp- totic optimality of IDA*. It states that IDA* expands O(N) nodes in every tree in which the maximum num- ber of adjacent dummy iterations is bounded by a con- stant. Theorem 3 Let G = (Gl, G2, . . .) be any arbitary sequence of trees such that M = O(1) in G. Then xtot = O(N) in S. Although the condition stated in Theorem 3 is suf- ficient for O(N) node expansions by IDA*, it is not a necessary condition. The necessary condition is stated in Theorem 4, which can be proved using Lemma 1 (see (Mahanti et a!. 1992) for details). The lemma shows that if a tree 6’ is constructed from G in such a way that 6’ is identical to G except that one node n in G’ has a higher f-value than in G, i.e. fG’(n) > fG(n), then the total number of node expansions by IDA* on G’ will be less than the number of node expansions by IDA* on G. What this means is that if a new prob- lem instance is created from an old problem instance of IDA* by pushing a new node of iteration j to the iter- ation k, such that k > j, then xtot in the new problem instance will be less than in the old problem instance. The lemma holds for the simple reason that the nodes in earlier iterations are expanded more number of times than nodes in later iterations. Lemma 1 Let G be any tree such that I _> 2, and let lsj<k<I.Ifx new(j) such that F = I - 1 and = 1, then let G’ be any tree 4,,(i) = %3v(i), i = 1,. . .,j - 1; 542 Problem Solving: Search and Expert Systems 3$,,(i) = %lew(i + l), i = j, . . . , k - 2; x;,,(k - 1) = xnew(k) + 1; x;,,(i) = GlevQ(~ + l), i= k,...,I-1. Otherwise, let G’ be any state space such that I’ = I and x;%Ji) =, %x?w(i), a’= l,...,j-1; x’,,,(j) = xnew(j) - 1; x&(i) = xrlew(~), i= j+l,...,k- 1; x’,,,(k) = xnew(k) + 1; x;,,(i) = xnew(i+ I), i= k+l,...,I. Then xiot < xtot. The following theorem says that IDA* achieves O(N) node expansions only if the number dummy it- erations after the last active iteration is bounded by a constant. Theorem 4 Let g = (Gl, G2,. . .) be any arbitary sequence of trees. Then in 9, xtot = O(N) only if c, = O(1). Limited-Memory Search on ees In this section, we show that in general, limited- memory best-first search algorithms can not always perform as well as A*, even on trees. Let G be a tree, and d be any search algorithm used to search G. A stores a node n if during the current state of d’s execution, A contains information about the identity of node n (plus possibly some other information about n). A properly stores node n if it stores not only n, but also at least one of the parents of n. A properly runs in storage S 2 0 if at all times during its operation, it properly stores no more than S nodes. Lemma 2 Let G be a b-ary tree that is complete to depth k for some k > 0, and A be a search algorithm that properly runs in storage S on 6. Let d be the smallest integer such that S 5 w. If d < k, then A properly stores no more than b” of the nodes at depth d + 1 of G. Let dbf be any limited-memory best-first tree search algorithm. An algorithm is said to perform a best-first search in limited memory on tree G if for each z > 0, it does not expand any node of VG(z) before expanding every node of VG (2’) at least once, for all z’ < Z. Note that IDA*, MA* (Chakrabarti et aZ. 1989), MREC (Sen & Bagchi 1989) are all limited-memory best-first tree search algorithms. The following theorem states that there exists no best-first tree search algorithm, which while using less than a constant fraction of the memory used by A*, can have the same worst-case time complexity as A* on all trees. Its proof uses the result of lemma 2. n5 - Figure 3: IDA* is s2(22N). Theorem 5 There does not exist any best-first al- gorithm .Aaf such that for every sequence of trees G = (6 G2,. . .), daf has O(N) complexity and prop- erly runs in S = & memory, where $(N) is a func- tion that is # O(1). A* on Acyclic Graphs What happens if we run IDA* on directed acyclic graphs? For graphs with monotone heuristic, when a node n is expanded by A*, g(n) = g*(n) and A* does not expand a node more than once. Since IDA* runs in linear memory, it can not store all expanded nodes for future duplicate checking as in A*. Thus IDA* can expand a node several times due to both its limited- memory nature and unfolding of a graph into tree. It has been shown previously (Korf 1988) that depth-first search can expand exponential (in N) number of nodes on a directed acyclic graph with N nodes. We extend this result to IDA* and show that IDA* can expand Q(22N) nodes on directed acyclic graphs with N nodes. The following example demonstrates the worst-case be- havior of IDA* on directed acyclic graphs. Example. Consider the search graph G shown in Figure 3. We can generalize the graph with N = k + 1 non-goal nodes and one goal node. Let no be the start node and nk+l be the goal node. The cost structure is defined as follows: c(no,ni) = 2i-1, l<isk; c(nl,nk+l) = 2’ - 1; c(ni,n;-1) = 26-2, l<i<k; c(ni,nj) = 2jw1, l<j<i, l<i<k; h(q) = 0, OQ<k+l. It can be easily seen that the unfolded tree of G will contain nodes of all f-values from 0 through 2N. Therefore the total number of node expansions will be O(N) for A*, and s2(22N) for IDA*. The following theorem gives total number of node expansions case on trees and graphs. upper bounds on the by IDA* in the worst- Mahanti, et al. 543 Theorem 6 IDA* makes no more than N2 node ex- pansions on trees, and no more than 22N node expan- sions on acyclic graphs. Conclusion We have presented the following results about IDA* and related algorithms: 1. The conditions stated by Korf (1988) are not suffi- cient to guarantee asymptotic optimality of IDA*; i.e., IDA* will perform badly in some of the trees on which it was thought to be asymptotically optimal. Pearl, J. 1984. Heuristics, Intelligent Search Strate- gies for Computer Problem Solving, Addison-Wesley. Sen, A., and Bagchi A. Fast Recursive Formulations for Best-First Search That Allow Controlled Use of Memory. 1989. In Proceedings of the Eleventh Inter- national Joint Conference on Artificial Intelligence, 297-302. 2. The above failing is not unique to IDA*, for in gen- eral, no best-first limited-memory heuristic search algorithm can be asymptotically optimal. 3. We have presented necessary and sufficient condi- tions for IDA* to be asymptotically optimal. Our conditions show that IDA* is asymptotically opti- mal in a somewhat different range of problems than was originally believed. 4. On graphs, with a monotone heuristic IDA* can per- form exponentially worse than A*. Thus, on graphs it may be preferable to use a graph search algorithm rather than using IDA*. References Chakrabarti, P.; Ghosh, S.; Acharya, A.; and De Sarkar, S. 1989. Heuristic Search in Restricted Mem- ory. AI Journal 41 (1): 197-221. Dechter, R.; and Pearl, J. 1985. Generalized Best- First Search Strategies and the Optimality of A*. JACM 32 (3): 505-536. Hart, P. E.; Nilsson, N. J.; and Raphael, B. 1968. A Formal Basis for the Heuristic Determination of Minimum Cost Paths. IEEE Trans. Syst. Cybern. 4 (2): 100-107 Korf, R. 1985. Depth First Iterative Deepening: An Optimal Admissible Tree Search. AI Journal 27 (1): 97-109. Korf, R. 1988. Optimal Path Finding Algorithms, Search in AI. Edited by Kanal, L., and Kumar, V., Springer Verlag, Symbolic Computation: 200-222. Mahanti, A., and Pal, A. 1990. A Worst-cast Time Complexity of IDA*. In Proceedings of SCCC-10 In- ternational Conference in Computer Science, 35-45. Santiago de Chile. Mahanti. A., Ghosh, S., Nau, D. S., Pal, A. K., Kanal, L. 1992. On the Asymptotic Optimality of IDA*, Technical Report, CS-TR-2852. Dept. of Computer Science, University of Maryland. Patrick, B. G.; Almulla, M.; and Newborn, M. M. 1991. An Upper Bound on the Complexity of Iterative-Deepening-A *. Annals of Mathematics and Artificial Intelligence. Forthcoming. Nilsson, N. J. 1980. Principles of Artificial Intelli- gence, Tioga Publications Co., Palo Alto, CA. 544 Problem Solving: Search and Expert Systems | 1992 | 94 |
1,292 | Am Average-Case with Applications: Summary of Weixiong Zhang and Richard E. Korf * Computer Science Department University of California, Los Angeles Los Angeles, CA 90024 Email: <last-name>@cs.ucla.edu Abstract # of nodes generated Motivated by an anomaly in branch-and-bound (BnB) search, we analyze its average-case com- plexity. We first delineate exponential vs poly- nomial average-case complexities of BnB. When best-first BnB is of linear complexity, we show that depth-first BnB has polynomial complexity. For problems on which best-first BnB haa expo- nentia.1 complexity, we obtain an expression for the heuristic branching factor. Next, we apply our analysis to explain an anomaly in lookahead search on sliding-tile puzzles, and to predict the existence of an a.verage-case complexity transition of BnB on the Asymmetric Traveling Salesman Problem. Finally, by formulating IDA* as cost- bounded BnB, we show its aaverage-case optima.l- ity, which also implies tl1a.t RBFS is optimal on avera.ge . Introduction Consider a. simple search problem. We define a uni- form random tree as a. tree of depth d, branching fac- tor B, random edge costs independently and identi- cally drawn from a. non-negative discrete probability distribution, and node costs computed as the sum of the edge costs on the path from the root to the node. The problem is to find a. frontier node at depth d of minimum cost. A uniform random tree is an abstract model of the state space of a, discrete optimiza,tion problem, with a cost function that is monotonically non-decreasing along a path. One of the most efficient linear-space algorithms for this problem is depth-first branch-and-bound (BnB) [Kumar 921. Depth-first BnB starts with an upper bound of infinity on the minimum goal cost, and then searches the entire tree in a depth-first fashion. When- ever a node at depth d is reached whose cost is lower *This research was supported by an NSF Presidential Young Investigator Award, No. IRI-8552925, to the second author and a grant from Rockwell International. Thanks to Joe Pembert& and Hui Zhou for many helpful discussions, and to Lars Hagen for pointing out an error in a draft. 100 150 200 search horizon d Figure 1: Anomaly of depth-first BnB. than the best one found so far, the upper-bound is re- vised to the cost of this node. Whenever an internal node is encountered whose cost equals or exceeds the current upper bound, the subtree below it is pruned. The most important property of depth-first BnB is that it only requires space that is linear in the search depth, since only the nodes on the path from the root to the current node must be stored. One drawback of depth-first BnB is that it may expand nodes with costs greater than the minimum goal cost. Best-first BnB [Kumar 921, or best-first search, al- wa.ys expands a node of least cost among all nodes which have been generated but not yet expanded, and as a result, never expands a node whose cost is greater than the minimum goal cost. To guarantee this, how- ever, best-first BnB has to store all frontier nodes, making it useful only for small problems because of memory limitations. Figure 1 shows the performance of depth-first BnB on uniform random trees with edge costs drawn inde- pendently and uniformly from (0, 1,2,3,4}. The x-axis Zhang and Korf 545 From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. is the search depth d, and the y-axis is the number of nodes generated. The straight dotted lines on the left show the complexity of brute-force search, which gen- erates every node in the tree, or (Bd+l - l)/(B - 1) = O(Bd). The curved lines to the right represent the number of nodes generated by depth-first BnB, aver- aged over 1000 random trials. Figure 1 shows two ef- fects of depth-first BnB. First, it is dramatically more efficient than brute-force search. Secondly, depth-first BnB displays the following counterintuitive anomaly. For a given amount of computation, we can search deeper in the larger trees. Alternatively, for a given search depth, we can search the larger trees faster. We explore the reasons for this anomaly by ana- lyzing the average-case complexity of BnB. We first discuss the behavior of the minimum goal cost. We then discuss the average-case complexity of BnB. As applications of our analysis, we explain this anomaly in lookahead search on sliding-tile puzzles [Korf 901, and predict the existence of an average-case complexity transition of BnB on Asymmetric Traveling Salesman Problems (ATSP) [La.wler et al. $53. Iterative-deepening-A* (IDA*) [Korf $53 and recur- sive best-first search (RBFS) [Korf 921 are also linear- space search algorithms. By formulating IDA* as cost- bounded BnB, we show its average-case optimality. This leads to the corollary that RBFS is also optimal on average. Finally, we discuss the knowledge/search tradeoff. The proofs of theorems are omitted due to space limitations, but a full treatment of the results is in [Zhang 6c Korf 921. Properties of Minimum Goal Cost A uniform random tree models the state space of a dis- crete optimization problem. In general, a state space is a graph with cycles. Nevertheless, a tree is an ap- propriate model for analysis for two reasons. First, any depth-first search must explore a tree at the cost of generating some states more than once. Secondly, many operators used in practice for some optimization problems, such a,s the ATSP, partition the state space into mutually exclusive parts, so that the space visited is a tree. If po is the probability that an edge has zero cost, and B is the branching factor, then Bpo is the expected number of children of a node that have the same cost as their parent (same-cost children). When Bpo < 1, the expected number of same-cost children is less than one, and the minimum goal cost should increa.se with depth. On the other hand, when Bpo > 1, we should expect the minimum goal cost not to increase with depth, since in this case, we expect a minimum- cost child to have the same cost as its parent. Lemma 1 [McDiarmid & Provan 911 On a uniform random tree, asymptotically the minimum goal cost grows linearly with depth almost surely when Bpo < 1, and is asymptotically bounded above by a constant al- most surely when Bpo > 1. 0 Average-Case Complexity Given a frontier node value, to verify that it is of mini- mum cost requires examining all nodes that have costs less than the given value. When Bpo < 1, minimum- cost goal nodes are very rare, their cost grows linearly with depth, and the average number of nodes whose costs are less than the minimum goal cost is exponen- tial. Thus, any search algorithm must expand an expo- nential number of nodes on average. The extreme case of this is that no two edges have the same cost, and thus po = 0. On the other hand, when Bpo > 1, there are many nodes that have the same cost, and there are many minimum-cost goal nodes as well. In this case, best-first BnB, breaking ties in favor of deeper nodes, and depth-first BnB can easily find one minimum-cost goal node, and then prune off the subtrees of nodes whose costs are greater than or equal to the goal cost. The extreme case of this is that all edges have cost zero, i.e. po = 1, and hence every leaf of the tree is a minimum-cost goal. Best-first BnB does not need to expand an exponential number of nodes in this case. Theorem 1 [McDiarmid & Provan 911 On a uniform random tree, the average-case complexity of best-first BnB is exponential in the search depth d, when Bpo < 1, and the average-case complexity of best-first BnB is linear in d, when Bpo > 1. 0 Theorem 1 also implies that depth-first BnB must generate an exponential number of nodes if Bpo < 1, because all nodes expanded by best-first BnB are ex- amined by depth-first BnB as well, up to tie-breaking. What is the average-case complexity of depth-first BnB when Bpo > 1 ? In contrast to best-first BnB, depth- first BnB ma.y expand nodes that have costs greater than the minimum goal cost. This makes the anal- ysis of depth-first BnB more difficult. An important question is whether depth-first BnB has polynomial or exponential a.verage-case complexity when Bpo > 1. In fact, depth-first BnB is polynomial when Bpo > 1. Theorem 2 When Bpo > 1, the average-case com- plexity of depth-first BnB on a uniform random tree is bounded above by a polynomial function, O(d*+‘), if edge costs are independently drawn from (0, 1, . . . . m), regardless of the probability distribution. 0 For example, in Figure 1, po = 0.2, thus Bpo > 1 when B 2 6. By experiment, we found that the curves for B > 6 can be bounded above by the function y = O.O75d’+ 8.0d2 + 8.0d + 1.0, which is O(d3). The above analysis shows that the average-case com- plexity of BnB experiences a dramatic transition, from exponential to polynomial, on discrete optimization problems, depending on the branching factor B and the cost function (~0). When Bpo < 1, both best- first BnB and depth-first BnB take exponential aver- age time. On the other hand, when Bpo > 1, best-first BnB and depth-first BnB run in linear and polynomial average time, respectively. Therefore, the average-case 546 Problem Solving: Search and Expert Systems 0.8 - 0.6 - easy region branching factor B Figure 2: Difficult and ea.sy regions for BnB. Figure 3: Anomaly of lookahead search [Korf 901. complexity of BnB changes from exponential to poly- nomial as the expected number of same cost children, Bpo, changes from less than one to greater than one. Figure 2 illustrates these two complexity regions and the transition boundary. For a uniform random tree with Bpo < 1, the hezlris- tic branching factor of the tree measures the complex- ity of the problem modeled by the tree. The heuristic branching factor of a problem is the ra.tio of the aver- age number of nodes with a given cost to the average number of nodes with the next smaller cost. Theorem 3 When. Bpo < 1 and edge costs are 0, 1, . ..) m with probabilities po,pl, . . ..p., the asymp- totic heuristic branching factor b of a uniform random tree is a solution greater than one to the equation, Xrn - B 2 pix~-i = o. Cl (1) d=O Although there exists no closed-form solution to this equation in general when 172 2 5, it can be solved nu- merically. Applications Anomaly of Lookahead Search A sliding-tile puzzle consists of a k x k square frame holding k2 - 1 mova.ble square tiles, with one space left over (the blank). Any tiles which are horizontally or vertically adja.cent( to the blank may move into the blank position. Exa.mples of sliding-tile puzzles include the 3 x 3 Eight Puzzle, the 4 x 4 Fifteen Puzzle, the 5 x 5 Twenty-four Puzzle, and the 10 x 10 Ninety-nine Puzzle. A common cost function for sliding-tile puz- zles is f(n) = g(n)+h(n), where g(n) is the number of steps from the initial state to node n, and h(n) is the Manhattan Dista,nce [Pea.rl 841 from node 12 to the goal 0 10 20 30 40 50 lookahead depth d state. The Man hattan Distance is computed by count- ing, for each tile not in its goal position, the number of moves along the grid it is away from its goal, and sum- ming these values over all tiles, excluding the blank. A lookahead search to depth /C returns a node that is k: moves away from the original node, and whose f value is a minimum over all nodes at depth Ic. The straight dotted lines on the left of Figure 3 represent the total number of nodes in the tree up to the given depth, for different size puzzles. The curved lines to the right represent the total number of nodes generated in a depth-first BnB to the given depth using Manhat- tan Distance (avera.ging over 1000 randomly generated initial states). This shows the same anomaly as in Fig- ure 1, namely that the larger problems can be searched faster to a given depth. The explanation of this anomaly on sliding-tile puz- zles is the following. Moving a tile either increases its Manhattan Distance h by one, or decreases it by one. Since every move increases the g value by one, the cost function f = g + h either increases by two or stays the same. Thus, this problem can be modeled by a uniform random tree where edge costs are either zero or two. The probability that the h value either increases by one or decreases by one by moving a tile is roughly one half initially, independent of the problem size. Thus, the probability that a child node has the same cost as its parent is roughly one half, i.e. po cz 0.5. On the other hand, the branching factor B increases with the size of a puzzle. For example, the branching factors of the Eight, Fifteen, Twenty-four, and Ninety-nine Puzzles are 1.732,2.130, 2.368, and 2.790, respectively [Korf 901. Th ere ore, f a larger puzzle has a larger Bpo. According to the analysis, the asymptotic average-case complexity of fixed-depth lookahead search on a larger puzzle is smaller than that on a smaller puzzle. Zhang and Morf 547 This result does not imply that a larger sliding-tile puzzle is easier to solve, since the solution length for a larger puzzle is longer than that for a smaller one. Fur- thermore, the assumption that edge costs are indepen- dent is not valid for sliding-tile puzzles. For example, from experiments, po is slightly less than 0.5 initially, but slowly decreases with search depth. Complexity Transition of BnB on ATSP Given n cities and an asymmetric matrix (ci,j) that defines the cost between each pair of cities, the Asym- metric Traveling Salesman Problem (ATSP) is to find a minimum-cost tour visiting each city exactly once. The most efficient approach known for optimally solving the ATSP is BnB using the assignment problem solution as a lower bound function [Balas & Toth 851. The solution of an assignment problem (AP) [Martello & Toth 871, a relaxation of the ATSP, is either a single tour or a collection of disjoint subtours. The ATSP can be solved a,s follows. The AP of all n cities is first solved. If the solution is not a tour, then the problem is decomposed into subproblems by eliminat- ing one of the subtours in the solution. A subproblem is one which has some excluded arcs that are forbid- den from the solution, and some included arcs that must be present in the solution. Then a. subproblem is selected and the a.bove process is repeated until each subproblem is either solved, i.e. its AP solution is a tour, or all unsolved subproblems have costs greater than or equal to the cost of the best tour obtained so far. Many decomposition rules for the ATSP partition the state space into a. tree [Balas & Toth 851. Hence, the state space of the ATSP can be modeled by a uni- form random tree, in which the root corresponds to the ATSP, a leaf node is a subproblem whose AP solution is a tour, and the cost of a node is the AP cost of the corresponding subproblem. The AP cost is monotoni- cally non-decreasing, since the AP of a subproblem is a more constrained AP than the parent problem, and hence the cost of the child node is no less than the cost of the parent. When the intercity distances are chosen from (0, 1, **-, k}, the probability that two distances have the same va,lue decreases as rl increases. Similarly, the probability that two sets of edges have the same to- tal distance decreases as k increa.ses. Thus, when b is small with respect to the number of cities, the proba- bility that the AP value of a child is equal to that of its parent is large, i.e. po in the sea.rch tree is large. By our analysis, when b is large, po is small, and more nodes need to be examined. On the other hand, when k is small, po is large, Bpo > 1, and the ATSP is easy to solve. The a,bove analysis implies the existence of a complexity transition of BnB on ATSP as k changes. We verified this prediction by experiments using Carpaneto and Toth’s decomposition rules [CarpanetNo & Toth SO], and with intercity distances uniformly cho- sen from (0, 1,2, . . . . II]. Figure 4 gives the results on # of nodes generated I I 2400 - 1600 - 800 - loo-city ATSP 400 - 0’ I I I I I- 10’ lo3 lo5 lo7 log distance range k Figure 4: Complexity transition of BnB on ATSP. loo-city ATSPs using depth-first BnB, averaging over 1000 random trials, which clearly show a complexity transition. This transition has also been observed on 200-city and 300-city ATSPs as well. Complexity transitions of BnB on ATSP are also reported in [Cheeseman et nb. 911, where Little’s al- gorithm [Little et al. 631 and the AP cost function were used. In their experiments, they observed that an ATSP is easy to solve when the number of same- distance edges is large or small, and the most difficult problem instances lie in between these regions. There is a discrepancy between the observations of [Cheese- man et al. 911 and our observations on ATSP. This is probably due to the fact that different algorithms are used, suggesting that such transitions are sensitive to the choice of algorithm. Average-Case Optimality of IDA* and RBFS Iterative-deepening-A* (IDA*) [Korf 851 is a linear- space search algorithm. Using a variable called the threshold, initially set to the cost of the root, IDA* per- forms a series of depth-first search iterations. In each iteration, IDA* expands all nodes with costs less than the threshold. If a goal is chosen for expansion, then IDA* terminates successfully. Otherwise, the thresh- old is updated to the minimum cost of nodes that were generated but not expanded on the last iteration, and a. new iteration is begun. We may treat IDA* as cost-bounded depth-first BnB, in the sense that it expands those nodes whose costs are less than the threshold, and expands them in depth- first order. A tree can be used to analyze its average- case performance. On a tree, the worst-case of IDA* occurs when all node costs are unique, in which case only one new node 548 Problem Solving: Search and Expert Systems is expanded in each iteration [Patrick e2 a/. $91. The condition of unique node costs asymptotically requires that the number of bits used to represent the costs increase with each level of the tree, which may be un- realistic in practice. When Bpo > 1 the minimum goal cost is a constant by Lemma 1. Therefore, IDA* terminates in a constant number of iterations. This means that the total num- ber of nodes generated by IDA* is of the same order as the total number of nodes generated by best-first BnB, resulting in the optimality of IDA* in this case. The number of iterations of IDA*, however, is not a constant when Bpo < 1, since the minimum goal cost grows with the search depth. When Bpo < 1, it can be shown that the ra.tio of the number of nodes gener- ated in one iteration to the number of nodes generated in the previous iteration is the sa.me as the heuristic branching factor of the uniform random tree. Asymp- totically, this ratio is the solution greater than one to equation (1). Consequently, we have the following re- sult. Theorem 4 On a uniform random tree with Bpo < 1, IDA* is optimal on average. 0 Simila#r results were independently obtained by Patrick [Patrick 9 l]. With a non-monotonic cost function, the cost of a. child can be less than the cost of its parent, and IDA* no longer expands nodes in best-first order. In this case, recursive best-first sea.rch (RBFS) [Korf 921 ex- pands new nodes in best-first order, and still uses mem- ory linear in the search depth. It was shown that with a monotonic cost function, RBFS generates fewer nodes than IDA*, up to tie-breaking [Korf 921. This, with Theorem 4, gives us the following corollary. Corollary 1 On a uniform ran.dom tree with Bpo < 1, RBFS is optimal on average. 0 iscussion The efficiency of BnB depends on the cost function used, which involves domain-specific knowledge. There is a tradeoff between knowledge and sea.rch complex- ity, in that a. more accura.te cost estimate prunes more nodes, resulting in less computation. The results of our analysis measure this tradeoff in an average-case set- ting. In particular, to make an optimiza.t*ion problem tractable, enough domain-specific knowledge is needed so that the expected number of children of a node that have the same heuristic evaluation as their parent is greater tha.n one. We call this property local consis- tency. Local consistency is a. different characterization of a heuristic function tl1a.n its error as an estimator. Lo- cal consistency is a property that ca.n be determined locally, for example by randomly generating states and computing the avera.ge number of same-cost chil- dren. Determining the error in a heuristic estima,tor, on the other hand, requires knowing the exact value be- ing estimated, which is impossible in a difficult prob- lem, since determining minimum-cost solutions is in- tractable. Thus, determining local consistency by ran- dom sampling gives us a practical means of predicting whether the complexity of a branch-and-bound search will be polynomial or exponential. This prediction, however, is based on the assumption that edge costs are independent of each other. By The- orem 1, local consistency implies that the estimated cost of a node is within a constant of its actual cost on a uniform random tree with independent edge costs. In other words, local consistency implies constant ab- solute error of the heuristic estimator. Unfortunately, edge costs are often not independent in real problems. For example, in the sliding-tile puzzles, a zero-cost edge implies a tile moving toward its goal location. As a se- quence of moves are made that bring tiles closer to their goal locations, it becomes increasing likely that the next move will require moving a tile away from its goal location. On the other hand, the independence assumption may be reasonable for a relatively short fixed-depth search in practice. Related Work Dechter [Dechter $11, Smith [Smith 841, and Wah and Vu [Wah & Yu 851 analyzed the average-case com- plexities of best-first BnB a.nd depth-first BnB using tree models, and concluded that they are exponential. Purdom [Purdom 831 characterized exponential and polynomial performance of backtracking, essentially a depth-first BnB on constraint-satisfaction problems. Stone and Sipala [Stone & Sipala 861 considered the rela.tionship between the pruning of some branches and the average complexity of depth-first search with back- tracking. Karp a.nd Pearl [Karp & Pearl 831 reported impor- tant results for best-first BnB on a uniform binary tree, with edge costs zero or one. McDiarmid and Provan [McDia.rmid & Provan 911 extended Karp and Pearl’s results by using a general tree model, which has ar- bitrary edge costs and variable branching factor. In fact, the properties of the minimum goal cost (Lemma 1) and the average-case complexities of best-first BnB (Theorem 1) discussed in this paper are based on Mc- Diarmid and Provan’s results. We further extended these results in two respects. First, when best-first BnB has linear average-case complexity, we showed that depth-first BnB has polynomial complexity. Sec- ond, for problems on which best-first BnB has expo- nential average-case complexity, we obtained an ex- pression for its heuristic branching factor. Huberman and Hogg [Huberman & Hogg 871, and Cheeseman et al. [Cheeseman et al. 911 argued that phase transitions are universal in intelligent systems and in most NP-hard problems. The worst-case complexity of IDA* was first shown by Patrick et ad. [Patrick et al. 891. Vempaty et al. Zhang and Korf 549 [Vempaty et al. 911 compared depth-first BnB and IDA*. Recently, Mahanti et al. discussed performance of IDA* on trees and graphs [Mahanti et al. 921. Our results on IDA* concludes the average-case optimality of IDA* on a uniform random tree, which also implies that RBFS is optimal on average. Similar results on IDA* were also obtained by Patrick [Patrick 911. Conclusions This paper contains the following results on branch- and-bound, one of the most efficient approaches for exact solutions to discrete optimization problems. Our analysis is based on a tree with uniform branching fac- tor and random edge costs. We delineated exponential and polynomial complexities of BnB in an average-case setting. When best-first BnB has linear complexity, we showed that the complexity of depth-first BnB is polynomial. We further obtained an expression for the heuristic branching factor of problems on which best- first BnB has exponential complexity. The analysis uncovered the existence of a complexity transition of BnB on discrete optimization problems. Furthermore, the analysis explained an anomaly observed in looka- head search with sliding-tile puzzles, and predicted the existence of an average-case complexity transition of BnB on ATSP, which was verified by experiments. In addition, our results showed a. quantitative tradeoff be- tween knowledge and search complexity, and provided a means of testing avera.ge-case search complexity. By formulating IDA* as cost-bounded BnB, we derived an expression for the ratio of the number of nodes gener- ated in one iteration to the number of nodes gener- ated in the previous iteration, a.nd showed that IDA* is optimal on average. This implies the average-case optimality of RBFS in this model. References Balas, E. and P. Toth, 1985. “Branch and bound methods,” The Traveling Salesman Problem, E.L. Lawler, J.K. Lenstra, A.H.G. Rimrooy Kan and D.B. Shmoys (eds.) John Wiley and Sons, pp.361-401. Carpaneto, G., and P. Toth, 1980. “Some new branching and bounding criteria for the asymmetric traveling salesman problem,” Management Science, 26:736-43. Cheeseman, P., B. Kanefsky, W .M. Taylor, 1991. “Where the really hard problems are,” Proc. IJCAI- 91, Sydney, Australia, Aug. pp.331-7. Dechter, A., 1981. “A probabilistic analysis of branch- and-bound search,” Tech Rep. UCLA-ENG-81-39, School of Eng. and Applied Sci., UCLA, Oct. Huberman, B.A., and T. Hogg, 1987. “Phase transi- tions in artificial intelligence systems,” Artificial In- telligence, 33:155-71. Karp, R.M., and J. Pearl, 1983. “Searching for an optimal path in a tree with random cost,” Artificial Intelligence, 21:99-117. Korf, R.E., 1985. “Depth-first iterative-deepening: An optimal admissible tree search,” Artificial Intel- ligence, 27:97-109. Korf, R.E., 1990. “Real-time heuristic search,” Arti- ficial Intelligence, 42: 189-211. Korf, R.E., 1992. “Linear-space best-first search: Summary of results,” Proc. AAAI-92, San Jose, CA, July 12-17. Kumar, V., 1992. “Search, Branch-and-bound,” in Encyclopedia of Artificial Intelligence, 2nd Ed, S.C. Shapiro (ed.) Wiley-Interscience, pp.1468-72. Lawler, E.L., J.K. Lenstra, A.H.G. Rinnooy Kan and D.B. Shmoys (eds.), 1985. The Traveling Salesman Problem, John Wiley and Sons. Little, J .D.C., K.G. Murty, D.W.Sweeney, and C. Karel, 1963. “An algorithm for the traveling salesman problem,” Operations Research, 11:972-989. Mahanti, A., S. Ghosh, D. S. Nau, A. K. Pal, and L. N. Kanal, 1992. “Performance of IDA* on Trees and Graphs,” Proc. AAAI-92, San Jose, CA, July 12-17. Martello, S., and P. Toth, 1987. “Linear assignment problems,” Annals of Discrete Mathematics, 31:259- 82. McDiarmid, C.J .H., and G.M.A. Provan, 1991. “An expected-cost analysis of backtracking and non- backtracking algorithms,” Proc. IJCA I-91, Sydney, Australia, Aug. pp. 172-7. Patrick, B.G., 1991. Ph.D. dissertation, Computer Science Dept., McGill University, Canada. Patrick, B.G., M. Almulla, and M.M. Newborn, 1989. “An upper bound on the complexity of iterative- deepening-A* ,” Proceedings of the Symposium on Ar- tificial Intelligence and Mathematics, Ft. Lauderdale, Fla., Dec. Pearl, J., 1984. Heuristics, Addison-Wesley, Reading, MA. Purdom, P. W., 1983. “Search Rearrangement back- tracking and polynomial average time,” Artificial In- telligence, 21:117-33. Vempaty, N.R., V. Kumar, and R.E. Korf, 1991. “Depth-first vs best-first search,” proc. AAAI-91, Anaheim, CA, July, pp.434-40. Smith, D.R., 1984. “Random trees and the analysis of branch and bound procedures,” JACM, 31:163-88. Stone, H.S., and P. Sipala, 1986. “The average com- plexity of depth-first search with backtracking and cutoff,” IBM J. Res. Develop., 30:242-58. Wah, B.W., and C.F. Yu, 1985. “Stochastic mod- eling of branch-and-bound algorithms with best- first search,” IEEE Trans. on Software Engineering, 11:922-34. Zhang, W., and R. Korf, 1992. “An Average-Case Analysis of Branch-and-Bound with Applications,” in preparation. 550 Problem Solving: Search and Expert Systems | 1992 | 95 |
1,293 | mic MAP Calcul Eugene Charniak and Eugene Santos Jr. Department of Computer Science Brown University Providence RI 02912 ec@cs.brown.edu and esj@cs.brown.edu Abstract We present a dynamic algorithm for MAP cal- culations. The algorithm is based upon San- tos’s technique (Santos 1991b) of transform- ing minimal-cost-proof problems into linear- programming problems. The algorithm is dy- namic in the sense that it is able to use the re- sults from an earlier, near by, problem to lessen its search time. Results are presented which clearly suggest that this is a powerful technique for dy- namic abduction problems. Introduction Many AI problems, such as language understanding, vision, medical diagnosis, map learning etc. can be characterized as abduction - reasoning from effects to causes. Typically, when we try to characterize the computational problem involved in abduction, we dis- tinguish between (a) finding possible causes and (b) selecting the one most likely to be correct. In this paper we concentrate on the second of these issues. We further limit ourselves to probabilistic methods. It seems clear that “the most likely to be correct” is that which is most probable. The arguments against the use of probability therefore usually concentrate on the difficulty of computing the relevant probabilities. How- ever, recent advances in the application of probability theory to AI problems, from Markov Random Fields (Geman & Geman 1984) to Bayesian Networks (Pearl 1988) have made such arguments harder to maintain. The problems of our first sentence are not just ab- duction problems, they are dynamic abduction prob- lems. That is, we are not confronted by a single prob- lem, but rather by a sequence of closely related prob- lems. In medical diagnosis the problem changes as new evidence comes in. In vision, the picture changes slightly over time. In story understanding, we get fur- ther portions of the story. Of course we can reduce the dynamic case to the static. Each scene, medical problem, or story com- prehension task sets up a new probabilistic problem which the program tackles afresh. For example, in our previous work on the Wimp3 story understanding pro- gram (Charniak & Goldman 1989; Charniak & Gold- man 1991; Goldman & Charniak 1990) story decisions are translated into Bayesian Networks. The network is extended on a word-by-word basis. As one would expect, most of the network at word n was there for word n - 1. Yet the algorithm we used for calculating the probabilities at n made no use of the values found at n - 1. This seemed wasteful, but we knew of no way to do better. This paper corrects this situation. Previous Research Roughly speaking, probabilistic algorithms can be di- vided up into exact algorithms and ones which are only likely to return a number within some 6 of the answer. Considering exact algorithms, we are not aware of any which are dynamic. The story is different for the ap- proximation schemes since most are stochastic in na- ture and have the property that if we can start with a better guess of the correct answer they will converge to that answer more quickly. (See for example (Shachter & Peot 1989; Shwe & C,ooper 1990) .) Thus such al- gorithms are inherently dynamic in the sense that the results from the previous computation can be used to improve the performance on the next one. However, even for such algorithms we are unaware of any study of their dynamic properties. The particular (exact) algorithm we propose here did not arise from a search for a dynamic algorithm, but rather from an effort to improve the speed of proba- bilistic calculations in Wimp3. One scheme we consid- ered was the use of Hobbs and Stickel’s (Hobbs et al. 1988) work on minimal-cost proofs for finding the best explanations for text. Their idea was to find a set of facts which would allow the program to prove the con- tents of the textual input. Since there would be many possible sets of explanations, they assigned costs to as- sumptions. The cost of a proof was the sum of the cost of the assumptions it used. (Actually, we are outlining “cost-based abduction” as defined in (Charniak 8z Shi- mony 1990) which is slightly simpler than the scheme used by Hobbs and Stickel. However, the two are suf- ficiently close that we will not bother to distinguish 552 Representation and Reasoning: Abduction and Diagnosis From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. 4 6 3 Figure 1: An and-or dag showing several proofs of house-quiet between them.) For example, see Figure 1. There we want the minimal-cost proof of the proposition house-quiet (my house is quiet). This is an “and-node” so proving it requires proving both no-barking and TV-off. Figure 1 shows several possible proofs of these using different assumptions. One possible set of assumptions would be homework-time, dog-sleeping. Given the costs in the figure, the minimal cost proof would be simply assum- ing kids-walking-dog at a cost of 6. We were interested in minimal-cost proofs since their math seems a lot simpler than typical Bayesian Net- work calculations. Unfortunately, the costs were ad- hoc, and it was not clear what the algorithm was re- ally computin Shimony 1990 ‘j . Charniak and Shimony (Charniak & fixed these problems by showing how the costs could be interpreted as negative log proba- bilities, and that under this interpretation minimal- cost proofs produced MAP assignments (subject to some minor qualifications). (A MAP, Maximum A- Posteriori, assignment is the assignment of values to the random variables which is most probable given the evidence.) A subsequent paper (Shimony & Charniak 1990), showed that any MAP problem for Bayesian Networks could be recast as a minimal-cost-proof prob- lem. In the rest of this paper we will talk about al- gorithms for minimal-cost proofs and depend on the result of (Shimony & Charniak 1990) to relate them to MAP assignments. Unfortunately, the best-first search scheme for find- ing minimal-cost proofs proposed by Charniak and Shimony (and modeled after the Hobbs and Stickel’s work) did not seem to be as efficient as the best algo- rithms for Bayesian Network evaluation (Jensen et al. 1989; Lauritzen & Spiegelhalter 1988). Even improved admissible cost estimations (Charniak dz Husain 1991) did not raise the MAP performance to the levels ob- tained for Bayesian Network evaluation. Recently, Santos (Santos 1991a; Santos 1991c; San- tos 199 1 b) presented a new technique different from the best-first search schemes. It showed how minimal-cost proof problems could be translated into O-l program- ming problems and then solved using simplex com- bined with branch and bound techniques when sim- plex did not return a O-l solution. Santos reports that simplex returns O-l solutions on 95% of the random waodags he tried and 60-70% of those generated by the Wimp 3 natural language understanding program. This plus the fact that branch and bound quickly found O-l solutions in the remaining cases showed that this new approach outperformed the best-first heuristics. It actually exhibited an expected polynomial run-time growth rate where as the heuristics were exponential. This approach immediately suggested a dynamic MAP calculation algorithm. Waodags as Linear Constraints Santos, following (Charniak & Shimony 1990) formal- ized the minimal-cost proof problem as one of find- ing a minimal-cost labeling of a weighted-and-or-dag (waodag). Informally a waodag is a proof tree (actu- ally a dag since a node can appear in several proofs, or in the same proof several times). We have al- ready seen an example in Figure 1. Formally it is a 4-tuple< G, c, T, S >, where 1. G is a connected directed acyclic graph, G = (V, E), 2. c is a function from V to the non-negative reals, called the cost function (this is simplified in that we only allow assuming things true to have a cost), 3. r is a function from V to (and, or) which labels each node as an and-node or an or-node, 4. S is a set of nodes with outdegree 0, called the evi- dence. The problem is to find an assignment of true and false to every node, obeying the obvious rules for and-nodes and or-nodes, such that the evidence is all labeled true, and the total cost of the assignment is minimal. In the transformation to a linear programming prob- lem a node n becomes a variable 3: with values re- stricted to O/l (false/true). An and-node n which was Charniak and Santos 553 true iff its parents no.. . ni were true would have the linear constraints AND1 x 5 x0,. . .x 5 zi AND2 x > x0 + . . . + xi - i + 1. An or-node n which is true iff at least one of its parents no. . . ni are true would have the linear constraints OR1 x 5 20 + * * * + xi OR2 x 1 x0,. . .x 2 xi. The constraints AND1 and OR1 can be thought of as “bottom up” in that if one thinks of the evidence as at the bottom of the dag, then these rules pass true values up the dag to the assumptions. The constraints AND2 and OR2 are “top down.” In our implementation we only bothered with the bottom-up rules. The costs of assumptions are reflected in the objec- tive function of the linear system. As we are making the simplifying (but easily relaxed) assumption that we assign costs only to assuming statements true, model- ing the costs co. . . ci for nodes no . . . n; is accomplished with the objective function coxo + - - * + cixi Santos then shows that a zero-one solution to the linear equations which minimizes the objective function must be the minimal-cost proof (and thus the MAP solution for the corresponding Bayesian Network.) The Algorithm Simplex is, of course, a search algorithm. It searches the boundary points of a convex polygon in a high di- mensional space, looking for a point which gives the optimal solution to the linear inequalities. The search starts with an easily obtained, but not very good, so- lution to the problem. It is well known that simplex works better if the initial solution is closer to optimal. When we say “better” we mean that the algorithm re- quires fewer “pivots” - the traditional measure of time for simplex. To those not familiar with the scheme, the number of pivots corresponds to the number of so- lutions tested before the optimal is found. In what follows we will assume that the following are primitive operations, and that it is possible to take an existing solution, perform any combination of them, and still use the existing solution as a start in find- ing the next solution. This is, in fact, standard in the linear-programming literature (see (Hillier & Lieber- man 1967)). Ll Add a new variable (with all zero coefficients) to the problem. L2 Add a new equation to the problem. L3 Change the coefficient of a variable in an equation. L4 Change the coefficient of a variable in the objective function. Moving down a level, we need to talk about opera- tions on the waodags. In particular we need to do the following: Wl add a new node to the dag, W2 add an arrow between nodes, W3 set the value of a node, W4 remove a node (and arcs from it). For example, when we get a new word of the text (e.g., “bank”) in a story comprehension program we need to add a new or-node corresponding to it (Wl) and, since this is not a hypothesis, but rather a known fact, set the value of the node to true (W3). To add an explana- tion for this word, say that it was used because the au- thor wanted to refer to a savings institution, we would add a second or-node corresponding to the “savings in- stitution” hypothesis, add a coefficient corresponding to its cost to the objective function (L4), and add an arc between it an the node for the word (W2), possibly with an intermediate newly minted and-node. Next we relate Wl-W4 to Ll-L4. Wl-W3 are fairly simple. Wl Adding a new node nl to the dag is accomplished by adding a new variable xi to the linear program- ming problem. If it has a cost cl, change the coef- ficient of xi in the objective function from 0 to cl u-4 W2 Adding an arrow from node nr to n2 is accom- plished in one of three ways (we only deal with the bottom-up equations): e If n2 is an and-node, add the new equation 22 5 Xl p-4 e If n2 is an or node with the equation 22 5 x3+. . .+ xi already in the problem, change the coefficient of xi in this equation from zero to one (L3) o Else, add a new equation x2 5 x1 (L2). W3 Setting the value of a node ni to true (false) is accomplished by adding the equation nl = l(0) to the linear programming problem (L2). (In cases were the node is about to be introduced, we can optimize by not explicitly adding its variable to any equations, and instead substituting its value into the equations for parents nodes.) The only complicated modification to Woadags is W4, removing a node (and arcs from it). We need this so, as the text goes along, it will be possible to set values of nodes to be definitely true or false, thus removing them from further probabilistic calculations (except should they serve as evidence for other facts). If all we wanted to do was set the value, we could use the method in (W3), adding an equation setting the value. But this is not enough. We want to remove the variable from all equations as well so as to reduce the size of the simplex tableau and thus decrease the pivot time. We will assume in what follows that the variable in question is to be assigned the value it has in the current MAP. If this is not the case then a new equation must be added. 554 Representation and Reasoning: Abduction and Diagnosis If the variable xj to be removed is a non-basic vari- able the problem is easy. We just use technique L3 to modify all of zi’s coefficients to be zero. We can then remove its column from the tableau. This does not work, however, if the variable is basic. Then there will be a row, say ri which will look like this: Ci,l,Ci,2, * ' * ci,j-1, k,j+1, * * *Ci,k = b. Changing the coefficient ci,j which is currently 1, to 0 will leave this equation with no basic variable, some- thing not allowed. However, if any of the other coeffi- cients ci,l . . . ci,k 2 0 then we can pivot on that variable and make it basic. This leaves the case when none of the other variables are positive. The solution depends on the fact that we are setting the value of x~j to its current value in the MAP. This will be, of course, b,. Thus we should, and will, subtract b, from both sides of the equation. On the left-hand-side this is done by making ci,j = 0. On the right we actually subtract b, - b, to get b: = 0. Note now that since bi = 0 we can multiply both sides of the equation by -1 when all of the other coefficients are negative, thus making them positive. b: is still zero so the equation remains in standard form, and we now have a non-zero coef- ficient to pivot on. Finally, if there are no non-zero coefficients other than ci,j then the equation can be deleted, along with XC;,~. esults The algorithm described in the previous section was run on a set of probabilistic problems generated by the Wimp 3 natural-language understanding program. As we have already noted, Wimp 3 works by translat- ing problems in language understanding into Bayesian Networks. Ambiguities such as alternative references for a pronoun become separate nodes in the network. The alternative with the highest probability given the evidence is selected as the “correct” interpretation. Wimp 3 used a version of Lauritzen and Spiegelhal- ter’s algorithm (Lauritzen & Spiegelhalter 1988) as im- proved by Jensen (Jensen et ab. 1989), to compute the probabilities. Wimp 3 generated 218 networks ranging in size from 3 to 87 nodes. As befits an inherently expo- nential algorithm, we have plotted the log of evaluation time against network size. (All times are compiled Lisp run on a Sun Spare 1.) See Figure 2. A least squares fit of the equation time = B . 10A’Idagl gives A = .03 and B = .275. The total evaluation time for all of the networks was 575 seconds, to be compared with a to- tal of 1235 seconds to run the examples (or 46.5% of the total running time). This illustrates that network evaluation time was the major component of the time taken to process the examples. Wimp 3 was then modified slightly to use the dy- namic MAP algorithm described in this paper. While there is a general algorithm for turning Bayesian net- works into cost-based abduction problems (Shimony & Charniak 1990), it can be rather expensive in terms of the number of nodes created. Instead we made use of the fact that the networks created by Wimp were already pretty much and-or dags, and fixed the few re- maining places on a case-by-case basis. A graph of the resulting programs running time (or the log thereof) vs. dag size is given in Figure 3. The dag’s sizes reported are, in general twice those for the Bayesian Networks. The major reason is that the dag’s included explicit and-nodes while these were absorbed into the distribu- tions in the networks. The total time to process the dags was 73 seconds. Thus the time spent on proba- bilistic calculations was decreased by a factor of 7.9. Running time, of course, is not a very good measure of performance since so many factors are blended into the final result. Unfortunately, the schemes operate on such different principles that we have not been able to think of a more implementation independent measure for comparing them. It is, nevertheless, our belief that these numbers are indicative of the relative efficiency of the two schemes on the task at hand. As should be clear from Figure 3, the connection be- tween the size of the dag and the running time is much more tenuous for the linear technique. This suggested looking at the standard measure for the performance of the simplex method - number of pivots. Figure 4 shows the number of pivots vs DAG size. Note that we did not graph dag size against the Iog of the number of pivots. As should be clear, the number of pivots grows very slowly with the size of the dag, and the correla- tion is not very good. It certainly does not seem to be growing exponentially. If one does a least squares fit of the linear relation pivots = A- 1 dag 1 +B one finds the best fit A = .091 and B = 7.1. Since the time per pivot for simplex is order n2 we have seemingly re- duced the “expected time” complexity of our problem to low polynomial time. Conclusion While the results of the previous section are impres- sive to our eyes, it should be emphasized that there are limitations to this approach. The most obvious is that even an n2 algorithm is only feasible for smaller n. Cur algorithm performs acceptably for our networks of up to 175 nodes. It is doubtful that it would work for problems in pixel-level vision, where there are, say lo6 pixels, each a random variable. Furthermore, if the problem is not amenable to a cost-based abduction for- mulation it is unlikely that the general transformation from Bayesian Networks to waodags will produce ac- ceptably small dags. But this still leaves at lot of problems for which this technique is applicable. In several previous papers (Charniak 1991; Charniak & Goldman 1991) on the use of Bayesian Networks for story understanding we have emphasized that the problem of network evalua- tion was the major stumbling block in the use of these networks. The results of the previous section would indicate that this is no longer the case. Putting the Charniak and Santos 555 100. 10. 1. c .l d0 40 d0 d0 Figure 2: Bayesian-Network-Evaluation Time (in Sec.) vs. Number of Nodes 10. 1. I .l .Ol 8 :. 0 . : 00 a. a 0 I I I I I I I I $5 d0 15 lb0 155 I 150 1+5 Figure 3: Linear Cost-Based Abduction Time (in Sec.) vs. Number of Nodes 6i e e e 0 8 :a * 00 6 o- 8 @ e 0 Figure 4: Number of Pivots vs. Number of Nodes 556 Representation and Reasoning: Abduction and Diagnosis data in perspective, we are spending about .3 seconds per word on probabilistic calculations. Furthermore, we are using a crude version of simplex which one of the authors wrote. It includes none of the more so- phisticated work which has been done to handle larger linear programming problems. It seems clear that a better simplex could handle order of magnitude larger problems in the same time (or less, with the very much more powerful machines already on the market.) Thus network evaluation is no longer a limiting factor. Now the limiting factor is for us, as it is for pretty much the rest of “traditional” AI, knowledge representation. Acknowledgements This research was supported in part by NSF contract IRI-8911122 and QNR contract N0014-91-J-1202. eferences Charniak, E. and Goldman, R. 1989. A semantics for probabilistic quantifier-free first-order languages, with particular application to story understanding. In Proceedings of the IJCAI Conference. Charniak, E. and Goldman, R. 1991. A probabilistic model of plan recognition. In Proceedings of the AAAI Conference. Charniak, E. and Husain, S. 1991. A new admissible heuristic for minimal-cost proofs. In Proceedings of the AAAI Conference. Charniak, E. and Shimony, S. E. 1990. Probabilistic semantics for cost based abduction. In Proceedings of the AAAI Conference. 106-l 11. Charniak, E. 1991. Bayesian networks without tears. AI Magazine 12(4):50-63. Geman, S. and Geman, D. 1984. Stochastic relax- ation, gibbs distribution, and the bayesian restoration of images. IEEE Transactions on Pattern Analysis and Machine Intelligence 6~721-41. Goldman, R. and Charniak, E. 1990. Dynamic con- struction of belief networks. In Proceedings of the Conference on Uncertainty in Artificial Intelligence. Hillier, F. S. and Lieberman, G. J. 1967. Introduction to Operations Research. Holden-Day, Inc. Hobbs, J. R.; Stickel, M.; Martin, P.; and Edwards, D. 1988. Interpretation as abduction. In Proceed- ings of the 26th Annual Meeting of the Association for Computational Linguistics. Jensen, F. V.; Lauritzen, S. L.; and Olesen, K. G. 1989. Bayesian updating in recursive graphical mod- els by local computations. Technical Report Report R 89-15, Institute for Electronic Systems, Department of Mathematics and Computer Science, University of Aalborg, Denmark. Lauritzen, S. L. and Spiegelhalter, D. J. 1988. Local computations with probabilities on graphical struc- tures and their applications to expert systems. J. Royal Statistical Society 50(2):157-224. Pearl, J. 1988. Probabilistic Reasoning in Intelligent Systems: Networks of Plausible Inference. Morgan Kaufmann, San Mateo, CA. Santos, E. Jr. 1991a. Cost-based abduction and linear constraint satisfaction. Technical Report CS-91-13, Department of Computer Science, Brown University. Santos, E. Jr. 1991b. A linear constraint satisfaction approach to cost-based abduction. Submitted to Ar- tificial Intelligence Journal. Santos, E. Jr. 1991c. On the generation of alternative explanations with implications for belief revision. In Proceedings of the Conference on Uncertainty in Ar- tificial Intelligence. Shachter, R. D. and Peot, M. A. 1989. Simulation approaches to general probabilistic inference on be- lief networks. In Proceedings of the Conference on Uncertainty in Artificial Intelligence. Shimony, S. E. and Charniak, E. 1990. A new algo- rithm for finding map assignments to belief networks. In Proceedings of the Conference on Uncertainty in Artificial Intelligence. Shwe, M. and Cooper, G. 1990. An emperical analysis of likelihood-weighting simulation on a large multiply- connected belief network. In Proceedings of the Con- ference on Uncertainty in Artificial Intelligence. Charniak and Santos 557 | 1992 | 96 |
1,294 | Consistency- ased Diagnosis in Physiological Keith L. Downing * Department of Computer and Information Science, Linkijping University, S-58183 Linkaping, Sweden Abstract This research attempts to span the gap between the AI in medicine (AIM) and consistency-based diagno- sis (CBD) communities by applying CBD to physiol- ogy. The highly-regulated nature of physiological sys- tems challenges standard CBD algorithms, which are not tailored for complex dynamic systems. To combat this problem, we separate static from dynamic analysis, so that CBD is performed over the steady-state constraints at only a selected set of time slices. Regulatory mod- els help link static inter-slice diagnoses into a complete dynamic account of the physiological progression. This provides a simpler approach to CBD in dynamic systems that (a) preserves information-reuse capabilities, (b) ex- tends information-theoretic probing, and (c) adds a new capability to CBD: the detection of dynamic faults (i.e., those that do not necessarily persist throughout diagno- sis) . I. Introduction The consistency-based approach to diagnosis (CBD) pro- vides a general formal technique for deep-model diagno- sis [5, 161. This research extends a very popular CBD approach, the GDE paradigm [5, 41, to physiology. Most CBD work has focused on discrete static domains, such as simple digital electronics. Additionally, CBD has been successfully extended to discrete dynamic systems [II, 91, but applications to continuous dynamic systems have confronted more obstacles [2]. We argue that these prob- lems stem from the frailty in dynamic domains of refer- entiak trcbnsparency [l], a key prerequisite to information reuse in GDE. We preserve referential transparency by separating static from dynamic analysis so that the CBD system deals only with steady-state analysis at selected time points. In this way, we perform model-based diagnose of continuous dynamic systems without performing dy- namic simulations. Our system, IDUN, combines the GDE methodology with data interpretation to diagnose continuous dynamic systems that exhibit dynamic faults. *Author’s current affiliation: SINTEF, Automatic Control Division, N-7034 Trondheim, Norway (email: keith.downingOitk.unit.no) 2 Msmotonicity i A key to GDE’s success is the ability to evaluate many candidates (i.e., diagnostic hypotheses) quickly. Since many candidates are often quite similar, they support many of the same predictions. The caching and reuse of these predictions (via the ATMS [s]) is critical to an efficient search of the candidate space. Although the ATMS supports nonmonotonic reason- ing during the search of an implicit context tree, ATMS usage within GDE requires two key monotonic assump- tions for making predictions within any particular node of that tree: if a particular candidate (Cand) and a set of observed findings (Obs) support a set of predictions, P, then one derives a superset of P by either (a) adding a new observation (M) to Obs, or (b) adding a new as- sumption about the behavioral mode of some component (C) to Cand. ATMS environments typically contain ob- servation and mode assumptions, so the above mono- tonicities enable the ATMS to quickly determine an envi- ronment’s implications by considering predictions made earlier by subset environments. 1 Component mode assumptions usu~ally include “work- ing”, “broken” and oft.en more specific fault modes. Deep models that support the above two monotonic assump- tions have the property that a component’s outruts are strictly a function of its inputs and its mode. This prop- erty is a type of referential transparency [I], which pro- motes inference reuse in the obvious way: if a set of inputs and mode derive a set of outputs at time t, then given the same inputs and mode at a later time t’, one can immediately assume the same outputs, wit1 out re- doing the potentially expensive derivation. Two key factors contribute to the preservation of ref- erential transparency: (a) components are highly mod- ularized so that other components cannot affect them through channels other than the recognized input path- ways, and (b) components have few or no state variables. Essentially, the modular state-less components of sim- ple digital circuits have been the key to GDE’s previous success. The state-less requirement indicates that dy- namic systems will be more problematic for GDE. For example, given a particular input fluid flow (F) to ;t ves- sel (V), one cannot ascertain the output flow value (0) lIn ATMS terminology, ax3 enaironment is a set of assumptions. 558 Representation and Reasoning: Abduction and Diagnosis From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. as a strict function of F, if V has a modeled capaci- tance and fluid volume. The values of these parameters must also be accounted for, typically as extra ATMS as- sumptions, in the justification of 0. Unfortunately, larger antecedents decrease reusability, since more conjuncts must hold in order to reassert 0 at t’. Similarly, larger value spaces for antecedent parameters decrease reusabil- ity. Hence, it is no surprise that GDE has had the most success in digital domains. hysiological G The extension of GDE to physiology demands (a) careful attention to modularity in modeling primitives, and (b) a means to combat the decline in reusability associated with state variables. Patil[14] envisions many problems with applying CBD to medicine. One of his main concerns is that cur- rent medical knowledge provides few causal pathways from anatomical structures (i.e., physical components) to physiological behaviors. Hence, organs or bones could not serve as the input-output modules indigenous to most GDE domains. However, modules need not cor- respond to physical objects but can instead represent structural or behavioral abstractions of a physical sys- tem. Compartmental models, for instance, have no nec- essary mapping to physical space, yet they abstract phys- iological systems to a level of interacting modules - a level at which model-based diagnosis has been performed [15, 121. Our system, IDUN, also employs compartmen- tal models [7]. H owever, we view mechanisms (see be- low) as the fundamental modules for GDE applications in physiology. A second design decision further insures referential transparency: IDUN handles static and dynamic anal- ysis separately. IDUN inputs observations from different time slices, but it assumes that the system can be ap- proximated by steady-state equations at each slice. This helps preserve referential transparency by fixing most state variables during a time slice. For instance, in the simple-vessel example given earlier, a steady-state as- sumption insures that the output flow equals the input flow while the internal fluid volume and capacitance hold steady. In compartmental models, this enables us to as- sume that the total inputs of a material to a compart- ment equal the total outputs. As detailed below, IDUN performs GDE-style diagnosis only at the steady-state level, where referential transparency is more easily pre- served. The steady-state assumption is relatively common and accurate in physiological modeling due to the homeo- static nature of biological systems. Additionally, home- ostatic systems, when perturbed, often evolve through a series of (relatively stable) states, each characterized by a unique set of faults. IDUN diagnoses such progressions. ing UN 4.1 Variables Variables in IDUN are classified as either dependmt or fc&t, where changes in the latter normally affect the for- mer through basic mechanisms, whereas fault variables are affected only by regpslcstory mechanisms. C’ariable values are expressed as ranges over the reals, similar to [17]. Each variable has a normal point value, as well as normal, low and high ranges about that point. 2 This allows for the imprecision in both physiological models and measuring techniques, while avoiding the ambiguity of qualitative simulation in feedback-rich domains. 4.2 Mechanisms We define a mechanism as “a group of system variables and a causal relationship between them, where the causal connection is as direct/primitive as the granularitg of the system model permits.” Each mechanism in IDUN is rep- resented by one or more steady-state constraints (SSCs) such as conservation laws or ohm’s law (as applied to fluids). Each constraint may contain one or moee fault variables. A mechanism can be faulted in one of two ways: (1) one of its fault variables is in a high or low range, or (2) one or more of its steady-state constraints simply does not hold, regardless of fault modes. Mechanisms are either b&c or regulatory. Basic mech- anisms are only represented by SSCs that are presumably always satisfied . Otherwise they are necessarily faulted by criterion 2 above. Table 1 presents the mecl:anisms used in the cardiovascular exa.mple. 3 Regulators have temporal delays and durations, which respectively denote (a) the normal time lag between a regulator-triggering perturbation and the time at which its SSCs become satisfied, and (b) the normal amount of time which the SSCs remain satisfied. Some regulators, such as the baroreceptors, lose their sensitivity tc per- sistent triggers. An unsatisfied regulatory SSC indicates either (a) a regulator fault, or (b) an inactive period (i.e., a pre-delay or post-duration point in time). 4 Dynamic qualitative relationships among variables, injbences, are associated with regulators. These cap- ture the effect of the trigger variable’s value upon a fault 2For instant e in the cardiovascular example discussed be- , low, these ranges are: (-10% +lO%), (-40% -lo%), and (+lO% +40%), respectively, denoting percentages above and below the normal point value. 3The cardiovascular variables in this model are: Arterial Pressure (PA), Blood Vohune (BV), Cardiac Output (CO), Right Atrial Pressure (RAP), Systemic Pressure Drop (DP- SYS), Systemic Resistance (R-SYS), Urine Output (UO), Ve- nous Compliance (VC), Venous Pressure (VP), Venous Pres- sure Drop (DP-VEN), Venous Resistance (R-VEN), and Ve- nous Return (VR). 41n this paper, we disregard faults in regulators and there- fore always assume case b. However, the IDUN code supports either case as well as fault modes in regulators. Downing 559 Mechanism Systemic Ohms - Active Volume Venous Ohms Flow Conservation Constraints DP-SYS = PA - PV PV = BV/VC DP-VEN = PV - RAP co = VR DP-SYS = CO * R-SYS DP-VEN = VR * R-VEN Fault Vars R-SYS R-VEN -I BV,VC i Table 1: Basic Circulatory Mechanisms variable’s derivative. For instance, as part of autoreg- ulation, the sign of the normalized value of CO equals the sign of the derivative of R-SYS (Notationally, CO + R-SYS in Table 2) 5. Thus, high CO causes R-SYS to increase. IDUN estimates derivatives by comparing a variable’s values across time slices. 5 A Cardiovascular Example In the circulatory condition known as volume-loading hy- pertension (VLH), increased water and salt intake cou- pled with renal insufficiency (e.g., the inactivity of many nephrons) cause a rise in blood volume (BV), which in turn raises cardiac output (CO) and arterial pressure (PA). The baroreceptors (BARO) immediately react to rising PA by decreasing systemic resistance (R-SYS). Thus, the earliest stage of VLH is characterized by two faults: high BV and low R-SYS, and symptoms such as high PA and high CO. Table 3 summarizes the stages of VLH as described in [lo]. After a day or two, the long-term autoregulator mech- anism (AUTO) reacts to an overabundance of cellular oxygen (caused by high CO) by raising R-SYS. So af- ter 3 days, AUTO has gradually elevated R-SYS back to normal, while the baroreceptors have basically lost their ability to push R-SYS down. Thus, stage two of VLH has a single fault: high BV. After a week or two, the kidneys (although damaged) manage to excrete enough salt and water (via urine) to reduce BV almost to normal, which in turn decreases CO. However, AUTO responds to the formerly-high CO by raising R-SYS well above normal. The typical effects of AUTO take time to reverse, since they involve changes to the size and topology of capillary beds. Hence, the characteristic fault of VLH’s third stage is high R-SYS. h Variables Day 1 Day 3 Day 14 BV +10% +18% +5% co +35% +37% +5% R-SYS -15% 0% +33% PA +15% +35% +40% Table 3: The Progression of Volume-Loading Hyper- tension If an automated diagnostician first “observes” a pa- 5 “ ,,T denotes an inverse relationship in Table 2 tient two weeks after VLH onset, it might wrongly as- sume that the root cause of high PA is high R-SYS. Thus it might prescribe various vasodilators, when in fact a low-salt diet and/or kidney dialysis would be more ap- propriate. Hence, an understanding of the entire regu- latory sequence is critical to (a) differentiating primary from secondary faults, and (b) recommending treatments for the root causes and not merely their consequences. 6 The IDUN Syste IDUN performs the following sequence of activities in diagnosing time-varying physiological models: 1. The mechanisms and initial observations are input. 2. Within each reZevapzt (see below) time slice, conflicts and rated candidates are generated. 3. Rated links are formed between candidates in adja- cent time slices. 4. The k highest-ranking chains (of candidates and links) are generated by best-first search. 5. Chain ratings combine with candidate predictions to support information-theoretic testing, whereby IDUN determines what and when to measure. IDUN moves freely about the time slices gathering data and refining candidates and chains. Thia time- hopping is analogous to a doctor’s ability to check a pa- tient’s history or to further analyze samples or pictures taken of the patient at earlier times. 6 The following sections address each of IDUN’s activi- ties in detail while tracing through IDUN’s diagnosis of a volume-loading hypertension scenario. 6.1 Initialization At the outset, IDUN receives general descriptions of the variables and mechanisms of the physiological model. For the VLH example, IDUN inputs all the information in Tables 1 and 2. In addition, we provide three ob- servations of CO and PA in accordance with Table 3. 7 These observations tell IDUN to perform diagnosis in three different time slices: 1,3 and 14 days. 6This scenario also occurs during data-intensive types of diagnosis such as core-dump analysis, where the diagnostician has ready access to time-tagged memory values but certainly does not want to look at ALL of them. 71DUN inputs the absolute measurements corresponding to the percentages about the normals in Table 3. Three .Iralues for RAP (all zero) are also inputted for this example. 560 Representation and Reasoning: Abduction and Diagnosis Regulator Baroreceptor Long-Term Autoregulation Renal Fluid Balance r Constraint R-SYS = -.17*PA + 34 R-SYS = 3.6*CO UO = 3*PA-240 Triggers high(PA), low(PA) high( CO), low( CO) high(PA), low(PA) Influences PA 0 R-SYS CO + R-SYS PA- BV PA--,VC Delay O-hours 48-hours 24-hours Duration 72 hours 00 00 u -” Table 2: Circulatory Regulators 6.2 h-ha-slice Candidate Generation: D with Fault Modes The conflicts and candidates of IDUN each pertain to a particular time slice. Each slice has a set of potentially active mechanisms (PAMs) which consists of all the basic mechanisms plus any regulatory mechanism R such that: delay(R) 5 time(slice) 5 delay(R) + duration(R) Each candidate diagnosis, C, in IDUN is characterized by a set of active mechanisms, AM(C), and a set of fault-variable modes, FVM( C), which exactly accounts for each fault variable in AM(C). The fault modes of C, FM(C) C_ FVM(C), are high and low modes. All other modes are ozormcd/unfaulted. Within a time slice, S, IDUN begins diagnosis with a single candidate, the null cundidute, in which FM(C,,ll) = 0 and AM(C,,zr) = PAM(S). IDUN en- ters each of the slice’s observed values into the constraint network and tests Cazllz via interval-based constraint propagation over AM(C,,II). Contradictions (i.e., the assignment of two non-overlapping intervals to the same variable) lead to conflict generation, candidate refine- ment, and further testing as more fully described in [7]. An eqluiozedfault mode of C is one whose real-valued interval overlaps a value predicted by a regulator, in AM(C), for the same fault variable. IDUN rates candi- dates between 0 (worst) and 1 (best), with favorable rat- ings going to those with fewer unexplained fault modes and smaller set differences between PAM(S) and AM(C). Given the aforementionned initial observations, IDUN generates the time-tagged candidates of Figure 1. 8 6.3 Inter-Slice Candidate Linkage The likelihood of a candidate depends not only on local factors, but also on the possibility of its causal linkage to 81n Figure 1, candidates appear within rectangles, while links have rounded edges. An “L” ( “H”) in front of a candi- date’s fault variable denotes “low” (“high”), and a regulator name that follows a fault mode (in square brackets) signifies that the regulator explains the fault mode; hence the fault mode’s presence will not decrease the candidate’s rating. The regulators in curly brackets are those in AM(C), which, in ail cases, includes the 4 basic mechanisms as well. The paren- thesized number is the candidate’s rating. candidates in neighboring time slices. Hence, chains of candidates, which extend from the first to the last slice, become the focus of diagnosis. The first step in building chains is the formation of links between candidates. A link, L, connects an earlier candidate, Cl, to a later one, C2. Rating(L) is simply the percentage of qualita- tive fault-mode changes between FM(C1) and FM(C2) that can be explained by the dynamic properties of a rel- evant regulator, i.e., one whose delay a.nd duration would allow it to be active sometime during the open imerval between time(C1) and time(C2): deZuy(reg) l : time(C2) A deiuy(reg) + durution(reg) > t;me(Cl) Furthermore, the explaining regulator’s trigger roust be satisfied in Cl. Triggers can be satisfied either by ob- served values or by values predicted by Cl. For the VLH example, eight of the 12 links between candidates appear in Figure 1. ’ 6.4 Global Explanation Chains After forming local links, IDUN begins at the earliest slice and performs a best-first search for the k highest- rated chains, where the rating of a chain is the product of the ratings of its candidates and links. In the VLH example, there are 9 chains; five appear in Figure 1. Notice that the middle chain in Figure 1 (call it CHl) matches our previous description of VLH progression: e Day 1: low(R-SYS), high(BV) o Day 3: high(BV) o Day 14: high(R-SYS) CHl receives the highest rating because (a) all of its links are completely explained by dynamic regulator models, and (b) every fault mode, except high(BV) on day 1, is explained by a static regulator model. Conversely, the chain to the immediate right, of CHl receives a lower rating since nothing explains the increase in BV from “normal” (on day 1) to “high” (on day 3). gEach link in Figure 1 includes (a) the significant qualita- tive changes (i.e., increase, I, or decrease, D) in fault modes between the candidates, (b) the regulators that explain those changes, and (c) a link rating. Downing 561 VOLUME-LOADING HYPERTENSION DIAGNOSES 7 Evaluating IDUN 6.5 Information-Theoretic Testing The likelihood of a candidate is best estimated by the ratings of its chains, since these reflect the likeli- hood that the candidate participates in a global diagno- sis/explanation. As fully described in [7], IDUN uses a variant of [5] ‘s entropy-based testing that (a) uses chain ratings as the basis for the probabilities of measurement outcomes, and (b) determines the best variable AND TIME SLICE for the next measurement. Using information-theoretic testing in the VLH ex- ample, IDUN determines that PV at day 3 is best to measure. An inputted value of 20 mmHg then causes a reduction in chains from 9 to 6. IDUN then asks for PV’s value at day 1. Entering 20 mmHG (i.e., +33%) reduces the set of chains to four. Unfortunately, each of these chains has identical predictions, so IDUN sim- ply produces the chain with the highest rating, CHl, as its global diagnosis. CHl corresponds to the standard medical explanation of VLH [lo]. IDUN currently runs in Common Lisp on a SUN 4. The above VLH example requires only a few seconds of run- time. To test IDUN on more sizeable models, we built a compartmental modeling interface, wherein the user enters a description of compartments, substances, trans- fers and chemical reactions. IDUN then generates the necessary steady-state constraints and fault variables. As detailed in [7], a 5-compartment physiological model of acid-base balance compiles into 39 mecha- nisms and 69 variables (16 of which are fault variables). IDUN then requires 5 minutes to diagnose a 4-time- slice acidosis-compensation scenario. IDUN’s leading chains (after 7 rounds of testing) are similar to those in the physiology literature but are weakened by the presence of excess/ ~spurious” faults in many candidates. Spurious faults stem from difficulties in accurately es- timating (a) the “requested” (by information-theoretic testing) values of different substance concentrations dur- ing different stages of, for instance, acidosis compensa- tion, and (b) th e normal, low and high ranges of fault variables, such as the permeability coefficient of the kid- neys to bicarbonate. IDUN’s use of intervals allows for imprecise estimates, but large ranges hinder CBD con- flict detection. Accurate parameter estimation is cur- rently the major obstacle to scaling-up IDUN. We have no data on information reuse in other CBD systems, so comparisons are impossible; but IDUN’s numbers for the acidosis scenario appear quite impres- sive. Of the over 2000 candidates generated, 44% were analyzed. lo 90% of the analyzed candidates were eliminated because they subsumed contradictory envi- ronments - leaving only 4% of the original candidates for actual testing (i.e., constraint propagation). During testing, an average of 94% of the varia.bles were assigned ATMS-cached values (derived earlier by similar candi- dates), thus saving considerable recomputation. 8 Discussion IDUN’s key steps to extending GDE to physiology are (a) a dissection of physiological systems into modula; mech- anisms, (b) the representation of these mechanisms in terms of steady-state constraint equations coupled with dynamic models of regulators, and (c) the analysis of candidates across multiple time slices in order to aca:ount for the temporal progression of medical conditions. ‘OlDUN maintains a maximal size, M, for candidates, where size is the number of fault-mode plus inactive-mechanism as- sumptions. Candidates larger than M are often generated but not analyzed until all candidates of size 5 M are ruled out. 562 Representation and Reasoning: Abduction and Diagnosis Recent GDEtype systems [2, 9, II] have employed dynamic component models to predict time-varying be- haviors, which derive conflicts that static models alone would miss. These systems rely on complete dynamic simulations and sophisticated temporal reasoning to di- agnose dynamic systems. We strongly believe that dy- namic simulation should not be a prerequisite to the di- agnosis of dynamic systems. IDUN embodies this tenet by separating static from dynamic analysis, thus reduc- ing the dynamic aspects to simple qualitative reason- ing. Furthermore, in the above three systems, candidates themselves are static: they presumably hold throughout diagnosis. IDUN extends GDE to handle dynamic can- didates, an important new topic in CBD [8]. IDUN is perhaps most similar to DeCoste’s DATMI [3], since both systems produce slice-dependent explana- tions (i.e., p-interps in DATMI, candidates in IDUN) and then compare them across slices to provide global expla- nations. However, [3] uses only qualitative models, re- quires an a-priori complete envisionment, and diagnoses faulty measurements rather than mechanisms. Compared to other first-principle diagnosxic ap- proaches in medicine, ID’lrN is unique in its use of the GDE paradigm. As in [13], we account for the d.elays and persistences of physiological events during diag:losis. However, while [13] mixes causal and temporal re‘zsoning via temporally enhanced causal rules, IDUN performs static and dynamic causal analysis separately in order to facilitate the information reuse indigenous to GDE. Currently, IDUN contributes more to CBD research than to AIM. It exploits the highly-regulated nature of physiological domains to illustrate the use of a hy- brid static/dynamic, quantitative/qualitative extension of GDE to diagnose dynamic faults in dynamic systems, but without performing detailed dynamic simulations. For the AIM community, we hope this research shows that CBD should not be matter-of-factly discounted from medical applications due to some inherent modeling dif- ferences between physiology and engineering. Rather, the problem lies in (a) connecting the physiological and medical levels, and (b) finding the right combination of qualitative and quantitative reasoning so that physiolog- ical CBD systems can avoid the combinatoric explosion of qualitative simulation without demanding a plethora of a-priori quantitative information about obscure phys- iological variables. I am very grateful to Larry Widman, Adam Farquhar and Oskar Dressler for their advice. eferences [l] H. Abelson and G. Sussman. Structure and inter- pretation of computer programs. The MIT Press, Cambridge, Massachusetts, 1985. [2] P. Dague, P. Deves, P. Luciani, and P. Taillibert. Analog Systems Diagnosis. Proceedings ECAI, 173- 178, Stockholm, Sweden, 1990. [3] D. DeCoste. Dy namic across-time measurement in- terpretation. Proceedings AAA I, 373-379, 1990. [4] J. deKleer and B. Williams. Diagnosis with behav- ioral modes. Proceedings IJCAI, 1324-1330, 1989. [5] J. deKleer and B. Williams. Diagnosing multiple faults. Artificial Intelligence, 31( 1):97-130, 1987. [6] J. deKleer. An Assumption-based TMS. Artificial Intelligence, 28, 127-161, 1986. [7] K. Downing. Physiological applications of consistency-based diagnosis. Submitted to Artiji- cial Intelligence ipz Medicine, special issue on inteI- ligent monitoring and control of dynamic physiolog- ical systems, 1992. [8] G. Friedrich and F. Lackinger. Diagnosing temporal misbehavior. Proceedings IJCA I, Sydney, AustraIia, 1991. [9] T. Guckenbiehl, and G. Schgfer-Richter. SIDIA - Extending prediction-based diagnosis to dynamic models. International Workshop on Principles of Diagnosis, Stanford University, 1990. [lo] A. Guyton, C. Coleman, R. Manning, and J. Hall. Some problems and solutions for modeling over- all cardiovascular regulation. Mathematical Bio- sciences, 72:141-155, 1984. [II] W. Hamscher. Modeling Digital Circuits for Trou- bleshooting. Artificial Intelligence - Special Issue on Qualitative Reasoning, 1991. [12] L. Ironi, M. Stefanelli, and G. Lanzola. Qualitative models in medical diagnosis. Artificial Intelligence in Medicine (2), 85-101, 1990. [13] W. Long. Reasoning about state from causation and time in a medical domain. Proceedings AAAI, 251-254, 1983. [14] R. Patil. Artificial Intelligence for diagnostic reason- ing in medicine. In H. Shrobe, editor, Explorations in Artifica’al Intelligence, pages 347-379, Morgan Kaufmann Publishers, 1988. [15] R. Patil, P. Szolovits, and W. Schwartz. Modeling knowledge of the patient in acid-base and electrolyte disorders. In P. Szolovits, editor, Artificial Irate& gence in Medicine, pages 191-226, Westview Press, 1982. [16] R. Reiter. A theory of diagnosis from first principles. Artificial Intelligence, 32(l), 1987. [17] L.E. Widman. Semi-quantitative “close enough” systems dynamics models: An alternative to quali- tative simulation. In L.E. Widman, K.A. Loparo, and N.R. Nielsen, editors, Artificial Intelligence, Sirneslation and Modeding, pages 159-188, John Wi- ley & Sons, New York, 1989. Downing 563 | 1992 | 97 |
1,295 | Adaptive MO sed iagnostie Mecha Yoichiro Nakakuki Yoshiyuki Koseki Midori Tanaka C&C Systems Research Laboratories NEC Corporation 4-l-l Miyazaki, Miyamae-ku, Kawasaki 216, JAPAN nakakukiQbtl.cl.nec.co.jp Abstract This paper describes an adaptive model-based di- agnostic mechanism. Although model-based sys- tems are more robust than heuristic-based expert systems, they generally require more computation time. Time consumption can be significantly re- duced by using a hierarchical model scheme, which presents views of the device at several different levels of detail. We argue that in order to em- ploy hierarchical models effectively, it is necessary to make economically rational choices concern- ing the trade-off between the cost of a diagnosis and its precision. The mechanism presented here makes these choices using a model diagnosabiliiy criterion which estimates how much information could be gained by using a candidate model. It takes into account several important parameters, including the level of diagnosis precision required by the user, the computational resources available, the cost of observations, and the phase of the di- agnosis. Experimental results demonstrate the ef- fectiveness of the proposed mechanism. 1 Introduction Model-based diagnosis is an approach that uses a be- havioral specification of a device [Davis 1984; de Kleer and Williams 1987; Genesereth 1984; Reiter 19871. Al- though model-based systems are more robust than heuristic-based expert systems, they require more com- putation time. In general, the computational complex- ity of model-based diagnosis grows rapidly with the complexity of the device model. This paper proposes an efficient diagnostic mechanism using a hierarchical model scheme. Other researchers have investigated several ap- proaches for model-based device diagnosis. One suc- cessful approach is to use probabilistic information, e.g., the minimum entropy technique (GDE [de Kleer and Williams 19871, Sherlock [de Kleer and Williams 19891) or the focusing technique [de Kleer 19911. How- ever, in order to deal with large scale problems, it is important to use not only those techniques but also a hierarchical model scheme (XDE [Hamscher 19901). A hierarchical model scheme can reason about the target device at multiple levels of abstraction: early in the diagnosis, an abstract level model can be used to elim- inate parts of the device from consideration, while later a more detailed model can be used. Since diagnostic computation at more detailed levels is generally more complex and expensive, the selection of an appropri- ate level involves making trade-offs between diagnosis cost and diagnosis precision. In order to solve this problem, XDE uses a simple heuristic algorithm that tries to keep the level of the model as high as possible. This may not always be the most efficient strategy, as shown in the empirical comparison with this paper’s more adaptive mechanism. Consider as an example the problem of diagnosing an electronic device composed of several boards, each of which is composed of several chips. Sometimes a field service engineer may only want to know which board to replace, while at other times the faulty chip must be pinpointed. Diagnostic systems should be flexible enough to adapt to the required diagnosis precision. Diagnostic systems should also minimize the total diagnosis cost, which we measure here in terms of time as the sum of the observation cost and the computation cost. The observation cost depends on the instruments being used. For example, the manual method of using a logic analyzer to capture a digital signal from a de- vice is expensive, whereas an electron-beam tester can easily observe a signal anywhere within an MI chip. In the manual case the number of observations taken will greatly affect the total diagnosis cost, while in the latter case the total cost will mainly be determined by the computation cost. Thus a diagnostic system should respond to both the observation cost and the computation cost. This paper presents a diagnosis mechanism that takes into account four parameters: the phase of di- agnosis, the computational environment, the cost of observing the target device, and the required diagno- sis precision. Section 2 gives an illustrative example of a hierarchical model, and shows how information gain can be measured at various levels. Section 3 pro- 564 Representation and Reasoning: Abduction and Diagnosis From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. poses a model diagnosability criterion for estimating how much information could be gained from the vari- ous models. Section 4 proposes an adaptive diagnosis algorithm based on that criterion. Section 5 concludes with suggestions for several generalizations and exten- sions of the algorithm. 2 iagnosis with ierarchical Models In most conventional hierarchical model-based ap- proaches [Davis 1984; Hamscher 19901, the struc- ture of a device is represented both as a phys- ical hierarchy and as a logical (functional) hier- ar thy . The required diagnosis precision is usu- ally represented as a level in the physical hierar- chy. Taking the example of the device shown in Fig. 2-1, if the required diagnosis precision is the chip level, then a diagnostic system tries to find the faulty chip(s) among the three chips Cl, C’s, and Cs. Board level Chip level - Gate level --II G12 G13 G14 Gal G22 G23 G24 G31632 G33 G34 Fig. 2-1 Hierarchical structure In general, physical hierarchies and logical hierar- chies have different structures [Davis 19841. To sim- plify discussion, this paper assumes that they have the same structure, and also assumes that there is only a single fault in the target device. However, the proposed techniques can easily be extended to remove these as- sumptions. Consider the hierarchical model scheme shown in Fig. 2-2. A full adder (a) is composed of five subcom- ponents, and an g-bit ripple carry adder (b) comprises eight full adders. (a) Full Adder (b) &bit Ripple Carry Adder Fig. 2-2 Hierarchical Model Scheme There are 256 distinct models for an &bit ripple carry adder; of the three shown in Fig. 2-3, model X is the most abstract, model Z is the most detailed, and model Y lies between the two. In general, diagnosis from a more detailed model is more expensive, but it is also more specific. The selection of an appropriate level for a given diagnostic situation should take into account how much information can be gained at each differ- ent level of model detail. The next section presents a method of estimating this information gain. Model Y Model Z Fig. 2-3 Example 2.1 iagnosis Precision and Entropy Several existing systems [de Kleer and Williams 1987; de Kleer and Williams 1989; Hamscher 1990; Koseki et al. 19901 use the entropy of a set of suspected com- ponents to estimate the expected information needed to complete a diagnosis. However, the expected in- formation generally depends on the required diagnosis precision, as illustrated by the faulty 2-bit ripple carry adder shown in Fig. 2-4. Changes of diagnostic status are shown at two different levels: (a) the function-level, and (b) the gate-level. The suspected components are shown hatched; white components are no longer sus- pected. The fault probability P(C) for each suspected component C is also shown. The figure gives the ini- tial diagnostic status, and the status after each of two different sets of observations, A and B. lnltlal State P(Fl)=P( F2)=0.5 P( F2)=1 .O P( F1)=0.33 P( F2)=0.67 (a) Function Level initial State P(Oij)=O.l (id 12 j=l,2,3,4,5) P(G2j)=O.25 (j=l,3,4,5) (b) Gate Level Fig. 2-4 Chauges of Diagnostic Status Nakakuki, Koseki, and Tanaka 565 Fig. 2-4(a) illustrates the case where the required precision is the function-level. If we get observation A, showing that Fr is normal, then the diagnosis is over. But even if we get observation B, both Fi and F2 are still suspected. At this level, observation A seems to be more informative than observation B. But in Fig. 2-4(b), h w ere the required precision is the gate- level, observation A reduces the number of suspected components to four, whereas observation B reduces it to three. At this level observation B is more informa- tive than A. This contrast illustrates the importance of taking into account the desired diagnosis precision when measuring the information gain. In order to measure the information gain according to the given precision, we calculate the entropy for each level in the physical hierarchy. For instance, in the above example the entropy for the function-level (EF) and for the gate-level ( EG) are defined as follows, and are expressed in terms of bits. EF = - c P(Fi) log P(Fi) i EG = -xrP(G;j)logP(Gij) i j Fig. 2-5 summarizes the reduction of entropy achieved by the observations, in both levels of the above exam- ple. 1:o Entropy 0.0 1 Obs. A * 1 .OO --* 0.00 Obs. B * i 1 .oo -+ 0.92 (a) Function Level Entropy EF (b) Gate Level Entropy EG Fig. 2-5 Changes of Entropy The entropy at a given level is regarded as the re- maining information required to complete a diagnosis at that level of precision; when it has been reduced to zero no further information from observations is re- quired. The algorithm proposed here chooses the ap propriate figure for entropy according to the level of precision required. For example, if the required preci- sion is the function-level, it tries to reduce EF, whereas if gate-level precision is required, it will use the gate- level entropy, EG. 3 Model Diagnosability Criterion This section introduces a model diagnosability crite- rion that provides an estimate (in terms of entropy) of the most detailed diagnosis that is achievable using a given model. Consider the three models for a Zbit ripple carry adder shown in Fig. 3-l. Assume that the required di- agnosis precision is the gate-level and that each of the ten gates, Gij (i = 1,2; j = 1,2,3,4,5), has the same fault probability of 0.1. (Thus under the single fault as- sumption the probability failure for each function-level component, F;, is 0.5.) This section works through the calculation of the minimal entropy achievable by mod- els A, B and C. Model A ww Model B GllGw G21G22 1 Model C Fig. 3-l Models for a 2-bit Adder Using model A, if enough observations are given, it is possible to find a faulty function (Fl or F2), but the faulty gate in the function can never be pinpointed. If, for instance, the faulty component is Gli, the sys- tem can only conclude that the faulty component is Gri, G12, Gls, G14, or G15 with probability 0.2 each. With model A the gate-level entropy can never be re- duced below 5 . (-0.2logO.2) = 2.32. No matter how many further observations are given, the system still cannot obtain the additional 2.32 bits information needed. Using model B the system can (given enough obser- vations) find the faulty gate provided it is one of the five gates, G2j (j = 1,2,3,4,5). If not, the entropy can not be reduced to less than 5 . (-0.21ogO.2) = 2.32. Thus the expected lower bound for the entropy reduc- tion is: 0.5 - 2.32 + 0.5 - 0 = 1.16 Using model C, the faulty gate can always be found (given enough observations), so the expected lower bound for the entropy reduction is 0. As an estimate of the completeness of the diagnosis achievable by a model, we define the model diagnos- ability D(M) for a model M. The maximum value of 1.0 indicates that complete diagnosis always achiev- able. D(M) = Ecu;- E~ow cur Here, Ecu, is the current entropy and El,, is the ex- pected lower bound for the entropy. The current en- tropy expresses the expected information needed to 566 Representation and Reasoning: Abduction and Diagnosis complete a diagnosis. The numerator (E,,, - EJ,,) in- dicates how much information is expected to be gained by using model M. In the example above, current entropy is 10 . ( - 0.1 log 0.1) = 3.32 at the initial stage of a diagnosis (Fig. 3-2(a)). Therefore, the D(M) for each model is calculated as follows: D( modelA) = 3.32 - 2.32 = o 3. 3.32 . D( modeli?) = 3*3:;l’16 = 0.65 . D(modelC) = 3’3~~~*oo = 1.00 . Fig. 3-2(b) summarizes these results. It shows that a diagnosis with model A can gain at most 30% of necessary information, but model C is powerful enough to gain all the necessary information. GllGi2 P GmG14Gi5 G23G24G25 (4 3. Model A Model B Model C 03 Fig. 3-2 Initial Stage Next assume that the set of suspected components has been narrowed down by some observations to those hatched in Fig. 3-3(a). Then the values for D(M) change to those shown in Fig. 3-3(b). Now no infor- mation can be gained if model A is used, but model B and C have the ability to gain the all information needed to pinpoint a faulty gate. GllG12 ? G21 Ga GI~GI~GIS Ga Ga G2s (a) 2. 0 D(M) Model A 0.00 Model B 1 .oo Model C 1 .oo (b) Fig. 3-3 Later Stage 4 Adaptive Diagnosis Mechanism The previous section introduced the model diagnos- ability criterion; this section presents an adaptive di- agnostic algorithm called HIMA that uses that crite- rion to select an appropriate model at each stage of a diagnosis. Let D(M) be the diagnosability for model M, and let C be the average cost of an observation (in terms of the time required to make it). The diagnostic process con- sists of several observation/computation cycles (also called phases), so T(M) + C is the expected cost for a cycle, where T(M) is the expected time to calculate the suspects (given an observation) under model M. We assume that T(M) can be estimated empirically or analytically, and that C is a model-independent con- stant. To choose an appropriate model, we evaluate each model by using the following criterion: E(M) = DW) T(M) + c At each diagnostic cycle the model with the greatest value for E(M) is selected as the best one. This diagnostic mechanism adapts its choice of level according to several factors: the phase of the diagnosis, the given diagnosis precision, and the costs of observa- tion and computation. The remainder of this section is a worked example illustrating the algorithm’s behavior under two differ- ent economic situations: first where the cost of obser- vations is very low relative to computation time, and then when it is relatively high. Returning to the three models of &bit ripple carry adder of Fig. 2-3, assume that the required diagno- sis precision is the gate-level and that the expected computation time for each model is as follows. (These values are derived empirically using our diagnostic en- gine [Koseki et al. 19901.) T(modeZ X) = 0.30 (set) T(model Y) = 0.39 (set) T(mode1 2) = 1.22 (see) First consider the case where the cost of observations is relatively low, i.e. C << T(M) for each model M. Then E(M) can be approximated as: Nakakuki, Koseki, and Tanaka 567 (a) Initial Stage (b) Later Stage Fig. 4-l Examples of Diagnostic Stages IInitial stage 1 Fig. 4-l(a) shows the initial stage of the diagnosis, when all gates are suspected with the same probability (l/40). At this stage model X is se- lected because it has the largest value for E(M), as shown in Table 4-l(a). Model X can gain about 56% of the necessary information at a low cost. (Laterstage Suppose that after some observe tions, the diagnosis has proceeded to the state shown in Fig. 4-l(b). The values for E(M) in Table 4--l(b) show that model Y should now be selected. Model X can gain at most only 30% of necessary information, and model 2 is relatively costly. Table 4-l E(M) for each model (C<< T(M)) (a) Initial Stage I z I 1.00 1 1.22 1 0.82 1 (b) Later Stage Model Diagnosability Cost E(M) X 0.30 0.30 1.00 Y 0.65 0.39 pq z 1.00 1.22 0.82 This example shows the HIMA algorithm’s ability to change the level of the model appropriately at each stage. Now consider the opposite case, where the cost of observations is high relative to the computation cost, i.e. T(M) << C for each model M. In this case the diagnosis cost is barely affected by the observation cost C. For example, if C = 100.0 set in the above exam- ple, then the diagnosis cost (the sum of the observation cost and the computation cost) for models X, Y and Z are 100.30, 100.39 and 101.22, respectively. Table 4-2 shows that model Z will be selected in both stages of the diagnosis. Intuitively this shows that when obser- vations are expensive, it is worth maintaining a very detailed model at all times, whereas if observations are cheap, this detail is needed only in the later stages. Table 4-2 E(M) for each model (T(M)< C) (a) Initial Stage L Model 1 Diagnosability 1 Cost I E(M) I x I 0.56 1 100.3 1 0.0056 1 Y 0.62 100.4 0.0061 Z 1.00 101.2 (a.oo991 (b) Later Stage Diagnosability Cost 1 Jww This contrast illustrates the HIMA algorithm’s abil- ity to adapt to the dynamic economics of the obser- vation and computation. Computation cost obviously depends on the computing machinery available; a l- MIPS computer will require far more time than a lOO- MIPS machine, so it is important that this factor is specified as an input to the algorithm. Finally, suppose that the required diagnosis preci- sion were changed from the gate level to the function- level in each of the two examples above. All of the three models have enough diagnosability, so model X would be selected because it has the least expected cost among the three. This illustrates the adaptabil- ity of the HIMA algorithm to the required diagnosis precision. 4.1 Algorithm In general, there are huge number of possible models for a given hierarchical model scheme and target de- vice, and this number grows exponentially with the number of components in the device. Since it is im- practicable to test all possible models, we aim to reduce the number of models considered. The following pseu- docode for the HIMA algorithm introduces a heuristic search mechanism to achieve this end. M c Most abstract level model; while {there is an expandable component ci in M and E( expand(M, ci)) > E(M)} M + expand(M, ci); Expandable components are those that have mod- els at a more detailed level, and expand(M, c;) is a model obtained from model M by replacing com- ponent cd with the components that comprise ci at the next level below. For example, in Fig. 2-3, 568 Representation and Reasoning: Abduction and Diagnosis model U=expand (Model X, f7) (f7 is the seventh full-adder from the left). No component of model Z is expandable. The algorithm requires time linearly pro- portional to the number of components in the model scheme. 4.2 Experimental Results We evaluated the performance of the HIMA algorithm on a 16bit adder represented by a three-level hierar- chical model scheme. The number of components at successive levels was 2, 32 and 160. The required di- agnosis precision was set to the most detailed level. The performance of the HIMA algorithm was com- pared to the two obvious “strawman” algorithms that could be used in two extremely different diagnostic en- vironments. Results show that the HIMA algorithm outperforms both strawman algorithms, even under the conditions most favorable to each. The first strawman, FIX, uses a fixed model throughout the diagnostic process, determined by the required precision (so in this case, the most detailed level model is always used). The other strawman al- gorithm, AHAP, keeps the level of the model to use as high as possible: it changes to a more detailed level only if there is no possibility of gaining information using the current model. Single faults were generated randomly, and the aver- age cost (the sum of computation cost and observation cost) of pinpointing the faulty component was mea- sured. The experiments were performed with three different expected observation costs (lmsec, lsec and 100sec). The results shown in Table 4-3 show that the HIMA algorithm performs best in all cases. Table 463 Average Diagnosis Cost (set) Algorithm Expected Observation Cost 3 Discussion The technique described in this paper adapts to several factors: the required precision, the given computation power, the observation cost, and the phase of diagnosis. Although some simplifying assumptions were made to the diagnosis problem, the proposed mechanism can naturally be extended to more general cases, which have natural justifications in the real-world diagnosis tasks. First, the diagnosis precision need not be re- stricted to a fixed level in the physical hierarchy. For example, according to the availability of spare parts, chip-level precision may be required for some parts of the target device, and board-level precision may be required for others. Second, the physical hierarchy and the logical hierarchy need not be identical. Third, whereas we assumed that the observation cost is model independent, this need not be the case: the output sig- nal of a whole board may be cheaper to observe than the output signal of an intermediate chip. The HIMA algorithm can be extended in several other ways. First, in some domains it may be prefer- able to modify the model diagnosability criterion, be cause it does not estimate the number of required ob- servations. For example, even if D(M) = 0.9 for a certain model M, a diagnosis with the model may re- quire dozens of observations to gain this 90% of the necessary information, so the criterion does not always estimate the diagnosability exactly. Second, the algo- rithm requires estimates of the computation cost and the fault probability for each component. Inductive learning techniques [Nakakuki et al. 19901 or analyti- cal methods can provide this. Acknowledgment This research has been carried out as a part of the Fifth Generation Computer Project. The authors would like to thank Katsumi Nitta of the Institute for New Gen- eration Computer Technology for his support. The authors also would like to thank Masahiro Yamamoto and Takeshi Yoshimura for their encouragement in this work, and Jason Catlett for his valuable suggestions. References Davis, R. 1984. Diagnostic reasoning based on struc- ture and behavior. Artificial Intelligence 24:347-410. de Kleer, J. and Williams, B. C. 1987. Diagnosing multiple faults. Artificial Intelligence 32:97-130. de Kleer, J. and Williams, B. C. 1989. Diagnosis with behavioral modes. Proc. IJCAI-89 2:1324-1330. de Kleer, J. 1991. Focusing on probable diagnosis. Proc. AAAI-91 21842~848. Genesereth, M. R. 1984. The use of design descrip- tions in automated diagnosis. Artificial Intelligence 24:411-436. Hamscher, W. 1990. XDE: Diagnosing devices with hierarchic structure and known component failure modes. Proc. CAIA - 90 1:48-54. Koseki, Y.; Nakakuki, Y.; and Tanaka, M. 1990. An adaptive model-Based diagnostic system. Proc. PRI- CAI’90 1:104-109. Nakakuki, Y.; Koseki, Y.; and Tanaka, M. 1990. In- ductive learning in probabilistic domain. Proc. AAAI- 90 2:809-814. Reiter, R. 1987. A theory of diagnosis from first prin- ciples. Artificial Intelligence 32:57-95. Nakakuki, Koseki, and Tanaka 569 | 1992 | 98 |
1,296 | Reasoning MPE to Multiply Connected Belief Networks Using Message Passing Bon K. Sy Queens College of the City University of New York Department of Computer Science 65-30 Kissena Boulevard Flushing, NY 11367-0904 Email: bon@lqcvax. bit net bon@cunyvmsl.gc.cuny.edu Abstract Finding the I Most Probable IJxplanations (MPE) of a given evidence, Se, in a Bayesian belief network is a process to identify and order a set of com- posite hypotheses, His, of which the posterior probabil- ities are the I largest; i.e., Pr(Hii&) 2 Pr(H21&) 2 . . . L Pr(&ISlz)~ A composite hypothesis is defined as an instantiation of all the non-evidence variables in the network. It could be shown that finding all the probable explanations is a NP-hard problem. Previ- ously, only the first two best explanations (i.e., I = 2) in a singly connected Bayesian network could be effi- ciently derived without restrictions on network topolo- gies and probability distributions. This paper presents an efficient algorithm for finding d (2 2) MPE in singly- connected networks and the extension of this algorithm for multiply-connected networks. This algorithm is ba- sed on a message passing scheme and has a time com- plexity O(lkn) for singly-connected networks; where I is the number of MPE to be derived, k the length of the longest path in a network, and n the maximum num- ber of node states - defined as the product of the size of the conditional probability table of a node and the number of the incoming/outgoing arcs of the node. Whenever a variable in a Bayesian network is ob- servable, this variable is referred to as an evidence vari- able. The set of evidence variables is represented by S,. Given a Se, an instantiation of all the non-evidence variables - H - in a Bayesian belief network is referred to as a composite hypothesis. Each H is said to be a probable explanation of the given observation, S,, in a Bayesian belief network if Pr(HjS,) > 0. Finding the I Most Probable &xplanations (MPE) of a given evidence, Se, in a Bayesian belief network is to iden- tify and order a set of composite hypotheses, His, of which the posterior probabilities are the 2 largest; i.e., J+(&]S,) 2 Pr(HzlS,) L . . . L P+&]SJ. 1. Introduction A Bayesian belief network [Pearl, 19861 is a graph- theoretic approach for the representation of probabilis- tic knowledge about the inter-dependencies among a set of random variables. This kind of knowledge represen- tation technique has recently been applied to various problem domains [Charniak & Goldman, 19911 [Dean, 1990][Andreassen et al, 19911, and particularly in the domain of diagnosis [Shwe, et al 19911. A problem to be addressed in this paper is related to the generation of the most probable explanations to an observation from a Bayesian network. We believe that the solution of this problem will be very useful to the development of probabilistic inference algorithms for solving diagnos- tic problems which are modeled using Bayesian belief network representation. Since the number of composite hypotheses expo- nentially increases with respect to the number of non- evidence variables, finding all the probable explana- tions is generally NP-hard. [Santos, 19911 proposed a linear programming approach to solve this problem but the complexity is found to be subexponential. Even if we are interested in only the few most probable compos- ite hypotheses, there is still exponential number of com- posite hypotheses to consider. It is possible to reduce the search space if certain probability distributions of the variables in a network are assumed. [Cooper, 19841 demonstrated that if Pr(E;IS,) 2 Pr(EjlS,) holds for all Eis and Ejs whenever the number of instan- tiated variables in Ej is larger than that in Ei, then finding the most probable composite hypotheses can be formulated as a search problem, and the best-first search strategy with branch and bound pruning can be applied. Although this approach is efficient and per- mits reasoning on hypotheses which do not include all the non-evidence variables, [Henrion, 19901 pointed out that the assumption is too strong and such an assump- tion is hardly valid in any real world problem. An- other approach being explored by [Shimony & Char- niak, 19901 is to transform a Bayesian network into a Weighted Boolean Function Directed Acyclic Graph (WBFDAG) which p ermits the application of the best- first search strategy. The major distinction of this ap- proach in comparison to Cooper’s approach is that no 570 Representation and Reasoning: Abduction and Diagnosis From: AAAI-92 Proceedings. Copyright ©1992, AAAI (www.aaai.org). All rights reserved. assumption is made about the probability distributions. However, the spatial complexity of a WBFDAG is in an exponential order of the original DAG; where the spatial complexity is defined in terms of the size of a network. Although the time complexity is shown to be linear with respect to the size of a graph, the exponen- tial complexity problem remains. Another approach being taken is to take advantage of the structure of a network. [Pearl, 19881 h as shown a message passing algorithm which can efficiently derive two most prob- able composite hypotheses in a singly-connected net- work. In a singly-connected network, any pair of nodes is connected by at most one unique path. Unfortu- nately, Pearl’s algorithm has two limitations. First, it cannot be applied to multiply-connected networks (i.e., non-singly connected networks). Second, Pearl’s message passing scheme cannot be extended to find- ing more than the first two most probable composite hypotheses. The objective of this paper is to introduce a mes- sage passing scheme for the derivation of the most prob- able composite hypotheses. The mechanism of our mes- sage passing process, in essence, is similar to Pearl’s algorithm [Pearl, 19881. However, our method differs from Pearl’s and others’ algorithms in four ways. First, the message passing in our method is unidirectional as opposed to bidirectional in Pearl’s algorithm. Second, each “message stream” in our method is a vector but not a value as in [Pearl, 19881. Third, we retain all pro- cessed information to permit their reusage in a system- atically ordered fashion for the successive derivation of the most probable composite hypotheses. Finally, our message passing scheme can be applied to a tree-type hypergraph which is critical in dealing with multiply- connected networks. In section 2 we will discuss the formalism of Bayes- ian belief networks and the realization of our message passing scheme as an unidirectional path traversal in a hierarchically organized graph. In section 3 we will de- tail the mathematical formulation of our message pass- ing scheme. The treatment of multiply-connected net- works will be discussed in section 4. In section 5 we will conclude this paper with a discussion of the rela- tionship of this research with others in the field and future research work. 2. Formalism of Bayesian belief networks A Bayesian network [Pearl, 19861 is a Directed Acy-clic Graph (DAG) within which a set of nodes are connected by a set of arcs. Each node in a graph rep- resents a random variable, and an arc connecting two nodes indicates the dependency between them. In par- ticular, head- to-head, head- to- tail, and tail- to- tail are three configurations to specify the marginal and condi- tional independencies among 3 adjacent nodes. These three configurations, together with the definitions of “joint” and “separate” discussed in [Pearl, 19861, per- mit the joint distribution of a Bayesian belief network shown in Fig. 1 to be re-written as below: Pr (abcdefghij) = PT(a)PT(bla)PT(clb)P~(d)PT(elcd)Pr(flb) P~(slf>P~(hls>Pr(;lfj)Pr(j) (1) Note that the Right Hand Side (RHS) expression of (1) is in a form of III,ENPr(z;]J,,); where N is the set of nodes in a Bayesian belief network, and JZi is the set of immediate parents of xi. This expression is a sim- plified form of the Bayes expression obtained from the marginal and conditional independency characteristics of the distribution of the network. The realization of the RHS expression of equation (1) signifies two impor- tant characteristics. First, the spatial complexity of the RHS expression is in the linear order of the sum of the number of states in each probability term, as opposed to the exponential order (with respect to the number of variables) as the expression in the LHS. Second, each probability term in the RHS, PT(x;]J,~), can be con- ceptualized as a local probability term associated with the node x;. Each of these local probability terms con- stitutes the basis of the information to be passed to its neighbors in our proposed message passing scheme. Let’s first consider the singly-connected network shown in Fig. 1. The idea of our message passing scheme is to propagate the minimum amount of infor- n a i” __...... ___________.___ . . . . . . . . _ ..__ _ ___.: i message i 1 propagation / h ii Fig. I: A ten-node singly connected Bayesian network. SY 571 Direction of Message Fig. 2 Message Flow Graph mation needed towards a designated node via a set of unique paths which cover all the nodes in a net- work. For example, suppose node a is selected as a designated node (i.e., a sink) to absorb the incom- ing information from every other node in the network. Then three unique paths can be identified; namely, d + e --) c --) b + a, h + g + f ---) b 3 a, and j+i--,f--,b-,a. For the sake of discussion, each variable in Fig. 1 is represented by a lower case letter and is assumed to be binary-valued - true or false. An upper case letter represents the value of a variable. For example, X and X represent x = X (i.e., true) and x = X (i.e., false) respectively. In addition, each node in the three unique paths discussed previously can be replaced by the probability terms of all its possible instantiations, and the three unique paths can now be represented in terms of the probability terms’ of the nodes as shown in Fig. 2. The purpose of conceptualizing these three unique paths as a graph is for the realization of our proposed message passing scheme to be discussed in ’ Only consistent terms are connected. the next section. 3. Message passing using local propagation To illustrate the local computation involved in our proposed message passing scheme, let’s suppose we are interested in finding the most probable composite hy- potheses without evidence (S, = 0) in Fig. 1; i.e., ArgMax[Pr(abcdefghij)]. Finding the most probable composite hypothesis is equivalent to finding the opti- mal setting for each of the local probability terms in the RHS of equation (1). Since Fig. 1 is a singly- connected network, any two non-adjacent nodes are conditionally independent given that at least one node in the unique path connecting the two nodes is (un)inst- antiated to separate them. This conditional indepen- dency property implies that the identification of the optimal setting of a particular local probability term depends on only the ascendant terms. For example, in order to determine the optimal setting for the term Pr(clb), it depends only on the terms Pr(elcd) and Pr(d), but not Pr(bla), B(a) (the descendant terms in Fig. 2), or ~+lg), f+(glf), Wf 1% P(j), P+l.Lf) (the out-of-branch terms in Fig. 2). This permits the 572 Representation and Reasoning: Abduction and Diagnosis optimal setting of each local probability term to be searched locally in an unidirectional downward propa- gation (in Fig. 2). An important question to ask now is the kind of information which should be carried in the message passing process. One of the considerations is to anticipate the possible settings of the immediate descendant terms in Fig. 2. For example, the infor- mation that should go from Pr(h]g) to pr(g]f) would be all the possible settings of g. That is, the informa- tion to be passed from node h to g would be Mh,, = [Illazh[Pr(h]G)], Mazh[Pr(!@)]]. The next message propagation from node g to f, however, should con- sider both [lMazg[Pr(g]F)], MuxSIPr(gIp)]] as well as Mb-s. In order to integrate the information prop- erly, a convolution operation, *, and a Belief matrix are defined for this purpose. Definitionl: Given &-+2 = [n&+,x1 md-& . . . ??&&+X,], and Pr(a]J,) = [Pr(Xi]z11,) Pr(Xr]v2,) . . . Pr(XT,]&)] ( w h ere vi, is an instantiation of the vari- ables in J,), the convolution of Md-2 with Pr(s]JZ) is defined as the product of every single term in Pr(z]J,) with a consistent md+Z in Mdde; where J:, is the set of immediate parent nodes of x in a Bayesian belief network. Pr(x]J,) and m&,Z are consistent with each other if the instantiation of x in md-+Z and that in PT (x IJz) are identical. Definition2: A Belief Matrix of a node x, BeZ(x), is defined as the convolution of all Md+z with pT(x]J,) -- n&J,,, * _&&jZ-+Z * . . . * M&-+3 * PT(X1J,); where di are the nodes which propagate Mdi-+2 to x for i = l...b. To illustrate the definitions of convolution and be- lief matrix, let’s suppose A&+, = [mh-+G m&G] = [(HG 0.6) (HG 0.8)] and Pr(glf) = [I;; ;*;; . then we have Del(g) = A&.-+, * Pr(g]j) = [ (HGF 0.18) (HGF 0.27) (HCF 0.56) (HGE 0.44) I Remark: Pr(h]g) in &?h_,g is represented by a 2- tuple. The first tuple is the settings of h and g, and the second tuple is Pr(hlg). For example, (HG 0.6) in MfZ-s is equivalent to Pr(H]G) = 0.6. With these two definitions, M,,f can be formu- lated as M’uxg[BeZ(glF) BeZ(glF)]; i.e., M,,f = [(WCF 0.56) (HGF 0.44)]. Lemma1 summarizes the fOrIdati0~ Of a message Stream .ktb-a: Lemmal: A message stream that a node b propagates to a node a in a Bayesian belief network (in Fig. 1 but not Fig. 2) is defined as Muxb[Bet(blA) Bel(blii)] i&-w = if a is ,an immediate parent of b; Mux[BeZ(B) Bel(B)] if b is an immediate parent of a; ikf&-+b * . . . * &&-+b * Pr(blqh...Pk) if a is an immediate parent of b; *i&-b * P+‘ln...pk) if b is an immediate parent of a; dl . . . dl, = are the immediate descendent nodes of b, and pr . . . pl are the immediate ascendent nodes of b. Remark: If node b is a root node, Mb+.* is simply [(B Pr(B)) (B wm1~ It is possible that the instantiation of a variable for the maximal value of BeZ(e) is not unique. In this case, all such instantiations must be included in a mes- sage vector in order to find all the MPEs. However, if we are interested in only one of the MPEs, then we can break tie arbitrary. Due to the unidirectional mes- sage propagation, the arbitrarily selected instantiation is guaranteed to be one of the solutions. This elimi- nates the need of carrying all instantiatious via explicit pointers, which is required in the Pearl’s bidirectional message propagation [Pearl, 19881. Note that 2Mb-a described in Lemma1 is a prun- ing process illustrated in Fig. 2 that, at each level, all the links, except one, in each group of the vari- able instantiations are pruned (marked by “x”). For example, Fig. 2 illustrates part of the pruning pro- cess2. If we look at the message passing from node e to c, only one link from e to c remains for each pos- sible instantiation of c; i.e., from Pr(e = EIC,d = D) + Pr(Clb = B), and from Pr(e = El6’,d = D) ---) P@lb = B). Similarly, only the links from Pr(c = C]B) + Pr(B]u = A) and Pr(c = C]B) -+ Pr(B]u = A) remain unpruned. When the informa- tion from each node reaches the designated sink (node a), the most probable composite hypotheses can be re- alized from ArgMux,[BeZ(A) BeZ(~)]. Once the most probable composite hypothesis is found, let’s say, ABCDEF~l?rJ, the path correspon- ding to this instantiation in Fig. 2 is marked (those marked with “0”). To find the second most probable composite hypothesis, the candidate must be from one 2 The actual spatial complexity of Fig. 2 is only proportional to the total number of unpruned links be- cause only unpruned links are stored. SY 573 of the unpruned links, or undeleting some of the pre- viously pruned links in which variable instantiation is exhausted. For example, once the link from Pr(E]CD) -+ Pr(C]B) (in Fig. 2) is marked after the most prob- able composite hypothesis is identified, the informa- tion to be passed from node e to c with node c be- ing instantiated to C is exhausted. In this case, the links, Pr(elCd) -+ Pr(Clb) (i.e., A&,,), are undeleted (indicated by “Q”); e.g., Pr(EjCn) + Pr(CIB) and Pr(ElCD) -+ Pr(qB) are undeleted. These two piec- es of new information are used in Pr(ejCd) * Pr(Clb) to update the belief matrix Bel(c), and the second largest of BeZ(C) is added to the previous message stream to be propagated for the next local computation. Such an updating is then repeated at each level, and at each iteration for identifying the next most probable com- posite hypothesis. In essence, we need to keep track at most n terms for each instantiation xi of a given variable, X, in computing the n most probable composite hypotheses. When an instantiation ~i of a variable X and some in- stantiation yj of a variable Y in A&x-y are identified as the settings for the most probable interpretation in, let’s say, L-jth iteration, then the k-largest term with the instantiation of the variable X to be xi (and some instantiation of Y) is the only additional information to be included in the Ith iteration. Therefore, the size of the message vector will grow incrementally as the number of iteration increases. Such a linear increment is the worst case in which the size of a message vector will grow per iteration. In the best case, the size of a message vector will remain the same as the one in the previous iteration. Due to the page limit, the readers are referred to [Sy, 1992a] for the detailed discussion. We have also proved in [Sy, 1992a] that the information propagated at each level and at each iteration accord- ing to the process just described is complete and is the minimal amount which is needed in identifying the next most probable composite hypothesis. The following is the algorithm of this message passing scheme: Step 1: Define I + length of partial ordering (i.e., number of most probable composite hypotheses to be sought), and Se c the evidence. Step 2: Designate a node as a sink, identify the paths for the propagation of message streams, and construct the corresponding flow graph using the (instantiated) local probability terms associated with each variable. Initialize the iteration count, i = 1. Step 3: Compose Mb_,+, using Lemmal, and propa- gate messages along the proper paths identified in step 3 I. Step 4: Perform convolution operation to integrate incoming messages and update Belief matrix, Bel(x), at each node traversal. Step 5: Identify the setting of the composite hypothe- sis with the i-largest Pr(H;ISB) in the designated sink node at the ith iteration. Step 6: Mark the path which corresponds to the most probable composite hypothesis just found. Step 7: Undelete the previously pruned paths in which variable instantiations are exhausted. Step 8: Repeat steps 3 to 8 until i reaches 1. Noted that the algorithm shown above is based on the propagation of quantitative vector streams towards a designated sink node in a network. In a complete iteration of propagating the vector streams to the sink node, one composite hypothesis of the ordering can be identified. To obtain the I most probable composite hypotheses, I iterations will be needed. When parallel processing is permitted, the amount of time required for each iteration will be at most the amount of time required for the convolution operations in the longest path (i.e., length k stated in the theo- rem). Note that the node states, n - defined as the product of the size of the conditional probability table of a node and the number of incoming/outgoing (de- pends on the direction of message flow) arcs of the node in a Bayesian belief network (Fig. 1) - is the worst case of the time complexity of one convolution opera- tion. The time complexity for one iteration is O(h), and for 2 iterations, the time complexity is O(Zkn). The details of a formal proof of this complexity order and the completeness of the message passing scheme are referred to [Sy, 1992a]. 5. Coping multiply-connected network The message passing scheme discussed and illus- trated in the previous sections fails to produce correct inference when the Bayesian belief network is multiply connected, One of the main reasons is that a common parent node or a common daughter node (such as nodes a and d in Fig. 3 respectively) may receive conflicting messages along the paths of propagation. For example, suppose the propagation paths relevant to nodes a, b, c, and d are d + b + a and d ---) c + a in Fig. 3. Node a may receive different values of b and c when the maximum of Pr(bja)Pr(dlbc) and Pr(cla)Pr(d\bc) are considered via different paths. In order to apply the message passing algorithm to a multiply connected network, the knots in a multiply connected network must be broken up; for example, a- b-d-c-a in Fig. 3. Clustering and cutset conditioning are two techniques [Pearl, 1988][Neapolitan, 1990][Peot & Shachter, 19911 for resolving these knots. The basic idea of clustering is to lump variables together to form compound variables as a method of eliminating knots. 574 Representation and Reasoning: Abduction and Diagnosis Fig. 3. Multiply Connected Network Fig. 4. Singly Connected Compound-Variable Network For example, nodes b and c in Fig. 3 can be lumped together as a compound variable bc. However, a disad- vantage of this approach is that the belief relevant to a compound variable explains less in terms of the be- lief accrued by each individual variable in a compound variable. The other technique - cutset conditioning - is based on the idea that a parent node can be absorbed into one or more of its immediate descendant nodes for the purpose of breaking up knots. For example, node a in Fig. 3 can be absorbed into node b to obtain a singly connected network once node a is instantiated to have a fixed value. This approach, however, renders an expensive computation because all possible values of the absorbed nodes (node a in this case) have to be considered in the process of local computation. The technique that we employ to resolve knots is a combination of clustering and cutset conditioning. There are two major steps in our proposed technique in breaking up knots. The first step is the formulation of a singly connected version of the multiply connected net- work. The second step is the construction of the density function. Whenever a parent node, x, is absorbed by its immediate descendant nodes, this parent node and the compound variable are marked as special nodes where all possible values of x must be propagated in the mes- sage passing process. For example, the multiply con- nected network shown in Fig. 3 can be formulated to have a singly connected version (Fig. 4) after node a is absorbed by node b to form a compound-variable node ub, and node ub is absorbed by node e to form ube. These compound-variable nodes are marked as special nodes and all the possible values of a, ub, and ube must be included as the messages during the message prop- agation. In order to illustrate the necessity of this, let’s suppose the message propagation paths are from a + c + d + ub and ube + e -+ d + ub. Since nodes a, ub, and ube will all influence the setting of a in find- ing the most probable composite hypotheses, all possi- ble values of a and b must be carried along the message propagation. This step has the same effect as creating multiple copies of the absorbed nodes and keeping track of their values to ensure consistency. Before we can ap- ply our proposed message passing scheme, the density function of the network in Fig. 4 can be realized as P’(u)P’(clu)P’(dlub, c)P’(ub).P’(ube)P’(flube, d) which has a form II?: P’( xlJX). Since the product of must equal to the product of all PT( , each be realized as the product of the evant erms with proper scalings. Each term, Pr(o), is scaled to be Z%(e)&; where n is the number of occur- rences of Z+(s) in the singly connected version of the network4. For example, P’(u) = Z+(u)? P’(ube) = Pr(elb)Pr(blu)~P~(u)~ P’(ub) = Pr(blu)*Pr(u)~ P’(clu) = Pr(clu) P’(dlub, c) = Pr(dlbc)Pr(u)~ P’(flube, d) = Pr(flde)Pr(blu)~Pr(u)* There are two important points about the treat- ment of multiply connected networks. First, the terms )s are not necessarily probability functions. Never- theless, the product of all P’(r)s yields the same values of the probability density function of the network. This property is similar to the concept of potential func- tion introduced in [Lauritzen & Spiegelhalter, 19881 for dealing with multiply connected networks through tri- angulation techniques [Kjaerulff, 19901. Second, if a P’(xly) is related to only one Pr(xJy) term, the or- dering of P’(xly), with respect to different instantia- tion of x and y, is the same as that of Pr(zl?~) even though Pr(xl~) is scaled. If a P’(e) is related to several ) terms, the influence of non-immediate parent or daughter nodes are brought to the scope in the case of compound-variable node such as P’(dlub, c) shown in Fig. 4. These two properties ensure the sufficiency of the information required for the message passing and the correctness of the belief computation. 6. Conclusion In this paper we have presented a message passing algorithm for the derivation of the first I most proba- ble explanations. If a network is singly connected, the first I most probable explanations can be found in or- der of O(kZn); where 1 is the number of most probable 4 The purpose of scaling R(o) is to reduce the prob- lem arising from the non-unique instantiations of vari- ables which share the same maximal BeZ value. SY 575 explanations to be derived, k the length of the longest path in a network, and n the maximum number of node states. We believe that this result is important in the domains such as diagnosis because previously we were able to only efficiently derive the first two (I = 2) most probable explanations. If a network is multiply-connected, the computa- tional complexity is generally NP-hard and there is no algorithm which could efficiently derive the I most probable explanations. In this paper we have intro- duced a technique based on the idea of clustering and cutset conditioning to obtain a singly connected ver- sion of a multiply connected network in which our mes- sage passing scheme can be applied to identify the 1 MPE. Although the computational complexity is still NP-hard, we argue that our message passing algorithm only deals with exponential complexity proportional to the maximum number of node states of the compound variables. Finally, we need to point out that an explanation is viewed as a composite hypothesis in this paper; where a composite hypothesis is defined as an instantiation of all non-evidence variables. Apparently an explana- tion can be viewed as an instantiation of any subset of non-evidence variables. This raises the issue of what it is meant by an explanation, which was discussed to some extent in [Peng & Reggia, 198’71. Unfortunately finding the I MPE of this kind would require the sum of those variables that are neither in the explanation nor in the evidence. This results in an exponential number of terms to be dealt with in such a summation. A chal- lenging problem, as a follow-up to this research, is the development of an efficient algorithm for finding the 1 MPE of this kind and the preliminary results can be found in [Sy, 1992b]. Acknowledgements This work is supported in part by the C.U.N.Y. PSC-CUNY Research Award Program, and a grant to Queens College from the General Research Branch, N.I.H. under grant No. RR-07064. I also thank the anonymous reviewers for their valuable comments. References [Andreassen S., Woldbye M., Falck B., and Andersen S., 19911 MUNIN - A C ausal Probabilistic Network for Interpretation of Electromyographic Findings, Proc. of the gth National Conf. on Artificial Intelligence, pp. 121-123, Menlo Park, California: AAAI. [Charniak E., and Goldman R., 19911 A Probabilis- tic Model of Plan Recognition, Proc. the gth National Conf. on Artificial Intelligence, pp. 160-165, Menlo Park, California: AAAI. [Cooper G., 19841 NESTOR: A Computer-Based Med- ical Diagnosis that Integrates Causal and Probabilis- tic Knowledge, Technical Report HPP-84-48, Stanford University, Stanford, CA. [Dean T., 19901 Coping with Uncertainty in a Control System for Navigation and Exploration, Proc. of the gth National Conf. on Artificial Intelligence, pp. lOlO- 1015, Boston, MA: AAAI. [Henrion M., 19901 T owards Efficient Probabilistic Di- agnosis in Multiply Connected Belief Networks, in R.M. Oliver and J.Q. Smith eds, Influence Diagrams, Belief Nets and Decision Analysis, pp. 385-409, John Wiley & Sons Ltd., New York. [Lauritzen S.L., Spiegelhalter D.J., 19881 “Local com- putations with Probabilities on Graphical Structures and their application to Expert System,” Journal of Royal Statistics Society - British, 50(2), 157-224. [Kjaerulff U., 19901 “Triangulation of Graphs - Algo- rithms Giving Small Total State Space,” Internal Tech. Report, R-90-09, University of Aalborg, Denmark. [Neapolitan R., 19901 Probabilistic Reasoning in Expert Systems,, John Wiley & Sons, New York. [Pearl J., 19861 “F usion, Propagation, and Structuring in Bayesian Networks,” Artificial Intelligence, Vol. 28, pp. 241-288. [Pearl J., 19881 Probabilistic reasoning in Intelligent Systems Morgan Kaufmann Publishers. [Peng Y. and Reggia J.A., 19871 A Probabilistic Causal Model for Diagnostic Problem Solving (Part I & II), IEEE Transactions on Systems, Man, and Cybernetics, Vol. 17, (No. 2 & 3). [Peot M., Shachter R.D., 19911 Fusion and Propagation with Multiple Observations in Belief Networks, Artifi- cial Intelligence, Vol. 48, pp. 299-318. [Santos E., 19911 On the G eneration of Alternative Ex- planations with Implications for Belief Revision, Proc. of the Conf. on Uncertainty in A.I., pp. 339-347. [Shimony S.E. and Charniak E., 19901 A New Algo- rithm for Finding MAP Assignments to Belief Net- works, Proceedings of the Conference on Uncertainty in Artificial Intelligence, Cambridge, MA, pp. 98-103. [Shwe M., Middleton B., Heckerman D., Henrion M., Horvitz E., and Lehmann H., 19911 Probabilistic Diag- nosis Using a Reformulation of the INTERNIST-l/ QMR Knowledge Base, Methods of Information in Medicine, 30:241-255. [Sy B.K., 1992a] A Recurrence Local Computation Ap- proach Towards Ordering Composite Beliefs, to appear in the International Journal of Approximate Reason- ing, North-Holland. [Sy B.K., 1992b] An Adaptive Reasoning Approach To- wards Efficient Ordering of Composite Hypotheses, submitted to the Annals of Mathematics and Artificial Intelligence. 576 Representation and Reasoning: Abduction and Diagnosis | 1992 | 99 |
1,297 | erimenta esults on over Point i ity James M. Crawford Larry D. Auton AT&T Bell Laboratories 600 Mountain Ave. Murray Hill, NJ 07974-0636 j&research.att.com, lda@research.att.com Abstract Determining whether a propositional theory is satisfiable is a prototypical example of an NP- complete problem. Further, a large number of problems that occur in knowledge representation, learning, planning, and other areas of AI are essen- tially satisfiability problems. This paper reports on a series of experiments to determine the loca- tion of the crossu2rer point - the point at which half the randomly generated propositional theo- ries with a given number of variables and given number of clauses are satisfiable - and to assess the relationship of the crossover point to the diffi- culty of determining satisfiability. We have found empirically that, for Q-SAT, the number of clauses at the crossover point is a linear function of the number of variables. This result is of theoretical interest since it is not clear why such a linear rela- tionship should exist, but it is also of practical in- terest since recent experiments [Mitchell et al. 92; Cheeseman et al. 911 indicate that the most com- putationally difficult problems tend to be found near the crossover point. We have also found that for random 3-SAT problems below the crossover point, the average time complexity of satisfiability problems seems empirically to grow linearly with problem size. At and above the crossover point the complexity seems to grow exponentially, but the rate of growth seems to be greatest near the crossover point. Introduction Many classes of problems in knowledge representation, learning, planning, and other areas of AI are known to be NP-complete in their most general form. The best known algorithms for such problems require expo- nential time (in the size of the problem) in the worst case. Most of these problems can be naturally viewed as constraint-satisfaction problems. Under this view, a problem defines a set of constraints that any solution must satisfy. Most known algorithms essentially search the space of possible solutions for one that satisfies the constraints. Consider a randomly-generated constraint- satisfaction problem. Intuitively, if there are very few constraints, it should be easy to find a solution (since there will generally be many solutions). Similarly, if there are very many constraints, an intelligent algo- rithm will generally be able to quickly close off most or all of the branches in the search tree. We thus in- tuitively expect the hardest problems to be those that are neither over- nor under-constrained. Cheeseman et al. have shown empirically that this is indeed the case [91]. Mitchell et al. take this argument further and show empirically that the most difficult problems occur in the region where there are enough constraints so that half of the randomly generated problems have a solution [92]. We refer to this point as the cfossouer point. The location of the crossover point is of both theoret- ical and practical importance. It is theoretically inter- esting since the number of constraints at the crossover point is an intrinsic property of the language used to express the constraints (and in particular is indepen- dent of the algorithm used to find solutions). Further, we have found that in the case of S-SAT the number of constraints required for crossover is a linear function of the number of variables. This leads one to expect there to be some theoretical method for explaining the location of the crossover point (though no satisfactory explanation has yet been proposed). The crossover point is of practical interest for several reasons. First, since empirically the hardest problems seem to be found near the crossover point, it makes sense to test candidate algorithms on these hard prob- lems. Similarly, if one encounters in practice a prob- Automated Reasoning 21 From: AAAI-93 Proceedings. Copyright © 1993, AAAI (www.aaai.org). All rights reserved. lem that is near the crossover point, one can expect it to be difficult and avoid it or plan to devote ex- tra computational resources to it. Furthermore, sev- eral algorithms have been proposed [Selman et al. 92; Minton et al. 901 that can often find solutions to constraint-satisfaction problems, but that cannot show a problem unsolvable (they simply give up after some set number of tries). Accurate knowledge about the location of the crossover point provides a method for partially testing such algorithms on larger problems - models should be found for around half of the randomly generated problems at the projected crossover point. Finally, as problem size increases, the transition from satisfiable to unsatisfiable becomes increasingly sharp (see Figures 3-6). This means that if one knows the lo- cation of the crossover point, then for random problem (i.e., problems with no regular structure) the number of clauses can be used as a predictor of satisfiability. In this paper we focus on the prototypical example of an NP-complete problem: Z-SAT - propositional satisfiability of clausal form theories with three vari- ables per clause. We first survey the algorithm used to carry out our experiments (readers primarily interested in the experimental results may skip this section). We then confirm and extend the results of Mitchell et al. [92] by showing that for up to 200 variables the hardest problems do tend to be found near the crossover point. We then show empirically that at the crossover point the number of clauses is a linear function of the num- ber of variables. Finally we show empirically that be- low the crossover point the complexity of determining satisfiability seems to grow linearly with the number of variables, but above the crossover point the complexity seems to grow exponentially. The exponential growth rate appears to be steepest near the crossover point. Propositional Satisfiability The propositional satisfiability problem is the following ([Garey & Johnson 791): Instance: A set of clauses’ C on a finite set U of variables. Question: Is there a truth assignment’ for U that satisfies all the clauses in C? We refer to a set of clauses as a clausal propositional theory. S-SAT is propositional satisfiability for theories in which all clauses have exactly three terms.3 Tableau Based Satisfiability Checking Our satisfiability checking program, TABLEAU, began life as an implementation of Smullyan’s tableau based inference algorithm [Smullyan, 681. TABLEAU has since ‘A clause is a disjunction of propositional variables or negated propositional variables. ‘A truth assignment is a mapping from U to (true, false). 3A term is a negated or non-negated variable. 22 Crawford evolved significantly and can most easily be presented as a variant of the Davis-Putnam procedure. The basic Davis-Putnam procedure is the following [Davis et al. 621: Find,Model(theory) unit -propagate (theory) ; if contradiction discovered returncfalse); else if all variables are valued returnctrue); else ( x = some unvalued variable; return(Find,Model(theory AND x) OR Find,Model(theory AND NOT x>>; Unit Propagation Unit propagation consists of the inference rule: X of the repeated application 12 v y1 . . . v yn Yl V - - . V Yn (similarly for lx). Complete unit propagation takes time linear in the size of the theory [Dowling & Gallier $41. In this sec- tion we sketch the data structures and algorithms used for efficient unit propagation in TABLEAU. We maintain two tables: the variable table and the clause table. In the variable table, we record the value of each variable (true, false, or unknown) and lists of the clauses in which the variable appears. In the clause table, we keep the text of each clause (i.e., a list of the terms in the clause), and a count of the to- tal number of unvalued variables (i. e., variables whose value is unknown) in the clause. Unit propagation then consists of the following: Whenever a variable’s value goes from unknown to true, decrement the unvalued variable count for all clauses (with non-zero counts) in which the variable appears negated, and set to zero the unvalued vari- able count for all clauses in which the variable ap- pears positively (this signifies that these clauses are now redundant and can be ignored). Variables going from unknown to false are treated similarly. Whenever the count for a clause reaches one, walk through the list of variables in the clause and value the one remaining unvalued variable. The actual implementation has several additional complications for efficiency. Details are given in [Craw- ford & Auton 93-J. Heurist its On each recursive call to Findi’Model one must choose a variable to branch on. We have observed that simple variable selection heuristics can make several orders of magnitude difference in the average size of the search tree. The first observation underlying the heuristics used in TABLEAU is that there is no need to branch on vari- ables which only occur in Horn clauses:4 Theorem 1 If a clausal propositional theory con- sists only of Horn clauses and unit propagation does not result in an explicit contradiction (i.e. z and lx for some variable z in the theory) then the theory is satisfiable. Satisfiability problems are often viewed as constraint-satisfaction problems in which the vari- ables must be given values from {true, false}, subject to the constraints imposed by the clauses. We take a different approach - we view each non-Horn clause as a “variable” that must take a “value” from among the literals in the clause. The Horn clauses are then viewed as the constraints. It turns out that one can ignore any negated variables in the non-Horn clauses (whenever any one of the non-negated variables is set to true the clause becomes redundant and whenever all but one of the non-negated variables are set to false the clause becomes Horn). Thus the number of “val- ues” a non-Horn clause can take on is effectively the number of non-negated variables in the clause. Our first variable-selection heuristic is to concen- trate on the non-Horn clauses with a minimal num- ber of non-negated variables. Basically this is just a most-constrained-first heuristic (since the non-Horn clauses with a small number of non-negated variables are viewed as “variables” that can take on a small num- ber of “values”). The first step of TABLEAU's variable- selection algorithm is thus to collect a list, V, of all variables that occur positively in a non-Horn clause with a minimal number of non-negated variables. The remainder of the variable selection heuristics are used to impose a priority order on the variables in V. Our first preference criterion is to prefer variables that would cause a large number of unit-propagations. We have found that it is not cost-effective to actually com- pute the number of unit-propagations. Instead we ap- proximate by counting the number of (non-redundant) binary clauses in which the variables appear.5 This heuristic is similar to one used by Zabih and McAllester In cases where several variables occur in the same number of binary clauses, we count the number of un- valued singleton neighbors. 6 We refer to two terms as neighbors if they occur together in some clause.7 A term is a singleton iff it only occurs in one clause in 4A clause is Horn ’ rff it contains no more than one posi- tive term. 5At this point we count appearances in non-Horn and Horn clauses since the intent is to approximate the total number of unit-propagations that would be caused by valu- ing the variables. ‘This heuristic was worked out jointly with Haym Hirsh. 7Recall that a te rm is a negated or non-negated variable. Thus x and 1~ are different terms but the same variable. the theory (this does not mean that the clause is of length one - if a theory contains x V y V z and the term x occurs nowhere else in the theory then x is a singleton). Singleton terms are important because if their clause becomes redundant, their variable will then occur with only one sign and so can be valued: Theorem 2 If a variable x always occurs negated in a clausal propositional theory Th, then Th is satisfiable iff Th A lx is satisfiable. A similar result holds for variables which only occur positively. In some cases there is still a tie after the applica- tion of both metrics. In these cases we count the total number of occurrences of the variables in the theory. Figure 1: Effects of the search heuristics. The data on each line is for the heuristic listed added to all the nrevious heuristics. Figure 1 shows the effects of the search heuristics on 1000 randomly generated S-SAT problems with 100 variables and 429 clauses .s Notice that counting the number of occurrences in binary clauses has quite a dramatic impact on the size of the search space. We have noticed that TABLEAU usually branches down some number of levels (depending on the problem size) and then finds a large number of unit-propagations that lead to a contradiction relatively quickly. This heuristic seems to work by decreasing the depth in the search tree at which this cascade occurs (thus greatly decreasing the number of nodes in the tree). Figure 2 shows a comparison of TABLEAU with Davis-Putnam on 50-150 variable S-SAT problems near the crossover point. ’ The experience of the community has been that the complexity of the Davis-Putnam al- gorithm on s-SAT /p roblems near the crossover point grows at about 2n 5 (where n is the number of vari- ables). Our experiments indicate that the complexity of TABLEAU grows at about 2”/17, thus allowing us to handle problems about three times as large. 8Some of the heuristics are more expensive to compute than others, but we will ignore these differences since they tend to become less significant on larger problems, and since even our most expensive heuristics are empirically only a factor of about three to four times as expensive to compute. ‘The Davis-Putnam data in this table is courtesy of David Mitchell. Automated Reasoning 23 Tableau: Variables Clauses Experiments Nodes Timea 50 218 1000 26 .02 100 430 1000 204 .47 150 635 1000 1532 3.50 Davis-Putnam: Variables Clauses Experiments Nodes 50 218 1000 341 100 430 1000 42,407 150 635 164 3.252.280 Figure 2: A Comparison of Davis-Putnam to TABLEAU on Q-SAT problems. aRun times are in seconds and are for the C version of TABLEAU running on a MIPS RC6280, R6000 uni-processor with 128MB ram. Probabilistic Analysis of Subsumption The original Davis-Putnam procedure included a test for subsumed clauses (e.g., if the theory includes 2 V y and x V y V z then the larger clause was deleted). We have found that this test does not seem to be useful near the crossover point. lo Consider a clause x V 9 V Z. If we derive lx, we then unit propagate and conclude yV Z. What is the chance that this new clause subsumes some other clause in the theory ? A simple probabilistic analysis shows that the expected number of subsumed clauses is 3c/2(v - 1) (where v is the number of variables, and c is the ratio of clauses to variables - empirically this is about 4.24 at the crossover point). The expected number of subsumptions is thus relatively small (.06 for v = 100 near the crossover point) and falls as the size of the problem increases. It seems likely that a similar, but more complex, analysis would show that the expected benefit from enforcing arc and path consistency on S-SAT problems near the crossover point also decreases with increasing problem size. Experiment 1: The Relationship Between Crossover and Problem Difficulty This experiment is intended to give a global view of the behavior of Q-SAT problems as the clause/variable ratio is changed. Experimental Method We varied the number of variables from 50 to 200, incrementing by 50. In each case we varied the clause/variable ratio from zero to ten, incrementing the number of clauses by 5 for 50 and 100 variables, by 15 for 150 variables, and by 20 for 200 variables. “We do, of course, do “unit subsumption” - if we gen- erate 2, we remove all clauses containing 2. Nodes (normalized) -0 5 clause/variable ratio Figure 3: Percent satisfiable and size of the search tree - 50 variables. At each setting we ran TABLEAU on 1000 randomly generated S-SAT problems.‘l Results The graphs for 50, 100, 150, and 200 variables are shown in Figures 3-6. In each case we show both the average number of nodes in the search tree and the percentage of the theories that were found to be satis- fiable. Discussion Our data corroborates the results of Mitchell et al. [92] - the most difficult problems tend to occur near the crossover point, and the steepness of both curves increases as the size of the problem is increased. Our data shows a small secondary peak in problem diffi- culty at about two clauses per variable. This peak does not seem to occur with the Davis-Putnam algo- rithm and is probably an artifact of ihe heuristics used to choose branch variables in TABLEAU. For Q-SAT theories with only three variables, one can analytically derive the expected percent satisfiable for a given clauses/variable ratio. The clauses in a theory with three variables can differ only in the placements of negations (since we require each clause to contain three distinct variables). A theory will thus be unsat- isfiable iff it contains each of the eight possible clauses (i.e., every possible combination of negations). If the theory cant ains n randomly chosen clauses, then the chance that it will be unsatisfiable is equivalent to the chance that picking n times from a bag of eight ob- jects (with replacement) results in getting at least one of each objects. The expected percent satisfiable as a function of the clauses/variables ratio is shown if Fig- l1In aJl our exp eriments we generated random theories using the method of Mitchell et al. [92] - we made sure that each clause contained three unique variables but did not check whether clauses were repeated in a theory. 24 Crawford Nodes (normalized) -0 5 clause/variable ratio 10 Figure 4: Percent satisfiable and size of the search tree Figure 5: Percent satisfiable and size of the search tree - 190 variables. - 150 variables. ure 7. Notice that the shape of this curve is similar to the experimentally derived curves in Figures 3-6. Experiment 2: The Location of the Crossover Point The aim of this experiment is to characterize as pre- cisely as possible the exact location of the crossover point and to determine how it varies with the size of the problem. Experimental Method We varied the number of variables from 20 to 260, incrementing by 20. In each case we collected data near where we expected to find the crossover point. We then focused on the data from five clauses below the crossover point to five clauses above the crossover point.12 For each data point we ran TABLEAU on lo4 randomly generated S-SAT problems (lo3 for 220 vari- ables and above). Results The results for 20, 100, 180, and 260 variables are shown in Figure 8. Each set of points shows the per- centage of theories that are satisfiable as a function of the clause/variable ratio. Notice that the relationship between the percent satisfiable and the clause/variable ratio is basically linear (this is only true, of course, for points very close to the crossover point). 12To determine whether a point is above or below the crossover point we rounded to one place beyond the deci- mal point - points at 50.0 were taken to be ot the crossover point. In most cases we found five points clearly above and five points clearly below the crossover point. The excep- tions were: 60 variables - 5 above, 1 at, 4 below, 100 vari- ables - 5 above, 1 at, 4 below, 140 variables - 5 above, 1 at, 4 below, 240 variables - 4 above, 1 at, 5 below, and 260 variables - 4 above, 1 at, and 5 below. Nodes (normalized) 5 clause/variable ratio We took the 50 percent point on each of these lines as our experimental value for the crossover point. The resulting points are shown in Figure 9. Discussion From the analytical analysis for 3 variables, one can show that the crossover point for 3 variables is at 19.65 clauses. If we add this data to the least-squares fit in Figure 9 we get: clauses = 4.24vars + 6.21 This equation is our best current estimate of the loca- tion of the crossover point. Experiment 3: T’ un Time of TABLEAU The goal of this experiment is to characterize the complexity of TABLEAU below, at, and above the crossover point. Experimental Method In these experiments we fixed the ratio of clauses to variables (at 1,2,3 and 10) and varied the number of variables from 100 to 1000 incrementing by 100. At each point we ran 1000 experiments and counted the number of nodes in the search tree.13 We also used the results from Experiment 2 to calculate the size of the search tree near the crossover point (thus each data point represents an average over lo5 runs for 20 to 200 variables, and over lo4 runs for 220 to 260 variables). Results The graphs for clause/variable ratios of 1,2, and 3 are shown in Figure 10. The results near the crossover point, and at 10 clauses/variable are shown in Figure 11. iscussion 13At 10 clauses/variable we currently only have data up to 600 variables. Automated Reasoning 25 .oo vars 260 180 vars 4.2 4.4 4.6 clause/variable ratio Figure 8: Percent satisfiable as a function of the number of clauses. 100 50 -0 Nodes (normalized) -0 5 10 clause/variable ratio Figure 6: Percent satisfiable and size of the search tree - 200 variables. Below the crossover point, the size of the search tree seems to grow roughly linearly with the number of vari- ables. This is consistent with the results of Broder et al. [93]. However, even in this range there are clearly some problems as hard as those at the crossover point (we observed such problems while trying to gather data beyond 1000 variables). Near the crossover point, the complexity of TABLEAU seems to be exponential in the number of variables. The growth rate from 20 to 260 variables is approximately 2”/17. Above the crossover point, the complexity appears to grow exponentially (this is consistent with the results of Chvatal and Sze- meredi [SS]), but the exponent is lower than at the crossover point. The growth rate from 100 to 600 vari- ables at 10 clauses/variable is approximately 2n/57. 100 50 -0 I I I I I -b ;; lb 115 2’0 clause/variable ratio Figure 7: Analytical results for the three variable case. Conclusion Our experimental results show that the hardest sat- isfiability problems seem to be those that are crit- ically constrained - i.e., those that are neither so under-constrained that they have many solutions nor so over-constrained that the search tree is small. This confirms past results [Cheeseman et al. 91; Mitchell et al. 921. For randomly-generated prob- lems, these critically-constrained problems seem to be found in a narrow band near the crossover point. Em- pirically, the number of clauses required for crossover seems to be a hear function of the number of vari- ables. Our best current estimate of this function is clauses = 4.24vars + 6.21. Finally, the complexity of our satisfiability algorithm seems to be on average 26 Crawford 50 loo 150 200 250 Variables Figure 9: The number of clauses required for crossover. 250 Branches 200 2 clauses/var I 500 Variables Figure 10: The size of the search tree below the crossover point. roughly linear on randomly generated problems below the crossover point (though even here there are some problems that are as hard as those at the crossover point). At the crossover point the complexity seems to be about 2n/17 (where n is the number of vari- ables). Above the crossover point we conjecture that the growth rate will be of form 2nlk where k is less than 17 and increases as one gets further from the crossover point. At 10 clauses/variable k seems to be approxi- mately 57. Acknowlledgments Many people participated in discussions of this ma- terial, but we would like to particularly thank Haym Hirsh, Bart Selman, Henry Kautz, David Mitchell, David Etherington, and the participants at the 1993 AAAI Spring Symposium on “AI and NP Hard Prob- lems” . References Broder, A., Frieze, A., and Upfal, E. (1993). On the Satisfiability and Maximum Satisfiability of Random 3-CNF Formulas. Fourth Annual ACM-SIAM Sympo- sium on Discrete Algorithms. Cheeseman, P., Kanefsky, B., and Taylor, W.M. (1991). Where the really hard problems are. IJCAI- 91, pp. 163-169. Chvbtal, V. and Szemeredi, E. (1988). Many Hard Examples for Resolution. JACM 35:4, pp. 759-768. Crawford, J.M. and Auton L.D. (1993). Pushing the edge of the satisfiability envelope. In preparation. Davis, M., Logemann, G., and Loveland, D. (1962). “A machine program for theorem proving”, CACM, 5, 1962, 394-397. Dowling, W.F. and Gallier, J.H. (1984). Linear-time algorithms for testing the satisfiability of proposi- tional Horn formulae. Journal of Logic Programming, 3, 267-284. Garey, M.R. and Johnson D.S. (1979). Computers and Intractability. W.H. Freeman and Co., New York. Minton, S., Johnson, M.D., Philips, A.B. and Laird, P. (1990). Solving 1 ar e scale g - constraint-satisfaction and scheduling problems using a heuristic repair method. AAAI-90, pp. 17-24. Mitchell, D., Selman, B., and Levesque, H. (1992). Hard and easy distributions of SAT problems. AAAI- 92, pp. 459-465. Selman, B., Levesque, H., and Mitchell, D. (1992). A new method for solving hard satisfiability problems. AAAI-92, pp. 440-446. Smullyan, R. M. (1968) First Order Logic. Springer- Verlag New York Inc. Zabih, R.D. and McAllester, D.A. (1988). A re- arrangement search strategy for determining propo- sitional satisfiability. AAAI-88, pp. 155-160. 100000 Branches i near cross-over 10000 1000 100 10 clauses/variable I I -0 200 400 600 Variables Figure 11: The size of the search tree at and above the crossover point (log scale). Automated Reasoning 27 | 1993 | 1 |
1,298 | Representing and using cedural knowledge Thomas F. McDougal Department of Computer Science University of Chicago 1100 E. 58th St. Chicago, IL 60637 mcdougal@cs.uchicago.edu, hammond@cs.uchicago.edu Abstract What is the nature of expertise? This paper posits an answer to that question in the domain of geometry problem-solving. We present a computer program called POLYA which makes use of explicit planning knowledge to solve geometry proof problems, integrating the processes of parsing the diagram and writing the proof. Introduction This paper describes a computer program called POLYA that solves high school geometry proof problems. High school geometry first attracted our interest when the first author was student teaching geometry in a public high school as part of a teacher certification program. We were curious about what kinds of knowledge enabled him and other experienced mathematicians to solve geometry proof problems very quickly, in contrast to his students, who solved the same problems only with great effort. That knowledge had to involve more than the formal rules of geometry (the theorems, axioms, definitions), since, by virtue of their ability to solve the problems at all, the students clearly knew those rules. We conjectured that geometry expertise involves an ability to recognize when those rules should be used, in contrast to when the rules can be used. Such expertise generally arises from exposure to and experience with a large number of problems. The problem for us then was to define that knowledge concretely and to build a computer model of geometry problem-solving that made use of that knowledge. We call our computer program POLYA. Although POLYA’s task is to write geometry proofs, our desire to model human expertise led us away from some of the traditional concerns of automated theorem-proving. We are not concerned, for instance, with solving hard lThis research is supported by the Office of Naval Research under contract N00014-9 1 -J- 1185, by the Defense Advanced Research Projects Agency monitored by the Air Force Office of Scientific Research under contract F30602-91-C-0028, and by the University of Chicago School Mathematics Project Fund for Support of Research in Math Education. 60 McDougal problems; rather, we are concerned with capturing the knowledge that allows experts to solve easy problems easily. Our research has led us to address a broad range of important AI issues: visual reasoning and the use of diagrams in problem-solvin g; representation of planning and problem-solving knowledge; how to store, efficiently retrieve, and apply plans; how to integrate planning and action; how to use the world as a memory aid; how to direct a limited focus of attention to gather information; and what it means to know how to solve a problem as distinct from knowing the solution. This paper describes our representation for geometry problem-solving knowledge and the computer program, POLYA, which uses that knowledge to write proofs. Recognizing when rules shoul Central to our model of human geometry theorem-proving expertise is a distinction between when a rule may be applied (as determined by its preconditions) and when a rule should be applied. A novice with complete understanding of the rules and their preconditions can still have trouble with a relatively easy problem. The novice may get lost in a large number of legitimate but useless inferences, or she may be reluctant to make a single inference without knowing how it will contribute to the final proof. The expert, on the other hand, shows a remarkable ability to make exactly those inferences relevant to the solution without knowing a priori what that solution is. [Koedinger & Anderson 19901 documents the tendency of geometry experts to make inferences from the given information without regard to the goal; [Lax-kin et al. 19801 documents analogous forward reasoning by physics experts. We hold that most of the expert’s decision-making is based on cues in the diagram. This thesis, so broadly stated, is not new; [Koedinger & Anderson 19901 presented a model of geometry problem-solving called DC in which the diagram is parsed into configuration schema, each of which defines a restricted subset of applicable rules. Their model contrasts with earlier systems [Gelernter 1959, Nevins 1975, Green0 19831 which used the diagram primarily as a source of heuristic search control information. From: AAAI-93 Proceedings. Copyright © 1993, AAAI (www.aaai.org). All rights reserved. We believe that our model addresses two shortcomings in the DC model. First, while the DC model makes a significant contribution in terms of knowledge representation for geometry problem-solving, it still says very little about the problem-solving process. The authors note that once the diagram has been parsed, finding the inference chain is trivial, which suggests that most, if not all, of the problem-solving task involves recognizing the relevant schema. Yet they consciously side-step the question of how people do this, with only a brief argument that perhaps the diagram parsing and schema search processes could be coordinated. We also disagree with DC’s model of schema application. Although DC’s configuration schema significantly reduce the rule space, the model still falls back on inference chaining to decide, for each schema, which rule or rules should apply. The problem is that DC’s schemas are overly general. Just as human experts are able to commit to specific inferences early in the problem- solving process, more specific schema would make it possible to decide exactly which rule should apply without a second phase of inference chaining. Figure 2: a triangle which appears isosceles. Angles 1 and 2 are the base angles. Angles 3 and 4 are marked congruent, as are two pairs of segments. This represents the initial conditions for one problem POLYA can solve. The input In contrast, POLYA builds up the proof at the same time that it builds up its understanding of the diagram. It uses schema-like knowledge to parse the diagram on demand, and it recognizes highly specific configurations in the diagram which enable it to make concrete inferences likely to contribute to the final proof. The next sections provide an overview of POLYA’s operation and a detailed description of its geometry problem-solving knowledge. As in textbooks, a geometry proof problem for POLYA consists of givens, a goal, and a diagram. The givens and goal are predicates such as (congruent-segments (segment s x) (segment t y)). The diagram is a composite of lines and labelled points. Each line is defined by the coordinates of its endpoints, and labelled points are listed by their coordinate locations, as: (x y <label>), where <label> is a letter (A, B, etc.). The labels are irrelevant to the problem- solving process; they are used only to define the givens and the goal and to generate the proof in human-readable form. An overview of POLYA Simulated vision POLYA comprises three basic modules: a memory retriever, a plan interpreter, and a module for simulated vision (figure 1). The memory retriever takes a steady stream of features and uses them to trigger plans in memory. The plan interpreter selects a plan and executes the steps in the plan. The vision module computes features in response to the actions called for by the plan. The next sections discuss these modules in detail. POLYA accesses the diagram by way of a simulated visual system. The visual system provides over 120 operators by which POLYA can specify which object or objects in the diagram it wishes to inspect; the visual system returns a description of that object including its exact location and a list of aspects. The operator L 0 0 K-AT-LEFT-BASE-ANGLE, for example, takes as its argument the vertices of a triangle which appears isosceles* and returns a description of one of its base angles (e.g. angle 1 in figure 2). That description includes the (x, y) location of the vertex, the compass directions of the rays, a symbolic description of the approximate size of the angle (e.g. ACUTE>45), a symbolic description of the pattern of rays at the vertex (SIMPLE-ANGLE), a count of the number of rays interior to the angle (zero), and, if there are no interior rays, a description of the space unto which the angle opens (TRIANGLE). The description also includes whether the angle is marked (e.g. angles 3 and 4 in figure 2 are each marked with SINGLE-ARC congruency marks). POLYA can itself make annotations such as angle marks on the diagram. There are several benefits from such annotations. Looking at angles 3 and 4, it Plan memory Simulated vision Text & reter diagram actions & predictions Ggure 1: POLYA’s three modules. The plan interpreter sends commands to the vision module, which computes a description of some part of the problem and sends that description both to the memory module and back to the plan interpreter. *Based on euclidean distances between the vertices. Case-Based Reasoning 61 Figure 3: POLYA can look at Zs to see if the angles are congruent or the lines parallel. is apparent from the marks that the angles are congruent to each other. Thus POLYA, like a person, need not remember which angles are congruent, since it can always oet that information directly from the diagram. Furthermore, having a mark associated with an individual angle streamlines some inferencing. Looking at angles 3 and 5, POLYA can guess that angle 5 is probably congruent to some other angle (angle 6). In addition to angles, POLYA can focus on and describe any of the visual objects involved in geometry proofs: points, segments, triangles, quadrilaterals. It can compare pairs of objects-two triangles, for example, or a segment and an angle-to see how they relate to each other spatially. When POLYA looks at a triangle, the visual system computes its shape (RIGHT, ISOSCELES, EQUILATERAL) and counts the number of sides and angles annotated with congruency marks. Thus marks on segments and angles are reflected in the descriptions of all larger objects which contain those segments or angles. So, for example, POLYA can recognize when all sides of a triangle are marked, suggesting the applicability of the side-side-side triangle congruency theorem. This is the other benefit of angle and segment annotations. POLYA can also look at composite shapes sometimes mentioned in textbooks but never mentioned in proofs. One textbook, for example, explicitly teaches students Z and F patterns involving parallel lines cut by a transversal [Rhoad, Whipple & Milauskas 19881. POLYA can look at Zs to see if the angles are marked congruent or if the lines are marked parallel (figure 3). Operators can sometimes fail. FIND-ADJACENT- MARKED-ANGLE, for instance, can fail if no such angle exists. Such operators are nonetheless useful for efficiently locating objects of interest. Geometry plans To parse the diagram and write a proof concurrently, POLYA needs to gather information in an organized way while still responding flexibly to what it sees. POLYA has a large memory of geometry plans which structure visual search and instantiate rules; plans are triggered and executed on the basis of configurations in the diagram. A geometry plan defines a sequence of actions which can be directly executed by the plan interpreter. A typical action looks like this: ((COMPARE-TRIANGLES ?tril ?tri2) :predict (tri-pair (extents shared-side)) : unbind (?tril ?tri2) :bind ?tri-pair) Figure 4: Two triangles share a side, and each triangle has one side marked and one angle marked. This pattern triggers the P-SAS-SHARED-SIDE proof plan, which checks that the marked angle is between the marked side and the shared side. isosceles. The first item is an action for the visual system whose arguments are defined by local plan variables. The prediction partially specifies what the result of that action should look like; if the result fails to match the prediction, the plan aborts. A typical use of predictions is to check preconditions of a rule. Each step may bind the result of the action to a local plan variable and may unbind variables no longer needed. There are two types of plans: search plans and proof plans. Search plans direct the focus of attention to potentially relevant parts of the diagram, gathering information for the memory module. Proof plans instantiate formal rules of geometry and add them to the proof. Search and proof plans are structured and handled in the same way, except that POLYA runs proof plans preferentially. (See plan selection, below.) S-ISOSCELES3 is a typical search plan. It directs attention to the legs and base angles of a triangle which looks isosceles. This reflects knowledge that if the triangle is actually isosceles, the legs and base angles are more likely to provide useful information, and more likely to play a role in the proof, than the apex angle or the base side. P-SAS-SHARED-SIDE3 is a typical proof plan: if POLYA detects two triangles each of which has one angle marked and one side marked such that the triangles also share a side (figure 4), the plan verifies that the angle between the marked side and the shared side is marked, then adds to the proof a statement that the triangles are congruent. Search plans gather features which trigger proof plans and other search plans in an interacting cycle of plan selection and execution. To build a proof for an easy-to- moderate geometry problem, POLYA may make use of 12 to 28 plans, causing between 50 to 120 actions to be performed. POLYA’s geometry plans define what it means to know how to solve geometry problems. Once a plan has been triggered, execution is straightforward. This is consistent with our view of geometry problem-solving as being primarily a task of recognizing when a rule or other piece 3By convention, we use prefixes S- and P- to distinguish search and proof plans. 62 McDougal of knowledge should apply. Next we consider how POLYA recognizes which plans are relevant. Plan memory and retrieval We have said that plan execution generates visual results which in turn trigger other plans. In this section we describe specifically how plans are triggered. POLYA’s plan indexing scheme is based on the marker- passing scheme used in DMAP, a case-based natural language understanding system [Martin 19901. Each plan has a plan index havin g two parts: an index pattern and index constraints. An index pattern consists of a sequence of partially-specified visual results. A typical index pattern looks like this one for the P-SAS-SHARED-SIDE proof plan: ( (triangle (angle-mark-count 1) (seg-mark-count 1)) (tri-pair (extents shared-side)) ) This pattern detects a triangle with one marked side and one marked angle, and a triangle pair sharing a side. The index constraints specify that the triangle must be part of the triangle pair: ( ((?l) = (?2 triangle-l)) ) The memory module matches visual results against the index pattern using DMAP’s marker-passing scheme. A marker is placed on a node representing the first element of the pattern. When a visual result matches that node, the marker is advanced to the next element in the pattern. When the last element has been matched, the plan is triggered, posted to a list as eligible for execution. We wish to emphasize that a plan index should not be thought of as the antecedent of a rule. Relative to most rules, plan indices are both over- and under-specified: over- specified in the sense that they seek to recognize not only when a rule may be applied but when it shoulrl be applied; under-specified in that they do not always guarantee the applicability of the rule. In the case of the P-SAS-SHARED- SIDE proof plan, for instance, the marked angle must lie between the marked side and the shared side in each triangle, a constraint which is not easily captured by the raw descriptions of the triangle and the triangle pair. It would be possible to design the visual system to capture that information as one aspect of the triangle pair. That would subsume an important part of geometry knowledge in the vision module. We prefer, however, to represent explicitly as much geometry knowledge as possible in the plans. As stated earlier, an important part of geometry er pertise is the ability to make the inferences which are mosi likely to contribute to the final solution. POLYA makes an assumption which seems to work well for easy to medium problems: If some features in the diagram cause a search plan to focus attention on an object, then the object is likely to be relevant to the proof. For the P-SAS-SHARED-SIDE proof plan to be tri ggered, some other script must have directed POLYA’s attention to the triangles. This does not Ouarantee that it will be useful to prove the triangles D congruent, but it seems to be true most of the time. Plan selection When the plan interpreter module finishes a plan, POLYA chooses another from the list of triggered plans. Typically there are several search plans to choose from, and perhaps one proof plan. Proof plans are chosen ahead of search plans, since after all the task is to write a proof; and plans triggered more recently are chosen ahead of plans triggered less recently. This plan-selection algorithm is too simple to work in the long run, and we are experimenting with ways to incorporate knowledge about which plans should run first. In some cases one plan subsumes another; by annotating the larger plan we can ensure that POLYA runs it and not the other. Issues One of our objectives with POLYA was to integrate diagram parsing with the process of constructing a proof. In so doing, we have had to address issues associated more with planning, robotics, and vision than with traditional theorem-proving. laming and action POLYA treats planning as memory retrieval, in the spirit of case-based planning [Hammond 19891. Because feature extraction is a major part of POLYA’s task, POLYA cannot solve problems by retrieving and adapting a single case, as a prototypical CBR system does. Instead, POLYA accesses memory constantly, retrieving and using tens of plans over the course of a single problem. POLYA plans and re-plans in response to what it sees. This responsiveness to visual features is characteristic of situated activity [Chapman & Agre 1986, Agre 19881. Yet POLYA is not purely reactive; its behavior is better characterized as reactive planning [Firby 19891. It executes each plan to completion so long as its predictions are met. The plans provide necessary structure for apprehending complex relationships in the diagram and for writing a formal mathematical argument. POLYA strikes a balance between top-down memory-based planning and bottom-up reactivity. Active sensing In the computer vision community, researchers are acknowledging that it is both intractable and unnecessary to identify everything in an image [e.g. Ballard 1991, Clark & Ferrier 1988, Swain 19911. Particular tasks require attention to only particular aspects of the image. One may be interested only in the object at the center of the image, or one may be concerned only with detecting rapid motion. Similarly, a robot may have a ring of sonars, but for moving forward across mostly-empty space it makes sense to ignore the sonars pointing aft. Geometry diagrams are simpler and more constrained than an arbitrary image or a cluttered room, but the idea for POLYA is the same: different parts of the diagram are Case-Based Reasoning 63 relevant for different tasks, and some parts of the diagram can be ignored altogether. Furthermore, we suspect that POLYA’s problem of coordinating multiple sensing operations is relevant to vision and robotics as well, and that the solution of using short plans for information-gathering, with top-down predictions, may apply. Example Figure 2 above is one example of a problem POLYA can solve. Here we show the diagram with all given infor- mation already marked on the diagram; one of the first things POLYA does is annotate the diagram to reflect the given information. The goal in this problem is to prove that the large triangle is isosceles, i.e. that its left and right sides are congruent (have equal lengths). At startup, POLYA computes a general description of the diagram as a whole, capturing the left/right symmetry of the diagram and the basic shape: a triangle with corner triangles. Two search plans are immediately triggered based on this description: S-ISOSCELES, described above, and S-CORNER-TRIANGLES. After marking the given information, POLYA executes the S-CORNER-TRIANGLES search plan, which focuses attention on the corner triangles. The descriptions of those triangles triggers S-SIDE+SIDE, which looks at angles 5 & 6 and at sides WX and YZ. The pattern of rays at the vertex of angle 5 triggers S-PIER, which compares angle 5 with its adjacent angle, angle 3. Because angle 3 is marked, plan P-LINEAR-PAIR-PAIR is triggered, which proves that angles 5 and 6 are congruent. Shortly thereafter, POLYA proves the corner triangles congruent using P-SAS-SIMPLE, which instantiates the side-angle-side theorem. At this point POLYA makes the equivalent of a leap of reasoning. A very specialized plan, P-CORNER- TRIANGLES->ISOSCELES, is triggered by the combination of the shape of the diagram (isosceles with comer triangles) and the assertion that the triangles are congruent.4 Though POLYA has not yet read the goal statement, this plan represents the knowledge one might have from having seen this problem before: the large triangle is almost certainly isosceles, and, furthermore, that is probably a key conclusion (though not necessarily the goal) in this problem. The plan steps through the argument, adding inferences to the proof: because the corner triangles are congruent, the corner angles are congruent (1 and 2), and therefore the sides of the large triangle are congruent. Finally, POLYA reads the goal, discovering that the proof is complete. Discussion Theorem-proving is usually done from scratch, using a minimalist representation of the problem and the rules. In 41nferences are passed to memory in the same way visual descriptions are, and can be used for indexing. that light of that tradition, what POLYA does in the problem above might seem like cheating. In the foregoing example, POLYA makes use of two very specialized plans: S-CORNER-TRIANGLES and P- CORNER-TRIANGLES->ISOSCELES. If we remove the P- CORNER-TRIANGLES->ISOSCELES proof plan from memory, POLYA is still able to solve the problem, though it takes longer. (It cannot solve it without S-CORNER- TRIANGLES.) But to remove that plan would be contrary to the main point of this research. The point is not to build a system which knows very little but can solve problems by working very hard. That has been done many times before. The point is to build a system which knows a lot and which can solve problems easily. The point is to model what an expert knows, including his memory of problems he has solved before. This is what POLYA’s plans represent. Conclusion At current writing, POLYA has 68 search and proof plans. These plans constitute POLYA’s knowledge about how to solve geometry proof problems, covering roughly one-fifth of the simple triangle congruence problems in a textbook and a very few examples involving parallel lines. Expanding POLYA’s knowledge to cover quadrilaterals, other parallel line examples, and other aspects of geometry will at least double or treble the number of plans. Rapid growth of plan memory is not a bad thing, provided that we can continue to index the plans efficiently. While many of POLYA’s plans correspond fairly directly to general rules, some of POLYA’s plans relate to specific problems in much the same way that a person might remember a specific problem. We believe that it is both necessary and appropriate that geometry expertise comprise knowledge at many levels of generality. When POLYA has a specific plan for a particular problem, fewer plans are needed and fewer actions are performed in solving that problem. Thus it is the case with POLYA, as with an expert, that the more knowledge it has, the more easily it can solve problems. References Agre, P.E. 1988. The Dynamic Structure of Everyday Life. Ph.D. diss., Artificial Intelligence Laboratory, MIT. Ballard, D. H. 1991. Animate vision. Artificial intelligence 48. Chapman, D., and Agre, P.E. 1986. Abstract reasoning as emergent from concrete activity. In Reasoning about Actions and Plans, Proceedings of the 1986 Workshop, Timberline, Oregon, Georgeff, M.P., Lansky, A.L., eds. Los Altos, CA.: Morgan-Kaufmann. Clark, J. J. & Ferrier, N. J. 1988. Modal control of an attentive vision system. In Proceedings of the International Conference on Computer Vision. Firby, R.J. 1989. Adaptive execution in complex dynamic worlds. Ph.D. diss., Yale University. 64 McDougal Gelernter, H. 1959. Realization of a geometry theorem proving machine. In The Proceedings of the International Conference on Information Processing, UNESCO, Reprinted in E.A. Feigenbaum & J. Feldman, (Eds.) (1963), Computers and thought. McGraw-Hill. Greeno, J.G. 1983. Forms of understanding in mathematical problem solving. In Paris, S.G., Olson, G.M., and Stevenson, H.W., 1983. Learning and Motivation in the Classroom. Erlbaum. Hammond, K. 1989. Case-Based Planning: Viewing Planning as a Memory Task. Academic Press, San Diego, CA , Vol. 1, Perspectives in Artificial Intelligence. Koedinger, K.R. and Anderson, J.R. 1990. Abstract planning and perceptual chunks: Elements of expertise in geometry. Cognitive Science 14:5 1 l-550. Larkin, J.H., McDermot, J., Simon, D.P., and Simon, H.A. 1980. Models of competence in solving physics problems. Cognitive Science 4~3 17-348. Martin, C.E. 1990. Direct Memory Access Parsing. Ph.D. diss., Yale University. Nevins, A.J. 1975. Plane geometry theorem proving using forward chaining. Artificial Intelligence 6. Rhoad, R., Whipple, R., and Milauskas, G. 1988. Geometry for enjoyment and challenge. McDougal, Littell. Swain, M. J. 1991. Low resolution cues for guiding saccadic eye movements. SPIE advances in intelligent robot systems. Case-Based Reasoning 65 | 1993 | 10 |
1,299 | Towards owledge-Level Analysis 0 otion Plannin Ronen I. Brafman Jean-Claude Latombe Yoav Shoham Robotics Laboratory Stanford University Stanford, CA 94305 e-mail: {brafman,latombe,shoham}@cs.stanford.edu Abstract Inspired by the success of the distributed com- puting community in applying logics of knowledge and time to reasoning about distributed protocols, we aim for a similarly powerful and high-level ab- straction when reasoning about control problems involving uncertainty. Here we concentrate on robot motion planning, with uncertainty in both control and sensing. This problem has already been well studied within the robotics community. Our contributions include the following: e We define a new, natural problem in this do- main: obtaining a sound and complete termina- tion condition, given initial and goal locations. o We consider a specific class of (simple) motion plans in Rn from the literature, and provide nec- essary and sufficient conditions for the existence of sound and complete termination conditions for plans in that class. l We define a high-level language, a logic of time and knowledge, to reason about motion plans in the presence of uncertainty, and use them to pro- vide general conditions for the existence of sound and complete termination conditions for a broader class of motion plans. Introduction Much research carried on in computer science in gen- eral, and AI in particular, concerns the development of powerful abstractions, and their application to prob- lems of interest. In the context of this article, of par- ticular note is the application of logics of knowledge in distributed computing (e.g., [Halpern and Moses, 19901). The essential insight behind that line of re- search was that a formal notion of “knowing,” devel- oped initially in philosophy [Hintikka, 19621 and later *The work of the first and third author is supported by DARPA grant USC 598240 (DARPA DABT63-91-C0025) and AFOSR grant #F49620-92-J-0547. The work of the second author is supported by DARPA grant N00014-92-J- 1809. 670 Brafman imported to AI [Moore, 19851, can be coherently and usefully applied to reasoning about (and later also de- signing) distributed protocols. The reasons for the suc- cess of this approach include: Intuitiveness: The high-level language supported statements of the sort “processor A doesn’t know that processor B is faulty,” which are precisely the type employed informally by people reasoning about the do- main. Groundedness: The formal notion of knowledge was anything but vague; it was defined precisely in terms of the underlying protocol. Abstraction and Generality: In principle, the notion of knowledge was dispensable. However, the analysis in terms of knowledge homed in on the essential notion, the knowledge available to the various processors at dif- ferent points in time, and allowed one to abstract away from the details of how the particular physical proto- col implemented that knowledge. This knowledge-level abstraction made it possible to analyze (and later also design) protocols even before their physical implemen- tation was specified; in fact, the same knowledge-level protocol could be implemented differently, without af- fecting the high-level analysis. While logics of knowledge have been widely used in AI (e.g., to model human-computer interaction, distributed planning, and nonmonotonic logics), they have so far not been applied in a similar fashion, as a knowledge level corresponding to some specific concrete system. Two exceptions do come to mind - Levesque’s knowledge-level analysis of databases [Levesque, 19841, and Rosenschein and Kaelbling’s Sit- uated Automata [Rosenschein, 1985, Kaelbling and Rosenschein, 19901. We claim, however, that there is a much wider arena in which the lessons from distributed computing can be applied, namely planning and con- trol in the presence of uncertainty. In this article we take one step towards exploring this arena, concentrat- ing on robot motion planning. Robot motion planning with uncertainty is a well re- searched area [Canny, 1989, Erdmann, 1986, Latombe, 1991, Latombe et al., 19911. The uncertainty in that domain can arise from several sources, including par- From: AAAI-93 Proceedings. Copyright © 1993, AAAI (www.aaai.org). All rights reserved. tial information about the location of various objects, sloppy control, and noisy sensing. We argue that this domain exhibits all the ‘right’ properties: (1) One nat- urally analyzes the situation by saying that “the robot knows that it is at the goal, since it knows that the cur- rent reading could only have been obtained if it were either at the goal or beyond the wall, and it knows its motion plan could not possibly have taken it be- hind the wall” ; (2) the notion of knowledge can be grounded precisely in the motion plan of the robot, as well as some additional parameters such as the slop in control and the noise in sensing. It would have been convenient to start with a given class of motion planning problems, and delve directly into their knowledge-level analysis However, we were surprised to find that, although much related research has been conducted in robotics, the simple question ure would like to pursue has not been addressed. A typical question asked in robotics is “Given that the robot must end up in a particular region, and given bounds on the slop in control and noise in sensing, what is the biggest initial area from which the robot can start, and still be guaranteed to arrive at the goal and recognize that it is at the goal?” This initial area is called the pre-image of the goal. In a multi-step motion plan, this question is repeated in a backward- chaining fashion, leading to the method of pre-image buckchaining [Lozano-Perez et ad., 19841. In contrast, we consider fixed initial and goal regions and a class of simple motion commands ‘Go in direction D, until the termination condition, T, is satisfied’. D can be seen as responsible for reaching the goal, while T is responsible for recognizing it. The seemingly more basic question we ask is: “Given a fixed D, and given bounds on the slop in control and noise in sensing of the robot, does there exist a good definition of T?” Of course, one could interpret good in many ways. We will interpret it by appealing to standard computer-scientific notions; we will be interested in termination conditions that are sound and complete, that is, ones that guarantee that if the robot stops, it only stops at the goal, and that it does eventually stop. Before introducing a high-level language, we will give more feel for the problem by considering it in the con- text of a particular class of motion plans in R”; we will present some results on necessary and sufficient conditions for the existence of sound and complete ter- mination conditions in that class. We will then con- sider general motion planning, define a (fairly stan- dard) logic of knowledge and time for reasoning about them, and then, for a broad class of motion planning problems in R”, provide a knowledge-level characteri- zation of the conditions in which sound and complete termination conditions exist. Our proofs, contained in a longer version of this paper ([Brafman et al., 1993]), are constructive, that is, when such termination condi- tions exist, the proofs yield ways of computing them. Figure 1: An example domain We conclude the introduction with a simple path- planning problem in R1, taken from [Latombe, 19911. We will use it later to illustrate the various definitions and results, along with more realistic examples, to the extent that space allows. Example 1 Assume that our robot is a point mov- ing forward along the positive reals, starting at 0; it moves continuously at finite velocity, until the termi- nation condition is satisfied, at which point it stops. The goal is the interval [2,4]. There is a position sens- ing uncertainty of 1, so that if the robot is at locution 1, its sensor may indicate any value between l- 1 and 1-I-l. In the following let r denote the current position reading of the robot. Clearly ‘r > 1 ’ is a complete termination condition, but not a sound one. Simi- larly, ‘r = 3’ is a sound termination condition, but not a complete one (readings need not be continuous: we may have a sequence of readings that are accurate until we reach 2.5, at which point they might become consistently 08 by +l, i.e., start from 3.5 and grow). Somewhat surprisingly, there exists a termination con- dition that is both sound and complete, e.g., ‘r E [3,5] ‘. rmination Conditions in Motion Planning We introduce a motion planning domain, with partic- ular types of sensing and control uncertainty, in which we investigate the existence of sound and complete ter- mination conditions. The problem Our robot starts its motion from a designated set of lo- cations (possibly a singleton), I, within the workspace W c R”. It proceeds along its commanded direction, D, attempting to reach and stop at the goal, G, a compact subset of W ( see Figure 1). However, control uncertainty may cause the tangent of the path to devi- ate by up to AD from this direction. This constrains Representation for Actions & Motion 671 I Goal boundary &) n Boundary of the naive termination condition / \ Cone of possible positions \/ \ Figure 2: A naive termination condition the robot to remain within a cone of possible positions defined by the initial state, by D and by AD. At each position, q, the robot’s sensors supply a position read- ing, r; but while the robot’s motion is continuous, the position readings may not be continuous. The reading, r, must be within a disk of radius p, AR(q), centered at 4. Consequently, given a position reading, r, the actual position, Q, is also within a disk of radius p, AQ(r), centered in r, defining the sensing uncertainty. If a subset of this disk is outside the cone of possible po- sitions, it can be eliminated as candidates for the ac- tual position. We use the term motion planning in- stance to refer to the domain specified by AD, p, I, and G. The termination condition, T, is a (total) boolean function on the set of possible readings. The first time it evaluates to true the robot stops. An annotated trajectory describes a possible execu- tion of a motion command. Definition 1 Given a motion planning instance and a motion command M=(D, T), r=(Q, V) is a consistent annotated trajectory, where Q is a continuous func- tion from [O,oo) to W (d escribing the path), and V is a (not necessarily continuous) function from [0, co) to R (describing the readings), if the the following properties are satisfied: * Q(O)e I; * v’s E lb4 : IV(s) - Q(s)1 I Pi o b’s E [O,oo) : IdQ(s) - Dl 5 AD, where dQ(s) is the direction of the tangent to Q at s; o t( 5 [G(y) : if T(V(s)) is true, then vs’ > s s= s. Definition 2 Given a motion planning instance and a motion direction, a termination condition T is sound if for every consistent trajectory r =(Q, V): for s = inf (s E [0, 00): T(V(s)) is true) it is the case that - / A separating cutset ’ \ Figure 3: cutsets Q(g) EG. It is complete if every consistent trajectory r =(Q, V) satisfies 3 s E [O,CQ) such that T(V(s)) is true. That is, if the termination condition is complete the robot eventually stops, and if it is sound, if the robot stops, it stops in the goal. A precise formulation of the problem we wish to investigate, is: Given a motion planning instance and a motion direction D, does there exist a sound and complete termination condition? The naive termination con&t ion Let the forward projection of I, 3(I), be the set of positions that can be reached from I by a path consistent with D and AD. The termination condi- tion ‘AQ(r) n F(I) c G’ can only be true at positions within the goal or at positions that cannot be reached from I. Hence it is sound. We call it the naive termi- nation condition. The naive termination condition in Example 1 is ‘r = 3’. Example 2 In Figure 2 we see an example of a naive termination condition, bounded by the dashed line. The positions from which the reading r-1 can be obtained are contained in the disk AQ(r1). Some of them, those in the shaded area, are not in the goal. Thus, a reading of r-1 may be obtained from outside the goal, and r1 is not within the naive termination condition. r2 is in the naive termination condition, although part of the positions from which we can obtain a reading of r2 are outside the goal. These positions are outside 3(I), and cannot be reached by any consistent motion. The naive termination condition is not complete. In Example 2, because the distance between the points A’ and B’ is less than 2p, a consistent annotated tra- jectory, in which the termination condition never eval- uates to true exists. 672 Brafman conditions for existence of a sound and complete termination condition We now derive a number of conditions for the exis- tence of a sound and complete termination condition in domains containing no obstacles, in which the initial states are in a single connected component. Definition 3 A motion cutset (w.r.t. a motion di- ,rection) is a set of positions, at least one of which must be traversed by every consistent trajectory, assuming the termination condition T E false. A separating cutset is a motion cutset cs such that F(I)\cs consists of two disjoint connected components, one of which includes the set of possible initial states. Figure 3 offers an separating cutsets. example of separating and non- Theorem 1 A suficient condition for the existence of a sound and complete termination condition is that the naive termination condition contains a separating cutset. We have a constructive proof of this theorem, which due to length limitations we must omit. The construc- tion relies on the fact that we can disregard positions consistent with our reading if we know that reaching them requires that we pass through earlier positions that satisfy the termination condition. We use the given cutset, cs, to derive a second cutset within the goal, cs’, (one that is p “farther”) and construct a ter- mination condition that guarantees that we never pass cs’, thus allowing us to ignore positions that are “be- yond” this cutset. Figure 4 illustrates a sound and complete termination condition based on this construc- tion for an example similar to, but more extreme than that of Figure 2 (i.e., A’ and B’ of Figure 2 are equal). Example 1 (continued) The naive termination con- dition ‘r = 3’ is a separating cutset (as is any other point). Using the construction provided by the proof of Theorem 1, a sound and complete termination condi- tion is ‘r E [3,5] ‘. Although a reading in the range of [3,5] can be obtained outside the goal, the first time the termination condition is satisfied will always be within the goal. Theorem 2 A necessary condition for the existence of a sound and complete termination condition is that the naive termination condition be a motion cutset. Since for convex goals if the naive termination con- dition is a motion cutset then it is a separating cutset we obtain: Consequence 1 If the goal is convex a necessary and suficient condition for the existence of a sound termi- nation condition is that the naive termination condi- tion is a motion cutset. Using more complex definitions we can prove stronger versions of Theorem 1 (i.e., allow obstacles and relax restrictions on initial states) and Theorem 2 (i.e., relax restriction on initial states). Figure 4: sound & complete termination condition nowledge-Level Formallization We would like to generalize the results of the previous section, by extendTlng our analysis to more general do- mains, not restrictink ourselves to such a limited class of sensors. The notion of knowledge will serve as a powerful abstraction, enabling us to do so. The motion protocol We can view our endeavor as the investigation of a class of two-player protocols. Our players are the robot, which follows the motion command, and the environment, which decides nondeterministically, how the robot actually moves and what it senses,’ within given margins [Taylor et al., 19881. Let us make this more precise. Definition 4 A (global) state is a pair (e,r), where e E C and r E R. & is the set of possible (local) states of the environment and R is the set of possible (local) states of the robot. The set of global states is denoted by S. If a is an agent (i.e., the robot or the environment), the set of local states of a is denoted by SIP. In the domain of the previous section the local state of the robot consisted -of its current sensor reading, while the local state of the environment consisted of the robot’s actual position. Definition 5 A run R, is a function from [O,oo) to S. A system is a set of runs. A run R is consistent with a system S if R E S. A run extends the static description of the world, provided by the state, over time. Asystem corresponds to some subset of the set of possible runs, those runs that describe behaviors that correspond to the ones we would like to model. The states that are part of a consistent run are called possible states (or worlds), and represent states of the world that may hold at some time. To reason about one-step motion plans we look at a parameterized class of systems that includes runs that obey the following restrictions: Representation for Actions 2% Motion 673 Q(I, D, AD, AR) The initial state is in I. The restriction of the run to the local state of the robot describes a continuous trajectory. The direction of the tangent to the trajectory at each point q, dq, satisfies dq E AD(q). The reading r in q satisfies r E AR(q). Note that there are no restrictions on the shape or size of AR(q), the set of readings possible at q. The possible initial states are not constrained, either, nor is AD(q) (th us we are not restricted to cone-like do- mains). As an example, in the previous section we looked at a case where AR(q) is a disk of radius p centered in q, and AD(q) = (D’ : ID - D’I 5 A} for a constant A. Knowledge-level analysis of the mot ion protocol We introduce a language for reasoning about the mo- tion protocol. This language contains temporal and epistemic modal operators and has intuitive semantics. We use it to formulate and prove new, more general, results. The language We assume that we have a proposi- tional language ,C. Given an instance of the above mo- tion protocol, let S be the set of possible states. Let Z be an interpretation function, which is a boolean func- tion on S and the primitive propositions in ,C. Z tells us whether a certain primitive proposition is true in a certain possible state. We define the notion of satis- fiability of a propositional formula in a state s, under interpretation Z of S. * Z,S,s b p for a primitive proposition p if Z(s,p) = true; . z,s,s j= la * 1, s, s pa ; o Z,S,s + o A /3 e Z, S, s lo and Z,S,s /=p . We assume that the interpretation function 1, is fixed and ‘natural’, e.g., the proposition g, denoting a goal state, will be satisfied exactly by those states in which the position is part of the goal. We will use Sk Q! when o is satisfied by all states in S, and ~CX when S’b a for any S’. Motion is closely connected with time, thus we add temporal 0perators:l e s,s b 3oa if there exists a run R such that 3 E [O,oo) such that R(t) = s and Vt’ > t R(t’) j= a. I.e., all possible states following s (s inclusive) of a cer- tain run containing s, satisfy a. . s,s j= &a if for some run R such that 3 E [0, 00) R(t) = s, 3’ 2 t s.t. R(t’) b CY. I.e., some possible state following s (or s itself) in some run con- taining s, satisfies 0. ‘Temporal log’ K with these operators were investigated by Emerson and Halpern ([Emerson and Halpern, 1985]), among others. These modal operators define two other operators: In the above operators the present state is considered a part of the future. We have similar operators for the past. The 8 operator for all tenses are: To deal with uncertainty we define the notion of knowledge. Definition 6 Let S be a given set of states, and let s,s’ E s. s -I- s’ e the state of the robot is identical in s and s ‘. Note that -r is an equivalence relation. Definition 7 Let a E ,C. The robot knows (Y at SES, written &Sk K&k! if for any state s’, such that s- .r s’, S,s’~a! . From now on we shall assume that our language, ,C, is closed under the temporal and epistemic operators. All definitions remain unchanged. Although detailed logical investigation is not the thrust of this paper, we note in passing that Ii’ is an S5 operator. Note that given S, the satisfiability in s of a formula of the form &a depends only on the local state of the robot, and can be interpreted as a predicate on its local state. KTa thus uniquely defines a termination condition (al- though not necessarily an easily computable one). The following is our main theorem: Theorem 3 Assume that Sk (lg A b&g) -+ 3olg, where g is the proposition satisfied precisely by the goal states. A sound and complete termination condition exists ifl KTVeg defines a sound and complete termi- nation condition.2 Discussion: There are a number of important things to note. Constructive canonical form: The theorem gives a constructive definition of a sound and complete termi- nation condition, if one exists, so we need only check this condition to verify the existence of a sound and complete termination condition. Optimality: For any run, this termination condition evaluates to true no later than any other sound and complete termination condition. Generality: The use of knowledge to characterize the termination condition means that it applies to sensing uncertainty of any type, i.e., while previously AR(q) was a disk, it can now take on any shape. In fact, we 2We will assume that K,Veg is a closed set. This is a very weak assumption which we discuss in the longer version of this paper [Brafman et al., 19931. 674 Brafman are not constrained to position sensing, and the the- orem applies to force sensing, as well as robots with sensing memory. The initial state may be part of a large region or just a point and our domain may con- tain obstacles. The control uncertainty is not limited to the cone-like behavior of the previous section. The following lemma shows that Theorem 3 covers a large natural family of domains, Lemma 1 For any convex subspace of R”, if the goal region is convex, Sk (lg A V+g) + 301s. Example 1 (continued) If you recall our robot moved along the positive reals, its goal was to be in [2,4] and its reading uncertainty was p = 1. The condition ‘dog is satisfied by positions q E [2, oo), thus I<,Veg is sat- isfied by readings r E [3, oo), corresponding to a sound and complete termination condition. Using the above theorem we have been able to prove the following result about the domain of the previous section. Theorem 4 In an empty subspace of R” with AR(q) a disc of radius p E R and a compact goal, in which the condition Sk (lg A Vgg) --+ 3nlg of Theorem 3 holds for a robot with sensing history; a sound and complete termination condition based on a complete reading his- tory exists, i19p there is one dependent only on the cur- rent position reading. Conclusion and future work Knowledge is a powerful tool for reasoning about do- mains in which uncertainty exists. The temporal- epistemic language we used provides a natural and powerful tool in the domain of motion planning with uncertainty, and enabled us to express and prove re- sults ‘more general than when using geometric specifi- cations. One important task for future research will be to look for interesting temporal/epistemic properties of different sensors and domains (relating the knowledge level and the geometric level), and exploit these prop- erties to prove more specific results. We also hope to be able to lift the restrictions of Theorem 3, and find a general characterization of sound and complete ter- minat ion conditions. The present paper has studied one particular prob- lem. However, knowledge can be applied to many nat- ural problems in motion planning, especially ones that deal with multiple agents, where purely geometrical reasoning would become even more complicated. In fact, most interesting aspects of knowledge come out when there are a number of agents. For example, one can look at the problem of mobile coordinated attack, in which two robots need to halt at their respective goals at synchronized times. Here, a more complicated no- tion of common knowEedge is involved (see [Fagin et al., 19931 for definitions and examples). Various geometric settings of this problem can be explored and it seems that in these complex environments knowledge will be an essential tool. In fact, motion planning offers all the problems encountered in distributed systems and more, but in a much richer setting. Acknowledgement We wish to thank Ronny Ko- havi and Moshe Tennenholtz for important discussions about this work. References Brafman, R. I.; Latombe, J. C.; and Shoham, Y. 1993. Towards knowledge-level analysis of motion planning. Technical report, Stanford University. in preparation. Canny, J. F. 1989. On computability of fine mo- tion plans. In Proc. of the 1989 IEEE Int. Conf on Robotics and Automation. 177-182. Emerson, E. A. and Halpern, J. Y. 1985. Decision procedures and expressivenessin the temporal logic of branching time. J. of Comp. and Sys. Sci. 30( l):l-24. Erdmann, M. 1986. Using backprojection for fine mo- tion planning with uncertainty. Int. J. of Robotics Research 5( 1):19-45. Fagin, R.; Halpern, J. Y.; Moses, Y.; and Vardi, M. Y. 1993. Reasoning about Knowledge. MIT Press. to appear. Halpern, J. Y. and Moses, Y. 1990. Knowledge and common knowledge in a distributed environment. J. ACM 37(3):549-587. Hintikka, J. 1962. Knowledge and Belief. Cornell University Press, Ithaca, NY. Kaelbling, L. P. and Rosenschein, S. J. 1990. Action and planning in embedded agents. Robotics and Au- tonomous Systems 6135-48. Latombe, J. C.; Lazanas, A.; and Shekhar, S. 1991. Robot motion planning with uncertainty in control and sensing. Artificial Intelligence 52:1-47. Latombe, J. C. 1991. Robot Motion Planning. Kluwer Academinc Publishers, Boston. Levesque, H. 1984. Foundations of a functional ap- proach to knowledge representation. Artificial Intel- ligence 23(2):155-212. Lozano-Perez, T.; Mason, M. T.; and Taylor, R. H. 1984. Automatic synthesis of fine-motion strategies for robots. Int. J. of Robotics Research 3(1):3-24. Moore, R. C. 1985. A formal theory of knowledge and action. In Hobbs, J. R. and Moore, R. C., editors 1985, Formal Theories of the Common Sense World, Norwood, N.J. Ablex Publishing Corporation. Rosenschein, S. J. 1985. Formal theories of knowledge in ai and robotics. New Generation Comp. 3~345-357. Taylor, R. H.; Mason, M. T.; and Goldberg, K. Y. 1988. Sensor-based manipulation planning as a game with nature. In Bolles, R. and Roth, B., editors 1988, Robotics Research 4. MIT Press. 421-429. Representation for Actions & Motion 675 | 1993 | 100 |
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.