ontology modelling and the semantic web
DESCRIPTION
Presentation from Digital Documents lecture at HiOA 2012-10-23TRANSCRIPT
![Page 1: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/1.jpg)
Ontology modellingand the semantic web
Asgeir Rekkavik
Deichmanske bibliotek
![Page 2: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/2.jpg)
What does the wordsemantic mean?
• Semantics: The branch of linguistics concerned with meaning.(Shorter Oxford English dictionary)
• Semantics is the study of meaning.(Wikipedia 2013-10-16)
![Page 3: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/3.jpg)
I love youI ♥ U
Different syntax, same semantics
![Page 4: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/4.jpg)
![Page 5: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/5.jpg)
![Page 6: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/6.jpg)
![Page 7: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/7.jpg)
![Page 8: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/8.jpg)
![Page 9: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/9.jpg)
What does ontology mean?
• Ontology: The science or study of being.(Shorter Oxford English dictionary)
• In computer science and information science, an ontology formally represents knowledge as a set of concepts within a domain, and the relationships between those concepts.(Wikipedia 2013-10-16)
![Page 10: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/10.jpg)
What does ontology mean?
• The world can be described in many different ways: e.g. language, art etc.
• An ontology describes the world in a way that is formal, structured and unambiguous.
• Why? Because we want to describe it to computers.
![Page 11: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/11.jpg)
Ann and Becky are sisters
Ann and Becky are mothers
![Page 12: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/12.jpg)
Taxonomies
![Page 13: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/13.jpg)
Taxonomies
• Hierarchical classification• Characteristics
• Generic relations (’is-a’ relations)• Directed graph• Nodes represent categories• Arrows represent broader/narrower relations
• Especially known from biology. Developed by Carl von Linné.
![Page 14: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/14.jpg)
Taxonomies
![Page 15: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/15.jpg)
Transitive relations
• If A is related to B and B is related to C,then A is related to C
• Examples:• If Ann is younger than Bob and Bob is younger
than Carl, then Ann is younger than Carl• If a wolf is a mammal and a mammal is an
animal, then a wolf is an animal.
![Page 16: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/16.jpg)
Transitive relations
• Other transitive relations can exist between concepts, e.g. ’part-of’ relations
![Page 17: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/17.jpg)
Different types of relations
• Generic (’is-a’, e.g. Cat - Animal)
• Partitive (’part-of’, e.g. Oslo - Norway)
• Instance (e.g. Socrates - Philospher)
• Equivalence (e.g. Dove – Pigeon)
• Associative (’the rest’)
![Page 18: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/18.jpg)
Thesaurus
• Concepts are represented by terms
• Certain types of relations between concepts are formalized:• Generic, partitive and instance relations are all
formalized as ’broader / narrower’• Equivalence relations are formalized as ’use% / use
for ’• Some associative relations are formalized as ’see
also:’
![Page 19: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/19.jpg)
Thesaurus hierarchy
![Page 20: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/20.jpg)
Thesaurus
• Solar systemsNT: Planets
• PlanetsBT: Solar systemsNT: Gas giants
• Gas giantsBT: PlanetsNT: Jupiter
• JupiterBT: Gas giants
![Page 21: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/21.jpg)
Protégé
• Free, open source ontology editor
• Developed by Stanford University and the University of Manchester
• Available from:
http://protege.stanford.edu
![Page 22: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/22.jpg)
Ontology – key concepts
• Classes
• Instances (individuals)
• Properties
![Page 23: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/23.jpg)
Classes
• Represent categories, sets of individual instances
• Are related to eachother through parent-child relationships (superclass-subclass)
• Only generic ’is a’-relations are allowed• Unlike in a taxonomy, multiple inheritence
is allowed.
![Page 24: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/24.jpg)
Generic class hierarchy
![Page 25: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/25.jpg)
Generic class hierarchy
![Page 26: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/26.jpg)
Properties of classes
• Classes can be:
• Disjoint
(if n is a member of A, n is not a member of B)
(e.g. if Robin is a girl, then Robin is not a boy)
• Equivalent
(if n is a member of A, n is also a member of B and
if n is a member of B, n is also a member of A)
(e.g. Firstgraders Pupils born in 2007)
![Page 27: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/27.jpg)
ExerciseCreate a taxonomy with these classes:
• Bicycle• Boat• Bulldog• Car• Cat• Colour• Dog• Dolphin• Flower• Man
• Oak• Person• Pet• Pinetree• Plant• Puppy• Rose• Whale• Woman• Zebra
![Page 28: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/28.jpg)
Instances
• Individual entities that can populate any number of classes.
• An instance that is a member of a class, is necessarily also a member of all its superclasses.
![Page 29: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/29.jpg)
![Page 30: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/30.jpg)
ExerciseCreate these instances:
![Page 31: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/31.jpg)
The semantic triple
• A semantic triple is a statement consisting of three parts:• an instance (subject)• a property that refers to that instance (predicate)• a value for that property (object)
George likes chocolate
s p o
![Page 32: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/32.jpg)
![Page 33: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/33.jpg)
![Page 34: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/34.jpg)
![Page 35: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/35.jpg)
![Page 36: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/36.jpg)
Properties
• The instances are described through properties.
• There are two different types of properties:• Object property:
• Takes another instance as value• e.g. Alice knows Fred
• Datatype property• Takes a distinct datatype value, like a number, a string etc.• e.g. King Harald has year of birth 1937
• The property is the ”predicate” in the semantic triple.
![Page 37: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/37.jpg)
Domain and Range
• The domain and range of a property determine what kind of instances it can be used for and what kind of values it can have.
• Domain• The class, whose instances can have the property• If domain is not set, domain=Thing
• Range• The class, whose instances can be value for an object
property• The type of data that is allowed as value for a datatype
property
![Page 38: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/38.jpg)
Properties of properties
• Properties can be:• symmetric
(Martin has cousin Thomas) (Thomas has cousin Martin)
• asymmetric(Martin is father of Rosie) (Rosie can not be father of Martin)
• inverse(Martin is parent of Rosie) (Rosie is child of Martin)
• transitive(Rosie descends from Martin) and (Martin descends from Emma) (Rosie descends from Emma)
• functional (can have only one value)• inverse functional (value can be held by only one instance)• reflexive (instance takes itself as a value)
![Page 39: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/39.jpg)
ExerciseObject properties
• Create the following object properties• owns• ownedBy• hasNeighbour
• Set domain and range
• Connect instances, so that:• Mr. Taylor owns Duchess• Mrs. Robertson owns Lassie• Mr. Taylor and Mrs. Robertson are neighbours
![Page 40: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/40.jpg)
Restrictions
• Classes can be populated according to rules called restrictions.
• This is done by expressing that a class is equivalent to a certain set of instances.
• The set can be defined by• combining other classes with and/or/not
operators• using criteria based on desired properties for
the instances
![Page 41: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/41.jpg)
Restrictions
• Add new class LivingThing• Use class expression editor to express
equivalence relation:LivingThing Animal or Plant or Person
![Page 42: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/42.jpg)
• Add the class Gender• Add the individuals Male and Female• Add the property hasGender, domain: LivingThing• Express that:
• Lassie is female• Duchess is female• Moby Dick is male• Mr. Taylor is male• Mrs. Robertson is female• Thomas O’Malley is male
![Page 43: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/43.jpg)
• Add classes FemaleBeing and MaleBeing• Use class expression editor to express
equivalence relations:
FemaleBeing ≡ hasGender value Female
MaleBeing ≡ hasGender value Male
Pet ≡ Animal and ownedBy some Person
![Page 44: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/44.jpg)
What about this?
WildAnimal ≡ Animal and not (ownedBy some Person)
![Page 45: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/45.jpg)
Open world assumption
• The truth-value of an assumption does not depend on whether it is known or not
• The absence of a statement therefore does not count as a negation of that statement
![Page 46: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/46.jpg)
• Statements:• Mary is a woman• George is a man• Mary is an American citizen
• Question:• Is George an American citizen?
• Answers• Closed world assumption: "No"• Open world assumption: "Unknown"
![Page 47: Ontology modelling and the semantic web](https://reader033.vdocuments.site/reader033/viewer/2022061210/5490b0efb479594c388b45da/html5/thumbnails/47.jpg)
Example ontologies
• Dublin Core metadata termshttp://purl.org/dc/terms/
• Bibo (Bibliographic ontology)http://purl.org/ontology/bibo/
• Core FRBRhttp://purl.org/spar/frbr/
• FOAF (Friend of a friend)http://xmlns.com/foaf/spec/