university politehnica of bucharest 2008-2009 adina magda florea artificial intelligence
of 45
/45
University Politehnica of Bucharest 2008-2009 Adina Magda Florea http://turing.cs.pub.ro/ aifils_08 Artificial Artificial Intelligence Intelligence
Post on 18-Dec-2015
216 views
Embed Size (px)
TRANSCRIPT
- Slide 1
- Slide 2
- University Politehnica of Bucharest 2008-2009 Adina Magda Florea http://turing.cs.pub.ro/aifils_08 Artificial Intelligence
- Slide 3
- 2 Structured knowledge representation n Semantic Networks n Units n Specific inferences n Problems with inheritance n Semantic Web Lecture No. 8
- Slide 4
- 3 Semantic networks n first model for structured knowledge representation n describe semantics of natural language n used extensively as a model for representing knowledge in KBS
- Slide 5
- Knowledge base n Radu sent a letter to Maria. n Radu is a student. n Ioana is a schoolgirl. n Radu's address is Luterana, 15. n occupation (radu, student) n occupation (ioana, schoolgirl) n send (radu, ioana, letter) n address (radu, luterana - 15)
- Slide 6
- Group knowledge into entities n Radu occupation (radu, student) send (radu, ioana, letter) address (radu, luterana - 15) n Ioana occupation (ioana, schoolgirl) send (radu, ioana, letter) Radu occupation:student address:luterana-15 Ioana occupation: schoolgirl Associate properties or attributes Model 2 args predicates What about 3 args predicates?
- Slide 7
- - use ISA predicate - use Skolemization to eliminate existential quantifier
- Slide 8
- 7 Radu ISA:Person Occupation:student Address:luterana-15 Ioana ISA:Person Occupation :schoolgirl T1 ISA:Sending-event Sender:Radu Receiver:Ioana Object:letter slots
- Slide 9
- 8 ISA introduces a class-instance relationship AKO predicate introduces a subclass-class relationship
- Slide 10
- 9 Sending-event AKO:Event Sender:Person Receiver:Person Object:ObjectClass Person AKO:living Thing Occupation:(student, engineer, ) Address:string
- Slide 11
- 10 Examples of SN
- Slide 12
- 11 n Units n MemberOf - ISA n SubClass, SuperClass - AKOUnits
- Slide 13
- 12 n Facets Features associated to slots Possible facets n Value facet n Value type facet n Default facet n If-needed procedure or function n Demon facet n Comment facetFacets
- Slide 14
- Specific inferences in semantic networks: properties/attributes inheritance 1) Inheritance of attributes along the ISA relation 2) Inheritance of attributes along the AKO relation Attribute's value inheritance
- Slide 15
- Attribute's value inheritance
- Slide 16
- Algorithm:Inheritance of attribute's value in a class hierarchy The algorithm gets the value V of an attribute A of the object O FindVal (O, A, V) 1.Create a list L with node O and all the nodes linked to O by an ISA relationship 2.while L != [ ] do 2.1.Remove first node N from L 2.2.if attribute A of node N has value, be it V then 2.2.1.Place V as the value of attribute A of object O 2.2.3.return SUCCESS 2.3.Add all nodes linked by AKO to N at the end of L 3.return FAIL end.
- Slide 17
- 16 Attribute's default value inheritance
- Slide 18
- Algorithm:Inheritance of attribute's default value in a class hierarchy The algorithm gets the default value V of an attribute A of the object O FindDefault (O, A, V) 1.Create a list L with node O and all the nodes linked to O by an ISA relationship 2.while L != [ ] do 2.1.Remove first node N from L 2.2.if attribute A of node N has a default value, be it V then 2.2.1.Place V as the value of attribute A of object O 2.2.3.return SUCCESS 2.3.Add all nodes linked by AKO to N at the end of L 3.return FAIL end. FindIfNeeded(O,A,V)
- Slide 19
- 18 Control strategy n the control strategy of inheritance indicates the order of considering the different facets n 2 basic strategies N strategy Z strategy
- Slide 20
- Algorithm: The algorithm gets the value V of an attribute A of the object O using the N strategy FindValN (O, A, V) 1.if FindVal (O,A,V) = SUCCESS then return SUCCESS 2. if FindDefault (O,A,V) = SUCCESS then return SUCCESS 3. if FindIfNeeded (O,A,V) = SUCCESS then return SUCCESS 4.return FAIL end Strategy N
- Slide 21
- Algoritm:Strategia Z de determinare a valorii unui atribut. Algoritmul determina valoarea unui atribut A al unei instante O utilizind strategia Z. DetValZ (O, A, V) 1.Formeaza o lista L cu nodul O si toate nodurile legate de O prin relatia ISA 2.cat timp L != [ ] executa 2.1.Elimina primul nod, N, din lista L 2.2.daca fateta valoare a atributului A a nodului N este V then 2.2.1.Depune V in nodul punctat de atributul A al obiectului O 2.2.2.intoarce SUCCES Strategy Z
- Slide 22
- 2.3.daca fateta valoare implicita a atributului A a nodului N este V atunci 2.3.1.Depune V in nodul punctat de atributul A al obiectului O 2.3.2.intoarce SUCCES 2.4.daca fateta procedura necesara a atributului A a nodului N este proc (A 1,..., A n,V) atunci 2.4.1.Determina valorile atributelor A 1,..., A n ale instantei O 2.4.2.daca s-au gasit valori pentru A 1,..., A n atunci i.executa proc (A 1,..., A n,V) ii.Depune V in nodul punctat de atributul A al obiectului O iii.intoarce SUCCES 3.intoarce INSUCCES sfarsit.
- Slide 23
- 22 Problems with inheritance n DAG networks n Multiple inheritance
- Slide 24
- Slide 25
- 24 Multiple inheritance Distance between units n If we look for the value of an attribute A of a unit U1 and find 2 paths : U1 U2 and U1 U3 to U2 and U3 containing values for A n then compute the length of the alternate paths from the instance/unit U1 to units U2 and U3 and choose the value from the closest unit (shortest path) n May cause semantic problems
- Slide 26
- 25 Distance and inferential distance Shortest distance Shortest inferential distance
- Slide 27
- 26 Multiple inheritance Inferential distance n Unit1 is closer to Unit2 than to Unit3 if and only if Unit1 has an inferential path to Unit3 which contains Unit2. Unit1 is closer to Unit2 than to Unit3 if and only if Unit2 is on an inferential path of ISA and AKO relationships between Unit1 and Unit3
- Slide 28
- Algorithm:Inheritance of attribute's value in a class hierarchy based on inferential distance Find the value V of slot S of unit U 1.Make a list L with unit U and all units to which unit U is linked by an ISA/MemberOf 2.Initialize a list CAND = [ ] 3.while L != [ ] do 3.1.remove first unit X from L 3.2.if slot S of X has value then CAND = CAND {X} 3.3.else add to L all units to which X is linked by a AKO/SuperClass 4.for each unit C CAND do 4.1.Verify if there is another C CAND having an inferential distance to U shorter than to C 4.2.if such a C' exists then remove C from CAND
- Slide 29
- 5. if card (CAND) = 0 then return FAIL /* no value for S */ 6.if card (CAND) = 1 then 6.1.Be C the one element of CAND 6.2.Make the value V of slot S of C the value of slot S of U 6.3.return SUCCESS 7.if card (CAND) > 1 then return CONTRADICTION end.
- Slide 30
- Combined representations Knowledge base contains: - declarative knowledge: units - procedural knowledge: rules daca Camion.Inaltime > 2 si Camion.Culoare = rosu atunci Camion.Pret = 1000 Inferences: both specific to units and specific to rules
- Slide 31
- 30 Semantic Web and Ontologies
- Slide 32
- Semantic Web n Web was invented by Tim Berners-Lee (amongst others), a physicist working at CERN n TBLs original vision of the Web was much more ambitious than the reality of the existing (syntactic) Web: n TBL (and others) have since been working towards realising this vision, which has become known as the Semantic Web E.g., article in May 2001 issue of Scientific American ... a goal of the Web was that, if the interaction between person and hypertext could be so intuitive that the machine-readable information space gave an accurate representation of the state of people's thoughts, interactions, and work patterns, then machine analysis could become a very powerful management tool, seeing patterns in our work and facilitating our working together through the typical problems which beset the management of large organizations.
- Slide 33
- Where we are Today: the Syntactic Web [Hendler & Miller 02]
- Slide 34
- The Syntactic Web is n A hypermedia, a digital library A library of documents called (web pages) interconnected by a hypermedia of links n A database, an application platform A common portal to applications accessible through web pages, and presenting their results as web pages n A platform for multimedia BBC Radio 4 anywhere in the world! Terminator 3 trailers! n A naming scheme Unique identity for those documents n A place where computers do the presentation (easy) and people do the linking and interpreting (hard). n Why not get computers to do more of the hard work? [Goble 03]
- Slide 35
- Impossible (?) using the Syntactic Web n Complex queries involving background knowledge Find information about animals that use sonar but are not either bats or dolphins n Locating information in data repositories Travel enquiries Prices of goods and services Results of human genome experiments n Delegating complex tasks to web agents Book me a holiday next weekend somewhere warm, not too far away, and where they speak French or English
- Slide 36
- What is the Problem? n Consider a typical web page: n Markup consists of: rendering information (e.g., font size and colour) Hyper-links to related content n Semantic content is accessible to humans but not (easily) to computers
- Slide 37
- What information can we see WWW2002 The eleventh international world wide web conference Sheraton waikiki hotel Honolulu, hawaii, USA 7-11 may 2002 1 location 5 days learn interact Registered participants coming from australia, canada, chile denmark, france, germany, ghana, hong kong, india, ireland, italy, japan, malta, new zealand, the netherlands, norway, singapore, switzerland, the united kingdom, the united states, vietnam, zaire Register now On the 7 th May Honolulu will provide the backdrop of the eleventh international world wide web conference. This prestigious event Speakers confirmed Tim berners-lee Tim is the well known inventor of the Web, Ian Foster Ian is the pioneer of the Grid, the next generation internet
- Slide 38
- What information can a machine see
- Slide 39
- Solution: XML markup with meaningful tags?
- Slide 40
- But What About
- Slide 41
- Must add semantics n External agreement on meaning of annotations E.g., Dublin Core Agree on the meaning of a set of annotation tags Problems with this approach Inflexible Limited number of things can be expressed n Use Ontologies to specify meaning of annotations Ontologies provide a vocabulary of terms New terms can be formed by combining existing ones Meaning (semantics) of such terms is formally specified Can also specify relationships between terms in multiple ontologies
- Slide 42
- Ontology in philosophy a philosophical disciplinea branch of philosophy that deals with the nature and the organisation of reality n Science of Being (Aristotle, Metaphysics, IV, 1) n Tries to answer the questions: What characterizes being? Eventually, what is being?
- Slide 43
- Ontology in Computer Science n An ontology is an engineering artifact: It is constituted by a specific vocabulary used to describe a certain reality, plus a set of explicit assumptions regarding the intended meaning of the vocabulary. n Thus, an ontology describes a formal specification of a certain domain: Shared understanding of a domain of interest Formal and machine manipulable model of a domain of interest An explicit specification of a conceptualisation [Gruber93]
- Slide 44
- Structure of an ontology Ontologies typically have two distinct components: n Names for important concepts in the domain Elephant is a concept whose members are a kind of animal Herbivore is a concept whose members are exactly those animals who eat only plants or parts of plants Adult_Elephant is a concept whose members are exactly those elephants whose age is greater than 20 years n Background knowledge/constraints on the domain Adult_Elephants weigh at least 2,000 kg All Elephants are either African_Elephants or Indian_Elephants No individual can be both a Herbivore and a Carnivore
- Slide 45
- Example of ontology
- Slide 46
- Tools n Description Logics n OWL = Web Ontological Language n Protg framework for building ontologies