system SmS1.3 and the knowledge representation scheme NRDR in light of the knowledge level idea. Section 4 presents our interaction language SKIL (Search.
Building Search Heuristics at the Knowledge Level Ghassan Beydoun and Achim Hoffmann School of Computer Sciences and Engineering University of New South Wales Sydney, NSW 2052, Australia Email: {ghassan, achim}@cse.unsw.edu.au
Abstract. The development of highly effective heuristics for search problems is a difficult and time-consuming task. We present a knowledge acquisition approach to incrementally model expert search processes. Our approach targets at the implicit representation of the less clearly definable quality criteria by allowing the expert to limit their input to the system to explanations of the steps in the expert search process. These explanations are expressed in our Search Knowledge Interactive Language (SKIL). The explanations are used to construct a knowledge base representing search control knowledge. For the basis of our knowledge acquisition approach, we substantially extend the work done on Ripple-Down Rules which allows knowledge acquisition and maintenance without analysis or a knowledge engineer. This extension allows the expert to enter his domain terms during the KA process, which integrates the knowledge elicitation and knowledge acquisition in one incremental process and allows the expert to provide a knowledge level model of his search process. We call the new framework Nested Ripple Down Rules. In this paper, we will show an approach to build effective search heuristics efficiently at the knowledge level. We employ SmS for the acquisition of expert chess knowledge for performing a highly pruned search. These experimental results in the chess domain are evidence for the practicality of our approach.
1. Introduction It is well-known that human experts are often surprisingly good in finding better solutions to a given optimisation problem then existing heuristic programs. The successful simulation of the human way of solving optimisation problems would be of primary importance for significant improvements of the computer’s use in most areas of today’s and tomorrow’s computer applications. If the way skilled humans search for solutions can be simulated on computers, then computers will probably be able to perform the search process much faster than humans. In this paper, we describe an approach to incrementally acquire expert search control knowledge. This search knowledge is used to forward prune the search. Our focus is on the epistemological development of search heuristics. We conjecture that this pruned search will resemble the human search process. Furthermore, we expect that
our approach will also yield heuristically adequate algorithms for two reasons: Firstly the human expert is able to make use of static features in a given search state which gives him quick foresight without having to follow useless search paths. Moreover, such knowledge is the easier part to acquire as this is what the expert are normally eager to express in their thought traces, examples in [12, 13, 19]. Secondly, computer circuitry switching is much faster than that of human biological neurons1, so digitally stored human knowledge would be utilised much faster on computers. We developed a workbench which consults the expert on search problems and takes advice of what search steps should be taken in which search state. The results we obtained are very encouraging and provide evidence that our approach may be suitable for a general framework of building high-performance problem-specific search heuristics for combinatorial problems. We do not claim that our workbench simulates the human search process, nor do we claim that we capture human sub-cognitive perceptual mechanisms to zero in on promising search paths. While we claim that our incremental knowledge acquisition approach captures major parts of an expert knowledge which are normally inaccessible by introspective means, this is not where our main contribution is. Our contribution is a promising methodology for developing efficient and effective heuristics with little engineering effort. Since it has been recognised that different search problems require individually tailored heuristics which are expensive to develop, the significance of this work is obvious. This paper is an extension of the work presented in [1]. It’s organised as follow: section 2 gives a more comprehensive treatment of knowledge acquisition requirements presented in [1]. Section 3 presents and discusses the architecture of the our system SmS1.3 and the knowledge representation scheme NRDR in light of the knowledge level idea. Section 4 presents our interaction language SKIL (Search Knowledge Interaction Language) used to interface SmS to the expert, we also show the results of its application in the domain of chess, finally section 5 presents a discussion of the results and future direction of this research.
2. Acquiring Search Knowledge In this paper, the effective performance of a search process itself is the domain of expertise. In many activities of human intellectual endeavour, some sort of search within a set of potential solutions can be said to take place. Capturing the expertise being employed for such skilled search processes is a difficult task. This is reflected in the great efforts being spent on building tools for semi-automatic or even automatic design for many technical problems, e.g. in circuit design [16], mechanical design [10] or architecture [11]. In circuit design, usually the design produced by current design tools is optimised by human intervention. The process of such human intervention is very difficult to formalise and, thus does not usually become automated. Our approach targets to skip the time-consuming process of analysing the expertise and the problem domain by a knowledge engineer, as it has been advocated, e.g. in 1 The speed of human reasoning may also be attributed to the high degree of parallelism of their neurons.
[7]. It rather allows the experts themselves to communicate their expertise to the system. Since also experts usually need to perform a structuring of their knowledge themselves in order to articulate it, the system should allow to specify knowledge ‘on the fly’ and to restructure or rephrase or refine it later on. We view the expert knowledge from a purely declarative perspective. This is a big advantage over generic techniques as in [3] and [24] where from a procedural perspective, knowledge is encoded by programmers. Thus, we allow the expert to develop the structure of the knowledge they want to communicate to the system during the actual knowledge acquisition and maintenance process. We aim at acquiring such intractable search knowledge mainly by other than purely introspective means. We want rather (re-)construct that knowledge than to directly acquire it. We envisage a spiral process of knowledge acquisition, similar to [17] of coming stepwise closer and closer to an operationalisation of the knowledge in question. Our approach follows the work on knowledge acquisition which allows knowledge acquisition and maintenance without a knowledge engineer [5, 6, 8, 15]. We believe that experts are usually able to explain their reasoning process on a particular problem instance in rather general terms that cover at least the given concrete next step in their search process. However, their explanation may be quite inaccurate in the sense that for other search states their explanation would not deliver the search step they would actually take. Either their explanation would not cover the step they would take or their explanation would suggest search steps they would actually not consider. Thus, we pursue an approach similar to [14], which allows to incrementally acquire complex concept definitions without demanding an operational definition from the expert. Rather, the expert is merely required to judge whether the concept applies to particular instances. This is a much more natural task for an expert than to articulate general rules on how to judge on any particular instance. 2.1 Requirements for a KA environment As a result of our aim, a suitable knowledge acquisition tool has to support the following steps of an expert building a knowledge base of search control knowledge: 1. The criteria being used to select search steps worthwhile to consider for a deepening tree search must be very flexible. I.e. the following options should be available: • The expert can freely define concepts to characterise search states as well as search operators applied to the search states. • The definition of concepts should allow the use of other expert-defined ‘sub’concepts. The revision or modification or amendment of initially defined concepts must be possible. E.g. a vocabulary may provide terms like ‘capturing move’, ‘attacking move’, etc.Such terms are not easily defined comprehensively. As a consequence, such terms are subject to incremental refinement throughout the Knowledge Acquisition process. Furthermore, the side effects being introduced by an amendment of a (sub)concept must be limited or controllable in some way
•
In conceptualising their knowledge, experts refine their hierarchical model in a bidirectional manner: bottom up and top down [23]. This must be allowed during the knowledge acquisition process. 2. As indicated in the example of a chess expert search process, how the search proceeds may depend on the findings of search states encountered earlier in the search. To accommodate this sort of reasoning, the system should have a search engine which logs the encountered search states along with potentially interesting findings of the encountered search states. I.e. certain characteristics of search states should be stored as well. This reduces computational requirements as many characteristics persist over sequences of search operators. Furthermore, the expert definable selection criteria for search operators must allow conditions which involve such findings of earlier encountered search states. 3. Finally, there is evidence that domain expert knowledge is fairly complex [23], for instance Simon [22] estimated that a chess master has about 25000-100000 schemata. Hence, any knowledge representation used must be structured and modular to allow easy maintenance, access and development. The fulfilment of the above requirements within our framework is discussed in the next section.
3. Acquiring Search Knowledge at the Knowledge Level In this section of the paper we will discuss our work towards acquiring search knowledge. We will first present our system’s architecture. This will highlight how some of the requirements discussed in section 2 are fulfilled, the satisfaction of the rest of the requirements will be discussed in relation to the knowledge representation scheme NRDR (in section 3.2). We will then discuss how our system SmS1.3 behaves at the knowledge level as originally conceived by Newell in [18]. This treatment will show how the architecture and the knowledge representation scheme used are complementary towards the foreshadowed knowledge level interactions. 3.1. System architecture In designing our system SmS1.3, we aimed at providing a workbench to allow the efficient development of search heuristics and their easy refinement. Thus, SmS aims towards providing means to acquire human expert knowledge as discussed in section 2. For the acquisition of this knowledge and to assist the human expert in modifying the knowledge base as required, SmS models the structure of expert search processes as seen in figure 3.1. To fulfill SmS's goals, the Knowledge Acquisition Module together with the Case Data Base and the KA Assistant are responsible for the incremental development of an NRDR knowledge base which is always consistent with the seen cases. The Search Engine and the Working Memory are conducting the actual search. Which search states are visited is determined by the Domain Specific Search Operators Module and the Search Control Knowledge Base which functions as a filter on all applicable search operators. The progress of the search is stored in the working memory. This
progress is often used by the expert to explain his decisions; this satisfies the second requirement from the previous section. 3.2. Nested Ripple Down Rules In this section we present our Nested Ripple Down Rules (NRDR) which can be seen
Fig 3.1 SmS1.3 Architecture
Fig. 3.2. A simple example of nested rules an update in concept A2 can cause modifications in the meaning of rules C1.1, C1.2 and A1.1 of the KB.
as a set of hierarchical concept definitions. They are the central knowledge representation scheme in our system SmS1.3. We discuss their advantages and the complexity of their maintenance. As discussed in section 2, an essential requirement of the workbench is the ease of acquisition and maintenance of the search knowledge. For this purpose we use Ripple Down Rules as a starting point for the implementation of the knowledge base and the learning module. With RDR, knowledge maintenance is a simple process which can be done by the user without guidance of a knowledge engineer [7]. An RDR tree is a collection of simple rules organised in a tree structure. Every rule can have two branches to two other rules: A false and a true branch. Examples are shown in Figure 3.2, where every block represents a simple RDR. When a rule fires a true branch is taken, otherwise a false branch is taken. If a ’true-branch’ leads to a terminal node t and the condition of t is not fulfilled the conclusion of the rule in the parent node of t is taken, hence the inference is handled implicitly within the structure of the knowledge. In an RDR tree, if a ’false-branch’ leads to a terminal node t and the condition of t is not fulfilled the knowledge base is said to fail and requires modification. An important strength of RDRs is the fact, that they can be easily modified in order to become consistent with a new case without becoming inconsistent with previously classified cases. In their simple form, RDRs use attribute-value combinations as conditions for the rules [6,7,9,21]. Given a search domain, e.g. chess, the attributes used by the expert are not known a priori. The expert may use abstract attributes
which he can explain using simpler attributes. The elementary level is the level of domain primitives. In our system, these primitives must be provided for every given domain by respective C-procedures. The system allows the expert to introduce his/her vocabulary by using Ripple Down Rule structure for allowing him/her to define a conceptual hierarchy during the KA process. For every concept definition a simple Ripple Down Rule tree is used. Conclusions of rules within a concept definition have a boolean value indicating whether the concept is satisfied by a case or not. Defined concepts can in turn be used Figure 3.3. Graphical view of the knowlas higher order attributes by the exedge base. Concept definitions are given in perts to define other concepts. Clearly separate windows. the evolving concept hierarchy depends not only on the given search domain but also on the expert and will reflect the expert’s individual way of conceptualising his own search process. We call such construction of a concept hierarchy using Ripple Down Rule trees Nested Ripple Down Rule Trees (NRDR). Thus, in NRDR’s the attributes used as conditions can themselves be defined in terms of lower order RDR trees. An NRDR knowledge base is said to fail and requires modification, only if in the entry point RDR tree2, a ’false-branch’ leads to a terminal node t and the condition of t is not fulfilled. Given an instance which requires the knowledge base to be modified, the modification can occur in a number of places. For example, say a case x satisfies conditions A1 and B1 in rule C1.1 but the expert thinks that case x is not C1. Hence, the knowledge base needs to be modified to reflect this. A rule can be added as an exception for the RDR tree describing C1, or alternatively, the meaning of attribute A1 can be changed by updating the definition A1, or, the meaning of A2 in rule A1.1 can be changed; and so forth. The number of possibilities depends on the depth of the concept hierarchy in the knowledge base. A more profound update problem is dealing with inconsistencies due to localised updates in the hierarchical knowledge base. For instance, if the expert updates the meaning of A1 by changing the meaning of attribute A2 in rule A1.1, he may inadvertently cause a change in the meaning of rule C1.2 which contains A2. This inadvertent change is detected by the system after every update. The system will check the Case Data Base (see figure 3.1) for inconsistencies. In simple RDRs, a corner stone case is associated with every rule. The rule is the justification for the classification of this case [20]. In NRDR, every rule has a set of corner stone cases. This set contains all the cases that a rule classified correctly under 2 The entry point is the normally the highest level RDR tree. However, this does not have to be the case, as the NRDR knowledge base can be used to verify a case against any of the concepts defined within the knowledge base.
the verification of an expert. These verified classifications must always hold as the knowledge base evolves. Formal treatment of this maintenance process is in [2]. For an update, all points of update are available for the expert via a cascaded representation (see figure 3.3). Consequently, NRDR structures can be developed in topdown or bottom up fashion, satisfying both tendencies of human experts, of which Sowa in [23] states: “..The two approaches may be combined in bidirectional reasoning, which is orginally triggered by stimulus in the data (bottom up), but which then invokes a high-level goal that controls the rest of the process (top down)”.
The integration of NRDR within the SmS architecture and the knowledge acquisition process will be discussed in the next section in light of the knowledge level idea. 3.3. The Knowledge Level, NRDR and SmS The idea of the knowledge level talks about a system description level, at which the system is viewed as a rational agent guided by a knowledge base specified at a level at which humans communicate their knowledge to their fellows. The knowledge level is in some sense an AI version of the philosophical intentional stance where we communicate with computers as though they were humans and will have our intentions. In [18] Newell mentions the relation between his knowledge level and Dennett’s intentional stance formulation. Viewing the system as a rational agent that chooses its actions to achieve its goals according to what it “knows” resembles greatly the intentional stance3. The idea of the knowledge level received considerable attention within the AI community, and it has been extensively discussed, see e.g. [4]. We believe the key contribution of the knowledge level idea is that it offers a perspective that simplifies the design of intelligent systems. For example where action is required, this action should can be viewed as knowledge, moreover where context is altering the needed actions, this context can also be represented within the knowledge. Categorization of knowledge has been a concern of recent papers in AI. It may be argued that this categorization is essential for the implementation of the symbol level that supports the knowledge level development. We claim that this taxonomy is not needed for the development of search heuristics. We will support our claim by highlighting how our system SmS accommodates the knowledge level description as originally conceived by Newell in [18]. More importantly, as we do this we will highlight the knowledge acquisition requirements for implementing search heuristics at the knowledge level (KL). The first feature of the knowledge level is its incompleteness [18]. So, to implement a rational agent at the knowledge level incremental refinement of its knowledge is required. When a system is built using interactions with the expert, the choice of using Ripple Down Rules as a starting point is clearly justified because their structure anticipates future changes and these get easily accommodated within the knowledge base. As the system is developed, its subsequent behaviour determines the subsequent actions of the expert interacting with it. The knowledge acquisition (KA) process is an 3 In [Dennett, 1996 #99], Dennett describes the intentional stance as follow: “The intentional stance is the strategy of interpreting the behaviour of an entity as if it were a rational agent who governed its “choice”of “action” by a “consideration”of its “beliefs”and “desires” “.
interactive process driven by the inherent incompleteness of the KL. Furthermore, as discussed in section 3, the extension of RDR into NRDR allows the expert to enter his own domain terms and explicitly stating the relationships between these terms, which further facilitates the communication between the developing agent (i.e. the system) and the expert. In his description of the KL, Newell [18] continues: “.. Moreover knowledge is not just a collection of symbolic expressions plus some static organisation; it requires both processes and data structures”. To communicate processes at the KL, the classical debate between declarativists and procedurlists must be transcended. In SmS these processes are built incrementaly during the KA process. Primitive domain descriptions at the symbolic level implement the actions at the KL. At the KL, Newell [18] states that no distinction is required between goal and body of knowledge, so at the KL we talk of knowledge about goals. From a system development perspective, the procedural/declarative distinction is made redundant. In SmS, knowledge about the goal is only relevant, while the actual goal is implicitly learned by storing knowledge about the actual operators that modify a search state. Hence, the operators leading to a search state are themselves treated as features of a state. E.g. in the design domains, the current state of the design along with the last action taken to get to this state would be represented to the expert. The expert would comment on the action and the state in the same way. Or in the domain of chess, the goal may be as simple as the completion of a sequence of moves to more subtle as going through states in the game to achieve a strategic goal. So in our framework, using NRDR the expert expresses all his knowledge in a declarative manner, the features of the search state along with the features of the operator that led to this state are presented to the expert for commenting (in retrospect). NRDR concepts can be viewed as labels that organise the knowledge (both the “how” and the “what” knowledge). These concepts can be used to store sequences of actions where every rule turns into an action when it interacts with the search engine in SmS. This common perspective on features and operators is the fundamental step required for adopting the generic view of knowledge in the knowledge base. It enables the metamorphous between declarative and procedural knowledge transparently. Finally, an important feature of knowledge at the knowledge level is its dependence on the task on hand. I.e. knowledge is generated dynamically. This is expressed by Newell [18] as follows: “.. this knowledge can only be created dynamically in time. If generated by some simple procedure, only relatively uninteresting knowledge can be found. Interesting knowledge requires generating only what is relevant to the task at hand ..”. In acquiring search knowledge we note that the expert often refers to the ongoing search process while explaining his steps. This dynamic reference is accommodated in SmS by storing this search process in a working memory (see figure 3.1) and availing it at the knowledge level. Consequently, while a search is being executed by SmS, some of its decisions are based on this very search and can only be generated dynamically. These decisions cannot be known statically. In the next section We discuss the interaction language which constitutes the interface between the expert and the knowledge base (i.e. the system).
4. Search Knowledge Interaction Language (SKIL) The interaction language between the expert and the system is called SKIL (Search Knowledge Interaction Language). The language structure allows existential and universal quantifications of generic variables used in primitives. Conjunctions and negations of the primitives are also possible. The language construct is perfectly transferable across domains. The actual primitives are the only non-transferable component of the system. A domain expert is required for their construction, this is a quick initial knowledge engineering stage. An example of a set of such primitives in the domain of chess is discussed at the end of this section. The strength of NRDR as earlier discussed is that it allows the expert to define his/her own concepts in terms of domain primitives, or other previously defined concepts. In defining a concept X (as an RDR tree) in SKIL, the expert can give a formal parameter list to the concept. The use of this parameter list is flexible. Initially, the expert may give a general rule condition leaving some parameters unbounded. In later refinements, he may enter rules with bounded parameters. Also, in SKIL, there is a special time stamp parameter to indicate the point of application of the concept. For example, if the expert states X(-1), then he’s referring to the previous search state in the search path. This gives the expert complete access to the actual search progress stored in the working memory, as he gives his explanations. Conjunction and negation are also possible on expert defined concepts. Conditions in every rule in NRDR, are statements given by the expert in SKIL. In normal RDR, the expert chooses a list of relevant differences from the so called difference list. This difference list is the finite set of differences between the corner stone case of the parent rule and the corner stone case of the newly added rule. In normal RDR, this difference list is easily generated as every case is represented as vector of propositional valued attributes, and these same attributes are used as conditions in the rules. In NRDR, cases are also represented as propositional valued attribute vectors. However, the conditions of the rules in NRDR are relations between the vector features expressed in SKIL. So, a finite difference list is not feasible in our framework. Instead, the expert is represented with a visual representation of a corner stone case of the parent rule and the current case causing the addition of a rule. The primitives can be declared in reference to the current search state, or to any past search state in the search progress stored in the working memory. They can also be negated. As an example we discuss the implementation of domain primitives n the domain of chess. The primitives in the domain of chess can be classified into four major category: Variable declaration and comparison primitives: There are a number of ways a variable can be declared, a variable X can be declared as piece, a rank, a file, a colour, or a particular square. See example in table 1. Tactical primitives: They essentially describe how many legal moves are needed for a variable to reach another variable. See example in table 1. Visual primitives: In chess, often the expert searches for visual patterns on the board when making a decision. This is very common in chess endgames. To express his
visual reasoning, the expert is provided with primitives which relate variables in terms of their relative visual orientation. See example in table 1. Global primitives: In chess, the expert often refers to global features of the board when justifying his move e.g. he may say “I exchange my queen because I am two pawns ahead and therefore my two pawns advantage will become more crucial when there are less pieces on the board”. See example in table 1. In the system implementation, we ensured the flexibility of domain primitives module (see diagram 3.1) by using automatic grammar generator systems (Lex and Yacc), so it’s easy to extend the primitives set during the actual knowledge acquisition stage. Primitive and description
Board
value
comparisons:
This
Example
Example explanation
Category
bvalue (0) Y in 1
of ranks between two variables.
There is one rank separating X and
Visual
Y. X (or Y) can be a particular
primitive
piece or square, or any square existentielly declared on a given file, rank or colour Count files: This counts the number
X F> Y in 3
of files between two variables.
There are three files separating X
Visual
and Y. X (or Y) can be a particular
primitive
piece or square, or any square existentielly declared on a given
Shortest
distance
measure:
This
X
È Y in 5
file, rank or colour The minimum separation between
Visual
counts the shortest separation be-
X and Y is 5. X (or Y) can be a
primitive
tween two variables. This separation
particular piece or square, or any
is the minimal number of ranks or
square existentielly declared on a
files. Declaring variables: This declares a
given file, rank or colour X = a5
X is declared to be square a5.
variable to be a square, a piece, a file,
declara-
a rank or the totality of the board. Variable comparison: This compares two variables.
Variable
tion X=Y
X is constrained to values equal to
Variable
Y. X and Y must be declared.
comparison
Value comparison: This compares the
X >> P
value of a variable to a piece value.
X is constrained to values larger
Variable
than a pawn ( a pawn is one point)
compari-
E.g. in chess a rook is 5, and a knight
son
is 3. Captured
piece
statements:
the
Captured = P
The captured piece is a pawn.
Compari-
captured piece ceases to be on the
son
board, therefore it’s designated by its
primitive
own token “captured” Table 1. Primitives in SKIL in the domain of chess
In the next section we will show how using the above primitives within SKIL SmS can be used to simulate expert chess knowledge. This will clearly show how the expert/system interactions are at the knowledge level. 4.1. SmS in Chess We now demonstrate our approach by showing examples of the typical knowledge acquisition cycle (or rather spiral) in the domain of chess. The objective is to develop a search knowledge base which produces a search process that resembles a human expert search process as much as possible. To do that, we defined concepts that approve moves to be considered in a minmax tree search which determines the actual move to be taken. In order to keep the searched tree small, it is important to approve only those moves that are really worthwhile considering any further. On the other hand, no dangerous move by the opponent should be excluded from the tree search in order to ensure high quality play. The knowledge acquisition process attempts to develop a concept ‘good move’, which applies to exactly those moves which should be considered for the tree search. Initially, no search operator in any search state will qualify, i.e. no move in any chess position will be classified as ‘good move’ and, hence, no tree search takes place. 4.1.1 Multi-point modification Initially the Knowledge base is empty. The default rule is "If True then -Good" which means no move is considered as good. Hence, the system will consider all moves generated by the move generator as bad and none will be developed further in the search tree. So, the system develops a search tree of depth 1. It chooses a move using a simple evaluation function as used in the minmax algorithm. In figure 4.1 there is a pawn to be captured on e3. The human expert plays for black Nxd5. The expert sees this as a good move because he wins a piece. Thus, on the highest level of the knowledge hierarchy he introduces a new rule "If WinPiece then Good". Subsequently, he needs to explain the meaning of the newly used attribute "WinPiece". The system creates a new Ripple Down Rule tree prompting the expert to explain the concept "WinPiece". The expert enters the root node "If WinPawn then WinPiece". Similarly, the system prompts the expert for an explanation of the attribute “WinPawn”. The expert explains the concept in terms of primitives which are known to the system. Assume it is white's turn and he
plays Re1. Assuming the system knowledge consists of the three rules entered in the mentioned scenario, it responds with Nxe3 as it thinks it wins a piece. The expert disagrees with this, because Nxe3 is not a safe move as the knight on e3 can be Captured by the rook on e1. So, he must modify the knowledge base. At the highest level, the expert can add "If Not SafeMove then Not Good" on the true link of "If WinPiece then Good". Or, he can change the meaning of "WinPiece" by adding "If Not SafeMove then Not WinPiece"; finally, he can also change the meaning of "WinPawn" in the WinPiece Ripple Figure 4.1. Black to play. Black knight can Down Rule tree by adding "If Not capture a "Free" pawn on e3. SafeMove then Not WinPawn". Note, the choice of the point of modification is part of the knowledge acquisition process. In this particular example any of the modifications is valid.
Fig 4.2. Pawn on e3 can or cannot be captured? Left: After 1. Re1 -- Nxe3 (bad unsafe play by black). Right: Pawn on e3 is worth capturing.
Inserting the new rule on a higher level in the concept hierarchy can specialise the knowledge base modification more than inserting the new rule in a more specialised concept. However, modifying the more specialised concepts may cause more inconsistencies to be introduced into the knowledge base. This is since there is a greater chance for the more specialised concepts to be used as attributes. It is the responsibility of the knowledge acquisition assistant module to detect these effects and guide the expert to deal with them. It is worth mentioning that the higher the hierarchical structure of the concepts, the more condensed the knowledge base may become. In the above example, the expert chooses to modify the meaning of "WinPiece" by adding "If Not SafeMove then Not WinPiece" to the true link of Rule 1 in the "WinPiece" concept definition. Of course, the meaning of "SafeMove" needs to be explained. The expert introduces the rule "If white can reach the destination square in one move then Not SafeMove" which is understood to the system as it is defined solely in terms of the primitives available (see table 1).
4.1.2 Further features of SKIL in chess In figure 4.2 (left), the pawn on e3 is protected by the rook on e1, hence, Nxe3 is not considered a good move by the system. However, capturing the protected pawn on e3 exposes the white knight on d4 to the black bishop on g7. So, the expert enters new knowledge into the system. The rule "If Expose then Good" is added on the highest level. The concept Expose(X) is explained as capturing an opponent piece Y, such that Y has been protecting the piece X for the last two positions4 i.e. the move exposed X to an attack. This parameter X is a variable used in the primitives explaining the concept "Expose". In figure 4.3, white plays the bishop to b2 protecting his knight. Hence, capturing the pawn on e3 no longer exposes the knight. Hence, the knowledge base needs to be altered again. In particular, inside the Ripple Down Rule tree describing the Expose concept. According to our chess expert, a black move exposes a white piece if the move removes all of the white piece’s protection it had in the previous two positions.
Fig 4.3. Pawn on e3 is not worth taking anymore after White plays Bb2.
4.1.3. Pruning a search tree using the knowledge base Chess is a two players game. The search tree nodes alternate for the two players. To look ahead further than one half move, the knowledge base must be large enough to account for the responses of the opponent. The expert plays for white explaining the option he takes. Thus, for figure 4.1 the expert plays Re1 to protect the pawn on e3, and for figure 4.3 (right), he plays Bb2 to protect the knight on d4. The knowledge base is developed by the expert’s input. The concept of "DefendingPiece" is introduced. As for black’s sake who is required to find some good moves in the absence of possible killer moves- i.e. capturing and/or exposing white’s pieces, the knowledge base is extended to cover more strategic moves such as strengthen one’s defence or attack. As a result, the knowledge base matured to 20 rules and 11 concepts. The hierarchy of the concepts is up to depth four. In figure 4.1 with white to play, the evolved knowledge base leads to a tree search of depth five involving 47 nodes. This is opposed to the blind min-max tree search of depth several million of nodes. The pruned tree reflected largely the expert’s decisions on which moves are worthwhile to investigate further. The computer play with a pruned tree of depth five is also shown below
4 Primitives access the working memory when referring to the last two positions. (see table 1)
figure 4.4 . The play shown resulted in the computer gaining the upper hand against an average human player Fig.4.4 Average human player against our system SmS1.3. The starting position is the one in figure 4.1. White to play against SmS1.3: 1. Re1 Rd8 2. h3 Bf6 3. Nd4 Nxe3 4. Rxe3 Bxd4 5. Kf2 … Left: The resulting position. SmS 's performance (black) against an average human player (white).
Clearly the used knowledge base would not suffice for playing sufficiently well over an entire chess game as many more problems would occur, to which the KB has no solution yet. However, it is clearly possible to take advantage of the human knowledge to prune the tree significantly without loosing quality of play.
5. Discussion and conclusion In this paper, we presented a new approach to the development of effective search heuristics. We viewed the problem as a knowledge acquisition task, which resulted in a modelling of expert search knowledge at the knowledge level. This modelling process is based on expert’s explanations of the expert search process. Our experimental results, so far, suggest that it is possible for an expert to articulate incrementally (tacit) search knowledge when forced to explain the outcome of the knowledge in sufficient detail. The expert was asked to explain and refine concepts until the application of the concepts resulted in the same search steps the expert was proposing. Our knowledge acquisition, representation and maintenance scheme, Nested RippleDown Rules, is more generally applicable than to the acquisition of search knowledge. Furthermore, we developed a mechanism to support keeping the knowledge base consistent with previously encountered cases as the knowledge base is updated and maintained. In future development of this work, we will accommodate uncertainty measures during the knowledge acquisition process. This will be a more realistic representation of knowledge of human experts who are known to accommodate some kind of uncertain reasoning.
References 1. Beydoun, G. and A. Hoffmann. Acquisition of Search Knowledge. in the 10th European Knowledge Acquisition Workshop. 1997. 2. Beydoun, G. and A. Hoffmann. Simultaneous Modelling and Knowledge Acquisition Using NRDR. in 5th Pacific Rim Conference on Artificial Intelligence. 1998. Singapore: SpringerVerlag.
3. Chandrasekaran, B., Generic tasks in knowledge-based reasoning: High level building blocks for expert system design. IEEE Expert, 1986. 3(1): p. 23-30. 4. Clancey, W.J., The Knowledge Level Reinterpreted: Modeling How Systems Interact. Machine Learning, 1989. 4: p. 285-291. 5. Compton, P., et al., Ripple down rules: Turning knowledge acquisition into knowledge maintenance. Artificial Intelligence in Medicine, 1992. 4: p. 463--475. 6. Compton, P. and R. Jansen., A philosophical basis for knowledge acquisition. Knowledge Acquisition, 1990. 2: p. 241--257. 7. Compton, P., et al. Knowledge Acquisition Without Knowledge Analysis. in European Knowledge Acquisition Workshop. 1993. 8. Compton, P., P. Preston, and T. Yip. Local patching produces compact knowledge bases. in The European Knowledge Acquisition Workshop. 1994: Springer-Verlag. 9. Gaines, B.R. Induction and Visualisation of Rules with Exceptions. in 6th Banff Knowledge Acquisition for Knowledge Base System Workshop. 1991. 10.Gero, J. and F. Sudweeks, Artificial Intelligence in Design. 1996: Kluwer Academic Press. 11.Gero, J. and E. Tyugu, Formal Design Methods for CAD. 1994: North-Holland. 12.Groot, A.d., Thought and choice in chess. 1965, Paris: Mouton. 13.Groot, A.d., Perception and memory versus thought: some old ideas and recent findings. 1966, New York: John Wiley and Sons. 14.Hoffmann, A. and S. Thakar. Acquiring Knowledge by Efficient Query Learning. in 12th International Conference on Artificial Intelligence. 1991. 15.Kang, B., P. Compton, and P. Preston. Multiple classification ripple down rules: Evaluation and possibilities. in 9th AAAI-sponsored Banff Knowledge Acquisition for Knowledge Based Systems Workshop. 1995. 16.Lengauer, T., Combinatorial Algorithms for Integrated Circuit Layout. 1990: John Wiley and Sons. 17.Linster, M., Explicit and operational models as a basis for second generation knowledgeacquisition tools, in Second Generation Expert Systems, J.-M. David, J.-P. Krivine, and R. Simmons, Editors. 1993, Springer-Verlag. p. 477-506. 18.Newell, A., The knowledge level. Artificial Intelligence, 1982. 18: p. 87--127. 19.Newell, A. and H.A. Simon, Human problem solving. 1972, Englewood Cliffs. N. J.: Prentice-Hall. 20.Richards, D., V. Chellen, and P. Compton. The Reuse of RDR Knowledge Bases: Using Machine Learning to Remove Repetition. in Pacific Knowledge Acquisition Workshop. 1996. 21.Shiraz, G. and C. Sammut. Combining knowledge acquisition and machine learning to control dynamic systems. in 15th International Joint Conference on Artificial Intelligence. 1997. 22.Simon, H.A., How big is a chunk? Science, 1974. 183: p. 482-488. 23.Sowa, J.F., Conceptual Structures, information processing in mind and machine. 1984: Addison and Wesley. 24.Yost, G.R., Acquiring Knowledge in Soar. IEEE Expert, 1993(6): p. P26-34.