4. Production Systems and Artificial Intelligence

Quite apart from their cognitive plausibility, production systems have advantages over conventional programming languages that make them ideal for task domains in which knowledge may change or grow over time, and in which the initial problem state and final solution state may differ from user to user: they are flexible, modular, and plausible.

4.1. Production Systems Are Flexible

Production systems use the same basic `if-then' format to represent knowledge in very different domains. An informal Automated Tourist Guide rule, for example, expresses a very different content from the rules, given earlier, for closing Tweetie's cage or for applying suntan lotion:


	rule centre_cinema :
	       if      [entertainment, medium, cinema] &
	               [entertainment, place, centre]
	       then    add [location, leicester_square].

Yet all three rules have the same underlying form: whether its function is to infer conclusions from premises or to perform actions in response to given circumstances, in each case the `condition' side of the rule is matched against working memory and, if the match succeeds, the action specified in the rule body is executed.

4.2. Production Systems Are Modular

In an ordinary computer program one procedure calls another, in such a way that a change to one procedure may entail the modification of any others that call it. Simply removing a procedure may well result in the collapse of the whole program. In contrast, the functional units of a production system -- the set of rules in its rulebase -- are independent, self-contained chunks of knowledge, any one of which can be altered or replaced without disabling the entire production system and without requiring the modification of other rules. Such alterations might modify or restrict the behaviour of the system, but will not cripple it. This is because the rules in a production system are separate from the program that runs them: the rules do not interact with one another directly but only through changes to the working memory. By way of illustration, figure 4 contrasts the flow of control in an ordinary program with that of a production system. Modularity is especially important in large production systems; as knowledge of a domain is modified or extended, new rules can be added in a fairly straightforward manner. Failure of a system to perform some primitive action or draw some inference can be remedied simply by writing a new rule whose head matches the relevant items in the database and whose body executes the appropriate action.

Figure 4. Flow of control in ordinary programs (left) and production systems (right).

The most important development in production systems has been in the building of expert systems: computer programs that have the knowledge and expertise, in the form of hundreds or even thousands of rules, that will enable them to operate at the level of the human expert in some specialist domain. This makes them valuable as consultants in medicine, management, engineering, computer-system configuration, and chemical analysis, to name but a few areas where expert systems are in regular use. Such systems provide the support of expert knowledge that is relatively cheap (a full-time human consultant commands a much higher salary!), reliable (humans do make mistakes), portable (human experts are scarce, and sometimes too busy to come on call), and untiring (human experts have to sleep sometimes; eventually they die); and, because of the modularity of such systems, they can be extended to become more proficient than any human expert whose knowledge has been `written into' the rulebase. Expert systems need not store information uniquely in the form of production rules. For example, the PROSPECTOR system to analyze geological data codes much of its knowledge in a semantic net; other systems have used frames or a form of predicate logic.

4.3. Production Systems Are Plausible

Human experts do not simply apply their knowledge to problems; they can also explain exactly why they have made a decision or reached a particular conclusion. This facility is also built into the expert systems that simulate human expert performance: they can be interrogated at any moment and asked, for example, to display the rule they have just used or to account for their reasons in using that rule. That a system is able to explain its reasoning is in itself no guarantee that the human user will understand the explanation: if the advice is to be of use, it is important that the system be able to justify its reasoning process in a cognitively plausible manner, by working through a problem in much the same way as a human expert would. Production systems, and the more sophisticated expert systems, can be made to reason either forwards, from initial evidence towards a conclusion, or backwards, from a hypothesis to the uncovering of the right kind of evidence that would support that hypothesis, or by a combination of the two. One significant factor which will determine whether a system will use forward or backward reasoning is the method used by the human expert.

If all the necessary data are either pre-given or can be gathered, and if it is possible to state precisely what is to be done in any particular set of circumstances, then it is more natural and likely that a human being -- and hence any machine modelling human performance -- would work forward from the data towards a solution. An expert system which reasons forward in this way is R1 (also known as XCON), which configures DEC-VAX computer systems. R1 reasons forward until a single good system configuration is found (others may be possible, but are not considered so long as one good solution is found). Medical diagnosis, on the other hand, normally proceeds abductively from a patient's symptoms back to the possible causes of the illness, and hence to an appropriate course of treatment. This was a crucial factor in the design of, for example, MYCIN, a system that diagnoses blood infections. MYCIN is a moderately large expert system, having around 450 rules, of which the following is typical. (The form of the rule is shown in its English form, which is used by MYCIN to generate explanations to the user. For reasoning, the system calls on rules coded in an extension of the LISP programming language.)


	if     [the stain of the organism is gramneg] &
	       [the morphology of the organism is rod] &
	       [the aerobicity of the organism is aerobic]
	then   print `There is strongly suggestive evidence (0.8) that
	               the class of the organism is enterobacteriacae'.