Your SlideShare is downloading. ×
Linked Data Tutorial (Florianópolis)
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Linked Data Tutorial (Florianópolis)

6,648
views

Published on

Slides from the tutorial given by Asunción Gómez-Pérez and Oscar Corcho at 3º OntoBras in Florianópolis (September 2010)

Slides from the tutorial given by Asunción Gómez-Pérez and Oscar Corcho at 3º OntoBras in Florianópolis (September 2010)

Published in: Technology

0 Comments
10 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
6,648
On Slideshare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
269
Comments
0
Likes
10
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • 727 veces el term-based record-basedthesaurus
  • Transcript

    • 1. Mini-curso sobre LinkedData
      Oscar Corcho, Asunción Gómez Pérez ({ocorcho, asun}@fi.upm.es)
      Universidad Politécnica de Madrid
      Florianópolis, September 1st 2010(3º OntoBras 2010)
      Credits: Raúl García Castro, Oscar Muñoz, Jose Angel Ramos Gargantilla, María del Carmen Suárez de Figueroa, Boris Villazón, Alex de León, Víctor Saquicela, Luis Vilches, Miguel Angel García, Manuel Salvadores, Juan Sequeda, Carlos Ruiz Moreno and manyothers
      WorkdistributedunderthelicenseCreativeCommonsAttribution-Noncommercial-Share Alike 3.0
    • 2. Contents
      IntroductiontoLinked Data
      Linked Data Foundations: RDF, RDF Schema, SPARQL and OWL
      Coffee break
      Linked Data publication
      MethodologicalguidelinesforLinked Data publication
      RDB2RDF tools
      Technicalaspects of Linked Data publication
      Linked Data consumption
      2
    • 3. Whatisthe Web of Linked Data?
      An extension of the current Web…
      … where information and services are given well-defined and explicitly represented meaning, …
      … so that it can be shared and used by humans and machines, ...
      ... better enabling them to work in cooperation
      How?
      Promoting information exchange by tagging web content with machineprocessable descriptions of its meaning.
      And technologies and infrastructure to do this
      And clear principles on how to publish data
      data
    • 4. What is Linked Data?
      Linked Data is a term used to describe a recommended best practice for exposing, sharing, and connecting pieces of data, information, and knowledge on the Semantic Web using URIs and RDF.
      Part of the Semantic Web
      Exposing, sharing and connecting data
      Technologies: URIs and RDF (although others are also important)
    • 5. The fourprinciples (Tim Berners Lee, 2006)
      Use URIs as names for things
      Use HTTP URIs so that people can look up those names.
      When someone looks up a URI, provide useful information, using the standards (RDF*, SPARQL)
      Include links to other URIs, so that they can discover more things.
      http://www.w3.org/DesignIssues/LinkedData.html
      5
      http://www.ted.com/talks/tim_berners_lee_on_the_next_web.html
    • 6. Linked Open Data evolution
    • 7
      LOD Cloud May 2007
      Facts:
      • Focal points:
      • 9. DBPedia: RDFizedvesion of Wikipiedia; many ingoing and outgoing links
      • 10. Music-related datasets
      • 11. Big datasets include FOAF, US Census data
      • 12. Size approx. 1 billion triples, 250k links
      Figure from [4]
    • 13. 8
      LOD Cloud September 2008
      Facts:
      • More than 35 datasets interlinked
      • 14. Commercial players joined the cloud, e.g., BBC
      • 15. Companies began to publish and host dataset, e.g. OpenLink, Talis, or Garlik.
      • 16. Size approx. 2 billion triples, 3 million links
      Figure from [4]
    • 17. 9
      LOD Cloud March 2009
      Facts:
      • Big part from Linking Open Drug cloud and the BIO2RDF project (bottom)
      • 18. Notable new datasets: Freebase, OpenCalais, ACM/IEEE
      • 19. Size > 10 billion triples
      Figure from [4]
    • 20. LOD clouds
    • 21. WhyLinked Data?
      Basically, tomovefrom a Web of documentsto a Web of Data
      Let’s try anexample:
      • Tell me whichfootballplayers, born in theprovince of Albacete, in Spain, havescored a goal in theWorld Cup final
      Disclaimer:
      Sorryto use anexampleaboutfootball, butyouhavetounderstandthatforseveralyearsSpaniardswillbetalkingaboutfootball a lot ;-)
    • 22. Informationsearch in the Web of documents
      • ¿?
    • What we were actually looking for
    • 23. Itwouldbebettertomake a data query…
      (footballplayersfrom Albacete whoplayedEurocup 2008)
    • 24. Howshouldwepublish data?
      Formats in which data ispublishednowadays…
      XML
      HTML
      DBs
      APIs
      CSV
      XLS

      However, mainlimitationsfrom a Web of Data point of view
      Difficulttointegrate
      Data isnotlinkedtoeachother, as ithappenswith Web documents.
    • 25. Which format do we use then?
      RDF (ResourceDescription Framework)
      Data model
      Basedon triples: subject, predicate, object
      <Oscar> <vive en> <Madrid>
      <Madrid> <es la capital de> <España>
      <España> <es campeona de> <Mundial de Fútbol>

      Serialised in differentformats
      RDF/XML, RDFa, N3, Turtle, JSON…
    • 26. URIs (Universal-UniformResourceIdentifer)
      Two types of identifiers can be used to identify Linked Data resources
      URIRefs(Unique Resource IdentifiersReferences)
      A URI and an optional FragmentIdentifier separated from the URI by the hash symbol ‘#’
      http://www.ontology.org/people#Person
      people:Person
      Plain URIs can also be used, as in FOAF:
      http://xmlns.com/foaf/0.1/Person
      17
    • 27. How do wepublishLinked Data?
      ExposingRelationalDatabasesorother similar formatsintoLinked Data
      D2R
      Triplify
      R2O
      NOR2O
      Virtuoso
      Ultrawrap

      Usingnative RDF triplestores
      Sesame
      Jena
      Owlim
      Talisplatform

      Incorporatingit in theform of RDFa in CMSslikeDrupal
      18
    • 28. How do we consume Linked Data?
      Linked Data browsers
      To explore things and datasets and to navigate between them.
      Tabulator Browser (MIT, USA), Marbles (FU Berlin, DE), OpenLink RDF Browser (OpenLink, UK), Zitgist RDF Browser (Zitgist, USA), Disco Hyperdata Browser (FU Berlin, DE), Fenfire (DERI, Ireland)
      Linked Data mashups
      Sites that mash up (thus combine Linked data)
      Revyu.com (KMI, UK), DBtune Slashfacet (Queen Mary, UK), DBPedia Mobile (FU Berlin, DE), Semantic Web Pipes (DERI, Ireland)
      Search engines
      To search for Linked Data.
      Falcons (IWS, China), Sindice (DERI, Ireland), MicroSearch (Yahoo, Spain), Watson (Open University, UK), SWSE (DERI, Ireland), Swoogle (UMBC, USA)
      Listing on this slide by T. Heath, M. Hausenblas, C. Bizer, R. Cyganiak, O. Hartig
      19
    • 29. Linked Data browsers (Disco)
    • 30. Linked Data Mashup (LinkedGeoData)
      © Migración de datos a la Web de los Datos - Enfoques, técnicas y herramientas
      Luis Manuel Vilches Blázquez
    • 31. Linked Data Mashup (DBpedia Mobile)
      http://wiki.dbpedia.org/DBpediaMobile
      © Migración de datos a la Web de los Datos - Enfoques, técnicas y herramientas
      Luis Manuel Vilches Blázquez
    • 32. Linked Data Search Engines (Sindice and SIG.MA)
      Entity lookup service. Find a document that mentions a URI or a keyword.
    • 33. Linked Data SearchEngines (NYT)
      The New York Times: Alumni In The News
      http://data.nytimes.com/schools/schools.html
    • 34. Linked Data SearchEngines (NYT)
      The New York Times: Source code is available
      … and is based on SPARQL queries
    • 35. Oneadditionalmotivation: Open Government
      Government and state administration should be opened at all levels to effective public scrutiny and oversight
      Objectives:
      Transparency
      Participation
      Collaboration
      Inclusion
      Cost reduction
      Interoperability
      Reusability
      Leadership
      Market & Value
      26
      • Some Links:
      • 36. B. Obama –Transparency and Open Government
      • 37. T. Berners-Lee - Raw data now!
      • 38. J. Manuel Alonso - ¿Qué es Open Data?
      • 39. Open Government Data
      • 40. 8 Principles of Open Government Data
    • Open Government. USA and UK
      27
      BOTTOM-UP
      Top-down
    • 41. Linked Data Mashup (data.gov)
      Clean Air Status and Trends (CASTNET)
      http://data-gov.tw.rpi.edu/demo/exhibit/demo-8-castnet.php
    • 42. Linked Data in the UK
      Education
      http://education.data.gov.uk/id/school/106661
      Parliament
      http://parliament.psi.enakting.org/id/member/1227
      Maps
      E.g., London: http://data.ordnancesurvey.co.uk/id/7000000000041428
      http://map.psi.enakting.org
      Transport
      http://www.dft.gov.uk/naptan/
      SameAs service
      http://www.sameas.org
      Challenges
      http://gov.tso.co.uk/openup/sparql/gov-transport
      29
    • 43. Linked Data Mashup (data.gov.uk)
      Research Funding Explorer
      http://bis.clients.talis.com/
    • 44. Open GovernmentSpain. Euskadi
      31
    • 45. Open GovernmentSpain. Abredatos
      32
    • 46. Open GovernmentSpain. Zaragoza
      33
    • 47. Open GovernmentSpain. Asturias
      34
    • 48. Linked Data Mashup (Waterquality)
      Water quality in Asturias’ beaches
      http://datos.fundacionctic.org/sandbox/asturias/playas/
    • 49. Contents
      IntroductiontoLinked Data
      Linked Data Foundations: RDF, RDF Schema, SPARQL and OWL
      Coffee break
      Linked Data publication
      MethodologicalguidelinesforLinked Data publication
      RDB2RDF tools
      Technicalaspects of Linked Data publication
      Linked Data consumption
      36
    • 50. Index
      ResourceDescription Framework (RDF)
      RDF primitives
      Reasoningwith RDF
      RDF Schema
      RDF Schemaprimitives
      Reasoningwith RDFS
      RDF(S) Management APIs
      SPARQL
      OWL
      37
    • 51. RDF: Resource Description Framework
      W3C recommendation
      RDF is graphical formalism ( + XML syntax + semantics)
      For representing metadata
      For describing the semantics of information in a machine- accessible way
      Resources are described in terms of properties andproperty values using RDF statements
      Statements are represented as triples, consisting of asubject, predicate and object. [S, P, O]
      “Oscar Corcho García”
      person:hasName
      person:hasColleague
      oeg:Oscar
      oeg:Asun
      person:hasHomePage
      person:hasColleague
      “http://www.fi.upm.es/”
      oeg:Raul
      38
    • 52. RDF and URIs
      RDF uses URIRefs(Unique Resource IdentifiersReferences) toidentify resources
      A URIRef consists of a URI and an optional FragmentIdentifier separated from the URI by the hash symbol ‘#’
      Examples
      http://www.co-ode.org/people#hasColleague
      coode:hasColleague
      A set of URIRefs is known as a vocabulary
      E.g., the RDF Vocabulary
      The set of URIRefs used indescribing the RDF concepts:rdf:Property,rdf:Resource, rdf:type, etc.
      The RDFS Vocabulary
      The set of URIRefs used indescribing the RDF Schema language: rdfs:Class, rdfs:domain, etc.
      The ‘Pizza Ontology’ Vocabulary
      pz:hasTopping,pz:Pizza, pz:VegetarianPizza, etc.
      39
    • 53. RDF Serialisations
      Normative
      RDF/XML (www.w3.org/TR/rdf-syntax-grammar/)
      Alternative (for human consumption)
      N3 (http://www.w3.org/DesignIssues/Notation3.html)
      Turtle (http://www.dajobe.org/2004/01/turtle/)
      TriX (http://www.w3.org/2004/03/trix/)

      Important: the RDF serializations allow different syntactic variants. E.g., the order of RDF statements has no meaning
      40
    • 54. RDF Serialisations. RDF/XML
      <?xml version="1.0"?>
      <rdf:RDF
      xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
      xmlns:person="http://www.ontologies.org/ontologies/people#"
      xmlns="http://www.oeg-upm.net/ontologies/people#"
      xml:base="http://www.oeg-upm.net/ontologies/people">
      <rdf:Property rdf:about="http://www.ontologies.org/ontologies/people#hasHomePage"/>
      <rdf:Property rdf:about="http://www.ontologies.org/ontologies/people#hasColleague"/>
      <rdf:Property rdf:about="http://www.ontologies.org/ontologies/people#hasName"/>
      <rdf:Description rdf:about="#Raul"/>
      <rdf:Description rdf:about="#Asun">
      <person:hasColleague rdf:resource="#Raul"/>
      <person:hasHomePage>http://www.fi.upm.es</person:hasHomePage>
      </rdf:Description>
      <rdf:Description rdf:about="#Oscar">
      <person:hasColleague rdf:resource="#Asun"/>
      <person:hasName>Oscar Corcho García</person:hasName>
      </rdf:Description>
      </rdf:RDF>
      41
    • 55. RDF Serialisations. N3
      @base <http://www.oeg-upm.net/ontologies/people >
      @prefix person: <http://www.ontologies.org/ontologies/people#>
      :Asun person:hasColleague :Raul ;
      person:hasHomePage “http://www.fi.upm.es/”.
      :Oscar person:hasColleague :Asun ;
      person:hasName “Óscar Corcho García”.
      42
    • 56. Exercise
      • Objective
      • 57. Getusedtothedifferentsyntaxesof RDF
      • 58. Tasks
      • 59. Takethetextofan RDF file andcreateitscorrespondinggraph
      • 60. Takean RDF graphandcreateitscorresponding RDF/XML and N3 files
      43
    • 61. Exercise 1.a. Create a graph from a file
      Open the file StickyNote_PureRDF.rdf
      Create the corresponding graph from it
      Compare your graph with those of your colleagues
      44
    • 62. Exercise 1.a. StickyNote_PureRDF.rdf
      45
    • 63. Exercise 1.b. Create files from a graph
      Transform the following graph into N3 syntax
      46
      hasMeasurement
      Measurement8401
      Sensor029
      includes
      hasTemperature
      atTime
      Class01
      includes
      2010-06-12T12:00:12
      29
      Computer101
      hasOwner
      User10A
      hasName
      Pedro
    • 64. Blank nodes: structured property values
      Most real-world data involves structures that are more complicated than sets of RDF triple statements
      In RDF/XML, it is an <rdf:Description> node with no rdf:about
      In N3, it is a resource identifier that starts with ‘_’
      E.g., “_:nodeX”
      Thisintermediate URI doesnotneedtohave a name
      “Oscar Corcho García”
      person:hasName
      person:hasPostalAddress
      oeg:Oscar
      address:hasStreetName
      address:city
      Campus de Montegancedo s/n
      city:BoadillaDelMonte
      47
    • 65. Typed literals
      So far, all values have been presented as strings
      XML Schema datatypes can be used to specify values (objects in some RDF triple statements)
      In RDF/XML, this is expressed as:
      <rdf:Description rdf:about=”#Oscar”> <person:hasBirthDate rdf:datatype="http://www.w3.org/2001/XMLSchema#date">1976-02-02 </person:hasBirthDate></rdf:Description>
      In N3, this is expressed as:
      oeg:Oscar person:hasBirthDate ”1976-02-02”^^xsd:date .
      person:hasBirthDate
      oeg:Oscar
      1976-02-02
      48
    • 66. RDF Containers
      There is often the need to describe groups of things
      A book was created by several authors
      A lesson is taught by several persons
      etc.
      RDF provides a container vocabulary
      rdf:Bag  A group of resources or literals, possibly including duplicate members, where the order of members is not significant
      rdf:Seq  A group of resources or literals, possibly including duplicate members, where the order of members is significant
      rdf:Alt  A group of resources or literals that are alternatives (typically for a single value of a property)
      rdf:type
      person:hasEmailAddress
      oeg:Oscar
      rdf:Seq
      rdf:_2
      rdf:_1
      “oscar.corcho@upm.es”
      “ocorcho@fi.upm.es”
      49
    • 67. RDF Reification
      RDF statements about other RDF statements
      “Raúl believes that Oscar’s birthdate is on Feb 2nd, 1976 and that his e-mail address is ocorcho@fi.upm.es”
      RDF Reification
      Allows expressing beliefs (and other modalities)
      Allows expressing trust models, digital signatures, etc.
      Allows expressing metadata about metadata
      modal:believes
      oeg:Raúl
      oeg:Oscar
      person:hasBirthDate
      person:hasEmailAddress
      02/02/1976
      “ocorcho@fi.upm.es”
      50
    • 68. Main value of a structured value
      Sometimes one of the values of a structured value is the main one
      The weight of an item is 2.4 kilograms
      The most important value is 2.4, which is expressed with rdf:value
      Scarcely used
      product:hasWeight
      product:Item1
      rdf:value
      units:hasWeightUnit
      units:kilogram
      2.4
      51
    • 69. Index
      ResourceDescription Framework (RDF)
      RDF primitives
      Reasoningwith RDF
      RDF Schema
      RDF Schemaprimitives
      Reasoningwith RDFS
      RDF(S) Management APIs
      SPARQL
      OWL
      52
    • 70. RDF inference. Graph matching techniques
      RDF inference is based on graph matching techniques
      Basically, the RDF inference process consists of the following steps:
      Transform an RDF query into a template graph that has to be matched against the RDF graph
      It contains constant and variable nodes, and constant and variable edges between nodes
      Match against the RDF graph, taking into account constant nodes and edges
      Provide a solution for variable nodes and edges
      53
    • 71. RDF inference. Examples (I)
      Sample RDF graph
      Query: “Tell me who are the persons who have Asun as a colleague”
      Result: oeg:Oscar and oeg:Raúl
      “Oscar Corcho García”
      person:hasName
      person:hasColleague
      oeg:Oscar
      oeg:Asun
      person:hasHomePage
      person:hasColleague
      “http://www.fi.upm.es/”
      oeg:Raúl
      person:hasColleague
      ?
      oeg:Asun
      54
    • 72. RDF inference. Examples (II)
      Query: “Tell me which are the relationships between Oscar and Asun”
      Result: oeg:hasColleague
      Query: “Tell me the homepage of Oscar colleagues”
      Result: “http://www.fi.upm.es/”
      ?
      oeg:Oscar
      oeg:Asun
      person:hasColleague
      oeg:Oscar
      person:hasHomePage
      ?
      55
    • 73. RDF inference. Entailment rules
      56
    • 74. Index
      ResourceDescription Framework (RDF)
      RDF primitives
      Reasoningwith RDF
      RDF Schema
      RDF Schemaprimitives
      Reasoningwith RDFS
      RDF(S) Management APIs
      SPARQL
      OWL
      57
    • 75. RDFS: RDF Schema
      W3C Recommendation
      RDF Schema extends RDF to enable talking about classes of resources, and the properties to be used with them
      Class definition: rdfs:Class, rdfs:subClassOf
      Property definition: rdfs:subPropertyOf, rdfs:range, rdfs:domain
      Other primitives: rdfs:comment, rdfs:label, rdfs:seeAlso, rdfs:isDefinedBy
      RDFS vocabulary adds constraints on models, e.g.:
      x,y,ztype(x,y) and subClassOf(y,z) type(x,z)
      ex:Animal
      rdfs:subClassOf
      rdf:type
      ex:Oscar
      ex:Person
      58
    • 76. RDF(S) Serialisations. RDF/XML syntax
      <?xml version="1.0"?>
      <rdf:RDF
      xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
      xmlns:person="http://www.ontologies.org/ontologies/people#"
      xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
      xmlns="http://www.oeg-upm.net/ontologies/people#"
      xml:base="http://www.oeg-upm.net/ontologies/people">
      <rdfs:Class rdf:about="http://www.ontologies.org/ontologies/people#Professor">
      <rdfs:subClassOf>
      <rdfs:Class rdf:about="http://www.ontologies.org/ontologies/people#Person"/>
      </rdfs:subClassOf>
      </rdfs:Class>
      <rdfs:Class rdf:about="http://www.ontologies.org/ontologies/people#Lecturer">
      <rdfs:subClassOf rdf:resource="http://www.ontologies.org/ontologies/people#Person"/>
      </rdfs:Class>
      <rdfs:Class rdf:about="http://www.ontologies.org/ontologies/people#PhD">
      <rdfs:subClassOf rdf:resource="http://www.ontologies.org/ontologies/people#Person"/>
      </rdfs:Class>

      59
    • 77. RDF(S) Serialisations. RDF/XML syntax

      <rdf:Property rdf:about="http://www.ontologies.org/ontologies/people#hasHomePage"/>
      <rdf:Property rdf:about="http://www.ontologies.org/ontologies/people#hasColleague">
      <rdfs:domain rdf:resource=" http://www.ontologies.org/ontologies/people#Person"/>
      <rdfs:range rdf:resource=" http://www.ontologies.org/ontologies/people#Person"/>
      </rdf:Property>
      <rdf:Property rdf:about="http://www.ontologies.org/ontologies/people#hasName">
      <rdfs:domain rdf:resource="http://www.w3.org/2002/07/owl#Thing"/>
      </rdf:Property>
      <person:PhD rdf:ID="Raul"/>
      <person:Professor rdf:ID=“Asun">
      <person:hasColleague rdf:resource="#Raul"/>
      <person:hasHomePage>http://www.fi.upm.es</person:hasHomePage>
      </person:Professor>
      <person:Lecturer rdf:ID="Oscar">
      <person:hasColleague rdf:resource="#Asun"/>
      <person:hasName>Óscar Corcho García</person:hasName>
      </person:Lecturer>
      </rdf:RDF>
      60
    • 78. RDF(S) Serialisations. N3
      @base <http://www.oeg-upm.net/ontologies/people >
      @prefix person: <http://www.ontologies.org/ontologies/people#>
      person:hasColleague a rdf:Property;
      rdfs:domain person:Person;
      rdfs:range person:Person.
      person:Professor rdfs:subClassOf person:Person.
      person:Lecturer rdfs:subClassOf person:Person.
      person:PhD rdfs:subClassOf person:Person.
      :Asun a person:Professor;
      person:hasColleague :Raul ;
      person:hasHomePage “http://www.fi.upm.es/”.
      :Oscar a person:Lecturer;
      person:hasColleague :Asun ;
      person:hasName “Óscar Corcho García”.
      :Raul a person:PhD.
      a is equivalent to rdf:type
      61
    • 79. RDFS
      rdfs:Literal
      rdfs:Class
      rdf:Type
      rdfs:range
      Flight
      rdfs:domain
      arrivalDate
      rdf:Type
      rdfs:domain
      rdfs:domain
      rdfs:domain
      departureDate
      company-name
      singleFare
      rdfs:range
      rdfs:range
      rdf:Type
      rdfs:range
      units:currencyQuantity
      rdf:Type
      time:Date
      rdf:Type
      rdf:Type
      RDF
      rdf:Property
      rdf:Type
      rdf:Type
      company-name
      rdf:Type
      IB-4321
      “Iberia”
      arrivalDate
      singleFare
      departureDate
      10/11/2005
      500 euros
      RDF(S) Example
      62
    • 80. Exercise
      • Objective
      • 81. GetusedtothedifferentsyntaxesofRDF(S)
      • 82. Tasks
      • 83. TakethetextofanRDF(S) file andcreateitscorrespondinggraph
      • 84. TakeanRDF(S) graphandcreateitscorresponding RDF/XML and N3 files
      63
    • 85. Exercise 2.a. Create a graph from a file
      Open the files StickyNote.rdf and StickyNote.rdfs
      Create the corresponding graph from them
      Compare your graph with those of your colleagues
      64
    • 86. Exercise 2.a. StickyNote.rdf
      65
    • 87. Exercise 2.a. StickyNote.rdfs
      66
    • 88. Exercise 2.b. Create files from a graph
      Transform the following graph into N3 syntax
      67
      Room
      Person
      Measurement
      Object
      hasMeasurement
      Sensor029
      includes
      hasTemperature
      atTime
      Class01
      includes
      2010-06-12T12:00:12
      29
      Computer101
      hasOwner
      User10A
      hasName
      Pedro
    • 89. Index
      ResourceDescription Framework (RDF)
      RDF primitives
      Reasoningwith RDF
      RDF Schema
      RDF Schemaprimitives
      Reasoningwith RDFS
      RDF(S) Management APIs
      SPARQL
      OWL
      68
    • 90. RDF(S) inference. Entailment rules
      69
    • 91. RDF(S) inference. Additional inferences
      70
    • 92. RDF(S) limitations
      RDFS too weak to describe resources in sufficient detail
      No localised range and domain constraints
      Can’t say that the range of hasChild is person when applied to persons and elephant when applied to elephants
      No existence/cardinality constraints
      Can’t say that all instances of person have a mother that is also a person, or that persons have exactly 2 parents
      No boolean operators
      Can’t say or, not, etc.
      No transitive, inverse or symmetrical properties
      Can’t say that isPartOf is a transitive property, that hasPart is the inverse of isPartOf or that touches is symmetrical
      Difficult to provide reasoning support
      No “native” reasoners for non-standard semantics
      May be possible to reason via FOL axiomatisation
      71
    • 93. Exercise
      • Objective
      • 94. Understand the features of RDF(S) for implementing ontologies, including its limitations
      • 95. Tasks
      • 96. Given a scenario description, build a simple ontology in RDF Schema
      72
    • 97. Exercise 3. Domain description
      Un lugar puede ser un lugar de interés.
      Los lugares de interés pueden ser lugares turísticos o establecimientos, pero no las dos cosas a la vez.
      Los lugares turísticos pueden ser palacios, iglesias, ermitas y catedrales.
      Los establecimientos pueden ser hoteles, hostales o albergues.
      Un lugar está situado en una localidad, la cual a su vez puede ser una villa, un pueblo o una ciudad.
      Un lugar de interés tiene una dirección postal que incluye su calle y su número.
      Las localidades tienen un número de habitantes.
      Las localidades se encuentran situadas en provincias.
      Covarrubias es un pueblo con 634 habitantes de la provincia de Burgos.
      El restaurante “El Galo” está situado en Covarrubias, en la calle Mayor, número 5.
      Una de las iglesias de Covarrubias está en la calle de Santo Tomás.
      73
    • 98. Exercise 3. Sample resulting ontology
      74
    • 99. Index
      ResourceDescription Framework (RDF)
      RDF primitives
      Reasoningwith RDF
      RDF Schema
      RDF Schemaprimitives
      Reasoningwith RDFS
      RDF(S) Management APIs
      SPARQL
      OWL
      75
    • 100. Sample RDF APIs
      RDF libraries for different languages:
      Java, Python, C, C++, C#, .Net, Javascript, Tcl/Tk, PHP, Lisp, Obj-C, Prolog, Perl, Ruby, Haskell
      List in http://esw.w3.org/topic/SemanticWebTools
      Usually related to a RDF repository
      Multilanguage:
      Redland RDF Application Framework (C, Perl, PHP, Python and Ruby):
      http://www.redland.opensource.ac.uk/
      Java:
      Jena: http://jena.sourceforge.net/
      Sesame: http://www.openrdf.org/
      PHP:
      RAP - RDF API for PHP: http://www4.wiwiss.fu-berlin.de/bizer/rdfapi/
      Python:
      RDFLib: http://rdflib.net/
      Pyrple: http://infomesh.net/pyrple/
      76
    • 101. Jena
      Java framework for building Semantic Web applications
      Open source software from HP Labs
      The Jena framework includes:
      A RDF API
      An OWL API
      Reading and writing RDF in RDF/XML, N3 and N-Triples
      In-memory and persistent storage
      A rule based inference engine
      SPARQL query engine
      77
    • 102. Sesame
      A framework for storage, querying and inferencing of RDF and RDF Schema
      A Java Library for handling RDF
      A Database Server for (remote) access to repositories of RDF data
      Highly expressive query and transformation languages
      SeRQL, SPARQL
      Various backends
      Native Store
      RDBMS (MySQL, Oracle 10, DB2, PostgreSQL)
      main memory
      Reasoning support
      RDF Schema reasoner
      OWL DLP (OWLIM)
      domain reasoning (custom rule engine)
      78
    • 103. Jena example. Graph creation
      http://.../JohnSmith
      vcard:FN
      vcard:N
      John Smith
      vcard:Given
      vcard:Family
      Smith
      John
      // some definitions
      String personURI = "http://somewhere/JohnSmith";
      String givenName = "John";
      String familyName = "Smith";
      String fullName = givenName + " " + familyName;
      // create an empty
      Model Model model = ModelFactory.createDefaultModel();
      // create the resource
      // and add the properties cascading style
      Resource johnSmith = model.createResource(personURI)
      .addProperty(VCARD.FN, fullName)
      .addProperty(VCARD.N, model.createResource()
      .addProperty(VCARD.Given, givenName)
      .addProperty(VCARD.Family, familyName));
      79
    • 104. Jena example. Read and write
      // create an empty model
      Model model = ModelFactory.createDefaultModel();
      // use the FileManager to find the input file
      InputStream in = FileManager.get().open( inputFileName );
      if (in == null) {
      throw new IllegalArgumentException("File not found");
      }
      // read the RDF/XML file
      model.read(in, "");
      // write it to standard out
      model.write(System.out);
      <rdf:RDF
      xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns#'
      xmlns:vcard='http://www.w3.org/2001/vcard-rdf/3.0#'
      >
      <rdf:Description rdf:nodeID="A0">
      <vcard:Family>Smith</vcard:Family>
      <vcard:Given>John</vcard:Given>
      </rdf:Description>
      <rdf:Description rdf:about='http://somewhere/JohnSmith/'>
      <vcard:FN>John Smith</vcard:FN>
      <vcard:N rdf:nodeID="A0"/>
      </rdf:Description>
      ...
      </rdf:RDF>
      80
    • 105. Some RDF editors
      IsaViz
      http://www.w3.org/2001/11/IsaViz/
      Morla
      http://www.morlardf.net/
      RDFAuthor
      http://rdfweb.org/people/damian/RDFAuthor/
      RdfGravity
      http://semweb.salzburgresearch.at/apps/rdf-gravity/
      Rhodonite
      http://rhodonite.angelite.nl/
      81
    • 106. Main References
      Brickley D, Guha RV (2004) RDF Vocabulary Description Language 1.0: RDF Schema. W3C Recommendation
      http://www.w3.org/TR/PR-rdf-schema/
      Lassila O, Swick R (1999) Resource Description Framework (RDF) Model and Syntax Specification. W3C Recommendation
      http://www.w3.org/TR/REC-rdf-syntax/
      RDF validator:
      http://www.w3.org/RDF/Validator/
      RDF resources:
      http://planetrdf.com/guide/
      82
    • 107. Index
      ResourceDescription Framework (RDF)
      RDF primitives
      Reasoningwith RDF
      RDF Schema
      RDF Schemaprimitives
      Reasoningwith RDFS
      RDF(S) Management APIs
      SPARQL
      OWL
      83
    • 108. RDF(S) query languages
      Languages developed to allow accessing datasets expressed in RDF(S) (and in some cases OWL)
      Supported by the most important language APIs
      Jena (HP labs)
      Sesame (Aduna)
      Boca (IBM)
      ...
      There are some differences wrt. languages like SQL, such as
      Combination of different sources
      Trust management
      Open World Assumption
      84
      Application
      Application
      SQL queries
      SPARQL, RQL, etc., queries
      RelationalDB
      RDF(S)OWL
    • 109. Query types
      Selection and extraction
      “Select all the essays, together with their authors and their authors’ names”
      “Select everything that is related to the book ‘Bellum Civille’”
      Reduction: we specify what it should not be returned
      “Select everything except for the ontological information and the book translators”
      Restructuring: the original structure is changed in the final result
      “Invert the relationship ‘author’ by ‘is author of’”
      Aggregation
      “Return all the essays together with the mean number of authors per essay”
      Combination and inferences
      “Combine the information of a book called ‘La guerra civil’ and whose author is Julius Caesar with the book whose identifier is ‘Bellum Civille’”
      “Select all the essays, together with its authors and author names”, including also the instances of the subclasses of Essay
      “Obtain the relationship ‘coauthor’ among persons who have written the same book”
      85
    • 110. RDF(S) query language families
      SPARQL
      W3C Recommendation
      15 January 2008
      Description graphs
      Query semantics
      Triple database Query structure
      SquishQLFamily
      SquishQL
      rdfDB Query Language
      RDQL
      BRQL
      TriQL
      XPath, XSLT, XQuery
      XQueryfor RDF
      XsRQL
      TreeHuggerandRDFTwig
      RDFT, Nexus Query Language
      RDFPath, RpathandRXPath
      Versa
      RQL Family
      RQL
      SeRQL
      eRQL
      Controlled natural language
      Metalog
      Other
      Algae
      iTQL
      N3QL
      PerlRDF Query Language
      RDEVICE DeductiveLanguage
      RDFQBE
      RDFQL
      TRIPLE
      WQL
      XML repository Query syntax
      86
    • 111. SPARQL
      SPARQL Protocol and RDF Query Language
      Supported by: Jena, Sesame, IBM Boca, etc.
      Features
      Itsupportsmostoftheaforementionedqueries
      Itsupportsdatatypereasoning(datatypes can be requestedinsteadof actual values)
      Thedomainvocabularyandtheknowledgerepresentationvocabularyare treateddifferently by thequeryinterpreters
      Itallowsmakingqueriesoverpropertieswithmultiplevalues, overmultiplepropertiesof a resourceandoverreifications
      Queries can containoptionalstatements
      Someimplementationssupportaggregationqueries
      Limitations
      Neitherset operationsnorexistentialor universal quantifierscan be included in thequeries
      Itdoesnotsupportrecursivequeries
      87
    • 112. SPARQL is also a protocol
      SPARQL is a Query Language …Find names and websites of contributors to PlanetRDF:
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      SELECT ?name ?website
      FROM <http://planetrdf.com/bloggers.rdf>
      WHERE {
      ?person foaf:weblog ?website .
      ?person foaf:name ?name .
      ?website a foaf:Document }
      ... and a Protocolhttp://.../qps?query-lang=http://www.w3.org/TR/rdf-sparql-query/ &graph-id=http://planetrdf.com/bloggers.rdf&query=PREFIXfoaf: <http://xmlns.com/foaf/0.1/...
      Services running SPARQL queries over a set of graphs
      A transport protocol for invoking the service
      Based on ideas from earlier protocol work such as Joseki
      Describing the service with Web Service technologies
      88
    • 113. SPARQL Endpoints
      SPARQL protocol services
      Enables users (human or other) to query a knowledge base using SPARQL
      Results are typically returned in one or more machine-processable formats
      List of SPARQL Endpoints
      http://esw.w3.org/topic/SparqlEndpoints
      Programmatic access using libraries:
      ARC, RAP, Jena, Sesame, Javascript SPARQL, PySPARQL, etc.
      Examples:
      89
    • 114. Example: Querying dbpedia
      People who were born in Berlin before 1900
      90
    • 115. A simple SPARQL query
      Data:
      @prefix dc: <http://purl.org/dc/elements/1.1/> .
      @prefix : <http://example.org/book/> .
      :book1 dc:title "SPARQL Tutorial" .
      Query:
      SELECT ?title
      WHERE
      {
      <http://example.org/book/book1> <http://purl.org/dc/elements/1.1/title> ?title .
      }
      Query result:
      • A pattern is matched against the RDF data
      • 116. Each way a pattern can be matched yields a solution
      • 117. The sequence of solutions is filtered by: Project, distinct, order, limit/offset
      • 118. One of the result forms is applied: SELECT, CONSTRUCT, DESCRIBE, ASK
      91
    • 119. Graph patterns
      Basic Graph Patterns, where a set of triple patterns must match
      Group Graph Pattern, where a set of graph patterns must all match
      Optional Graph patterns, where additional patterns may extend the solution
      Alternative Graph Pattern, where two or more possible patterns are tried
      Patterns on Named Graphs, where patterns are matched against named graphs
      92
    • 120. @prefix foaf: <http://xmlns.com/foaf/0.1/> .
      _:a foaf:name "Johnny Lee Outlaw" .
      _:a foaf:mbox <mailto:jlow@example.com> .
      _:bfoaf:name "Peter Goodguy" .
      _:bfoaf:mbox <mailto:peter@example.org> .
      _:cfoaf:mbox <mailto:carol@example.org> .
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      SELECT ?name ?mbox
      WHERE
      { ?x foaf:name ?name .
      ?x foaf:mbox ?mbox }
      Multiple matches
      93
    • 121. @prefix dt: <http://example.org/datatype#> .
      @prefix ns: <http://example.org/ns#> .
      @prefix : <http://example.org/ns#> .
      @prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
      :x ns:p "cat"@en .
      :y ns:p "42"^^xsd:integer .
      :z ns:p "abc"^^dt:specialDatatype .
      SELECT ?v WHERE { ?v ?p "cat" }
      SELECT ?v WHERE { ?v ?p "cat"@en }
      SELECT ?v WHERE { ?v ?p 42 }
      SELECT ?v WHERE { ?v ?p "abc"^^<http://example.org/datatype#specialDatatype> }
      Matching RDF literals
      94
    • 122. @prefix foaf: <http://xmlns.com/foaf/0.1/> .
      _:a foaf:name "Alice" .
      _:bfoaf:name "Bob" .
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      SELECT ?x ?name
      WHERE { ?x foaf:name ?name }
      =
      Blank node labels in query results
      95
    • 123. Group graph pattern
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      SELECT ?name ?mbox
      WHERE { { ?xfoaf:name ?name . }
      { ?xfoaf:mbox ?mbox . }
      }
      SELECT ?x
      WHERE {}
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      SELECT ?name ?mbox
      WHERE { { ?x foaf:name ?name . }
      { ?x foaf:mbox ?mbox . FILTER regex(?name, "Smith")}
      }
      96
    • 124. Optional graph patterns
      @prefix foaf: <http://xmlns.com/foaf/0.1/> .
      @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
      _:a rdf:typefoaf:Person .
      _:a foaf:name "Alice" .
      _:a foaf:mbox <mailto:alice@example.com> .
      _:a foaf:mbox <mailto:alice@work.example> .
      _:brdf:typefoaf:Person .
      _:bfoaf:name "Bob" .
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      SELECT ?name ?mbox
      WHERE { ?x foaf:name ?name .
      OPTIONAL { ?x foaf:mbox ?mbox }
      }
      97
    • 125. Multiple optional graph patterns
      @prefix foaf: <http://xmlns.com/foaf/0.1/> .
      _:a foaf:name "Alice" .
      _:a foaf:homepage <http://work.example.org/alice/> .
      _:bfoaf:name "Bob" .
      _:bfoaf:mbox <mailto:bob@work.example> .
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      SELECT ?name ?mbox ?hpage
      WHERE { ?x foaf:name ?name .
      OPTIONAL { ?x foaf:mbox ?mbox } .
      OPTIONAL { ?x foaf:homepage ?hpage }
      }
      98
    • 126. Alternative graph patterns
      @prefix dc10: <http://purl.org/dc/elements/1.0/> .
      @prefix dc11: <http://purl.org/dc/elements/1.1/> .
      _:a dc10:title "SPARQL Query Language Tutorial" .
      _:a dc10:creator "Alice" .
      _:b dc11:title "SPARQL Protocol Tutorial" .
      _:b dc11:creator "Bob" .
      _:c dc10:title "SPARQL" .
      _:c dc11:title "SPARQL (updated)" .
      PREFIX dc10: <http://purl.org/dc/elements/1.0/>
      PREFIX dc11: <http://purl.org/dc/elements/1.1/>
      SELECT ?title
      WHERE { { ?book dc10:title ?title } UNION
      { ?book dc11:title ?title } }
      SELECT ?x ?y
      WHERE { { ?book dc10:title ?x } UNION
      { ?book dc11:title ?y } }
      SELECT ?title ?author
      WHERE
      { { ?book dc10:title ?title . ?book dc10:creator ?author }
      UNION
      { ?book dc11:title ?title . ?book dc11:creator ?author }}
      99
    • 127. Patterns on named graphs
      # Named graph: http://example.org/foaf/aliceFoaf
      @prefix foaf:<http://.../foaf/0.1/> .
      @prefix rdf:<http://.../1999/02/22-rdf-syntax-ns#> .
      @prefix rdfs:<http://.../2000/01/rdf-schema#> .
      _:a foaf:name "Alice" .
      _:a foaf:mbox <mailto:alice@work.example> .
      _:a foaf:knows _:b .
      _:b foaf:name "Bob" .
      _:b foaf:mbox <mailto:bob@work.example> .
      _:b foaf:nick "Bobby" .
      _:b rdfs:seeAlso <http://example.org/foaf/bobFoaf> .
      <http://example.org/foaf/bobFoaf>
      rdf:type foaf:PersonalProfileDocument .
      # Named graph: http://example.org/foaf/bobFoaf
      @prefix foaf:<http://.../foaf/0.1/> .
      @prefix rdf:<http://.../1999/02/22-rdf-syntax-ns#> .
      @prefix rdfs:<http://.../2000/01/rdf-schema#> .
      _:z foaf:mbox <mailto:bob@work.example> .
      _:z rdfs:seeAlso <http://example.org/foaf/bobFoaf> .
      _:z foaf:nick "Robert" .
      <http://example.org/foaf/bobFoaf>
      rdf:type foaf:PersonalProfileDocument .
      100
    • 128. Patterns on named graphs II
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      SELECT ?src ?bobNick
      FROM NAMED <http://example.org/foaf/aliceFoaf>
      FROM NAMED <http://example.org/foaf/bobFoaf>
      WHERE
      {
      GRAPH ?src
      { ?xfoaf:mbox <mailto:bob@work.example> .
      ?xfoaf:nick ?bobNick
      }
      }
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      PREFIX data: <http://example.org/foaf/>
      SELECT ?nick
      FROM NAMED <http://example.org/foaf/aliceFoaf>
      FROM NAMED <http://example.org/foaf/bobFoaf>
      WHERE
      {
      GRAPH data:bobFoaf {
      ?x foaf:mbox <mailto:bob@work.example> .
      ?x foaf:nick ?nick }
      }
      101
    • 129. Restricting values
      @prefix dc: <http://purl.org/dc/elements/1.1/> .
      @prefix : <http://example.org/book/> .
      @prefix ns: <http://example.org/ns#> .
      :book1 dc:title "SPARQL Tutorial" .
      :book1 ns:price 42 .
      :book2 dc:title "The Semantic Web" .
      :book2 ns:price 23 .
      PREFIX dc: <http://purl.org/dc/elements/1.1/>
      SELECT ?title
      WHERE { ?x dc:title ?title
      FILTER regex(?title, "^SPARQL")
      }
      PREFIX dc: <http://purl.org/dc/elements/1.1/>
      SELECT ?title
      WHERE { ?x dc:title ?title
      FILTER regex(?title, "web", "i" )
      }
      PREFIX dc: <http://purl.org/dc/elements/1.1/>
      PREFIX ns: <http://example.org/ns#>
      SELECT ?title ?price
      WHERE { ?x ns:price ?price .
      FILTER (?price < 30.5)
      ?x dc:title ?title . }
      102
    • 130. Value tests
      Based on XQuery 1.0 and XPath 2.0 Function and Operators
      XSD boolean, string, integer, decimal, float, double, dateTime
      Notation <, >, =, <=, >= and != for value comparisonApply to any type
      BOUND, isURI, isBLANK, isLITERAL
      REGEX, LANG, DATATYPE, STR (lexical form)
      Function call for casting and extensions functions
      103
    • 131. Solution sequences and modifiers
      SELECT ?name
      WHERE { ?x foaf:name ?name ; :empId ?emp }
      ORDER BY ?name DESC(?emp)
      Order modifier: put the solutions in order
      Projection modifier: choose certain variables
      Distinct modifier: ensure solutions in the sequence are unique
      Reduced modifier: permit elimination of some non-unique solutions
      Limit modifier: restrict the number of solutions
      Offset modifier: control where the solutions start from in the overall sequence of solutions
      SELECT ?name
      WHERE
      { ?x foaf:name ?name }
      SELECT DISTINCT ?name
      WHERE { ?x foaf:name ?name }
      SELECT REDUCED ?name
      WHERE { ?x foaf:name ?name }
      SELECT ?name
      WHERE { ?x foaf:name ?name }
      LIMIT 20
      SELECT ?name WHERE { ?x foaf:name ?name }
      ORDER BY ?name
      LIMIT 5
      OFFSET 10
      104
    • 132. SPARQL query forms
      SELECT
      Returns all, or a subset of, the variables bound in a query pattern match
      CONSTRUCT
      Returns an RDF graph constructed by substituting variables in a set of triple templates
      ASK
      Returns a boolean indicating whether a query pattern matches or not
      DESCRIBE
      Returns an RDF graph that describes the resources found
      105
    • 133. SPARQL query forms: SELECT
      @prefix foaf: <http://xmlns.com/foaf/0.1/> .
      _:a foaf:name "Alice" .
      _:a foaf:knows _:b .
      _:a foaf:knows _:c .
      _:bfoaf:name "Bob" .
      _:cfoaf:name "Clare" .
      _:cfoaf:nick "CT" .
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      SELECT ?nameX ?nameY ?nickY
      WHERE
      { ?x foaf:knows ?y ;
      foaf:name ?nameX .
      ?y foaf:name ?nameY .
      OPTIONAL { ?y foaf:nick ?nickY }
      }
      106
    • 134. @prefix foaf: <http://xmlns.com/foaf/0.1/> .
      _:a foaf:name "Alice" .
      _:a foaf:mbox <mailto:alice@example.org> .
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      PREFIX vcard: <http://www.w3.org/2001/vcard-rdf/3.0#>
      CONSTRUCT { <http://example.org/person#Alice> vcard:FN ?name }
      WHERE { ?x foaf:name ?name }
      Query result:
      @prefix vcard: <http://www.w3.org/2001/vcard-rdf/3.0#> .
      <http://example.org/person#Alice> vcard:FN "Alice" .
      SPARQL query forms: CONSTRUCT
      107
    • 135. SPARQL query forms: ASK
      @prefix foaf: <http://xmlns.com/foaf/0.1/> .
      _:a foaf:name "Alice" .
      _:a foaf:homepage <http://work.example.org/alice/> .
      _:b foaf:name "Bob" .
      _:b foaf:mbox <mailto:bob@work.example> .
      PREFIX foaf: <http://xmlns.com/foaf/0.1/>
      ASK { ?xfoaf:name "Alice" }
      Query result:
      yes
      108
    • 136. PREFIX ent: <http://org.example.com/employees#>
      DESCRIBE ?x WHERE { ?xent:employeeId "1234" }
      Query result:
      @prefix foaf: <http://xmlns.com/foaf/0.1/> .
      @prefix vcard: <http://www.w3.org/2001/vcard-rdf/3.0> .
      @prefix exOrg: <http://org.example.com/employees#> .
      @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
      @prefix owl: <http://www.w3.org/2002/07/owl#>
      _:a exOrg:employeeId "1234" ;
      foaf:mbox_sha1sum "ABCD1234" ;
      vcard:N
      [ vcard:Family "Smith" ;
      vcard:Given "John" ] .
      foaf:mbox_sha1sum rdf:type owl:InverseFunctionalProperty .
      SPARQL query forms: DESCRIBE
      109
    • 137. Main References
      Prud’hommeaux E, Seaborne A (2008) SPARQL Query Language for RDF. W3C Recommendation
      http://www.w3.org/TR/rdf-sparql-query/
      SPARQL validator:
      http://www.sparql.org/validator.html
      SPARQL implementations:
      http://esw.w3.org/topic/SparqlImplementations
      SPARQL Endpoints
      http://esw.w3.org/topic/SparqlEndpoints
      SPARQL in Dbpedia
      http://dbpedia.org/sparql
      110
    • 138. Index
      ResourceDescription Framework (RDF)
      RDF primitives
      Reasoningwith RDF
      RDF Schema
      RDF Schemaprimitives
      Reasoningwith RDFS
      RDF(S) Management APIs
      SPARQL
      OWL
      111
    • 139. Description Logics
      A family of logic based Knowledge Representation formalisms
      Descendants of semantic networks and KL-ONE
      Describe domain in terms of concepts (classes), roles (relationships) and individuals
      Specificlanguagescharacterisedbytheconstructors and axiomsusedtoassertknowledgeaboutclasses, roles and individuals.
      Example: ALC (theleastexpressivelanguage in DL thatispropositionallyclosed)
      Constructors: boolean(and, or, not)
      Role restrictions
      Distinguished by:
      Model theoretic semantics
      Decidable fragments of FOL
      Closely related to Propositional Modal & Dynamic Logics
      Provision of inference services
      Sound and complete decision procedures for key problems
      Implemented systems (highly optimised)
    • 140. Structure of DL Ontologies
      A DL ontology can be divided into two parts:
      Tbox (Terminological KB): a set of axioms that describe the structure of a domain :
      Doctor  Person
      Person  Man  Woman
      HappyFather  Man  hasDescendant.(Doctor  hasDescendant.Doctor)
      Abox (Assertional KB): a set of axioms that describe a specific situation :
      John  HappyFather
      hasDescendant (John, Mary)
    • 141. Mostcommonconstructors in classdefinitions
      Intersection: C1 ...  Cn Human  Male
      Union: C1  ...  Cn Doctor  Lawyer
      Negation: C Male
      Nominals: {x1}  ...  {xn} {john}  ...  {mary}
      Universal restriction: P.C hasChild.Doctor
      Existentialrestriction: P.C hasChild.Lawyer
      Maximumcardinality: nP.C 3hasChild.Doctor
      Minimumcardinality: nP.C 1hasChild.Male
      SpecificValue: P.{x} hasColleague.{Matthew}
      Nesting of constructors can bearbitrarilycomplex
      Person hasChild.(Doctor hasChild.Doctor)
      Lots of redundancy
      AB is equivalent to ( A  B)
      P.C is equivalent to P. C
    • 142. OWL (1.0 and 1.1)
      February 2004
      Web Ontology Language
      Built on top of RDF(S)
      Three layers:
      Several syntaxes:
    • OWL 2 (I). New features
      October 2009
      New features
      Syntactic sugar
      Disjoint union of classes
      New expressivity
      Keys
      Property chains
      Richer datatypes, data ranges
      Qualified cardinality restrictions
      Asymmetric, reflexive, and disjoint properties
      Enhanced annotation capabilities
      New syntax
      OWL2 Manchester syntax
    • 152. OWL 2 (II). Three new profiles
      OWL2 EL
      Ontologies that define very large numbers of classes and/or properties,
      Ontology consistency, class expression subsumption, and instance checking can be decided in polynomial time.
      OWL2 QL
      Sound and complete query answering is in LOGSPACE (more precisely, in AC0) with respect to the size of the data (assertions),
      Provides many of the main features necessary to express conceptual models (UML class diagrams and ER diagrams).
      It contains the intersection of RDFS and OWL 2 DL.
      OWL2 RL
      Inspired by Description Logic Programs and pD*.
      Syntactic subset of OWL 2 which is amenable to implementation using rule-based technologies, and presenting a partial axiomatization of the OWL 2 RDF-Based Semantics in the form of first-order implications that can be used as the basis for such an implementation.
      Scalable reasoning without sacrificing too much expressive power.
      Designed for
      OWL applications trading the full expressivity of the language for efficiency,
      RDF(S) applications that need some added expressivity from OWL 2.
    • 153. OWL: Most common constructors
      Intersection: C1 ...  CnintersectionOf Human  Male
      Union: C1  ...  CnunionOf Doctor  Lawyer
      Negation: C complementOf Male
      Nominals: {x1}  ...  {xn} oneOf {john}  ...  {mary}
      Universal restriction: P.C allValuesFrom hasChild.Doctor
      Existentialrestriction: P.C someValuesFrom hasChild.Lawyer
      Maximumcardinality: nP[.C] maxCardinality (qualifiedornot) 3hasChild[.Doctor]
      Minimumcardinality: nP[.C] minCardinality (qualifiedornot) 1hasChild[.Male]
      Exactcardinality: =nP[.C] exactCardinality (qualifiedornot) =1hasMother[.Female]
      SpecificValue: P.{x} hasValue hasColleague.{Matthew}
      Local reflexivity: -- hasSelfNarcisist  Person  hasSelf(loves)
      Keys -- hasKeyhasKey(Person, passportNumber, country)
      Subclass C1  C2 subClassOf Human  Animal  Biped
      Equivalence C1  C2 equivalentClass Man  Human  Male
      Disjointness C1  C2   disjointWith, AllDisjointClasses Male  Female  
      DisjointUnion C  C1  ...  Cn and Ci Cj   foralli≠jdisjointUnionOf Person DisjointUnionOf (Man, Woman)
      Metaclasses and annotations on axioms are also valid in OWL2, and declarations of classes have to provided.
      Full list available in reference specs and in the Quick Reference Guide: http://www.w3.org/2007/OWL/refcard
    • 154. OWL: Most common constructors
      Subproperty P1  P2 subPropertyOf hasDaughter  hasChild
      Equivalence P1  P2 equivalentProperty cost  price
      DisjointProperties P1  ...  Pn   disjointObjectProperties hasDaughter  hasSon  
      Inverse P1  P2- inverseOf hasChild  hasParent-
      Transitive P+  P TransitiveProperty ancestor+  ancestor
      Functional   1P FunctionalProperty T  1hasMother
      InverseFunctional   1P- InverseFunctionalProperty T  1hasPassportID-
      Reflexive ReflexiveProperty
      Irreflexive IrreflexiveProperty
      Asymmetric AsymmetricProperty
      Property chains P  P1 o ... o Pn propertyChainAxiom hasUncle  hasFather o hasBrother
      Equivalence {x1}  {x2} sameIndividualAs {oeg:OscarCorcho}{img:Oscar}
      Different {x1}  {x2} differentFrom, AllDifferent {john}  {peter}
      NegativePropertyAssertion NegativeDataPropertyAssertion {hasAge john 35}
      NegativeObjectPropertyAssertion {hasChild john peter}
      Besides, top and bottom object and datatype properties exist
    • 155. Basic Inference Tasks
      Subsumption – check knowledge is correct (captures intuitions)
      Does C subsume D w.r.t. ontology O? (in every modelI of O, CIDI )
      Equivalence – check knowledge is minimally redundant (no unintended synonyms)
      Is C equivalent to D w.r.t. O? (in every modelI of O, CI = DI )
      Consistency – check knowledge is meaningful (classes can have instances)
      Is C satisfiable w.r.t. O? (there exists some modelI of O s.t. CI)
      Instantiation and querying
      Is x an instance of C w.r.t. O? (in every modelI of O, xICI )
      Is (x,y) an instance of R w.r.t. O? (in every modelI of O, (xI,yI) RI )
      All reducible to KB satisfiability or concept satisfiability w.r.t. a KB
      Can be decided using highly optimised tableaux reasoners
    • 156. MainReferences
      W3C OWL Working Group (2009) OWL2 Web Ontology Language Document Overview. http://www.w3.org/TR/2009/REC-owl2-overview-20091027/
      Dean M, Schreiber G (2004) OWL Web Ontology Language Reference. W3C Recommendation. http://www.w3.org/TR/owl-ref/
      Gómez-Pérez, A.; Fernández-López, M.; Corcho, O. Ontological Engineering. Springer Verlag. 2003
      Capítulo 4: Ontology languages
      Baader F, McGuinness D, Nardi D, Patel-Schneider P (2003) The Description Logic Handbook: Theory, implementation and applications. Cambridge University Press, Cambridge, United Kingdom
      Jena web site:http://jena.sourceforge.net/
      Jena API: http://jena.sourceforge.net/tutorial/RDF_API/
      Jena tutorials:http://www.ibm.com/developerworks/xml/library/j-jena/index.html
      http://www.xml.com/pub/a/2001/05/23/jena.html
      Pellet: http://clarkparsia.com/pellet
      RACER: http://www.racer-systems.com/
      FaCT++: http://owl.man.ac.uk/factplusplus/
      HermIT: http://hermit-reasoner.com/
    • 157. Contents
      IntroductiontoLinked Data
      Linked Data Foundations: RDF, RDF Schema, SPARQL and OWL
      Coffee break
      Linked Data publication
      MethodologicalguidelinesforLinked Data publication
      RDB2RDF tools
      Technicalaspects of Linked Data publication
      Linked Data consumption
      122
    • 158. MethodologicalguidelinesforLinked Data publication
      Motivation
      Related Work
      GeoLinkedData
      Identification of the data sources
      Vocabulary Development
      Generation of the RDF data
      Publication of the RDF data
      Data cleansing
      Linking the RDF data
      Enable effective discovery
      Future Work
    • 159. GeoLinkedData
      It is an open initiative whose aim is to enrich the Web of Data with Spanish geospatial data.
      This initiative has started off by publishing diverse information sources, such as National Geographic Institute of Spain (IGN-E) and National Statistics Institute (INE)
      http://geo.linkeddata.es
    • 160. Motivation
      99.171 % English
      0.019 % Spanish
      The Web of Data ismainlyfor
      Englishspeakers
      Poorpresence of Spanish
      Source:Billion Triples dataset at http://km.aifb.kit.edu/projects/btc-2010/
      Thanks to Aidan and Richard
    • 161. Related Work
    • 162. Impact of Geo.linkeddata.es
      Número de tripletas en Español (July): 1.412.248
      Número de tripletas en Español (End august): 21.463.088
      127
      Asunción Gómez Pérez
    • 163. Processfor Publishing Linked Data onthe Web
      Identification
      of the data sources
      Vocabulary
      development
      Generation
      of the RDF Data
      Publication
      of the RDF data
      Data cleansing
      Linking
      the RDF data
      Enable effective
      discovery
    • 164. 1. Identification and selection of the data sources
      Identification
      of the data sources
      Instituto GeográficoNacional
      Vocabulary
      development
      Generation
      of the RDF Data
      Publication
      of the RDF data
      Data cleansing
      Linking
      the RDF data
      Instituto Nacionalde Estadística
      Enable effective
      discovery
    • 165. 1. Identification and selection of the data sources
      Instituto Geográfico Nacional (GeographicSpanishInstitute)
      Multilingual (Spanish, Vasc, Gallician, Catalan)
      Conceptualizationmistmatches
      Granularity (scale concept)
      Textual information
      Particularaties
      Longitude
      latitude
      • Instituto Nacional de Estadística (StatisticSpanishInstitute)
      • 166. Monolingual
      • 167. Numericalinformation
      • 168. Particularaties
      Geo (textual level)
      Temporal
      130
      Asunción Gómez Pérez
    • 169. 1. Identification and selection of the data sources
      IGN-E
    • 170. 1. Identification and selection of the data sources
      IndustryProductionIndex
      Year
      Province
    • 171. 2. Vocabulary development
      http://www4.wiwiss.fu-berlin.de/bizer/pub/LinkedDataTutorial/#whichvocabs
      Identification
      of the data sources
      Vocabulary
      development
      Generation
      of the RDF Data
      Thisisnotenough
      Publication
      of the RDF data
      Data cleansing
      Linking
      the RDF data
      Enable effective
      discovery
    • 172. 2. Vocabularydevelopment
      Features
      Lightweight :
      Taxonomies and a fewproperties
      Consensuatedvocabularies
      Toavoidthemappingproblems
      Multilingual
      Linked data are multilingual
      TheNeOnmethodology can helpto
      Re-enginer Non ontologicalresourcesintoontologies
      Pros: use domainterminologyalreadyconsensuatedbydomainexperts
      Withdraw in heavyweightontologiesthosefeaturesthatyoudon’tneed
      Reuseexistingvocabularies
      134
      Identification
      of the data sources
      Vocabulary
      development
      Generation
      of the RDF Data
      Publication
      of the RDF data
      Data cleansing
      Linking
      the RDF data
      Enable effective
      discovery
      Asunción Gómez Pérez
    • 173. Knowledge Resources
      Ontological Resources
      O. Design Patterns
      3
      4
      O. Repositories and Registries
      5
      6
      Flogic
      RDF(S)
      OWL
      OntologicalResource
      Reuse
      O. Aligning
      O. Merging
      5
      6
      2
      Ontology Design
      Pattern Reuse
      Non Ontological Resource
      Reuse
      4
      3
      6
      Non Ontological Resources
      2
      Ontological Resource
      Reengineering
      7
      Glossaries
      Dictionaries
      Lexicons
      5
      Non Ontological Resource
      Reengineering
      4
      6
      Classification
      Schemas
      Thesauri
      Taxonomies
      Alignments
      2
      RDF(S)
      1
      Flogic
      O. Conceptualization
      O. Implementation
      O. Formalization
      O. Specification
      Scheduling
      OWL
      8
      Ontology Restructuring
      (Pruning, Extension,
      Specialization, Modularization)
      9
      O. Localization
      1,2,3,4,5,6,7,8, 9
      Ontology Support Activities: Knowledge Acquisition (Elicitation); Documentation;
      Configuration Management; Evaluation (V&V); Assessment
      135
    • 174. Vocabularydevelopment: Specification
      Content requirements: Identifythe set of questionsthattheontologyshouldanswer
      Whichone are theprovinces in Spain?
      Where are thebeaches?
      Where are thereservoirs?
      Identifytheproductionindex in Madrid
      Whichoneisthecitywithhigherproductionindex?
      Give me Madrid latitude and altitude
      ….
      Non-contentrequirements
      Theontologymustbe in thefourofficialSpanishlanguages
      136
      Asunción Gómez Pérez
    • 175. 2. Lightweight Ontology Development
      WGS84 Geo Positioning: an RDF vocabulary
      scv:Dimension
      scv:Item
      scv:Dataset
      hydrographical phenomena (rivers, lakes, etc.)
      Vocabulary for instants, intervals, durations, etc.
      Names and international code systems for territories and groups
      Ontology for OGC Geography Markup Language
      reused
      Following the INSPIRE
      (INfrastructure for SPatial InfoRmation in Europe) recommendation.
      hydrOntology,SCOVO, FAO Geopolitcal, WGS84, GML, and Time
    • 176. Objetivos:
      INSPIRE intenta conseguir fuentes armonizadas de Información Geográfica para dar soporte a la formulación, implementación y evaluación de políticas comunitarias (Medio Ambiente, etc).
      Fuentes de Información Geográfica: Bases de datos de los Estados Miembros (UE) a nivel local, regional, nacional e internacional.
      Contexto – Directiva INSPIRE
      Luis Manuel Vilches Blázquez
    • 177. INSPIRE - Anexos
      Luis Manuel Vilches Blázquez
    • 178. hydrOntology
      Existencia de gran diversidad de problemas (múltiples fuentes, heterogeneidad de contenido y estructuración, ambigüedad del lenguaje natural, etc.) en la información geográfica.
      Necesidad de un modelo compartido para solventar los problemas de armonización y estructuración de la información hidrográfica.
      hydrOntology es una ontología global de dominio desarrollada conforme a un acercamiento top-down.
      Recubrir la mayoría de los fenómenos representables cartográficamente asociados al dominio hidrográfico.
      Servir como marco de armonización entre los diferentes productores de información geo-espacial en el entorno nacional e internacional.
      Comenzar con los pasos necesarios para obtener una mejor organización y gestión de la información geográfica (hidrográfica).
      Luis Manuel Vilches Blázquez
    • 179. Fuentes
      Tesauros y Bibliografía
      Catálogos de fenómenos
      Getty
      FTT ADL
      BCN25
      GEMET
      WFD
      CC.AA.
      EGM & ERM
      Diccionarios y
      Monografías
      BCN200
      Nomenclátor Geográfico Nacional
      Nomenclátor Conciso
      Luis Manuel Vilches Blázquez
    • 180. Criterios de estructuración
      Directiva Marco del Agua
      Propuesta por Parlamento y Consejo de la UE
      Lista de definiciones de fenómenos hidrográficos
      Proyecto SDIGER
      Proyecto piloto INSPIRE
      Dos cuencas, países e idiomas
      Criterios semánticos
      Diccionarios geográficos
      Diccionario de la Real Academia de la Lengua
      WordNet
      Wikipedia
      Bibliografía de varias áreas de conocimiento
      Herencia: Estructuración actual de catálogos
      Asesoramiento expertos en toponimia del IGN
      Luis Manuel Vilches Blázquez
    • 181. Modelización del dominio hidrográfico
      Luis Manuel Vilches Blázquez
    • 182. Implementación & Formalizacón
      + Pellet
      4
      1
      2
      5
      3
      +150 conceptos (classes) , 47 tipos de relaciones (properties) y 64 tipos de atributos (attribute types)
      Luis Manuel Vilches Blázquez
    • 183. 2. Vocabularydevelopment: HydrOntology
      145
      Asunción Gómez Pérez
    • 184. 3. Generation of RDF
      From the Data sources
      Geographic information (Databases)
      Statistic information (.xsl)
      Geospatial information
      Different technologies for RDF generation
      Reengineering patterns
      R20 and ODEMapster
      Annotation tools
      Geometry generation
      Identification
      of the data sources
      Vocabulary
      development
      Generation
      of the RDF Data
      Publication
      of the RDF data
      Data cleansing
      Linking
      the RDF data
      Enable effective
      discovery
    • 185. 3. Generation of the RDF Data
      NOR2O
      INE
      ODEMapster
      IGN
      Geometry2RDF
      Geospatial
      column
      IGN
    • 186. 3. Generation of the RDF Data / instances
      NOR2O is a software librarythatimplementsthetransformationsproposedbythePatternsfor Re-engineering Non-OntologicalResources (PR-NOR). Currentlywehave 16 PR-NORs.
      PR-NORs define a procedurethattransforms a Non-OntologicalResource (NOR) componentsintoontologyelements. http://ontologydesignpatterns.org/
      · Classification
      schemes
      NOR2O
      · Thesauri
      · Lexicons
      NOR2O
      FAO Water classification
      · Classification scheme
      · Path enumeration data model
      · Implemented in a database
    • 187. Re-engineeringModelforNORs
      Patterns for Re-engineering
      Non-Ontological Resources
      (PR-NOR)
      Ontology Forward
      Engineering
      Con-
      ceptual
      Speci-
      fication
      NOR Reverse
      Engineering
      Conceptua-
      lization
      Transformation
      Requirements
      Formalization
      Design
      Implementation
      Implementation
      RDF(S)
      Non-Ontological Resource
      Ontology
    • 188. PR-NOR library at the ODP Portal
      Technologicalsupport
      http://ontologydesignpatterns.org/wiki/Submissions:ReengineeringODPs
    • 189. 3. Generation of the RDF Data – NOR2O
      NOR2O
      Year
      Industry Production Index
      Province
    • 190. hydrOntology & Bases de Datos
      NGN
      1:25.000
      multilingüe
      © Migración de datos a la Web de los Datos - Enfoques, técnicas y herramientas
      Luis Manuel Vilches Blázquez
    • 191. 3. Generation of the RDF Data – R2O & ODEMapster
      Creation of the R2O Mappings
    • 192. 3. Generation of the RDF Data – Geometry2RDF
      Oracle STO UTIL package
      SELECT TO_CHAR(SDO_UTIL.TO_GML311GEOMETRY(geometry))
      AS Gml311Geometry
      FROM "BCN200"."BCN200_0301L_RIO" c
      WHERE c.Etiqueta='Arroyo'
    • 193. 3. Generation of the RDF Data – Geometry2RDF
    • 194. 3. Generation of the RDF Data – Geometry2RDF
    • 195. 3. Generation of the RDF data – RDF graphs
      IGN INE
      So far
      7 RDF Named Graphs
      1.412.248 triples
      BTN25
      BCN200
      IPI
      ….
      http://geo.linkeddata.es/dataset/IGN/BTN25
      http://geo.linkeddata.es/dataset/IGN/BCN200
      http://geo.linkeddata.es/dataset/INE/IPI
    • 196. 4. Publication of the RDF Data
      Identification
      of the data sources
      Vocabulary
      development
      SPARQL
      Linked Data
      HTML
      Generation
      of the RDF Data
      IncludingProvenance
      Support
      Publication
      of the RDF data
      Pubby
      Pubby 0.3
      Data cleansing
      Linking
      the RDF data
      Enable effective
      discovery
      Virtuoso 6.1.0
    • 197. 4. Publication of the RDF Data
    • 198. 4. Publication of the RDF Data - License
      License for GeoLinkedData
      Creative Commons Attribution-ShareAlike 3.0
      GNU Free Documentation License
      Each dataset will have its own specific license, IGN, INE, etc.
    • 199. 5. Data cleansing
      Identification
      of the data sources
      Lack of documentation of the IGN datasets
      Broken links: Spain, IGN resources
      Lack of documentation of theontology
      Missingenglish and spanishlabels
      Building a spanish ontology and importing some concepts of other ontology (in English):
      Importing the English ontology. Add annotations like a Spanish label to them.
      Importing the English ontology, creating new concepts and properties with a Spanish name and map those to the English equivalents.
      Re-declaring the terms of the English ontology that we need (using the same URI as in the English ontology), and adding a Spanish label.
      Creating your own class and properties that model the same things as the English ontology.
      Vocabulary
      development
      Generation
      of the RDF Data
      Publication
      of the RDF data
      Data cleansing
      Linking
      the RDF data
      Enable effective
      discovery
    • 200. 5. Data cleansing
      URIs in Spanish
      http://geo.linkeddata.es/ontology/Río
      RDF allows UTF-8 characters for URIs
      But, Linked Data URIs has to be URLs as well
      So, non ASCII-US characters have to be %code
      http://geo.linkeddata.es/ontology/R%C3%ADo
    • 201. 6. Linking of the RDF Data
      Identification
      of the data sources
      Silk - A Link Discovery Framework for the Web of Data
      First set of links: Provinces of Spain
      86% accuracy
      Vocabulary
      development
      Geonames
      Generation
      of the RDF Data
      GeoLinkedData
      DBPedia
      Publication
      of the RDF data
      Data cleansing
      Linking
      the RDF data
      Enable effective
      discovery
    • 202. 6. Linking of the RDF Data
      http://geo.linkeddata.es/page/Provincia/Granada
      164
      Asunción Gómez Pérez
    • 203. 7. Enable effective discovery
      Identification
      of the data sources
      Vocabulary
      development
      Generation
      of the RDF Data
      Publication
      of the RDF data
      Data cleansing
      Linking
      the RDF data
      Enable effective
      discovery
    • 204. DEMO
      http://geo.linkeddata.es/
    • 205. Provinces
    • 206. IndustryProductionIndex – Capital of Province
    • 207. Rivers
    • 208. Beaches
    • 209. Future Work
      Generate more datasets from other domains, e.g. universities in Spain.
      Identify more links to DBPedia and Geonames.
      Cover complex geometrical information, i.e. not only Point and LineString-like data; we will also treat information representation through polygons.
    • 210. Contents
      IntroductiontoLinked Data
      Linked Data Foundations: RDF, RDF Schema, SPARQL and OWL
      Coffee break
      Linked Data publication
      MethodologicalguidelinesforLinked Data publication
      RDB2RDF tools
      Technicalaspects of Linked Data publication
      Linked Data consumption
      172
    • 211. Ontology-based Access to DBs
      1
      3
      2
      4
      Build a new ontology from 1 DB schema and 1 DB
      Align the ontology built with approach 1 with a legacy ontology
      Align an existing DB with a legacy ontology
      a) Massive dump (semantic data warehouse)
      b) Query-driven
      Align an ontology network with n DB schemas and other data sources
      a) Massive dump (semantic data warehouse)
      b) Query-driven
      new ontology
      existing ontology
    • 212. Ontology-based Access to Databases
      Universidad
      Profesor
      Doctorando
      Ontología
      ?
      Organización
      Personal
      BDR
      Modelo
      Relacional
      Pregunta: Nombre de los profesores de la universidad UPM
      * Un profesor es una persona cuyo puesto es “docente”
      * Una universidad es una organización de tipo “3”
      Procesador
      Procesado de la consulta de acuerdo a la descripción formal de correspondencia
      Consulta: valores de la columna nombre de los registros de la tabla Personal para los que el valor de la columna puesto is “docente” que estén relacionados con al menos un registro de la tabla Organización con el valor “3” en la columna tipo y “UPM” en la columna nombre.
    • 213. Align data sourceswithlegacyontologies
      Aeropuertos
      Ontología O2
      Ontología O1
      Centro
      Comunicaciones
      PuntoGPS
      Estación
      Punto Europeo
      Aeropuerto
      PuntoAsiatico
      PuntoEspañol
      Aeropuerto
      f (Aeropuertos)
      =
      PuntoEuropeo
      f (Aeropuertos)
      =
      RC(O2,M1)
      RC(O1,M1)
      Modelo Relacional M1
    • 214. R2O
      is a declarative language to specify mappings between relational data sources and ontologies.
      <xml>
      R2O Mapping
      </xml>
      Organization
      Persons
      University
      RDB
      Professor
      Student
      Relational Model
      Ontology
    • 215. Example: types of mappingsneeded
      Attibute Mapping with transformation
      (Regular Expression)
      Attibute Direct Mapping
      Relation Mapping w. Transformation
      (Regular Expression)
      Relation Mapping w. Transformation
      (Keyword search)
    • 216. Population example (II)
      Population example (II)
      The Operation element defines a transformation based on a regular expression to be applied to the database column for extracting property values
    • 217. For concepts...
      One or more concepts can be extracted from a single data field (not in 1NF).
      A view maps exactly one concept in the ontology.
      For attributes...
      A column in a database view maps directly an attribute or a relation.
      A subset of the columns in the view map a concept in the ontology.
      A subset (selection) of the records of a database view map a concept in the ontology.
      A column in a database view maps an attribute or a relation after some transformation.
      A subset of the records of a database view map a concept in the onto. but the selection cannot be made using SQL.
      A set of columns in a database view map an attribute or a relation.
      R2O (Relational-to-Ontology) Language
    • 218. R2O Basic Syntax
      <conceptmap-defname="Customer">
      <identified-by> Table key </identified-by>
      <uri-as>operation</uri-as>
      <applies-if>condition</applies-if>
      <joins-via> expression </joins-via>
      <documentation>description …</documentation>
      <described-by>attributes,relations</described-by>
      </conceptmap-def>
      <attributemap-defname="http://esperonto/ff#Title">
      <aftertransform>
      <operationoper-id="constant">
      <arg-restrictionon-param="const-val">
      <has-column>fsb_ajut.titol</has-column>
      </arg-restriction>
      </operation>
      </aftertransform>
      </attributemap-def>
      <relationmap-defname="http://esperonto/ff#isCandidateFor">
      <to-concept name="http://esperonto/ff#FundOpp">
      <joins-via>
      <operationoper-id=“equals">
      <arg-restrictionon-param="value1">
      <has-column>fsb_ajut.id</has-column>
      </arg-restriction>
      <arg-restriction on-param="value2">
      <has-column>fsb_candidate.forFund</has-column>
      </arg-restriction>
      </operation>
      </joins-via>
      </relationmap-def>
    • 219. ODEMapster
      generates RDF instances from relational instances based on the mapping description expressed in the R2O document
    • 220. 182
      Mapping Design
      • 3 Mapping Creation Steps
      • 221. Load Ontology
      • 222. Load Database(s)
      • 223. Create mapping
      • 224. 2 Usage Modes
      • 225. Online mode (run time query execution)
      • 226. Offline mode (materialized RDF dump)
    • Contents
      IntroductiontoLinked Data
      Linked Data Foundations: RDF, RDF Schema, SPARQL and OWL
      Coffee break
      Linked Data publication
      MethodologicalguidelinesforLinked Data publication
      RDB2RDF tools
      Technicalaspects of Linked Data publication
      Linked Data consumption
      183
    • 227. Using an RDF repository
      Itallowsstoring and accessing RDF data
      Forexample, SESAME (http://www.openrdf.org/)
      Downloaditfromhttp://www.openrdf.org/download.jsp
      openrdf-sesame-2.3.0-sdk.zip
      Deploythe .war in Tomcat (JDK and Tomcatneeded)
      Create a repository at
      http://localhost:8080/openrdf-sesame
      Check:
      http://localhost:8080/openrdf-sesame/repositories/XXXX
      http://localhost:8080/openrdf-sesame/repositories/XXX/statements
    • 228. Linked Data frontend
      Toexpose data as Linked Data
      Includingcontentnegotiation, etc.
      Forexample, Pubby
      http://www4.wiwiss.fu-berlin.de/pubby/
      Installation
      Use pubby-0.3.zip
      Deploythewebapp folder (and rename)in Tomcat
      Modify config.n3
      Restarttomcat
      Check: http://localhost:8080/XXX/
    • 229. REST API
      • Forexample, RDF2Go
      • 230. Java abstractionover RDF repositories
      http://rdf2go.semweb4j.org/
    • 231. Add SPARQL explorer
      Forexample, SNORQL (http://wiki.github.com/kurtjx/SNORQL/)
    • 232. ValidatingLinked Data URLs
      http://validator.linkeddata.org/vapour
      188
    • 233. Contents
      IntroductiontoLinked Data
      Linked Data Foundations: RDF, RDF Schema, SPARQL and OWL
      Coffee break
      Linked Data publication
      MethodologicalguidelinesforLinked Data publication
      RDB2RDF tools
      Technicalaspects of Linked Data publication
      Linked Data consumption
      189
    • 234. RelFinder: finding relations in Linked Data
      E.g., relations between films
      “Pulp Fiction”, “Kill Bill” y “Reservoir Dogs”
    • 235. Exerciseon data.gov.uk
      • Publicschools in London thatcontaintheword “music”
    • Exercise: find information in DBPedia
      Image by http://www.flickr.com/photos/bflv/
      http://dbpedia.org/resource/Darth_Vader)
      • Findficticious serial killers in DBPedia
      (etc)
    • 236. Designing URI sets forthePublic Sector (UK)
      http://www.cabinetoffice.gov.uk/media/301253/puiblic_sector_uri.pdf
      193
    • 237. Asociación Española de Linked Data
      194
    • 238. Mini-curso sobre LinkedData
      Oscar Corcho, Asunción Gómez Pérez ({ocorcho, asun}@fi.upm.es)
      Universidad Politécnica de Madrid
      Florianópolis, September 1st 2010(3º OntoBras 2010)
      Credits: Raúl García Castro, Oscar Muñoz, Jose Angel Ramos Gargantilla, María del Carmen Suárez de Figueroa, Boris Villazón, Alex de León, Víctor Saquicela, Luis Vilches, Miguel Angel García, Manuel Salvadores, Juan Sequeda, Carlos Ruiz Moreno and manyothers
      WorkdistributedunderthelicenseCreativeCommonsAttribution-Noncommercial-Share Alike 3.0

    ×