© fraunhofer ipsi datamining versus semanticweb veljko milutinovic, [email protected]@etf.bg.ac.yu

73
Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, [email protected] http://galeb.etf.bg.ac.yu/vm

Upload: maude-fox

Post on 11-Jan-2016

221 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

© Fraunhofer IPSI

DataMining versus SemanticWeb

Veljko Milutinovic, [email protected]

http://galeb.etf.bg.ac.yu/vm

Page 2: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

2/73© Fraunhofer IPSI

DataMining versus SemanticWeb

Two different avenues leading to the same goal!

The goal: Efficient retrieval of knowledge,from large compact or distributed databases, or the Internet

What is the knowledge: Synergistic interaction of information (data)and their relationships (correlations).

The major difference: Placement of complexity

Page 3: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

3/73© Fraunhofer IPSI

Essence of DataMining

Data and knowledge representedwith simple mechanisms (typically, HTML)and without metadata (data about data).

Consequently, relatively complex algorithms have to be used (complexity migratedinto the retrieval request time).

In return,low complexity at system design time!

Page 4: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

4/73© Fraunhofer IPSI

Essence of SemanticWeb

Data and knowledge representedwith complex mechanisms (typically XML)and with plenty of metadata (a byte of data may be accompanied with a megabyte of metadata).

Consequently, relatively simple algorithms can be used (low complexity at the retrieval request time).

However, large metadata designand maintenance complexityat system design time.

Page 5: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

5/73© Fraunhofer IPSI

Major Knowledge Retrieval Algorithms (for DataMining)

Neural Networks Decision Trees Rule Induction Memory Based Reasoning, etc…

Consequently, the stress is on algorithms!

Page 6: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

6/73© Fraunhofer IPSI

Major Metadata Handling Tools (SemanticWeb)

XML RDF Ontology Languages Verification (Logic +Trust) Efforts in

Progress

Consequently, the stress is on tools!

Page 7: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

7/73© Fraunhofer IPSI

Semantic Web Tutorial Structure (Overview)

Introduction to the Semantic Web XML Technologies for the Semantic

Web Defining vocabularies with RDF Ontologies and ontology languages Challenges for the Semantic Web References

Page 8: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

8/73© Fraunhofer IPSI

World Wide Web - Today

preferences

preferences

Information consumer

Information and Service Providers

Search Engines (eg. Google), Information Portals

Information request

Indexing, refences,

collections

Page 9: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

9/73© Fraunhofer IPSI

Semantic Web - Vision

Calendar…

Preferences

User

Information and Service Provider

Ratings, Signatures, Certificates

„Trust“-Services

S+

Agents

Request/Task

Communication, Negotiation, Planning, Decisions, Proofs

Semanticly enriched information

Interpretation

Interpretation

Interpretation

S+

S+

S+S+

S+

Interpretation

S+

Calendar

Preferences

Page 10: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

10/73© Fraunhofer IPSI

A Definition of the Semantic Web

“Semantic Web is an extension of the current web in which information is given well-defined meaning, better enabling computers and people to work in cooperation”Tim Berners-Lee, James Hendler, Ora Lassila, The Semantic Web, Scientific American, May 2001

Page 11: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

11/73© Fraunhofer IPSI

Why?

To use the large amount of information on the Web more effectively

To enable more advanced automated processing on the Web - machines can “understand” the content

Intelligent browsers to help you find what you are looking for

To derive new information from existing information (reasoning) - Virtual global database

Advanced applications and services become possible, e.g. in

- e-business

- e-government

- e-learning

Page 12: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

12/73© Fraunhofer IPSI

Examples

Context-awareness -- linking based on the meaning of the information elements

Filtering -- you could rate the pages you visit, and this is later used for automatic general recommendations

Annotations -- you could add comments to the information on the Web, and these comments can be shown to other visitors

Privatization -- you can create your own database of information from the Web

Page 13: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

13/73© Fraunhofer IPSI

How? - Semantic Web layer model

