Knowledge-Based Systems 9 (1996) 509±515
Design and application of a new knowledge engineering tool for solving real-world problems Zdzisław S. Hippe* Department of Computer Chemistry, University of Technology, 6 Powstan˜co´w Warszawy Ave., 35-041 Rzeszo´w, Poland
Abstract The results of a broader cognitive research on an intelligent knowledge engineering program environment are described. This intelligent programming tool features an open architecture, modularity and an idea to use multistrategy learning, multistrategy knowledge representation and integration of various schemes of knowledge processing in a single inferential process. Some selected applications of the developed tool, carefully examined at various levels, are briefly dealt with. q 1997 Elsevier Science B.V. Keywords: Knowledge engineering; Machine learning; Production rules automatic generation; Multistrategy reasoning
1. Introduction The work presented here is a continuation of a long-range research project, aimed at development of an intelligent knowledge engineering program environment, being able to generate expert systems using various schemes of reasoning in a single inferential process. The idea of application of different ways of reasoning, described for the first time by Otsu [1] for the RWC Japanese project, has been combined in the information system being discussed with a concept of open architecture. It means that some loosely connected modules of the system – those already developed – may easily be augmented by new operational modules, without any conflict with data and/or information flow throughout the existing structure. Additionally, along with current trends in artificial intelligence [2], the hand-crafted development of knowledge bases is avoided and substituted, whenever possible, by a specific type of case-based reasoning, terminated by an automatic generation of respective production rules. Therefore, the recent version of the system uses various formalisms of knowledge representation like frames, knowledge images, fuzzy knowledge vectors, knowledge associations, and plain language production rules. In the reasoning process some of the knowledge representation formalisms are jointly combined in a hybrid, multistrategy inferential process to achieve the best performance of the system. For example, in the control (steering) of large industrial objects the combination of frames, knowledge images, knowledge vectors and production rules is applied, whereas for solving many problems in natural sciences * Fax: +48 17 41519; e-mail:
[email protected]
0950-7051/97/$17.00 q 1997 Elsevier Science B.V. All rights reserved PII S 09 50 - 70 5 1( 9 6) 0 00 0 2- 0
melting of production rule formalism with knowledge images was found to be very effective. To achieve better performance of the developed system in solving basic problems met in natural sciences, the following areas of specific applications of the tool have initially been chosen: • • • •
automation of chemical processes; interpretation of molecular spectra (user guided or automatic); modelling of chemical transforms (forwards or backwards); and prediction of properties of materials and/or substances.
2. Outline of the architecture of the system: main functions of selected modules The basic architecture of the developed tool (SCANKEE), previously containing five working modules [3,4], has been currently enhanced to the architecture presented (see Fig. 1). Graphic Datapath Builder (GDB) creates control structures within the knowledge base, together with a pictorial representation of knowledge (if necessary, and if possible, using formalism of pictures, drawings, curves, icons, chemical structures, etc.) in the form of knowledge images. These structures are then used by the inference engine of the system during reasoning and decision making. The concept of knowledge images, i.e. pictorial representation of objects, attributes, and/or their values, in most cases tested, filled well a gap between the human reasoning and computers as conventionally programmed. Application of this concept
510
Z.S. Hippe/Knowledge-Based Systems 9 (1996) 509–515
Fig. 1. General architecture of the SCANKEEt system (functions of selected modules are described in the text). In the reasoning process, some of the knowledge representations, gained by subsequent modules, are jointly combined in a hybrid, multistrategy inferential process to achieve the best performance of the system.
provides better representation of categories that shade one into another, and implies necessary fuzziness, particularly required in the natural sciences. The creation of knowledge images by means of the module discussed is brought about in a very simple and user-friendly way. The image of virtually any object may be generated with user-defined lines, colours, size and spatial location; the library of a priori defined images (e.g. standardized symbols and outlines) may also be easily created. Essentially, this is an implicit knowledge generated in some cases automatically using our own sophisticated, mathematical models. Also, some generic operations on objects may be performed, such as rotation, changing position and size, or aggregation of single objects into the specified aggregation. Multimedial Knowledge Formalizer (MKF) may be regarded as a very flexible tool for knowledge formalization and its preparation to conduct effectively the process of automatic inferencing. Currently, three different formalisms of knowledge representation may be inherently used. The first one is based on the application of frames, employed later in a specific way, where slots may contain images, comments, suggestions or warnings. The second formalism
of knowledge used in the module is based on fuzzy knowledge vectors; it is particularly convenient for storage of information about states of any complex industrial object. For the sake of clarity of the discussion, we set apart an object in the normal state, and in the perturbed (distorted) state. In the normal state all components of the knowledge vector have their values within allowed bounds. Distortion of only one component in a vector causes the search for a sequence of allowed corrections to begin. This search is executed using the last allowed formalism for knowledge representation embedded in the module, i.e. a mechanism based on production rules. Initially, production rules may be formulated using a Knowledge base Kernel Language (KKL), a subset of current (ethnic) English, consisting now (in the recent version) of about 80 keywords. KKL is tentatively used to describe cases, situations, objects and relations between them, and also for scheduling, defining coordinates (e.g. time), etc., using monotonic, ŁukasiewiczTarski-, or fuzzy logic. Additionally, some keywords are used to control the operation of the inference engine of the system (recursion, cycling, maintaining confidence), method of reasoning (backward or forward chaining), communication with external programs or files, and style of output display. The module discussed also provides a mechanism to define any number of synonyms for a keyword, which distinctly extends the vocabulary of KKL. In this sense we may talk about plain language production rules; they may be formulated in an extremely flexible form, according to the individual will of a given user. Moreover, in that way a noteworthy advance in knowledge engineering and expert systems was achieved: use of the concept of synonyms leads directly to unlimited possibilities of generating a knowledge base in virtually any natural language. For example, ALS (in Dutch) may be treated as a synonym of an English keyword IF; other ‘‘synonyms’’ (foreign words in selected languages) are shown in Fig. 2. Multistrategy Learning Classifier (MLC) is based on the specific formalization of knowledge developed in our group,
Fig. 2. An example of the extended concept of keyword synonyms. Here, the keyword IF may be substituted by words from selected foreign languages: 1 from Dutch, 2 from Polish, 3 from Japanese, 4 from Swedish, 5 from Italian, and 6 from German.
Z.S. Hippe/Knowledge-Based Systems 9 (1996) 509–515
called by us knowledge associations. Inferencing with this formalism may be bidirectional: forwards (classification; a walk from a given input set of technological parameters to a product, having properties dependent on input data), or backwards (prediction; a walk from a product having required properties back to a forecast, how to fix an optimum set of discovered technological parameters, in order to get a given product). Using the knowledge representation formalism developed, an association may be created that exhibits logical relations between sets of parameters, describing important features of the technology being investigated. An example association is given below:
Thus, the knowledge association constitutes a convenient formalism to describe precisely divergent technological processes applied in computer-assisted engineering of materials. The applied formalism of knowledge representation may be treated as a generalization of data for case-based reasoning, used for the description of a fact (or an example):
Only the user’s experience and needs determine which attributes should be placed in the box A, B, and C, respectively. Usually, in box C attributes best describing the engineered product should be located. On the other hand, splitting of attributes among boxes A and B (causes, generally) do not play any role. We may, for example, move all attributes from box B to box A, which yields a one-step association (with the logical product):
An ordering effect is clearly seen here, if – without the change of attributes values in box A – we change the attributes (precisely speaking, their values) in box B. This situation is represented by the following association:
The example shown might easily be converted into two one-step associations:
511
A collection of relevant facts (examples) constitutes the body of a knowledge base, which may then be effectively used for bidirectional case-based reasoning. Inferencing with this module has been successfully applied in solving some real-world problems in the metallurgical industry (development of alloys having required properties) and also in the chemical industry (production of polymeric blends, production of car tyres, production of glass, etc.). Multispectral Structure Analyser (MSA) is a newly developed module employing its own set of knowledge bases for molecular spectroscopy, developed by our group in a separate research [5]. This set consists of: 463 13C-NMR spectra, 253 1H-NMR spectra, 1800 mass spectra (highresolution and truncated), 300 infrared spectra, 165 Raman spectra and 210 UV spectra.1 The main field of application of the MSA module is the user-guided interpretation of molecular spectra, using the so-called ‘‘cascade of facts logic’’ (CFL) developed by De˛bska [6]. CFL methodology allows one to discover the main substructures of the analysed compound (represented in the form of a graph) by stepwise discrimination of the library search throughout various molecular spectroscopy knowledge bases of the system. Molecular Structure Generator (MSG) now being developed, is assumed to perform exhaustive (and fast) generation of candidate structures from a set of substructures, obtained during the automatic interpretation of molecular spectra (see Case_1). Common Sense Builder (CSB) is able to simulate the procedural knowledge of a highly qualified chemist. The simulation process is executed forwards, i.e. consistent with the natural direction of flow of reactions, using a mathematical formalism described in [7]. Additionally, the concept of ‘‘common sense reasoning’’ has been cast over this formalism, which allowed to prevent from unnecessary processing (generation of reactions). The common sense algorithm developed uses its own knowledge base (implicit knowledge!) and utility programs (common sense routines), designed to manipulate a procedural-type knowledge about organic reactions. Briefly speaking, these routines enable one to mimic the intellectual capabilities of an educated chemist while predicting the chemical behaviour of a molecule (or a chemical system consisting of two or more molecules) after at-a-glance inspection of its (their) structure(s). In other words, the common sense routines look for the most promising reaction sites (active parts of a molecule, atoms, bonds, etc.) in the processed molecule. Only these sites will be used, in the next step, in simulation; other potential reaction sites are kept inactive. In this way an exhaustive search through the solution space is avoided; not all chemical transforms are generated, but only a part of them, possibly the most promising. It was found that the module discussed generates reactions which display a considerable degree of ingenuity and lead to interesting conclusions about the 1
Status by end of July 1996; subject to changes.
512
Z.S. Hippe/Knowledge-Based Systems 9 (1996) 509–515
behaviour of the simulated chemical system. These intelligent abilities also cover the possibility of reasoning in the case of incomplete and/or uncertain knowledge about the investigated object. Incidentally, it should be emphasized that a list of predicted (by the module) reactions may contain unprecedented reactions (i.e. not described in current chemical literature). Chemical Syntheses Planer (CSP) is able to create complete synthetic routes to complex molecules, using the backward processing of a target structure (the ultimate goal of a synthesis), through various sub-goals of different generations. In the developed synthesis tree [8], branches represent routes to a given target structure, whereas terminal leaves stand for starting chemicals: these may be available (on the market) or known to the user (in other words, the user knows how to synthesize a given starting chemical). Chemical Technologies Optimizer (CTO) enables computation of automatically stoichiometric relations for any chemical equation, using an internally developed knowledge base. Here, the processing of molecular information – contained in the form of graphs – is combined with inferencing based on production rule formalism. Intermodule Communication Tool (ICT), now being developed, serves as a specific programming block, enabling communication and transfer of information between agents (modules) involved in distributed problem-solving. This kind of problem-solving is met whenever more than one operational module of the SCANKEE system is combined towards a single inferential process. Simulator of Expert’s Knowledge (SEK) essentially is an advanced inference engine of the developed system. It fulfils requirements settled for the reasoning section of contemporary expert systems, for example a high-level user interface enabling easy communication with the system, tracing the line of reasoning, using the what–if scenario, or inspecting chunks of knowledge actually used, no matter whether formalized as frames, vectors, associations, and/or production rules (written in any ethnic language). Moreover, the module has two unique features: (1) it chains various knowledge formalisms in a single inferential process (see Section 3, Case 2), and (2) it combines knowledge images with production rules in decision making, yielding a very powerful methodology for general problem-solving.
3.1. Case 1 In this research a very special feature of the MKF (multistrategy knowledge formalizer) has been employed, namely the ability to learn automatically spectrum–structure correlation, aimed at subsequent generation of respective production rules (by the computer itself), and putting them together into a complete analytical knowledge base for the identification of structural fragments in organic compounds. In the case discussed, we focus our attention on infrared spectrometry (IR); however, the learning procedure of the computer is developed for six different spectral techniques ( 13C-NMR, 1H-NMR, MS (high-resolution and also truncated mass spectra), IR, Raman, and UV). During the learning process, the list of statistically significant correlations is developed and then translated into an optimum set of production rules. The methodology discussed is exemplified here by a knowledge base for identification of three (arbitrarily selected) substructures: ester group [–C(yO)–O–], ether bond [–O–], and methyl group [–CH 3], by means of infrared spectrometry. The knowledge base (Fig. 3), obtained automatically, consists of some clearly defined parts: (a) control of the inference engine; (b) questions displayed on the monitor screen during problem-solving; (c) main production rule controlling the operation of the knowledge base, summing up probabilities of identification, displaying the results, and concluding the reasoning process; (d) set of four production rules responsible for the identification of selected substructures; (e) a rule that controls the input of parameters of subsequent bands of the spectrum being elucidated; and (f) control structure for displaying the results (invoked from within the rule no. 0). Such a knowledge base may be treated as the ‘‘ready-touse’’ base of an expert system for identification of selected structural fragments. In the research, numerous knowledge bases have been generated, compiled, and used in the identification of various substructures. One can readily imagine the creation of various knowledge bases well suited for the solution of any specific type of structural identification. It is believed that this approach surpasses the ‘‘barrier’’ of the DENDRAL project [9]: here, instead of only one spectroscopic method used (mass spectrometry), six various spectral techniques may be instantly applied, reaching a high and reliable level of identification, enhanced by the possibility of combining various spectral methods in a single inferential process.
3. Examples of applications
3.2. Case 2
In the initial testing of the performance of the developed system, three challenging sub-fields of chemistry have been explored: identification of structural fragments in organic compounds (Case 1), high-level educational research on the example of training controllers (operators) of a very large production plant (Case 2), and engineering of materials (Case 3).
As a test bed, a production plant of CS 2 (carbon disulphide) has been selected. The main process here is based on carefully controlled burning of sulphur under high pressure and at a very high temperature exceeding many times the boiling point of CS 2). In the case of malfunction of the pressured air installation there are only 7 minutes in which to execute a proper sequence of actions, whereas in
Z.S. Hippe/Knowledge-Based Systems 9 (1996) 509–515
513
Fig. 3. An example knowledge base, automatically developed by the computer, for identification of selected substructures (here: methyl group, ester bond, and ether bond). The type and number of substructures, selected for identification, may be arbitrarily set in the experiment. The meaning of subsequent parts of the base (a, b, c, d, e, and f) are discussed in the text.
the case of a lack of cooling water the plant controller has only 1 minute to stop the production and exhaust the installation from unused chemicals; here also, a given sequence of actions must be completed in the specified time. The SCANKEE system is able to control the entire installation, or it may be used to increase the skill and experience of plant controllers. It should be emphasized that in any complex industrial objects (or industrial organizations, like an electric power network) such people must have their welltrained substitutes; moreover, industrial objects of large complexity must be independent on typical problems issued by the staff itself, like opposition, incompetence, retirements, absence (justified, not justified), illnesses, etc. The system was tested using a very large knowledge base containing roughly 1650 production rules describing 120 dif-
ferent cases of malfunctioning of the CS 2 installation, simulated by means of knowledge vectors and ‘‘correct’’ production rules. Additionally, many other rules have been prepared with intentionally incorrect answers, or not meaningful answers, to simulate a broad spectrum of situations for the trained personnel. The training procedure of plant controllers was executed at various levels. At the lowest level, frames (representing knowledge about a general layout of the installation) having their slots loaded with knowledge images (pictorial representation of fine details, like valves, measuring and controlling devices, their location, and comments about their required state) were used. At the next, more advanced level of training, some questions are randomly generated, connected with finding causes of various malfunctions (intentionally or randomly selected).
Z.S. Hippe/Knowledge-Based Systems 9 (1996) 509–515
514
At this very moment, the inference engine of the system begins to use in a single inferential process a combination of knowledge vectors and knowledge images, derived – using chemical nomenclature – ‘‘in statu nascendi’’. After correct location of the fault and its reason(s), the last level of training is executed. Now, the system generates a series of questions leading to the correct behaviour of the plant controller in a given situation. Clearly, the third formalism of knowledge representation (plain language production rules) is now added to the existing combination of knowledge vectors and knowledge images). In any case, when the answer(s) submitted by the plant controller being trained was (were) not in accordance with the simulated situation, the inference engine displays information about mistakes made. Somewhat more sophisticated possibilities are available for examining the skill, expertise and readiness of the plant controllers in performing their duties. In that case a special mechanism, triggered by a keyword TIME, is set forward; the consultation (learning) is executed in time domain, thus the user may get a hint, whether or not his/ her behaviour in a given situation displays the required speed. It was found that application of the system in training of reserved personnel, in this extremely complex real-world problem, was very successful: the time and cost of training have been distinctly decreased. 3.3. Case 3 In this research, the MLC module (Multistrategy Learning Classifier) has been applied to solve some problems of car tyres production.2 Essentially, the research was performed in accordance with the following general schemes: 1. (forward chaining) given: physical/chemical composition of materials and parameters of the process searched: what type of product will be obtained, in sense of its properties? Or 2. (backward chaining) given: required product with specified properties searched: how should we combine components (qualitatively and qualitatively), and how parameters of the technological process should be fixed? Additional experiments have shown that of paramount importance for problem-solving in computer-assisted engineering of materials is application of a very powerful visualization procedure, embedded in the MLC. Namely, this procedure allows for fast and reliable projection of multidimensional solution space (up to 300 dimensions) on a two-dimensional plane. Inspection of that plane (for a given experiment) gives a better insight into the location 2 Detailed results obtained in our research, at the request of cooperating companies, have been kept confidential.
Fig. 4. Examples of application of the visualization procedure, casting a multidimensional solution space on to a two-dimensional plane: (a) location (successful) of the searched instance among similar cases, stored in the knowledge base; (b) location of the searched instance (in this case a product of a given technology), at some distance from a cluster of neighbours; clearly, the knowledge base cannot be used for prediction; (c) location (successful) of the searched instance using linear machine classification. In all cases, the unknown pattern is denoted by x.
of data in the space, and thus into the expected quality of classification or prediction (see Fig. 4).
4. Conclusions Based on literally hundreds of tests performed, in which all modules described in Section 2 were involved, it was found that the general concept of the system organized around loosely related modules working on a common
Z.S. Hippe/Knowledge-Based Systems 9 (1996) 509–515
knowledge base seemed to be quite successful. In fact, the user has an unrestricted possibility to select the most suitable module(s) for knowledge representation, best matched to the problem being solved. Additionally, the research carried out has proved the finding that the hybridization of various ways of knowledge representation, both in acquiring knowledge and in processing it, provides more reliable results in all sub-domains mentioned in the Introduction.
5. Limitations: future work It was found, during the exploitation of Module 3 (multistrategy learning classifier), that this formally most promising research tool for natural sciences (prediction of properties of materials and/or substances) gained a much lower acceptance by many industrial and academic users than expected a priori. This fact is probably a result of the capability of the module to treat only numeric – except symbolic – data. Also, in many real-world cases, such machine learning tools should display the ability to accept missing data (up to roughly 15%). Future work devoted to development of the system will certainly be focused on the removal of the above-mentioned weaknesses.
Acknowledgements Preparation of this paper was possible owing to the excellent job done by my coworkers: Dr B. De˛bska, M.Sc. M. Mazur, Dr G. Fic and D. Nowak. Dr B. Guzowska-S´wider coordinated the design of spectral bases used in the research. Also, the financial support from the State Committee for
515
Scientific Research (Warsaw) for research project No. 8 8308 92 03 (first part of our research) and research project No. 8 T11C 004 09 (second part of our research) is greatly acknowledged.
References [1] N. Otsu, Toward flexible intelligence: MITT’s new program of real world computing, Proceedings of the 13th International Joint Conference on Artificial Intelligence, Vol. 1, Chambery, 1993, pp. 786–791. [2] H. Kitano, Challenges of massive parallelism, Proceedings of the 13th International Joint Conference on Artificial Intelligence, Vol. 1, Chambery, 1993, pp. 813–834. [3] Z.S. Hippe, Intelligent Information System for Knowledge Processing in Natural Sciences Domain, in: M. Da˛browski, Z. Ras´ (Eds.), Intelligent Information Systems, Polish Academy of Sciences, Warsaw, 1994, pp. 179–187. [4] Z.S. Hippe, B. De˛bska, M. Mazur, New programming tool for realworld applications of CAE in industry, in: K.E. Oczos´, H. Ostholt (Eds.), CAE Techniques, University of Technology Editorial Office, Rzeszo´w, 1994, pp. 321–328. [5] B. Guzowska-S´wider, Z.S. Hippe, Structure elucidation of organic compounds aided by the computer program system SCANNET, Journal of Molecular Structure 275 (1992) 225. [6] B. De˛bska, Methodology and programming tool for computer-aided structural identification of organic compounds, Ph.D.-B, University of Technology Editorial Office, Rzeszo´w, 1994 (in Polish). [7] Z.S. Hippe, G. Fic, G. Nowak, Representation of common sense in chemical syntheses by means of molecular graphs, Foundations of Computing and Decision Science 19 (1994) 21–31. [8] Z.S. Hippe, Artificial Intelligence in Chemistry: Structure Elucidation and Simulation of Organic Reactions, PWN/Elsevier, Amsterdam, 1991, p. 39. [9] R.K. Lindsay, G.B. Buchanan, E.A. Feigenbaum, J. Lederberg, Application of Artificial Intelligence for Organic Chemistry: The Dendral Project, McGraw-Hill, New York, 1980.