l 3

Information about l 3

Published on November 26, 2007

Author: Talya

Source: authorstream.com

Content

Knowledge Representation:  Knowledge Representation Lecture 3 More Logic Semantic Networks and Frames From lecture 2..:  From lecture 2.. Need formal notation to represent knowledge, allowing automated inference and problem solving. One popular choice is use of logic. Propositional logic is the simplest. Symbols represent facts: P, Q, etc.. These are joined by logical connectives (and, or, implication) e.g., P  Q; Q  R Given some statements in the logic we can deduce new facts (e.g., from above deduce R) Predicate Logic:  Predicate Logic Propositional logic isn’t powerful enough as a general knowledge representation language. Impossible to make general statements. E.g., “all students sit exams” or “if any student sits an exam they either pass or fail”. So we need predicate logic.. Predicate Logic:  Predicate Logic In predicate logic the basic unit is a predicate/ argument structure called an atomic sentence: likes(alison, chocolate) tall(fred) Arguments can be any of: constant symbol, such as ‘alison’ variable symbol, such as X function expression, e.g., motherof(fred) So we can have: likes(X, richard) friends(motherof(joe), motherof(jim)) Predicate logic: Syntax:  Predicate logic: Syntax These atomic sentences can be combined using logic connectives likes(john, mary)  tall(mary) tall(john)  nice(john) Sentences can also be formed using quantifiers  (forall) and  (there exists) to indicate how to treat variables:  X lovely(X) Everything is lovely.  X lovely(X) Something is lovely.  X in(X, garden) lovely(X) Everything in the garden is lovely. Predicate Logic:  Predicate Logic Can have several quantifiers, e.g.,  X  Y loves(X, Y)  X handsome(X)   Y loves(Y, X) So we can represent things like: All men are mortal. No one likes brussel sprouts. Everyone taking AI3 will pass their exams. Every race has a winner. John likes everyone who is tall. John doesn’t like anyone who likes brussel sprouts. There is something small and slimy on the table. Semantics:  Semantics There is a precise meaning to expressions in predicate logic. Like in propositional logic, it is all about determining whether something is true or false.  X P(X) means that P(X) must be true for every object X in the domain of interest.  X P(X) means that P(X) must be true for at least one object X in the domain of interest. So if we have a domain of interest consisting of just two people, john and mary, and we know that tall(mary) and tall(john) are true, we can say that  X tall(X) is true. Proof and inference:  Proof and inference Again we can define inference rules allowing us to say that if certain things are true, certain other things are sure to be true, e.g.  X P(X) Q(X) P(something) ----------------- (so we can conclude) Q(something) This involves matching P(X) against P(something) and binding the variable X to the symbol something. Proof and Inference:  Proof and Inference What can we conclude from the following?  X tall(X)  strong(X) tall(john)  X strong(X)  loves(mary, X) Prolog and Logic:  Prolog and Logic All this should remind you of Prolog.. Prolog is based on predicate logic, but with slightly different syntax. a(X) :- b(X), c(X). Equivalent to  X a(X)  b(X)  c(X) Or equivalently  X b(X)  c(X) a(X) Prolog has a built in proof/inference procedure, that lets you determine what is true given some initial set of facts. Proof method called “resolution”. Other Logics:  Other Logics Predicate logic not powerful enough to represent and reason on things like time, beliefs, possibility. “He may do X” He will do X. I believe he should do X. Specialised logics exist to support reasoning on this kind of knowledge. Other Knowledge Representation Methods:  Other Knowledge Representation Methods Logic isn’t the only method of representing knowledge. There are other methods which are less general, but more natural, and arguably easier to work with: Semantic Nets Frames Objects To some extent modern OOP has superceded the first two, with the ability to represent knowledge in the object structures of your programming language. Semantic Nets etc..:  Semantic Nets etc.. Semantic nets, frames and objects all allow you to define relations between objects, including class relations (X isa Y). Only restricted inference supported by the methods - that based on inheritance. So.. Fido is a dog, dogs have 4 legs, so Fido has 4 legs. Semantic Networks:  Semantic Networks Knowledge represented as a network or graph Animal Reptile Elephant Nellie Mammal apples large head subclass subclass haspart subclass instance likes size Africa livesin Semantic Networks:  Semantic Networks By traversing network we can find: That Nellie has a head (by inheritance) That certain concepts related in certain ways (e.g., apples and elephants). BUT: Meaning of semantic networks was not always well defined. Are all Elephants big, or just typical elephants? Do all Elephants live in the “same” Africa? Do all animals have the same head? For machine processing these things must be defined. Frames:  Frames Frames were the next development, allowing more convenient “packaging” of facts about an object. Frames look much like modern classes, without the methods: We use the terms “slots” and “slot values” mammal: subclass: animal elephant: subclass: mammal size: large haspart: trunk Nellie: instance: elephant likes: apples Frames:  Frames Frames often allowed you to say which things were just typical of a class, and which were definitional, so couldn’t be overridden. Using an asterix to denote typical values: Frames also allowed multiple inheritance (Nellie is an Elephant and is a circus animal). Introduces problems in inheritance. Elephant: subclass: mammal haspart: trunk * colour: grey * size: large Frames and procedures:  Frames and procedures Frames often allowed slots to contain procedures. So.. Size slot could contain code to run to calculate the size of an animal from other data. Sometimes divided into “if-needed” procedures, run when value needed, and “if-added” procedures, run when a value is added (to update rest of data, or inform user). So.. Similar, but not quite like modern object-oriented languages. Semantic Networks (etc) and Logic:  Semantic Networks (etc) and Logic How do we precisely define the semantics of a frame system or semantic network? Modern trend is to have special knowledge representation languages which look a bit like frames to users, but which: use logic to define what relations mean don’t provide the full power of predicate logic, but a subset that allows efficient inference. (May not want more than inheritance). Implementing simple Frame systems:  Implementing simple Frame systems Sometimes, even when using a logic-based language, it is useful to be able to define inheritance rules, and group object attributes together in a frame-like structure. So we could have..: slot-value(elephant, size, large) instance(nellie, elephant) value(Obj, Slot, V) :- instance(Obj, Class), slot-value(Class, Slot, V). Summary:  Summary Predicate logic provides well defined language for knowledge rep supporting inference. Frames/Networks/Objects more natural, but only explicitly support inheritance, and may not have well defined semantics. Current trend is either to just use OO, or to use logic, but specialises non-logic-based languages still exist.

