Cover page images (keys)

Semantic Web

$Date: 2007/03/31 10:34:30 $

Ivan Herman, W3C

Overview of the Semantic Web

RDF Icon

Slides of the presentation …

This is an evolving slide set, updated regularly.

Towards a Semantic Web

Towards a Semantic Web

However…

Example: Searching

Example: Automatic Airline Reservation

Example: Data(base) Integration

Example: Digital Libraries

Example: Semantics of Web Services

What Is Needed?

What Is Needed (Technically)?

 

Basic Metadata Architecture: RDF

RDF Triples

RDF Triples (cont.)

(http://www.ivan-herman.net, http://…/myCalendar, http://…/calendar)

RDF Triples (cont.)

RDF is a Graph

A Simple RDF Example (in RDF/XML)

A Simple RDF Graph with full URI-s
<rdf:Description rdf:about="http://.../membership.svg#FullSlide">
    <axsvg:graphicsType>Chart</axsvg:graphicsType>
    <axsvg:labelledBy rdf:resource="http://...#BottomLegend"/>
    <axsvg:chartType>Line</axsvg:chartType>
</rdf:Description>

A Simple RDF Example (in Turtle)

A Simple RDF Graph with full URI-s
<http://.../membership.svg#FullSlide>
    axsvg:graphicsType "Chart";
    axsvg:labelledBy <http://...#BottomLegend>;
    axsvg:chartType "Line".

URI-s Play a Fundamental Role

URI-s: Merging

What Merge Can Do...

simple node with myself only
Scotts' environemnt added via a foaf statement starting from me
coauthors of IEEE TVCG paper added by Scott, with Scott, me, and Guy
coauthors of CGF paper added by Guy, with Maylis, me, and Guy
'know' links between me and Maylis and between me and Guy

What Merge Can Do…

See the “tabulator” example…

 

RDF Vocabulary Description Language (RDFS)
(a.k.a. RDFS)

Need for RDF Schemas

Classes, Resources, …

Classes, Resources, … (cont.)

Classes, Resources in RDF(S)

A slide showing the Flipper with its own Schema and the RDFS entitites, all merged

Schema Example in RDF/XML

<rdf:Description rdf:ID="Dolphin">
  <rdf:type rdf:resource=
    "http://www.w3.org/2000/01/rdf-schema#Class"/>
</rdf:Description>
<rdf:Description rdf:about="#Flipper">
   <rdf:type rdf:resource="animal-schema.rdf#Dolphin"/>
</rdf:Description>

Inferred Properties

A slide showing an inferred property

Inference: Let Us Be Formal…

If:
  uuu rdfs:subClassOf xxx .
  vvv rdf:type uuu .
Then add:
  vvv rdf:type xxx .

Properties

Property Specification Example

A slide showing the Fullslide (in appl. space) with its own Schema and the RDFS entitites, all merged

Literals

Literals Serialized

In RDF/XML

<rdf:Description rdf:about="#Flipper">
   <animal:is_TV_Star
      rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">
         True
   </animal:is_TV_Star>
</rdf:Description/>

In Turtle

:Flipper
   animal:is_TV_Star "True"^^<http://www.w3.org/2001/XMLSchema#boolean>.

 

Querying RDF Data: SPARQL

How to retrieve triples?

triples = graph.triples((Resource,Property,None))

Querying RDF Graphs

Simple SPARQL Example

SELECT ?cat ?val # note: not ?x!
WHERE { ?x rdf:value ?val. ?x category ?cat }
a simple graph with two tree like subgraphs
a simple graph with two tree like subgraphs left subgraph highlighted
a simple graph with two tree like subgraphs with selected nodes in the left subgraph highlighted
a simple graph with two tree like subgraphs with selected nodes in the right subgraph highlighted
a simple graph with two tree like subgraphs with selected nodes in the right subgraph highlighted

Other SPARQL Features

SPARQL Usage in Practice

 

Get to RDF(S) Data

Simplest: Write your own RDF Data…

<svg ...>
  ...
  <metadata>
    <rdf:RDF xmlns:rdf="http://../rdf-syntax-ns#">
      ...
    </rdf:RDF>
  </metadata>
    ...
</svg>

RDF Can Also Be Extracted/Generated

RDF Can Also Be Extracted/Generated (cont.)

Bridge to Relational Databases

SPARQL As a Unifying Force

diagram showing a sparql that can be connected to an rdf datafile, a document via grddl, and to a database via an sparql/sql bridge

 

Ontologies (OWL)

Ontologies

Classes in OWL

OWL Resource and Thing

Union of Classes

Showing unionOf with marine mammals

Same Serialized

<owl:Class rdf:ID="MarineMammal">
   <owl:unionOf rdf:parseType="Collection">
       <owl:Class rdf:about="#Dolphin"/>
       <owl:Class rdf:about="#Orca"/>
       <owl:Class rdf:about="#Whale"/>
   </owl:unionOf>
</owl:Class>
:Dolphin  rdf:type owl:Class.
:Orca     rdf:type owl:Class.
:Whale    rdf:type owl:Class.
:MarineMammal rdf:type owlClass;
   owl:unionOf (:Dolphin, :Orca, :Whale).

Property Restrictions

Property Restrictions in OWL

Property Restriction Example

Restriction example, using allValuesFrom

Property Characterization

The top level OWL property definitions

Characterization Example

Restriction example, using cardinality

OWL: Additional Features

Example: Connecting to Hungarian

Example of equivalence between English and Hungarian terms

However: Ontologies are Hard!

concentric arcs with RDF, RDFS, OWL Lite, DL, and Full

I am sorry, you need to have an SVG enabled browser to see this slide...

Ontologies are Hard! (cont)

concentric arcs with RDF, RDFS, OWL Lite, DL, and Full

 

RDF/OWL in Practice

RDF in Programming Practice

Example: Jena

  // create a model (a.k.a. Triple Store)
  Model model = new ModelMem();
  Resource subject = model.createResource("URI_of_Subject")
  // 'in' refers to the input file
  model.read(new InputStreamReader(in));
  StmtIterator iter = model.listStatements(subject,null,null);
  while(iter.hasNext()) { 
     st = iter.next();
     p = st.getProperty();
     o = st.getObject();
     do_something(p,o);
  }

Jena (cont)

Lots of Other tools

 

Current/future Developments

Simple Knowledge Organization System

Example: Entries in a Glossary (1)

“Assertion”
“(i) Any expression which is claimed to be true. (ii) The act of claiming something to be true.”
“Class”
“A general concept, category or classification. Something used primarily to classify or categorize other things.”
“Resource”
“(i) An entity; anything in the universe. (ii) As a class name: the class of everything; the most inclusive category possible.”

(from the RDF Semantics Glossary)

Example: Entries in a Glossary (2)

A slide for a simple SKOS glossary

Example: Entries in a Glossary (3)

A slide for a simple SKOS glossary

Example: Thesaurus (1)

Term
Economic cooperation
Used For
Economic co-operation
Broader terms
Economic policy
Narrower terms
Economic integration, European economic cooperation, …
Related terms
Interdependence
Scope Note
Includes cooperative measures in banking, trade, …

(from UK Archival Thesaurus)

Example: Thesaurus (2)

A slide for a simple SKOS thesaurus

Why Having SKOS OWL?

“Core” Vocabularies

Rules

Rules Interchange Format Working Group

RIF Phase 1 Goals

RIF Use Cases and Requirements

RIF Phase 2 Goals

Lots of Theoretical Questions to Solve

Beyond Rules: Trust

Other Issues…

 

Available Documents

Some Books

Further Information

SWBP Working Group Documents

Further Information (cont)

Public Fora at W3C

Semantic Web Interest Group
a forum for discussions on applications
RDF Logic
public (archived) mailing list for technical discussions

 

Some Application Examples

SW Applications

Applications are not always very complex…

The Active Semantic Doc picture: a doctor's file with annotations

Data integration

Life Sciences (cont.)

Left side: data silos, each its own representation on a screen, with scientist interpreting; right side: same silos, converted to rdf and co, scientist doing data right away.

General approach

  1. Map the various data onto RDF
    • “mapping” may mean on-the-fly SPARQL to SQL conversion, “scraping”, etc
  2. Merge the resulting RDF graphs (with a possible help of ontologies, rules, etc, to combine the terms)
  3. Start making queries on the whole!

Example: antibodies demo

Antibodies' demo screen dump

Portals

Vodafone screen dump

OKAR Fujitsu's and Ricoh's OKAR

Okar structural image

Adobe's XMP

XMP Application dump

Further Information

These slides are at:
http://www.w3.org/People/Ivan/CorePresentations/SW_Advanced/
Semantic Web homepage
http://www.w3.org//2001/sw/
More information about W3C:
http://www.w3.org/Consortium/
Contact information:
http://www.w3.org//Consortium/Contact
Mail me:
ivan@w3.org