Inference in Cyc. Copyright 2002 Cycorp

Similar documents
Artificial Intelligence Prof. P. Dasgupta Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur

Inference in Cyc. This is the final lesson in the Inference Tutorial. It will focus on microtheories and forward/backward inference.

Revisiting the Socrates Example

Artificial Intelligence: Valid Arguments and Proof Systems. Prof. Deepak Khemani. Department of Computer Science and Engineering

(Refer Slide Time 03:00)

Artificial Intelligence. Clause Form and The Resolution Rule. Prof. Deepak Khemani. Department of Computer Science and Engineering

Semantic Entailment and Natural Deduction

Announcements. CS243: Discrete Structures. First Order Logic, Rules of Inference. Review of Last Lecture. Translating English into First-Order Logic

In this section you will learn three basic aspects of logic. When you are done, you will understand the following:

Artificial Intelligence Prof. P. Dasgupta Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur

A BRIEF INTRODUCTION TO LOGIC FOR METAPHYSICIANS

Reasoning and Decision-Making under Uncertainty

Russell on Denoting. G. J. Mattey. Fall, 2005 / Philosophy 156. The concept any finite number is not odd, nor is it even.

Day 3. Wednesday May 23, Learn the basic building blocks of proofs (specifically, direct proofs)

INTERMEDIATE LOGIC Glossary of key terms

Selections from Aristotle s Prior Analytics 41a21 41b5

Logicola Truth Evaluation Exercises

Announcements. CS311H: Discrete Mathematics. First Order Logic, Rules of Inference. Satisfiability, Validity in FOL. Example.

A. Problem set #3 it has been posted and is due Tuesday, 15 November

Basic Concepts and Skills!

10.3 Universal and Existential Quantifiers

Chapter 6, Tutorial 1 Predicate Logic Introduction

Also, in Argument #1 (Lecture 11, Slide 11), the inference from steps 2 and 3 to 4 is stated as:

What would count as Ibn Sīnā (11th century Persia) having first order logic?

HANDBOOK (New or substantially modified material appears in boxes.)

Module 5. Knowledge Representation and Logic (Propositional Logic) Version 2 CSE IIT, Kharagpur

HANDBOOK (New or substantially modified material appears in boxes.)

Pearson Education Limited Edinburgh Gate Harlow Essex CM20 2JE England and Associated Companies throughout the world

HANDBOOK. IV. Argument Construction Determine the Ultimate Conclusion Construct the Chain of Reasoning Communicate the Argument 13

Bertrand Russell Proper Names, Adjectives and Verbs 1

Semantic Foundations for Deductive Methods

Venn Diagrams and Categorical Syllogisms. Unit 5

16. Universal derivation

Verification and Validation

Early Russell on Philosophical Grammar

A Note on Straight-Thinking

(1) A phrase may be denoting, and yet not denote anything; e.g., 'the present King of France'.

2.1 Review. 2.2 Inference and justifications

Logic & Proofs. Chapter 3 Content. Sentential Logic Semantics. Contents: Studying this chapter will enable you to:

CHAPTER 1 A PROPOSITIONAL THEORY OF ASSERTIVE ILLOCUTIONARY ARGUMENTS OCTOBER 2017

Foundations of Knowledge Representation in Cyc

Logic: The Science that Evaluates Arguments

2.3. Failed proofs and counterexamples

6.080 / Great Ideas in Theoretical Computer Science Spring 2008

Transition to Quantified Predicate Logic

An Introduction to. Formal Logic. Second edition. Peter Smith, February 27, 2019

CONTENTS A SYSTEM OF LOGIC

Chapter 9- Sentential Proofs

HOW TO ANALYZE AN ARGUMENT

Russell: On Denoting

logic is everywhere Logik ist überall Hikmat har Jaga Hai Mantık her yerde la logica è dappertutto lógica está em toda parte

Chapter 8 - Sentential Truth Tables and Argument Forms

