Knowledge Representation Lecture 2 out of 5. Last Week Intelligence needs knowledge We need to represent this knowledge in a way a computer can process.

Slides:



Advertisements
Similar presentations
Artificial Intelligence
Advertisements

1 Knowledge Representation Introduction KR and Logic.
Propositional Logic CMSC 471 Chapter , 7.7 and Chuck Dyer
Knowledge Representation Methods
AI - Week 13 Knowledge Representation, Logic, Semantic Web Lee McCluskey, room 2/07
Outline Recap Knowledge Representation I Textbook: Chapters 6, 7, 9 and 10.
CSCI 5582 Fall 2006 CSCI 5582 Artificial Intelligence Lecture 9 Jim Martin.
1 Chapter 7 Propositional and Predicate Logic. 2 Chapter 7 Contents (1) l What is Logic? l Logical Operators l Translating between English and Logic l.
Modelling Conceptual Knowledge using Logic - Week 6 Lee McCluskey Department of Computing and Mathematical Sciences University of Huddersfield.
Formal Aspects of Computer Science – Week 12 RECAP Lee McCluskey, room 2/07
CIA2326 Week4: Predicate Logic : introduction Lee McCluskey, room 2/07
Predicates and Quantifiers
Ming Fang 6/12/2009. Outlines  Classical logics  Introduction to DL  Syntax of DL  Semantics of DL  KR in DL  Reasoning in DL  Applications.
First Order Logic Chapter 7. PL is a Weak Representational Language §Propositional Logic (PL) is not a very expressive language because: §Hard to identify.
1 Chapter 7 Propositional and Predicate Logic. 2 Chapter 7 Contents (1) l What is Logic? l Logical Operators l Translating between English and Logic l.
1st-order Predicate Logic (FOL)
1 Knowledge Based Systems (CM0377) Lecture 4 (Last modified 5th February 2001)
Declarative vs Procedural Programming  Procedural programming requires that – the programmer tell the computer what to do. That is, how to get the output.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations.
Pattern-directed inference systems
1 Knowledge Representation. 2 Definitions Knowledge Base Knowledge Base A set of representations of facts about the world. A set of representations of.
1 CMSC 471 Fall 2002 Class #10/12–Wednesday, October 2 / Wednesday, October 9.
Chapter 1, Part II: Predicate Logic With Question/Answer Animations.
Key Concepts Representation Inference Semantics Discourse Pragmatics Computation.
For Wednesday Read chapter 9, sections 1-3 Homework: –Chapter 7, exercises 8 and 9.
Artificial Intelligence “Introduction to Formal Logic” Jennifer J. Burg Department of Mathematics and Computer Science.
Propositional Logic Predicate Logic
1 CSC384: Intro to Artificial Intelligence Lecture 5.  Knowledge Representation.
1 First order theories (Chapter 1, Sections 1.4 – 1.5) From the slides for the book “Decision procedures” by D.Kroening and O.Strichman.
LDK R Logics for Data and Knowledge Representation Propositional Logic Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia,
Albert Gatt LIN3021 Formal Semantics Lecture 3. Aims This lecture is divided into two parts: 1. We make our first attempts at formalising the notion of.
First-Order Logic Semantics Reading: Chapter 8, , FOL Syntax and Semantics read: FOL Knowledge Engineering read: FOL.
Metalogic Soundness and Completeness. Two Notions of Logical Consequence Validity: If the premises are true, then the conclusion must be true. Provability:
Artificial Intelligence Knowledge Representation.
March 3, 2016Introduction to Artificial Intelligence Lecture 12: Knowledge Representation & Reasoning I 1 Back to “Serious” Topics… Knowledge Representation.
Artificial Intelligence Logical Agents Chapter 7.
CS.462 Artificial Intelligence SOMCHAI THANGSATHITYANGKUL Lecture 04 : Logic.
Logical Agents. Outline Knowledge-based agents Logic in general - models and entailment Propositional (Boolean) logic Equivalence, validity, satisfiability.
CENG 424-Logic for CS Introduction Based on the Lecture Notes of Konstantin Korovin, Valentin Goranko, Russel and Norvig, and Michael Genesereth.
Chapter 7. Propositional and Predicate Logic
Lecture 1 – Formal Logic.
Knowledge Representation and Reasoning
Knowledge and reasoning – second part
The Propositional Calculus
ARTIFICIAL INTELLIGENCE
Knowledge Representation
Identifying Counterexamples
The Foundations: Logic and Proofs
CS201: Data Structures and Discrete Mathematics I
Logics for Data and Knowledge Representation
CS201: Data Structures and Discrete Mathematics I
1st-order Predicate Logic (FOL)
Knowledge and reasoning – second part
Back to “Serious” Topics…
Computer Security: Art and Science, 2nd Edition
Logics for Data and Knowledge Representation
Chapter 7. Propositional and Predicate Logic
Knowledge Representation I (Propositional Logic)
CSNB234 ARTIFICIAL INTELLIGENCE
Predicates and Quantifiers
Chapter 1: Propositional and First-Order Logic
Propositional Logic CMSC 471 Chapter , 7.7 and Chuck Dyer
CS201: Data Structures and Discrete Mathematics I
Predicates and Quantifiers
CS201: Data Structures and Discrete Mathematics I
Introduction to Computational Linguistics
Representations & Reasoning Systems (RRS) (2.2)
1st-order Predicate Logic (FOL)
Habib Ullah qamar Mscs(se)
Logical Agents Prof. Dr. Widodo Budiharto 2018
Presentation transcript:

Knowledge Representation Lecture 2 out of 5

Last Week Intelligence needs knowledge We need to represent this knowledge in a way a computer can process to do useful tasks We can do this in various ways Here we are looking at LOGIC based approaches … founded on mathematics and philosophy

Syntax and Semantics Syntax – what it looks like Semantics – what it means

Syntax eg rules of grammar for natural language – more formal (and restricted) for most logical notations eg the operator ^ takes 2 operands like so: – Valid: P ^ Q – Invalid: ^P Syntax specifies the allowed symbols and arrangements of those symbols

Semantics What does P^Q mean? – It means that P is true and Q is true. The same division between syntax and semantics can be seen in natural language – ‘They can fish’ has 2 meanings yet is syntactically identical.

Interpretation P ^ Q means that P is true AND Q is true But what do P and Q represent? This is interpretation – The symbol => (implies) takes 2 arguments (syntax) – A=>B means that either A is false, or B is true (semantics) – Let A represent ‘a score less than 40%’ and B be ‘fail’ (interpretation)

World Models “all models are wrong, but some are useful.” Box, George E. P.; Norman R. Draper (1987). Empirical Model-Building and Response Surfaces, p. 424, Wiley. ISBN A ‘world model’ is just that – usually a simplification of the real world Is the UK a country? Are cats carnivores? Is the world a sphere? we need the computer to 'know' just enough to do useful work. The model will never be accurate in every detail, nor do we need it to be.

What do we want a KRL to be? KRL = Knowledge Representation Language Expressive – can say what we want to say Effective – Can infer (see last week) new knowledge Efficient – doesn’t take too much processing power Explicit - Understandable These are criteria for a KR language – a way of writing down a model of the world.

Expressive In increasing level of complexity: – Bob is a student – students are types of people – all students have student IDs – by default birds can fly, – a child has exactly 2 parents, – Nothing is both animal AND plant – A bottle of wine has only one vintage year – Your national insurance number uniquely identifies you

Effective ‘new from old’: can infer things from what you have written down. Eg – Students are types of people, – SO if bob is a student – THEN bob is a person A more complex example – if ‘person A’ has the same National Insurance number as ‘person B’ then ‘A’ and ‘B’ identify the same person.

Efficient Efficient reasoning (inference) should be possible in reasonable time and computational power. There is a trade off between expressiveness and efficiency Some parts of logic are theoretically sound but in practice not even computable in infinite time!

Explicit An explicit KRL is one that explains its reasoning, and justifies its answer. The KRL should be natural and easy to understand. If you have just inferred something, you should be able to answer the question ‘why’

LOGIC Here we shift gear and start talking about the ‘nuts and bolts’ af KRLs: Objects – a symbol representing something in the real world – ‘alice’, ‘bob’ … Variables – represent object eg A, B etc where A could ‘stand for’ any object ‘alice’, ‘bob’ etc until it is BOUND. Terms – variables and objects

LOGIC (ctd) Predicates – properties. – Singled valued: is_student(bob) – Multiple valued: taller_than(bob, alice) atomic formula – terms and predicates negation NOT (¬) Literal – atomic formula and (optional) negation

LOGIC (ctd) Connectives – AND, OR, NOT, IMPLIES – (^ V ¬ => respectively) Quantifiers – Universal (for all)  ‘all carnivores eat meat’ (but could eat other things) – Existential (there exists)  ‘somebody knows the answer’. (but could be others too) Well formed formula (wff) – or expression. – A 'sentence' comprised of literals with (optional) connectives and (optional) quantifiers.

LOGIC (ctd) First order logic (FOL) contains all of this. – FOL and first order predicate logic (FOPL) are used more or less interchangeably Propositional logic contains all of this except quantifiers and (crucially) variables.

Reasoning (or Inference) Reminder: Inference is manipulation of symbols, using rules of language, to prove other sentences. – If A is true and A=>B then B is true – If B is false and A=>B then A cannot be true – If A is true and A=>B and B=> C then C is true

Sound reasoning SOUND – “If we infer it, is it true?” – given true premises, everything we infer is true – FOL and propositional logic are both sound.

Complete reasoning COMPLETE – “If it's true, can we infer it?” – a=>b necessarily means !a OR b – Can we formally prove this? – FOL and propositional logic are both complete.

The Godel Sentence “This sentence cannot be proved” If it is true, then the language is INCOMPLETE If it is false, then the language is UNSOUND So, sufficiently expressive languages cannot be both sound and complete First order logic is not that expressive, so it can be both sound and complete

Decidable reasoning DECIDEABLE – ”Is it true?” – Propositional logic is decideable. – FOL is actually semidecideable if it's necessarily true (or false), we will be able to tell, but it may take an awfully long time. If on the other hand we don't have enough evidence, it may take (literally) forever. The trouble is how to tell one from the other?

Coming up next week Real KR techniques – Semantic Nets – Frames