Lecture Notes in Artificial Intelligence Subseries of Lecture Notes in Computer Science Edited by J. G. Carbonell and J. Siekmann
Lecture Notes in Computer Science Edited by G. Goos, J. Hartmanis and J. van Leeuwen
1453
Marie-Laure Mugnier Michel Chein (Eds.)
Conceptual Structures" Theory, Tools and Applications 6th International Conference on Conceptual Structures, ICCS'98 Montpellier, France, August 10-12, 1998 Proceedings
Springer
Series Editors Jaime G. Carbonell, Carnegie Mellon University, Pittsburgh, PA, USA J/~rg Siekmann, University of Saarland, Saarbriiclen, Germany
Volume Editors Marie-Laure Mugnier Michel Chein LIRMM 161 rue Ada, F-34392 Montpellier Cede~ 5, France E-mail: {mugnier, chein} @lirmm.fr Cataloging-in-Publication Data applied for
Die Deutsche Bibliothek - CIP-Einheitsaufnahme Conceptual structures : theory, tools and applications ; proceedings / 6th International Conference on Conceptual Structures, ICCS '98, Montpellier, France, August 10 - 14, 1998. Marie-Lanre Muguier ; Michel Chein (ed.). - Berlin ; Heidelberg ; New York ; Barcelona ; Budapest ; Hong Kong ; London ; Milan ; Paris ; Singapore ; Tokyo : Springer, 1998 (Lecture notes in computer science ; Vol. 1453 : Lecture notes in artificial intelligence) ISBN 3-540-64791-0
CR Subject Classification (1991): 1.2, G.2.2, E4.1, E2 ISBN 3-540-64791-0 Springer-Verlag Berlin Heidelberg New York This work is subject to copyright. All rights are reserved, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, re-use of illustrations, recitation, broadcasting, reproduction on microfilms or in any other way, and storage in data banks. Duplication of this publication or parts thereof is permitted only under the provisions of the German Copyright Law of September 9, 1965, in its current version, and permission for use must always be obtained from Springer-Verlag. Violations are liable for prosecution under the German Copyright Law. 9 Springer-Verlag Berlin Heidelberg 1998 Printed in Germany Typesetting: Camera ready by author SPIN 10638203 06/3142 - 5 4 3 2 1 0
Printed on acid-free paper
In memory of our colleague and friend, Jean Fargues
Preface Since 1993 the International Conference on Conceptual Structures (ICCS) has been the primary forum for reporting progress in conceptual structures research with main emphasis on conceptual graphs. Conceptual graphs are a knowed~e representation model introduced by John F. Sowa in 1984, stemming from ~emantic networks and the existential graphs of C.S. Peirce. The formal aspects have two mathematical bases, logic and graph theory. Conceptual graphs are used in several domains, such as natural language processing, knowledge based systems, knowledge engineering and database design, among others. Research teams around the world have developed a sizeable software base and have built applications upon it. These last years, ICCS conferences have expanded to other knowledge representation formalisms having relationships with conceptual graphs. Our desire for ICCS'98 was to develop this trend. The call for papers, the composition of the editorial board and of the program committee, and the choice of the invited speakers were guided by the desire to broaden the range of the conference. We firmly believe that efforts must be strengthened to bring the conceptual graphs community and the knowledge representation community closer. These proceedings gather 30 papers (20 long papers and 10 research notes), carefully selected from 66 proposals presented at the sixth International Conference on Conceptual Structures, held in the city of Montpellier, France. These papers are broadly classified into the following categories: knowledge representation and knowledge engineering, tools, conceptual graphs and other formalisms, relationships with logics, algorithms and complexity, epistemology and ontologies, natural language processing, applications. It is a pleasure to thank the invited speakers, Franz Baader, Daniel Kayser, and John F. Sowa for accepting our invitation to give talks and to contribute papers to the proceedings. We thank the authors, the editorial board, the program committee, and the auxiliary reviewers, for making this book, result of their cooperative work, a valuable contribution in the knowledge representation research field. Very special thanks are due to Eric Salvat, who spared no effort to make this conference a success (among his numerous activities for ICCS'98, he realized our Web site). Finally, on behalf of the organizing committee, we thank the institutions that contributed to this conference: AFIA (French Association of AI), CNRS (National Center of Scientific Research), INRIA (National Institute of Automatics and Informatics), LIRMM (Laboratory of Informatics, Robotics, and Microelectronics of Montpellier), Universit~ Montpellier 2, District de Montpellier, R6gion Languedoc-Roussillon. Montpellier, August 1998 Michel CHEIN and Marie-Laure MUGNIER
Organizing
Committee
H o n o r a r y Chair John F. Sowa
SUNY at Binghamton, USA
General Chair Michel Chein
LIRMM, Universitd Montpellier 2, France
P r o g r a m Chair Marie-Laure Mugnier
LIRMM, Universitd Montpellier 2, France
Publicity Chair Eric Salvat
LIRMM, Universitd Montpellier 2, France
Local A r r a n g e m e n t s Rose Dieng David Genest Pascal Jappy Corine Zicler
INRIA Sophia Antipolis, France LIRMM, Universitd Montpellier 2, France LIRMM, Universitd Montpellier 2, France LIRMM, Universit@ Montpellier 2, France
Editorial Board Brian Gaines Fritz Lehmann Dickson Lukose Guy Mineau Leroy Searle Stefano Spaccapietra Rudolf Wille Program
The University of Calgary, Canada Cycorp, USA The University of New England, Australia Universitd Laval, Canada University of Washington, USA Swiss Federal Institute of Technology, Switzerland Technische Universit/it Darmstadt, Germany
Committee
Harmen van den Berg Jean Bdzivin Bernard Botella Marc Champesme Peter Creasy Walling R. Cyre Harry S. Delugach Judy Dick Rose Dieng Peter Eklund Gerard Ellis Bruno Emond John Esch Norman Foo
Telematics Research Centre, The Netherlands Univ. de Nantes, France Dassault Electronique, St-Cloud, France Univ. Paris-Nord, France Univ. of Queensland, Australia Virginia Polytechnic Inst. & Sate Univ., USA Univ. of Alabama in Hunstville, USA ActE, Toronto, Canada INRIA Sophia Antipolis, France Griffith Univ., Australia Peirce Holdings International, Australia Univ. du Qudbec ~ Hull, Canada Lockheed Martin, USA Univ. of New South Wales, Australia
Christophe Fouquerd Brian Garner Robert Godin Michel Habib Ollivier Haemmerld Roger Hartley Mary Keeler Robert Kremer Michel Lecl6re Maurizio Lenzerini Robert Levinson Bernard Levrat Graham A. Mann Rokia Missaoui Jens-Uwe Moeller Bernard Moulin Maurice Pagnucco Mike P. Papazoglou Heike Petermann Heather Pfeiffer Daniel Rochowiak Genevieve Simonet Rudi Studer Gerd Stumme William Tepfenhart Eric Tsui Michel Wermelinger Mark Willems Vilas Wuwongse Pierre Zweigenbaum External
Univ. Paris-Nord, France Deakin Univ., Australia Univ. du Qudbec ~ Montrdal, Canada Univ. MontpeUier 2, France INAPG, Paris, France New Mexico State Univ., Las Cruces, USA Univ. of Washington, USA Univ. of Calgary, Canada Univ. de Nantes, France Univ. degli Studi Di Roma "La Sapienza", Italy Univ. of California at Santa Cruz, USA Univ. d'Angers, France Univ. of New South Wales, Australia Univ. du Qudbec ~ Montrdal, Canada Univ. of Hamburg, Germany Univ. de Laval, Canada Univ. of New South Wales, Australia Univ. of Tilburg, The Netherlands Univ. Hamburg, Germany New Mexico State Univ., Las Cruces, USA Univ. of Alabama in Huntsville, USA Univ. Montpellier 2, France AIFB, Univ. Karlsruhe, Germany Technische Universit~it Darmstadt, Germany AT&T Research, USA CSC Financial Services Group & Univ. of Sydney Univ. Nova de Lisboa, Portugal Cycorp, USA Asian Institute of Technology, Thailand DIAM, SIM/AP-HP & Univ. Paris 6, France
Referees
Tassadit Amghar Pierre Brezellec Steve R. Callaghan Tru H. Cao Alexander Friedmann
David Genest Gwen Kerdiles Thdr~se Libourel Stdphane Loisean Lhouari Nourine
Abdellatif Obaid Eric Salvat Henry Soldano Guy Tremblay
Table of c o n t e n t s
Invited Talks Conceptual Graph Standard and Extensions . . . . . . . . . . . . . . .
John F. Sowa Matching in Description Logics: Preliminary Results . . . . . . . . . . Franz Baader, Alex Borgida, Deborah L. McGuinness Ontologically, Yours . . . . . . . . . . . . . . . . . . . . . . . . . . . . Daniel Kayser
3
15 35
Knowledge Representation and Knowledge Engineering Executing Conceptual Graphs . . . . . . . . . . . . . . . . . . . . . . . Walling R. Cyre From Actors to Processes: The Representation of Dynamic Knowledge Using Conceptual Graphs . . . . . . . . . . . . . . . . . . . . . . Guy W. Mineau A Semantic Validation of Conceptual Graphs . . . . . . . . . . . . . . Juliette Dibie, Ollivier Haemmerld, St~phane Loiseau Using Viewpoints and CG for the Representation and Management of a Corporate Memory in Concurrent Engineering . . . . . . . . . Myriam Ribi~re
51
65 80
94
Tools WebKB-GE
- A Visual Editor for Canonical Conceptual Graphs
(Research Note)
............................
Simon Pollitt, Andrew Burrow, Peter W. Eklund Mapping of CGIF to Operational Interfaces (Research Note) . . . . . . Arno Puder TOSCANA-Systems Based on Thesauri . . . . . . . . . . . . . . . . . Bernd Groh, Selma Strahringer, Rudolf Wille MULTIKAT, a Tool for Comparing Knowledge of Multiple E x p e r t s . . Rose Dieng, Stefan Hug A Platform Allowing Typed Nested Graphs: How CoGITo Became CoGITaNT (Research Note) . . . . . . . . . . . . . . . . . . . . . . David Genest, Eric Salvat
111
119 127 139
154
Conceptual Graphs and Other Models Towards Correspondences between Conceptual Graphs and Description Logics. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Pascal Coupey, Catherine Faron
165
• Piece Resolution: Towards Larger Perspectives . . . . . . . . . . . . . Stgphane Coulondre, Eric Salvat Triadic Concept Graphs . . . . . . . . . . . . . . . . . . . . . . . . . . Rudolf Wille Powerset Trilattices . . . . . . . . . . . . . . . . . . . . . . . . . . . . Klaus Biedermann
179 194 209
Relationships with Logics Simple Concept Graphs: A Logic Approach . . . . . . . . . . . . . . . Susanne Prediger Two FOL Semantics for Simple and Nested Conceptual Graphs . . . . Genevieve Simonet Peircean Graphs for the Modal Logic $5 . . . . . . . . . . . . . . . . . Torben Braiiner Fuzzy Order-Sorted Logic Programming in Conceptual Graphs with a Sound and Complete Proof Procedure . . . . . . . . . . . . . . . Tru H. Cao, Peter N. Crcasy
225 240 255
270
Algorithms and Complexity Knowledge Querying in the Conceptual Graph Model: The RAP Module (Research Note) . . . . . . . . . . . . . . . . . . 287 Olivier Guinaldo, Ollivier Haemmerld Stepwise Construction of the Dedekind-MacNeille Completion (Research Note) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295 Bernhard Ganter, Sergei O. Kuznetsov PAC Learning Conceptual Graphs . . . . . . . . . . . . . . . . . . . . 303 Pascal Jappy, Richard Nock
Epistemology and Ontologies Procedural Renunciation and the Semi-automatic Trap . . . . . . . . . Graham A. Mann Ontologies and Conceptual Structures . . . . . . . . . . . . . . . . . . William M. Tepfenhart
319 334
Natural Language Processing Manual Acquisition of Uncountable Types in Closed Worlds (Research Note) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351 Galia Angelova A Logical Framework for Modeling a Discourse from the Point of View of the Agents Involved in It (Research Note) . . . . . . . . . . . . 359 Bernard Moulin Computational Processing of Verbal Polysemy with Conceptual Structures (Research Note) . . . . . . . . . . . . . . . . . . . . . . 367 Karim Chibout, Anne Vilnat
XIII
Word Graphs: The Second Set . . . . . . . . . . . . . . . . . . . . . . C. Hoede, X. Liu Tuning Up Conceptual Graph Representation for Multilingual Natural Language Processing in Medicine (Research Note) . . . . . . . . . Anne-Marie Rassinoux, Robert H. Baud, Christian Lovis, Judith C. Wagner, Jean-Raoul Scherrer
375
390
Applications
Conceptual Graphs for Representing Business Processes in Corporate Memories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 401 Olivier Gerbg, Rudolf K. Keller, Guy W. Mine-au Handling Specification Knowledge Evolution Using Context Lattices 416 Aldo de Moor, Guy W. Mineau Using CG Formal Contexts to Support Business System Interoperations (Research Note) . . . . . . . . . . . . . . . . . . . . . . . . . 431 Hung Wing, Robert M. Colomb, Guy W. Mineau A u t h o r Index
439
Conceptual Graph Standard and Extensions John F. Sowa
Abstract. The proposed ANSI standard for conceptual graphs codifies the basic core that has formed the basis for most CG implementations since 1984. Standards are essential for building and sharing development tools and for supporting commercial applications. But the CG community has traditionally been a coalition of researchers who have been actively extending conceptual graphs with a variety of experimental features that often go far beyond the core and are sometimes incompatible with it. This paper discusses the recently developed CG standard and its approach to standardizing the CG core while allowing innovative extensions. 1 Accommodating Standardization and Innovation A draft proposed ANSI standard (dpANS) for conceptual graphs has been developed by the NCITS T2 Committee on Information Interchange and Interpretation. It is now being circulated for comments and approval; barring unforeseen difficulties, it should be approved before the end of 1998. The dpANS is based on the original CG syntax and semantics (Sowa 1984) with some extensions and modifications that have been requested or suggested by the community of CG users and implementers. But the number of possible extensions and modifications is greater than can be accommodated by tile 1998 CG standard. This conference is the sixth in a series of International Conferences on Conceptual Structures (ICCS), which have followed seven annual workshops on conceptual graphs. Thrcc journals, publishcd in the U.S., U.K., and Francc, devotcd spccial issues to papers on conceptual graphs (Way 1992, Sowa 1992, Chcin 1996). Many of the papcrs in thesc confcrcnccs and journals have prcscntcd ncw ways of using thc basic features of conceptual graphs, but others have developed novel extensions to the syntax and semantics. Growth and change are inevitable and cssential in any language or system that is widely used, but practical applications require a stable platform. The stability of the CG core is ensured by the generality of first-order logic (FOL). Frege (1879) and Peirce (1885) independently developed equivalent versions of FOL, even though they had no knowledge of each other's work and they used widely divergent notations. Since then, first-order logic has proved to be a solid foundation that is gencral enough to describe and represent anything that can be computcd by any digital computer, including the computer itself. By ensuring that the common core of CGs is gcneral enough to represent classical first-order logic, its generality is ensured. To promote interoperability with other computer systems, the CG standard has been developed in parallel with the proposed ANSI standard for the Knowledge Interchange Format (KIF). Both CGs and KIF express FOL in a form that can bc automatically translated from onc to the other whilc preserving the semantics.
Despite the generality of classical FOL, there are many reasons why people who use a knowledge representation language may want to diverge from FOL: 9
The traditional algebraic notation for predicate calculus, which is based on Peirce's notation of 1885 with a change of symbols by Giuseppe Peano, has been widely criticized as unreadable. Peirce himself later developed a graph notation, which he believed was a "more iconic" representation for "the atoms and molecules of logic." Conceptual graphs, which are based on Peirce's graphs, are more readable than predicate calculus for many applications. But there is an infinite number of ways in which logical notations can be specialized or tailored to an application, especially when a graphical display is available.
9
C o m p u t a b i l i t y . Theorem proving in full FOL can often take an cxponcntial amount of time. Many variations of logic restrict the expressibility so that only cfficiently computable problems can be expressed. Such restrictions can be accommodated in any notation for FOL by stating constraints on the combinations of operators that may be used. An example is the Horn-clause subset used in Prolog, which does not allow disjunctions in the conclusion of an implication. Such constraints can be imposed on CGs in the same way they are imposed on the algebraic notations.
9
Convenience. Many extensions to the logical notations make them more convcnient for expressing certain frequently occurring features. Such extensions can be accommodated by definitional facilities that allow new symbols to be defined by combinations of the old symbols.
9
Surprises. Although logic can express anything that can be computed, it cannot express exceptions that are unknown or unknowable to the person who is using it. Computer input/output facilities are a primary source of "surprises" that cannot bc anticipated by a programmer or other computer user.
e
C o n t e x t dependence. Natural languages are often more concise than formal languages because they omit much of the information that can be inferred from the context. Linguists have been analyzing and codifying the ways that languages use context-dependent information, but the complete specification of those methods remains an active area of research.
9
Because of its generality, first-order logic can be used as a metalanguage to define new kinds of logics that go beyond FOL. By quantifying over predicates or relations, for example, higher-order logic (HOL) can summarize in one statement an infinite number of first-order statements.
Readability.
E x t e n d e d logics.
These issues have been actively explored in the past dozen years of CG workshops and conferences, and many different approaches to them have been suggested, implemented, and published. To accommodate innovation while standardizing the core, the dpANS for CGs defines the syntax and semantics of those features that are based on wellunderstood logical principles. That includes all of classical first-order logic and some extensions, such as the use of FOL at the metalevel and the ability to quantify over relations for HOL. These are the same features that are defined in the dpANS for KIF. To accommodate the open-ended research areas, the
dpANS for CGs also defines syntax for certain features whose semantics have not yet been standardized; those features include the surprises and context dependencies. The dpANS gives a formal specification for the conceptual graph interchange format (CGIF), which is designed for communication between computer systems. To allow further experimentation with the syntax designed for human readability, the methods for displaying CGs to humans are suggested as informal guidelines rather than normative standards. The semantics of those displays is determined by their mapping to CGIF and KIF.
2 Actors Functions are relations that behave like one-way streets in guiding a computation. In graphic form, they correspond to dataflow diagrams, which have a preferred directionality. By definition, a function is a relation that has one argument called the output, which has a single value for each combination of values of the other arguments, called the inputs. In conceptual graphs, the output concept of a function is attached to its last arc, whose arrow points away from the circle. I f f is a function from type TI to type T2, the constraint of a single output for each input can be stated by an axiom in a conceptual graph or predicate calculus:
IT1: ~-,-b')-,-T2:
~)q.
(Vx:T I)(q~:T2)y= f(x). Both the graph and the formula say that for every input of type T 1, f h a s exactly one output (3!y) of type T2. Since the distinction between functions and other relations is important for many applications, it is useful to have a special notation that marks a relation as a function. In Figure 1, the diamond nodes indicate that the relations Sum, Pred, and CS2N are functional.
Number:?a~
r .... , :~um//~'lNumber
l..mber:
?b~'~'"/
String: ?e ~
I~>/~
,
<,~.~/~1 Number
Number: "x
'/'r
Figure 1. A datallow diagramwith functionalrelations The variables ?a, ?b, and ?c are inputs that refer to concept nodes on other graphs. The output variable *x marks a defining node that could be referenced elsewhere by ?x. The functions Sum and Prod each take two numbers as input and generate one number as output. The function CS2N converts a character string input to a number as output. Figure 1 could be mapped to the following expression in predicate calculus supplemented with an infix notation for the mathematical operators: x = (a + b)* cs2n(c).
This equation looks like an assignment statement, and it could be translated to one in a conventional programming language. But the converse does not hold: not every assignment statement can be translated to a dataflow diagram. The following assignment statement, for example, could never be interpreted as a true equation for any value of x:
X~-X+
1.
Such assignments, which change the value of a variable, cannot be represented in a dataflow diagram. The programming languages that correspond to dataflow diagrams are called functional. Variables in those languages are not truly variable, since their values can never be modified after their first assignment. For that reason, they are also called single assignment languages. The diamond nodes in dataflow diagrams are called actors. Sowa (1984) proposed them as a computational supplement to the logical inferences performed with conceptual graphs. T h a t approach is similar to the procedural attachments that are implemented in m a n y knowledge representation systems and logic-based theorem provers. M a n y CG implementers have used the actors to represent procedures, database ~relations, and input/output facilities that are outside the C G system. Some of those uses of actors are intended for convenience or efficiency, and they could be replaced by ordinary conceptual relations. Other actors, however, m a y have side effects whose representations are either omitted or unknown. In the d p A N S for CGs, the diamond nodes are defined as synonyms for conceptual relations, but with an additional axiom for every output arc attached to the actor. Let a be an actor with n input arcs and m output arcs (either n or m, but not both m a y be 0). Then a is formally defined as a conceptual relation with n + m arcs which is further specified by axioms that declare each of the outputs to be functionally dependent on the inputs. For each i from l to m, there is an axiom of the following form: ~ x I :T0...(u
!y,:T,) y, = a,(x, ..... x.).
The actor a corresponds to a collection of m functions of the form a~(xl,..., x.). This definition characterizes the purely functional effects of the actors, but it does not represent any side effects that might occur during their execution. Recursive dataflow graphs. Without loops and branches, dataflow diagrams cannot support a complete programming system. But when supplemented with a conditional operator and the ability to call diagrams recursively, they form the basis for a language that can specify any computable function. Only three control mechanisms are needed for a complete functional programming language: recursire function definition, function application, and a conditional operator. As an example, Figure 2 shows a conceptual graph for defining the function facto, which computes the factorial x of a nonnegative integer n.
relation Faclo(*n,*x) Is functional I Inleger 2 i~,, J ~.
,oo,.n L._ Integer: ?x
"lnt er Figure 2. Using a dataflow graph to define a recursive function The relation Subl subtracts 1 from its input; it corresponds to the function subl in LISP or the decrement operator in C. The conditional relation Cond corresponds to an if-then-else expression or the ternary ?: operator in C. In Figure 2, the first argument of Cond is the truth value of 2 > n; if true, the output of Cond is the second argument 1; otherwise, the output of Cond is the third argument, which results from the recursive call. The keyword Jimctional is a metalanguage abbreviation for the axiom that there exists exactly one output x for every input n. The next three lines show how the conceptual graph would be translated to a lambda expression in predicate calculus, a function in C, and a function in LISP: *
Predicate calculus, facto = (~n:Integer)cond(2 > n, I, n'facto(n- I)).
,
C. int facto(int n) { return ((2 > n) ? 1 : n'facto(--n)); }
9
LISP. (defun facto (n) ( i f ( > 2 n) I (* n (facto (subl n)))))
These translations illustrate the equivalence between a specification in logic and a purely functional specification in a programming language. For convenience, efficiency, and the ability to control multiple processes, languages like C and LISP support many other features, but the functional mechanisms alone are sufficient to simulate a Turing machine. For parallel machines, functional languages can often achieve higher efficiency than conventional languages because all the dependencies are specified before compile time; no surprises can occur that would interrupt the parallel processes. Sowa (1984) also defined token-passing methods for evaluating the actors in dataflow diagrams. A question mark was used to trigger a backward-chaining or lazy method of evaluating dataflow diagrams, and an exclamation mark was used to trigger a forward-chaining or eager method of evaluation. Those methods of evaluation are not specified in the dpANS for conceptual graphs.
3 lndexicals An important feature of Peirce's logical graphs is their explicit marking of contexts, which map directly to the way contexts are represented in natural languages. Peirce also coined the term indexical for context-dependent references, such as pronouns and words like here, there, and now. In CGs, the symbol # represents the general indexical, which is usually expressed by the definite article the. More specific indexicals are marked by a qualifier after the # symbol, as in #here, #now, #he, #she, or #it. Figure 3 shows two conceptual graphs for the sentence I f a farmer owns a donkey, then he beats it. The CG on the left represents the original pronouns with indexicals, and the one on the right replaces the indexicals with the coreference labels ?x and ?y.
CG with Indexlcals
Figure 3.
CO with Indexicals resolved
Two conceptual graphs for "If a farmer owns a donkey, then he heats it."
In the concept Animate: #he, the label Animate indicates the semantic type, and the indexical #he indicates that the referent must be found by a search for some type of Animate entity for which the masculine gender is applicable. In the concept Entity: #it, the label Entity is synonymous with T, which may represent anything, and the indexical #it indicates that the referent has neuter gender. The search for referents starts in the inner context and proceeds outward to find concepts of an appropriate type and gender. The CG on the right of Figure 3 shows the result of resolving the indexicals: the concept for he has been replaced by ?x to show a coreference to the farmer, and the concept for it has been replaced by ?y to show a coreference to the donkey. Predicate calculus does not have a notation for indexicals, and its syntax does not show the context structure explicitly. Therefore, the CG on the left of Figure 3 cannot be translated directly to predicate calculus. After the indexicals have been resolved, the CG on the right can be translated to the following formula: fix: Farmer)(VyDonkey)0/z:Own) (expr(z,x) ^ thme(zd0) (3w:Beat)(agnt(w,x) ^ ptnt(w,y))). The dpANS for conceptual graphs specifies # as the syntactic marker for indexicals, but it does not define their semantics, the rules for resolving them to their referents, or their translation to predicate calculus and KIF. It allows CGs with indexicals to be sent between different CG systems, but their semantics is left undefined.
The complete determination of all the rules for resolving indexicals is still an active area of research in linguistics and logic. As an example, consider the sentence You can lead a horse to water, but you can't m a k e him drink. The first step would be the generation of a logical form with indexicals, such as the CG in Figure 4, which may be read literally It is possible (Psbl) f o r you to lead a horse to water, but it is not possible ( -" Psbl) f o r you to cause him to drink the liquid. The relation -" Psbl is defined as a combination of -- and Psbl: relation -'Psbl(*p) Js -Proposition: (Psbl)§
?p.
-f-ropos.~n: Proposition: Poreon: #you ~
Proposition: Proposition: I Pemon:~ou
Figure 4. CG for "Youcan leada horseto water,but you can't makehim drink." A parser and semantic interpreter that did a purely local or context-free analysis of the English sentence could generate the four concepts marked as indexicais by # symbols in Figure 4: ,
The two occurrences of you would map to the two concepts of the form Person: #you.
e
The pronoun him represents a masculine animate indexical in the objective case, whose concept is Animate: #he.
9 The missing object of the verb drink is presupposed by the concept type Drink, which requires a patient of type Liquid. The implicit concept Liquid: # is marked as an indexical, so that the exact referent can be determined from the context. The indexicals would have to be resolved by a context-dependent search, proceeding outward from the context in which each indexical is nested.
10 Conversational implicatures. Sometimes no suitable referent for an indexical can be found. In such a case, the person who hears or reads the sentence must make further assumptions about implicit referents. The philosopher Paul Grice (1975) observed that such assumptions, called conversational implicatures, are often necessary to make sense out of the sentences in ordinary language. They are justified by the charitable assumption that the speaker or writer is trying to make a meaningful statement, but for the sake of brevity, m a y leave some background information unspoken. To resolve the indexicals in Figure 4, the listener would have to make the following kinds of assumptions to fill in the missing information: 1. The two concepts of the form Person: #you would normally be resolved to the listener or reader of the sentence. Since no one is explicitly mentioned in any containing context, some such person must be assumed. T h a t assumption corresponds to drawing an if-then nest of contexts with a hypothetical reader x coreferent with you:
If:
Person: *x....
- -Person:
/you
Then:
The entire graph in Figure 4 would be inserted in place of the three dots in the then part, and every occurrence of #you would be replaced by ?x. The resulting graph could be read l f there exists a person x, then x can lead a horse to water, but x can't make him drink the liquid. 2. The concept Animate: #he might be resolved to either a human or a beast. Since the reader is referred to as you, the most likely referent is the horse. But in both C G s and DRSs, coreference links can only be drawn between concepts under one of the following conditions: * The antecedent concept Horse cur in the same context. .
and the indexical Animate: #he both oc-
The antecedent occurs in a context that includes the context of the indexical.
In Figure 4, neither of these conditions holds. To make the second condition true, the antecedent Horse can be exported or lifted to some containing context, such as the context of the hypothetical reader x. This assumption has the effect of treating the horse as hypothetical as the person x. After a coreference label is assigned to the concept Horse: *y, the indexical #he could be replaced by ?y. 3. The liquid, which had to be assumed to make sense of the verb drink, might be coreferent with the water. But in order to draw a corefercnce link, another assumption must be made to lilt the antecedent concept Water: *z to the same hypothetical context as the reader and the horse. Then the concept Liquid: # would become Liquid: ?z. The result would be the following CG with all indexicals resolved:
11
If: Person: *x Horse: *y Water: *z Then: Proposi t| on: (Psbl)§ Person: ?x§ (Thme)§ ?y (Dest)§ Proposi ti on:
?z §
(~Psbl)§ t ion: Person: ?x § (Rsl t)§ tuation: Animate: ?y§247247247
§ ?z
.
This CG may be read I f there exist a person x, a horse y, and water z, then the person x can lead the horse y to water z, but the person x can't make the animate being y drink the liquid z. Before the indcxicals are resolved, the type labels are needed to match the indexicals to their antecedents. Afterwards, the bound concepts Person: ?x, Horse: ?y, Animate: ?y, Water: ?z, and Liquid: ?z could be simplified to just ~, ~, or ?z. As this example illustrates, indexicals occur in the intermediate stage of translating language to logic, and their correct resolution may require nontrivial assumptions. Many programs in AI and computational linguistics follow rules of discourse representation to resolve indexicals. The problem of making the correct assumptions about conversational implicatures is more difficult. The kinds of assumptions needed to understand ordinary conversation are similar to the assumptions that are made in nonmonotonic reasoning. Both of them depend partly on context-independent rules of logic and partly on context-dependent background knowledge.
4 Metalevel and Higher-Order Logic Mctalcvcl reasoning can bc treated as first-order rcasoning with the object-level language as part of the domain of discourse. As an example, consider the sentence The greater-than relation is transitive. That sentence uses English as a metalanguage for talking about logic, it could bc translated to the following CG:
Relation: greaterThan§ (Attr) § This metalevel CG talks about some attribute (Attr) of a relation. At the object level, that attribute implies an axiom of a particular form about how the greaterThan relation may be used. The translation from the metalevel to the object level can be specified by the metametalevel CG in Figure 5.
12
If:
i Relation:"r ~
Transitive I
If:
IT'n:
Then:
Figure 5.
Metametalevel CG
mapping from the metalevel to the object level
The If-part of Figure 5 is the following conceptual graph, written in the linear notation:
Relation: *r§247
t| ve.
This graph matches the previous CG, with the variable *r matching the name greaterThan. The Then-part of Figure 5 is another If-Then rule, which contains conceptual relations whose label is pr. The Greek letter p represents an operator that maps a name like greaterThan to a label of a conceptual relation. The following statement defines the symbol > as the value of p when applied to the name greaterThan:
pgreaterThan = '>' With this definition, the If-Then rule in Figure 5 would generate the conclusion in Figure 6.
If:
Then: ~
Figure 6.
I
Object-level CG derived by applying the rule in Figure 5 to the CG in Figure 7.18
The If-Then rule in Figure 6 is the axiom that defines what it means for the greaterThan relation to be transitive. In English, Figure 6 may be read, I f x is greater than y and y is greater than z, then x is greater than z. The symbols *x, *y, and *z in the IF-part of Figure 6 represent the defining occurrences of the
13 variables x, y, and z. The symbols ?x and ?z in the Then-part represent references back to the defining occurrences. KIF uses the same form ?x, ?y, and ?z for both the defining occurrences and the repeated references. Following is the KIF form of Figure 6:
(-> (and (> ?x ?y) (> ?y ?z)) (- ?x ?z) ) As these examples illustrate, conceptual graphs and KIF can be used like E-R diagrams to represent metalevel information. But they can also state something that no E-R diagram ever could: the object-level axiom for transitivity in Figure 6. Furthermore, they can even state metametarules like Figure 5, which map from the metalevel to the object level. With such power, CGs and KIF can be used as the object language, the metalanguage, or even the metametalanguage. In fact, they can be used at a potentially infinite number of levels. $ Pictures as Literals Figure 7 shows a concept of type Situation, which is linked by two image relations (Imag) to two different kinds of images of that situation: a picture and the assoc i a t ~ sound. The description relation (Dscr) links the situation to a proposition that describes some aspect of it. It is equivalent to the entailment operator, x I=p, which means that p is a true proposition about x. The proposition is linked by three statement relations (Strut) to statements of the proposition in three different languages: an English sentence, a conceptual graph, and a formula in the Knowledge Representation Language (KIF). As the diagram illustrates, the sound image and the picture image capture information that is not stated in the propositional forms, but even they are only partial representations. S..auo.
' plmum:
/
CLAMKETu
scra,e
/
/
-
I I~Y
I
Figure 7. A CG representing a situation of a plumber carrying a pipe
14 The sound and the picture, which are displayed graphically in Figure 7, would be stored in some conventional representation, such as a GIF or JPEG file. The CG could be mapped to the following formula in predicate calculus:
(3s:Situation)(3p:Proposition)(3g:CG) (~x:Sound)(3y:Picture)(3z:English )(3w:K IF) (dscr(s,p) ^ imag(s,x) ^ imag(s~v) ^ stored(x,clankety.wav) ^ stored(y,plumber.gif) ^ stmt(p,z) ^ stmt(p~) ^ stmt(p,w) ^ literal(z,"A plumber is carrying a pipe.") ^ literal(g,~Plumber§247247 ") ^ literal(w,O(exists ( ( ~ plumber) (?y carry) (?z pipe)) (and (agnt ~ ~ ) (throe ~ ?z)))")). The stored relation links images to the names of files in which they are stored, and the literal relation links linguistic entities to the character strings used to express them. A multimedia system can display them in any form that is convenient for the users. Those forms, however, are not specified by the dpANS for conceptual graphs. References
Chcin, Michel, ed. (1996) Revue d'Intelligence artificielle, Special Issue on Conceptual Graphs, vol. 10, no. 1. Frege, Gottlob (1879) Begriffsschrift, translated in Jean van Heijenoort, ed. (1967) From Frege to G6del, Harvard University Press, Cambridge, MA, pp. 1-82. Gricc, H. Paul (1975) "Logic and conversation," in P. Cole & J. Morgan, eds., Syntax and Semantics 3: Speech Acts, Academic Press, New York, pp. 41-58. Peirce, Charles Sanders (1885) "On the algebra of logic," American Journal of Mathematics, vol. 7, pp. 180-202. Sowa, John F. (1984) Conceptual Structures: Information Processing in Mind and Machine, Addison-Wesley, Reading, MA. Sowa, John F., ed. (1992) Knowledge-Based Systems, Special Issue on Conceptual Graphs, vol. 5, no. 3, September 1992. Way, Eileen C., ed. (1992) Journal of Experimental and Theoretical Artificial Intelligence (JETAI), Special Issue on Conceptual Graphs, vol. 4, no. 2.
Matching in Description Logics: Preliminary Results Franz Baader 1, Alex Borgida 2, and Deborah L. McGuinness 3 z Theoretical Computer Science, RWTH Aachen, 52074 Aachen, Germany baader@inf ormatik, rwth-aachen, de
2 Dept. of Computer Science, Rutgers University, New Brunswick, N J, USA borgida@c s. rutgers, edu
s Information Systems and Services Research, AT&T Labs - Research Florham Park, N J, USA dim@research, art. tom
Matching of concepts with variables (concept patterns) is a relatively new operation that has been introduced in the context of concept description languages (description logics), originally to help filter out unimportant aspects of large concepts appearing in industrialstrength knowledge bases. This paper proposes a new approach to performing matching, based on a "concept-centered" normal form, rather than the more standard "structural subsumption" normal form for concepts. As a result, matching can be performed (in polynomial time) using arbitrary concept patterns of the description language JrL:_, thus removing restrictions from previous work. The paper also addresses the question of matching problems with additional "side conditions", which were motivated by practical experience. Abstract.
1
Introduction
Knowledge representation systems based on Description Logic Systems (DL systems) can be used to represent the terminological knowledge of an application domain in a structured and formally well-understood way 12, 4, 11, 32, 8. With the help of these languages, the important notions of the domain can be described by concept descriptions, i.e., expressions that are built from atomic concepts (unary predicates) and atomic roles (binary predicates) using the concept constructors provided by the description logic language (DL language) of the system. The atomic concepts and the concept descriptions represent sets of individuals, whereas roles represent binary relations between individuals. For example, using the atomic concept Woman and the atomic role child, the concept of all women having only daughters (i.e., women such that all their children are again women) can be represented by the concept description Woman I-1 Vchild.Woman.
DL systems provide their users with various inference capabilities that allow them to deduce implicit knowledge from the explicitly represented knowledge.
16 For instance, the subsumption algorithm allows one to determine subconceptsuperconcept relationships: C is Subsumed by D (C E D) iff all instances of C are also instances of D, i.e., the first description is always interpreted as a subset of the second description. For example, the concept description Woman obviously subsumes the concept description Woman I-I Vchild.Woman. With the help of the subsumption algorithm, a newly introduced concept description can automatically be placed at the correct position in the hierarchy of the already existing concept descriptions. Two concept descriptions C, D are equivalent (C - D) iff they subsume each other, i.e., if they always represent the same set of individuals. For example, the descriptions Woman FIVchild.Woman and (Vchild.Woman)I-I Woman are equivalent since • is interpreted as set intersection, which is obviously commutative. The traditional inference problems for DL systems (like subsumption) are now well-investigated, which means that algorithms are available for solving the subsumption problem and related inference problems in a great variety of DL languages of differing expressive power (see, e.g., 22, 31, 28, 20, 1, 3, 19, 13, 10, 6, 2, 6, 7). In addition, the computational complexity of these inference problems has been investigated in detail 22, 27, 29, 15, 14, 17, 30, 16. It has turned out, however, that building and maintaining large DL knowledge bases requires support by additional inference capabilities, which have not been considered in the DL literature until very recently. The present paper is concerned with such a new inference service, namely, matching of concept descriptions. Matching of Description Logic concepts was introduced in the CLASSIC system (version 2), under the name of "ilterin', as a technique for specifying which aspects of a concept should be selected for printing or explanation. The need for this facility became apparent when dealing with large knowledge bases, involving concepts whose description spans multiple pages of output: in many cases, such concepts carried details that either were obviously true (e.g., the age of a person is a number) or were intended for some internal function (e.g., graphical display) rather than domain modeling. In either case, both the printing and the explaining of results provided by the more traditional inference services 24, 23 required pruning. In projects using CLASSIC, pruning of the description resulted in concepts that were approximately an order of magnitude smaller. In small applications such as 25, this actually saved 3-5 pages of printout; in larger applications such as 33, 26 it might save up to 30 pages. This pruning mechanism was first formalized 23 as a purely syntactic match involving terms/concepts with variables, and then given a semantics and a syntactic implementation in 9. Given a concept pattern D (i.e., a concept description containing variables) and a concept description C without variables, the matching problem introduced in 9 asks for a substitution a (of the variables by concept descriptions) such that C E a(D). More precisely, one is interested in a "minimal" solution of the matching problem, i.e., a should satisfy the property that there does not exist a substitution (i such that C E 5(D) E a(D). For example, the minimal matcher of the pattern D := Vresearch-interests.X against
17 the description
C := Vpets.Cat I-I Vresearch-interests.Al r-I Vhobbies.Gardening
assigns AI to the variable X, and thus finds the scientific interests (in this case Artificial Intelligence) described in the concept. (The concept pattern can be thought of as a "format statement", describing what information is to be displayed (or explained), if the pattern matches successfully against a specifi, ~.oncept. If there is no match, nothing is displayed.) In some cases, this pruning effect can be improved by imposing additional side conditions on the solutions of matching problems. For example, the information that the research interests lie in the area of Artificial Intelligence may not provide interesting information if our knowledge base is concerned onl) '~ i~, AI researchers. A side condition stating that the solutions for the variable :i must be subsumed by KR would make sure that matching succeeds only if the research interests belong to (a subfield of) Knowledge Representation. Thus, the description C from above no longer matches the pattern D, whereas C I :-- Vpets.Cat 7 Vresearch-interests.DL i-I Vhobbies.Gardening
would still yield a solution (provided that DL is defined by a description that is subsumed by KR). In some cases we would like to have a matching process which succeeds only if the variable X is substituted for by a value that is strictly subsumed by some description (or pattern). The utility of such strict side-conditions might be more clearly seen in an example where the concept Person is known to have Number restrictions on the age attribute, and we are interested in seeing the value restriction for age only if it represents some additional (i.e., stricter) constraint. Another point worth noting is that according to the standard Description Logic semantics, every description is subsumed by all concepts of the form VR.3-, where T denotes the universal concept. Hence the pattern D above (concerning research interests) matches every concept. Side conditions requiring the value substituted for a variable to be strictly subsumed by 3- prevent such "trivial" matches. Matching algorithms for a DL containing most of the constructs available in CLASSIC are introduced in 23 and 9. These algorithms are based on the rolecentered normal form 1 of concept descriptions usually employed by structural subsumption algorithms. The main drawback of these algorithms is that they cannot treat arbitrary matching problems since they require the concept pattern to be in structural normal form. In 5, Baader and Narendran consider unification of concept descriptions in ~-L:0, which allows for conjunction 03), value restriction (VR.C), and the top concept (3-). Matching modulo equivalence, i.e., the question whether, for a given pattern D and a description C, there exists a substitution a such that C __=_a(D), 1 We call this normal form "role-centered" since it groups sub-descriptions by role names, whereas the concept-centered normal form used in this paper groups value restrictions by concept names.
8 can be seen as a special case of unification where One of the descriptions (namely C) does not contain variables. Since C E a(D) iff C = a(C N D), matching modulo subsumption (as introduced above) is an instance of matching modulo equivalence. The polynomial matching algorithm described in 5 does not impose restrictions on the form of the patterns. However, it is restricted to the small language 9r/~0. In the present paper, we show that this algorithm can be extended to treat matching in languages allowing for inconsistent concept descriptions, namely ~-~• which extends ~'~o by the bottom concept (3-), and ~ / ~ , which extends ~'/~• by primitive negation (-~A, where A is an atomic concept). In addition, we consider matching under additional conditions on the variable bindings, which also arose in examples in 25, 23 and were responsible for about 25% of our space savings in our deployed example. In this paper, we consider two different variants of these "side conditions": subsumption conditions and strict subsumption conditions. Subsumption conditions are of the form X _ E, where X is a variable and E is a pattern (i.e., it may contain variables), and they restrict the marchers to substitutions a satisfying a(X) U a(E). It should be noted that such a side condition is not a matching problem since variables may occur on both sides. We shall see, however, that in many cases matching under subsumption conditions can be reduced in polynomial time to matching without subsumption conditions. In contrast, strict subsumption conditions may increase the complexity of the matching problem. Such conditions are of the form X F- E, where X is a variable and E is a pattern, and they restrict the marchers to substitutions a satisfying a ( X ) U a(E) and a ( X ) ~ a(E). We shall show that, even for the small languages ~'/:0, matching under strict subsumption conditions is NP-hard.
2
Formal
preliminaries
In this section, we first introduce syntax and semantics of the description languages considered in this paper. Then, we formally introduce matching problems, and state some simple results about matching problems and their solutions.
Definition 1. Let C and R be disjoint finite sets representing the set of atomic concepts and the set of atomic roles. The set of all 5rs over g and ~ is inductively defined as follows:
descriptions
- Every element of g is a concept description (atomic concept). - The symbols T (top concept} and 3_ (bottom concept} are concept descriptions. If A E g, then -~A is a concept description (atomic negation). - If C and D are concept descriptions, then C tq D is a concept description (concept conjunction). - I / C is a concept description and R E ~ is an atomic role, then VR.C is a concept description (value restriction). -
19 In the sublanguage ~-s of ~c/:., atomic negation and _L may not be used, whereas in ~s177only atomic negation is disallowed. The following definition provides a model-theoretic semantics for ~ . and its sublanguages: D e f i n i t i o n 2. A n interpretation I consists of a nonempty set A I, the domain of the interpretation, and an interpretation function that assigns to every atomic concept A E g a set A I C_ A ~, and to every atomic role R E T r binary relation R I C_ A I • A 1. The interpretation function is extended to complex concept descriptions as follows: TI
:=
A I,
-1-I := O, (-~A) I := A z \ A ~, ( C F I D ) / := C / A D z, (VR.C) I :-- {d 6 AI
Ve 6 At: (d,e) 6 R I --+ e 6 CX}.
Based on this semantics, subsumption and equivalence of concept descriptions is defined as follows: Let C and D be ~'s descriptions. C is subsumed by D (C U D) iff C I C__D x for all interpretations I. C is equivalent to D (C - D) iff C x = D I for all interpretations I. - C is strictly subsumed by D (C U D) iff C ___D and C ~ D.
-
-
In order to define matching of concept descriptions, we must introduce the notion of a concept pattern and of substitutions operating on patterns. For this purpose, we introduce an additional set of symbols A~ (concept variables), which is disjoint from C U 7~. D e f i n i t i o n 3. The set of all ~ s tively defined as follows:
patterns over C, T~, and 2( is induc-
Every concept variable X 6 2( is a pattern. - Every 3:s description over C and T~ is a pattern. If C and D are concept patterns, then C ~ D is a concept pattern. If C is a concept pattern and R 6 T~ is an atomic role, then V R . C is a concept pattern. -
-
-
Thus, concept variables can be used like atomic concepts, with the only difference being that atomic negation may not be applied to variables. A substitution a is a mapping from 2( into the set of all Ys descriptions. This mapping is extended to concept patterns in the obvious way, i.e., -
-
-
-
a(A) := A and a ( ~ A ) := -~A for all A 6 C, a ( T ) := T and a(_l.) := _l_, a ( C N D) := a(C) N a(D), and ~(VR.C) := VR.a(C).
20
For example, applying the substitution a := { X ~ A q VR.A, Y ~ B } to t h e pattern X ~ Y fq V R . X yields the description A q (VR.A) rq B lq V R . ( A R VR.A). Obviously, the result of applying a substitution to an ~'s pattern is an ~ s description. 2 An ~rs maps concept variables to ~s descriptions. ~L:• are defined analogously. Subsumption can be extended to substitutions as follows. The substitution a is subsumed by the substitution T (a E T) iff a ( X ) E T ( X ) for all variables XEX. 9
D e f i n i t i o n 4. A n ~'s problem is of the form C =" D where C is an Yrs description and D is an YrE~-concept pattern. A solution or matcher of this problem is a substitution a such that C -- a(D). A subsumption condition in yrs is of the form X E ? E where X is a concept variable and E is an Yrs pattern. The substitution a satisfies this condition iff a ( X ) U a ( E ) . A strict subsumption condition in ffcs is of the form X E ? E where X is a concept variable and E is an Yrf.~-concept pattern. The substitution a satisfies this condition iff a ( X ) E a(E). Matching problems a n d (strict) subsumption conditions in ~ s and ~ ' s 1 7 7are defined analogously. Note that also the solutions are then constrained to belong to the respective sublanguage. Instead of a single matching problem, we may also consider a finite system {(71 - ? D 1 , . . . , Cm - ? Din} of such problems. The substitution a is a solution of this system iff it is a solution of all the matching problems Ci - ? Di contained in the system. However, it is easy to see that solving systems of matching problems can be reduced (in linear time) to solving a single matching problem. L e m m a 1. Let R a , . . . , R m
be distinct atomic roles. Then a solves the system {C1 ='9 D1,. .., Cm ='-9 D,~} iff it solves the single matching problem VRt.C1 Iq .. 9fq VRm.Cm - ? k/R1.D1 ~ 9"" R VRm.Dm.
Consequently, we may (without loss of generality) restrict our attention to single matching problems with or without finite sets of (strict) subsumption conditions. In 9, 23, a different type of matching problems has been considered. We will refer to those problems as matching problems modulo subsumption in order to distinguish them from the matching problems modulo equivalence introduced above. D e f i n i t i o n 5. A matching problem modulo subsumption is of the form C E ? D where C is a concept description and D is a pattern. A solution of this problem is a substitution a satisfying C E a(D). 2 Note that this would not be the case if we had allowed the application of negation to concept variables.
21
For any description language allowing conjunction of concepts, matching modulo subsumption can be reduced (in linear time) to matching modulo equivalence: L e m m a 2. The substitution a solves the matching problem C E ? D iff it solves ~?
C=
CnD.
For ~-L:-~,and more generally for any description language in which variables in patterns may only occur in the scope of "monotonic" operators, solvability of matching problems modulo subsumption can be reduced to subsumption: L e m m a 3. Let C r? D be a matching problem modulo subsumption in Y:f.,,
and let aT be the substitution that replaces each variable by T. Then C E ? D has a solution iff aT solves C ~? D. Thus, solvability of matching problems modulo subsumption in ~ s and its sublanguages is not an interesting new problem. This changes, however, if we consider such matching problems together with additional (strict) subsumption conditions. In fact, these conditions may exclude the trivial solution a-r. In addition, one is usually not interested in an arbitrary solution of the matching problem C E ? D, but rather in computing a "minimal" solution: D e f i n i t i o n 6. Let C E ? D be a matching problem modulo subsumption. The
solution a o C E ? D is called minimal iff there does not exist a substitution (i such that C ~ 5(D) E a(D). L e m m a 4. Let C ~? D be an YrS.-matching problem modulo subsumption. If
a is the least solution oC E ? D w.r.t, subsumption of substitutions, i.e., a E 5 or all solutions 6, then a is also a minimal solution. Proof. This is an immediate consequence of the following fact, which can easily be proved by induction on the structure of .Tg~-concept patterns: If a __ (i, then a(D) E ~(D) for any ~'s pattern D. It should be noted that talking about the least solution is a slight abuse of language since the least solution of a given matching problem is unique only up to equivalence: if a and r are both least solutions of the same matching problem then they subsume each other, which means that a(X) - T(X) for all variables XEX. The converse of Lemma 4 need not hold. For example, for the matching problem,VR.A ~? VR.ANVR.X, the substitutions a :-- {X ~ A} and r := {X T} are both minimal solutions, but r obviously cannot be a least solution. This example also demonstrates that minimal solutions of a given matching problem need not be unique up to equivalence.
22
3
Matching in .~Z2•
The purpose of this section is to show that solvability of ~-/Z• problems can be decided in polynomial time. In addition, for matching problems modulo subsumption we can compute a minimal solution in polynomial time. Our algorithm is based on a "concept-centered" normal form for ~rs177 descriptions. First, let us recall the concept-centered normal form for 9rs descriptions introduced in 5. It is easy to see t h a t any 5rs description can be transformed into an equivalent description t h a t is either 3- or a (nonempty) conjunction of descriptions of the form V R 1 . " ' V R m . A for m > 0 (not necessarily distinct) atomic roles R I , . . . , R m and an atomic concept A ~ 3-. We abbreviate V R 1 . " "VRm.A by V R 1 . . . R m . A , where R 1 . . . Rm is considered as a word over the alphabet Z := 7E of all atomic roles. In addition, instead of V w l . A • . . . R Vwl.A we write VL.A where L := { w l , . . . , w t } is a finite set of words over Z. The t e r m V0.A is considered to be equivalent to T. Using these abbreviations, any pair of 5r/~o-concept descriptions G, D containing the atomic concepts A 1 , . . . , Ak can be rewritten as C - VU1.A1 R ... fq VUk.Ak
and
D -- VV1.A1 R . . . R VVk.Ak,
where Ui, V/ are finite sets of words over the alphabet of all atomic roles. This normal form provides us with the following characterization of equivalence of 5r/~o-concept descriptions 5: L e m m a 5. Let C, D be JC~.o-concept descriptions with normal forms as introduced above. Then C = D iff Ui = Vi for all i, 1 < i < k. This characterization can in turn be used to reduce matching of 5rs descriptions to a certain formal language problem, which can easily be shown to be solvable in polynomial time (see 5 for details). If we treat _l_ like an arbitrary atomic concept, 9~/2• descriptions C, D can still be represented in the form 3 C -~ ~i~Uo.•
VU1.A1 -1... q VUk.Ak and D - VVo.• N VV1.A1 N ... ~ ~Vk.Ak.
However, equivalence of the descriptions no longer corresponds to equality of the languages Ui and V/. The reason is that V R 1 . " V R m . • is subsumed by any value restriction of the form V R 1 . . . . VR,~. VRm+I... 9VRm+~.A. This fact is taken into account by the following characterization of equivalence of 5r/:• concept descriptions: L e m m a 6. Let C, D be 3zs177 introduced above. Then C-
D
if
descriptions with :Ts
U o . Z * = Vo.E* and Ui U Uo.Z* = V~ U Vo.E* for all i, 1 < i < k,
a We shall call this the J--/:o-normal form of the descriptions.
forms as
23
where Z* is the set of all words over the alphabet o all atomic roles and stands or concatenation. Proof. Assume t h a t the right-hand side of the equivalence stated in the l e m m a holds. It is sufficient to show t h a t this implies C ~ D (since D _ C then follows by symmetry). Considering the normal form of D this means t h a t we must show t h a t for all w E Vo we have (1) C _ Vw.• and for all i, 1 < i < k, and all w E Vi we have (2) C E Vw.As. Thus, let w E V0. By assumption, V0 C_ Vo.E* - Uo'•*, which implies t h a t there exist a word u E U0 and v E E * such t h a t w ---- uv. Thus, the normal form for C contains the conjunct Vu.• Since Vu.2 _ Vuv.• for any word v we have established t h a t (1) holds. P r o p e r t y (2) can be shown similarly. Conversely, assume t h a t the right-hand side of the equivalence stated in the l e m m a does not hold, i.e., (1) Uo'~* ~ V0"~*, or for some i, 1 < i < k, (2)
usuUo.~* ~ Y~UYo.~*. First, we assume t h a t (1) holds. Without loss of generality we m a y assume t h a t there exist a word w := R I . . . R m E Z* such that w E Uo'Z* and w Vo'Z*. We claim t h a t this implies D ~ C, and thus C ~ D. In order to prove this claim, we construct an interpretation I as follows: the domain A I := {do,... ,din) consists of m + 1 distinct individuals; the interpretation of atomic concepts Ai is given by A t := AX; finally, the atomic roles are interpreted as S I := {(ds-1, ds) I S = Ri). It is easy to see t h a t this interpretation satisfies do E (Vu.As) I for all words u E Z* (since A / = AI), and do E (Vu.• I for all words u t h a t are not a prefix of w = R 1 . . . Rm. Consequently, do E (Vu.As) t for all u E Vi. In addition, w ~ V0.Z* implies t h a t no word in Vo is a prefix of w, and thus do E (Vu.• t for all words u E Vo. This shows t h a t do E D t. However, by construction, do r (Vw.• t, which implies do r C / . Second, we assume t h a t (1) does not hold, i.e., U0-Z* = Vo.E*, and t h a t (2) holds. Without loss of generality we m a y assume t h a t there exists a word w := R1 . . . Rm E Z* such t h a t w E Us and w r Vi U Vo.Z*. Again, we claim t h a t this implies D ~ C, and thus C ~ D. In order to prove this claim, we construct an interpretation I as follows: the domain A s := {do,... ,dm} consists of m + 1 distinct individuals; the interpretation of atomic concepts Aj for j ~ i is given by A / := At; the interpretation of As is A / := A t \ {din); finally, the atomic roles are interpreted as S t := {(ds-1, ds) I S = Ri}. By construction do r (~/w.As) I, and thus do r C t. On the other hand, it is easy to show (using arguments t h a t are similar to the ones employed in the first case) t h a t do E D I. If D is an 9 c s 1 7 7 containing the variables X 1 , . . . , Xt, then its Y s normal form is of the form D ~ VVo.• n VV1 .At M... MVVk.Ak MVW~.X1 M ... ~ VW~.Xl. If we want to match D with the description C (with normal form as above), we must solve the following "formal language" equations (where Xj# are interpreted
24 as variables for finite sets of words):
(•
Uo.Z* = Vo.Y,* U W~.X~,o.E* U . . . U Wt'Xt,o'Z*,
and for all i, 1 < i < k,
(Ai)
Ui U Uo.~* = Vi U W1.X1, i U . . . U W t . X t , i U Uo'~*.
T h e o r e m 1. Let C be an 3:s description and D an 3:s177 pattern with ffrf~o-normal forms as introduced above. Then the matching problem __? C = D has a solution iff the formal language equations ( l ) and ( A 1 ) , . . . , (Ak) are each solvable.
Proof. Let k
k
a := {Xt ~ VLl,o.J- rl -I VLt,i.Ai, . . . , X t ~-+VLt,o.J- rl F VL~,i.Ai} i=I
i=l
be a substitution. 4 By employing elementary equivalences between concept descriptions we can show that the ~ s form of a(D) is
G(D) - V (Vo U W1.LI,o U . - . U W~.Lt,o) .• n k
n ~ / ( v / u w1 .LI,i u . - . u Wt-Lt,i) .Ai.
i=1
Lemma 6 implies that C - a(D) iff Uo.E* -- (Vo U W1-LI,o U - . - U Wl.Ll,o)-Z*,
(1)
and for all i, 1 < i < k,
Ui U Uo'~* = Vi U WI'LI# U . . . U W~.L~,i U (Vo U Wl'Lz,o U . - . U Wt'Ll,o)'2*.
(2)
Since concatenation distributes over union, (1) corresponds to the fact that the assignment Xl,o := L1,0,..., Xt,o := Lt,o solves equation (_L). In addition, if we already know that (1) holds, then (2) corresponds to the fact that the assignment Xl,i := L I # , . . . ,X~,i := Lt,i solves equation (Ai). This shows how a solution a of the matching problem C =? D yields solutions of the equations (_L), (At), ..., (Ak), and conversely how solutions of these equations can be used to construct a matcher a.
Example 1. As a running example, we will consider the problem of matching the pattern D := Xt n (VR.X1) n (VS.X2) 4 Without loss of generality we restrict our attention to the images of variables occurring in D, and assume that a introduces only atomic concepts occurring in C or D.
25 against the description C := VR.((VS.At) M (VR._L)) MVS.VS._L. The ~'s177
forms of C and D are
C - V { R R , SS}._L flV{RS}.A1 and D - V0._LRV0.A1RV{e, R}.X1 ITV{S}.X2. __?
Thus, the matching problem C =" D is translated into the following two equations:
(• {RR, S S } . Z * = 0.E* U {~, R}.Xl,0.~* U {S}.X2,0.E*, (A1) { R S } U { R R , S S ) . ~ * = $ U { e , R } . X 1 j U {S}.X2j U { R R , S S ) . ~ * . If we want to utilize Theorem 1 for deciding matching problems in 5rs177we must show how solvability of the equations ( l ) , (A1), ..., (Ak) can be tested. First, we address the problem of solving equation (_l_). Lemma
7. Equation ( I ) has a solution iff replacing Xj,o'~* by the sets
N
weW~
solves equation (1). 5 Proof. To show the only-if direction, we assume that the assignment X1;o := M l , o , . . . , X~,o := Mt,o solves equation (3_). First, we prove that Mj,o.~* C_ nwew~ w-1 .(Uo-E*) ho2ds for all j, 1 < j _ t. Thus, let v E Mj,o-Z* and w e Wj. Since Wj.Mj,o.Z C_ Uo.Z*, we know that wv E U0.Z*, and thus v E w-l.(Uo.Z*). This shows that Mj,o.E* C_ w - l . ( U o . Z *) for all w E Wj, and thus Mj,o.~* C_ n ~ e w j w-l"(Uo'Z*) 9 As an immediate consequence, we obtain Uo.Z* = Vo.~* U W1.MI,o.~* U . . . U Wt.Ml,o.Z*
VoZ. u
N
wEW1
u... u w,
N
wEWl
It remains to be shown that the inclusion in the other direction holds as well. Obviously, we have Vo.E* C_ U0.Z* since there exists a solution of ( l ) . To conclude the proof of the only-if direction, assume that u E Wj and v E We must show that uv e Uo.Z*. Obviously, u E Wj implies
v E u-l.(Uo.E*), and thus uv E Uo.Z*. To prove the if direction, it is sufficient to show that there exist finite sets of words Lj,0 (j = 1 , . . . , t ) such that Lj,0"E 9 = n ~ e w . w - 1 . ( u 0 . z * ). This is an immediate consequence of the fact that languages of t~e form L.E* for finite L are closed under (binary) intersection and left quotients (see (1) and (2) of Lemma 8 below). 5 For a word w and a set of words L we have w - l . L := {u wu E L}. This language is called a left quotient of L.
26 L e m m a 8. Let U, V be finite languages and w a word.
1. There exists a finite language L1 such that LI.S* = w-I.(U.S*). 2. There exists a finite language L2 such that L2.E* = U.Z* N V.S*. 3. U.S* U V.S* = (U tA V).S* and U.(V.S*) = (U.V).~*. Proof. (1) Since (uv)-lL = v-l-(u-l.L) for all languages L, it is sufficient to consider the case where w has length 1, i.e., w 9 S . We distinguish two cases: - If the e m p t y word c belongs to U, then U.S* = S* = w - l - S *, and thus we can take L1 := {~}. If e r U, then our assumption t h a t the length of w is 1 implies t h a t w - I . ( U . S *) = (w-l.U) 9 S*, and thus we can take L1 := w - l ' U , which is finite since U is finite. -
(2) It is easy to see t h a t we can take L2 := (U N V-Z*) U (V N U.S*). (3) is trivial. For the matching problem of Example 1, we replace X1.S* by
R - I . ( { R R , SS}.S*)N~-I.({RR, SS}-S*) = {R}.S*N{RR, SS}.Z* : { R R } . S * and X2.S* by
S - I . ( { R R , SS}.Z*) = {S}.Z*. It is easy to see t h a t this replacement solves the equation. The finite languages Lj,o are defined as L1,0 := {RR} and L2,0 := {S}. Now, let us consider the equations (Ai) for 1 < i < k. L e m m a 9. Equation (Ai) has a solution iff replacing the variables Xj,i by the sets Lj,i := ~wewj w-l'(Ui U Uo.Z*) yields a solution of (Ai).
Proof. The proof of the only-if direction is very similar to the proof of this direction for L e m m a 7. In particular, one can show t h a t any assignment Xl,i := M l , i , . . . , X~,i := Mt,i t h a t solves (Ai) satisfies Mj,i C_ Lj,i. To prove the if direction, it is sufficient to show t h a t there exist finite sets of words Lj,i such t h a t Wj.Lj,i U Uo.Z* = Wj.Lj,i t3 Uo.Z*. We have Lj,i = Nwew~ (w-l"Ui U w-l.(Uo.Z*)). By applying distributivity of intersection over union, this intersection of unions can be transformed into a union of intersections. Except for the intersection Nwewj w-l'(Uo'Z*), all the intersection expressions in this union contain at least one language w-lUi for a word w E Wj. Since Ui is finite, this shows t h a t N~oewj w-l"(Uo "S*) is the only (possibly) infinite language in the union. Consequently, if we define Lj,i : : Lj,i \ NweW~ w-l'(UO'~'*), then Lj,i is a finite language. A
In order to prove t h a t Wj.Lj,i kJ Uo.S* = Wj.Lj,i tA Uo.S*, it is sufficient to show t h a t u 9 Wj and v 9 Lj,i \ Lj,i implies uv 9 Uo.Z*. By definition of Lj,i, we know t h a t v 9 Nwew~ w-l"(Uo'S*), and thus u 9 Wj implies uv 9 Uo.S*.
27 For the matching problem of Example 1, we have
L,,~ = R-I.({RS} U {RR, SS}.~*) N~-I.({RS} 9 {RR, SS}.E*) = (iS} U { R } . r * ) N ({RS} U {RR, SS}.E*) = {RS} U {RR}.2*,
L2,1 = S - I ' ( { R S } U {RR, S S } . 2 " ) =
A
Again, it is easy to see that replacing the variables Xj,1 by Lj,1 yields a solution of equation (A1). The finite languages Lj,1 are defined as LI,1 :-- {RS} and L2,1 := ~). Lemma 7 and 9 provide us with a polynomial algorithm for deciding solvability of matching problems in ~'t:• T h e o r e m 2. Solvability of matching problems in ~f~• can be decided in poly-
nomial time. Pro@ Obviously, Lemma 7 and 9 provide us with an effective method for testing matching problems in ~t:j_ for solvability. It remains to be shown that this test can be realized in polynomial time. First, note that the combined size 6 of the finite languages Ui and Vi is linear in the size of the concept description and the pattern. Thus, the size of the equations (_l_) and (Ai) is polynomial in the size of the original matching problem. Both for equation (1) and for equation (Ai) we compute a "candidate" for a solution and then test whether it really is a solution. First, let us consider equation (_l_). Given the finite language U0, we can construct (in polynomial time) a deterministic finite automaton that accepts the left-hand side U0"E* of equation (1), and whose size is polynomial in the size of U0. Regarding the right-hand side of equation (• it is easy to see that computing the candidate and inserting it into the right-hand side can be done in polynomial time. To be more precise, we can compute (in polynomial time) a deterministic finite automaton accepting the (regular) language obtained by inserting the candidate solution into the right-hand side of equation (_1_), and the size of this automaton is polynomial in the size of the equation. In fact, in order to construct this automaton, we start with finite deterministic a u t o m a t a for U0.Z* and V0-E*, and then apply the closure properties stated in Lemma 8 a polynomial number of times. It is easy to see that each closure operation can be realized as a polynomial operation on deterministic finite automata. Since equivalence of regular languages given by deterministic finite a u t o m a t a can be decided in time polynomial in the size of the automata, 7 this shows that solvability of equation (1) can be tested in polynomial time. 6 As size of a finite language we take the sum of the length of the words occurring in the language. 7 Note that this would not be the case for nondeterministic finite automata.
28 The equations (Ai) can be treated similarly. We just have to extend our argument regarding closure properties and deterministic finite automata from languages of the form L.~* for finite L to languages of the form L U L~-Z * for finite L, L ~. The proofs of Lemma 7 and 9 also show how to compute a matcher of a given solvable ~'s177 problem in polynomial time. In fact, if the matching problem is solvable, then the following substitution {7 is a matcher: k
k
{7 :---- {Xl ~ VLI,o.• Cl - VL1 i.Ai, ... i----1
'
'
Xe ~ VLt,o.• R 7 VLt i.Ai}, i=l
'
where the languages Lj,o (1 < j < ~) are defined as in the proof of Lemma 7, and the languages Lj# (1 _< j < ~, 1 < i < k) are defined as in the proof of Lemma 9. It should be noted that the language Lj,i = Lj,i \ ~wewj w-1 .(Uo.Z*) is a subset of J,cwj v-lUi, and thus its size is polynomial in the size of the matching problem. For the matching problem of Example 1, we thus obtain the matcher {X
1 v-~
(VR.VR._I_) N (VR.VS.A1), X2 ~-~ VS.&}.
L e m m a 10. Assume that the given Jzs177 problem C -~ =" D is solvable. Then the substitution a defined above is the least solution of C -~ ~" D. Proof. Assume that k
k
5 := {Xl ~ VM1 0.-l- n 7 VM1 i.Ai, ... '
i=1
'
'
X~ ~ VMt,0.-l- n -7 VMt i.Ai} i----1
'
_?
is another solution of C =" D. Consequently, the assignment X1,0 :-- M l , o , . . . , Xl,o := M~,o solves equation (Z), and the assignment Xl,i := M l , i , . . . ,Xl,i := M~,i solves (Ai). As shown in the proofs of Lemma 7 and 9, this implies that Mj,o.E* C Lj,o.E* (1 < j < ~) and Mj# C Lj,i (1 < j < ~, 1 < i < k). As a consequence of Lemma 6, we can infer a ( X j ) E 5(Xj) from Mj,o.Z* C Lj,o-E* and Mj,i U Mj,0.E* C_ Lj,i U Lj,o.E*. We already know that the first inclusion holds. For the second inclusion, it remains to be shown that Mj,i C_ Lj,i U Lj,0.Z*. This is an immediate consequence of Mj,i C_ Lj,i since Lj,i = Lj# U Nwewj w-l"(Uo'~*) and Lj,o.E* = N,o~w~ w-l"(Uo'E*). This lemma, together with Lemma 4, immediately implies the following theorem: T h e o r e m 3. Let C E_? D be a solvable matching problem modulo subsumption. Then the least solution of C =" - ~ C n D is a minimal solution of C r-? D, and this solution can be computed in polynomial time.
29 4
M a t c h i n g in .~'Z:-~
The results for matching in 5 / : • can easily be extended to the language ~/:-.. In principle, negated atomic concepts are treated like new atomic concepts. The fact that A • -~A is inconsistent (i.e., equivalent to _L) is taken care of by extending the language in the value restriction for the concept J_ appropriately. To be more precise, let C, D be ~'E• descriptions, and A 1 , . . . , Ak the atomic concepts occurring in C, D. By treating the negated atomic concepts ~Ai like new atomic concepts, we can transform C and D into their 9V/:o-normal forms: C =- VUo._LN VU~.A1 n . . . R VUk.Ak n VUk+t.-~Ai N . . . R VU2k.-~Ak, D - VVo.-L 7 ~r R . . . R VVk .Ak r'l ~b"~k..l_l .-~A1 r7... R VV2k.~Ak. If we define k
k
Oo::uouU(u, nuk+4
and
o::vouU(y nvk+,),
i=1
i=1
then Lemma 6 can be generalized to ~'/:~ as follows: L e m m a 11. Let C, D be 3:f~-~-concept descriptions with 3:~'o-normal forms as introduced above. Then C - O
and
ity
Ui U Uo-~* = V/U V0-~* oralli, 1 < i < 2 k , where ~* is the set of all words over the alphabet of all atomic roles. Consequently, all the results for matching in 5v/:~.carry over to ~'/:~: we simply have to replace k by 2k and the sets U0, V0 by Uo, V0. T h e o r e m 4. Let C =_? D be an Y:E~-matching problem. Solvability of C =? D c a n be tested in polynomial time. If C =_? D is solvable, then a least solution of C =_? D can be computed in polynomial time.
5
Matching under
side conditions
In the following, we consider strict subsumption conditions in more detail. For (non-strict) subsumption conditions we just briefly mention some results.
Strict subsumption conditions Recall that a strict subsumption condition is of the form X E ? E where X is a concept variable and E is a concept pattern. If the concept patterns of a set of strict subsumption conditions do not contain variables (i.e., the expressions E on the right-hand sides of the strict subsumption conditions are concept descriptions), then it is sufficient to compute a least solution of the matching problem, and then test whether this solution also solves the strict subsumption conditions.
30 T h e o r e m 5. Let C -? D be an J:s problem, and X1 r-? E l , . . . , Xn u ? En strict subsumption conditions such that El,. 9 En are Jrf~-concept descriptions. Then solvability of C -? D under these conditions is decidable in polynomial time. If the right-hand sides of strict subsumption conditions may contain variables, then solvability becomes NP-hard, even for the language ~-Z:o. This will be shown by reducing 3SAT 18 to the matching problem under strict subsumption conditions. Recall that matching modulo subsumption can be reduced to matching modulo equivalence, and that a system of matching problems can be coded into a single matching problem. For this reason, we may, without loss of generality, construct a problem that consists of matching problems modulo subsumption, matching problems modulo equivalence, and strict subsumption conditions. T h e o r e m 6. Matching under strict subsumption conditions is NP-hard, even for the small language ~f~o.
Proof. Let A be an arbitrary concept name. For every propositional variable p occurring in the 3SAT problem, we introduce three concept variables, namely Xp, X~, and Zp, and two roles Rp and R~. Using these concept variables and roles, we construct the matching statement VRB.A q VR~.A E_ Zp,
(3)
and the strict subsumption condition
Zp E VRp.X~ n VR~.X~.
(4)
It is easy to see that the subsumption relationship between VRp.A q VR~.A and VRp.Xp fq VR~.X~ enforced by (3) and (4) implies that any solution 0 of (3) and (4) satisfies:
(O(Xp) - A V 0(Xp) - T) A (0(X~) - A V 0(X~) - T). In addition, the fact that this subsumption relationship must be strict implies O(Xp) -- T V O(X~) =_ T.
Finally, if this solution also satisfies the matching statement
A - Xp n Z~,
(5)
then we know that both variables can not be replaced by T, i.e.,
O(Xp) =_-A V O(X~) =_A. This shows that, if we take T as the truth value 1 and A as the t r u t h value 0, then any solution assigns either 0 or 1 to Xp, and the opposite t r u t h value to
31 It remains to be shown that 3-clauses and the corresponding t r u t h conditions can be encoded. We introduce a concept variable Zc and three roles Rr for every 3-clanse c in our 3SAT problem, and represent the clause by a matching problem together with a strict subsumption condition. For example, assume that c := p V -~q V r. Then c is represented by the matching statement
VRc,I.A n VRc,2.A n VRc,a.A E Zc,
(6)
and the strict subsumption condition
Zc - VRc,1 .Zp i3 VRc,2.Xff 3 VRc,3 .Zr.
(7)
Obviously, the strict inclusion implied by these two statements can only be satisfied by a substitution ~ if it assigns -7 to at least one of the variables Xp, X~, and Xr. This completes our reduction. Note that (5) is a matching problem modulo equivalence that cannot be represented by a matching problem modulo subsumption. Thus, it is still open whether the NP-hardness result also holds for matching modulo subsumption under strict subsumption conditions. Theorem 6 only provides a hardness result for matching under strict subsumption conditions. Thus, another open question is how to extend the match: ing algorithm for 9vs to an algorithm that can also handle strict subsumption conditions.
Subsumption conditions If the subsumption conditions do not introduce cyclic variable dependencies, then a matching problem with subsumption conditions can be reduced to an ordinary matching problem. To be more precise, the sequence of subsumption conditions X1 ___7E l , . . . , Xn E ? En is acyclic iff for all i, 1 < i < n, the pattern Ei does not contain the variables X i , . . . , Xn. Given such an acyclic sequence of subsumption conditions, we can define a substitution s a inductively as follows:
a(X1) := II1NE1 and a(Xi) := Y ~ a ( E i )
(l
where the Y/are new variables. We can show that the matching problem C _-7 D is solvable under the subsumption conditions X1 U__? E 1 , . . . , X n v-? En iff C -=? a(D) is solvable without subsumption conditions. Unfortunately, the new pattern a ( D ) m a y be exponentially larger than the original matching problem with subsumption conditions. However, we conjecture that a compact representation of a(D) may be used to obtain a polynomial algorithm for matching under acyclic subsumption conditions in 9t'E~. s Strictly speaking, this is not a substitution as introduced in Section 2 since variables axe mapped to patterns, and not just to descriptions. It should be clear, however, that the notion of a substitution can be extended appropriately.
32 The reduction we have just described is independent of the DL used for constructing the patterns and descriptions. For ~'L:o, we can go one step further: cyclic subsumption conditions can here be reduced to acyclic ones. Let us illustrate this by two examples: (1) If a satisfies X1 E ? X2 R E~,X2 E ? X1 I"l E~, then a(X1) - a(X2), which means that we can identify both variables; (2) If a satisfies X E ? V R . X , then a ( X ) = T, and thus X can be replaced by T.
6
Future work
Our goal is to extend the results on matching to cover languages at least as expressive as the DL considered in 9. This requires extending the language to include range constructors (rain and max), an individual set constructor (one-of), number restrictions (at-least and at-most), and a fills constructor. For the constructors rnin, max, and one-of, this mainly requires an appropriate treatment of disjointness, which we have already achieved by our treatment of primitive negation. Number restrictions and the fills construct are more challenging extensions; however, we expect to be able to exploit the characterization of subsumption in cyclic A/X-terminologies provided in 21 for our purposes. Another motivation for investigating matching modulo equivalence may be found in merging heterogeneous databases. Consider a situation where there is a master ontology along with new database schemas that need to be integrated into the master ontology. In this situation, the integrator would like to know how the new schemas may be mapped onto the master ontology. Our idea is to represent the ontology and the schemas in an appropriate DL, and to view the problem of finding such a mapping as a matching problem of the concepts of the new schema onto the concepts of the master ontology.
7
Conclusion
We have been motivated by the need to prune complicated structures in order to provide manageable object presentations and explanations. The pruning problem can be viewed as a matching problem where there is a comparison between a pattern describing the interesting portions of the object and the larger object itself. Only those portions of the object that match the pattern of interest should be presented. We began with the filtering work introduced in CLASSIC and the theoretical work on the unification of concept terms and" generated a formal treatment of matching in the description logic language ~'L:• We presented results concerning the solvability of the problem including polynomial decidability and (for solvable problems) polynomial computability of a least solution. We also extended the work to include matching under additional side constraints on the variables in the matching patterns. We showed that matching modulo equivalence with strict side conditions is NP-hard even for the small language 3cs
33
References 1. F. Bander. Augmenting concept languages by transitive closure of roles: An alternative to terminological cycles. In Proceedings of the 12th International Joint Conference on Artificial Intelligence, pages 446-451, Sydney, Australia, 1991. 2. F. Bander, M. Buchheit, and B. Hollunder. Cardinality restrictions on concepts. Artificial Intelligence, 88(1-2):195-213, 1996. 3. F. Bander and P. Hanschke. A scheme for integrating concrete domains into concept languages. In Proceedings of the 12th International Joint Conference on Artificial Intelligence, pages 452-457, Sydney, Australia, 1991. 4. F. Bander and B. Hollunder. A terminological knowledge representation system with complete inference algorithms. In M. Richter and H. Boley, editors, Proceed-
ings of the First International Workshop on Processing Declarative Knowledge, 5.
6.
7.
8. 9.
10.
11.
12. 13.
14.
15.
volume 567 of Lecture Notes in Computer Science, pages 67-85, Kaiserslautern (Germany), 1991. Springer-Verlag. F. Baader and P. Narendran. Unification of concept terms in description logics. In H. Prade, editor, Proceedings of the 13th European Conference on Artificial Intelligence (ECAI-98), pages 331-335, Brighton, UK, 1998. John Wiley & Sons Ltd. An extended version has appeared as Technical Report LTCS-98-06. F. Bander and U. Sattler. Description logics with symbolic number restrictions. In W. Wahlster, editor, Proceedings of the Twelfth European Conference on Artificial Intelligence (ECAI-96), pages 283-287. John Wiley & Sons Ltd, 1996. F. Baader and U. Sattler. Number restrictions on complex roles in description logics. In Proceedings of the Fifth International Conference on the Principles of Knowledge Representation and Reasoning (KR-96). Morgan Kaufmann, Los Altos, 1996. A. Borgida. Description Logics in Data Management. IEEE Trans. on Knowledge and Data Engineering, 7(5): 671-682, 1995. A. Borgida and D.L. McGuinness. Asking queries about frames. In Proceedings
of the Fifth International Conference on Principles of Knowledge Representation and Reasoning, KR'96, pages 340-349, Cambridge, MA (USA), 1996. A. Borgida and P. Patel-Schneider. A semantics and complete algorithm for subsumption in the CLASSIC description logic. Journal of Artificial Intelligence Research, 1:277-308, 1994. R. J. Brachman, D. L. McGuinness, P. F. Patel-Schneider, L. A. Resnick, and A. Borgida. Living withCLASSIC: When and how to use a KL-ONE-Iike language. In J. Sowa, editor, Principles of Semantic Networks, pages 401-456. Morgan Kaufmann, San Mateo, Calif., 1991. R. J. Brachman and J. G. Schmolze. An overview of the KL-ONE knowledge representation system. Cognitive Science, 9(2):171-216, 1985. M. Buchheit, F. M. Donini, and A. Schaerf. Decidable reasoning in terminological knowledge representation systems. Journal of Artificial Intelligence Research, 1:109-138, 1993. F. Donini, M. Lenzerini, D. Nardi, and W. Nutt. The complexity of concept languages. In Proceedings of the 2nd International Conference on Principles of Knowledge Representation and Reasoning, pages 151-162, Cambridge, Mass., 1991. F. Donini, M. Lenzerini, D. Nardi, and W. Nutt. Tractable concept languages. In Proceedings of the 12th International Joint Conference on Artificial Intelligence, pages 458-463, Sydney, Australia, 1991.
34 16. F. Donini, M. Lenzerini, D. Nardi, and A. Schaerf. Deduction in concept languages: From subsumption to instance checking. Journal of Logic and Computation, 4(4):423-452, 1994. 17. F.M. Donini, B. Hollunder, M. Lenzerini, A.M. Spaccamela, D. Nardi, and W. Nutt. The complexity of existential quantification in concept languages. Journal of Artificial Intelligence, 53:309-327, 1992. 18. M.R. Garey and D.S. Johnson. Computers and Intractability: A Guide to the Theory of NP-Completeness. W.H. Freeman and Company, New York, 1979. 19. B. Hollunder and F. Baader. Qualifying number restrictions in concept languages. In Proceedings of the 2nd International Conference on Principles of Knowledge Representation and Reasoning, pages 335-346, Cambridge, Mass., 1991. 20. B. Hollunder, W. Nutt, and M. Schmidt-Schaufl. Subsumption algorithms for concept description languages. In Proceedings of the 9th European Conference on Artificial Intelligence, pages 348-353, Stockholm, Sweden, 1990. 21. R. Kiisters. Characterizing the semantics of terminological cycles in AEAf using finite automata. In Proceedings of the Sixth International Conference on Principles of Knowledge Representation and Reasoning (KR'98), Trento, Italy, 1998. 22. H. J. Levesque and R. J. Brachman. Expressiveness and tractability in knowledge representation and reasoning. Computational Intelligence, 3:78-93, 1987. 23. D.L. McGuinness. Explaining Reasoning in Description Logics. Ph.D. thesis, Department of Computer Science, Rutgers University, October 1996. Also available as a Rutgers Technical Report LCSR-TR-277. 24. D.L. McGuinness and A. Borgida. Explaining subsumption in Description Logic. In Proceedings of the 14th International Joint Conference on Artificial Intelligence, IJCAI'95, pages 816-821, Montreal, Canada, 1995. Morgan Kaufmann. 25. D.L. McGuinness, L. Alperin Resnick, and C. Isbell. Description Logic in practice: A CLASSIC application. In Proceedings of the 14th International Joint Conference on Artificial Intelligence, IJCAI'95, pages 2045-2046, Montreal, Canada, 1995. Morgan Kaufmann. Video Presentation. 26. D.L. McGuinness and J.R. Wright. An industrial strength Description Logic-based configurator platform. IEEE Expert, Special Issue on Configuration, 1998. To appear. 27. B. Nebel. Computational complexity of terminological reasoning in BACK. Journal of Artificial Intelligence, 34(3):371-383, 1988. 28. B. Nebel. Reasoning and Revision in Hybrid Representation Systems, volume 422 of Lecture Notes in Computer Science. Springer-Verlag, 1990. 29. B. Nebel. Terminological reasoning is inherently intractable. Journal of Artificial Intelligence, 43(2):235-249, 1990. 30. A. Schaerf. On the complexity of the instance checking problem in concept languages with existential quantification. Journal of Intelligent Information Systems, 2:265-278, 1993. 31. M. Schmidt-SchauB and G. Smolka. Attributive concept descriptions with complements. Journal of Artificial Intelligence, 47:1-26, 1991. 32. W. A. Woods and J. G. Schmolze. The KL-ONE family. Computers and Mathematics with Applications, special issue on knowledge representation, 23(2-5):133-177, 1991. 33. J. R. Wright, E. S. Weixelbaum, G. T. Vesonder, K. Brown, S. R. Palmer, J. I. Berman, and H. H. Moore. A knowledge-based configurator that supports sales, engineering, and manufacturing at AT•T network systems. A I Magazine, 14(3):6980, 1993.
Ontologically Yours, Daniel Kayser L.I.P.N., Institut Galil6e Universit6 Paris-Nord Avenue Jean-Baptiste Cl6ment F-93430 Villetaneuse, France
[email protected]
Abstract. The word 'ontology' belongs to the vocabulary of Philosophy, and
it is now commonly used in Artificial Intelligence with a rather different meaning. There is nothing wrong here, so long as what is meant remains clear. AI typically claims to use ontology for building 'conceptual structures'. Now concepts are named by words, and in the relation concept-word, the goals of AI imply not to move too far away from words. Therefore, it is not at all certain that 'conceptual structures' should be handled in the way that logicians and philosophers consider to be adequate for concepts. Thinking about the actual use of words in reasoning may therefore open some new perspectives in the theory of 'conceptual structures'.
1 Introduction Knowledge Representation (KR) aims at expressing the knowledge concerning a domain in terms of its concepts, relations, individuals or whatever; however, the choice of these entities is not considered to be a genuine KR question, but rather an ontological one. Ontology is more and more frequently referred to in Artificial Intelligence (AI), and there is an active and scientifically very creative research community currently interested in 'ontologies'. Now, the word 'ontology' belongs to the vocabulary of Philosophy, where it is deeply related with problems of existence. When AI considers some questions as being ontological, does it really mean that we are concerned with metaphysical problems? Most of us will certainly answer negatively. We are considering models of a reality; these models are designed for a given purpose, and the main problem we are interested in is their adequacy to this purpose. Being adequate is not grounded on being "real"; furthermore being realistic, i.e. aiming at the representation of "all" aspects of reality, goes in the opposite direction to being adequate, for obvious complexity reasons. What "AI ontology" wants is to find the basis for efficient models, whereas what "philosophical ontology" wants is to discuss the problem of
36 real existence, whatever this may mean (see below). Their goals are not comparable, and their methods can be completely contradictory. Although it may distract me from my main points, I would like to digress on what means "to exist" for the layman.
1.1 Trivial considerations about existence The most "natural" way of existing is precisely to exist in Nature. Trees exist. Ghosts do not exist. But we often forget that tree is a word, that people use to refer to a category of objects, and the "existence" of trees is nothing more than an agreement that this oak, that pine, and so on belong to the same category, agreement based on the fact that these objects share common properties that we consider as important. The other "way of existence" is the existence inside of a model. In the standard propositional calculi, there exist tautologies; in euclidean geometry, for each point there exists a unique line including the point and having a given direction, etc. In some sense, the distinction between both "ways of existence" is ill-defined, because as we have noticed, rather than to Nature itself, the first one refers to an agreement about the "obvious model" of Nature, hence existence in Nature is also existence inside of a model. But there is another deep problem to take into consideration, namely whether objects (e.g. this oak, etc.) do exist in Nature or only in the "obvious model", presumably innate, by which we perceive the external world. At a very different scale from ours, this oak is not an object at all: it is a collection of molecules or, alternatively, an indistinguishable part of the vegetal cover of the earth. This question may at first sight appear to be more relevant to "philosophical ontology" than to AI, but we will see that it is not the case.
1.2 Plan of the paper Section 2 explains the difference between "philosophical" ontology and AI in terms of their different view of what a concept actually is. Of course, only a small part of such a subject is covered, and we try to focus on what is relevant for the basic idea defended in this paper. We have already underlined that even if there are fundamental discrepancies between a concept and the lexical unit that names it, it was nonetheless impossible to ignore the behaviour of words in a discussion about concepts. Therefore, section 3 develops and exemplifies some linguistic considerations, in the domain of technical terms as in the general use of the language. We will then be ready to present, in section 4, the main thesis of the paper: the inadequacy of current AI ontologies - - as soon as they concern a domain dealing with concepts which are not perfectly defined logically - - originates in an idealistic view which does not meet AI needs. This view should be replaced by a much more flexible one, taking into account variability, i.e. the fact that ontological uniqueness
37 is a wrong requirement for AI, and borrowing from the linguistic processes by which the meaning of a word gets adapted to its context of use.
2 Philosophical vs. AI view of a concept Philosophy, as for that matter Mathematical Logic, has a rather strict notion of a concept. In its extensional version, a concept corresponds exactly to a unary predicate, i.e. to a function which, for every object, tells whether or not it "falls under" the concept. The other view of a concept, i.e. its intension, can either be seen as a kind of generalization (intension as extension in multiple worlds, cf. 10), as a mere variant (intension as a set of properties, each property being nothing more than a unary predicate) or as ontologicaUy distinct (properties "exist", their having an extension being a contingent, less important, feature). The intensional view has ~interesting applications in AI (equational calculus based on intensional normal forms has proven useful in Description Logics), but identifying an object with the set of its properties is counterintuitive, and when the properties are allowed to change with time, the identity of the object is hard to maintain. We therefore concentrate on the extensional view. There are a number of difficult questions lurking behind this seemingly simple notion, some of which are discussed below.
2.1 Vague concepts The first problem is well known. Whether an object "falls" or not under a concept does not always come as a yes / no decision. Under the designation of vagueness (Russell), fuzziness (Zadeh) or whatever, this issue has been investigated by various means. None of them appear to be completely'satisfactory. Consider for instance the popular fuzzy-set representation of a vague concept: if a concept c is vague, it is hard to decide which real number ~t (i.e. a number, each digit of which has a welldefined value!) corresponds to the degree of membership of every object o to c. The meaning of setting ~ato 1 must also be clear, i.e. there must exist a criterion telling what a perfect instance of c is, and this seems somehow contradictory to the fact that c is only vaguely defined. Several other technical or mathematical proposals have been put forward in order to cope with Vagueness, and we will not discuss them here, because we want to focus on a more difficult issue, which seems to have been often overlooked.
2.2 Vague objects? In order to give either a yes / no answer, or a more finely shaded one a s t o whether object o falls under concept c, it is not only important to know what we
38 mean by c, but also what o precisely is. All traditional logical approaches tend to consider that objects "are there", and to ignore the problem of deciding what counts as an object ~. There are well known philosophical difficulties, e.g. whether a heap is an object or a set of objects, yielding to possible paradoxes (sorites), see also 13. There may be also physical difficulties to define objects, e.g. at the wave/corpuscle level. None of them is really relevant to AI: when we represent entities in knowledge bases, they usually behave as "classical" objects. N o w even so, what we consider in the real world to be an object tends to be much more problematic than most o f us are ready to admit. Language adds a lot of difficulties, that we cannot ignore - - therefore, we will discuss them in the following section - - but language is far from being responsible for all the problems. Ostensive designation 2 for instance introduces also ambiguity. If, pointing to some direction, you utter or make a gesture suggesting "this is awkward", you may mean that some object, or all objects of some category, or a situation in which some (set of) object(s) play(s) a role, or many other things, are unpleasant to you. A "conceptual" translation such as: I
(q x) (awkward(x))
(F)
1 requires to define over which domain D (physical objects, classes of physical objects, sets, situations, etc.) the variable x is quantified, or in other terms what counts as an object, independently of any "sorites" or "quantum physics" kind of consideration.
2.3 Variable ontology Even if we are able to make a reasonable choice for D under some given circumstances, what seems to have been up to now completely neglected is the fact that this choice must be a revisable one. As a matter of fact, the ability to modify an ontology during a reasoning process seems to be a fundamental property of intelligence. My favourite example here - - b u t an amazing number of various situations exhibit the same pattern - - consists in planning a journey; suppose you have to go by car from A to B; it is often enough to take A and B as points, and the route between them as a line. But the map on which you plan your route may give indications o f narrow sections of the road, or of low bridges, in which case you have to take temporarily into account two or three-dimensional clearance considerations. Moreover, if the place B where you are heading, is located in a town T, it is convenient to reason as if T were a point, up to T's outskirts where you might have
iMereology 9 can be counted as different in this respect, but this approach adds specific difficulties which we cannot develop here. ~See also 11.
39 to choose between directions T-West and T-East, a very strange choice if T continues to be handled as a point! We will discuss in section 4. some implications of this kind of phenomena. The only consequence that we draw for now is that the solution of an "ontological problem" should not be a structure such that the concepts of the application rigidly map to a unique entity of the structure. The degrees of freedom that are needed should answer the problems of vagueness or fuzziness as well as the problem of the identity of objects.
3 Some linguistic considerations
3.1
General
Natural languages add a lot of specificities to the problem of concept representation; just to mention a few of them, the distinction between homonymy and polysemy, the distinction between proper (literal) meaning and various metonymic or metaphorical extensions, the assignment of a syntactic category, the variation of the meaning of an expression when it gets translated from a language to another . . . . It may therefore seem wise for "knowledge engineers" to be careful not to tread on the dangerous ground of language. But this cautiousness would lead to evade the real problems. After all, it is not by chance if, in order to make clear what concept we are interested in, we always designate it by a natural language word or phrase. The widespread belief that precautions - - s u c h as putting capital letters for concepts and lowercase ones for w o r d s - are sufficient to prevent concepts from borrowing the involved behaviour of words, is groundless. Let us consider a couple of examples.
3.2 W h a t kind of thing is a Unix c o m m a n d ? "Command" is a word that has various meanings according to context. However, in the narrow scope of the Unix Operating System, it seems that this word corresponds to a single, well-defined concept. Looking across a User's Guide 3 tells us how the word is used; because of some of the linguistic phenomena listed in w and especially of metonymy, the uses may not be very helpful to determine exactly where to put the concept in an ontology. However, it should provide useful hints. The first occurrence of the word, and the only one which has the form of a definition, is very misleading:
3We refer in this section to "SunOS User's Guide: Getting Started 9 Sun Microsystems Inc." The numbers following the sentences refer to the page numbers in that Guide.
40
Most commands are executable files; that is, they are files that you can run. Later on, it appears that the Guide tries to carefully distinguish between the command and the command line (i.e. command + options + arguments). But quickly the tendency to conciseness seems to override this distinction: I
The r a k d i r corn,hand creates directory.
(23)1
Is this sentence a metonymy, i.e. should it be read as "command lines having rnkdS_r as their command create directories"? Or is it still the proper sense, i.e. the command does create the directory, but the way to do it requires that you type a command line including the command and some other stuff? A similar doubt arises with the very frequent occurrences of sentences "the syntax of xxx is ..." where xxx has been introduced as a command. The (nonambiguous) meaning of such sentences can be both understood as metonymic ("the syntax of a command line starting with xxx is ...") or proper (commands have syntax, explaining how command lines using them should be formed). Sentences like the following one are obviously inconsistent with the policy expressed in the Guide, since options are said to be part of command lines, not of commands: I
Use the l s
- 1 command to determine what permissions files and directories have.
(37) I
The above remarks only illustrate the very trivial fact that, despite its attempts to name consistently the concepts, the Guide, as every technical or non-technical piece of text, cannot completely avoid sloppiness in its wording. However, this leaves completely open our initial question: where should we put the concept command in an ontology? Under "string of characters"? Under "class of processes"? Under "implements"? Or still in a different part of the ontology? An even more important question is "what is the criterion allowing to choose among these possibilities?", i Consider for a moment that we select (more or less arbitrarily) one of these options; for instance, we decide that "basically", a command is a kind of string of characters; then, all the other concepts that may be called a command should be derived from this "basis". This decision being taken, a careful reading of the Guide allows us to endow this "basic" concept with roles, e.g. commands are strings of characters: 9 typed by a user, 9 in order to fulfill one of his/her goals, 9 being interpreted by a program, 9 thereby creating a process, 9 etc. The Guide could then be rewritten, albeit in a clumsy style, in a consistent way with this ontological decision. As we have seen above, this rewriting may not be unique, but if the meaning of the sentence is clear, the various translations should be equivalent.
I
41
But some cases remain problemati c . Consider the sentence:
L
k i l l provides you with a direct way to stop commands that you no longer
want. The clear meaning of this sentence is: << i__~fy o u
type at s o m e t i m e t a command line starting with of characters) c, in o r d e r to f u l f i l l g o a l g, t h e r e b y c r e a t i n g p r o c e s s p, at s o m e l a t e r t i m e t', g is n o t f u l f i l l e d , p is s t i l l active, a n d y o u h a v e the n e w g o a l c a n c e l l i n g p,
then
you
should type at t' a command line 1 obeying PIDs", w h e r e ... >>.
the
command
g' c o n s i s t i n g
the
syntax
(stnng
in
"kill
The least that can be said here is that the translation is not easy. Similar difficulties will be encountered with: running a command in the background.
(88)
restarting a command These difficulties are related to the spatio-temporal dimension which was not taken into account in the choice of our "basic" concept. They belong to the type/token kind of difficulties, that arise more or less everywhere. As a matter of fact, if a command is identified to a string of characters, two different users typing the same string will issue the same command, as will do a single user typing the same string at two different times. The correspondence between command and process will therefore become rather problematic. In technical domains, the story generally ends well: there is in principle one (or several) "ontologically correct" representation(s) of each occurrence of a term that can be expressed as formula(s) using the "basic concept", whatever it is, that has been selected for that term. However, the relationship can be very hard to find (in the (85) example above, commands stands for processes initiated by command lines starting with "commands" in the "basic" sense of the term ; in a similar study 6 on the Hypercard User's Manual, an even more far-fetched solution was needed: it turned out that field was used for the way the content of the "basic" field concept was displayed on the printer!).
I
42
3.3 What kind of thing is a traffic light? In everyday life, it is far less obvious to determine a "basic" concept, and, more radically, whether this idea of "basic concept" makes sense at all. In a previous work 4, I argued that book should basically refer to an equivalence class of physical objects, the equivalence relation being under-determined (depending on the context, e.g. two different editions of a book count as equivalent or not). Therefore, even in a well-defined situation, there may remain for ordinary language an under-determination as to how a given occurrence of a word such as book should be translated by means of "basic" concepts. In a more recent paper 3 my colleagues and myself have tried to investigate how the concept of traffic light was to be ontologically classified, when car-crash reports had to be analyzed 4. Two sensible choices appear as possible: either a traffic light is a physical object, or it is a process. Of course, there is a relation between them: the process is the purpose of the object, the object is the place where the process takes place. In several sentences, both concepts must coexist in a single occurrence of the term. Consider for example: I
(...) car d'ordinaire se trouve un feu ~ ce carrefour. (hors fonctionnement ce jour-I~)
A6 I
I
(...) as usually there is a traffic light at this crossroads (out of use this very day) What is located at the crossroads is the physical object, and what is not functioning, is the process. Maybe, more strikingly: I
l~tant ,~ I'arr& au feu tricolore (rouge)
B4 I
being stopped at the three-coloured traffic light (red) The physical object is not three-coloured, nor is the process! The process allows the light emitted by the object to take different colours at different times; the parenthesis reflects the trouble of the author of the report, to assign simultaneously different types to a single word. An "ontologically correct" paraphrase of the text would be something like: being stopped in the vicinity of the location of a physical object sheltering a process emitting light that at different times takes three different colours, at a phase of the process where the colour was red !! A similar case can be made about: A Nanterre, arr&6e ~ un feu rouge, un automobiliste n'a pas v u l e feu
B66
bz Nanterre, while ! was stopped at a red traffic light, a car-driver did not see the traffic light 4We are grateful to M.A.I.F. Insurance Co. for having put a number of reports at our
disposal. The number following the sentences correspond to a numbering of these texts.
43 the author is stopped in the vicinity of the object, at a specific phase of process, and what happened is presumably not the fact that the other car-driver not see the object, but that he did not pay attention to the current phase of ocess. The temporal interpretation is event sharper in: Alors que je red6marrais au feu vert, (...)
the did the ....
B6
. While I was getting going again at the green traffic light, (...) If the "basic concept" is the object, we have to jump from it to the process and then to the instant at which the process is changing phases. The conclusion is that we may arbitrarily assign a "basic" concept to the term traffic light. But then nearly every occurrence of the term must be treated as a metonymy, that our knowledge of the usual driving situations allows us to decode, more or less accurately, in order to get an expression using the "basic" meaning. However, this view entails: 9 a choice of the "basis", for which no solid ground seems available, 9 a tedious, sometimes reckless, translation of the occurrences of the term, 9 and this results in an overall impression of artificiality and inadequacy of the conceptual representation.
3.4 Pustejovsky's Generative Lexicon In 12 and various other writings, J.Pustejovsky suggests to deal with the variability of semantic interpretation of a given lexical unit by a process called type coercion. Lexical units get a type, but when they are used in sentences where this type yields ill-formed expressions, the process operates and produces an entity of a new type. This process relies on a qualia structure associated to each lexical unit; four facets are defined: CONST, FORMAL, TELIC, AGENTIVE, but the method to fill these facets remains intuitive, and the examples provided show that arbitrariness cannot be eliminated. To take once more the example of book, FORMAL is filled with physobj (standing for physical object) and AGENTIVE, with write, while it would have been possible to consider the "agent" of the physical-object book to be the printer, or alternatively the "formal" facet of the written book as its semantic content rather than as a physical-object. To cope with the plurality of views on a single word, Pustejovsky introduced more recently "complex types", e.g. book has type physical-object.info, and according to the context, one, or the other, or both members of this couple is/are activated. Unfortunately, this step goes in the direction of a finite enumeration of word senses, which is precisely what the "generative" approach is supposed to avoid.
44
3.5 (Provisional) conclusion The difficulties arising in the above examples can be blamed on the language only. Using natural languages necessarily entails delicate transpositions in a neat conceptual structure, but the existence and importance of such structures might remain unquestionned. Alternatively, they can be a hint to the pointlessness of keeping concepts pure from any linguistic contamination.
4 Some promising tracks
4.1 Semantic adaptation The meanings that a single word can take in various contexts form a virtually unlimited set. Dictionaries keep, in an often peculiar organization 5, the most typical
semantic values. Even if this fact is seldom acknowledged, no text understanding is possible if the understander has only access to the dictionary meaning of each word of the text: every human unconsciously twists in some way or another the sense(s) found in the dictionary in order to find an adequate value of a word in its context. As an illustration among billions of others, the temporal value offeu in example (B6) w is not given in any dictionary - - and should probably not be given if we are to keep their size compatible with human use. There is therefore a process of semantic adaptation, about which surprizingly little is known neither psychologically nor computationally 6, in order to transform the lexical information, on a word into a reasonably adequate semantic value for that word in its context. This process is, to some degree, regular. The regularities have been listed in Linguistics, and usually considered as rules governing metonymy. However, linguists focus their study on "interesting" metonymieg rather than on the most common ones; moreover their rules correspond to a flat list of possible shifts, little being said concerning the actual applicability of the rule in a given situation. Now a blind application of the rules generates a huge number of interpretations, most of which would never come to the mind of a human understander.
5As no semantic organizational principle has been spelled out, most dictionaries organize the senses according to the (syntactic) constructions allowed by each meaning; as a result, intuitively very similar senses are remote in the dictionary (see 7). 'See however the special issue of Computational Intelligence devoted to non-literal meaning 2.
45 This describes the situation of words, but what is the relevance of the phenomenon of semantic adaptation and of its regularity when concepts are considered? As we already insisted, concepts are not that different from words, not different anyhow to a point where a treatment having interesting features for words would be completely irrelevant for concepts.
4.2 Conceptual adaptation The idea is thus to take advantage of the study of the process of semantic adaptation in words, in order to investigate to which extent it might be useful in concepts too. At first sight, such an idea seems both counterproductive and ... absurd: ~ counterproductive, because concepts have been invented, as it were, to get rid of the pecularities of words when speaking about content; imitating at the level of concepts the seemingly erratic behaviour of lexical semantics is sort of going backwards, with respect to the advances obtained in working with concepts instead of words; ~ absurd, as semantic adaptation navigates from concept to concept in order to find which one meets the constraints imposed by the context on the occurrence of a word; it makes no sense at all to allow a concept to wander around in a structure of concepts which themselves wander around! However, there might be a more reasonable picture, introducing different levels. At each level, the domain of interest is structured with stable concepts. Before going further, let us observe that the same concept can be found at different levels, but with no easy correspondence. As a metaphor, the black circle representing MontpeUier on the 1/5,000,000 map that I have in my notebook does not yield a huge black dot on the 1/50,000 map they sell you for going cycling in the outskirts of the city. Should it correspond to a typical point in the city (e.g. the townhall), to the area delimited by the city limits, by the limits of the conurbation . . . . ? The answer depends on the situation, if any, where the question makes sense. Consider now a concept occurring in a conceptual representation; even it bears the same name as a "stable" concept appearing at some level, this does not necessarily entail a full coincidence with it. A process of conceptual adaptation may reveal as necessary here as the process of semantic adaptation was inescapable for text understanding. More precisely, I argue that any formula (F) representing some piece of knowledge (or some questions to be answered, e.g. if the formula has free variables) in a conceptual language should not be matched with (for consistency checking) or fed into (for inference) a single conceptual structure, identifying the concept names appearing in the formula with those occuring in the pre-existing structure. Instead of that, the formula should rather be confronted with several such structures, without being misled by identity of concept names. In each case, a process of conceptual adaptation should be invoked, in order to discard the levels where (F) makes no
46 sense, and to modify (F), following regular patterns, in order to get from it meaningful results. I know very well that this opinion should be backed up at least by an illustrative example. The trouble is that every simple example, say of a size compatible with this paper, will more easily be solved with a one-level conceptual architecture, and if the agreement between the concept names of the structure and (F) is not good, the normal reaction is to blame the knowledge engineer for inconsistently using his/her own predicate names. Therefore, I will only hint at what such an example should look like; of course, it will always be possible to solve it in a ~( logically correct >> way. Consider the ~genuine)r car-crash rej~ort below: J'ai vu I'arriSre du vthicule B s'approcher. J'ai appuy6 h fond sur le frein, le vthicule B a continu6 h s'approcher. J'ai cru sur le moment que mes freins n'avaient pas r~pondu et nous avons rempli ce constat. J'ai immediatement apr~s essay6 rues freins qui fonclionnaient tr~s bien. J'ai mainlenant la certitude, la rue 6lant Idg~.rement en penle, que c'est le camion qui a recul6 et est venu me percuter (...)
B68
I saw the back o f vehicle B coming nearer. ! pushed on the brake to the bottom, but vehicle B kept coming nearer. I believed, on the spot, that my brakes had failed and we.filled the present report. Immediately after, I checked the brakes which work quite well. I am now absolutely conviced that, as the street has a slight slope, it is the truck who was moving back and stroke me (...)
Independently of the words used, the representation of what happened requires a rather complex description on some notions, e.g. beliefs and how to confirm them, in order to infer that the author now disagrees with what (s)he wrote in the report; on the other hand, the comprehension of this text requires only a very crude description of vehicles and of their dynamics (there is a brake; when it works, it prevents you from coming nearer the vehicle you see). In most other texts, the opposite holds: confirmation of beliefs is irrelevant, but considerations on the effect of speed and dampness over braking distances play an essential role. Having a single ontology to shelter all the knowledge that may come into play entails: 9 reasoning in every case in the most complex setting - - a very inefficient s t r a t e g y - - , and 9 handling a number of concepts presumably larger by an order of magnitude than the size of the vocabulary, hence the need to use e.g. STREET#1 (a line), STREET#2 (a surface, the causeway), STREET#3 (a skew surface, the causeway plus the sidewalks), STREET#4 (a volume, including the buildings opening onto the sidewalks), and so on. The alternative is to use a simple ontology (e.g. STREET defined as a line) and to refine it when and where the need arises. In the above example, "brake" can at first be defined as a part of a vehicle, but clearly we need later to distinguish among
47 BRAKE#1 (the pedal), BRAKE#2 (the brake shoe), and BRAKE#3 (the whole device by which pressing on the pedal results in the shoe rubbing on the wheels). Having all sorts of brakes and streets cluttering the ontology of the domain of car-crashes is a very hard constraint to cope with, and a very useless one too! Having ontologies at different levels, with bridges between them, and reasoning at the simplest level, except when it is inconsistent to do so seems much more attractive. But the difficulties must not be underestimated: 9 designing a strategy to select the ontological level appropriate for a given situation is difficult, 9 having efficient cooperation between levels which, by definition, do not share the same ontology is even harder, 9 deciding when to start and stop a new level of reasoning cannot be grounded on any formal principle, but only on empirical basis. Even if these obstacles are fearsome and hence this "promising track" not really attractive, I believe that the relatively easy way explored by philosophers and logicians has shown its intrinsic limitations, and nothing really less fearsome might solve the problem. More technical developments of this idea can be found in previous papers 8 5.
5 Summary The less controversial examples of conceptual structures use mathematically perfectly defined notions (not going back as far in History as Port Royal's definition of comprehension and extension on triangles, it is worth noticing that e.g. Chein & Mugnier's paper 1 use an ontology of polygons!). This is so because only in that case, the quest for a unique ontology is admissible and successful. The acceptance of ontological multiplicity, which goes necessarily with the need for a process of conceptual adaptation does not mean setting the fox (I mean the scruffiness inherent to natural languages) to mind the geese (I mean the neatness of the conceptual level); it is essential if we want to develop tools truly adapted to reallife domains, and not to their idealisation, but it can be done with a high standard of rigour. This idea provides by itself no methodology; at least, endorsing it means to stop looking for oversimplistic solutions where they obviously do not work.
References 1. Chein, M., Mugnier, M-L.: Conceptual Graphs: Fundamental Notions. Revue d'Intelligence Artificielle vol.6 n~ (1992) 365-406 2. Computational Intelligence. Special Issue on Non-Literal Language (D.Fass, J.Martin, E.Hinckelmann eds.) vol.8 n~ (Aug.1992) 3. Gayral, F., Kayser, D., L6vy F.: Quelle est la couleur du feu rouge du Boulevard Henri IV ? in R6f6rence et anaphore, Revue VERBUM tome XIX n~ (1997) 177-200
48 4. Kayser, D.: Une s6mantique qui n'a pas de sens. Langages n~ (Septembre 1987) 33-45 5. Kayser, D.: Le raisonnement h profondeur variable. Actes des journ6es nationales du GRECO-P.R.C. d'Intelligence Artificielle, F,ditions Teknea, Toulouse (1988) 109-136 6. Kayser, D.: Terme et d6notation. La Banque des Mots, n ~ sp6cial 7-1995 (1996) 19-34 7. Kayser, D.: La s6mantique lexicale est d'abord inf6rentielle. Langue Fran~aise n~ "Aux sources de la polys6mie nominale" (P.Cadiot et B.Habert eds.) (Mars 1997) 92-106 8. Kayser, D., Coulon, D.: Variable-Depth Natural Language Understanding. Proc. 7 th I.J.C.A.I., Vancouver (1981) 64-66 9. Lesniewski, S.: Sur les fondements de la math6matique (1927) (trad.fr. par G.Kalinowski, Hermes, Pads, 1989) 10. Montague, R.: Formal Philosophy (R.Thomason, ed.) Yale University Press (1974) 11. Nunberg, G.D.: The Pragmatics of Reference. Indiana University Linguistics Club, Bloomington (Indiana) (June 1978) 12. Pustejovsky, J.: The Generative Lexicon. The MIT Press (1995) 13. Unger, P.: There are no ordinary things. Synthese vol.41 (1979) 117-154
M.-L. Mugnier and M. Chein (Eds.): ICCS’98, LNAI 1453, pp. 3-14, 1998 Springer-Verlag Berlin Heidelberg 1998
4
J.F. Sowa
Conceptual Graph Standard and Extensions
5
6
J.F. Sowa
Conceptual Graph Standard and Extensions
7
8
J.F. Sowa
Conceptual Graph Standard and Extensions
9
10
J.F. Sowa
Conceptual Graph Standard and Extensions
11
12
J.F. Sowa
Conceptual Graph Standard and Extensions
13
14
J.F. Sowa
Executing Conceptual Graphs Walling R. Cyre The Bradley Department of Electrical and Computer Engineering Virginia Tech Blacksburg, VA 24061-0111
[email protected]
This paper addresses the issue of directly executing conceptual graphs by developing an execution model that simulates interactions among behavioral concepts and with attributes related to object concepts. While several researchers have proposed various mechanisms for computing or simulating conceptual graphs, but these usually rely on extensions to conceptual graphs. The simulation algorithm described in this paper is inspired by digital logic simulators and reactive systems simulators. Behavior in conceptual graphs is described by action, event and state concept types along with all their subtypes. Activity in such concepts propagates over conceptual relations to invoke activity or changes in other behavioral concepts or to affect the attributes related to object type concepts. The challenging issues of orderly simulation of behavior recursively described by another graphs, and of combinational relations are also addressed. Abstract.
1 Introduction Conceptual Graphs have been used to represent a great variety of knowledge, including dynamic knowledge or knowledge which describes the behavior of people, animate beings, displays and mechanisms. In simple graphs it is not difficult to mentally trace possible activities and decide if the situation is modeled correctly, and the anticipated behavior is described. In complex and hierarchical graphs, however, this may not be practical so that validation of the description must be carried out by simulation or reasoning. From another viewpoint, simulation is useful to predict the consequences of behavior described by a conceptual graph. In this paper, mechanics for simulation by executing conceptual graphs are presented. As an example of conceptual graphs execution, consider the graph of Figure 1 which describes the throwing of a ball. Suppose one wishes to execute or simulate this graph to observe the behavior it describes. As discussed in the next section, most researchers have suggested extending conceptual graphs with special nodes called actors or demons to implement behavior. Instead, consider what is necessary to execute this graph as it is. First, the throw action must be associated with some underlying procedure or type definition that knows what types of concepts may be related to it, and how the execution of the throw action affects these adjacent
52 concepts. In this case, executing a throw should only change the position attribute of the ball from matching that of Joe (100,35) to that of Hal (200,0) and change the tense of throw from future to past. Note that this situation has been modeled so that only attributes of concepts are modified. Had the position concept of the ball been coreferent with Joe's position, then it would be necessary to necessary for the throw procedure to modify the structure of the graph by removing the position link of the ball from Joe's position to Hal's position. Since the graph is a data structure, modifying it is not a problem. In the discussions that follow, it will be assumed that action procedures only act on the values of attributes, and that these values may be rewritten multiple times. ~
(100,350)
t
Fig. 1. A Description of a Behavior In this discussion, throw was assumed to have a procedure defined for it in a library of concept procedures. Such a Liberia can easily get out of hand, so it is more desirable to have a type definition for throw in terms of a modest set of primitive actions which copy, replace, combine or operate only on values of attributes. Here, the type definition would have only a copy operation from the agent position concept to the object position concept. Figure 1 only has one isolated behavioral concept: throw. The conceptual graph of Figure 2 provides a more interesting example in which the execution of actions and events have effects on one another. One would like to execute or simulate this description by specifying an initial condition, say that action 1 is active, the state is true and the variable has the initial value of zero. Action 1 generates event 2, which in turn deactivates action 1 and initiates the increment action. The increment action reads its variable's value attribute, increments it and returns the sum as the result. Starting the increment also generates event 4 if it is enabled by the state being true. Firing event 4 terminates the increment and re-initiates action 1. The example of Figure 1 considered a single action, and its procedure or definition needed to know what to do with the possible adjacent concepts. Figure 2 has relations such as generator, terminator, intiator and enabler, which relate actions, events and states. As described later, to simplify the simulator, these and similar types of relations can be processed uniformly regardless of the subtypes of
53 actions events and states they are incident to. Only actions need to have 'personalized' procedures. In the following sections, related work by other researchers is considered. Following that, a simulation algorithm is described, including it's supporting mechanisms (data types), it's simulation cycle, and how conceptual relations among behavioral concept types affect the execution of graphs.
~
event: #2 F
I action: #l
tincrement: #3 I
/
t~minat~176176 7 event: #4 ~
s
nerat0 r
~
state: ~
~
~,
~
d
~
variable: #6 1 ~ ( . ~
Fig. 2. An Example Graph
2 Related Work In 1984, Sown stated that "Conceptual Graphs represent declarative information." and then went on to describe " ... a formalism for graphs of actors that are bound to conceptual graphs." These actor nodes form (bipartite) dataflow graphs 7 with value type concepts of conceptual graphs. The relations between the actors and concepts are input_arc and output_arc to the actors. Sown described an execution model for computing with conflict-free, acyclic dataflow graphs using a system of tokens. Actors can be defined recursively or by other graphs with actors. This model only allows single assignments (of referents) to (generic) value concepts. While this view of executing conceptual graphs has the computational power of dataflow models, functional dataflow graphs are not the most popular model of computation, and they require the appendage of a new node type (actors) to conceptual graphs. In addition, dataflow models are not easily derived from most natural language descriptions. In the present paper we show an execution model for general conceptual graphs without special actors. Other models of computation were considered by Delugach, including state transition models 5,6. Another type of node, called 'demon' was added to conceptual graphs to account for the problem of states. The argument is that if a conceptual graph is to be true, and a system can be in only one state at a time, then
54 (state) concepts must be created and destroyed when transitions occur. This approach was extended recently by the introduction of assertion types and assertion events 12. While demon nodes or assertion events offer the attractive capability of modifying the structure of a conceptual graph, they are external to conceptual graphs as actors are. Here, we avoid having to create and destroy states, by simply marking them as being true or false (negated). The actor graphs and problem maps of Lukose 10 are object-oriented extensions of conceptual graphs to provide executability. An actor graph consists of the type definition of an a c t concept supplemented with an actor whose methods are invoked by messages. Execution of an actor graph terminates in a goal state which may be a condition for the execution of other actor graphs. Control of sequences and nesting of actor graphs are provided by problem maps. While this approach does associate executable procedures with a c t concept types, no mention is given to event and proposition types. The application of conceptual graphs to governing agents, such as robots, was introduced by Mann 11. A conceptual database includes schemata of actions the agent can perform. Commands in the form of conceptual graphs derived from natural language expressions are unified with schemata to evoke behavior. The behavior itself is produced by programs associated with demon concepts in the schemata. At the same time, the present author considered the visual interpretation of conceptual graphs, including the pictorial depiction of their knowledge 3. Comments were included on animating displays generated from conceptual graphs. Animation would be produced by animator procedures associated with action and event type concepts. In this case, a conceptual graph would govern a display engine rather than a robot. While both of these proposals, execute conceptual graphs, each is rather specialized. Recently, simulation of conceptual graphs has been considered more generally 1. This approach considers actions, states and events, where the underlying execution model is a state transition system. Action concepts are preconditioned by states and events. These actions can be recursively defined as sets of actions joined by temporal relations and conditioned by states and events. Events are changes in the truth of states. These state changes are described by links to transition concepts which, in turn, are invoked by actions through 'effect' relations. A simulation step consists of identifying the set of actions whose preconditions are true, and selecting one for execution to advance the simulation. Time apparently advances with each time step. The user is consulted to resolve indeterminacy due to multiple enabled actions in a step. Simulation also detects unreachable actions and inconsistencies. The execution model we describe treats states and events more generally and considers the interaction between behavior concepts (actions, events, states) and values or entities. Our set of general concept types and the simulation algorithm were developed through an examination of modeling notations for computer systems rather than from considering human behavior. As discussed later, behavioral models are not limited to computer system behavior. Since the present execution model is based on computer systems 2, it is appropriate to review here some approaches used in computer simulators. This will
55 be limited to event-driven simulators. In computer logic simulators, the only possible events are changes in values (signals). At a given point in time, one or more signals may change. The behavior of each circuit having a signal change event on any input is simulated to determine output signal events. An output event consists of a value change and the time the event will occur due to delay in the circuitry. These events are posted to a queue. Once all output events due to current events have been determined, the next future event(s) is found from the event queue and simulation time is advanced to that time so that event can be processed. If the next event occurs at the present time, the simulation time is not advanced. In a simple simulator, the code that simulates behaviors of circuits is contained n a library. In more general digital simulators 9, the user may write processes which respond to input events and produce output events. The procedures of all processes execute once upon initial startup of the simulator. This is appropriate since hardware is always processing its inputs as long as power is applied. After startup, procedures execute only when stimulated. In a simulation cycle, all stimulated processes complete before the next cycle begins. A very general modeling notation called Statecharts is supported by a more elaborate simulation procedure 8. Our simulation algorithm was inspired by this approach. Statecharts are founded on finite state machines. The states may be hierarchical, consisting in turn of transition diagrams. Parallel compound machines are supported so the system can be in multiple sub-states at a time. Each transition can be triggered by an event and predicated on a condition. Both conditions and events may be Boolean combinations of other conditions and events, respectively. When a transition occurs, an action may be stimulated. Other actions may be stimulated by events as long as the system is in a particular (enabling) state. Such action invocations may be predicated on other conditions. In addition, actions and events may generate new events. The objective of the present paper is to show how conceptual graphs can be executed or simulated by an approach such as this.
3 Simulation Approach 3.1 Execution Semantics of Concept Types To begin to develop a general conceptual graph simulator, it is necessary to first consider the types of concepts that will participate in the simulation. In the present discussion, we consider the top-level type hierarchy of Figure 3. The behavior types actively participate in a simulation. Objects are passive elements whose attributes, such as value for variable and position for entity, can be affected by the execution of action types. State concepts describe the status of what is described by a conceptual graph, and may be pre-conditions on the execution of actions or the occurrence of events. States may be defined by the activity of actions or their relationships among attributes of objects, such as the values of variables and the positions of objects. Events are instantaneous and mark changes in activity of actions or the attributes of objects.
56 entity object ~
variable action
behavior ~
e
v
e
n
t state value
attribute ~
position delay
Fig. 3. Top-Level Concept Type Hierarchy Since conceptual graph theory allows concepts to be defined n terms of conceptual graphs, such recursively defined concepts must be accounted for in executing a graph. Consider an action that is defined by a graph that includes actions, events and states. When the defined action is executed, its graph must be executed completely before the action is completed and it's consequences may be propagated on. In order to show that our approach is quite general, some traditional concept types 13 are interpreted in terms of the simulator type hierarchy of Figure 3, as shown in Table 1. Note that some concept type names conflict. For example, Sowa's event type is classified as an action here because it has an agent and does not exclude a duration. Our events have no duration and are only discontinuities in actions. The type believe is an action (operation) whose operand is a belief or proposition (state). In this paper, we will only discuss the attributes value of variables and position of entity. Note however, that all discussions are extended to any attribute, such as the age or the color of an entity. Conceptual relations describe the interaction among these concept types and directs the simulator in assigning attributes and generating events during simulation. The interpretation of conceptual relations during simulation is described in detail in a later section.
3.2 Simulation Support Mechanisms The simulation algorithm described here is event-driven. Since event is a concept type in the type hierarchy, it is useful to define incident as the element processed by
57 the simulation algorithm. Each incident is associated with a specific concept of the conceptual graph(s) being simulated, and has five attributes which specify: the concept type, the concept identifier the simulator time, the level of recursion and the type of operation to be performed. The simulator time is measured with respect to the beginning of the simulation, which occurs at time zero. The simulator may perform many cycles at a given simulator time. That is, a cycle does not necessarily advance the simulation time, and simulation time cannot be reversed. Often, incidents generated at the present time must be processed in the present time (without delay). Such incidents are assigned a zero for simulation time. The types of incidents generated and processed by the simulator are listed in Table 2. The effects of these types of incidents are described later. Table 1. Traditional Concept Types
Traditional Type
Simulator Type
act age animal believe belief message color communicate contain event proposition teacher think warm
action attribute entity action state variable attribute action state action state entity action attribute
The simulator uses the collection of lists shown in Table 3 to keep tract of incidents and the state of the conceptual graph. The Queue contains incidents that have not yet been processed by the simulator. The Current list contains the incidents to be processed during the current simulation cycle, and the Future list contains incidents generated during the current cycle and to be processed in a future cycle. The Current incidents are selected from Queue at the beginning of a cycle, and the Future incidents will be added to the Queue at the end of the cycle and before the next cycle begins. Which action concepts are active is kept track of by the Activity list. Activity describes the status of an action; an action may be active, but may not do anything during a given cycle. Those actions which must be executed during the current cycle are listed in the Execute list. The True_states list keeps track of which states are true at the present time. A state concept may reflect
58 the activity of an action, or may represent conditions defined by relationships among attributes of objects, such as values of variables or positions of entities. The Value and Position lists keep track of the current values of variable concepts and the positions of entity concepts. In Prolog, lists are convenient structures for maintaining the status of the conceptual graph. In other implementation languages, lists of pointers might be used instead, and some lists might be eliminated entirely. For example, values and positions can be left in referent fields of concepts, but then, the graph would have to be scanned each cycle. Similarly, the status of action concepts and the truth of state concepts can be represented by the unary relations (active) and (not), respectively, incident to the concepts.
Table 2. Types of Simulation Incidents
Incident Type
Parameters
Function
action
type, id, time, level, operation
event
type, id, time, level, none
state
type, id, time, level, operation
variable
type, id, time, level, new_value
entity
type, id, new_position
time,
level,
Starts, stops or resumes an action. Fires an event. Enters or exits a state (makes true or false). Assigns a new value. Assigns a new position.
Table 3. Working Lists used by the Simulator
List
Contents
Queue
Pending incidents
Current
Incidents to be processed in the current cycle
Future
Future incidents produced in the current cycle
Activity True_states
Action concepts that are currently active State concepts that are true
Values
Pairs of variable concepts and their current values
Positions
Pairs of entity concepts and their current positions
Execute
Action concepts to be executed in the current cycle
59 3.3 The Simulation Cycle A simulation cycle consists of the following steps: 1) Get current incidents: The list of incidents, Current, to be processed during the current cycle is extracted from the incidents Queue. All incidents at the current level of recursion and having a zero time are extracted for processing in the current cycle. If no incidents with zero time exist at the current level, then the level is raised. If no incidents with zero time exist at the top level, simulation time must be advanced. Then, the incident(s) with the earliest time and the deepest level is extracted for processing during this cycle. The simulation level is set to that level and simulator time is advanced to that time. Current incidents are deleted from the Queue. 2) Update attributes: Process attribute (value and position) change incidents by changing these attributes of the affected concepts. This may result in an immediate change in whether some states (conditions) are true, so the True_states list may be affected. Incidents are deleted from the Current list as they are processed. 3) Process remaining incidents: Process state, action and event incidents from the Current list. The order of processing these incidents is immaterial since any consequences are placed in the Future list for processing during a later simulation cycle. 4) Execute actions. Finally, action concepts to be executed during the current cycle are executed in this step. This must be last, since event occurrences and state changes stimulate and precondition activities, respectively. 5) Update Oueue: Append the Future list to the Queue. The manner of processing the various types of incidents is described in the following paragraphs. Note again that an incident is processed only if the simulator time has caught up with the incident time. Attribute (value and position) incidents specify changes in values of variables and positions of entities, and the time they are to occur. In each case, the affected concept is located and its appropriate attribute is changed, both in the graph and in the Values and Positions lists. These incidents must be processed before action and event incidents, since value and position changes can affect the truth of preconditions for executing actions and firing events. Two types of state incidents are defined. An enter state incident causes the state concept to be added to the True_states list, and an exit incident removes the state concept from this list. State incidents are generated explicitly by actions, and so do not account for changes in status of state concepts due to changes in activity of actions and the attributes of variables or entities. For example, the state incidents
60 incident(service, #, _,exit) and incident(idle, #, _,enter) are indicated by the expression, "Reset changes the mode from service to idle." An event incident fires the indicated event concept in a conceptual graph. The consequences of firing an event are determined by the conceptual relations incident with the event. Incidents generated through conceptual relations are described shortly. Action incidents change the activity of action concepts by adding them to or removing them from the Activity list. A stop incident removes the action. A start incident or r e s u m e incident places the action onto the Activity list. A s t a r t incident invokes an execution of the action with initial values and positions for associated variables and entities. A resume incident invokes an execution of the action using the last values or positions. This supports persistence in actions. Once incidents have been processed and changes in objects and states are completed, the action concepts stimulated into execution are processed. Action concepts may have operands they operate on to produce results. These will be value or position attributes of other concepts. If an action is executed by a start incident, it is reset to initial values/positions before execution begins. Otherwise, the current values/positions are used. Execution may not only generate value or position incidents with respect to result concepts, but may also generate event, state and other action incidents. To generate value and position events, a procedure for transforming inputs to outputs must be available. Rather than defining actor or demon nodes as part of an extended conceptual graph to account for these procedures, we follow the pattern of digital simulators that have libraries of procedures for simulating the behavior of action concepts. That is there are a collection of primitive actions which the simulator knows how to process. Other actions can be recursively defined in terms of schemata employing these primitive actions. So, to execute a complex action, its schema is executed. But, the schemata may take multiple cycles to execute. To satisfy this requirement the simulator has levels of cycles. That is the function of the level parameter of the incidents. All current incidents at the deepest level of recursion must be completed before any higher-level incidents are processed. It is possible that some primitive actions may be invoked at different levels at the same simulation time. The present simulation strategy executes the action at the deepest level first. The simulation cycle is not completed until all action concepts have completed their execution, that is, suspended themselves. Self-suspension here means the computation is complete, and has nothing to do with terminating the activity of the action, unless the action generates a stop incident to itself.
3.4 Conceptual Relations and the Production of New Incidents As described thus far, the simulator consumes incidents but produces none, so a simulation would soon die out. New incidents are produced by the conceptual relations incident to firing events and executing actions. Table 4 shows a collection of relation types among behaviors and objects. Although their names may be
61
unfamiliar, these relations account for most interactions among concepts, with the exception of attributes. Only binary relations are shown in the table; some ternary relations will be considered later. The challenge in developing a model for executing conceptual graphs is to determine which incidents are generated by the various relations, and how combinations of relations incident with concepts interact.
Table 4. Signatures of Selected Conceptual Relations
Has
entity
entity
part
event
state
action
event
state
attribute
status
position color age value structure
i part
variable action
variable
agent patient source destination
operand result
cause deactivator temporal part generator
initiator resumor terminator temporal trigger temporal part make_true entrance make_false exit
if
enabler
part
In Table 4, a relation is interpreted as the row concept 'has relation' with the column concept, such as an event has initiator action. This interpretation yields some unusual relation type names, but is traditional in conceptual graphs, and is necessary when considering combinations of relations incident with behavior concepts. First, consider relations actions have with behaviors (Row 3 in Table 4). When an event incident to an initiator relation fires, it will generate an action start incident for the related action, with zero time and the current level of recursion, e.g. incident(action, Id, 0, L, start). Similarly, the suspendor and resumor relations will generate stop and resume action incidents for their related actions. A single action incident may not be sufficient to stimulate the execution of the action. If the action has one or more i f relations with states and the states are not true (on the True_states list), then the action will not execute. In addition, an action must have an action incident on each of its initiator or resumor relations to execute, since conceptual graph theory interprets multiple relations of the same type incident to a concept as conjoined (ANDed). Disjunction of relations is not conveniently represented in conceptual graphs. For this purpose, we define new relations or and x o r to synthesize artificial disjunctive concepts. The relation x o r indicates exclusive-or. Since complex combinations cannot be expressed this way, introduction of artificial concepts is necessary, as in the example graph in Figure 4, which indicates that action A executes only if states S1 and $2 are true and if a start
62 incident was produced from event E5 as well as event E3 or E4 or both E2 and E2. That is the condition (S1 and $2 and E5 and ((El and E2) or E3 or E4)) Event event: *1 was artificially introduced to represent the event that E3 or E4 or event: *2 occurred. Event event: *2 is the event that E1 and E2 occur simultaneously.
action, A (initiator)-> event: *1 (or) -> event: *2 (part) -> event: E l (part) -> event: E2, (or) -> event: E3 (or) -> event: E4 (initiator) -> event: E5 (if) -> state: S1 (if) -> state: $2,. Fig. 4. Complex Conditioning of Action Execution.
Which types of incident are generated by some of the relations identified in Table 4 are shown in Table 5. Thus far the generation of the time parameter of incidents has not been addressed, so all incidents generated with the above relations have zero (present) time and the simulation time never advances. To introduce time, it is necessary to add a set of ternary relations comparable to the relations of Table 4. For example the relation initiator_after has the signature shown in Figure 5.
action
-> (initiatoLafter) 1 - > event 2 -> delay,.
Fig. 5. Signature for initiator_after relation. During firing of the event, then, incident(action,#,T,start) is added to the Future list, where the value of T is the current simulation time plus the delay. Table 4 also shows temporal relations among actions and events. These may include interval relations, endpoint relations and point relations 4. Although temporal relations seem to imply causality, we interpret them here as constraints. For example, action: A1 -> (starts_when finishes) -> action: A2
63 does not cause a start action incident for action A1 to be generated when action A2 terminates. Instead the simulator must check when action A1 is initiated that action A2 has terminated, and post an exception if this is not the case. Alternatively, temporal relations could be interpreted as causal, in which case the temporal and other behavioral relations can be checked statically for consistency. Similarly, duration relations incident to actions can be used as constraints to check if a stop incident occurs with the appropriate delay after a start incident, or the duration can be used when the action starts to generate a stop incident that terminates the action.
Table 5. Incidents Produced by Conce ~tualRelations
Concept activity
Incident Relation
Consequent Incident
Fire event
initiator
action start
resumor
action resume
Execute action
terminator
action stop
trigger
event
entrance
state enter
exit
state exit
cause
action start
deactivator
action stop
generator
event
maketrue
state enter
make_false
state exit
4 Conclusions Mechanisms for simulating hierarchical conceptual graphs without introducing special nodes such as actors or demons have been described. To support execution of graphs, concept types are classified as behavior (action, event, state), object (entity, variable) and attribute. Execution is performed by procedures associated with action types that operate on object attributes, and by procedures associated with conceptual relations among behavior concepts. Although the simulation strategy was inspired by digital system simulators, the approach has been show to be applicable to general concept types and relations.
64
5 Acknowledgments This work was funded in part by the National Science Foundation, Grant MIP-9707317.
References 1.
.
3.
.
.
6.
.
8.
9. 10. 11.
12. 13.
C. Bos, B. Botella and P. Vanheeghe, "Modelling and Simulating Human Behaviours with Conceptual Graphs," Proc. 5th Int'l Conf. on Conceptual Structures, Seattle, WA, 275-289, August 3-8, 1997. Walling Cyre "A Requirements Language for Automated Analysis," International Journal of Intelligent Systems, 10(7), 665-689, July, 1995. W. R. Cyre, S. Balachandar, and A. Thakar, "Knowledge Visualization from Conceptual Structures," Proc. 2nd Int'l Conf. on Conceptual Structures, College Park, MD, 275-292, August 16-20, 1994. W. R. Cyre, "Acquiring Temporal Knowledge from Schedules," in G. Mineau, B. Moulin, J. Sowa, eds., Conceptual Graphs for Knowledge Representation, Springer-Verlag, NY, 328-344, 1993. (ICCS'93) H. Delugach, "Dynamic Assertion and Retraction of Conceptual Graphs," Proc. 7th Workshop on Conceptual Structures, Binghamton, NY, July 11-13, 1991. H. Delugach, "Using Conceptual Graphs to Analyze Multiple Views of Software Requirements," Proc. 6th Workshop on Conceptual Structures, Boston,MA, July 29, 1990. J. Dennis, "First Version of a Data Flow Procedure Language," Lecture Notes in Computer Science, Springer-Verlag, NY, 362-376, 1974. D. Harel and A. Naamad, The STATEMATE Semantics of Statecharts, i-Logix, Inc. Andover, MA, June 1995. R. Lipsett, C.F. Schaefer & C. Ussery, VHDL: Hardware Description and Design, Kluwer Academic, Boston, 1989. D. Lukose, "Executable Conceptual Structures," Proc. 1st Int'l Conf. on Conceptual Structures, Quebec City, Canada, 223-237, August 4-7, 1993. G. Mann, "A Rational Goal-Seeking Agent using Conceptual Graphs," Proc. 2nd Int'l Conf. on Conceptual Structures, College Park, MD, 113-126, August 16-20, 1994. R. Raban and H. S. Delugach, "Animating Conceptual Graphs," Proc. 5th Int'l Conf. on Conceptual Structures, Seattle, WA, 431-445, August 3-8, 1997. J. Sowa, Conceptual Structures, Addison-Wesley, Reading, MA, 1984.
From Actors to Processes: The Representation of Dynamic Knowledge Using Conceptual Graphs Guy W. Mineau Department of Computer Science Universit6 Laval Quebec City, Canada tel.: (418) 656-5189 fax: (418) 656-2324 email:
[email protected] The conceptual graph formalism provides all necessary representational primitives needed to model static knowledge. As such, it offers a complete set of knowledge modeling tools, covering a wide range of knowledge modeling requirements. However, the representation of dynamic knowledge falls outside the scope of the actual theory. Dynamic knowledge supposes that transformations of objects are possible. Processes describe such transformations. To allow the representation of processes, we need a way to represent state changes in a conceptual graph based system. Consequently, the theory should be extended to include the description of processes based on the representation of assertions and retractions about the world. This paper extends the conceptual graph theory in that direction, taking into account the implementation considerations that such an extension entails. Abstract.
1 Introduction This paper introduces a second-order knowledge description primitive into the conceptual graph theory, the process statement, needed to define dynamic processes. It explains how such processes can be described, implemented and executed in a conceptual graph based environment. To achieve this goal, it also introduces assert and retract operations. The need for the description of processes came from a major research and development project conducted at DMR Consulting Group in Montreal, where a corporate memory was being developed using conceptual graphs as its representation formalism. Among other things, the company's processes needed to be represented. Although they are actually described in a static format using first-order conceptual graphs, advanced user support capabilities will eventually require them to be explained, taught, updated and validated. For that purpose, we need to provide for their execution, and thus, for their representation as dynamic knowledge. Dynamic knowledge supposes that transformations of objects are possible. Processes describe such transformations. To represent processes, we need a way to describe state changes in a conceptual graph based system. We decided to use assertion and retraction operations as a means to describe state changes. Therefore, the definition of a process that we put forth in this paper is based on such operations. Generally, processes can be described using algorithmic languages. These languages are mapped onto state transition machines, such as computers. So, a
66
process can be described as a sequence of state transitions. A transition transforms a system in such a way that its previous state gives way to a new state. These previous and new states can be described minimally by conditions, called respectively pre and postconditions, which characterize them. The preconditions of a transition form the smallest set of conditions that must conjunctively be true in order for the transition to occur; its postconditions can be described in terms of assertions to and retractions from the previous state. Thus, transitions can be represented by pairs of pre and postconditions. Processes can be defined as sequences of transitions, where the postconditions of a transition match the preconditions of the next transition. The triggering of a transition may be controlled by different mechanisms; usually, it depends solely on the truth value of the preconditions of the transition. This simplifies the control mechanism which needs to be implemented for the execution of processes; therefore, this is the approach that we advocate. Section 2 reviews the actual conceptual graph (cg) literature on processes. Section 3 presents an example that shows how a simple process can be translated into a set of transitions. Section 4 describes the process statement that this paper introduces. Finally, because of its application-oriented nature, this paper also addresses the implementation issues related to the engineering of such a representation framework; section 5 covers these issues.
2 T h e C G L i t e r a t u r e on P r o c e s s e s Delugach introduced a primitive form of demons in 1. Demons are processes triggered by the evaluation of some preconditions. Delugach's demons take concepts as input parameters, but assert or retract concepts as the result of their actions, contrarily to actors which only compute individuals of a predetermined type. Demons are thus a generalization of actors. They can be defined using other demons as well. Consequently, they allow the representation of a broader range of computation. We extended these ideas by allowing a demon to have any cg as input and output parameters. Consequently, our processes are a generalization of Delugach's demons. We kept the same graphical representation as Delugach's, using a labeled double-lined diamond box. However, we had to devise a new parameter passing mechanism. We chose context boxes since what we present here is totally compatible with the definition of contexts as formalized in 2. Similarly to 3, we chose state transitions as a basis for representing a process, except that we do not impose to explicitly define all execution paths1; the execution of a process will create this path dynamically. This simplifies the process description activity. There is much work in the cg community about the extension the cg formalism to include process related primitives 4, 5, 6, 7, 8. One of the main motivation behind these efforts, is the development of an object oriented architecture on top of a cg-based system 12. As we advocate, 7 focuses on Simple primitives to allow the modeling of processes. The process description language that we foresee could be extented to include high-level concepts as proposed in 7. In 9, we explain how our two approaches complete each other. Also, 12 uses transitions as a basis for describing behaviour and 11 uses contexts as pre and postconditions for modeling behaviour. The work presented here is An execution path is defined as a possible sequence of operations, i.e., of state transitions, according to some algorithm.
67 totally compatible with what is presented in these two papers, but furthermore, 1) it adds packaging facilitly, 2) it deals with implementation details that render a full definition and execution framework for processes, and 3) it is completely compatible with the definition of contexts as formalized in 2, providing a formal environment for using contexts as state descriptions. In what follows, we present a framework to describe processes in such a way that: 1) both dynamic and static knowledge can be defined using simple conceptual graphs (in a completely integrated manner), 2) they can be easily executed using a simple execution engine, and 3) inferences on processes are possible in order to validate them, produce explanations and support other knowledge-dependent tasks.
3 From Algorithms to Pre and Postcondition Pairs We believe that a small example will be sufficient to show how a simple process, the iterative factorial algorithm, can be automatically translated into a set of pre/postcondition pairs. From this example, the definitions and explanations given in sections 4 and 5 below will then become easier to present and justify. Let Figure 1 illustrate the process that we want to represent as a set of pre/postconditions pairs. Since a process relies on a synchronization mechanism to properly sequence the different transitions that it is composed of, and since we wish to represent transitions only in terms of pre and postconditions (for implementation simplicity), we decided to include the sequencing information into the pre/postconditions themselves 2. With an algorithmic language such as C, variable dependencies and boolean values determine the proper sequence of instructions. Then it is rather easy to determine the additional conditions that must be inserted in the pre and postconditions for them to represent the proper sequence structure of the algorithm. Without giving a complete algorithm that extracts this sequence structure, Figure 2 provides the synchronizationgraph of the algorithm of Figure 1. The reader will find it easy to verify its validity, knowing that all non-labeled arcs determine variable dependencies between different instructions, that arcs marked with T and F indicate a dependency on a boolean value, and that arcs marked as L indicate a loop. i0: int fact(int n) ii: { int f; 12:
int i;
13:
f = i;
14: 15:
i = 2; while (i <= n)
16:
{
17: 18: 19:
f = f . i; i = i + i;
} return f; }
Fig. 1. The iterative version of the factorial algorithm written in C. 3 2 Any sequencing mechanism that can easily be predicated can be translated to pairs of pre and post conditions. The presented mechanism only implements the SWS and FBS relations of 13; other temporal relations may be expressed in terms of these two relations whenever a process can be subdivided in smaller subprocesses. 3 For simplicity, n is known to be equal or greater than 0.
68 Each algorithmic instruction will be represented as a small set of transitions, called transition rules. The synchronization graph is useful to update the preconditions of
(••
1~
~ 16
~. 1~ L'~
Hg. 2. The synchronization graph of the algorithm of Figure 1. these rules, making sure that they include the information as to when they should fire. Also, since we do not wish to retire rules once they have been executed (except for loops), the corresponding postconditions will make sure that their preconditions will not be true again. Synchronization is achieved through assertions and retractions. 4 line 10: the entry point of the algorithm The triggering of the process will be possible by the assertion of a graph stating that line 10 is to be executed. A process will be defined using variables (as done below), but it will be executed only after the instantiation of all concepts representing line numbers. The triggering of the process would then be done through the assertion of a graph where the concept refers to the first line of the process to be executed (see Figure 3). Having individuals unique to a process will ensure that only the transitions of this process will be triggered 5. The transition rule associated with line 10 (see below) is composed of a single pair of pre/postconditions 6. The preconditions include a graph that corresponds to the input parameter of the algorithm. Section 5 below presents how parameter passing can be implemented. The postconditions include one assertion and one retraction (the first two graphs) which are meant to prevent this transition rule to fire again.
Line:#10 ~ ~ ) Fig. 3. The assertion needed to trigger the process. pre 1:
I Integer ~
Variable:*n
4 In our example, variables dependencies are used to determine possible execution sequences; we chose to reference them through line numbers. 5 In this paper, we illustrate the definition of a process, not an actual individual process ready for execution. Consequently, all figures (but Figure 1) display generic concepts instead of individuals. 6 In order to associate different pre and postconditions together, indexes are used. Also, all graphs in a postcondition are asserted, except those preceded by the negation sign, which are retracted. Of course, assertions and retractions may be without effect as asserted and negated graphs may already be known to be true or false respectively.
69
Line: *10 ~ ~ ) postl:
Line: *1o I Line: *1o
line 1 3 : f
=
ILine:*13
~ ~ ~ )
Line:*14
~ ~ ~ )
1; and line 14: 5. =
2;
An assignment operation is represented by two transition rules because the assigned value may be different (or not) from the actual value of the variable. Here, the assigned value could be determined directly from the algorithm. Note that line 14will not be set to "to do" after 13, since it depends on some boolean value, as shown by the T marked arrow in the synchronization graph of Figure 2. Because of space limitation, only the transition rules associated with line 13 are shown below; those of line 14 (pre4, post4, pre 5 and posts) will not be shown since they are very similar to those of line 13.7 pre2:
Line: "13 Line: *10 ~ ~ ) Integer:*z2
~
Variable: *f
Integer: 1
I
Boolean: True
Here, we defined one actor for each basic computation normally provided by a computer, such as !=, <=, +, *, etc. They are in fact procedures which are called when activated. Their activation is done when their input concepts are all instantiated to individual concepts. Then the computation is triggered and their output concepts are instantiated to the computed value.
70 post2:
I Integer: *z2 I Integer:l
~ @ ~
Variable: *f
I
Variable: *f
I
ILine:*13 ~ I Line:*13 ~
/
pre3:
I Integer: *z2
Variable: *f
Integer: 1
Boolean: False I Line: "13 Line: *1o post3:
I Line: "13 Line:*13 ~ ~ ) line l5:
while
(i
<=
n)
The loop requires two transition rules since its condition evaluates to a boolean value. Depending upon this evaluation, the set of instructions in the body of the loop will be set to "to do" or not. Also, since the loop will not be completed until the condition evaluates to false, we can not set the status of line 15 to "done" until then. Please note that the last two graphs in post6 are meant to reset the transition rules that are part of the loop, allowing them to retire (for the next iteration).
71
pre6:
~
I Line:"15 I Line:"14 ~1"~,~~ Integer ~
Variable:*n I Variable:*i
Integer Boolean:True I post6:
Line:"15 I Line:*16 ~-~to.~-d~) I Line:*16 ~91-'M~.~) ~ Line:*17 ~-Md~) pre7:
Integer
<5>q Variable:*n
Integer
Variable:*i
IBoolean:False I Line:*15 ~ ~ ) ILine:*14~
72 post7:
Line: "15 I Line: *15 ~ ~ ) I Line: *19 line ! 6 :
f
=
f
*
•
This instructionis an assigmnentwhichis doneafterthe expressionon the right side is evaluated.Onlythe firsttransitionrule associatedwill)I~, pre~and poslM,is shownbeh)w, becauseof spacelimilation. pre8:
I Integer:*z4 ~ q ~ ) ~
Variable:*f
Integer ~
Variable:*i I
Integer: *y4 I
I Boolean:True Line: *!~ ILine:*l~ ~ post8:
Integer: *z4 ~
Variable:*f
Integer: *y4 ~
Variable:*f I
Line: *l~
73
I Line: *16 ~
~
I Line:*17 ~ line 17: ~. = 5. + 1; This instruction is similar to the one in line i6. Its postcondition, however, will assert that line 15 has to be executed next (it must be marked "to do" again) since at the end of the loop the comlition (it"line 15 must be reevaluated. Again, because of space restriclions, we will not show pre./posh, and pre~Jposh j, the transition rules associated with 17. line 19: the exit point of the algorithm In posh2, the Iirsl graph indicates the end of the process, while the last graph represents the output parameter of the algorithm. In order to instantiate this graph to the computed value (contained in variable f), a graph to that effect is inserted in pre~2 (its last graph). Since coreference is global in a process definition, the value of f is passed on to posh2, producing the appropriate computed value as the output parameter of the process. prel2: Line: *Is Line: "19 Integer: *z5
Variable: *f
postl2:
I Line: '19 ILine:*19 ~ - - ~ I I,,eger:*z5 4 The
Process
I
Statement
Let us define a transition rule r i as a pair of pre and postconditions <prei,posti>. Figure 4 shows how a process can be defined. A process statement is accompanied by a list of transition rules which describe the process itself. This list is called the rule set of the process. This rule set can be produced automatically from the analysis of an algorithm, as illustrated in Seclion 3. When parameters are used, they are defined as separate graphs beibre the rule set, but are automatically incorporated into some transition rule. The input parameters
74 will appear in the preconditions of the first transition rule (the entry point of the process); while the output parameters will appear in the postconditions of the last transition rule (the exit point of the process) g. In our example, the first graph of pre 1 would be labeled u 1 while the last cg in postl2 would be labeled u 2. Figure 5 shows how the factorial algorithm could be defined as a cg process. p r o c e s s name(in 1 Ul; ... in n Un; out 1 Un+li ... o u t m Un+m) is: u 1 .... u n, Un+ 1 .... Un+ m {r i, Vi e a,b}
Fig. 4. The process statement. p r o c e s s fact(in 1 Ul; o u t 1 u 2) is: u 1, u 2 {r i, Vi ~ 1,12}
Fig. 5. The definition of the factorial process. In graphical form, a process is represented by a double-lined diamond box labeled with the name of the process 9. Its parameters each appear as a separate statement linked to the process symbol by an ingoing (for input) or outgoing (for output) arc. Each arc is indexed according to the process definition. Figure 6 shows how our factorial process is graphically represented.
STATEMENT: Ilnteger:*z5
I
STATEMENT:
Integer
Vaable:*n I
Fig. 6. The graphical representation of the factorial process. Provided that there is an agreed-upon ontology on process definition terms, a process symbol could be expanded to this other representation. Figure 7 shows such an expansion with regard to the vocabulary of Figure 8. With this particular vocabulary, four conceptual relations are introduced: pre, states, asserts and retracts, and four concepts are defined: Process, Statement, Assertion (a true statement) and Negation (a false statement). In terms of this vocabulary, the graph of Figure 6 could be expanded
For simplicity reasons, we suppose that a process has only one entry and one exit point. In the linear form, a process can be represented by its name between double angled brackets. For example, we would have: <
> to represent the factorial process. Parameters appear as statements (which can be negated by using the -, sign inside the box).
75 to the one in Figure 9. This is given just as an example of process expansion with regard to a pre-established vocabulary; of course, other expansions could be defined.
ASSO __ CSA
I ~o~o~
s~.
I
Fig. 7. An alternative representation for processes. T
/,,,,
Link
PROCESS STATEMENT 7 ~,,~ ASSERTION
NEGATION
'~'~ pre e~sStates ass
\
negates
Fig. 8. A simple ontology (concepts and relations) for the description of processes.
I ..oc~s~ ~ ~
+
STATEMENT: Ilnteger:*z6
I
STATEMENT: I
Integer
~ ~ b ~
Variable: *n I
Fig. 9. A possible expansion of the graph of Figure 6.
5 The Process S t a t e m e n t This section deals with two main issues relevant to the implementation of the framework proposed in this paper: the parameter passing (section 5.1) and the process call (section 5.2) mechanisms.
76 5.1 The Evaluation of Parameters The formal paremeters of a process, both input and output, are identified with indexes in the process statement. They are those graphs which appear before the rule set of the process. They are automatically inserted in the preconditions of the first transition rule of the process (for input parameters), and in the postconditions of the last transition rule (for output parameters). As shown by the example of Figure 6, each effective parameter is given as a separate statement linked by a numbered arc to the process for which it is a parameter. Since the arcs are directed and numbered, there is no confusion between input and output parameters. That way, and because input and output boxes contain only one cg, the effective and formal parameters of a process can be matched to one another unambiguously. Let us define KB, a knowledge base represented as a set of conceptual graphs, and let us define S(g), the set of conceptual graphs belonging to KB, which are specializations of some graph g of KB. Then, S(g) = {gi E KB I 3/1;i, a projection, such that gi = ~ i g } . The graphs of S(g) are said to be models of g. Let ~5: KB --~ P(KB), where P(KB) is the power set of KB, be a function that produces the models of any graph of KB, called its denotation set, such that ~Sg = S(g). Let e andf be two cgs of KB; and 8e and 8f be their denotation sets. Let us define the following three generalization relationships between e and f. If 3~, a projection, such that e = rotten egf; if egf then e =g f. Let e be a cg used as an effective input parameter of a process p, and f, its formal counterpart (used in the definition of process p). Let us suppose that one of these relationships holds: 1) e -g f. In the first case, since all graphs in ~Se would be included in ~if if f were to be asserted in KB, we assign 8e to 8f: 8 f ~-- ~Se. In the second case, f covers only a portion of e. We assign taSf, the subset of 8e that is covered byf: ~if ~-- {gi e ~e I 3re i, a projection, such that gi = ~if}. In any case, if ~Sf is empty, then f is negated. Process p can be executed only after the denotation sets of all its formal input parameters are computed 1~ If f is negated while it should not, this will prevent process p from being executed. Let us now define e, a cg used as an effective output parameter, and f, its formal counterpart. As the result of a process, e will be asserted n with regard to its computed counterpart f. If e >g f, then: ~Se ~ ~Sf. If e
1~ course this computation may be costly. Different strategies to achieve this computation and to the represent denotation sets may be adopted; they will not be discussed here. l J It could also be negated as the result of the process, in which case 8e must be empty.
77 should be computed from gi and g2 respectively, and asserted as this result. 12 The efficiency issues related to this mechanism fall outside the scope of this paper and will not be discussed here. 5.2 P r o c e s s Calls As seen previously, a process is described using generic concepts representing the variables of the process and the line numbers where the instructions are located in the algorithm. The scope of these concepts spans over the whole process description. This rules the coreference mechanism. Two overall principles should be enforced in order to avoid confusion when executing a process. First, the variables of a process are local to that process: no global variables are allowed. Second, the line numbers of a process should be different from the line numbers of any other processes. These two principles aim at enforcing the independence between processes, and it helps to reduce the complexity associated with the implementation of the execution engine. It consequently increases the reliability of the system. To make sure that these two principles are respected throughout the execution of a process, the following procedures must be applied when the execution of a process is required (i.e., when a process definition must be instantiated and executed). 1) Compute the
6 Conclusion and Future Developments This paper presents a simple representation framework for processes, based on pre and post conditions, that allows their integration into a cg-based system, and their easy implementation for execution. In such a framework, the emphasis is put on transformations of objects from their input to output states; other representations put the emphasis on some other characteristic such as the structure of the process itself ~2 In conventional programming Ifiel= 1. Here, we allow multiple transformations to take place. ~3 The framework that we propose in this paper is well adapted for execution in any rulebased system.
78 7. Our choice permits easy implementation of an execution engine, while providing a basis for comparing processes (subprocesses) on their pre and post conditions (which will be useful in a near future). With this aim in mind, for our needs, a process is better characterized in terms of its input and output, rather than in terms of its structure. However, we must acknowledge the fact that the proposed implementation would suffer from the same completeness and soundness problems as any rule-based system: are two postconditions conflicting? Are two preconditions interdependent? These are problems that, of course, still remain unsolved. Furthermore, even though not all process formalisms use variables and algorithmic primitives to synchronize their action, the point that this paper makes is that automatic translation from most process representation formalisms to transition rules is possible. The knowledge modeler can use the formalism that he or she is the most familiar with in order to describe processes; their representation using cgs can be automatically derived, offering full integration to a cg knowledge base. This should facilitate the associated knowledge modeling activities. Also, second-order knowledge on application domains, such as constraints on processes, could be represented as transition rules as well 10. Using the same execution engine, the execution of processes could undergo constraint validation without requiring the implementation of any particular facility. For these reasons, the development of a Conceptual Programming Environment (CPE) where imperative and logic programming coexist and complement each other, which is our long-term goal, could be easily developed. This would allow for explanations on processes to be generated, for processes to be simulated and validated, and so on, providing tremendous support not only to the knowledge modeler, but to the end users as well. Consequently, we think that the definition framework that we propose in this paper for the representation of dynamic processes is a necessary addition to the actual cg theory, particularly with regard to its usefulness for corporate memories and task support systems. With the process statement that it introduces, this paper increases the expressivity of the formalism without impairing on its simplicity and without making any special or ad hoc ontological commitment, leaving the theory as simple and as unbiased as it was originally intented to be. Finally, considering the cost of technology transfer from theory to practice, this paper proposes a definition framework which is extremely simple to implement. By doing so, we hope to facilitate its use in real cg systems, helping the dissemination of the theory.
References 1. Delugach, H. S. (1991). Dynamic Assertion and Retraction of Conceptual Graphs. In: Proc. of the 6th Ann. Workshop on Conceptual Structures, E, Way (Ed.), Binghamton, N.Y.: SUNY at Binghamton, pp. 15-24. 2. Mineau, G.W. & Gerb6, O., (1997). Contexts: A Formal Definition of Worlds of Assertions. In: Lecture Notes in AI #1257. Springer-Verlag. 80-94.
79 3. Creasy, P. & Moulin, B. (1991). Approaches to Data Conceptual Modelling. In Proc. of the 6th Annual Workshop on Conceptual Structures, E. Way (Ed.), Binghamton, N.Y.: SUNY at Binghamton, pp. 387-399. 4. Haemmerl6, O. (1995). Implementation of Multi Agent Systems using Conceptual Graphs for Knowledge and Message Representation: The GoGITo Platform. In: Proc. of the 3rd Int. Conf. on Conceptual Structures (ICCS-95), G. Ellis, R. Levinson, & B. Rich (Ed.), Santa Cruz, CA: UCSC, pp. 13-24. 5. Hines, T. R., Oh, J. C. & Hines, M. L. A. (1990). Object-Oriented Conceptual Graphs. In: Proc. of the 5th Ann. Workshop on Conceptual Structures, L. Gerholz & P. Eklund (Ed.), Boston, Mass. Section A.08. 6. Kabbaj, A. & Frasson, C. (1995). Dynamic CG: Toward a General Model of Computation. In: Proc. of the 3rd Int. Conf. on Conceptual Structures (ICCS-95), G. Ellis, R. Levinson & B. Rich (Ed.), Santa Cruz, CA: UCSC, pp. 46-60. 7. Lukose, D., Cross, T., Munday, C. & Sobora, F. (1995). Operational KADS Conceptual Model using Conceptual Graphs and Executable Conceptual Structures. In: Proc. of the 3rd Int. Conf. on Conceptual Structures (ICCS-95), G. Ellis, R. Levinson & B. Rich (Ed.), Santa Cruz, CA: UCSC, pp. 71-85. 8. Wuwongse, V. & Gosh, B. C. (1992). Towards Deductive Object-Oriented Databases Based on Conceptual Graphs. In: Lecture Notes in AI #754. Springer-Verlag. pp. 188205. 9. Lukose, D. & Mineau, G.W., (1998). A Comparative Study of Dynamic Conceptual Graphs. In: Proceedings of the l lth Knowledge Acquisition for Knowledge-Based Systems Workshop (KAW-98). Banff, Alberta, Canada. Section VKM-7. April 18-23. 10.Minean, G.W. & Missaoui, R., (1996). Semantic Constraints in Conceptual Graph Systems. DMR Consulting Group. R&D Division. Report #960611A. l l.Bos, C., Botella, B. & VanHeeghe, P., (1997). Modeling and Simulating Human Behaviours with Conceptual Graphs. In: Lecture Notes in AI #1257. Springer-Verlag. 275-289. 12.Ellis, G., (1995). Object-Oriented Conceptual Graphs. In: Lecture Notes in AI #954. Springer-Verlag. 144-157. 13.Allen, J.F., (1981). An Interval-Based Representation of Temporal Knowledge. In: Proceedings of the 7th Int. Joint Conference on Artificial Intelligence. 221-226.
A Semantic Validation of Conceptual Graphs Juliette Dibie 1,2, Ollivier Haemmerl~ 1, and Stdphane Loiseau 1'3 1 INA-PG, D~partement OMIP 16, rue Claude Bernard, F-75231 Paris Cedex 05, France 2 LAMSADE, Universitd de Paris IX - Dauphine Place du Mardchal de Lattre de Tassigny, F-75775 Paris Cedex 16: France L R I - CNRS, B~t 490, Universitd Paris XI - Orsay F-91405 Orsay Cedex, France Juliette. Dibie@inapg. inra. fr, Ollivier. Haemmerle@inapg. inra. fr, St ephane. Loiseau@lri. fr
Abstract. Validation is an important part of the research work on knowledge based systems. Three kinds of validation have been studied: syntactic validation, logical validation and semantic validation. We are interested in these three kinds of validation for knowledge based systems based on conceptual graphs. This paper focuses on semantic validation. We present a method to check whether a knowledge base is semantically valid. This is done with respect to constraints. We present two types of constraints, minimal and maximal descriptive constraints. Each of them is associated with a conceptual graph G. It allows one to specify that if there exist specializations of G in the knowledge base, then these specializations must respect some conditions. For each kind of descriptive constraints we propose a way of checking if a knowledge base is valid and define their logical semantics. Finally we compare descriptive constraints with other extensions of the conceptual graph model.
1
Introduction
Validation is an increasing preoccupation for knowledge based (KB) system developers mainly for two reasons. Firstly, researchers have worked for a long time on knowledge representation and related algorithms. Some operational systems can now be designed using those approaches, so researchers focus on methods and tools to help ensuring the quality of KB system, which is a requirement for industrial systems. Secondly, the particular nature of knowledge requires specific approaches for KB systems; software engineering works provide only partial solutions. According to 1, the validation is defined as "the set of activities of which the goal is to contribute in ensuring to a certain degree the quality and reliability of a KB system". Most of the works on the validation of KB systems concern the rule based systems 2-5. In other works, some study the validation of knowledge model 6 and in particular the validation of semantic networks. 7 proposes
81 solutions to exhibit incoherences in the knowledge bases using production rules and semantic networks. 8 defines descriptive logics as a language with good properties to represent and verify a structured knowledge. As far as we know, no work has been done previously on the validation of conceptual graphs. In this paper, we are interested in the semantic validation of conceptual graphs. The semantic validation of a KB system aims at ensuring that the semantics of the factual knowledge of the KB conform to some constraints. The constraints are rules of the form " I f . . . Then _l_" which are reliable knowledge expressing contradictory conditions. Our work is based on the CG model 9 as formalized in 10. A knowledge base (KB) is composed of a support (S) and of one (or several) conceptual graph(s) (G) representing the factual knowledge. The semantic validation leads us to extend the CG model by introducing constraints, called descriptive constraints. A descriptive constraint is knowledge given by the designer for validation purpose, associated with a conceptual graph G and built on the support S. A descriptive constraint allows one to specify that if there exist specializations of G in the KB, then these specializations must respect some conditions. A descriptive constraint is of the form G c~st C, where C characterizes the conditions associated with the specializations of the graph G in the KB. A descriptive constraint is either minimal or maximal. A minimal (resp. maximal) descriptive constraint specifies that if there exist specializations of G in the KB, then these specializations must atleast (resp. atmost) respect some conditions. The combination of minimal and maximal descriptive constraints provides an efficient way of setting constraints on conceptual graphs. This paper is organized as follows. The second section deals with the definitions of descriptive constraints. The third section presents the semantic validation of a KB, with respect to some descriptive constraints. In the fourth section, we discuss the descriptive constraints with regard to what already exists in the CG model in terms of definition and constraint.
2
Descriptive
constraints
A descriptive constraint is either minimal or maximal. Firstly, we formalize the notion of descriptive constraint. Secondly, we present the minimal and maximal descriptive constraints themselves.
2.1
Definition of descriptive constraints
Intuitively, a descriptive constraint associated with a conceptual graph G allows one to specify that if there exists a specialization of G in the knowledge base, then this specialization must respect some conditions. It restricts the possible specializations of G in the base to specific specializations. For instance a descriptive constraint allows one to indicate that "if a painter paints, then he must paint a painting".
A coreference link 9 links two concept vertices of comparable labels. It is graphically represented by a dotted line between these concept vertices.
82 D e f i n i t i o n 1 Let G1 and G2 be two connected conceptual graphs, C1 and C2 being their respective class of concept vertices. A coreference link between two concept vertices of comparable labels of C = C1 • C2 is an equivalence relation on C.
Coreference links are used in the definition of descriptive constraints. The conditions that must be respected by all the specializations of G in the base are characterized by descriptions, the concept vertices of G being linked by coreference links to some concept vertices of each description. D e f i n i t i o n 2 A description, noted d, of a connected conceptual graph G is a connected conceptual graph specialization of G, such that each concept vertex of G is linked by a coreference link to one of its concept vertices. We call head of the description the subgraph composed of the concept vertices linked by a coreference link to the concept vertices of G and of the relation vertices linking these concept vertices together. The head of a description d is unique and noted
hd. We admit that a descriptive constraint is associated with an irredundant conceptual graph. A conceptual graph G is irredundant if there is no projection from G into one of its strict subgraphs 11. D e f i n i t i o n 3 A descriptive constraint associated with an irredundant connected
conceptual graph G called constraint graph is noted G c~st ~ di where for all i:l i E 1, m, di is a description of G. E x a m p l e 1 (followed throughout the paper):
Let G and d be the following conceptual graphs: G IP a i n t e r : * ~
d
IPainter: * ~
Paint:*l
Paint:* ~ P a i n t i n g : *
hd
Let CB be the knowledge base composed of the following factual knowledge F = {71,72, ?3}, a juxtaposition of the connected conceptual graphs 71, ?2 and
73: 71
IPainter: Dali ~ c1
72
Paint:* rl
~
c2
IP a i n t e r : E r n s t I ~ P a i n t : * c4 r3 C5
Painting: *1 r2
c3
83 73
IP a i n t e r : M i r 5 ~ - - ~ P a i n t : * C6
r4
~ C7
Painting: BlueI Cs
r5 1 @
2 I Painting: BlueH r6
C9
The descriptive constraint G co~,t d means that i / a painter paints then he must paint a painting. Intuitively, it appears that the descriptive constraint is not satisfied by ~ B . On the one hand the painter Ernst paints, but he does not paint any painting and on the other hand the painter Mir5 paints more than one painting. 2.2
M i n i m a l descriptive constraints and m a x i m a l descriptive constraints
There exist two types of descriptive constraints: the minimal descriptive constraints and the maximal descriptive constraints. They allow one to set restrictions on a conceptual graph as follows: m
1. the minimal descriptive constraint is noted G "~'~ V di. It allows one to i~l
specify that for each specialization of G in the base, this specialization must at least satisfy a description di, i E 1,m; 2. the maximal descriptive constraint is noted G m ~ ~ di V G. It allows one to i:l
specify that for each specialization of G in the base and for each description di, i E 1,m, this specialization must at most satisfy it once. That is to say that if a specialization of G satisfies a description di, i E 1, m, then it must satisfy this description only once. There can be specializations of G which do not satisfy any description di, i E 1, m, then they satisfy the conceptual graph G itself; 3. with the previous two descriptive constraints, we can express the fact that for each specialization of G in the base, this specialization must only satisfy a description d~, i E 1, m. That is to say that each specialization of G must at least satisfy a description di, i E 1, m, and this only once. The intuitive notions at least satisfy and at most satisfy are formalized in the definitions of the satisfaction of minimal and maximal descriptive constraints. Example 2 : Let us consider the conceptual graph G and its description d presented in example 1. The intuitive interpretation of the minimal descriptive constraint G m~n d is that "if a painter paints, then he must at least paint a painting". The intuitive interpretation of the maximal descriptive constraint G ~ x d V G is that "if a painter paints, then he must at most paint a single painting, he can paint none".
84 3
Semantic
validation
The semantic validation aims at ensuring that the coherence of the factual knowledge is checked with respect to constraints, which represent some expert knowledge given for validation purpose. We say that a knowledge base is semantically valid if it respects all the constraints of the knowledge based system. Definition 4 A knowledge base ~B is semantically valid iff )~B satisfies each minimal descriptive constraint and each maximal descriptive constraint of the knowledge based system. We introduce the notion of image graph, used in the definitions of the satisfaction of minimal and maximal descriptive constraints. Definition 5 Let H and G be conceptual graphs. We say that there exists a projection from G into H with h the image graph of G if h is a subgraph of H and there exists a surjective projection from G into h. In the following, we consider that the knowledge base ~B, being semantically validated, is composed of a support S and a conceptual graph under normal form F. A conceptual graph G is under normal form if each individual marker belonging to G appears exactly once 11. 3.1
Satisfaction of m i n i m a l descriptive constraints
In t e r m s of g r a p h o p e r a t i o n s The satisfaction of a minimal descriptive conm
straint G ,~n ~/di by a knowledge base CB consists in checking if each spei----1
cialization of G in )~B satisfies at least one description di, i C 1, inf. In terms of graph operations, the constraint is satisfied iff for each specialization ~ of G in ~B (~/is an image graph of G in F), there exists at least one projection from a description di, i E 1, m, into F with ~/the image graph of the head of di. Definition 6 Let CB be a knowledge base composed of a support S and a m
conceptual graph under normal form F. Let G m~n V di be a minimal descriptive i:l
constraint. The minimal descriptive constraint is satisfied by ~B iff for each projection from G into F such that ~, is the image graph of G, there exists at least a projection from a description di, i E 1, m, into F with ~, the image graph of the head of di. Example 3 : Let us consider the conceptual graph G, its description d and the conceptual graphs ")11 and ~/2 presented in example 1. a) Let el3 be a knowledge base composed of the factual knowledge F = {~/1}. We
check if ~13 satisfies the minimal descriptive constraint DC : G m~n d.
85
There is a projection from G into 71 with 71 the conceptual graph limited to the vertices Cl, rl and c2 and the image graph of G; there is a projection from d into 71 with 71 the image graph of the head of d. ICB satisfies the minimal descriptive constraint DC : the painter Dali paints and he paints a painting. b) Let 1C13' be a knowledge base composed of the factual knowledge F ' = {71,72}. We check if 1CB' satisfies the minimal descriptive constraint DC. (1) There is a projection from G into 71 with 71 the conceptual graph limited to the vertices cl, rl and c2 and the image graph of G; there is a projection from d into 71 with 71 the image graph of the head of d; (2) there is a projection from G into 72 but there doesn't exist a projection from d into 72. 1CB' doesn't satisfy the minimal descriptive constraint DC: the painter Dali paints and he paints a painting, but the painter Ernst paints and he paints nothing. L o g i c a l s e m a n t i c s The logical interpretation of definition 6 relies on the notion of S-substitution. A S-substitution is an application of a logical formula ~o associated with a conceptual graph into another one r such that with each term or atom of ~o a term or an atom of r is associated 11. Property
1 L e t / ~ B be a knowledge base composed of a support S and a conm
ceptual graph under normal f o r m / ' . Let G ~ n
V di be a minimal descriptive i=l
constraint. The minimal descriptive constraint is satisfied by/CB iff: for each S-substitution p from ~(G) into ~ ( F ) , 3 a S-substitution p' from ~(d~) into ~(/~) with p'(~(hd~)) = p(~(G)). We prove the equivalence of definition 6 and its logical interpretation (property 1) in proof 1 of the annex section. Example 4 :
Let us consider example 3 b, with knowledge base ~ B t composed of the factual knowledge F' = {~1,')'2}. The logical interpretation 9, 11 of conceptual graphs G, d and I "~ are: 9 (G) = 3x, y Painter(x) A Paint(y) A agt(y, x) r = 3u, v, w Painter(u) A Paint(v) A Painting(w) A agt(v, u) A obj(v, w) ~(1") = 3l, m, n Painter( Dali)APaint(1)APainting(m)Aagt(l, Dali)Aobj (1, m) A Painter(Ernst) A Paint(n) A agt(n, Ernst) We obtain the same result from a logical point of view as from a graphic one. (1) Let Pl be a S-substitution from ~(G) into ~(Ft), Pl = {(Painter, Painter), (x, Dali), (Paint, Paint), (y, l), (agt, agt)}, there exists a S-substitution p' from q~(d) into ~(F'), p' = { (Painter, Painter), (u, Dali), (Paint, Paint), (v, l), (Painting, Painting), (w, m), (agt, agt), (obj, obj)} and p'(~(hd)) = pl(~(G)).
86 (2) Let p2 be a S-substitution from ~(G) into ~(F'), P2 -- ((Painter, Painter), (x, Ernst), (Paint, Paint), (y, n), (agt, agt)}, there doesn't exist a S-substitution p~ from ~(d) into ~(F') with p'(~(hd)) = p2(~(G)). CI3 ~ doesn't satisfy the minimal descriptive constraint D C because of case (2). 3.2
Satisfaction of m a x i m a l descriptive c o n s t r a i n t s
Whereas redundance is considered in the study of the satisfaction of minimal descriptive constraints, it makes no sense in the study of the satisfaction of maximal descriptive constraints. The maximal descriptive constraint contains the idea of at most whereas redundance is logically interpreted by the idea of at least. Intuitively, we can see that having a maximal descriptive constraint composed by redundant conceptual graphs and studying the satisfaction of a maximal descriptive constraint by a redundant knowledge base would be irrelevant. Thus, we admit that the descriptions of maximal descriptive constraints and the conceptual graph(s) belonging to the knowledge base are irredundant. In t e r m s of g r a p h o p e r a t i o n s The satisfaction of a maximal descriptive m
constraint G ~ x
V d~ v G by a knowledge base 1CB consists in checking if for i----1
each description d~, i E 1, m, each specialization of G in CB satisfies at most this description once. In terms of graphs operations, the constraint is satisfied iff for each specialization ~/of G in the base (V is an image graph of G in F), there exists at most one projection from each description di, i E 1, m, into F with ~/the image graph of the head of di. D e f i n i t i o n 7 Let CB be a knowledge base composed of a support S and let F m
be an irredundant conceptual graph under normal form. Let G m ~ V diVG be a i:l
maximal descriptive constraint, the descriptions di, i C 1, m, being irredundant. The maximal descriptive constraint is satisfied by (:B iff for each projection from G into F such that V is the image graph of G, there is at most one projection from each graph di, i E 1, m, into F with V the image graph of the head of di. Example 5 : Let us consider the conceptual graph G, its description d and the conceptual graphs V2 and V3 presented in example 1. a) Let/CB be a knowledge base composed of the actual knowledge F -- {V2}. We check if CB satisfies the maximal descriptive constraint D C : G ~ x d V G. There is a projection from G into V2 and there does not exist a projection from d into F with V2 the image graph of hd. CB satisfies the maximal descriptive constraint DC: the painter Ernst paints and as he paints nothing, he does not paint more than one painting. b) Let CB t be a knowledge base composed of the actual knowledge/~t -- {V2,V3}. We check if CIJ ~ satisfies the maximal descriptive constraint DC.
87 (1) There is a projection from G into 3"2 and there does not exist a projection from d into F with 3"2 the image graph of hd; (2) there is a projection from G into 3'3 and there are two projections from d into F' with 7~ the conceptual graph limited to vertices c6, r4 and c7 and the image graph of hd. lOB' doesn't satisfy the maximal descriptive constraint DC, because of the two projections from d into F' in case (2): the painter Ernst paints and he paints nothing, but the painter Mir6 paints more than one painting. Logical s e m a n t i c s The logical interpretation of definition 7 is as follows. P r o p e r t y 2 Let /CB be a knowledge base composed of a support S and an m
irredundant conceptual graph under normal form/'. Let G ~ x
V di v G be a i~1
maximal descriptive constraint, the descriptions di, i E 1, m, being irredundant. The maximal descriptive constraint is satisfied by K:B iff: for each S-substitution p from 4~(G) into ~5(F), if 3 a S-substitution p' from ~(di) into r with p'(~(hdi)) = p(~(G)) then p' must be unique. We prove the equivalence of definition 7 and its logical interpretation (property 2) in proof 2 of the annex section. Example 6 : Let us consider example 5 b, with knowledge base feb ~ composed of the factual knowledge F~ = {3'2,73}. The logical interpretations of the conceptual graphs G, d and r ~ are: 9 (G) = 3x, y Painter(x) A Paint(y) A agt(y, x) 9 (d) = 3u, v, w Painter(u) A Paint(v) A Painting(w) A agt(v, u) A obj(v, w) 9 (F') = 3l,m Painter(Ernst) A Paint(1) A agt(l, Ernst) A Painter(Mir6) A Paint (m ) A Painting( BlueI) A Painting( Bluel I) Aagt( m, M ir6) Aobj (m, BlueI) A obj(m, BlueII) We obtain the same result from a logical point of view as from a graphic one. (1) Let Pl be a S-substitution from ~(G) into ~(F'), pl = {(Painter, Painter), (x, Ernst), (Paint, Paint), (y, l), (agt, agt)}, there doesn't exist a S-substitution p~ from ~(d) into ~(F') with p'(~(hd)) = pl(~(G)).
(2) Let P2 be a S-substitution from ~(G) into ~(F'), p2 = {(Painter, Painter), (x, Mir5), (Paint, Paint), (y, m), (agt, agt)}, there exist two S-substitutions p~ and p" from r into ~(F'): p' = {(Painter, Painter), (u, UirS), (Paint, Paint), (v, m), (Painting, Painting), (w, BlueI), (agt, agt), (obj, obj)} and p~(~(hd)) = p2(q~(G)); p" -- {(Painter, Painter), (u, Mir5), (Paint, Paint), (v, m), (Painting, Painting), (w, BluelI), (agt, agt), (obj, obj)} and p'(~(hd)) = p2(~(G)). ICB' doesn't satisfy the maximal descriptive constraint DC because of case (2).
88 4 4.1
Discussion D e s c r i p t i v e c o n s t r a i n t s versus definitions
In the conceptual graph (CG) model, several authors have been interested in the definition of types 9, 12. A type is defined (1) either by genus, the genus representing its over-type: in that case, there is implication between the type and its genus; (2) or by genus and difference: the definition then declares an equivalence between the type and its description. 12 also talks about partial definition of a type t that declares the implication of a description D by the type t: t(x) d~ D(x). In the description logic, the definition is richer than in the CG model because it allows one to set restrictions on concepts. A description logic 13 contains concepts and roles, which can respectively be compared with concept types and relation types of the CG model. These concepts and roles can be either primitive or complex, complex concepts and roles being defined via descriptions built by a set of constructors. For instance, a complex concept can be defined by restrictions of roles: three constructors, all, atleast and atmost, are used to build concepts by restricting their relationships with other concepts. The definition by genus and difference of types in the CG model is not enough to establish such restrictions on types. The introduction of descriptive constraints in the CG model allows one to set restrictions on types and more generally on conceptual graphs. A descriptive constraint is associated with a conceptual graph, which can be limited to a concept vertex (constraint associated with a concept type) or to a relation vertex with its neighbours (constraint associated with a relation type). The notion of the constructors atleast and atmost of the description logic is covered in the minimal descriptive constraints and the maximal descriptive constraints. The descriptive constraints thus allow one to extend the definition of types in the CG model by setting restrictions on types. It is on purpose that we have used the word "descriptions" to characterize restrictions and the notation G c~=~,t ~ di to represent the descriptive constraints, which are inspired by the i----1
partial definition of a type t. As in the definitions, we are interested in multiple descriptive constraints and nested descriptive constraints. We talk about multiple descriptive constraints if more than one descriptive constraint is associated with a constraint graph. We talk about nested descriptive constraints if a descriptive constraint is associated with the description of a constraint graph. In these two cases, the following definition and property are obvious. D e f i n i t i o n 8 If two distinct descriptive constraints DC1 and DC2 are associm
ated with the same constraint graph G, DCI: G co=~,t V di and DC2: G c~:~,t i=1 rr~
rr~
I
V d~, then the descriptive constraint associated with G is a c~st V di V V d~. k=l
i=1
k=l
89 P r o p e r t y 3 Let DC be a descriptive constraint of a constraint graph G, DC: m
G co=~st V di. If a descriptive constraint DC ~ is associated with one of the i=1 l
descriptions dj of G, DC~: dj ~o=~st V d~, then the descriptive constraint DC k=l m
becomesGC~St
l
V
d i v V d~.
i=l,i:~j
k=l
The proof of this property is almost immediate. It uses definition 8 and the property of transitivity of the coreference links (definition 1). 4.2
D e s c r i p t i v e c o n s t r a i n t s versus c o n s t r a i n t s
The notion of constraint is not a new idea in the Conceptual Structures Theory. It is studied by 10 in the expression of knowledge of different types and is associated with the notion of canonicity by 14-16 and17 took an interest in the representation of semantic constraints in conceptual graph systems. We study these three cases in comparison with the descriptive constraints. 10 propose to express knowledge of different types. They presente in particular the notions of necessarily implicit knowledge and local constraint. These two types of knowledge can be expressed in terms of descriptive constraints. A necessarily implicit knowledge D associated with a type t expresses the fact that if in a conceptual graph there is a concept vertex of type t I such that t ~ ~ t, then this vertex has necessarily the particular graph D in its environment. Such a necessarily implicit knowledge can be seen as a minimal descriptive constraint of the form: t(x) m~n D(x). A local constraint C associated with a type t expresses the fact that in every graph satisfying the constraint C, the environment of each concept vertex of type t I such that t ~ _~ t conforms to this constraint. Such a local constraint can be seen as a descriptive constraint of the form: t(x) co~st C(x). More precisely, a local constraint can allow to represent functional constraints, for instance every painter who paints paints a single painting, which can be seen as a maximal descriptive constraint of the form G ~ x d V G with G and d the conceptual graphs of example 1, d being the local constraint. 15 says that canonicity handles the violation of selectional constraints. The checking mechanism of canonicity consists in checking whether a conceptual graph G is a canonical graph with respect to a canonical basis. According to 14, a conceptual graph G is canonical iff there are projections of the graphs of the canonical basis into G that wholly cover G. This checking mechanism of canonicity cannot be compared with the satisfaction of minimal descriptive constraints. Let Bc~n be a canonical basis composed of n canonical graphs noted di, i E 1, hi. Let us study the canonicity of a conceptual graph G with respect to Bc~n. We would like to demonstrate that: "G is canonical with respect to Bc~n iff the knowledge base composed of the conceptual graph G satisfies the m
m
minimal descriptive constraint G ~ n V di". But G ~ n V di is not a minimal i=1
i-~1
90 descriptive constraint because the graphs di, i E 1,m, are not specializations of the graph G. Besides, 16 proposes a positive canonical model and negative canonical models, associated with each concept type and relation type in the ontology of the domain, to strengthen the semantic checking mechanism of the CG model. The checking mechanism of canonicity of a conceptual graph G is enforced by projecting positive and negative canonical models into G. There must exist a projection from the positive canonical model of each type into every occurrence of that type in G and there must not exist a projection from the negative canonical models of each type into any occurrence of that type in G. This mechanism of semantic checking can be compared with the satisfaction of minimal descriptive constraints. Let us build the descriptive constraints corresponding to canonical models. The positive canonical model and the negative canonical models are conceptual graphs associated with a type t. We note them respectively G + and G~, i E 1,m. Let Gt be the conceptual graph associated with the type t, Gt is limited to a concept vertex if t is a concept type, and to a relation vertex and its neighbours if t is a relation type. The checking mechanism of canonicity of a conceptual graph G can be compared with the minimal descriptive constraint Gt m~nG+ t that must be satisfied and the minimal descriptive constraint m
Gt m~n ~ / G ~ that must not be satisfied. i----1
17 present topological constraints on conceptual graphs, that are based upon the identification of invalid graphs. The authors propose to use non-validity intervals to represent invalid graphs. A non-validity interval is a pair of conceptual graphs u and v, represented within brackets, such that v < u. Any graph G which falls in a non-validity interval, for instance u, v, is to be considered invalid, that is to say G is invalid if v < G < u, otherwise G is plausible according to this interval. Such a non-validity interval can be seen as a minimal descriptive constraint of the form: u ~ n v. As a matter of fact G is invalid (G does not satisfy the minimal descriptive constraint) if G is a specialization of u and is not more specific than v, else it satisfies the minimal descriptive constraint. The non-validity intervals allow one not to consider the boundary values of the interval, which cannot be done with our descriptive constraints. The authors also present domain constraints. They want to extend the conceptual graph theory to cover a wider range of constraints. Yet, our goal is to propose relevant constraints for the validation of a knowledge base built on conceptual graphs, and not new semantic constraints in the conceptual graph model. 4.3
Conclusion
ConceptuM Structures Theory 9 talks about three levels of meaning: syntax, logic and ontology. We have been working on conceptual graph validation in three directions, according to these three levels: the syntactic validation, the logical validation and the semantic validation. The first level is a syntactic validation 18 that consists in checking a knowledge base structurally. Firstly, the KB must conform to the definitions of the
91
conceptual graph model. Secondly, the factual knowledge of the KB must conform to its terminological knowledge. The second level is a logical validation 19 leading to a KB that corresponds exactly to the designer's intuitive interpretation. An extension of the conceptual graph model -the LV-graph model- is proposed and allows one to define "distinction links" between concept vertices. The third level is a semantic validation that consists in confronting the KB to some expert knowledge specifications. The semantic validation of a KB using descriptive constraints ensures that the factual knowledge of the KB satisfies these constraints. Instead of being used for validation purpose the descriptive constraints could be considered as terminological knowledge belonging to the knowledge base. We could imagine extending the conceptual graph model by introducing a descriptive base, a set of descriptive constraints, such that the definition base or the canonical basis. So, it would be valuable to build conceptual graphs which would be wellformed with respect to a descriptive base. This work has been implemented and tested for several months on the CoGITo platform 20 which is a tool designed to implement applications based on the conceptual graph model 21, 22. 5
Annex:
Proof
of the properties
The definition of the S-substitution verifies the following property 11, which we recall for proof 1: P r o p e r t y 4 There exists a projection from a conceptual graph G into a conceptual graph H iff there exists a S-substitution from ~(G) into ~(H). P r o o f 1 Let us show the equivalence of the two propositions: - PI: "for each S-substitution p from ~(G) into r 3 a S-substitution p' from ~(di) into #( F) with p~(#(hdi)) = p(#(G))" - P2: "for each projection from G into F such that 7 is the image graph of G, there is at least a projection from a graph di into F with "f the image graph of the head of di". According to property 4, there exists a projection ~r from G into F iff there exists a S-substitution p from #(G) into #( F) , and there exists a projection ld from di into F iff there exists a S-substitution p~ from #(di) into #(F). P1 is equivalent to "for each projection 7r from G into F, there exists a projection 7d from di into F such that the image graph of the head hdi of di in F corresponds to the image graph of G in F". The idea of "there exists a projection from di into F such that ..." is equivalent to the idea of "there is at least a projection from a graph di into F with ...". Thus P1 is equivalent to "for each projection from G into F with 7 the image graph of G in F, there is at least a projection from a graph di into F with -y the image graph of the head hdi of di", that is to say P~ r P2.
g2 P r o o f 2 Let us show the equivalence of the two propositions: - PI: "for each S-substitution p from ~(G) into ~ ( F ) , if 3 a S-substitution p~ from ~(di) into ~ ( F ) with p'(~(hdi)) = p(~(G)), then p' must be unique" - P2: "for each projection from G into F such t h a t ~ is the image graph of G, there is at most one projection from each graph di into F with ~ the image graph of the head of di". According to property 4, there exists a projection ~r from G into F iff there exists a S-substitution p from 4~(G) into 4~(F), and there exists a projection r ' from di into F iff there exists a S-substitution p~ from ~(di) into ~ ( F ) . P1 is equivalent to "for each projection ~ from G i n t o / ' , if there exists a projection ~' from di into F such t h a t the image graph of the head hdi of di in F corresponds to the image graph of G in F, then the projection r ' must be unique". The idea of "if there exists a projection from di into /" such t h a t ..., then it must be unique" is equivalent to the idea of "there is at most one projection from each graph di i n t o / " with . . . " . Thus P1 is equivalent to "for each projection ~r from G into F with "y the image graph of G i n / ' , there is at most one projection from each graph di into F with ~ the image graph of the head hdi of di", t h a t is to s a y P 1 r P2.
References 1. J.P. Laurent.
Proposals for a valid terminology in KBS validation.
European
Conference of Artificial Intelligence, pages 829-834, August 1992. 2. A. Ginsberg. Knowledge-base reduction : a new approach to checking knowledge bases for inconsistency and redundancy. AAAI, pages 585-589, 1988. 3. P. Meseguer. Verification of multi-level rule-based expert systems. AAAI, pages 323-328, 1991. 4. A. Preece and N. Zlaterava. A state of the art in automated validation of knowledge-based systems. Expert Systems with Applications, 7(2):151-167, 1994. 5. S. Loiseau. Checking and restoring the consistency of knowledge databases. Encyclopedia of Computer Science and Technologie, 36:15-34, 1997. 6. C. Haouche and J. Charlet. KBS validation : a knowledge acquisition perspective. ECAI, pages 433-437, 1996. 7. M.C. P~ousset. Knowledge formal specifications for formal verification: a proposal based on the integration of different logical formalism. European Conference of Artificial Intelligence, pages 739-743, 1994. 8. P. Hors and M.C. Rousset. Modeling and verifying complex objects : A declarative approach based on description logics. European Conference of Artificial Intelligence, 1996. 9. J.F. Sowa. Conceptual structures: information processing in mind and machine. Addison Wesley Publishing Company, 1984. 10. M.L. Mugnier and M. Chein. Representer des connalssances et raisonner avec des graphes. Revue d'Intelligence Artifieie!le, 10(1):7-56, 1996. 11. M. Chein and M.L. Mugnier. Conceptual graphs: fundamental notions. Revue d'Intelligence Artifieielle, 6(4):365-406, 1992.
93 12. M. Lecl~re. Les connaissances du niveau terminologique du module des graphes conceptuels : construction et exploitation. PhD thesis, Universit~ Montpellier II, Decembre 1995. 13. F. Bouali. Les systemes terminologiques et la relation partie de. Rapport de stage de DEA, Universit~ PAR/S-SUD, centre d'Orsay, Septembre 1992. 14. M.L. Mugnier and M. Chein. Characterization and algorithmic recognition of canonical conceptual graphs. In Proceedings of the 1st International Conference on Conceptual Structures, ICCS'93, Quebec City, Canada, L.N.A.I. 699, pages 294-311. Springer-Verlag, August 1993. 15. M. Wermelinger. A different perspective on canonicity. In Proceedings of the 5th Int. Conf. on Conceptual Structures, Lecture Notes in Artificial Intelligence 1257, pages 110-124, Seattle, U.S.A., 1997. Springer Verlag. 16. P. Kocura. Conceptual graph canonicity and semantic constraints. In Gerard Ellis Peter W. Eklund and Graham Mann, editors, Conceptual Structures: Knowledge Representation as Interlingua - Auxilliary Proceedings of the Fourth International Conference on Conceptual Structures, pages 133-145, Sydney, Australia, August 1996. Springer Verlag. 17. G. W. Mineau and R. Missaoui. The representation of semantic constraints in conceptual graph systems. In Proceedings of the 5th Int. Conf. on Conceptual Structures, Lecture Notes in Artificial Intelligence 1257, pages 138-152, Seattle, U.S.A., 1997. Springer Verlag. 18. J. Dibie. Validation des graphes conceptuels. Rapport de stage de DEA, Universit~ Paris IX, Dauphine, Paris, Septembre 1997. 19. J. Dibie, O. Haemmerl~, and S. Loiseau. Une validation logique des graphes conceptuels. Rapport interne, Institut National Agronomique, Paris, Janvier 1998. 20. O. Haemmerl~. CoGITo: une plate-forme de ddveloppement de logiciels sur les graphes conceptuels. PhD thesis, Universit~ Montpellier II, Janvier 1995. 21. P. Martin and L. Alpay. Conceptual structures and structured documents. In Proceedings of the 4th Int. Conf. on Conceptual Structures, Lecture Notes in Artificial Intelligence 1115, Springer-Verlag, pages 145-159, Sydney, Australia, August 1996. 22. C. Bos, B. Botella, and P. Vanheeghe. Modelling and simulating human behaviours with conceptual graphs. In Proceedings of the 5th Int. Conf. on Conceptual Structures, Lecture Notes in Artificial Intelligence 1257, pages 275-289, Seattle, U.S.A., 1997. Springer Verlag.
Using "Viewpoints and CG for the Representation and Management of a Corporate Memory in Concurrent Engineering Myriam Ribi&e INRIA (project ACACIA) 2004, route des Lucioles BE93 06902 Sophia-Antipolis Cedex E-mail: Myriam.Ribiere @sophia.inria, fr Abstract. In Concurrent Engineering, several participants (designers, managers,...) stemming from different specialities, collaborate in order to build a system. In this paper, we propose a representation with the Conceptual Graph formalism to keep a trace of the design process in Concurrent Engineering as a project memory. Such design process is a cycle of individual design and collaborative evaluation. In order to facilitate knowledge extraction from this memory and to ensure the evolution of knowledge, we define a viewpoints management. This management is based in our study of viewpoints in Conceptual Graphs.
1 Introduction In Concurrent Engineering (CE), several participants (designers, managers,...) stemming from different specialities, collaborate in order to construct a system (also called artefact). Such a design process is a cycle of individual design, in which each designer defines a design proposition corresponding to his speciality and to his task, and collaborative evaluation in which the integration of propositions in the artefact is evaluated. Participants need sometimes to review previous decisions. So, it is important to define a project memory and to represent different states of the artefact. This memory must be accessible by designers in different specialities during the project process.. Conceptual Graph (CG) formalism offers a knowledge representation close to natural language, we propose to use this formalism to represent states of the artefact. We also exploit Viewpoint notion to make knowledge accessible to different participants. We present first (Section 2) Concurrent Engineering (CE) through the description of the CE task and the corporate memory in CE. In the next section (Section 3), we clarify the viewpoint definition according to the CE context. Then, we propose (Section 4) methods and algorithms to manage a part of the corporate memory (the different states of the artefact). Those methods are related to the building, the consultation and the update of the artefact during the CE task.
2 Concurrent Engineering and Corporate Memory 2.1
C E Task
As we noted above, the CE process is a cycle of individual design and collaborative evaluation. In fact, we note three main tasks in CE:
95
,qh
Fig. 1. CE Task 9 Individual Design: (Design task), relying on his private knowledge (Private model), each designer generates some propositions to satisfy given requirements. His task is similar to a design task. 9 Cooperative Evaluation: (Evaluate task), The group evaluates the integration of propositions in the artefact. Propositions may not satisfy participants' needs and conflicts can appear. To promote the acceptance of his propositions by the group, a participant justifies them with a number of arguments (Argue task). Assumptions made in the design task are used to determine arguments and to define them. Argumentation tries to change other participant's opinion by justifying the utility and the necessity of a proposition. We can note that different types of knowledge (private and shared) and different types of tasks (individual and cooperative) are manipulated in CE task. Note also that several fields (domains) are implicated and that designers may be in geographically distant sites. So, different types of knowledge (related to profession, to experience, etc.) have to be capitalized (on) and designers need to access them (from a relative field, or collaborative decisions,...) for each task.
2.2 Corporate Memory in CE In 11 we study the complete elaboration of a corporate memory in CE, and distinguish different types of memory needed during the different task of the CE (Fig. 1.). We distinguish a memory dedicated to the individual design task and another dedicated to the cooperative evaluation task. We can notice that states of the artefact are essential in the second memory, they represent the evolution of the design object during the CE process. Participants need to review previous decisions (in previous artefact states), and they need to examine the current state of the artefact in order to specify requirements of each part of the artefact and the interaction between these parts. They also need to refer to previous project. So there is a direct interaction between experts and the description of the artefact. For this reason, we use the conceptual graph formalism to represent information or knowledge in the artefact. CG are close to natural language thanks to their representation of knowledge with concepts and relations, and they have a graphical display form of logic which is more readable than classical notations. We exploit also arguments of Gerb6, in 5, about how conceptual graphs "are a response
96 to the specific requirements involved in the development of corporate knowledge repositories": the possibility to express knowledge both at the type and instance level, partial knowledge, category or instance in relationship, and category or instance in MetaModel. In a second phase, we must exploit the viewpoint notion to describe the artefact according to the different experts collaborating to its building. Furthermore viewpoints help in information retrieval, that all participants need in the different tasks described in CE process. So in the next section we describe the use of viewpoints in such a process and we reuse the integration of viewpoints that we presented in a previous paper 10 to formalize our representation of artefact.
3 Viewpoints and Definition "Viewpoint" is a polysemous word, i.e. its definition depend on the context of use. In TROPES, for example, a viewpoint "is a perspective of interest from which an expert examines the knowledge base". It is a general definition, that can take several interpretations in different applications. 3.1 Definition of a Viewpoint for CE In CE, we must introduce a human dimension that corresponds to the different participants in a design project, and a knowledge dimension corresponding to the experience, competence and situation of participants. Generally we can say that a viewpoint is taken by a person according to his/her knowledge, domain of competence and his/her objective in his/her activity. Finch 4 speaks about a vocational viewpoint for a viewpoint used in a particular work activity. So in CE, we characterize a viewpoint by three objects: person, domain, objective. Each object has a definition: is described by the name of the person, its situation in the enterprise and its competencies and level of competence for each competency,
9
person
9
domain
9
objective
is described by the name of the domain, and the current activity, is described by a focus in the activity on a design object.
We applied this definition in accidentology, collaborative design and conflict management between distributed data. We notice that person, domain, objective are always (or more often) present in the elaboration of a viewpoint. So we can constitute a begin of ontology for CE with those objects and define viewpoints in CE on this ontology, but the description of each object depends on the application. Moreover we consider two important parts in a viewpoint, first the "Objective" constitutes the focus, and second "Domain" and "Person" constitute the different angles of view on a same focus (Fig. 2.).
97
Fig. 2. Example on a description of a network According to this definition, we propose in the next section an adaptation of the integration of viewpoints in CG.
3.2 Viewpoints and CGs First step in using viewpoints and conceptual graphs To represent knowledge in a context of several experts, it is interesting to model the multiple perspectives that different experts may have on the objects handled in their reasoning. Taking inspiration from research in object oriented representation, we proposed in a previous work [10] an extension of the conceptual graph formalism to integrate viewpoints in the support and in the building of conceptual graphs. Viewpoints allow us to define the context of use and the origin (name of the expert or group of experts, speciality, degree of experience,...) of concept types introduced in a graph. As a reminder we detail some definitions used in this previous work:
9 Definition: viewpoint relation, basic and v-oriented concept type Let C 1, C 2 be two concept types. If C 1 < C 2, then there may exist a "viewpoint relation" VPt such that C 1 is a subtype of C 2 according to VPt. VPt is a second order conceptual relation of signature (TYPE,TYPE). Then C 1 is a basic concept type and C 2 a v-oriented concept type. ~ Definitions: basic and v-oriented concept - Let Tc be a basic type concept, and r an individual or generic referent. [Tc:r] is an instantiation of the "basic concept type" Tc. It is called "basic concept". - Let To be a v-oriented concept type, and r an individual or generic referent. [To:r] is an instantiation of the "v-oriented concept type" To. It is called "v-oriented concept". 9 We also introduce a new relation, called "Repr", which links a concept to one of its representations. Repr is a first order relation. It can be expressed only if the two concept types are linked through a viewpoint relation in the viewpoint knowledge base. Two concepts linked by a "representation relation" describe the same object, We also detailed different second order relations (equivalence, inclusion, exclusion) between concept types, which can help to manage the representation relation or to make deductions. Those relations depend on the representation relation. Our aim was to define viewpoints to help knowledge representation with conceptual graphs for multi-expert knowledge acquisition and also to have an accessible and evol-
98
utive knowledge base of conceptual graphs through viewpoints. Our approach is also aimed at making comparisons of expertises by defining second order relation between concept types such as equivalence, inclusion or exclusion. According to the definition inthe previous section we describe the viewpoint relation by a definition type and express sufficient conditions to use this relation. Definition of a viewpoint relation: aecessary conditions for Vpt (TC 1,TC2) TYPE:TC1
. t,%~
,TYPE:TC2
sufficient conditions for Vpt (TC1,TC2) jTperson:*x pVpt ~(described_by)~Objective:*y "NDomain:*z The different concept types person, objective and domain have a definition in CE context, but their definition is not always the same. So we express necessary conditions for the definition of those objects: necessary conditions for Person(x) ~(attr) >Name Person:*x~-->(attr) >Situation "~(attr) >Competence/Level of competence necessary conditions for Domain(x) . .. att, ~.~q~Iame Domaan. X ~ a t t : ~) >activity necessary conditions for Objective(x) Obj ective:,x~___...~attr! ~"~(attr)
> Object > Focus
In the context of CE project, this proposition for viewpoints is not sufficient. So we have to clarify this integration of viewpoints and our aim in using viewpoints. Second step in characterization of viewpoints and use with conceptual graphs The integration of viewpoints proposed in 10 is based on a simple definition of viewpoints that is: "viewpoint is the explicit expression of a particular subtype relation existing between two concept types". This definition takes into account the difficulty in elaborating an unique model using different terminologies. It Mlows us to describe a complex object under different perspectives, and allows the possibility of comparing two descriptions in verifying if they use equivalent concept types. But our aim is to compare two descriptions on the same level of abstraction, written from different angles, but focusing on the same problem or task. The determination of such graphs is not easy with only viewpoints and terminology. In fact it is very difficult to automatically determine the viewpoint in a description (represented by a conceptual graph) from the concept types used. So we must distinguish viewpoints used in descriptions of complex objects and viewpoints used in descriptions of an expertise, a proposition or a belief.
99
Description viewpoints ./(Vpt
../ TYPE: PC exploitation system~,~..,,, TYPE:Computer_unix TYPE: Computer VMS TYPE: C o m p u t e r ~ . . ~ TYPE:Computer IPX ' ~ (Vpt protocol _ n e t w o r k ~ TYPE: Computer_TCP-IP TYPE: Computer_PPP TYPE: Server '(Vpt usability in network)/~t--------TYPE: client_terminal TYPE: client_Computer Expertise viewpoints 9 ..--(Vpt electronics engineer),. TYPE:cable topology TYPE:topology of network ~f- " " - "",(Vpt network_designer)< TYPE:Machine_topology
Description of complex objects Computer /1(Repr) < Computer unix: primo Computer__TCP-IP: primo Computer:primo ~ (Repr) < Sever: primo ~-'~Repr) < Computer_unix: M2 /.t-(Repr) < Computer_TCP-IP: Computer:M2 ~--------(Repr) < client_terminal: primo -"~Repr) < Description topologic of network, by network designer: graph definition of Machine_topology(x) composed_by) > Computer_Unix Machine_topology: *x (nb_~gmputer) Numb~er: 10 "~composed_by) > Server: primo
~
Fig. 3. Example of description and expertise viewpoints We consider our first definition of viewpoint dedicated to the description of complex objects as "viewpoint of description", and we clarify in this paper the notion of "viewpoint of expertise". The distinction is essential, it determines the nature of knowledge that we index with viewpoints, and the possibility of each viewpoint in terms of knowledge management.
Definition: projection operation (as reminder) Let G and G' two conceptual graphs. The viewpoint projection of G into G' is an application ~:G--)G', where nG is a subgraph of G', such that: - For each concept c in G, ~c is a concept in G' and type(~c) is a subtype of type(c). - For each conceptual relation r in G, type(rcr)=type(r). If the ith arc of r is linked to a concept c in G, the ith arc of rcr must be linked to ~c in G'.
Definition: viewpoints of expertise, see example in (Fig. 3.) Suppose the experts have a common objective, described by a basic concept type F 1. Their expertises, according to this common objective F1, will be expressed by v-oriented subtypes of F 1, according to the expertise viewpoints V 1..... V n. An expertise viewpoint relation V is a viewpoint relation where the concept type Objective is replaced by Flin its definition.
100
sufficient conditions for expertise_Vpt (F1,TC) ..,~person:*x pVpt > (described_by)~--.~F1: *y ":aDomain:*z 4
Methodology to Build and Manage CE Project Memory with C G and Viewpoints
As we said in (Section 2) a part of a project memory in CE must contain all states of the artefact during the project. So our first interest is to represent an artefact. According to the definition of viewpoints in CE and the integration of such viewpoints in the conceptual graph formalism, we propose a method to build the artefact with a multiview approach and a method to facilitate the management (information retrieval and up-date) of this part of the corporate memory. We proposed also algorithms 4.1
Methodologyto Build the Artefact
For describing a design object or product, we must follow several steps: a) decomposition of the object in several components, b) describe each component c) describe relations among components and their interactions. 12 proposes a multi-view product model based on the life cycle of the product. Each object must be described under several views by only one expert. The different views or steps in the life cycle are "skeletal structure or topologic view", "geometric view", "manufacturing view", "material view", "thermal view", "mechanical view" and "dynamic/Kinematic view". We can note according to our definition of viewpoint, that those views represent the different focus or objective, taken by experts to describe objects. Each expert can also have his description according to the focus. This model is proposed for only one expert for one view, but we can generalize and apply it to several experts on one view. Indeed two experts can be in the same domain, and express their description in the same focus, but can have two different descriptions that correspond to their level of competence and experience in the domain. For example see (Fig. 5.)
Method to represent the artefact with viewpoints and CG (Fig. 4.) O We can note that those different views constitute the different focus on description that all participants can take. So we can characterize the objective characteristic of all "expertise viewpoints" with the different step of the life cycle on the product.Declaration of concept type s in the lattice 9Introduction of all basic concept types in the lattice corresponding to all components of the object, 9Introduction of all oriented concept types corresponding to the different expertise for each focus on components. @ Construction of the CG for the decomposition of the product O Introduction of all expertise viewpoints (according to life cycle and participant) O Description through second order conceptual graphs, of all viewpoint relations existing between basic concept types and v-oriented concept types
101
9 Definition via a CG of all oriented concept types O Instanciation of concept types corresponding to the different objects and their different description(s) to express interaction or relations between components
/~owledge baseof CG~'~I ,
~ticeC~ type Setofrelation ~ewpointmanagemen~ @ O I LO Viewpointbase) ~,~Instantiation base~
|
I
Fig. 4. Steps in the building of artefact ODescription of viewpoint relation and expertise viewpoint relation Description viewpoints ~1~VpLmechanic) < TYPE:arrow TYPE:Beam ~--------(Vpt_shape) < TYPE:structural_element ~'-(Vpt_geometric) < TYPE:parallelepiped Expertise viewpoints TYPE:Description_geometric_tree: (Vpt_geometric&El~: TYPE:Treegeometric . _ j...-~Vpt topologic&Bz~ TYPE:Tree_skeletal TYPE: Description_topologic_tre~"~f-_~._(Vpt-_topologicE3)~ TYPE:Tree_skin TYPE:Tree_flux T~ . . . . . . . . . _.......~(Vpt thermal&E4)< et~:uescripti~ )~ TYPE:Tree_surface TYPE:DescriptiOn_material_tree~(Vpt_materialE3) < (Vpt_material&E1X 9 Definition via a CG of oriented concept types
definition graph of Treegeometric (x) Tree~------~Composed._of) >cylinder (Composed of)
> parallepiped
>(has_for)
TYPE:Tree_mechanic TYPE:Tree_thermal
>size:*y
> (has for) >quotation:*z
Fig. 5. Example of a part of an artefact represented vith viewpoints and CGs
Algorithmsfor Consistencycheckingduringthe buildingof the artefact: In this section, we present two of several algorithms(sub-process of the principal programs are not described in this paper), for checking consistency during the building of the artefact. We can not deal with all cases, in this paper, so the assumption is that the concept types lattice and the set of relations (conceptual relations, viewpoint relations, expertise relations) are already build.We denote the input variables with I:, and Output variable with O: 9 creation of a viewpoint relation Vpt between two concept types T1 and T2: Program
crea t e v i e w ~ o i n t_rela tion ( I : Vpt, T1, T2 )
102
G := TYPE:T2 -> (Vpt) -> TYPE:T1 If in the concept type lattice T2 < T1 then a d d G in the v i e w p o i n t base else y o u can not create a v i e w p o i n t r e l a t i o n b e t w e e n EndProgram
T2 and T1
9 instantiation of a concept type Tc by a r e , r e n t ref P r o g r a m i n s t a n t i a t i o n (I: Tc,ref) if Tc:ref a l r e a d y p r e s e n t in the i n s t a n t i a t i o n b a s e then ok for the i n s t a n t i a t i o n else if Tc is a b a s i c c o n c e p t type then creation_description(I:Tc, ref, i n s t a n t i a t i o n base) else if Tc is a v _ o r i e n t e d concept type then Tb := b a s i c _ c o n c e p t _ t y p e _ a s s o c i a t e d ( I : v i e w p o i n t base) if Tb:ref a l r e a d y p r e s e n t in i n s t a n c i a t i o n base then creation_viewpoint_instance(I:Tb,Tc,ref,instanciationbase,O: L i s t _ t y p e s instantiated) creation_other_instanciation(I:Tb,Tc,ref,List_types_i n s t a n t i a t e d , v i e w p o i n t base, i n s t a n c i a t i o n base) else add T:ref<-(Repr)<-Tc:ref in the instantiation base creation_other instanciation (I: T,Tc, r e f , n i l , v i e w p o i n t base, i n s t a n c i a t i o n base) else ok for i n s t a n t i a t i o n EndProgram
4.2
D e s c r i p t i o n of the M a n a g e m e n t o f the A r t e f a c t in C E
Artefact (CG base)
i n t e r a c t i o n with t ~ corporate m e m o r y
.._
i~r
IlnformationRetrieval viewpoints
'1 I 'j
IVisualization of Artefactl withCG I I '
.A
== ;~
"~ 2 t~
I / IJ 1~1~
"~ )
~itaiio,ls--~---"-, ~rT_~____~-~ "~ I I~,~ I
Ii /~I'" , ~ I v|sualizanon ~ ~
~x~-----/ !E" u4 /
I | .L
modificatl~'d~ Update the Artefact by 1,~-2--'~--'~-~-'~ (~')~'16~ '.'~"1 integTation of design ~--v.~-~ tr 'I solution 'I desi-n t2~'a~tt~ .g . IL ~ solution m CG Fig. 6. Viewpoint management in CE corporate memory
Method for information retrieval in the artefact 0 Information Retrieval through viewpoints (Fig. 6.)
~. \ ~.
(~" ,..
k-
~--~ ~ ='..~. ,~ ~0 t~
103
In the first task of CE, designers need to consult the current state of the artefact. So we propose to help the designer in information retrieval from the artefact representation by using viewpoints. Information retrieval uses the characterization of viewpoints on the objects domain, person and focus to filter information for the user (Fig. 6.). The principle is to use a navigation graph based on those objects in order to automatically filter information and to present only CG related to the asked viewpoints. For example, in (Fig. 7.) the characterization on "domain" of the artefact gives four viewpoints: mechanics, electronics, aerodynamics and hydraulics. Each viewpoint gives access to related information (phase 2 of CG visualization), or to another characteristic existing in viewpoints (in that case "hydraulics" gives access to three characteristics related to more specific viewpoints allowing more specific information about the artefact). This navigation 1 helps the user to find appropriate information and prevents him from getting lost in the complex base of CG.
~l~aerod ~
",
Y viewpoints
x~
"
'1
I
~23 .._
,
~
~
i !
Fig. 7. Navigation through viewpoints: consultation of the hydraulics viewpoint in the artefact.
note: When a participant choose one level in navigation graph, a concept is selected. It is composed by a concept type (domain, person or objective) and a referent (resp. reference of the domain, resp. reference of the person or resp. reference of the objective) 0 Visualization of artefact with CG (Fig. 6.) After using the navigation graph, we can select conceptual graphs related to the selected set of characteristics (that must correspond to one or several viewpoints). As we said in (Section 2.2), the use of conceptual graphs makes direct consultation of the designer easier. Algorithms (sub-process of the principal program are not described in this paper): This a l g o r i t h m uses only e x p e r t i s e viewpoints. Program selectiongraphs // S e l e c t i o n C o n c e p t s c h a r a c t e r i s i n g the v i e w p o i n t a s k e d by the u s e r S e l e c t i o n in n a v i g a t i o n _ g r a p h ( O : L_concepts) / / S e a r c h in d e f i n i t i o n of v i e w p o i n t r e l a t i o n types, all viewp o i n t r e l a t i o n types that contains all the concepts s e l e c t e d S e a r c h _ v i e w p o i n t s _ a s s o c i a t e d (I :L_concepts, 0 : v i e w p o i n t _ l i s t ) S e a r c h _ l i s t of v o r i e n t e d _ c o n c e p t _ t y p e s _ a s s o c i a t e d ( I : v i e w p o i n t _ l i s t , 0 :list v o r i e n t e d _ c o n c e p t _ t y p e s ) S e a r c h _ g r a p h s _ d e f i n i t i o n s _ a n d _ l i s t of v o r i e n t e d _ c o n c e p t s (I :L
h The user can ask for information to be filtred with all objects characterising viewpoints used in the artefact structuring.
104
ist v o r i e n t e d _ c o n c e p t _ t y p e ; O: l i s t _ a n s w e r e d _ g r a p h s on c o n c e p t _ t y p e _ d e f i n i t i o n , i is t _ o r i e n t e d _ c o n c e p t ) Search_graphs in C G B a s e (I : l i s t _ o r i e n t e d _ c o n c e p t , 0 : i i s t_answered_graphs ) EndProgram
Remark: This work is in progress, because answers of this algorithm are not sufficiently organized for the designer, in comparison to the work realised in Rock 1.
Methodfor the Up-date of the artefact by integration of design propositions 0 Update the artefact by integration of design propositions (Fig. 6.) In the third task of CE (evaluate task), designers need to integrate the design propositions chosen in the artefact. This integration must be guided by the navigation through objects characterizing a viewpoint in order to detect in which part of the artefact, propositions must be integrated. Using description viewpoints, we can detect if concept types used to describe a design proposition have equivalence in other viewpoints: in 10 we defined inter-viewpoints relations, like equivalence or inclusion, between two concept types. Thanks to these inter-viewpoint relations and to the projection operator, we can compare a conceptual graph of the artefact and the conceptual graph of the design proposition. Furthermore with the different operations of conceptual graphs, we can detect if the given design proposition graph is a specialization (resp. generalization) of a more generic (resp. specific) graph already present in the artefact. The system can also detect if the given design proposition graph is the definition of a concept already used in a conceptual graph in the artefact. All those verifications can be done with classic conceptual graph operations and with new operations created for the viewpoint management in conceptual graphs 10. The use of conceptual graph and viewpoints facilitates the integration of design solution in the artefact by choosing the good viewpoints to integrate the solution and by using operations on conceptual graph for consistency checking.
Algorithm for comparison of conceptual graphs In this paper, we focus on the building of a corporate memory with the different states of the artefact. When we want to integrate a solution in the artefact, to generate a new state of the artefact, we must take into account that the solution is a consensual decision of participants. The solution is the result of the "evaluate task" in the CE Cycle. So an algorithm for comparison of graphs (such as the proposition in 3) is essential to detect that the solution is more general or more specific than descriptions in the artefact. But the extension for viewpoints proposed in this part could be very more efficient in the "evaluate task". So we propose an extension, for the viewpoint management, of the algorithm proposed in 3 for the comparison and integration of two conceptual graphs. 3 proposes some relations existing between concept types, and also relations existing between two "links". A link is an "elementary link of a conceptual graph rel(C 1..... Cn)". This relation permits to categorize the relation existing between two graphs (subgraph or supergraph, contraction and expansion, specialization, generalization, instantiation and
conceptualization).
105
In each of this categorization, we have more precise relations that can be exist between two graphs. As in 3, we use the notation CG=(C, RA). To a given conceptual graph, A is the set of its "elementary links" denoted rel(C 1..... Cn) with rel e R with arity(rel)=n, and for i 1..n, C i = adj(i,rel) e C. In our approach of viewpoint we propose new relations among Concept vertices of different conceptual graphs and in the same way, several relations among elementary links of those graphs.
new relations among Concept vertices of different conceptual graphs Let C G I = ( C I , ~ , A I ) and CG2=(C2,~2,A2) the conceptual graphs to be compared. We define the additional binary relations on C1 * C2 and redefine some of relations described in 3: 9 isspecialized_viewpoint (C1,C2) iff type (C1) < type(C2) A referent(C1) = referent(C 2) ^ C 1 is a v-oriented concept type ^ C 2 is a basic concept type ^ 3 G in instantiation base such that G: C1->(Repr)->C 2 9 is_generalized viewpoint(C1,C2)" iff is_specialized_viewpoint(C2,C1) 9 is_equivalent_concept (C1,C 2) iff type(C1) t..) type(C2) ~ T ^ 3 G in viewpoint base such that G: TYPE:type(C 1) ->(equiv)-> TYPE:type(C2) 9 is_inclusion_concept (C1,C2) iff type(C1) u type(C2) ~ T ^ 3 G in viewpoint base such that G: TYPE:type(C 1) ->(incl)->TYPE:type(C2) 9 is_exclusion_concept (C1,C 2) iff type(C1) u type(C2) ~ T A 3G in viewpoint base such as G: TYPE:type(C 1) - >(excl) -> TYPE:type(C2) 9 ismore_generalized_concept (C1,C2) iff is_generalization (C1,Cx) v is__generalized_viewpoint(C 1,C2) v is generalization&conceptualization(Ct,Cx)
New relations among elementary links of different conceptual graphs Let C G I = ( q , ~ I , A I ) and CG2=(C2,~e~2,A2) the conceptual graphs to be compared. We define additional kinds of relations possible 2between elementary links of CG 1 and CG 2, respectively denoted linkl=rell(C 11...Cln) and link 2 = rel 2 (C21...C2n), where rel 1 and rel 2 have the same arity: 9 9
is_concept_total_viewpoint_specialization(Linkl,Link2) iff type(rell)=type(rel 2) ^ Vie l..n, isspecialized_viewpoint (adj(i,rell), adj(i,rel2)) is_concept_partial_viewpoint_specialization (Linkl,Link2) iff type(rell)=type(rel2) ^ V i e 1..n, (isspecialized_viewpoint (adj(i,rell), adj(i,rel2)) v 2.In this article we do not define the same relation if type(rell)
106
is_specialization(adj(i,rell),adj(i,rel2) ) v is_same_concept(adj(i,rell), adj(i,rel2)) ) ^3ie 1..n, is_specialized_viewpoint (adj(i,rell), adj(i,rel2)) ls_concept_total_viewpoint_generalization(Linkl,Link2) iff is_concept_total_viewpoint_specialization(Link2,Linkl) lS_Concept_partial_viewpoint_generalization(Link 1,Link2) iff is_concept_partial_viewpoint specialization (Link2,Linkl) is_concept_total_equivalence (Linkl,Link 2) iff type(rell)=type(rel 2) ^ Vie 1..n, is_equivalent_concept (adj(i,rell), adj(i,rel2)) is_concept_total_inclusion (Linkl,Link 2) iff type(rell)=type(rel 2) A Vie 1..n, is_inclusion_concept (adj(i,rell), adj(i,rel2)) 9 is_concept_exclusion (Link l,Link 2) iff type(rell)=type(rel2) A 3ie 1..n, is_exclusion_concept (adj(i,rell), adj(i,rel2)) 9 IS_Concept_partial_equivalence (Link 1,Link2) iff type(rell)=type(rel 2) A Vie 1..n, (is_equivalent_concept (adj(i,rell), adj(i,rel2)) v is_same_concept(adj(i,rell), adj(i,rel2)) ) A3ie 1..hi, is_equivalent_concept (adj(i,rell), adj(i,rel2)) 9 is_concept_partial_inclusion (Link 1,Link2) iff type(rell)=type(rel 2) A Vie 1..n, (is_inclusion_concept (adj(i,rell), adj(i,rel2)) v is_same_concept(adj(i,rell), adj(i,rel2)) ) A3ie 1..n, is_inclusion_concept (adj(i,rell), adj(i,rel2)) 9
9
9
9
New relations among conceptual graphs According to the definition of relations between elementary links, we can define new relations between conceptual graphs: 9 The equivalence relation can be exploited for graphs expressing the same propositions with different vocabularies. 9 The inclusion relation can be exploited for expressing inclusion of a proposition in another. 9 The exclusion relation can help to indicate two incompatible graphs. 9 The definition of specialization through viewpoints, can be included in the relation "concept total specialization" and "concept partial specialization". All those relations can help in detection of conflicts between design propositions in the "evaluate task" of the CE process 9 CG 2 is "a totally equivalent graph" of CG l iff 3 a graph morphism (he: C2->C1, hr: ~2->~1, ha:A2->^1) from CG 2 to CG 1 such that Vlink2e A2, is_concept_total_equivalent (link 1,ha(link2)) 9 CG 2 is "a partially equivalent graph" of CG 1 iff q a graph morphism (he: C2->C1, hr: ~(2->~1, ha:A2->N1) from CG 2 to CG 1 such that Vlink2e A2, (is_concept_partial_equivalent (link 1,ha(link2)) v is_same_link (link 1,ha(link2))) A 31ink2e A2 such that: is_concept_partial_equivalent (link 1,ha(link2)) 9 CG 2 is "a totally included graph" of CG 1 iff 3 a graph morphism (hc: C2->C1, hr: 9~2->9~1, ha:A2->A1) from CG 2 to CG 1 such that Vlink2e A 2, is_concept_total_inclusion (link l,ha(link2)) 9 CG 2 is "a partially included graph" of CG 1 iff q a graph morphism (he: C2->C1,
107
9
hr: PW>~, ha:A2->A1) from CG 2 to CG 1 such that Vlink2~ A2, (is_concept._partial_inclusion (link 1,ha(link2) ) v is_same_link (link 1,ha(link2))) ^ 31ink2e A2 such that: is_concept_partial_inclusion (linkl,ha(link2)) CG 2 is "a exclusion graph" of CG 1 iff 3 a graph morphism (hc: C2->C1, hr: PW>~, ha:A2->A1) from CG 2 to CG 1 such that 31ink2e A2, is_concept_exclusion (link 1,ha(link2) )
4.2.0.1 Strategies of integration of a proposition in the artefact When all relations between elementary links are given, 3 proposes several strategies to integrate the two compared conceptual graphs. In the artefact, the information or knowledge must be as precise as possible. So we detail the different cases of relations that could exist between two conceptual graphs: 9 If there is one of the different relations of specialization, detail in 3, then we apply the "strategy of the highest direct specialization": if the proposition is more precise than a description in the artefact, and use more precise expression, we prefer to restrict what was expressed in the artefact. 9 If there is one of the different relations of instantiation, then we apply the "strategy of the highest direct instantiation". 9 If there is a relation of partial equivalence and equivalence, then we can keep the two graphs in the different viewpoints they belong to, or choose one of them. 9 If there is a relation of inclusion or partial inclusion, we keep the graph that includes the other graphs, because the information in the included graphs will be present in the other graph. 9 If there is an excluded relation, the proposition is not valid. This case can note append in this context of integration of a solution in the artefact, but is efficient in the "evaluate task".
5 Conclusion In this paper, we present an approach to the construction of a corporate memory in CE, in taking account the different steps of the artefact during the design process. We propose a representation of artefact with viewpoints and conceptual graphs based on previous work on CG and an adaptation of viewpoints and viewpoints management to this problem. We introduce the notion of description viewpoints, and expertise viewpoints. We propose several algorithms (not detailed in this paper)for the building and maintain of the CG base representing artefact. Related work are already done in Design Rationale: 9 propose to use case librairies to represent past experiences and 6 focused on the usability of design rationale documents, but they do not use the conceptual graph formalism. Our approach using viewpoints and CGs can be extend to the different elements of a corporate memory detailed in 6 and it take care of the variety of information sources and the context in which knowledge or information must be understood. The implementation of this work is in progress and realized with the COGITO platform. In further work we have to organize answers of algorithms according to the different levels of viewpoints. Our aim is to propose a support system allowing the management of a CE project memory, based first on the artefact, but also must be
108
extended to the proposition (for the Design Rationale part) of 11, i.e. take into account the history of artefact but also the different possible choices during the CE process represented by the different design propositions. In this way, we could use efficiently the algorithm of comparison to see differences between several propositions
References 1.
Carbonneill,B., Haemmerlr, O., Rock: Un syst~me de question/reponse fondd sur le formlaisme des graphes conceptuels, In actes du 9i~meCongr~s Reconnaissances des Formes et Intelligence Artificielle, Paris, p. 159-169, 1994.
2.
Cointe,C., Matta, N., Ribi~re, M., Design Propositions Evaluation: Using Viewpoint to manage Conflicts in CREoPS2, In Proceedings of ISPE/CE, Concurrent Engineering: Research and Applications, Rochester August 1997.
3.
Dieng, R., Hug, S.,MULTIKAT, a Tool for Comparing Knowledge of Multiple Experts, In Proceedings of ICCS'98, Ed. Springer Verlag, Montpellier, France, August 1998.
4.
Finch,I., Viewpoints - Facilitating Expert Systems for Multiple Users, In Proceedings of the 4th International Conference on Database and Expert Systems Applications, DEXA'93, ed. Springer Verlag, 1993.
5.
Gerbr, O., Conceptual Graphs for corporate Knowledge Repositories, In Proceedings of ICCS'97, ed. Springer-Verlag, Seattle, Washington, USA, August 1997
6.
Karsenty,L., An empirical evaluation of design rationale documents, Electronic Proceedings of CHI'96, http:llwww.acm.orglsigchilchi961proceedings/paperslKarsenty/ lk_txt.htm, 1996.
7.
Leite,J.,Viewpoints on viewpoints, in Proceedings of Viewpoints 96: An International Workshop on Multiple Perspectives in Software Development, San Francisco, USA, 14-15 October, 1996.
8.
Marino,O., Rechenmann, F., P. Uvietta, Multiple perspectives and classification mechanism in Object-oriented Representation, Proc. 9th ECAI, Stockholm, Sweden, p. 425-430, Pitman Publishing, London, August 1990.
9.
Prasad,M.V.N., Plaza, E., Corporate Memories as Distributed Case Librairies, Proceedings of the 10th banff, Knowledge Acquisition for Knowledge-based Systems Workshop, Banff, Alberta, Canada, November 9-14, p. 40-1 40-19, 1996.
10.
Ribi~re,M., Dieng, R., Introduction of viewpoints in Conceptual Graph Formalism, In Proceedings of ICCS'97, Ed. Springer-Verlag, Seattle, USA, Aofit 1997,
11.
Ribi~re, M., Matta, N., Guide for the elaboration of a Corporate Memory in CE, submitted to the 5th European Concurrent Engineering Conference, Erlangen-Nuremberg, Germany, april 26-29, 1998.
12.
Tichkiewitch, S., Un modkle multi-rues pour la conception integr~e, in Summer Scool on ....Entreprises communicantes: Tendances et Enjeux", Modane, France, 1997.
13.
Sowa, J.F., Conceptual Structures, lnformation Processing in Mind and Machine. Reading, Addison-Wesley, 1984.
WebKB-GE
- - A V i s u a l E d i t o r for C a n o n i c a l Conceptual Graphs
S. Pollitt 1, A. Burrow i, and P.W. Eklund 2 i sepollitt/alburrow@cs,
adelaide, edu. au
Department of Computer Science, University of Adelaide, AUSTRALIA 5005 2
p. eklund@gu, edu. au
School of Information Technology, Griffith University, Parklands Drive, Southport, AUSTRALIA 9276 Abstract. This paper reports a CG editor implementation which uses canonical formation as the direct manipulation metaphore. The editor is written in Java and embedded within the WekKB indexation tool. The user's mental map is explicitly supported by a separate representation of a graph's visual layout. In addition, co-operative knowledge formulation is supported by network-aware work-sharing features. The layout language and its implementation are described as well as the design and implementation features. 1
Introduction
Display form conceptual graphs (CGs) provide information additional to the graph itself. An editing tool should therefore preserve layout information. For aesthetic reasons a regular layout style is also preferred. However, one consideration of good CG layout (as opposed to a general graph layout) is that understandability is the primary goal rather than attractiveness 2. The editor we describe (WebKB-GE) limits manipulation on the graph to the canonical formation rules 16 (copy, restrict, join, simplify). Atomic graphs are also canonical and therefore any CG constructed using WebKB-GE will be canonical. WebKB 12 is a public domain experimental knowledge annotation toolkit. It allows indices of any Document Elements (DEs) on the WWW to be built using annotations in CGs. This permits the semantic content, and relationships to other DEs, to be precisely described. Search is initiated remotely, via a WWWbrowser and/or a knowledge engine. This enables construction of documents using inference within the knowledge engine to assemble DEs. Additionally, the knowledge base provides an alternate index through which both query and direct hyperlink navigation can occur. WebKB has been built using Javascript and Java for the WWW-based interface and C and C + + for the inference engines. One of the goals of the WebKB toolkit is to aid Computer Supported Co-operative Work (CSCW). WebKB-GE is integrated into WebKB and therefore multi-user/distributed features are implemented. 2
Design
Goals
WebKB-GE is designed to be used by domain experts in a distributed cooperative environment. This means: (i) domain dependent base languages must
112
be distributed; (ii) co-operation depends on a shared understanding of a base language; (iii) domain experts are not necessarily experts in CG theory; (iv) large, collaborative domain knowledge bases are difficult to navigate; (v) a medium for collaborative communications must be provided. The design of WebKB-GE supports the construction of accurate well-formed CGs allowing the user to experience a CG canon's expressiveness. This is achieved through a direct manipulation interface. The properties of a graphs depiction are explicitly stored between sessions. WebKB-GE is designed to operate as a client tool in a distributed environment. 2.1
Direct M a n i p u l a t i o n
Direct manipulation (DM) allows complex commands to be activated by direct and intuitive user actions. DM is the visibility of the object of interest; rapid, reversible, incremental actions; and replacement of complex command language by direct manipulation of the object of interest 15. It should allow the user to form a model of the object represented in the interface 4. A well recognised subclass of DM interfaces is the graphical object editor 17 where the subject is edited through interaction with a graphical depiction. Unidraw 18 is a toolkit explicitly designed to support the construction of graphical object editors. WebKB-GE is an example of a graphical object editor handling CGs. Central to the DM interface is the Editing/Manipulation Pane. This contains a number of Objects manipulated by Tools. Relations between objects are also indicated. Objects provide visual representations of complex entities. The Concepts and Relations in CGs are graphical objects in WebKB-GE. A concept may contain additional information (an individual name for example) but only the Type is displayed in the visual representation. A palette of tools is provided to manipulate objects. The behaviour of a tool may be a function of the manipulated object, so each tool expresses an abstract operation. "Operation animation" is an essential feature of a DM interface. An operation like "move" allows the user to see the object dragged from the start to the finish point. Visual feedback about the success or failure of an operation must be provided. 2.2
Canonical Graphs
WebKB is aimed at the domain expert. It is important to restrict the graphs to those derivable from a canon. To ensure canonical graphs, the only operations allowed are canonical formation rules 16; (i) C o p y - a copy of a canonical graph is canonical; (ii) R e s t r i c t - a more general type may be restricted to a more specific type (as defined in the Type hierarchy). Also, a generic concept type may be replaced by an individual object of that type; (iii) J o i n - two canonical sub-graphs containing an identical concept are joined at that concept; (iv) Simplify - when a relation is duplicated between identical concepts the duplicates are redundant and removed. A distinction is made between operations that affect the graph and operations that affect the representation of the graph. Each of the four canonical operations operate on the underlying graph and the visual representation is updated accordingly. These are the only operations allowed on the graph itself. Operations on the representation of the graph, such as a "Move" operation, are also allowed.
113
(b)
le)
(c)
$
Fig. 1. Visual feedback in a WebKB-GE join operation. The left hand side shows an unsuccessful join. The system starts in a stable state (a) a concept is dragged in (b). The join is invalid so the dragged object turns red. The mouse is released at this point. The operation is undone by snapping the concept back to the previous position (c). The right hand side of shows a successful join. The system starts in (d), the lower left concept is moved towards an identical concept (e). The mouse is released and the two concepts snap together as the join is performed (f).
2.3
Distributed Multi-User Application
CSCW tools such as WebKB, allow members of a group to access a shared canon. The canon is received each time the user starts the application to ensure changes are propogated from the central site. The server is not fixed and the user chooses from several. Graphs created by distributed users should be available to the other members of the workgroup. The ideal way is for clients to send graphs back to the central server. When users share information it is important that the original creator be acknowledged. These features are implemented in WebKB-GE. 2.4
L a y o u t Retention
In preceding local implementations of CG editors 1, 3 only the graph operations were considered important. No display or linear form editors in the literature have the capacity to maintain display form representations 11, 13. In these tools the formation rules are sometimes implemented for graph manipulation but only the final linear form of the graph is stored between editing sessions. The visual representation of a conceptual graph contains additional metainformation significant to the graph's creator. Layout should be disturbed as little as possible by operations performed on the underlying CG. This allows the users' mental map 14 to be preserved. Additionally, the user will want to alter the visual representation while not altering the underlying graph. The only such operation permitted is moving objects to new spatial locations. These moving operations are constrained - - a regularity is imposed by the layout language describing the visual representations. The method chosen for layout storage is implemented according to Burrow and Eklund2 and described below in Section 3.4.
114
3 Implementation 3.1 Architecture A general multiple server/multiple client architecture allows communication over a network such as the Internet. The network is not an essential p a r t of the system - - b o t h server and client can run on a single machine. The server code controls distribution of a canon to clients. In addition, initial layouts for a canon are sent to a client. The server can handle database access for a shared CG canon. The client requests a copy of a canon from a server as well as the layout of any new subgraphs the user adds to the editing pane.
3.2
Implementation Language: Java
One i m p o r t a n t issue is the difference between J a v a Applets and J a v a Applications. An Applet is a J a v a program 5 t h a t runs within a restricted environment, normally a Web browser. This restricted environment does not allow certain operations for security reasons: (i) making a network connection to a machine other t h a n t h a t from which the applet was loaded. This restricts each instance of the client tO only contact a single server. Changing servers requires the whole applet be re-loaded from the new server: (ii) accessing the local disk. The client is unable to r e a d / w r i t e to the local disk and unable to save/load CGs locally. This is not a large problem depending on how saving graphs is handled. If all graphs are saved via the server no local access is required. Each time an applet is loaded in a web browser all code for t h a t applet is downloaded from the server to the client machine. This ensures the user is receiving continuously updated software but can be a slow if the applet is large. With a J a v a application, the J a v a Run-time Environment (JRE) is downloaded separately for the appropriate platform. The application code is executed using the JRE. Applet restrictions do not apply for J a v a Applications and for this reason b o t h the client and server code are written as J a v a Applications. A number of DM toolkits are available for use with Java. Most provide a layer on top of the Abstract Windowing Toolkit (AWT) to make interface creation straightforward. Some of the more widely known toolkits are subArctic 6, Sgraphics 9 and the Internet Foundation Classes 7. The DM toolkit for W e b K B - G E is subarctic6, a constraint-based layout toolkit. At the time W e b K B - G E was written it was the most stable of supported toolkits. It is also available free for both commercial and non-commercial use. Objectspace has created the "Generic Collection Library" (JGL) for J a v a 8. This library was also used.
3.3
Communication
For communication between client and server a simple protocol was implemented. Currently only two active operations are implemented: (i) Canon Request - the server responds to this by returning a copy of the canon being served, read from its local disk; (ii) Layout Request - - the server reads the relation name sent by the client and returns the layout specification for t h a t relation. Additional operations, such as canon modifications and database access, can be added to the protocol if required. The client application contains two parsers to process information from a server. One parser reads the linear CGs and other information
115
from the canon to build the internal CG data store. The second reads layout and builds the visual representation of each graph. 3.4
Layout Language
The layout language devised to display CGs is the feature that differentiates this editor from othersll, 13, 3. The language originates in Kamada and Kawai10 who developed a constraint based layout language (COOL) to generate a pictorial representation of text. Graphical relations in COOL are one of either geometric relations - - constraints between variables characterising the objects; and drawing relations - - lines and labels on and between objects. Specifying layout is performed in two stages: (i) constraining the (defined) reference points to lie on a geometric curve (line, arc, spline); (ii) connecting the reference points of the object by a geometric curve with an arrowhead. Burrow and Eklund 2 devised a canon that represents the visual structure of conceptual graphs in the language of CGs. Following that work, the actual physical locations of objects are not stored in WebKB-GE. Instead, spatial relationships between the objects are captured in the language. A container-based approach is used. All objects must be stored in horizontal and vertical containers. The ordering of the objects within containers is preserved as objects are moved. If a container in either orientation does not exist at the final move location, a new container is created in that direction. Moving the final object out of a container dissolves the container. Horizontal containers are defined to extend to the width of the editing pane with the height of the tallest object contained. Vertical containers are defined to extend to the height of the editing pane with the width of the widest object. In WebKB, as in any co-operative work environment, it is important to record the original source of knowledge and data. Because layout information is saved separately from the linear form a mapping from linear form to display objects is also required. This is achieved by generating a quasi-unique identifier for every graph component. This is created using the Internet Protocol (IP) address of the machine on which the graph was created along with the time-stamp. This results in a twenty four digit identifier. Inside the client application the linear and display form of the graph are stored and manipulated separately. The two forms are synchronised using the twenty four digit identifier discussed above. The abstract (linear) graph information is stored in a series of data structures descending from the editing pane. The canon currently in use is also stored in the editing sheet and constructed from the Type and Relation hierarchies. Each entry in the Relation hierarchy contains a graph describing the concept types to be connected by the relation. Both graphs in relation definitions and user constructed graphs have their abstract information stored internally in a CG map: one for each graph. The graphical layout is stored in a series of containers with the top level being the "Container Constrainer". This handles alignment of horizontal and vertical containers and creates/destroys new/old containers. Each container is responsible for managing the layout of the objects contained within it. When objects change their dimensions or are added and removed the container resizes appropriately. The code
116
ensures containers are not too close together. Each object in the graphical representation maintains a connection with the abstract graph object it displays. When graph operations are targeted on a graphical object the abstract object is retrieved. Links between abstract graph objects (edges) are not stored in object containers but maintained within the user interface. Due to the simplicity of the layout language there are only a very Small number of definitions that may appear. HBOX:hbox_uum ~ ( H C O N T A I N S ) ~ E L E M E N T : ! uniqueid. VBOX:vboxnum-+(VCONTAINS)-+ELEMENT:!uniqueid. hboxnum and vboxnum denote the box into which to insert the element. The box numbers do not have to indicate any sort of ordering. The uniqueid is the placeholder for the corresponding element in the linear description. E L E M E N T : ! uniqueid--+ ( E L T R I G H T ) - + ELEMENT:!uniqueid. ELEMENT:!uniqueid~(ELTBELOW)-+ELEMENT:!uniqueid. The second uniqueid indicates the corresponding element is to the right (below) the first uniqueid.
HBOX:hboxnum-+(BOXBELOW)-->HBOX:hboxnum. VBOX:vboxnum--+(BOXRIGI-IT)-+VBOX:vboxnum. The second box specified is below (to the right of) the first. With these definitions the relative layout is stored. When a relation is added to the editing pane by the user, or a graph is loaded from a file, the following process occurs: 1. the linear form is loaded into a temporary CG map. This restricts the search space for resolving unique IDs and rollback if an error occurs. If a relation from the canon is being added, this occurred when the canon was retrieved; 2. the layout script of the graph is processed and objects to be placed in the containers. Container objects are reordered correctly; 3. dummy objects are resolved using the appropriate abstract objects from the linear form. Graphical representations of the links between objects are created and stored in the interface; 4. each graphical container is resized to fit the largest contained object. Containers are assigned an initial starting position which accounts for spacing between the containers. Positions of the graphical links are updated as the containers (and consequently, the objects) move; 5. if the previous stages occur successfully, the layout and abstract objects are merged in the editing pane. ! 1 :User
{-> ( !2 :Role) -> !3 :WN_expert,
-> ( !4 :Chrc) -> !5 :Property
).
Fig. 2. The augmented linear form of the CG. Fig. 2 shows the linear form augmented with unique identifiers. The graphical layout script is shown in Fig. 3 and the corresponding screen-shot shown in Fig. 4. The format of the canon used by the editor is a simple series of definitions giving the concept and relation hierarchies. The lattices containing the definitions must be defined first, with a separate lattice for every arity relation required. For example (from the default canon):
117
[HB0X:I] -> (HCONTAINS)-> [ E L ~ N T : ! I ] . [HBOX:I] -> (HCONTAINS) -> [ELEMENT:!4]. [RSOX:2] -> (HCONTAINS) -> [ELEMENT:!2]. [HBOX:2] -> (HCONTAINS) -> [ELEMENT:!5]. [HBOX:3] -> (HCONTAINS) -> [ELEI~NT:!3]. [ELENENT:!I] -> (ELTRIGHT) -> [ELENENT:!4]. [ELEMENT: !2] -> (ELTRIGHT) -> [ELEMENT: !5]. [HBOX:I] -> (BOXBEL0W) -> [RSOX:2]. [HBOX:2] -> (BOXBEL0W) -> [HBOX:3].
[VB0X:I] [VBOX: I] [VBOX:2] [VBOX:2] [VB0X:2] [ELEMENT: [ELEMENT: [ELEMENT: [VBOX: I]
-> (VCONTAINS) -> [ELEMENT: !I]. -> (VCONTAINS) -> [ELEMENT: !2]. -> (VCONTAINS) -> [ELEMENT: !4]. -> (VCONTAINS) -> [ELEMENT:!5]. -> (VCONTAINS) -> [ELEMENT: !3]. !1] -> (ELTBEL0W) ~> [ELEMENT: !2]. !4] -> (ELTBEL0W) -> [ELEMENT: !5]. !5] -> (ELTBELOW) -> [ELEMENT: !3]. -> (BOXRIGHT) -> [VBOX:2].
Fig. 3. The layout description of the graph.
Fig. 4. The top level window with the example graph loaded. lattice lattice
UNIVERSAL, ABSURD i s t y p e : *. TOP-T1-T1, BOT-T1-T1 i s r e l a t i o n
( UNIVERSAL, UNIVERSAL ) .
The concept hierarchy is then defined: type Entity(x) is [!I:UNIVERSAL:*x]. type Situation(x) t y p e S o m e t h i n g _ p l a y i n g _ a _ r o l e ( x ) i s [ ! 3 :UNIVERSAL: * x ] .
is
[!2:UNIVERSAL:*x].
Finally the relation hierarchies are defined: relation Attributive_binaryRel(x, y) i s [ ! 1 : UNIVERSAL: *x] - > ( ! 2 : TOP-TI-TI) -> [ ! 3 : UNIVERSAL : * y ] . relation Spatial_binaryRel(x, y) i s [ ! 7 : UNIVERSAL: *x] - > ( ! 8 : TOP-TI-TI) -> [ ! 9 : UNIVERSAL : * y ] .
r e l a t i o n Component b i n a r y R e l ( x , [ ! 4 : UNIVERSAL : *x] - > ( ! 5 : TOP-TI - T I ) - > [ ! 6 : UNIVERSAL : * y ] .
y) i s
Once the linear sections of the canon have been defined, the initial layouts of the relations must be defined. Each relation layout is specified in a file with the naming form: -.layout. A layout script for the graph is contained in that file. For example, the layout for Spatial_binaryRel is: [HBOX: I] -> (HCONTAINS) -> [HBOX:I] -> (HCONTAINS) -> [HBOX:I] -> (HCONTAINS) -> [ELEMENT: !7] -> (ELTRIGHT) [ELEMENT:!8] -> (ELTRIGHT)
4
[ELEMENT: !7]. [ELEMENT:!8]. [ELEMENT:!9]. -> [ELEMENT: !8]. -> [ELEMENT:!9].
[VBOX: I] [VBOX:2] [VBOX:3] [VEOX:I] [VEOX:2]
-> -> -> -> ->
(VCONTAINS) (VCONTAINS) (VCONTAINS) (BOXItIGHT) (BOXRIGHT)
-> [ELEMENT: !7]. -> [ELEMENT: !8]. -> [ELEMENT:!9]. -> [VBOX:2]. -> [VBOX:3].
Conclusion
A visual-form CG editor has been designed and implemented. Editing operations are restricted to the four canonical formation rules. This guarantees well-formed CGs. The key feature of this editor is the use of a graphical scripting language to capture relevant details of the graph layout. This information is stored along with the linear information.
118
The application is written to be used for co-operative work by networkconnected users and in particular for use in the WebKB indexation toolkit. Only simple graphs are currently supported. The ability to extend the framework to nested graphs, along with extending the layout language with different containers, is inherent in the design of the editor. WekKB and W e b K B - G E m a y be obtained from h t t p : / / w w w , i n t . gu. edu. au/kvo.
References 1. A.L. Burrow. Meta tool support for a GUI for conceptual structures. Hons. thesis, Dept. of Computer Science, www.int.gu.edu.au/kvo/reports/andrew.ps.gz, 1994. 2. A.L. Burrow and P.W. Eklund. A visual structure representation language for conceptual structures. In Proceedings of the 3rd International Conference on Conceptual Structures (Supplement), pages 165-171, 1995. 3. Peter W. Eklund, Josh Leane, and Chris Nowak. GRIT: An Implementation of a Graphical User Interface for Conceptual Structures. Technical Report TR94-03, University of Adelaide, Dept. Computer Science, Feb. 1994. 4. P.W. Eklund, J. Leane, and C. Nowak. GRIT: A GUI for conceptual structures. In Proceeedings of the 2rd International Workshop on PEIRCE. ICCS-93, 1993. 5. James Gosling and Henry McGilton. The Java Language Environment: A White Paper. Technical report, Sun Microsystems, 1996. 6. Scott Hudson and Ian Smith. subarctic User Manual. Technical report, GVU Center, Georgia Institute of Technology, 1997. 7. IFC Dev. Guide. Technical report, Netscape Communications Corp., 1997. 8. JGL User Manual. Technical report, Objectspace Inc., 1997. 9. Mike Jones. Sgraphics Design Documentation. Technical report, Mountain Alter-
native Systems, http://www.mass, com/software/sgraphics/index, 1997. 10. T. Kamada and S. Kawai. A general framework for visualizing abstract objects and relations. ACM Transactions on Graphics, 10(1):1-39, January 1991. 11. R.Y. Kamath and Walling Cyre. Automatic integration of digital system requirements using schemata. In 3rd International Conference on Conceptual Structures ICCS'95, number 954 in LNAI, pages 44-58, Berlin, 1995. Springer-Verlag. 12. P.H. Martin. The WebKB set of tools: a common scheme for shared W W W annotations, shared knowledge bases and information retrieval. In Proceedings of the CGTools Workskop at the 5th International Conference on Conceptual Structures ICCS '97, pages 588-595. Springer Verlag, LNAI 1257, 1997. 13. Jens-Uwe MSller and Detlev Wiesse. Editing conceptual graphs. In Proceedings of the 4 th International Conference on Conceptual Structures ICCS'96, pages 175187, Berlin, 1996. Springer-Verlag, LNAI 1115. 14. George G. Roberston, Stuart K. Card, and Jock D. Mackinlay. Information visualization using 3D interactive animation. CACM, 36(4):57-71, Apr 1993. 15. B Shneiderman. Direct manipulation. Computer, 16(8):57-68, Aug 1983. 16. J Sowa. Conceptual Structures : Information Processing in Mind and Machine. Addison-Wesley, 1984. 17. J. Vlissides. Generalized graphical object editing. Technical Report CSL-TR-90427, Dept. of Elec. Eng. and Computer Science, Stanford University, 1990. 18. John M. Vlissides and Mark A. Linton. Unidraw: A framework for building domainspecific graphical editors. ACM Trans. on Info. Systems, 8(3):237-268, Jul 1990.
Mapping of CGIF to Operational Interfaces A. Puder International Computer Science Institute 1947 Center St., Suite 600 Berkeley, CA 94704-1198 USA puder~icsi, berkeley, edu
Conceptual Graph Interchange Format (CGIF) is a notation for conceptual graphs which is meant for communication between computers. CGIF is represented through a grammar that defines 'tonthe-wire-representations". In this paper we argue that for interacting applications in an open distributed environment this is too inefficient both in terms of the application creation process as well as runtime characteristics. We propose to employ the widespread middleware platform based on CORBA to allow the interoperability within a heterogeneous environment. The major result of this paper is a specification of an operational interface written in CORBA's Interface Definition Language (IDL) that is equivalent to CGIF, yet better suited for the efficient implementation of applications in distributed systems. K e y w o r d s : CGIF, CORBA, IDL. A b s t r a c t . The
1
Introduction
Conceptual Graphs (CG) are abstract information structures t h a t are independent of a notation (see 5). Various notations have been developed for different purposes (see Figure 1). Among these are the display form (graphical notation) or the linear form (textual notation). These two notations are intended for h u m a n computer interaction. Another notation called Conceptual Graph Interchange Format (CGIF) is meant for communication between computers. C G I F is represented through a g r a m m a r t h a t defines "on-the-wire-representations" (i.e. the format of the d a t a transmitted over the network). The reason for developing C G I F was to support the interoperability for C G based applications t h a t needed to communicate with other C G - b a s e d applications. We argue t h a t for interacting applications in an open distributed environment this is too inefficient both in terms of the application creation process as well as runtime characteristics. Applications t h a t need to interoperate are written by different teams of programmers, in different p r o g r a m m i n g languages using different communication protocols. A generalization of this problem is addressed by so-called middleware platforms. As the name suggests, these platforms reside between the operating syst e m and the application. One prominent middleware platform is defined through the Common Object Request Broker Architecture (CORBA) which allows the interoperability within a heterogeneous environment (see 4). In this p a p e r we will show how to use C O R B A for C G - b a s e d applications.
120
~ .
.
.
.
.
.
.
.
.
.
.
ConceptualGraphs /
.
~
~
Intension
_
.
.
.
. . . . . . . . . . .
"
.Linear Form 9 . ....
Display F o r m
.. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Human Computer Interaction
.
.
CGIF
9
--..
.
.
.
.
.
.
.
CGIDL
...............................
.
.
9
. . '
ComputerComputer Interaction
Fig. 1. Different notations represent the intension of conceptual graphs.
The outline of this paper is as follows: in Section 2 we give a short overview of CORBA. In Section 3 we discuss some drawbacks of using CGIF for distributed applications. In Section 4 we present our mapping of CGIF to CORBA IDL, which is further explained in Section 5 through an example. It should be noted that we describe work-in-progress. The following explanations emphasize the potential of using CORBA technology for CG-based applications. A complete mapping of CGIF to CORBA IDL is subject to further research.
2
Overview
of CORBA
Modern programming languages employ the object paradigm to structure computation within a single operating system process. The next logical step is to distribute a computation over multiple processes on a single machine or even on different machines. Because object orientation has proven to be an adequate means for developing and maintaining large scale applications, it seems reasonable to apply the object paradigm to distributed computation as well: objects are distributed over the machines within a networked environment and communicate with each other. As a fact of life, the computers within a networked environment differ in hardware architecture, operating system software, and the programming languages used to implement the objects. T h a t is what we call a heterogeneous distributed environment. To allow communication between objects in such an environment, one needs a rather complex piece of software called a middleware platform. The Common Object Request Broker Architecture (CORBA) is a specification of such a middleware platform. The CORBA standard is issued by the Object Management Group (OMG), an international organization with over 750 information software vendors, software developers, and users. The goal of the OMG is the establishment of industry guidelines and object management specifications to provide a common framework for application development. CORBA addresses the following issues:
121
O b j e c t o r i e n t a t i o n : Objects are the basic building blocks of CORBA applications. D i s t r i b u t i o n t r a n s p a r e n c y : A caller uses the same mechanisms to invoke an object whether it is located in the same address space, on the same machine, or on a remote machine. H a r d w a r e , OS, a n d l a n g u a g e i n d e p e n d e n c e : CORBA components can be implemented using different programming languages on different hardware architectures running different operating systems. V e n d o r i n d e p e n d e n c e : CORBA compliant implementations from different vendors interoperate and applications are portable between different vendors. One important aspect of CORBA is that it is a specification and not an implementation. CORBA just provides a framework allowing applications to interoperate in a distributed and heterogeneous environment. But it does not prescribe any specific technology how to implement the CORBA standard. The standard is freely available via the World Wide Web at h t t p : / / w w w , omg. o r g / . Currently there exist many implementations of CORBA focusing on different market segments.
Fig. 2. Basic building blocks of a CORBA based middlewaxe platform.
Figure 2 gives an overview of the components of a CORBA system (depicted in gray), as well as the embedding of an application in such a platform (white components). The Object Request Broker (ORB) is responsible for transferring operations from clients to servers. This requires the ORB to locate a server implementation (and possibly activate it), transmit the operation and its parameters, and finally return the results back to the client.
122
An Object Adapter (OA) offers various services to a server such as the management of object references, the activation of server implementations, and the instantiation of new server objects. Different OAs may be tailored for specific application domains and may offer different services to a server. The ORB is responsible for dispatching between different OAs. One mandatory OA is the so-called Basic Object Adapter (BOA). As its name implies, it offers only very basic services to a server. The interface between a client and a server is specified with an Interface Definition Language (IDL). According to the object paradigm, an IDL specification separates the interface of a server from its implementation. This way a client has access to a server's operational interface without being aware of the server's implementation details. An IDL-compiler generates a stub for the client and a skeleton for the server which are responsible for marshalling and unmarshalling the parameters of an operation. The Dynamic Invocation Interface (DII) and the Dynamic Skeleton Interface (DSI) allow the sending and receiving of operation invocations. They represent the marshalling and unmarshalling API offered to stubs and skeletons by the ORB. Different ORB implementations can interoperate through the Internet Inter-ORB Protocol (IIOP) which describes the on-the-wire representations of basic and constructed IDL data types as well as message formats needed for the protocol. With that respect it defines a transfer syntax, just like CGIF does. The design of IIOP was driven by the goal to keep it simple, scalable, and general.
3
Using
CGIF
in a
heterogeneous environment
In this section we explain how CGIF might be used in constructing distributed applications and the disadvantages this has. Figure 3 depicts a typical configuration. The application consists of a client and a server, communicating via a transport layer over the network. The messages being exchanged between the client and the server contain CGs as defined by CGIF. First note that this is not sufficient for a distributed application. CGIF only allows to code parameters for operations, but the kind of operations to be invoked at the server is out of scope of CGIF. The distinction between parameters and operations corresponds to the distinction between KIF and KQML (see 2). In that respect there is no equivalent to KQML in the CG-world. One of our premises is that the client and server can be written in different programming languages, running on different operating systems using different transport media. A programmer would most certainly define some data structures to represent a CG in his/her programming language. In order to transmit a CG, the internal data structure needs to be translated to CGIF. This is accomplished by a stub. On the server side the CG coded in CGIF needs to be translated back to an internal data structure again. This is done by a skeleton. The black nodes in Figure 3 show the important steps in the translation process. At step 1 the CG exists as a data structure in the programming language used to implement the client. The stub, which is also written in the same pro-
123
0 ..........
?
e" ...............................................................................
ii
..................
iN!iiiiiiiiiiiiiiTi!ii
Fig. 3. Marshalling code is contained in stubs and skeletons.
gramming language as the client, translates this data structure to CGIF (step 2). After transporting the CG over the network, it arrives at the server (step 3). The skeleton translates the CG back into a data representation in the programming language used for the implementation of the server. At step 4 the CG can finally be processed by the server. CGIF does not prescribe an internal data structure of a programming language. I.e., using CGIF for transmitting CGs, a programmer must first make such a definition based on his/her programming language followed by a manual coding of the stub and skeleton. This imposes a high overhead in the application creation process. The main benefit of using CORBA IDL is that stubs and skeletons are automatically generated by an IDL compiler and there is a well-defined mapping from IDL to different programming languages. Furthermore, the IDL specification does not only allow the specification of parameters but also for operations which makes it suitable for the specification of operational interfaces between application components. Although an IDL specification induces a transfer syntax through IIOP similar to CGIF, an IDL specification is better suited for the design of distributed applications. An IDL specification hides the transfer syntax and focuses on the user defined types, which are mapped to different programming languages by an IDL compiler. CGIF on the other hand exposes the complexity of the transfer syntax to an application programmer who is responsible for coding stubs and skeletons.
4
CG
interface
through
IDL
In this section we show how to translate some of the basic definitions of the proposed CG standard to CORBA IDL. The explanations presented here should
124
be seen as a proof of concept. A more thorough approach including all definitions of the CG standard is still a research topic. The mapping we explain in the following covers definitions 3.1 (Conceptual Graphs), 3.2 (Concept) and 3.3 (Conceptual Relation) of the proposed CG standard (see 6). The basic design principle of the operational interface is to exploit some common features of the object paradigm and the CG definitions. A conceptual graph is a bipartite graph consisting of concept and conceptual relation nodes. This definition resembles an object graph, where objects represent the nodes of a CG and object references arcs between the nodes. Therefore it seems feasible to model the nodes of a CG through CORBA objects and the links between the nodes through object references. This way of modelling a CG through CORBA IDL has several advantages. Since object references are used to connect relation with concept nodes, one CG can be distributed over several hosts. The objects, which denote the nodes of a CG are not required to remain in the same address space, since an object reference can span host boundaries in a heterogeneous environment. Furthermore, a CG does not necessarily need to be sent by value, but rather by reference. Only if the receiving side of an operation actually accesses a node, it will be transferred over the network. This scheme enables a lazy evaluation strategy for CG operations. It is common to place all IDL definitions related to a particular service in a separate namespace to avoid name conflicts with other applications. Therefore, we assume that the following IDL definitions are embraced by an IDL module: module CG { // Here come all definitions related to // the CG module
}; Using the inheritance mechanism of CORBA IDL we first define a common base interface for concepts and conceptual relations. This interface is called Node and defined through the following specification: typedef string Label; interface Node { attribute Label type;
}; The interface Node contains all the definitions which are common for concept and relation nodes. The common property shared by those two types of nodes is the type label. The type label is represented through an attribute of type Label. Note that we made Label a synonym for s t r i n g through a t y p e d e f declaration. Next, we define the interface for all concept nodes: interface Concept : Node { attribute Label referent;
}; typedef sequence ConceptSeq;
125
The interface Concept inherits all properties (i.e., attribute Label) from interface Node and adds a new property, namely an attribute for the referent. The following t y p e d e f defines an unbounded sequence of concepts. This is necessary for the definition of the relation node: interface Relation
: Node { attribute ConceptSeq links;
}; Just as the interface Concept, the interface R e l a t i o n inherits all properties from Node. The new property added here is a list of neighboring concept nodes, represented by the attribute l i n k s . Note that ConceptSeq is an ordered sequence. The length of this sequence corresponds with the arity of the relation. The first item in a sequence refers to the concept node pointing towards the relation. The final definition gives the IDL abstraction of a CG: typedef sequence Graph;
A CG is represented by a list of interface Node. For brevity reasons the IDL type is called Graph. The order of appearance of the individual nodes is of no importance. This data structure suffices to transmit a simple CG over the network. In the following section we provide a little example how this definition might be used in a real application context. 5
Example
Given the basic specifications from the previous section, how does a programmer develop an application using CG? Using the CORBA framework the programmer would have to design the interface to the application to be written based on the definition from the previous section. E.g., consider a simple application which would offer database functionality for CGs, such as save, restore, etc. The resulting IDL specification would look some like the following: #include "cg. idl" interface DB {
typedef string Key; exception Duplicate {}; exception NotFound {}; exception IllegalKey {}; Key save( in CG::Graph c ) raises( Duplicate ); CG::Graph retrieve( in Key k ) raises( NotFound, IllegalKey ); void delete( in CG::Graph c ) raises( NotFound, IllegalKey );
};
126 This example assumes t h a t the basic definitions for CGs from Section 4 are stored in a file called "cg. i d l " . The definitions are made known through the # i n c l u d e directive. Access to the database is defined through interface DB. The database stores CGs and assigns a unique key to each CG. The database allows to save, retrieve and delete CGs. If a CG is saved, the database returns a unique key for this CG. The operations r e t r i e v e and d e l e t e need a key as an input parameter. Errors are reported through exceptions. The IDL definition of interface DB is all t h a t a client program will need in order to access an implementation. As pointed out before, the language and precise technology that was used to implement the database are irrelevant to the client.
6
Conclusion
The construction of C G - b a s e d applications can benefit from the usage of middleware platforms. In this paper we have shown how to translate the basic definitions for a conceptual graph to C O R B A IDL. A conceptual graph is represented through a set of C O R B A objects which do not need to reside in the same address space. Besides language independence, this has the advantage of supporting lazy evaluation strategies for CG operations. Once a proper mapping from C G I F to C O R B A IDL has been accomplished, the existing CG applications should be re-structured using C O R B A (see 1). By doing so, those applications could more easily exploit specific services they offer among each other and to other applications. There are several C O R B A implementations available including free ones (see 3). Applications, which use C O R B A as a middleware platform, can be easily accessed in a standardized fashion from any C O R B A implementation, such as the one included in the Netscape Communicator.
References 1. CGTOOLS. Conceptual Graphs Tools homepage, http://cs.une.edu.au/~cgtools/, School of Mathematical and Computer Science, University of New England, Australia, 1997. 2. M.R. Genesereth and S.P. Ketchpel. Software Agents. Communications of the Association or Computing Machinery, 37(7):48-53, July 1994. 3. MICO. A free CORBA 2.0 compliant implementation, http://www.vsb.informatik.uni-frankfurt, de/~mico, Computer Science Department, University of Frankfurt, 1997. 4. Object Management Group (OMG), The Common Object Request Broker: Architecure and Specification, Revision 2.2, February 1998. 5. J.F. Sowa. Conceptual Structures, information processing mind and machine. Addison-Wesley Publishing Company, 1984. 6. J.F. Sowa. Standardization of Conceptual Graphs. ANSI DraB, 1998.
TOSCANA-Systems
Based on Thesauri
B e r n d G r o h 1, S e l m a S t r a h r i n g e r 2, a n d R u d o l f W i l l e 2 1 School of Information Technology Griffith University PMB 50 Gold Coast Mail Centre QLD 9726 Australia e-mail: [email protected] Fachbereich Mathematik Technische Universits Darmstadt, Schloi3gartenstr. 7 64289 Darmstadt, Germany e-marl: {strahringer~ wille}@mathematik.tu-darmstadt.de
A b s t r a c t . T O S C A N A is a computer program which allows an online interaction with d a t a bases to analyse and explore d a t a conceptually. Such interaction uses conceptual data systems which are based on formal contexts consisting of relationships between objects and attributes. Those formal contexts often have attributes taken from a thesaurus, which may be understood as ordered set and be completed to a join-semilattice (if necessary). The join of thesaurus terms indicates the degree of resemblance of the terms and should therefore be included in the formal contexts containing those terms. Consequently, the formal contexts of a conceptual d a t a system based on a thesaurus should have join-closed attribute sets. A problem arises for the TOSCANA-system implementing such conceptual d a t a system because the attributes in a nested line diagram produced by T O S C A N A might not be join-closed, although its components have join-closed attribute sets. In this paper we offer a solution to this problem by developing a method for extending line diagrams to those whose attributes are join-closed. This method allows to implement TOSCANA-systems based on thesauri which respect the join-structure of the thesauri.
Keywords:
1
C o n c e p t u a l K n o w l e d g e Processing, F o r m a l C o n c e p t A n a l y s i s , D r a w i n g Line D i a g r a m s , T h e s a u r i
TOSCANA
T O S C A N A is a c o m p u t e r p r o g r a m which allows an online i n t e r a c t i o n w i t h d a t a bases to a n M y s e a n d e x p l o r e d a t a c o n c e p t u a l l y . T O S C A N A realizes conceptual data systems 17,20 which are m a t h e m a t i c a l l y specified s y s t e m s c o n s i s t i n g of a d a t a c o n t e x t a n d a collection of f o r m a l contexts, called conceptual scales, tog e t h e r w i t h line d i a g r a m s of their concept lattices. T h e r e is a c o n n e c t i o n b e t w e e n f o r m a l o b j e c t s of t h e c o n c e p t u a l scales a n d t h e o b j e c t s in t h e d a t a c o n t e x t t h a t
128
can be activated to conceptually represent the data objects within the line diagrams of the conceptual scales. This allows thematic views into the database (underlying the data context) via graphically presented concept lattices showing networks of conceptual relationships. The views may even be combined, interchanged, and refined so that a flexible and informative navigation through a conceptual landscape derived from the database can be performed (cf. 21). For an elementary understanding of conceptual data systems, it is best to assume that the data are given by a larger formal context K :-- (G, M, I). A conceptual scale derived from data context K can then be specified as a subcontext (G, Mj, I M (G • Mj)) with Mj _C M. A basic proposition of Formal Concept Analysis states that the concept lattice of K can be represented as a V-subsemilattice within the direct product of the concept lattices of subcontexts (G, Mj, IN (G x Mj)) (j E J) if M = Uj~J Mj 3; p. 77. This explains how every concept lattice can be represented by a nested line diagram of smaller concept lattices. Figure 1 shows a nested line diagram produced with the assistance of TOSCANA from a database about environmental literature. One concept lattice is represented by the big circles with their connecting line segments, while the line diagram of the second is inserted into each big circle. In such a way the direct product of any two lattices can be diagramed, where a non-nested line diagram of the direct product may be obtained from a nested diagram by replacing each line segment between two big circles by line segments between corresponding elements of the two line diagrams inside the two big circles. In Fig. 13 , the black little circles represent the combined concept lattice which has the two smaller concept lattices as V-homomorphic images. Since larger data contexts usually give rise to an extensive object labelling, TOSCANA attaches first to a node the number of objects which generate the concept represented by that node; after clicking on that number, TOSCANA presents all names of the counted objects. TOSCANA-systems have been successfully elaborated for many purposes in different research areas, but also on the commercial level. For example, TOSCANA-systems have been established: for analyzing data of children with diabetes 17, for investigating international cooperations 11, for exploring laws and regulations concerning building constructions 13, for retrieving books in a library 12, 15, for assisting engineers in designing pipings 19, for inquiring flight movements at Frankfurt Airport 10, for inspecting the burner of an incinerating plant 9, for developing qualitative theories in music esthetics 14, for studying semantics of speech-act verbs 8, for examining the medical nomenclature system SNOMED 16 etc. In applying the TOSCANA program, the desire often arises to extend the program by additional functionalities so that TOSCANA is still in a process of further development (cf. 18).
3 Translation of the labels in Fig. 1: Fluss/river, Oberflaechengewaesser/surface waters, Talsperre/impounded dam, Stausee/impounded lake, Staugewaesser/back water, Stauanlage/reservoir facilities, Staudamm/storage dam, Stausufe/barrage weir with locks, Seen/lakes, Teich/pond
129
Staugewaesser I_~/~23~V---a-4~ /~"-.. J Staudamm I
Oberflaechen
Fig. 1. Nested line diagram of a data context derived from a database about environmental literature
130
2
Thesaurus
Terms
as Attributes
D a t a contexts, which are supposed to be analysed and explored conceptually, often have attributes that are terms of a thesaurus. Those terms are already hierarchically structured by relations between the terms. We discuss in this section how the hierarchical structure of the thesaurus terms should be respected in a T O S C A N A - s y s t e m with additional functionality (compare other approaches in 2, 5, 6). Let us first describe a formalization of thesauri t h a t meets our purpose. Mathematically, we understand a thesaurus as a set T of terms together with a order relation <, i.e. a reflexive, transitive, and anti-symmetric binary relation on T. Note t h a t we do not assume that a thesaurus has a tree structure, i.e., we allow that, for an element x E T, there are elements y and z in T with x < y, x _< z and y /~ z, z ~ y. We assume that a thesaurus has a unique m a x i m a l element. If this is not made explicit, we add a new top element to the structure. For tl, t2 E T, the element tl V t2 is defined as the unique minimal upper bound of tl and t2. If there is no unique minimal upper bound oft1 and t2, we add a new element to T which is understood as the conjunction of the minimal upper bounds of tl and t2. We interpret tl Y t2 as the smallest c o m m o n generalization of the terms tl and t2. The extension of (T, ~) obtained by completing the Voperation leads m a t h e m a t i c a l l y to a Y-semilattice. This allows us to assume for the sequel that the considered thesaurus is formalized by a finite V-semilattice. A formal context ( G , M , I ) where M := (M, <) is a finite V-semilattice is called a context with compatible attribute-semilattice if m l < m2 and gIml imply gIm2 for all m l , m2 E M and g E G. Interesting examples of contexts with compatible attribute-semilattice can be derived from document databases where the documents have been indexed by thesaurus terms to describe their content. For a d a t a context K := (G, M , I) with compatible attribute semilattice M := (M, <), the question arises how a conceptual d a t a system based on K m a y respect the semilattice structure on the attributes of K. This question especially suggests to discuss desirable properties of conceptual scales derived from E. As mentioned above, the join ml V m2 of the attributes m l and m2 is interpreted as the smallest c o m m o n generalization of m l and rn2 and indicates therefore the degree of resemblance of the attributes rnl and rn2. Of course, for a conceptual scale Kj := (G, Mj, I n (G • Mj)) with Mj C_ M, it is desirable to code this indication of resemblance into the scale; hence, the attribute set Mj of the scale Kj should be join-closed, i.e. m l V m2 E Mj for all m~, m2 E Mj. We say t h a t a subcontext (conceptual scale) Kj is join-closed if its attribute set Mj is joinclosed. Now, we conclude our consideration with the claim that the conceptual scales derived from a d a t a context with compatible attribute-semilattice should be join-closed. Since TOSCANA-systems work with nested line diagrams, we are confronted with the question of how the resemblance of attributes is visible in a nested line diagram which represents conceptual scales derived from a d a t a context with compatible attribute-semilattice. An investigation of this question uncovers the problem that, for join-closed conceptual scales Kj := (G, Mj, I n (G x Mj))
131
(j = 1, 2) of the data context IN := (G, M___,I), the join ml V m2 for ml E M1 and rns E Ms may not have a correspondig concept node to be attached to within the nested line diagram which represents the union of the conceptual scales IIQ and IN2 ; in particular, this would yield ml V m2 ~ M1 U Ms. Thus, we have to extend the union M1 U M2 by those problematic attributes which yields the join-closed attribute set Mls := M1 U Ms U (M1 V Ms) with M1 V M2 := {ml V m2 I ml E M1 and m2 E M2}. This attribute set determines the join-closed subcontext IK~ V lK2 := (G, M12, I n (G x Mls)) which should be the contextual basis for the desired extension of the nested line diagram. The problem is how to derive graphically that extension from the already drawn diagram. For solving this problem, we propose to insert into the nested line diagram node after node for the problematic attributes and to complete the diagram after each positioning of a new node to obtain a drawing for the concept lattice of the respective extended subcontext. This procedure, which finally reaches a line diagram for the concept lattice of IK1 V IK2, reduces the problem to the case of extending a subeontext by one attribute. How this elementary case can be treated will be explained in the next section. 3
Extending
Lattice
Diagrams
We consider a formal context IN := (G, M, I) and a subcontext IN0 := (G, M0, I n (G x M0) with M0 c M; furthemore, let m E M \ M0 such that rn ~ is not an extent of No, and let I ~ := (G, M0 U {m}, I O (G x M0 O {m}). In this section we describe how to extend a line diagram of the concept lattice of No to a line diagram of the concept lattice of l t ~ . Recall that I t ( I ~ ) denotes the set of extents of the context 1 ~ and that ( i t ( I ~ ) , C_) ~ ~ _ ( I ~ ) . This means that it suffices to consider only the closure system of extents together with the settheoretic inclusion for our drawing problem. We start by defining the ordered set P := (lt(N0)U{mt}, C_). In P the element m r has exactly one upper cover which we denote by C. Obviously, completing P__by forming all intersections yields the closure system (it(IK~n ), C_). To identify the new intersections, we consider the following partition of P into four classes (see Fig. 2).
(1) IV) := {x e P_lC c_ x} (2) (.r := {x e P_lX c_ . r (3) (C \ ((m' U {C}) with (C := {X E P_IX c_ c }
(4) _e\ (c) u (c) We say that S E It(I~0) is a m i n i m a l n-generator if m / n S ~ P and if R C S with rn I N R = m t O S (R E It(N0)) implies R = S. Since minimal n-generators have to be incomparable to m I, they cannot be in the class (1) or (2). For an element S of class (4), the equality (S n C) n m I = S n m r shows that S cannot be a minimal N-generator. Thus, the minimal n-generators form a subset gm of the class (3). Obviously, we have ( i t ( I ~ ) = P U {m z n S S E g,~} and each minimal n-generator S has S n rn r as lower neighbour in ( i t ( ~ ) .
132
P
Fig. 2. Partition of the ordered set P into four classes
Now, we are able to describe how to derive a line diagram for ( H ( I ~ ) from a line diagram of (~/(lK0). First we insert a node for m I and join this node with the node of C by a line segment. Then we move the subdiagram representing (C0 := {X E ll(K0) X C C} along that line segment until the node of C coincides with the node of m x, but keep a copy of the nodes representing (C0 \ ((m I U {C}), i.e. class (3), still at its original place so that the nodes representing elements in (C0 \ ((m I t3 {C}) double. Each pair of doubled nodes is joined by a new line segment. The resulting diagram has eventually too many nodes because only the intersection of m I with the minimal N-generators yields new elements. Therefore we replace all moved nodes of the elements in (C0 \ ((m z tO {C}) that are not in g,~ by a dummy; but we keep all line segments in place. In this way we obtain a line diagram for (ll(lK~n) where the nodes represent the lattice elements and the dummies guarantee a satisfying arrangement of the line segments. Let us now illustrate our drawing procedure by an example. The documents in the database ULIDAT of the Umweltbundesamt (Federal Environmental Agency of Germany) are indexed by terms of the Umwelt-Thesaurus (Environmental Thesaurus) to describe their content for the purpose of document retrieval (cf. 1). Hence we may understand the documents as objects and the thesaurus terms as attributes of a formal context IK := (G, M, I) with V-compatible attributesemilattice. We have chosen the scales IK1 and IK2 induced by the sets of terms M1 and M2, respectively, visualized in Fig. 3 together with the order relation constituted by the thesaurus. The V-closure M12 : = M1 t3 M2 tO (M1 V M2) consists of the thesaurus terms shown in Fig. 4 4 . We can see that the term "Stehendes Gewaesser" which is a join of "Seen" and "Staugewaesser" and the 4 Translation of the new label in Fig. 4: Stehendes Gewaesser/standing waters
133
Oberflaechengewa~,~
y
Fluss
Teich
(M,, ___) S t a u g e w ~
Stausee
U Staudamm
Staustufe Talsperre
(M2, <) Fig. 3. Two ordered sets of thesaurus terms
term "T" (for the top element of the thesaurus) which is a join of "Stauanlage" and "Oberflaechengewaesser" are the new attributes. Since all objects have the attribute "T", it does not carry any information and can therefore be omitted in the line diagram. The line diagram of the concept lattice oflK1 VIK2 in Fig. 5 will be extended to a line diagram of ~__(K1 V K2). For reasons of comprehension we use a non-nested line diagram first and will later extend a nested line diagram. The line diagram of ~__(K1 VK2) in Fig. 6 has been obtained from the line diagram in Fig. 5 by doubling six lattice elements which yields the new elements in Fig. 6 represented by the black circles with a white dot. In Fig. 7, a line diagram of ~_~_(K1 V K2) is shown that has been derived from the nested line diagram in Fig. 1. In the line diagram in Fig. 1, each of the three top elements in the two large circles labelled with "Oberflaechengewasser" and "Fluss" has been doubled. The resulting lattice elements are encircled by an ellipse in Fig. 7. 4
Discussion
The study of TOSCANA-systems based on thesauri has been motivated by different investigations of thesauri and classification systems from which the desire arose to develop methods for representing the resemblance of classification terms within line diagrams of concept lattices. The understanding of the join of two classification terms as the smallest generalization of those terms suggests an algebraic description method for the degree of resemblance of thesaurus terms. From this suggestion we derived the claim that a TOSCANA-system based on a
134
T
Oberflaechengewaesser Stehendes Gewaesser Fluss Seen
Stauanlage Stauge\waesser
Teich
Stausee
Staudamm
Staustufe Talsperre
(M1 u M2 u (M1 v M2), <) Fig. 4. The join-closure of the thesaurus terms shown in Fig. 3
thesaurus should have join-closed conceptual scales. Since T O S C A N A represents combined conceptual scales by nested line diagrams, it is a consequence of our claim that the attributes in those diagrams should be join-closed too. This leads to the problem how to extend a line diagram of a concept lattice with attributes taken from a V-semilattice to a line diagram with join-closed attributes. Our solution of this problem offers an incremental procedure of inserting into line diagrams node by node new A-irreducible attribute concepts. Each new attribute forces an extension of the actual concept lattice which doubles a convex subset of the lattice (cf. 4). This extension need not to be the new concept lattice generated by the old one and the new attribute, but it contains the new lattice. Thus the line diagram of the extension yields a graphical representation of the new concept lattice if we replace the elements of the extension which are not in that lattice by dummies. Of course, one might even erase those elements, but then one has to erase line segments too and has to insert eventually new line s e g m e n t s which could cause serious problems. An advantage of keeping the superfluous nodes in only changing them to dummies lies in the possibility to
135
Fig. 5. A non-nested line diagram of the concept lattice visualized in Fig. 1
automate the drawing procedure. Thus, with our method, we especially offer an incremental procedure for drawing concept lattices automatically (an incremental algorithm for determining concept lattices has already been published in 7).
References 1. W. Batschi: Environmental thesaurus and classification of the Umweltbundesamt (Federal Environmental Agency), Berlin. In: S. Stancikova and I. Dahlberg (eds.): Environmental Knowledge Organization and Information Management. Indeks, Frankfurt/Main 1994. 2. C. Carpineto and G. Romano: A Lattice Conceptual Clustering System and Its Application to Browsing Retrieval. Machine Learning 24 (1996), 95-122.
136
Gewaesser J
Fig. 6. The line diagram in Fig. 5 extended by six new lattice elements
3. B. Ganger and R. Wille, Formale Begriffsanalyse: Mathematische Grundlagen. Springer, Berlin-Heidelberg 1996. (English translation to appear) 4. W. Geyer: The generalized doubling construction and formal concept analysis. Algebra Uuiversalis 32 (1994), 341-367. 5. R. Godin and H. Mill: Building and Maintaining Analysis-Level Class Hierarchies Using Galois Lattices. In Proceedings of the ACM Conference on Object-Oriented Programming Systems, Languages, and Applications (OOPSLA'93), A. Paepcke (Ed.), Washington, DC, 1993, ACM Press, 394-410. 6. R. Godin, G.W. Mineau, and R. Missaoui: Incremental structuring of knowledge bases. In: Proceedings of the International Knowledge Retrieval, Use, and Storage for Efficiency Symposium (KRUSE'95), Santa Cruz, Lecture Notes in Artificial Intelligence, Springer, 1995, 179-198.
137
Staugewaesser 1.. ~
~
IStaudarnmI
Stehendes Gewaesser Oberflaechen
Fig. 7. The nested line diagram in Fig. 1 extended by six new lattice elements
138
7. R. Godin, R. Missaoui, aml It. Alaoui: Incremental Concept Formation Algorithms Based on Galois (Concept) Lattices. Computational Intelligence, 11(2) (1995), 246-267. 8. A. Grosskopf and G. Harras: A TOSCANA-system for speech-act verbs. FB4Preprint, TU Darmstadt 1998. 9. E. Kalix, Entwicklung von Regelungskonzepten ffir thermische Abfallbehandlungsanlagen. Diplomarbeit, TU Darmstadt, 1997. 10. U. Kanfmann, Begriffiiche Analyse fiber Flugereignisse - Implementierung eines Erkundungs- und Analysesystems mit TOSCANA. Diplomarbeit, TH Darmstadt 1996. 11. B. Kohler-Koch and F. Vogt, Normen und regelgeleitete internationale Kooperationen. FB4-Preprint 1632, TU Darmstadt 1994. 12. W. Kollewe, C. Sander, R. Schmiede, and R. Wille, TOSCANA als Instrument der der bibliothekarischen Sacherschlieflung. In: H. Havekost and H.J. W/itjen (eds.), Aufbau und Erschlleflung begrifflicher Datenbanken. (BIS)-Verlag, Oldenburg, 1995, 95-114. 13. W. Kollewe, M. Skorsky, F. Vogt, and R. Wille, TOSCANA ein Werkzeug zur begriffiichen Analyse und Erkundung yon Daten. In: R. Wille and M. Zickwolff (eds.), Begriffiiche Wissensverarbeitung - Grundfragen und Anfgaben. B.I.Wissenschaftsverlag, Mannheim, 1994, 267-288. 14. K. Mackensen and U. WiUe: Qualitative text analysis supported by conceptual data systems. Preprint, ZUMA, Mannheim 1997. 15. T. Rock and R. Wille: Ein TOSCANA-System zur Literatursuche. In: G. Stumme and R. Wille (eds.): Begriffiiche Wissensverarbeitung: Methoden und Anwendungen. Springer, Berlin-Heidelberg (to appear) 16. M. Roth-Hintz, M. Mieth, T. Wetter, S. Strahringer, B. Groh, R. Wille, Investigating SNOMED by Formal Concept Analysis. Submitted to: Artificial Intelligence in Medicine. 17. P. Scheich, M. Sorsky, F. Vogt, C. Wachter, R. Wille: Conceptual data systems. In: O. Opitz, B. Lausen, R. Klar (eds.): Information and classification. Springer, Berlin-Heidelberg 1993, 72-84. 18. G. Stumme and K. E. Wolff: Computing in conceptual data systems with relational structures. In: G. Mineau and A. Fall (eds.): Proceedings of the Second International Symposium on Knowledge Retrieval, Use, Storage for Efficiency. Simon Fraser University, Vancouver 1997, 206-219. 19. N. Vogel: Ein begriffiiches Erkundungssystem ffir Rohrleitungen. Diplomarbeit, TU Darmstadt 1995. 20. F. Vogt and R. Wille: TOSCANA - a graphical tool for analyzing and exploring data. In: R. Tamassia, I.G. Tollis (eds.): Graph Drawing '94. Lecture Notes in Computer Science 894. Springer Berlin-Heidelberg-New York 1995, 226-233. 21. R. Wille: Conceptual landscapes of knowledge: a pragmatic paradigm for knowledge processing. In: G. Mineau and A. Fall (eds.): Proceedings of the Second International Symposium on Knowledge Retrieval, Use, Storage for Efficiency. Simon Fraser University, Vancouver 1997, 2-13.
MULTIKAT, a Tool for Comparing Knowledge of Multiple Experts Rose Dieng 1, Stefan Hug 2 INRIA, ACACIA Project, 2004 Route des Lucioles, BP 93, 06902 Sophia-Antipolis Cedex, France
[email protected] 2 PTV Planungsbiiro Transport und Verkehr GmbH, StumpfstraSe 1, 76131 Karlsruhe, Germany Stefan.Hug @ptv.ptv.de Abstract. This paper presents MULTIKAT, a tool aimed at conflict management during knowledge modeling from multiple experts: this tools allows to compare knowledge of several experts both automatically and cooperatively, when such knowledge is represented through Sowa's conceptual graph formalism. MULTIKAT implements an algorithm of comparison and integration of several supports, and an algorithm of comparison and integration of multiple conceptual graphs corresponding to different viewpoints, the integration being guided by different integration strategies. This paper details this last algorithm.
1
Introduction
The development of a corporate memory or of a knowledge-based system in a company may involve knowledge acquisition from several experts, that can stem from the same domain or from different ones. Therefore, the knowledge engineer (KE) must detect and solve several kinds of conflicts: (a) differences of terminology, (b) incompatibility between terminologies, (c) differences between compatible reasonings (i.e. the experts use different problem solving methods but obtain non contradictory results), (d) incompatibility of reasonings (i.e. the different problem solving methods used by the experts lead to contradictory results). Few knowledge acquisition methods or tools take into account expertise conflict management: study of terminology conflicts and comparison of repertory grids in 7 17; management of several viewpoints in 6; conflict detection in the framework of KADS-I methodology in 2; cooperative building of a common ontology from several experts 8 19. After the KE elicited rough data from the different experts, she must analyze the elicited data in order to build: a) a common model corresponding to the kernel of knowledge common to all experts and perhaps models common only to sub-groups of experts, b) specific models corresponding to knowledge specific to an expert and not shared by other experts. Two approaches are possible: (1) either the KE tries to build such models (the common one and the specific ones) directly from the rough data, or (2) she builds separately each model of expertise corresponding to each expert (independently of the others) and then tries to compare the obtained models of expertise in order to find their common parts and their specific parts. In this second case, the common and specific models are obtained not directly from the rough data but from the separate expertise models.
140
C~ncept type lattice
R el t ai on ~ type mttice Support
Set of marke~s
Viewpoint 1 le~wpolnt 2 Base of conceptual graphs Fig. 1. Expertise model of an agent.
In 2, we had proposed techniques for comparing knowledge graphs representing knowledge of multiple experts. In 3 4, we adapted such techniques to Sowa's conceptual graph (CG) formalism 18. As shown in Fig. 1, to each expert we associate an artificial agent having a support (made of a concept type lattice, a relation type lattice, and a set of markers satisfying a conformity relation w.r.t, the concept type lattice) and a base of canonical conceptual graphs, built on this support and partitioned in several viewpoints. The purpose of this paper is to detail the tool MULTIKAT 12 implementing such techniques. After a brief summary of the model of CG formalism, we will first present our algorithm of comparison of CGs implemented in MULTIKAT: this algorithm relies on the local and global relations established between the graphs to be compared. Then we will present the integration strategies offered by MULTIKAT for guiding the construction of the integrated graph. Throughout the paper, we will illustrate the tool through examples in road accident analysis.
2
Conceptual Graph Model
We rely on the model of simple CGs, as defined in 18 = (~c, c~, B, ~
1 20. A support S is a tuple
conf) where : (c~c, <, T, -1_)is a lattice of concept types, c~ is a partially
ordered set of relation types (we will suppose that (c~, <, TTr, _LTr) has also a structure of lattice), B i s a set of "star graphs" in bijection with ~ , and indicating the signature of each relation type, M is a set of individual markers (M u {0, *} has a structure of lattice), conf is a conformity relation, that relates type labels to individual markers. A CG defined with respect to a support S is a connected, bipartite, labelled graph,
(C, ~P~~_~ label) with labeled vertices (the labelling respecting some constraints): C is the set of concept nodes (or C-vertices), R is the set of relation nodes (or R-vertices), E i s the set of edges, label is a function of C u ~PLu E t h a t associates to a C-vertex or R-vertex or an edge its label. Moreover, we will exploit the following characteristics: - We define the function adj : N * ~PL--->C: rel being a R-vertex of arity n and i being an integer ~ N, adj (i, rel) is the ith C-vertex adjacent to the R-vertex rel if i _
141
-
To a given CG, we associate A the set of its "elementary links" denoted rel (C 1, .... Cn), with rel ~ ~P~ arity(rel) = n, and ~/i ~ 1..n,
C i = adj (i, rel) ~ C. Therefore,
we will rather consider a CG as a tuple (C, P~ .,~ ~ label) and we will rather use the simplified notation G = (C, P~ A ) . - We make some simplifying hypotheses: ~/rel 1 and rel 2 ~ cj~ \ {TTr'/Tr} such that rel 1 < rel 2, we have: arity (rell) = arity (rel2) and type (adj (i, B (rell))) < type (adj (i, B (rel2))). - To each concept type or relation type, a set of synonyms of its main name can be associated. To each relation type, a list of incompatible relation types is associated. -
In this paper, we will use the following vocabulary: specialization~ or restriction of a concept type: on a concept-node type:ref, type is replaced by one of its subtypes, ~instantiation~ or restriction of a referent : on a concept-node type:*ref, the generic marker *ref is replaced by an individual marker conform with type, - ~relation specialization~ or restriction of a relation type : on a R-vertex denoted (type-rel), type-rel is replaced by one of its subtypes, - r162 generalization~: on a concept-node type:ref, type is replaced by a supertype, ~r on a concept-node type:ind-ref, the individual marker ind-ref is replaced by a generic marker conform with type, - r generalization~: on a R-vertex (type-rel), type-rel is replaced by a supertype of type-rel. - r
-
-
3
Algorithm of Integration of two Expertise Models
During the knowledge modelling phase, for each expert, the KE describes the concept and relation types handled by this expert through the support associated to the agent representing this expert. For each expert, the KE can also indicate which concept types correspond to the competence domain of this expert (e.g. all concept types subtypes of Infrastructure will be marked as specialties of the infrastructure engineer)1.The base of canonical CGs associated to an agent can be partitioned according to viewpoints. For example, in an application of traffic accident analysis, in addition to a task viewpoint, the experts handle CGs focusing on the drivers, the vehicles, the infrastructure, the interaction driver-vehicle, the interaction driver-infrastructure and the interaction vehicle-infrastructure.
The algorithm of comparison of the expertise models of two agents is based on the following steps:
1.This information will be exploited later if a strategy of the greatest competence is chosen for building the integrated graph.
142
1. Comparison of the two supports and building of the common support. It can be decomposed in: - Comparison and fusion of the concept type lattices of the two experts. Comparison and fusion of the relation type lattices used by the two experts. - Comparison and fusion of the two sets of markers. 2. Comparison of the two bases of CGs : for each viewpoint for which both agents have associated CGs, compare the two corresponding CGs, G 1 and G 2. This comparison of CGs of the same viewpoint can be decomposed as follows: - Preprocessing: In each CG of an agent, replace the expert's terms by the agreed terms adopted in the common lattices of concept types and of relation types. - Set up local relations between comparable "elementary links" of both graphs. Set up global relations between G 1 and G 2. 3. Construction of the base of integrated graphs, according to the chosen integration strategy: by exploiting the local and global relations previously established, build the integrated CGs for each viewpoint (unless G 1 and G 2 were recognized as incompatible). The comparison and fusion of supports is detailed elsewhere 12 5. In this paper we will focus only on the comparison of CGs, i.e. the steps 2 and 3 of the algorithm. Therefore, from now on, we will suppose the common support Scom = (%-com, Bcom, ~ o r n , c~ 4
~-com,
has been built.
Local Relations among C-vertices of Different Conceptual Graphs
During the elicitation sessions, the experts may express themselves with different levels of precision or of abstraction, they may exploit (or not) abstract knowledge, examples, particular cases... Therefore strategies for comparing two experts may be based on criteria of generalization vs specialization, conceptualization vs instantiation. In order to exploit such strategies, the KE must be able to detect global relations among the CGs describing the respective knowledge of the different experts. These global relations among CGs rely on the local relations among their elementary links. Such local relations rely themselves on the local relations among the concepts appearing in both graphs. The purpose of all such relations is to help to determine what is the most specialized (resp. generalized) or the most instantiated (resp. conceptualized) among two knowledge elements to be compared. This section will describe the local relations among concepts, section 5 the local relations among elementary links and section 6 the global relations among CGs. For lack of room, we don't detail all the relation definitions that can be found in 4 12. 4.1
D e f i n i t i o n s
Let G, = ( C 1, ~PL1,-~-1) and G 2 = ( C2, ~ , - ~ 2 ) the CGs of Expert 1 and of Expert 2, corresponding to the same viewpoint v and based on the common support Scorn.
143
Definitions o f Binary Relations on C 1 * C 2
Let C 1 be a C-vertex in G t and C 2 a C-vertex in G 2. i s - s a m e - c o n c e p t (C t , C 2 ) iff type (C 1 ) = type (C2) ^ referent (C 1 ) = referent (C2), - i s - g e n e r a l i z a t i o n (C l , C2) iff type (C2) < type (C 1 ) ^ referent (C 1 ) = referent (C2), i s - s p e c i a l i z a t i o n (C 1 , C 2 ) iff is-generalization (C 2, C1), -
- i s - c o n c e p t u a l i z a t i o n (C 1,C2) iff type(C1) = type(C2) ^ referent(C2) < referent(C1), i s - i n s t a n t i a t i o n (C 1, C2) iff is-conceptualization (C 2, C I ) , - is-generalization&conceptualization
(C 1, (22) iff type (C2) < type (CI) A referent
(C2) < referent (C1), is-specialization&instantiation
(C 1, C2) iff is-generalization&conceptualization
(C2, C1), -
is-more-generalized
(C 1, C2) iff is-generalization (C 1 ' C2) v is-generaliza-
tion&conceptualization (C 1, C2), i s - m o r e - s p e c i a l i z e d (C 1, C2) iff is-more-generalized (C 2 , C1), (C 1, C 2) iff type (C1) u type (C2) r T , -possible-common-specialization (C 1, C2) iff type (C1) n type (C2) ~ J_. - are-comparable-concepts
Definitions o f Functions: C 1 * C 2 --9 Cco m - m o s t - g e n e r a l i z e d (C 1, C2) =
C 1 iff is-same-concept (C 1, C2) v is-more-generalized (C 1, C2), C 2 iff is-more-generalized (C 2, CI), 0 otherwise. - common-generalization
(C 1, C2) =
typeco m : ref iff typeco m ~ T (with typeco m = type (C1) ~ type (C2) and ref = referent (C1) u referent (C2)) 0 otherwise. - m o s t - s p e c i a l i z e d (C1, C2) = C 1 iffis-same-concept (C 1, C2) v is-more-specialized (C 1, C2) , C 2 iff is-more-specialized (C 2, Ct), 0 otherwise. - c o m m o n - s p e c i a l i z a t i o n (C 1, C2) = typeco m " ref iff typecom ~ T ^ ref ~ 0 (with typeco m = type (CI) n type (C2) and ref = referent (C1) n referent (C2)), 0 otherwise. - m o s t - c o n c e p t u a l i z e d (C 1, C2) = C 1 iff is-same-concept (C 1 , C 2) v is-conceptualization (C 1 , C2), C 2 iff is-conceptualization (C 2 , C 1 ), 0 otherwise.
144
(C 1 , C2) = typeco m : ref iff type (C 1 ) = type (C2) (with typecom = type (C 1 ) = type (C2) and ref= referent (C 1 ) u referent (C2)) 0 otherwise. most-instantiated (C 1, C2) = C 1 if is-same-concept (C 1, C2) v is-instantiation (C 1, C2), C 2 if is-instantiation (C 2, C1), () otherwise. common-instantiation (C 1, C2) = typeco m : ref iff type (C 1 ) = type (C2) A ref ~ 0 (with typecom = type (C 1 ) = type (C2) and ref =referent (C1) n referent (C2)) 0 otherwise.
-
common-conceptualization
-
-
4.2
Examples
is-generalization (Driver's-Error: err-Paul, Wrong-Distance-Evaluation : err-Paul) is-conceptualization (Vehicle-Control-Loss : *x, Vehicle-Control-Loss : err-Jean) is-specialization&instantiation (Wrong-Manoeuvre : err-Fred, Driver's-Error: *y) is-more-specialized (Vehicle-Control-Loss : err-Jean, Driver's-Error: *y) are-comparable-concepts (Obstacle-Perception-Lack : *x, Indicator-not-put : *y) most-generalized (Driver's-Error : *y, Vehicle-Control-Loss : err-Jean) = Driver' s-Error : *y common-generalization (Vehicle-Control-Loss : err-Jean, Wrong-Manoeuvre : errFred) = Action-Error : * common-specialization (Driver's-Error: *y, Vehicle-Control-Loss : err-Jean) = Vehicle-Control-Loss : err-Jean
5
Local Relations among Elementary Links of Conceptual Graphs Definitions of Functions on A 1 * A 2
5.1
Let 11= rl(C 11-.- C l n ) and 12 = r 2 (C21 ... C2n) be elementary links of G 1 and G 2. MULTIKAT implements several possible relations between them: -
-
-
(12, 11) iff type(rl) = type (r2) A ~' i ~ 1, n, is-same-concept (adj (i, r2), adj (i, rl)) are-incompatible-links (12, ll) iff incompatible(type(r 1), type(r2)) ^ V i ~ 1, n, is-same-concept(adj (i, r2),adj (i, r 1)) are-comparable-links (12, ll) iff type(rl) u type(r2) ;e T A ~/i ~ 1, n, are-comparable-concepts (adj(i, r2), adj(i, rl) ) is-same-link
Specialization -
-
(l 2, ll) iff type(r2) < type (rl) A V i ~ 1, n, is-same-concept (adj (i, r2), adj (i, rl)) is-concept-total-specialization (12, 11) iff is-relation-specialization
145
type(r1) = type (r 2) A V i 9 1, n, is-specialization (adj (i, r2), adj (i, rl)) - is-concept-partial-specialization (12, 11) iff type(r1) = type (r 2) ^ V i 9 1, n, (is-speciaiization (adj (i, r2), adj (i, rl) ) v is-same-concept (adj (i, rl), adj (i, r2))) ^ 3 i 9 1, n, is-specialization (adj (i, r2), adj (i, rl) ) The relations is-relation&concept-total-specialization and is-relation&concept-partial-specialization can be defined by the same way. Generalization. Generalization relations are defined thanks to speciaiization relations. Instantiation - is-total-instantiation (12, I1)
iff
type(rl) = type (r2) ^ V i 9 1, n, type ( adj (i, rl)) = type (adj (i, r2) ) A referent (adj (i, r2) < referent (adj (i, rl))) We also define the relation is-partial-instantiation. Conceptualization.Conceptualization relations are defined w.r.t, instantiation ones. Specialization and Instantiation
(12, 11) iff type(r2) < type (rl) A V i 9 1, n, is-instantiation (adj (i, r2), adj (i, rl) ) Other relations such as is-relation-specialization&partial-instantiation, is-concepttotal-specialization&total-instantiation or is-concept-total-specialization&partial-instantiation can be defined by the same way (see 4 12). - is-relation-specialization&total-instantiation
Generalization and Coneeptualization.<~Generalization and Conceptualization>> relations are defined thanks to <<Specialization and Instantiation>> relations
Conceptualization
( Specialization (
-T7-4ame
Specia!ization &
)
Fig. 2. Clustering of possible relations between elementary links Competence Domain. If nb-specialties (Expert i, li) is, in the link 1i, the number of concept types marked by the KE as corresponding to Experti's domain of competence:
146
(1l, 12) = 11 iff nb-specialties (Expert I , 11) > nb-specialties (Expert2, 12) 12 iff nb-specialties (Expert 2, 12) > nb-specialties (Expert 1 , 11) 0 otherwise. Fig. 2 shows the clustering of possible relations among elementary links. - More-specialist
Examples. In the example shown Fig. 3, in G 1, let us denote: 111 -- Driver --> (Moving-with) --> Vehicle, 112 = Vehicle --> (Possible-Influence) --> Driver's-Error 113 = Age --> (Possible-Influence) --> Driver's-Error, 114 = Driver --> (Characteristic) --> Age In G 2, let us denote : 121 = Driver --> (Moving-with) ---> GTI, 122 = GTI --> (Incites-to) --> Excessive-Speed 123 = GTI --> (Incites-to) ---> Vehicle-Control-Loss, 124 = Driver --> (Characteristic) --> Age:young 125 = Age:young --> (Possible-Influence) --> Excessive-Speed Between these graphs, the following local relations among their elementary links exist: is-concept-partial-generalization (111,121), is-relation&concept-total-generalization (112, 122) is-relation&concept-total-generalization (112, 123), is-concept-partial-conceptualization (114, 124) is-concept-partial-generalization&partial-conceptualization (113,125) G1 Driver's-Error
Ve
,Onver
ic,o
Con olLossl
: xcessiveSp ,
- - " ~
A g e : young ~ , , ~ f ~ u e n ~ e . )
Fig. 3. Conceptual graphs of two experts, on the viewpoint interaction-vehicle-driver 5.2
Definitions of Functions: "~-1 * "~2 --> "~ corn
- most-specialized(ll,
I
12) = 11 iff 3 a specialization relation between 11 and 12
147
-
12 iff 3 a specialization relation between 12 and 11 0 otherwise. c o m m o n - s p e c i a l i z a t i o n (11, 12) = most-specialized(11, 12) iff most-specialized(11, 12) ~ 0 r (c 1 ..... Cn) iff type (r) ~ T A V i ~ 1, n, c i ~ 0 (with r = r 2 n r I and V i ~ I, n, c i = common-specialization (adj(i, r2), adj(i, rl)) ) 0 otherwise. most-generalized
-
(11, 12) =
12 iff 3 a specialization relation between 11 and 12 11 iff 3 a specialization relation between 12 and 11,
0 otherwise. (11, 12) = most-generalized (11, 12) iff most-generalized (11, 12) ~ 0 r (c 1 ..... Cn) iff type (r) ~ Ttr ^ V i ~ 1, n, c i ~ 0 (with r = r I u r 2 and V i ~ I, n, c i = common-generalization (adj(i, r2), adj(i, rl) ) ) 0 otherwise. m o s t - i n s t a n t i a t e d (11, 12) = 1 1 iff 3 an instantiation relation between 11 and 12
- common-generalization
-
-
common-instantiation
- most-conceptualized
-
12 iff 3 an instantiation relation between 12 and 11 0 otherwise. (11, 12) = most-instantiated (11, 12). (11, 12) = 1 1 iff 3 an instantiation relation between 12 and 11
12 iff 3 an instantiation relation between 11 and 12 0 otherwise. common-conceptualization (11, 12) = most-conceptualized (11, 12) iff most-conceptualized (11, 12) ~e 0 r (c 1 ..... Cn) i f f r l = r2 ~e Ttr ^ V i ~ 1, n, c i ~e 0 (with r=rl= r 2 and V i ~ I, hi, ci=common-conceptualization (adj(i, r2), adj(i, rl)) ) 0 otherwise.
With the example of Fig. 3, common-specialization (111,121) = 121, common-instantiation (113,125) = 125, common-generalization (122, 123) = GTI
6 6.1
common-generalization (112, 122) = 112 common-conceptualization (114, 124) = 114 ~ (incites-to) ~ Action-error.
Global Relations among Conceptual Graphs Dermitions
Let G 1 = ( C 1, R1, "~1) and G 2 = ( C 2, ~ , "~2) tWO CGs of Expert 1 and of Expert 2, corresponding to the same viewpoint v and based on the c o m m o n support Scom. w e adapt as follows the definition of graph morphism proposed by 1. W - m o r p h i s m . A 3-ple of functions:
(hc: C 1 ~ C 2, h r ~kt --~ ~k~2, ha: -~1 ~ "~2) is
148
iff k/11 = r l ( C l l ' ...Cln )E "~1:
calledatF-m~176176176
ha(It) = h r (rl) (h e (Cli) .... h c (Cln) A type (h r (rl)) < type (rl) ^ V i ~ 1..n,
type (h e (Cli)) < type (Cli) A referent (h e (Cli)) < referent type (Cli).
We define several binary relations on G 1 * G 2. S a m e g r a p h , S u b g r a p h , S u p e r g r a p h , Incompatibility - IsSameGraph (G1, G 2 ) iff 3 a bijective ~ - m o r p h i s m WGI_* G2 = (he, hr, h a ) such
that V 11 ~ A 1, is-same-link (11, ha(ll) ). - IsSubgraph (G 2 , G 1 ) iff 3 a W-morphism tlflG2___>G1 -- (he, hr, ha) such that is-same-
link (ha(12), 12 ). - IsSupergraph (G 2 , G 1 ) iff IsSubgraph (G1, G2). - IncompatibleGraphs (G 1, G 2 ) iff 3 11 ~ A 1, 3 12 ~ A 2 such that are-incompatible-
links (11,12 ). Specialization 1. We define the relations IsConceptTotalSpecialization, IsConceptPartialSpecialization, IsRelationTotalSpecialization, IsRelationPartialSpecialization, IsRelation&ConceptPartialSpecializationls, Relation&ConceptTotalSpecialization. - IsRelation&ConceptTotalSpecialization (G 2 ,G 1 ) iff 3 a W-morphism tIJG2___> G1 =
(h c, h r , ha) such that ~' 12 ~ A 2,11 = h a (12) ~ A 1 satisfies: is-relation&concept-totalspecialization (12, 11). Generalization.The generalization relations are defined w.r.t, the specialization ones. Instantiation. We define the relations IsTotallnstantiation, IsPartiallnstantiation,IsRelationSpecialization&Totallnstantiation and lsRelationSpecialization&Partiallnstantiation. For example: - IsRelationSpecialization&Totallnstantiation
(G 2 , G1) iff 3 tIJG2_._> G1 such that
V 12 ~ A 2 : is-relation-specialization&total-instantiation (12, h a (12)). Conceptualization. The conceptualization relations are defined w.r.t, the instantiation relations. For lack of room, we don't detail the relations <<Specialization a n d Instantiation>> or <~Generalization a n d Conceptualization>> (see 4 12 for more details). According to the clustering of local relations among elementary links, the global relations between graphs are clustered as shown in Fig. 4. Based on this clustering, we
1.Notice that our specialization and generalization relations differ from the terminology usually adopted in Conceptual Graph community.
149
define the following functions: - m o s t - s p e c i a l i z e d ( G 1, G2) = G 1 iff 3 a specialization relation between G 1 and G 2
G 2 iff 3 a specialization relation between G 2 and G 1 0 otherwise. - m o s t - g e n e r a l i z e d (G 1, G2) = G 2 iff most-specialized(G 1, G2) = G 1 G 1 iff most-specialized(G 1, G2) = G 2 0 otherwise. m o s t - i n s t a n t i a t e d (G 1, G2) = G 1 iff 3 an instantiation relation between G 1 and G 2
-
G 2 iff 3 an instantiation relation between G 2 and G 1 0 otherwise. - m o s t - c o n c e p t u a l i z e d (G 1, G2) = G 2 iff most-instantiated (G1, G2) = G 1 G 1 iff most-instantiated (G 1, G2) = G 2 0 otherwise. R e m a r k : The previous ~F-morphisms need not be injective. The interest to use or not surjective W-morphisms is discussed in 12.
S \ ( Specialization (
_Specialization &
)
Fig. 4: Clustering of global relations among conceptual graphs. Example. In the example of Fig. 3, the following relations hold: IsRelation&ConceptPartialGeneralization&PartialConceptualization (G 1, G2) IsRelation&ConceptPartialSpecialization&PartialInstantiation (G 2, GI) Therefore, most-generalized (G 1, G 2) = G 1, most-specialized (G 1, G2) = G 2 most-instantiated (G 1, G2) = G 1, most-conceptualized (G 1, G2) = G 2
7 7.1
Construction of the Base of Integrated Conceptual Graphs Strategies of Integration
Unless the relation I n c o m p a t i b l e G r a p h s (G 1 , G 2) was set up between both graphs, their integration is possible. The building of the integrated graph Gcom from both graphs G 1 and G 2 is guided by a s t r a t e g y for solving conflicts. To each strategy, two functions, fglobal and floeal can be associated. If there exists a global relation between G 1 and G2, the result of the function fglobal associated to the current strategy will be included in Gcom. If no such global relation exists, the local relations among comparable elementa-
150
ry links are exploited : in case of choice between two such comparable links 11 ~ -'~1, and 12 ~ -'~2 the result of the function flocal associated to the current strategy will be included in Gcom. If the function flocal gives no result, both links 11 and 12 are included in Gcom. The connection of the partial graphs thus obtained is performed with strategy-dependent join operations: we implemented another version of the maximal join operator 12. Once the integrated graph created for each viewpoint, the common knowledge model is obtained. According to the integration strategy chosen by the KE, the graphs of this common knowledge model may represent or not the complete knowledge of both initial graph bases. MULTIKAT supplies the KE with 9 predefined strategies among which she can make a choice. These strategies allow to carry out the integration according to various criteria. The ~direct~ strategies are better when the ICE prefers to always restrict to what was explicitly expressed by at least one expert and takes no initiative for modifying the knowledge expressed by an expert. The ~indirect~ strategies are useful when the KE prefers to exploit the knowledge expressed by an expert, in order to take initiative for modifying (e.g. generalizing, specializing, conceptualizing or instantiating) the other expert's knowledge.
Strategy of the highest direct generalization: Preconditions: An expert focuses on particular cases, while the other expert expresses general knowledge, valid in more general cases. fglobal (G1, G2) = most-generalized (G 1, G2); flocal (ll, 12) = most-generalized (11, 12)
Strategy of the highest indirect generalization: Preconditions: The characteristics of the expert are the same as in the previous case. fglobal(G1,GE)=most-generalized (G1, G2); flocal (11,12) = common-generalization (11, 12)
Strategy of the highest direct specialization: Preconditions: An expert is more specialized than the other, on a given aspect and uses more precise expressions. fglobal (G1, G2) = most-specialized (G 1, G2); flocal (11, 12) = most-specialized (11, 12)
Strategy of the highest indirect specialization: Preconditions: The preconditions on the experts are the same as in the previous case. fglobal (G1,GE)=most-specialized (G1, G2); flocal (ll, 12) = common-specialization (11, 12)
Strategy of the highest direct conceptualization: Preconditions: An expert focuses on too particular cases and on too specific examples, while the other expert expresses general knowledge, at a better level of abstraction. fglobal(G1,G2) =most-conceptualized (G 1, G2); flocal(ll, 12) =most-conceptualized (l 1, 12) If the function gives no result, both links l 1 and 12 are included in Gcom.
Strategy of the highest indirect conceptualization : Preconditions: The characteristics of the expert are the same as in the previous case. fglobal(G 1,GE)=m~176 !,G2); flocal(ll,lE)=common-conceptualization(ll, 12)
151
Strategy of the highest direct instantiation 1: Preconditions: An expert gives useful and precise examples. fglobal (GI, G2) = most-instantiated (G 1, G2); flocal (11, 12) = most-instantiated (11, 12) Strategy of the greatest competence: Preconditions: An expert is known as having a higher level of competence in a given field. flocat (11, 12) = specialist (11, 12) Strategy of experts' consensus: Preconditions: (1) Both experts have the same level of competence in the considered field and the KE has no criterion for choosing one rather than the other. (2) Or, for < reasons, it is impossible to make a selection between both experts. (3) Or, the future KBS or corporate memory to be built is explicitly aimed at relying only on the intersecting knowledge of both experts. flocal (11, 12) = 11 iff is-same-link (12, 11) the link on which both experts agree otherwise. 7.2
Method for Using Integration Strategies
Among those predefined strategies, the KE chooses the integration strategy, according to the individual characteristics of the experts and to their expertises: their specialities, the way they expressed during the elicitation sessions (level of precision, abstraction of their expressions, presence or absence of examples illustrating abstract knowledge, capability to abstract knowledge from particular cases...). The KE can choose a global strategy, to be applied throughout the integration algorithm, or, on the contrary, a local strategy to be changed according to the context. So, throughout a given session, the KE can combine the previously described integration strategies, with the help of the experts. For example, in traffic accident analysis, if the two psychologists are respectively known as specialists of GTI vehicle drivers and of drivers' errors, the KE can adopt (a) the strategy of the greatest competence when comparing parts of the graphs concerning drivers of GTI vehicles or drivers' errors, (b) otherwise, the strategy of the highest direct specialization whenever it can be applied. Fig. 5 shows an example of integration with two different strategies.
8 8.1
Conclusions Implementation and Further Work
The interested reader can find the details of all algorithms in 12. MULTIKAT was implemented in C/C++, above the COGITO platform 11. We restricted to binary relations. The implementation of W-morphisms relied on COGITO projection. We also implemented another version of the maximal join operator. For the interaction with the user (i.e. the KE), a graphic user interface was implemented using JAVA and JDK-1. lb, in order to allow a distant use over the Internet. The algorithm of comparison commu-
1.The definition of a strategy of the highest indirect instantiation seems difficult.
152
nicates with the user interface via a TCP/IP socket connection. It functions as a clientserver communication. MULTIKAT was tested on different examples stemming from knowledge models in traffic accident analysis 4 12. As a further work, we will take into account the notion of viewpoints proposed in 16, in order to extend our criteria of comparison among the graphs.
I
Driver ~ g ' x ~ ~ c ~
G3
GTI-Driver
- w q ~J" I " ~ , ~ . , , " " - ~ ~ Age : young
Excessive-Speed I
Driver's.Injury-Level: , ~ ~ ~ r I very-serious ~ . v _ i n g - w i ~ N ~ t GTI ~ ' J (.~fSleOd~ I Driver's-Error I
I
Gcoml
Driver' s-Injury-Level: very-serious ~ ~ V e h i c l e _ C o n t r o l _ L o s s GTI-Driver ~
~
~
'
I
, Age : young
Gcom2
Driver's-Error
Fig. 5. Integrated graph of G2 and G3, with a strategy of the highest specialization (resp. generalization) 8.2
Related Work
In this paper, we described a tool MULTIKAT implementing an algorithm for comparison and integration of CGs representing knowledge of several experts. Techniques for comparing several viewpoints and solving conflicts among them are described in 6. Techniques for integrating new knowledge into an existing knowledge base are proposed in 14. Our techniques of comparison between several CGs can also be compared to research on algorithms for similarity-based matching of CGs 15 or for merging
153
C G s 9 or e v e n on graph i s o m o r p h i s m 10. Our exploitation o f local and global relations a m o n g graphs, and o f integration strategies seems original. M o r e o v e r , w e c o m b i ne both automatic and c o o p e r a t i v e integration and w e allow the c o m b i n a t i o n o f several c o m p a r i s o n criteria thanks to several integration criteria.
References 1. 2. 3. 4.
5. 6. 7. 8. 9. 10.
11. 12. 13. 14. 15.
16. 17. 18. 19.
20.
Chein, M., Mugnier, M.-L. Conceptual Graphs: Fundamental Notions. R1A, 6(4):365-406, (1992). Dieng, R. Conflict Management in Knowledge Acquisition. In I. Smith (Ed), AIEDAM, Special Issue on Conflict Management in Design, 9(4):337-351, (1995). Dieng, R. Comparison of Conceptual Graphs for Modelling Knowledge of Multiple Experts. In Ras & al eds., Foundations of Intelligent Systems, ISMIS'96, Springer-Verlag, LNAI 1079, (1996) 78-87. Dieng, R. Comparison of Conceptual Graphs for Modelling Knowledge of Multiple Experts: Application to Traffic Accident Analysis. INRIA Research Report RR-3161, (1997). Also in http://www.inria.fr/ RRRT/RR-3161.html Dieng, R., Hug., S. Comparison of <~Personal Ontologies>>Represented through Conceptual Graphs. To appear in Prade ed., Proc. of ECAI'98, John Wiley & Sons, Ltd, Brighton, UK (1998) 341-345. Easterbrook, S. Handling conflict between domain descriptions with computer-supported negotiation. Knowledge Acquisition, 3(3):255-289, (1991). Gaines, B., Shaw, M. Comparing the Conceptual Systems of Experts. In Proc. of IJCAI'89, Detroit, USA (1989) 633--638. Garcia, C. Co-Operative Building of an Ontology within Multi-Expertise Framework. Proc. of the 2nd Int. Conf. on the Design of Cooperative Systems (C00P'96), Juan-les-Pins (1996) 435-454. Garner, B. J., Lukose, D. Knowledge Fusion. In H. D. Pfeiffer &al eds, Conceptual Structures: Theory and Implementation, Springer-Verlag, LNA1754, Las Cruces, NM, USA (1992) 158-167. Guinaldo, O. Conceptual Graph Isomorphism: Algorithm and Use. In Eklund et al, eds, Conceptual Structures: Knowledge Representation as lnterlingua, Spring.-Verl., LNAI 1115, Sydney, Australia (1996) 160-174. Haemmefl6, O. CoGITo: une plate-forme de ddveloppement de logiciels sur les graphes conceptuels. Ph.D thesis, Montpellier II University, France (1995). Hug., S. Vergleich von Begriffsgraphen fiir die Modellierung von Wissen mehrerer Experten. Master Thesis, Univ. of Karlsruhe, Germany (1997). Mineau, G. W., Allouche, M. Establishing a Semantic Basis: Toward the Integration of Vocabularies. In Gaines et al eds Proc. of KAW'95, pp. 2-1 - 2-16, Banff, Canada (1995). Murray, K., Porter, B. Developing a Tool for Knowledge Integration: Initial Results. lnt.Journal of Man-Machine Studies, 33:373-383 (1990). Poole, J., Campbell, J. A. A Novel Algorithm for Matching Conceptual and Related Graphs. In G. Ellis et al eds, Conceptual Structures: Applications, Implementation and Theory, Springer-Veflag, LNAI 954, Santa Cruz, CA, USA (1995) 293-307. Ribi~re, M., Dieng, R. Introduction of Viewpoints in Conceptual Graph Formalism. In Lukose & al eds, Fulfilling Peirce's Dream, ICCS'97, Springer-Verlag, LNAI 1257, Seattle, USA,(1997) 168-182. Shaw, M. L. G., Gaines, B. R. A methodology for recognizing conflict, correspondence, consensus and contrast in a knowledge acquisition system. Knowledge Acquisition, 1(4):341-363, (1989). Sowa, J. F. Conceptual Structures: Information Processing in Mind and Machine. Reading, AddisonWesley, (1984). Tennison, J., Shadboldt, N. APECKS: a Tool to Support Living Ontologies. In Gaines et al eds, Proc. of the 11th Banff Workshop on Knowledge Acquisition, Modeling and Management (KA W'98), Banff, Canada, (1998). Also in http://ksi.cpsc.ucalgary.ca/KAW/KAW98/tennisolaJ Willems, M. Projection and Unification for Conceptual Graphs. In Ellis et al eds, Conceptual Structures: Applications, Implementation and Theory, Springer-Verlag, LNAI 954, Santa Cruz, CA, USA, (1995) 278-292.
A Platform Allowing Typed Nested Graphs: How CoGITo Became C o G I T a N T David Genest and Eric Salvat LIRMM (CNRS and Universit~ Montpellier II), 161 rue Ada, 34392 Montpellier Cedex 5, France.
A b s t r a c t . This paper presents CoGITaNT, a software development platform for applications based on conceptual graphs. CoGITaNT is a new version of the CoGITo platform, adding simple graph rules and typed nested graphs with coreference links.
1
Introduction
The goal of the CORALI project (Conceptual graphs at Lirmm) is to build a theoretical formal model, to search for algorithms for solving problems in this model, and to develop of software tools implementing this theory. Our research group considers the CG model 16 as a declarative model where knowledge is solely represented by labeled graphs and reasoning is can be done by labeled graphs operations 3. In a first stage, such a model, the "simple conceptual graph" (SCG) model has been defined 4,11. This model has sound and complete semantics in first order logic. This model has been extended in several ways such as rules 12, 13 and positive nested graphs with coreference links 5. As for the SCG model, a sound and complete semantics has been proposed for these extensions 6, 15. The software platform CoGITo (Conceptual Graphs Integrated Tools) 9, 10 had been developed on the SCG model. This paper presents the updated version of this platform, CoGITaNT ( C o G I T o allowing Nested Typed graphs), which is based on these extensions: graph rules and nested conceptual graphs with coreference links. 2
CoGITaNT
CoGITaNT is a software platform: it enables an application developer to manage graphs and to apply the operations of the model. For portability and maintenance reasons, the object oriented programming paradigm was chosen and CoGITaNT was developed as a set of C + + classes. Each element of the theoretical model is represented by a class (conceptual graph, concept vertex, concept type, support,... ). Hence, the use of object programming techniques allows to represent graphs in a "natural" way (close to the model): for example, a graph is a set of concept vertices plus a set of relation vertices having an ordered set of
155
neighbors. The methods associated with each class correspond to the usual handling functions (graph creation, type deletion, edge addition, ... ) and specific operations on the model (projection, join, fusion, ... ). CoGITaNT is compiled using the freeware C + + compiler GNU C++ on Unix systems. CoGITaNT is available for free on request (for further informations, please send an e-mail to
cogito@lirmm, fr). C o G I T a N T is an extension of CoGITo: each functionality of the previous version is present in the new one. Hence, applicationsbased upon C o G I T o should use C o G I T a N T without important source filesmodifications. CoGITo has been
presented in 10, 2, we only describe here some distinctive characteristics. The platform manages SCGs, and implements algorithms that have been developed by the CORALI group, such as a backtracking projection algorithm, a polynomial projection algorithm for the case when the graph to be projected is a tree, and a maximal join (isojoin) algorithm. The new version extends available operations on simple graphs by implementing graph rules. CoGITaNT also introduces a new set of classes that allows handling of typed nested graphs with coreference links and some other new features: graphs are no more necessarily connected, the set of concept types and the set of relation types ;ay not be necessarily ordered by a "kind of" relation in a lattice but may be partially ordered in a poset. 3
Graph
Rules
Conceptual graph rules have been presented in 13 and 12. These rules are of "IF G1 THEN G2" (noted G1 =~ G2) kind, where G1 and G2 are simple conceptual graphs with co-reference links between concepts of G1 and G2. Such vertices are called the connection points of the rule. Conceptual graph rules are implemented as a new CoGITaNT class. An instance of this class consists of two SCGs, the hypothesis and the conclusion, and a list of couple of concept vertices (cl, c~), where Cl is a vertex of the hypothesis and c2 is a vertex of the conclusion. This list represents the list of connection points of the rule.
G,I 0.o.,:.x
. on::y
person :"
oo:'z I
lather
,
person:,.y
,
Fig. 1. An example of a graph rule. Figure 1 may be interpreted as the following sentence: "if a person X is the brother of a person Y, and Y is the father of a person Z, then X is the uncle of Y, and there exists a person which is the father of X and Y". In this figure, x, y, z
156
are used to represent coreference links. Vertices which referents are *x, *y and *z are the connection points of this rule. CG rules can be used in forward chaining and backward chaining, both mechanisms being defined with graph operations. Furthermore, these two mechanisms are sound and complete with respect to deduction on the corresponding subset of FOL formulae. Forward chaining is used to explicitly enrich facts with knowledge which is implicitly present in the knowledge base by the way of rules. Then, when a fact fulfills the hypothesis of a rule (i.e. when there is a projection from the hypothesis to the fact), then the conclusion of the rule can be "added" to the fact (i.e. joined on connection points). This basic operation of forward chaining is implemented in CoGITaNT. This method allows to apply a rule R on a CG G, following a projection ~r from the hypothesis of R to G. The resulting graph is RIG, ~r, obtained by joining the conclusion of R on G. The join is made on the connection points of the conclusion and the vertices of G which are images of the corresponding connection points in the hypothesis. This method is the basic method of forward chaining, since it allows only to apply a given rule on a given graph and following a given projection. But, since CoGITaNT allows to compute all projections between two graphs, then it is easy to compute all applications of a rule on a graph. Backward chaining is used to prove a request (a goal) on a knowledge base without applying rules on the facts of the knowledge base. Then, we search for a unification between the conclusion of a rule and the request. If such an unification exists, then a new request is built deleting the unified part of the previous request and joining the hypothesis of the rule to the new request. We defined backward chaining method in two steps: first, we compute all unifications between the conclusion of the rule and the request graph; then, given a rule R, a request graph Q and a unification u(Q, R), another procedure builds the new request. As in forward chaining, the implemented methods are the basic methods for a backward chaining mechanism. The user can manage the resolution procedure, for example by implementing heuristics that choose, in each step, the unifications to use at first.
4 4.1
Typed Nested Graphs with Coreference Links Untyped Nested Graphs and Typed Nested G r a p h s
In some applications, the SCG model does not allow a satisfactory representation of the knowledge involved. An application for the validation of stereotyped behavior models in human organizations 1 uses CGs to represent behaviors: Such CGs represent situations, pre-conditions and post-conditions of actions, each of these elements being described with CGs. Another application is using CGs for document retrieval 7: a document is described with a CG, such a CG represents the author, the title, and the subject (which is described by a CG). In these applications, knowledge can be structured by hierarchical levels, but this structure can not be represented easily by the SCG model. A satisfactory way of representing this structure is to put CGs within CGs.
157 An extension of the model, called the (untyped) "nested conceptual graph" (NCG) model 5 allows the representation of this hierarchical structure by adding in each concept vertex a "partial internal description" which may be either a set of NCGs or generic (i.e. an empty set, denoted **).
J perso.:':'" ~
watch:':'"
television : * power-on button : * : **
I
screen : * ITV show:* J presenter:*:"
2
agent
1 talk:~. **
1
object
2
person:*:** Ir
uninteresting : * : "* I
Fig. 2. An untyped nested conceptual graph. The (untyped) nested graph of figure 2 may represent the knowledge "A person is watching television. This television has a power-on button and its screen displays an uninteresting TV show where a presenter talks about someone". In figure 2, the same notion of nesting is used to represent that the button and the screen are "components" of the TV, the screen "represents" a TV show, and the scene where the presenter talks about someone is a "description" of the show. Hence, untyped NCGs fail to represent these various nesting semantics. However, in some applications, to specify the nesting semantics is useful. Typed NCGs may represent these more specific semantics than "the nested graph is the partial internal description" (see figure 3). The typed NCG model is not precisely described here, please refer to 5 for a more complete description. The typed NCG extension adds to the support a new partially ordered type set, called the nesting type set which is disjoint from the other type sets, and have a greatest element called "Description". A typed NCG G can be denoted G -- (R, C, E, l) where R, C and E are respectively relation, concept and edge sets of G, 1 is the labeling function of R and C such that Vr E R, l(r) = type(r) is an element of the relation type set, Vc e C, l(c) = (type(c), ref(c), desc(c)), where type(c) is an element of the concept type set, tel(c) is an individual marker or *, and desc(c) (called "internal partial description") is **, called the generic description or a non-empty set of couples (ti, G~), where ti is a nesting type and G~ is a typed NCG. 4.2
T y p e d N e s t e d G r a p h s in C o G I T a N T
One of the main new characteristics of CoGITaNT is that it allows handling typed NCGs. Data structures used by CoGITaNT for representing such graphs are a natural implementation of this structure.
158
~
I person:,,*:**
television : *
:*:**
-.
"-.
Component power-on button screen
watch
: * : **
" " " -..
:*
"-..
"..
Representation TV show: *
"'.
~
Description J presenter
:
:
tt
2
t agent
2 talk : *
uninteresting
object
: * : ** J
person : * : **
1
Fig. 3. A typed nested conceptual graph and a coreference link (dashed line). As described in figure 4, a typed N C G is composed of a list of connected components and a list of coreference classes (see further details). A connected component is constituted of a list of relation vertices and a list of concept vertices. A concept vertex is composed of a concept type, a referent (individual marker or *) and a list of nestings (** is represented by a NULL pointer). A nesting is constituted of a nesting type and a typed NCG. As for simple graphs, available methods implement usual handling functions and operations on the extended model. The projection structure and the projection operation defined on SCGs have been adapted to the recursive structure of NCGs and the projection operation follows the constraint induced by types of nestings 5. A "projection between typed NCGs" from H to G is represented by a list of "projections between connected components" 1. A "projection between connected components" from CCH to ccv is represented by a list of pairs (rl, r2) of relations 2 and a list of structures (Cl, c2, n) 3 where Cl is a concept vertex of CCH, c2 is a concept vertex of cco and n is an e m p t y list (if cl has a generic description) or a list of structures (nl, n2, g) where nl is a nesting of Cl, n2 is a nesting of c2 and g is a "projection between typed NCGs" from the graph nested in nl to the graph nested in n2. Thus, the representation of a projection between t y p e d NCGs has a recursive structure which is comparable with the structure of typed NCGs. The projection algorithm between NCGs computes first every projection between level-0 graphs without considering nestings. Obtained projections are then filtered: let H be one of these projections, if a concept vertex c of H has a nesting (t, G) such t h a t II(c) does not contain a nesting (g, G ~) such 1 for each connected component in H there is one "projection between connected components" in the list. 2 for each relation vertex r in CCH there is one pair (r, II(r)) in the list, where II(r) is the image of r. 3 for each concept vertex c in CCH there is one structure (c, II(c), n) in the list, where ll(c) is the image of c.
159
typed NCG
I
I
I list of coreference classes
list of connected components
connected component
I
I
I
I
list of concept vertices
list of relation vertices
relation vertex
relation type
coreference class
list of concept vertices
concept vertex
I
I
concept type
referent
, j
list of nestings ~
nesting
I nesting type
I typed NCG
Fig. 4. Data structures: typed NCG. that t >_ t' and there is a projection from G to G', t h e n / - / i s not an acceptable projection. Acceptable projections are then completed (third part of (Cl, c2, n) structures: projections between nestings). SCGs are also typed NCGs (without any nesting) and untyped NCGs are also typed NCGs (the type of each nesting is "Description"), hence CoGITaNT can also handle SCGs and untyped NCGs. Even if data structures and operations are not optimal when handling such graphs, there is no sensible lack of performances comparing to SCGs operations of CoGITo. Useless comparisons of (generic) descriptions for SCGs handled as typed NCGs (e.g. comparison of NULLpointers) and useless comparisons of nesting types (equal to "Description") for untyped NCGs handled as typed NCGs do not influence on the overall performances of the system. 4.3
Coreference Links
CoGITaNT also allows handling coreference links. A set of non-trivial coreference classes is associated with each graph. These classes are represented by lists of (pointers to) concept vertices. Trivial coreference classes (such as one-element classes and classes constituted by the set of concept vertices having the same type and the same individual marker) are not represented for memory saving reasons. The coreference link in figure 3 is represented by a (non-trivial) 2element coreference class that contains the two "person" concept vertices. Of course, the projection method makes use of coreference classes: the images of all vertices of a given coreference class must belong to the same (trivial or non trivial) coreference class. The projection algorithm from H to G currently computes first every projection from H to G without coreference constraints.
160
L e t / / b e one of these projections. In order to return only those conforming to coreference constraints, projections are then filtered: VCOH a non trivial coreference class of H , Vcl 6 Coil, Vc2 6 COH, if /-/(cl) and H(c2) are not in a same (trivial or non trivial) coreference class, then H is not an acceptable projection.
5
The
BCGCT
Format
A simple extension of the B C G C T format 9 is the CoGITaNT native file format: it is a textual format allowing supports, rules and graphs to be saved in permanent memory. Files in this format can easily be written and understood by a user, B C G C T is indeed a structured file format which represents every element of the model in a natural way. For example, the representation of a graph is constituted of three parts, the first describes concept vertices, the second describes relation vertices, and the third represents edges between these vertices. The representation of a concept vertex is a 3-tuple constituted of a concept type, an individual marker or an optional "*" (generic concept), and a set of couples (tl, Gi) where t~ is a nesting type and Gi is a graph identifier, or an optional "**" (generic description). Ex: cl= t e l e v i s i o n : * : (Component , g t v d e s c r ) ; ( "gtvdescr" is a graph identifier). Coreference links are represented using the same variable symbol for each concept vertex belonging to the same coreference class. Ex: c3= p e r s o n : $xl :** ; and c9= p e r s o n : $xl ; represent that these concept vertices belong to the same coreference class.
6
Conclusion
The platform has been provided to about ten research centers and firms. In particular, two collaborations of our research group, the one with Dassault Electronique and the other with the ABES (Agency of French university libraries) lead evolutions of the model and the platform. The research center of the firm Dassault Electronique uses the platform for building a software that furnishes an assistance for the acquisition and the validation of stereotyped behavior models in human organizations 1. This application led our research group to the definition of the typed NCG model, and its implementation in CoGITaNT. The other project of our group is on document retrieval: a first approach 8 convinced the ABES to continue with our collaboration to study the efficiency of a document retrieval system based on CGs and to develop a prototype of such a system. These collaborations make us consider many improvement perspectives for CoGITaNT. The efficiency of some operations can be improved by algorithmical studies. Indeed, the optimization of the unification procedure for graph rules will improve the backward chaining mechanism efficiency. Moreover, coreference links processing during projection computing can be improved by an algorithm that considers as soon as possible restrictions induced by these links.
161
We plan the extension of the expressiveness of C o G I T a N T with nested graph rules. A first theoretical study has been done in 14, 12, but nested graphs considered in this study are without coreference links. The extension of this work with coreference links will be implemented in the platform. In the long term, negation (or limited types of negation which are required by applications we are involved in) will be introduced in C o G I T a N T as required by the users of the platform.
References 1. Corinne Bos, Bernard Botella, and Philippe Vanheeghe. Modelling and simulating human behaviours with conceptual graphs. In Proceedings of ICCS '97, volume 1257 of LNAI, pages 275-289. Springer, 1997. 2. Boris Carbonneill, Michel Chein, Olivier Cogis, Olivier Guinaldo, Ollivier Haemmerl~, Marie-Laure Mugnier, and Eric Salvat. The COnceptual gRAphs at LIrmm project. In Proceedings of the first CGTools Workshop, pages 5-8, 1996. 3. Michel Chein. The CORALI project: From conceptual graphs to conceptual graphs via labelled graphs. In Proceedings of ICCS '97, volume 1257 of LNAI, pages 65-79. Springer, 1997. 4. Michel Chein and Marie-Laure Mugnier. Conceptual graphs: Fundamental notions. RIA, 6(4):365-406, 1992. 5. Michel Chein and Marie-Laure Mugnier. Positive nested conceptual graphs. In Proceedings of ICCS '97, volume 1257 of LNAI, pages 95-109. Springer, 1997. 6. Michel Chein, Marie-Laure Mugnier, and Genevieve Simonet. Nested graphs: A graph-based knowledge representation model with FOL semantics. To be published in proceedings of KR'98, 1998. 7. David Genest. Une utilisation des graphes conceptuels pour la recherche documentaire. M~moire de DEA, 1996. Universit~ Montpellier II. 8. David Genest and Michel Chein. An experiment in document retrieval using conceptual graphs. In Proceedings of ICCS '97, volume 1257 of LNAI, pages 489-504. Springer, 1997. 9. Olliver Haemmerl6. CoGITo : une plateforme de ddveloppement de logiciels sur les graphes conceptuels. PhD thesis, Universit6 MontpeUier II, France, 1995. 10. OUiver Haemmerl~. Implementation of multi-agent systems using conceptual graphs for knowledge and message representation: the CoGITo platform. In Supplementary Proceedings of ICCS'95, pages 13-24, 1995. 11. Marie-Laure Mugnier and Michel Chein. Repr6senter des connaissances et raisonnet avec des graphes. RIA, 10(1):7-56, 1996. 12. Eric Salvat. Raisonner avec des opdrations de graphes : Graphes conceptuels et r~gles d'infdrence. PhD thesis, Universit6 Montpellier II, France, 1997. 13. Eric Salvat and Marie-Laure Mugnier. Sound and complete forward and backward chaining of graph rules. In Proceedings of ICCS '96, volume 1115 of LNAI, pages 248-262. Springer, 1996. 14. Eric Salvat and Genevieve Simonet. R~gles d'inf~rence pour les graphes conceptuels embot6s. RR LIRMM 97013, 1997. 15. Genevieve Simonet. Une sfimantique logique pour les graphes embot~s. RR LIRMM 96047, 1996. 16. John F. Sowa. Conceptual Structures: Information Processing in Mind and Machine. Addison Wesley, 1984.
Towards Correspondences Between Conceptual Graphs and Description Logics P. Coupeyt and C. Faron$ tLIPN-CNRS UPRESA 7030, Universit6 Paris 13, Av. J.B. Clement, 93430 Villetaneuse, France [email protected] :~LIFO, Universtit6 d'Orl~ans, rue L~onard de Vinci, BP 6759 45067 Orleans cedex 2, France Catherine.Faron~lip6. fr, [email protected] A b s t r a c t . We present a formal correspondence between Conceptual Graphs and Description Logics. More precisely, we consider the Simple Conceptual Graphs model provided with type definitions (which we call TSC~) and the .Af~,f.O7. standard Description Logic. We prove an equivalence between a subset of TSC~ and a subset of .AEF_.OZ.Based on this equivalence, we suggest extensions of both formalisms while preserving the equivalence. In particular, regarding to standard Description Logics where a concept can be defined by the conjunction of any two concepts, we propose an extension of type definition in CGs allowing type definitions from the "conjunction" of any two types and consequently partial type definitions. Symmetrically, regarding generalization/specialization operations in Conceptual Graphs, we conclude by suggesting how Description Logics could take advantage of these correspondences to improve the explanation of subsumption computation.
1
Introduction
Conceptual Graphs (CGs) 21 and Description Logics (DLs) 3 both are knowledge representation formalisms descended from semantic networks. They are dedicated to the representation of assertional knowledge (i.e. facts) and terminological knowledge: hierarchies of concept types and relation types in CGs, hierarchies of concepts and roles in DLs. Subsumption is central in both formalisms: between graphs or between types in CGs (generalization), between concepts in DLs. Similarities between these formalisms have often been pointed out 1, 11 but up to now, to our knowledge, no formal study has ever been carried out about correspondences between CGs and DLs. Beyond an interesting theoretical result, such a work would offer CGs and DLs communities a mutual advantage of about 15 years of research. More precisely, numerous formal results in DLs about semantics and subsumption complexity could easily be adapted to CGs. Symmetrically, specialization/generalization and graph projection operations defined in CGs would help in explaining the computation of subsumption in DLs and thus contribute to current research in this community 14.
166
In this paper, we present a formal correspondence between Conceptual Graphs and Description Logics. More precisely, focusing on the terminological level, we consider the standard Description Logic .A/~CG~ 18 and the Simple Conceptual Graphs model 7, 8, 5 provided with type definitions 6, 12, 13 we call 7-SC~. We outline fundamental differences between both formalisms and set up restrictions on them, thus defining two subsets: G and s Then we show, regarding their formal semantics, that G and /2 are two notational variants of the same formalism and that subsumption definitions in G and /2 are equivalent. Based on this result, we make both formalisms vary while preserving the equivalence. In particular, regarding standard DLs where a concept can be defined by the conjunction of any two concepts, we propose an extension of type definition in CGs allowing concept type definitions from the "conjunction" of any two types and consequently partial type definitions. Symmetrically, regarding generalization/specialization operations in CGs, we suggest how DLs could take advantage of their correspondences with CGs to improve the explanation of subsumption computation. First we present ,4/~EOZ and TSCG in sections 2 and 3. Then we prove in section 4 the equivalence between the sub-formalisms ~ of 7-SCG and ~ of .As In section 5 we examine extensions of ~ and/2 that preserve the equivalence.
2
Description Logics
Description logics are a family of knowledge representation formalisms descended from the KL-ONE language 3. They mostly formalize the idea of concept definition and reasoning about these definitions. A DL includes a terminological language and an assertional language. The assertional language is dedicated to the statement of facts and assertional rules, the terminologicM language to the construction of concepts and roles (binary relations). A concept definition states necessary and sufficient conditions for membership in the extension of that concept. Concepts in DLs are organized in a taxonomy. The two fundamental reasoning tasks are thus subsumption computation between concepts, and classification. The classifier automatically inserts a new defined concept in the taxonomy, linking it to its most specific subsumers and to the most general concepts it subsumes. Among standard Description Logics we have selected As 18 since it is the largest subset of the best known DL CLASSIC 2 and the necessary description language for which a correspondence with the Simple Conceptual Graphs model holds true. .AZ.s is inductively defined from a set Pc of primitive concepts, a set P~ of primitive roles, a set I of individuals, the constant concept -l-, and two abstract syntax rules; one for concepts ( P is a primitive concept, R a role and ai elements
of I): C, D
--4
-IP
most general concept primitive concept
167
I
VR.C
13n.c I CmD
I {al...a~}
universal restriction on role existential restriction on role concept conjunction concept in extension
and one for roles (Q is a primitive role): R
-+
Q Q-1
primitive role inverse primitive role
Figure 1 presents examples of ,4s formulae. The first one describes the females who are researchers; the second one, the males who have at least one child; the third, the females all of whose children are graduates; the fourth, the boys whose mother has a sister who is a researcher; the last one, the males whose (only) friends are Pamela and Claudia, who are female.
Female 3 Researcher Male rq 3child.T Female rq Vchild.Graduate Boy 7 3child -1 .(Female 3 3sister.Researcher) Male rq VFriend.( { Pamela Claudia} rq Female) Fig. 1. Examples of A E E O Z formulae
A concept may be fully defined 1 (i.e. necessary and sufficient conditions) from a term C of . 4 s this is noted A - C, or partially defined (i.e. necessary but not sufficient conditions) from a term C of A s this is noted A c C. A terminological knowledge base (T-KB) is thus a set of concepts and their definitions (partial or full). Note that all partial definitions can be converted into full definitions by using new primitive concepts (cf. 17). Let an atomic concept A be partially defined w.r.t, a term C: A r- C. This can be converted into a full definition by adding to Pc a new primitive concept A': A - A ' rq C. A' implicitly describes the remainder of the necessary additional conditions for a C to be an A. From a theoretical point of view this supposes that one can always consider a T-KB has no more partial definitions. Figure 2 presents the definition of concept R N e p h e w .
R N e p h e w - Boy I3 3child -1 .(Female 13 3sister.Researcher) Fig. 2. Defmition of concept RNephew 1 We assume that concept definitions are non-recursive.
168
The formal meaning of concept descriptions built according to the above rules is classically given as an extensional semantics by an interpretation I = (D, I1.11I). The domain D is an arbitrarily non-empty set of individuals and I1.11z is an interpretation function mapping each concept onto a subset of D, each role onto a subset of D • D and each individual ai onto an element of D (if ai and aj are different individual names then IlaillI # HajllI). The denotation of a concept description is given by:
117-11~ = D IIC rq DII ~ = IICII I n IIDII'
IIVR.CII ~ = {a E D, Vb, if (a, b) E Ilnll ~ then b E IICIl') 113R.Cll ~ = {a E D, 3b, (a, b) ~ IIRII~ and b E IICIIz} II{al... a.}ll I = U;~=l{llaill z} IIQ-11 I = {(a,b), (b,a) E IIQIIz} An interpretation I is a model for a concept C if IICll I is non-empty. Based on this semantics, C is subsumed by D, noted C v- D, iff IlCll I C IIDI I for every interpretation I. C is equivalent to D iff (C r- D) and (D U C). The reader will find complete theoretical and practical developments in 17.
3
Conceptual
Graphs
Conceptual Graphs have first been introduced by J. Sowa in 21. In this paper, we consider the Simple Conceptual Graphs model SCG defined in 7, 8, 5 and extended with type definitions in 12, 13. We call it TSCG. It is a formal system appropriate to comparisons with Description Logics. We focus on the terminological level of 7-SC~, i.e the canon. A canon mainly consists of two type hierarchies: the concept type hierarchy Tc and the relation type hierarchy Tr, each one provided with a most general type, respectively Tc and T~. A canon also contains a canonical base of conceptual graphs, called star graphs, expressing constraints on the maximal types of the adjacent concept vertices of relation vertices 16. Conceptual graphs are built according to the canon, i.e they are made of concept and relation nodes whose types belong to T~ and T~ and respect the constraints expressed in the canonical base. Both type hierarchies are composed of atomic and defined types. A concept type definition s is a monadic abstraction, i.e. a conceptual graph whose one generic concept is considered as formal parameter. It is noted t~(x) r D(z). The formal parameter concept node of D(z) is called the head of t~, its type the genus of t~ and D(z) the differentia from tc to its genus 13. A relation type definition is a n-ary abstraction, i.e. a conceptual graph with n generic concepts considered as formal parameters. It is noted tr(xz, ...zn) r D(xz, ...xn). Figure 3 presents the definition of concept type RNephew and its logical interpretation. 2 We assume that type definitions are non-recursive.
169
vx (RN~phew(x) n ~ . ~ c h ~ ( z )))
.~
(3~, 3z Bou(~) ^ chile(y,x) ^ Female(y) ^ ~i~te~(U, z) ^
Fig. 3. Definition of concept type RNephew
T~ and T~ are provided with the order relations _
Correspondences
between
T,-qCG a n d r
Let us now consider the terminological parts of TSC~ and .A~.gOZ. Regarding the definition of concept RNephew (figure 2) and type RNephew (figure 3) which obviously describe the same set of individuals, one may easily guess that a conceptual graph made of a relation R between two concepts ~ and is translated in .ALgOz by the formula C 7 3R.D. In this section, our aim is to formalize this intuition and prove an equivalence between a subset G of TSCG and a subset s of Af~EOZ. In the following subsection we define G and s by restricting TSC~ and AfEOZ. 4.1
R e s t r i c t i o n s o f TSCG a n d .AISEOZ
To state an equivalence between TSCG and ,4f_.gOZ, some restrictions are necessary which correspond to real differences between CGs and DLs, others are only useful to avoid the writing of definitions and properties unnecessarily complex. In section 5 we show that most of these restrictions may be relaxed while preserving the equivalence.
Necessary Restrictions 1. In .A~gSO:T.and more generally in all DLs, complex role descriptions are not allowed. In TSC~, let us consider two relations R and R ~ from a concept vertex ~ : ~ to a concept vertex ~ whose logical formula is 3y C(x) A
170
2.
3. 4.
5. 6.
R(x, y) A R'(x, y) A D(y). This can not be translated in . A s 1 6 3 since it is impossible to describe properties on roles, and thus to describe the conjunction R(x, y) A R'(x, y). This kind of description corresponds to cycles (cf. 21, page 78). In consequence, we only consider in TSCG definition graphs which do not contain cycles, i.e. trees (like in 15). Since there is no constraint on roles in .As163 we consider the canonical base in TSCG is empty. Concept vertices adjacent to a relation vertex can thus have any type. Since there is no connective to define complex roles in .As we consider there is no defined relation types in the set Tr of TSCG. Since there are only binary relations in standard DLs, we do not consider n-cry relation types in TSCG. As outlined in section 5 this is not a real restriction since it is known that any n-cry relation can be translated as a set of binary relations. Since CGs are existential graphs, we do not consider in .As163 the universal quantification on roles, i.e. the V connective which is standard in DLs. Since there is no way in CGs to define 3 a type as the conjunction of two types, we limit in . A s 1 6 3 the scope of the 7 connective of standard DLs: the conjunction connective is restricted to C • SR.D.
We will show in section 5.2 how to relax all these restrictions, the fifth excepted, by extending TSC~ and .As Useful Restrictions 1. Even the descriptions of sets of individuals in ~4s163 and individual referents in T S C ~ both are allowed, it would unnecessarily complicate the proof of the equivalence. In consequence, we consider no concepts description in extension in .As ( { a l . . . an }) and no individual concepts in TSCG (only generic concepts). 2. Since any concept in .As is defined, except primitive ones t h a t can not be compared, we consider type hierarchies as only made of incomparable types we call primitive types: the most specialized c o m m o n super-type of any two atomic types is type Tc in Tc and type T r in Tr. 3. Since in DLs subsumption between concepts relative to a terminology T is equivalent to subsurnption with an e m p t y terminology (cf. section 2), we only consider unordered atomic types in the canon of TSC~(i.e. no defined types in the canon). We will show in section 5 how to relax these useful but not necessary restrictions. 4.2
~ and s
We call ~ and s the sub-formalisms of TSC~ and .As above restrictions.
corresponding to the
3 We only consider "fully" defined types (cf. the second useful restriction below).
171
Concept definition in s may be defined like in .As section 2), with no concept in extension, no universal restriction on roles and a limited version of conjunction: C n 3R.D. Here we give an equivalent definition of concept definition relying on an inductive definition of the set C of concepts: C0 = Pc U {T} d,` = 6 . , - 1 U { C o n 3 R ~ . ( C , )
. . .n 3Rp.(Cp)
m 3n~~,.(Cp+~)...m3R~.(Cq), Co 9
d 0 , V / = 1 . . . q , Ci 9 g , ` - l , R i 9 P~} Concepts in Z: are then defined as follows: A - C, C 9 C. Concept type definitions in a are inductively defined by considering the following inductive definition of the set Ca of conceptual graphs: Cao =
C 9 Tc }
Ca,`= Ca,_lu{
~
,C 9 To,V/=1...q,P~ 9 Tr,Ci
9 Tc,Gi 9
C6,-1} Concept types in a are then defined as follows: t ca D(x), D(x) 9 Ca, its head being the concept vertex - ~ . The canon of a is made of two unordered sets Tc and Tr of types we call primitive types since they correspond to primitive concepts and roles in s
4.3
E q u i v a l e n c e b e t w e e n (~ a n d s
T h e o r e m l . a and s are two notational variants of the same formalism and subsumption definitions in a and s are equivalent. Proof. Let us first show that any concept type definition of a can be translated in s and that any concept definition of s can be translated in a. To do this, let us consider the two functions f : a ) 1: and g :/: ~ a. f is defined as follows: (Pc U {T} = T~ and P~ = T~) if a e Ca0, f ( a ) = f ( V ~
if
a 9 Can,f(G) -~ f( ~
= c,
) ~- C3Rl.(Cl)...l-3Rp.(Cp)
3R~-_~I.(Cp+I)... I9 3R~I.(Cq) , with Ci = f ( G i ) , g i = 1 . . . q .
R
172
A concept - ~ of ~ is translated into a concept C of/Z, a relation a role Ri, a relation Rj,j=v+l...n, to a role Ry 1.
Ri,i=l...p
Symmetrically, g is defined as follows: if D e C0, g ( D ) = -~-, ir/) e t:,,, ,(/)) = :l(G,n31r
~
, with
Gi
= g(Di) and Di -- Ci ...,
to
=
Vi
-= 1 ...q.
It is obvious that g = f - 1 and f is bijective, meaning that any concept type definition of ~ can be translated to a concept definition of ~ and vice-versa. Let us now consider the semantics of concept type definitions in G. Let t(x) <=> G(x), G e CG~. Its logical interpretation is the following: Vx(t(x) ++ F(x)), F(x) being an existentially closed conjunction of unary and binary predicates interpreting the concepts and relations of G respectively. The extensional semantics of such a concept type definition G in G is given in 8. It is exactly the same as the equivalent concept definition f(G) in /2 (cf. section 2). In other words G and/2 have the same semantics. G and s are thus two notational variants of the same logical formalism. Moreover, since the definitions of subsumption between two concept types in and subsumption between two concepts in Z; both rely on the inclusion of the extensions of concept types and concepts respectively, they are equivalent. R e m a r k : Our proof of the equivalence is based on the semantics. It could also have been shown by examining the connection between the equational system of .d/:gOZ(properties of its connectives) which characterizes equivalence classes 10, 9 and the notion of irredundantgraphs introduced in 7, 8.
5
Extensions
The equivalence between ~ and/2 is a first (but necessary) step towards broader correspondences between CGs and DLs. Research in DLs mostly consists in studying formally and in practice different Description Logics by varying the description language. Our aim is to apply this principle to CGs by conjointly extending ~ and s while preserving the equivalence, then taking advantage of these correspondences to transfer results from DLs to CGs and vice-versa. In this section, we succinctly present some of these extensions. We do not give the equivalence proofs but only the intuitive elements which conjecture them. Some of these extensions still are subsets of T,SCG (section 5.1) while others propose an enrichment of CGs (section 5.2).
173
5.1
Subsets of TSCG
I n d i v i d u a l s Whereas both TSCG and As163 allow description of individuals, for the sake of simplicity, we have defined G with no individual referents in conceptual graphs, and s with no concept definition in extension ( { a l . . . an}). Extending G with individual referents in conceptual graphs while preserving the equivalence with Z: does not bring any m a j o r problem. To do this, the terminological language of s must be extended with P(a~) and T(ai) which are respectively equivalent to P 7 {ai} and T Yl {ai}, {ai} being a concept in extension (cf. section 2) restricted to a single element. As a result, a limited form of cycles can be tolerated in CGs: cycles "closed" at an individual concept vertex can be translated in DLs. Figure 4 presents an example of such a conceptual graph of ~ and its translation in s
,BusOnvor
Malo*x
I
Male • 3friend.(Female(Claudia) 3sister.Female(Claudia))
Fom01eC,audia N 3own,Cat)
I-I 3chief.(BusDriver
R
Fig. 4. A definition graph including individuals and its translation in DLs
R e l a t i o n T y p e D e f i n i t i o n 7-86~ is provided with a relation type definition mechanism (cf. section 3). Some DLs also are provided with role connectives allowing the description of complex roles:
R,Q
R • Q
I I
domain R C range R C
role conjunction domain restriction co-domain restriction
For example, childR -- (domain child (Male ~ 3own.Cat)) ~ (range childR (Female R 3 member.FootballTeam)) defines a new role childR which describes a particular child relation between father and daughter such that the father owns a cat and the daughter is m e m b e r of a football team. The translation of this example in CGs is given in figure 5. The equivalence b e t w e e n / : and G could thus be extended to role and relation type definitions 4 4 Even if intuition allows to conjecture such an extension, an in-depth study still has to be done to make explicit a precise equivalence between relation type definitions in CGs and role definitions in DLs, which is outside of the scope of this paper.
174
childR(x, y) r
Fig. 5. Definition of relation type childR
C a n o n i c a l B a s e Translating in DLs the star graphs of the canonical base of TSCG also requires the addition of role connectives to s From a theoretical point of view, a star graph associated to a type relation R of Tr defines constraints relative to the concepts vertices adjacent to a relation vertex of type R in a conceptual graph (cf. section 3). In DLs, this is viewed as the definition of a new, more specific, relation type. Let Fem~0.'*~ m.d.~ Male:*y be the star graph associated to the married relation type. Its translation in DLs would be the definition of a new role m a r r i e d F M = (domain married Female) (range married Male), the role m a r r i e d F M being thus equivalent to the married relation type with its star graph. More generally, the constraints described by a star graph in TSC~ are translated in DLs by using the range and domain restrictions in role definition. C y c l e s in C G s Translating in DLs conceptual graphs not limited to trees also requires the addition of role connectives to s As an example, let R and R ~ be two relations vertices from a concept vertex ~ to a concept vertex ~ - ' ~ . Its translation in .As provided with role connectives would be the following: C n 9 ( n n R').D. N - a r y R e l a t i o n T y p e s In standard DLs roles are binary while relation types in CGs are n-ary. However it is known that any n-ary relation can be described with a set of binary relations 4, 20. From a theoretical point of view, adding n-ary relations to l: and ~ can therefore be considered without any change. 5.2
E x t e n d i n g t y p e definitions in T S C G
C o n c e p t C o n j u n c t i o n The conjunction of any two concepts is standard in DLs, while impossible in CGs. As an example, let NonSmoker and BusDriver be two primitive concepts; NonSmokerRBusDriver describes all the individuals who are non smokers and bus drivers. As it is shown in figure 6a, the problem that arises when translating such a conjunction in CGs is relative to the non connexion of definition graphs. A "non connected" graph being a set of connected graphs, from a logical point of view (as it is shown in 8) it is interpreted as the conjunction of the formulae interpreting its connected components. Then, such a conjunction is exactly the logical expression underlying the concept conjunction we want to translate in figure 6a. However authorizing this kind of definition graphs in CGs would induce technical graph writing problems when expanding defined concept types: as it is shown in figure 6c, to which concept should the
175
friend relation be connected when expanding concept C in the graph of figure 6b?
C(x)r INonSmoker:*x,
C: ~
~
gusDriver:*x
Researcher:
Researcher:
a
b
9 "
NonSmoker: IBusD~iver:
C(x) Nonsm~ ~ BusDriver:
c
d
Fig. 6. Concept type conjunction
To this representational problem in GCs, we propose a solution drawing its source from DLs. Some DLs are provided with a specific role id (for identity) describing all the couples (x, x)14, 19. Let id be an equivalent relation type in 7-SCG: it allows to define concept types as a concept type conjunction while preserving the connection of the defintion graph. For instance, concept type C in figure 6d describes all the individuals which are NonSmoker and BusDriver. The logical interpretation of this definition graph is the following: V x(C(x) r 3 y (NonSmoker(x) A BusDriver(y) A id(x, y))). Since x is equal to y (thanks to the id relation type), x is a BusDriver and a N o n S m o k e r which is exactly the semantics of NonSmoker 7 BusDriver. In other words, concept type definitions in G may be extended while preserving its equivalence with ~ (extended with id role) ~. U n i f o r m i z i n g T y p e D e f i n i t i o n In DLs, one can always consider that a T-KB contains only fully defined concepts by adding new primitive concepts (cf. section 3.2). This may be transposed to CGs by using the id relation. More precisely, a partial concept type definition may be converted into a full definition by adding a relation id from the head of the definition graph to a concept whose type is a new primitive concept type (cf. the figure 7b and 7c). This improvement would give an homogeneous semantics for all types in the canon. In CGs there is a distinction between atomic types which are sub-types of other type(s) and those which are fully defined with a conceptual graph. Regarding correspondences with DLs, one may envision an extension of CGs with partial definitions. Provided with partial definitions and the id relation, it would be possible to associate an equivalent full definition to any atomic or partially defined concept type, by building a conceptual graph using the "id" relation for conjunction of super-types and a new type - like in DLs (cf. section 2. For example, in figure 7a, C1 and C2 are partially defined by the conjunction 5 Of course this extension would imply to adapt the graphs operations (for example, by taking into account the commutativity of id) which is out of the scope of this paper.
176
of P1 and P 2 for C1 and the conjunction of C1 and P 3 for C2 (P1, P 2 and P3 are primitive types). Figure 7b presents the partial definitions of C1 and C2 and figure 7 their full definitions (P4 and P 5 are two new primitive types). The expanded form of the definition of C2 is presented in figure 7d.
Cl(x) r
PI
P3
a
c2(• ,,
b
c
d
Fig. 7. Definition graphs for non primitive concept types
As a result, from a theoretical point of view, one would now consider a terminological knowledge base for CGs as a set of (full) concept type definitions, the canon containing only primitive concept types as it is the case in DLs. This result should be adapted to type relation definition. Such an extension would allow to unify the formal semantics for types, definition graphs and subsumption. Thus, from a theoretical point of view, the whole terminological reasoning in CGs could be circumscribed to only the graph specialization/generalization operations 6.
6
Conclusion and Perspectives
In this paper, our aim was to provide formal correspondences between Conceptual Graphs and Description Logics. We have proved that a subset ~ of TSC~ and a subset s of the .As Description Logic are two notational variants of the same formalism at the terminological level, and that subsumption definitions are equivalent. This theoretical work is a necessary prerequisite for taking mutual advantage of research in CGs and DLs. As a first step in this transposition process, we have proposed an extension of TSCG with a special relation type id. This extension allows: to introduce partial type definitions without any change from a theoretical point of view - like in DLs; to associate a definition graph to any "non primitive" concept type (atomic or not) - like in DLs. As a result, it syntactically and semantically unifies subsumption between any concept types since it could be defined by a specialization of two expanded graphs. 6 Of course, we do not claim that, from a practical point of view, the canon and partial definitions are not usefull but that they can be not considered for formal study of terminological reasoning.
177
In this paper, we have focused on correspondences between the terminological levels of DLs and CGs. A first perspective of this work consists in studying formal correspondences between their assertional level. The most important perspective concerns adaptations of results from CGs to DLs. In particular, it would be fruitful to use graphs operations to solve a crucial problem in DLs: how to explain subsumption? Indeed, in DLs, a terminological knowledge base is split into formulae and the normalization process simplifies and transforms the initial descriptions before computing subsumption. The problem is that the users are often confused since they do not understand the connection between their initial descriptions and the results given by the system, or how the system has obtained these results. It has been proven many times in practice that a lot of results are unexpected by users 14 : subsumption computation is a "black box". Thanks to a correspondence between CGs and DLs, graph operations, which are intuitive, easily comprehensible and readable, may be used in DLs to explain step by step the subsumption computation.
References 1. B. Bi~bow and G. Chaty. A comparison between conceptual graphs and KL-ONE. In ICCS'93, First International Conference on Conceptual Structures, L N A I 699, pages 75-89. Springer-Verlag, Berfin, Quebec, Canada, 1993. 2. R.J. Brachman, D.L. McGuiness, P.F. Patel-Schneider, L.A. Resnick, and A. Borgida. Living with CLASSIC: When and how to use a KL-ONE-like language. In J. Sown, editor, Principles of Semantic Networks, pages 401-456. Morgan Kaufmann, San Mateo, Cal., 1991. 3. R.J. Brachman and J.G. Schmolze. An overview of the KL-ONE knowledge representation system. Cognitive Science, 9(2):171-216, 1985. 4. B. Carbonneill and O. Haemmerl~. Standardizing and interfacing relational database using conceptual graphs. In ICCS'94, Second International Conference on Conceptual Structures, L N A I 835, pages 311-330. Springer-Verlag, Berlin, Maryland, USA, 1994. 5. M. Chein. The CORALI project: from conceptual graphs to conceptual graphs via labelled graphs. In ICCS'97, Fifth International Conference on Conceptual Structures, L N A I 1257, pages 65-79. Springer-Verlag, Berlin, Seattle, USA, 1997. 6. M. Chein and M. Lecl~re. A cooperative program for the construction of a concept type lattice. In supplement proceedings of ICCS'94, Second International Conference on Conceptual Structures, pages 16-30. Maryland, USA, 1994. 7. M. Chein and M.L. Mugnier. Conceptual graphs: Fundamental notions. Revue d 'Intelligence Artificielle, 6(4):365-406, 1992. 8. M. Chein and M.L. Mugnier. Representer des connaissances et raisonner avec des graphes. Revue d'Intelligence Artificielle, 10(1):7-56, 1996. 9. P. Coupey and C. Fouquer~. Extending conceptual definitions with default knowledge. Computational Intelligence Journal, 13(2):258-299, 1997. 10. R. Dionne, E. Mays, and F.J. Oles. The equivalence of model-theoretic and structural subsumption description logics. n 13th International Joint Conference on Artificial Intelligence, pages 710-716, Chamb~ry, France, 1993.
178
11. C. Faron and J.G. Ganascia. Representation of defaults and exceptions in conceptual graphs formalism. In ICCS'97, Fifth International Conference on Conceptual Structures, LNAI1257, pages 153-167. Springer-Verlag, Berlin, Seattle, USA, 1997. 12. M. LeclSre. Les connaissances du niveau terminologique du rnod~le des graphes conceptuels : construction et exploitation. University thesis, Universit6 de Montpellier 2, France, 1995. 13. M. Lecl~re. Reasonning with type definitions. In ICCS'97, Fith International Conference on Conceptual Structures, LNA11257, pages 401-415. Springer-Verlag, Berlin, Seattle, USA, 1997. 14. D.L. McGuinness and A.T. Borgida. Explaining subsumption in description logics. In 14th International Joint Conference on Artificial Intelligence, pages 816-821, Montreal, Canada, 1995. 15. M.L. Mugnier. On generalization/specialization for conceptual graphs. Journal of Experimental ~A Theoretical Artificial Intelligence, 7(3):325-344, 1995. 16. M.L. Mugnier and M. Chein. Characterization and algorithmic recognition of canonical conceptual graphs. In ICCS'93, First International Conference on Conceptual Structures, L N A I 699, pages 294-311. Springer-Verlag, Berlin, Quebec, Canada, 1993. 17. B. Nebel. Reasoning and Revision in Hybrid Representation Systems. Number 422 in Lecture Notes in Computer Science. Springer-Verlag, 1990. 18. A. Schaerf. Query Answering in Concept-Based Knowledge Representation Systems: Algorithms, Complexity and Semantics Issues. PhD thesis, Universit~ di Roma "La Sapienza", Roma, Italy, 1994. 19. K. Schild. A correspondence theory for terminological logics: Preliminary report. In 12th International Joint Conference on Artificial Intelligence, pages 466-471, Sydney, Australia, 1991. 20. J.G. Schmolze. Terminological knowledge representation systems supporting nary terms. In J.G. Schmolze, editor, Principles of Knowledge Representation and Reasoning: 1st International Conference, pages 432-443. Toronto, Ont., 1989. 21. J.F. Sown. Conceptual Structures : Information Processing in Mind and Machine. Addison-Wesley, Reading, Massachusetts, 1984.
Piece Resolution: Towards Larger Perspectives St~phane Coulondre and Eric Salvat L.I.R.M.M. (U.M.R. 9928 Universit~ Montpellier II / C.N.R.S.) 161 rue Ada, 34392 Montpellier cedex 5 - France e-maih {coulondre,salvat ) ~lirmm.fr
A b s t r a c t . This paper focuses on two aspects of piece resolution in backward chaining for conceptual graph rules 13. First, as conceptual graphs admit a first-order logic interpretation, inferences can be proven by classical theorem provers. Nevertheless, they do not use the notion of piece, which is a graph notion. So we define piece resolution over a class of first-order logical formulae: the logical rules. An implementation of this procedure has been done, and we compare the results with the classical SLD-resolution (i.e. Prolog). We point out several interesting results: it appears that the number of backtracks is strongly reduced. Second, we point out the similarities between these rules and database data dependencies. The implication problem for dependencies is to decide whether a given dependency is logically implied by a given set of dependencies. A proof procedure for the implication problem, called "chase", was already studied. The chase is a bottom-up procedure: from hypothesis to conclusion. This paper introduces a new proof procedure which is topdown: from conclusion to hypothesis. Indeed, we show that the implication problem for dependencies can be reduced to the existence of a piece resolution.
1
Introduction
This p a p e r focuses on two aspects of piece resolution in backward chaining for conceptual graph rules. This procedure has been originally presented in 13. It is summarized in section 2. As conceptual graphs admit a first-order logic interpretation, inferences can be proven by classical theorem provers. Nevertheless, we point out t h a t the clausal form of logic prevent from using the notion of piece. So we define in section 3 piece resolution over a class of first-order logical formulae: the logical rules. We made an implementation of this procedure, and we compare in section 4 the results with those of the classical SLD-resolution (i.e. Prolog), on the same benchmarks. We show several interesting results: it appears t h a t the number of backtracks is strongly reduced. Second, we point out in section 5 the similarities between logical rules and d a t a dependencies. D a t a dependencies are well-known in the context of relational database. They specify constraints t h a t the d a t a must satisfy to model correctly the part of the world under consideration. The implication problem for dependencies is to decide whether a given dependency is logically implied by a given set of dependencies. A proof procedure for the implication problem, called "chase" was already studied in 2, in
180
the case of tuple-generating and equality-generating dependencies. This class of dependencies generalizes most cases of interest, including the well-known functional and multivalued dependencies. The chase is a bottom-up procedure: from hypotheses to conclusion. This paper introduces a new proof procedure which is top-down: from conclusion to hypothesis. To do that, we use the logical rules and showJthat the problem for implication for dependencies can be reduced to the existence of a piece resolution. We end this paper with several concluding remarks pointing out some possible generalizations of our results and further work.
2
Piece
resolution
within
conceptual
graphs
This section summarizes backward chaining of conceptual graph rules by way of graph operations. The framework we consider here is composed of simple conceptual graphs (non-nested), without negation. They are not necessary connected.
2.1
T h e rules
Rules are of the type "If G1 then G2", where G1 and G2 are conceptual graphs with possible coreference links between some concept vertices of G1 and G2. A coreference link indicates that two vertices denote the same individual. In other words, 9 associates to these vertices the same variable or constant. A rule is denoted R : G1 ~ G 2 , where G1 and G2 are called the hypothesis and the conclusion of R. A useful notation is that of lambda-abstraction. A lambdaabstraction JkXl...x=G, with n > 0, is composed of a graph G and n special generic vertices of G.
Definition 1 (Conceptual g r a p h r u l e 13). A conceptual graph rule R : G1 ~ G2 is a couple of lambda-abstractions (XXl...XnGl,XXl...xnG2). Xl, ...,xn are called connection points. In the following, we will denote by x~ (resp. x 2) the vertex xi of G1 (resp. G2). For each i e 1..n, x~ and x~ are coreferent.
R:
~ G2 of co: *y
*Y 1 2
1
2
Fig. 1. A CG rule.
1
181
The rule in figure 1 informally means the following: "If an employee z is in an office y managed by a manager x, then z has got a desk which is inside the office y, and x employs z". 2.2
Logical interpretation o f a rule
associates to every lambda-abstraction Axl...x,~G a first-order formula, where all the variables are existentially quantified, except variables of xl...xn which are free. Let R : G1 ~ G2 be a CG rule, if --+ is the logical implication connector, then k~(R) = (~(A(xl ...xn)G1)) --~ (~(:k(xl ...xn)V2)). To every couple of vertices x i1 and x 2 is associated the same variable. 4~(R) is the universal closure of ~(R): 9 (R) = VXl...Vxn~(R). For example, consider the rule R of figure 1, ~(R) = VxVyVz(3w( Manager(x) A Manage(w) A O f f i c e ( y ) A Employee(z) A agt(x, w) A obj (w, y) A loc( z, y ) ) --~ (3u3vO f f ice(y ) A Desk(u ) A Employee( z ) A Employ(v) A Manager(x) A loc(u, y) A poss(z, u) A obj(v, z) A agt(x, v) ). A knowledge base is composed of a support S, a set of CGs (facts), and a set of rules.
2.3
Piece resolution procedure
Consider a goal Q to be proven. The piece resolution procedure allows us to determine, given a knowledge base K B , whether ~ ( B K ) ~ ~(Q). The basic operation of the piece resolution is the piece unification which, given a goal Q and a rule, builds, if possible, a new goal Q' to be proven such that if Q~ is proven on K B , then Q is proven on K B .
Definition 2 (Piece and cut points 13). Let R : G1 ~ G2 be a rule. A cut point of G2 is either a connection point (i.e. a generic concept shared with G1) or a concept with an individual marker (which may be common with G1 or not). A cut point of G1 is either a connection point of G1 or a concept with an individual marker which is common with G2. The pieces of G2 are obtained as follows: remove from G2 all cut points; one obtains a set of connected components; some of them are not CGs since some edges have lost an extremity. Complete each incomplete edge with a concept with same label as the former cut point. Each connected component is a piece. Equivalently, two vertices of G2 belong to the same piece if and only if there exists a path from one vertex to the other that does not go through a cut point. In figure 1, G2 has two pieces. The first one includes all vertices from y to z and the second one includes all vertices from z to x. Indeed, x, y and z are cut points, and G2 is split at z vertex. Instead of splitting the goal in subgoals to be treated separately 7 8, as also for Prolog 5 for first-order logic, piece resolution processes as much as possible the graph as a whole. For example, the request Q' of figure 2 can unify with the rule of figure 1. Indeed, we can unify the subgraph of Q containing the vertices from Manager
182
Q: t.an.,o,:Tom
Emp,o,
:.
Fig. 2. A request Manager
~
: Tom
1
agt
2
Manage
l
obj
2
Office : *
Employee: *
Fig. 3. A new request built by unification of the request and the rule
to Employee with the piece of G2 from the concept vertex with the marker x to the concept vertex with the marker z. We obtain a new request Q~. A piece resolution is a sequence of piece unifications. It ends successfully if the last produced goal is the empty graph. It needs the definition of a tree exploration strategy (breadth-first or depth-first search like in Prolog for example). For more details on piece resolution, we refer the reader to 13 12. The piece resolution procedure is j clearly a top-down (or backward chaining) procedure. Indeed, rules are applied to a conclusion (the goal is actually a rule with an empty hypothesis), thus generating new goals to be proven. This is done until we obtain the empty graph. Thus the procedure uses here the goal to guide the process.
Theorem 1 (Soundness and completeness of piece resolution 13). Let K B be a knowledge base and Q be a CG request. Then: - If a piece resolution of Q on K B ends successfully, then ~ ( K B ) ~ ~(Q). If ~ ( K B ) ~ ~(Q), then there is a piece resolution of Q on K B that ends successfully. -
3
Piece
resolution within first-order logic
Resolution in backward chaining for conceptual graph rules has been defined in section 2. This mechanism is sound and complete relative to the deduction in first-order logic. The underlying idea is to determine subgraphs as large as possible, that can be processed as a whole. As already mentioned, conceptual graph rules can be expressed as first-order sentences. Therefore it may be legitimate to express graph resolution using first-order formulae. This will lead us to a new kind of resolution called Piece Resolution. A unification between a goal graph and a graph rule produces a new request which is also a conceptual graph. This new goal can be expressed as a first-order logic sentence, and can also contain existential quantifiers. Now, classical proof procedures for first-order logic generally use clausal form 10 or specific forms, obtained in every case by taking out
183
existential quantifiers. This is called Skolemisation 3. This process modifies the knowledge base, thus further inferences do not use the original one. On the contrary, graph resolution uses the original base and allows existential quantifiers to take part of the proof mechanism (in the associated logical interpretation of rules) by using graphs structure. The inference is thus more "natural". Moreover, we will see that graph resolution provides ways to improve effectiveness theoretically speaking as well as practically. We will now clarify the idea of piece in first-order logic. 3.1
Pieces
D e f i n i t i o n 3 (Logical rule). A logical rule is a formula of the form F = 3xl...3xs(A1 A ... A Ap) ~- B1 A ... A Bn, p > 1, universally closed. There are no functional symbols. We will omit universal quantifiers for sake of readability. The hypothesis of F, /~{B~li E 1..n} is denoted by hyp(F), and the conclusion of F, 3xl...3x, A { A d i 9 1..p} is denoted by conc(F). Each A~,i 9 1..p and each Bi, i 9 1..n is an atom and x~, i 9 1..s are variables appearing only in A i , i 9 1..p. All other variables in A i , i 9 1..p also appear in the hypothesis and are universally quantified. If n = O, F is also called a logical fact. When we want to know if a logical fact is logically implied by a set of logical rules, we talk about logical goal.
Example 1 (Logical rule). Consider the following logical rule: R = 3u(ta(u) A r4(x,u)) +-- tl(x) A tl(y) A r l ( x , y ) . We have hyp(R) = tl(x) A tl(y) A r l ( x , y ) and conc(R) = 3u(t4(u) A ra(x, u) ). Remark 1. If s = 0, then F is equivalent to a set of horn clauses {Ai +-- B1 A ... ^ B n , i e 1..p} D e f i n i t i o n 4 (Piece). Let C = A1 A ... A Ap be a conjunction of atoms and V = {Xl, ...,xs} be a set of variables. Pieces of C in relation to V are defined in the following way: for all atoms A and A' members of {A1, ..., An}, A and A I belong to the same piece if and only if there is a sequence of atoms (P1, ..., Pro) of {A1, ...,Ap} such that P1 = A and P m = A' and Vi = 1 , . . . , m - 1, Pi and Pi+l share at least one variable of V. By construction, the set of pieces is a partition
of C. D e f i n i t i o n 5 (Logical r u l e pieces). Let R=3xl...3x, (A1 A ... A Ap) +-- B1 A ... A Bn be a logical rule. Pieces of R are pieces of conc(R) = A1 A ... A Ap in relation to {xl, ..., xs}.
Example 2. Let R = VxVyVz(Sw(Manager(x) A Manage(w) A O f f i c e ( y ) A Employee(z) A agt(x, w) A obj(w, y) A loc(z, y) ) --~ (3u3vO f fice(y) A Desk(u) A Employee(z) A Employ(v) A Manager(x) A loc(u, y) A BOSS(Z, u) A obj(v, z) A agt(x, v)) be a logical rule. R has five pieces, which are :
184
(Desk(u), loc(u, y),poss(z, u)} which contains atoms that share the existentially quantified variable u, - {Employ(v), obj(v, z), agt(x, v)} which contains atoms that share the existentially quantified variable v, - {Employee(z)}, { M a n a g e r ( x ) } and { O f f i c e ( y ) } which contain atoms where no existentially quantified variable appears, thus giving one atom in each piece. -
D e f i n i t i o n 6 ( P i e c e s p l i t t i n g ) . Let R = 3Xl...3xs(A1A...AAp) +- B1A...ABn be a logical rule, and t be the number of pieces of R. R can be split, giving several logical rules RI, ..., Rt. Each Ri, i E 1..t has the same hypothesis as R, and the piece number i as conclusion. Ri = 3xil...3xisi (Ail A ... A Aip~) +- B1 A ... A Bn, i E 1..t. Pi is the number of atoms in the piece number i, si is the number of existentially quantified variables concerning the piece, and Aij, j E 1..pi are atoms of the piece number i. Each variable not in xij is universally quantified. Construction of R1 A ... A Rt is called piece splitting of R. We will denote in the same way the splitting operation and its result R1 A ... A Rt. Remark 2. Uie1 t(Jje1 p Aij) = Uke1 p Ak. Indeed, the union of atoms in conclusions of new rules is'e~actly the set of atoms in the conclusion of the initial rule. Therefore, an atom belongs to only one piece, thus it can appear in only one of the newly generated rules. Hence )-~ie1 t Pi = P. No atom is created and none is deleted. The set of pieces is a partition of the set of atoms in the conclusion of the initial rule.
P r o p o s i t i o n 1. R is logically equivalent to R1 A ... A Rt. Proof (Sketch). In R, we can group existential quantifiers together in front of concerned atoms sets. Each group of existential quantifiers together with the corresponding set of atoms is by definition a piece. We rewrite the obtained formula by eliminating implication. Then by distributivity of V on A, we obtain as many formulae as pieces, connected by conjunction, each of them having the same hypothesis which is initial logical rule hypothesis. Common variables to these formulae are all universally quantified. As V x ( F A G) and (VxF A VxG) are equivalent, we can decompose R in R1 A ... ARt.
D e f i n i t i o n 7 (Trivial logical r u l e s ) . Let R be a logical rule. R is trivial if and only if every interpretation of R satisfies R (R is valid). Example 3 (Trivial logical rules). The following logical rules are trivial:
t(x) t(x) ^ r(x, y) 3u(t(u)) t(y) 3v(r(x, y, v)) t(z) ^ r(x, y, z) Piece splitting can generate logical trivial rules, therefore useless. It is the case, among others, of rules in which each atom of the conclusion appears also in the hypothesis. Let R1, ...,Ri, ...Rt be the result of piece splitting of R. We showed that R and R1, ..., Ri, ...Rt are logically equivalent. Let Ri be a trivial logical rule. R and R1, ..., Ri-1, Ri+l, ...Rt are logically equivalent. Hence Ri can be deleted.
185
3.2
Basic operations
Definition 8 (Piece unification). Let Q be a logical goal and R be a logical rule. There is a unification between Q and R, say a=, if and only if: 1. there are two substitutions al and a2 defined respectively on a subset of variables of Q and on a subset of universally quantified variables of R. 2. au = alUa2. Pieces of an(Q) are defined as pieces of conc(au(Q) ) in relation to the set of existentially quantified variables of an(R). There must exist as least one piece of an(Q) appearing entirely in the conclusion of ~ru(R). Once a piece unification a~ has been found, a new request Q' is built from Q. Q' becomes the new logical goal.
Definition 9 ( C o n s t r u c t i o n o f a new logical goal). Let Q be a logical goal, R be a logical rule and au be a piece unifier between Q and R, we obtain the new goal Q~ the following way: 1. Delete from an(Q) pieces that appear in an(R) and add atoms of hyp(au(R) ) 2. Update existential quantifiers an(Q), more specifically: (a) Delete existential quantifiers in an(Q) that were corresponding to deleted existentially quantified variables in au (R). (b) Add existential quantifiers corresponding to variables appearing in atoms of hyp( au (R ) ) added to an(Q) (corresponding to universally quantified variables of an(R)). These steps may need variable renaming, to avoid variable binding phenomena. Indeed, an atom of hyp(au(R)) added to an(Q) must not contain an already quantified variable in a=(Q), because it would be "captured" by a wrong quantifier. Therefore, we must rename common variables to Q and R.
Definition 10 (Logical piece resolution). Logical piece resolution of a logical goal Q is a sequence of piece unifications. It ends successfully if the last produced request is empty. In this case, the last used rule has an empty hypothesis (i.e. a logical fact). Example ~ (Piece unification). Let R be the following logical rule: R = VxVyVz (3w( Manager (x)AManage(w)AO f fice(y)AEmployee(z)Aagt(x, w)Aobj (w, y)A loc(z, y) ) -+ (3u3vO f fiee(y)ADesk(u)AEmployee(z)AEmploy(v)AManager(x)
^ toc(u, y) A poss(z, u) A obj(v, z) ^ agt(x, v)). Let Q be the following request (note that Q and R must not have variables in common): Q -~ 3i3j3kManager(tom) A Employ(i) A Employee(j) A Car(k) A
agt(tom, i) A obj(i, j) A poss(j, k) A unifier is au = {(x, tom), (i, v), (j, z)}. After applying a~, we construct the new goal Q':
Q' = 3w3z3y3k(Manager(tom) A Manage(w) A Office(y) A Employee(z) A agt(tom, w) A obj(w, y) A loc(z, y) A Car(k) A poss(z, k))
186
Remark 3. It is possible to simulate a piece resolution in backward chaining with conceptual graphs by a piece resolution with logical rules, and vice/versa. Thus these problems are equivalent. The first reduction (graphs -+ logic) is trivial. For the second reduction (logic --+ graphs), we need to construct a support and to add concept vertices with universal type for terms that do not appear in predicate of arity one. In the support, each concept type is covered by the universal type and thus two concept types are incomparable. The relation types set is partitioned in subsets of relation types of the same arity where each relation type is covered by the greater element and thus two relation types are incomparable.
3.3
Soundness and completeness of logical piece resolution
L e m m a 1. Let Q be a logical goal and R be a logical rule. If Q' is a new goal built by a piece unification between Q and R, then Q', R ~ Q T h e o r e m 2 (Soundness of logical piece resolution 6). Let 1" be a set of logical rules, and Q be a logical goal. If a logical piece resolution of Q on 1" ends successfully, then 1" ~ Q. Proof (Sketch). The way we build Q' allows us to prove Q', R ~ Q. To prove the theorem, we then proceed by induction on the number of piece unifications.
T h e o r e m 3 (Completeness of logical piece resolution 6). Let F be a set of logical rules, and Q be a logical goal. If 1" ~ Q then there is a logical piece resolution of Q that ends successfully. Proof (Sketch). We first prove by refutation the existence of a piece unification between the logical goal Q and the logical rule R, giving a logical goal Q' (assuming that Q', R ~ Q, but not Q' ~ Q). Secondly, we prove by induction that the implication of a logical goal by a set of logical rules can be "decomposed" in a sequence of logical implications involving the previous goal and only one rule to give the next goal. Then we proceed by induction on the number of piece unifications. 3.4
F r o m fact goals to rule goals
So far, goals were only rules without hypothesis. But it is useful to consider rules as goals. Indeed it would allow to decide whether a rule is logically implied by a set of rules, for example to know if the rule is worth being added to the set. We could also want to compute the minimal cover of a set (that is the minimal set that allows to generate the initial set), or the transitive closure of a set (see section 5).
Definition 11. Let S be a set of logical rules, and R be a logical rule. The operation w, defined on R with respect to S and noted ws(R), replaces every universally quantified variable of R by a new and unique constant (not appearing neither in S nor in R).
187
Let F be a set of logical rules, and R be a logical rule. R is of the form R = 3xl...3x,(A1A ... AAp) e- B1A ... ABn, p >_ 1. Let R' = w r ( R ) . Then F ~ R if and only if F, hyp(R') ~ conc(R').
T h e o r e m 4 (12).
Proof (Sketch). ~ Let I be a model of/~ and hyp(R'). We show that I is also a model of conc(R'). v== We prove t h a t / ~ A -~R is inconsistent. To do that, we show that the set of ground instances of/~ A hyp(R') A -~conc(R') which is inconsistent is included in the set of ground instances of/~ A -~R. The theorem of compactness allows to conclude.
4
Comparison and statistical analysis
In order to estimate how much piece resolution can reduce the resolution tree, we built a logical rules random generator. We present in this section the results of this first series of tests, comparing the number of unitary backtracks, for the same rule base, in the case of piece resolution and SLD-resolution 9 11 (used in Prolog) 1. The rule base is translated into Horn clauses in order to fit with Prolog, whose effect is to multiply the base size. Therefore, the piece resolution algorithm deals with the original base, and Prolog deals with the translated base. To prevent procedures from looping, there is no cycle in the dependency graph of logical rules. We made 3011 tests, varying each parameter (base size, maximal number of atoms in hypothesis and conclusion, ... ). A quick analysis over the results shows that the number of backtracks in piece resolution is always lower than 310,000, whereas it is lower than 5,000,000 for Prolog. The table 4 gives the distribution in details for each method. It shows that piece resolution reduces the number of backtracks. Indeed the number of cases with more than 10.000 backtracks is 73 (2,42%) for piece resolution, whereas it is 279 (9.19%) for Prolog.
x=number of backtracks x < 100 101 < x < 1000 1001 < x < 10000 10001 < x < 100000 100001 < x < 1000000 1000001 < x
Prolog 2047 67,98% 407 13,52% 280 9,30% 153 5,08% 82 2,72% 42 1,39%
Piece resolution 2504 83,16% 294 9,76% 140 4,65% 66 2,19% 7 0,23% 0 0%
Fig. 4. Repartition of tests, according to the number of backtracks. The table 5 gives for the same base the repartition of cases in which piece resolution reduces the number of backtracks (function of number of backtracks 1 We used SWI-Prolog (Copyright (C) 1990 Jan Wielemaker, University of Amsterdam).
188
for Prolog - number of backtracks for piece resolution). The percentage is given relatively to the number of cases t h a t show improvement for piece resolution. x = improvement inumber of cases percentage x < 100 696 47,54% I01<x<1000 290 19,81% 1001 < x < 10000 232 15,85% 10001 < x < 100000 127 8,67% 100001 < x < 1000000 78 5,33% 1000001 < x 41 2,80% Fig. 5. Repartition of tests in which nece resolution is more efficient than Prolog, function of decreasing number of backtracks.
In the same way, the table 6 gives for the same base the repartition of cases in which piece resolution increases the number of backtracks (function of number of backtracks for piece resolution - number of backtracks for Prolog). The percentage is given relatively to the number of cases t h a t show degradation for piece resolution. x = degradation number of cases percentage x ~ I00 228 76,77% 1 0 1 < x < 1000 36 12,12% 1001 < x < 10000 21 7,07% 10001 < x < 100000 10 3,37% 100001 < x 2 0,67% Fig. 6. Repartition of tests in which piece resolution is less efficient than Prolog, function of increasing number of backtracks.
Let us point out the 42 cases where the number of backtracks for Prolog is greater t h a n 1 million (table 4). Moreover, the number of backtracks is decreased by more t h a n 1 million for piece resolution, except in one case (decreasing of 931.850), the m a x i m u m decreasing being 4.878.882. Therefore, even considering the time parameter, a better efficiency is shown by piece resolution in 33 cases out of 42, in spite of a low efficient algorithm. Indeed, we have implemented a "brute force" algorithm t h a t computes every possible unification between the terms of a goal and a rule, keeping only piece unifications. We can certainly decrease execution time by studying more efficient algorithms. One m a y argue t h a t the number of backtracks for piece resolution is lower because a part of the backtracks made by Prolog is moved inside the piece unification operation. Indeed, the decision problem associated with piece unification between two formulae is NP-complete. Several arguments m a y run counter to this allegation. First, practical results show t h a t for 33 out of 42 Prolog difficult cases, piece resolution takes less longer to achieve. Yet its algorithm is very
189
rough. In particular, in 4 cases, piece resolution terminates within 1 second, and in less than 10 backtracks, while Prolog makes between 1,4 and 3,3 million backtracks, in 6,5 and 16 minutes. Thus the backtracks have not been all moved into the unification process. Theoretically speaking, the piece idea keeps intact a part of the formula structure and allows to detect fails sooner. Indeed, substitutions that are not piece unifications are rejected, whereas Prolog will use them to unify and develop its solution tree, and the fail will take place later (not sooner anyway). As stated before, we can improve the piece unification resolution by studying efficient piece unification algorithms, using graph theory or Constraint Satisfaction Problems (CSP) results. Indeed, there is a strong correspondence between a CSP and projection checking on two conceptual graphs 4. In particular, unification has the same complexity as a projection between two graphs. It is polynomial when the corresponding piece has a tree form. 5
An
application
to relational
database
theory
Data dependencies are well-known in the context of relational databases. T h e y aim to formalize constraints that the data must satisfy. A dependency is a statement to the effect that when certain tuples are present in the database, so are certain others, or some values of the first ones are equal. The formalism usually used to define the TGDs and EGDs and to describe the chase procedure is either that of tableaux, or that of first-order logic with identity 2 1. In this paper we use the latter formalism. In this section, we show how dependencies theory can benefit from the logical piece resolution.
5.1
Dependencies
For sake of simplicity, we assume, as in 2, several restrictions on the model. These restrictions can be lifted with minor modifications. We assume the database is under the universal relation assumption (only one relation symbol noted R), distinct attributes have disjoint domains (typed dependencies), that dependencies do not contain constants.
Definition 12 (Tuple-Generating Dependency 1).
A TGD is a firstorder logic sentence of the form Vxl...Vxn~(xl, ..., xn) ~-~ 3Zl...3Zkr (Yl, .-., Ym), where {zl, ...,Zk} = {Yl,...,Ym} -- {Xl, ...,Xn}, where ~ is a conjunction (possibly empty) of atoms of the form R ( w l , ..., wt) (where each wl, ..., wz is a variable) using all the variables xl, ..., xn, and where r is a non empty conjunction of atoms of the form R(wl, ...,wt) (where each wl, ...,wt is a variable), using all the variables zl, ..., Zk. Example 5 (TGD). The following first-order sentence is a TGD: F = VxVyVzVtVuVvVwR(x, y, z, t)AR(x, u, v, w) --+ 3s R(s, y, v, t)AR(s, u, z, w). F means that for every couple of tuples having the same value for the first attribute in the instance of the relation R, there are two other tuples in the instance with values taken from the two latter, and a new value for the first attribute.
190
Definition 13 (Equality-Generating D e p e n d e n c y 1). A n EGO is a firstorder logic sentence of the form Vxl...Vxn~(xl, ..., xn) --~ r xn), where ~o is a conjunction (possibly empty) of atoms of the form R(Wl, ..., wt) (where each Wl, ...,wl is a variable) using all the variables Xl,...,xn, and where ~b is of the form w = w I, (where w and w I are variables of xl, ...,Xn). As dependencies are typed, equality atom involves a pair of variables assigned to the same position. Let A be the attribute associated to this position. Then this EGO is called an A-EGO. As dependencies are typed, we assume that variables in atoms occur only in their assigned positions. Example 6 (EGO). The following first-order sentence is an EGO: G = V x V y V z V t V u V v R ( x , y , z , t ) A R ( u , y , z , v ) --+ (x = u). G means that all couples of tuples that have the same value for the second and third attribute in the instance of the relation R, also have the same value for the first attribute of the instance.
T h e implication p r o b l e m for dependencies and the chase procedure Let D be a set of dependencies, and d be a dependency. The implication problem is to decide whether D ~ d. The chase procedure 2 has been designed to solve the implication problem. We will not describe it in details here. Informally speaking, the chase procedure takes the hypothesis of d and treats it as if it formed a set of tuples, thus replacing variables with symbols. Then it applies repeatedly the dependencies of D, following two distinct rules: a T-rule for a TGD, whose effect is to add tuples to the relation, and a E-rule for an EGD, whose effect is to "identify" two symbols. If we obtain the conclusion of d, then we are done. When d is a TGD, we stop when obtaining the tuples satisfying the conclusion of d. If d is an EGD, we stop when obtaining identification of the two symbols involved in the equality in the conclusion of d. This mechanism has been shown sound and complete in 2. Note that the implication problem for TGDs and EGDs is semi-decidable 14. Thus this procedure may not stop. Nevertheless, some cases have been shown decidable. The chase procedure is clearly a bottom-up (or forward chaining) procedure. Indeed, rules are applied to hypotheses, thus generating some consequences (new tuples or identification of symbols). This is executed until the desired conclusion is obtained. The initial goal (i.e. the conclusion of d) is not used to guide the process. We now show that we can solve the implication problem with the piece resolution method presented in section 3. In other words, we provide a top-down (or backward chaining) procedure, 5.2
From one m o d e l to another
In this section, we reduce the problem of implication for dependencies to the existence of a piece resolution within logical rules. Our model of logical piece resolution does not handle equality. This is not a problem for TGD, which are included in the set of logical rules, but EGO contains equality predicates. We
191
have two ways of dealing with this problem. First, we can add equality treatment to our model formalism, but we want to stay in the scope of the CG piece resolution. Second, we can use some results of 2 to eliminate equality for treatment of the implication problem. T h a t is the solution chosen here.
Suppressing equality in dependencies In this section, we use several results previously shown in 2. Informally, instead of dealing with equality and identifying symbols within an EGD, we can say that they "look the same" within the relation. Expressing the results in the first-order logic formalism, we obtain the following transformation: Let e = Vxl, ...xn(JR ~ (xi = xj)) be an EGD. We associate to e two TGDs el and e2, as follows: el ----- VXl, ...Xn,Yl, ...YI-I(JR A R ( x j , y l , ...,Yl-1) --~ R ( x i , y l , ...,YI-1) e2 = Vxl, ...xmyl, ...yt-l(JR A R(x~,yl, ...,Yz-1) -+ R ( x j , y l , ...,Yl-1) where l is the arity of the only relation R and Yk, k E 1..l - 1 are new variables not appearing in xl, ...xn. Example 7. The 2 TGDs associated with the EGD of example 6 are: F1 VxVyVzVtVuVvVnVrVsR(x, y, z, t)AR(u, y, z, v)AR(u, n, r, s) -+ R(x, n, r, s) F2 = VxVyVzVtVuVvVnVrVsR(x, y, z, t )AR(u, y, z, v)AR(x, n, r, s) -+ R(u, n, r, s) =
In the following, we will denote by D* the set of dependencies D in which every EGD has been replaced by its associated TGDs.
Theorem5 (2).
Let D be a set of TGDs and EGDs, d be a TGD and e be a non trivial A-EGD (i.e. e = Vxl .... x,~(JR -+ (xi = xj)) and i ~ j ) . D ~ d if and only if D* ~ d. D ~ e if and only if D* ~ el and there is a non trivial A-EGD in D.
Reducing the implication problem We now only deal with TGDs. The previous results showed that the implication problem for TGDs and EGDs is reducible to the implication for TGDs. Theorem 6 (6).
Let D be a set of TGDs and EGDs, d be a TGD and e be a non trivial A-EGD. Let w be the operation already presented in definition 11. D ~ d if and only if D*, hyp(wD. (d)) ~ cone(wD. (d)). D ~ e if and only if D*, hyp(wD. (el)) ~ cone(wD.) and there is a non trivial A-EGD in D. Proof. TGDs are included in the set of logical rules. We simply apply theorems 4 and 5.
Theorem 7 (6).
Let D be a set of TGDs and EGDs, d be a TGD, and e be a non trivial A-EGD. D ~ d if and only if there is a logical piece resolution of conc(wD. (d)) on {D*, hyp(wD. (d))} that ends successfully, n ~ e if and only if there is a logical piece resolution of cone(wD. (el)) on { D*, hyp(wn. (el ) ) } that ends successfully and there is a non trivial A-EGD in D.
192
Proof. By theorem 6 and the property of soundness and completeness of logical piece resolution (theorems 2 and 3). D Therefore, we showed that we can apply logical piece resolution in backward chaining to solve the implication problem for TGDs and EGDs. Since this problem is semi-decidable, this procedure may never terminate, as for the chase process. But the advantage is that the inference is guided by the goal. We hope to develop some heuristics to help exploration of the solutions tree. 6
Conclusion
In this paper we presented in three points the contributions of the piece resolution mechanism. The underlying idea was to adapt a graph notion to first-order logic. This resolution method has been originally defined on conceptual graph rules 13. The central notion is that of a piece, that allows to unify subgraphs at once instead of splitting graphs into trivial subgraphs (restricted to a relation and its neighbors). In section 3, we translated the piece notion, which comes from graph theory, into first-order logic. As for conceptual graph rules, the piece resolution method is sound and complete on the set of FOL formulae defined by logical rules. In section 4, we compared SLD-resolution and logical piece resolution, considering the number of backtracks of each method. This comparison shows that pieces can considerably reduce the number of backtracks. We must keep in mind, nevertheless, that the unification in Prolog is polynomial, whereas the decision problem of piece unification between two formulae is NP-complete. The efficiency of the whole piece resolution mechanism depends on the unification, which is the central operation. Thus, an algorithmic study of the unification shall improve the whole procedure. Then, in section 5, we pointed out the similarities between logical rules and data dependencies and we presented a new proof procedure for the implication problem of dependencies, issued from the piece resolution on logical rules. This procedure is top-down. We assumed several restrictions on the model. As already stated, these restrictions can be lifted with minor modifications. The logical rules model can deal with several predicates, thus lifting the universal relation assumption. It can also handle non-disjoint domains, thus unsorted (untyped) dependencies, and constants. That is, we can express a constraint like "Employee #23 can have only one desk". Our theorems still work in these cases, provided that the reduction of EGDs to TGDs also works in the unrestricted model, which is stated in 2. We think this procedure comes to fill a gap in the data dependencies processing.
Acknowledgments We are grateful to M. C. Rousset for showing us the similarity between FOL formulae associated to CG rules and TGDs, to M. L. Mugnier who read the manuscript very carefully, and to M. Y. Vardi for his useful additional information.
193
References 1. S. Abiteboul, R. Hull, and V. Vianu. Foundations of Databases. Addison-Wesley, Reading, Mass., 1995. 2. Catriel Beeri and Moshe Y. Vardi. A proof procedure for data dependencies. Journal of the ACM, 31(4):718-741, October 1984. 3. Chin-Liang Chang and Richard Char-Tung Lee. Symbolic Logic and Mechanical Theorem Proving. Academic Press, New York, 1973. 4. M. Chein and M.-L. Mugnier. Reprdsenter des connaissances et raisonner avec des graphes. Revue d'Intelligence Artificielle, 10(1):7-56, 1996. 5. Alain Colmerauer. Prolog in 10 figures. Communications of the ACM, 28(12):12961310, December 1985. 6. St~phane Coulondre. Exploitation de la notion de piece des r~gles de graphes conceptuels en programmation logique et en bases de donn~es. Master's thesis, Universit~ Montpellier II, 1997. 7. Jean Fargues, Marie-Claude Landau, Anne Dugourd, and Laurent Catach. Conceptual graphs for semantics and knowledge processing. IBM Journal of Research and Development, 30(1):70-79, January 1986. 8. Bikash Chandra Ghosh and V. Wuwongse. A direct proof procedure for definite conceptual graph programs. Lecture Notes in Computer Science, 954, 1995. 9. R. A. Kowalski. Predicate logic as a programming language. Proc. IFIP 4, pages 569-574, 1974. 10. J. W. Lloyd. Foundations of Logic Programming, Second Edition. Springer-Verlag, 1987. 11. Donald W. Loveland. A simplified format for the model elimination procedure. Journal of the ACM, 16(3):233-248, July 1969. 12. Eric Salvat. Raisonner avee des opdrations de graphes : graphes eonceptuels et r~gles d'infgrence. PhD thesis, Universit~ Montpellier II, Montpellier, France, December 1997. 13. Eric Salvat and Marie-Lanre Mugnier. Sound and complete forward and backward chainings of graph rules. In Proceedings of the Fourth International Conference on Conceptual Structures (ICCS-96), volume 1115 of LNAI, pages 248-262, Berlin, August19-22 1996. Springer. 14. Moshe Y. Vardi. The implication and finite implication problems for typed template dependencies. Journal of Computer and System Sciences, 28(1):3-28, February 1984.
Triadic Concept Graphs Rudolf Wille Technische Universit~it Darmstadt, Fachbereich Mathematik SchloBgartenstr. 7, D-64289 Darmstadt, [email protected] Abstract. In the paper "Conceptual Graphs and Formal Concept Analysis,, the author has presented a first attempt in unifying the Theory of Conceptual Graphs and Formal Concept Analysis. This context-based approach, which is philosophically supported by Peirce's pragmatic epistemology, is grounded on families of related formal contexts whose formal concepts allow a mathematical representation of the concepts and relations of conceptual graphs. Such representation of a conceptual graph is called a "concept graph" of the context family from which it is derived. In this paper the theory of concept graphs is extended to allow a mathematical representation of nested conceptual graphs by "triadic concept graphs". As in the preceding paper, our focuss lies on the mathematical structure theory, which later could be used for extending the already developed logical theory of simple concept graphs. The overall aim of this research is to contribute to the development of a contextual logic as basis of Conceptual Knowledge Processing.
1
Contextual Logic
"Contextual Logic" is understood as a m a t h e m a t i z a t i o n of traditional philosophical logic which is based on "the three essential main functions of thinking - concept, judgment and conclusion" Ka88; p. 6. For mathematizing the doctrine of concepts we offer Formal Concept Analysis GW96 which formalizes concepts on the basis of formal contexts. For mathematizing the doctrine of judgments and conclusions we use the Theory o/ Conceptual Graphs So84,So98. Conceptual Logic shall be primarily developed as basis of Conceptual Knowledge Processing as discussed in Wi94. First ideas toward a contextual logic have been presented in the p a p e r "Restructuring m a t h e m a t i c a l logic: an approach based on Peirce's p r a g m a t i s m " Wi96a which proposes Formal Concept Analysis for establishing more connections between the logic-mathematical theory and reality. In the p a p e r "Conceptual Graphs and Formal Concept Analysis" Wi97b a first a t t e m p t is m a d e in unifying Formal Concept Analysis and the Theory of Conceptual Graphs for the foundation of a contextual logic. This context-based approach, which is philosophically supported by Peirce's pragmatic epistemology, is grounded on families of related formal contexts whose formal concepts allow a m a t h e m a t i c a l representation of the concepts and relations of conceptual graphs. Such representation of a conceptual graph is called a "concept graph" of the context family from which it is derived.
195
While the approach to concept graphs in Wi97b concentrates on the foundation of a mathematical structure theory, the paper "Simple concept graphs: a logic approach" Pr98b presents a logical theory of concept graphs, whose syntax defines concept graphs as syntactical constructs over an alphabet of object names, concept names, and relation names and whose semantics adapt the mathematical structure theory of Wi97b for the interpretation of those syntactical constructs (see also Pr98a). Up to now, the developed theory only allows to mathematically represent conceptual graphs without nesting. Therefore the theory should be extended so that nested conceptual graphs could be treated within Contextual Logic too. In this paper we approach such an extended theory of concept graphs by using Triadic Concept Analysis (see LW95). Again, our focuss lies on founding the mathematical structure theory, which later could be used for extending the logical theory of concept graphs. In Section 2 we discuss through triadic contexts of tonal music how subdivisions of concept graphs can be described using triadic concepts. This discussion motivates the foundation of a theory of "triadic concept graphs" in Section 3. In Section 4, we explain how positive nested conceptual graphs can be mathematically represented by triadic concept graphs. Finally, in Section 5, we sketch ideas of further research toward a comprehensive foundation of Contextual Logic. 2
Triadic Contexts
of Tonal Music
The discussion of concept graphs in music theory, offered in this section, shall provide us with an alternative view of the potential application of concept graphs, which especially suggests to allow not only nestings, but also subdivisions with overlappings. Concept graphs can be used to represent the harrmonic analysis of chord sequences. For example, the sequence of major triads C
-
F
-
G
-
D
-
E
-
A
is analysed in He49; p. 38 as a diatonic modulation from c major to a major via d major which can be represented by the concept graph visualized in Figure 1: Each small box represents the concept of a chroma and each disc represents the concept of a major triad which is understood as a ternary relation between tones of specific chroma; the functional meaning of a major triad is determined by the containment of its disc in the large boxes which represent major keys, respectively. As in the given example, objects and relationships might have different meanings in different surroundings. Therefore we propose a triadic approach for the extended theory of concept graphs which allows to represent mathematically the different meanings of the considered relationships. To keep this paper (as much as possible) selfcontained, we recall the basic notions of ~iadic Concept Analysis from Wi95 and LW95. A triadic context is defined as a quadruple (G, M, B, Y) where G, M, and B are sets and Y is a ternary relation between G, M, and B, i.e. Y C_ G x M x B; the elements of G, M, and B are called (formal) objects,
196
~- ................................................
! ;
key"
i- .......................
c major
! ' i i
i !
; i i i
2
i
1
3
L ....... !
"
; i
!
;
i i i
i i i "
~ ~
i i
'
i
;
i
i
i ,
i i 1 ,
i i i
i !
! !
i i
! !
1
3 ,
,'7
,
i i
"._. . . . . . . . . . . . . . . . . . . . . . .
-
-
. . . . . . . . . . . . . . . . . . . . . . . key:
i i i 9
2
i
~"
a major
2
1
3
i
i i i 9
i
i
;
i
,
i ! 3
,3
,
1
, i i
",i .......... ;-22 ............... 3!................................................... i
a .......................................
i
Fig. 1. Harmonic analysis of a diatonic modulation
attributes, and modalities, respectively, and (g, m, b) E Y is read: the object g has the attribute m in the modality b. Formal objects, attributes, and modalities may formalize entities in a wide range, but in the triadic context they are understood in the role of the corresponding Peircean category. In particular, the formal modalities as abstract instances of the third category may formalize relations, mediations, representations, interpretations, evidences, evaluations, modalities, meanings, reasons, purposes, conditions etc. If real data are described by a triadic context, the names of the formal objects, attributes, and modalities yield the elementary bridges to reality which are basic for interpretations (cf. Wi92). A triadic concept of a triadic context (G, M, B, Y) is defined as a triple (A1, A2, A3) with A1 C_G, A2 C M, and A3 C_ B such that the triple (A1, A2, A3) is maximal with respect to component-wise set inclusion in satisfying A1 x A2 x A3 C Y, i.e., for XI _C G, X2 C_ M, and X3 C_ B with X1 x X2 x X3 C_ Y, the containments A1 C_ X1, A2 C_ X2, and A3 C_ X3 always imply ( A 1 , A 2 , A 3 ) = (X1, X2, X3). If (G, M, B, Y) is described by a three-dimensional cross table, this means that, under suitable permutations of rows, columns, and layers of the cross table, the triadic concept ( A 1 , A 2 , A 3 ) is represented by a maximal rectangular box full of crosses. For a particular triadic concept r :-- (A1, A2, A3), the components A1, A2, and A3 are called the extent, the intent, and the modus of c, respectively; they are also denoted by E x t ( c ) , Int(c), and Mod(c). For the description of derivation operators, it is convenient to denote the underlying triadic context alternatively by N : - ( g l , g2, g3, Y). For { i , j , k} = {1, 2, 3} with j < k and for X C_ K i and Z C_ Kj x Kk, the (i)-derivation operators are defined by X ~-~ X (i) := { ( a j , a k ) E K j x K k I a i , a j , a k are related by Y for all ai E X}, Z ~-+ Z (0 := {ai E K i I ai, a j , a k are related by Y for all (aj,a~) 9 Z}.
It can be easily seen that a triple ( A l f A 2 , A a ) with Ai C Ki for i = 1,2,3 is a triadic concept of IK if and only if A~ = (Aj x Ak)(~) for { i , j , k } = {1,2,3} with j < k. The set ~(K) of all triadic concepts of the triadic context K :=
197
(K1,K2, K3, Y) is structured by set inclusion considered in each of the three components of the triadic concepts. For each i E {1, 2, 3}, one obtains a quasiorder
(A1,A2,A3) <~ (B1,B2,Ba) :r (A1,A2,A3) "~i (B1,B2,B3) :r
A~ C_ Bi A~ = Bi
and (i = 1,2,3).
The relational structure ~(IK) := (~(K), <1, <2, <3) is called the concept trilatrice of the triadic context K. As contextual and conceptual basis for concept graphs we define a power context family of triadic contexts by K :-- (K1,..., Kn) (n _> 2) with IKk := (Gk,Mk,B, Yk) (k = 1,... ,n) such that Gk C_ (G1) k. How specific contextual logics may be grounded on such power context families shall be demonstrated by a mathematical model for tuning logics of tonal music. Since 1980 the computer organ MUTABOR has been developed within the research project on "Mathematical Music Theory" at Darmstadt University of Technology (see GHW85,MW88,ARW92,Wi97a). The special feature of MUTABOR is its realtime-computing of pitches for the keys which is performed immediately after a key is touched. This allows to play on a regular keyboard with arbitrary pitches of the continuum of audible frequencies in almost arbitrary combinations. The computation of pitches is performed by specific computer programs called "tuning logics". A challenging problem is to design tuning logics which allow to play music on MUTABOR in just intonation. For solving this problem, mathematical models of tone systems for just intonation are needed. The most common system for this purpose is the Harmonic Tone System which is generated by the intervals octave (2 : 1), perfect fifth (3 : 2), and perfect third (5 : 4). An unbounded mathematical model of the Harmonic Tone System is given by the integer set T :-- {2P3q5r I P, q, r E Z} where Z is the set of all integers (cf. WiS0). As we have already seen by our preceding example of a diatonic modulation, a harmonic analysis (necessary for treating the tuning problem) is of triadic nature. Therefore we build from the integer set T a power context family of triadic contexts (Gk,Mk,B,Yk) (k = 1 , . . . , 12) by defining Gk := T k, M1 as the set of all keys, octave ranges, tone letters and chromas (with indices for syntonic commas), Mk as the set of all k-ary harmonies, chordal and harmonic forms, and B as the set of all tonalities, major and minor keys (for precise mathematical definitions of all those musical notions and of the relations Yk we refer to Wi76,Wi80,NW90). The musicologist M. Vogel has proposed a tuning logic for just intonation (see Vo75, pp. 343-345) which has been implemented on MUTABOR by using the triadic mathematization of the Harmonic Tone System underlying the described power context family. In discussing Vogel's tuning logic through an example concerned with the so-called Problem of the Harmony of Second Degree, we demonstrate the use of concept graphs derivable from the power context family of the Harmonic Tone System. Figure 2 shows above a concept graph representing a sequence of major and minor triads whose tone concepts are described by MIDI numbers of keys.
198
2
2
3
2
3
1 1 ~
2 2 1
55
2 2
3
11 ~ f ~
22
2
l
3
g
tonality: f
2
3
1
-1
tonality: a
-1
ton~ity:c
F i g . 2. A sequence of major and minor chords transformed into just intonation
199
/ :
<
( li
/
-(i Fig. 3. The chord sequence of Figure 2 represented in Euler's speculum musicum
The question is: which pitches should MUTABOR compute for those keys? The concept graph in the middle of Figure 2 yields a partial answer to this question in showing chroma concepts instead of the key concepts (e.g. the keys 60, 52, and 55 of the c major triad are replaced by the general chromas c, e, and g, respectively; notice that the keys 52 and 55 are in the range of the small octave and that the key 60 is in the range of the one-line octave). Figure 2 shows below a subdivided concept graph with precise chroma letters of the Harmonic Tone Sytem which, together with the octave range, uniquely determine the pitch, respectively. How Vogel's tuning logic reaches those pitches may be understood best with the aid of Euler's "speculum musicum" which graphically represents the chroma system of the Harmonic Tone System (cf. Vo75, p. 102); a detail of the speculum musicum is presented in Figure 3 together with the harmonic analysis of our chord sequence obtained by Vogel's tuning logic. Mathematically, Euler's net represents the numbers 3qY (q, r E Z) where c stands for 3050 and 3q5~ leads to 3q+15~ by one step to the right and to 3qY +1 by one step to the top (3q5~ is the chroma of the tones 2P3q5r with p E Z). Our chord sequence is indicated in Figure 3 by the hatched triangles from right to left. The hexagon on the right represents the tonality c which comprises all chromas contained in this hexagon. The other similar hexagons represent the tonalities f , a -1, g - l , and c -1. The key idea of Vogel's tuning logic is to determine the pitch of a touched chord by the (eventually new) tonality which has the same denotation as the chroma of the reference tone of the touched chord with respect to the actual tonality. For our example, this yields a suprising tonality modulation from c to c -~ via f , a -1, and g-1. It is still an open problem in which circumstances Vogel's solution is adequate and in which not. Viewing a harmonic analysis as a judgment, which can be mathematized by a concept graph, helps in understanding how concept graphs of power context families of triadic contexts should be defined. Of course, the main purpose of such a definition is to allow an adequate mathematization of nested conceptual
200 graphs which are understood as logical abstraction of verbal judgments. But the examples from music show that subdivisions with overlappings should be permitted. To cover such broad understanding of formal judgments, we define in the next section triadic concept graphs as a generalization of the concept graphs introduced in Wi97b. 3
Triadic
Concept
Graphs
For the definition of triadic concept graphs, we first define an abstract concept graph with subdivision as a structure q5 := i V, E, v, C, ~, 0, a) for which
n V k (2 < n E N) so that 1. V and E are sets and v is a mapping of E to Uk=l (V, E , v) can be considered as a directed multi-hypergraph with vertices from Y and edges from E (we define e = k :r v(e) = ( v l , . . . , vk)), 2. C is a set and a is a mapping of V U E to C such that a(el) = a(e2) always implies eli -- e21 (the elements of C may be understood as abstract concepts), 3. 0 is an equivalence relation on V, 4. a is a partial mapping of the vertex set V to the power set of V • C such that, for the partial mappings al and a 2 with hi(w) := (v E V I (v,c) E a(w) for some c e C} and a2(w) := {c e C (v,c) E a(w) for some v E Y} for w E dora(a), we have hi(Y) r 0 ~ a2(Y) and v • (al)'~(v) for all v E Y and rn E N. Abstract concept graphs with subdivision are quite common. Figure 4 (taken from Ka79) shows examples of such graphs (without edges) representing the lexical fields "Gew~isser and "waters". Now, let ~ be a power context family of triadic contexts K1,..., K~ with f~ := (Gk, Mk, B, Yk) (1 < k < n) and let C~ := Uk~_~__T(Kk). Then an abstract concept graph O with subdivision, specified by ~5 := (V,E,v,C,a,O,a), is called a triadic concept graph over the power context family K if
1. C = C ~ , 2. c_
),
3. a(e) E ~ ( I ~ ) for all e e E with lel---- k, 4. a2(w) C_ G1 for all w E dora(a). 5. cl E Ext(c2),c2 E Ext(c3),...,Cm-1 E Ext(cm) for Cl,C2,...,Cm E a2(V) imply cl # Cm.
A realization of such triadic concept graph ~5 over K is defined to be a mapping p of V to the power set of G1 satisfying, for all v E V, w E dam(a), and e E E with v(e) = (vl,... ,Vk), 1. 2. 3. 4.
0 ~ p(v) C_ Ext(~(v)) if v r a l ( ~ ) for all ~ E dam(a), p(vl) x ... x p(vk) C_ Ext(~(e)) if { v l . . . V k } ~ crl(~) for all ~ E dam(a), vlOv2 always implies p(vl ) = p(v2), 0 r p(v) C (Int(~(v)) x Mod(r if (v, c) E a(w),
201
Lexicalfield"Gewaesser"
Tuempel ~
1 F
I 8
Lexical field "water"
.oo, I.l... .voir I ...........
mere
t
pond
III
~_-_-z~z_-_-_-_-_-~zz_-z_-_-_-_-_-_-_-~z_-_-_-z~zzz~z~z~
fiver brook rivulet~
Fig. 4. Abstract concept graphs with subdivision for two lexical fields
5. p(vi) x - - - x p(vk) C (Int(R(e)) x Mod(c))(i) if (vi, c ) , . . . , (vk, c) E a(w),
6. a2(w) C_p(w). The pair ~ := (~, p) is called a realized triadic concept graph of the power context family K or, shortly, a triadic concept graph of K. In discussing the definition of triadic concept graphs, let us first remark that the triadic concept graphs of the power context family K with only one modality and with dora(a) = 0 can be considered as the concept graphs of K as introduced in Wi97b; in this way, triadic concept graphs can be understood as a generalization of (dyadic) concept graphs. The basic idea of triadic concept graphs is to describe the parts of a subdivision by specific triadic concepts which are also elements of the object set G1 and therefore called "general objects". Condition 5 of the definition of triadic concept graphs over a power context family guarantees (under a suitable finite chain condition) that the general objects can be determined inductively. Condition 4 and 5 of the definiton of realizations explicates the idea that the general object c E a2(w) (w E dom(a)) represents the part of the subdivision that is constituted by the vertex set {v E V I (v, r E a(w)}; for
202
a vertex v and an edge e in that part, the extents of a(v) and a(e) are modified to the extents (Int(a(v)) x Mod(c))(1) and (Int(a(e)) x Mod(c))O) to respect the modalities of c, while the intents of a(v) and ~(e) keep the identity of the triadic concepts a(v) and a(e), respectively, through changing modalities. 4
Contextual
Semantics
of Nested
Conceptual
Graphs
In this section we show how a nested conceptual graph can be represented mathematically by a triadic concept graph. As an example we choose the nested conceptual graph discussed in CM97. This conceptual graph (with added individual markers) is shown in Figure 5. To obtain the representing triadic concept graph, we first derive the power context family K := (IK1, K2) which represents the knowledge coded in the nested conceptual graph; K1 := (G1, M1, B, II1) and IN2 := (G2, M2, B, Y2) are described in Figure 6 by cross tables in which columns without crosses are omitted. The names of the formal objects, attributes, and modalities are heading the rows, the columns, and the vertical sections of the tables, respectively. The general objects u, a, b, and c, which represent the large boxes, are triadic concepts of IN1 generated by their corresponding attributes and modalities u, a, b, and c, i.e.
u := ({Peter, #1, a}, {u}, {u}),
. := ({#2, b}, {a}, {~}), b : : ({#3, #4, c}, {b}, {b}), c := ({#4, #5, #6, #7, #S}, {c}, {c}).
The concepts and the binary relations of the nested conceptual graphs are represented by triadic concepts of IK1 and K2 according to the following list: Person Think Painting Bucolic Scene Boat Lake Couple Fish Sleep agent object
++ ({Peter,
#5, #7}, {Person}, {u, c}), ({#1}, {Think, u}, {u}), ++ ({a}, {Painting, u}, {u}), +~ ({#2}, {Bucolic, a}, {a}), e+ ({b}, {Scene, a), {a}), ++ ({#3}, {Boat, b}, {b)), ++ ({#4}, {Lake, b, c}, {b, c}), ++ ({c}, {Couple, b}, {b}), ({#6}, {fish, c}, {c}), ({#s}, {Sleep, c}, {e}), ++ ({(#1, Peter), (#6, #5), (#8, #7)}, {agent}, {u, c}), ({(#1, .)}, {object, u}, {u}),
203
attribute 44 ({(b, #2)}, {attribute, a}, {a}), in +4 ({(#3, c), (#6, #4)}, {location, in}, {,c}), on +4 ({(#4, #3)}, {location, on}, {b}), All triadic concepts of IK1 and their triadic relationships can be read off from the triadic diagram of the concept trilattice T(K1 ) depicted in Figure 7; the line diagram on the right, visualizing the containment of the extents, represents the hierarchy of concept types indicated by the conceptual graph in Figure 5 (see LW95,Bi97 for reading conventions of triadic diagrams). The listed triadic concepts form a triadic concept graph over K and the assigment of individual markers to concept types in Figure 5 yields a realization and hence a triadic concept graph of IKwhich mathematically represents the nested conceptual graph of Figure 5. The example makes clear that a triadic approach is necessary if the concept and relations of nested conceptual graphs shall be represented by formal concepts. A dyadic representation is not flexible enough to capture precisely the knowledge coded in a nested conceptual graph. Person: Peter
2
~
Painting: a ~
Bucolic:#~
Scene: b Couple:c IPers~
2
agent
1 Fish'.#6 I in
2 Lake:#4 i
IPerson:#
7
~
f ji
2
l
Fig. 5. Example of a positive nested conceptual graph
204
U
=
b
a
.=
c
.~
IK 1 Peter #1 #2 #3
#4 #5 #6 #7 #8
X •
• •
X
•
X X
X X
X
X
X
X
X
X
X X X X
X XX
U
XX
a
XX
b
XX
C
u
a
b
C
IK 2
(#1, Peter) X X (#1, a ) X X (b , #2) XX (#3, c ) (#4, #3) (#6, #5) X (#6, #4) (#8, #7) X
e~ o
X
XX X
X XX
XX X X
XX
X XXX
X
X
Fig. 6. A power context family derived from the conceptual graph in Figure 5
205
Fig. 7. A triadic diagram of the concept trilattice of K1 in Figure 6
The triadic approach presented in this section can be applied to positive nested conceptual graphs as they are mathematized in CM96 and CM97 by labelled bipartite graphs G := (R, C, E, l) for which R and C are disjoint sets of vertices labelled via l by relation types and concept types, respectively, and E is a set of edges between R and C labelled in such a way that adjacent edges of a vertex of R get the consecutive numbers 1, 2 , . . . ; further labels of a vertex of C may be individual markers and also descriptions of subgraphs of G which can be considered to be nested into that vertex. Clearly, the graph G :-- (R, C, E , l) without its individual markers may be understood as an abstract concept graph ~5 with subdivision. For establishing the power context family K :-- (K1,. 9 9 ItS) with Kk := (Gk,Mk,B, Yk) (k = 1 , . . . , n ) which can be associated with G, we complete the invidual markers of G so that each of its concept nodes carries at least one individual marker; then we build with those markers and with the
206
descriptions of the distinguished subgraphs the set G1 (which will be changed later to the set G1 by replacing the subgraph descriptions by suitable general objects). The subgraph descriptions form the modality set B and shall be also elements of the attribute sets Mk; the other elements of Mk a r e the relation types assigned to a relation vertex with k adjacent concept vertices and, in case of k -- 1, also the assigned concept types. IF1 is then taken as the smallest ternary relation satisfying the following conditions: 1. (g, a, a) E Y1 for all subgraph descriptions a and for all individual markers and subgraph descriptions g assigned within the subgraph described by a, 2. the triadic context K1 := (G1,M1,B, Y1) permits a mapping p of V to the power set of r for a suitably chosen ~ : C --+ fl~(~l ) satisfying the conditions 1. and 4. of the definition of a realization in Section 3. For each subgraph description a, a triadic concept a can be defined by a := ( ( { a } • {a})(1), • • {a})(2), ( ( { a } • {a})(1) • • • starting an inductive procedure from the most inner subgraphs and the triadic context (r B, Y1) and, after each step, replacing in the object set of the actual context a subgraph description by the corresponding triadic concept. Finally we obtain the triadic context K1 :--- (G1, M1, B, Y1) whose object set G1 contains no more subgraph descriptions, but, as general objects, the triadic concepts defined for the subgraph descriptions. The other triadic contexts of the power context family IK may be similarily defined as K1 so that the abstract concept graph q5 can be concretized to a triadic concept graph of ~ which mathematically represents the positive nested conceptual graphs described by the labelled bipartite graph G := (R, C, E, l). 5
Further
Research
The started theory of triadic concept graphs shall be elaborated toward a comprehensive theory of formal judgments and conclusions as essential part of Contextual Logic. This will be performed in two directions: the elaboration of a mathematical structure theory which treats triadic concepts as realizations of abstract concept graphs with subdivision and the development of a logic theory which understands triadic concept graphs within contextual models of a syntactical language. For the mathematical structure theory, a challenging problem is to find suitable structures and representations which combine concept lattices and concept graphs effectively and communicatively. For the logic theory, the first task consists in extending the existing theory for simple concept graphs (see Pr98a,Pr98b) to a theory of syntax and semantics for triadic concept graphs, which adapts the started mathematical structure theory. Then, of course, a main desire is to widen the expressibility of the developed theory in activating larger parts of predicate logic which are still decidable and allow effective algorithms. Also the integration of modal logics should be tackled. Overall, the pragmatic meaning of the theoretical developments has to be continuously reflected and examined on the basis of concrete applications.
207
References 1. V. Abel, P. Reiss, 1~. Wille: MUTABOR II - Ein computergesteuertes Musikinstrument zum Experimentieren mit Stimmungslogiken und MikrotSnen. FB4Preprint Nr. 1513, TU Darmstadt 1992. 2. K. Biedermann: How triadic diagrams represent triadic structures. In: D. Lukose, H. Delugach, M. Keeler, L. Searle, J. Sowa (eds.): Conceptual Structures: Fulfilling Peirce's Dream. Springer, Berlin-Heidelberg-New York 1997, 304-317. 3. M. Chein, M.-L. Mugnier: Representer des connaissances et raisonner avec des graphes. Revue d'intelligence artificelle 101 (1996), 7-56. 4. M. Chein, M.-L. Mugnier: Positive nested conceptual graphs. In: D. Lukose, H. Delugach, M. Keeler, L. Searle, J. Sowa (eds.): Conceptual Structures: Fulfilling Peirce's Dream. Springer, Berlin-Heidelberg-New York 1997, 95-109. 5. B. Ganter, H. Hempel, R. Wille: MUTABOR - Ein rechnergesteuertes Musikinstrument zur Untersuchung von Stimmungen. ACUSTICA 57 (1985), 284-289. 6. B. Ganter, R. Wille: Formale Begriffsanalyse: Mathematische Grundlagen. Springer, Berlin-Heidelberg 1996. (English translation to appear) 7. R. Hernried: Systematische Modulation. de Gruyter, Berlin 1949. 8. I. Kant: Logic. Dover, New York 1988. 9. G. L. Karcher: Kontrastive Untersuchung von Wortfeldern im Deutschen und Englischen. Peter Lang, Frankfurt 1979. 10. F. Lehmann, R. Wille: A triadic approach to formal concept analysis. In: G. Ellis, R. Levinson, W. Rich, J. F. Sowa (eds.): Conceptual Structures: Applications, Implementations and Theory. Springer, Berlin-Heidelberg-New York 1995, 32-43. 11. C. Misch, R. Wille: Eine Programmiersprache fiir MUTABOR. In: F. Richter Heft (ed.): MikrotSne II. Edition Helbing, Innsbruck 1988, 87-94. 12. W. Neumaier, R. Wille: Extensionale Standardsprache der Musiktheorie - eine Schnittstelle zwischen Musik und Informatik. In: H.-P. Hesse (ed.): MikrotSne III. Edition Helbing, Innsbruck 1990, 149-167. 13. S. Prediger: Einfache Begriffsgraphen: Syntax und Semantik. FB4-Preprint Nr. 1962, TU Darmstadt 1998. 14. S. Prediger: Simple concept graphs: a logic approach. FB4-Preprint, TU Darmstadt 1998 (this volume). 15. M. Vogel: Die Lehre von den Tonbeziehungen. Verlag fiir systematische Musikwissenschaft. Bonn-Bad Godesberg 1975. 16. J. F. Sowa: Conceptual structures: information processing in mind and machine. Adison-Wesley, Reading 1984. 17. J. F. Sown: Knowledge representation: logical, philosophical, and computational foundations. PWS Publishing Co., Boston (to appear) 18. R. Wille: Mathematik und Musiktheorie. In: G. Schnitzler (ed.): Musik und Zahl. Verlag f/ir systematische Musikwissenschaft, Bonn-Bad Godesberg 1976, 233-264. 19. R. Wille: Mathematische Sprache in der Musiktheorie. Jahrbuch l)berblicke Mathematik 1980. Bibl. Institut, Mannheim 1980, 167-184. 20. R. Wille: Begriffiiche Datensysteme als Werkzeug der Wissenskommunikation. In: H. H. Zimmermann, H.-D. Luckhardt, A. Schulz (eds.): Mensch und Maschine Informationelle Schnittstellen der Kommunikation. Universit~tsverlag Konstanz, Konstanz 1992, 63-73. 21. R. Wille: Pl~idoyer f/Jr eine philosophische Grundlegung der Begriffiichen Wissensverarbeitung. In: R. Wille, M. Zickwolff (eds.): Begriffiiche Wissensverar-
208
22. 23.
24.
25.
26.
beitung - Grundfragen und Methoden. B.I.-Wissenschaftsverlag, Mannheim 1994, 11-25. 1%. Wille: The basic theorem of triadic concept analysis. Order 12 (1995), 149-158. R. Wille: Restructuring mathematical logic: an approach based on Peirce's pragmatism. In: A. Ursini, P. Agliano (eds.): Logic and Algebra. Marcel Dekker, New York 1996, 267-281. R. Wille: Conceptual structures of multicontexts. In: P. W. Eklund, G. Ellis, G. Mann (eds.): Conceptual Structures: Knowledge Representation as Interlingua. Springer, Berlin-Heidelberg-New York 1996, 23-39. R. Wille: MUTABOR - ein Medium fiir musikalische Erfahrungen. In: M. Warnke, W. Coy, G. C. Tholen (eds.): Hyperkult: Geschichte, Theorie und Kontext digitaler Medien. Stroemfeld Verlag, Basel 1997, 383-391. R. Wille: Conceptual Graphs and Formal Concept Analysis. In: D. Lukose, H. Delugach, M. Keeler, L. Searle, J. Sowa (eds.): Conceptual Structures: Fulfilling Peirce's Dream. Springer, Berlin-Heidelberg-New York 1997, 290-303.
Matching in Description Logics: Preliminary Results Franz Baader1 , Alex Borgida2 , and Deborah L. McGuinness3 1 2
Theoretical Computer Science, RWTH Aachen, 52074 Aachen, Germany [email protected] Dept. of Computer Science, Rutgers University, New Brunswick, NJ, USA [email protected] 3 Information Systems and Services Research, AT&T Labs – Research Florham Park, NJ, USA [email protected]
Abstract. Matching of concepts with variables (concept patterns) is a relatively new operation that has been introduced in the context of concept description languages (description logics), originally to help filter out unimportant aspects of large concepts appearing in industrialstrength knowledge bases. This paper proposes a new approach to performing matching, based on a “concept-centered” normal form, rather than the more standard “structural subsumption” normal form for concepts. As a result, matching can be performed (in polynomial time) using arbitrary concept patterns of the description language F L¬ , thus removing restrictions from previous work. The paper also addresses the question of matching problems with additional “side conditions”, which were motivated by practical experience.
1
Introduction
Knowledge representation systems based on Description Logic Systems (DL systems) can be used to represent the terminological knowledge of an application domain in a structured and formally well-understood way [12,4,11,32,8]. With the help of these languages, the important notions of the domain can be described by concept descriptions, i.e., expressions that are built from atomic concepts (unary predicates) and atomic roles (binary predicates) using the concept constructors provided by the description logic language (DL language) of the system. The atomic concepts and the concept descriptions represent sets of individuals, whereas roles represent binary relations between individuals. For example, using the atomic concept Woman and the atomic role child, the concept of all women having only daughters (i.e., women such that all their children are again women) can be represented by the concept description Woman u ∀child.Woman. DL systems provide their users with various inference capabilities that allow them to deduce implicit knowledge from the explicitly represented knowledge. M.-L. Mugnier and M. Chein (Eds.): ICCS’98, LNAI 1453, pp. 15–34, 1998. c Springer-Verlag Berlin Heidelberg 1998
16
F. Baader, A. Borgida, and D.L. McGuinness
For instance, the subsumption algorithm allows one to determine subconceptsuperconcept relationships: C is subsumed by D (C v D) iff all instances of C are also instances of D, i.e., the first description is always interpreted as a subset of the second description. For example, the concept description Woman obviously subsumes the concept description Woman u ∀child.Woman. With the help of the subsumption algorithm, a newly introduced concept description can automatically be placed at the correct position in the hierarchy of the already existing concept descriptions. Two concept descriptions C, D are equivalent (C ≡ D) iff they subsume each other, i.e., iff they always represent the same set of individuals. For example, the descriptions Woman u ∀child.Woman and (∀child.Woman) u Woman are equivalent since u is interpreted as set intersection, which is obviously commutative. The traditional inference problems for DL systems (like subsumption) are now well-investigated, which means that algorithms are available for solving the subsumption problem and related inference problems in a great variety of DL languages of differing expressive power (see, e.g., [22,31,28,20,1,3,19,13,10,6,2,6,7]). In addition, the computational complexity of these inference problems has been investigated in detail [22,27,29,15,14,17,30,16]. It has turned out, however, that building and maintaining large DL knowledge bases requires support by additional inference capabilities, which have not been considered in the DL literature until very recently. The present paper is concerned with such a new inference service, namely, matching of concept descriptions. Matching of Description Logic concepts was introduced in the Classic system (version 2), under the name of “filtering”, as a technique for specifying which aspects of a concept should be selected for printing or explanation. The need for this facility became apparent when dealing with large knowledge bases, involving concepts whose description spans multiple pages of output: in many cases, such concepts carried details that either were obviously true (e.g., the age of a person is a number) or were intended for some internal function (e.g., graphical display) rather than domain modeling. In either case, both the printing and the explaining of results provided by the more traditional inference services [24,23] required pruning. In projects using Classic, pruning of the description resulted in concepts that were approximately an order of magnitude smaller. In small applications such as [25], this actually saved 3–5 pages of printout; in larger applications such as [33,26] it might save up to 30 pages. This pruning mechanism was first formalized [23] as a purely syntactic match involving terms/concepts with variables, and then given a semantics and a syntactic implementation in [9]. Given a concept pattern D (i.e., a concept description containing variables) and a concept description C without variables, the matching problem introduced in [9] asks for a substitution σ (of the variables by concept descriptions) such that C v σ(D). More precisely, one is interested in a “minimal” solution of the matching problem, i.e., σ should satisfy the property that there does not exist a substitution δ such that C v δ(D) @ σ(D). For example, the minimal matcher of the pattern D := ∀research-interests.X against
Matching in Description Logics: Preliminary Results
17
the description C := ∀pets.Cat u ∀research-interests.AI u ∀hobbies.Gardening assigns AI to the variable X, and thus finds the scientific interests (in this case Artificial Intelligence) described in the concept. (The concept pattern can be thought of as a “format statement”, describing what information is to be displayed (or explained), if the pattern matches successfully against a specific concept. If there is no match, nothing is displayed.) In some cases, this pruning effect can be improved by imposing additional side conditions on the solutions of matching problems. For example, the information that the research interests lie in the area of Artificial Intelligence may not provide interesting information if our knowledge base is concerned only with AI researchers. A side condition stating that the solutions for the variable X must be subsumed by KR would make sure that matching succeeds only if the research interests belong to (a subfield of) Knowledge Representation. Thus, the description C from above no longer matches the pattern D, whereas C 0 := ∀pets.Cat u ∀research-interests.DL u ∀hobbies.Gardening would still yield a solution (provided that DL is defined by a description that is subsumed by KR). In some cases we would like to have a matching process which succeeds only if the variable X is substituted for by a value that is strictly subsumed by some description (or pattern). The utility of such strict side-conditions might be more clearly seen in an example where the concept Person is known to have Number restrictions on the age attribute, and we are interested in seeing the value restriction for age only if it represents some additional (i.e., stricter) constraint. Another point worth noting is that according to the standard Description Logic semantics, every description is subsumed by all concepts of the form ∀R.>, where > denotes the universal concept. Hence the pattern D above (concerning research interests) matches every concept. Side conditions requiring the value substituted for a variable to be strictly subsumed by > prevent such “trivial” matches. Matching algorithms for a DL containing most of the constructs available in Classic are introduced in [23] and [9]. These algorithms are based on the rolecentered normal form1 of concept descriptions usually employed by structural subsumption algorithms. The main drawback of these algorithms is that they cannot treat arbitrary matching problems since they require the concept pattern to be in structural normal form. In [5], Baader and Narendran consider unification of concept descriptions in FL0 , which allows for conjunction (u), value restriction (∀R.C), and the top concept (>). Matching modulo equivalence, i.e., the question whether, for a given pattern D and a description C, there exists a substitution σ such that C ≡ σ(D), 1
We call this normal form “role-centered” since it groups sub-descriptions by role names, whereas the concept-centered normal form used in this paper groups value restrictions by concept names.
18
F. Baader, A. Borgida, and D.L. McGuinness
can be seen as a special case of unification where one of the descriptions (namely C) does not contain variables. Since C v σ(D) iff C ≡ σ(C u D), matching modulo subsumption (as introduced above) is an instance of matching modulo equivalence. The polynomial matching algorithm described in [5] does not impose restrictions on the form of the patterns. However, it is restricted to the small language FL0 . In the present paper, we show that this algorithm can be extended to treat matching in languages allowing for inconsistent concept descriptions, namely FL⊥ , which extends FL0 by the bottom concept (⊥), and FL¬ , which extends FL⊥ by primitive negation (¬A, where A is an atomic concept). In addition, we consider matching under additional conditions on the variable bindings, which also arose in examples in [25,23] and were responsible for about 25% of our space savings in our deployed example. In this paper, we consider two different variants of these “side conditions”: subsumption conditions and strict subsumption conditions. Subsumption conditions are of the form X v E, where X is a variable and E is a pattern (i.e., it may contain variables), and they restrict the matchers to substitutions σ satisfying σ(X) v σ(E). It should be noted that such a side condition is not a matching problem since variables may occur on both sides. We shall see, however, that in many cases matching under subsumption conditions can be reduced in polynomial time to matching without subsumption conditions. In contrast, strict subsumption conditions may increase the complexity of the matching problem. Such conditions are of the form X @ E, where X is a variable and E is a pattern, and they restrict the matchers to substitutions σ satisfying σ(X) v σ(E) and σ(X) 6≡σ(E). We shall show that, even for the small languages FL0 , matching under strict subsumption conditions is NP-hard.
2
Formal preliminaries
In this section, we first introduce syntax and semantics of the description languages considered in this paper. Then, we formally introduce matching problems, and state some simple results about matching problems and their solutions. Definition 1. Let C and R be disjoint finite sets representing the set of atomic concepts and the set of atomic roles. The set of all FL¬ -concept descriptions over C and R is inductively defined as follows: – Every element of C is a concept description (atomic concept). – The symbols > (top concept) and ⊥ (bottom concept) are concept descriptions. – If A ∈ C, then ¬A is a concept description (atomic negation). – If C and D are concept descriptions, then C u D is a concept description (concept conjunction). – If C is a concept description and R ∈ R is an atomic role, then ∀R.C is a concept description (value restriction).
Matching in Description Logics: Preliminary Results
19
In the sublanguage FL0 of FL¬ , atomic negation and ⊥ may not be used, whereas in FL⊥ only atomic negation is disallowed. The following definition provides a model-theoretic semantics for FL¬ and its sublanguages: Definition 2. An interpretation I consists of a nonempty set ∆I , the domain of the interpretation, and an interpretation function that assigns to every atomic concept A ∈ C a set AI ⊆ ∆I , and to every atomic role R ∈ R a binary relation RI ⊆ ∆I × ∆I . The interpretation function is extended to complex concept descriptions as follows: >I := ∆I , ⊥I := ∅, (¬A)I := ∆I \ AI , (C u D)I := C I ∩ DI , (∀R.C)I := {d ∈ ∆I | ∀e ∈ ∆I : (d, e) ∈ RI → e ∈ C I }. Based on this semantics, subsumption and equivalence of concept descriptions is defined as follows: Let C and D be FL¬ -concept descriptions. – C is subsumed by D (C v D) iff C I ⊆ DI for all interpretations I. – C is equivalent to D (C ≡ D) iff C I = DI for all interpretations I. – C is strictly subsumed by D (C @ D) iff C v D and C 6≡D. In order to define matching of concept descriptions, we must introduce the notion of a concept pattern and of substitutions operating on patterns. For this purpose, we introduce an additional set of symbols X (concept variables), which is disjoint from C ∪ R. Definition 3. The set of all FL¬ -concept patterns over C, R, and X is inductively defined as follows: – – – –
Every concept variable X ∈ X is a pattern. Every FL¬ -concept description over C and R is a pattern. If C and D are concept patterns, then C u D is a concept pattern. If C is a concept pattern and R ∈ R is an atomic role, then ∀R.C is a concept pattern.
Thus, concept variables can be used like atomic concepts, with the only difference being that atomic negation may not be applied to variables. A substitution σ is a mapping from X into the set of all FL¬ -concept descriptions. This mapping is extended to concept patterns in the obvious way, i.e., – – – –
σ(A) := A and σ(¬A) := ¬A for all A ∈ C, σ(>) := > and σ(⊥) := ⊥, σ(C u D) := σ(C) u σ(D), and σ(∀R.C) := ∀R.σ(C).
20
F. Baader, A. Borgida, and D.L. McGuinness
For example, applying the substitution σ := {X 7→A u ∀R.A, Y 7→B} to the pattern X u Y u ∀R.X yields the description A u (∀R.A) u B u ∀R.(A u ∀R.A). Obviously, the result of applying a substitution to an FL¬ -concept pattern is an FL¬ -concept description.2 An FL0 -substitution maps concept variables to FL0 -concept descriptions. FL⊥ -substitutions are defined analogously. Subsumption can be extended to substitutions as follows. The substitution σ is subsumed by the substitution τ (σ v τ ) iff σ(X) v τ (X) for all variables X ∈ X. Definition 4. An FL¬ -matching problem is of the form C ≡? D where C is an FL¬ -concept description and D is an FL¬ -concept pattern. A solution or matcher of this problem is a substitution σ such that C ≡ σ(D). A subsumption condition in FL¬ is of the form X v? E where X is a concept variable and E is an FL¬ -concept pattern. The substitution σ satisfies this condition iff σ(X) v σ(E). A strict subsumption condition in FL¬ is of the form X @? E where X is a concept variable and E is an FL¬ -concept pattern. The substitution σ satisfies this condition iff σ(X) @ σ(E). Matching problems and (strict) subsumption conditions in FL0 and FL⊥ are defined analogously. Note that also the solutions are then constrained to belong to the respective sublanguage. Instead of a single matching problem, we may also consider a finite system {C1 ≡? D1 , . . . , Cm ≡? Dm } of such problems. The substitution σ is a solution of this system iff it is a solution of all the matching problems Ci ≡? Di contained in the system. However, it is easy to see that solving systems of matching problems can be reduced (in linear time) to solving a single matching problem. Lemma 1. Let R1 , . . . , Rm be distinct atomic roles. Then σ solves the system {C1 ≡? D1 , . . . , Cm ≡? Dm } iff it solves the single matching problem ∀R1 .C1 u · · · u ∀Rm .Cm ≡? ∀R1 .D1 u · · · u ∀Rm .Dm . Consequently, we may (without loss of generality) restrict our attention to single matching problems with or without finite sets of (strict) subsumption conditions. In [9,23], a different type of matching problems has been considered. We will refer to those problems as matching problems modulo subsumption in order to distinguish them from the matching problems modulo equivalence introduced above. Definition 5. A matching problem modulo subsumption is of the form C v? D where C is a concept description and D is a pattern. A solution of this problem is a substitution σ satisfying C v σ(D). 2
Note that this would not be the case if we had allowed the application of negation to concept variables.
Matching in Description Logics: Preliminary Results
21
For any description language allowing conjunction of concepts, matching modulo subsumption can be reduced (in linear time) to matching modulo equivalence: Lemma 2. The substitution σ solves the matching problem C v? D iff it solves C ≡? C u D. For FL¬ , and more generally for any description language in which variables in patterns may only occur in the scope of “monotonic” operators, solvability of matching problems modulo subsumption can be reduced to subsumption: Lemma 3. Let C v? D be a matching problem modulo subsumption in FL¬ , and let σ> be the substitution that replaces each variable by >. Then C v? D has a solution iff σ> solves C v? D. Thus, solvability of matching problems modulo subsumption in FL¬ and its sublanguages is not an interesting new problem. This changes, however, if we consider such matching problems together with additional (strict) subsumption conditions. In fact, these conditions may exclude the trivial solution σ> . In addition, one is usually not interested in an arbitrary solution of the matching problem C v? D, but rather in computing a “minimal” solution: Definition 6. Let C v? D be a matching problem modulo subsumption. The solution σ of C v? D is called minimal iff there does not exist a substitution δ such that C v δ(D) @ σ(D). Lemma 4. Let C v? D be an FL¬ -matching problem modulo subsumption. If σ is the least solution of C v? D w.r.t. subsumption of substitutions, i.e., σ v δ for all solutions δ, then σ is also a minimal solution. Proof. This is an immediate consequence of the following fact, which can easily be proved by induction on the structure of FL¬ -concept patterns: If σ v δ, then σ(D) v δ(D) for any FL¬ -concept pattern D. It should be noted that talking about the least solution is a slight abuse of language since the least solution of a given matching problem is unique only up to equivalence: if σ and τ are both least solutions of the same matching problem then they subsume each other, which means that σ(X) ≡ τ (X) for all variables X ∈ X. The converse of Lemma 4 need not hold. For example, for the matching problem ∀R.A v? ∀R.Au∀R.X, the substitutions σ := {X 7→A} and τ := {X 7→ >} are both minimal solutions, but τ obviously cannot be a least solution. This example also demonstrates that minimal solutions of a given matching problem need not be unique up to equivalence.
22
3
F. Baader, A. Borgida, and D.L. McGuinness
Matching in F L⊥
The purpose of this section is to show that solvability of FL⊥ -matching problems can be decided in polynomial time. In addition, for matching problems modulo subsumption we can compute a minimal solution in polynomial time. Our algorithm is based on a “concept-centered” normal form for FL⊥ -concept descriptions. First, let us recall the concept-centered normal form for FL0 -concept descriptions introduced in [5]. It is easy to see that any FL0 -concept description can be transformed into an equivalent description that is either > or a (nonempty) conjunction of descriptions of the form ∀R1 . · · · ∀Rm .A for m ≥ 0 (not necessarily distinct) atomic roles R1 , . . . , Rm and an atomic concept A 6= >. We abbreviate ∀R1 . · · · ∀Rm .A by ∀R1 . . . Rm .A, where R1 . . . Rm is considered as a word over the alphabet Σ := R of all atomic roles. In addition, instead of ∀w1 .A u . . . u ∀w` .A we write ∀L.A where L := {w1 , . . . , w` } is a finite set of words over Σ. The term ∀∅.A is considered to be equivalent to >. Using these abbreviations, any pair of FL0 -concept descriptions C, D containing the atomic concepts A1 , . . . , Ak can be rewritten as C ≡ ∀U1 .A1 u . . . u ∀Uk .Ak
and D ≡ ∀V1 .A1 u . . . u ∀Vk .Ak ,
where Ui , Vi are finite sets of words over the alphabet of all atomic roles. This normal form provides us with the following characterization of equivalence of FL0 -concept descriptions [5]: Lemma 5. Let C, D be FL0 -concept descriptions with normal forms as introduced above. Then C ≡ D iff Ui = Vi for all i, 1 ≤ i ≤ k. This characterization can in turn be used to reduce matching of FL0 -concept descriptions to a certain formal language problem, which can easily be shown to be solvable in polynomial time (see [5] for details). If we treat ⊥ like an arbitrary atomic concept, FL⊥ -concept descriptions C, D can still be represented in the form3 C ≡ ∀U0 .⊥ u ∀U1 .A1 u . . . u ∀Uk .Ak and D ≡ ∀V0 .⊥ u ∀V1 .A1 u . . . u ∀Vk .Ak . However, equivalence of the descriptions no longer corresponds to equality of the languages Ui and Vi . The reason is that ∀R1 . · · · ∀Rm .⊥ is subsumed by any value restriction of the form ∀R1 . · · · ∀Rm . ∀Rm+1 . · · · ∀Rm+n .A. This fact is taken into account by the following characterization of equivalence of FL⊥ concept descriptions: Lemma 6. Let C, D be FL⊥ -concept descriptions with FL0 -normal forms as introduced above. Then C≡D 3
iff
U0 ·Σ ∗ = V0 ·Σ ∗ and Ui ∪ U0 ·Σ ∗ = Vi ∪ V0 ·Σ ∗ for all i, 1 ≤ i ≤ k,
We shall call this the F L0 -normal form of the descriptions.
Matching in Description Logics: Preliminary Results
23
where Σ ∗ is the set of all words over the alphabet of all atomic roles and · stands for concatenation. Proof. Assume that the right-hand side of the equivalence stated in the lemma holds. It is sufficient to show that this implies C v D (since D v C then follows by symmetry). Considering the normal form of D this means that we must show that for all w ∈ V0 we have (1) C v ∀w.⊥, and for all i, 1 ≤ i ≤ k, and all w ∈ Vi we have (2) C v ∀w.Ai . Thus, let w ∈ V0 . By assumption, V0 ⊆ V0 ·Σ ∗ = U0 ·Σ ∗ , which implies that there exist a word u ∈ U0 and v ∈ Σ ∗ such that w = uv. Thus, the normal form for C contains the conjunct ∀u.⊥. Since ∀u.⊥ v ∀uv.⊥ for any word v we have established that (1) holds. Property (2) can be shown similarly. Conversely, assume that the right-hand side of the equivalence stated in the lemma does not hold, i.e., (1) U0 ·Σ ∗ 6= V0 ·Σ ∗ , or for some i, 1 ≤ i ≤ k, (2) Ui ∪ U0 ·Σ ∗ 6= Vi ∪ V0 ·Σ ∗ . First, we assume that (1) holds. Without loss of generality we may assume that there exist a word w := R1 . . . Rm ∈ Σ ∗ such that w ∈ U0 ·Σ ∗ and w 6∈ V0 ·Σ ∗ . We claim that this implies D 6vC, and thus C 6≡D. In order to prove this claim, we construct an interpretation I as follows: the domain ∆I := {d0 , . . . , dm } consists of m + 1 distinct individuals; the interpretation of atomic concepts Ai is given by AIi := ∆I ; finally, the atomic roles are interpreted as S I := {(di−1 , di ) | S = Ri }. It is easy to see that this interpretation satisfies d0 ∈ (∀u.Ai )I for all words u ∈ Σ ∗ (since AIi = ∆I ), and d0 ∈ (∀u.⊥)I for all words u that are not a prefix of w = R1 . . . Rm . Consequently, d0 ∈ (∀u.Ai )I for all u ∈ Vi . In addition, w 6∈V0 ·Σ ∗ implies that no word in V0 is a prefix of w, and thus d0 ∈ (∀u.⊥)I for all words u ∈ V0 . This shows that d0 ∈ DI . However, by construction, d0 6∈ (∀w.⊥)I , which implies d0 6∈C I . Second, we assume that (1) does not hold, i.e., U0 ·Σ ∗ = V0 ·Σ ∗ , and that (2) holds. Without loss of generality we may assume that there exists a word w := R1 . . . Rm ∈ Σ ∗ such that w ∈ Ui and w 6∈Vi ∪ V0 ·Σ ∗ . Again, we claim that this implies D 6vC, and thus C 6≡D. In order to prove this claim, we construct an interpretation I as follows: the domain ∆I := {d0 , . . . , dm } consists of m + 1 distinct individuals; the interpretation of atomic concepts Aj for j 6= i is given by AIj := ∆I ; the interpretation of Ai is AIi := ∆I \ {dm }; finally, the atomic roles are interpreted as S I := {(di−1 , di ) | S = Ri }. By construction d0 6∈(∀w.Ai )I , and thus d0 6∈C I . On the other hand, it is easy to show (using arguments that are similar to the ones employed in the first case) that d0 ∈ DI . If D is an FL⊥ -pattern containing the variables X1 , . . . , X` , then its FL0 normal form is of the form D ≡ ∀V0 .⊥ u ∀V1 .A1 u . . . u ∀Vk .Ak u ∀W1 .X1 u . . . u ∀W` .X` . If we want to match D with the description C (with normal form as above), we must solve the following “formal language” equations (where Xj,i are interpreted
24
F. Baader, A. Borgida, and D.L. McGuinness
as variables for finite sets of words): (⊥) U0 ·Σ ∗ = V0 ·Σ ∗ ∪ W1 ·X1,0 ·Σ ∗ ∪ . . . ∪ W` ·X`,0 ·Σ ∗ , and for all i, 1 ≤ i ≤ k, (Ai ) Ui ∪ U0 ·Σ ∗ = Vi ∪ W1 ·X1,i ∪ . . . ∪ W` ·X`,i ∪ U0 ·Σ ∗ . Theorem 1. Let C be an FL⊥ -concept description and D an FL⊥ -concept pattern with FL0 -normal forms as introduced above. Then the matching problem C ≡? D has a solution iff the formal language equations (⊥) and (A1 ), . . . , (Ak ) are each solvable. Proof. Let σ := {X1 7→ ∀L1,0 .⊥ u
k
u ∀L1,i .Ai , i=1
. . . , X` 7→ ∀L`,0 .⊥ u
k
u ∀L`,i .Ai } i=1
be a substitution.4 By employing elementary equivalences between concept descriptions we can show that the FL0 -normal form of σ(D) is σ(D) ≡ ∀ (V0 ∪ W1 ·L1,0 ∪ · · · ∪ W` ·L`,0 ) .⊥ u k
u ∀ (Vi ∪ W1 ·L1,i ∪ · · · ∪ W` ·L`,i ) .Ai . i=1 Lemma 6 implies that C ≡ σ(D) iff U0 ·Σ ∗ = (V0 ∪ W1 ·L1,0 ∪ · · · ∪ W` ·L`,0 )·Σ ∗ ,
(1)
and for all i, 1 ≤ i ≤ k, Ui ∪ U0 ·Σ ∗ = Vi ∪ W1 ·L1,i ∪ · · · ∪ W` ·L`,i ∪ (V0 ∪ W1 ·L1,0 ∪ · · · ∪ W` ·L`,0 )·Σ ∗ .
(2)
Since concatenation distributes over union, (1) corresponds to the fact that the assignment X1,0 := L1,0 , . . . , X`,0 := L`,0 solves equation (⊥). In addition, if we already know that (1) holds, then (2) corresponds to the fact that the assignment X1,i := L1,i , . . . , X`,i := L`,i solves equation (Ai ). This shows how a solution σ of the matching problem C ≡? D yields solutions of the equations (⊥), (A1 ), ..., (Ak ), and conversely how solutions of these equations can be used to construct a matcher σ. Example 1. As a running example, we will consider the problem of matching the pattern D := X1 u (∀R.X1 ) u (∀S.X2 ) 4
Without loss of generality we restrict our attention to the images of variables occurring in D, and assume that σ introduces only atomic concepts occurring in C or D.
Matching in Description Logics: Preliminary Results
25
against the description C := ∀R.((∀S.A1 ) u (∀R.⊥)) u ∀S.∀S.⊥. The FL⊥ -normal forms of C and D are C ≡ ∀{RR, SS}.⊥ u ∀{RS}.A1 and D ≡ ∀∅.⊥ u ∀∅.A1 u ∀{ε, R}.X1 u ∀{S}.X2 . Thus, the matching problem C ≡? D is translated into the following two equations: (⊥) {RR, SS}·Σ ∗ = ∅·Σ ∗ ∪ {ε, R}·X1,0 ·Σ ∗ ∪ {S}·X2,0 ·Σ ∗ , (A1 ) {RS} ∪ {RR, SS}·Σ ∗ = ∅ ∪ {ε, R}·X1,1 ∪ {S}·X2,1 ∪ {RR, SS}·Σ ∗ . If we want to utilize Theorem 1 for deciding matching problems in FL⊥ , we must show how solvability of the equations (⊥), (A1 ), ..., (Ak ) can be tested. First, we address the problem of solving equation (⊥). Lemma 7. Equation (⊥) has a solution iff replacing Xj,0 ·Σ ∗ by the sets \ w−1 ·(U0 ·Σ ∗ ) w∈Wj
solves equation (⊥).
5
Proof. To show the only-if direction, we assume that the assignment X1,0 := M1,0 , . . . , X`,0 := M`,0 solves equation T (⊥). First, we prove that Mj,0 ·Σ ∗ ⊆ w∈Wj w−1 ·(U0 ·Σ ∗ ) holds for all j, 1 ≤ j ≤ `. Thus, let v ∈ Mj,0 ·Σ ∗ and w ∈ Wj . Since Wj ·Mj,0 ·Σ ∗ ⊆ U0 ·Σ ∗ , we know that wv ∈ U0 ·Σ ∗ , and thus v ∈ w−1 ·(U0 ·Σ ∗ ). T This shows that Mj,0 ·Σ ∗ ⊆ −1 ∗ ∗ w ·(U0 ·Σ ) for all w ∈ Wj , and thus Mj,0 ·Σ ⊆ w∈Wj w−1 ·(U0 ·Σ ∗ ). As an immediate consequence, we obtain U0 ·Σ ∗ = V0 ·Σ ∗ ∪ W1 ·M1,0 ·Σ ∗ ∪ . . . ∪ W` ·M`,0 ·Σ ∗ \ \ ⊆ V0 ·Σ ∗ ∪ W1 · w−1 ·(U0 ·Σ ∗ ) ∪ . . . ∪ W` · w−1 ·(U0 ·Σ ∗ ). w∈W1
w∈W`
It remains to be shown that the inclusion in the other direction holds as well. Obviously, we have V0 ·Σ ∗ ⊆ U0 ·Σ ∗ since there exists a solution of (⊥). To conclude the proof of the only-if direction, assume that u ∈ Wj and v ∈ T −1 ·(U0 ·Σ ∗ ). We must show that uv ∈ U0 ·Σ ∗ . Obviously, u ∈ Wj implies w∈Wj w v ∈ u−1 ·(U0 ·Σ ∗ ), and thus uv ∈ U0 ·Σ ∗ . To prove the if direction, it is sufficient to show T that there exist finite sets of words Lj,0 (j = 1, . . . , `) such that Lj,0 ·Σ ∗ = w∈Wj w−1 ·(U0 ·Σ ∗ ). This is an immediate consequence of the fact that languages of the form L·Σ ∗ for finite L are closed under (binary) intersection and left quotients (see (1) and (2) of Lemma 8 below). 5
For a word w and a set of words L we have w−1 ·L := {u | wu ∈ L}. This language is called a left quotient of L.
26
F. Baader, A. Borgida, and D.L. McGuinness
Lemma 8. Let U, V be finite languages and w a word. 1. There exists a finite language L1 such that L1 ·Σ ∗ = w−1 ·(U ·Σ ∗ ). 2. There exists a finite language L2 such that L2 ·Σ ∗ = U ·Σ ∗ ∩ V ·Σ ∗ . 3. U ·Σ ∗ ∪ V ·Σ ∗ = (U ∪ V )·Σ ∗ and U ·(V ·Σ ∗ ) = (U ·V )·Σ ∗ . Proof. (1) Since (uv)−1 L = v −1 ·(u−1 ·L) for all languages L, it is sufficient to consider the case where w has length 1, i.e., w ∈ Σ. We distinguish two cases: – If the empty word ε belongs to U , then U ·Σ ∗ = Σ ∗ = w−1 ·Σ ∗ , and thus we can take L1 := {ε}. – If ε 6∈ U , then our assumption that the length of w is 1 implies that w−1 ·(U ·Σ ∗ ) = (w−1 ·U ) · Σ ∗ , and thus we can take L1 := w−1 ·U , which is finite since U is finite. (2) It is easy to see that we can take L2 := (U ∩ V ·Σ ∗ ) ∪ (V ∩ U ·Σ ∗ ). (3) is trivial. For the matching problem of Example 1, we replace X1 ·Σ ∗ by R−1 ·({RR, SS}·Σ ∗ )∩ε−1 ·({RR, SS}·Σ ∗ ) = {R}·Σ ∗ ∩{RR, SS}·Σ ∗ = {RR}·Σ ∗ and X2 ·Σ ∗ by
S −1 ·({RR, SS}·Σ ∗ ) = {S}·Σ ∗ .
It is easy to see that this replacement solves the equation. The finite languages Lj,0 are defined as L1,0 := {RR} and L2,0 := {S}. Now, let us consider the equations (Ai ) for 1 ≤ i ≤ k. Lemma 9. Equation (Ai ) has a solution iff replacing the variables Xj,i by the −1 b j,i := T ·(Ui ∪ U0 ·Σ ∗ ) yields a solution of (Ai ). sets L w∈Wj w Proof. The proof of the only-if direction is very similar to the proof of this direction for Lemma 7. In particular, one can show that any assignment X1,i := b j,i . M1,i , . . . , X`,i := M`,i that solves (Ai ) satisfies Mj,i ⊆ L To prove the if direction, it is sufficient to show that there exist finite sets of b j,i ∪ U0 ·Σ ∗ . words Lj,i such that Wj ·Lj,i ∪ U0 ·Σ ∗ = Wj ·L T −1 b j,i = We have L ·Ui ∪ w−1 ·(U0 ·Σ ∗ )). By applying distributivity w∈Wj (w of intersection over union, this intersection of unions can T be transformed into a union of intersections. Except for the intersection w∈Wj w−1 ·(U0 ·Σ ∗ ), all the intersection expressions in this union contain at least w−1 Ui T one language −1 for a word w ∈ Wj . Since Ui is finite, this shows that w∈Wj w ·(U0 ·Σ ∗ ) is the only (possibly) infinite language in the union. Consequently, if we define −1 b j,i \ T Lj,i := L ·(U0 ·Σ ∗ ), then Lj,i is a finite language. w∈Wj w b j,i ∪ U0 ·Σ ∗ = Wj ·Lj,i ∪ U0 ·Σ ∗ , it is sufficient to In order to prove that Wj ·L b j,i \ Lj,i implies uv ∈ U0 ·Σ ∗ . By definition of Lj,i , and v ∈ L show that u ∈ Wj T −1 we know that v ∈ w∈Wj w ·(U0 ·Σ ∗ ), and thus u ∈ Wj implies uv ∈ U0 ·Σ ∗ .
Matching in Description Logics: Preliminary Results
27
For the matching problem of Example 1, we have b 1,1 = R−1 ·({RS} ∪ {RR, SS}·Σ ∗ ) ∩ ε−1 ·({RS} ∪ {RR, SS}·Σ ∗ ) L = ({S} ∪ {R}·Σ ∗ ) ∩ ({RS} ∪ {RR, SS}·Σ ∗ ) = {RS} ∪ {RR}·Σ ∗ , b 2,1 = S −1 ·({RS} ∪ {RR, SS}·Σ ∗ ) L = {S}·Σ ∗ . b j,1 yields a solution Again, it is easy to see that replacing the variables Xj,1 by L of equation (A1 ). The finite languages Lj,1 are defined as L1,1 := {RS} and L2,1 := ∅. Lemma 7 and 9 provide us with a polynomial algorithm for deciding solvability of matching problems in FL⊥ . Theorem 2. Solvability of matching problems in FL⊥ can be decided in polynomial time. Proof. Obviously, Lemma 7 and 9 provide us with an effective method for testing matching problems in FL⊥ for solvability. It remains to be shown that this test can be realized in polynomial time. First, note that the combined size6 of the finite languages Ui and Vi is linear in the size of the concept description and the pattern. Thus, the size of the equations (⊥) and (Ai ) is polynomial in the size of the original matching problem. Both for equation (⊥) and for equation (Ai ) we compute a “candidate” for a solution and then test whether it really is a solution. First, let us consider equation (⊥). Given the finite language U0 , we can construct (in polynomial time) a deterministic finite automaton that accepts the left-hand side U0 ·Σ ∗ of equation (⊥), and whose size is polynomial in the size of U0 . Regarding the right-hand side of equation (⊥), it is easy to see that computing the candidate and inserting it into the right-hand side can be done in polynomial time. To be more precise, we can compute (in polynomial time) a deterministic finite automaton accepting the (regular) language obtained by inserting the candidate solution into the right-hand side of equation (⊥), and the size of this automaton is polynomial in the size of the equation. In fact, in order to construct this automaton, we start with finite deterministic automata for U0 ·Σ ∗ and V0 ·Σ ∗ , and then apply the closure properties stated in Lemma 8 a polynomial number of times. It is easy to see that each closure operation can be realized as a polynomial operation on deterministic finite automata. Since equivalence of regular languages given by deterministic finite automata can be decided in time polynomial in the size of the automata,7 this shows that solvability of equation (⊥) can be tested in polynomial time. 6 7
As size of a finite language we take the sum of the length of the words occurring in the language. Note that this would not be the case for nondeterministic finite automata.
28
F. Baader, A. Borgida, and D.L. McGuinness
The equations (Ai ) can be treated similarly. We just have to extend our argument regarding closure properties and deterministic finite automata from languages of the form L·Σ ∗ for finite L to languages of the form L ∪ L0 ·Σ ∗ for finite L, L0 . The proofs of Lemma 7 and 9 also show how to compute a matcher of a given solvable FL⊥ -matching problem in polynomial time. In fact, if the matching problem is solvable, then the following substitution σ is a matcher: σ := {X1 7→ ∀L1,0 .⊥ u
k
u ∀L1,i .Ai , i=1
. . . , X` 7→ ∀L`,0 .⊥ u
k
u ∀L`,i .Ai }, i=1
where the languages Lj,0 (1 ≤ j ≤ `) are defined as in the proof of Lemma 7, and the languages Lj,i (1 ≤ j ≤ `, 1 ≤ i ≤ k) are defined as in the proof of −1 b j,i \ T ·(U0 ·Σ ∗ ) Lemma 9. It should be noted that the language Lj,i = L w∈Wj w S −1 is a subset of v∈Wj v Ui , and thus its size is polynomial in the size of the matching problem. For the matching problem of Example 1, we thus obtain the matcher {X1 7→(∀R.∀R.⊥) u (∀R.∀S.A1 ), X2 7→ ∀S.⊥}. Lemma 10. Assume that the given FL⊥ -matching problem C ≡? D is solvable. Then the substitution σ defined above is the least solution of C ≡? D. Proof. Assume that δ := {X1 7→ ∀M1,0 .⊥ u
k
u ∀M1,i .Ai , i=1
. . . , X` 7→ ∀M`,0 .⊥ u
k
u ∀M`,i .Ai } i=1
is another solution of C ≡? D. Consequently, the assignment X1,0 := M1,0 , . . . , X`,0 := M`,0 solves equation (⊥), and the assignment X1,i := M1,i , . . . , X`,i := M`,i solves (Ai ). As shown in the proofs of Lemma 7 and 9, this implies that b j,i (1 ≤ j ≤ `, 1 ≤ i ≤ k). Mj,0 ·Σ ∗ ⊆ Lj,0 ·Σ ∗ (1 ≤ j ≤ `) and Mj,i ⊆ L As a consequence of Lemma 6, we can infer σ(Xj ) v δ(Xj ) from Mj,0 ·Σ ∗ ⊆ Lj,0 ·Σ ∗ and Mj,i ∪ Mj,0 ·Σ ∗ ⊆ Lj,i ∪ Lj,0 ·Σ ∗ . We already know that the first inclusion holds. For the second inclusion, it remains to be shown that Mj,i ⊆ b j,i since L b j,i = Lj,0 ·Σ ∗ . This is an immediate consequence of Mj,i ⊆ L Lj,i ∪ T T −1 ∗ ∗ −1 ∗ Lj,i ∪ w∈Wj w ·(U0 ·Σ ) and Lj,0 ·Σ = w∈Wj w ·(U0 ·Σ ). This lemma, together with Lemma 4, immediately implies the following theorem: Theorem 3. Let C v? D be a solvable matching problem modulo subsumption. Then the least solution of C ≡? C u D is a minimal solution of C v? D, and this solution can be computed in polynomial time.
Matching in Description Logics: Preliminary Results
4
29
Matching in F L¬
The results for matching in FL⊥ can easily be extended to the language FL¬ . In principle, negated atomic concepts are treated like new atomic concepts. The fact that A u ¬A is inconsistent (i.e., equivalent to ⊥) is taken care of by extending the language in the value restriction for the concept ⊥ appropriately. To be more precise, let C, D be FL⊥ -concept descriptions, and A1 , . . . , Ak the atomic concepts occurring in C, D. By treating the negated atomic concepts ¬Ai like new atomic concepts, we can transform C and D into their FL0 -normal forms: C ≡ ∀U0 .⊥ u ∀U1 .A1 u . . . u ∀Uk .Ak u ∀Uk+1 .¬A1 u . . . u ∀U2k .¬Ak , D ≡ ∀V0 .⊥ u ∀V1 .A1 u . . . u ∀Vk .Ak u ∀Vk+1 .¬A1 u . . . u ∀V2k .¬Ak . If we define b0 := U0 ∪ U
k [
(Ui ∩ Uk+i )
and
Vb0 := V0 ∪
i=1
k [
(Vi ∩ Vk+i ),
i=1
then Lemma 6 can be generalized to FL¬ as follows: Lemma 11. Let C, D be FL¬ -concept descriptions with FL0 -normal forms as introduced above. Then C≡D
iff
b0 ·Σ ∗ = Vb0 ·Σ ∗ and U b0 ·Σ ∗ = Vi ∪ Vb0 ·Σ ∗ for all i, 1 ≤ i ≤ 2k, Ui ∪ U
where Σ ∗ is the set of all words over the alphabet of all atomic roles. Consequently, all the results for matching in FL⊥ carry over to FL¬ : we b0 , Vb0 . simply have to replace k by 2k and the sets U0 , V0 by U Theorem 4. Let C ≡? D be an FL¬ -matching problem. Solvability of C ≡? D can be tested in polynomial time. If C ≡? D is solvable, then a least solution of C ≡? D can be computed in polynomial time.
5
Matching under side conditions
In the following, we consider strict subsumption conditions in more detail. For (non-strict) subsumption conditions we just briefly mention some results. Strict subsumption conditions Recall that a strict subsumption condition is of the form X @? E where X is a concept variable and E is a concept pattern. If the concept patterns of a set of strict subsumption conditions do not contain variables (i.e., the expressions E on the right-hand sides of the strict subsumption conditions are concept descriptions), then it is sufficient to compute a least solution of the matching problem, and then test whether this solution also solves the strict subsumption conditions.
30
F. Baader, A. Borgida, and D.L. McGuinness
Theorem 5. Let C ≡? D be an FL¬ -matching problem, and X1 @? E1 , . . . , Xn @? En strict subsumption conditions such that E1 , . . . , En are FL¬ -concept descriptions. Then solvability of C ≡? D under these conditions is decidable in polynomial time. If the right-hand sides of strict subsumption conditions may contain variables, then solvability becomes NP-hard, even for the language FL0 . This will be shown by reducing 3SAT [18] to the matching problem under strict subsumption conditions. Recall that matching modulo subsumption can be reduced to matching modulo equivalence, and that a system of matching problems can be coded into a single matching problem. For this reason, we may, without loss of generality, construct a problem that consists of matching problems modulo subsumption, matching problems modulo equivalence, and strict subsumption conditions. Theorem 6. Matching under strict subsumption conditions is NP-hard, even for the small language FL0 . Proof. Let A be an arbitrary concept name. For every propositional variable p occurring in the 3SAT problem, we introduce three concept variables, namely Xp , Xp , and Zp , and two roles Rp and Rp . Using these concept variables and roles, we construct the matching statement ∀Rp .A u ∀Rp .A v Zp ,
(3)
and the strict subsumption condition Zp @ ∀Rp .Xp u ∀Rp .Xp .
(4)
It is easy to see that the subsumption relationship between ∀Rp .A u ∀Rp .A and ∀Rp .Xp u ∀Rp .Xp enforced by (3) and (4) implies that any solution θ of (3) and (4) satisfies: (θ(Xp ) ≡ A ∨ θ(Xp ) ≡ >) ∧ (θ(Xp ) ≡ A ∨ θ(Xp ) ≡ >). In addition, the fact that this subsumption relationship must be strict implies θ(Xp ) ≡ > ∨ θ(Xp ) ≡ >. Finally, if this solution also satisfies the matching statement A ≡ Xp u Xp ,
(5)
then we know that both variables can not be replaced by >, i.e., θ(Xp ) ≡ A ∨ θ(Xp ) ≡ A. This shows that, if we take > as the truth value 1 and A as the truth value 0, then any solution assigns either 0 or 1 to Xp , and the opposite truth value to Xp .
Matching in Description Logics: Preliminary Results
31
It remains to be shown that 3-clauses and the corresponding truth conditions can be encoded. We introduce a concept variable Zc and three roles Rc,1 , Rc,2 , Rc,3 for every 3-clause c in our 3SAT problem, and represent the clause by a matching problem together with a strict subsumption condition. For example, assume that c := p ∨ ¬q ∨ r. Then c is represented by the matching statement ∀Rc,1 .A u ∀Rc,2 .A u ∀Rc,3 .A v Zc ,
(6)
and the strict subsumption condition Zc @ ∀Rc,1 .Xp u ∀Rc,2 .Xq u ∀Rc,3 .Xr .
(7)
Obviously, the strict inclusion implied by these two statements can only be satisfied by a substitution θ if it assigns > to at least one of the variables Xp , Xq , and Xr . This completes our reduction. Note that (5) is a matching problem modulo equivalence that cannot be represented by a matching problem modulo subsumption. Thus, it is still open whether the NP-hardness result also holds for matching modulo subsumption under strict subsumption conditions. Theorem 6 only provides a hardness result for matching under strict subsumption conditions. Thus, another open question is how to extend the matching algorithm for FL¬ to an algorithm that can also handle strict subsumption conditions. Subsumption conditions If the subsumption conditions do not introduce cyclic variable dependencies, then a matching problem with subsumption conditions can be reduced to an ordinary matching problem. To be more precise, the sequence of subsumption conditions X1 v? E1 , . . . , Xn v? En is acyclic iff for all i, 1 ≤ i ≤ n, the pattern Ei does not contain the variables Xi , . . . , Xn . Given such an acyclic sequence of subsumption conditions, we can define a substitution8 σ inductively as follows: σ(X1 ) := Y1 u E1 and σ(Xi ) := Yi u σ(Ei ) (1 < i ≤ n), where the Yi are new variables. We can show that the matching problem C ≡? D is solvable under the subsumption conditions X1 v? E1 , . . . , Xn v? En iff C ≡? σ(D) is solvable without subsumption conditions. Unfortunately, the new pattern σ(D) may be exponentially larger than the original matching problem with subsumption conditions. However, we conjecture that a compact representation of σ(D) may be used to obtain a polynomial algorithm for matching under acyclic subsumption conditions in FL¬ . 8
Strictly speaking, this is not a substitution as introduced in Section 2 since variables are mapped to patterns, and not just to descriptions. It should be clear, however, that the notion of a substitution can be extended appropriately.
32
F. Baader, A. Borgida, and D.L. McGuinness
The reduction we have just described is independent of the DL used for constructing the patterns and descriptions. For FL0 , we can go one step further: cyclic subsumption conditions can here be reduced to acyclic ones. Let us illustrate this by two examples: (1) If σ satisfies X1 v? X2 u E10 , X2 v? X1 u E20 , then σ(X1 ) ≡ σ(X2 ), which means that we can identify both variables; (2) If σ satisfies X v? ∀R.X, then σ(X) ≡ >, and thus X can be replaced by >.
6
Future Work
Our goal is to extend the results on matching to cover languages at least as expressive as the DL considered in [9]. This requires extending the language to include range constructors (min and max), an individual set constructor (one-of), number restrictions (at-least and at-most), and a fills constructor. For the constructors min, max, and one-of, this mainly requires an appropriate treatment of disjointness, which we have already achieved by our treatment of primitive negation. Number restrictions and the fills construct are more challenging extensions; however, we expect to be able to exploit the characterization of subsumption in cyclic ALN -terminologies provided in [21] for our purposes. Another motivation for investigating matching modulo equivalence may be found in merging heterogeneous databases. Consider a situation where there is a master ontology along with new database schemas that need to be integrated into the master ontology. In this situation, the integrator would like to know how the new schemas may be mapped onto the master ontology. Our idea is to represent the ontology and the schemas in an appropriate DL, and to view the problem of finding such a mapping as a matching problem of the concepts of the new schema onto the concepts of the master ontology.
7
Conclusion
We have been motivated by the need to prune complicated structures in order to provide manageable object presentations and explanations. The pruning problem can be viewed as a matching problem where there is a comparison between a pattern describing the interesting portions of the object and the larger object itself. Only those portions of the object that match the pattern of interest should be presented. We began with the filtering work introduced in Classic and the theoretical work on the unification of concept terms and generated a formal treatment of matching in the description logic language FL⊥ . We presented results concerning the solvability of the problem including polynomial decidability and (for solvable problems) polynomial computability of a least solution. We also extended the work to include matching under additional side constraints on the variables in the matching patterns. We showed that matching modulo equivalence with strict side conditions is NP-hard even for the small language FL0 .
Matching in Description Logics: Preliminary Results
33
References 1. F. Baader. Augmenting concept languages by transitive closure of roles: An alternative to terminological cycles. In Proceedings of the 12th International Joint Conference on Artificial Intelligence, pages 446–451, Sydney, Australia, 1991. 2. F. Baader, M. Buchheit, and B. Hollunder. Cardinality restrictions on concepts. Artificial Intelligence, 88(1–2):195–213, 1996. 3. F. Baader and P. Hanschke. A scheme for integrating concrete domains into concept languages. In Proceedings of the 12th International Joint Conference on Artificial Intelligence, pages 452–457, Sydney, Australia, 1991. 4. F. Baader and B. Hollunder. A terminological knowledge representation system with complete inference algorithms. In M. Richter and H. Boley, editors, Proceedings of the First International Workshop on Processing Declarative Knowledge, volume 567 of Lecture Notes in Computer Science, pages 67–85, Kaiserslautern (Germany), 1991. Springer–Verlag. 5. F. Baader and P. Narendran. Unification of concept terms in description logics. In H. Prade, editor, Proceedings of the 13th European Conference on Artificial Intelligence (ECAI-98), pages 331–335, Brighton, UK, 1998. John Wiley & Sons Ltd. An extended version has appeared as Technical Report LTCS-98-06. 6. F. Baader and U. Sattler. Description logics with symbolic number restrictions. In W. Wahlster, editor, Proceedings of the Twelfth European Conference on Artificial Intelligence (ECAI-96), pages 283–287. John Wiley & Sons Ltd, 1996. 7. F. Baader and U. Sattler. Number restrictions on complex roles in description logics. In Proceedings of the Fifth International Conference on the Principles of Knowledge Representation and Reasoning (KR-96). Morgan Kaufmann, Los Altos, 1996. 8. A. Borgida. Description Logics in Data Management. IEEE Trans. on Knowledge and Data Engineering, 7(5): 671–682, 1995. 9. A. Borgida and D.L. McGuinness. Asking queries about frames. In Proceedings of the Fifth International Conference on Principles of Knowledge Representation and Reasoning, KR’96, pages 340–349, Cambridge, MA (USA), 1996. 10. A. Borgida and P. Patel-Schneider. A semantics and complete algorithm for subsumption in the CLASSIC description logic. Journal of Artificial Intelligence Research, 1:277–308, 1994. 11. R. J. Brachman, D. L. McGuinness, P. F. Patel-Schneider, L. A. Resnick, and A. Borgida. Living with CLASSIC: When and how to use a KL-ONE-like language. In J. Sowa, editor, Principles of Semantic Networks, pages 401–456. Morgan Kaufmann, San Mateo, Calif., 1991. 12. R. J. Brachman and J. G. Schmolze. An overview of the KL-ONE knowledge representation system. Cognitive Science, 9(2):171–216, 1985. 13. M. Buchheit, F. M. Donini, and A. Schaerf. Decidable reasoning in terminological knowledge representation systems. Journal of Artificial Intelligence Research, 1:109–138, 1993. 14. F. Donini, M. Lenzerini, D. Nardi, and W. Nutt. The complexity of concept languages. In Proceedings of the 2nd International Conference on Principles of Knowledge Representation and Reasoning, pages 151–162, Cambridge, Mass., 1991. 15. F. Donini, M. Lenzerini, D. Nardi, and W. Nutt. Tractable concept languages. In Proceedings of the 12th International Joint Conference on Artificial Intelligence, pages 458–463, Sydney, Australia, 1991.
34
F. Baader, A. Borgida, and D.L. McGuinness
16. F. Donini, M. Lenzerini, D. Nardi, and A. Schaerf. Deduction in concept languages: From subsumption to instance checking. Journal of Logic and Computation, 4(4):423–452, 1994. 17. F.M. Donini, B. Hollunder, M. Lenzerini, A.M. Spaccamela, D. Nardi, and W. Nutt. The complexity of existential quantification in concept languages. Journal of Artificial Intelligence, 53:309–327, 1992. 18. M.R. Garey and D.S. Johnson. Computers and Intractability: A Guide to the Theory of NP-Completeness. W.H. Freeman and Company, New York, 1979. 19. B. Hollunder and F. Baader. Qualifying number restrictions in concept languages. In Proceedings of the 2nd International Conference on Principles of Knowledge Representation and Reasoning, pages 335–346, Cambridge, Mass., 1991. 20. B. Hollunder, W. Nutt, and M. Schmidt-Schauß. Subsumption algorithms for concept description languages. In Proceedings of the 9th European Conference on Artificial Intelligence, pages 348–353, Stockholm, Sweden, 1990. 21. R. K¨ usters. Characterizing the semantics of terminological cycles in ALN using finite automata. In Proceedings of the Sixth International Conference on Principles of Knowledge Representation and Reasoning (KR’98), Trento, Italy, 1998. 22. H. J. Levesque and R. J. Brachman. Expressiveness and tractability in knowledge representation and reasoning. Computational Intelligence, 3:78–93, 1987. 23. D.L. McGuinness. Explaining Reasoning in Description Logics. Ph.D. thesis, Department of Computer Science, Rutgers University, October 1996. Also available as a Rutgers Technical Report LCSR-TR-277. 24. D.L. McGuinness and A. Borgida. Explaining subsumption in Description Logic. In Proceedings of the 14th International Joint Conference on Artificial Intelligence, IJCAI’95, pages 816–821, Montr´eal, Canada, 1995. Morgan Kaufmann. 25. D.L. McGuinness, L. Alperin Resnick, and C. Isbell. Description Logic in practice: A classic application. In Proceedings of the 14th International Joint Conference on Artificial Intelligence, IJCAI’95, pages 2045–2046, Montr´eal, Canada, 1995. Morgan Kaufmann. Video Presentation. 26. D.L. McGuinness and J.R. Wright. An industrial strength Description Logic-based configurator platform. IEEE Expert, Special Issue on Configuration, 1998. To appear. 27. B. Nebel. Computational complexity of terminological reasoning in BACK. Journal of Artificial Intelligence, 34(3):371–383, 1988. 28. B. Nebel. Reasoning and Revision in Hybrid Representation Systems, volume 422 of Lecture Notes in Computer Science. Springer–Verlag, 1990. 29. B. Nebel. Terminological reasoning is inherently intractable. Journal of Artificial Intelligence, 43(2):235–249, 1990. 30. A. Schaerf. On the complexity of the instance checking problem in concept languages with existential quantification. Journal of Intelligent Information Systems, 2:265–278, 1993. 31. M. Schmidt-Schauß and G. Smolka. Attributive concept descriptions with complements. Journal of Artificial Intelligence, 47:1–26, 1991. 32. W. A. Woods and J. G. Schmolze. The KL-ONE family. Computers and Mathematics with Applications, special issue on knowledge representation, 23(2-5):133–177, 1991. 33. J. R. Wright, E. S. Weixelbaum, G. T. Vesonder, K. Brown, S. R. Palmer, J. I. Berman, and H. H. Moore. A knowledge-based configurator that supports sales, engineering, and manufacturing at AT&T network systems. AI Magazine, 14(3):69–80, 1993.
Powerset Trilattices Klaus Biedermann Technische Universits Darmstadt, Fachbereich Mathematik Schloi~gartenstr. 7, D-64289 Darmstadt, biedermann@mathematik, th-darmstadt .de A b s t r a c t . The Boolean lattices are fundamental algebraic structures in Lattice Theory and Mathematical Logic. Since the triadic approach to Formal Concept Analysis gave rise to the triadic generalization of lattices, the trilattices, it is natural to ask for the triadic analogue of Boolean lattices, the Boolean trilattices. The first step in establishing Boolean trilattices is the study of powerset trilattices, which are the the triadic generalization of powerset lattices. In this paper, an order-theoretic characterization of the powerset trilattices as certain B-trilattices is presented. In particular, the fmite B-trilattices are (up to isomorphism) just the finite powerset trilattices. They have 3 '~ elements. Further topics are the triadic de Morgan laws, the cycles of triadic complements as the triadic complementation and the atomic cycles, which take over the role of the atoms in the theory of Boolean lattices.
1
Introduction
The idea of a formalization of traditional philosophical logic, which is based on concepts, judgements, and conclusions as the three essential main functions of thinking, lead to a unification of the Theory of Conceptual Graphs and the Theory of Formal Concept Analysis (ef. Wi97). It has turned out t h a t for simple conceptual graphs without nesting the dyadic setting of Formal Concept Analysis is appropriate but for conceptual graphs with nesting the triadic approach to Formal Concept Analysis, Triadic Concept Analysis, is required. This is elaborated in the paper "Triadic Concept Graphs" by R. Wille in this volume. The triadic approach to Formal Concept Analysis on the other hand gave rise to a new class of algebraic structures, the so-called trilattices (cf. Wi95 and Bi98), which are the triadic generalization of lattices. Since Boolean lattices are fund a m e n t a l algebraic structures in Lattice Theory and Mathematical Logic, it is natural to ask for the triadic analogue of Boolean lattices, the Boolean trilattices, which play a similar role in the triadic case as Boolean lattices in the dyadic case. The first step in establishing Boolean trilattices, done in this paper, is the study of powerset trilattices as the triadic generalization of powerset lattices. In the following section, the basic notions and results about trilattices are given. Some first properties of powerset trilattices will be presented in the third section. Most of t h e m correspond to familiar results concerning powersets. In the fourth section, B-trilattices are defined as special (triadically) complemented trilattices
210
and it can be shown that, as for Boolean lattices, the triadic complementation in B-trilattices is unique. The atomic cycles, which correspond to the atoms in the theory of Boolean lattices, enable us to give a first characterization of the powerset trilattices as certain B-trilattices. In particular, the finite B-trilattices turn out to be the finite powerset trilattices just as the finite Boolean lattices are (up to isomorphism) the finite powerset lattices. Before motivating powerset trilattices, we must introduce trilattices as special triordered sets - j u s t as lattices are special ordered sets. More about Formal Concept Analysis and Lattice Theory can be found in GW96 and DP90. For basic results about Boolean lattices, the reader is for example referred to the article by R. W. Quwckenbush in Gr79 and to MB89.
2
Trilattices
A triordered set is a relational structure (P, < 1, < 2, < 3) for which the relations are quasiorders with -~i:=i for i = 1, 2, 3 such that the following conditions hold for all x , y E P and { i , j , k } = {1,2,3}: (1) z .~ y, z ~ j y implies x = y (uniqueness condition), (2) x k Y (antiordinality). A triordered set P := ( P , < t , < 2 , < 3 ) gives rise to the ordered sets (Pi,
211
all x 9 X and y j b for all/k-bounds b of (X, Y). A n / k - l i m i t l of (X, Y) is called the ik-join of (X, Y) and denoted by XXYikY i f / < ~ l for all ik-limits l of (X, Y). It is easy to see that there is at most one such/k-limit of (X, Y). A trilattice is a triordered set L := (L, ~1, ~2, ~3) in which all the ik-joins {xl, x2}Vik{yl, Y2} exist where xl, z2, Yl, Y2 9 P and {i,j, k} = {1, 2, 3}. I f X = {x} and Y = {y} we will shortly write xXYiky for {x}XYik{y}. A triordered set (L, <1, <2, <3) is called a complete trilattice if, for arbitrary sets X, Y C L, all the /k-joins XxYikY exist. In particular, a complete trilattice is bounded by Oj := LXYikL --- L V k i L where {i, j, k} = {1, 2, 3}. For a bounded trilattice L we define 0i := O,i and li := Oji = Oki where { i , j , k } = {1,2,3}, and also the boundary of L by b(L) := {x 9 L x "~i Oi for some i 9 {1,2,3}}. The best way to motivate in which sense the powerset trilattices are the triadic generalization of powerset lattices is to present them within the framework of Triadic Concept Analysis. So we briefly recall some basic definitions and results, which can be found in Wi95 and WZ98. For an immediate study of the powerset trilattices, the reader is directly referred to the first definition in the following section.
A triadic context is a quadruple K := (K1, K2, K 3 , Y ) consisting of a set K1 of objects, a set K2 of attributes, a set K3 of conditions and a ternary relation Y C_ K1 • K~ x K3 indicating under which condition b an object g has an attibute m or, in symbols (g, m, b) E Y. For two subsets X1 C_ K1 and X2 C K2 a derivation operator can be defined in the following way: (Xl, X2) (3) : : {a3 9 K3 (Xl, X2, a3) 9 Y for all xl 9 X1 and x2 9 X2} and similarly for {X1,X3}(2) and (X2,X3}(1). A triple A := (A1,A2,A3) 9 ~(K1) x ~(K2) • ~(K3) is said to be a triadic concept oflK ifAy : {Ai, Ak} (j) for all {i, j, k} = {1, 2, 3} with i < k. It follows that the triadic concepts (A1, A2, A3) of K are precisely those triples in ~(K1) x ~(K2) • ~(K3) which are maximal with respect to the component-wise set inclusion. With respect to the triadic context K, which can be understood as a three-dimensionM cross table, a triadic concept can be understood as a maximal, not necessarily connected box which is completely filled out with entries of the relation Y. The set of all triadic concepts ~(K) of K can be endowed with three quasiorders <~, i 9 {1, 2, 3}, by (A1, A2, A3)
xv13 3 = (((x,
(x,
(((x,
where X := .J{X1 I (Xl, X2, X3) 9 X} and Y := U{Y3
(x, (I1, Y2, Y3) 9 ~ ) .
212
3
Powerset
Trilattices
According to the ordinary (monadic) understanding, the powerset ~3(M) of a given set M consists of all subsets of M and is naturally ordered by set inclusion. We will call (~I(M), C) the powerset lattice of M. Within the dyadic setting of Formal Concept Analysis, the powerset ~3(M) is represented by the (dyadic) powerset context ~M : : (M, M, r and its complete concept lattice ~__(KM) := (~(IKM), <) which has as dyadic concepts the pairs (X~,X2) with X1 U Xz = M and X1 N X2 = 0 or, equivalently, X1 = X C and which is ordered by (X1,X2) < (Y1, Y2) :~:>X1 _CY1(r X2 D Yz). Consequently, one component already determines the other component and (~(M), C) is obviously isomorphic to ~__(KM). Structurally, the monadic and the dyadic understanding of a powerset are closely linked. In Triadic Concept Analysis, the idea of a powerset is represented by the triadic powerset context IKM := (M, M, M, YM) with YM := M 3 \ {(a, a, a) I a E M} and its complete concept trilattice ~(KM). In Wi95, it has already been observed that the triadic concepts (X1, X2, X3) of KM are characterized by X1NX2NX3 = and Xi U Xj = M for distinct i, j E { 1, 2, 3}. We use these conditions to define the triadic generalization of powersets. D e f i n i t i o n 3.1: The powertriset of a set M is defined as 2~(M) := {(Xl, X2, X3) E ~3(M) 3 I Xl N X2 N X3 = 0 and Xi U Xj = M for i ~s j E {1,2,3}}. It can be equipped with three quasiorders by
(x,, x2, x3) <~ (Yl, Y2, }'3) :~ x~ c_ Y~ where i = 1, 2, 3. The powerset trilatticeis defined as ~(M) := (T(M), <1, <2, <3) and denoted by ~(n) if M is finite with M = n. Fig. 1 shows the powerset trilattice ___(4). The triple represented by a little circle in the triangular net can be obtained by following straight lines to circles in the three side diagrams. There the numbers labelled "below" these circles are collected where "below" in a side diagram is the opposite direction to that indicated by the arrow. Since obviously ~:(M) = ~ ( ~ M ) , powerset trilattices are complete trilattices, which will also follow from Proposition 3.2 and Proposition 3.5. Moreover, the ordered structures (~(M)i, _Q), i E {1, 2, 3}, are isomorphic to (~3(M), C) (cf. Proposition 3.4). Note the three bounding elements O1 = (0, M, M), 02 = (M, 0, M), and 03 = (M, M, 0). Note also that a triple (X1, X2, X3) e 2~(M) is not determined by one of its components.
213
Fig. 1. The powerset trilattice ~(4) with the cycle cx of complements of X = ({1, 2}, {1,3, 4}, {2,3,4}).
P r o p o s i t i o n 3.2: Let (X1, X2, X3) E ~ ( M ) 3. Define the symmetric difference o f X , Y C M b y X i A X j := ( X i \ X j ) U ( X j \ X i ) . Then (Xl,X2,X3) E T ( M ) if
and only if x k = ( x , n x~) C = X, AX5 for aU { i , j , k } = { 1 , 2 , 3 } .
Proof: If (Xl, 2 2 , 23) E ~ ( M ) and {i, j, k} = {1, 2, 3}, then X1 Cl X2 Cl X3 = 0 is equivalent to Xk = (Xi Cl Xj) C. Moreover, Xi U Xj = M implies (Xi Cl Xj) C = (Xi \ Xj) U (Xj \ Xi). Conversely, we obtain Xi U Xk = Xi U (Xi Cl Xj) C = M and also X 1 ('1 X2 f"l X 3 ~-- 0. So a triple in if(M) is determined by two of its components. It immediately follows that ___(M) satisfies the unique meet condition and the condition of antiordinality and is therefore a triordered set. Next we consider the finite case: P r o p o s i t i o n 3.3: If M is finite with
IMI
=
n then
I~:(M)I =
3 ~.
Proof." Assume X C M with IXI = k < n as the first component of a triple in hE(M). As the second component Y C M with X U Y = M, we can choose Iq3(X)l = 2 k such sets to obtain the triple (X, Y, X A Y ) E ~E(M). Altogether, there are ~ = 0 (k) 2kln-k = (2 + 1) n = 3 n triples in ~:(M).
214
From the preceding proof it also becomes clear that, in general, any subset X C M can be enlarged to a triple in 3:(M) and can therefore occur in any of the three components. If we identify (X1, X2, X3)i with X~ for all (X~, X2, Xa) E ~(M) and i E {1, 2, 3}, it immediately follows: P r o p o s i t i o n 3.4: The ordered structures (fs M )i ,
= (Zl, Z2, Z3) where Zi = X tO y C
= (x n y)c Zk -= Y. In particular, the 13-join of ( (Xl, X2, X3), (Y1, I2, Ya)) E if(M) 2 is determined by (X1, X2, Xa)Vl3(Y1, Y2, Y3) = (Zl U Y3c, (Xl C/Y3)C , 13)Proof." We ensure first that Z := (Z1, Z2, Z3) E ~(M). Obviously, Zi U Zk = M and, since Zj = X C U y C , we also have Zi U Zj = M and Z j U Zk : M. Intersecting the three components yields Zi MZj f3 Zk = (X U y C ) Cl( X C U y C ) f3 Y = ( ( X N X C) U y C ) M Y = y C f3 Y = ~ and hence Z E ~(M). But it is also an /k-bound of (X,~) because (X1, X2, X3)
Many equations valid in all powerset trilattices can now be deduced but we will restrict ourselves to the triadic de Morgan laws after introducing the triadic complementation. Definition 3.6: For an element X := (X1, X2, X3) E ~(M) and a permutation ~r E $3, the a-complementofX is defined by X a := (Xo-, (1), Xo-1(2), Xa-l(3)) E ~(M). The set c x : = { x a I e s3} will be called the cycle of (triadic) complements of X . Obviously, X ~ can be obtained from X by moving the i th component Xi of X to the or(i) th position. Note that the cycle of complements of a boundary element
215
such as ({4}, {1, 2, 3, 4}, {1, 2, 3})in Fig. 1 lies entirely on the boundary. P r o p o s i t i o n 3.7" In powerset trilattices fs
the triadic de Morgan laws
( X ~ i k Y ) a = XoVa(Oa(k)Y c• hold for all X, Y E 5s
{i, j, k} = {1, 2, 3}, and ~ E $3.
Proof: Let X = (Xl, X2, X3) and Y = (Y, I/2, I/3). Then X V i k Y = (Zl, Z2, Z3) with Zi := X~ U y C , Zj := (Xi gl Yk) C, and Zk := Yk by Proposition 3.5. Since Xi is the cr(i) th component of X ~ and Yk is the cr(k) th component of Y~ it follows that X~ ~ has Xi U y C as a(i)th component, (Xi N Yk) C as ~r(j) th component, and Yk as or(k) th component. This implies XC*Va(i)a(k)Y c' =
(zl, z2, z3)" = (xv
.vF.
Note that the cycle of complements of a bounding element equals {O1,02, 03} and has therefore three elements. Cycles of complements have the following properties: P r o p o s i t i o n 3.8: Let cx be the cycle of complements of X E Ig(M) and let { i , j , k } = {1,2,3}. Then a l l Y E cx satisfy 1. Y "~k y(ij) and 2. Yi V y(iJ)i ~- li and Yi
A y(iJ)i
A y(ik)i
= Oi.
Proof: 1.: The k th component of y(ij) = (Y(ij)(1), Y(ij)(2), Y(ij)(a)) is unchanged. 2.: This follows immediately from Definition 3.1, Definition 3.6, and (the proof of) Proposition 3.4. In the following section it is shown that cx has six elements if X ~ {O1,02, Oh} (cf. Proposition 4.6). Note also that (yo)r = yoor for all Y E cx and ~r, r E Sa.
0 ; ' o - 5 3 9 : ..... o , ,
/ V .....!%0, _"~,,"01 02Q1T" Fig. 2. The smallest non-trivial trilattice B3 , isomorphic to ~(1).
Powerset lattices are order-isomorphic to powers of the smallest non-trivial lattice having two elements. We finish this section with the corresponding triadic
216
result and define the smallest non-trivial trilattice B__z := (B3,<1,<2,<3) by /33 :-- {O1,O2,O3} with 0~ "~i Oi and Oi
9 : ft.(M) --+ BB3 M with ~o(X1,X2,X3)(x) := Oi if x ~ Xi defines a triorder-isomovphism, i.e., any powerset trilattice is (tviorder-)isomorphic to a power of B__3. Proof." Let (X1,X2,X3) E ~:(M) and let x E M. Since x ~ Xi for some i E {1, 2, 3} implies z E Xj and x E Xk for {j,k} = {1, 2, 3} \ {i}, it follows that ~o is well-defined and ~o(X1,X2,X3) E B M. But it is also a triorder embedding: Let X, Y E ~ with X
,/
Fig. 3. A trilattice with isomorphic Boolean lattices as side diagrams which is not a powerset trilattiee.
217
4
B-Trilattices
According to Proposition 3.4, powerset trilattices have isomorphic powerset lattices as ordered structures. T h e trilattice in Fig. 3 has this p r o p e r t y but is different f r o m ~(3). If we add two further conditions, n a m e l y some p r o p e r t y of the ik-joins in powerset trilattices ( L e m m a 4.1) and the triadic c o m p l e m e n t a t i o n (Definition 4.2), and in this way define B-trilattiees, the powerset trilattices can be characterized as certain B-trilattices. In particular, the finite B-trilattices are (up to i s o m o r p h i s m ) j u s t the powerset trilattices ___(n). L e m m a 4.1: Let L := (L, ~<1, <2, ~3) be a bounded trilattice in which x V i k y ~ k Y holds f o r all i 7~ k in {1, 2, 3}. If z E L then z k,i := O k V i k z is the only boundary e l e m e n t b E b(L) satisfying b "~k z and b >~i z. In particular, the boundary elements already determine the ordered structures ( Lk, <_k), k E {1, 2, 3}. Proof." Obviously z k,i "~i Ok > ~ z and hence z k,i E b(L). Moreover z k,i "~k z such t h a t zk = zk'ik showing t h a t Lk = b(n)k := {bk I b e b(L)}.
D e f i n i t i o n 4.2: A set c:= {cl, c2, c3, c4, c~, c6} C L of a b o u n d e d trilattice L is called a cycle if Cl " 3 c2 " 2 c3 ~1 c4 ~3 e5 ~2 c6 "~1 Cl, el "~2 c4, c2 r176c5, and c3 "~a c6 (cf. Fig. 4). A cycle of (triadic) complements is a cycle r in which for each x E c there are elements y , z E c such t h a t for all i E { 1 , 2 , 3 } the join condition xi V Yi = Yi V zi = xi V zi = li and the meet condition xi A Yi A zi = 0~ are satisfied.
\//c, -3~ cl
~2 c6
Fig. 4. A cycle with six elements.
L e m m a 4.3: A cycle c of a trilattice L has one, three or six elements. A cycle of complements has one element if and only if ILl = 1. Proof: T w o elements ck, ct E c of a cycle r := {Cl, c2, c3, c4, c~, c6} with k ~ 1 can either b e / - e q u i v a l e n t for some i E {1,2,3} or not. If Ck = ct it follows Icl -< 3 in the first and Icl = 1 in the second case (apply the uniqueness condition). T h e r e are no cycles with two elements. If a cycle of c o m p l e m e n t s has one element then ILl = 1 because of the meet and the join condition.
218
Definition 4.4: A bounded trilattice L := (L,
4.5: A c o m p l e m e n t e d trilattice B := ( B , < a , < 2 , < 3 )
is called a
B-trilattice, if its ordered structures are isomorphic Boolean lattices and x V i k Y ~k y holds for all { i , j , k } = {1,2,3}. T h e powerset trilattices are obviously B-trilattices. By L e m m a 4.1, the b o u n d a r y elements already determine the Boolean side diagrams. Moreover, as for Boolean lattices, the triadic c o m p l e m e n t a t i o n in B-trilattices is unique:
Proposition 4.6: Let c be a cycle of a B-trilattice B. If the join and the meet condition hold for x, y, z E r for an index i E {1, 2, 3}, then the (ordinary) complement xi in (Bi, <_i) satisfies x~ = Yi A zi. Moreover, x belongs to exactly one cycle of complements, denoted by c~, and all cycles of complements except {O1, O2, O3} have six elements if IB I > 1. Proof." By definition, the elements x, y, z satisfy xi A (yi A zi) = 0i. On the other hand, it follows xi V (yi A z~) = (xi V yi) A (x~ V zi) = li A li = li and thus Yi A zi is the (unique) c o m p l e m e n t of xi in (Bi, ~_i). To show the uniqueness of the triadic c o m p l e m e n t a t i o n for x E B we start with cl := x E c of a cycle c of complements, using the s a m e n o t a t i o n as in Fig. 4, and determine the position of c2 E r in the triangular net: Let Xl := OxVaacl. T h e n xa "~a ca " 1 co and xa >a cl, c6 from which xa <2 ca, c6 follows by antiordinality. T h u s Xl2 ~2 ca2 A c612 = e 22t which implies xa2 f _>2 c212. Thus, for x2 E B with x2 ~3 xa and z212 = Xl~ we obtain x2 >2 c2 and it easily follows t h a t also x2a = xa~ holds. As for xa we similarly deduce t h a t x3 := 02V32c2 <1 c2, c3 such t h a t x3a ~_a c2a A c3a = ca~ = Xl~ = x2a, i.e. x3 a x2 since x3 "~2 c2 <2 x2 and x3 " 3 x2, and hence xa "~a x2 which implies xa = x2 because of the uniqueness condition. Therefore xa~ = e212 which fixes the position of c2 ~ a ca. Now, repeating this a r g u m e n t for c2 instead of ca yields c413 = O2Va2e2~ fixing the positions of e4 "~2 ca and c5 "-q e~ and, because c is a cycle, also c3 and c6. In this way, we have d e t e r m i n e d the unique cycle of c o m p l e m e n t s r of x. If a cycle c of c o m p l e m e n t s has three elements then it follows r = {O1, O2, Oh} because of the join and the meet condition of cycles of c o m p l e m e n t s . Since two cycles of c o m p l e m e n t s of a B-trilattice are either disjoint or identical, we can define the triadic c o m p l e m e n t a t i o n as a (unary) operation:
Definition 4.7: Let B be a B-trilattice, let {i, j, k} = {1, 2, 3} and (ij) E $3 be a transposition. T h e n we define 0 (ij) := Ok, O~ij) := Oj and for all nonb o u n d i n g elements x E B we fix x (ij) E c= by x (ij) ~ x and x(ij) ~ x and define x ~~ := (x~') r if ~r, r E $3. T h e element x ~ is called the ~r-complement o f x .
219
According to the preceding proof, x(ij) can be determined as the intersection of xk and OiVki x'J, because {x( i~)} = xk N OiVaix~, and therefore as the intersecting point of the corresponding lines in the triangular net of the triadic diagram. Crucial for the characterization of powerset lattices as atomic and complete Boolean lattices are the so-called atoms, which are the upper covers of the smallest element 0. (Recall that a lattice (L, ~) with 0 is called atomic if for any x E L \ {0} there is an atom a with a _< x.) Here special cycles of complements, the so-called atomic cycles, will be needed to characterize the powerset trilattices. D e f i n i t i o n 4.8: An element a E L of a trilattice L is called an i-atom (i-coatom) for i E {1, 2, 3}, if ai is an atom (coatom) of ( i i , ~ x where { i , j , k } = {1,2,3}. By antiordinality we obtain x j,i i ak'j implies yi,j <~k ak'j by antiordinality, such that yi,j _~ Ok and hence y E l i . Since a k'i E 1~, it follows from Proposition 4.6 that (ak,ii A ak'Ji) ' is an atom in (B~, <~), i.e. the (ik)-complements of the k-atoms are/-atoms. Repeating this argument finally yields that for all i E {1, 2, 3} the cycle of complements ca consists of i-atoms, i-coatoms and elements in li and that ca C_ 5(B).
D e f i n i t i o n 4.10: A cycle of complements as in the previous proposition is called an atomic cycle (of complements) and abbreviated by a. If i E {1, 2, 3} then ai C_ a denotes the subset o f / - a t o m s in a, and P2(B__)is defined as the set of all atomic cycles of the B-trilattice B_. The Characterization
T h e o r e m : Let B_ be a B-trilattice with atomic and complete Boolean lattices as side diagrams. Then a triorder-isomorphism ~ :
B__-~ ~_(~(B)) can be de~ned by ~(x) :-- (~(x)l, ~(x)% ~(x)a) with ~ ( x ) i := {a E P.I(B) I a
220
Proof: First of all we show t h a t ~ is well-defined, i.e. ~a(x) E T(92(B__)). Obviously, ~ ( { O 1 , O 2 , O3}) C_ ff(92(B)). So, let x E B \ { 0 1 , 0 2 , 0 3 . ) , let { i , j , k } = { 1 , 2 , 3 } and assume a ~ ~(x)k. Then, for a E ai with a = a ~'~, it follows a >k x and, since a >j x, also a k a(ik)" Because x, x (ik), and x(ijk) satisfy the meet condition for k, we obtain x ~k a(ik), i.e. a ~ ~(x)k and ~ ( x ) l M~(x)2M~(x)3 = (Note t h a t a E ~a(x)j because of ~o(x)j U ~(x)k = 92(t3).). Next we ensure t h a t ~a is a triorder-embedding. Let x, y E B with x 1 z. But since also a(12) >3 z we obtain a (1~) <2 z ,-~ y and hence a E ~(Y)2. But we can also show a E ~(y)3 as follows. Since (B1, <_1) is an a t o m i c and c o m p l e t e Boolean lattice and z = x 3 V 3 1 x 1 e'a 1 X l w e conclude A = ~(Xl) 1 : ~(Z)l and, since a 5 z with a as the already chosen 1-atom, it follows a ~ ~o(z)~ = A which implies a E A3 because of A1 U A3 = 9./(13). But, since also y = x~713x3 "~3 x3 implies A3 = ~a(x3)3 = ~a(y)3, we get a E ~a(y)3. Therefore a E ~a(y)~ M ~(Y)2 M ~a(y)3 which contradicts ~(y) E ff(92(B)). Consequently y - ~ z and hence y = z. B u t then A1 = ~a(y)~ and A3 = ~(Y)3 and therefore 9(y) = ( A i , A 2 , A 3 ) showing t h a t ~ is a surjective triorder-embedding, i.e. an i s o m o r p h i s m . T h e o r e m 1 and the Characterization T h e o r e m i m m e d i a t e l y yield: Corollary:
5
A n y finite B - t r i l a t t i c e B with n a t o m i c cycles satisfies B ~- ff__(n) -~
Discussion
Should we now identify the B-trilattices with the Boolean trilattices? In fact, the B-trilattices have similar properties as Boolean lattices such as the unique comp l e m e n t a t i o n . T h e y also play an analogous role in the C h a r a c t e r i z a t i o n T h e o r e m . In this sense, the presented order-theoretic a p p r o a c h to B-trilattices corresponds to the definition of Boolean lattices as c o m p l e m e n t e d and distributive lattices.
221
From an algebraic point of view, Boolean lattices can equivalently be understood as algebras in which certain equations hold. There are the lattice equations, the distributive laws and identities concerning the (ordinary) complement. Trilattices, on the other hand, can algebraically be characterized by certain trilattice equations (cf. Bi98). But there is not yet an algebraic way to understand the B-trilattices. In fact, it has not been possible to equivalently express the defining properties of B-trilattices by suitable triadic equations. It becomes, for example, quite complicated to describe the distributive laws of the ordered structures as terms with/k-joins. In general, there seems to be no immediate and simple connection between the triadic operations of B-trilattices - the ik-joins and the ~-complements - and the Boolean operations for their side diagrams. So the next step is to find such unifying and simplifying triadic equations as the distributive laws and also identities concerning the triadic complements.
References Bi97
Bi98 DP90 Gr79 GW96 LW95
MB89 Wi95 Wi97
wz98
K. Biedermann: How Triadic Diagrams Represent Conceptual Structures. In: D. Lukose, H. Delugach, M. Keeler, L. Searle, J. Sowa (eds.), Conceptual Structures: Fulfilling Peirce's Dream, Lecture Notes in Artificial Intelligence 1257. Springer-Verlag, Berlin-Heidelberg-New York 1997, 304-317. K. Biedermann: An Equational Theory for Trilattices. FB4-Preprint, TU Darmstadt 1998. B.A. Davey, H.A. Priestley: Introduction to Lattices and Order. Cambridge University Press, Cambridge 1990. G. Gr~itzer: Universal Algebra. Springer-Verlag, Berfin-Heidelberg-New York, 1979. B. GanGer, R. Wille: Formale Begriffsanalyse: Mathematische Grundlagen. Springer, Berlin-Heidelberg 1996. F. Lehmann, R. Wille: A Triadic Approach to Formal Concept Analysis. In: G. Ellis, R. Levinson, W. Rich and J.G. Sowa (ed.). Conceptual Structures: Applications, Implementations and Theory. Lecture Notes in Artificial Intelligence 954. Springer-Verlag, Berlin-Heidelberg-New York 1995, 32-43. J. D. Monk, R. Bonnet (eds.): Handbook of Boolean Algebras. Elsevier Science Publishers B.V., Amsterdam-New York 1989. R. Wille: The Basic Theorem of Triadic Concept Analysis. Order 12 (1995), 149-158. R. Wille: Conceptual Graphs and Formal Concept Analysis. In: D. Lukose, H. Delugach, M. Keeler, L. Searle (eds.): Conceptual Structures: Fulfilling Peirce's Dream. Springer, Berlin-Heidelberg-New York 1997, 290-303. R. WiUe, M. Zickwolff: Grundlegung einer Triadischen Begriffsanalyse. In: G. Stumme, R. Wille: Wissensverarbeitnng: Methoden und Anwendungen. Springer, Berlin-Heidelberg 1998.
Simple Concept Graphs: A Logic Approach Susanne Prediger Technische Universit~t Darmstadt, Fachbereich Mathematik SchloBgartenstr. 7, D-64289 Darmstadt, prediger~mathematik.tu-darmstadt.de
Abstract. Conceptual Graphs and Formal Concept Analysis are combined by developing a logical theory for concept graphs of relational contexts. Therefore, concept graphs are introduced as syntactical constructs, and their semantics is defined based on relational contexts. For this contextual logic, a sound and complete system of inference rules is presented and a standard graph is introduced that entails all concept graphs being valid in a given relational context. A possible use for conceptual knowledge representation and processing is suggested.
1
Introduction
The first approach combining the theory of Conceptual Graphs and Formal Concept Analysis was described by R.Wille in 12. For connecting the conceptual structures in both theories, the concept types appearing in conceptual graphs were considered to be formal concepts of formal contexts, the constituents in Formal Concept Analysis. To facilitate this connection, concept graphs, appropriate mathematizations of conceptual graphs, were introduced. The theory of concept graphs of formal contexts was developed as a mathematical structure theory where concept graphs of formal contexts are realizations of abstract concept graphs. In this paper, a logic approach is presented by developing a logical theory for concept graphs. Therefore, concept graphs are defined as syntactical constructs over an alphabet of objects names, concept names and relation names (Section 2). Then, a contextual semantics is specified. We interpret the syntactical names by objects, concepts and relations of a relational context (Section 3). In this way, we can profit from all notions for concepts that have been developed in Formal Concept Analysis. The introduced contextual logic is carried on by the study of inferences (Section 4). Based on a model-theoretic notion for the entailment of concept graphs, a sound and complete set of inference rules is established and compared to the notion of projections between concept graphs. With the standard model, we can present another interesting tool for reasoning with concept graphs. In Section 5, we introduce a standard graph for a given relational context. It gives a basis of all concept graphs being valid in the relational context. In the last section, we suggest how this approach can be used for knowledge representation and processing.
226
2
Syntax
for the Language
of Concept
Graphs
We want to introduce concept graphs as syntactical constructs. Therefore, we need an alphabet of concept names, relation names and objects names. As the theory of conceptual graphs provides an order-sorted logic, we start with ordered sets of names that are not necessarily lattices. These orders are determined by the taxonomies of the domains in view, they formalize ontological background knowledge. D e f i n i t i o n 1. An alphabet of concept graphs is a triple (C, g, T~), where (C, <_c) is a finite ordered set whose elements are called concept names, g is a finite set whose elements are called object names, and (T~, < ~ ) is a set, partitioned into finite ordered sets (7~k, <_n~)k=l ..... n whose elements are called relation names. Now, we can introduce concept graphs as statements formulated with these syntactical names. That means, we consider the concept graphs to be the wellformed formulas of our formal language. In accordance with the first mathematization of conceptual graphs in 12, the structure of (simple) concept graphs is described by means of directed multi-hypergraphs and labeling functions. D e f i n i t i o n 2. A (simple) concept graph over the alphabet (C, g, T~) is a structure (3 := (V, E , L,, ~, p), where 9 (V, E , u) is a (not necessarily connected) finite directed multi-hypergraph, i. e. a structure where V and E are finite sets whose elements are called vertices and edges respectively, and v: E --+ Uk"=l Vk is a mapping (n > 2), 9 ~: V u E -~ C O 7~ is a mapping such that a ( V ) C_ C and a ( E ) C T~, and all e E E with ~,(e) = ( v l , . . . , v~) satisfy a(e) E T~k, 9 p: Y --+ ~(g)\{0} is a mapping. For an edge e e E with u(e) = ( v i , . . . , V k ) , we define lel := k, and we write d e ) l , := and p(e) := p(vl) x . . . x p(vk). Apart from some little differences, the concept graphs correspond to the simple conceptual graphs defined in 8 or 1. We only use multi-hypergraphs instead of bipartite graphs in the mathematization. The application v assigns to every edge the tuple of all its incident vertices. The function R labels the vertices and edges by concept and relation names, respectively, and the mapping p describes the references of every vertex. In contrast to Sowa, we allow references with more than one object name (i. e. individual marker) but no generic markers, i. e. existential quantifiers, yet. They can be introduced into the syntax easily (cf. 6), but in this paper we want to put emphasis on the elementary language. That is why we can omit coreference links here which are only relevant in connection with generic markers. 3
Semantics
for Concept
Graphs
We agree with J.F.Sowa, when he writes about the importance of a semantics: "To make meaningful statements, the logic must have a theory of reference that
227
determines how the constants and variables are associated with things in the universe of discourse." 9, p. 27 Usually, the semantics for conceptual graphs is given by the translation of conceptual graphs into first-order logic (cf. 8 or 1). For some notions and proofs, a set-theoretic, extensional semantics was developed (cf. 4), but it is rarely used. We define a semantics based on relational contexts. That means, we interpret the syntactical elements (concept, object and relation names) by concepts, objects and relations of a relational context. We prefer this contextual semantics for several reasons. As the basic elements of concept graphs are concepts, we want a semantics in which concepts are considered in a formal, but manifold way. Therefore, it is convenient to use Formal Concept Analysis, which is a mathematization of the philosophical understanding of concepts as units of thought constituted by their extension and intension (cf. 11). Furthermore, it is essential for Formal Concept Analysis that these two components of a concept are unified on the basis of a specified context. This contextual view is supported by Peirce's pragmatism which claims that we can only analyze and argue within restricted contexts where we always rely on preknowledge and common sense (cf. 12). Experience has shown that formal contexts are a useful basis for knowledge representation and communication because, on the one hand, they are close enough to reality and, on the other hand, their formalizations allow an efficient formal treatment. As formal contexts do not formalize relations on the objects, the contexts must be enriched with relational structures. Therefore, R.Wille invented power context families in 12 where relations are described as concepts with extensions consisting of tuples of objects. Using relational contexts in this paper, we have chosen a slightly simpler formalism. Nevertheless, this formalism can be transformed to power context families and vice versa. This is explained in detail in 5 and will not be discussed in this paper. Let us start with the formal definition of a relational context (originally introduced in 7). D e f i n i t i o n 3. A formal context (G, M, I) is a triple where G and M are finite sets whose elements are called objects and attributes, respectively, and I is a binary relation between G and M which is called an incidence relation. A formal context, together with a set fit := U~=I fitk of sets of k-ary relations on G is called relational context and denoted by K := ( ( G, fit), M, I). The concept lattice ~_~_(G,M, I) := (f~(G, M, I), <) is also called the concept lattice of K and denoted
by For the basic notions in Formal Concept Analysis like the definition of the concept lattice, please refer to 3. We just mention the denotation gS := {m E M / ( g , ra) E I} for g E G (and dually for ra E M) which will be used in the following paragraphs. Now, we can specify how the syntactical elements of (C, G, ~ ) are interpreted in relational contexts by context-interpretations. The object names are interpreted by objects of the context, the concept names by its concepts and the
228
relation names by its relations. In this way, we can embed the order given on C into the richer structure of the concept lattice. Order-preserving mappings are required because the interpretation shall respect the subsumptions given by the orders on C and TO. D e f i n i t i o n 4. For an alphabet A := (C, G, T~) and a relational context K := ((G, iR), M, I) we call the union t := tc 0 b9 0 t7r of the mappings ~c: (C, <_c) -+ ~__(E), tg: ~ -+ G and ~n: (T~, <_n) "-+ (iR, C) a K-interpetation of at if tc and ~ are order-preserving and we have tTc(T~k) C_ irk for all k = 1,... ,n. The tuple (IK, t) is called a context-interpretation of A. Having defined how the syntactical elements are related to elements of a relational context, we can explain formally how to distinguish valid statements from invalid statements. Due to our contextual view, the notion of validity also depends on the specified relational context. That means, a concept graph is called valid in a context-interpretation if the assigned objects belong to the extension of the assigned concepts, and if the assigned relations conform with the labels of the edges. Let us make these conditions precise in a formal definition. D e f i n i t i o n 5. Let (K, t) be a context-interpretation of .4. The concept graph r := (V, E, u, ~, p) over .4 is called valid in (K, t) if 9 tap(v ) C_ Ext(~c~(v)) for all v E V (vertex condition) 9 tap(e ) C tn~(e) for all e E E (edge condition). If @ is valid in (K, t), then (K, ~) is called a model for @ and q5 is called a concept graph of (K, t). Note that, theoretically, any formal context could be completed to a model if the relations and the interpretation were chosen in the right way. For a given concept graph ~5 := (V, E, ~, a, p), a formal context (G, M, I) and a given mapping ta: ~ -~ G, we can always define an order-preserving mapping tc:C --~ ~3(G, M, I) satisfying the vertex condition, for example the mapping with ~c (c) := V { (tap(v) II, tap(v) I) v e v, ~(v) ~_c c}. Thus, we can obtain a model by choosing appropriate relations and a mapping ~n. This shows that looking for an adequate model is not only a matter of formalism. It always depends on the specific purpose. There is one interesting model for every concept graph, namely its standard model. It codes exactly the information given by the concept graph. D e f i n i t i o n 6. Let @ := (7, E, L,, ~;,p) be a concept graph over the alphabet (C, ~, TO). We define the standard model of ~b to be the relational context IK~ := ((G, iro), C, I ~ together with the K ~ -interpretation t ~ := tc 0 t a (3 tn where tc:C --+ ~__(K~ with tc(c) := (cXO,cX~1*), ta := ida, iro := ~n(Tr The incidence relation I 0 C_ ~ • C and the mapping tn are defined in such a way that for all g 9 G, c 9 C, ( g l , . . . ,gk) 9 G~ and R 9 T~, we have the following conditions: (g,c) 9 I ~
.'. '.. B y 9
( g l , . . . , g k ) 9 i n ( R ) .' '.. Be 9 E :
g(v)
229
We can read this definition as an instruction of how to construct the standard model. As objects of the context, we take all object names in G, as attributes of the context, we take all concept names in C and we relate the object name g and the concept name ~(v) (i. e., set (g,~(v)) E I ~) if the object name g belongs to the reference p(v) of the vertex v. For preserving the order, we additionally relate g to every concept name c satisfying a(v)
Reasoning
with Concept
Graphs
E n t a i l m e n t a n d Validity in t h e S t a n d a r d M o d e l
Having specified a formal semantics, we can easily describe inferences on the semantical level by entailments. For this, we only consider concept graphs over the same alphabet in the whole section. We recall the usual definition. D e f i n i t i o n 7. Let 01 and 02 be two concept graphs over the same alphabet. We say that 01 entails 02 if 02 is valid in every model for 01. We denote this by 01 ~ 02. The following proposition explains how the entailment can be characterized by standard models (for the proof see appendix). P r o p o s i t i o n 1. The concept graph 01 entails the concept graph 02 if and only if 02 is valid in the standard model (K~ , t ~1) of 01. That means, using the contextual language, we obtain an effective method for deciding whether a concept graph entails another one or not. Beyond this, we could theoretically concentrate completely on the context level and describe the relation ~ by means of inclusion in the standard models as the following lemma shows. L e m m a 1. Let Ox and 02 be two concept graphs over the same alphabet with standard models (K ~1 , t ~1) and (K ~2 , t ~2 ), respectively. They satisfy
01 ~ 02
r
I ~1 ~ I v2 and ~1 (n) ~ L~2(R) for all R e n .
Although the lemma is not very practical for reasoning in general, it has important consequences. Firstly, we can see easily that the relation ~ is reflexive and transitive, i. e., it is a preorder. Secondly, it implies that equivalent concept graphs (i. e. concept graphs with O1 ~ O2 and 02 ~ O1) have identical standard models.
230
Finally, we can characterize the order that is induced by the preorder on the equivalence classes of concept graphs: the lemma shows how it can be characterized by the inclusions in the corresponding standard models. In particular, this allows us to describe the infimum and supremum of concept graphs by join and intersection in the standard model. The infimum of the two equivalence classes of the concept graphs 61 and 62 is the equivalence class of the juxtaposition 61 $ 62 (cf. 2). It is not difficult to see that the standard model of this juxtaposition is exactly the standard model one obtains by "joining the standard models": for (Kelee2,~v~e2), we have I e~ev2 = I vl U I e2 and L~'ee2(R) ----~ ( n ) U ~en2(R) for all n 9 n . Whereas it is a difficult task to construct the supremum of two equivalence classes (if it exists at all), we can deduce immediately from Lemma 1 that its standard model ( ~ L) is the intersection of the standard models. That means, we have I = I ~' N I e2 and ~n(R) = ~ ' ( R ) N ~ 2 ( R ) for all R 9 T~. We conclude that describing the order induced by ~ is much easier on the context level than it is on the graph level. Especially suprema and infima can be characterized easily. This shows that for some purposes, it is convenient to translate the information given in concept graphs to the context level. For other purposes, it is interesting to do reasoning only on the syntactical level. But how can we characterize inferences on the syntactical level? It is usually done in two ways: by inference rules that were inspired by Peirce's inference rules for existential graphs and by projections, i. e. graph morphisms t h a t can be supported by graph-theoretical methods and algorithms (cf. 8, 4).
4.2
Projections
Projections describe inferences from the perspective of graph morphisms. We recall the definition of projections as graph morphisms respecting the labeling functions (cf. 1). It is slightly modified for concept graphs.
Definition 8. For the two concept graphs {~1 : = (V1,EI,Vl,~;1,Pl) and 62 := (V2, E2, ~'2, ~2, P2) over the same alphabet, a projection from 62 to 61 is defined as the union 7rvOrE of mappings ~rv:V2 --~ V1 and rE:E2 --+ E1 such that lel =
=
and
2(e) / o r all
edges
e E E2 and for all i : 1 , . . . , lel; and r~1(~rv(v)) <_c t~2(v) and pl(rV(v)) D_p2(v) for all vertices v E V2. We write 61 ~ 62 if there exists a projection from 62 to 6t. The relation ~< defines a preorder on the class of all concept graphs, i. e., it is reflexive and transitive but not necessarily antisymmetric. It can be proved that this relation is characterized by the following inference rules (cf. 1, for concept graphs see 5): 1. 2. 3. 4.
Double a vertex. Delete an isolated vertex. Double an edge. Delete an edge.
231
C:
HUMAN
~ := {Hansel,Gretel,Witch}
ADULT CHILD WOMAN
(~I
CHILD: Hansel,Gretel
l
G2
I HUMAN:Gretel,Witch
I
~3
woM,.:wit
l-
I
"R, := {THREATEN}
IADULT:Witch
""
2
ADULT: Witch'
~4
ADULT: Witch
I~ 1 ~
2"---~1CHIL~: Hansel I
Fig. 1. Counter-examples to the Completeness of the Projection
5. 6. 7. 8.
Generalize a concept name. Generalize a relation name. Restrict a reference. Copy the concept graph.
That means, two concept graphs ~1 and ~52 satisfy ~1 ~< ~2 if and only if ~52 can be derived from ~1 by applying these rules (which are elaborated more precisely in the appendix). Note that the Rule 7 (restrict a reference) is different to the restriction rule defined in 1: Here, we cannot replace an individual maker by a general marker but delete an individual marker from the set of objects being the reference. It can be proved that these rules are sound (cf. 5). But as the examples in Figure 1 show, they are not complete. It is easy to see that ~2 must be valid in every model for ~1. On the other hand, it cannot be derived from ~1 because by these rules, references can only be restricted, not extended or joined. Even for concept graphs with references of only one element, the rules are not complete, when we consider redundant graphs. This is shown by the concept graphs ~3 and ~Sa. We have ~3 ~ ~4, but the concept name WOMAN cannot be replaced by ADULT with the given rules.
232
4.3 A. Sound and Complete Calculus for all Concept Graphs There are two ways to treat the incompleteness: restricting the class of considered concept graphs (e. g. to concept graphs of normal form like in 4) or extending the rules. As it is convenient for conceptual knowledge processing to allow all concept graphs instead of restricting them to normal forms, we decided to modify and extend the rules. (Note that the introduced rules are usually needed to transform a concept graph into normal form.) Definition 9. Let ~51 and r be two concept graphs over the same alphabet. We call r derivable from q51 and denote 01 ~- r if it can be derived by the following inference rules (which are elaborated in the appendix):
1.
Double a vertex. Double a vertex v and its incident edges (several times if v occurs more than once in v(e)). Extend the mappings ~ and p to the doubles. 2. Delete an isolated vertex. Delete a vertex v and restrict ~ and p accordingly. 3. Double an edge. Double an edge e and extend the mappings ~ and p to the double. 4. Delete an edge. Delete an edge e and restrict the mappings ~ and p accordingly. 5.* Exchange a concept name. Substitute the assignment v ~-~ ~(v) for v ~-+ c for such a concept name c E C for which there is a vertex w e V with ~(w)
p(v v w) = p(v)
u
p(w).
We will state these inference rules more precisely in the appendix and prove formally that they are sound and complete. Note that Rule 8 is redundant because it can be substituted by applying Rule i and 4.
233
Proposition 2 (Soundness and Completeness). Let 01 and 02 be two concept graphs over the same alphabet. Then, we have O1~O2
~
O1FO2.
Let us sum up what has been achieved. There are three possibilities for characterizing inferences on concept graphs. The usual model-theoretic way is the entailment (cf. Def. 7). On the syntactical level, we have a sound and complete set of inference rules (cf. Def. 9) whereas the projections cannot be used in the general case due to incompleteness. With their graphical character, the inference rules can visualize inferences and can be intuitively used to derive relatively similar concept graphs by hand. T h a t is why they can support communication about reasoning to a certain degree. For implementation and general questions of decidability, it seems to be more convenient to use the third notion to characterize inferences, namely validity in the standard model (cf. Prop. 1).
5
The
Standard
Graph
of a Relational
Context
The construction of a standard model for a given concept graph gives not only an efficient mathematical method for reasoning, but also a mechanism to translate the knowledge given in concept graphs to knowledge formalized in relational contexts. This possibility to translate from the graphical level to the contextual level is important for the development of conceptual knowledge systems. For such a conceptual knowledge system, the opposite direction is equally important. How can we translate knowledge given in relational contexts into the language of concept graphs? Obviously, we can state many different valid concept graphs for a given relational context. If we look for a so-called standard graph that codes the same information as the relational context, we have to look for a concept graph that entails all other valid concept graphs. For a similar purpose, R.Wille proposed a procedure to construct a canonical concept graph in 12. We will modify this procedure for our purpose here. We start with a relational context, say K := ((G, ~ ) , M, I). For constructing a concept graph, we need an alphabet (C,~,7~). We define C := ~B(K), G := G and T~ := ~ . For every index k = 1 , . . . , n, we determine for every relation R 9 ~ k all maximal k-tuples ( A 1 , . . . , A k ) of non-empty subsets of G being included in R. All those (k + 1)-tuples (R, A 1 , . . . , Ak) are collected in the set EK. T h a t means, we define for R E ~Rk the set Rei~nax(R) := {A1 •
• Ak C_ R I
B1 • ... • Bk C R implies B1 • ... • Bk ~ Ax • . . . A k } and obtain the set of edges
E~ :--
~.J {(R, A1,...,Ak) k=l,...,n
R 9 ~tk, A1 •
• Ak 9 Ref~aX(R)}.
234
Now, we define VK:={A C G I there exists a (R, A1,... ,A~) E EK with A = Ai for an i _< k} U
{gXX C_G i g E G}, n k and set v~ : EK -+ Uk=iV~ with vg(R, At,...,Ak) := (A1,...,Ak) and aK : VK O E,: -+ ~B(K) U fit where r~K(R,A1,..., Ak) := R and ~K(A) := (A I1, A:). Finally, we can choose pK(A) := A for all A E VK. In this way, we obtain a concept graph r := (VK,EK, vK, ~K, PK) that is valid in (IK,id) and is called the standard graph of 1~
P r o p o s i t i o n 3. The standard graph r
of a relational context E entails every
concept graph ~5' that is valid in (K, id). This proposition (which is proved in the appendix) guarantees the demanded property of the standard graph. It is an irredundant graph that entails all concept graphs which are valid in its context. Thus, the standard graph is the counterpart to the standard model. With the standard model, we gather all the information given in the concept graph and have a tool to translate it from the graph level into the context level. Vice versa, we can translate information from the context level to the graph level by constructing the standard graph. The relationship between a context K and the context K~ , belonging to the standard model (K ~ , ~o(k')) of O(K) can also be described: The proof of Prop. 3 shows that the context IKo(K) only differs from K because its set of attributes is not reduced and the attributes have different names. Their concept lattices are isomorphic. Vice versa, starting with a concept graph q5 and constructing the standard model (IK~ , ~o), we cannot say that the standard graph of K~ is isomorphic to q5 in the formal sense because it is not a concept graph over the same alphabet. Nevertheless, it encodes the same information in an irredundant form. 6
Contextual
Logic for Knowledge
Representation
With the approach to contextual logic presented in this paper, we have proposed a logic for concept graphs that is equipped with a model-theoretic foundation and in which inferences can be characterized in multiple ways. From a computational point of view, an efficient method has been presented to do reasoning by checking validity in the corresponding standard models. The major domain of application we have in mind for this logic, is conceptual knowledge representation and processing. In particular, the contextual semantics allows an integration of concept graphs into conceptual knowledge systems like TOSCANA that are based on Formal Concept Analysis. Vice versa, an integration of concept lattices and various methods of Formal Concept Analysis into tools for conceptual graphs is possible. For this purpose, the separation of syntax and semantics is less important than the possibility of expressing knowledge on two different levels, the graph level and the context level. With the
235
standard model and the standard graph, we have developed two notions that help to translate knowledge from one level to the other. With it, the foundation is laid for conceptual knowledge systems which combine the advantages of both languages. For example, we can imagine a system that codes knowledge in relational contexts and provides, with the concept graphs, a graphical language as interface and representation tool for knowledge. In such a system, the knowledge engineer could extend a given knowledge base by constructing new concept graphs over the existing alphabet. Then, implemented algorithms on the graph level or on the context level (whatever is more convenient for the special situation) could check whether the new concept graph is already valid in the context (i. e., the information is redundant) or whether it represents additional information. Concept lattices could be used to find the conceptual hierarchy on the concepts and to determine the conceptual patterns and dependencies of concepts and objects. Obviously, we could profit from all the methods and algorithms already existent for conceptual graphs. The architecture of conceptual knowledge systems including relational contexts and concept graphs should be discussed, and the role of the different languages should be further explored. As the expressivity of the developed language is still quite limited, the extensions by quantifiers and nested concept graphs are considered in current research. 7
Appendix:
Formal
Proofs
P r o o f of P r o p o s i t i o n 1. We only have to prove that O2 is valid in an arbitrary model (K, A) for O1 with K := ((G, ~R),M, J) and A :-- A~ 0 Ac 0 Ar~ if O2 is valid in the standard model ( l ~ ' , ~vl) of Oi with l ~ 1 = ((g, 9~v~), C, I ~'). As a result of the vertex condition for Oi in the model (II~A), we have ~gpi(v) C_ ExtAchi(v) C Ext)~c(c) for all concept names c E C and for all vertices v E Vi with hi(v) <__c c (because Ac is order-preserving). It follows ~ g ( U ( p i ( v ) I v E Vi,hi(v) _
P r o o f of Soundness: r H r =~ ~51 ~ r Due to the transitivity of ~, it suffices to show soundness for each single inference rule. Therefore, we will give the exact definition of every inference rule by describing the derived concept graph O2. Then, we can prove the entailment by using Prop. 1 and checking that ~52 is valid in the standard model (K~ , e ~ ) of O1 := (Vi,Si,ui,tci,Pi). Because of L~~ :-- ida, E x t ( ~ l c ) = U{pi(v) I v E Vl,hl(v) ~C C} for all c E C and ~ ' R = U{pi(e) I e E El,hi(e) ~ n R} for all R E T~ (cf. Def. 6), we only have to convince ourselves that 02 satisfies the following vertex and edge conditions:
236
w
E
v2: p2( ) c_ U(pl(v) Iv e vl, l(v) _
Vy E E~: p2(f)
_c U{pl(e)
e E E~,~l(e) <_n n2(f)}
(vertex condition) (edge condition).
1. Double a vertex. The concept graph derived by doubling the vertex v E V1 is ~z := (V2, E2, u2, ~2, p2) which is defined by 9 V2 := V l \ { V } O { ( v , 1),(v, 2)}, 9 E2 := E1 \ E , 0 E v with E~ := {e E E1 vl(e)i = v for some i = 1 , . . . , e} and E ~ := {(e,6) e E E , , 6 E {1,2} e''} where e,v := {i I vl(e)i = v}, 9 I)2EI\E v : = IJlEI\E,, and vl(e), if i f~ e,v := (v,6(i)) if i E e,v for all (e,6) E E",
2.
3.
4.
5.*
6.*
9 a2:V2 U E2 --+ C U 7E x ~+ ~l(x) for all x E Vl\{V} U E I \ E , (v,j) ~+ ~l(v) for j - - i , 2 (e, 5) ~-~ al (e) for all (e, g) E E v, 9 P2VI\{v} : = PlVi\{v} and p 2 ( v , j ) : : p l ( V ) for j = 1,2. For this derived concept graph @2, the vertex and edge condition can be checked easily. It is left to the reader. Delete an isolated vertex. If v q V1 is an isolated vertex of @1 (i.e., there is no edge e E Ei and no i = 1 , . . . , e with vx(e)l~ = v), the components of the concept graph @2 derived by deleting the isolated vertex v are defined as follows: V2 := Vx\{v}, E2 := El, v2 := v~, ~2 := ~llv~uml and P2 := Piv~. These components obviously satisfy the vertex and edge conditions. Double an edge. The concept graph @2 derived by doubling the edge e E E~ is defined by V~. := V1, E2 := E i \ { e } U {(e, 1), (e, 2)} where (e, 1), (e, 2) r El, v2El\{e} := VlE~\{e} and v2(e,j) := vl(e) for j = 1,2, ~2V~u(E~\{e}) := ~IV~u(E1X{e}) and a2(e,j) := ~l(e) for j = 1,2 and p2 := pl. It satisfies the vertex and edge conditions. Delete an edge. Deleting the edge e E Et, one obtains the concept graph ~52 := (V1,EI\{e}, vxl~,k{~),~lv~u(E~k{d),pl) which satisfies the vertex and edge conditions. Exchange a concept name. The concept graph derived by substituting the concept name ~;l(v) for a c E C for which there is a vertex w E V1 with ~1 (w)
237
7. Restrict references. The concept graph derived by restricting the reference pl(v) of the vertex v E V1 to the reference A with 0 # A C_pi(v), is defined by 62 := (V1,EI,pl,tCl,p2) with P2vl\{.} := PlVl\{v} and p2(v) := A. From A C_ Pi (v) we deduce the vertex condition.
8. Copy the concept graph. For a copied concept graph 62, there exist two bijections ~ov:V1 ~ V2 and ~01v : Ei --+ E2 such that ~i(v) = R2(~ov(v)) and pi(v) = p2(~ov(v)) for all v E V1, and ~ov(vl(e)) -- v2(tpE(e)) and tq(e) = tc2(~oE(e)) for all e E E l . It trivially satisfies the vertex and edge conditions. 9*. Join vertices with equal references. The concept graph derived from 6 i by joining the two vertices v and w with equal references (i. e. with Pt (v) = pi(w)) is 6 z := (V2,Ei,u2,~;2,P2) with 9 v, := vA{v,w}0{vvw}, vVw
9 u2li(e):=
uz(e)i
=vor,,~(e)l~ =~ otherwise
ifvl(e)li
for all e E E l , i -- 1 , . . . , le, 9 ~2(vl\{v,~,})uE1 := ~i(vl\{~,w})usl and ~2(v Vw) := c for a c E C with ~l (v) _<e c and ~i (w) _
238
Let @i and ~2 be two concept graphs with ~5i ~ 02 and let P2 be a star of q52 with edge f and vertices wi, w 2 , . . . , wk. For deriving P.I from ~bi, we proceed in three steps. (i.) First, we derive stars from r such that, for every tuple ( g i , . . . ,gk) of objects in p ( f ) , there is a star P2g~..... g~ with edge %1 ..... g~ and P(%1 ..... g~) = (ii.) Then, we join these stars in several steps by joining the corresponding vertices. We obtain a star ~ with an edge f ' t h a t has the same references as the star ~ / o f q52. But it does not necessarily have the same concept and relation names. iiii.) In order to a d a p t the concept and relation names by Rules 5, and 6", we first have to derive isolated vertices vi for every vertex wi of 9/with ai (vi) = a2(wi) and pi(vi) D_ p2(wi). Then, we can finally deduce a copy of P / f r o m i) As 92 is valid in the standard model (Kol,~ v~) and a 2 ( f ) E TO, there exists a set T C ~ i ( E i ) of relations such t h a t ~ 1 ~ 2 ( f ) = .J {~r I R E T}. Consequently, for all ( g i , . . . , g ~ ) E P2(f), there exists an R E T such t h a t ~ ( g i , . . . . gk) = (gl,... ,gk) E ~ ' ( R ) . Because of R E a i ( E i ) , we can find an edge eg, .....g~ E E i with ( g i , . . . , g k ) E pi(eg~ .....g~). By means of Rule 2 and 4 (delete vertices and edges), we can derive, for all tuples ( g i , . . . , g k ) E P2(f), the corresponding star of r with the edge eg~ ..... g~. Using Rule 7 (restrict references), we restrict the references to g i , . . . , gk. In this way, we derive stars denoted by ~al ..... ~ with vertices denoted by v a ~ , . . . , v ~ . ii) In the first substep, we join the k *h vertices of all stars 9/ai ..... a* where the first k - 1 references are identical. For every tuple (gi,. 9 g k - i ) E P2 (wi) x 9 . . • p2(Wk-1), we consider all stars P.lyl .....g*-*,~* with gk E p 2 ( w k ) and unify the relation names ~(eyl .....y,_~,~) by Rule 6* (exchange relation names) into a common relation name Re~ .....~ _ . As all g~ belong to p2(wk), they satisfy ~(ey 1.....y,_~,~,) <_n ~(f). Thus, we find a common relation name Re~ .....~_~ <_7~ re(f). Thereafter, we join the k ~" vertices of all changed concept graphs ~Y~ ..... Y~- ~,~ by Rule 10" (join vertices with corresponding edges). Then, we join their first, then second, and finally (k - 1) *~ vertices. After deleting the double edges (Rule 4), we obtain a star with k vertices t h a t we denote by P2y~..... Y~-~. It has an edge ey, .....Y~-l, and we have p(ey 1.....y~_~) = {gl) • " ' " • {gk-1) • p 2 ( w k ) and In the second ~ubstep, we join the vertices of all those stars P2g l . . . .g.~. i (which all have the same k t h reference) t h a t correspond in the (k - 1) t h reference. Applying Rule 6", 10" and 4, we obtain concept graphs P2a~..... ~ - ~ with the edge eg~ ..... ~ - 2 satisfying p(e~ .....~_~) = {gi} • ... • {gk-2} • p2(Wk-i) • p2(W~). After k steps of joining, we obtain a star ~ with edge f ' t h a t has the same references as the edge f of ~. iii) As P.I is valid in the standard model ( K ~ i , ~ ) , every vertex w~ of P2 satisfies p2(w~) C_ E x t ( ~ " ~2(w~)) = _J {pi(v) I v E Vi,~i(v) _
239
all isolated vertices v 9 V1 with at(v) _ c ~2(wi). By means of Rule 10" (join vertices with corresponding edges), they can be joined into an isolated vertex vi with r~l(vi) = a2(wi) and pt(vi) ~_ p2(wi). Finally, we can exchange the concept and relation names (Rules 5* and 6*) and, by means of Rule 2 (delete all isolated vertices), we obtain a concept graph that is isomorphic to 92. Taken as a whole, this proves O1 ~- 91. P r o o f o f P r o p o s i t i o n 3. Let ~ be valid in (~f~id). We prove the assertion by showing that ~ ' is valid in the standard model of the standard graph ~5(K) := and by using Prop. 1. The standard model (K ~ , ~ ) of the concept graph with K ~ = ((G,~R),~__(IK),I~) satisfies ~ = idc, and ~Vm(R) = U {pK(e) I e 9 E , ~K(e) < R} = R for all R 9 3 . This implies ~ = id~n. Consequently, the edge condition for ~ in (K~,~ ~) is satisfied. Furthermore, we have ec~(C) := (c I• ,c I~I~) and, according to the definition of the incidence relation in the standard model, we have for every concept name c 9 C the equations cI~ := U {pK(A) aK(A) _< c} = U {glX (gH, gl) _< c} = U {gH I g 9 cI} = cl. Thus, the vertex condition is also satisfied. 3
References 1. Chein, M., Mugnier, M.-L.: Conceptual Graphs: Fundamental Notions. Revue d'Intelligence Artificielle 6 (1992) 365--406 2. Chein, M., Mugnier, M.-L.: Conceptual Graphs are also Graphs. Rapport de Recherche 95003, LIRMM, Universitd Montpellier II (1995) 3. Ganter, B., Wille, R.: Formal Concept Analysis: Mathematical Foundations. Springer, Berlin-Heidelberg, to appear 1998 4. Mugnier, M.-L., Chein, M.: Reprdsenter des Connaissances et Raisonner avec des Graphes. Revue d'Intelligence Artificielle 10 (1996) 7-56 5. Prediger, S.: Einfache Begriffsgraphen: Syntax und Semantik. Preprint, FB Mathematik, TU Darmstadt (1998) 6. Prediger, S.: Existentielle Begriffsgraphen. Preprint, FB Mathematik, TU Darmstadt (1998) 7. Prifl, U.: The Formalization of WordNet by Methods of Relational Concept Analysis. In: FeUbaum, C. (ed.): WordNet - An Electronic Lexical Database and some of its Applications. MIT-Press (1996) 8. Sowa, J. F.: Conceptual Structures: Information Processing in Mind and Machine. Adison-Wesley, Reading (1984) 9. Sowa, J. F.: Knowledge Representation: Logical, Philosophical, and Computational Foundations. PWS Publishing Co., Boston, to appear 1998 10. Wermelinger, M.: Conceptual Graphs and First-Order Logic. In: Ellis, G. et al. (eds.): Conceptual Structures: Applications, Implementations and Theory, Proceedings of the ICCS '95. Springer, Berlin-New York (1995) 323-337 11. Wille, R.: Restructuring Mathematical Logic: an Approach based on Peirce's Pragmatism. In: Ursini, A., Agliano, P. (eds.): Logic and Algebra. Marcel Dekker, New York (1996) 267-281 12. Wille. R.: Conceptual Graphs and Formal Concept Analysis. In: Lukose, D. et. al. (eds.): Conceptual Structures: Fulfilling Peirce's Dream, Proceedings of the ICCS'97. Springer, Berlin-New York (1997) 290-303
Two FOL Semantics for Simple and Nested Conceptual Graphs G. Simonet LIRMM (CNRS and Universit Montpellier II), 161, rue Ada, 34392 Montpellier Cedex 5, France, te1:(33)0467418543, fax: (33)0467418500, email: simonet~lirmm.fr
A b s t r a c t . J.F. Sowa has defined a FOL semantics for Simple Conceptual Graphs and proved the soundness of the graph operation called projection with respect to this semantics. M. Chein and M.L. Mugnier have proved the completeness result, with a restriction on the form of the target graph of the projection. I propose here another FOL semantics for Simple Conceptual Graphs corresponding to a slightly different interpretation of a Conceptual Graph. Soundness and completeness of the projection with respect to this semantics are true without any restriction. I extend the definitions and results on both semantics to Conceptual Graphs containing co-reference links and to Nested Conceptual Graphs.
1
Introduction
The Conceptual Graphs model has been proposed by J.F. Sowa 11 as a Semantics Networks one in Knowledge Representation. J.F. Sowa has defined a FOL (First Order classical Logic) semantics denoted by 9 for Simple Conceptual Graphs and proved the soundness of the graph operation called projection with respect to this semantics. M. Chein and M.L. Mugnier 1,5 have studied the basic model of Conceptual Graphs and several of its extensions. Among other results, they have proved the completeness of the projection with respect to the semantics 9 in Simple Graphs, with a restriction on the form of the target graph of the projection. This result shows that reasoning on Conceptual Graphs may be performed using graph operations instead of logical provers. The semantics has already been extended to Nested Conceptual Graphs in non-classical logics with "nested" formulas, i.e. formalisms in which a formula may appear as an argument of a predicate 11. Thus the structure of a Nested Graph is directly translated into the structure of a nested formula. These logics are similar to the logics of contexts of 4 and 3. A. Preller et al. 6 have defined a sequent formal system with nested formulas and proved the soundness and completeness of this formal system with respect to the projection in the Simple and Nested Graphs models. More details about related works may be found in 2. I propose here a slightly different interpretation of a Conceptual Graph which leads to the need for co-reference links in Simple Graphs and to another FOL semantics denoted by ~. Projection is shown sound and complete with respect to
241 the semantics k~ without any restriction. Then the definitions and results a b o u t the semantics 9 and ~ are extended to Nested Graphs. More details a b o u t these extensions m a y be found in 10,9. 2 2.1
Simple
Graphs
Basic notions
I briefly recall the basic (simplified) definitions: support, SG, projection, semantics qs, normal graph, normal form of a graph, as well as the soundness and completeness result. For more details on these definitions, see 11,1,5. I first specify some notations. Any partial order is denoted by <. ~ is the entailment relation symbol in FOL. Basic ontological knowledge is encoded in a support S = (Tc, T~, I). Tc and TR are type sets, respectively a set of concept types and a set of relation types, partially ordered by an A-Kind-Of relation. Relation types m a y have any arity greater or equal to 1, and two comparable relation types must have the same arity. I is a set of individual markers. All supports also possess a generic marker denoted by .. The following partial order is defined on the set of markers I U {*}: * is the greatest element and elements of I are pairwise noncomparable. Asserted facts are encoded by Simple Graphs. A SG (Simple Graph) on a support S, is a labelled bipartite graph G = (R, C, E, l). R and C are the node sets, respectively relation node set and concept node set. E is the set of edges. Edges incident on a relation node are totally ordered, they are numbered from 1 to the degree of the relation node. The ith neighbor of relation r is denoted by Gi(r). Each node has a label given by the mapping I. A relation node r is labelled by a relation type type(r), and the degree of r is equal to the arity of type(r). A concept node c is labelled by a couple (type(c), ref(c)), where type(c) is a concept type and tel(c), the referent of c, either belongs to I - - then c is an individual node - - or is the generic marker * - - then c is a generic node. The SG of Figure 1 represents the information: a person looks at the photograph A (the generic referent * is omitted).
Personl
~
Photography:AI
Fig. 1. A Simple Graph
A projection from a SG G = (RG, CG, EG, IG) to a SG H = (RH, CH, EH, 1H) is a mapping /7 from R c to RH and from C a to CH which 1. preserves adjacency and order on edges: Vrc 9 EG II(r)II(c) 9 EH and if c = Gi(r) then/-/(c) = Hi(II(r)) 2. m a y decrease labels: Vx 9 RG U CG Ig(II(x)) < lG(X).
242
The partial order on relation labels is that of TR. The partial order on concept labels is the product of the partial orders on T c and on I U {*}. SGs are given a semantics in FOL, denoted by 9 11. Given a support S, a constant is assigned to each individual marker and an n-adic (resp. unary) predicate is assigned to each n-adic relation (resp. concept) type. For simplicity, we consider that each constant or predicate has the same name as the associated element of the support. To S is assigned a set of formulas 4~(S) which corresponds to the interpretation of the partial orderings of TR and Tc. ~(S) is the set of formulas Vxl...Xp(t(Xl, ..., Xp) --~ t~(Xl, ..., Xp)), where t and t ~ are type such that t < t ~ and p is the arity of t and t ~. 9 maps any graph G on S into a formula ~(G) in the following way. First assign to each concept node c a term which is a variable if c is generic, and otherwise the constant corresponding to tel(c). Two distinct generic nodes receive distinct variables. Then assign an atom to each node of G: the atom to(e) to a concept node c where tc stands for the type of c and e is the term associated with c; the atom t~(el, ..., %) to a relation node r where $r stands for the type of r and ei is the term associated with the ith neighbor of r. r is the existential closure of the conjunction of these atoms. E.g. the formula associated with the graph of Figure 1 is 4~(G) -3yly2( Person(yl ) A Look(y2) A photograph(A) A agent(y2, Yl) A object(y2, A ) ). Projection is sound and complete with respect to the semantics ~, i.e.: given two SGs G and H defined on S, if there is a projection from G to H then ~(S), qh(H) ~ ~(G) (soundness 11); conversely, if H is normal and 9 (S), ~ ( H ) ~ ~(G) then there is a projection from G to H (completeness 5). A graph is normal iff each individual marker appears at most once in concept node labels. A graph G can be transformed into a normal graph G ~ (called the normal form of G) by merging all concept nodes having the same individual referent, provided that these nodes have the same type. The formulas ~(G) and ~(G ~) axe trivially equivalent. Figure 2 is a counterexample to the completeness result when H is not normal. ~(G) = t(a) A r(a, a) and ~(H) = t(a) A t(a) A r(a, a).
G
Fig. 2. Counterexample to the completeness result in SGs with
4~(S), ~ ( H ) ~ ~(G) (as ~ ( H ) and ~(G) are equivalent formulas) but there is no projection from G to H . The normal form of H is G. 2.2
C o - r e f e r e n c e links
According to the semantics ~, merging several individual nodes having the same referent (i.e. representing the same entity) does not change the meaning of the graph. However, in some applications, it may be useful to represent the same
243
entity with different concept nodes corresponding to different aspects or viewpoints on this entity, so that merging these nodes would destroy some information. Moreover, the different concept nodes representing the same entity may have different types (and therefore different labels in the graph) according to the different aspects of the entity that they represent. When a specified individual is represented by several nodes, the individual marker suffices for expressing that these nodes represent the same entity. But in the case of an unspecified entity represented by several generic nodes, an additional structure, called a co-reference link, is needed. A SG ~ef (SG with co-reference links) is a graph G = (R, C, E, l, co-re f), where co-ref is an equivalence relation on the set of G generic nodes (the coreference relation).The intuitive semantics of co-ref is "represents the same entity as". Any SG may be considered as a SG tel in which the co-reference relation is reduced to the identity one. The relation co-ref is naturally extended to an equivalence relation co-ident on the set C of all concept nodes of G (the coidentity relation). Every equivalence class for the co-identity relation is a set of concept nodes representing the same entity which are either co-referent generic nodes (in that case they are explicitly linked by a co-reference link in a graphical representation of G) or individual nodes having the same referent. Vc, cI E C, co-ident(c, cI) iff (co-ref(c, cI) or ref(c) = r e f ( d ) E I) The definitions and results on SGs are modified as follows by the introduction of co-reference links. A projection from a SG ref G = (RG, Cc, EG, IG, corefG) to a SG ref H = (RH,CH,EH, IH,co-refH) is a projection H from the SG (RG, CG, EG, lv) to the SG (RH, CH, EH, lH) that preserves co-identity, i.e. Vc, c' E CG if co-refG(c,e ~) then co-identH(lI(c),II(d)). Note that the co-identity of individual nodes is already preserved: for any c, d E CG, if ref(c) = r e f ( d ) E I then ref(II(c)) = ref(II(c')) = ref(c) E I. 9 may be extended to SGre/s by assigning the same variable to co-referent generic nodes. A SG re$ is normal iff it contains no co-reference links and each individual marker appears at most once in concept node labels (i.e. iff the co-identity relation is reduced to the identity one). The normal form of a SG ref G is obtained from G by merging its co-identical nodes (provided that they have the same type). Therefore co-reference links in a SG G have no real interest when G is interpreted according to the semantics ~. Their interest will appear with the semantics ~P and in Nested Graphs for both semantics. 2.3
A n o t h e r FOL s e m a n t i c s
The goal here is to modify the semantics q~ into a semantics ~P which would express the fact that the same entity is represented by several concept nodes. The structure of a graph G should be fully represented in ~P(G), which is not the case in ~(G). kV(G) is defined as follows. Two terms are assigned to each concept node c of G. The first term e~ represents the co-identity class ~ of c: the constant corresponding to tel(c) if c is an individual node, otherwise the variable assigned to the co-reference class of c (e~ is the term assigned to c in 4~(G)). The second
244
t e r m ec is a variable representing the node itself. All these variables are distinct. Assign the a t o m tc(e~, er to each concept node c and the a t o m tr(ecl, ..., ecp) to each relation node r of G, where ci is the ith neighbor of r. Y(G) is the existential closure of the conjunction of these atoms. E.g. in Figure 2, ~ ( G ) = 3xl(t(a, xl) Ar(Xl, Xl)) and ~(H) = 3xlx2(t(a, xl) At(a, x2) Ar(Xl, x2)). Y(S) is defined as ~5(S), except t h a t predicates associated with concept types become binary. Projection is sound and complete with respect to this semantics without any restriction. T h e o r e m 1. Let G and H be two SGr~I s. ~(S), Y(H) ~ O(C) iff there is a projection from C to H. E.g. in Figure 2, ~ ( S ) , Y ( H ) ~ Y(G) and there is no projection from G to H . P r o o f : the proof is similar to t h a t with the semantics ~. However it is given here because the complete proof with # (for SGs) is only available in French 5 and because Lemmas 1 and 2 will be used for NGr~Ys. For any formula F , let C(F) denote the clausal form of F. C(Y(H)) is the set of atomic clauses obtained from kO(H) atoms by substituting Skolem constants to the variables. Let p be this substitution. C ( - ~ ( G ) ) contains a unique clause whose literals are the negations of @(G) atoms. The Herbrand Universe UH of the formula @(S) A @(H) A --@(G) is the set of constants appearing in C(@(H)) or in @(G). A @-substitution from G to H w.r.t, p (in short @-substitution from G to H ) is a substitution a of the variables of @(G) by UH constants such t h a t for any a t o m t(el,...,en) of ~ ( G ) , there is t' <_ t such t h a t a(t'(el, ...,en)) is an a t o m of C(Y(H)) (i.e. for any a t o m t(el, ..., en) of Y(G), there is an a t o m t'(etl, ..., e In) of q~(H) such t h a t t' < t and for any i in {1, ..., n}, a(e,) -= p(e~)). Theorem 1 immediately follows from Lemmas 1 and 2. L e m m a 1: Y ( S ) , Y ( H ) ~ Y(G) iff there is a Y-substitution from G to H. P r o o f : let C = C(Y(S) A ~ ( H ) A --Y(G)). Y(S), Y ( H ) ~ # ( G ) iff C is unsatisfiable. If there is a O-substitution from G to H then the e m p t y clause can be obtained from C by the resolution method, so C is unsatisfiable. Conversely, let us suppose t h a t C is unsatisfiable. Let v be the Herbrand interpretation defined by: for any predicate t of arity n and any constants a t , ..., an of UH, v(t)(al,..., an) is true iff there is t' _< t such t h a t t'(al, ..., an) is an a t o m of C(Y(H)). v is a model of C(Y(S) A Y(H)). Then v is not a model of C(-~Y(G)), which provides a Y-substitution from G to H . L e m m a 2: I there is a projection H from G to H then there is a Y-
substitution a from G to H such that for any concept node c of G, a(ec) = p(en(c)) and a(e~) = p(e~(c) ). Conversely, if there is a Y-substitution a from G to H then there is a projection II from G to H such that for any concept node c of a ,
=
a n d o(e
) =
P r o o f : let us suppose that there is a p r o j e c t i o n / / f r o m G to H . For any variable x of Y(G), let c be the concept node of G such that x = ec (resp. e~) and let a(x) be the UH constant p(ert(c)) (resp. p(e~(c))). Then for any concept node c of G, a(ec) = p(ei(c)) and a(e~) = p(e~(c) ). For any a t o m t(el, ...,en) of Y(G), let s be a node of G associated with this atom. The a t o m of Y ( H ) associated
245
with II(s) is in the form t'(e~, "-',e'), with t' <_ t and for any i in {1, ...,n}, a(ei) = p(e~), a is a ~P-substitution from G to H. Conversely, let us suppose that there is a ~P-substitution a from G to H . For any node s of G, let t(el, ..., e,~) be the atom of ~P(G) associated with s and let lI(s) be I a node of H associated with an atom in the form t'~l,/e' .-., e~), with tl <_ t and for any i in {1, ...,n}, a(ei) = p(e~). Then for any node s of G, type(11(s)) < type(s) and for any concept node c of G, a(ec) = p(eH(c)) and a(e~) = p(e~(c) ). 1I fullfills the label-decreasing condition. Let us shooT that it preserves adjacency and order on edges. If c = Gi(r) then a(ec) = p(er/(c)) = P(eH,(II(r))), then II(c) = Hi(1-I(r)). Note that with the semantics 4~, we only have a(e-e) = p(e~(~)) = p ( e ~ ) , then 11(c) = Hi(11(r)) and we need the normality condition to ensure that 11(c) = Hi(11(r)). Let us s h o o t that 11 preserves coidentity. If co-refv(c, c') then ~ = c', then a(e-e) = a(ev) = p(e~(c) ) = p(eH---(~), then 11(c) = / - / ( c ' ) , i.e. co-identH(H(c), II(c')). 11 is a projection from G to H .
3 3.1
N e s t e d Graphs The model
The Nested Graphs model allows to associate with any concept node a partial internal description in the form of a Nested Graph. E.g. the Nested Graph (with co-reference links) of Figure 3 is obtained from the SG of Figure 1 by adding the partial internal description to the concept node labelled (photograph,A): the photograph represents a person on a boat (and adding a co-reference link to express that the person on the boat is the person looking at the photograph). A NG (Nested Graph) G, its depth depth(G) and the set UCG of concept nodes
IP~176176
Photography: A
(co-reference link) Fig. 3. A Nested Graph with co-reference links
appearing in G are defined by structural induction. 1. A basic NG G' is obtained from a SG G by adding to the label of each concept node c, a third field, denoted by Desc(c), equal to ** (the empty description); depth(G') = 0 and UCG, = CG, -- CG. 2. Let G be a basic NG, cl, c2, ..., ck concept nodes of G, and G1, G2, ..., Gk NGs. The graph G' obtained by substituting Gi to the description ** of ci for i = 1, ..., k is a NG; depth(G') = 1 + max{depth(Gi), 1 < i < k} and UCa, = C a u (U~<~
246 It is i m p o r t a n t to note (for the following definition of A(G)) t h a t if a SG or NG H is used several times in the construction of a NG G, we consider t h a t several copies of H (and not several times the graph H itself) are used in the construction of G. A NG can be denoted by G = (R, C, E, l) as a SG except t h a t the label l(c) of any concept node c has a third field Desc(c) (in addition to the fields type(c) and tel(c)) which is either ** or a NG. A complex node is a concept node c such t h a t Desc(c) is a NG. The set of complex nodes of G is denoted by D(G). A NGr~/ (NG with co-reference links) is a graph G = (R, C, E, l,co-ref), where co-tel is an equivalence relation on the set of generic nodes appearing in G. NGr~Ys are defined by structural induction from S G ~ I s as NCs from SGs, with the following definition of co-ref. If Gr is the basic NG ref obtained from a SG re/ G, then co-refG, = co-refG. If G' is the NG ~ / obtained from a basic NG ref G, concept nodes ci of G and NGreYs Gi, then co-refG, is an equivalence relation on the set of generic nodes of UCG, such t h a t its restriction to the set of generic nodes of CG (resp. UCG,) is co-refG (resp. co-refG,). The relation co-ref is extended to an equivalence relation co-ident on the set UCG as in the SG ref model. Any NG ref G has an associated rooted tree A(G) whose nodes are the SG~eIs used in the construction of G and edges are in the form (J, c)K, where J and K are nodes of A(G) and c is a concept node of J. Its root is denoted by R(G). E.g. the rooted tree associated with the NG r~f G of Figure 3 is represented in Figure 4: it has two nodes R(G) and K1 and one edge (R(G), c l ) g l (co-reference links are not edges of A(G)). A(G) is defined by structural induction. If G' is the
R(G) - S - - - - -
~
~
z ~
1 r----yq 1 f - - . ~ z LOOK ~
(co-refere~
i
Photography:A
versonI ~ - ' ~
cI
Boat I
Fig. 4. Rooted tree associated with the NO r~/ of Figure 3
basic NG ref obtained from a SGre! G, then A(G') is reduced to its root G. If G' is obtained from a basic NG re/ G, concept nodes ci of G and NGreYs Gi, then A(G') is obtained from the rooted trees A(Gi) by adding R(G) as the root and the edges (R(G), ci)R(Gi). The sets C a and CR(G) will be identified, as well as the set UCG and the union of the sets CK, K node of A ( G ) . T h e relation co-refa is translated in A(G) into an equivalence relation co-refA(a) on the union of the generic node sets of the nodes of A(G). A projection H from a NG ~e/ G to a NG~e! H and the image b y / / o f any node c of UCa, denoted b y / - / ( c ) , are defined by induction on the depth of G.
247
A projection from a NG ~ef G to a NG ~*f H is a f a m i l y / / =
(//0, (Hc)ceD(G))
which satisfies: 1. //o is a projection from the SG tel R(G) to the SG ref R(H), 2. Vc 9 D(G), Ho(c) 9 D(H) a n d / / c is a projection from Desc(c) to Desc(Ho(c)), 3. H preserves co-identity: Vc, d e UCo if co-refG(c, c') then co-idenQl(H(c)llI(d)), where II(c) = Ho(c) if c 9 C c and otherwise let Cl be the node of D(G) such that c 9
UCD ,c( I), U(c) = ILl(c).
Projection can be formulated in terms of the rooted trees A(G) and A(H) as follows. Let A1 = (X1,U1) and A2 = (X2,U2) be two rooted trees of SG~*fs with co-reference links and R1 and R2 be their respective roots. An A-projection from A1 to A2 is a family ~ -- (~o, (~OK)KeXl) which satisfies: 1. ~0 is a mapping from X1 to X2 that maps R1 to R2, 2. for any node K of A1, ~K is a projection from the SG ~ f K to the SG ~ f 3. ~ preserves adjacency in rooted trees: V(J, c)K 9 Vl (~Oo(J), ~j(c))~o(g) 9 U2, 4. ~ preserves co-identity: VK, K ' 9 X1 V(c, e') 9 CK x CK, if co-refal (c, cI) then co,identa2 (~oK(c), ~OK,(d)). Condition 3 on the image of an edge (J, c)K by an A-projection ~o is represented in Figure 5. It can be shown by induction on the depth of G that for any NGrefs
%
KL Fig. 5. Edge (J, c)K and its image by an A-projection
G and H , there is a projection from G to H iff there is an A-projection from A(G) to A(H). 3.2
The semantics @
In this section I will extend the semantics 9 to NGr~fs. I mentioned earlier the lack of interest of introducing co-reference links in a SG interpreted in the semantics 9 because of the possibility of merging nodes representing the same entity. Note that such nodes appearing in a NG G may be merged if they appear
248
in the same SG of A(G) (the resulting node having as description the union of the descriptions of the original nodes), but not otherwise. Thus the introduction of co-reference links in NGs interpreted in any semantics does improve their expressive power. In order to extend 9 to NGrefs, we add a first argument to each predicate, called the context argument. Thus a binary predicate is associated with each concept type, and a ( n + l ) - a d i c predicate is associated with each nadic relation type. For instance, if z (resp. x, y) is the variable assigned to a generic node of type Photograph (resp. Person, Boat), then the interpretation of the atom Person(z, x) is "x is a person in the context of the photograph z" and that of the atom on(z, x, y) is "the person x is on the boat y in the context of the photograph z". With S is associated the set ~(S) of formulas VZXl...xp (t(z,xl, ..., Xp) -+ t'(z, xl, ..., xp)), where t and t' are types such that t < t ~ and p is the arity of t and t ~ in the semantics 9 for SGs. For any NG tel G, let r(G) be the number of equivalence classes of the relation co-refG. Assign r(G) distinct variables Yl, ..., Yr(G) to the co-refa classes. For any node K of A(G), if K contains generic nodes then the variables of ~ ( K ) are some of the variables Yl, ..-, Yr(G). A subgraph of G is a NG ref that is either equal to G or to the description graph of a concept node appearing in G. A formula ~t (e, K ) (resp. 9 ~(e, G')) is associated with any term e and any node K of A(G) (resp. subgraph G' of G). ~'(e, K ) (resp. q~'(e, G')) is the formula associated with K (resp. G') when it is in the context represented by the term e, or more specifically, when K is the root of the description graph (resp. G ~ is the description graph) of a concept node associated with the term e. ~ ( e , K ) is defined as the conjunction of the atoms obtained from those of ~5(K) by adding the first argument e. 4~'(e, G ~) is defined by induction on the depth of G'. For any node K of A(G) and any concept node c of K , e~ denotes the term assigned to c in # ( K ) (which is in fact the term assigned to the co-identity class E of c).
q~'(e, G') = #'(e, R(G')) A (AceD(a,)#'(e~, Desc(e))) The formula
9 (G) = 3yl... yr(G)#'(ao, G) is associated with any NG *el G defined on the support S, where ao is a constant representing the general context induced by the support S, so that the same constant ao is used for all NGrefs defined on the support S. E.g. the formula associated with the graph G of Figure 3 is 9 (G) = 3yly2y3 (Person(ao, yl) A Look(ao, Y2) A photograph(ao, A)A agent(ao,y2, Yl) A object(ao,y2, A) A ~'(A, Desc(c))), where c is the concept node with referent A and qS'(A, Desc(c)) = Person(A, Yl) A Boat(A, Y3) A on(A, Yl, Y3)#(G) may be defined from A(G).
#(G) = Byl...yr(a)(AK node of A(a)#'(eK,K)) where eK = ao if K = R(G) and otherwise let (J, c)K be the edge of A(G) into
K, eK = e~. The normality notion and the soundness and completeness results extend to NGrefs. Let us first consider two counterexamples to the completeness result (presented in Figure 6). ~(G1) = t(ao,a) A r(ao,a, a) and ~(H1) = t(ao,a) A
249
t(ao, a) A r(ao, a, a). q~(G1) and qS(H1) are equivalent formulas, but there is no projection from G1 to H1. The problem here is that a node of A(H1) is not a normal SG ref. ~5(G2) = t(ao, a) A t(a, a) A t(a, a) and ~(H2) = t(ao, a) A t(a, a). 9 (G2) and ~(H2) are equivalent formulas, but there is no projection from G2 to H2. The problem here is that there are two co-identical concept nodes appearing in H2 such that one of them is a complex node and the other one is not. We
Fig. 6. Counterexample to the completeness result in NGr~fs with
have seen that the semantics ~5 does not distinguish co-identical nodes in a SG ref. In the same way, it does not distinguish which one(s) of co-identical nodes appearing in a NG ~ f contain(s) a given piece of information in its (their) description graph(s), as the description graphs of these nodes have the same context argument (the term assigned to the co-identity class of the nodes). A strong definition of normality could be the following. A NG ~ef G is strongly normal iff (1) every node of A(G) is a normal SG ~ f and (2) for any co-identical concept nodes c and c I appearing in two distinct nodes of A(G), if c is a complex node then d is a complex node and Desc(d) is an exact copy of Desc(c), i.e. Desc(d) is a copy of Desc(e) such that each generic node appearing in Desc(c) is co-referent to its copy appearing in Desc(d). The fact that Desc(d) is an exact copy of Desc(c), and not only a copy of Desc(c), is important. E.g. consider the
A(G)
~~
A(H) Fig. 7. Strong normality
NGrefs G, H and K in Figure 7. G and K are strongly normal, but H is not. 9 (G), qS(H) and qS(K) are equivalent formulas, but there is no projection from
250
G or K to H. Condition (2) of strong normality may be weakened as follows. Let G be a NG r~I and G ~ and H ~ be two SGre/s nodes of A(G) (resp. two NG~e/s subgraphs of G). An exact projection from G ~ to H ~ is a projection from G ~ to H ~ mapping each generic node c of Co, (resp. UCa,) to a generic node of CH, (resp. UCH, ) co-referent to c in G. G ~ and H ~ are exactly equivalent iff there is an exact projection from G ~ to H ~ and from H ~ to G ~. A NG re: G is normal iff 1. every node of A(G) is a normal SG *~f, 2. for any co-identical concept nodes c and c ~ appearing in two distinct nodes of A(G), if c is a complex node then c~ is a complex node and R(Desc(c~)) is exactly equivalent to R(Desc(c)). It can be shown by induction on the depth of Desc(c) that for any co-identicai complex nodes c and c~ appearing in a normal NG ~ f , not only the SGrefs R(Desc(c)) and R(Desc(c')) but the whole NGrels Desc(c) and Desc(c') are exactly equivalent. Moreover, Desc(c) and Desc(c ~) are exact copies of each other except for redundant relation nodes (a relation node r appearing in a node K of A(G) is redundant iff there is another relation node r' of K with the same respective neighbors as r and type(r') < type(r)). However, putting a NG ~ef G into normal form (i.e. transforming G into a normal NG ref G ~ such that 9 (G) - ~(G')) is not always possible. E.g. consider the graph/-/2 of Figure 6. If H~ was a normal NG ~I such that ~i(H2) -~ ~(H~) then ~(H~) would contain the atom t(a, a), then any concept node of UCH~ with referent a would have a concept node with referent a in the root of its description graph, and there would be an infinite chain in A(H~), which is impossible. The definition of normality is weakened into that of k-normality in such a way that any NG re/ G may be put into k-normal form for any k > depth(G). The level in G of a node c of UCG is the level in A(G) of the node K of A(G) containing c (i.e. the number of edges of the path in A(G) from R(G) to K). A NG ~ / G is k-normal iff 1. every node of A(G) is a normal SG r~f, 2. for any co-identical concept nodes c and d appearing in two distinct nodes of A(G) such that c is a complex node, if the level of c' in G is inferior to k then c ~ is a complex node and if c~ is a complex node then R(Desc(c~)) is exactly equivalent to R(Dese(c)). Note that a normal NG ~ f is k-normal for any natural integer k. T h e o r e m 2. Let G and H be two NGref s and k >_depth(G).
If there is a projection from G to H then ~(S), ~(H) ~ ~5(G). Conversely, if H is k-normal and ~5(S), ~(H) ~ ~(G) then there is a projection from G to H. P r o o f : We use the same notations as in the proof of Theorem 1. A ~-substitution from a NG ref G to a NG r~l H is defined in a similar way as a ~P-substitution from a SG r e / G to a SG ref H. Lemma 1 is true for NGre:s instead of SGre/s and the semantics 9 instead of ~P. Lemma 2 is true for S G ~ / s and for the semantics instead of ~P provided that H is a normal SG ~ / (the condition a(ec) = p(eri(c)) disappears as the term ec does not exist in the semantics ~).
251
Let us suppose t h a t there is a projection from G to H . Then there is an Aprojection ~ = (~o, ( ~ K ) K node of A(G)) from A(G) to A(H). From L e m m a 2, for any node K of A(G), there is a ~-substitution aK from K to ~o0(K) such t h a t for any concept node c of K , aK(e~) = p(e~---~-~). If a variable x is assigned to two co-referent nodes c and d appearing in different nodes K and K ' of A(G) then aK(x) = crg(e-~) = p(e~--~-(~) and aK,(X) = aK,(e~) = p ( e ~ ) . As preserves co-identity, ~ ( c ) -- ~o~,(d), then aK(x) = aK,(x). Therefore there is a substitution a of the variables of qh(G) by UH constants such t h a t for any node K of A(G), the restriction of a to the variables of ~ ( K ) is a ~ . The atoms of ~ ( G ) are obtained from those of the formulas ~ ( K ) , K node of A(G), by adding the context argument eK. To show t h a t a is a ~-substitution from G to H , it remains to show that for any node K of A(G), a(eK) = p(e~o(g)). If K = R(G) then ~o(K) = R(H) and a(eK) = p(e~o(l,:)) = ao, otherwise let (J, c)K be the edge of A(G) into K, eK : e~. From the definition of an Aprojection, (~o(J),~Og(c))~o(K) is an edge of A(H), then e~o(K ) = e ~ - ~ . It follows t h a t a(eg) ----a(e-~) = p(e~--j-~) = p(e~o(g)). Then a is a ~-substitution from G to H and we conclude with L e m m a 1. Convcrscly, lct us supposc that H is k-normal with k >_ depth(G) and ~(S), ~ ( H ) qh(G). From L e m m a 1, there is a ~-substitution a from G to H . We construct an A-projection ~ from A(G) to A(H) such t h a t for any node K o f A(G) and any concept node c of K , a(e-e) = p(e~--~-~). We define ~ o ( K ) and ~ g for any node K of A(G) and prove the preceding property by induction on the level l of K in A(G). For I -- 0, K is R(G). The atoms of ~(G) (resp ~ ( H ) ) associated with the nodes of R(G) (resp. R(H)) are those with a0 as first argument. Then the restriction of a to the variables of ~(R(G)) is a ~-substitution from R(G) to R(H). From L e m m a 2, there is a p r o j e c t i o n / / o from R(G) to R(H) such t h a t for any concept node c of R(G), a(e~) = p(en-~-~). We define ~o(R(G)) = R(H) and ~OR(C) = / / o - Suppose ~ is defined up to level I. Let (J, c)K be an edge of A(G) with K at level 1 + 1. Let s be a node of K and t(el, ..,, en) be the a t o m of ~(G) associated with s. Let t'(e~, .., ,e~) be an a t o m of ~ ( H ) such t h a t t' _< t and for any i in {1, ..., n}, a(ei) = p(e~). Let K ' be a node of A(H) and s' a concept node of K ' such t h a t the a t o m t'(e~, .., ,e~) is associated with s ~. el = e/~ = e~ and e~ = eg, then a(e-~) = p(eg,), then eg, r a0, then there is an edge (J',c')K' into K ' and eg, = e-~. By induction hypothesis, a(e~) = p(e~--j-~). We have
p(eT) = p(eK,) = a(e-e) = p(e~--~(-~), then c' -- ~ j ( c ) , i.e. c' and ~ j ( c ) are coidentical nodes. H is k-normal, c' and ~j(c) are co-identical, c' is a complex node and levelH(~j(c)) = levelc(c) < depth(G) <_ k then ~og(c) is a complex node and K ' is exactly equivalent to R(Desc(~oj(c))). Let s" be the image of s ~ by an exact projection from K ' to R(Desc(~j(c))). The a t o m of ~(R(Desc(~j(c)))) associated with s" is in the form t'(e~2,..,,e~n) with t" < t ~ __ t. It follows t h a t the restriction of a to the variables of ~ ( K ) is a q~-substitution from K to R(Desc(~j(c))). From L e m m a 2, there is a projection / / K from K to R(Desc(~g(c))) such t h a t for any concept node c" of K , a(e~) = p ( e ~ ) . We define ~oo(g) = R(Desc(~oj(c))) and ~aK = HK. ~oo(K) = R(Desc(~j(c)))
252
may be written as (~0(J), ~j(c))~o(K) is an edge of A(H), then ~ preserves adjacency in rooted trees. Let us show that ~ preserves co-identity. For any nodes K and K ~ of A(G) and any concept nodes c and d of K and K ~ respectively, if co-refA(G) (c, c') then ~ = c', then a(e~) = a(e~r) = p(e~--~-~) = p ( e ~ ) , then ~K (c) ---- ~K' (C'), i.e. co-identA(H)(~g (e), ~K' (C')). ~ is an A-projection from A(G) to A(H), then there is a projection from G to H The k-normal form G~k of G is defined for any k > depth(G) as follows. A rooted tree Ak of s G r e f s is built level by level from its root to level k. Its root is a copy of R(G). Let J be a node of Ak at level I < k and c a concept node of J (c is the copy of a node c' of UCG). If there is at least one complex node of UCc co-identical to d then add the edge (J, c)K to Ak, where K is a copy of the union of the SGrefs R(Desc(c')), c" complex node of UCG co-identical to d. Two generic nodes appearing in nodes of Ak are co-referent iff they are copies of co-referent nodes of UCG. Let G~ be the NG tel such that A(G~k) is obtained from Ak by replacing each node of Ak by its normal form (when merging several co-identical concept nodes, only one of the subtrees issued from these nodes is kept, as these subtrees are exact copies of each other in Ak). G~k is k-normal and 9 (G) -- #(G~) for any k > depth(G). E.g. the 2-normal form of the graph/-/2 of Figure 6 is H2 and its 3-normal form is G2. In Figure 7, for any k > 2, G and K are their own k-normal form and the k-normal form of H is K . Corollary 1 of Theorem 2 shows that reasoning on NGrefs may be performed using graph operations without any restriction on the NGr~fs. C o r o l l a r y 1: Let G and H be two NGref s and H~ be the k-normal form o
H, with k > max(depth(G), depth(H)). 9 (S), ~ ( H ) ~ ~(G) iff there is a projection from G to H~k. Note that from a practical point of view, it is sufficient to construct H~ up to level depth(G) since projection preserves levels. The semantics q5 is unable to express not only that an entity is represented by several concept nodes in a node of A(G), but also that several concept nodes representing the same entity have distinct descriptions. It is pertinent in applications in which the meaning of a graph is not changed when merging co-identical concept nodes of a SG re/ or replacing the description of co-identical concept nodes by the union of their descriptions (in particular in applications where graphs are naturally normal). But in some applications, each concept node has a specific situation in its SG ref and a specific description; merging these nodes or mixing their descriptions would destroy some information. For instance, let c and d be two concept nodes appearing in a NG ~eI G and representing a given lake. c appears in the context of a biological study (i.e. is related in a SG ~ f to nodes and appears in the description graphs of nodes concerning a biological study) and contains biological information about the lake in its description graph: animals and plants living in the lake. d appears in the context of a touristic study and contains touristic information about the lake in its description graph: possibilities of bathing, sailing and walking at the lake. The formulas ~(G), ~ ( H ) and ~ ( K ) are equivalent, where H is obtained from G by exchanging the description graphs of c and c ~ and K is the k-normal form of G
253
and H (with k -- max(depth(G), depth(H))), in which the description of c and c * is the union of the biological and touristic descriptions. Such an equivalence is obviously undesirable. In those applications, the semantics to be used is the semantics ~. 3.3
T h e s e m a n t i c s ~P
The semantics 9 is extended from s G r e l s to NGrels in the same way as the semantics ~, except that the context argument is the variable ec assigned to the concept node c representing the context instead of the term ee. Thus a description is specific to a concept node and not to a co-identity class. We add a context argument to each predicate (concept type predicates become 3-adic). For any NG ref G and any node K of A(G), let nc(K) be the number of K concept nodes. Assign r(G) variables yl, -.., Yr(G) to the r(G) co-refG classes and for any node K of A(G), ne(K) variables XlK, ..., xKc(K) to K concept nodes. All variables yi and x K are distinct. The variables of k~(K) are x K, ..., xK o(K) and, if K contains generic nodes, some of the variables Yl, .-., Yr(G). For any node K of A(G), ~ ( e , K ) is the conjunction of the atoms obtained from those of O(K) by adding the first argument e. ~ ( e , G ~) is defined by induction on the depth of G ~. For any node K of A(G) and any concept node e of K, ec denotes the variable assigned to c in k~(K).
~"(e, G') = 3x~(v')... n(G') Xnc(R(G')) (~'(e, R(G')) A (AceD(V,)O'(ec, Desc(c)))) The formula
k~(G) = 3yl... Yr(G)O'(ao, G) is associated with any NG tel G defined on the support S. E.g. the formula associated with the graph G2 of Figure 6 is
~(G2) = ~xl (t(ao, a, xl) ^ ~x2(t(x~, a, x~) ^ ~x3t(x2, a, x3))). ~P(G) may be defined from A(G) as the existential closure of the conjunction of the formulas O'(eg,K), K node of A(G), where eK is a0 if K is R(G) and otherwise let (J, c)K be the edge of A(G) into K , eK is ec. E.g. the formula associated with the graph G2 of Figure 6 may be written as O(G2) =
3xlx2x3(t(ao,a, xl) A t(xl,a, x2) A t(xz,a, x3)). Projection is sound and complete with respect to ~.
Let G and H be two NGrel s. O(S), ~9(H) ~ k~(G) iff there is a projection from G to g . T h e o r e m 3.
E.g. in Figure 6, for any i in {1,2}, ~(S),O(Hi) ~ O(Gi) and there is no projection from Gi to Hi. S k e t c h o f p r o o f : A technical proof is given in 9, similar to that concerning 9 . A more intuitive one is given here, which would not be available for ~. Let So be the support obtained from S by adding the individual marker ao, the universal concept type T (if it does not already exist) and a binary relation type tco~te~t (context relation). For any NG reJ' G on S, let Go be the NG r~/ on So reduced to a concept node labelled ( T , a o , G ) and Simple(G) be
254
the SG ref on So obtained from the union of the nodes of A(Go) by adding for each edge (J, c)K of A(Go) nc(K) relation nodes of type tcon~ext relating c to each concept node of K . It can be shown t h a t (1) there is a projection from G to H iff there is a projection from Simple(G) to Simple(H) and (2) ~ ( S ) , ~ ( H ) ~ ~P(G) iff ~ ( S 0 ) , ~ ( S i m p l e ( H ) ) ~ ~(Simple(G)) (any substitution of the variables of ~ ( G ) leading to the e m p t y clause by the resolution method is available for ~(Simple(G)), and conversely). We conclude with the soundness and completeness result on SGreSs. This proof would not be available for the semantics 9 because the SG tel Simple(H) obtained from a k-normal NG ref H containing distinct co-identical nodes is not normal.
4
Conclusion
I have presented two FOL semantics for Simple and Nested Graphs. Projection is sound and complete with respect to both semantics. This result shows t h a t reasoning on Conceptual Graphs may be performed using graph operations instead of logical provers (e.g. reasoning with G r a p h Rules 8,7). Non FOL formalisms, with "nested" formulas as in the logics of contexts have been proposed for Nested Graphs. It remains to compare these formalisms and the semantics t h a t m a y be associated with t h e m to the FOL semantics presented here.
References 1. M. Chein and M.L. Mugnier. Conceptual Graphs: fondamental notions. Revue d'InteUigence Artificielle, 6(4):365-406, 1992. Hermes, Paris. 2. M. Chein, M.L. Mugnier, and G. Simonet. Nested graphs: A graph-based knowledge representation model with fol semantics. In Proceedings of the Sixth Inter-
3. 4. 5. 6. 7. 8. 9. 10. 11.
national Conference on Principles of Knowledge Representation and Reasoning (KR '98), Trento, Italy, June 1998. R.V. Guha. Contexts: a formalization and some applications. Technical Report ACT-CYC-42391, MCC, December 1991. PhD Thesis, Stanford University. J. McCarthy. Notes on Formalizing Context. In Proc. IJCAI'93, pages 555-560, 1993. M.L. Mugnier and M. Chein. Representer des connaissances et raisonner avec des graphes. Revue d'Intelligence Artificielle, 10(1):7-56, 1996. Hermes, Paris. A Preller, M.L. Mugnier, and M. Chein. Logic for Nested Graphs. Computational Intelligence Journal, (CI 95-02-558), 1996. E. Salvat. Raisonner avec des opdrations de graphes : graphes conceptuels et r~gles d'infdrence. PhD thesis, Montpellier II University, France, December 1997. E. Salvat and M.L. Mugnier. Sound and Complete Forward and Backward Chainings of Graph Rules. In ICCS'96, Lecture Notes in A.L Springer Verlag, 1996. G Simonet. Une autre s6mantique logique pour les graphes conceptuels simples ou emboit~s. Research Report 96-048, L.I.R.M.M., 1996. G Simonet. Une s6mantique logique pour les graphes conceptuels emboitds. Research Report 96-047, L.I.R.M.M., 1996. J.F. Sowa. Conceptual Structures - Information Processing in Mind and Machine. Addison Wesley, 1984.
Peircean Graphs for the Modal Logic $5 Torben Braiiner* Centre for Philosophy and Science-Theory Aalborg University Langagervej 6 9220 Aalborg East, Denmark t orbenb@hum, auc. dk
A b s t r a c t . Peirce completed his work on graphical methods for reasoning within propositional and predicate logic, but left unfinished similar systems for various modal logics. In the present paper, we put forward a system of Peircean graphs for reasoning within the modal logic $5. It is proved that our graph-based formulation of $5 is indeed equivalent to the traditional Hilbert-Frege formulation. Our choice of proof-rules for the system is proof-theoretically well motivated as the rules are graphbased analogues of Gentzen style rules as appropriate for $5. Compared to the system of Peircean graphs for $5 suggested in 17, our system has fewer miles (two instead of five), and moreover, the new ~les seem more in line with the Peircean graph-rules for propositional logic.
1
Introduction
It was a m a j o r event in the history of diagrammatic reasoning when Charles Sanders Peirce (1839 - 1914) developed graphical methods for reasoning within propositional and predicate logic, 18. This line of work was taken up again in 1984 where conceptual graphs, which are generalisations of Peircean graphs, were introduced in 15. Since then, conceptual graphs have gained widespread use within Artificial Intelligence. The recent book 1 witnesses a general interest in logical reasoning with diagrams within the areas of logic, philosophy and linguistics. Furthermore, the book witnesses a practically motivated interest in d i a g r a m m a t i c reasoning related to the increasing use of visual displays within such diverse areas as hardware design, computer aided learning and multimedia. Peirce completed his work on graphical methods for reasoning within propositional and predicate logic but left unfinished similar systems for various m o d a l logics - see the account given in 12. In the present paper, we put forward a syst e m of Peircean graphs for reasoning within the modal logic $5. The importance of this logic is recognised within m a n y areas, notably philosophy, m a t h e m a t i c a l logic, Artificial Intelligence and computer science. It is proved t h a t our graphbased formulation of the modal logic $5 is indeed equivalent to the traditional Hilbert-Frege formulation. Our choice of proof-rules for the system is prooftheoretically well motivated as the rules are graph-based analogues of Gentzen * The author is supported by the Danish Natural Science Research Council.
256
style rules as appropriate for S51. Gentzen style is one way of formulating a logic which is characterised by particularly appealing proof-theoretic properties. It should be mentioned that a system of Peircean graphs for $5 was also suggested in 17. However, our system has fewer rules (two instead of five), and moreover, the new rules seem more in line with the Peircean graph-rules for propositional logic. In the second section of this paper we give an account of propositional and modal logic in Hilbert-Frege style. Graph-based systems for reasoning within propositional logic and the modal logic $5 are given in respectively the third and the fourth section. In section five it is proved that our graph-based formulation of $5 is equivalent to the Hilbert-Frege formulation. In section six we discuss possible further work.
2
Propositional
and Modal
Logic
In this section we shall give an account of propositional logic and the modal logic $5 along the lines of 14. See also 8, 9. We formulate the logics in the traditional Hilbert-Frege style. Formulae for propositional logic are defined by the grammar s ::= plsA...Asl'~(s) where p is a propositional letter. Parentheses are left out when appropriate. Given formulae r and r we abbreviate -~(r162 and -~(-~r162 as respectively r =~ r and r 1 6 2 D e f i n i t i o n 1. The axioms and proof-rules for propositional logic are as follows: A1 F- r :=~ (r :=~ r F- (r ==~ (r ~ 0)) =~ ((r ~ r ~ (r =~ 0)). A 3 I- (-1r =:~ -~r =~ (r ==~r M o d u s P o n e n s If F- r and F- r ~ r then F- r A2
Given the definition of derivability for propositional logic, it is folklore that one can prove soundness and completeness in the sense that a formula is derivable using the axioms and rules if and only if it is valid with respect to the standard truth-functional semantics. Formulae for modal logic are defined by extending the grammar for propositional logic with the additional clause
s ::. . . .
I O(s)
The connective symbolises "it is necessary that". Given a formula r we abbreviate -~-~r as <)r It follows that 0 symbolises "it is possible that". It is a notable 1 This gives rise to a highly interesting discussion on whether graphs should be considered as a generalisation of Gentzen or/and Natural Deduction style, or perhaps Hilbert-Frege style. (Note that there is danger of confusion here as Gentzen discovered Natural Deduction style as well as what is usually called Gentzen style, 6.)
257
property of the new connective that it is not truth-functional. Whereas the truth-value of for example the proposition -~r is determined by the truth-value of the proposition r it is not the case that the truth-value of I7r is determined by the truth-value of r For example, the truth of r does not necessarily imply the truth of De. This can be illustrated by taking r to symbolise either "all bachelors are unmarried" or "Bill Clinton is president of USA". The proposition r is true in both cases, but Or is true in the first case whereas it is false in the second. D e f i n i t i o n 2. The axioms and proof-rules for $5 are constituted by all axioms
and proof-rules for propositional logic together with the following: K F O(r :=~ r
~ ((3r ~ 7r T ~r162 s 5 ~- 0r ~ 0r N e c e s s i t a t i o n If F r then F De. It may be worth pointing out the relation between $5 and other well known modal logics. We get the modal logic $4 if axiom $5 is replaced by the axiom t- 3r ~ v i d e , called $4. It is straightforward to show that the logic $5 is stronger than the logic $4 in the sense that any formula provable in $4 is provable in $5 also. We get the modal logic T if axiom $5 is left out, and the modal logic K is obtained by leaving out $5 as well as T. The various modal logics described correspond to different notions of necessity. We shall here concentrate on $5 where can be considered as symbolising "it is under all possible circumstances the case that". Thus, the notion of necessity in question here is concerned with possible ways in which things might have been - it is not concerned with what is known or believed. This constitutes a philosophical motivation of the modal logic $5. From a mathematical point of view, $5 is interesting as it is a modal version of the monadic predicate logic (which is the usual predicate logic equipped with the restriction that every predicate has exactly one argument). Also, the modal logic $5 is used within the areas of Artificial Intelligence and computer science. In what follows, we shall give an account of the traditional possible-worlds semantics for $5. Formally, we need a non-empty set W together with a function V which assigns a truth-value V(w, p) to each pair consisting of an element w of W and a propositional letter p. The elements of W are to be thought of as possible worlds or possible circumstances. By induction, we extend the range of the valuation operator V to arbitrary formulas as follows:
V(w, r A r V(w,-~r V(w, 7r
iff V(w, r and V(w, ~b) iff not V(w, r iff for all w' in W, V(w', r
So V(w, r is to be thought of as r being true in the world w. A formula r is said to be S5-valid if and only if r is S5-true in any model (141,V), that is, we have V(w, r for any world w in W.
258
Given the definitions of derivability and validity in $5, it is well known that one can prove soundness and completeness, that is, a formula is derivable using the Hilbert-Frege axioms and rules for $5 if and only if it is S5-valid. 3
Graphs
for Propositional
Logic
In this section we shall give an account of propositional logic using Peircean graphs in linear notation. Graphs for propositional logic are defined by the grammar s
::= p I s...s I
where p is a propositional letter. The number of occurrences of s in a string s...s might be zero in which case we call the resulting graph empty. A graph can be rewritten into a formula of propositional logic by adding conjunction symbols as appropriate. We shall often blur the distinction between graphs and formulas when no confusion can occur. Given graphs r and r together with a propositional letter p occurring exactly once in r the expression r162 denotes r where r has been substituted for the occurrence of p. This notation will be used to point out one single occurrence of a graph in an enclosing graph. The --(...) part of a graph -~(r is called a negation context. We say that a graph r is positively enclosed in r162 if and only if it occurs within an even number of negation contexts. Negative enclosure is defined in an analogous fashion. A graph can be written in non-linear style by writing
instead of -,(r A notion of derivation for propositional graphs is introduced in the definition below. D e f i n i t i o n 3. A list of graphs r ..., r constitutes a derivation of r from r if and only if each r c a n be obtained from r by using one of the following rules: I n s e r t i o n Any graph may be drawn anywhere which is negatively enclosed. E r a s u r e Any positively enclosed graph may be erased. I t e r a t i o n A copy of any graph r may be drawn anywhere which is not within r provided that the only contexts crossed are negation contexts which do not enclose r D e i t e r a t i o n Any graph which could be the result of iteration may be erased. D o u b l e N e g a t i o n A double negation context may be drawn around any graph and a double negation context around any graph may be erased. The rules of the graph-based formulation of propositional logic have the notable property that they can be applied at the top-level as well as inside graphs. This is contrary to other formulations of propositional logic which allow only toplevel applications of rules. The point here is that the only global conditions on
259
applying the inference rules for graphs concern the notion of sign of a graph all the other conditions are purely local. This gives rise to the theorem below. T h e o r e m 1 ( C u t - a n d - P a s t e ) . Let a list of graphs r ---, Cn be given which constitutes a derivation of Cn from r Also, assume that a graph r162 is given in which ~b1 is positively enclosed. Then the list of graphs r162 ---, r162 constitutes a derivation of r162 from r162
Proof. Induction on n. This theorem and it's name is taken from 16. The justification for the name is that a derivation from the empty graph can be "cut out" and "pasted into" anywhere which is positively enclosed. In what follows, we shall give a proof that the graph-based formulation of propositional logic is equivalent to the Hilbert-Frege formulation in the sense that the same graphs/formulae are derivable. T h e o r e m 2. A graph is derivable from the empty graph if and only if the corresponding formula is derivable using the Hilbert-Frege style axioms and rules.
Proof. To see that a Hilbert-Frege derivable formula corresponds to a derivable graph the following two observations suffice: Firstly, the axioms A1, A2 and A3 all correspond to derivable graphs. Secondly, given derivations of graphs r and r :=:z r a derivation of r can be constructed as follows: The Cut-and-Paste Theorem enables us to combine the derivations of the graphs
r and
into a derivation of the graph
r
r
on which we apply Deiteration to get
which by Erasure yields
260
which by Double-Negation finally yields the graph
r
This corresponds to the Modus Ponens rule. To see that the rules for graphs do not prove too much, the following argument suffices: The e m p t y graph corresponds to the unit for conjunction which is obviously valid with respect to the standard truth-functional semantics and furthermore, the rules for derivability of graphs correspond to validity-preserving operations on formulae. Hence, the formula corresponding to a graph derivable from the e m p t y graph is valid and therefore Hilbert-Frege derivable according to the previously mentioned completeness result.
4
Graphs
for the Modal
Logic $5
In this section we shall give a graph-based version of the modal logic $5. Graphs for modal logic are defined by extending the g r a m m a r for defining graphs of propositional logic with the additional clause
s ::. . . .
I O(s)
The 0(...) part of a graph 9(r is called a modal context 2. Note t h a t modal contexts do not m a t t e r for whether a graph is positively or negatively enclosed. We say that a graph is modally enclosed if it occurs within a modal context. In non-linear style we write
r instead of (r A notion of derivation for modal graphs is introduced in the definition below. 2 A historical remark should be made here: Peirce's modal contexts correspond to -~(3(...)) in our system. This definition of modal contexts is adopted by some authors, for example those of the papers 12 and 17. Our choice of definition for modal contexts deviates from Peirce's because we want to keep the notions of negation and necessity distinct. This is in accordance with Sowa's definition of modal contexts for conceptual graphs, 15. It is straightforward to restate our graph-rifles in terms of Peirce's modal contexts by adding negation contexts as appropriate and by defining positive and negative enclosure such that negation contexts as well as modal contexts are taken into account.
261
D e f i n i t i o n 4. A list of graphs r ..., r constitutes a derivation of r from r if and only if each r can be obtained from r by using either one of the rules for propositional logic or one of the following:
N e g a t i v e D - I n t r o d u c t i o n A modal context may be drawn around any negatively enclosed graph. P o s i t i v e Q - I n t r o d u c t i o n A modal context may be drawn around any positively enclosed graph r which is not modally enclosed provided that each propositional letter which is within a context enclosing r but which is not within r is modally enclosed. Note that the condition regarding propositional letters in the rule Positive ElIntroduction is vacuous if the graph r is not enclosed by any contexts at all. Also, in the rule for iteration note that only negation contexts can be crossed when copying a graph (modal contexts cannot be crossed). Our choice of rules is proof-theoretically well motivated as the rules are graphbased analogues of the Gentzen rules for $5 originally given in 11 (and also considered in 2 and elsewhere). Gentzen rules for classical logic were introduced in 6. In Gentzen style, proof-rules are used to derive sequents ~1, ..., ~rt - r
.... , Cm
Derivability of such a sequent corresponds to derivability of (r
A ... ^ r
~
(r
v ... v era)
Note that the left hand side formulae r .-., r are negatively enclosed whereas the right hand side formulae r .--, r are positively enclosed. Generally, a rule in Gentzen style either introduces a formula on the left of the turnstyle or it introduces a formula on the right of the turnstile (that is, a formula is introduced either as negatively or positively occurring). In the $5 case, the Gentzen rules are as follows: IT-Left If F, r ~- A then F, 3r ~- A. D - R i g h t If F 1- r A then F ~- ~r A provided that any propositional letter occurring in F or A is modally enclosed. Clearly, the :-Left rule corresponds to the rule Negative O-Introduction for graphs and the El-Right rule corresponds to the rule Positive -Introduction. Note that in the rule Positive 3-Introduction, the restriction that r must not be modally enclosed cannot be left out. The two graphs <)q ~ <)q and ~q ~ ~~q constitute a counter-example as the first graph is derivable (as it is obviously valid) whereas the second graph is not derivable at all (as it is invalid). Here, the modal context enclosing the graph in question is negatively enclosed. Similarly, the two graphs 3(q V p) ~ 3(q V p) and 3(q V p) ~ 3(Elq V p) constitute a counter-example where the modal context enclosing the graph in question is positively enclosed. It should be mentioned that an equivalent system can be obtained by replacing the Negative D-Introduction rule by the following:
262
Positive D-Elimination m a y b e erased.
A m o d a l c o n t e x t a r o u n d any p o s i t i v e l y enclosed g r a p h
T h e equivalence is s t r a i g h t f o r w a r d to prove using the s e c o n d m o d a l c u t - a n d p a s t e t h e o r e m , T h e o r e m 4, given below 3. W e c l e a r l y have to c o m p a r e our s y s t e m to t h e s y s t e m for $5 given in t h e p a p e r 17. O u r rule N e g a t i v e D - I n t r o d u c t i o n is also a rule of this p a p e r , b u t o u r rule P o s i t i v e D - I n t r o d u c t i o n replaces three rules given there, n a m e l y g r a p h - b a s e d a n a l o g u e s of t h e H i l b e r t - F r e g e a x i o m s a n d p r o o f - r u l e s K, $5 a n d N e c e s s i t a t i o n . So, c o m p a r e d to t h e rules of 17 we have fewer rules (two i n s t e a d of five). F u r t h e r m o r e , o u r rules seem m o r e in line w i t h t h e g r a p h - r u l e s for p r o p o s i t i o n a l logic 4 a n d t h e y are p r o o f - t h e o r e t i c a l l y well m o t i v a t e d , as is m a d e clear in t h e discussion above. 3 The fact that the two males give rise to equivalent systems leaves us with a highly interesting question: Which of the rules should we take, Negative/--Introduction or Positive D-Elimination? The first is suggested if we consider graphs to be a generalisation of Gentzen style. But the second rule is suggested if we consider graphs to be a generalisation of Natural Deduction style where in general a rule either introduces or eliminates a formula on the right of the turnstile (that is, a formula is either introduced or eliminated as positively occurring). Note, however, that Natural Deduction lends itself towards intuitionistic logic (as the asymmetry between assumptions and conclusion in Natural Deduction proofs is reflected in the asymmetry between input and output in the Brouwer-Heyting-Kolmogorov interpretation) rather than classical logic (as the asymmetry between assumptions and conclusion in Natural Deduction is not reflected in the standard truth-functional interpretation where the truth-values, true and false, are perfectly symmetric) whereas the converse seems to be the case with graphs. On the other hand, Natural Deduction proofs correspond in a certain sense to intuitive, informal reasoning. To quote from Prawitz's classic on Natural Deduction: The inference rules of systems of natural deduction correspond closely to procedures common in intuitive reasoning, and when informal proofs - such as are encountered in mathematics for example - are formalised within these systems, the main structure of the informal proofs can often be preserved. (13, p. 7) Also Peircean graphs can be said to correspond to intuitive and informal reasoning. But it is not clear in which sense this can be said about Gentzen's calculus of sequents. Rather: The calculus of sequents can be understood as meta-calculi for the deducibility relation in the corresponding systems of natural deduction. (13, p. 90) The answer to the question concerning whether graphs generalise Gentzen o r / a n d Natural Deduction style may be hidden within the problem of finding an appropriate notion of reduction for graph-derivations analogous to cut-elimination in Gentzen systems o r / a n d normalisation in Natural Deduction systems - see 7. We shall leave this issue to future work. 4 This point is clear if we consider graphs as a generalisation of Gentzen o r / a n d Natural Deduction style rather than Hilbert-Frege style (the latter seems unnatural compared to the former).
263
We do not have the full Cut-and-Paste Theorem, Theorem 1, when the rules for the modal logic $5 are taken into account 5. However, it is possible to add restrictions in two different ways such that the theorem holds also in the modal case. In the first case we have added the restriction that r is not enclosed by any contexts at all. T h e o r e m 3 ( C u t - a n d - P a s t e ) . Let a list of graphs r
..., Cn be given which constitutes a derivation of Cn from r Also, assume that a graph r162 is given in which r is not enclosed by any contexts. Then the list of graphs r162 --., r162 constitutes a derivation of r162 from r162 Proof. Induction on n. In the second case we have added the restriction that the rule for positive 3introduction is not applied in the derivation of r from r T h e o r e m 4 ( C u t - a n d - P a s t e ) . Let a list of graphs r
..., Cn be given which constitutes a derivation of r from r where the rule for positive 3-introduction is not applied. Also, assume that a graph r162 is given in which r is positively enclosed. Then the list of graphs r162 ..., r162 constitutes a derivation ofr162 from r162 Proof. Induction on n.
5
T h e Equivalence
In this section, we shall prove that the graph-based formulation of $5 is equivalent to the traditional Hilbert-Frege formulation. The theorem below says that a graph is S5-derivable from the empty graph if the corresponding formula is Hilbert-Frege derivable. L e m m a 1. A graph is S5-derivable from the empty graph if the corresponding formula is derivable using the Hilbert-Frege style axioms and rules for $5. 5 In passing, we shall mention another theorem which holds for propositional logic but which does not hold for the modal logic $5 (and neither for other modal logics). This is the so-called Deduction Theorem which says that the derivability of r from 4) implies the derivability of r ==# r from the empty graph. Using the Cut-and Paste Theorem, it is straightforward to prove it for propositional logic. But here is a counter-example for $5: The graph :p is derivable from the graph p, but p =# :p is not derivable from the empty graph (as it is not valid). In the paper 17 it is claimed that the Deduction Theorem holds for the graph-based system for $5 proposed there (and for graph-based systems proposed for other modal logics as well). But this is not true, in fact, the counter-example just given works also for the systems of that paper. However, in the mentioned paper the Deduction Theorem does hold in the cases where it is used.
264
Proof. To see that a Hilbert-Frege derivable formula corresponds to a derivable graph the following four observations suffice: Firstly, the axioms A1, A2 and A3 all correspond to derivable graphs. This is analogous to the propositional case, Theorem 2. Secondly, given derivations of graphs r and r :=r r a derivation of r can be constructed. This is straightforward to show in a way analogous to the propositional case, Theorem 2, by using the first modal cut-and-paste theorem, Theorem 3. This corresponds to the rule Modus Ponens. Thirdly, the axioms K, T and $5 all correspond to derivable graphs. With the aim of making clear the role of our modal rules, we shall give the derivations. By Double Negation, Insertion and Iteration we get
which by Negative :-Introduction
yields
.....................................
r which by Positive :-Introduction
ir yields
.....................................
which by Double Negation finally yields the graph
that corresponds to 3(r ~ r ~ (Iqr ~ I7r Negation, Insertion and Iteration we get
that is, the axiom K. By Double
265
which by Negative G-Introduction yields the graph t ..............
;
f--------'-I
r that corresponds to r and Iteration we get
~ r that is, the axiom T. By Double Negation, Insertion
which by Positive -Introduction
yields the graph
t ....................
that corresponds to ~r ~ q0r that is, the axiom $5. Fourthly, given a derivation of a graph r a derivation of r can be constructed by using the rule Positive Vq-Introduction. This corresponds to the rule Necessitation. The following lemma says that negative D-introduction preserves validity. L e m m a 2. Let a graph r162 be given. For every Sh-model (W, V) it is the case
that 1. if r is negatively enclosed then V(w, r162 implies V(w, r162 2. if r is positively enclosed then V(w, r162 implies V(w, r162 for any w in W. Proof. Induction on the structure of r162 We proceed on a case by case basis where symmetric cases are omitted. - The case where r162 = a A flr for some a and/3. If V(w, a A/3r then V(w, a) and Y(w,/3r But V(w,/3r implies Y(w,/3:r by induction. Hence, V(w, a A/3r - The case where r162 = -"/3r for some /3. If V(w,--/3r then Y(w,/3r is false. But this implies the falsity of V(w,/3~r by contraposition of the induction hypothesis. Hence, Y(w, --/3V1r
266
- T h e case where r162 = E/3r for some/3. If V(w, :/3r then V(w', flr for any w' in W. T h u s V(w',/3r for any w' in W by induction. Hence,
y(w, nflr -
T h e case where r162 = r In this case, r cannot be negatively enclosed. Clearly, V(w, 3r implies V(w, r
W i t h the aim of proving t h a t Positive D - I n t r o d u c t i o n preserves validity, we shall prove a small proposition. Recall t h a t t r u t h in a m o d e l a m o u n t s to t r u t h in any world of the model. P r o p o s i t i o n 1. Let a graph r be given in which any propositional letter is modally enclosed. In a given SS-modei (W, V) either r is true or -~(r is true.
Proof. Induction on the structure of r We proceed on a case by case basis. - T h e case where r = c~ A/3 for some a and/3. If -~(a A fl) is not true in the world then Y(w, ~ A/3) for some world w in W, and hence, also Y(w, a) and V(w,/3). By induction, this implies the t r u t h of a a n d / 3 in the model, and hence, the t r u t h of a A fl in the model. - T h e case where r = -~fl for some/3. By induction, e i t h e r / 3 is true or -~fl is true in the model. - T h e case where r = :3/3 for some/3. Clearly ok.
T h e following t h e o r e m essentially says t h a t the rule Positive :-Introduction preserves validity. 3. Let a graph r162 be given in which r is positively enclosed but not modally enclosed. Furthermore, assume that any propositional letter not within r is modally enclosed. If r162 is true in a given Sh-model then r162 is also true in this model. Lemma
Proof. Induction on the structure of r162 We proceed on a case by case basis. - T h e case where r162 = a A flr for some a and 3. I f a A flr is true in the m o d e l then also c~ and flr are true. But the t r u t h of flr implies the t r u t h of flDr by induction. Hence, a A flDr is true. - T h e case where r162 = -~(a A-~flr for some a and ft. If -~(a A-~flr is true in the m o d e l then either -~c~ is true or flr is true according to P r o p o s i t i o n 1. B u t the t r u t h of flr implies the t r u t h of flDr by induction. Hence, -~(a A -~flEr is true. - T h e case where r162 = r Clearly, the t r u t h of r in the m o d e l implies the t r u t h of 3r
T h e l e m m a above can be generalised in the following sense.
267
L e m m a 4. Let a graph r162 be given in which r is positively enclosed but not
modally enclosed. Furthermore, assume that any propositional letter within a context enclosing r but not within r is modally enclosed. If r162 is valid then r162 is also valid. Proof. There are two cases. If r is not enclosed by any negation contexts in r162 then r162 = a A r for some a. If c~A r is valid then a and r are also valid. The validity of r implies the validity of :r Hence, aA:r is valid. If r is enclosed by a non-zero number of negation contexts in r162 then r162 = a A -~r for some a and/~. If a A -~flr is valid then also a and -~/~r are valid. By L e m m a 4 the validity of -~ftr implies the validity of -~/3Dr Hence, a A - ~ D r is valid. The following theorem says that a graph is Sb-derivable from the empty graph only if the corresponding formula is Hilbert-Frege derivable. L e m m a 5. A graph is Sb-derivable from the empty graph only if the correspond-
ing formula is derivable using the axioms and rules for $5. Proof. The formula corresponding to the empty graph is the unit for conjunction which is valid as it is true in any world of any model. The rules for derivability of graphs in propositional logic correspond to validity-preserving operations on formulae. It follows from Lemma 2 and Lemma 4 that the two rules for derivability of graphs in $5 correspond to validity-preserving operations on formulae. We conclude that the formula corresponding to any graph derivable from the empty graph is valid and therefore derivable using axioms and rules according to the previously mentioned completeness result. The theorem below says that the graph-based formulation of $5 is equivalent to the traditional Hilbert-Frege formulation. T h e o r e m 5. A graph is Sb-derivable from the empty graph if and only if the
corresponding formula is derivable using the axioms and rules for $5. Proof. L e m m a 1 and Lemma 5.
6
Further
Work
It is natural to ask whether what we have done in this paper is also possible with $5 replaced by $4, T or K. It is obviously possible to use graph-based analogues of the Hilbert-Frege axioms and proof-rules for each of the mentioned modal logics. This is what is done in 17. But is it possible to find proof-theoretically well motivated graph-based formulations of $4, T and K? Clearly, this is related to the possibility of finding Gentzen and Natural Deduction systems for the logics in question. Gentzen proof-rules for $4 and $5 were introduced in 10, 11 and Natural Deduction rules for these logics were given in 13. But such formulations
268
have not been found for other modal logics 6. In Handbook of Philosophical Logic, the following remark is made on Prawitz's Natural Deduction systems for $4 and $5: However, it has proved difficult to extend this sort of analysis to the great multitude of other systems of modal logic. It seems fair to say t h a t a deductive treatment congenial to modal logic is yet to be found, for Hilbert systems are not suited for actual deduction, .... (3, p. 27-28) The problem of finding proof-theoretically well motivated graph-based formulations of m o d a l logics is analogous. This suggests that $4 is amenable to a graph-based formulation along the same lines as the one for $5. But it also suggests that this is not the case for other modal logics. This deficiency calls for explanation. The handbook continues: The situation has given rise to various suggestions. One is t h a t the Gentzen format, which works so well for truth-functionM operators, should not be expected to work for intensional operators, which are far from truth-functional. (But then Gentzen works well for intuitionistic logic which is not truth-functional either.) Another suggestion is that the great proliferation of modal logics is an epidemy from which modal logic ought to be cured: Gentzen methods work for the i m p o r t a n t systems, and the other should be abolished. 'No wonder natural deduction does not work for unnatural systems!' (3, p. 28) It is not clear to the author of this paper whether one of these suggestions provides a way out of the trouble. We shall leave it to further work. A c k n o w l e d g e m e n t s : Thanks to Peter Ohrstrr for comments at various stages of writing this paper.
References 1 2 3
4
G. Allwein and J. Barwise, editors. Logical Reasoning with Diagrams. Oxford University Press, 1996. T. Braiiner. A cut-free Gentzen formulation of the modal logic $5. 12 pages. Manuscript, 1998. R. Bull and K. Segerberg. Basic modal logic. In D. Gabbay and F. Guenthner, editors, Handbook of Philosophical Logic, Vol. II~ Extensions o Classical Logic, pages 1-88. D. Reidel Publishing Company, 1984. M. Fitting. Tableau methods of proof for modal logics. Notre Dame Journal of Formal Logic, 13:237-247, 1972.
6 It should be mentioned that many modal logics can be given formulations which more or less diverge from ordinary Gentzen systems. Notable here are the formulations of T, $4 and $5 given in 9. Rather than sequents in the usual sense, they are based on indexed sequents, that is, sequents where each formula is indexed by a string of natural numbers. Also the Prefixed Tableau Calculus of 4, 5 should be mentioned. See the discussion in 2.
269
5
6 7 8 9 10 11 12
13 14 15 16 17
18
M. Fitting. Basic modal logic. In D. Gabbay et al., editor, Handbook o Logic in Artificial Intelligence and Logic Programming, Vol. 1, Logical Foundations, pages 365-448. Oxford University Press, Oxford, 1993. G. Gentzen. Untersuchungen fiber das logische Schliessen. Mathematische Zeitschrift, 39, 1934. J.-Y. Girard, Y. Lafont, and P. Taylor. Proos and Types. Cambridge University Press, 1989. G. E. Hughes and M. J. Cresswell. An Introduction to Modal Logic. Methuen, 1968. G. Mints. A Short Introduction to Modal Logic. CSLI, 1992. M. Ohnishi and K. Matsumoto. Gentzen method in modal calculi. Osaka Mathematical Journal, 9:113-130, 1957. M. Ohnishi and K. Matsumoto. Gentzen method in modal calculi, II. Osaka Mathematical Journal, 11:115-120, 1959. P. Ohrstrem. C. S. Peirce and the quest for gamma graphs. In Proceedings oJ Fifth International Conerence on Conceptual Structures, volume 1257 of LNCS. Springer-Verlag, 1997. D. Prawitz. Natural Deduction. A Proo- Theoretical Study. Almqvist and WikseU, 1965. D. Scott, editor. Notes on the Formalisation o Logic. Sub-faculty of Philosophy, University of Oxford, 1981. J . F . Sowa. Conceptual Structures: Inormation Processing in Mind and Machine. Addison-Wesley, Reading, 1984. J . F . Sowa. Knowledge Representation: Logical, Philosophical, and Computational Foundations. PWS Publishing Company, Boston, 1998. H. van den Berg. Modal logics for conceptual graphs. In Proceedings o First International Conference on Conceptual Structures, volume 699 of LNCS. SpringerVerlag, 1993. J. Zeman. Peiree's graphs. In Proceedings of Fifth International Conference on Conceptual Structures, volume 1257 of LNCS. Springer-Verlag, 1997.
Fuzzy Order-Sorted Logic Programming in Conceptual Graphs with a Sound and Complete Proof Procedure Tru H. Cao and Peter N. Creasy Department of Computer Science and Electrical Engineering University of Queensland Australia 4072 {tin, peter} @csee.uq.edu.au
Abstract. This paper presents fuzzy conceptual graph programs (FCGPs) as a fuzzy order-sorted logic programming system based on the structure of conceptual graphs and the approximate reasoning methodology of fuzzy logic. On one hand, it refines and completes a currently developed FCGP system that extends CGPs to deal with the pervasive vagueness and imprecision reflected in natural languages of the real world. On the other hand, it overcomes the previous widesense fuzzy logic programming systems to deal with uncertainty about types of objects. FCGs are reformulated with the introduction of fuzzy concept and relation types. The syntax of FCGPs based on the new formulation of FCGs and their general declarative semantics based on the notion of ideal FCGs are defined. Then, an SLD-style proof procedure for FCGPs is developed and proved to be sound and complete with respect to their declarative semantics. The procedure selects reductants rather than clauses of an FCGP in resolution steps and involves lattice-based constraint solving, which supports more expressive queries than the previous FCGP proof procedure did. The results could also be applied to CGPs as special FCGPs and useful for extensions adding to CGs lattice-based annotations to enhance their knowledge representation and reasoning power.
1. Introduction It is a matter of fact that uncertainty is frequently encountered in the real world. Uncertain knowledge representation and reasoning therefore have gained growing importance in artificial intelligence research. So far, research on extensions of CGs (29) for dealing with uncertainty has mainly clustered into two groups. One is on application of CGs to information retrieval (e.g., 11, 27, 13) and the other is on FCGs (e.g., 25, 33, 17), with the latter being our current research interest. Among several theories and methodologies dealing with different kinds of uncertainty, fuzzy logic (37), originated by the theory of fuzzy sets (35), is an essential one for representing and reasoning with vague and imprecise information, which is pervasive in the real world as reflected in natural languages. It is significant that, whilst a smooth mapping between logic and natural language has been regarded as the main motivation of CG (31), a methodology for computing with words has been regarded as the main contribution of fuzzy logic (38). Interestingly, for example, whilst quantifying words in natural languages such as many, few or most can be represented in CGs (30), the vagueness and imprecision of
271
these words can be handled by fuzzy logic (36). It shows that these two logic systems, although so far developed quite separately, have a common target of natural language. Their merger then promises a powerful knowledge representation language where CG offers a structure for placing words in and fuzzy logic offers a methodology for approximate reasoning with them. Fuzzy logic programming systems can be roughly classified into two groups with respect to (w.r.t.) the narrow and the wide senses of fuzzy logic. Systems of the first group have formulas associated with real numbers in the interval 0,1 (e.g. 26, 21). Those of the second involve computations with fuzzy sets as data in programs (e.g. 32, 2). There are two common shortcomings of the previous systems of the second group. First, model-theoretic semantics and theorem-proving fundamentals were not established, whence the soundness and the completeness of the systems could not be proved. Second, they did not deal with type hierarchies as classical order-sorted logic programming systems did. In the fuzzy case, there is the problem of uncertainty about types of objects. Overcoming the first shortcoming, annotated fuzzy logic programs (AFLPs) have been developed as an essential formalism for fuzzy logic programming systems computing with fuzzy sets as soft data (9, 7). The purpose of our current work on FCGPs is two-fold. On one hand, it extends CGPs (14, 28, 19) to deal with vague and imprecise knowledge. On the other hand, it provides a wide-sense fuzzy logic programming system that can handle uncertainty about types of objects. The system is in the spirit of possibility theory and possibility logic (12), where fuzzy set membership functions are interpreted as possibility distributions, in contrast to probability distributions in a probability framework. For that purpose, this paper refines and completes the previous work 34, 4 on FCGPs in the following issues: 1. FCGs are reformulated with the introduction of fuzzy concept and relation types, providing unified structure and treatment for both FCGs and CGs. The syntax of FCGPs is refined on the new formulation of FCGs. 2. The general declarative semantics of FCGPs is defined on the notion of ideal FCGs, ensuring finite proofs of logical consequences of programs. The fixpoint semantics of FCGPs as the bridge between their declarative and procedural semantics are studied. 3. A sound and complete SLD-style proof procedure for FCGPs is developed. For the completeness, the procedure selects reductants rather than clauses of an FCGP in resolution steps. Also, it involves solving constraints on lattice-based fuzzy value terms, supporting more expressive queries which are possibly about not only fuzzy attribute-values but also fuzzy types. In fact, FCGPs and CGPs can be studied in the lattice-based reasoning framework of annotated logic programs (20, 7), as CGPs compute with concept types and FCGPs compute with fuzzy types and fuzzy attribute-values as lattice-based data. From this point of view, the results obtained in this paper could also be applied to CGPs as special FCGPs and useful for extensions adding to CGs lattice-based annotations to enhance their knowledge representation and reasoning power.
272
The paper is organized as follows. Section 2 presents a framework of fuzzy types, the new formulation of FCGs and the notion of ideal FCGs. Section 3 defines the syntax and general declarative semantics of FCGPs and studies their fixpoint semantics. More details for these two sections can be found in 8. In Section 4, the definitions of FCGP reductants and FCGP constraints are presented. Then, the new FCGP proof procedure is developed and proved to be sound and complete w.r.t. FCGP declarative semantics. Finally, Section 5 is for conclusions and suggestions for future research.
2. FCG Formulation with Fuzzy Types Throughout this paper, the conventional notations n and u are respectively used for the ordinary/fuzzy set intersection and union operators, and lub stands for the least upper bound operator of a lattice. Especially, we use _~ as the common notation for all orderings used in the current work, under the same roof of information ordering, whereby A .~ B means B is more informative, or more specific, than A. In particular, we write A ~ B if B is a fuzzy sub-set of A, or B is a sub-type of A. It will be clear in a specific context which ordering this common notation denotes. 2.1. Fuzzy Types In the previous formulation of FCGs (34, 4) fuzzy truth-values, defined by fuzzy sets on 0,1, are used to represent the compatibility of a referent to a concept type, or referents to a relation type. The formulation of a fuzzy type as a pair of a basic type and a fuzzy truth-value was first proposed in 5, providing unified structure and treatment for both FCGs and CGs. The intended meaning of an assertion "x is of fuzzy type (t, v)" is "(x is of t) is v". For example, an assertion "John is of fuzzy type (AMERICAN-MAN,fairly true)" says "It is fairly true that John is an AMERICAN-MAN",where AMERICAN-MANis a basic type and fairly true is the linguistic label of a fuzzy truth-value. The intuitive idea of the fuzzy sub-type ordering is similar to that of the ordinary one. That is, if x2 is a fuzzy sub-type of x 1, then an assertion "x is of x2" entails an assertion "x is of Xl". For example, given BIRD --
273
false)}" says "It is very true that Object #1 is a BIRD and it is fairly false that it is an EAGLE". Given two conjunctive fuzzy types T 1 and T2, T 1 is said to be matchable to T2 iff VZle TlqX2e T2: x 1 is matchable to x 2. The mismatching degree of T 1 to Tz is then defined by md(TlIT2) = MaXT1MinT2{md(xllX2) I "~1~ T1, "c2eT 2 and "~I is matchable to x2}- When md(TtlT2) = 0, T2 is said to be a conjunctive fuzzy sub-type of T 1 and one writes T 1
274
An ideal FCG is defined like an FCG except that, fuzzy values in it are ideals of fuzzy attribute-value lattices or conjunctive fuzzy type upper semi-lattices. Given an ideal FCG g, a principal instance of g is an FCG derived from g by replacing each fuzzy value ideal in g by an element in the ideal. For a concept node c in a principal instance of g, we denote the corresponding concept node in g from which c is derived by origin(c). We write norm(g), which is called a normal ideal FCG, to denote g after being normalized, whereby no individual marker occurs in more than one concept node in norm(g) (cf. CG normal form in 14, 28). Ideal FCG projection as the subsumption ordering over a set of ideal FCGs is defined similarly as CG projection. The difference is only that CG projection is based on basic type lattices, whilst ideal FCG projection is based on conjunctive fuzzy type ideal lattices. Given ideal FCGs u and v, we write u
3. Syntax and Declarative Semantics of FCGPs 3.1. F C G P Syntax
Definition 3.1 An FCGP clause is defined to be of the form if u then v, where u and v are finite FCGs; v is called the head and u the body (possibly empty) of the clause, and there may be coreference links between u and v. Some concept and relation nodes may be defined to be thefirm nodes in the clause. An FCGP is a finite set of FCGP clauses. The intended meaning of firm nodes in FCGP rules is that, the firm nodes in the body of a rule require full matching for the rule to be fired, whilst the firm nodes in the head of a rule are not subject to change by mismatching degrees when the rule is fired. For the examples in this paper, we have a convention that concept and relation nodes without linguistic labels of fuzzy sets are firm nodes.
Example 3.1 The FCGP in Figure 3.1 consists of one fact saying "Apple #1 is fairly red", and one rule saying "If an apple is red, then it is ripe". Here, APPLE; #1, APPLE; *, (ATTR1)and (ATTR2)are firm nodes, and the others are not. Note that ATTR1 and ATTR2 are functional relation types, where the concept nodes linked to a functional relation node by double-lined arcs are the dependent concepts and the others are the determining concepts of the relation (24, 6).
~ if
COLOR:@fairlyred coLo..@red l -then .... ~
Fig. 3.1. An FCGP
RIPENESS:@ripe
275
3.2. FCGP Interpretations and Models There are two notions of FCGP declarative semantics: restricted and general. For the restricted semantics, an FCGP interpretation is a normal FCG, whose fuzzy values are elements of fuzzy attribute-value lattices or conjunctive fuzzy type upper semi-latrices. For the general semantics, an FCGP interpretation is a normal ideal FCG, whose fuzzy values are ideals of these lattices or upper semi-lattices. As shown in 20, 9, for logic programs computing with data based on lattices that may be infinite, the general semantics has to be used to guarantee finite proofs of logical consequences of programs.
Defini~on 3.2 An FCGP interpretation is a normal ideal FCG (possibly infinite). As in 34, 9, the satisfaction relation between an FCGP interpretation and an FCGP is based on the fuzzy modus ponens model of 23. The model is consistent with classical modus ponens, that is, when the body of a rule fully matches a fact, then the head of the rule can be derived. When the body mismatches the fact by some degree, one has a degree of indetermination in reasoning, and the conclusion should be more ambiguous and less informative than it is when there is no mismatching. It is obtained by adding the mismatching degree to fuzzy values in the head. For a fuzzy value A, A+E represents A being overall pervaded with an indetermination degree e ~ 0,1. I f A is a fuzzy set on a domain U, the membership function of A+e is defined by tA+e(u) = Min{~tA(U) + e, 1 }, for every u~ U. I r A is a fuzzy type (t, v), then A+e = (t, v+e). IrA is a conjunctive fuzzy type T, then A+e = {'c+e I x~ T}.
Definition 3.3 Let P be an FCGP and I be an FCGP interpretation. The satisfaction relation is defined as follows: 1. I I= P iff I I= C, for every clause C in P, 2. I I= if u then v iff the existence of an FCG projection rc from u to a principal instance g of I implies the existence of an ideal FCG projection ~* from v+en to I such that (1) the mismatching degree of each mapping from a firm node in u to a node in g is 0, and (2) v+En is derived from v by adding E~ to fuzzy values in all concept and relation nodes that are not firm nodes in v, and (3) for every ce Veu, c*e Vc,, if coref{c, c* } then re*c* = origin(rcc). I is a model of P iff I l= P. A program Q is said to be a logical consequence of a program P iff, for every FCGP interpretation I, if I l= P then I I= Q.
3.3. FCGP Fixpoint Semantics 9As in 22, 20, 14, 9, each FCGP P is associated with an interpretation mapping
Tp, which provides the link between the declarative and procedural semantics of P. The upward iteration of Tp is then defined with TpT0 being the empty ideal FCG.
Definition 3.4 Let P be an FCGP and I be an FCGP interpretation. Then Tp(1) is defined to be norm(Sp(1)ul) where Sp(1) = {v+en I if u then v is a clause in P and x is an FCG projection from u to a principal instance g of I such that (1) the mismatching
276
degree of each mapping from a firm node in u to a node in g is 0, and (2) v+e~ is derived from v by adding e n to fuzzy values in all concept and relation nodes that are not firm nodes in v, and (3) for every c e V c , , c*~Vcv, if coref{c, c*} then coref{c*,
origin(nc) } }. Example 3.2 Let P be the program in Example 3.1 and, for calculation illustration, suppose the following relations between fuzzy sets denoted by linguistic labels:
fairly red = red+e
Tp'~O) = lub{ Tp'~n l n~ N} = Tp'~2 = APPLE: #1---~(ATTRI)~COLOR: @fairly red ---->(ATTR2)~RIPENESS: @fairly ripe. Theorem 3.1 (8) Let P be an FCGP. Then TpStO is the least model of P. The significance of Theorem 3.1 is that it ensures a finite sound and complete mechanical proof procedure for FCGPs. Indeed, if g is a finite FCG and g
4. Procedural Semantics of FCGPs 4.1. FCGP Reductants
Definition 4.1 An FCGP annotation term is recursively defined to be of either of the following forms: 1. A fuzzy value constant, which is a fuzzy attribute-value or a conjunctive fuzzy type, or 2. A+~, where A is a fuzzy value constant and ~ is a variable whose value is a real number in 0,1, or 3. A fuzzy value variable, whose value is a fuzzy attribute-value or a conjunctive fuzzy type, or 4.f(x 1, x 2..... Xm), where each x i (1 < i < m) is an FCGP annotation term a n d f i s a computable (18) and monotonic (f(x 1, x 2..... Xm)
terms.
277
We denote fuzzy value variables by X, Y, .... and real number variables by ~, ~, .... which all are called annotation variables to be distinguished from individual variables denoted by x, y . . . . . An expression without annotation variables is called annotation
variable-free. Definition 4.2 Let P be an FCGP and C 1, C 2..... Cm be different clauses in P, where each C k (1 < k < m) is of the form if u k then v k. Suppose that some concept nodes in Vl, v 2..... v m can be joined by a coreference partition operator t~. Then the clause: if~5Ul-~l U2+~2 ... Um+~m t h e n norm(t~Vl+~l v2+~2 ... Vm+~m) is called a reductant of P, where each Uk+~k (or Vk+~k) is derived from uk (or Vk) by adding ~k to fuzzy values in all concept and relation nodes that are not firm nodes in u k (or Vk). Note that, in Definition 4.2, each real number variable ~k represents an unknown mismatching degree of the body of clause C k to some fact, for Ck taking part in the reductant; ~k = 0 if the body of C k is empty. This, on the other hand, corresponds to a tolerance degree for the head of C k in backward chaining in 4. Moreover, i f ~(Uk+~k)t h e n norm(~(Vk+~k)) is also an FCGP reductant, which is constructed from only Ck; in this case, ~ corresponds to a coreference partitioning in 28 on cut-point concept nodes of v k in a unification with a goal.
Example 4.1 Figure 4.1 illustrates a reductant constructed from the two rules of the FCGP P. The first rule says "If the demand on a product is not high, then its price is not expensive". The second rule says "If the demand on a product is not low, then its price is not cheap". The fact says "The demand on product #2 is normal and its quality is quite good". program P: if
PRODUCT:
*~
t,E~D:@,,ot high I
then
PRODUCT:* ~
PRICE:@notexpensive
,,
P.oouCT:,
then
i PRODUCT: *
low I PRIcE: .o, ch,ae
PRoDuCT:~ ~
~
X~---~
" ~
,
I
I
QUALITY:@quitegood I
a reductant of P:
if
PRoDuCT:* ~.~rr~2)*~ DEM~o:@lubt,,ot high~, ,ot low+~l,}I
then I PRODUCT:* ~ ) ~
PRICE:@lub{notexpensive+~,notcheap+~}I
Fig. 4.1. A reductant of an FCGP
278
Property 4.1 Let P be an FCGP. Any annotation variable-free instance, obtained by a substitution for real number variables, of a reductant of P is a logical consequence of P.
Proof. The proof is on the basis of FCGP declarative semantics and is similar to the proof for the alike property of A F L P reductants (Property 4.1 in 7).
4.2. FCGP Constraints
Definition 4.3 An FCGP constraint is defined to be of the form: ~ -%r & ~2 -%r ... & ~m -%era where, for each i from 1 to m, ~i and d?i are two FCGP annotation terms evaluated to fuzzy values of the same domain. The constraint is said to be normal iff (1) for each i from 1 to m, cri is a simple FCGP annotation term and if o i contains a variable then this variable does not occur in r r ..... r and (2) for every pair ~i and oj (i #j), ~i and crj are not the same conjunctive fuzzy type variable.
Definition 4.4 A solution for an FCGP constraint C is a substitution rp for annotation variables in C such that every annotation variable-free instance of r holds. An FCGP constraint is said to be solvable iff there is an algorithm to decide whether the constraint has a solution or not, and to identify a solution if it exists. Note that, in Definition 4.4, tp does not necessarily contain a binding for every annotation variable. Also, a constraint having a solution is not necessarily solvable, because there may not exist an algorithm to identify what a solution is. On the other hand, a solvable constraint may not have a solution.
Property 4.2 Any normal FCGP constraint is solvable. Proof. The proof is similar to the proof for the solvability of normal AFLP constraints (Property 4.2 in 7). The algorithm for testing satisfiability of a normal FCGP/AFLP constraint is adapted from 20 for constraints on fuzzy value terms.
Example 4.2 The constraint: (X
lub{not high, not low}, moderate = not expensivennot cheap = lub{not expensive, not cheap}. Applying the algorithm presented in 7, one obtains X = quite good, ~ = md(not high / normal) = 0 and ~g = md(not low / normal) = 0, which satisfy the constraint. So, a solution for the constraint is {X/quite good, ~/0, W0}.
279
4.3. FCGP Proof Procedure
Definition 4.5 An FCGP goal G is defined to be of the form QG II CG,where QG is the query part which is a finite FCG whose fuzzy values are simple FCGP annotation terms or of the form lub{~ 1, if2 ..... tSm} where oi's are simple FCGP annotation terms, and C G is the constraint part which is an FCGP constraint. The goal is said to be normal iff (1) C G is a normal FCGP constraint and (2) for a conjunctive fuzzy type variable X, there is at most one occurrence of X in QG or in an inequality X -
Definition 4.6 Let P be an FCGP and G be an FCGP goal. An answer for G w.r.t. P is a triple where p and ~ are respectively a referent specialization operator and a coreference partition operator on G, and tp is a substitution for annotation variables in G. The answer is said to be correct iff tp is a solution for C G and every annotation variable-flee instance of p~tpQ G is a logical consequence of P. The following definition of FCG unification is modified from the one in 4 with the introduction o f FCGP annotation terms and constraints on them. As defined in 4, a VAR generic marker is one whose concept occurs in an FCGP query, or in the body of an FCGP rule, or in the head of an FCGP rule and coreferenced with a concept in the body of the rule; a NON-VAR generic marker is one whose concept occurs in an FCGP fact, or in the head of an FCGP rule but are not coreferenced with any concept in the body of the rule.
Definition 4. 7 Let u and v be finite normal FCGs. An FCG unification from u to v is a mapping 0: u --->v such that: 1. V c e V C : type(c) is matchable to type(Oc) and referent-unified(c, Oc), and 2. V r e V R : type(r) is matchable to type(Or), and 'Vie { 1, 2 ..... arity(r) } : neighbor(Or, i) = Oneighbor(r, i), and 3. No VAR generic maker is unified with different individual markers or noncoreferenced NON-VARgeneric markers. The constraint produced by 0 is denoted by C O and defined by the set {aval(c)
aval(Oc) I c e V c , and c is a fuzzy attribute concept}u{type(c) <~ type(Oc) I ceVc,}~{type(r)
are respec-
Note that, in Definition 4.7, if aval(c) is of the form lub{cs 1, ~2 ..... Gin}, where t~i's are simple FCGP annotation terms, then the constraint lub{t~l, t~ ..... ~m} -
280
Definition 4.8 Let G be an FCGP goal QG I1 CG and C be an FCGP reductant if u then v (G and C have no variables in common). Suppose that there exists an FCG unification 0 from a normalized sub-graph g of QG to v. Then, the corresponding resolvent of G and C is a new FCGP goal denoted by Ro(G,C) and defined to be P0~0~50QG u II C0 & CG, where 80 deletes g from QG-
Property 4.3 Let G and C be respectively an FCGP goal and an FCGP reductant. If G is a normal FCGP goal, then any resolvent of G and C is also a normal FCGP goal.
Proof The proof is similar to the proofs for the alike properties of annotated logic programs (Lemma 2 in 20) and AFLPs (Property 4.3 in 7). Note that the order of the inequalities in C o is not significant, but the order of C o and C G in Definition 4.8 is.
Definition 4.9 Let P be an FCGP and G be an FCGP goal. A refutation of G and P is a finite sequence G G 1 ... Gn_ 1 G n such that: 1. For each i from 1 to n, Gi= Roi(Gi_l,Ci), where GO= G and C i is a reductant of P, and 2. QG, is empty, and 3. CG, is solvable and has a solution.
Example 4.3 Let P be the program in Example 4.1 and G be the following FCGP goal querying "Which product has a moderate price and what is its quality like?": PRODUCT: *x --->(ATTR2)=~PRICE: @moderate ---->(ATTR3)~ QUALITY: @X Assuming the relations between the linguistic labels in P and G as in Example 4.2, a refutation of G and P can be constructed as follows: go = PRODUCT:*x--->(ATTR2)~PRICE:@m~ (a sub-graph of QG) C 1 = if PRODUCT:*y--->(ATTR1)=~DEMAND: @tub{not high+~, not low+ql} (u) then PRODUCT: *y--~(ATTR2):=*,PRICE: @ lub {not expensive+ G, not cheap+ql } (v ) 01: go --->v, p01 = { }, ~ol = { {PRODUCT:*x, PRODUCT:*y } } G 1 = PRODUCT: *y---)(ATTR 1)==~DEMAND: @lub{not high+~, not low+ql} -->(AT'rR3)~ QUALITY: @X II (moderate (ATTR1 ) ~ DEMAND: @lub { not high+ G, not low+~ } (a sub-graph of QG1) c2 PRODUCT: #2--)(ATTRI)=~DEMAND: @normal --)(ATTRa)=OQUALITY: @quite good 02: gl ---) C2, P02= {(PRODUCT:*y, #2)}, 1D02= { } G 2 = #2-->(ATTR3)=:~QUALITY: @X
II (lub{not high+ G, not low+q1} <-tnormal) & (moderate -
281
c3--c: 03: QG 2 ---) C3, P03 = { }, 1~03= { } G3 = II (X
(moderate
II (X st quite good) & (not high+~ ~ normal) & (not low+W -
As in Example 4.2, one has X = quite good and ~ = W = 0 as a solution for the constraint above, whence the corresponding answer for G w.r.t. P is <{(PRODUCT:*X, #2) }, { }, {X/quite good}>. Note that, if a clause rather than a reductant of P were used to resolve go, there would not be a refutation of G and P because, generally, neither moderate -
is applied when gl is deleted from QG 1.
The following theorems state the soundness and the completeness of this FCGP proof procedure. Due to space limitation we omit the proofs for these theorems, which were presented in the submitted version of this paper.
Theorem 4.4 (Soundness) Let P be an FCGP and G be an FCGP goal. If G G 1 ... Gn_ 1 G n is a refutation of G and P, and 9 is a solution for CG,, then is a correct answer for G w.r.t.P.
Theorem 4.5 (Completeness) Let P be an FCGP and G be a normal FCGP goal. If there exists a correct answer for G w.r.t. P, then there exists a refutation of G and P. 4.4. Remarks A crisp attribute-value is a special fuzzy one defined by a fuzzy set whose membership function only has values 0 or 1. A basic type is a special fuzzy one whose fuzzy truth-value is absolutely true. So, a CG can be considered as a special FCG and a CGP as a special FCGP with all nodes in each of its rules being firm nodes. We now give remarks on proof procedures for both FCGPs and CGPs from the viewpoint of lattice-based reasoning. For discussion, let us consider the following CGP as a special FCGP: if PERSON: *X--)(WORK_FOR)--)PERSON: * then EMPLOYEE: *x if PERSON: *y--~(ATTEND)--~UNIVERSITY: * then STUDENT: *y PERSON: John----Y(WORK FOR)---)PERSON: * --)(ATrEND)--->UNIVERSITY: Queensland PERSON: John---)(BROTHER OF)---)GIRL: Mary where the first rule says "A person is an employee if working for another", the second rule says "A person is a student if attending a university", the first fact says "John works for some person and attends university Queensland", and the second fact says "John is a brother of Mary". Note the rules in this CGP, where two coreferenced concepts occur in the body
282
and the head of a rule with two different concept types. These rules realize a close coupling between the concept type hierarchy and the axiomatic part of a knowledge base (3, 4). A backward chaining proof procedure based on clause selection like the ones in 15, 28, 4 is not complete when such rules are present or facts are not in CG normal form. For example, it cannot satisfy the goal EMPLOYEE-STUDENT" John where EMPLOYEE-STUDENT= lub{EMPLOYEE,STUDENT}, because it does not combine rule-defined concept types of an individual, which are EMPLOYEE and STUDENTin this case. Meanwhile, CG normal form is required to combine fact-defined concept types of an individual. Such combinations are inherent in a forward chaining method (cf. 28, 19). Actually, the significance of FCGP reductants is to combine concept types as well as other lattice-based data for backward chaining. In this example, a reductant of the CGP is: if PERSON: *X-->(WORK_FOR)-->PERSON: * then EMPLOYEE-STUDENT: *x ---9(ATTEND)-->UNIVERSITY: * which together with the first fact resolve the goal EMPLOYEE-STUDENT: John. Moreover, in the light of annotated logic programming (20, 7), types have been viewed as annotations which can also be queried about. This then reveals an advantage of CG notation that makes this view possible, which has not been addressed in the previous works on CGPs/FCGPs (15, 28, 4, 19). With classical first-order logic notation, this view is hindered due to types being encoded in predicate symbols, whence queries about sorts of objects or relations among objects have not been thought about (cf. 1, 3). For example, the following CG query asks "What is John and what is John's relation with Mary?": X: John--->(Y)---->PERSON: Mary where X is a concept type variable and Y is a relation type variable. Applying the presented FCGP proof procedure, one obtains X = EMPLOYEE-STUDENT and Y = BROTHER_OF, which say "John is an employee and a student, and John is a brother of Mary", as the most informative answer w.r.t, the given CGP.
5. Conclusions The syntax of FCGPs with the introduction of fuzzy types has been presented, providing unified structure and treatment for both FCGPs and CGPs. The general declarative semantics of FCGPs based on the notion of ideal FCGs has been defined, ensuring finite proofs of logical consequences of programs. The fixpoint semantics of FCGPs has been studied as the bridge between their declarative and procedural semantics. Then, a new SLD-style proof procedure for FCGPs has been developed and proved to be sound and complete w.r.t, their declarative semantics. The two main new points in the presented FCGP proof procedure are that, it selects reductants rather than clauses of an FCGP in resolution steps and involves solving constraints on fuzzy value terms. As it has been analysed, a CGP/FCGP SLD-style proof procedure based on clause selection is not generally complete. The constraint solving supports more expressive queries which are possibly about not only fuzzy attribute-values but also fuzzy types. Since a CGP can be considered as a special FCGP, the results obtained here for
283
F C G P s could be applied to C G P systems. They could also be useful for any extension that adds to CGs lattice-based annotations to enhance their knowledge representation and reasoning power. The presented F C G P system, on one hand, extends C G P s to deal with vague and imprecise information pervading the real world as reflected in natural languages. On the other hand, to our knowledge, it is the first fuzzy order-sorted logic programming system for handling uncertainty about types o f objects. W h e n only fuzzy sets o f special cases are involved, F C G P s could become possibilistic CGPs, where concept and relation nodes in a C G are weighted by only values in 0,1 interpreted as necessity degrees. They are less expressive than general F C G P s but have simpler computation and are still very useful for CG-based systems dealing with uncertainty. Besides, F C G P s could be extended further to represent and reason with other kinds of uncertain knowledge, such as imprecise temporal information or vague generalized quantifiers. These are among the topics that are currently being investigated. A c k n o w l e d g m e n t . We would like to thank Marie-Laure Mugnier and the anonymous referees for the comments that help us to revise the paper for its readability. References 1. Ait-Kaci, H. & Nasr, R. (1986), Login: A Logic Programming Language with Built-In Inheritance. J. of Logic Programming, 3: 185-215. 2. Baldwin, J.E & Martin, T.P. & Pilsworth, B.W. (1995), Fril - Fuzzy and Evidential Reasoning in Artificial Intelligence. John Wiley & Sons, New York. 3. Beierle, C. & Hedtstuck, U. & Pletat, U. & Schmitt, P.H. & Siekrnann, J. (1992), An Order-Sorted Logicfor Knowledge Representation Systems. J. of Artificial Intelligence, 55: 149-191. 4. Cao, T.H. & Creasy, P.N. & Wuwongse, V. (1997), Fuzzy Unification and Resolution Proof Procedure for Fuzzy Conceptual Graph Programs. In Lukose, D. et al. (Eds.): Conceptual Structures - Fulfilling Peirce's Dream, LNAI No. 1257, Springer-Verlag, pp. 386-400. 5. Cao, T.H. & Creasy, P.N. & Wuwongse, V. (1997), Fuzzy Types and Their Lattices. In Proc. of the 6th IEEE International Conference on Fuzzy Systems, pp. 805-812. 6. Cao, T.H. & Creasy, P.N. (1997), Universal Marker and Functional Relation: Semantics and Operations. In Lukose, D. et al. (Eds.): Conceptual Structures - Fulfilling Peirce's Dream, LNAI No. 1257, Springer-Verlag, pp. 416-430. 7. Cao, T.H. (1997), Annotated Fuzzy Logic Programs. Int. J. of Fuzzy Sets and Systems. To appear. 8. Cao, T.H & Creasy, P.N. (1997), Fuzzy Conceptual Graph Programs and Their Fixpoint Semantics. Tech. Report No. 424, Department of CS&EE, University of Queensland. 9. Cao, T.H. (1998), Annotated Fuzzy Logic Programsfor Soft Computing. In Proc. of the 2nd International Conference on Computational Intelligence and Multimedia Applications, World Scientific, pp. 459-464. 10. Carpenter, B. (1992), The Logic of Typed Feature Structures with Applications to Unification Grammars, Logic Programs and Constraint Resolution. Cambridge University Press. 11. Chevallet, J-P. (1992), Un ModUle Logique de Recherche d'Informations Appliqud au Formalisme des Graphes Conceptuels. Le Prototype ELEN et Son Expdrimentation sur un Corpus de Composants Logiciels. PhD Thesis, Universit6 Joseph Fourier. 12. Dubois, D. & Lang, J. & Prade, H., (1994) PossibilisticLogic. In Gabbay, D.M. et al. (Eds.): Handbook of Logic in Artificial Intelligence and Logic Programming, Vol. 3, Oxford University Press, pp. 439-514. 13. Genest, D. & Chein, M. (1997), An Experiment in Document Retrieval Using Conceptual Graphs. In Lukose, D. et al. (Eds.): Conceptual Structures - Fulfilling Peirce's Dream, LNAI No. 1257, Springer-Verlag, pp. 489-504. 14. Ghosh, B.C. & Wuwongse, V. (1995), Conceptual Graph Programs and Their Declarative Semantics. IEICE Trans. on Information and Systems, Vol. E78-D, No. 9, pp. 1208-1217.
284
15. Ghosh, B.C. (1996), Conceptual Graph Language - A Language of Logic and Information in Conceptual Structures. PhD Thesis, Asian Institute of Technology. 16. Gr~itzer, G. (1978), GeneralLattice Theory. Academic Press, New York. 17. Ho, K.H.L. (1994), Learning Fuzzy Concepts By Examples with Fuzzy Conceptual Graphs. In Proc. of the 1st. Australian Conceptual Structures Workshop. 18. Hopcroft, J.E. & Ullman, J.D. (1979), Introduction to Automata Theory, Languages, and Computation. Addison-Wesley, Massachusetts. 19. Kerdiles, G. & Salvat, E. (1997), A Sound and Complete CG Proof Procedure Combining Projections with Analytic Tableaux. In Lukose, D. et al. (Eds.): Conceptual Structures - Fulfilling Peirce's Dream, LNAI No. 1257, Springer-Verlag, pp. 371-385. 20. Kifer, M. & Subrahmanian, V.S. (1992), Theory of Generalized Annotated Logic Programming and Its Applications. J. of Logic Programming, 12: 335-367. 21. Klawonn, F. (1995), Prolog Extensions to Many-Valued Logics. In H/Shle, U. & Klement, E.P. (Eds.): Non-Classical Logics and Their Applications to Fuzzy Subsets, Kluwer Academic Publishers, Dordrecht, pp. 271-289. 22. Lloyd, J.W. (1987), Foundations of Logic Programming. Springer-Verlag, Berlin. 23. Magrez, P. & Smets, P. (1989), Fuzzy Modus Ponens: A New Model Suitable for Applications in Knowledge-Based Systems. Int. J. of Intelligent Systems, 4: 181-200. 24. Mineau, G.W. (1994), Views, Mappings and Functions: Essential Definitions to the Conceptual Graph Theory. In Tepfenhart, W.M. & Dick, J.P. & Sowa, J.F. (Eds.): Conceptual Structures Current Practices, LNAI No. 835, Springer-Verlag, pp. 160-174. 25. Morton, S. (1987), Conceptual Graphs and Fuzziness in Artificial Intelligence. PhD Thesis, University of Bristol. 26. Mukaidono, M. & Shen, Z. & Ding, L. (1989), Fundamentals of Fuzzy Prolog. Int. J. of Approximate Reasoning, 3: 179-194. 27. Myaeng, S.H. & Khoo, C. (1993), On Uncertainty Handling in Plausible Reasoning with Conceptual Graphs. In Pfeiffer, H.D. & Nagle, T.E. (Eds.): Conceptual Structures - Theory and Implementation, LNAI No. 754, Springer-Verlag, pp. 137-147. 28. Salvat, E. & Mugnier, M.L. (1996), Sound and Complete Forward and Backward Chainings of Graph Rules. In Eklund, P.W. & Ellis, G. & Mann, G. (Eds.): Conceptual Structures - Knowledge Representation as Interlingua, LNAI No. 1115, Springer-Verlag, pp. 248-262. 29. Sowa, J.E (1984), Conceptual Structures: Information Processing in Mind and Machine. AddisonWesley, Massachusetts. 30. Sowa, J.F. (1991), Towards the Expressive Power of Natural Languages. In Sowa, J.F. (Ed.): Principles of Semantic Networks - Explorations in the Representation of Knowledge, Morgan Kaufmann Publishers, San Mateo, CA, pp. 157-189. 31. Sowa, J.E (1997), Matching Logical Structure to Linguistic Structure. In Houser, N. & Roberts, D.D. & Van Evra, J. (Eds.): Studies in the Logic of Charles Sanders Peirce, Indiana University Press, pp. 418-444. 32. Umano, M. (1987), Fuzzy Set Prolog. In Preprints of the 2nd International Fuzzy Systems Association Congress, pp. 750-753. 33. Wuwongse, V. & Manzano, M. (1993), Fuzzy Conceptual Graphs. In Mineau, G.W. & Moulin, B. & Sowa, J.E (Eds.): Conceptual Graphs for Knowledge Representation, LNAI No. 699, SpringerVerlag, pp. 430-449. 34. Wuwongse, V. & Cao, T.H. (1996), Towards Fuzzy Conceptual Graph Programs. In Eklund, P.W. & Ellis, G. & Mann, G. (Eds.): Conceptual Structures - Knowledge Representation as Interlingua, LNAI No. 1115, Springer-Verlag, pp. 263-276. 35. Zadeh, L.A. (1965), Fuzzy Sets. J. of Information and Control, 8: 338-353. 36. Zadeh, L.A. (1978), PRUF - A Meaning Representation Languagefor Natural Languages. Int. J. of Man-Machine Studies, 10: 395-460. 37. Zadeh, L.A. (1990), The Birth and Evolution of Fuzzy Logic. Int. J. of General Systems, 17: 95105. 38. Zadeh, L.A. (1996), Fuzzy Logic = Computing with Words. IEEE Trans. on Fuzzy Systems, 4: 103111.
Knowledge Querying in the Conceptual Graph Model: The RAP Module Olivier Guinaldo 1 and Ollivier Haemmerl~ 2 1 LIMOS - U. d'Auvergne, IUT de Clermont-Ferrand, BP 86, F-63172 Aubi~re Cedex, France guinaldo@volcans-ia, univ-bpclermont, fr
2 INA-PG, D~partement OMIP, 16, rue Claude Bernard F-75231 Paris Cedex 05, France Ollivier. gaemmerle@inapg, inra. fr
A b s t r a c t . The projection operation can be used to query a CG knowledge base by searching all the specializations of a particular CG - the question. But in some cases it may not be enough, particularly when the knowledge allowing an answer is distributed among several graphs belonging to the fact base. We define two operating mechanisms of knowledge querying, that work by means of graph operations. Both these mechanisms are equivalent and logically based. The first one modifies the knowledge base, while the second modifies the question. The RAP module is an implementation of the last algorithm on CoGITo.
1 Introduction The specialization relation, which can be computed by means of the projection operation, is the basis for the reasoning in the CG model. It expresses that one graph contains a more specific knowledge than another. One of the strong points of the CG model is that there exist sound and complete logical semantics, which means that the graphical reasoning is equivalent to the logical deduction upon the logical formulae associated with the graphs 1,
2. In this paper, we consider a knowledge based system in which the fact base and the query are represented in terms of CGs. An important step is to provide methods allowing one to query such a fact base. The projection operation can be used for such a search, but the problem is that the knowledge allowing one to answer a query can be distributed among several graphs of the knowledge base, in which case no projection can be made. We propose two algorithms designed to avoid that inconvenience. These algorithms are based on those of the ROCK system 3, 4. In the R