Part II: How to Evaluate Deductive Arguments

SOME RADICAL CONSEQUENCES OF GEACH'S LOGICAL THEORIES

Suppressed premises in real life. Philosophy and Logic Section 4.3 & Some Exercises

A Model of Decidable Introspective Reasoning with Quantifying-In

UC Berkeley, Philosophy 142, Spring 2016

Moore on External Relations

Logic: Deductive and Inductive by Carveth Read M.A. CHAPTER VI CONDITIONS OF IMMEDIATE INFERENCE

Logic for Computer Science - Week 1 Introduction to Informal Logic

The Development of Laws of Formal Logic of Aristotle

Philosophy 1100: Introduction to Ethics. Critical Thinking Lecture 1. Background Material for the Exercise on Validity

Van Inwagen's modal argument for incompatibilism

The SAT Essay: An Argument-Centered Strategy

9 Methods of Deduction

6: DEDUCTIVE LOGIC. Chapter 17: Deductive validity and invalidity Ben Bayer Drafted April 25, 2010 Revised August 23, 2010

1. Lukasiewicz s Logic

1 Clarion Logic Notes Chapter 4

9.1 Intro to Predicate Logic Practice with symbolizations. Today s Lecture 3/30/10

Module 02 Lecture - 10 Inferential Statistics Single Sample Tests

Mathematics in and behind Russell s logicism, and its

Artificial Intelligence Prof. Deepak Khemani Department of Computer Science and Engineering Indian Institute of Technology, Madras

Overview of Today s Lecture

Logical (formal) fallacies

Logic Appendix: More detailed instruction in deductive logic

Quantificational logic and empty names

Structure and essence: The keys to integrating spirituality and science

Philosophy 1100: Ethics

Richard Carrier, Ph.D.

What is the Frege/Russell Analysis of Quantification? Scott Soames

Searle vs. Chalmers Debate, 8/2005 with Death Monkey (Kevin Dolan)

Aquinas, The Divine Nature

Anthony P. Andres. The Place of Conversion in Aristotelian Logic. Anthony P. Andres

Experimental Design. Introduction

Logic: Deductive and Inductive by Carveth Read M.A. CHAPTER IX CHAPTER IX FORMAL CONDITIONS OF MEDIATE INFERENCE

Tautological Necessity and Tautological Validity With Quantifiers

SYLLOGISTIC LOGIC CATEGORICAL PROPOSITIONS

[3.] Bertrand Russell. 1

1. Introduction Formal deductive logic Overview

Informalizing Formal Logic

ON DENOTING BERTRAND RUSSELL ORIGINALLY PUBLISHED IN MIND 14.4 (1905): THIS COPY FROM PHILOSOPHY-INDEX.COM.

Outline. 1 Review. 2 Formal Rules for. 3 Using Subproofs. 4 Proof Strategies. 5 Conclusion. 1 To prove that P is false, show that a contradiction

Introduction. I. Proof of the Minor Premise ( All reality is completely intelligible )

You submitted this quiz on Mon 14 Oct :41 PM PDT (UTC -0700). You got a score of out of

Haberdashers Aske s Boys School

Artificial Intelligence Prof. Deepak Khemani Department of Computer Science and Engineering Indian Institute of Technology, Madras

Chapter 3: Basic Propositional Logic. Based on Harry Gensler s book For CS2209A/B By Dr. Charles Ling;

What is a logical argument? What is deductive reasoning? Fundamentals of Academic Writing

What is Game Theoretical Negation?

Negative Introspection Is Mysterious

Transcription:

Inference in Cyc Logical Aspects of Inference Incompleteness in Searching Incompleteness from Resource Bounds and Continuable Searches Efficiency through Heuristics Inference Features in Cyc We ll be talking about Inference in Cyc. Inference is the mechanism we use to conclude new facts from other existing facts and rules in the system. We ll be talking about it in four sections and the first section will be about the logical aspects of inference. 1

