http://springuniversity.bc3research.org/ | 1
Short introduction to ontology
Ioannis Athanasiadis
(using slides from Osnat Minz, Ian Horrocks presentations and material from Clay Shirky writings)
http://springuniversity.bc3research.org/ | 2
Summarizing the Problem:Computers don’t understand Meaning
“My mouse is broken. I need a new one…”
http://springuniversity.bc3research.org/ | 3
The Semantic Web Vision
“…having data on the Web defined and linked in a way that it can be used by machines not just for display purposes, but for automation, integration and reuse of data across various applications”
http://www.w3.org/sw/
http://springuniversity.bc3research.org/ | 4
What is the Problem?
• Consider a typical web page:
• Markup consists of: • rendering information (e.g., font
size and colour)
• Hyper-links to related content
• Semantic content is accessible to humans but not (easily) to computers…
http://springuniversity.bc3research.org/ | 5
What information can we see…WWW2002The eleventh international world wide web conferenceSheraton waikiki hotelHonolulu, hawaii, USA7-11 may 20021 location 5 days learn interactRegistered participants coming fromaustralia, 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 nowOn the 7th May Honolulu will provide the backdrop of the eleventh international world wide web conference.
This prestigious event …Speakers confirmedTim berners-leeTim is the well known inventor of the Web, …Ian FosterIan is the pioneer of the Grid, the next generation internet …
http://springuniversity.bc3research.org/ | 6
What information can a machine see…
WWW2002
&&
, , U
-11 2002
1 5
pp
, , &, , , , &,
, , , &p, , , ,
, p, , &, ,
,
p &p
. p
p&
-
& W,
p ,
http://springuniversity.bc3research.org/ | 7
But What About…
<conf>WWW2002 </conf><place> && , , U</place><date>-11 2002</date><slogan>1 5 </slogan><participants> pp
, , &, , , , &,
, , , &p, , , ,
, p, , &, ,
, </participants><introduction>
p &p
. p
p& </introduction><speaker> -</speaker><bio> & W,…
http://springuniversity.bc3research.org/ | 8
Machine sees…
< >WWW2002 </ >< > &&
, , U</ ><>-11 2002</>< >1 5 </ ><pp> pp
, , &, , , , &,
, , , &p, , , ,
, p, , &, ,
, </pp>< >
p &p
. p
p& </ ><p&> -</p&><> & W</>
http://springuniversity.bc3research.org/ | 9
Need to Add “Semantics”
•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
http://springuniversity.bc3research.org/ | 10
Ontology: Origins and HistoryOntology in Philosophy A philosophical discipline - a branch of philosophy
that deals with the nature and the organisation of reality
Science of Being (Aristotle, Metaphysics, IV, 1)
Tries to answer the questions:
What characterizes being? Eventually, what is being?
http://springuniversity.bc3research.org/ | 11
Ontology Οντολογία
• Οντολογία
• on -“to live”, to be, exist, God
• logos - language, word, reasoning
http://springuniversity.bc3research.org/ | 12
Plato’s cave
http://springuniversity.bc3research.org/ | 13
Ontology
•Ontology deals with questions concerning what entities exist or can be said to exist, and how such entities can be grouped, related within a hierarchy, and subdivided according to similarities and differences.
http://springuniversity.bc3research.org/ | 14
Ontology Definition
machine-readability with
computational
semantics
unambiguous terminology
definitions
commonly accepted
understanding
conceptual model of
a domain
(ontological theory)
[Gruber93]
http://springuniversity.bc3research.org/ | 15
http://springuniversity.bc3research.org/ | 16
Enough with definitionsLets see some examples!
http://springuniversity.bc3research.org/ | 17
Ontology in Linguistics
ReferentFormStands for
Relates toactivates
Concept
[Ogden, Richards, 1923]
Tank ?
http://springuniversity.bc3research.org/ | 18
Ontology in science
http://springuniversity.bc3research.org/ | 19
Ontology in library catalogs
•Dewey Decimal System's categorization for religions of the world:
Dewey, 200: Religion
210 Natural theology
220 Bible
230 Christian theology
240 Christian moral & devotional theology
250 Christian orders & local church
260 Christian social theology
270 Christian church history
280 Christian sects & denominations
290 Other religions
http://springuniversity.bc3research.org/ | 20
Ontology in library catalogs
• Library of Congress' categorization of history:
D: History (general)
DA: Great Britain
DB: Austria
DC: France
DD: Germany
DE: Mediterranean
DF: Greece
DG: Italy
DH: Low Countries
DJ: Netherlands
DK: Former Soviet Union
DL: Scandinavia
DP: Iberian Peninsula
DQ: Switzerland
DR: Balkan Peninsula
DS: Asia
DT: Africa
DU: Oceania
DX: Gypsies
http://springuniversity.bc3research.org/ | 21
Linnaean taxonomy
http://springuniversity.bc3research.org/ | 22
Agricultural thesaurus
http://springuniversity.bc3research.org/ | 23
What is an Ontology?
A model of (some aspect of) the world
• Introduces vocabulary relevant to domain• Often includes names for classes and relationships
• Specifies intended meaning of vocabulary• Typically formalised using a suitable logic• E.g., OWL formalised using SHOIQ description logic
• Consists of two parts• Set of axioms describing structure of the model• Set of facts describing some particular concrete situation
http://springuniversity.bc3research.org/ | 24
http://springuniversity.bc3research.org/ | 25
Axioms
Describe the structure of the model, e.g.:
Class: HogwartsStudentEquivalentTo: Student and
attendsSchool value Hogwarts
Class: HogwartsStudentSubClassOf: hasPet only (Owl or Cat or Toad)
ObjectProperty: hasPetInverses: isPetOf
Class: PhoenixSubClassOf: isPetOf only Wizard
http://springuniversity.bc3research.org/ | 26
Facts
Describe some particular concrete situation, e.g.:
Individual: HedwigTypes: Owl
Individual: HarryPotterTypes: HowgwartsStudentFacts: hasPet Hedwig
Individual: FawkesTypes: PhoenixFacts: isPetOf Dumbledore
http://springuniversity.bc3research.org/ | 27
Obvious Database Analogy
• Ontology axioms analogous to DB schema• Schema describes structure of and constraints on data
• Ontology facts analogous to DB data• Instantiates schema• Consistent with schema constraints
• But there are also important differences…
http://springuniversity.bc3research.org/ | 28
Database -v- Ontology
Ontology:
• Open world assumption (OWA)
– Missing information treated
as unknown
• No UNA
– Individuals may have more
than one name
• Ontology axioms behave like
implications (inference rules)
– Entail implicit information
Database:
• Closed world assumption (CWA)
– Missing information treated
as false
• Unique name assumption (UNA)
– Each individual has a single,
unique name
• Schema behaves as constraints
on structure of data
– Define legal database states
http://springuniversity.bc3research.org/ | 29
Let the games begin!
http://springuniversity.bc3research.org/ | 30
Database -v- Ontology: Q1
• E.g., given facts/data:Individual: HarryPotter
Facts: hasFriend RonWeasleyhasFriend HermioneGrangerhasPet Hedwig
Individual: Draco Malfoy
• Query: Is Draco Malfoy a friend of HarryPotter?
http://springuniversity.bc3research.org/ | 31
Database -v- Ontology: Q1
• E.g., given facts/data:Individual: HarryPotter
Facts: hasFriend RonWeasleyhasFriend HermioneGrangerhasPet Hedwig
Individual: Draco Malfoy
• Query: Is Draco Malfoy a friend of HarryPotter?• DB: No• Ontology: Don’t Know
• OWA (didn’t say Draco was not Harry’s friend)
http://springuniversity.bc3research.org/ | 32
Database -v- Ontology: Q2
• E.g., given facts/data:Individual: HarryPotter
Facts: hasFriend RonWeasleyhasFriend HermioneGrangerhasPet Hedwig
Individual: Draco Malfoy
• Query: How many friends does Harry Potter have?
http://springuniversity.bc3research.org/ | 33
Database -v- Ontology: Q2
• E.g., given facts/data:Individual: HarryPotter
Facts: hasFriend RonWeasleyhasFriend HermioneGrangerhasPet Hedwig
Individual: Draco Malfoy
• Query: How many friends does Harry Potter have?• DB: 2• Ontology: at least 1
• No UNA (Ron and Hermione may be 2 names for same person)
http://springuniversity.bc3research.org/ | 34
Database -v- Ontology: Q3
• E.g., given facts/data:Individual: HarryPotter
Facts: hasFriend RonWeasleyhasFriend HermioneGrangerhasPet Hedwig
Individual: Draco MalfoyDifferentIndividuals: RonWeasley HermioneGranger
• Query: How many friends does Harry Potter have?
http://springuniversity.bc3research.org/ | 35
Database -v- Ontology: Q3
• E.g., given facts/data:Individual: HarryPotter
Facts: hasFriend RonWeasleyhasFriend HermioneGrangerhasPet Hedwig
Individual: Draco MalfoyDifferentIndividuals: RonWeasley HermioneGranger
• Query: How many friends does Harry Potter have?• DB: 2• Ontology: at least 2
• OWA (Harry may have more friends we didn’t mention yet)
http://springuniversity.bc3research.org/ | 36
Database -v- Ontology: Q4
• E.g., given facts/data:Individual: HarryPotter
Facts: hasFriend RonWeasleyhasFriend HermioneGrangerhasPet Hedwig
Types: hasFriend only RonWeasley or HermioneGrangerIndividual: Draco MalfoyDifferentIndividuals: RonWeasley HermioneGranger
• Query: How many friends does Harry Potter have?
http://springuniversity.bc3research.org/ | 37
Database -v- Ontology: Q4
• E.g., given facts/data:Individual: HarryPotter
Facts: hasFriend RonWeasleyhasFriend HermioneGrangerhasPet Hedwig
Types: hasFriend only RonWeasley or HermioneGrangerIndividual: Draco MalfoyDifferentIndividuals: RonWeasley HermioneGranger
• Query: How many friends does Harry Potter have?• DB: 2• Ontology: 2!
http://springuniversity.bc3research.org/ | 38
Database -v- Ontology
• Insert new facts/data:Individual: DumbledoreIndividual: Fawkes
Types: PhoenixFacts: isPetOf Dumbledore
• Response from DBMS?• Update rejected: constraint violation
• Range of hasPet is Human; Dumbledore is not Human (CWA)
• Response from Ontology reasoner?• Infer that Dumbledore is Human (range restriction)• Also infer that Dumbledore is a Wizard
(only a Wizard can have a pheonix as a pet)
http://springuniversity.bc3research.org/ | 39
DB Query Answering
• Schema plays no role• Data must explicitly satisfy schema constraints
• Query answering amounts to model checking• I.e., a “look-up” against the data
• Can be very efficiently implemented• Worst case complexity is low (logspace) w.r.t. size of data
http://springuniversity.bc3research.org/ | 40
Ontology Query Answering
• Ontology axioms play a powerful and crucial role• Answer may include implicitly derived facts• Can answer conceptual as well as extensional queries
• E.g., Can a Muggle have a Phoenix for a pet?
• Query answering amounts to theorem proving• I.e., logical entailment
• May have very high worst case complexity• E.g., for OWL, NP-hard w.r.t. size of data
(upper bound is an open problem)• Implementations may still behave well in typical cases
http://springuniversity.bc3research.org/ | 41
Ontology Based Information Systems
• Analogous to relational database management systems• Ontology : schema; instances : data
• Some important (dis)advantages+ (Relatively) easy to maintain and update schema
• Schema plus data are integrated in a logical theory+ Query answers reflect both schema and data+ Can deal with incomplete information+ Able to answer both intensional and extensional queries• Semantics may be counter-intuitive or even inappropriate
• Open -v- closed world; axioms -v- constraints• Query answering (logical entailment) much more difficult
• Can lead to scalability problems
http://springuniversity.bc3research.org/ | 42
Semantic environmental modelling
utilize formal knowledge for representing the semantics of environmental data and models
• mediation approach: automatic integration of datasets, models and pipelines
• knowledge-driven approach: overcoming scale and paradigm differences, and automated knowledge discovery (experimental)
http://springuniversity.bc3research.org/ | 43
SEM - Mediation approach
http://springuniversity.bc3research.org/ | 44
SEM - Knowledge driven approach
http://springuniversity.bc3research.org/ | 45
Ontologies in kLAB
• Upper ontology (DOLCE)
• Domain ontologies (IM, ARIES, SWEET, …)plus “authorities” (GBIF, AGROVOC, …)
• User/App ontologies (Basque Country, your ontology)
http://springuniversity.bc3research.org/ | 46
The philosophers group
• Coming to town!
Editors: Ioannis N. Athanasiadis & Sander Janssen
Seamless Hall of Fame
Ioannis on explaining some of the uses of the ontology
Editors: Ioannis N. Athanasiadis & Sander Janssen
Seamless Hall of Fame
Sander talking about paradigm shifting and training.
Editors: Ioannis N. Athanasiadis & Sander Janssen
Seamless Hall of Fame
Kamel and Nina discussing during the FSSIM Framework Expert Week
Editors: Ioannis N. Athanasiadis & Sander Janssen
Seamless Hall of Fame
Kamel
http://springuniversity.bc3research.org/ | 51
Example 1: Annotate buffalo population dataset• An environmental scientist has put together a dataset on buffalo population. Assume that dataset has been
stored in WCS format.
model wcs(service = ”http://eco.logismi.co/wcs”, id = ”BF”)
named buffaloas count livestock:Buffalo per km^2 in 2011
with metadata {dc:description ”FAO␣Gridded␣Livestock␣Dataset” dc:rights ”cc-attr-nomod”dc:source ”http://www.fao.org/...” im:distribution ”public” };
(i) query part: specifies how to technically retrieve the data
(ii) observation semantics part: links to a concept of a livestock ontology, and declares units, and spatial and temporal reference,
(iii) annotation/metadata part: contains information on resource provenance, licensing and reuse.
http://springuniversity.bc3research.org/ | 52
Example 2: Create a Simple Flood Risk model
• Consider that the flood risk is classified by a simple rule depending on elevation
model SimpleFloodRiskModelas classification im.risk:FloodRiskobserving (im.geo:Elevation in m) named elevation
on definitionset to ’low’ if [elevation > 100]
’med’ if [elevation <= 100 and elevation > 20] ’high’ if [elevation<=20]
(i) model inputs and outputs are associated with concepts in an ontology (FloodRisk, Elevation)
(ii)enables the language system to subsequently compose and reuse the model with automated type checking, validate model chains and composition
(iii)a model can be transformed to a set of prerequisites to be satisfied
http://springuniversity.bc3research.org/ | 53
Example 3: Interpreting vegetation types from global sourcesclass NaturalVegetation is im.landcover:ForestSeminatural
has children
( Forest has children
( ConiferousForest with metadata
{ im:corine-encoding 312 im:nlcd-1992-encoding 42 im:nlcd-2001-
encoding 42 }
has children
(OpenConiferousForest with metadata
{ im:globcover-encoding 90 }),
(ClosedConiferousForest with metadata
{ im:globcover-encoding 70 })),
(MixedForest with metadata { im:globcover-encoding 100 im:nlcd-1992-encoding 43
im:nlcd-2001-encoding 43 im:corine-encoding 313})), ...