Page 14: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

14/73© Fraunhofer IPSI

SGML Document Exchange Format 1985

Trusted Web Resources

HTTP Foundation of Web today 1990

XML Self Describing

Documents 2000

Human Machine

DAML+OIL Shared Terminology machine machine

2010

Hy Time

HTML

RDF

OWL

Page 15: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

15/73© Fraunhofer IPSI

Building Blocks

Metadata

URI

Semantic Web

Data about data – labeling and structuring information in a document

Universal Resource Identifier – an universal and unique name for any resource

http://www.something.com/one

Page 16: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

16/73© Fraunhofer IPSI

Minimalist Design

• Making it as simple as possible • Simplicity helps future evolution of Semantic

Web

Page 17: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

17/73© Fraunhofer IPSI

Inference

• Deriving new data from the existing ones• Merging data repositories gives new

information• Allows the creation of more powerful

applications (intelligent agents)

• Unfortunately, inference can be achieved completely only when the semantics is defined formally in a language(e.g. "First Order Predicate Logic“ languages)

Page 18: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

18/73© Fraunhofer IPSI

Tutorial Structure

Introduction to the Semantic Web XML Technologies for the Semantic

Web Defining vocabularies with RDF Ontologies and ontology languages Challenges for the Semantic Web References

Page 19: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

19/73© Fraunhofer IPSI

XML Technologies for the Semantic Web Overview XML Instances XML Document Type Definition XML Linking XML Schema XML Query Language

Page 20: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

20/73© Fraunhofer IPSI

What is an XML-Document ?

ccc

bd

a<?xml version="1.0"?><a> <b id="x1"> <c>David</c> <c>Marie</c> </b> <d/> <b id="x2"> <c>John</c> </b></a>

File Format(Instance)

Tree Structure Instance

David Marie John

id=x1 id=x2

b

Schema(Document TypeDefinition, DTD)

a

b d

*

c

id

*

Page 21: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

21/73© Fraunhofer IPSI

The XML Stack

XML 1.0

Metadata- RDF, RDFS

Unicode

Schemas- XSD- Namespaces

Standardized ApplicationsXHTML, SVG, SMIL, P3P, MathML

API- DOM- SAX

Hyperlinks- XLink- XPointer

Layout- XSL- CSS

Queries- XPath- XQuery

Locators (URI)

SpecificApplications

DTDs

Page 22: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

22/73© Fraunhofer IPSI

Example of songs.xml

• Example of describing a song in songs.xml using music.dtd

<song> <title>Gipsy song</title> <artist>Vlatko Stefanovski</artist> <type class=”ETHNO” /><download class=“YES”/><comments/></song>

parent element defined in music.dtd

child elements defined in music.dtd

Page 23: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

23/73© Fraunhofer IPSI

Music.dtd

<!ELEMENT song (title, artist, album?, type, format?, download, comments?)>

<!ELEMENT title (#PCDATA)> <!ELEMENT artist (#PCDATA)> <!ELEMENT type EMPTY> <!ATTLIST type class (CLASSICAL | ROCK | POP |

RAP | JAZZ | TECHNO | ETHNO) #REQUIRED> <!ELEMENT download EMPTY> <!ATTLIST download class (YES | NO) "YES" > <!ELEMENT comments (#PCDATA)>

Parent element

Child elements

Attributes describe content

List of values for download

Page 24: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

24/73© Fraunhofer IPSI

XML Linking

Simple Link Extended Link

XPointer Link Group

Page 25: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

25/73© Fraunhofer IPSI

XPath

• A language that enables us to address parts of an XML document (elements, attributes, …)

• Select the title elements of the song elements of the catalog element and all the artist elements in the document

/catalog/song/title | //artist

• Selects all the song elements of the catalog element that have a download element with a value of yes:

/catalog/song[download=yes]/title

selects the child elementselects several pathsselects any element in the

document

Page 26: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

26/73© Fraunhofer IPSI

Also…

• Use * to select unknown XML elements

/catalog/*/artist• Use @attribute_name to specify an attribute

//song[@type=‘classical']• XPath expressions – logical, arithmetical

/catalog/song[duration<5] • XPath functions - count(), id(), last(), name(),

concat(), string(), trenslate(), sum(), round(), false(), not(),…

/catalog/song[last()] • To select nodes from the XML document (IE)

xmlDoc.selectNodes("/catalog/song/title/text()")

the path

Page 27: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

27/73© Fraunhofer IPSI

XPointer

• Locates portions of other XML documents (elements, attributes…), without the need to place anchors inside those documents (as in HTML)

• More robust to the changes in the target document

• URL + XPath • http://www.music.org/first.xml/#xpointer(//

song/title[1]) XPointer expression

(XPath language)

URL of the document we point into

Page 28: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

28/73© Fraunhofer IPSI

XML Schema

• XML Schema defines a class of XML documents

• Defines (explains) the datatypes, elements, and attributes

• Defines and catalogues vocabularies for classes of XML documents

• The document described by an XML schema can be called an instance (parallel to OOP)

• The schema language, considerably extends the capabilities of XML 1.0 document type definitions (DTDs), most importantly with datatypes

Page 29: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

29/73© Fraunhofer IPSI

Limitations of DTDs

<!ELEMENT song (title, artist, album?, type, format?, download, comments?)>

<!ELEMENT title (#PCDATA)>

<!ELEMENT artist (#PCDATA)>

<!ELEMENT type EMPTY>

<!ATTLIST type

class (CLASSICAL | ROCK | POP | RAP | JAZZ | TECHNO | ETHNO) #REQUIRED>

<!ELEMENT download EMPTY>

<!ATTLIST download

class (YES | NO) "YES">

<!ELEMENT comments (#PCDATA)>

Datentypes:Essentially only "String"

Syntax:Not XML

Constructors:Elementset withContent Model

Practically no reuseof contentmodels

Page 30: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

30/73© Fraunhofer IPSI

XML Schema Components

• An XML Schema is comprised of a set of schema components

• There are three groups of components Primary components - Simple type definitions,

Complex type definitions, Attribute declarations, Element declarations

Secondary components - Attribute group definitions, Identity-constraint definitions, Model group definitions, Notation declarations

“Helper” components – Annotations, Model groups, Particles, Wildcards, Attribute Uses

Page 31: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

31/73© Fraunhofer IPSI

Example – song

<xsd:complexType name=“song" > <xsd:sequence> <xsd:element name=“title" type="xsd:string"/> <xsd:element name=“artist" type="xsd:string"/> </xsd:sequence>

<xsd:attribute name=“length" type="xsd:duration"/> </xsd:complexType>

xsd – used to denote XML Schema namespace

Complex type

Simple type

Type definition

Type declarations

<xsd:choice

></

xsd:choice>

Page 32: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

32/73© Fraunhofer IPSI

Reusability of schemas

• xs:include – to include a schema from another document (copy-paste)

<xs:include schemaLocation=“collection.xsd"/> • xs:redefine – same, plus it lets you redefine

schema• xs:import - reusing definitions from other

namespaces (a system of libraries)

<xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="myxml.xsd"/>

Now we can reference an external element from the imported namespace in our schema

Page 33: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

33/73© Fraunhofer IPSI

Tutorial Structure

Introduction to the Semantic Web XML Technologies for the Semantic

Web Defining vocabularies with RDF Ontologies and ontology languages Challenges for the Semantic Web References

Page 34: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

34/73© Fraunhofer IPSI

Defining vocabularies with RDF

Motivation for RDF RDF Instances

Basic concepts and building blocks Syntax options Reification Collections

RDF Schema: Defining your own Vocabularies Supporting Interoperability with RDF

Page 35: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

35/73© Fraunhofer IPSI

What do we NOT get from XML?

Superimposing (meta) information: XML combines metainformation and

content Datatypes that we can „reason“ about:

Example:CLASSICAL | ROCK | POP | RAP | JAZZ | TECHNO | ETHNOis just a choice of allowed strings. We cannot represent that DIXIE is a subclass of JAZZ, BLUES overlaps with ROCK, ETHNO

Bottom up reuse of vocabularies Independently evolved XML Schemas

for one and the same thing How do you model an „address“?

Page 36: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

36/73© Fraunhofer IPSI

RDF: Defining Semantics on the Web There is a need to describe resources on the Web

in a form that can be interpreted by machines across the Web

Interpretation depends on the context of a resource eg. Jaguar (car vs. beast)

Using their experience and cognitive abilities humans may infer the context of a resource in many ways, even if it is not made explicit

Software can interpret context only if it is described explicitly and formally

RDF and the ontology languages building upon RDF provide means to explicate (part of) this context

Page 37: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

37/73© Fraunhofer IPSI

RDF-Resource Description Framework Defines a framework for structuring and

describing resources like documents in the Semantic Web

Enables the definition of vocabularies for the description of resources in an application domain;

Goals: Extensibility, interoperability, and

reuse of vocabularies; Improved support for interpretation of data

by machines

Page 38: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

38/73© Fraunhofer IPSI

The RDF Data Model

Simple but powerful datamodel for the description of resources and the creation of metadata

Consists of three core concepts:ResourcePropertyStatement

+ Class (in RDF Schema) Similar to other modeling approaches

(e.g. object-oriented modeling), but property-centric, not class-centric

Page 39: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

39/73© Fraunhofer IPSI

RDF Statement and Graph

Each triple (S, P, O) node - arc - node represents an RDF statement

Gipsy song is performed by Vlatko Stefanovski. subject

(resource)

predicate

(property)

http://www.music.org/songs/g/gipsySong Performed by

http://www.artist.org/stefanovski

Artist represented by his homepage

object

(resource or literal)

Song represented by entry in a (fictive) song directory

Page 40: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

40/73© Fraunhofer IPSI

Arcs in the RDF Graph

An Arc represents the predicate of an RDF statement is labeled with a URI referring to an RDF

property is directed pointing from the subject of a

statement to the object of a statement

http://www.music.org/songs/g/gipsySong music:performed

by

http://www.artist.org/stefanovski

subjectpredicate

object

Page 41: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

41/73© Fraunhofer IPSI

RDF Resource

• The Resource forms the central concept in RDF

• Anything that can be described can act as a resource

Web page, part of web page, web site, book, photograph, persons, …

• Resources are identified by a resource identifier - URI (plus optional anchor IDs)

• Compare for an entity (in the Entity Relationship model) or an object (in an object-oriented model)

Page 42: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

42/73© Fraunhofer IPSI

RDF Property

An RDF Property is used to express• A characteristic of an resource or• A binary relation between resources • A predicate in a statement

• A property can be compared to a (binary) relationship among entities (in the Entity Relationship model)

Page 43: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

43/73© Fraunhofer IPSI

Example

The individual whose name is Vlatko Stefanovski and whose email is [email protected], is the artist of http://www.music.org/songs/g/gipsySongURI

reference

blank node

literal

music:artist

http://www.music.org/songs/g/gipsySong

Vlatko Stefanovski

person:name person:homepage

http://www.artists.org/stefano

vski

node

Page 44: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

44/73© Fraunhofer IPSI

XML Serialization

• How to translate the RDF graph structure into XML’s tree-oriented notation

<rdf:Description rdf:about = “http://www.music.org/songs/g/gipsySong”> <music:performedby>

<rdf:Description> <person:name> Vlatko Stefanovski</person:name>

<person:homepage><rdf:Description

about = “http://www.artists.org/stefanovski”> </rdf:Description>

</person:homepage> </rdf:Description> </music:performadby> </rdf:Description>

music:performedby

Vlatko Stefanovski

person:name person:homepage

http://www.artists.org/stefanovski

http://www.music.org/songs/g/gipsySong

Page 45: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

45/73© Fraunhofer IPSI

Reification

Latin: Res ... Thing -> Reification ... “Thing Making“ Statements themselves can be considered as

resources (things) in RDF. Thus, it is possible to make statements about statements (Reification).

Possible applications: Definition of a context for a statement

with respect to time, place, validity, …. Embed a statements into a discourse

(claims, doubts, proofs of statements) …

Example:Statement A: <sonata XY> <composer> <Mozart> Statement B: <music expert A> <claims> <statement

A><music expert C> <doubts> <statement A>

Page 46: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

46/73© Fraunhofer IPSI

Reification Syntax

The statement to be reified has to be modeled as an RDF resource;

The RDF vocabulary provides special constructs for this purpose:

• The class rdf:Statements which is the type of all RDF statements.

• The property rdf:type which is used to associate

an RDF resource with a class.• The property rdf:subject refers to the subject

of the modeled statement (i.e. to the described resource)

• The property rdf:predicate refers to the property used as a predicate in the modeled statement

• The property rdf:object refers to the object of the modeled statement (i.e. the property value)

Page 47: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

47/73© Fraunhofer IPSI

How to create a reified statement?

• Associate the subject, predicate and object of the statement with the resource rdf: Statement This is done by using the rdf:subject, rdf:predicate and rdf:object properties;

rdf:Statement

rdf:type

rdf:subjectrdf:objectrdf:predicate

www.operas.org/Zauberflöte www.artists.org/

Mozart

music:composerwww.operas.org/

Zauberflöte www.artists.org/Mozartmusic:composer

Page 48: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

48/73© Fraunhofer IPSI

How to create a reified statement?

• Now the created node which represents the statements can be used as an object or subject of another RDF statement

rdf:Statement

rdf:type

rdf:subjectrdf:object

rdf:predicate

music:composerwww.operas.org/SonataXY

www.artists.org/Mozart

www.musicExperts.org/ExpertA

music:claimedBy

Statement becomes a resource

Page 49: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

49/73© Fraunhofer IPSI

XML Syntax for Reification

<rdf:RDF xmlns:rdf = "http://w3.org/1999/02/22-rdf-syntax-ns#" xmlns:music="http://ipsi.fhg.de/music-schema#">

<rdf:Description>

<rdf:type resource=" http://w3.org/1999/02/22-rdf-syntax-ns#Statement” >

<rdf:subject resource="http://www.operas.org/SonataXY " />

<rdf:predicate resource="http://ipsi.fhg.de/music-schema#Composer" />

<rdf:object resource = “http://www.artists.org/Mozart” />

<music:claimedBy resource = “http://www.musicExperts.org/ExpertA” />

</rdf:Description>

</rdf:RDF>

Property of the statement

Page 50: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

50/73© Fraunhofer IPSI

RDF Collections

An RDF Container models a collection of resources. The RDF model supports three types of containers:

• Bag - an unordered list of resources or literals.

• Sequence - An ordered list of resources or literals.

• Alternative - A list of resources or literals that represent alternatives for the (single) value of a property.

Bag and Sequence can be used for multivalued properties

Page 51: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

51/73© Fraunhofer IPSI

Container - RDF Graph Syntax

rdf:Sequence

…/Aria1

…/Aria2

…/Aria3

…/Aria4

http://www.opera.org/Zauberflöte

music:arias

rdf:type

Example: Collection of Arias

rdf:_1

rdf:_2

rdf:_4

rdf:_3

Page 52: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

52/73© Fraunhofer IPSI

Container - XML Syntax

<rdf:RDF> <rdf:Description about="http://www.operas.org/Zauberflöte">

<music:arias><rdf:Sequence>

<rdf:li resource=“…/Aria1”>

<rdf:li resource=“…/Aria2"/>

<rdf:li resource=“…/Aria3"/>

<rdf:li resource=“…/Aria4"/>

</rdf:Sequence>

</music:arias>

</rdf:Description> </rdf:RDF>

Page 53: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

53/73© Fraunhofer IPSI

Statements about a Container and its members rdf:about is used to make a statement

on the comtainer as a whole rdf:aboutEach is used to make a statement

about each of the members of the container rdf:aboutEachPrefix makes a statement

about each member resource of a Bag that is only implicitly defined. This Bag contains all the resources whose fully resolved resource identifiers begin with the character string given as the value of the attribute

Page 54: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

54/73© Fraunhofer IPSI

RDF Schema

The RDF vocabulary description language - RDF Schema stresses

Reuse and extension of existing schemata Semantic enrichment by concept hierarchiesEnables statements on the schema level to: define classes of resources define relationships between these classes define the kinds of properties that instances of

that classes have define relationships between properties to restrict possible combinations of classes and

relationships/properties Allows mixing of schemata

Page 55: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

55/73© Fraunhofer IPSI

Defining an RDF Class (Example)

Class<rdfs:Class rdf:about = “http://www.ipsi.fhg.de/music-

schema#MusicComposition“><rdfs:subClassOf

rdf:resource =“http://www.w3.org/2000/rdf-schema#Resource”><rdfs:label>MusicComposition</rdfs:label></rdfs:Class>

Instance<rdf:Description about = “http://www.operas.org/Zauberflöte”> <rdf:type

rdf:resource = “http://www.ipsi.fhg.de/music-schema#MusicComposotion >

</rdf:type> … </rdf:Description>

music:MusicComposition

rdfs:subClassOf

rdfs:Resource

rdf:type

www.operas.org/Zauberflöte

Page 56: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

56/73© Fraunhofer IPSI

Class-centric vs. Property-centric

Class-centric Attributes as part of

the class definition Stresses common

structure

Property-centric Property as first-class

object Stresses extensibility

and flexibility with respect to properties

music:composer

rdfs:rangerdfs:domain

music:MusicTitle person:Person

MusicTitle

composer : Personlabel : String

rdf:label

rdfs:domain

rdfs:Literal

rdfs:range

Page 57: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

57/73© Fraunhofer IPSI

Defining Concept Hierarchies

rdfs:subClassOf represents a specialization relationship between RDF classes (transitive).

music:MusicTitle

music:Genre

music:Classic music:Modern

music:Operamusic:Sonata

music:RockOpera

music:Rock

http://www.operas.org/Zauberflöte

rdf:type

rdf:type

rdfs:subClassOf

rdfs:subClassOf

rdfs:subClassOf

rdfs:subClassOf

rdfs:subClassOfrdfs:subClassOf

rdfs:subClassOf

Page 58: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

58/73© Fraunhofer IPSI

RDF Property Hierarchies

rdfs:subPropertyOf

• Is used to specify that one property is a specialization of another property

• If a resource r has value v for property p1 and property p1 is subproperty of p2 than r also has value v for property p2.

performs

sings

Cher

rdfs:subPropertyOf

SomeSong is also a value of performs

“SomeSong“

singsperforms

SomeSong is a value for sings

Page 59: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

59/73© Fraunhofer IPSI

Tutorial Structure

Introduction to the Semantic Web XML Technologies for the Semantic

Web Defining vocabularies with RDF Ontologies and ontology languages Challenges for the Semantic Web References

Page 60: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

60/73© Fraunhofer IPSI

Ontologies and Ontology Languages What is an Ontology? The Ontology Language OWL

Taxonomies Property Restrictions

Page 61: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

61/73© Fraunhofer IPSI

Ontology

„An ontology is a specification of a conceptualization.” *

• A conceptualization is an abstract, simplified view of the world that we wish to represent for some purpose.

*T. R. Gruber. A translation approach to portable ontologies. Knowledge

Acquisition, 5(2):199-220, 1993

claudia niederée
revise
Page 62: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

62/73© Fraunhofer IPSI

Ontology Languages

• Ontology languages are semantic markup languages for defining ontologies

• DAML+OIL is a combination of the two predecessor ontology languages

• DAML – DARPA Agent Markup Language• OIL - Ontology Inference Layer

• OWL (Web Ontology Language) is the successor DAML + OIL currently developed by the W3C Web Ontology Group (Status: Working Draft)

• Building on RDF ideas• OWL Lite is a subset of OWL

Page 63: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

63/73© Fraunhofer IPSI

OWL Characteristics

OWL enables the definition of various types of relationships between

classes (in addition to subclass hierarchies)

additional restrictions for property valuesadditional types of relationships between

propertiesdifferent kinds of properties

OWL distinguishes between classes and instances (objects) on the one side, and data types and value on the other side (XML Schema datatypes)

Page 64: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

64/73© Fraunhofer IPSI

Ontology Definition

The body of the ontology consists of: classes properties instances (for use in class definitions)

The main component of an ontology is a taxonomy i.e. a class hierarchy

Page 65: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

65/73© Fraunhofer IPSI

Further Class Relationships

A class definition may also contain other class relationships owl:disjointWith – this property is used to

express that a class is disjoint with another class (no instances in common);

owl:sameClassAs - this property is used to express that a class is equivalent to another class (same instances);

The values of these properties are defined by a class expressions, which in the simplest case is the name (URI) of a class;

Page 66: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

66/73© Fraunhofer IPSI

Properties in OWL

OWL properties are deferred from RDF properties

It is possible to define different types of properties,

where several property types can be combined with each other

relationships between properties

Page 67: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

67/73© Fraunhofer IPSI

Tutorial Structure

Introduction to the Semantic Web XML Technologies for the Semantic

Web Defining vocabularies with RDF Ontologies and ontology languages Challenges for the Semantic Web References

Page 68: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

68/73© Fraunhofer IPSI

Logic and Proof

• Deduction; checking a document against a set of rules

• Add predicate logic and quantifiers• Logic + Digital Signature Proof

You owe me

$30.

Oh yeah!

Prove it.

The check is in the email!

{Purchased(user1.book1.AOL);www.confirm.com#t1221122}

{Priceof(book1, $30);AOL-historyDB#t29293910}

{Purchase(a,b,c) & Priceof(b,d)Owes(a,c,d);www.ont.com/prodont}

Page 69: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

69/73© Fraunhofer IPSI

Instead of a Conclusion: IPSI Projects

Scalable Technology and Applicationsfor the

Semantic Web

Page 70: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

70/73© Fraunhofer IPSI

Individualized Electronic Newspaper

Page 71: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

71/73© Fraunhofer IPSI

Dictionary of Art

Page 72: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

72/73© Fraunhofer IPSI

XML Broker: Integrating Web Resources via XML

<www.reiseplanung.de> <route> <von>53757</von> <nach>93333</nach> <entfernung>481.9</entfernung> <fahrzeit>274</fahrzeit> <karte>5375793333.gif</karte> </route> <!-- ... --></www.reiseplanung.de>

<www.wetter.de> <wetter> <plz>87724</plz> <datum>981001</datum> <temperatur>16</temperatur> <regen>90</regen> <wind>9</wind> <prognose>13</prognose> </wetter> <!-- ... --><www.wetter.de>

<golfplatz id="platz0001"> <adresse> [...] </adresse> <policy> ... </policy> <handicap> <wochentag>34</wochentag> <wochenende>34</wochenende> </handicap></golfplatz>

XML Broker

<golfdemo <golfplatz> <adresse> ... </adresse> <greenfee> ... </greenfee> ... </golfplatz> <wetter> ... </wetter> <route> ... </route></golfdemo>

XSL

Query

Page 73: © Fraunhofer IPSI DataMining versus SemanticWeb Veljko Milutinovic, vm@etf.bg.ac.yuvm@etf.bg.ac.yu

73/73© Fraunhofer IPSI

Virtual Gallery