Inference uses Deduction: Rules Rules - general, variables (#$mother?person?mother) (#$loves?person?mother)) Rules are very general statements in a formal logical language, such as this formula, under Rules, which essentially says that everyone loves their mother. If?MOTHER is the mother of some?person, then that?person loves that?mother. It s a conditional statement. It s general -- it doesn t apply to one specific thing and it quantifies over objects in the world. As such it usually has variables (i.e.?person ) in it and there are usually multiple literals, or statements, that are connected together by logical connectives (i.e. implies ). Rules tend to be the complicated logical statements. The other statements in the system can be colloquially described as facts. 2

Inference uses Deduction: Facts Facts - specific, no variables, atomic (#$mother #$Hamlet #$Gertrude) Facts tend to be about some very specific thing in the world -- unlike rules which are general. They tend to be ground, meaning that they don t have any variables in them, because they re talking about some specific case, they re not quantifying over the world. Facts are also atomic, which has to do with it being a single statement, like the mother of Hamlet is Gertrude. It is the application of a predicate, #$mother, to arguments, #$Hamlet and #$Gertrude. So the rule from the previous slide would not be atomic because there are two literals connected together by a logical connective to say that if this (a person has a mother) were the case, then this (a person loves their mother) would be the case. So something is atomic if there is no conditional aspect to it, if it s just a single statement. Facts are more formally called ground atomic formulas because they are formulas that are both ground and atomic. 3

Inference uses Deduction: Non-atomic terms, Predicates, and Functions Non-atomic terms are functional (#$BabyFn #$Jaguar) Predicates are true or false (#$mother #$Hamlet #$Gertrude) Functions denote a new term (#$BabyFn #$Jaguar) A non-atomic term would be a functional term, something like (#$BabyFn #$Jaguar). Let s say you had a function called #$BabyFn that applies to any animal type and you can use it to denote the baby forms of any animal. So you could denote a baby cat, a baby whale, or a baby jaguar. There is a distinction between predicates and functions in logic. Predicates are statements about the truth of something -- it is either true or it s not. In the case of (#$mother #$Hamlet #$Gertrude), it s stating it is true that the mother of Hamlet is Gertrude. Functions denote a new term that you re talking about. The application of #$BabyFn to #$Jaguar does not say it is true that BabyFn of Jaguar. That doesn t make any sense. The application of #$BabyFn to #$Jaguar allows you to denote a new concept, that of Baby Jaguar. Functions and predicates can both be used to make what Cyc calls formulas. 4

Inference uses Deduction: Formulas and Logic Formula - a relation applied to arguments (#$mother?person?mother) (#$loves?person?mother)) Cyc s Inference uses standard logical deductions All men are mortal. Socrates is a man. Socrates is mortal. A formula is just an operator applied to arguments. In that sense, logical connectives like #$implies, #$and, and #$or are also operators. So the previous example of a rule is a formula as well. The operator #$implies takes two formulas as arguments and maks a larger formula. This is what a logical connective is -- it is something that connects formulas into more complex formulas. The basis for inference in Cyc is just performing the standard logical deductions or syllogisms that you learn in logic classes: All men are mortal. Socrates is a man. Therefore, Socrates is mortal. This is just to point out that the basis of our system is not Bayesian Reasoning or fuzzy logic or something like that. For every inference step we make, we actually have a logicallysound proof behind it that you can look at to see X is true specifically because I did a deduction and Y and Z are the two things which together allow me to conclude it. This will be important later, when we describe how we perform truth maintenance in our system. 5

Inference uses Deduction: Rules + Facts Deduction - rule + fact(s) => new fact (#$loves #$Hamlet #$Gertrude) Rules - general, variables (#$mother?person?mother) (#$loves?person?mother)) Facts - specific, no variables (#$mother #$Hamlet #$Gertrude) Our system uses logical deduction as the basis for inference. This can be tersely summarized as the application of rules plus facts to conclude some new facts. An example of a fact is the mother of Hamlet is Gertrude. You can use this fact plus the rule from previous slides to perform a logical deduction. This deductive inference would be that because of this rule (everyone loves their mother) and this fact (the mother of Hamlet is Gertrude) you can logically conclude that Hamlet loves Gertrude. 6

The Resolution Principle Resolution Principle : Unify, Substitute, Merge Query Rule (#$mother?person?mother) (#$loves?person?mother)) Let s talk in a little more detail about how we perform these logical deductions. The specific method that we use is the Resolution Principle. The Resolution Principle is a very standard logical mechanism for connecting two logical statements to come up with a third one. The algorithm that embodies the resolution principle can be tersely summarized as Unify, Substitute, and Merge, in that order. I ll describe each of these steps in this next example. Assume for a moment that I have a question that I m asking the system: Who is it that Hamlet both knows and loves? I want the system to try and prove what answers for Who? are in our system. So, given that the formula on the left of the slide is the query that I m asking, and we have the rule on the right of the slide in our system (which says that everyone loves their mother), then one way of concluding who someone loves would be if you know who their mother is. 7

The Resolution Principle: Unify Resolution Principle : Unify, Substitute, Merge Query Rule (#$mother?person?mother) (#$loves?person?mother)) Pivot Literals I can use the query and the rule to perform one logical deductive step: I can prove an answer for your query if I can prove an answer for something else because of some rule in the system. In effect, an application of the Resolution Principle allows you to take one logical formula and use it in concert with the thing you re trying to prove to help you turn it into something else you should try and prove. This can either be more complicated or less complicated than what you start with. I ll talk about the ramifications of both of those options later. For now, let s look at how we would perform this one step in this case. The act of combining the query and the rule to help answer part of the query is one deductive step. The following is how we apply the resolution principle to this situation. The key is to identify one particular literal which is common between the two. In this case, we have the literal Who does Hamlet love? and a rule that would allow us to conclude who everyone loves. Who does Hamlet love? would be called the pivot literal in the query and Person loves its mother would be called the pivot literal in the rule because these are the literals around which the whole step pivots. So we identify that we are going to try and prove this literal, (#$loves #$Hamlet?WHO), using the rule on the right of the slide. 8

The Resolution Principle: Unify Resolution Principle : Unify, Substitute, Merge Query Rule (#$mother?person?mother) (#$loves?person?mother)) Most General Unifier #$Hamlet /?PERSON?WHO /?MOTHER = Se we have decided to see if we can prove the loves part, the third line of the query, using the third line of the rule. We can do it by unifying the loves from the query with the loves from the rule. The unification step is attempting to identify a way of making the two loves literals exactly the same. This is the essence of Unification. We re trying to come up with a recipe for how to make both of these actually exactly the same. That recipe is referred to as the Most General Unifier. This is a recipe for substituting one thing for another such that if you did the substitution, then you would actually have the exact same thing. So, in this case, we can get the literals to be exactly the same with this proviso: if #$Hamlet is matched up with?person and?who is matched up with?mother. It s called the Most General Unifier because we make the most conservative recipe possible -- we re not committing to anything more than we have to in order to get these things to match and that makes it most general. So once we ve identified the Most General Unifier, the most general recipe for making them the same, we ve completed the unifying step. 9

The Resolution Principle: Substitute Resolution Principle : Unify, Substitute, Merge Query Most General Unifier #$Hamlet /?PERSON?WHO /?MOTHER Rule (#$mother?person?mother) (#$loves?person?mother)) Substituted Query Substituted Rule (#$mother #$Hamlet?WHO) Given the Most General Unifier, we can apply this recipe to both of them to perform the Substitution step. We apply this recipe to one literal in order to get it to be the same as the other. If I substitute into the rule, #$Hamlet for?person and?who for?mother, I ll then have something in which the third line of both the query and the rule exactly match. We also apply the Most General Unifier to the rest of the query and the rule. This is a simple unification, but it is common in the inference that Cyc normally does. 10

The Resolution Principle: Merge Resolution Principle : Unify, Substitute, Merge Substituted Query Substituted Rule (#$mother #$Hamlet?WHO) (#$loves?hamlet?who)) Merged Query (#$mother #$Hamlet?WHO)) The final step is the Merge step, where we then take the remaining pieces of both and merge them together into something like what you see at the bottom of the slide. The loves part disappears because that s the thing that actually got proved in this step. The result of the merge is a combination of the two substituted pieces together. So, we start out with Who does Hamlet know and love? and using this rule, Everyone loves their mother, we can turn our original query into Who does Hamlet know? And is that person Hamlet s mother? If I were to find an answer for the new, merged question, then because of the rule, it would be an answer for the query. So what results is a new thing, shown at the bottom of the slide, that we try and prove. It indicates that any answer for the formula, because of the rule on the right of the slide, would be an answer for the query on the left of the slide. 11

The Resolution Principle using a fact Query Resolution Principle : Unify, Substitute, Merge Fact (#$loves #$Hamlet #$Ophelia) Most General Unifier?WHO / #$Ophelia (#$knows #$Hamlet #$Ophelia) So, the act of inference is taking things that you're trying to prove and applying things you already know in order to find different things to prove. Hopefully these things you are trying to prove eventually reduce down to something like true which is patently true already and does not need to be proven. Therefore, the path of how you got there would provide one complete logical proof of an answer. Let s look at another example of the Resolution Principle -- one that uses a fact instead of a rule. Let s say that we actually have Hamlet loves Ophelia as a fact instead of a rule. We re still asking Who does Hamlet know and love? I can use the fact Hamlet loves Ophelia to resolve against the loves literal in the query. In this case, the Most General Unifier would be simpler. It would just be matching?who with #$Ophelia. All that would be left to prove is if Hamlet knows Ophelia, so down below we have a very simple statement. This would usually be proved using some other knowledge, for example Ophelia is Hamlet s friend and everyone knows their friends, or something like that. With this, I could reduce the formula (#$knows #$Hamlet #$Ophelia) down to #$True. There would be nothing left to prove. It would be like there being an empty degenerate ) in the query, which is equivalent to #$True. This example shows that the use of a fact strictly simplifies a proof, while the use of a rule usually leaves a proof at least as complicated and sometimes more complicated (if it has more conditions in the antecedent) than the original. 12

Resolving to #$True Query Rule Most General Unifier New Query Hamlet knows and loves Ophelia. New Query Rule Most General Unifier Newer Query Newer Query Rule Most General Unifier Newest Query Newest Query Fact Most General Unifier #$True #$True => the end Let me say more about proving True. Once you arrive at #$True as the final thing to prove, you can realize that #$True is true, so you ve actually finally proved it -- you ve reached the end. This leaves you with one complete deductive proof such that you can walk backwards and say What did I use in each step along the way? and collect up the formulas that you used along the way to make each step. By collecting all of the Most General Unifiers involved in the proof, you can see things like what did this variable?who get bound to? Oh, it eventually got bound to #$Ophelia here. So this kind of information keeps getting passed up to the top and eventually out the top will bubble an answer. Here is one answer for what you asked for and the path all the way down has each step along the way -- the intermediate steps (Most General Unifiers) and how you proved them, and what you used to justify this answer. Next we ll be talking about how we actually algorithmically perform all of these resolution steps. We just described logically how Cyc performs inference and in the next lesson we re going to describe in more detail the mechanism that we use to perform these logical deductions. 13

Summary Inference uses Deduction Facts + Rules => New Fact Rules vs. Facts Predicates vs. Functions Inference uses Resolution The Resolution Principle: Unify, Substitute, Merge Resolving to #$True This concludes the lesson on the logical aspects of Inference. 14