Related presentations


Other presentations created by Talya

Chapter 19
06. 11. 2007
0 views

Chapter 19

MDR TB Aaron
07. 01. 2008
0 views

MDR TB Aaron

Ourplanetearth
03. 10. 2007
0 views

Ourplanetearth

Serway CP poll ch05
09. 10. 2007
0 views

Serway CP poll ch05

ELISA powerpoint Agrow knowledge
24. 10. 2007
0 views

ELISA powerpoint Agrow knowledge

Presentation Jean Pierre Allain
24. 10. 2007
0 views

Presentation Jean Pierre Allain

H114m
26. 11. 2007
0 views

H114m

svd
03. 12. 2007
0 views

svd

Invasive Species ID Powerpoint
11. 12. 2007
0 views

Invasive Species ID Powerpoint

Fallacies vs Facts
12. 12. 2007
0 views

Fallacies vs Facts

upload c beatles64 4n27
29. 10. 2007
0 views

upload c beatles64 4n27

2 relational model
30. 10. 2007
0 views

2 relational model

POSTMODERN MANAGEMENT
30. 10. 2007
0 views

POSTMODERN MANAGEMENT

Introduction Overview
02. 11. 2007
0 views

Introduction Overview

Ocean platforms prince
05. 11. 2007
0 views

Ocean platforms prince

AST PRESENTATION TO PCA
06. 11. 2007
0 views

AST PRESENTATION TO PCA

ANI
06. 11. 2007
0 views

ANI

rebecca 3rd
06. 11. 2007
0 views

rebecca 3rd

The Slave Diary Assessment
07. 11. 2007
0 views

The Slave Diary Assessment

Sugarcane presentation
23. 11. 2007
0 views

Sugarcane presentation

Perth
04. 01. 2008
0 views

Perth

birds total
22. 11. 2007
0 views

birds total

TECNICASDE ESTUDIOA DISTANCIA
05. 01. 2008
0 views

TECNICASDE ESTUDIOA DISTANCIA

Sue Gries LC
07. 01. 2008
0 views

Sue Gries LC

morrill
03. 10. 2007
0 views

morrill

Naveen Kumar October 24 2006
12. 11. 2007
0 views

Naveen Kumar October 24 2006

nhs fellowship
25. 10. 2007
0 views

nhs fellowship

icml kdd2003
27. 09. 2007
0 views

icml kdd2003

FOSOntoWeb
30. 10. 2007
0 views

FOSOntoWeb

f ad 06112006
26. 10. 2007
0 views

f ad 06112006

20040112 SPACE04
03. 01. 2008
0 views

20040112 SPACE04

bobkov
03. 01. 2008
0 views

bobkov

AGM 2005
20. 02. 2008
0 views

AGM 2005

FL Unit 1 pgs 16 18
24. 02. 2008
0 views

FL Unit 1 pgs 16 18

Lecture15 2003 10 14 FINAL
27. 02. 2008
0 views

Lecture15 2003 10 14 FINAL

art1945 60
19. 12. 2007
0 views

art1945 60

lail
05. 03. 2008
0 views

lail

ISAE 7giu05def
31. 10. 2007
0 views

ISAE 7giu05def

acg
14. 03. 2008
0 views

acg

CentralDogma
27. 03. 2008
0 views

CentralDogma

Gorini Sidlaw Mon
30. 10. 2007
0 views

Gorini Sidlaw Mon

X Internet Q2 2002
13. 04. 2008
0 views

X Internet Q2 2002

AGM Mar 06 Final frm Kim e
07. 12. 2007
0 views

AGM Mar 06 Final frm Kim e

Ballroom Dance Lessons
23. 11. 2007
0 views

Ballroom Dance Lessons

Hosea HHFW 6 28 07
21. 11. 2007
0 views

Hosea HHFW 6 28 07

radiacevesmir
15. 11. 2007
0 views

radiacevesmir

Iyer
16. 11. 2007
0 views

Iyer

proebsting
05. 11. 2007
0 views

proebsting

200753051013737
28. 12. 2007
0 views

200753051013737

Schatzmann Nett
25. 10. 2007
0 views

Schatzmann Nett

ukio bankas
14. 11. 2007
0 views

ukio bankas

E145 WorkshopB Mktg
16. 11. 2007
0 views

E145 WorkshopB Mktg

StarMotion
13. 11. 2007
0 views

StarMotion

BEL Valves
20. 11. 2007
0 views

BEL Valves

herrera Parallel 4 1
28. 11. 2007
0 views

herrera Parallel 4 1

job search bootcamp
17. 12. 2007
0 views

job search bootcamp